@learncard/network-plugin 1.2.2 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lcn-plugin.cjs.development.js +6 -0
- package/dist/lcn-plugin.cjs.development.js.map +2 -2
- package/dist/lcn-plugin.cjs.production.min.js +1 -1
- package/dist/lcn-plugin.cjs.production.min.js.map +3 -3
- package/dist/lcn-plugin.esm.js +6 -0
- package/dist/lcn-plugin.esm.js.map +2 -2
- package/dist/types.d.ts +2 -0
- package/package.json +4 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var HH=Object.create;var y0=Object.defineProperty;var zH=Object.getOwnPropertyDescriptor;var $H=Object.getOwnPropertyNames;var GH=Object.getPrototypeOf,KH=Object.prototype.hasOwnProperty;var s=(t,e)=>y0(t,"name",{value:e,configurable:!0});var an=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),vl=(t,e)=>{for(var r in e)y0(t,r,{get:e[r],enumerable:!0})},mC=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of $H(e))!KH.call(t,i)&&i!==r&&y0(t,i,{get:()=>e[i],enumerable:!(n=zH(e,i))||n.enumerable});return t};var Js=(t,e,r)=>(r=t!=null?HH(GH(t)):{},mC(e||!t||!t.__esModule?y0(r,"default",{value:t,enumerable:!0}):r,t)),VH=t=>mC(y0({},"__esModule",{value:!0}),t);var JC=an((S0,C0)=>{"use strict";Object.defineProperty(S0,"__esModule",{value:!0});var GC=new WeakMap,t3=new WeakMap;function Qr(t){let e=GC.get(t);return console.assert(e!=null,"'this' is expected an Event object, but got",t),e}s(Qr,"pd");function jC(t){if(t.passiveListener!=null){typeof console<"u"&&typeof console.error=="function"&&console.error("Unable to preventDefault inside passive event listener invocation.",t.passiveListener);return}!t.event.cancelable||(t.canceled=!0,typeof t.event.preventDefault=="function"&&t.event.preventDefault())}s(jC,"setCancelFlag");function Uu(t,e){GC.set(this,{eventTarget:t,event:e,eventPhase:2,currentTarget:t,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:e.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let r=Object.keys(e);for(let n=0;n<r.length;++n){let i=r[n];i in this||Object.defineProperty(this,i,KC(i))}}s(Uu,"Event");Uu.prototype={get type(){return Qr(this).event.type},get target(){return Qr(this).eventTarget},get currentTarget(){return Qr(this).currentTarget},composedPath(){let t=Qr(this).currentTarget;return t==null?[]:[t]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return Qr(this).eventPhase},stopPropagation(){let t=Qr(this);t.stopped=!0,typeof t.event.stopPropagation=="function"&&t.event.stopPropagation()},stopImmediatePropagation(){let t=Qr(this);t.stopped=!0,t.immediateStopped=!0,typeof t.event.stopImmediatePropagation=="function"&&t.event.stopImmediatePropagation()},get bubbles(){return Boolean(Qr(this).event.bubbles)},get cancelable(){return Boolean(Qr(this).event.cancelable)},preventDefault(){jC(Qr(this))},get defaultPrevented(){return Qr(this).canceled},get composed(){return Boolean(Qr(this).event.composed)},get timeStamp(){return Qr(this).timeStamp},get srcElement(){return Qr(this).eventTarget},get cancelBubble(){return Qr(this).stopped},set cancelBubble(t){if(!t)return;let e=Qr(this);e.stopped=!0,typeof e.event.cancelBubble=="boolean"&&(e.event.cancelBubble=!0)},get returnValue(){return!Qr(this).canceled},set returnValue(t){t||jC(Qr(this))},initEvent(){}};Object.defineProperty(Uu.prototype,"constructor",{value:Uu,configurable:!0,writable:!0});typeof window<"u"&&typeof window.Event<"u"&&(Object.setPrototypeOf(Uu.prototype,window.Event.prototype),t3.set(window.Event.prototype,Uu));function KC(t){return{get(){return Qr(this).event[t]},set(e){Qr(this).event[t]=e},configurable:!0,enumerable:!0}}s(KC,"defineRedirectDescriptor");function C$(t){return{value(){let e=Qr(this).event;return e[t].apply(e,arguments)},configurable:!0,enumerable:!0}}s(C$,"defineCallDescriptor");function S$(t,e){let r=Object.keys(e);if(r.length===0)return t;function n(i,o){t.call(this,i,o)}s(n,"CustomEvent"),n.prototype=Object.create(t.prototype,{constructor:{value:n,configurable:!0,writable:!0}});for(let i=0;i<r.length;++i){let o=r[i];if(!(o in t.prototype)){let f=typeof Object.getOwnPropertyDescriptor(e,o).value=="function";Object.defineProperty(n.prototype,o,f?C$(o):KC(o))}}return n}s(S$,"defineWrapper");function VC(t){if(t==null||t===Object.prototype)return Uu;let e=t3.get(t);return e==null&&(e=S$(VC(Object.getPrototypeOf(t)),t),t3.set(t,e)),e}s(VC,"getWrapper");function I$(t,e){let r=VC(Object.getPrototypeOf(e));return new r(t,e)}s(I$,"wrapEvent");function k$(t){return Qr(t).immediateStopped}s(k$,"isStopped");function T$(t,e){Qr(t).eventPhase=e}s(T$,"setEventPhase");function M$(t,e){Qr(t).currentTarget=e}s(M$,"setCurrentTarget");function qC(t,e){Qr(t).passiveListener=e}s(qC,"setPassiveListener");var WC=new WeakMap,HC=1,zC=2,vg=3;function yg(t){return t!==null&&typeof t=="object"}s(yg,"isObject");function E0(t){let e=WC.get(t);if(e==null)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return e}s(E0,"getListeners");function R$(t){return{get(){let r=E0(this).get(t);for(;r!=null;){if(r.listenerType===vg)return r.listener;r=r.next}return null},set(e){typeof e!="function"&&!yg(e)&&(e=null);let r=E0(this),n=null,i=r.get(t);for(;i!=null;)i.listenerType===vg?n!==null?n.next=i.next:i.next!==null?r.set(t,i.next):r.delete(t):n=i,i=i.next;if(e!==null){let o={listener:e,listenerType:vg,passive:!1,once:!1,next:null};n===null?r.set(t,o):n.next=o}},configurable:!0,enumerable:!0}}s(R$,"defineEventAttributeDescriptor");function r3(t,e){Object.defineProperty(t,`on${e}`,R$(e))}s(r3,"defineEventAttribute");function $C(t){function e(){Co.call(this)}s(e,"CustomEventTarget"),e.prototype=Object.create(Co.prototype,{constructor:{value:e,configurable:!0,writable:!0}});for(let r=0;r<t.length;++r)r3(e.prototype,t[r]);return e}s($C,"defineCustomEventTarget");function Co(){if(this instanceof Co){WC.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return $C(arguments[0]);if(arguments.length>0){let t=new Array(arguments.length);for(let e=0;e<arguments.length;++e)t[e]=arguments[e];return $C(t)}throw new TypeError("Cannot call a class as a function")}s(Co,"EventTarget");Co.prototype={addEventListener(t,e,r){if(e==null)return;if(typeof e!="function"&&!yg(e))throw new TypeError("'listener' should be a function or an object.");let n=E0(this),i=yg(r),a=Boolean(i?r.capture:r)?HC:zC,f={listener:e,listenerType:a,passive:i&&Boolean(r.passive),once:i&&Boolean(r.once),next:null},l=n.get(t);if(l===void 0){n.set(t,f);return}let u=null;for(;l!=null;){if(l.listener===e&&l.listenerType===a)return;u=l,l=l.next}u.next=f},removeEventListener(t,e,r){if(e==null)return;let n=E0(this),o=(yg(r)?Boolean(r.capture):Boolean(r))?HC:zC,a=null,f=n.get(t);for(;f!=null;){if(f.listener===e&&f.listenerType===o){a!==null?a.next=f.next:f.next!==null?n.set(t,f.next):n.delete(t);return}a=f,f=f.next}},dispatchEvent(t){if(t==null||typeof t.type!="string")throw new TypeError('"event.type" should be a string.');let e=E0(this),r=t.type,n=e.get(r);if(n==null)return!0;let i=I$(this,t),o=null;for(;n!=null;){if(n.once?o!==null?o.next=n.next:n.next!==null?e.set(r,n.next):e.delete(r):o=n,qC(i,n.passive?n.listener:null),typeof n.listener=="function")try{n.listener.call(this,i)}catch(a){typeof console<"u"&&typeof console.error=="function"&&console.error(a)}else n.listenerType!==vg&&typeof n.listener.handleEvent=="function"&&n.listener.handleEvent(i);if(k$(i))break;n=n.next}return qC(i,null),T$(i,0),M$(i,null),!i.defaultPrevented}};Object.defineProperty(Co.prototype,"constructor",{value:Co,configurable:!0,writable:!0});typeof window<"u"&&typeof window.EventTarget<"u"&&Object.setPrototypeOf(Co.prototype,window.EventTarget.prototype);S0.defineEventAttribute=r3;S0.EventTarget=Co;S0.default=Co;C0.exports=Co;C0.exports.EventTarget=C0.exports.default=Co;C0.exports.defineEventAttribute=r3});var XC=an((k0,I0)=>{"use strict";Object.defineProperty(k0,"__esModule",{value:!0});var n3=JC(),uc=class extends n3.EventTarget{constructor(){throw super(),new TypeError("AbortSignal cannot be constructed directly")}get aborted(){let e=xg.get(this);if(typeof e!="boolean")throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return e}};s(uc,"AbortSignal");n3.defineEventAttribute(uc.prototype,"abort");function B$(){let t=Object.create(uc.prototype);return n3.EventTarget.call(t),xg.set(t,!1),t}s(B$,"createAbortSignal");function D$(t){xg.get(t)===!1&&(xg.set(t,!0),t.dispatchEvent({type:"abort"}))}s(D$,"abortSignal");var xg=new WeakMap;Object.defineProperties(uc.prototype,{aborted:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(uc.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});var dc=class{constructor(){ZC.set(this,B$())}get signal(){return YC(this)}abort(){D$(YC(this))}};s(dc,"AbortController");var ZC=new WeakMap;function YC(t){let e=ZC.get(t);if(e==null)throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${t===null?"null":typeof t}`);return e}s(YC,"getSignal");Object.defineProperties(dc.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(dc.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});k0.AbortController=dc;k0.AbortSignal=uc;k0.default=dc;I0.exports=dc;I0.exports.AbortController=I0.exports.default=dc;I0.exports.AbortSignal=uc});var tS=an((hc,eS)=>{var QC=typeof self<"u"?self:hc,wg=function(){function t(){this.fetch=!1,this.DOMException=QC.DOMException}return s(t,"F"),t.prototype=QC,new t}();(function(t){var e=function(r){var n={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function i(re){return re&&DataView.prototype.isPrototypeOf(re)}if(s(i,"isDataView"),n.arrayBuffer)var o=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(re){return re&&o.indexOf(Object.prototype.toString.call(re))>-1};function f(re){if(typeof re!="string"&&(re=String(re)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(re))throw new TypeError("Invalid character in header field name");return re.toLowerCase()}s(f,"normalizeName");function l(re){return typeof re!="string"&&(re=String(re)),re}s(l,"normalizeValue");function u(re){var ae={next:function(){var J=re.shift();return{done:J===void 0,value:J}}};return n.iterable&&(ae[Symbol.iterator]=function(){return ae}),ae}s(u,"iteratorFor");function h(re){this.map={},re instanceof h?re.forEach(function(ae,J){this.append(J,ae)},this):Array.isArray(re)?re.forEach(function(ae){this.append(ae[0],ae[1])},this):re&&Object.getOwnPropertyNames(re).forEach(function(ae){this.append(ae,re[ae])},this)}s(h,"Headers"),h.prototype.append=function(re,ae){re=f(re),ae=l(ae);var J=this.map[re];this.map[re]=J?J+", "+ae:ae},h.prototype.delete=function(re){delete this.map[f(re)]},h.prototype.get=function(re){return re=f(re),this.has(re)?this.map[re]:null},h.prototype.has=function(re){return this.map.hasOwnProperty(f(re))},h.prototype.set=function(re,ae){this.map[f(re)]=l(ae)},h.prototype.forEach=function(re,ae){for(var J in this.map)this.map.hasOwnProperty(J)&&re.call(ae,this.map[J],J,this)},h.prototype.keys=function(){var re=[];return this.forEach(function(ae,J){re.push(J)}),u(re)},h.prototype.values=function(){var re=[];return this.forEach(function(ae){re.push(ae)}),u(re)},h.prototype.entries=function(){var re=[];return this.forEach(function(ae,J){re.push([J,ae])}),u(re)},n.iterable&&(h.prototype[Symbol.iterator]=h.prototype.entries);function g(re){if(re.bodyUsed)return Promise.reject(new TypeError("Already read"));re.bodyUsed=!0}s(g,"consumed");function x(re){return new Promise(function(ae,J){re.onload=function(){ae(re.result)},re.onerror=function(){J(re.error)}})}s(x,"fileReaderReady");function _(re){var ae=new FileReader,J=x(ae);return ae.readAsArrayBuffer(re),J}s(_,"readBlobAsArrayBuffer");function E(re){var ae=new FileReader,J=x(ae);return ae.readAsText(re),J}s(E,"readBlobAsText");function T(re){for(var ae=new Uint8Array(re),J=new Array(ae.length),S=0;S<ae.length;S++)J[S]=String.fromCharCode(ae[S]);return J.join("")}s(T,"readArrayBufferAsText");function B(re){if(re.slice)return re.slice(0);var ae=new Uint8Array(re.byteLength);return ae.set(new Uint8Array(re)),ae.buffer}s(B,"bufferClone");function F(){return this.bodyUsed=!1,this._initBody=function(re){this._bodyInit=re,re?typeof re=="string"?this._bodyText=re:n.blob&&Blob.prototype.isPrototypeOf(re)?this._bodyBlob=re:n.formData&&FormData.prototype.isPrototypeOf(re)?this._bodyFormData=re:n.searchParams&&URLSearchParams.prototype.isPrototypeOf(re)?this._bodyText=re.toString():n.arrayBuffer&&n.blob&&i(re)?(this._bodyArrayBuffer=B(re.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):n.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(re)||a(re))?this._bodyArrayBuffer=B(re):this._bodyText=re=Object.prototype.toString.call(re):this._bodyText="",this.headers.get("content-type")||(typeof re=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):n.searchParams&&URLSearchParams.prototype.isPrototypeOf(re)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},n.blob&&(this.blob=function(){var re=g(this);if(re)return re;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?g(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(_)}),this.text=function(){var re=g(this);if(re)return re;if(this._bodyBlob)return E(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(T(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},n.formData&&(this.formData=function(){return this.text().then(K)}),this.json=function(){return this.text().then(JSON.parse)},this}s(F,"Body");var H=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function U(re){var ae=re.toUpperCase();return H.indexOf(ae)>-1?ae:re}s(U,"normalizeMethod");function q(re,ae){ae=ae||{};var J=ae.body;if(re instanceof q){if(re.bodyUsed)throw new TypeError("Already read");this.url=re.url,this.credentials=re.credentials,ae.headers||(this.headers=new h(re.headers)),this.method=re.method,this.mode=re.mode,this.signal=re.signal,!J&&re._bodyInit!=null&&(J=re._bodyInit,re.bodyUsed=!0)}else this.url=String(re);if(this.credentials=ae.credentials||this.credentials||"same-origin",(ae.headers||!this.headers)&&(this.headers=new h(ae.headers)),this.method=U(ae.method||this.method||"GET"),this.mode=ae.mode||this.mode||null,this.signal=ae.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&J)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(J)}s(q,"Request"),q.prototype.clone=function(){return new q(this,{body:this._bodyInit})};function K(re){var ae=new FormData;return re.trim().split("&").forEach(function(J){if(J){var S=J.split("="),m=S.shift().replace(/\+/g," "),b=S.join("=").replace(/\+/g," ");ae.append(decodeURIComponent(m),decodeURIComponent(b))}}),ae}s(K,"decode");function W(re){var ae=new h,J=re.replace(/\r?\n[\t ]+/g," ");return J.split(/\r?\n/).forEach(function(S){var m=S.split(":"),b=m.shift().trim();if(b){var p=m.join(":").trim();ae.append(b,p)}}),ae}s(W,"parseHeaders"),F.call(q.prototype);function N(re,ae){ae||(ae={}),this.type="default",this.status=ae.status===void 0?200:ae.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in ae?ae.statusText:"OK",this.headers=new h(ae.headers),this.url=ae.url||"",this._initBody(re)}s(N,"Response"),F.call(N.prototype),N.prototype.clone=function(){return new N(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},N.error=function(){var re=new N(null,{status:0,statusText:""});return re.type="error",re};var G=[301,302,303,307,308];N.redirect=function(re,ae){if(G.indexOf(ae)===-1)throw new RangeError("Invalid status code");return new N(null,{status:ae,headers:{location:re}})},r.DOMException=t.DOMException;try{new r.DOMException}catch{r.DOMException=function(ae,J){this.message=ae,this.name=J;var S=Error(ae);this.stack=S.stack},r.DOMException.prototype=Object.create(Error.prototype),r.DOMException.prototype.constructor=r.DOMException}function ce(re,ae){return new Promise(function(J,S){var m=new q(re,ae);if(m.signal&&m.signal.aborted)return S(new r.DOMException("Aborted","AbortError"));var b=new XMLHttpRequest;function p(){b.abort()}s(p,"abortXhr"),b.onload=function(){var v={status:b.status,statusText:b.statusText,headers:W(b.getAllResponseHeaders()||"")};v.url="responseURL"in b?b.responseURL:v.headers.get("X-Request-URL");var C="response"in b?b.response:b.responseText;J(new N(C,v))},b.onerror=function(){S(new TypeError("Network request failed"))},b.ontimeout=function(){S(new TypeError("Network request failed"))},b.onabort=function(){S(new r.DOMException("Aborted","AbortError"))},b.open(m.method,m.url,!0),m.credentials==="include"?b.withCredentials=!0:m.credentials==="omit"&&(b.withCredentials=!1),"responseType"in b&&n.blob&&(b.responseType="blob"),m.headers.forEach(function(v,C){b.setRequestHeader(C,v)}),m.signal&&(m.signal.addEventListener("abort",p),b.onreadystatechange=function(){b.readyState===4&&m.signal.removeEventListener("abort",p)}),b.send(typeof m._bodyInit>"u"?null:m._bodyInit)})}return s(ce,"fetch"),ce.polyfill=!0,t.fetch||(t.fetch=ce,t.Headers=h,t.Request=q,t.Response=N),r.Headers=h,r.Request=q,r.Response=N,r.fetch=ce,Object.defineProperty(r,"__esModule",{value:!0}),r}({})})(wg);wg.fetch.ponyfill=!0;delete wg.fetch.polyfill;var ju=wg;hc=ju.fetch;hc.default=ju.fetch;hc.fetch=ju.fetch;hc.Headers=ju.Headers;hc.Request=ju.Request;hc.Response=ju.Response;eS.exports=hc});var rS=an(()=>{});var s3=an((nS,i3)=>{(function(t,e){"use strict";function r(S,m){if(!S)throw new Error(m||"Assertion failed")}s(r,"assert");function n(S,m){S.super_=m;var b=s(function(){},"TempCtor");b.prototype=m.prototype,S.prototype=new b,S.prototype.constructor=S}s(n,"inherits");function i(S,m,b){if(i.isBN(S))return S;this.negative=0,this.words=null,this.length=0,this.red=null,S!==null&&((m==="le"||m==="be")&&(b=m,m=10),this._init(S||0,m||10,b||"be"))}s(i,"BN"),typeof t=="object"?t.exports=i:e.BN=i,i.BN=i,i.wordSize=26;var o;try{typeof window<"u"&&typeof window.Buffer<"u"?o=window.Buffer:o=rS().Buffer}catch{}i.isBN=s(function(m){return m instanceof i?!0:m!==null&&typeof m=="object"&&m.constructor.wordSize===i.wordSize&&Array.isArray(m.words)},"isBN"),i.max=s(function(m,b){return m.cmp(b)>0?m:b},"max"),i.min=s(function(m,b){return m.cmp(b)<0?m:b},"min"),i.prototype._init=s(function(m,b,p){if(typeof m=="number")return this._initNumber(m,b,p);if(typeof m=="object")return this._initArray(m,b,p);b==="hex"&&(b=16),r(b===(b|0)&&b>=2&&b<=36),m=m.toString().replace(/\s+/g,"");var v=0;m[0]==="-"&&(v++,this.negative=1),v<m.length&&(b===16?this._parseHex(m,v,p):(this._parseBase(m,b,v),p==="le"&&this._initArray(this.toArray(),b,p)))},"init"),i.prototype._initNumber=s(function(m,b,p){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):(r(m<9007199254740992),this.words=[m&67108863,m/67108864&67108863,1],this.length=3),p==="le"&&this._initArray(this.toArray(),b,p)},"_initNumber"),i.prototype._initArray=s(function(m,b,p){if(r(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 v=0;v<this.length;v++)this.words[v]=0;var C,I,k=0;if(p==="be")for(v=m.length-1,C=0;v>=0;v-=3)I=m[v]|m[v-1]<<8|m[v-2]<<16,this.words[C]|=I<<k&67108863,this.words[C+1]=I>>>26-k&67108863,k+=24,k>=26&&(k-=26,C++);else if(p==="le")for(v=0,C=0;v<m.length;v+=3)I=m[v]|m[v+1]<<8|m[v+2]<<16,this.words[C]|=I<<k&67108863,this.words[C+1]=I>>>26-k&67108863,k+=24,k>=26&&(k-=26,C++);return this._strip()},"_initArray");function a(S,m){var b=S.charCodeAt(m);if(b>=48&&b<=57)return b-48;if(b>=65&&b<=70)return b-55;if(b>=97&&b<=102)return b-87;r(!1,"Invalid character in "+S)}s(a,"parseHex4Bits");function f(S,m,b){var p=a(S,b);return b-1>=m&&(p|=a(S,b-1)<<4),p}s(f,"parseHexByte"),i.prototype._parseHex=s(function(m,b,p){this.length=Math.ceil((m.length-b)/6),this.words=new Array(this.length);for(var v=0;v<this.length;v++)this.words[v]=0;var C=0,I=0,k;if(p==="be")for(v=m.length-1;v>=b;v-=2)k=f(m,b,v)<<C,this.words[I]|=k&67108863,C>=18?(C-=18,I+=1,this.words[I]|=k>>>26):C+=8;else{var w=m.length-b;for(v=w%2===0?b+1:b;v<m.length;v+=2)k=f(m,b,v)<<C,this.words[I]|=k&67108863,C>=18?(C-=18,I+=1,this.words[I]|=k>>>26):C+=8}this._strip()},"_parseHex");function l(S,m,b,p){for(var v=0,C=0,I=Math.min(S.length,b),k=m;k<I;k++){var w=S.charCodeAt(k)-48;v*=p,w>=49?C=w-49+10:w>=17?C=w-17+10:C=w,r(w>=0&&C<p,"Invalid character"),v+=C}return v}s(l,"parseBase"),i.prototype._parseBase=s(function(m,b,p){this.words=[0],this.length=1;for(var v=0,C=1;C<=67108863;C*=b)v++;v--,C=C/b|0;for(var I=m.length-p,k=I%v,w=Math.min(I,I-k)+p,A=0,R=p;R<w;R+=v)A=l(m,R,R+v,b),this.imuln(C),this.words[0]+A<67108864?this.words[0]+=A:this._iaddn(A);if(k!==0){var D=1;for(A=l(m,R,m.length,b),R=0;R<k;R++)D*=b;this.imuln(D),this.words[0]+A<67108864?this.words[0]+=A:this._iaddn(A)}this._strip()},"_parseBase"),i.prototype.copy=s(function(m){m.words=new Array(this.length);for(var b=0;b<this.length;b++)m.words[b]=this.words[b];m.length=this.length,m.negative=this.negative,m.red=this.red},"copy");function u(S,m){S.words=m.words,S.length=m.length,S.negative=m.negative,S.red=m.red}if(s(u,"move"),i.prototype._move=s(function(m){u(m,this)},"_move"),i.prototype.clone=s(function(){var m=new i(null);return this.copy(m),m},"clone"),i.prototype._expand=s(function(m){for(;this.length<m;)this.words[this.length++]=0;return this},"_expand"),i.prototype._strip=s(function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},"strip"),i.prototype._normSign=s(function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},"_normSign"),typeof Symbol<"u"&&typeof Symbol.for=="function")try{i.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch{i.prototype.inspect=h}else i.prototype.inspect=h;function h(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}s(h,"inspect");var g=["","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"],x=[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],_=[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];i.prototype.toString=s(function(m,b){m=m||10,b=b|0||1;var p;if(m===16||m==="hex"){p="";for(var v=0,C=0,I=0;I<this.length;I++){var k=this.words[I],w=((k<<v|C)&16777215).toString(16);C=k>>>24-v&16777215,v+=2,v>=26&&(v-=26,I--),C!==0||I!==this.length-1?p=g[6-w.length]+w+p:p=w+p}for(C!==0&&(p=C.toString(16)+p);p.length%b!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}if(m===(m|0)&&m>=2&&m<=36){var A=x[m],R=_[m];p="";var D=this.clone();for(D.negative=0;!D.isZero();){var M=D.modrn(R).toString(m);D=D.idivn(R),D.isZero()?p=M+p:p=g[A-M.length]+M+p}for(this.isZero()&&(p="0"+p);p.length%b!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}r(!1,"Base should be between 2 and 36")},"toString"),i.prototype.toNumber=s(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&&r(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-m:m},"toNumber"),i.prototype.toJSON=s(function(){return this.toString(16,2)},"toJSON"),o&&(i.prototype.toBuffer=s(function(m,b){return this.toArrayLike(o,m,b)},"toBuffer")),i.prototype.toArray=s(function(m,b){return this.toArrayLike(Array,m,b)},"toArray");var E=s(function(m,b){return m.allocUnsafe?m.allocUnsafe(b):new m(b)},"allocate");i.prototype.toArrayLike=s(function(m,b,p){this._strip();var v=this.byteLength(),C=p||Math.max(1,v);r(v<=C,"byte array longer than desired length"),r(C>0,"Requested array length <= 0");var I=E(m,C),k=b==="le"?"LE":"BE";return this["_toArrayLike"+k](I,v),I},"toArrayLike"),i.prototype._toArrayLikeLE=s(function(m,b){for(var p=0,v=0,C=0,I=0;C<this.length;C++){var k=this.words[C]<<I|v;m[p++]=k&255,p<m.length&&(m[p++]=k>>8&255),p<m.length&&(m[p++]=k>>16&255),I===6?(p<m.length&&(m[p++]=k>>24&255),v=0,I=0):(v=k>>>24,I+=2)}if(p<m.length)for(m[p++]=v;p<m.length;)m[p++]=0},"_toArrayLikeLE"),i.prototype._toArrayLikeBE=s(function(m,b){for(var p=m.length-1,v=0,C=0,I=0;C<this.length;C++){var k=this.words[C]<<I|v;m[p--]=k&255,p>=0&&(m[p--]=k>>8&255),p>=0&&(m[p--]=k>>16&255),I===6?(p>=0&&(m[p--]=k>>24&255),v=0,I=0):(v=k>>>24,I+=2)}if(p>=0)for(m[p--]=v;p>=0;)m[p--]=0},"_toArrayLikeBE"),Math.clz32?i.prototype._countBits=s(function(m){return 32-Math.clz32(m)},"_countBits"):i.prototype._countBits=s(function(m){var b=m,p=0;return b>=4096&&(p+=13,b>>>=13),b>=64&&(p+=7,b>>>=7),b>=8&&(p+=4,b>>>=4),b>=2&&(p+=2,b>>>=2),p+b},"_countBits"),i.prototype._zeroBits=s(function(m){if(m===0)return 26;var b=m,p=0;return(b&8191)===0&&(p+=13,b>>>=13),(b&127)===0&&(p+=7,b>>>=7),(b&15)===0&&(p+=4,b>>>=4),(b&3)===0&&(p+=2,b>>>=2),(b&1)===0&&p++,p},"_zeroBits"),i.prototype.bitLength=s(function(){var m=this.words[this.length-1],b=this._countBits(m);return(this.length-1)*26+b},"bitLength");function T(S){for(var m=new Array(S.bitLength()),b=0;b<m.length;b++){var p=b/26|0,v=b%26;m[b]=S.words[p]>>>v&1}return m}s(T,"toBitArray"),i.prototype.zeroBits=s(function(){if(this.isZero())return 0;for(var m=0,b=0;b<this.length;b++){var p=this._zeroBits(this.words[b]);if(m+=p,p!==26)break}return m},"zeroBits"),i.prototype.byteLength=s(function(){return Math.ceil(this.bitLength()/8)},"byteLength"),i.prototype.toTwos=s(function(m){return this.negative!==0?this.abs().inotn(m).iaddn(1):this.clone()},"toTwos"),i.prototype.fromTwos=s(function(m){return this.testn(m-1)?this.notn(m).iaddn(1).ineg():this.clone()},"fromTwos"),i.prototype.isNeg=s(function(){return this.negative!==0},"isNeg"),i.prototype.neg=s(function(){return this.clone().ineg()},"neg"),i.prototype.ineg=s(function(){return this.isZero()||(this.negative^=1),this},"ineg"),i.prototype.iuor=s(function(m){for(;this.length<m.length;)this.words[this.length++]=0;for(var b=0;b<m.length;b++)this.words[b]=this.words[b]|m.words[b];return this._strip()},"iuor"),i.prototype.ior=s(function(m){return r((this.negative|m.negative)===0),this.iuor(m)},"ior"),i.prototype.or=s(function(m){return this.length>m.length?this.clone().ior(m):m.clone().ior(this)},"or"),i.prototype.uor=s(function(m){return this.length>m.length?this.clone().iuor(m):m.clone().iuor(this)},"uor"),i.prototype.iuand=s(function(m){var b;this.length>m.length?b=m:b=this;for(var p=0;p<b.length;p++)this.words[p]=this.words[p]&m.words[p];return this.length=b.length,this._strip()},"iuand"),i.prototype.iand=s(function(m){return r((this.negative|m.negative)===0),this.iuand(m)},"iand"),i.prototype.and=s(function(m){return this.length>m.length?this.clone().iand(m):m.clone().iand(this)},"and"),i.prototype.uand=s(function(m){return this.length>m.length?this.clone().iuand(m):m.clone().iuand(this)},"uand"),i.prototype.iuxor=s(function(m){var b,p;this.length>m.length?(b=this,p=m):(b=m,p=this);for(var v=0;v<p.length;v++)this.words[v]=b.words[v]^p.words[v];if(this!==b)for(;v<b.length;v++)this.words[v]=b.words[v];return this.length=b.length,this._strip()},"iuxor"),i.prototype.ixor=s(function(m){return r((this.negative|m.negative)===0),this.iuxor(m)},"ixor"),i.prototype.xor=s(function(m){return this.length>m.length?this.clone().ixor(m):m.clone().ixor(this)},"xor"),i.prototype.uxor=s(function(m){return this.length>m.length?this.clone().iuxor(m):m.clone().iuxor(this)},"uxor"),i.prototype.inotn=s(function(m){r(typeof m=="number"&&m>=0);var b=Math.ceil(m/26)|0,p=m%26;this._expand(b),p>0&&b--;for(var v=0;v<b;v++)this.words[v]=~this.words[v]&67108863;return p>0&&(this.words[v]=~this.words[v]&67108863>>26-p),this._strip()},"inotn"),i.prototype.notn=s(function(m){return this.clone().inotn(m)},"notn"),i.prototype.setn=s(function(m,b){r(typeof m=="number"&&m>=0);var p=m/26|0,v=m%26;return this._expand(p+1),b?this.words[p]=this.words[p]|1<<v:this.words[p]=this.words[p]&~(1<<v),this._strip()},"setn"),i.prototype.iadd=s(function(m){var b;if(this.negative!==0&&m.negative===0)return this.negative=0,b=this.isub(m),this.negative^=1,this._normSign();if(this.negative===0&&m.negative!==0)return m.negative=0,b=this.isub(m),m.negative=1,b._normSign();var p,v;this.length>m.length?(p=this,v=m):(p=m,v=this);for(var C=0,I=0;I<v.length;I++)b=(p.words[I]|0)+(v.words[I]|0)+C,this.words[I]=b&67108863,C=b>>>26;for(;C!==0&&I<p.length;I++)b=(p.words[I]|0)+C,this.words[I]=b&67108863,C=b>>>26;if(this.length=p.length,C!==0)this.words[this.length]=C,this.length++;else if(p!==this)for(;I<p.length;I++)this.words[I]=p.words[I];return this},"iadd"),i.prototype.add=s(function(m){var b;return m.negative!==0&&this.negative===0?(m.negative=0,b=this.sub(m),m.negative^=1,b):m.negative===0&&this.negative!==0?(this.negative=0,b=m.sub(this),this.negative=1,b):this.length>m.length?this.clone().iadd(m):m.clone().iadd(this)},"add"),i.prototype.isub=s(function(m){if(m.negative!==0){m.negative=0;var b=this.iadd(m);return m.negative=1,b._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(m),this.negative=1,this._normSign();var p=this.cmp(m);if(p===0)return this.negative=0,this.length=1,this.words[0]=0,this;var v,C;p>0?(v=this,C=m):(v=m,C=this);for(var I=0,k=0;k<C.length;k++)b=(v.words[k]|0)-(C.words[k]|0)+I,I=b>>26,this.words[k]=b&67108863;for(;I!==0&&k<v.length;k++)b=(v.words[k]|0)+I,I=b>>26,this.words[k]=b&67108863;if(I===0&&k<v.length&&v!==this)for(;k<v.length;k++)this.words[k]=v.words[k];return this.length=Math.max(this.length,k),v!==this&&(this.negative=1),this._strip()},"isub"),i.prototype.sub=s(function(m){return this.clone().isub(m)},"sub");function B(S,m,b){b.negative=m.negative^S.negative;var p=S.length+m.length|0;b.length=p,p=p-1|0;var v=S.words[0]|0,C=m.words[0]|0,I=v*C,k=I&67108863,w=I/67108864|0;b.words[0]=k;for(var A=1;A<p;A++){for(var R=w>>>26,D=w&67108863,M=Math.min(A,m.length-1),te=Math.max(0,A-S.length+1);te<=M;te++){var L=A-te|0;v=S.words[L]|0,C=m.words[te]|0,I=v*C+D,R+=I/67108864|0,D=I&67108863}b.words[A]=D|0,w=R|0}return w!==0?b.words[A]=w|0:b.length--,b._strip()}s(B,"smallMulTo");var F=s(function(m,b,p){var v=m.words,C=b.words,I=p.words,k=0,w,A,R,D=v[0]|0,M=D&8191,te=D>>>13,L=v[1]|0,Y=L&8191,Z=L>>>13,P=v[2]|0,z=P&8191,oe=P>>>13,ue=v[3]|0,me=ue&8191,ke=ue>>>13,Q=v[4]|0,j=Q&8191,$=Q>>>13,X=v[5]|0,se=X&8191,ee=X>>>13,le=v[6]|0,be=le&8191,Se=le>>>13,Te=v[7]|0,De=Te&8191,Ne=Te>>>13,ye=v[8]|0,pe=ye&8191,ne=ye>>>13,he=v[9]|0,Ee=he&8191,Ie=he>>>13,Re=C[0]|0,Oe=Re&8191,bt=Re>>>13,Qe=C[1]|0,qe=Qe&8191,vt=Qe>>>13,gt=C[2]|0,tt=gt&8191,Ut=gt>>>13,ht=C[3]|0,et=ht&8191,Dt=ht>>>13,pt=C[4]|0,Xe=pt&8191,Mt=pt>>>13,ft=C[5]|0,Ye=ft&8191,It=ft>>>13,lt=C[6]|0,Ze=lt&8191,Rt=lt>>>13,ut=C[7]|0,Je=ut&8191,Bt=ut>>>13,dt=C[8]|0,at=dt&8191,tr=dt>>>13,Tt=C[9]|0,rt=Tt&8191,Yt=Tt>>>13;p.negative=m.negative^b.negative,p.length=19,w=Math.imul(M,Oe),A=Math.imul(M,bt),A=A+Math.imul(te,Oe)|0,R=Math.imul(te,bt);var Kt=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Kt>>>26)|0,Kt&=67108863,w=Math.imul(Y,Oe),A=Math.imul(Y,bt),A=A+Math.imul(Z,Oe)|0,R=Math.imul(Z,bt),w=w+Math.imul(M,qe)|0,A=A+Math.imul(M,vt)|0,A=A+Math.imul(te,qe)|0,R=R+Math.imul(te,vt)|0;var Vt=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,w=Math.imul(z,Oe),A=Math.imul(z,bt),A=A+Math.imul(oe,Oe)|0,R=Math.imul(oe,bt),w=w+Math.imul(Y,qe)|0,A=A+Math.imul(Y,vt)|0,A=A+Math.imul(Z,qe)|0,R=R+Math.imul(Z,vt)|0,w=w+Math.imul(M,tt)|0,A=A+Math.imul(M,Ut)|0,A=A+Math.imul(te,tt)|0,R=R+Math.imul(te,Ut)|0;var Vr=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Vr>>>26)|0,Vr&=67108863,w=Math.imul(me,Oe),A=Math.imul(me,bt),A=A+Math.imul(ke,Oe)|0,R=Math.imul(ke,bt),w=w+Math.imul(z,qe)|0,A=A+Math.imul(z,vt)|0,A=A+Math.imul(oe,qe)|0,R=R+Math.imul(oe,vt)|0,w=w+Math.imul(Y,tt)|0,A=A+Math.imul(Y,Ut)|0,A=A+Math.imul(Z,tt)|0,R=R+Math.imul(Z,Ut)|0,w=w+Math.imul(M,et)|0,A=A+Math.imul(M,Dt)|0,A=A+Math.imul(te,et)|0,R=R+Math.imul(te,Dt)|0;var Wr=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Wr>>>26)|0,Wr&=67108863,w=Math.imul(j,Oe),A=Math.imul(j,bt),A=A+Math.imul($,Oe)|0,R=Math.imul($,bt),w=w+Math.imul(me,qe)|0,A=A+Math.imul(me,vt)|0,A=A+Math.imul(ke,qe)|0,R=R+Math.imul(ke,vt)|0,w=w+Math.imul(z,tt)|0,A=A+Math.imul(z,Ut)|0,A=A+Math.imul(oe,tt)|0,R=R+Math.imul(oe,Ut)|0,w=w+Math.imul(Y,et)|0,A=A+Math.imul(Y,Dt)|0,A=A+Math.imul(Z,et)|0,R=R+Math.imul(Z,Dt)|0,w=w+Math.imul(M,Xe)|0,A=A+Math.imul(M,Mt)|0,A=A+Math.imul(te,Xe)|0,R=R+Math.imul(te,Mt)|0;var Ir=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Ir>>>26)|0,Ir&=67108863,w=Math.imul(se,Oe),A=Math.imul(se,bt),A=A+Math.imul(ee,Oe)|0,R=Math.imul(ee,bt),w=w+Math.imul(j,qe)|0,A=A+Math.imul(j,vt)|0,A=A+Math.imul($,qe)|0,R=R+Math.imul($,vt)|0,w=w+Math.imul(me,tt)|0,A=A+Math.imul(me,Ut)|0,A=A+Math.imul(ke,tt)|0,R=R+Math.imul(ke,Ut)|0,w=w+Math.imul(z,et)|0,A=A+Math.imul(z,Dt)|0,A=A+Math.imul(oe,et)|0,R=R+Math.imul(oe,Dt)|0,w=w+Math.imul(Y,Xe)|0,A=A+Math.imul(Y,Mt)|0,A=A+Math.imul(Z,Xe)|0,R=R+Math.imul(Z,Mt)|0,w=w+Math.imul(M,Ye)|0,A=A+Math.imul(M,It)|0,A=A+Math.imul(te,Ye)|0,R=R+Math.imul(te,It)|0;var tn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(tn>>>26)|0,tn&=67108863,w=Math.imul(be,Oe),A=Math.imul(be,bt),A=A+Math.imul(Se,Oe)|0,R=Math.imul(Se,bt),w=w+Math.imul(se,qe)|0,A=A+Math.imul(se,vt)|0,A=A+Math.imul(ee,qe)|0,R=R+Math.imul(ee,vt)|0,w=w+Math.imul(j,tt)|0,A=A+Math.imul(j,Ut)|0,A=A+Math.imul($,tt)|0,R=R+Math.imul($,Ut)|0,w=w+Math.imul(me,et)|0,A=A+Math.imul(me,Dt)|0,A=A+Math.imul(ke,et)|0,R=R+Math.imul(ke,Dt)|0,w=w+Math.imul(z,Xe)|0,A=A+Math.imul(z,Mt)|0,A=A+Math.imul(oe,Xe)|0,R=R+Math.imul(oe,Mt)|0,w=w+Math.imul(Y,Ye)|0,A=A+Math.imul(Y,It)|0,A=A+Math.imul(Z,Ye)|0,R=R+Math.imul(Z,It)|0,w=w+Math.imul(M,Ze)|0,A=A+Math.imul(M,Rt)|0,A=A+Math.imul(te,Ze)|0,R=R+Math.imul(te,Rt)|0;var xn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(xn>>>26)|0,xn&=67108863,w=Math.imul(De,Oe),A=Math.imul(De,bt),A=A+Math.imul(Ne,Oe)|0,R=Math.imul(Ne,bt),w=w+Math.imul(be,qe)|0,A=A+Math.imul(be,vt)|0,A=A+Math.imul(Se,qe)|0,R=R+Math.imul(Se,vt)|0,w=w+Math.imul(se,tt)|0,A=A+Math.imul(se,Ut)|0,A=A+Math.imul(ee,tt)|0,R=R+Math.imul(ee,Ut)|0,w=w+Math.imul(j,et)|0,A=A+Math.imul(j,Dt)|0,A=A+Math.imul($,et)|0,R=R+Math.imul($,Dt)|0,w=w+Math.imul(me,Xe)|0,A=A+Math.imul(me,Mt)|0,A=A+Math.imul(ke,Xe)|0,R=R+Math.imul(ke,Mt)|0,w=w+Math.imul(z,Ye)|0,A=A+Math.imul(z,It)|0,A=A+Math.imul(oe,Ye)|0,R=R+Math.imul(oe,It)|0,w=w+Math.imul(Y,Ze)|0,A=A+Math.imul(Y,Rt)|0,A=A+Math.imul(Z,Ze)|0,R=R+Math.imul(Z,Rt)|0,w=w+Math.imul(M,Je)|0,A=A+Math.imul(M,Bt)|0,A=A+Math.imul(te,Je)|0,R=R+Math.imul(te,Bt)|0;var Pn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,w=Math.imul(pe,Oe),A=Math.imul(pe,bt),A=A+Math.imul(ne,Oe)|0,R=Math.imul(ne,bt),w=w+Math.imul(De,qe)|0,A=A+Math.imul(De,vt)|0,A=A+Math.imul(Ne,qe)|0,R=R+Math.imul(Ne,vt)|0,w=w+Math.imul(be,tt)|0,A=A+Math.imul(be,Ut)|0,A=A+Math.imul(Se,tt)|0,R=R+Math.imul(Se,Ut)|0,w=w+Math.imul(se,et)|0,A=A+Math.imul(se,Dt)|0,A=A+Math.imul(ee,et)|0,R=R+Math.imul(ee,Dt)|0,w=w+Math.imul(j,Xe)|0,A=A+Math.imul(j,Mt)|0,A=A+Math.imul($,Xe)|0,R=R+Math.imul($,Mt)|0,w=w+Math.imul(me,Ye)|0,A=A+Math.imul(me,It)|0,A=A+Math.imul(ke,Ye)|0,R=R+Math.imul(ke,It)|0,w=w+Math.imul(z,Ze)|0,A=A+Math.imul(z,Rt)|0,A=A+Math.imul(oe,Ze)|0,R=R+Math.imul(oe,Rt)|0,w=w+Math.imul(Y,Je)|0,A=A+Math.imul(Y,Bt)|0,A=A+Math.imul(Z,Je)|0,R=R+Math.imul(Z,Bt)|0,w=w+Math.imul(M,at)|0,A=A+Math.imul(M,tr)|0,A=A+Math.imul(te,at)|0,R=R+Math.imul(te,tr)|0;var li=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(li>>>26)|0,li&=67108863,w=Math.imul(Ee,Oe),A=Math.imul(Ee,bt),A=A+Math.imul(Ie,Oe)|0,R=Math.imul(Ie,bt),w=w+Math.imul(pe,qe)|0,A=A+Math.imul(pe,vt)|0,A=A+Math.imul(ne,qe)|0,R=R+Math.imul(ne,vt)|0,w=w+Math.imul(De,tt)|0,A=A+Math.imul(De,Ut)|0,A=A+Math.imul(Ne,tt)|0,R=R+Math.imul(Ne,Ut)|0,w=w+Math.imul(be,et)|0,A=A+Math.imul(be,Dt)|0,A=A+Math.imul(Se,et)|0,R=R+Math.imul(Se,Dt)|0,w=w+Math.imul(se,Xe)|0,A=A+Math.imul(se,Mt)|0,A=A+Math.imul(ee,Xe)|0,R=R+Math.imul(ee,Mt)|0,w=w+Math.imul(j,Ye)|0,A=A+Math.imul(j,It)|0,A=A+Math.imul($,Ye)|0,R=R+Math.imul($,It)|0,w=w+Math.imul(me,Ze)|0,A=A+Math.imul(me,Rt)|0,A=A+Math.imul(ke,Ze)|0,R=R+Math.imul(ke,Rt)|0,w=w+Math.imul(z,Je)|0,A=A+Math.imul(z,Bt)|0,A=A+Math.imul(oe,Je)|0,R=R+Math.imul(oe,Bt)|0,w=w+Math.imul(Y,at)|0,A=A+Math.imul(Y,tr)|0,A=A+Math.imul(Z,at)|0,R=R+Math.imul(Z,tr)|0,w=w+Math.imul(M,rt)|0,A=A+Math.imul(M,Yt)|0,A=A+Math.imul(te,rt)|0,R=R+Math.imul(te,Yt)|0;var ui=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(ui>>>26)|0,ui&=67108863,w=Math.imul(Ee,qe),A=Math.imul(Ee,vt),A=A+Math.imul(Ie,qe)|0,R=Math.imul(Ie,vt),w=w+Math.imul(pe,tt)|0,A=A+Math.imul(pe,Ut)|0,A=A+Math.imul(ne,tt)|0,R=R+Math.imul(ne,Ut)|0,w=w+Math.imul(De,et)|0,A=A+Math.imul(De,Dt)|0,A=A+Math.imul(Ne,et)|0,R=R+Math.imul(Ne,Dt)|0,w=w+Math.imul(be,Xe)|0,A=A+Math.imul(be,Mt)|0,A=A+Math.imul(Se,Xe)|0,R=R+Math.imul(Se,Mt)|0,w=w+Math.imul(se,Ye)|0,A=A+Math.imul(se,It)|0,A=A+Math.imul(ee,Ye)|0,R=R+Math.imul(ee,It)|0,w=w+Math.imul(j,Ze)|0,A=A+Math.imul(j,Rt)|0,A=A+Math.imul($,Ze)|0,R=R+Math.imul($,Rt)|0,w=w+Math.imul(me,Je)|0,A=A+Math.imul(me,Bt)|0,A=A+Math.imul(ke,Je)|0,R=R+Math.imul(ke,Bt)|0,w=w+Math.imul(z,at)|0,A=A+Math.imul(z,tr)|0,A=A+Math.imul(oe,at)|0,R=R+Math.imul(oe,tr)|0,w=w+Math.imul(Y,rt)|0,A=A+Math.imul(Y,Yt)|0,A=A+Math.imul(Z,rt)|0,R=R+Math.imul(Z,Yt)|0;var di=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(di>>>26)|0,di&=67108863,w=Math.imul(Ee,tt),A=Math.imul(Ee,Ut),A=A+Math.imul(Ie,tt)|0,R=Math.imul(Ie,Ut),w=w+Math.imul(pe,et)|0,A=A+Math.imul(pe,Dt)|0,A=A+Math.imul(ne,et)|0,R=R+Math.imul(ne,Dt)|0,w=w+Math.imul(De,Xe)|0,A=A+Math.imul(De,Mt)|0,A=A+Math.imul(Ne,Xe)|0,R=R+Math.imul(Ne,Mt)|0,w=w+Math.imul(be,Ye)|0,A=A+Math.imul(be,It)|0,A=A+Math.imul(Se,Ye)|0,R=R+Math.imul(Se,It)|0,w=w+Math.imul(se,Ze)|0,A=A+Math.imul(se,Rt)|0,A=A+Math.imul(ee,Ze)|0,R=R+Math.imul(ee,Rt)|0,w=w+Math.imul(j,Je)|0,A=A+Math.imul(j,Bt)|0,A=A+Math.imul($,Je)|0,R=R+Math.imul($,Bt)|0,w=w+Math.imul(me,at)|0,A=A+Math.imul(me,tr)|0,A=A+Math.imul(ke,at)|0,R=R+Math.imul(ke,tr)|0,w=w+Math.imul(z,rt)|0,A=A+Math.imul(z,Yt)|0,A=A+Math.imul(oe,rt)|0,R=R+Math.imul(oe,Yt)|0;var Hn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Hn>>>26)|0,Hn&=67108863,w=Math.imul(Ee,et),A=Math.imul(Ee,Dt),A=A+Math.imul(Ie,et)|0,R=Math.imul(Ie,Dt),w=w+Math.imul(pe,Xe)|0,A=A+Math.imul(pe,Mt)|0,A=A+Math.imul(ne,Xe)|0,R=R+Math.imul(ne,Mt)|0,w=w+Math.imul(De,Ye)|0,A=A+Math.imul(De,It)|0,A=A+Math.imul(Ne,Ye)|0,R=R+Math.imul(Ne,It)|0,w=w+Math.imul(be,Ze)|0,A=A+Math.imul(be,Rt)|0,A=A+Math.imul(Se,Ze)|0,R=R+Math.imul(Se,Rt)|0,w=w+Math.imul(se,Je)|0,A=A+Math.imul(se,Bt)|0,A=A+Math.imul(ee,Je)|0,R=R+Math.imul(ee,Bt)|0,w=w+Math.imul(j,at)|0,A=A+Math.imul(j,tr)|0,A=A+Math.imul($,at)|0,R=R+Math.imul($,tr)|0,w=w+Math.imul(me,rt)|0,A=A+Math.imul(me,Yt)|0,A=A+Math.imul(ke,rt)|0,R=R+Math.imul(ke,Yt)|0;var kn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(kn>>>26)|0,kn&=67108863,w=Math.imul(Ee,Xe),A=Math.imul(Ee,Mt),A=A+Math.imul(Ie,Xe)|0,R=Math.imul(Ie,Mt),w=w+Math.imul(pe,Ye)|0,A=A+Math.imul(pe,It)|0,A=A+Math.imul(ne,Ye)|0,R=R+Math.imul(ne,It)|0,w=w+Math.imul(De,Ze)|0,A=A+Math.imul(De,Rt)|0,A=A+Math.imul(Ne,Ze)|0,R=R+Math.imul(Ne,Rt)|0,w=w+Math.imul(be,Je)|0,A=A+Math.imul(be,Bt)|0,A=A+Math.imul(Se,Je)|0,R=R+Math.imul(Se,Bt)|0,w=w+Math.imul(se,at)|0,A=A+Math.imul(se,tr)|0,A=A+Math.imul(ee,at)|0,R=R+Math.imul(ee,tr)|0,w=w+Math.imul(j,rt)|0,A=A+Math.imul(j,Yt)|0,A=A+Math.imul($,rt)|0,R=R+Math.imul($,Yt)|0;var Qn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Qn>>>26)|0,Qn&=67108863,w=Math.imul(Ee,Ye),A=Math.imul(Ee,It),A=A+Math.imul(Ie,Ye)|0,R=Math.imul(Ie,It),w=w+Math.imul(pe,Ze)|0,A=A+Math.imul(pe,Rt)|0,A=A+Math.imul(ne,Ze)|0,R=R+Math.imul(ne,Rt)|0,w=w+Math.imul(De,Je)|0,A=A+Math.imul(De,Bt)|0,A=A+Math.imul(Ne,Je)|0,R=R+Math.imul(Ne,Bt)|0,w=w+Math.imul(be,at)|0,A=A+Math.imul(be,tr)|0,A=A+Math.imul(Se,at)|0,R=R+Math.imul(Se,tr)|0,w=w+Math.imul(se,rt)|0,A=A+Math.imul(se,Yt)|0,A=A+Math.imul(ee,rt)|0,R=R+Math.imul(ee,Yt)|0;var zn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(zn>>>26)|0,zn&=67108863,w=Math.imul(Ee,Ze),A=Math.imul(Ee,Rt),A=A+Math.imul(Ie,Ze)|0,R=Math.imul(Ie,Rt),w=w+Math.imul(pe,Je)|0,A=A+Math.imul(pe,Bt)|0,A=A+Math.imul(ne,Je)|0,R=R+Math.imul(ne,Bt)|0,w=w+Math.imul(De,at)|0,A=A+Math.imul(De,tr)|0,A=A+Math.imul(Ne,at)|0,R=R+Math.imul(Ne,tr)|0,w=w+Math.imul(be,rt)|0,A=A+Math.imul(be,Yt)|0,A=A+Math.imul(Se,rt)|0,R=R+Math.imul(Se,Yt)|0;var hi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(hi>>>26)|0,hi&=67108863,w=Math.imul(Ee,Je),A=Math.imul(Ee,Bt),A=A+Math.imul(Ie,Je)|0,R=Math.imul(Ie,Bt),w=w+Math.imul(pe,at)|0,A=A+Math.imul(pe,tr)|0,A=A+Math.imul(ne,at)|0,R=R+Math.imul(ne,tr)|0,w=w+Math.imul(De,rt)|0,A=A+Math.imul(De,Yt)|0,A=A+Math.imul(Ne,rt)|0,R=R+Math.imul(Ne,Yt)|0;var pi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(pi>>>26)|0,pi&=67108863,w=Math.imul(Ee,at),A=Math.imul(Ee,tr),A=A+Math.imul(Ie,at)|0,R=Math.imul(Ie,tr),w=w+Math.imul(pe,rt)|0,A=A+Math.imul(pe,Yt)|0,A=A+Math.imul(ne,rt)|0,R=R+Math.imul(ne,Yt)|0;var mi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(mi>>>26)|0,mi&=67108863,w=Math.imul(Ee,rt),A=Math.imul(Ee,Yt),A=A+Math.imul(Ie,rt)|0,R=Math.imul(Ie,Yt);var ys=(k+w|0)+((A&8191)<<13)|0;return k=(R+(A>>>13)|0)+(ys>>>26)|0,ys&=67108863,I[0]=Kt,I[1]=Vt,I[2]=Vr,I[3]=Wr,I[4]=Ir,I[5]=tn,I[6]=xn,I[7]=Pn,I[8]=li,I[9]=ui,I[10]=di,I[11]=Hn,I[12]=kn,I[13]=Qn,I[14]=zn,I[15]=hi,I[16]=pi,I[17]=mi,I[18]=ys,k!==0&&(I[19]=k,p.length++),p},"comb10MulTo");Math.imul||(F=B);function H(S,m,b){b.negative=m.negative^S.negative,b.length=S.length+m.length;for(var p=0,v=0,C=0;C<b.length-1;C++){var I=v;v=0;for(var k=p&67108863,w=Math.min(C,m.length-1),A=Math.max(0,C-S.length+1);A<=w;A++){var R=C-A,D=S.words[R]|0,M=m.words[A]|0,te=D*M,L=te&67108863;I=I+(te/67108864|0)|0,L=L+k|0,k=L&67108863,I=I+(L>>>26)|0,v+=I>>>26,I&=67108863}b.words[C]=k,p=I,I=v}return p!==0?b.words[C]=p:b.length--,b._strip()}s(H,"bigMulTo");function U(S,m,b){return H(S,m,b)}s(U,"jumboMulTo"),i.prototype.mulTo=s(function(m,b){var p,v=this.length+m.length;return this.length===10&&m.length===10?p=F(this,m,b):v<63?p=B(this,m,b):v<1024?p=H(this,m,b):p=U(this,m,b),p},"mulTo");function q(S,m){this.x=S,this.y=m}s(q,"FFTM"),q.prototype.makeRBT=s(function(m){for(var b=new Array(m),p=i.prototype._countBits(m)-1,v=0;v<m;v++)b[v]=this.revBin(v,p,m);return b},"makeRBT"),q.prototype.revBin=s(function(m,b,p){if(m===0||m===p-1)return m;for(var v=0,C=0;C<b;C++)v|=(m&1)<<b-C-1,m>>=1;return v},"revBin"),q.prototype.permute=s(function(m,b,p,v,C,I){for(var k=0;k<I;k++)v[k]=b[m[k]],C[k]=p[m[k]]},"permute"),q.prototype.transform=s(function(m,b,p,v,C,I){this.permute(I,m,b,p,v,C);for(var k=1;k<C;k<<=1)for(var w=k<<1,A=Math.cos(2*Math.PI/w),R=Math.sin(2*Math.PI/w),D=0;D<C;D+=w)for(var M=A,te=R,L=0;L<k;L++){var Y=p[D+L],Z=v[D+L],P=p[D+L+k],z=v[D+L+k],oe=M*P-te*z;z=M*z+te*P,P=oe,p[D+L]=Y+P,v[D+L]=Z+z,p[D+L+k]=Y-P,v[D+L+k]=Z-z,L!==w&&(oe=A*M-R*te,te=A*te+R*M,M=oe)}},"transform"),q.prototype.guessLen13b=s(function(m,b){var p=Math.max(b,m)|1,v=p&1,C=0;for(p=p/2|0;p;p=p>>>1)C++;return 1<<C+1+v},"guessLen13b"),q.prototype.conjugate=s(function(m,b,p){if(!(p<=1))for(var v=0;v<p/2;v++){var C=m[v];m[v]=m[p-v-1],m[p-v-1]=C,C=b[v],b[v]=-b[p-v-1],b[p-v-1]=-C}},"conjugate"),q.prototype.normalize13b=s(function(m,b){for(var p=0,v=0;v<b/2;v++){var C=Math.round(m[2*v+1]/b)*8192+Math.round(m[2*v]/b)+p;m[v]=C&67108863,C<67108864?p=0:p=C/67108864|0}return m},"normalize13b"),q.prototype.convert13b=s(function(m,b,p,v){for(var C=0,I=0;I<b;I++)C=C+(m[I]|0),p[2*I]=C&8191,C=C>>>13,p[2*I+1]=C&8191,C=C>>>13;for(I=2*b;I<v;++I)p[I]=0;r(C===0),r((C&-8192)===0)},"convert13b"),q.prototype.stub=s(function(m){for(var b=new Array(m),p=0;p<m;p++)b[p]=0;return b},"stub"),q.prototype.mulp=s(function(m,b,p){var v=2*this.guessLen13b(m.length,b.length),C=this.makeRBT(v),I=this.stub(v),k=new Array(v),w=new Array(v),A=new Array(v),R=new Array(v),D=new Array(v),M=new Array(v),te=p.words;te.length=v,this.convert13b(m.words,m.length,k,v),this.convert13b(b.words,b.length,R,v),this.transform(k,I,w,A,v,C),this.transform(R,I,D,M,v,C);for(var L=0;L<v;L++){var Y=w[L]*D[L]-A[L]*M[L];A[L]=w[L]*M[L]+A[L]*D[L],w[L]=Y}return this.conjugate(w,A,v),this.transform(w,A,te,I,v,C),this.conjugate(te,I,v),this.normalize13b(te,v),p.negative=m.negative^b.negative,p.length=m.length+b.length,p._strip()},"mulp"),i.prototype.mul=s(function(m){var b=new i(null);return b.words=new Array(this.length+m.length),this.mulTo(m,b)},"mul"),i.prototype.mulf=s(function(m){var b=new i(null);return b.words=new Array(this.length+m.length),U(this,m,b)},"mulf"),i.prototype.imul=s(function(m){return this.clone().mulTo(m,this)},"imul"),i.prototype.imuln=s(function(m){var b=m<0;b&&(m=-m),r(typeof m=="number"),r(m<67108864);for(var p=0,v=0;v<this.length;v++){var C=(this.words[v]|0)*m,I=(C&67108863)+(p&67108863);p>>=26,p+=C/67108864|0,p+=I>>>26,this.words[v]=I&67108863}return p!==0&&(this.words[v]=p,this.length++),b?this.ineg():this},"imuln"),i.prototype.muln=s(function(m){return this.clone().imuln(m)},"muln"),i.prototype.sqr=s(function(){return this.mul(this)},"sqr"),i.prototype.isqr=s(function(){return this.imul(this.clone())},"isqr"),i.prototype.pow=s(function(m){var b=T(m);if(b.length===0)return new i(1);for(var p=this,v=0;v<b.length&&b[v]===0;v++,p=p.sqr());if(++v<b.length)for(var C=p.sqr();v<b.length;v++,C=C.sqr())b[v]!==0&&(p=p.mul(C));return p},"pow"),i.prototype.iushln=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26,v=67108863>>>26-b<<26-b,C;if(b!==0){var I=0;for(C=0;C<this.length;C++){var k=this.words[C]&v,w=(this.words[C]|0)-k<<b;this.words[C]=w|I,I=k>>>26-b}I&&(this.words[C]=I,this.length++)}if(p!==0){for(C=this.length-1;C>=0;C--)this.words[C+p]=this.words[C];for(C=0;C<p;C++)this.words[C]=0;this.length+=p}return this._strip()},"iushln"),i.prototype.ishln=s(function(m){return r(this.negative===0),this.iushln(m)},"ishln"),i.prototype.iushrn=s(function(m,b,p){r(typeof m=="number"&&m>=0);var v;b?v=(b-b%26)/26:v=0;var C=m%26,I=Math.min((m-C)/26,this.length),k=67108863^67108863>>>C<<C,w=p;if(v-=I,v=Math.max(0,v),w){for(var A=0;A<I;A++)w.words[A]=this.words[A];w.length=I}if(I!==0)if(this.length>I)for(this.length-=I,A=0;A<this.length;A++)this.words[A]=this.words[A+I];else this.words[0]=0,this.length=1;var R=0;for(A=this.length-1;A>=0&&(R!==0||A>=v);A--){var D=this.words[A]|0;this.words[A]=R<<26-C|D>>>C,R=D&k}return w&&R!==0&&(w.words[w.length++]=R),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},"iushrn"),i.prototype.ishrn=s(function(m,b,p){return r(this.negative===0),this.iushrn(m,b,p)},"ishrn"),i.prototype.shln=s(function(m){return this.clone().ishln(m)},"shln"),i.prototype.ushln=s(function(m){return this.clone().iushln(m)},"ushln"),i.prototype.shrn=s(function(m){return this.clone().ishrn(m)},"shrn"),i.prototype.ushrn=s(function(m){return this.clone().iushrn(m)},"ushrn"),i.prototype.testn=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26,v=1<<b;if(this.length<=p)return!1;var C=this.words[p];return!!(C&v)},"testn"),i.prototype.imaskn=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26;if(r(this.negative===0,"imaskn works only with positive numbers"),this.length<=p)return this;if(b!==0&&p++,this.length=Math.min(p,this.length),b!==0){var v=67108863^67108863>>>b<<b;this.words[this.length-1]&=v}return this._strip()},"imaskn"),i.prototype.maskn=s(function(m){return this.clone().imaskn(m)},"maskn"),i.prototype.iaddn=s(function(m){return r(typeof m=="number"),r(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)},"iaddn"),i.prototype._iaddn=s(function(m){this.words[0]+=m;for(var b=0;b<this.length&&this.words[b]>=67108864;b++)this.words[b]-=67108864,b===this.length-1?this.words[b+1]=1:this.words[b+1]++;return this.length=Math.max(this.length,b+1),this},"_iaddn"),i.prototype.isubn=s(function(m){if(r(typeof m=="number"),r(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 b=0;b<this.length&&this.words[b]<0;b++)this.words[b]+=67108864,this.words[b+1]-=1;return this._strip()},"isubn"),i.prototype.addn=s(function(m){return this.clone().iaddn(m)},"addn"),i.prototype.subn=s(function(m){return this.clone().isubn(m)},"subn"),i.prototype.iabs=s(function(){return this.negative=0,this},"iabs"),i.prototype.abs=s(function(){return this.clone().iabs()},"abs"),i.prototype._ishlnsubmul=s(function(m,b,p){var v=m.length+p,C;this._expand(v);var I,k=0;for(C=0;C<m.length;C++){I=(this.words[C+p]|0)+k;var w=(m.words[C]|0)*b;I-=w&67108863,k=(I>>26)-(w/67108864|0),this.words[C+p]=I&67108863}for(;C<this.length-p;C++)I=(this.words[C+p]|0)+k,k=I>>26,this.words[C+p]=I&67108863;if(k===0)return this._strip();for(r(k===-1),k=0,C=0;C<this.length;C++)I=-(this.words[C]|0)+k,k=I>>26,this.words[C]=I&67108863;return this.negative=1,this._strip()},"_ishlnsubmul"),i.prototype._wordDiv=s(function(m,b){var p=this.length-m.length,v=this.clone(),C=m,I=C.words[C.length-1]|0,k=this._countBits(I);p=26-k,p!==0&&(C=C.ushln(p),v.iushln(p),I=C.words[C.length-1]|0);var w=v.length-C.length,A;if(b!=="mod"){A=new i(null),A.length=w+1,A.words=new Array(A.length);for(var R=0;R<A.length;R++)A.words[R]=0}var D=v.clone()._ishlnsubmul(C,1,w);D.negative===0&&(v=D,A&&(A.words[w]=1));for(var M=w-1;M>=0;M--){var te=(v.words[C.length+M]|0)*67108864+(v.words[C.length+M-1]|0);for(te=Math.min(te/I|0,67108863),v._ishlnsubmul(C,te,M);v.negative!==0;)te--,v.negative=0,v._ishlnsubmul(C,1,M),v.isZero()||(v.negative^=1);A&&(A.words[M]=te)}return A&&A._strip(),v._strip(),b!=="div"&&p!==0&&v.iushrn(p),{div:A||null,mod:v}},"_wordDiv"),i.prototype.divmod=s(function(m,b,p){if(r(!m.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var v,C,I;return this.negative!==0&&m.negative===0?(I=this.neg().divmod(m,b),b!=="mod"&&(v=I.div.neg()),b!=="div"&&(C=I.mod.neg(),p&&C.negative!==0&&C.iadd(m)),{div:v,mod:C}):this.negative===0&&m.negative!==0?(I=this.divmod(m.neg(),b),b!=="mod"&&(v=I.div.neg()),{div:v,mod:I.mod}):(this.negative&m.negative)!==0?(I=this.neg().divmod(m.neg(),b),b!=="div"&&(C=I.mod.neg(),p&&C.negative!==0&&C.isub(m)),{div:I.div,mod:C}):m.length>this.length||this.cmp(m)<0?{div:new i(0),mod:this}:m.length===1?b==="div"?{div:this.divn(m.words[0]),mod:null}:b==="mod"?{div:null,mod:new i(this.modrn(m.words[0]))}:{div:this.divn(m.words[0]),mod:new i(this.modrn(m.words[0]))}:this._wordDiv(m,b)},"divmod"),i.prototype.div=s(function(m){return this.divmod(m,"div",!1).div},"div"),i.prototype.mod=s(function(m){return this.divmod(m,"mod",!1).mod},"mod"),i.prototype.umod=s(function(m){return this.divmod(m,"mod",!0).mod},"umod"),i.prototype.divRound=s(function(m){var b=this.divmod(m);if(b.mod.isZero())return b.div;var p=b.div.negative!==0?b.mod.isub(m):b.mod,v=m.ushrn(1),C=m.andln(1),I=p.cmp(v);return I<0||C===1&&I===0?b.div:b.div.negative!==0?b.div.isubn(1):b.div.iaddn(1)},"divRound"),i.prototype.modrn=s(function(m){var b=m<0;b&&(m=-m),r(m<=67108863);for(var p=(1<<26)%m,v=0,C=this.length-1;C>=0;C--)v=(p*v+(this.words[C]|0))%m;return b?-v:v},"modrn"),i.prototype.modn=s(function(m){return this.modrn(m)},"modn"),i.prototype.idivn=s(function(m){var b=m<0;b&&(m=-m),r(m<=67108863);for(var p=0,v=this.length-1;v>=0;v--){var C=(this.words[v]|0)+p*67108864;this.words[v]=C/m|0,p=C%m}return this._strip(),b?this.ineg():this},"idivn"),i.prototype.divn=s(function(m){return this.clone().idivn(m)},"divn"),i.prototype.egcd=s(function(m){r(m.negative===0),r(!m.isZero());var b=this,p=m.clone();b.negative!==0?b=b.umod(m):b=b.clone();for(var v=new i(1),C=new i(0),I=new i(0),k=new i(1),w=0;b.isEven()&&p.isEven();)b.iushrn(1),p.iushrn(1),++w;for(var A=p.clone(),R=b.clone();!b.isZero();){for(var D=0,M=1;(b.words[0]&M)===0&&D<26;++D,M<<=1);if(D>0)for(b.iushrn(D);D-- >0;)(v.isOdd()||C.isOdd())&&(v.iadd(A),C.isub(R)),v.iushrn(1),C.iushrn(1);for(var te=0,L=1;(p.words[0]&L)===0&&te<26;++te,L<<=1);if(te>0)for(p.iushrn(te);te-- >0;)(I.isOdd()||k.isOdd())&&(I.iadd(A),k.isub(R)),I.iushrn(1),k.iushrn(1);b.cmp(p)>=0?(b.isub(p),v.isub(I),C.isub(k)):(p.isub(b),I.isub(v),k.isub(C))}return{a:I,b:k,gcd:p.iushln(w)}},"egcd"),i.prototype._invmp=s(function(m){r(m.negative===0),r(!m.isZero());var b=this,p=m.clone();b.negative!==0?b=b.umod(m):b=b.clone();for(var v=new i(1),C=new i(0),I=p.clone();b.cmpn(1)>0&&p.cmpn(1)>0;){for(var k=0,w=1;(b.words[0]&w)===0&&k<26;++k,w<<=1);if(k>0)for(b.iushrn(k);k-- >0;)v.isOdd()&&v.iadd(I),v.iushrn(1);for(var A=0,R=1;(p.words[0]&R)===0&&A<26;++A,R<<=1);if(A>0)for(p.iushrn(A);A-- >0;)C.isOdd()&&C.iadd(I),C.iushrn(1);b.cmp(p)>=0?(b.isub(p),v.isub(C)):(p.isub(b),C.isub(v))}var D;return b.cmpn(1)===0?D=v:D=C,D.cmpn(0)<0&&D.iadd(m),D},"_invmp"),i.prototype.gcd=s(function(m){if(this.isZero())return m.abs();if(m.isZero())return this.abs();var b=this.clone(),p=m.clone();b.negative=0,p.negative=0;for(var v=0;b.isEven()&&p.isEven();v++)b.iushrn(1),p.iushrn(1);do{for(;b.isEven();)b.iushrn(1);for(;p.isEven();)p.iushrn(1);var C=b.cmp(p);if(C<0){var I=b;b=p,p=I}else if(C===0||p.cmpn(1)===0)break;b.isub(p)}while(!0);return p.iushln(v)},"gcd"),i.prototype.invm=s(function(m){return this.egcd(m).a.umod(m)},"invm"),i.prototype.isEven=s(function(){return(this.words[0]&1)===0},"isEven"),i.prototype.isOdd=s(function(){return(this.words[0]&1)===1},"isOdd"),i.prototype.andln=s(function(m){return this.words[0]&m},"andln"),i.prototype.bincn=s(function(m){r(typeof m=="number");var b=m%26,p=(m-b)/26,v=1<<b;if(this.length<=p)return this._expand(p+1),this.words[p]|=v,this;for(var C=v,I=p;C!==0&&I<this.length;I++){var k=this.words[I]|0;k+=C,C=k>>>26,k&=67108863,this.words[I]=k}return C!==0&&(this.words[I]=C,this.length++),this},"bincn"),i.prototype.isZero=s(function(){return this.length===1&&this.words[0]===0},"isZero"),i.prototype.cmpn=s(function(m){var b=m<0;if(this.negative!==0&&!b)return-1;if(this.negative===0&&b)return 1;this._strip();var p;if(this.length>1)p=1;else{b&&(m=-m),r(m<=67108863,"Number is too big");var v=this.words[0]|0;p=v===m?0:v<m?-1:1}return this.negative!==0?-p|0:p},"cmpn"),i.prototype.cmp=s(function(m){if(this.negative!==0&&m.negative===0)return-1;if(this.negative===0&&m.negative!==0)return 1;var b=this.ucmp(m);return this.negative!==0?-b|0:b},"cmp"),i.prototype.ucmp=s(function(m){if(this.length>m.length)return 1;if(this.length<m.length)return-1;for(var b=0,p=this.length-1;p>=0;p--){var v=this.words[p]|0,C=m.words[p]|0;if(v!==C){v<C?b=-1:v>C&&(b=1);break}}return b},"ucmp"),i.prototype.gtn=s(function(m){return this.cmpn(m)===1},"gtn"),i.prototype.gt=s(function(m){return this.cmp(m)===1},"gt"),i.prototype.gten=s(function(m){return this.cmpn(m)>=0},"gten"),i.prototype.gte=s(function(m){return this.cmp(m)>=0},"gte"),i.prototype.ltn=s(function(m){return this.cmpn(m)===-1},"ltn"),i.prototype.lt=s(function(m){return this.cmp(m)===-1},"lt"),i.prototype.lten=s(function(m){return this.cmpn(m)<=0},"lten"),i.prototype.lte=s(function(m){return this.cmp(m)<=0},"lte"),i.prototype.eqn=s(function(m){return this.cmpn(m)===0},"eqn"),i.prototype.eq=s(function(m){return this.cmp(m)===0},"eq"),i.red=s(function(m){return new ae(m)},"red"),i.prototype.toRed=s(function(m){return r(!this.red,"Already a number in reduction context"),r(this.negative===0,"red works only with positives"),m.convertTo(this)._forceRed(m)},"toRed"),i.prototype.fromRed=s(function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},"fromRed"),i.prototype._forceRed=s(function(m){return this.red=m,this},"_forceRed"),i.prototype.forceRed=s(function(m){return r(!this.red,"Already a number in reduction context"),this._forceRed(m)},"forceRed"),i.prototype.redAdd=s(function(m){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,m)},"redAdd"),i.prototype.redIAdd=s(function(m){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,m)},"redIAdd"),i.prototype.redSub=s(function(m){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,m)},"redSub"),i.prototype.redISub=s(function(m){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,m)},"redISub"),i.prototype.redShl=s(function(m){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,m)},"redShl"),i.prototype.redMul=s(function(m){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.mul(this,m)},"redMul"),i.prototype.redIMul=s(function(m){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.imul(this,m)},"redIMul"),i.prototype.redSqr=s(function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},"redSqr"),i.prototype.redISqr=s(function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},"redISqr"),i.prototype.redSqrt=s(function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},"redSqrt"),i.prototype.redInvm=s(function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},"redInvm"),i.prototype.redNeg=s(function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},"redNeg"),i.prototype.redPow=s(function(m){return r(this.red&&!m.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,m)},"redPow");var K={k256:null,p224:null,p192:null,p25519:null};function W(S,m){this.name=S,this.p=new i(m,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}s(W,"MPrime"),W.prototype._tmp=s(function(){var m=new i(null);return m.words=new Array(Math.ceil(this.n/13)),m},"_tmp"),W.prototype.ireduce=s(function(m){var b=m,p;do this.split(b,this.tmp),b=this.imulK(b),b=b.iadd(this.tmp),p=b.bitLength();while(p>this.n);var v=p<this.n?-1:b.ucmp(this.p);return v===0?(b.words[0]=0,b.length=1):v>0?b.isub(this.p):b.strip!==void 0?b.strip():b._strip(),b},"ireduce"),W.prototype.split=s(function(m,b){m.iushrn(this.n,0,b)},"split"),W.prototype.imulK=s(function(m){return m.imul(this.k)},"imulK");function N(){W.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(N,"K256"),n(N,W),N.prototype.split=s(function(m,b){for(var p=4194303,v=Math.min(m.length,9),C=0;C<v;C++)b.words[C]=m.words[C];if(b.length=v,m.length<=9){m.words[0]=0,m.length=1;return}var I=m.words[9];for(b.words[b.length++]=I&p,C=10;C<m.length;C++){var k=m.words[C]|0;m.words[C-10]=(k&p)<<4|I>>>22,I=k}I>>>=22,m.words[C-10]=I,I===0&&m.length>10?m.length-=10:m.length-=9},"split"),N.prototype.imulK=s(function(m){m.words[m.length]=0,m.words[m.length+1]=0,m.length+=2;for(var b=0,p=0;p<m.length;p++){var v=m.words[p]|0;b+=v*977,m.words[p]=b&67108863,b=v*64+(b/67108864|0)}return m.words[m.length-1]===0&&(m.length--,m.words[m.length-1]===0&&m.length--),m},"imulK");function G(){W.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}s(G,"P224"),n(G,W);function ce(){W.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}s(ce,"P192"),n(ce,W);function re(){W.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}s(re,"P25519"),n(re,W),re.prototype.imulK=s(function(m){for(var b=0,p=0;p<m.length;p++){var v=(m.words[p]|0)*19+b,C=v&67108863;v>>>=26,m.words[p]=C,b=v}return b!==0&&(m.words[m.length++]=b),m},"imulK"),i._prime=s(function(m){if(K[m])return K[m];var b;if(m==="k256")b=new N;else if(m==="p224")b=new G;else if(m==="p192")b=new ce;else if(m==="p25519")b=new re;else throw new Error("Unknown prime "+m);return K[m]=b,b},"prime");function ae(S){if(typeof S=="string"){var m=i._prime(S);this.m=m.p,this.prime=m}else r(S.gtn(1),"modulus must be greater than 1"),this.m=S,this.prime=null}s(ae,"Red"),ae.prototype._verify1=s(function(m){r(m.negative===0,"red works only with positives"),r(m.red,"red works only with red numbers")},"_verify1"),ae.prototype._verify2=s(function(m,b){r((m.negative|b.negative)===0,"red works only with positives"),r(m.red&&m.red===b.red,"red works only with red numbers")},"_verify2"),ae.prototype.imod=s(function(m){return this.prime?this.prime.ireduce(m)._forceRed(this):(u(m,m.umod(this.m)._forceRed(this)),m)},"imod"),ae.prototype.neg=s(function(m){return m.isZero()?m.clone():this.m.sub(m)._forceRed(this)},"neg"),ae.prototype.add=s(function(m,b){this._verify2(m,b);var p=m.add(b);return p.cmp(this.m)>=0&&p.isub(this.m),p._forceRed(this)},"add"),ae.prototype.iadd=s(function(m,b){this._verify2(m,b);var p=m.iadd(b);return p.cmp(this.m)>=0&&p.isub(this.m),p},"iadd"),ae.prototype.sub=s(function(m,b){this._verify2(m,b);var p=m.sub(b);return p.cmpn(0)<0&&p.iadd(this.m),p._forceRed(this)},"sub"),ae.prototype.isub=s(function(m,b){this._verify2(m,b);var p=m.isub(b);return p.cmpn(0)<0&&p.iadd(this.m),p},"isub"),ae.prototype.shl=s(function(m,b){return this._verify1(m),this.imod(m.ushln(b))},"shl"),ae.prototype.imul=s(function(m,b){return this._verify2(m,b),this.imod(m.imul(b))},"imul"),ae.prototype.mul=s(function(m,b){return this._verify2(m,b),this.imod(m.mul(b))},"mul"),ae.prototype.isqr=s(function(m){return this.imul(m,m.clone())},"isqr"),ae.prototype.sqr=s(function(m){return this.mul(m,m)},"sqr"),ae.prototype.sqrt=s(function(m){if(m.isZero())return m.clone();var b=this.m.andln(3);if(r(b%2===1),b===3){var p=this.m.add(new i(1)).iushrn(2);return this.pow(m,p)}for(var v=this.m.subn(1),C=0;!v.isZero()&&v.andln(1)===0;)C++,v.iushrn(1);r(!v.isZero());var I=new i(1).toRed(this),k=I.redNeg(),w=this.m.subn(1).iushrn(1),A=this.m.bitLength();for(A=new i(2*A*A).toRed(this);this.pow(A,w).cmp(k)!==0;)A.redIAdd(k);for(var R=this.pow(A,v),D=this.pow(m,v.addn(1).iushrn(1)),M=this.pow(m,v),te=C;M.cmp(I)!==0;){for(var L=M,Y=0;L.cmp(I)!==0;Y++)L=L.redSqr();r(Y<te);var Z=this.pow(R,new i(1).iushln(te-Y-1));D=D.redMul(Z),R=Z.redSqr(),M=M.redMul(R),te=Y}return D},"sqrt"),ae.prototype.invm=s(function(m){var b=m._invmp(this.m);return b.negative!==0?(b.negative=0,this.imod(b).redNeg()):this.imod(b)},"invm"),ae.prototype.pow=s(function(m,b){if(b.isZero())return new i(1).toRed(this);if(b.cmpn(1)===0)return m.clone();var p=4,v=new Array(1<<p);v[0]=new i(1).toRed(this),v[1]=m;for(var C=2;C<v.length;C++)v[C]=this.mul(v[C-1],m);var I=v[0],k=0,w=0,A=b.bitLength()%26;for(A===0&&(A=26),C=b.length-1;C>=0;C--){for(var R=b.words[C],D=A-1;D>=0;D--){var M=R>>D&1;if(I!==v[0]&&(I=this.sqr(I)),M===0&&k===0){w=0;continue}k<<=1,k|=M,w++,!(w!==p&&(C!==0||D!==0))&&(I=this.mul(I,v[k]),w=0,k=0)}A=26}return I},"pow"),ae.prototype.convertTo=s(function(m){var b=m.umod(this.m);return b===m?b.clone():b},"convertTo"),ae.prototype.convertFrom=s(function(m){var b=m.clone();return b.red=null,b},"convertFrom"),i.mont=s(function(m){return new J(m)},"mont");function J(S){ae.call(this,S),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(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)}s(J,"Mont"),n(J,ae),J.prototype.convertTo=s(function(m){return this.imod(m.ushln(this.shift))},"convertTo"),J.prototype.convertFrom=s(function(m){var b=this.imod(m.mul(this.rinv));return b.red=null,b},"convertFrom"),J.prototype.imul=s(function(m,b){if(m.isZero()||b.isZero())return m.words[0]=0,m.length=1,m;var p=m.imul(b),v=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),C=p.isub(v).iushrn(this.shift),I=C;return C.cmp(this.m)>=0?I=C.isub(this.m):C.cmpn(0)<0&&(I=C.iadd(this.m)),I._forceRed(this)},"imul"),J.prototype.mul=s(function(m,b){if(m.isZero()||b.isZero())return new i(0)._forceRed(this);var p=m.mul(b),v=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),C=p.isub(v).iushrn(this.shift),I=C;return C.cmp(this.m)>=0?I=C.isub(this.m):C.cmpn(0)<0&&(I=C.iadd(this.m)),I._forceRed(this)},"mul"),J.prototype.invm=s(function(m){var b=this.imod(m._invmp(this.m).mul(this.r2));return b._forceRed(this)},"invm")})(typeof i3>"u"||i3,nS)});var kS=an((uoe,Ig)=>{(function(){"use strict";var t="input is invalid type",e="finalize already called",r=typeof window=="object",n=r?window:{};n.JS_SHA3_NO_WINDOW&&(r=!1);var i=!r&&typeof self=="object",o=!n.JS_SHA3_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node;o?n=global:i&&(n=self);var a=!n.JS_SHA3_NO_COMMON_JS&&typeof Ig=="object"&&Ig.exports,f=typeof define=="function"&&define.amd,l=!n.JS_SHA3_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",u="0123456789abcdef".split(""),h=[31,7936,2031616,520093696],g=[4,1024,262144,67108864],x=[1,256,65536,16777216],_=[6,1536,393216,100663296],E=[0,8,16,24],T=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],B=[224,256,384,512],F=[128,256],H=["hex","buffer","arrayBuffer","array","digest"],U={128:168,256:136};(n.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(M){return Object.prototype.toString.call(M)==="[object Array]"}),l&&(n.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(M){return typeof M=="object"&&M.buffer&&M.buffer.constructor===ArrayBuffer});for(var q=s(function(M,te,L){return function(Y){return new A(M,te,M).update(Y)[L]()}},"createOutputMethod"),K=s(function(M,te,L){return function(Y,Z){return new A(M,te,Z).update(Y)[L]()}},"createShakeOutputMethod"),W=s(function(M,te,L){return function(Y,Z,P,z){return m["cshake"+M].update(Y,Z,P,z)[L]()}},"createCshakeOutputMethod"),N=s(function(M,te,L){return function(Y,Z,P,z){return m["kmac"+M].update(Y,Z,P,z)[L]()}},"createKmacOutputMethod"),G=s(function(M,te,L,Y){for(var Z=0;Z<H.length;++Z){var P=H[Z];M[P]=te(L,Y,P)}return M},"createOutputMethods"),ce=s(function(M,te){var L=q(M,te,"hex");return L.create=function(){return new A(M,te,M)},L.update=function(Y){return L.create().update(Y)},G(L,q,M,te)},"createMethod"),re=s(function(M,te){var L=K(M,te,"hex");return L.create=function(Y){return new A(M,te,Y)},L.update=function(Y,Z){return L.create(Z).update(Y)},G(L,K,M,te)},"createShakeMethod"),ae=s(function(M,te){var L=U[M],Y=W(M,te,"hex");return Y.create=function(Z,P,z){return!P&&!z?m["shake"+M].create(Z):new A(M,te,Z).bytepad([P,z],L)},Y.update=function(Z,P,z,oe){return Y.create(P,z,oe).update(Z)},G(Y,W,M,te)},"createCshakeMethod"),J=s(function(M,te){var L=U[M],Y=N(M,te,"hex");return Y.create=function(Z,P,z){return new R(M,te,P).bytepad(["KMAC",z],L).bytepad([Z],L)},Y.update=function(Z,P,z,oe){return Y.create(Z,z,oe).update(P)},G(Y,N,M,te)},"createKmacMethod"),S=[{name:"keccak",padding:x,bits:B,createMethod:ce},{name:"sha3",padding:_,bits:B,createMethod:ce},{name:"shake",padding:h,bits:F,createMethod:re},{name:"cshake",padding:g,bits:F,createMethod:ae},{name:"kmac",padding:g,bits:F,createMethod:J}],m={},b=[],p=0;p<S.length;++p)for(var v=S[p],C=v.bits,I=0;I<C.length;++I){var k=v.name+"_"+C[I];if(b.push(k),m[k]=v.createMethod(C[I],v.padding),v.name!=="sha3"){var w=v.name+C[I];b.push(w),m[w]=m[k]}}function A(M,te,L){this.blocks=[],this.s=[],this.padding=te,this.outputBits=L,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(M<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=L>>5,this.extraBytes=(L&31)>>3;for(var Y=0;Y<50;++Y)this.s[Y]=0}s(A,"Keccak"),A.prototype.update=function(M){if(this.finalized)throw new Error(e);var te,L=typeof M;if(L!=="string"){if(L==="object"){if(M===null)throw new Error(t);if(l&&M.constructor===ArrayBuffer)M=new Uint8Array(M);else if(!Array.isArray(M)&&(!l||!ArrayBuffer.isView(M)))throw new Error(t)}else throw new Error(t);te=!0}for(var Y=this.blocks,Z=this.byteCount,P=M.length,z=this.blockCount,oe=0,ue=this.s,me,ke;oe<P;){if(this.reset)for(this.reset=!1,Y[0]=this.block,me=1;me<z+1;++me)Y[me]=0;if(te)for(me=this.start;oe<P&&me<Z;++oe)Y[me>>2]|=M[oe]<<E[me++&3];else for(me=this.start;oe<P&&me<Z;++oe)ke=M.charCodeAt(oe),ke<128?Y[me>>2]|=ke<<E[me++&3]:ke<2048?(Y[me>>2]|=(192|ke>>6)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]):ke<55296||ke>=57344?(Y[me>>2]|=(224|ke>>12)<<E[me++&3],Y[me>>2]|=(128|ke>>6&63)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]):(ke=65536+((ke&1023)<<10|M.charCodeAt(++oe)&1023),Y[me>>2]|=(240|ke>>18)<<E[me++&3],Y[me>>2]|=(128|ke>>12&63)<<E[me++&3],Y[me>>2]|=(128|ke>>6&63)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]);if(this.lastByteIndex=me,me>=Z){for(this.start=me-Z,this.block=Y[z],me=0;me<z;++me)ue[me]^=Y[me];D(ue),this.reset=!0}else this.start=me}return this},A.prototype.encode=function(M,te){var L=M&255,Y=1,Z=[L];for(M=M>>8,L=M&255;L>0;)Z.unshift(L),M=M>>8,L=M&255,++Y;return te?Z.push(Y):Z.unshift(Y),this.update(Z),Z.length},A.prototype.encodeString=function(M){var te,L=typeof M;if(L!=="string"){if(L==="object"){if(M===null)throw new Error(t);if(l&&M.constructor===ArrayBuffer)M=new Uint8Array(M);else if(!Array.isArray(M)&&(!l||!ArrayBuffer.isView(M)))throw new Error(t)}else throw new Error(t);te=!0}var Y=0,Z=M.length;if(te)Y=Z;else for(var P=0;P<M.length;++P){var z=M.charCodeAt(P);z<128?Y+=1:z<2048?Y+=2:z<55296||z>=57344?Y+=3:(z=65536+((z&1023)<<10|M.charCodeAt(++P)&1023),Y+=4)}return Y+=this.encode(Y*8),this.update(M),Y},A.prototype.bytepad=function(M,te){for(var L=this.encode(te),Y=0;Y<M.length;++Y)L+=this.encodeString(M[Y]);var Z=te-L%te,P=[];return P.length=Z,this.update(P),this},A.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var M=this.blocks,te=this.lastByteIndex,L=this.blockCount,Y=this.s;if(M[te>>2]|=this.padding[te&3],this.lastByteIndex===this.byteCount)for(M[0]=M[L],te=1;te<L+1;++te)M[te]=0;for(M[L-1]|=2147483648,te=0;te<L;++te)Y[te]^=M[te];D(Y)}},A.prototype.toString=A.prototype.hex=function(){this.finalize();for(var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z="",oe;P<L;){for(Z=0;Z<M&&P<L;++Z,++P)oe=te[Z],z+=u[oe>>4&15]+u[oe&15]+u[oe>>12&15]+u[oe>>8&15]+u[oe>>20&15]+u[oe>>16&15]+u[oe>>28&15]+u[oe>>24&15];P%M===0&&(D(te),Z=0)}return Y&&(oe=te[Z],z+=u[oe>>4&15]+u[oe&15],Y>1&&(z+=u[oe>>12&15]+u[oe>>8&15]),Y>2&&(z+=u[oe>>20&15]+u[oe>>16&15])),z},A.prototype.arrayBuffer=function(){this.finalize();var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z=this.outputBits>>3,oe;Y?oe=new ArrayBuffer(L+1<<2):oe=new ArrayBuffer(z);for(var ue=new Uint32Array(oe);P<L;){for(Z=0;Z<M&&P<L;++Z,++P)ue[P]=te[Z];P%M===0&&D(te)}return Y&&(ue[Z]=te[Z],oe=oe.slice(0,z)),oe},A.prototype.buffer=A.prototype.arrayBuffer,A.prototype.digest=A.prototype.array=function(){this.finalize();for(var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z=[],oe,ue;P<L;){for(Z=0;Z<M&&P<L;++Z,++P)oe=P<<2,ue=te[Z],z[oe]=ue&255,z[oe+1]=ue>>8&255,z[oe+2]=ue>>16&255,z[oe+3]=ue>>24&255;P%M===0&&D(te)}return Y&&(oe=P<<2,ue=te[Z],z[oe]=ue&255,Y>1&&(z[oe+1]=ue>>8&255),Y>2&&(z[oe+2]=ue>>16&255)),z};function R(M,te,L){A.call(this,M,te,L)}s(R,"Kmac"),R.prototype=new A,R.prototype.finalize=function(){return this.encode(this.outputBits,!0),A.prototype.finalize.call(this)};var D=s(function(M){var te,L,Y,Z,P,z,oe,ue,me,ke,Q,j,$,X,se,ee,le,be,Se,Te,De,Ne,ye,pe,ne,he,Ee,Ie,Re,Oe,bt,Qe,qe,vt,gt,tt,Ut,ht,et,Dt,pt,Xe,Mt,ft,Ye,It,lt,Ze,Rt,ut,Je,Bt,dt,at,tr,Tt,rt,Yt,Kt,Vt,Vr,Wr,Ir;for(Y=0;Y<48;Y+=2)Z=M[0]^M[10]^M[20]^M[30]^M[40],P=M[1]^M[11]^M[21]^M[31]^M[41],z=M[2]^M[12]^M[22]^M[32]^M[42],oe=M[3]^M[13]^M[23]^M[33]^M[43],ue=M[4]^M[14]^M[24]^M[34]^M[44],me=M[5]^M[15]^M[25]^M[35]^M[45],ke=M[6]^M[16]^M[26]^M[36]^M[46],Q=M[7]^M[17]^M[27]^M[37]^M[47],j=M[8]^M[18]^M[28]^M[38]^M[48],$=M[9]^M[19]^M[29]^M[39]^M[49],te=j^(z<<1|oe>>>31),L=$^(oe<<1|z>>>31),M[0]^=te,M[1]^=L,M[10]^=te,M[11]^=L,M[20]^=te,M[21]^=L,M[30]^=te,M[31]^=L,M[40]^=te,M[41]^=L,te=Z^(ue<<1|me>>>31),L=P^(me<<1|ue>>>31),M[2]^=te,M[3]^=L,M[12]^=te,M[13]^=L,M[22]^=te,M[23]^=L,M[32]^=te,M[33]^=L,M[42]^=te,M[43]^=L,te=z^(ke<<1|Q>>>31),L=oe^(Q<<1|ke>>>31),M[4]^=te,M[5]^=L,M[14]^=te,M[15]^=L,M[24]^=te,M[25]^=L,M[34]^=te,M[35]^=L,M[44]^=te,M[45]^=L,te=ue^(j<<1|$>>>31),L=me^($<<1|j>>>31),M[6]^=te,M[7]^=L,M[16]^=te,M[17]^=L,M[26]^=te,M[27]^=L,M[36]^=te,M[37]^=L,M[46]^=te,M[47]^=L,te=ke^(Z<<1|P>>>31),L=Q^(P<<1|Z>>>31),M[8]^=te,M[9]^=L,M[18]^=te,M[19]^=L,M[28]^=te,M[29]^=L,M[38]^=te,M[39]^=L,M[48]^=te,M[49]^=L,X=M[0],se=M[1],It=M[11]<<4|M[10]>>>28,lt=M[10]<<4|M[11]>>>28,Ie=M[20]<<3|M[21]>>>29,Re=M[21]<<3|M[20]>>>29,Vt=M[31]<<9|M[30]>>>23,Vr=M[30]<<9|M[31]>>>23,Xe=M[40]<<18|M[41]>>>14,Mt=M[41]<<18|M[40]>>>14,vt=M[2]<<1|M[3]>>>31,gt=M[3]<<1|M[2]>>>31,ee=M[13]<<12|M[12]>>>20,le=M[12]<<12|M[13]>>>20,Ze=M[22]<<10|M[23]>>>22,Rt=M[23]<<10|M[22]>>>22,Oe=M[33]<<13|M[32]>>>19,bt=M[32]<<13|M[33]>>>19,Wr=M[42]<<2|M[43]>>>30,Ir=M[43]<<2|M[42]>>>30,at=M[5]<<30|M[4]>>>2,tr=M[4]<<30|M[5]>>>2,tt=M[14]<<6|M[15]>>>26,Ut=M[15]<<6|M[14]>>>26,be=M[25]<<11|M[24]>>>21,Se=M[24]<<11|M[25]>>>21,ut=M[34]<<15|M[35]>>>17,Je=M[35]<<15|M[34]>>>17,Qe=M[45]<<29|M[44]>>>3,qe=M[44]<<29|M[45]>>>3,pe=M[6]<<28|M[7]>>>4,ne=M[7]<<28|M[6]>>>4,Tt=M[17]<<23|M[16]>>>9,rt=M[16]<<23|M[17]>>>9,ht=M[26]<<25|M[27]>>>7,et=M[27]<<25|M[26]>>>7,Te=M[36]<<21|M[37]>>>11,De=M[37]<<21|M[36]>>>11,Bt=M[47]<<24|M[46]>>>8,dt=M[46]<<24|M[47]>>>8,ft=M[8]<<27|M[9]>>>5,Ye=M[9]<<27|M[8]>>>5,he=M[18]<<20|M[19]>>>12,Ee=M[19]<<20|M[18]>>>12,Yt=M[29]<<7|M[28]>>>25,Kt=M[28]<<7|M[29]>>>25,Dt=M[38]<<8|M[39]>>>24,pt=M[39]<<8|M[38]>>>24,Ne=M[48]<<14|M[49]>>>18,ye=M[49]<<14|M[48]>>>18,M[0]=X^~ee&be,M[1]=se^~le&Se,M[10]=pe^~he&Ie,M[11]=ne^~Ee&Re,M[20]=vt^~tt&ht,M[21]=gt^~Ut&et,M[30]=ft^~It&Ze,M[31]=Ye^~lt&Rt,M[40]=at^~Tt&Yt,M[41]=tr^~rt&Kt,M[2]=ee^~be&Te,M[3]=le^~Se&De,M[12]=he^~Ie&Oe,M[13]=Ee^~Re&bt,M[22]=tt^~ht&Dt,M[23]=Ut^~et&pt,M[32]=It^~Ze&ut,M[33]=lt^~Rt&Je,M[42]=Tt^~Yt&Vt,M[43]=rt^~Kt&Vr,M[4]=be^~Te&Ne,M[5]=Se^~De&ye,M[14]=Ie^~Oe&Qe,M[15]=Re^~bt&qe,M[24]=ht^~Dt&Xe,M[25]=et^~pt&Mt,M[34]=Ze^~ut&Bt,M[35]=Rt^~Je&dt,M[44]=Yt^~Vt&Wr,M[45]=Kt^~Vr&Ir,M[6]=Te^~Ne&X,M[7]=De^~ye&se,M[16]=Oe^~Qe&pe,M[17]=bt^~qe&ne,M[26]=Dt^~Xe&vt,M[27]=pt^~Mt>,M[36]=ut^~Bt&ft,M[37]=Je^~dt&Ye,M[46]=Vt^~Wr&at,M[47]=Vr^~Ir&tr,M[8]=Ne^~X&ee,M[9]=ye^~se&le,M[18]=Qe^~pe&he,M[19]=qe^~ne&Ee,M[28]=Xe^~vt&tt,M[29]=Mt^~gt&Ut,M[38]=Bt^~ft&It,M[39]=dt^~Ye<,M[48]=Wr^~at&Tt,M[49]=Ir^~tr&rt,M[0]^=T[Y],M[1]^=T[Y+1]},"f");if(a)Ig.exports=m;else{for(p=0;p<b.length;++p)n[b[p]]=m[b[p]];f&&define(function(){return m})}})()});var Qu=an((rfe,AI)=>{AI.exports=_I;function _I(t,e){if(!t)throw new Error(e||"Assertion failed")}s(_I,"assert");_I.equal=s(function(e,r,n){if(e!=r)throw new Error(n||"Assertion failed: "+e+" != "+r)},"assertEqual")});var EI=an((nfe,B3)=>{typeof Object.create=="function"?B3.exports=s(function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))},"inherits"):B3.exports=s(function(e,r){if(r){e.super_=r;var n=s(function(){},"TempCtor");n.prototype=r.prototype,e.prototype=new n,e.prototype.constructor=e}},"inherits")});var Io=an(zr=>{"use strict";var LG=Qu(),UG=EI();zr.inherits=UG;function jG(t,e){return(t.charCodeAt(e)&64512)!==55296||e<0||e+1>=t.length?!1:(t.charCodeAt(e+1)&64512)===56320}s(jG,"isSurrogatePair");function qG(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if(typeof t=="string")if(e){if(e==="hex")for(t=t.replace(/[^a-z0-9]+/ig,""),t.length%2!==0&&(t="0"+t),i=0;i<t.length;i+=2)r.push(parseInt(t[i]+t[i+1],16))}else for(var n=0,i=0;i<t.length;i++){var o=t.charCodeAt(i);o<128?r[n++]=o:o<2048?(r[n++]=o>>6|192,r[n++]=o&63|128):jG(t,i)?(o=65536+((o&1023)<<10)+(t.charCodeAt(++i)&1023),r[n++]=o>>18|240,r[n++]=o>>12&63|128,r[n++]=o>>6&63|128,r[n++]=o&63|128):(r[n++]=o>>12|224,r[n++]=o>>6&63|128,r[n++]=o&63|128)}else for(i=0;i<t.length;i++)r[i]=t[i]|0;return r}s(qG,"toArray");zr.toArray=qG;function HG(t){for(var e="",r=0;r<t.length;r++)e+=SI(t[r].toString(16));return e}s(HG,"toHex");zr.toHex=HG;function CI(t){var e=t>>>24|t>>>8&65280|t<<8&16711680|(t&255)<<24;return e>>>0}s(CI,"htonl");zr.htonl=CI;function zG(t,e){for(var r="",n=0;n<t.length;n++){var i=t[n];e==="little"&&(i=CI(i)),r+=II(i.toString(16))}return r}s(zG,"toHex32");zr.toHex32=zG;function SI(t){return t.length===1?"0"+t:t}s(SI,"zero2");zr.zero2=SI;function II(t){return t.length===7?"0"+t:t.length===6?"00"+t:t.length===5?"000"+t:t.length===4?"0000"+t:t.length===3?"00000"+t:t.length===2?"000000"+t:t.length===1?"0000000"+t:t}s(II,"zero8");zr.zero8=II;function $G(t,e,r,n){var i=r-e;LG(i%4===0);for(var o=new Array(i/4),a=0,f=e;a<o.length;a++,f+=4){var l;n==="big"?l=t[f]<<24|t[f+1]<<16|t[f+2]<<8|t[f+3]:l=t[f+3]<<24|t[f+2]<<16|t[f+1]<<8|t[f],o[a]=l>>>0}return o}s($G,"join32");zr.join32=$G;function GG(t,e){for(var r=new Array(t.length*4),n=0,i=0;n<t.length;n++,i+=4){var o=t[n];e==="big"?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=o&255):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=o&255)}return r}s(GG,"split32");zr.split32=GG;function KG(t,e){return t>>>e|t<<32-e}s(KG,"rotr32");zr.rotr32=KG;function VG(t,e){return t<<e|t>>>32-e}s(VG,"rotl32");zr.rotl32=VG;function WG(t,e){return t+e>>>0}s(WG,"sum32");zr.sum32=WG;function JG(t,e,r){return t+e+r>>>0}s(JG,"sum32_3");zr.sum32_3=JG;function YG(t,e,r,n){return t+e+r+n>>>0}s(YG,"sum32_4");zr.sum32_4=YG;function ZG(t,e,r,n,i){return t+e+r+n+i>>>0}s(ZG,"sum32_5");zr.sum32_5=ZG;function XG(t,e,r,n){var i=t[e],o=t[e+1],a=n+o>>>0,f=(a<n?1:0)+r+i;t[e]=f>>>0,t[e+1]=a}s(XG,"sum64");zr.sum64=XG;function QG(t,e,r,n){var i=e+n>>>0,o=(i<e?1:0)+t+r;return o>>>0}s(QG,"sum64_hi");zr.sum64_hi=QG;function eK(t,e,r,n){var i=e+n;return i>>>0}s(eK,"sum64_lo");zr.sum64_lo=eK;function tK(t,e,r,n,i,o,a,f){var l=0,u=e;u=u+n>>>0,l+=u<e?1:0,u=u+o>>>0,l+=u<o?1:0,u=u+f>>>0,l+=u<f?1:0;var h=t+r+i+a+l;return h>>>0}s(tK,"sum64_4_hi");zr.sum64_4_hi=tK;function rK(t,e,r,n,i,o,a,f){var l=e+n+o+f;return l>>>0}s(rK,"sum64_4_lo");zr.sum64_4_lo=rK;function nK(t,e,r,n,i,o,a,f,l,u){var h=0,g=e;g=g+n>>>0,h+=g<e?1:0,g=g+o>>>0,h+=g<o?1:0,g=g+f>>>0,h+=g<f?1:0,g=g+u>>>0,h+=g<u?1:0;var x=t+r+i+a+l+h;return x>>>0}s(nK,"sum64_5_hi");zr.sum64_5_hi=nK;function iK(t,e,r,n,i,o,a,f,l,u){var h=e+n+o+f+u;return h>>>0}s(iK,"sum64_5_lo");zr.sum64_5_lo=iK;function sK(t,e,r){var n=e<<32-r|t>>>r;return n>>>0}s(sK,"rotr64_hi");zr.rotr64_hi=sK;function oK(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}s(oK,"rotr64_lo");zr.rotr64_lo=oK;function aK(t,e,r){return t>>>r}s(aK,"shr64_hi");zr.shr64_hi=aK;function cK(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}s(cK,"shr64_lo");zr.shr64_lo=cK});var ed=an(TI=>{"use strict";var kI=Io(),fK=Qu();function Ug(){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}s(Ug,"BlockHash");TI.BlockHash=Ug;Ug.prototype.update=s(function(e,r){if(e=kI.toArray(e,r),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){e=this.pending;var n=e.length%this._delta8;this.pending=e.slice(e.length-n,e.length),this.pending.length===0&&(this.pending=null),e=kI.join32(e,0,e.length-n,this.endian);for(var i=0;i<e.length;i+=this._delta32)this._update(e,i,i+this._delta32)}return this},"update");Ug.prototype.digest=s(function(e){return this.update(this._pad()),fK(this.pending===null),this._digest(e)},"digest");Ug.prototype._pad=s(function(){var e=this.pendingTotal,r=this._delta8,n=r-(e+this.padLength)%r,i=new Array(n+this.padLength);i[0]=128;for(var o=1;o<n;o++)i[o]=0;if(e<<=3,this.endian==="big"){for(var a=8;a<this.padLength;a++)i[o++]=0;i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=e>>>24&255,i[o++]=e>>>16&255,i[o++]=e>>>8&255,i[o++]=e&255}else for(i[o++]=e&255,i[o++]=e>>>8&255,i[o++]=e>>>16&255,i[o++]=e>>>24&255,i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=0,a=8;a<this.padLength;a++)i[o++]=0;return i},"pad")});var D3=an(yc=>{"use strict";var lK=Io(),wa=lK.rotr32;function uK(t,e,r,n){if(t===0)return MI(e,r,n);if(t===1||t===3)return BI(e,r,n);if(t===2)return RI(e,r,n)}s(uK,"ft_1");yc.ft_1=uK;function MI(t,e,r){return t&e^~t&r}s(MI,"ch32");yc.ch32=MI;function RI(t,e,r){return t&e^t&r^e&r}s(RI,"maj32");yc.maj32=RI;function BI(t,e,r){return t^e^r}s(BI,"p32");yc.p32=BI;function dK(t){return wa(t,2)^wa(t,13)^wa(t,22)}s(dK,"s0_256");yc.s0_256=dK;function hK(t){return wa(t,6)^wa(t,11)^wa(t,25)}s(hK,"s1_256");yc.s1_256=hK;function pK(t){return wa(t,7)^wa(t,18)^t>>>3}s(pK,"g0_256");yc.g0_256=pK;function mK(t){return wa(t,17)^wa(t,19)^t>>>10}s(mK,"g1_256");yc.g1_256=mK});var OI=an((afe,PI)=>{"use strict";var td=Io(),gK=ed(),bK=D3(),P3=td.rotl32,Z0=td.sum32,vK=td.sum32_5,yK=bK.ft_1,DI=gK.BlockHash,xK=[1518500249,1859775393,2400959708,3395469782];function _a(){if(!(this instanceof _a))return new _a;DI.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}s(_a,"SHA1");td.inherits(_a,DI);PI.exports=_a;_a.blockSize=512;_a.outSize=160;_a.hmacStrength=80;_a.padLength=64;_a.prototype._update=s(function(e,r){for(var n=this.W,i=0;i<16;i++)n[i]=e[r+i];for(;i<n.length;i++)n[i]=P3(n[i-3]^n[i-8]^n[i-14]^n[i-16],1);var o=this.h[0],a=this.h[1],f=this.h[2],l=this.h[3],u=this.h[4];for(i=0;i<n.length;i++){var h=~~(i/20),g=vK(P3(o,5),yK(h,a,f,l),u,n[i],xK[h]);u=l,l=f,f=P3(a,30),a=o,o=g}this.h[0]=Z0(this.h[0],o),this.h[1]=Z0(this.h[1],a),this.h[2]=Z0(this.h[2],f),this.h[3]=Z0(this.h[3],l),this.h[4]=Z0(this.h[4],u)},"_update");_a.prototype._digest=s(function(e){return e==="hex"?td.toHex32(this.h,"big"):td.split32(this.h,"big")},"digest")});var O3=an((cfe,NI)=>{"use strict";var rd=Io(),wK=ed(),nd=D3(),_K=Qu(),ko=rd.sum32,AK=rd.sum32_4,EK=rd.sum32_5,CK=nd.ch32,SK=nd.maj32,IK=nd.s0_256,kK=nd.s1_256,TK=nd.g0_256,MK=nd.g1_256,FI=wK.BlockHash,RK=[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 Aa(){if(!(this instanceof Aa))return new Aa;FI.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=RK,this.W=new Array(64)}s(Aa,"SHA256");rd.inherits(Aa,FI);NI.exports=Aa;Aa.blockSize=512;Aa.outSize=256;Aa.hmacStrength=192;Aa.padLength=64;Aa.prototype._update=s(function(e,r){for(var n=this.W,i=0;i<16;i++)n[i]=e[r+i];for(;i<n.length;i++)n[i]=AK(MK(n[i-2]),n[i-7],TK(n[i-15]),n[i-16]);var o=this.h[0],a=this.h[1],f=this.h[2],l=this.h[3],u=this.h[4],h=this.h[5],g=this.h[6],x=this.h[7];for(_K(this.k.length===n.length),i=0;i<n.length;i++){var _=EK(x,kK(u),CK(u,h,g),this.k[i],n[i]),E=ko(IK(o),SK(o,a,f));x=g,g=h,h=u,u=ko(l,_),l=f,f=a,a=o,o=ko(_,E)}this.h[0]=ko(this.h[0],o),this.h[1]=ko(this.h[1],a),this.h[2]=ko(this.h[2],f),this.h[3]=ko(this.h[3],l),this.h[4]=ko(this.h[4],u),this.h[5]=ko(this.h[5],h),this.h[6]=ko(this.h[6],g),this.h[7]=ko(this.h[7],x)},"_update");Aa.prototype._digest=s(function(e){return e==="hex"?rd.toHex32(this.h,"big"):rd.split32(this.h,"big")},"digest")});var jI=an((ffe,UI)=>{"use strict";var F3=Io(),LI=O3();function xc(){if(!(this instanceof xc))return new xc;LI.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}s(xc,"SHA224");F3.inherits(xc,LI);UI.exports=xc;xc.blockSize=512;xc.outSize=224;xc.hmacStrength=192;xc.padLength=64;xc.prototype._digest=s(function(e){return e==="hex"?F3.toHex32(this.h.slice(0,7),"big"):F3.split32(this.h.slice(0,7),"big")},"digest")});var U3=an((lfe,$I)=>{"use strict";var us=Io(),BK=ed(),DK=Qu(),Ea=us.rotr64_hi,Ca=us.rotr64_lo,qI=us.shr64_hi,HI=us.shr64_lo,Cf=us.sum64,N3=us.sum64_hi,L3=us.sum64_lo,PK=us.sum64_4_hi,OK=us.sum64_4_lo,FK=us.sum64_5_hi,NK=us.sum64_5_lo,zI=BK.BlockHash,LK=[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 To(){if(!(this instanceof To))return new To;zI.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=LK,this.W=new Array(160)}s(To,"SHA512");us.inherits(To,zI);$I.exports=To;To.blockSize=1024;To.outSize=512;To.hmacStrength=192;To.padLength=128;To.prototype._prepareBlock=s(function(e,r){for(var n=this.W,i=0;i<32;i++)n[i]=e[r+i];for(;i<n.length;i+=2){var o=JK(n[i-4],n[i-3]),a=YK(n[i-4],n[i-3]),f=n[i-14],l=n[i-13],u=VK(n[i-30],n[i-29]),h=WK(n[i-30],n[i-29]),g=n[i-32],x=n[i-31];n[i]=PK(o,a,f,l,u,h,g,x),n[i+1]=OK(o,a,f,l,u,h,g,x)}},"_prepareBlock");To.prototype._update=s(function(e,r){this._prepareBlock(e,r);var n=this.W,i=this.h[0],o=this.h[1],a=this.h[2],f=this.h[3],l=this.h[4],u=this.h[5],h=this.h[6],g=this.h[7],x=this.h[8],_=this.h[9],E=this.h[10],T=this.h[11],B=this.h[12],F=this.h[13],H=this.h[14],U=this.h[15];DK(this.k.length===n.length);for(var q=0;q<n.length;q+=2){var K=H,W=U,N=GK(x,_),G=KK(x,_),ce=UK(x,_,E,T,B,F),re=jK(x,_,E,T,B,F),ae=this.k[q],J=this.k[q+1],S=n[q],m=n[q+1],b=FK(K,W,N,G,ce,re,ae,J,S,m),p=NK(K,W,N,G,ce,re,ae,J,S,m);K=zK(i,o),W=$K(i,o),N=qK(i,o,a,f,l,u),G=HK(i,o,a,f,l,u);var v=N3(K,W,N,G),C=L3(K,W,N,G);H=B,U=F,B=E,F=T,E=x,T=_,x=N3(h,g,b,p),_=L3(g,g,b,p),h=l,g=u,l=a,u=f,a=i,f=o,i=N3(b,p,v,C),o=L3(b,p,v,C)}Cf(this.h,0,i,o),Cf(this.h,2,a,f),Cf(this.h,4,l,u),Cf(this.h,6,h,g),Cf(this.h,8,x,_),Cf(this.h,10,E,T),Cf(this.h,12,B,F),Cf(this.h,14,H,U)},"_update");To.prototype._digest=s(function(e){return e==="hex"?us.toHex32(this.h,"big"):us.split32(this.h,"big")},"digest");function UK(t,e,r,n,i){var o=t&r^~t&i;return o<0&&(o+=4294967296),o}s(UK,"ch64_hi");function jK(t,e,r,n,i,o){var a=e&n^~e&o;return a<0&&(a+=4294967296),a}s(jK,"ch64_lo");function qK(t,e,r,n,i){var o=t&r^t&i^r&i;return o<0&&(o+=4294967296),o}s(qK,"maj64_hi");function HK(t,e,r,n,i,o){var a=e&n^e&o^n&o;return a<0&&(a+=4294967296),a}s(HK,"maj64_lo");function zK(t,e){var r=Ea(t,e,28),n=Ea(e,t,2),i=Ea(e,t,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(zK,"s0_512_hi");function $K(t,e){var r=Ca(t,e,28),n=Ca(e,t,2),i=Ca(e,t,7),o=r^n^i;return o<0&&(o+=4294967296),o}s($K,"s0_512_lo");function GK(t,e){var r=Ea(t,e,14),n=Ea(t,e,18),i=Ea(e,t,9),o=r^n^i;return o<0&&(o+=4294967296),o}s(GK,"s1_512_hi");function KK(t,e){var r=Ca(t,e,14),n=Ca(t,e,18),i=Ca(e,t,9),o=r^n^i;return o<0&&(o+=4294967296),o}s(KK,"s1_512_lo");function VK(t,e){var r=Ea(t,e,1),n=Ea(t,e,8),i=qI(t,e,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(VK,"g0_512_hi");function WK(t,e){var r=Ca(t,e,1),n=Ca(t,e,8),i=HI(t,e,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(WK,"g0_512_lo");function JK(t,e){var r=Ea(t,e,19),n=Ea(e,t,29),i=qI(t,e,6),o=r^n^i;return o<0&&(o+=4294967296),o}s(JK,"g1_512_hi");function YK(t,e){var r=Ca(t,e,19),n=Ca(e,t,29),i=HI(t,e,6),o=r^n^i;return o<0&&(o+=4294967296),o}s(YK,"g1_512_lo")});var VI=an((ufe,KI)=>{"use strict";var j3=Io(),GI=U3();function wc(){if(!(this instanceof wc))return new wc;GI.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}s(wc,"SHA384");j3.inherits(wc,GI);KI.exports=wc;wc.blockSize=1024;wc.outSize=384;wc.hmacStrength=192;wc.padLength=128;wc.prototype._digest=s(function(e){return e==="hex"?j3.toHex32(this.h.slice(0,12),"big"):j3.split32(this.h.slice(0,12),"big")},"digest")});var WI=an(id=>{"use strict";id.sha1=OI();id.sha224=jI();id.sha256=O3();id.sha384=VI();id.sha512=U3()});var ek=an(QI=>{"use strict";var Bl=Io(),ZK=ed(),jg=Bl.rotl32,JI=Bl.sum32,X0=Bl.sum32_3,YI=Bl.sum32_4,XI=ZK.BlockHash;function Sa(){if(!(this instanceof Sa))return new Sa;XI.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}s(Sa,"RIPEMD160");Bl.inherits(Sa,XI);QI.ripemd160=Sa;Sa.blockSize=512;Sa.outSize=160;Sa.hmacStrength=192;Sa.padLength=64;Sa.prototype._update=s(function(e,r){for(var n=this.h[0],i=this.h[1],o=this.h[2],a=this.h[3],f=this.h[4],l=n,u=i,h=o,g=a,x=f,_=0;_<80;_++){var E=JI(jg(YI(n,ZI(_,i,o,a),e[eV[_]+r],XK(_)),rV[_]),f);n=f,f=a,a=jg(o,10),o=i,i=E,E=JI(jg(YI(l,ZI(79-_,u,h,g),e[tV[_]+r],QK(_)),nV[_]),x),l=x,x=g,g=jg(h,10),h=u,u=E}E=X0(this.h[1],o,g),this.h[1]=X0(this.h[2],a,x),this.h[2]=X0(this.h[3],f,l),this.h[3]=X0(this.h[4],n,u),this.h[4]=X0(this.h[0],i,h),this.h[0]=E},"update");Sa.prototype._digest=s(function(e){return e==="hex"?Bl.toHex32(this.h,"little"):Bl.split32(this.h,"little")},"digest");function ZI(t,e,r,n){return t<=15?e^r^n:t<=31?e&r|~e&n:t<=47?(e|~r)^n:t<=63?e&n|r&~n:e^(r|~n)}s(ZI,"f");function XK(t){return t<=15?0:t<=31?1518500249:t<=47?1859775393:t<=63?2400959708:2840853838}s(XK,"K");function QK(t){return t<=15?1352829926:t<=31?1548603684:t<=47?1836072691:t<=63?2053994217:0}s(QK,"Kh");var eV=[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],tV=[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],rV=[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],nV=[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]});var rk=an((pfe,tk)=>{"use strict";var iV=Io(),sV=Qu();function sd(t,e,r){if(!(this instanceof sd))return new sd(t,e,r);this.Hash=t,this.blockSize=t.blockSize/8,this.outSize=t.outSize/8,this.inner=null,this.outer=null,this._init(iV.toArray(e,r))}s(sd,"Hmac");tk.exports=sd;sd.prototype._init=s(function(e){e.length>this.blockSize&&(e=new this.Hash().update(e).digest()),sV(e.length<=this.blockSize);for(var r=e.length;r<this.blockSize;r++)e.push(0);for(r=0;r<e.length;r++)e[r]^=54;for(this.inner=new this.Hash().update(e),r=0;r<e.length;r++)e[r]^=106;this.outer=new this.Hash().update(e)},"init");sd.prototype.update=s(function(e,r){return this.inner.update(e,r),this},"update");sd.prototype.digest=s(function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},"digest")});var q3=an(nk=>{var ni=nk;ni.utils=Io();ni.common=ed();ni.sha=WI();ni.ripemd=ek();ni.hmac=rk();ni.sha1=ni.sha.sha1;ni.sha256=ni.sha.sha256;ni.sha224=ni.sha.sha224;ni.sha384=ni.sha.sha384;ni.sha512=ni.sha.sha512;ni.ripemd160=ni.ripemd.ripemd160});var i4=an((n4,Rk)=>{"use strict";(function(t){function e(I){return parseInt(I)===I}s(e,"checkInt");function r(I){if(!e(I.length))return!1;for(var k=0;k<I.length;k++)if(!e(I[k])||I[k]<0||I[k]>255)return!1;return!0}s(r,"checkInts");function n(I,k){if(I.buffer&&ArrayBuffer.isView(I)&&I.name==="Uint8Array")return k&&(I.slice?I=I.slice():I=Array.prototype.slice.call(I)),I;if(Array.isArray(I)){if(!r(I))throw new Error("Array contains invalid value: "+I);return new Uint8Array(I)}if(e(I.length)&&r(I))return new Uint8Array(I);throw new Error("unsupported array-like object")}s(n,"coerceArray");function i(I){return new Uint8Array(I)}s(i,"createArray");function o(I,k,w,A,R){(A!=null||R!=null)&&(I.slice?I=I.slice(A,R):I=Array.prototype.slice.call(I,A,R)),k.set(I,w)}s(o,"copyArray");var a=function(){function I(w){var A=[],R=0;for(w=encodeURI(w);R<w.length;){var D=w.charCodeAt(R++);D===37?(A.push(parseInt(w.substr(R,2),16)),R+=2):A.push(D)}return n(A)}s(I,"toBytes");function k(w){for(var A=[],R=0;R<w.length;){var D=w[R];D<128?(A.push(String.fromCharCode(D)),R++):D>191&&D<224?(A.push(String.fromCharCode((D&31)<<6|w[R+1]&63)),R+=2):(A.push(String.fromCharCode((D&15)<<12|(w[R+1]&63)<<6|w[R+2]&63)),R+=3)}return A.join("")}return s(k,"fromBytes"),{toBytes:I,fromBytes:k}}(),f=function(){function I(A){for(var R=[],D=0;D<A.length;D+=2)R.push(parseInt(A.substr(D,2),16));return R}s(I,"toBytes");var k="0123456789abcdef";function w(A){for(var R=[],D=0;D<A.length;D++){var M=A[D];R.push(k[(M&240)>>4]+k[M&15])}return R.join("")}return s(w,"fromBytes"),{toBytes:I,fromBytes:w}}(),l={16:10,24:12,32:14},u=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],h=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],g=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],x=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],_=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],E=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],T=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],B=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],F=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],H=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],U=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],q=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],K=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],W=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],N=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function G(I){for(var k=[],w=0;w<I.length;w+=4)k.push(I[w]<<24|I[w+1]<<16|I[w+2]<<8|I[w+3]);return k}s(G,"convertToInt32");var ce=s(function(I){if(!(this instanceof ce))throw Error("AES must be instanitated with `new`");Object.defineProperty(this,"key",{value:n(I,!0)}),this._prepare()},"AES");ce.prototype._prepare=function(){var I=l[this.key.length];if(I==null)throw new Error("invalid key size (must be 16, 24 or 32 bytes)");this._Ke=[],this._Kd=[];for(var k=0;k<=I;k++)this._Ke.push([0,0,0,0]),this._Kd.push([0,0,0,0]);for(var w=(I+1)*4,A=this.key.length/4,R=G(this.key),D,k=0;k<A;k++)D=k>>2,this._Ke[D][k%4]=R[k],this._Kd[I-D][k%4]=R[k];for(var M=0,te=A,L;te<w;){if(L=R[A-1],R[0]^=h[L>>16&255]<<24^h[L>>8&255]<<16^h[L&255]<<8^h[L>>24&255]^u[M]<<24,M+=1,A!=8)for(var k=1;k<A;k++)R[k]^=R[k-1];else{for(var k=1;k<A/2;k++)R[k]^=R[k-1];L=R[A/2-1],R[A/2]^=h[L&255]^h[L>>8&255]<<8^h[L>>16&255]<<16^h[L>>24&255]<<24;for(var k=A/2+1;k<A;k++)R[k]^=R[k-1]}for(var k=0,Y,Z;k<A&&te<w;)Y=te>>2,Z=te%4,this._Ke[Y][Z]=R[k],this._Kd[I-Y][Z]=R[k++],te++}for(var Y=1;Y<I;Y++)for(var Z=0;Z<4;Z++)L=this._Kd[Y][Z],this._Kd[Y][Z]=q[L>>24&255]^K[L>>16&255]^W[L>>8&255]^N[L&255]},ce.prototype.encrypt=function(I){if(I.length!=16)throw new Error("invalid plaintext size (must be 16 bytes)");for(var k=this._Ke.length-1,w=[0,0,0,0],A=G(I),R=0;R<4;R++)A[R]^=this._Ke[0][R];for(var D=1;D<k;D++){for(var R=0;R<4;R++)w[R]=x[A[R]>>24&255]^_[A[(R+1)%4]>>16&255]^E[A[(R+2)%4]>>8&255]^T[A[(R+3)%4]&255]^this._Ke[D][R];A=w.slice()}for(var M=i(16),te,R=0;R<4;R++)te=this._Ke[k][R],M[4*R]=(h[A[R]>>24&255]^te>>24)&255,M[4*R+1]=(h[A[(R+1)%4]>>16&255]^te>>16)&255,M[4*R+2]=(h[A[(R+2)%4]>>8&255]^te>>8)&255,M[4*R+3]=(h[A[(R+3)%4]&255]^te)&255;return M},ce.prototype.decrypt=function(I){if(I.length!=16)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var k=this._Kd.length-1,w=[0,0,0,0],A=G(I),R=0;R<4;R++)A[R]^=this._Kd[0][R];for(var D=1;D<k;D++){for(var R=0;R<4;R++)w[R]=B[A[R]>>24&255]^F[A[(R+3)%4]>>16&255]^H[A[(R+2)%4]>>8&255]^U[A[(R+1)%4]&255]^this._Kd[D][R];A=w.slice()}for(var M=i(16),te,R=0;R<4;R++)te=this._Kd[k][R],M[4*R]=(g[A[R]>>24&255]^te>>24)&255,M[4*R+1]=(g[A[(R+3)%4]>>16&255]^te>>16)&255,M[4*R+2]=(g[A[(R+2)%4]>>8&255]^te>>8)&255,M[4*R+3]=(g[A[(R+1)%4]&255]^te)&255;return M};var re=s(function(I){if(!(this instanceof re))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new ce(I)},"ModeOfOperationECB");re.prototype.encrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16)o(I,w,0,A,A+16),w=this._aes.encrypt(w),o(w,k,A);return k},re.prototype.decrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16)o(I,w,0,A,A+16),w=this._aes.decrypt(w),o(w,k,A);return k};var ae=s(function(I,k){if(!(this instanceof ae))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Block Chaining",this.name="cbc",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 bytes)");this._lastCipherblock=n(k,!0),this._aes=new ce(I)},"ModeOfOperationCBC");ae.prototype.encrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16){o(I,w,0,A,A+16);for(var R=0;R<16;R++)w[R]^=this._lastCipherblock[R];this._lastCipherblock=this._aes.encrypt(w),o(this._lastCipherblock,k,A)}return k},ae.prototype.decrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16){o(I,w,0,A,A+16),w=this._aes.decrypt(w);for(var R=0;R<16;R++)k[A+R]=w[R]^this._lastCipherblock[R];o(I,this._lastCipherblock,0,A,A+16)}return k};var J=s(function(I,k,w){if(!(this instanceof J))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Feedback",this.name="cfb",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 size)");w||(w=1),this.segmentSize=w,this._shiftRegister=n(k,!0),this._aes=new ce(I)},"ModeOfOperationCFB");J.prototype.encrypt=function(I){if(I.length%this.segmentSize!=0)throw new Error("invalid plaintext size (must be segmentSize bytes)");for(var k=n(I,!0),w,A=0;A<k.length;A+=this.segmentSize){w=this._aes.encrypt(this._shiftRegister);for(var R=0;R<this.segmentSize;R++)k[A+R]^=w[R];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(k,this._shiftRegister,16-this.segmentSize,A,A+this.segmentSize)}return k},J.prototype.decrypt=function(I){if(I.length%this.segmentSize!=0)throw new Error("invalid ciphertext size (must be segmentSize bytes)");for(var k=n(I,!0),w,A=0;A<k.length;A+=this.segmentSize){w=this._aes.encrypt(this._shiftRegister);for(var R=0;R<this.segmentSize;R++)k[A+R]^=w[R];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(I,this._shiftRegister,16-this.segmentSize,A,A+this.segmentSize)}return k};var S=s(function(I,k){if(!(this instanceof S))throw Error("AES must be instanitated with `new`");if(this.description="Output Feedback",this.name="ofb",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 bytes)");this._lastPrecipher=n(k,!0),this._lastPrecipherIndex=16,this._aes=new ce(I)},"ModeOfOperationOFB");S.prototype.encrypt=function(I){for(var k=n(I,!0),w=0;w<k.length;w++)this._lastPrecipherIndex===16&&(this._lastPrecipher=this._aes.encrypt(this._lastPrecipher),this._lastPrecipherIndex=0),k[w]^=this._lastPrecipher[this._lastPrecipherIndex++];return k},S.prototype.decrypt=S.prototype.encrypt;var m=s(function(I){if(!(this instanceof m))throw Error("Counter must be instanitated with `new`");I!==0&&!I&&(I=1),typeof I=="number"?(this._counter=i(16),this.setValue(I)):this.setBytes(I)},"Counter");m.prototype.setValue=function(I){if(typeof I!="number"||parseInt(I)!=I)throw new Error("invalid counter value (must be an integer)");for(var k=15;k>=0;--k)this._counter[k]=I%256,I=I>>8},m.prototype.setBytes=function(I){if(I=n(I,!0),I.length!=16)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=I},m.prototype.increment=function(){for(var I=15;I>=0;I--)if(this._counter[I]===255)this._counter[I]=0;else{this._counter[I]++;break}};var b=s(function(I,k){if(!(this instanceof b))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",k instanceof m||(k=new m(k)),this._counter=k,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new ce(I)},"ModeOfOperationCTR");b.prototype.encrypt=function(I){for(var k=n(I,!0),w=0;w<k.length;w++)this._remainingCounterIndex===16&&(this._remainingCounter=this._aes.encrypt(this._counter._counter),this._remainingCounterIndex=0,this._counter.increment()),k[w]^=this._remainingCounter[this._remainingCounterIndex++];return k},b.prototype.decrypt=b.prototype.encrypt;function p(I){I=n(I,!0);var k=16-I.length%16,w=i(I.length+k);o(I,w);for(var A=I.length;A<w.length;A++)w[A]=k;return w}s(p,"pkcs7pad");function v(I){if(I=n(I,!0),I.length<16)throw new Error("PKCS#7 invalid length");var k=I[I.length-1];if(k>16)throw new Error("PKCS#7 padding byte out of range");for(var w=I.length-k,A=0;A<k;A++)if(I[w+A]!==k)throw new Error("PKCS#7 invalid padding byte");var R=i(w);return o(I,R,0,0,w),R}s(v,"pkcs7strip");var C={AES:ce,Counter:m,ModeOfOperation:{ecb:re,cbc:ae,cfb:J,ofb:S,ctr:b},utils:{hex:f,utf8:a},padding:{pkcs7:{pad:p,strip:v}},_arrayTest:{coerceArray:n,createArray:i,copyArray:o}};typeof n4<"u"?Rk.exports=C:typeof define=="function"&&define.amd?define(C):(t.aesjs&&(C._aesjs=t.aesjs),t.aesjs=C)})(n4)});var Pk=an((c4,Dk)=>{"use strict";(function(t){function r(_){let E=new Uint32Array([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]),T=1779033703,B=3144134277,F=1013904242,H=2773480762,U=1359893119,q=2600822924,K=528734635,W=1541459225,N=new Uint32Array(64);function G(b){let p=0,v=b.length;for(;v>=64;){let C=T,I=B,k=F,w=H,A=U,R=q,D=K,M=W,te,L,Y,Z,P;for(L=0;L<16;L++)Y=p+L*4,N[L]=(b[Y]&255)<<24|(b[Y+1]&255)<<16|(b[Y+2]&255)<<8|b[Y+3]&255;for(L=16;L<64;L++)te=N[L-2],Z=(te>>>17|te<<32-17)^(te>>>19|te<<32-19)^te>>>10,te=N[L-15],P=(te>>>7|te<<32-7)^(te>>>18|te<<32-18)^te>>>3,N[L]=(Z+N[L-7]|0)+(P+N[L-16]|0)|0;for(L=0;L<64;L++)Z=(((A>>>6|A<<32-6)^(A>>>11|A<<32-11)^(A>>>25|A<<32-25))+(A&R^~A&D)|0)+(M+(E[L]+N[L]|0)|0)|0,P=((C>>>2|C<<32-2)^(C>>>13|C<<32-13)^(C>>>22|C<<32-22))+(C&I^C&k^I&k)|0,M=D,D=R,R=A,A=w+Z|0,w=k,k=I,I=C,C=Z+P|0;T=T+C|0,B=B+I|0,F=F+k|0,H=H+w|0,U=U+A|0,q=q+R|0,K=K+D|0,W=W+M|0,p+=64,v-=64}}s(G,"blocks"),G(_);let ce,re=_.length%64,ae=_.length/536870912|0,J=_.length<<3,S=re<56?56:120,m=_.slice(_.length-re,_.length);for(m.push(128),ce=re+1;ce<S;ce++)m.push(0);return m.push(ae>>>24&255),m.push(ae>>>16&255),m.push(ae>>>8&255),m.push(ae>>>0&255),m.push(J>>>24&255),m.push(J>>>16&255),m.push(J>>>8&255),m.push(J>>>0&255),G(m),[T>>>24&255,T>>>16&255,T>>>8&255,T>>>0&255,B>>>24&255,B>>>16&255,B>>>8&255,B>>>0&255,F>>>24&255,F>>>16&255,F>>>8&255,F>>>0&255,H>>>24&255,H>>>16&255,H>>>8&255,H>>>0&255,U>>>24&255,U>>>16&255,U>>>8&255,U>>>0&255,q>>>24&255,q>>>16&255,q>>>8&255,q>>>0&255,K>>>24&255,K>>>16&255,K>>>8&255,K>>>0&255,W>>>24&255,W>>>16&255,W>>>8&255,W>>>0&255]}s(r,"SHA256");function n(_,E,T){_=_.length<=64?_:r(_);let B=64+E.length+4,F=new Array(B),H=new Array(64),U,q=[];for(U=0;U<64;U++)F[U]=54;for(U=0;U<_.length;U++)F[U]^=_[U];for(U=0;U<E.length;U++)F[64+U]=E[U];for(U=B-4;U<B;U++)F[U]=0;for(U=0;U<64;U++)H[U]=92;for(U=0;U<_.length;U++)H[U]^=_[U];function K(){for(let W=B-1;W>=B-4;W--){if(F[W]++,F[W]<=255)return;F[W]=0}}for(s(K,"incrementCounter");T>=32;)K(),q=q.concat(r(H.concat(r(F)))),T-=32;return T>0&&(K(),q=q.concat(r(H.concat(r(F))).slice(0,T))),q}s(n,"PBKDF2_HMAC_SHA256_OneIter");function i(_,E,T,B,F){let H;for(l(_,(2*T-1)*16,F,0,16),H=0;H<2*T;H++)f(_,H*16,F,16),a(F,B),l(F,0,_,E+H*16,16);for(H=0;H<T;H++)l(_,E+H*2*16,_,H*16,16);for(H=0;H<T;H++)l(_,E+(H*2+1)*16,_,(H+T)*16,16)}s(i,"blockmix_salsa8");function o(_,E){return _<<E|_>>>32-E}s(o,"R");function a(_,E){l(_,0,E,0,16);for(let T=8;T>0;T-=2)E[4]^=o(E[0]+E[12],7),E[8]^=o(E[4]+E[0],9),E[12]^=o(E[8]+E[4],13),E[0]^=o(E[12]+E[8],18),E[9]^=o(E[5]+E[1],7),E[13]^=o(E[9]+E[5],9),E[1]^=o(E[13]+E[9],13),E[5]^=o(E[1]+E[13],18),E[14]^=o(E[10]+E[6],7),E[2]^=o(E[14]+E[10],9),E[6]^=o(E[2]+E[14],13),E[10]^=o(E[6]+E[2],18),E[3]^=o(E[15]+E[11],7),E[7]^=o(E[3]+E[15],9),E[11]^=o(E[7]+E[3],13),E[15]^=o(E[11]+E[7],18),E[1]^=o(E[0]+E[3],7),E[2]^=o(E[1]+E[0],9),E[3]^=o(E[2]+E[1],13),E[0]^=o(E[3]+E[2],18),E[6]^=o(E[5]+E[4],7),E[7]^=o(E[6]+E[5],9),E[4]^=o(E[7]+E[6],13),E[5]^=o(E[4]+E[7],18),E[11]^=o(E[10]+E[9],7),E[8]^=o(E[11]+E[10],9),E[9]^=o(E[8]+E[11],13),E[10]^=o(E[9]+E[8],18),E[12]^=o(E[15]+E[14],7),E[13]^=o(E[12]+E[15],9),E[14]^=o(E[13]+E[12],13),E[15]^=o(E[14]+E[13],18);for(let T=0;T<16;++T)_[T]+=E[T]}s(a,"salsa20_8");function f(_,E,T,B){for(let F=0;F<B;F++)T[F]^=_[E+F]}s(f,"blockxor");function l(_,E,T,B,F){for(;F--;)T[B++]=_[E++]}s(l,"arraycopy");function u(_){if(!_||typeof _.length!="number")return!1;for(let E=0;E<_.length;E++){let T=_[E];if(typeof T!="number"||T%1||T<0||T>=256)return!1}return!0}s(u,"checkBufferish");function h(_,E){if(typeof _!="number"||_%1)throw new Error("invalid "+E);return _}s(h,"ensureInteger");function g(_,E,T,B,F,H,U){if(T=h(T,"N"),B=h(B,"r"),F=h(F,"p"),H=h(H,"dkLen"),T===0||(T&T-1)!==0)throw new Error("N must be power of 2");if(T>2147483647/128/B)throw new Error("N too large");if(B>2147483647/128/F)throw new Error("r too large");if(!u(_))throw new Error("password must be an array or buffer");if(_=Array.prototype.slice.call(_),!u(E))throw new Error("salt must be an array or buffer");E=Array.prototype.slice.call(E);let q=n(_,E,F*128*B),K=new Uint32Array(F*32*B);for(let A=0;A<K.length;A++){let R=A*4;K[A]=(q[R+3]&255)<<24|(q[R+2]&255)<<16|(q[R+1]&255)<<8|(q[R+0]&255)<<0}let W=new Uint32Array(64*B),N=new Uint32Array(32*B*T),G=32*B,ce=new Uint32Array(16),re=new Uint32Array(16),ae=F*T*2,J=0,S=null,m=!1,b=0,p=0,v,C,I=U?parseInt(1e3/B):4294967295,k=typeof setImmediate<"u"?setImmediate:setTimeout,w=s(function(){if(m)return U(new Error("cancelled"),J/ae);let A;switch(b){case 0:C=p*32*B,l(K,C,W,0,G),b=1,v=0;case 1:A=T-v,A>I&&(A=I);for(let D=0;D<A;D++)l(W,0,N,(v+D)*G,G),i(W,G,B,ce,re);if(v+=A,J+=A,U){let D=parseInt(1e3*J/ae);if(D!==S){if(m=U(null,J/ae),m)break;S=D}}if(v<T)break;v=0,b=2;case 2:A=T-v,A>I&&(A=I);for(let D=0;D<A;D++){let M=(2*B-1)*16,te=W[M]&T-1;f(N,te*G,W,G),i(W,G,B,ce,re)}if(v+=A,J+=A,U){let D=parseInt(1e3*J/ae);if(D!==S){if(m=U(null,J/ae),m)break;S=D}}if(v<T)break;if(l(W,0,K,C,G),p++,p<F){b=0;break}q=[];for(let D=0;D<K.length;D++)q.push(K[D]>>0&255),q.push(K[D]>>8&255),q.push(K[D]>>16&255),q.push(K[D]>>24&255);let R=n(_,q,H);return U&&U(null,1,R),R}U&&k(w)},"incrementalSMix");if(!U)for(;;){let A=w();if(A!=null)return A}w()}s(g,"_scrypt");let x={scrypt:function(_,E,T,B,F,H,U){return new Promise(function(q,K){let W=0;U&&U(0),g(_,E,T,B,F,H,function(N,G,ce){if(N)K(N);else if(ce)U&&W!==1&&U(1),q(new Uint8Array(ce));else if(U&&G!==W)return W=G,U(G)})})},syncScrypt:function(_,E,T,B,F,H){return new Uint8Array(g(_,E,T,B,F,H))}};typeof c4<"u"?Dk.exports=x:typeof define=="function"&&define.amd?define(x):t&&(t.scrypt&&(t._scrypt=t.scrypt),t.scrypt=x)})(c4)});var iT=an((nde,nT)=>{"use strict";var ub="qpzry9x8gf2tvdw0s3jn54khce6mua7l",d4={};for(dp=0;dp<ub.length;dp++){if(lb=ub.charAt(dp),d4[lb]!==void 0)throw new TypeError(lb+" is ambiguous");d4[lb]=dp}var lb,dp;function md(t){var e=t>>25;return(t&33554431)<<5^-(e>>0&1)&996825010^-(e>>1&1)&642813549^-(e>>2&1)&513874426^-(e>>3&1)&1027748829^-(e>>4&1)&705979059}s(md,"polymodStep");function tT(t){for(var e=1,r=0;r<t.length;++r){var n=t.charCodeAt(r);if(n<33||n>126)return"Invalid prefix ("+t+")";e=md(e)^n>>5}for(e=md(e),r=0;r<t.length;++r){var i=t.charCodeAt(r);e=md(e)^i&31}return e}s(tT,"prefixChk");function HV(t,e,r){if(r=r||90,t.length+7+e.length>r)throw new TypeError("Exceeds length limit");t=t.toLowerCase();var n=tT(t);if(typeof n=="string")throw new Error(n);for(var i=t+"1",o=0;o<e.length;++o){var a=e[o];if(a>>5!==0)throw new Error("Non 5-bit word");n=md(n)^a,i+=ub.charAt(a)}for(o=0;o<6;++o)n=md(n);for(n^=1,o=0;o<6;++o){var f=n>>(5-o)*5&31;i+=ub.charAt(f)}return i}s(HV,"encode");function rT(t,e){if(e=e||90,t.length<8)return t+" too short";if(t.length>e)return"Exceeds length limit";var r=t.toLowerCase(),n=t.toUpperCase();if(t!==r&&t!==n)return"Mixed-case string "+t;t=r;var i=t.lastIndexOf("1");if(i===-1)return"No separator character for "+t;if(i===0)return"Missing prefix for "+t;var o=t.slice(0,i),a=t.slice(i+1);if(a.length<6)return"Data too short";var f=tT(o);if(typeof f=="string")return f;for(var l=[],u=0;u<a.length;++u){var h=a.charAt(u),g=d4[h];if(g===void 0)return"Unknown character "+h;f=md(f)^g,!(u+6>=a.length)&&l.push(g)}return f!==1?"Invalid checksum for "+t:{prefix:o,words:l}}s(rT,"__decode");function zV(){var t=rT.apply(null,arguments);if(typeof t=="object")return t}s(zV,"decodeUnsafe");function $V(t){var e=rT.apply(null,arguments);if(typeof e=="object")return e;throw new Error(e)}s($V,"decode");function db(t,e,r,n){for(var i=0,o=0,a=(1<<r)-1,f=[],l=0;l<t.length;++l)for(i=i<<e|t[l],o+=e;o>=r;)o-=r,f.push(i>>o&a);if(n)o>0&&f.push(i<<r-o&a);else{if(o>=e)return"Excess padding";if(i<<r-o&a)return"Non-zero padding"}return f}s(db,"convert");function GV(t){var e=db(t,8,5,!0);if(Array.isArray(e))return e}s(GV,"toWordsUnsafe");function KV(t){var e=db(t,8,5,!0);if(Array.isArray(e))return e;throw new Error(e)}s(KV,"toWords");function VV(t){var e=db(t,5,8,!1);if(Array.isArray(e))return e}s(VV,"fromWordsUnsafe");function WV(t){var e=db(t,5,8,!1);if(Array.isArray(e))return e;throw new Error(e)}s(WV,"fromWords");nT.exports={decodeUnsafe:zV,decode:$V,encode:HV,toWordsUnsafe:GV,toWords:KV,fromWordsUnsafe:VV,fromWords:WV}});var fie={};vl(fie,{getLearnCardNetworkPlugin:()=>Qy,getVerifyBoostPlugin:()=>e3,initNetworkLearnCard:()=>cie});module.exports=VH(fie);function WH(t){return t}s(WH,"identity");function JH(t){return t.length===0?WH:t.length===1?t[0]:s(function(r){return t.reduce((n,i)=>i(n),r)},"piped")}s(JH,"pipeFromArray");function la(t){let e={subscribe(r){let n=null,i=!1,o=!1,a=!1;function f(){if(n===null){a=!0;return}o||(o=!0,typeof n=="function"?n():n&&n.unsubscribe())}return s(f,"unsubscribe"),n=t({next(l){i||r.next?.(l)},error(l){i||(i=!0,r.error?.(l),f())},complete(){i||(i=!0,r.complete?.(),f())}}),a&&f(),{unsubscribe:f}},pipe(...r){return JH(r)(e)}};return e}s(la,"observable");function gC(t){return e=>{let r=0,n=null,i=[];function o(){n||(n=e.subscribe({next(f){for(let l of i)l.next?.(f)},error(f){for(let l of i)l.error?.(f)},complete(){for(let f of i)f.complete?.()}}))}s(o,"startIfNeeded");function a(){if(r===0&&n){let f=n;n=null,f.unsubscribe()}}return s(a,"resetIfNeeded"),{subscribe(f){return r++,i.push(f),o(),{unsubscribe(){r--,a();let l=i.findIndex(u=>u===f);l>-1&&i.splice(l,1)}}}}}}s(gC,"share");var Nu=class extends Error{constructor(e){super(e),this.name="ObservableAbortError",Object.setPrototypeOf(this,Nu.prototype)}};s(Nu,"ObservableAbortError");function bC(t){let e;return{promise:new Promise((n,i)=>{let o=!1;function a(){o||(o=!0,i(new Nu("This operation was aborted.")),f.unsubscribe())}s(a,"onDone");let f=t.subscribe({next(l){o=!0,n(l),a()},error(l){o=!0,i(l),a()},complete(){o=!0,a()}});e=a}),abort:e}}s(bC,"observableToPromise");var Gn=class extends Error{static from(e,r={}){return e instanceof Error?e.name==="TRPCClientError"?e:new Gn(e.message,{...r,cause:e,result:null}):new Gn(e.error.message??"",{...r,cause:void 0,result:e})}constructor(e,r){let n=r?.cause;super(e,{cause:n}),this.meta=r?.meta,this.cause=n,this.shape=r?.result?.error,this.data=r?.result?.error.data,this.name="TRPCClientError",Object.setPrototypeOf(this,Gn.prototype)}};s(Gn,"TRPCClientError");function YH(t,e){if("error"in t){let n=e.transformer.deserialize(t.error);return{ok:!1,error:{...t,error:n}}}let r={...t.result,...(!t.result.type||t.result.type==="data")&&{type:"data",data:e.transformer.deserialize(t.result.data)}};return{ok:!0,result:r}}s(YH,"transformResultInner");function vC(t){return!!t&&!Array.isArray(t)&&typeof t=="object"}s(vC,"isObject");function og(t,e){let r;try{r=YH(t,e)}catch{throw new Gn("Unable to transform response from server")}if(!r.ok&&(!vC(r.error.error)||typeof r.error.error.code!="number"))throw new Gn("Badly formatted response from server");if(r.ok&&!vC(r.result))throw new Gn("Badly formatted response from server");return r}s(og,"transformResult");function yC(t){return la(e=>{function r(i=0,o=t.op){let a=t.links[i];if(!a)throw new Error("No more links to execute - did you forget to add an ending link?");return a({op:o,next(l){return r(i+1,l)}})}return s(r,"execute"),r().subscribe(e)})}s(yC,"createChain");var xC=s(()=>{},"noop");function wC(t,e){return new Proxy(xC,{get(n,i){if(!(typeof i!="string"||i==="then"))return wC(t,[...e,i])},apply(n,i,o){return t({args:o,path:e})}})}s(wC,"createInnerProxy");var jy=s(t=>wC(t,[]),"createRecursiveProxy"),qy=s(t=>new Proxy(xC,{get(e,r){if(!(typeof r!="string"||r==="then"))return t(r)}}),"createFlatProxy");function _C(){return typeof window<"u"?window:globalThis}s(_C,"getWindow");function ZH(t){return t??_C().AbortController??null}s(ZH,"getAbortController");function AC(t){if(t)return t;let e=_C(),r=e.fetch;if(r)return typeof r.bind=="function"?r.bind(e):r;throw new Error("No fetch implementation found")}s(AC,"getFetch");function Hy(t){let e=t.headers||(()=>({}));return{url:t.url,fetch:AC(t.fetch),AbortController:ZH(t.AbortController),headers:typeof e=="function"?e:()=>e}}s(Hy,"resolveHTTPLinkOptions");function XH(t){let e={};for(let r=0;r<t.length;r++){let n=t[r];e[r]=n}return e}s(XH,"arrayToDict");var QH={query:"GET",mutation:"POST"};function EC(t){return"input"in t?t.runtime.transformer.serialize(t.input):XH(t.inputs.map(e=>t.runtime.transformer.serialize(e)))}s(EC,"getInput");function zy(t){let e=t.url+"/"+t.path,r=[];if("inputs"in t&&r.push("batch=1"),t.type==="query"){let n=EC(t);n!==void 0&&r.push(`input=${encodeURIComponent(JSON.stringify(n))}`)}return r.length&&(e+="?"+r.join("&")),e}s(zy,"getUrl");function ez(t){if(t.type==="query")return;let e=EC(t);return e!==void 0?JSON.stringify(e):void 0}s(ez,"getBody");function $y(t){let{type:e}=t,r=t.AbortController?new t.AbortController:null;return{promise:new Promise((o,a)=>{let f=zy(t),l=ez(t),u={};Promise.resolve(t.headers()).then(h=>{if(e==="subscription")throw new Error("Subscriptions should use wsLink");return t.fetch(f,{method:QH[e],signal:r?.signal,body:l,headers:{"content-type":"application/json",...h}})}).then(h=>(u.response=h,h.json())).then(h=>{o({json:h,meta:u})}).catch(a)}),cancel:s(()=>{r?.abort()},"cancel")}}s($y,"httpRequest");var Gy=s(()=>{throw new Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new")},"throwFatalError");function Ky(t){let e=null,r=null,n=s(()=>{clearTimeout(r),r=null,e=null},"destroyTimerAndPendingItems");function i(f){let l=[[]],u=0;for(;;){let h=f[u];if(!h)break;let g=l[l.length-1];if(h.aborted){h.reject(new Error("Aborted")),u++;continue}if(t.validate(g.concat(h).map(_=>_.key))){g.push(h),u++;continue}if(g.length===0){h.reject(new Error("Input is too big for a single dispatch")),u++;continue}l.push([])}return l}s(i,"groupItems");function o(){let f=i(e);n();for(let l of f){if(!l.length)continue;let u={items:l,cancel:Gy};for(let x of l)x.batch=u;let{promise:h,cancel:g}=t.fetch(u.items.map(x=>x.key));u.cancel=g,h.then(x=>{for(let _=0;_<x.length;_++){let E=x[_],T=u.items[_];T.resolve(E),T.batch=null}}).catch(x=>{for(let _ of u.items)_.reject(x),_.batch=null})}}s(o,"dispatch");function a(f){let l={aborted:!1,key:f,batch:null,resolve:Gy,reject:Gy},u=new Promise((g,x)=>{l.reject=x,l.resolve=g,e||(e=[]),e.push(l)});return r||(r=setTimeout(o)),{promise:u,cancel:s(()=>{l.aborted=!0,l.batch?.items.every(g=>g.aborted)&&(l.batch.cancel(),l.batch=null)},"cancel")}}return s(a,"load"),{load:a}}s(Ky,"dataLoader");function ag(t){let e=Hy(t);return r=>{let n=t.maxURLLength||1/0,i=s(u=>({validate:s(x=>{if(n===1/0)return!0;let _=x.map(B=>B.path).join(","),E=x.map(B=>B.input);return zy({...e,runtime:r,type:u,path:_,inputs:E}).length<=n},"validate"),fetch:s(x=>{let _=x.map(F=>F.path).join(","),E=x.map(F=>F.input),{promise:T,cancel:B}=$y({...e,runtime:r,type:u,path:_,inputs:E});return{promise:T.then(F=>(Array.isArray(F.json)?F.json:x.map(()=>F.json)).map(q=>({meta:F.meta,json:q}))),cancel:B}},"fetch")}),"batchLoader"),o=Ky(i("query")),a=Ky(i("mutation")),f=Ky(i("subscription")),l={query:o,subscription:f,mutation:a};return({op:u})=>la(h=>{let g=l[u.type],{promise:x,cancel:_}=g.load(u);return x.then(E=>{let T=og(E.json,r);if(!T.ok){h.error(Gn.from(T.error,{meta:E.meta}));return}h.next({context:E.meta,result:T.result}),h.complete()}).catch(E=>h.error(Gn.from(E))),()=>{_()}})}}s(ag,"httpBatchLink");var cg=class{$request({type:e,input:r,path:n,context:i={}}){return yC({links:this.links,op:{id:++this.requestId,type:e,path:n,input:r,context:i}}).pipe(gC())}requestAsPromise(e){let r=this.$request(e),{promise:n,abort:i}=bC(r);return new Promise((a,f)=>{e.signal?.addEventListener("abort",i),n.then(l=>{a(l.result.data)}).catch(l=>{f(Gn.from(l))})})}query(e,r,n){return this.requestAsPromise({type:"query",path:e,input:r,context:n?.context,signal:n?.signal})}mutation(e,r,n){return this.requestAsPromise({type:"mutation",path:e,input:r,context:n?.context,signal:n?.signal})}subscription(e,r,n){return this.$request({type:"subscription",path:e,input:r,context:n?.context}).subscribe({next(o){o.result.type==="started"?n.onStarted?.():o.result.type==="stopped"?n.onStopped?.():n.onData?.(o.result.data)},error(o){n.onError?.(o)},complete(){n.onComplete?.()}})}constructor(e){this.requestId=0;function r(){let n=e.transformer;return n?"input"in n?{serialize:n.input.serialize,deserialize:n.output.deserialize}:n:{serialize:i=>i,deserialize:i=>i}}s(r,"getTransformer"),this.runtime={transformer:r()},this.links=e.links.map(n=>n(this.runtime))}};s(cg,"TRPCUntypedClient");var tz={query:"query",mutate:"mutation",subscribe:"subscription"};function rz(t){return qy(e=>t.hasOwnProperty(e)?t[e]:jy(({path:r,args:n})=>{let i=[e,...r],o=i.pop(),a=tz[o],f=i.join(".");return t[a](f,...n)}))}s(rz,"createTRPCClientProxy");function Vy(t){let e=new cg(t);return rz(e)}s(Vy,"createTRPCProxyClient");var nz=Object.defineProperty,fg=s((t,e)=>nz(t,"name",{value:e,configurable:!0}),"__name"),iz=fg(t=>()=>({next:e,op:r})=>la(n=>{let i=null,o=0,a=!1,f=fg(()=>{o+=1,i?.unsubscribe(),i=e(r).subscribe({error:async l=>{if(o>5||l.data?.httpStatus!==401)return n.error(l);await t(),f()},next:l=>n.next(l),complete:()=>{a&&n.complete()}})},"attempt");return f(),()=>{a=!0,i?.unsubscribe()}}),"callbackLink"),CC=fg(async(t,e)=>{let r=[],n=Vy({links:[ag({url:t,headers:{Authorization:`Bearer ${await e()}`}})]}),i=fg(async(a=95+Math.round((Math.random()-.5)*5))=>n.utilities.getChallenges.query({amount:a}),"getChallenges");return r=await i(),Vy({links:[iz(async()=>{r=await i()}),ag({url:t,headers:async()=>(r.length===0&&r.push(...await i()),{Authorization:`Bearer ${await e(r.pop())}`})})]})},"getClient");var Mr;(function(t){t.assertEqual=i=>i;function e(i){}s(e,"assertIs"),t.assertIs=e;function r(i){throw new Error}s(r,"assertNever"),t.assertNever=r,t.arrayToEnum=i=>{let o={};for(let a of i)o[a]=a;return o},t.getValidEnumValues=i=>{let o=t.objectKeys(i).filter(f=>typeof i[i[f]]!="number"),a={};for(let f of o)a[f]=i[f];return t.objectValues(a)},t.objectValues=i=>t.objectKeys(i).map(function(o){return i[o]}),t.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{let o=[];for(let a in i)Object.prototype.hasOwnProperty.call(i,a)&&o.push(a);return o},t.find=(i,o)=>{for(let a of i)if(o(a))return a},t.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function n(i,o=" | "){return i.map(a=>typeof a=="string"?`'${a}'`:a).join(o)}s(n,"joinValues"),t.joinValues=n,t.jsonStringifyReplacer=(i,o)=>typeof o=="bigint"?o.toString():o})(Mr||(Mr={}));var yt=Mr.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),sf=s(t=>{switch(typeof t){case"undefined":return yt.undefined;case"string":return yt.string;case"number":return isNaN(t)?yt.nan:yt.number;case"boolean":return yt.boolean;case"function":return yt.function;case"bigint":return yt.bigint;case"symbol":return yt.symbol;case"object":return Array.isArray(t)?yt.array:t===null?yt.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?yt.promise:typeof Map<"u"&&t instanceof Map?yt.map:typeof Set<"u"&&t instanceof Set?yt.set:typeof Date<"u"&&t instanceof Date?yt.date:yt.object;default:return yt.unknown}},"getParsedType"),nt=Mr.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"]),sz=s(t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),"quotelessJson"),Ys=class extends Error{constructor(e){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};let r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){let r=e||function(o){return o.message},n={_errors:[]},i=s(o=>{for(let a of o.issues)if(a.code==="invalid_union")a.unionErrors.map(i);else if(a.code==="invalid_return_type")i(a.returnTypeError);else if(a.code==="invalid_arguments")i(a.argumentsError);else if(a.path.length===0)n._errors.push(r(a));else{let f=n,l=0;for(;l<a.path.length;){let u=a.path[l];l===a.path.length-1?(f[u]=f[u]||{_errors:[]},f[u]._errors.push(r(a))):f[u]=f[u]||{_errors:[]},f=f[u],l++}}},"processError");return i(this),n}toString(){return this.message}get message(){return JSON.stringify(this.issues,Mr.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=r=>r.message){let r={},n=[];for(let i of this.issues)i.path.length>0?(r[i.path[0]]=r[i.path[0]]||[],r[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:r}}get formErrors(){return this.flatten()}};s(Ys,"ZodError");Ys.create=t=>new Ys(t);var w0=s((t,e)=>{let r;switch(t.code){case nt.invalid_type:t.received===yt.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case nt.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,Mr.jsonStringifyReplacer)}`;break;case nt.unrecognized_keys:r=`Unrecognized key(s) in object: ${Mr.joinValues(t.keys,", ")}`;break;case nt.invalid_union:r="Invalid input";break;case nt.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${Mr.joinValues(t.options)}`;break;case nt.invalid_enum_value:r=`Invalid enum value. Expected ${Mr.joinValues(t.options)}, received '${t.received}'`;break;case nt.invalid_arguments:r="Invalid function arguments";break;case nt.invalid_return_type:r="Invalid function return type";break;case nt.invalid_date:r="Invalid date";break;case nt.invalid_string:typeof t.validation=="object"?"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:Mr.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case nt.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(t.minimum)}`:r="Invalid input";break;case nt.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(t.maximum)}`:r="Invalid input";break;case nt.custom:r="Invalid input";break;case nt.invalid_intersection_types:r="Intersection results could not be merged";break;case nt.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case nt.not_finite:r="Number must be finite";break;default:r=e.defaultError,Mr.assertNever(t)}return{message:r}},"errorMap"),kC=w0;function oz(t){kC=t}s(oz,"setErrorMap");function ug(){return kC}s(ug,"getErrorMap");var dg=s(t=>{let{data:e,path:r,errorMaps:n,issueData:i}=t,o=[...r,...i.path||[]],a={...i,path:o},f="",l=n.filter(u=>!!u).slice().reverse();for(let u of l)f=u(a,{data:e,defaultError:f}).message;return{...i,path:o,message:i.message||f}},"makeIssue"),az=[];function kt(t,e){let r=dg({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,ug(),w0].filter(n=>!!n)});t.common.issues.push(r)}s(kt,"addIssueToContext");var Kn=class{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,r){let n=[];for(let i of r){if(i.status==="aborted")return zt;i.status==="dirty"&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,r){let n=[];for(let i of r)n.push({key:await i.key,value:await i.value});return Kn.mergeObjectSync(e,n)}static mergeObjectSync(e,r){let n={};for(let i of r){let{key:o,value:a}=i;if(o.status==="aborted"||a.status==="aborted")return zt;o.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),(typeof a.value<"u"||i.alwaysSet)&&(n[o.value]=a.value)}return{status:e.value,value:n}}};s(Kn,"ParseStatus");var zt=Object.freeze({status:"aborted"}),TC=s(t=>({status:"dirty",value:t}),"DIRTY"),Ai=s(t=>({status:"valid",value:t}),"OK"),Wy=s(t=>t.status==="aborted","isAborted"),Jy=s(t=>t.status==="dirty","isDirty"),hg=s(t=>t.status==="valid","isValid"),pg=s(t=>typeof Promise<"u"&&t instanceof Promise,"isAsync"),pr;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(pr||(pr={}));var Ss=class{constructor(e,r,n,i){this.parent=e,this.data=r,this._path=n,this._key=i}get path(){return this._path.concat(this._key)}};s(Ss,"ParseInputLazyPath");var SC=s((t,e)=>{if(hg(e))return{success:!0,data:e.value};{if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");let r=new Ys(t.common.issues);return{success:!1,error:r}}},"handleResult");function nr(t){if(!t)return{};let{errorMap:e,invalid_type_error:r,required_error:n,description:i}=t;if(e&&(r||n))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:i}:{errorMap:s((a,f)=>a.code!=="invalid_type"?{message:f.defaultError}:typeof f.data>"u"?{message:n??f.defaultError}:{message:r??f.defaultError},"customMap"),description:i}}s(nr,"processCreateParams");var Xt=class{constructor(e){this.spa=this.safeParseAsync,this._def=e,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.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return sf(e.data)}_getOrReturnCtx(e,r){return r||{common:e.parent.common,data:e.data,parsedType:sf(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new Kn,ctx:{common:e.parent.common,data:e.data,parsedType:sf(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let r=this._parse(e);if(pg(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(e){let r=this._parse(e);return Promise.resolve(r)}parse(e,r){let n=this.safeParse(e,r);if(n.success)return n.data;throw n.error}safeParse(e,r){var n;let i={common:{issues:[],async:(n=r?.async)!==null&&n!==void 0?n:!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:sf(e)},o=this._parseSync({data:e,path:i.path,parent:i});return SC(i,o)}async parseAsync(e,r){let n=await this.safeParseAsync(e,r);if(n.success)return n.data;throw n.error}async safeParseAsync(e,r){let n={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:sf(e)},i=this._parse({data:e,path:n.path,parent:n}),o=await(pg(i)?i:Promise.resolve(i));return SC(n,o)}refine(e,r){let n=s(i=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(i):r,"getIssueProperties");return this._refinement((i,o)=>{let a=e(i),f=s(()=>o.addIssue({code:nt.custom,...n(i)}),"setError");return typeof Promise<"u"&&a instanceof Promise?a.then(l=>l?!0:(f(),!1)):a?!0:(f(),!1)})}refinement(e,r){return this._refinement((n,i)=>e(n)?!0:(i.addIssue(typeof r=="function"?r(n,i):r),!1))}_refinement(e){return new os({schema:this,typeName:jt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return Qs.create(this,this._def)}nullable(){return pa.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return ss.create(this,this._def)}promise(){return lc.create(this,this._def)}or(e){return lf.create([this,e],this._def)}and(e){return uf.create(this,e,this._def)}transform(e){return new os({...nr(this._def),schema:this,typeName:jt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let r=typeof e=="function"?e:()=>e;return new gf({...nr(this._def),innerType:this,defaultValue:r,typeName:jt.ZodDefault})}brand(){return new x0({typeName:jt.ZodBranded,type:this,...nr(this._def)})}catch(e){let r=typeof e=="function"?e:()=>e;return new Al({...nr(this._def),innerType:this,catchValue:r,typeName:jt.ZodCatch})}describe(e){let r=this.constructor;return new r({...this._def,description:e})}pipe(e){return bf.create(this,e)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}};s(Xt,"ZodType");var cz=/^c[^\s-]{8,}$/i,fz=/^[a-z][a-z0-9]*$/,lz=/^([a-f0-9]{8}-[a-f0-9]{4}-[1-5][a-f0-9]{3}-[a-f0-9]{4}-[a-f0-9]{12}|00000000-0000-0000-0000-000000000000)$/i,uz=/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|([^-]([a-zA-Z0-9-]*\.)+[a-zA-Z]{2,}))$/,dz=s(t=>t.precision?t.offset?new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${t.precision}}(([+-]\\d{2}(:?\\d{2})?)|Z)$`):new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${t.precision}}Z$`):t.precision===0?t.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$"):t.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?Z$"),"datetimeRegex"),Zs=class extends Xt{constructor(){super(...arguments),this._regex=(e,r,n)=>this.refinement(i=>e.test(i),{validation:r,code:nt.invalid_string,...pr.errToObj(n)}),this.nonempty=e=>this.min(1,pr.errToObj(e)),this.trim=()=>new Zs({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==yt.string){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.string,received:o.parsedType}),zt}let n=new Kn,i;for(let o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="max")e.data.length>o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="length"){let a=e.data.length>o.value,f=e.data.length<o.value;(a||f)&&(i=this._getOrReturnCtx(e,i),a?kt(i,{code:nt.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):f&&kt(i,{code:nt.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),n.dirty())}else if(o.kind==="email")uz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"email",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="uuid")lz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"uuid",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid")cz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"cuid",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid2")fz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"cuid2",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{i=this._getOrReturnCtx(e,i),kt(i,{validation:"url",code:nt.invalid_string,message:o.message}),n.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"regex",code:nt.invalid_string,message:o.message}),n.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="startsWith"?e.data.startsWith(o.value)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:{startsWith:o.value},message:o.message}),n.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:{endsWith:o.value},message:o.message}),n.dirty()):o.kind==="datetime"?dz(o).test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:"datetime",message:o.message}),n.dirty()):Mr.assertNever(o);return{status:n.value,value:e.data}}_addCheck(e){return new Zs({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...pr.errToObj(e)})}url(e){return this._addCheck({kind:"url",...pr.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...pr.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...pr.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...pr.errToObj(e)})}datetime(e){var r;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:(r=e?.offset)!==null&&r!==void 0?r:!1,...pr.errToObj(e?.message)})}regex(e,r){return this._addCheck({kind:"regex",regex:e,...pr.errToObj(r)})}startsWith(e,r){return this._addCheck({kind:"startsWith",value:e,...pr.errToObj(r)})}endsWith(e,r){return this._addCheck({kind:"endsWith",value:e,...pr.errToObj(r)})}min(e,r){return this._addCheck({kind:"min",value:e,...pr.errToObj(r)})}max(e,r){return this._addCheck({kind:"max",value:e,...pr.errToObj(r)})}length(e,r){return this._addCheck({kind:"length",value:e,...pr.errToObj(r)})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get minLength(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxLength(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}};s(Zs,"ZodString");Zs.create=t=>{var e;return new Zs({checks:[],typeName:jt.ZodString,coerce:(e=t?.coerce)!==null&&e!==void 0?e:!1,...nr(t)})};function hz(t,e){let r=(t.toString().split(".")[1]||"").length,n=(e.toString().split(".")[1]||"").length,i=r>n?r:n,o=parseInt(t.toFixed(i).replace(".","")),a=parseInt(e.toFixed(i).replace(".",""));return o%a/Math.pow(10,i)}s(hz,"floatSafeRemainder");var Ao=class extends Xt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==yt.number){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.number,received:o.parsedType}),zt}let n,i=new Kn;for(let o of this._def.checks)o.kind==="int"?Mr.isInteger(e.data)||(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.invalid_type,expected:"integer",received:"float",message:o.message}),i.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="multipleOf"?hz(e.data,o.value)!==0&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.not_finite,message:o.message}),i.dirty()):Mr.assertNever(o);return{status:i.value,value:e.data}}gte(e,r){return this.setLimit("min",e,!0,pr.toString(r))}gt(e,r){return this.setLimit("min",e,!1,pr.toString(r))}lte(e,r){return this.setLimit("max",e,!0,pr.toString(r))}lt(e,r){return this.setLimit("max",e,!1,pr.toString(r))}setLimit(e,r,n,i){return new Ao({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:n,message:pr.toString(i)}]})}_addCheck(e){return new Ao({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:pr.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:pr.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:pr.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:pr.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:pr.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:pr.toString(r)})}finite(e){return this._addCheck({kind:"finite",message:pr.toString(e)})}get minValue(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Mr.isInteger(e.value))}get isFinite(){let e=null,r=null;for(let 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"&&(e===null||n.value<e)&&(e=n.value)}return Number.isFinite(r)&&Number.isFinite(e)}};s(Ao,"ZodNumber");Ao.create=t=>new Ao({checks:[],typeName:jt.ZodNumber,coerce:t?.coerce||!1,...nr(t)});var of=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==yt.bigint){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.bigint,received:n.parsedType}),zt}return Ai(e.data)}};s(of,"ZodBigInt");of.create=t=>{var e;return new of({typeName:jt.ZodBigInt,coerce:(e=t?.coerce)!==null&&e!==void 0?e:!1,...nr(t)})};var af=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=Boolean(e.data)),this._getType(e)!==yt.boolean){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.boolean,received:n.parsedType}),zt}return Ai(e.data)}};s(af,"ZodBoolean");af.create=t=>new af({typeName:jt.ZodBoolean,coerce:t?.coerce||!1,...nr(t)});var ua=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==yt.date){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.date,received:o.parsedType}),zt}if(isNaN(e.data.getTime())){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_date}),zt}let n=new Kn,i;for(let o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),n.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),n.dirty()):Mr.assertNever(o);return{status:n.value,value:new Date(e.data.getTime())}}_addCheck(e){return new ua({...this._def,checks:[...this._def.checks,e]})}min(e,r){return this._addCheck({kind:"min",value:e.getTime(),message:pr.toString(r)})}max(e,r){return this._addCheck({kind:"max",value:e.getTime(),message:pr.toString(r)})}get minDate(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e!=null?new Date(e):null}};s(ua,"ZodDate");ua.create=t=>new ua({checks:[],coerce:t?.coerce||!1,typeName:jt.ZodDate,...nr(t)});var yl=class extends Xt{_parse(e){if(this._getType(e)!==yt.symbol){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.symbol,received:n.parsedType}),zt}return Ai(e.data)}};s(yl,"ZodSymbol");yl.create=t=>new yl({typeName:jt.ZodSymbol,...nr(t)});var cf=class extends Xt{_parse(e){if(this._getType(e)!==yt.undefined){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.undefined,received:n.parsedType}),zt}return Ai(e.data)}};s(cf,"ZodUndefined");cf.create=t=>new cf({typeName:jt.ZodUndefined,...nr(t)});var ff=class extends Xt{_parse(e){if(this._getType(e)!==yt.null){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.null,received:n.parsedType}),zt}return Ai(e.data)}};s(ff,"ZodNull");ff.create=t=>new ff({typeName:jt.ZodNull,...nr(t)});var cc=class extends Xt{constructor(){super(...arguments),this._any=!0}_parse(e){return Ai(e.data)}};s(cc,"ZodAny");cc.create=t=>new cc({typeName:jt.ZodAny,...nr(t)});var da=class extends Xt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Ai(e.data)}};s(da,"ZodUnknown");da.create=t=>new da({typeName:jt.ZodUnknown,...nr(t)});var Xs=class extends Xt{_parse(e){let r=this._getOrReturnCtx(e);return kt(r,{code:nt.invalid_type,expected:yt.never,received:r.parsedType}),zt}};s(Xs,"ZodNever");Xs.create=t=>new Xs({typeName:jt.ZodNever,...nr(t)});var xl=class extends Xt{_parse(e){if(this._getType(e)!==yt.undefined){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.void,received:n.parsedType}),zt}return Ai(e.data)}};s(xl,"ZodVoid");xl.create=t=>new xl({typeName:jt.ZodVoid,...nr(t)});var ss=class extends Xt{_parse(e){let{ctx:r,status:n}=this._processInputParams(e),i=this._def;if(r.parsedType!==yt.array)return kt(r,{code:nt.invalid_type,expected:yt.array,received:r.parsedType}),zt;if(i.exactLength!==null){let a=r.data.length>i.exactLength.value,f=r.data.length<i.exactLength.value;(a||f)&&(kt(r,{code:a?nt.too_big:nt.too_small,minimum:f?i.exactLength.value:void 0,maximum:a?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&&(kt(r,{code:nt.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&&(kt(r,{code:nt.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((a,f)=>i.type._parseAsync(new Ss(r,a,r.path,f)))).then(a=>Kn.mergeArray(n,a));let o=[...r.data].map((a,f)=>i.type._parseSync(new Ss(r,a,r.path,f)));return Kn.mergeArray(n,o)}get element(){return this._def.type}min(e,r){return new ss({...this._def,minLength:{value:e,message:pr.toString(r)}})}max(e,r){return new ss({...this._def,maxLength:{value:e,message:pr.toString(r)}})}length(e,r){return new ss({...this._def,exactLength:{value:e,message:pr.toString(r)}})}nonempty(e){return this.min(1,e)}};s(ss,"ZodArray");ss.create=(t,e)=>new ss({type:t,minLength:null,maxLength:null,exactLength:null,typeName:jt.ZodArray,...nr(e)});var mg;(function(t){t.mergeShapes=(e,r)=>({...e,...r})})(mg||(mg={}));function Lu(t){if(t instanceof Jr){let e={};for(let r in t.shape){let n=t.shape[r];e[r]=Qs.create(Lu(n))}return new Jr({...t._def,shape:()=>e})}else return t instanceof ss?ss.create(Lu(t.element)):t instanceof Qs?Qs.create(Lu(t.unwrap())):t instanceof pa?pa.create(Lu(t.unwrap())):t instanceof Is?Is.create(t.items.map(e=>Lu(e))):t}s(Lu,"deepPartialify");var Jr=class extends Xt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),r=Mr.objectKeys(e);return this._cached={shape:e,keys:r}}_parse(e){if(this._getType(e)!==yt.object){let u=this._getOrReturnCtx(e);return kt(u,{code:nt.invalid_type,expected:yt.object,received:u.parsedType}),zt}let{status:n,ctx:i}=this._processInputParams(e),{shape:o,keys:a}=this._getCached(),f=[];if(!(this._def.catchall instanceof Xs&&this._def.unknownKeys==="strip"))for(let u in i.data)a.includes(u)||f.push(u);let l=[];for(let u of a){let h=o[u],g=i.data[u];l.push({key:{status:"valid",value:u},value:h._parse(new Ss(i,g,i.path,u)),alwaysSet:u in i.data})}if(this._def.catchall instanceof Xs){let u=this._def.unknownKeys;if(u==="passthrough")for(let h of f)l.push({key:{status:"valid",value:h},value:{status:"valid",value:i.data[h]}});else if(u==="strict")f.length>0&&(kt(i,{code:nt.unrecognized_keys,keys:f}),n.dirty());else if(u!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let u=this._def.catchall;for(let h of f){let g=i.data[h];l.push({key:{status:"valid",value:h},value:u._parse(new Ss(i,g,i.path,h)),alwaysSet:h in i.data})}}return i.common.async?Promise.resolve().then(async()=>{let u=[];for(let h of l){let g=await h.key;u.push({key:g,value:await h.value,alwaysSet:h.alwaysSet})}return u}).then(u=>Kn.mergeObjectSync(n,u)):Kn.mergeObjectSync(n,l)}get shape(){return this._def.shape()}strict(e){return pr.errToObj,new Jr({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(r,n)=>{var i,o,a,f;let l=(a=(o=(i=this._def).errorMap)===null||o===void 0?void 0:o.call(i,r,n).message)!==null&&a!==void 0?a:n.defaultError;return r.code==="unrecognized_keys"?{message:(f=pr.errToObj(e).message)!==null&&f!==void 0?f:l}:{message:l}}}:{}})}strip(){return new Jr({...this._def,unknownKeys:"strip"})}passthrough(){return new Jr({...this._def,unknownKeys:"passthrough"})}extend(e){return new Jr({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Jr({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>mg.mergeShapes(this._def.shape(),e._def.shape()),typeName:jt.ZodObject})}setKey(e,r){return this.augment({[e]:r})}catchall(e){return new Jr({...this._def,catchall:e})}pick(e){let r={};return Mr.objectKeys(e).forEach(n=>{e[n]&&this.shape[n]&&(r[n]=this.shape[n])}),new Jr({...this._def,shape:()=>r})}omit(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{e[n]||(r[n]=this.shape[n])}),new Jr({...this._def,shape:()=>r})}deepPartial(){return Lu(this)}partial(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{let i=this.shape[n];e&&!e[n]?r[n]=i:r[n]=i.optional()}),new Jr({...this._def,shape:()=>r})}required(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{if(e&&!e[n])r[n]=this.shape[n];else{let o=this.shape[n];for(;o instanceof Qs;)o=o._def.innerType;r[n]=o}}),new Jr({...this._def,shape:()=>r})}keyof(){return MC(Mr.objectKeys(this.shape))}};s(Jr,"ZodObject");Jr.create=(t,e)=>new Jr({shape:()=>t,unknownKeys:"strip",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});Jr.strictCreate=(t,e)=>new Jr({shape:()=>t,unknownKeys:"strict",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});Jr.lazycreate=(t,e)=>new Jr({shape:t,unknownKeys:"strip",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});var lf=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=this._def.options;function i(o){for(let f of o)if(f.result.status==="valid")return f.result;for(let f of o)if(f.result.status==="dirty")return r.common.issues.push(...f.ctx.common.issues),f.result;let a=o.map(f=>new Ys(f.ctx.common.issues));return kt(r,{code:nt.invalid_union,unionErrors:a}),zt}if(s(i,"handleResults"),r.common.async)return Promise.all(n.map(async o=>{let a={...r,common:{...r.common,issues:[]},parent:null};return{result:await o._parseAsync({data:r.data,path:r.path,parent:a}),ctx:a}})).then(i);{let o,a=[];for(let l of n){let u={...r,common:{...r.common,issues:[]},parent:null},h=l._parseSync({data:r.data,path:r.path,parent:u});if(h.status==="valid")return h;h.status==="dirty"&&!o&&(o={result:h,ctx:u}),u.common.issues.length&&a.push(u.common.issues)}if(o)return r.common.issues.push(...o.ctx.common.issues),o.result;let f=a.map(l=>new Ys(l));return kt(r,{code:nt.invalid_union,unionErrors:f}),zt}}get options(){return this._def.options}};s(lf,"ZodUnion");lf.create=(t,e)=>new lf({options:t,typeName:jt.ZodUnion,...nr(e)});var lg=s(t=>t instanceof hf?lg(t.schema):t instanceof os?lg(t.innerType()):t instanceof pf?[t.value]:t instanceof Eo?t.options:t instanceof mf?Object.keys(t.enum):t instanceof gf?lg(t._def.innerType):t instanceof cf?[void 0]:t instanceof ff?[null]:null,"getDiscriminator"),wl=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.object)return kt(r,{code:nt.invalid_type,expected:yt.object,received:r.parsedType}),zt;let n=this.discriminator,i=r.data[n],o=this.optionsMap.get(i);return o?r.common.async?o._parseAsync({data:r.data,path:r.path,parent:r}):o._parseSync({data:r.data,path:r.path,parent:r}):(kt(r,{code:nt.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),zt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,r,n){let i=new Map;for(let o of r){let a=lg(o.shape[e]);if(!a)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let f of a){if(i.has(f))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(f)}`);i.set(f,o)}}return new wl({typeName:jt.ZodDiscriminatedUnion,discriminator:e,options:r,optionsMap:i,...nr(n)})}};s(wl,"ZodDiscriminatedUnion");function Yy(t,e){let r=sf(t),n=sf(e);if(t===e)return{valid:!0,data:t};if(r===yt.object&&n===yt.object){let i=Mr.objectKeys(e),o=Mr.objectKeys(t).filter(f=>i.indexOf(f)!==-1),a={...t,...e};for(let f of o){let l=Yy(t[f],e[f]);if(!l.valid)return{valid:!1};a[f]=l.data}return{valid:!0,data:a}}else if(r===yt.array&&n===yt.array){if(t.length!==e.length)return{valid:!1};let i=[];for(let o=0;o<t.length;o++){let a=t[o],f=e[o],l=Yy(a,f);if(!l.valid)return{valid:!1};i.push(l.data)}return{valid:!0,data:i}}else return r===yt.date&&n===yt.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}s(Yy,"mergeValues");var uf=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e),i=s((o,a)=>{if(Wy(o)||Wy(a))return zt;let f=Yy(o.value,a.value);return f.valid?((Jy(o)||Jy(a))&&r.dirty(),{status:r.value,value:f.data}):(kt(n,{code:nt.invalid_intersection_types}),zt)},"handleParsed");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(([o,a])=>i(o,a)):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}))}};s(uf,"ZodIntersection");uf.create=(t,e,r)=>new uf({left:t,right:e,typeName:jt.ZodIntersection,...nr(r)});var Is=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.array)return kt(n,{code:nt.invalid_type,expected:yt.array,received:n.parsedType}),zt;if(n.data.length<this._def.items.length)return kt(n,{code:nt.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),zt;!this._def.rest&&n.data.length>this._def.items.length&&(kt(n,{code:nt.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());let o=[...n.data].map((a,f)=>{let l=this._def.items[f]||this._def.rest;return l?l._parse(new Ss(n,a,n.path,f)):null}).filter(a=>!!a);return n.common.async?Promise.all(o).then(a=>Kn.mergeArray(r,a)):Kn.mergeArray(r,o)}get items(){return this._def.items}rest(e){return new Is({...this._def,rest:e})}};s(Is,"ZodTuple");Is.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Is({items:t,typeName:jt.ZodTuple,rest:null,...nr(e)})};var df=class extends Xt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.object)return kt(n,{code:nt.invalid_type,expected:yt.object,received:n.parsedType}),zt;let i=[],o=this._def.keyType,a=this._def.valueType;for(let f in n.data)i.push({key:o._parse(new Ss(n,f,n.path,f)),value:a._parse(new Ss(n,n.data[f],n.path,f))});return n.common.async?Kn.mergeObjectAsync(r,i):Kn.mergeObjectSync(r,i)}get element(){return this._def.valueType}static create(e,r,n){return r instanceof Xt?new df({keyType:e,valueType:r,typeName:jt.ZodRecord,...nr(n)}):new df({keyType:Zs.create(),valueType:e,typeName:jt.ZodRecord,...nr(r)})}};s(df,"ZodRecord");var _l=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.map)return kt(n,{code:nt.invalid_type,expected:yt.map,received:n.parsedType}),zt;let i=this._def.keyType,o=this._def.valueType,a=[...n.data.entries()].map(([f,l],u)=>({key:i._parse(new Ss(n,f,n.path,[u,"key"])),value:o._parse(new Ss(n,l,n.path,[u,"value"]))}));if(n.common.async){let f=new Map;return Promise.resolve().then(async()=>{for(let l of a){let u=await l.key,h=await l.value;if(u.status==="aborted"||h.status==="aborted")return zt;(u.status==="dirty"||h.status==="dirty")&&r.dirty(),f.set(u.value,h.value)}return{status:r.value,value:f}})}else{let f=new Map;for(let l of a){let u=l.key,h=l.value;if(u.status==="aborted"||h.status==="aborted")return zt;(u.status==="dirty"||h.status==="dirty")&&r.dirty(),f.set(u.value,h.value)}return{status:r.value,value:f}}}};s(_l,"ZodMap");_l.create=(t,e,r)=>new _l({valueType:e,keyType:t,typeName:jt.ZodMap,...nr(r)});var ha=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.set)return kt(n,{code:nt.invalid_type,expected:yt.set,received:n.parsedType}),zt;let i=this._def;i.minSize!==null&&n.data.size<i.minSize.value&&(kt(n,{code:nt.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&&(kt(n,{code:nt.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),r.dirty());let o=this._def.valueType;function a(l){let u=new Set;for(let h of l){if(h.status==="aborted")return zt;h.status==="dirty"&&r.dirty(),u.add(h.value)}return{status:r.value,value:u}}s(a,"finalizeSet");let f=[...n.data.values()].map((l,u)=>o._parse(new Ss(n,l,n.path,u)));return n.common.async?Promise.all(f).then(l=>a(l)):a(f)}min(e,r){return new ha({...this._def,minSize:{value:e,message:pr.toString(r)}})}max(e,r){return new ha({...this._def,maxSize:{value:e,message:pr.toString(r)}})}size(e,r){return this.min(e,r).max(e,r)}nonempty(e){return this.min(1,e)}};s(ha,"ZodSet");ha.create=(t,e)=>new ha({valueType:t,minSize:null,maxSize:null,typeName:jt.ZodSet,...nr(e)});var fc=class extends Xt{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.function)return kt(r,{code:nt.invalid_type,expected:yt.function,received:r.parsedType}),zt;function n(f,l){return dg({data:f,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,ug(),w0].filter(u=>!!u),issueData:{code:nt.invalid_arguments,argumentsError:l}})}s(n,"makeArgsIssue");function i(f,l){return dg({data:f,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,ug(),w0].filter(u=>!!u),issueData:{code:nt.invalid_return_type,returnTypeError:l}})}s(i,"makeReturnsIssue");let o={errorMap:r.common.contextualErrorMap},a=r.data;return this._def.returns instanceof lc?Ai(async(...f)=>{let l=new Ys([]),u=await this._def.args.parseAsync(f,o).catch(x=>{throw l.addIssue(n(f,x)),l}),h=await a(...u);return await this._def.returns._def.type.parseAsync(h,o).catch(x=>{throw l.addIssue(i(h,x)),l})}):Ai((...f)=>{let l=this._def.args.safeParse(f,o);if(!l.success)throw new Ys([n(f,l.error)]);let u=a(...l.data),h=this._def.returns.safeParse(u,o);if(!h.success)throw new Ys([i(u,h.error)]);return h.data})}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new fc({...this._def,args:Is.create(e).rest(da.create())})}returns(e){return new fc({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,r,n){return new fc({args:e||Is.create([]).rest(da.create()),returns:r||da.create(),typeName:jt.ZodFunction,...nr(n)})}};s(fc,"ZodFunction");var hf=class extends Xt{get schema(){return this._def.getter()}_parse(e){let{ctx:r}=this._processInputParams(e);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}};s(hf,"ZodLazy");hf.create=(t,e)=>new hf({getter:t,typeName:jt.ZodLazy,...nr(e)});var pf=class extends Xt{_parse(e){if(e.data!==this._def.value){let r=this._getOrReturnCtx(e);return kt(r,{received:r.data,code:nt.invalid_literal,expected:this._def.value}),zt}return{status:"valid",value:e.data}}get value(){return this._def.value}};s(pf,"ZodLiteral");pf.create=(t,e)=>new pf({value:t,typeName:jt.ZodLiteral,...nr(e)});function MC(t,e){return new Eo({values:t,typeName:jt.ZodEnum,...nr(e)})}s(MC,"createZodEnum");var Eo=class extends Xt{_parse(e){if(typeof e.data!="string"){let r=this._getOrReturnCtx(e),n=this._def.values;return kt(r,{expected:Mr.joinValues(n),received:r.parsedType,code:nt.invalid_type}),zt}if(this._def.values.indexOf(e.data)===-1){let r=this._getOrReturnCtx(e),n=this._def.values;return kt(r,{received:r.data,code:nt.invalid_enum_value,options:n}),zt}return Ai(e.data)}get options(){return this._def.values}get enum(){let e={};for(let r of this._def.values)e[r]=r;return e}get Values(){let e={};for(let r of this._def.values)e[r]=r;return e}get Enum(){let e={};for(let r of this._def.values)e[r]=r;return e}extract(e){return Eo.create(e)}exclude(e){return Eo.create(this.options.filter(r=>!e.includes(r)))}};s(Eo,"ZodEnum");Eo.create=MC;var mf=class extends Xt{_parse(e){let r=Mr.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==yt.string&&n.parsedType!==yt.number){let i=Mr.objectValues(r);return kt(n,{expected:Mr.joinValues(i),received:n.parsedType,code:nt.invalid_type}),zt}if(r.indexOf(e.data)===-1){let i=Mr.objectValues(r);return kt(n,{received:n.data,code:nt.invalid_enum_value,options:i}),zt}return Ai(e.data)}get enum(){return this._def.values}};s(mf,"ZodNativeEnum");mf.create=(t,e)=>new mf({values:t,typeName:jt.ZodNativeEnum,...nr(e)});var lc=class extends Xt{unwrap(){return this._def.type}_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.promise&&r.common.async===!1)return kt(r,{code:nt.invalid_type,expected:yt.promise,received:r.parsedType}),zt;let n=r.parsedType===yt.promise?r.data:Promise.resolve(r.data);return Ai(n.then(i=>this._def.type.parseAsync(i,{path:r.path,errorMap:r.common.contextualErrorMap})))}};s(lc,"ZodPromise");lc.create=(t,e)=>new lc({type:t,typeName:jt.ZodPromise,...nr(e)});var os=class extends Xt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===jt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:r,ctx:n}=this._processInputParams(e),i=this._def.effect||null;if(i.type==="preprocess"){let a=i.transform(n.data);return n.common.async?Promise.resolve(a).then(f=>this._def.schema._parseAsync({data:f,path:n.path,parent:n})):this._def.schema._parseSync({data:a,path:n.path,parent:n})}let o={addIssue:a=>{kt(n,a),a.fatal?r.abort():r.dirty()},get path(){return n.path}};if(o.addIssue=o.addIssue.bind(o),i.type==="refinement"){let a=s(f=>{let l=i.refinement(f,o);if(n.common.async)return Promise.resolve(l);if(l instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return f},"executeRefinement");if(n.common.async===!1){let f=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return f.status==="aborted"?zt:(f.status==="dirty"&&r.dirty(),a(f.value),{status:r.value,value:f.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(f=>f.status==="aborted"?zt:(f.status==="dirty"&&r.dirty(),a(f.value).then(()=>({status:r.value,value:f.value}))))}if(i.type==="transform")if(n.common.async===!1){let a=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!hg(a))return a;let f=i.transform(a.value,o);if(f instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:f}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(a=>hg(a)?Promise.resolve(i.transform(a.value,o)).then(f=>({status:r.value,value:f})):a);Mr.assertNever(i)}};s(os,"ZodEffects");os.create=(t,e,r)=>new os({schema:t,typeName:jt.ZodEffects,effect:e,...nr(r)});os.createWithPreprocess=(t,e,r)=>new os({schema:e,effect:{type:"preprocess",transform:t},typeName:jt.ZodEffects,...nr(r)});var Qs=class extends Xt{_parse(e){return this._getType(e)===yt.undefined?Ai(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};s(Qs,"ZodOptional");Qs.create=(t,e)=>new Qs({innerType:t,typeName:jt.ZodOptional,...nr(e)});var pa=class extends Xt{_parse(e){return this._getType(e)===yt.null?Ai(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};s(pa,"ZodNullable");pa.create=(t,e)=>new pa({innerType:t,typeName:jt.ZodNullable,...nr(e)});var gf=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=r.data;return r.parsedType===yt.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:r.path,parent:r})}removeDefault(){return this._def.innerType}};s(gf,"ZodDefault");gf.create=(t,e)=>new gf({innerType:t,typeName:jt.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...nr(e)});var Al=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r,common:{...r.common,issues:[]}}});return pg(n)?n.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue()})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue()}}removeCatch(){return this._def.innerType}};s(Al,"ZodCatch");Al.create=(t,e)=>new Al({innerType:t,typeName:jt.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...nr(e)});var El=class extends Xt{_parse(e){if(this._getType(e)!==yt.nan){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.nan,received:n.parsedType}),zt}return{status:"valid",value:e.data}}};s(El,"ZodNaN");El.create=t=>new El({typeName:jt.ZodNaN,...nr(t)});var pz=Symbol("zod_brand"),x0=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=r.data;return this._def.type._parse({data:n,path:r.path,parent:r})}unwrap(){return this._def.type}};s(x0,"ZodBranded");var bf=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.common.async)return s(async()=>{let o=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return o.status==="aborted"?zt:o.status==="dirty"?(r.dirty(),TC(o.value)):this._def.out._parseAsync({data:o.value,path:n.path,parent:n})},"handleAsync")();{let i=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?zt:i.status==="dirty"?(r.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:n.path,parent:n})}}static create(e,r){return new bf({in:e,out:r,typeName:jt.ZodPipeline})}};s(bf,"ZodPipeline");var RC=s((t,e={},r)=>t?cc.create().superRefine((n,i)=>{if(!t(n)){let o=typeof e=="function"?e(n):e,a=typeof o=="string"?{message:o}:o;i.addIssue({code:"custom",...a,fatal:r})}}):cc.create(),"custom"),mz={object:Jr.lazycreate},jt;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline"})(jt||(jt={}));var gz=s((t,e={message:`Input not instance of ${t.name}`})=>RC(r=>r instanceof t,e,!0),"instanceOfType"),BC=Zs.create,DC=Ao.create,bz=El.create,vz=of.create,PC=af.create,yz=ua.create,xz=yl.create,wz=cf.create,_z=ff.create,Az=cc.create,Ez=da.create,Cz=Xs.create,Sz=xl.create,Iz=ss.create,kz=Jr.create,Tz=Jr.strictCreate,Mz=lf.create,Rz=wl.create,Bz=uf.create,Dz=Is.create,Pz=df.create,Oz=_l.create,Fz=ha.create,Nz=fc.create,Lz=hf.create,Uz=pf.create,jz=Eo.create,qz=mf.create,Hz=lc.create,IC=os.create,zz=Qs.create,$z=pa.create,Gz=os.createWithPreprocess,Kz=bf.create,Vz=s(()=>BC().optional(),"ostring"),Wz=s(()=>DC().optional(),"onumber"),Jz=s(()=>PC().optional(),"oboolean"),Yz={string:t=>Zs.create({...t,coerce:!0}),number:t=>Ao.create({...t,coerce:!0}),boolean:t=>af.create({...t,coerce:!0}),bigint:t=>of.create({...t,coerce:!0}),date:t=>ua.create({...t,coerce:!0})},Zz=zt,_e=Object.freeze({__proto__:null,defaultErrorMap:w0,setErrorMap:oz,getErrorMap:ug,makeIssue:dg,EMPTY_PATH:az,addIssueToContext:kt,ParseStatus:Kn,INVALID:zt,DIRTY:TC,OK:Ai,isAborted:Wy,isDirty:Jy,isValid:hg,isAsync:pg,get util(){return Mr},ZodParsedType:yt,getParsedType:sf,ZodType:Xt,ZodString:Zs,ZodNumber:Ao,ZodBigInt:of,ZodBoolean:af,ZodDate:ua,ZodSymbol:yl,ZodUndefined:cf,ZodNull:ff,ZodAny:cc,ZodUnknown:da,ZodNever:Xs,ZodVoid:xl,ZodArray:ss,get objectUtil(){return mg},ZodObject:Jr,ZodUnion:lf,ZodDiscriminatedUnion:wl,ZodIntersection:uf,ZodTuple:Is,ZodRecord:df,ZodMap:_l,ZodSet:ha,ZodFunction:fc,ZodLazy:hf,ZodLiteral:pf,ZodEnum:Eo,ZodNativeEnum:mf,ZodPromise:lc,ZodEffects:os,ZodTransformer:os,ZodOptional:Qs,ZodNullable:pa,ZodDefault:gf,ZodCatch:Al,ZodNaN:El,BRAND:pz,ZodBranded:x0,ZodPipeline:bf,custom:RC,Schema:Xt,ZodSchema:Xt,late:mz,get ZodFirstPartyTypeKind(){return jt},coerce:Yz,any:Az,array:Iz,bigint:vz,boolean:PC,date:yz,discriminatedUnion:Rz,effect:IC,enum:jz,function:Nz,instanceof:gz,intersection:Bz,lazy:Lz,literal:Uz,map:Oz,nan:bz,nativeEnum:qz,never:Cz,null:_z,nullable:$z,number:DC,object:kz,oboolean:Jz,onumber:Wz,optional:zz,ostring:Vz,pipeline:Kz,preprocess:Gz,promise:Hz,record:Pz,set:Fz,strictObject:Tz,string:BC,symbol:xz,transformer:IC,tuple:Dz,undefined:wz,union:Mz,unknown:Ez,void:Sz,NEVER:Zz,ZodIssueCode:nt,quotelessJson:sz,ZodError:Ys});var FC=_e.array(_e.string().or(_e.record(_e.any()))),ise=_e.object({type:_e.string().optional(),narrative:_e.string().optional()}),gg=_e.string().or(_e.object({id:_e.string(),type:_e.string(),caption:_e.string().optional()})),Xz=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),latitude:_e.number(),longitude:_e.number()}),Qz=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),addressCountry:_e.string().optional(),addressCountryCode:_e.string().optional(),addressRegion:_e.string().optional(),addressLocality:_e.string().optional(),streetAddress:_e.string().optional(),postOfficeBoxNumber:_e.string().optional(),postalCode:_e.string().optional(),geo:Xz.optional()}),e$=_e.enum(["sourcedId","systemId","productId","userName","accountId","emailAddress","nationalIdentityNumber","isbn","issn","lisSourcedId","oneRosterSourcedId","sisSourcedId","ltiContextId","ltiDeploymentId","ltiToolId","ltiPlatformId","ltiUserId","identifier"]).or(_e.string()),NC=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),identifier:_e.string(),identifierType:e$}),_0=_e.string().or(_e.object({id:_e.string().optional(),type:_e.string().or(_e.string().array().nonempty().optional()),name:_e.string().optional(),url:_e.string().optional(),phone:_e.string().optional(),description:_e.string().optional(),endorsement:_e.any().array().optional(),image:gg.optional(),email:_e.string().email().optional(),address:Qz.optional(),otherIdentifier:NC.array().optional(),official:_e.string().optional(),parentOrg:_e.any().optional(),familyName:_e.string().optional(),givenName:_e.string().optional(),additionalName:_e.string().optional(),patronymicName:_e.string().optional(),honorificPrefix:_e.string().optional(),honorificSuffix:_e.string().optional(),familyNamePrefix:_e.string().optional(),dateOfBirth:_e.string().optional()}).catchall(_e.any())),Zy=_e.object({id:_e.string().optional()}).catchall(_e.any()),t$=_e.object({type:_e.string(),id:_e.string()}),r$=_e.object({id:_e.string(),type:_e.string()}),n$=_e.object({id:_e.string(),type:_e.string()}).catchall(_e.any()),Cl=_e.object({"@context":FC,id:_e.string().optional(),type:_e.string().array().nonempty(),issuer:_0,issuanceDate:_e.string(),expirationDate:_e.string().optional(),credentialSubject:Zy.or(Zy.array()),credentialStatus:t$.optional(),credentialSchema:r$.array().optional(),refreshService:n$.optional()}).catchall(_e.any()),vf=_e.object({type:_e.string(),created:_e.string(),challenge:_e.string().optional(),domain:_e.string().optional(),nonce:_e.string().optional(),proofPurpose:_e.string(),verificationMethod:_e.string(),jws:_e.string().optional()}).catchall(_e.any()),A0=Cl.extend({proof:vf.or(vf.array())}),i$=_e.object({"@context":FC,id:_e.string().optional(),type:_e.string().array().nonempty(),verifiableCredential:A0.or(A0.array()).optional(),holder:_e.string().optional()}).catchall(_e.any()),Xy=i$.extend({proof:vf.or(vf.array())}),s$=_e.enum(["ceasn:Competency","ceterms:Credential","CFItem","CFRubric","CFRubricCriterion","CFRubricCriterionLevel","CTDL"]).or(_e.string()),bg=_e.object({type:_e.string().array().nonempty(),targetCode:_e.string().optional(),targetDescription:_e.string().optional(),targetName:_e.string(),targetFramework:_e.string().optional(),targetType:s$.optional(),targetUrl:_e.string()}),o$=_e.enum(["Achievement","ApprenticeshipCertificate","Assessment","Assignment","AssociateDegree","Award","Badge","BachelorDegree","Certificate","CertificateOfCompletion","Certification","CommunityService","Competency","Course","CoCurricular","Degree","Diploma","DoctoralDegree","Fieldwork","GeneralEducationDevelopment","JourneymanCertificate","LearningProgram","License","Membership","ProfessionalDoctorate","QualityAssuranceCredential","MasterCertificate","MasterDegree","MicroCredential","ResearchDoctorate","SecondarySchoolDiploma"]),a$=o$.or(_e.string()),c$=_e.object({id:_e.string().optional(),narrative:_e.string().optional()}).catchall(_e.any()),f$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),endorsementComment:_e.string().optional()}),l$=Cl.extend({credentialSubject:f$,proof:vf.or(vf.array()).optional()}),u$=_e.object({id:_e.string(),"@language":_e.string().optional(),version:_e.string().optional()}),d$=_e.enum(["GradePointAverage","LetterGrade","Percent","PerformanceLevel","PredictedScore","RawScore","Result","RubricCriterion","RubricCriterionLevel","RubricScore","ScaledScore","Status"]).or(_e.string()),h$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),description:_e.string().optional(),level:_e.string().optional(),name:_e.string(),points:_e.string().optional()}).catchall(_e.any()),p$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),allowedValue:_e.string().array().optional(),name:_e.string(),requiredLevel:_e.string().optional(),requiredValue:_e.string().optional(),resultType:d$,rubricCriterionLevel:h$.array().optional(),valueMax:_e.string().optional(),valueMin:_e.string().optional()}).catchall(_e.any()),m$=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),achievementType:a$.optional(),creator:_0.optional(),creditsAvailable:_e.number().optional(),criteria:c$,description:_e.string(),endorsement:l$.array().optional(),fieldOfStudy:_e.string().optional(),humanCode:_e.string().optional(),image:gg.optional(),"@language":_e.string().optional(),name:_e.string(),otherIdentifier:NC.array().optional(),related:u$.array().optional(),resultDescription:p$.array().optional(),specialization:_e.string().optional(),tag:_e.string().array().optional(),version:_e.string().optional()}).catchall(_e.any()),g$=_e.object({type:_e.string(),hashed:_e.boolean(),identityHash:_e.string(),identityType:_e.string(),salt:_e.string().optional()}),b$=_e.enum(["Completed","Enrolled","Failed","InProgress","OnHold","Withdrew"]),v$=_e.object({type:_e.string().array().nonempty(),achievedLevel:_e.string().optional(),alignment:bg.array().optional(),resultDescription:_e.string().optional(),status:b$.optional(),value:_e.string().optional()}).catchall(_e.any()),OC=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),activityEndDate:_e.string().optional(),activityStartDate:_e.string().optional(),creditsEarned:_e.number().optional(),achievement:m$.optional(),identifier:g$.array().optional(),image:gg.optional(),licenseNumber:_e.string().optional(),narrative:_e.string().optional(),result:v$.array().optional(),role:_e.string().optional(),source:_0.optional(),term:_e.string().optional()}).catchall(_e.any()),y$=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),narrative:_e.string().optional(),name:_e.string().optional(),description:_e.string().optional(),genre:_e.string().optional(),audience:_e.string().optional()}).catchall(_e.any()),x$=Cl.extend({name:_e.string().optional(),description:_e.string().optional(),image:gg.optional(),credentialSubject:OC.or(OC.array()),endorsement:Cl.array().optional(),evidence:y$.array().optional()}),ose=x$.extend({proof:vf.or(vf.array())}),cse=_e.object({checks:_e.string().array(),warnings:_e.string().array(),errors:_e.string().array()}),LC=_e.enum(["Success","Failed","Error"]),fse=LC.enum,lse=_e.object({check:_e.string(),status:LC,message:_e.string().optional(),details:_e.string().optional()}),use=_e.object({title:_e.string().optional(),createdAt:_e.string().optional(),issuer:_0.optional(),issuee:_0.optional(),credentialSubject:Zy.optional()}),dse=_e.object({id:_e.string(),uri:_e.string()}).catchall(_e.any()),w$=_e.object({profileId:_e.string().min(3).max(40),displayName:_e.string().default(""),did:_e.string(),email:_e.string().optional(),image:_e.string().optional(),isServiceProfile:_e.boolean().default(!1).optional()}),pse=_e.enum(["CONNECTED","PENDING_REQUEST_SENT","PENDING_REQUEST_RECEIVED","NOT_CONNECTED"]),mse=_e.object({uri:_e.string(),to:_e.string(),from:_e.string(),sent:_e.string().datetime(),received:_e.string().datetime().optional()}),gse=_e.object({uri:_e.string(),name:_e.string().optional(),type:_e.string().optional(),category:_e.string().optional()}),bse=_e.object({to:w$,from:_e.string(),received:_e.string()}),_$=_e.object({kty:_e.string(),crv:_e.string(),x:_e.string(),y:_e.string().optional(),n:_e.string().optional(),d:_e.string()}),A$=_e.object({alg:_e.string(),iv:_e.string(),tag:_e.string(),epk:_$.partial().optional(),kid:_e.string().optional(),apv:_e.string().optional(),apu:_e.string().optional()}),E$=_e.object({header:A$,encrypted_key:_e.string()}),UC=_e.object({protected:_e.string(),iv:_e.string(),ciphertext:_e.string(),tag:_e.string(),aad:_e.string().optional(),recipients:E$.array().optional()});var Qy=s(async(t,e)=>{let r=t.id.did(),n=await CC(e,async a=>{let f=await t.invoke.getDidAuthVp({proofFormat:"jwt",challenge:a});if(typeof f!="string")throw new Error("Error getting DID-Auth-JWT!");return f}),i;try{i=await n.profile.getProfile.query()}catch(a){t.debug?.("No profile!",a)}let o=i?.did||r;return{name:"LearnCard Network",displayName:"LearnCard Network",description:"LearnCard Network Integration",id:{did:(a,f)=>!f||f==="web"?o:t.id.did(f),keypair:(a,f)=>t.id.keypair(f)},read:{get:async(a,f)=>{if(a.debug?.("learnCard.read['LearnCard Network'].get"),!f)return;let l=f.split(":");if(l.length!==5)return;let[u,h]=l;if(!(u!=="lc"||h!=="network"))try{let g=await n.storage.resolve.query({uri:f});return"ciphertext"in g&&(g=await a.invoke.getDIDObject().decryptDagJWE(g)),await A0.or(Xy).parseAsync(g)}catch(g){a.debug?.(g);return}}},store:{upload:async(a,f)=>(a.debug?.("learnCard.store['LearnCard Network'].upload"),n.storage.store.mutate({item:f})),uploadEncrypted:async(a,f,{recipients:l=[]}={recipients:[]})=>{a.debug?.("learnCard.store['LearnCard Network'].upload");let u=await a.invoke.getDIDObject().createDagJWE(f,[a.id.did(),...l]);return n.storage.store.mutate({item:u})}},methods:{createProfile:async(a,f)=>{if(i)throw new Error("Account already exists!");let l=await n.profile.createProfile.mutate(f);return i=await n.profile.getProfile.query(),o=l,l},createServiceProfile:async(a,f)=>{if(i)throw new Error("Account already exists!");let l=await n.profile.createServiceProfile.mutate(f);return i=await n.profile.getProfile.query(),o=l,l},updateProfile:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return await n.profile.updateProfile.mutate(f)?(i=await n.profile.getProfile.query(),!0):!1},deleteProfile:async()=>{if(!i)throw new Error("Account does not exist!");return await n.profile.deleteProfile.mutate()?(i=void 0,!0):!1},getProfile:async(a,f)=>f?n.profile.getOtherProfile.query({profileId:f}):n.profile.getProfile.query(),searchProfiles:async(a,f="",{limit:l=25,includeSelf:u=!1,includeConnectionStatus:h=!1}={})=>n.profile.searchProfiles.query({input:f,limit:l,includeSelf:u,includeConnectionStatus:h}),connectWith:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectWith.mutate({profileId:f})},cancelConnectionRequest:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.cancelConnectionRequest.mutate({profileId:f})},connectWithInvite:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectWithInvite.mutate({profileId:f,challenge:l})},disconnectWith:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.disconnectWith.mutate({profileId:f})},acceptConnectionRequest:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.acceptConnectionRequest.mutate({profileId:f})},getConnections:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.connections.query()},getPendingConnections:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.pendingConnections.query()},getConnectionRequests:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectionRequests.query()},generateInvite:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.generateInvite.mutate({challenge:f})},sendCredential:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");if(!u)return n.credential.sendCredential.mutate({profileId:f,credential:l});let h=await a.invoke.getProfile(f);if(!h)throw new Error("Could not find target account");let g=await a.invoke.getDIDObject().createDagJWE(l,[i.did,h.did]);return n.credential.sendCredential.mutate({profileId:f,credential:g})},acceptCredential:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.acceptCredential.mutate({uri:f})},getReceivedCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.receivedCredentials.query({from:f})},getSentCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.sentCredentials.query({to:f})},getIncomingCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.incomingCredentials.query({from:f})},deleteCredential:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.deleteCredential.mutate({uri:f})},sendPresentation:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");if(!u)return n.presentation.sendPresentation.mutate({profileId:f,presentation:l});let h=await a.invoke.getProfile(f);if(!h)throw new Error("Could not find target account");let g=await a.invoke.getDIDObject().createDagJWE(l,[i.did,h.did]);return n.presentation.sendPresentation.mutate({profileId:f,presentation:g})},acceptPresentation:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.acceptPresentation.mutate({uri:f})},getReceivedPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.receivedPresentations.query({from:f})},getSentPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.sentPresentations.query({to:f})},getIncomingPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.incomingPresentations.query({from:f})},deletePresentation:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.deletePresentation.mutate({uri:f})},createBoost:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.boost.createBoost.mutate({credential:f,...l})},getBoosts:async()=>{if(!i)throw new Error("Please make an account first!");return n.boost.getBoosts.query()},getBoostRecipients:async(a,f,l=25,u)=>{if(!i)throw new Error("Please make an account first!");return n.boost.getBoostRecipients.query({uri:f,limit:l,skip:u})},updateBoost:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.boost.updateBoost.mutate({uri:f,updates:l})},deleteBoost:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.boost.deleteBoost.mutate({uri:f})},sendBoost:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");let h=await a.invoke.resolveFromLCN(l),g=await Cl.spa(h);if(!g.success)throw new Error("Did not get a valid boost from URI");let x=await a.invoke.getProfile(f);if(!x)throw new Error("Target profile not found");let _=g.data;_.issuer=a.id.did(),Array.isArray(_.credentialSubject)?_.credentialSubject=_.credentialSubject.map(F=>({...F,id:x.did})):_.credentialSubject.id=x.did,_?.type?.includes("BoostCredential")&&(_.boostId=l);let E=await a.invoke.issueCredential(_);if(!u)return n.boost.sendBoost.mutate({profileId:f,uri:l,credential:E});let T=await n.utilities.getDid.query(),B=await a.invoke.getDIDObject().createDagJWE(E,[i.did,x.did,T]);return n.boost.sendBoost.mutate({profileId:f,uri:l,credential:B})},registerSigningAuthority:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.registerSigningAuthority.mutate({signingAuthority:f})},resolveFromLCN:async(a,f)=>{let l=await n.storage.resolve.query({uri:f});return Cl.or(A0).or(Xy).or(UC).parseAsync(l)}}}},"getLearnCardNetworkPlugin"),e3=s(async(t,e)=>{let r=[{id:"LearnCard Network",url:"https://network.learncard.com",did:"did:web:network.learncard.com"}],n;if(e){let a=await fetch(e);a.status===200?n=JSON.parse(await a.text()):n=r}else n=r;let i=s(a=>{if(!!a)return typeof a=="string"?a:"id"in a&&typeof a.id=="string"?a.id:void 0},"getIssuerDID"),o=s(a=>{let f=i(a);if(!!f)return n.find(l=>l.did===f)},"getTrustedBoostVerifier");return{name:"VerifyBoost",displayName:"Verify Boost Extension",description:"Adds a check for validating Boost Credentials.",methods:{verifyCredential:async(a,f)=>{let l=await t.invoke.verifyCredential(f),u=f?.boostCredential;try{if(u){let h=await t.invoke.verifyCredential(u);if(!u?.boostId&&!f?.boostId&&l.warnings.push("Boost Authenticity could not be verified: Boost ID metadata is missing."),h.errors?.length>0)l.errors=[...h.errors||[],...l.errors||[],"Boost Credential could not be verified."];else if(u?.boostId!==f?.boostId)l.errors.push("Boost Authenticity could not be verified: Boost ID metadata is mismatched.");else{let g=o(f?.issuer);g?l.checks.push(`Boost is Authentic. Verified by ${g.id}.`):l.warnings.push(`Boost Authenticity could not be verified. Issuer is outside of trust network: ${i(f?.issuer)}`)}}}catch{l.errors.push("Boost authenticity could not be verified.")}return l}}}},"getVerifyBoostPlugin");var _pe=require("isomorphic-fetch"),gv=Js(XC()),aD=Js(require("isomorphic-webcrypto")),mU=Js(tS());var $i={};vl($i,{BaseContract:()=>ad,BigNumber:()=>ze,Contract:()=>Ol,ContractFactory:()=>ip,FixedNumber:()=>cn,Signer:()=>Hi,VoidSigner:()=>vc,Wallet:()=>Ro,Wordlist:()=>co,constants:()=>v3,errors:()=>ks,getDefaultProvider:()=>A4,logger:()=>AW,providers:()=>E4,utils:()=>I4,version:()=>k4,wordlists:()=>fd});var mS=Js(s3());var iS="logger/5.7.0";var sS=!1,oS=!1,_g={debug:1,default:2,info:2,warning:3,error:4,off:5},aS=_g.default,o3=null;function P$(){try{let t=[];if(["NFD","NFC","NFKD","NFKC"].forEach(e=>{try{if("test".normalize(e)!=="test")throw new Error("bad normalize")}catch{t.push(e)}}),t.length)throw new Error("missing "+t.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}s(P$,"_checkNormalize");var cS=P$(),a3;(function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARNING="WARNING",t.ERROR="ERROR",t.OFF="OFF"})(a3||(a3={}));var ks;(function(t){t.UNKNOWN_ERROR="UNKNOWN_ERROR",t.NOT_IMPLEMENTED="NOT_IMPLEMENTED",t.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",t.NETWORK_ERROR="NETWORK_ERROR",t.SERVER_ERROR="SERVER_ERROR",t.TIMEOUT="TIMEOUT",t.BUFFER_OVERRUN="BUFFER_OVERRUN",t.NUMERIC_FAULT="NUMERIC_FAULT",t.MISSING_NEW="MISSING_NEW",t.INVALID_ARGUMENT="INVALID_ARGUMENT",t.MISSING_ARGUMENT="MISSING_ARGUMENT",t.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",t.CALL_EXCEPTION="CALL_EXCEPTION",t.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",t.NONCE_EXPIRED="NONCE_EXPIRED",t.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",t.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",t.TRANSACTION_REPLACED="TRANSACTION_REPLACED",t.ACTION_REJECTED="ACTION_REJECTED"})(ks||(ks={}));var fS="0123456789abcdef",ve=class{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,r){let n=e.toLowerCase();_g[n]==null&&this.throwArgumentError("invalid log level name","logLevel",e),!(aS>_g[n])&&console.log.apply(console,r)}debug(...e){this._log(ve.levels.DEBUG,e)}info(...e){this._log(ve.levels.INFO,e)}warn(...e){this._log(ve.levels.WARNING,e)}makeError(e,r,n){if(oS)return this.makeError("censored error",r,{});r||(r=ve.errors.UNKNOWN_ERROR),n||(n={});let i=[];Object.keys(n).forEach(l=>{let u=n[l];try{if(u instanceof Uint8Array){let h="";for(let g=0;g<u.length;g++)h+=fS[u[g]>>4],h+=fS[u[g]&15];i.push(l+"=Uint8Array(0x"+h+")")}else i.push(l+"="+JSON.stringify(u))}catch{i.push(l+"="+JSON.stringify(n[l].toString()))}}),i.push(`code=${r}`),i.push(`version=${this.version}`);let o=e,a="";switch(r){case ks.NUMERIC_FAULT:{a="NUMERIC_FAULT";let l=e;switch(l){case"overflow":case"underflow":case"division-by-zero":a+="-"+l;break;case"negative-power":case"negative-width":a+="-unsupported";break;case"unbound-bitwise-result":a+="-unbound-result";break}break}case ks.CALL_EXCEPTION:case ks.INSUFFICIENT_FUNDS:case ks.MISSING_NEW:case ks.NONCE_EXPIRED:case ks.REPLACEMENT_UNDERPRICED:case ks.TRANSACTION_REPLACED:case ks.UNPREDICTABLE_GAS_LIMIT:a=r;break}a&&(e+=" [ See: https://links.ethers.org/v5-errors-"+a+" ]"),i.length&&(e+=" ("+i.join(", ")+")");let f=new Error(e);return f.reason=o,f.code=r,Object.keys(n).forEach(function(l){f[l]=n[l]}),f}throwError(e,r,n){throw this.makeError(e,r,n)}throwArgumentError(e,r,n){return this.throwError(e,ve.errors.INVALID_ARGUMENT,{argument:r,value:n})}assert(e,r,n,i){e||this.throwError(r,n,i)}assertArgument(e,r,n,i){e||this.throwArgumentError(r,n,i)}checkNormalize(e){e==null&&(e="platform missing String.prototype.normalize"),cS&&this.throwError("platform missing String.prototype.normalize",ve.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:cS})}checkSafeUint53(e,r){typeof e=="number"&&(r==null&&(r="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(r,ve.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(r,ve.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,r,n){n?n=": "+n:n="",e<r&&this.throwError("missing argument"+n,ve.errors.MISSING_ARGUMENT,{count:e,expectedCount:r}),e>r&&this.throwError("too many arguments"+n,ve.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:r})}checkNew(e,r){(e===Object||e==null)&&this.throwError("missing new",ve.errors.MISSING_NEW,{name:r.name})}checkAbstract(e,r){e===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",ve.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):(e===Object||e==null)&&this.throwError("missing new",ve.errors.MISSING_NEW,{name:r.name})}static globalLogger(){return o3||(o3=new ve(iS)),o3}static setCensorship(e,r){if(!e&&r&&this.globalLogger().throwError("cannot permanently disable censorship",ve.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),sS){if(!e)return;this.globalLogger().throwError("error censorship permanent",ve.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}oS=!!e,sS=!!r}static setLogLevel(e){let r=_g[e.toLowerCase()];if(r==null){ve.globalLogger().warn("invalid log level - "+e);return}aS=r}static from(e){return new ve(e)}};s(ve,"Logger");ve.errors=ks;ve.levels=a3;var lS="bytes/5.7.0";var gn=new ve(lS);function dS(t){return!!t.toHexString}s(dS,"isHexable");function qu(t){return t.slice||(t.slice=function(){let e=Array.prototype.slice.call(arguments);return qu(new Uint8Array(Array.prototype.slice.apply(t,e)))}),t}s(qu,"addSlice");function pc(t){return Pt(t)&&!(t.length%2)||eo(t)}s(pc,"isBytesLike");function uS(t){return typeof t=="number"&&t==t&&t%1===0}s(uS,"isInteger");function eo(t){if(t==null)return!1;if(t.constructor===Uint8Array)return!0;if(typeof t=="string"||!uS(t.length)||t.length<0)return!1;for(let e=0;e<t.length;e++){let r=t[e];if(!uS(r)||r<0||r>=256)return!1}return!0}s(eo,"isBytes");function je(t,e){if(e||(e={}),typeof t=="number"){gn.checkSafeUint53(t,"invalid arrayify value");let r=[];for(;t;)r.unshift(t&255),t=parseInt(String(t/256));return r.length===0&&r.push(0),qu(new Uint8Array(r))}if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),dS(t)&&(t=t.toHexString()),Pt(t)){let r=t.substring(2);r.length%2&&(e.hexPad==="left"?r="0"+r:e.hexPad==="right"?r+="0":gn.throwArgumentError("hex data is odd-length","value",t));let n=[];for(let i=0;i<r.length;i+=2)n.push(parseInt(r.substring(i,i+2),16));return qu(new Uint8Array(n))}return eo(t)?qu(new Uint8Array(t)):gn.throwArgumentError("invalid arrayify value","value",t)}s(je,"arrayify");function sr(t){let e=t.map(i=>je(i)),r=e.reduce((i,o)=>i+o.length,0),n=new Uint8Array(r);return e.reduce((i,o)=>(n.set(o,i),i+o.length),0),qu(n)}s(sr,"concat");function Ts(t){let e=je(t);if(e.length===0)return e;let r=0;for(;r<e.length&&e[r]===0;)r++;return r&&(e=e.slice(r)),e}s(Ts,"stripZeros");function Sl(t,e){t=je(t),t.length>e&&gn.throwArgumentError("value out of range","value",arguments[0]);let r=new Uint8Array(e);return r.set(t,e-t.length),qu(r)}s(Sl,"zeroPad");function Pt(t,e){return!(typeof t!="string"||!t.match(/^0x[0-9A-Fa-f]*$/)||e&&t.length!==2+2*e)}s(Pt,"isHexString");var c3="0123456789abcdef";function Ve(t,e){if(e||(e={}),typeof t=="number"){gn.checkSafeUint53(t,"invalid hexlify value");let r="";for(;t;)r=c3[t&15]+r,t=Math.floor(t/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if(typeof t=="bigint")return t=t.toString(16),t.length%2?"0x0"+t:"0x"+t;if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),dS(t))return t.toHexString();if(Pt(t))return t.length%2&&(e.hexPad==="left"?t="0x0"+t.substring(2):e.hexPad==="right"?t+="0":gn.throwArgumentError("hex data is odd-length","value",t)),t.toLowerCase();if(eo(t)){let r="0x";for(let n=0;n<t.length;n++){let i=t[n];r+=c3[(i&240)>>4]+c3[i&15]}return r}return gn.throwArgumentError("invalid hexlify value","value",t)}s(Ve,"hexlify");function Ei(t){if(typeof t!="string")t=Ve(t);else if(!Pt(t)||t.length%2)return null;return(t.length-2)/2}s(Ei,"hexDataLength");function Fr(t,e,r){return typeof t!="string"?t=Ve(t):(!Pt(t)||t.length%2)&&gn.throwArgumentError("invalid hexData","value",t),e=2+2*e,r!=null?"0x"+t.substring(e,2+2*r):"0x"+t.substring(e)}s(Fr,"hexDataSlice");function Mn(t){let e="0x";return t.forEach(r=>{e+=Ve(r).substring(2)}),e}s(Mn,"hexConcat");function ma(t){let e=f3(Ve(t,{hexPad:"left"}));return e==="0x"?"0x0":e}s(ma,"hexValue");function f3(t){typeof t!="string"&&(t=Ve(t)),Pt(t)||gn.throwArgumentError("invalid hex string","value",t),t=t.substring(2);let e=0;for(;e<t.length&&t[e]==="0";)e++;return"0x"+t.substring(e)}s(f3,"hexStripZeros");function ur(t,e){for(typeof t!="string"?t=Ve(t):Pt(t)||gn.throwArgumentError("invalid hex string","value",t),t.length>2*e+2&&gn.throwArgumentError("value out of range","value",arguments[1]);t.length<2*e+2;)t="0x0"+t.substring(2);return t}s(ur,"hexZeroPad");function ga(t){let e={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(pc(t)){let r=je(t);r.length===64?(e.v=27+(r[32]>>7),r[32]&=127,e.r=Ve(r.slice(0,32)),e.s=Ve(r.slice(32,64))):r.length===65?(e.r=Ve(r.slice(0,32)),e.s=Ve(r.slice(32,64)),e.v=r[64]):gn.throwArgumentError("invalid signature string","signature",t),e.v<27&&(e.v===0||e.v===1?e.v+=27:gn.throwArgumentError("signature invalid v byte","signature",t)),e.recoveryParam=1-e.v%2,e.recoveryParam&&(r[32]|=128),e._vs=Ve(r.slice(32,64))}else{if(e.r=t.r,e.s=t.s,e.v=t.v,e.recoveryParam=t.recoveryParam,e._vs=t._vs,e._vs!=null){let i=Sl(je(e._vs),32);e._vs=Ve(i);let o=i[0]>=128?1:0;e.recoveryParam==null?e.recoveryParam=o:e.recoveryParam!==o&&gn.throwArgumentError("signature recoveryParam mismatch _vs","signature",t),i[0]&=127;let a=Ve(i);e.s==null?e.s=a:e.s!==a&&gn.throwArgumentError("signature v mismatch _vs","signature",t)}if(e.recoveryParam==null)e.v==null?gn.throwArgumentError("signature missing v and recoveryParam","signature",t):e.v===0||e.v===1?e.recoveryParam=e.v:e.recoveryParam=1-e.v%2;else if(e.v==null)e.v=27+e.recoveryParam;else{let i=e.v===0||e.v===1?e.v:1-e.v%2;e.recoveryParam!==i&&gn.throwArgumentError("signature recoveryParam mismatch v","signature",t)}e.r==null||!Pt(e.r)?gn.throwArgumentError("signature missing or invalid r","signature",t):e.r=ur(e.r,32),e.s==null||!Pt(e.s)?gn.throwArgumentError("signature missing or invalid s","signature",t):e.s=ur(e.s,32);let r=je(e.s);r[0]>=128&&gn.throwArgumentError("signature s out of range","signature",t),e.recoveryParam&&(r[0]|=128);let n=Ve(r);e._vs&&(Pt(e._vs)||gn.throwArgumentError("signature invalid _vs","signature",t),e._vs=ur(e._vs,32)),e._vs==null?e._vs=n:e._vs!==n&&gn.throwArgumentError("signature _vs mismatch v and s","signature",t)}return e.yParityAndS=e._vs,e.compact=e.r+e.yParityAndS.substring(2),e}s(ga,"splitSignature");function T0(t){return t=ga(t),Ve(sr([t.r,t.s,t.recoveryParam?"0x1c":"0x1b"]))}s(T0,"joinSignature");var Ag="bignumber/5.7.0";var M0=mS.default.BN,mc=new ve(Ag),l3={},hS=9007199254740991;function gS(t){return t!=null&&(ze.isBigNumber(t)||typeof t=="number"&&t%1===0||typeof t=="string"&&!!t.match(/^-?[0-9]+$/)||Pt(t)||typeof t=="bigint"||eo(t))}s(gS,"isBigNumberish");var pS=!1,ze=class{constructor(e,r){e!==l3&&mc.throwError("cannot call constructor directly; use BigNumber.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}fromTwos(e){return as(br(this).fromTwos(e))}toTwos(e){return as(br(this).toTwos(e))}abs(){return this._hex[0]==="-"?ze.from(this._hex.substring(1)):this}add(e){return as(br(this).add(br(e)))}sub(e){return as(br(this).sub(br(e)))}div(e){return ze.from(e).isZero()&&to("division-by-zero","div"),as(br(this).div(br(e)))}mul(e){return as(br(this).mul(br(e)))}mod(e){let r=br(e);return r.isNeg()&&to("division-by-zero","mod"),as(br(this).umod(r))}pow(e){let r=br(e);return r.isNeg()&&to("negative-power","pow"),as(br(this).pow(r))}and(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","and"),as(br(this).and(r))}or(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","or"),as(br(this).or(r))}xor(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","xor"),as(br(this).xor(r))}mask(e){return(this.isNegative()||e<0)&&to("negative-width","mask"),as(br(this).maskn(e))}shl(e){return(this.isNegative()||e<0)&&to("negative-width","shl"),as(br(this).shln(e))}shr(e){return(this.isNegative()||e<0)&&to("negative-width","shr"),as(br(this).shrn(e))}eq(e){return br(this).eq(br(e))}lt(e){return br(this).lt(br(e))}lte(e){return br(this).lte(br(e))}gt(e){return br(this).gt(br(e))}gte(e){return br(this).gte(br(e))}isNegative(){return this._hex[0]==="-"}isZero(){return br(this).isZero()}toNumber(){try{return br(this).toNumber()}catch{to("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch{}return mc.throwError("this platform does not support BigInt",ve.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(arguments[0]===10?pS||(pS=!0,mc.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):arguments[0]===16?mc.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",ve.errors.UNEXPECTED_ARGUMENT,{}):mc.throwError("BigNumber.toString does not accept parameters",ve.errors.UNEXPECTED_ARGUMENT,{})),br(this).toString(10)}toHexString(){return this._hex}toJSON(e){return{type:"BigNumber",hex:this.toHexString()}}static from(e){if(e instanceof ze)return e;if(typeof e=="string")return e.match(/^-?0x[0-9a-f]+$/i)?new ze(l3,R0(e)):e.match(/^-?[0-9]+$/)?new ze(l3,R0(new M0(e))):mc.throwArgumentError("invalid BigNumber string","value",e);if(typeof e=="number")return e%1&&to("underflow","BigNumber.from",e),(e>=hS||e<=-hS)&&to("overflow","BigNumber.from",e),ze.from(String(e));let r=e;if(typeof r=="bigint")return ze.from(r.toString());if(eo(r))return ze.from(Ve(r));if(r)if(r.toHexString){let n=r.toHexString();if(typeof n=="string")return ze.from(n)}else{let n=r._hex;if(n==null&&r.type==="BigNumber"&&(n=r.hex),typeof n=="string"&&(Pt(n)||n[0]==="-"&&Pt(n.substring(1))))return ze.from(n)}return mc.throwArgumentError("invalid BigNumber value","value",e)}static isBigNumber(e){return!!(e&&e._isBigNumber)}};s(ze,"BigNumber");function R0(t){if(typeof t!="string")return R0(t.toString(16));if(t[0]==="-")return t=t.substring(1),t[0]==="-"&&mc.throwArgumentError("invalid hex","value",t),t=R0(t),t==="0x00"?t:"-"+t;if(t.substring(0,2)!=="0x"&&(t="0x"+t),t==="0x")return"0x00";for(t.length%2&&(t="0x0"+t.substring(2));t.length>4&&t.substring(0,4)==="0x00";)t="0x"+t.substring(4);return t}s(R0,"toHex");function as(t){return ze.from(R0(t))}s(as,"toBigNumber");function br(t){let e=ze.from(t).toHexString();return e[0]==="-"?new M0("-"+e.substring(3),16):new M0(e.substring(2),16)}s(br,"toBN");function to(t,e,r){let n={fault:t,operation:e};return r!=null&&(n.value=r),mc.throwError(t,ve.errors.NUMERIC_FAULT,n)}s(to,"throwFault");function u3(t){return new M0(t,36).toString(16)}s(u3,"_base36To16");function d3(t){return new M0(t,16).toString(36)}s(d3,"_base16To36");var Ui=new ve(Ag),B0={},vS=ze.from(0),yS=ze.from(-1);function xS(t,e,r,n){let i={fault:e,operation:r};return n!==void 0&&(i.value=n),Ui.throwError(t,ve.errors.NUMERIC_FAULT,i)}s(xS,"throwFault");var D0="0";for(;D0.length<256;)D0+=D0;function h3(t){if(typeof t!="number")try{t=ze.from(t).toNumber()}catch{}return typeof t=="number"&&t>=0&&t<=256&&!(t%1)?"1"+D0.substring(0,t):Ui.throwArgumentError("invalid decimal size","decimals",t)}s(h3,"getMultiplier");function Hu(t,e){e==null&&(e=0);let r=h3(e);t=ze.from(t);let n=t.lt(vS);n&&(t=t.mul(yS));let i=t.mod(r).toString();for(;i.length<r.length-1;)i="0"+i;i=i.match(/^([0-9]*[1-9]|0)(0*)/)[1];let o=t.div(r).toString();return r.length===1?t=o:t=o+"."+i,n&&(t="-"+t),t}s(Hu,"formatFixed");function ro(t,e){e==null&&(e=0);let r=h3(e);(typeof t!="string"||!t.match(/^-?[0-9.]+$/))&&Ui.throwArgumentError("invalid decimal value","value",t);let n=t.substring(0,1)==="-";n&&(t=t.substring(1)),t==="."&&Ui.throwArgumentError("missing value","value",t);let i=t.split(".");i.length>2&&Ui.throwArgumentError("too many decimal points","value",t);let o=i[0],a=i[1];for(o||(o="0"),a||(a="0");a[a.length-1]==="0";)a=a.substring(0,a.length-1);for(a.length>r.length-1&&xS("fractional component exceeds decimals","underflow","parseFixed"),a===""&&(a="0");a.length<r.length-1;)a+="0";let f=ze.from(o),l=ze.from(a),u=f.mul(r).add(l);return n&&(u=u.mul(yS)),u}s(ro,"parseFixed");var ba=class{constructor(e,r,n,i){e!==B0&&Ui.throwError("cannot use FixedFormat constructor; use FixedFormat.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.signed=r,this.width=n,this.decimals=i,this.name=(r?"":"u")+"fixed"+String(n)+"x"+String(i),this._multiplier=h3(i),Object.freeze(this)}static from(e){if(e instanceof ba)return e;typeof e=="number"&&(e=`fixed128x${e}`);let r=!0,n=128,i=18;if(typeof e=="string"){if(e!=="fixed")if(e==="ufixed")r=!1;else{let o=e.match(/^(u?)fixed([0-9]+)x([0-9]+)$/);o||Ui.throwArgumentError("invalid fixed format","format",e),r=o[1]!=="u",n=parseInt(o[2]),i=parseInt(o[3])}}else if(e){let o=s((a,f,l)=>e[a]==null?l:(typeof e[a]!==f&&Ui.throwArgumentError("invalid fixed format ("+a+" not "+f+")","format."+a,e[a]),e[a]),"check");r=o("signed","boolean",r),n=o("width","number",n),i=o("decimals","number",i)}return n%8&&Ui.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",n),i>80&&Ui.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",i),new ba(B0,r,n,i)}};s(ba,"FixedFormat");var cn=class{constructor(e,r,n,i){e!==B0&&Ui.throwError("cannot use FixedNumber constructor; use FixedNumber.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=i,this._hex=r,this._value=n,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(e){this.format.name!==e.format.name&&Ui.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}addUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.add(n),this.format.decimals,this.format)}subUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.sub(n),this.format.decimals,this.format)}mulUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}floor(){let e=this.toString().split(".");e.length===1&&e.push("0");let r=cn.from(e[0],this.format),n=!e[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(bS.toFormat(r.format))),r}ceiling(){let e=this.toString().split(".");e.length===1&&e.push("0");let r=cn.from(e[0],this.format),n=!e[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(bS.toFormat(r.format))),r}round(e){e==null&&(e=0);let r=this.toString().split(".");if(r.length===1&&r.push("0"),(e<0||e>80||e%1)&&Ui.throwArgumentError("invalid decimal count","decimals",e),r[1].length<=e)return this;let n=cn.from("1"+D0.substring(0,e),this.format),i=O$.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(i).floor().divUnsafe(n)}isZero(){return this._value==="0.0"||this._value==="0"}isNegative(){return this._value[0]==="-"}toString(){return this._value}toHexString(e){if(e==null)return this._hex;e%8&&Ui.throwArgumentError("invalid byte width","width",e);let r=ze.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return ur(r,e/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(e){return cn.fromString(this._value,e)}static fromValue(e,r,n){return n==null&&r!=null&&!gS(r)&&(n=r,r=null),r==null&&(r=0),n==null&&(n="fixed"),cn.fromString(Hu(e,r),ba.from(n))}static fromString(e,r){r==null&&(r="fixed");let n=ba.from(r),i=ro(e,n.decimals);!n.signed&&i.lt(vS)&&xS("unsigned value cannot be negative","overflow","value",e);let o=null;n.signed?o=i.toTwos(n.width).toHexString():(o=i.toHexString(),o=ur(o,n.width/8));let a=Hu(i,n.decimals);return new cn(B0,o,a,n)}static fromBytes(e,r){r==null&&(r="fixed");let n=ba.from(r);if(je(e).length>n.width/8)throw new Error("overflow");let i=ze.from(e);n.signed&&(i=i.fromTwos(n.width));let o=i.toTwos((n.signed?0:1)+n.width).toHexString(),a=Hu(i,n.decimals);return new cn(B0,o,a,n)}static from(e,r){if(typeof e=="string")return cn.fromString(e,r);if(eo(e))return cn.fromBytes(e,r);try{return cn.fromValue(e,0,r)}catch(n){if(n.code!==ve.errors.INVALID_ARGUMENT)throw n}return Ui.throwArgumentError("invalid FixedNumber value","value",e)}static isFixedNumber(e){return!!(e&&e._isFixedNumber)}};s(cn,"FixedNumber");var bS=cn.from(1),O$=cn.from("0.5");var wS="properties/5.7.0";var F$=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},Eg=new ve(wS);function Pe(t,e,r){Object.defineProperty(t,e,{enumerable:!0,value:r,writable:!1})}s(Pe,"defineReadOnly");function ln(t,e){for(let r=0;r<32;r++){if(t[e])return t[e];if(!t.prototype||typeof t.prototype!="object")break;t=Object.getPrototypeOf(t.prototype).constructor}return null}s(ln,"getStatic");function Nr(t){return F$(this,void 0,void 0,function*(){let e=Object.keys(t).map(n=>{let i=t[n];return Promise.resolve(i).then(o=>({key:n,value:o}))});return(yield Promise.all(e)).reduce((n,i)=>(n[i.key]=i.value,n),{})})}s(Nr,"resolveProperties");function zu(t,e){(!t||typeof t!="object")&&Eg.throwArgumentError("invalid object","object",t),Object.keys(t).forEach(r=>{e[r]||Eg.throwArgumentError("invalid object key - "+r,"transaction:"+r,t)})}s(zu,"checkProperties");function Er(t){let e={};for(let r in t)e[r]=t[r];return e}s(Er,"shallowCopy");var N$={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function _S(t){if(t==null||N$[typeof t])return!0;if(Array.isArray(t)||typeof t=="object"){if(!Object.isFrozen(t))return!1;let e=Object.keys(t);for(let r=0;r<e.length;r++){let n=null;try{n=t[e[r]]}catch{continue}if(!_S(n))return!1}return!0}return Eg.throwArgumentError(`Cannot deepCopy ${typeof t}`,"object",t)}s(_S,"_isFrozen");function L$(t){if(_S(t))return t;if(Array.isArray(t))return Object.freeze(t.map(e=>fn(e)));if(typeof t=="object"){let e={};for(let r in t){let n=t[r];n!==void 0&&Pe(e,r,fn(n))}return e}return Eg.throwArgumentError(`Cannot deepCopy ${typeof t}`,"object",t)}s(L$,"_deepCopy");function fn(t){return L$(t)}s(fn,"deepCopy");var cs=class{constructor(e){for(let r in e)this[r]=fn(e[r])}};s(cs,"Description");var va="abi/5.7.0";var _r=new ve(va),Il={},AS={calldata:!0,memory:!0,storage:!0},U$={calldata:!0,memory:!0};function Cg(t,e){if(t==="bytes"||t==="string"){if(AS[e])return!0}else if(t==="address"){if(e==="payable")return!0}else if((t.indexOf("[")>=0||t==="tuple")&&U$[e])return!0;return(AS[e]||e==="payable")&&_r.throwArgumentError("invalid modifier","name",e),!1}s(Cg,"checkModifier");function j$(t,e){let r=t;function n(f){_r.throwArgumentError(`unexpected character at position ${f}`,"param",t)}s(n,"throwError"),t=t.replace(/\s/g," ");function i(f){let l={type:"",name:"",parent:f,state:{allowType:!0}};return e&&(l.indexed=!1),l}s(i,"newNode");let o={type:"",name:"",state:{allowType:!0}},a=o;for(let f=0;f<t.length;f++){let l=t[f];switch(l){case"(":a.state.allowType&&a.type===""?a.type="tuple":a.state.allowParams||n(f),a.state.allowType=!1,a.type=$u(a.type),a.components=[i(a)],a=a.components[0];break;case")":delete a.state,a.name==="indexed"&&(e||n(f),a.indexed=!0,a.name=""),Cg(a.type,a.name)&&(a.name=""),a.type=$u(a.type);let u=a;a=a.parent,a||n(f),delete u.parent,a.state.allowParams=!1,a.state.allowName=!0,a.state.allowArray=!0;break;case",":delete a.state,a.name==="indexed"&&(e||n(f),a.indexed=!0,a.name=""),Cg(a.type,a.name)&&(a.name=""),a.type=$u(a.type);let h=i(a.parent);a.parent.components.push(h),delete a.parent,a=h;break;case" ":a.state.allowType&&a.type!==""&&(a.type=$u(a.type),delete a.state.allowType,a.state.allowName=!0,a.state.allowParams=!0),a.state.allowName&&a.name!==""&&(a.name==="indexed"?(e||n(f),a.indexed&&n(f),a.indexed=!0,a.name=""):Cg(a.type,a.name)?a.name="":a.state.allowName=!1);break;case"[":a.state.allowArray||n(f),a.type+=l,a.state.allowArray=!1,a.state.allowName=!1,a.state.readArray=!0;break;case"]":a.state.readArray||n(f),a.type+=l,a.state.readArray=!1,a.state.allowArray=!0,a.state.allowName=!0;break;default:a.state.allowType?(a.type+=l,a.state.allowParams=!0,a.state.allowArray=!0):a.state.allowName?(a.name+=l,delete a.state.allowArray):a.state.readArray?a.type+=l:n(f)}}return a.parent&&_r.throwArgumentError("unexpected eof","param",t),delete o.state,a.name==="indexed"?(e||n(r.length-7),a.indexed&&n(r.length-7),a.indexed=!0,a.name=""):Cg(a.type,a.name)&&(a.name=""),o.type=$u(o.type),o}s(j$,"parseParamType");function Sg(t,e){for(let r in e)Pe(t,r,e[r])}s(Sg,"populate");var vr=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),q$=new RegExp(/^(.*)\[([0-9]*)\]$/),Yr=class{constructor(e,r){e!==Il&&_r.throwError("use fromString",ve.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),Sg(this,r);let n=this.type.match(q$);n?Sg(this,{arrayLength:parseInt(n[2]||"-1"),arrayChildren:Yr.fromObject({type:n[1],components:this.components}),baseType:"array"}):Sg(this,{arrayLength:null,arrayChildren:null,baseType:this.components!=null?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json){let n={type:this.baseType==="tuple"?"tuple":this.type,name:this.name||void 0};return typeof this.indexed=="boolean"&&(n.indexed=this.indexed),this.components&&(n.components=this.components.map(i=>JSON.parse(i.format(e)))),JSON.stringify(n)}let r="";return this.baseType==="array"?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):this.baseType==="tuple"?(e!==vr.sighash&&(r+=this.type),r+="("+this.components.map(n=>n.format(e)).join(e===vr.full?", ":",")+")"):r+=this.type,e!==vr.sighash&&(this.indexed===!0&&(r+=" indexed"),e===vr.full&&this.name&&(r+=" "+this.name)),r}static from(e,r){return typeof e=="string"?Yr.fromString(e,r):Yr.fromObject(e)}static fromObject(e){return Yr.isParamType(e)?e:new Yr(Il,{name:e.name||null,type:$u(e.type),indexed:e.indexed==null?null:!!e.indexed,components:e.components?e.components.map(Yr.fromObject):null})}static fromString(e,r){function n(i){return Yr.fromObject({name:i.name,type:i.type,indexed:i.indexed,components:i.components})}return s(n,"ParamTypify"),n(j$(e,!!r))}static isParamType(e){return!!(e!=null&&e._isParamType)}};s(Yr,"ParamType");function P0(t,e){return z$(t).map(r=>Yr.fromString(r,e))}s(P0,"parseParams");var Si=class{constructor(e,r){e!==Il&&_r.throwError("use a static from method",ve.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),Sg(this,r),this._isFragment=!0,Object.freeze(this)}static from(e){return Si.isFragment(e)?e:typeof e=="string"?Si.fromString(e):Si.fromObject(e)}static fromObject(e){if(Si.isFragment(e))return e;switch(e.type){case"function":return ri.fromObject(e);case"event":return Ci.fromObject(e);case"constructor":return ti.fromObject(e);case"error":return fs.fromObject(e);case"fallback":case"receive":return null}return _r.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return e=e.replace(/\s/g," "),e=e.replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," "),e=e.trim(),e.split(" ")[0]==="event"?Ci.fromString(e.substring(5).trim()):e.split(" ")[0]==="function"?ri.fromString(e.substring(8).trim()):e.split("(")[0].trim()==="constructor"?ti.fromString(e.trim()):e.split(" ")[0]==="error"?fs.fromString(e.substring(5).trim()):_r.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!!(e&&e._isFragment)}};s(Si,"Fragment");var Ci=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="event "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",e!==vr.sighash&&this.anonymous&&(r+="anonymous "),r.trim()}static from(e){return typeof e=="string"?Ci.fromString(e):Ci.fromObject(e)}static fromObject(e){if(Ci.isEventFragment(e))return e;e.type!=="event"&&_r.throwArgumentError("invalid event object","value",e);let r={name:O0(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],type:"event"};return new Ci(Il,r)}static fromString(e){let r=e.match(F0);r||_r.throwArgumentError("invalid event string","value",e);let n=!1;return r[3].split(" ").forEach(i=>{switch(i.trim()){case"anonymous":n=!0;break;case"":break;default:_r.warn("unknown modifier: "+i)}}),Ci.fromObject({name:r[1].trim(),anonymous:n,inputs:P0(r[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&e.type==="event"}};s(Ci,"EventFragment");function CS(t,e){e.gas=null;let r=t.split("@");return r.length!==1?(r.length>2&&_r.throwArgumentError("invalid human-readable ABI signature","value",t),r[1].match(/^[0-9]+$/)||_r.throwArgumentError("invalid human-readable ABI signature gas","value",t),e.gas=ze.from(r[1]),r[0]):t}s(CS,"parseGas");function SS(t,e){e.constant=!1,e.payable=!1,e.stateMutability="nonpayable",t.split(" ").forEach(r=>{switch(r.trim()){case"constant":e.constant=!0;break;case"payable":e.payable=!0,e.stateMutability="payable";break;case"nonpayable":e.payable=!1,e.stateMutability="nonpayable";break;case"pure":e.constant=!0,e.stateMutability="pure";break;case"view":e.constant=!0,e.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+r)}})}s(SS,"parseModifiers");function IS(t){let e={constant:!1,payable:!0,stateMutability:"payable"};return t.stateMutability!=null?(e.stateMutability=t.stateMutability,e.constant=e.stateMutability==="view"||e.stateMutability==="pure",t.constant!=null&&!!t.constant!==e.constant&&_r.throwArgumentError("cannot have constant function with mutability "+e.stateMutability,"value",t),e.payable=e.stateMutability==="payable",t.payable!=null&&!!t.payable!==e.payable&&_r.throwArgumentError("cannot have payable function with mutability "+e.stateMutability,"value",t)):t.payable!=null?(e.payable=!!t.payable,t.constant==null&&!e.payable&&t.type!=="constructor"&&_r.throwArgumentError("unable to determine stateMutability","value",t),e.constant=!!t.constant,e.constant?e.stateMutability="view":e.stateMutability=e.payable?"payable":"nonpayable",e.payable&&e.constant&&_r.throwArgumentError("cannot have constant payable function","value",t)):t.constant!=null?(e.constant=!!t.constant,e.payable=!e.constant,e.stateMutability=e.constant?"view":"payable"):t.type!=="constructor"&&_r.throwArgumentError("unable to determine stateMutability","value",t),e}s(IS,"verifyState");var ti=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"constructor",stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});e===vr.sighash&&_r.throwError("cannot format a constructor for sighash",ve.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let r="constructor("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ";return this.stateMutability&&this.stateMutability!=="nonpayable"&&(r+=this.stateMutability+" "),r.trim()}static from(e){return typeof e=="string"?ti.fromString(e):ti.fromObject(e)}static fromObject(e){if(ti.isConstructorFragment(e))return e;e.type!=="constructor"&&_r.throwArgumentError("invalid constructor object","value",e);let r=IS(e);r.constant&&_r.throwArgumentError("constructor cannot be constant","value",e);let n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],payable:r.payable,stateMutability:r.stateMutability,gas:e.gas?ze.from(e.gas):null};return new ti(Il,n)}static fromString(e){let r={type:"constructor"};e=CS(e,r);let n=e.match(F0);return(!n||n[1].trim()!=="constructor")&&_r.throwArgumentError("invalid constructor string","value",e),r.inputs=P0(n[2].trim(),!1),SS(n[3].trim(),r),ti.fromObject(r)}static isConstructorFragment(e){return e&&e._isFragment&&e.type==="constructor"}};s(ti,"ConstructorFragment");var ri=class extends ti{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map(n=>JSON.parse(n.format(e))),outputs:this.outputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="function "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",e!==vr.sighash&&(this.stateMutability?this.stateMutability!=="nonpayable"&&(r+=this.stateMutability+" "):this.constant&&(r+="view "),this.outputs&&this.outputs.length&&(r+="returns ("+this.outputs.map(n=>n.format(e)).join(", ")+") "),this.gas!=null&&(r+="@"+this.gas.toString()+" ")),r.trim()}static from(e){return typeof e=="string"?ri.fromString(e):ri.fromObject(e)}static fromObject(e){if(ri.isFunctionFragment(e))return e;e.type!=="function"&&_r.throwArgumentError("invalid function object","value",e);let r=IS(e),n={type:e.type,name:O0(e.name),constant:r.constant,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],outputs:e.outputs?e.outputs.map(Yr.fromObject):[],payable:r.payable,stateMutability:r.stateMutability,gas:e.gas?ze.from(e.gas):null};return new ri(Il,n)}static fromString(e){let r={type:"function"};e=CS(e,r);let n=e.split(" returns ");n.length>2&&_r.throwArgumentError("invalid function string","value",e);let i=n[0].match(F0);if(i||_r.throwArgumentError("invalid function signature","value",e),r.name=i[1].trim(),r.name&&O0(r.name),r.inputs=P0(i[2],!1),SS(i[3].trim(),r),n.length>1){let o=n[1].match(F0);(o[1].trim()!=""||o[3].trim()!="")&&_r.throwArgumentError("unexpected tokens","value",e),r.outputs=P0(o[2],!1)}else r.outputs=[];return ri.fromObject(r)}static isFunctionFragment(e){return e&&e._isFragment&&e.type==="function"}};s(ri,"FunctionFragment");function ES(t){let e=t.format();return(e==="Error(string)"||e==="Panic(uint256)")&&_r.throwArgumentError(`cannot specify user defined ${e} error`,"fragment",t),t}s(ES,"checkForbidden");var fs=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="error "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",r.trim()}static from(e){return typeof e=="string"?fs.fromString(e):fs.fromObject(e)}static fromObject(e){if(fs.isErrorFragment(e))return e;e.type!=="error"&&_r.throwArgumentError("invalid error object","value",e);let r={type:e.type,name:O0(e.name),inputs:e.inputs?e.inputs.map(Yr.fromObject):[]};return ES(new fs(Il,r))}static fromString(e){let r={type:"error"},n=e.match(F0);return n||_r.throwArgumentError("invalid error signature","value",e),r.name=n[1].trim(),r.name&&O0(r.name),r.inputs=P0(n[2],!1),ES(fs.fromObject(r))}static isErrorFragment(e){return e&&e._isFragment&&e.type==="error"}};s(fs,"ErrorFragment");function $u(t){return t.match(/^uint($|[^1-9])/)?t="uint256"+t.substring(4):t.match(/^int($|[^1-9])/)&&(t="int256"+t.substring(3)),t}s($u,"verifyType");var H$=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function O0(t){return(!t||!t.match(H$))&&_r.throwArgumentError(`invalid identifier "${t}"`,"value",t),t}s(O0,"verifyIdentifier");var F0=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");function z$(t){t=t.trim();let e=[],r="",n=0;for(let i=0;i<t.length;i++){let o=t[i];o===","&&n===0?(e.push(r),r=""):(r+=o,o==="("?n++:o===")"&&(n--,n===-1&&_r.throwArgumentError("unbalanced parenthesis","value",t)))}return r&&e.push(r),e}s(z$,"splitNesting");var p3=new ve(va);function Gu(t){let e=[],r=s(function(n,i){if(!!Array.isArray(i))for(let o in i){let a=n.slice();a.push(o);try{r(a,i[o])}catch(f){e.push({path:a,error:f})}}},"checkErrors");return r([],t),e}s(Gu,"checkResultErrors");var An=class{constructor(e,r,n,i){this.name=e,this.type=r,this.localName=n,this.dynamic=i}_throwError(e,r){p3.throwArgumentError(e,this.localName,r)}};s(An,"Coder");var yf=class{constructor(e){Pe(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return Mn(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(sr(e._data))}writeBytes(e){let r=je(e),n=r.length%this.wordSize;return n&&(r=sr([r,this._padding.slice(n)])),this._writeData(r)}_getValue(e){let r=je(ze.from(e));return r.length>this.wordSize&&p3.throwError("value out-of-bounds",ve.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:r.length}),r.length%this.wordSize&&(r=sr([this._padding.slice(r.length%this.wordSize),r])),r}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){let e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,r=>{this._data[e]=this._getValue(r)}}};s(yf,"Writer");var xf=class{constructor(e,r,n,i){Pe(this,"_data",je(e)),Pe(this,"wordSize",r||32),Pe(this,"_coerceFunc",n),Pe(this,"allowLoose",i),this._offset=0}get data(){return Ve(this._data)}get consumed(){return this._offset}static coerce(e,r){let n=e.match("^u?int([0-9]+)$");return n&&parseInt(n[1])<=48&&(r=r.toNumber()),r}coerce(e,r){return this._coerceFunc?this._coerceFunc(e,r):xf.coerce(e,r)}_peekBytes(e,r,n){let i=Math.ceil(r/this.wordSize)*this.wordSize;return this._offset+i>this._data.length&&(this.allowLoose&&n&&this._offset+r<=this._data.length?i=r:p3.throwError("data out-of-bounds",ve.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+i})),this._data.slice(this._offset,this._offset+i)}subReader(e){return new xf(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,r){let n=this._peekBytes(0,e,!!r);return this._offset+=n.length,n.slice(0,e)}readValue(){return ze.from(this.readBytes(this.wordSize))}};s(xf,"Reader");var TS=Js(kS());function or(t){return"0x"+TS.default.keccak_256(je(t))}s(or,"keccak256");var kg={};vl(kg,{decode:()=>N0,encode:()=>gc});var MS="rlp/5.7.0";var ya=new ve(MS);function RS(t){let e=[];for(;t;)e.unshift(t&255),t>>=8;return e}s(RS,"arrayifyInteger");function BS(t,e,r){let n=0;for(let i=0;i<r;i++)n=n*256+t[e+i];return n}s(BS,"unarrayifyInteger");function PS(t){if(Array.isArray(t)){let n=[];if(t.forEach(function(o){n=n.concat(PS(o))}),n.length<=55)return n.unshift(192+n.length),n;let i=RS(n.length);return i.unshift(247+i.length),i.concat(n)}pc(t)||ya.throwArgumentError("RLP object must be BytesLike","object",t);let e=Array.prototype.slice.call(je(t));if(e.length===1&&e[0]<=127)return e;if(e.length<=55)return e.unshift(128+e.length),e;let r=RS(e.length);return r.unshift(183+r.length),r.concat(e)}s(PS,"_encode");function gc(t){return Ve(PS(t))}s(gc,"encode");function DS(t,e,r,n){let i=[];for(;r<e+1+n;){let o=OS(t,r);i.push(o.result),r+=o.consumed,r>e+1+n&&ya.throwError("child data too short",ve.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:i}}s(DS,"_decodeChildren");function OS(t,e){if(t.length===0&&ya.throwError("data too short",ve.errors.BUFFER_OVERRUN,{}),t[e]>=248){let r=t[e]-247;e+1+r>t.length&&ya.throwError("data short segment too short",ve.errors.BUFFER_OVERRUN,{});let n=BS(t,e+1,r);return e+1+r+n>t.length&&ya.throwError("data long segment too short",ve.errors.BUFFER_OVERRUN,{}),DS(t,e,e+1+r,r+n)}else if(t[e]>=192){let r=t[e]-192;return e+1+r>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{}),DS(t,e,e+1,r)}else if(t[e]>=184){let r=t[e]-183;e+1+r>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{});let n=BS(t,e+1,r);e+1+r+n>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{});let i=Ve(t.slice(e+1+r,e+1+r+n));return{consumed:1+r+n,result:i}}else if(t[e]>=128){let r=t[e]-128;e+1+r>t.length&&ya.throwError("data too short",ve.errors.BUFFER_OVERRUN,{});let n=Ve(t.slice(e+1,e+1+r));return{consumed:1+r,result:n}}return{consumed:1,result:Ve(t[e])}}s(OS,"_decode");function N0(t){let e=je(t),r=OS(e,0);return r.consumed!==e.length&&ya.throwArgumentError("invalid rlp data","data",t),r.result}s(N0,"decode");var FS="address/5.7.0";var wf=new ve(FS);function NS(t){Pt(t,20)||wf.throwArgumentError("invalid address","address",t),t=t.toLowerCase();let e=t.substring(2).split(""),r=new Uint8Array(40);for(let i=0;i<40;i++)r[i]=e[i].charCodeAt(0);let n=je(or(r));for(let i=0;i<40;i+=2)n[i>>1]>>4>=8&&(e[i]=e[i].toUpperCase()),(n[i>>1]&15)>=8&&(e[i+1]=e[i+1].toUpperCase());return"0x"+e.join("")}s(NS,"getChecksumAddress");var $$=9007199254740991;function G$(t){return Math.log10?Math.log10(t):Math.log(t)/Math.LN10}s(G$,"log10");var m3={};for(let t=0;t<10;t++)m3[String(t)]=String(t);for(let t=0;t<26;t++)m3[String.fromCharCode(65+t)]=String(10+t);var LS=Math.floor(G$($$));function US(t){t=t.toUpperCase(),t=t.substring(4)+t.substring(0,2)+"00";let e=t.split("").map(n=>m3[n]).join("");for(;e.length>=LS;){let n=e.substring(0,LS);e=parseInt(n,10)%97+e.substring(n.length)}let r=String(98-parseInt(e,10)%97);for(;r.length<2;)r="0"+r;return r}s(US,"ibanChecksum");function ar(t){let e=null;if(typeof t!="string"&&wf.throwArgumentError("invalid address","address",t),t.match(/^(0x)?[0-9a-fA-F]{40}$/))t.substring(0,2)!=="0x"&&(t="0x"+t),e=NS(t),t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&e!==t&&wf.throwArgumentError("bad address checksum","address",t);else if(t.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(t.substring(2,4)!==US(t)&&wf.throwArgumentError("bad icap checksum","address",t),e=u3(t.substring(4));e.length<40;)e="0"+e;e=NS("0x"+e)}else wf.throwArgumentError("invalid address","address",t);return e}s(ar,"getAddress");function jS(t){try{return ar(t),!0}catch{}return!1}s(jS,"isAddress");function qS(t){let e=d3(ar(t).substring(2)).toUpperCase();for(;e.length<30;)e="0"+e;return"XE"+US("XE00"+e)+e}s(qS,"getIcapAddress");function kl(t){let e=null;try{e=ar(t.from)}catch{wf.throwArgumentError("missing from address","transaction",t)}let r=Ts(je(ze.from(t.nonce).toHexString()));return ar(Fr(or(gc([e,r])),12))}s(kl,"getContractAddress");function HS(t,e,r){return Ei(e)!==32&&wf.throwArgumentError("salt must be 32 bytes","salt",e),Ei(r)!==32&&wf.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),ar(Fr(or(sr(["0xff",ar(t),e,r])),12))}s(HS,"getCreate2Address");var L0=class extends An{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,r){try{r=ar(r)}catch(n){this._throwError(n.message,r)}return e.writeValue(r)}decode(e){return ar(ur(e.readValue().toHexString(),20))}};s(L0,"AddressCoder");var U0=class extends An{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,r){return this.coder.encode(e,r)}decode(e){return this.coder.decode(e)}};s(U0,"AnonymousCoder");var Ku=new ve(va);function g3(t,e,r){let n=null;if(Array.isArray(r))n=r;else if(r&&typeof r=="object"){let l={};n=e.map(u=>{let h=u.localName;return h||Ku.throwError("cannot encode object for signature with missing names",ve.errors.INVALID_ARGUMENT,{argument:"values",coder:u,value:r}),l[h]&&Ku.throwError("cannot encode object for signature with duplicate names",ve.errors.INVALID_ARGUMENT,{argument:"values",coder:u,value:r}),l[h]=!0,r[h]})}else Ku.throwArgumentError("invalid tuple value","tuple",r);e.length!==n.length&&Ku.throwArgumentError("types/value length mismatch","tuple",r);let i=new yf(t.wordSize),o=new yf(t.wordSize),a=[];e.forEach((l,u)=>{let h=n[u];if(l.dynamic){let g=o.length;l.encode(o,h);let x=i.writeUpdatableValue();a.push(_=>{x(_+g)})}else l.encode(i,h)}),a.forEach(l=>{l(i.length)});let f=t.appendWriter(i);return f+=t.appendWriter(o),f}s(g3,"pack");function b3(t,e){let r=[],n=t.subReader(0);e.forEach(o=>{let a=null;if(o.dynamic){let f=t.readValue(),l=n.subReader(f.toNumber());try{a=o.decode(l)}catch(u){if(u.code===ve.errors.BUFFER_OVERRUN)throw u;a=u,a.baseType=o.name,a.name=o.localName,a.type=o.type}}else try{a=o.decode(t)}catch(f){if(f.code===ve.errors.BUFFER_OVERRUN)throw f;a=f,a.baseType=o.name,a.name=o.localName,a.type=o.type}a!=null&&r.push(a)});let i=e.reduce((o,a)=>{let f=a.localName;return f&&(o[f]||(o[f]=0),o[f]++),o},{});e.forEach((o,a)=>{let f=o.localName;if(!f||i[f]!==1||(f==="length"&&(f="_length"),r[f]!=null))return;let l=r[a];l instanceof Error?Object.defineProperty(r,f,{enumerable:!0,get:()=>{throw l}}):r[f]=l});for(let o=0;o<r.length;o++){let a=r[o];a instanceof Error&&Object.defineProperty(r,o,{enumerable:!0,get:()=>{throw a}})}return Object.freeze(r)}s(b3,"unpack");var j0=class extends An{constructor(e,r,n){let i=e.type+"["+(r>=0?r:"")+"]",o=r===-1||e.dynamic;super("array",i,n,o),this.coder=e,this.length=r}defaultValue(){let e=this.coder.defaultValue(),r=[];for(let n=0;n<this.length;n++)r.push(e);return r}encode(e,r){Array.isArray(r)||this._throwError("expected array value",r);let n=this.length;n===-1&&(n=r.length,e.writeValue(r.length)),Ku.checkArgumentCount(r.length,n,"coder array"+(this.localName?" "+this.localName:""));let i=[];for(let o=0;o<r.length;o++)i.push(this.coder);return g3(e,i,r)}decode(e){let r=this.length;r===-1&&(r=e.readValue().toNumber(),r*32>e._data.length&&Ku.throwError("insufficient data length",ve.errors.BUFFER_OVERRUN,{length:e._data.length,count:r}));let n=[];for(let i=0;i<r;i++)n.push(new U0(this.coder));return e.coerce(this.name,b3(e,n))}};s(j0,"ArrayCoder");var q0=class extends An{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,r){return e.writeValue(r?1:0)}decode(e){return e.coerce(this.type,!e.readValue().isZero())}};s(q0,"BooleanCoder");var Vu=class extends An{constructor(e,r){super(e,e,r,!0)}defaultValue(){return"0x"}encode(e,r){r=je(r);let n=e.writeValue(r.length);return n+=e.writeBytes(r),n}decode(e){return e.readBytes(e.readValue().toNumber(),!0)}};s(Vu,"DynamicBytesCoder");var H0=class extends Vu{constructor(e){super("bytes",e)}decode(e){return e.coerce(this.name,Ve(super.decode(e)))}};s(H0,"BytesCoder");var z0=class extends An{constructor(e,r){let n="bytes"+String(e);super(n,n,r,!1),this.size=e}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+this.size*2)}encode(e,r){let n=je(r);return n.length!==this.size&&this._throwError("incorrect data length",r),e.writeBytes(n)}decode(e){return e.coerce(this.name,Ve(e.readBytes(this.size)))}};s(z0,"FixedBytesCoder");var $0=class extends An{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,r){return r!=null&&this._throwError("not null",r),e.writeBytes([])}decode(e){return e.readBytes(0),e.coerce(this.name,null)}};s($0,"NullCoder");var v3={};vl(v3,{AddressZero:()=>Tg,EtherSymbol:()=>VS,HashZero:()=>Ju,MaxInt256:()=>KS,MaxUint256:()=>Bg,MinInt256:()=>GS,NegativeOne:()=>Mg,One:()=>Rg,Two:()=>zS,WeiPerEther:()=>$S,Zero:()=>Wu});var Tg="0x0000000000000000000000000000000000000000";var Mg=ze.from(-1),Wu=ze.from(0),Rg=ze.from(1),zS=ze.from(2),$S=ze.from("1000000000000000000"),Bg=ze.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),GS=ze.from("-0x8000000000000000000000000000000000000000000000000000000000000000"),KS=ze.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");var Ju="0x0000000000000000000000000000000000000000000000000000000000000000";var VS="\u039E";var G0=class extends An{constructor(e,r,n){let i=(r?"int":"uint")+e*8;super(i,i,n,!1),this.size=e,this.signed=r}defaultValue(){return 0}encode(e,r){let n=ze.from(r),i=Bg.mask(e.wordSize*8);if(this.signed){let o=i.mask(this.size*8-1);(n.gt(o)||n.lt(o.add(Rg).mul(Mg)))&&this._throwError("value out-of-bounds",r)}else(n.lt(Wu)||n.gt(i.mask(this.size*8)))&&this._throwError("value out-of-bounds",r);return n=n.toTwos(this.size*8).mask(this.size*8),this.signed&&(n=n.fromTwos(this.size*8).toTwos(8*e.wordSize)),e.writeValue(n)}decode(e){let r=e.readValue().mask(this.size*8);return this.signed&&(r=r.fromTwos(this.size*8)),e.coerce(this.name,r)}};s(G0,"NumberCoder");var WS="strings/5.7.0";var JS=new ve(WS),ji;(function(t){t.current="",t.NFC="NFC",t.NFD="NFD",t.NFKC="NFKC",t.NFKD="NFKD"})(ji||(ji={}));var Ii;(function(t){t.UNEXPECTED_CONTINUE="unexpected continuation byte",t.BAD_PREFIX="bad codepoint prefix",t.OVERRUN="string overrun",t.MISSING_CONTINUE="missing continuation byte",t.OUT_OF_RANGE="out of UTF-8 range",t.UTF16_SURROGATE="UTF-16 surrogate",t.OVERLONG="overlong representation"})(Ii||(Ii={}));function K$(t,e,r,n,i){return JS.throwArgumentError(`invalid codepoint at offset ${e}; ${t}`,"bytes",r)}s(K$,"errorFunc");function YS(t,e,r,n,i){if(t===Ii.BAD_PREFIX||t===Ii.UNEXPECTED_CONTINUE){let o=0;for(let a=e+1;a<r.length&&r[a]>>6===2;a++)o++;return o}return t===Ii.OVERRUN?r.length-e-1:0}s(YS,"ignoreFunc");function V$(t,e,r,n,i){return t===Ii.OVERLONG?(n.push(i),0):(n.push(65533),YS(t,e,r,n,i))}s(V$,"replaceFunc");var Dg=Object.freeze({error:K$,ignore:YS,replace:V$});function x3(t,e){e==null&&(e=Dg.error),t=je(t);let r=[],n=0;for(;n<t.length;){let i=t[n++];if(i>>7===0){r.push(i);continue}let o=null,a=null;if((i&224)===192)o=1,a=127;else if((i&240)===224)o=2,a=2047;else if((i&248)===240)o=3,a=65535;else{(i&192)===128?n+=e(Ii.UNEXPECTED_CONTINUE,n-1,t,r):n+=e(Ii.BAD_PREFIX,n-1,t,r);continue}if(n-1+o>=t.length){n+=e(Ii.OVERRUN,n-1,t,r);continue}let f=i&(1<<8-o-1)-1;for(let l=0;l<o;l++){let u=t[n];if((u&192)!=128){n+=e(Ii.MISSING_CONTINUE,n,t,r),f=null;break}f=f<<6|u&63,n++}if(f!==null){if(f>1114111){n+=e(Ii.OUT_OF_RANGE,n-1-o,t,r,f);continue}if(f>=55296&&f<=57343){n+=e(Ii.UTF16_SURROGATE,n-1-o,t,r,f);continue}if(f<=a){n+=e(Ii.OVERLONG,n-1-o,t,r,f);continue}r.push(f)}}return r}s(x3,"getUtf8CodePoints");function Ar(t,e=ji.current){e!=ji.current&&(JS.checkNormalize(),t=t.normalize(e));let r=[];for(let n=0;n<t.length;n++){let i=t.charCodeAt(n);if(i<128)r.push(i);else if(i<2048)r.push(i>>6|192),r.push(i&63|128);else if((i&64512)==55296){n++;let o=t.charCodeAt(n);if(n>=t.length||(o&64512)!==56320)throw new Error("invalid utf-8 string");let a=65536+((i&1023)<<10)+(o&1023);r.push(a>>18|240),r.push(a>>12&63|128),r.push(a>>6&63|128),r.push(a&63|128)}else r.push(i>>12|224),r.push(i>>6&63|128),r.push(i&63|128)}return je(r)}s(Ar,"toUtf8Bytes");function y3(t){let e="0000"+t.toString(16);return"\\u"+e.substring(e.length-4)}s(y3,"escapeChar");function w3(t,e){return'"'+x3(t,e).map(r=>{if(r<256){switch(r){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(r>=32&&r<127)return String.fromCharCode(r)}return r<=65535?y3(r):(r-=65536,y3((r>>10&1023)+55296)+y3((r&1023)+56320))}).join("")+'"'}s(w3,"_toEscapedUtf8String");function Pg(t){return t.map(e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode((e>>10&1023)+55296,(e&1023)+56320))).join("")}s(Pg,"_toUtf8String");function ls(t,e){return Pg(x3(t,e))}s(ls,"toUtf8String");function _f(t,e=ji.current){return x3(Ar(t,e))}s(_f,"toUtf8CodePoints");function _3(t){let e=Ar(t);if(e.length>31)throw new Error("bytes32 string must be less than 32 bytes");return Ve(sr([e,Ju]).slice(0,32))}s(_3,"formatBytes32String");function A3(t){let e=je(t);if(e.length!==32)throw new Error("invalid bytes32 - not 32 bytes long");if(e[31]!==0)throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;e[r-1]===0;)r--;return ls(e.slice(0,r))}s(A3,"parseBytes32String");function W$(t){if(t.length%4!==0)throw new Error("bad data");let e=[];for(let r=0;r<t.length;r+=4)e.push(parseInt(t.substring(r,r+4),16));return e}s(W$,"bytes2");function E3(t,e){e||(e=s(function(i){return[parseInt(i,16)]},"func"));let r=0,n={};return t.split(",").forEach(i=>{let o=i.split(":");r+=parseInt(o[0],16),n[r]=e(o[1])}),n}s(E3,"createTable");function ZS(t){let e=0;return t.split(",").map(r=>{let n=r.split("-");n.length===1?n[1]="0":n[1]===""&&(n[1]="1");let i=e+parseInt(n[0],16);return e=parseInt(n[1],16),{l:i,h:e}})}s(ZS,"createRangeTable");function C3(t,e){let r=0;for(let n=0;n<e.length;n++){let i=e[n];if(r+=i.l,t>=r&&t<=r+i.h&&(t-r)%(i.d||1)===0){if(i.e&&i.e.indexOf(t-r)!==-1)continue;return i}}return null}s(C3,"matchMap");var J$=ZS("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),Y$="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map(t=>parseInt(t,16)),Z$=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],X$=E3("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),Q$=E3("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),eG=E3("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",W$),tG=ZS("80-20,2a0-,39c,32,f71,18e,7f2-f,19-7,30-4,7-5,f81-b,5,a800-20ff,4d1-1f,110,fa-6,d174-7,2e84-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,2,1f-5f,ff7f-20001");function rG(t){return t.reduce((e,r)=>(r.forEach(n=>{e.push(n)}),e),[])}s(rG,"flatten");function nG(t){return!!C3(t,J$)}s(nG,"_nameprepTableA1");function iG(t){let e=C3(t,Z$);if(e)return[t+e.s];let r=X$[t];if(r)return r;let n=Q$[t];if(n)return[t+n[0]];let i=eG[t];return i||null}s(iG,"_nameprepTableB2");function sG(t){return!!C3(t,tG)}s(sG,"_nameprepTableC");function S3(t){if(t.match(/^[a-z0-9-]*$/i)&&t.length<=59)return t.toLowerCase();let e=_f(t);e=rG(e.map(n=>{if(Y$.indexOf(n)>=0)return[];if(n>=65024&&n<=65039)return[];let i=iG(n);return i||[n]})),e=_f(Pg(e),ji.NFKC),e.forEach(n=>{if(sG(n))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")}),e.forEach(n=>{if(nG(n))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")});let r=Pg(e);if(r.substring(0,1)==="-"||r.substring(2,4)==="--"||r.substring(r.length-1)==="-")throw new Error("invalid hyphen");return r}s(S3,"nameprep");var K0=class extends Vu{constructor(e){super("string",e)}defaultValue(){return""}encode(e,r){return super.encode(e,Ar(r))}decode(e){return ls(super.decode(e))}};s(K0,"StringCoder");var Af=class extends An{constructor(e,r){let n=!1,i=[];e.forEach(a=>{a.dynamic&&(n=!0),i.push(a.type)});let o="tuple("+i.join(",")+")";super("tuple",o,r,n),this.coders=e}defaultValue(){let e=[];this.coders.forEach(n=>{e.push(n.defaultValue())});let r=this.coders.reduce((n,i)=>{let o=i.localName;return o&&(n[o]||(n[o]=0),n[o]++),n},{});return this.coders.forEach((n,i)=>{let o=n.localName;!o||r[o]!==1||(o==="length"&&(o="_length"),e[o]==null&&(e[o]=e[i]))}),Object.freeze(e)}encode(e,r){return g3(e,this.coders,r)}decode(e){return e.coerce(this.name,b3(e,this.coders))}};s(Af,"TupleCoder");var Og=new ve(va),oG=new RegExp(/^bytes([0-9]*)$/),aG=new RegExp(/^(u?int)([0-9]*)$/),Tl=class{constructor(e){Pe(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new L0(e.name);case"bool":return new q0(e.name);case"string":return new K0(e.name);case"bytes":return new H0(e.name);case"array":return new j0(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new Af((e.components||[]).map(n=>this._getCoder(n)),e.name);case"":return new $0(e.name)}let r=e.type.match(aG);if(r){let n=parseInt(r[2]||"256");return(n===0||n>256||n%8!==0)&&Og.throwArgumentError("invalid "+r[1]+" bit length","param",e),new G0(n/8,r[1]==="int",e.name)}if(r=e.type.match(oG),r){let n=parseInt(r[1]);return(n===0||n>32)&&Og.throwArgumentError("invalid bytes length","param",e),new z0(n,e.name)}return Og.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,r){return new xf(e,this._getWordSize(),this.coerceFunc,r)}_getWriter(){return new yf(this._getWordSize())}getDefaultValue(e){let r=e.map(i=>this._getCoder(Yr.from(i)));return new Af(r,"_").defaultValue()}encode(e,r){e.length!==r.length&&Og.throwError("types/values length mismatch",ve.errors.INVALID_ARGUMENT,{count:{types:e.length,values:r.length},value:{types:e,values:r}});let n=e.map(a=>this._getCoder(Yr.from(a))),i=new Af(n,"_"),o=this._getWriter();return i.encode(o,r),o.data}decode(e,r,n){let i=e.map(a=>this._getCoder(Yr.from(a)));return new Af(i,"_").decode(this._getReader(je(r),n))}};s(Tl,"AbiCoder");var V0=new Tl;function Ms(t){return or(Ar(t))}s(Ms,"id");var Fg="hash/5.7.0";var I3={};vl(I3,{decode:()=>Yu,encode:()=>Zu});function Yu(t){t=atob(t);let e=[];for(let r=0;r<t.length;r++)e.push(t.charCodeAt(r));return je(e)}s(Yu,"decode");function Zu(t){t=je(t);let e="";for(let r=0;r<t.length;r++)e+=String.fromCharCode(t[r]);return btoa(e)}s(Zu,"encode");function QS(t,e){e==null&&(e=1);let r=[],n=r.forEach,i=s(function(o,a){n.call(o,function(f){a>0&&Array.isArray(f)?i(f,a-1):r.push(f)})},"flatDeep");return i(t,e),r}s(QS,"flat");function cG(t){let e={};for(let r=0;r<t.length;r++){let n=t[r];e[n[0]]=n[1]}return e}s(cG,"fromEntries");function fG(t){let e=0;function r(){return t[e++]<<8|t[e++]}s(r,"u16");let n=r(),i=1,o=[0,1];for(let K=1;K<n;K++)o.push(i+=r());let a=r(),f=e;e+=a;let l=0,u=0;function h(){return l==0&&(u=u<<8|t[e++],l=8),u>>--l&1}s(h,"read_bit");let g=31,x=Math.pow(2,g),_=x>>>1,E=_>>1,T=x-1,B=0;for(let K=0;K<g;K++)B=B<<1|h();let F=[],H=0,U=x;for(;;){let K=Math.floor(((B-H+1)*i-1)/U),W=0,N=n;for(;N-W>1;){let re=W+N>>>1;K<o[re]?N=re:W=re}if(W==0)break;F.push(W);let G=H+Math.floor(U*o[W]/i),ce=H+Math.floor(U*o[W+1]/i)-1;for(;((G^ce)&_)==0;)B=B<<1&T|h(),G=G<<1&T,ce=ce<<1&T|1;for(;G&~ce&E;)B=B&_|B<<1&T>>>1|h(),G=G<<1^_,ce=(ce^_)<<1|_|1;H=G,U=1+ce-G}let q=n-4;return F.map(K=>{switch(K-q){case 3:return q+65792+(t[f++]<<16|t[f++]<<8|t[f++]);case 2:return q+256+(t[f++]<<8|t[f++]);case 1:return q+t[f++];default:return K-1}})}s(fG,"decode_arithmetic");function lG(t){let e=0;return()=>t[e++]}s(lG,"read_payload");function eI(t){return lG(fG(t))}s(eI,"read_compressed_payload");function uG(t){return t&1?~t>>1:t>>1}s(uG,"signed");function dG(t,e){let r=Array(t);for(let n=0;n<t;n++)r[n]=1+e();return r}s(dG,"read_counts");function XS(t,e){let r=Array(t);for(let n=0,i=-1;n<t;n++)r[n]=i+=1+e();return r}s(XS,"read_ascending");function hG(t,e){let r=Array(t);for(let n=0,i=0;n<t;n++)r[n]=i+=uG(e());return r}s(hG,"read_deltas");function W0(t,e){let r=XS(t(),t),n=t(),i=XS(n,t),o=dG(n,t);for(let a=0;a<n;a++)for(let f=0;f<o[a];f++)r.push(i[a]+f);return e?r.map(a=>e[a]):r}s(W0,"read_member_array");function tI(t){let e=[];for(;;){let r=t();if(r==0)break;e.push(mG(r,t))}for(;;){let r=t()-1;if(r<0)break;e.push(gG(r,t))}return cG(QS(e))}s(tI,"read_mapped_map");function pG(t){let e=[];for(;;){let r=t();if(r==0)break;e.push(r)}return e}s(pG,"read_zero_terminated_array");function rI(t,e,r){let n=Array(t).fill(void 0).map(()=>[]);for(let i=0;i<e;i++)hG(t,r).forEach((o,a)=>n[a].push(o));return n}s(rI,"read_transposed");function mG(t,e){let r=1+e(),n=e(),i=pG(e),o=rI(i.length,1+t,e);return QS(o.map((a,f)=>{let l=a[0],u=a.slice(1);return Array(i[f]).fill(void 0).map((h,g)=>{let x=g*n;return[l+g*r,u.map(_=>_+x)]})}))}s(mG,"read_linear_table");function gG(t,e){let r=1+e();return rI(r,1+t,e).map(i=>[i[0],i.slice(1)])}s(gG,"read_replacement_table");function nI(t){let e=W0(t).sort((n,i)=>n-i);return r();function r(){let n=[];for(;;){let u=W0(t,e);if(u.length==0)break;n.push({set:new Set(u),node:r()})}n.sort((u,h)=>h.set.size-u.set.size);let i=t(),o=i%3;i=i/3|0;let a=!!(i&1);i>>=1;let f=i==1,l=i==2;return{branches:n,valid:o,fe0f:a,save:f,check:l}}}s(nI,"read_emoji_trie");function iI(){return eI(Yu("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA=="))}s(iI,"getData");var Ng=iI(),bG=new Set(W0(Ng)),vG=new Set(W0(Ng)),yG=tI(Ng),xG=nI(Ng),sI=45,oI=95;function aI(t){return _f(t)}s(aI,"explode_cp");function wG(t){return t.filter(e=>e!=65039)}s(wG,"filter_fe0f");function cI(t){for(let e of t.split(".")){let r=aI(e);try{for(let n=r.lastIndexOf(oI)-1;n>=0;n--)if(r[n]!==oI)throw new Error("underscore only allowed at start");if(r.length>=4&&r.every(n=>n<128)&&r[2]===sI&&r[3]===sI)throw new Error("invalid label extension")}catch(n){throw new Error(`Invalid label "${e}": ${n.message}`)}}return t}s(cI,"ens_normalize_post_check");function fI(t){return cI(_G(t,wG))}s(fI,"ens_normalize");function _G(t,e){let r=aI(t).reverse(),n=[];for(;r.length;){let i=EG(r);if(i){n.push(...e(i));continue}let o=r.pop();if(bG.has(o)){n.push(o);continue}if(vG.has(o))continue;let a=yG[o];if(a){n.push(...a);continue}throw new Error(`Disallowed codepoint: 0x${o.toString(16).toUpperCase()}`)}return cI(AG(String.fromCodePoint(...n)))}s(_G,"normalize");function AG(t){return t.normalize("NFC")}s(AG,"nfc");function EG(t,e){var r;let n=xG,i,o,a=[],f=t.length;for(e&&(e.length=0);f;){let l=t[--f];if(n=(r=n.branches.find(u=>u.set.has(l)))===null||r===void 0?void 0:r.node,!n)break;if(n.save)o=l;else if(n.check&&l===o)break;a.push(l),n.fe0f&&(a.push(65039),f>0&&t[f-1]==65039&&f--),n.valid&&(i=a.slice(),n.valid==2&&i.splice(1,1),e&&e.push(...t.slice(f).reverse()),t.length=f)}return i}s(EG,"consume_emoji_reversed");var CG=new ve(Fg),uI=new Uint8Array(32);uI.fill(0);function lI(t){if(t.length===0)throw new Error("invalid ENS name; empty component");return t}s(lI,"checkComponent");function k3(t){let e=Ar(fI(t)),r=[];if(t.length===0)return r;let n=0;for(let i=0;i<e.length;i++)e[i]===46&&(r.push(lI(e.slice(n,i))),n=i+1);if(n>=e.length)throw new Error("invalid ENS name; empty component");return r.push(lI(e.slice(n))),r}s(k3,"ensNameSplit");function T3(t){try{return k3(t).length!==0}catch{}return!1}s(T3,"isValidName");function Ef(t){typeof t!="string"&&CG.throwArgumentError("invalid ENS name; not a string","name",t);let e=uI,r=k3(t);for(;r.length;)e=or(sr([e,or(r.pop())]));return Ve(e)}s(Ef,"namehash");function J0(t){return Ve(sr(k3(t).map(e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");let r=new Uint8Array(e.length+1);return r.set(e,1),r[0]=r.length-1,r})))+"00"}s(J0,"dnsEncode");var dI=`Ethereum Signed Message:
|
|
1
|
+
"use strict";var HH=Object.create;var y0=Object.defineProperty;var zH=Object.getOwnPropertyDescriptor;var $H=Object.getOwnPropertyNames;var GH=Object.getPrototypeOf,KH=Object.prototype.hasOwnProperty;var s=(t,e)=>y0(t,"name",{value:e,configurable:!0});var an=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),vl=(t,e)=>{for(var r in e)y0(t,r,{get:e[r],enumerable:!0})},mC=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of $H(e))!KH.call(t,i)&&i!==r&&y0(t,i,{get:()=>e[i],enumerable:!(n=zH(e,i))||n.enumerable});return t};var Js=(t,e,r)=>(r=t!=null?HH(GH(t)):{},mC(e||!t||!t.__esModule?y0(r,"default",{value:t,enumerable:!0}):r,t)),VH=t=>mC(y0({},"__esModule",{value:!0}),t);var JC=an((S0,C0)=>{"use strict";Object.defineProperty(S0,"__esModule",{value:!0});var GC=new WeakMap,t3=new WeakMap;function Qr(t){let e=GC.get(t);return console.assert(e!=null,"'this' is expected an Event object, but got",t),e}s(Qr,"pd");function jC(t){if(t.passiveListener!=null){typeof console<"u"&&typeof console.error=="function"&&console.error("Unable to preventDefault inside passive event listener invocation.",t.passiveListener);return}!t.event.cancelable||(t.canceled=!0,typeof t.event.preventDefault=="function"&&t.event.preventDefault())}s(jC,"setCancelFlag");function Uu(t,e){GC.set(this,{eventTarget:t,event:e,eventPhase:2,currentTarget:t,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:e.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let r=Object.keys(e);for(let n=0;n<r.length;++n){let i=r[n];i in this||Object.defineProperty(this,i,KC(i))}}s(Uu,"Event");Uu.prototype={get type(){return Qr(this).event.type},get target(){return Qr(this).eventTarget},get currentTarget(){return Qr(this).currentTarget},composedPath(){let t=Qr(this).currentTarget;return t==null?[]:[t]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return Qr(this).eventPhase},stopPropagation(){let t=Qr(this);t.stopped=!0,typeof t.event.stopPropagation=="function"&&t.event.stopPropagation()},stopImmediatePropagation(){let t=Qr(this);t.stopped=!0,t.immediateStopped=!0,typeof t.event.stopImmediatePropagation=="function"&&t.event.stopImmediatePropagation()},get bubbles(){return Boolean(Qr(this).event.bubbles)},get cancelable(){return Boolean(Qr(this).event.cancelable)},preventDefault(){jC(Qr(this))},get defaultPrevented(){return Qr(this).canceled},get composed(){return Boolean(Qr(this).event.composed)},get timeStamp(){return Qr(this).timeStamp},get srcElement(){return Qr(this).eventTarget},get cancelBubble(){return Qr(this).stopped},set cancelBubble(t){if(!t)return;let e=Qr(this);e.stopped=!0,typeof e.event.cancelBubble=="boolean"&&(e.event.cancelBubble=!0)},get returnValue(){return!Qr(this).canceled},set returnValue(t){t||jC(Qr(this))},initEvent(){}};Object.defineProperty(Uu.prototype,"constructor",{value:Uu,configurable:!0,writable:!0});typeof window<"u"&&typeof window.Event<"u"&&(Object.setPrototypeOf(Uu.prototype,window.Event.prototype),t3.set(window.Event.prototype,Uu));function KC(t){return{get(){return Qr(this).event[t]},set(e){Qr(this).event[t]=e},configurable:!0,enumerable:!0}}s(KC,"defineRedirectDescriptor");function C$(t){return{value(){let e=Qr(this).event;return e[t].apply(e,arguments)},configurable:!0,enumerable:!0}}s(C$,"defineCallDescriptor");function S$(t,e){let r=Object.keys(e);if(r.length===0)return t;function n(i,o){t.call(this,i,o)}s(n,"CustomEvent"),n.prototype=Object.create(t.prototype,{constructor:{value:n,configurable:!0,writable:!0}});for(let i=0;i<r.length;++i){let o=r[i];if(!(o in t.prototype)){let f=typeof Object.getOwnPropertyDescriptor(e,o).value=="function";Object.defineProperty(n.prototype,o,f?C$(o):KC(o))}}return n}s(S$,"defineWrapper");function VC(t){if(t==null||t===Object.prototype)return Uu;let e=t3.get(t);return e==null&&(e=S$(VC(Object.getPrototypeOf(t)),t),t3.set(t,e)),e}s(VC,"getWrapper");function I$(t,e){let r=VC(Object.getPrototypeOf(e));return new r(t,e)}s(I$,"wrapEvent");function k$(t){return Qr(t).immediateStopped}s(k$,"isStopped");function T$(t,e){Qr(t).eventPhase=e}s(T$,"setEventPhase");function M$(t,e){Qr(t).currentTarget=e}s(M$,"setCurrentTarget");function qC(t,e){Qr(t).passiveListener=e}s(qC,"setPassiveListener");var WC=new WeakMap,HC=1,zC=2,vg=3;function yg(t){return t!==null&&typeof t=="object"}s(yg,"isObject");function E0(t){let e=WC.get(t);if(e==null)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return e}s(E0,"getListeners");function R$(t){return{get(){let r=E0(this).get(t);for(;r!=null;){if(r.listenerType===vg)return r.listener;r=r.next}return null},set(e){typeof e!="function"&&!yg(e)&&(e=null);let r=E0(this),n=null,i=r.get(t);for(;i!=null;)i.listenerType===vg?n!==null?n.next=i.next:i.next!==null?r.set(t,i.next):r.delete(t):n=i,i=i.next;if(e!==null){let o={listener:e,listenerType:vg,passive:!1,once:!1,next:null};n===null?r.set(t,o):n.next=o}},configurable:!0,enumerable:!0}}s(R$,"defineEventAttributeDescriptor");function r3(t,e){Object.defineProperty(t,`on${e}`,R$(e))}s(r3,"defineEventAttribute");function $C(t){function e(){Co.call(this)}s(e,"CustomEventTarget"),e.prototype=Object.create(Co.prototype,{constructor:{value:e,configurable:!0,writable:!0}});for(let r=0;r<t.length;++r)r3(e.prototype,t[r]);return e}s($C,"defineCustomEventTarget");function Co(){if(this instanceof Co){WC.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return $C(arguments[0]);if(arguments.length>0){let t=new Array(arguments.length);for(let e=0;e<arguments.length;++e)t[e]=arguments[e];return $C(t)}throw new TypeError("Cannot call a class as a function")}s(Co,"EventTarget");Co.prototype={addEventListener(t,e,r){if(e==null)return;if(typeof e!="function"&&!yg(e))throw new TypeError("'listener' should be a function or an object.");let n=E0(this),i=yg(r),a=Boolean(i?r.capture:r)?HC:zC,f={listener:e,listenerType:a,passive:i&&Boolean(r.passive),once:i&&Boolean(r.once),next:null},l=n.get(t);if(l===void 0){n.set(t,f);return}let u=null;for(;l!=null;){if(l.listener===e&&l.listenerType===a)return;u=l,l=l.next}u.next=f},removeEventListener(t,e,r){if(e==null)return;let n=E0(this),o=(yg(r)?Boolean(r.capture):Boolean(r))?HC:zC,a=null,f=n.get(t);for(;f!=null;){if(f.listener===e&&f.listenerType===o){a!==null?a.next=f.next:f.next!==null?n.set(t,f.next):n.delete(t);return}a=f,f=f.next}},dispatchEvent(t){if(t==null||typeof t.type!="string")throw new TypeError('"event.type" should be a string.');let e=E0(this),r=t.type,n=e.get(r);if(n==null)return!0;let i=I$(this,t),o=null;for(;n!=null;){if(n.once?o!==null?o.next=n.next:n.next!==null?e.set(r,n.next):e.delete(r):o=n,qC(i,n.passive?n.listener:null),typeof n.listener=="function")try{n.listener.call(this,i)}catch(a){typeof console<"u"&&typeof console.error=="function"&&console.error(a)}else n.listenerType!==vg&&typeof n.listener.handleEvent=="function"&&n.listener.handleEvent(i);if(k$(i))break;n=n.next}return qC(i,null),T$(i,0),M$(i,null),!i.defaultPrevented}};Object.defineProperty(Co.prototype,"constructor",{value:Co,configurable:!0,writable:!0});typeof window<"u"&&typeof window.EventTarget<"u"&&Object.setPrototypeOf(Co.prototype,window.EventTarget.prototype);S0.defineEventAttribute=r3;S0.EventTarget=Co;S0.default=Co;C0.exports=Co;C0.exports.EventTarget=C0.exports.default=Co;C0.exports.defineEventAttribute=r3});var XC=an((k0,I0)=>{"use strict";Object.defineProperty(k0,"__esModule",{value:!0});var n3=JC(),uc=class extends n3.EventTarget{constructor(){throw super(),new TypeError("AbortSignal cannot be constructed directly")}get aborted(){let e=xg.get(this);if(typeof e!="boolean")throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return e}};s(uc,"AbortSignal");n3.defineEventAttribute(uc.prototype,"abort");function B$(){let t=Object.create(uc.prototype);return n3.EventTarget.call(t),xg.set(t,!1),t}s(B$,"createAbortSignal");function D$(t){xg.get(t)===!1&&(xg.set(t,!0),t.dispatchEvent({type:"abort"}))}s(D$,"abortSignal");var xg=new WeakMap;Object.defineProperties(uc.prototype,{aborted:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(uc.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});var dc=class{constructor(){ZC.set(this,B$())}get signal(){return YC(this)}abort(){D$(YC(this))}};s(dc,"AbortController");var ZC=new WeakMap;function YC(t){let e=ZC.get(t);if(e==null)throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${t===null?"null":typeof t}`);return e}s(YC,"getSignal");Object.defineProperties(dc.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(dc.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});k0.AbortController=dc;k0.AbortSignal=uc;k0.default=dc;I0.exports=dc;I0.exports.AbortController=I0.exports.default=dc;I0.exports.AbortSignal=uc});var tS=an((hc,eS)=>{var QC=typeof self<"u"?self:hc,wg=function(){function t(){this.fetch=!1,this.DOMException=QC.DOMException}return s(t,"F"),t.prototype=QC,new t}();(function(t){var e=function(r){var n={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};function i(re){return re&&DataView.prototype.isPrototypeOf(re)}if(s(i,"isDataView"),n.arrayBuffer)var o=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(re){return re&&o.indexOf(Object.prototype.toString.call(re))>-1};function f(re){if(typeof re!="string"&&(re=String(re)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(re))throw new TypeError("Invalid character in header field name");return re.toLowerCase()}s(f,"normalizeName");function l(re){return typeof re!="string"&&(re=String(re)),re}s(l,"normalizeValue");function u(re){var ae={next:function(){var J=re.shift();return{done:J===void 0,value:J}}};return n.iterable&&(ae[Symbol.iterator]=function(){return ae}),ae}s(u,"iteratorFor");function h(re){this.map={},re instanceof h?re.forEach(function(ae,J){this.append(J,ae)},this):Array.isArray(re)?re.forEach(function(ae){this.append(ae[0],ae[1])},this):re&&Object.getOwnPropertyNames(re).forEach(function(ae){this.append(ae,re[ae])},this)}s(h,"Headers"),h.prototype.append=function(re,ae){re=f(re),ae=l(ae);var J=this.map[re];this.map[re]=J?J+", "+ae:ae},h.prototype.delete=function(re){delete this.map[f(re)]},h.prototype.get=function(re){return re=f(re),this.has(re)?this.map[re]:null},h.prototype.has=function(re){return this.map.hasOwnProperty(f(re))},h.prototype.set=function(re,ae){this.map[f(re)]=l(ae)},h.prototype.forEach=function(re,ae){for(var J in this.map)this.map.hasOwnProperty(J)&&re.call(ae,this.map[J],J,this)},h.prototype.keys=function(){var re=[];return this.forEach(function(ae,J){re.push(J)}),u(re)},h.prototype.values=function(){var re=[];return this.forEach(function(ae){re.push(ae)}),u(re)},h.prototype.entries=function(){var re=[];return this.forEach(function(ae,J){re.push([J,ae])}),u(re)},n.iterable&&(h.prototype[Symbol.iterator]=h.prototype.entries);function g(re){if(re.bodyUsed)return Promise.reject(new TypeError("Already read"));re.bodyUsed=!0}s(g,"consumed");function x(re){return new Promise(function(ae,J){re.onload=function(){ae(re.result)},re.onerror=function(){J(re.error)}})}s(x,"fileReaderReady");function _(re){var ae=new FileReader,J=x(ae);return ae.readAsArrayBuffer(re),J}s(_,"readBlobAsArrayBuffer");function E(re){var ae=new FileReader,J=x(ae);return ae.readAsText(re),J}s(E,"readBlobAsText");function T(re){for(var ae=new Uint8Array(re),J=new Array(ae.length),S=0;S<ae.length;S++)J[S]=String.fromCharCode(ae[S]);return J.join("")}s(T,"readArrayBufferAsText");function B(re){if(re.slice)return re.slice(0);var ae=new Uint8Array(re.byteLength);return ae.set(new Uint8Array(re)),ae.buffer}s(B,"bufferClone");function F(){return this.bodyUsed=!1,this._initBody=function(re){this._bodyInit=re,re?typeof re=="string"?this._bodyText=re:n.blob&&Blob.prototype.isPrototypeOf(re)?this._bodyBlob=re:n.formData&&FormData.prototype.isPrototypeOf(re)?this._bodyFormData=re:n.searchParams&&URLSearchParams.prototype.isPrototypeOf(re)?this._bodyText=re.toString():n.arrayBuffer&&n.blob&&i(re)?(this._bodyArrayBuffer=B(re.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):n.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(re)||a(re))?this._bodyArrayBuffer=B(re):this._bodyText=re=Object.prototype.toString.call(re):this._bodyText="",this.headers.get("content-type")||(typeof re=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):n.searchParams&&URLSearchParams.prototype.isPrototypeOf(re)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},n.blob&&(this.blob=function(){var re=g(this);if(re)return re;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?g(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(_)}),this.text=function(){var re=g(this);if(re)return re;if(this._bodyBlob)return E(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(T(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},n.formData&&(this.formData=function(){return this.text().then(K)}),this.json=function(){return this.text().then(JSON.parse)},this}s(F,"Body");var H=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function U(re){var ae=re.toUpperCase();return H.indexOf(ae)>-1?ae:re}s(U,"normalizeMethod");function q(re,ae){ae=ae||{};var J=ae.body;if(re instanceof q){if(re.bodyUsed)throw new TypeError("Already read");this.url=re.url,this.credentials=re.credentials,ae.headers||(this.headers=new h(re.headers)),this.method=re.method,this.mode=re.mode,this.signal=re.signal,!J&&re._bodyInit!=null&&(J=re._bodyInit,re.bodyUsed=!0)}else this.url=String(re);if(this.credentials=ae.credentials||this.credentials||"same-origin",(ae.headers||!this.headers)&&(this.headers=new h(ae.headers)),this.method=U(ae.method||this.method||"GET"),this.mode=ae.mode||this.mode||null,this.signal=ae.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&J)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(J)}s(q,"Request"),q.prototype.clone=function(){return new q(this,{body:this._bodyInit})};function K(re){var ae=new FormData;return re.trim().split("&").forEach(function(J){if(J){var S=J.split("="),m=S.shift().replace(/\+/g," "),b=S.join("=").replace(/\+/g," ");ae.append(decodeURIComponent(m),decodeURIComponent(b))}}),ae}s(K,"decode");function W(re){var ae=new h,J=re.replace(/\r?\n[\t ]+/g," ");return J.split(/\r?\n/).forEach(function(S){var m=S.split(":"),b=m.shift().trim();if(b){var p=m.join(":").trim();ae.append(b,p)}}),ae}s(W,"parseHeaders"),F.call(q.prototype);function N(re,ae){ae||(ae={}),this.type="default",this.status=ae.status===void 0?200:ae.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in ae?ae.statusText:"OK",this.headers=new h(ae.headers),this.url=ae.url||"",this._initBody(re)}s(N,"Response"),F.call(N.prototype),N.prototype.clone=function(){return new N(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},N.error=function(){var re=new N(null,{status:0,statusText:""});return re.type="error",re};var G=[301,302,303,307,308];N.redirect=function(re,ae){if(G.indexOf(ae)===-1)throw new RangeError("Invalid status code");return new N(null,{status:ae,headers:{location:re}})},r.DOMException=t.DOMException;try{new r.DOMException}catch{r.DOMException=function(ae,J){this.message=ae,this.name=J;var S=Error(ae);this.stack=S.stack},r.DOMException.prototype=Object.create(Error.prototype),r.DOMException.prototype.constructor=r.DOMException}function ce(re,ae){return new Promise(function(J,S){var m=new q(re,ae);if(m.signal&&m.signal.aborted)return S(new r.DOMException("Aborted","AbortError"));var b=new XMLHttpRequest;function p(){b.abort()}s(p,"abortXhr"),b.onload=function(){var v={status:b.status,statusText:b.statusText,headers:W(b.getAllResponseHeaders()||"")};v.url="responseURL"in b?b.responseURL:v.headers.get("X-Request-URL");var C="response"in b?b.response:b.responseText;J(new N(C,v))},b.onerror=function(){S(new TypeError("Network request failed"))},b.ontimeout=function(){S(new TypeError("Network request failed"))},b.onabort=function(){S(new r.DOMException("Aborted","AbortError"))},b.open(m.method,m.url,!0),m.credentials==="include"?b.withCredentials=!0:m.credentials==="omit"&&(b.withCredentials=!1),"responseType"in b&&n.blob&&(b.responseType="blob"),m.headers.forEach(function(v,C){b.setRequestHeader(C,v)}),m.signal&&(m.signal.addEventListener("abort",p),b.onreadystatechange=function(){b.readyState===4&&m.signal.removeEventListener("abort",p)}),b.send(typeof m._bodyInit>"u"?null:m._bodyInit)})}return s(ce,"fetch"),ce.polyfill=!0,t.fetch||(t.fetch=ce,t.Headers=h,t.Request=q,t.Response=N),r.Headers=h,r.Request=q,r.Response=N,r.fetch=ce,Object.defineProperty(r,"__esModule",{value:!0}),r}({})})(wg);wg.fetch.ponyfill=!0;delete wg.fetch.polyfill;var ju=wg;hc=ju.fetch;hc.default=ju.fetch;hc.fetch=ju.fetch;hc.Headers=ju.Headers;hc.Request=ju.Request;hc.Response=ju.Response;eS.exports=hc});var rS=an(()=>{});var s3=an((nS,i3)=>{(function(t,e){"use strict";function r(S,m){if(!S)throw new Error(m||"Assertion failed")}s(r,"assert");function n(S,m){S.super_=m;var b=s(function(){},"TempCtor");b.prototype=m.prototype,S.prototype=new b,S.prototype.constructor=S}s(n,"inherits");function i(S,m,b){if(i.isBN(S))return S;this.negative=0,this.words=null,this.length=0,this.red=null,S!==null&&((m==="le"||m==="be")&&(b=m,m=10),this._init(S||0,m||10,b||"be"))}s(i,"BN"),typeof t=="object"?t.exports=i:e.BN=i,i.BN=i,i.wordSize=26;var o;try{typeof window<"u"&&typeof window.Buffer<"u"?o=window.Buffer:o=rS().Buffer}catch{}i.isBN=s(function(m){return m instanceof i?!0:m!==null&&typeof m=="object"&&m.constructor.wordSize===i.wordSize&&Array.isArray(m.words)},"isBN"),i.max=s(function(m,b){return m.cmp(b)>0?m:b},"max"),i.min=s(function(m,b){return m.cmp(b)<0?m:b},"min"),i.prototype._init=s(function(m,b,p){if(typeof m=="number")return this._initNumber(m,b,p);if(typeof m=="object")return this._initArray(m,b,p);b==="hex"&&(b=16),r(b===(b|0)&&b>=2&&b<=36),m=m.toString().replace(/\s+/g,"");var v=0;m[0]==="-"&&(v++,this.negative=1),v<m.length&&(b===16?this._parseHex(m,v,p):(this._parseBase(m,b,v),p==="le"&&this._initArray(this.toArray(),b,p)))},"init"),i.prototype._initNumber=s(function(m,b,p){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):(r(m<9007199254740992),this.words=[m&67108863,m/67108864&67108863,1],this.length=3),p==="le"&&this._initArray(this.toArray(),b,p)},"_initNumber"),i.prototype._initArray=s(function(m,b,p){if(r(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 v=0;v<this.length;v++)this.words[v]=0;var C,I,k=0;if(p==="be")for(v=m.length-1,C=0;v>=0;v-=3)I=m[v]|m[v-1]<<8|m[v-2]<<16,this.words[C]|=I<<k&67108863,this.words[C+1]=I>>>26-k&67108863,k+=24,k>=26&&(k-=26,C++);else if(p==="le")for(v=0,C=0;v<m.length;v+=3)I=m[v]|m[v+1]<<8|m[v+2]<<16,this.words[C]|=I<<k&67108863,this.words[C+1]=I>>>26-k&67108863,k+=24,k>=26&&(k-=26,C++);return this._strip()},"_initArray");function a(S,m){var b=S.charCodeAt(m);if(b>=48&&b<=57)return b-48;if(b>=65&&b<=70)return b-55;if(b>=97&&b<=102)return b-87;r(!1,"Invalid character in "+S)}s(a,"parseHex4Bits");function f(S,m,b){var p=a(S,b);return b-1>=m&&(p|=a(S,b-1)<<4),p}s(f,"parseHexByte"),i.prototype._parseHex=s(function(m,b,p){this.length=Math.ceil((m.length-b)/6),this.words=new Array(this.length);for(var v=0;v<this.length;v++)this.words[v]=0;var C=0,I=0,k;if(p==="be")for(v=m.length-1;v>=b;v-=2)k=f(m,b,v)<<C,this.words[I]|=k&67108863,C>=18?(C-=18,I+=1,this.words[I]|=k>>>26):C+=8;else{var w=m.length-b;for(v=w%2===0?b+1:b;v<m.length;v+=2)k=f(m,b,v)<<C,this.words[I]|=k&67108863,C>=18?(C-=18,I+=1,this.words[I]|=k>>>26):C+=8}this._strip()},"_parseHex");function l(S,m,b,p){for(var v=0,C=0,I=Math.min(S.length,b),k=m;k<I;k++){var w=S.charCodeAt(k)-48;v*=p,w>=49?C=w-49+10:w>=17?C=w-17+10:C=w,r(w>=0&&C<p,"Invalid character"),v+=C}return v}s(l,"parseBase"),i.prototype._parseBase=s(function(m,b,p){this.words=[0],this.length=1;for(var v=0,C=1;C<=67108863;C*=b)v++;v--,C=C/b|0;for(var I=m.length-p,k=I%v,w=Math.min(I,I-k)+p,A=0,R=p;R<w;R+=v)A=l(m,R,R+v,b),this.imuln(C),this.words[0]+A<67108864?this.words[0]+=A:this._iaddn(A);if(k!==0){var D=1;for(A=l(m,R,m.length,b),R=0;R<k;R++)D*=b;this.imuln(D),this.words[0]+A<67108864?this.words[0]+=A:this._iaddn(A)}this._strip()},"_parseBase"),i.prototype.copy=s(function(m){m.words=new Array(this.length);for(var b=0;b<this.length;b++)m.words[b]=this.words[b];m.length=this.length,m.negative=this.negative,m.red=this.red},"copy");function u(S,m){S.words=m.words,S.length=m.length,S.negative=m.negative,S.red=m.red}if(s(u,"move"),i.prototype._move=s(function(m){u(m,this)},"_move"),i.prototype.clone=s(function(){var m=new i(null);return this.copy(m),m},"clone"),i.prototype._expand=s(function(m){for(;this.length<m;)this.words[this.length++]=0;return this},"_expand"),i.prototype._strip=s(function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},"strip"),i.prototype._normSign=s(function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},"_normSign"),typeof Symbol<"u"&&typeof Symbol.for=="function")try{i.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch{i.prototype.inspect=h}else i.prototype.inspect=h;function h(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}s(h,"inspect");var g=["","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"],x=[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],_=[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];i.prototype.toString=s(function(m,b){m=m||10,b=b|0||1;var p;if(m===16||m==="hex"){p="";for(var v=0,C=0,I=0;I<this.length;I++){var k=this.words[I],w=((k<<v|C)&16777215).toString(16);C=k>>>24-v&16777215,v+=2,v>=26&&(v-=26,I--),C!==0||I!==this.length-1?p=g[6-w.length]+w+p:p=w+p}for(C!==0&&(p=C.toString(16)+p);p.length%b!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}if(m===(m|0)&&m>=2&&m<=36){var A=x[m],R=_[m];p="";var D=this.clone();for(D.negative=0;!D.isZero();){var M=D.modrn(R).toString(m);D=D.idivn(R),D.isZero()?p=M+p:p=g[A-M.length]+M+p}for(this.isZero()&&(p="0"+p);p.length%b!==0;)p="0"+p;return this.negative!==0&&(p="-"+p),p}r(!1,"Base should be between 2 and 36")},"toString"),i.prototype.toNumber=s(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&&r(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-m:m},"toNumber"),i.prototype.toJSON=s(function(){return this.toString(16,2)},"toJSON"),o&&(i.prototype.toBuffer=s(function(m,b){return this.toArrayLike(o,m,b)},"toBuffer")),i.prototype.toArray=s(function(m,b){return this.toArrayLike(Array,m,b)},"toArray");var E=s(function(m,b){return m.allocUnsafe?m.allocUnsafe(b):new m(b)},"allocate");i.prototype.toArrayLike=s(function(m,b,p){this._strip();var v=this.byteLength(),C=p||Math.max(1,v);r(v<=C,"byte array longer than desired length"),r(C>0,"Requested array length <= 0");var I=E(m,C),k=b==="le"?"LE":"BE";return this["_toArrayLike"+k](I,v),I},"toArrayLike"),i.prototype._toArrayLikeLE=s(function(m,b){for(var p=0,v=0,C=0,I=0;C<this.length;C++){var k=this.words[C]<<I|v;m[p++]=k&255,p<m.length&&(m[p++]=k>>8&255),p<m.length&&(m[p++]=k>>16&255),I===6?(p<m.length&&(m[p++]=k>>24&255),v=0,I=0):(v=k>>>24,I+=2)}if(p<m.length)for(m[p++]=v;p<m.length;)m[p++]=0},"_toArrayLikeLE"),i.prototype._toArrayLikeBE=s(function(m,b){for(var p=m.length-1,v=0,C=0,I=0;C<this.length;C++){var k=this.words[C]<<I|v;m[p--]=k&255,p>=0&&(m[p--]=k>>8&255),p>=0&&(m[p--]=k>>16&255),I===6?(p>=0&&(m[p--]=k>>24&255),v=0,I=0):(v=k>>>24,I+=2)}if(p>=0)for(m[p--]=v;p>=0;)m[p--]=0},"_toArrayLikeBE"),Math.clz32?i.prototype._countBits=s(function(m){return 32-Math.clz32(m)},"_countBits"):i.prototype._countBits=s(function(m){var b=m,p=0;return b>=4096&&(p+=13,b>>>=13),b>=64&&(p+=7,b>>>=7),b>=8&&(p+=4,b>>>=4),b>=2&&(p+=2,b>>>=2),p+b},"_countBits"),i.prototype._zeroBits=s(function(m){if(m===0)return 26;var b=m,p=0;return(b&8191)===0&&(p+=13,b>>>=13),(b&127)===0&&(p+=7,b>>>=7),(b&15)===0&&(p+=4,b>>>=4),(b&3)===0&&(p+=2,b>>>=2),(b&1)===0&&p++,p},"_zeroBits"),i.prototype.bitLength=s(function(){var m=this.words[this.length-1],b=this._countBits(m);return(this.length-1)*26+b},"bitLength");function T(S){for(var m=new Array(S.bitLength()),b=0;b<m.length;b++){var p=b/26|0,v=b%26;m[b]=S.words[p]>>>v&1}return m}s(T,"toBitArray"),i.prototype.zeroBits=s(function(){if(this.isZero())return 0;for(var m=0,b=0;b<this.length;b++){var p=this._zeroBits(this.words[b]);if(m+=p,p!==26)break}return m},"zeroBits"),i.prototype.byteLength=s(function(){return Math.ceil(this.bitLength()/8)},"byteLength"),i.prototype.toTwos=s(function(m){return this.negative!==0?this.abs().inotn(m).iaddn(1):this.clone()},"toTwos"),i.prototype.fromTwos=s(function(m){return this.testn(m-1)?this.notn(m).iaddn(1).ineg():this.clone()},"fromTwos"),i.prototype.isNeg=s(function(){return this.negative!==0},"isNeg"),i.prototype.neg=s(function(){return this.clone().ineg()},"neg"),i.prototype.ineg=s(function(){return this.isZero()||(this.negative^=1),this},"ineg"),i.prototype.iuor=s(function(m){for(;this.length<m.length;)this.words[this.length++]=0;for(var b=0;b<m.length;b++)this.words[b]=this.words[b]|m.words[b];return this._strip()},"iuor"),i.prototype.ior=s(function(m){return r((this.negative|m.negative)===0),this.iuor(m)},"ior"),i.prototype.or=s(function(m){return this.length>m.length?this.clone().ior(m):m.clone().ior(this)},"or"),i.prototype.uor=s(function(m){return this.length>m.length?this.clone().iuor(m):m.clone().iuor(this)},"uor"),i.prototype.iuand=s(function(m){var b;this.length>m.length?b=m:b=this;for(var p=0;p<b.length;p++)this.words[p]=this.words[p]&m.words[p];return this.length=b.length,this._strip()},"iuand"),i.prototype.iand=s(function(m){return r((this.negative|m.negative)===0),this.iuand(m)},"iand"),i.prototype.and=s(function(m){return this.length>m.length?this.clone().iand(m):m.clone().iand(this)},"and"),i.prototype.uand=s(function(m){return this.length>m.length?this.clone().iuand(m):m.clone().iuand(this)},"uand"),i.prototype.iuxor=s(function(m){var b,p;this.length>m.length?(b=this,p=m):(b=m,p=this);for(var v=0;v<p.length;v++)this.words[v]=b.words[v]^p.words[v];if(this!==b)for(;v<b.length;v++)this.words[v]=b.words[v];return this.length=b.length,this._strip()},"iuxor"),i.prototype.ixor=s(function(m){return r((this.negative|m.negative)===0),this.iuxor(m)},"ixor"),i.prototype.xor=s(function(m){return this.length>m.length?this.clone().ixor(m):m.clone().ixor(this)},"xor"),i.prototype.uxor=s(function(m){return this.length>m.length?this.clone().iuxor(m):m.clone().iuxor(this)},"uxor"),i.prototype.inotn=s(function(m){r(typeof m=="number"&&m>=0);var b=Math.ceil(m/26)|0,p=m%26;this._expand(b),p>0&&b--;for(var v=0;v<b;v++)this.words[v]=~this.words[v]&67108863;return p>0&&(this.words[v]=~this.words[v]&67108863>>26-p),this._strip()},"inotn"),i.prototype.notn=s(function(m){return this.clone().inotn(m)},"notn"),i.prototype.setn=s(function(m,b){r(typeof m=="number"&&m>=0);var p=m/26|0,v=m%26;return this._expand(p+1),b?this.words[p]=this.words[p]|1<<v:this.words[p]=this.words[p]&~(1<<v),this._strip()},"setn"),i.prototype.iadd=s(function(m){var b;if(this.negative!==0&&m.negative===0)return this.negative=0,b=this.isub(m),this.negative^=1,this._normSign();if(this.negative===0&&m.negative!==0)return m.negative=0,b=this.isub(m),m.negative=1,b._normSign();var p,v;this.length>m.length?(p=this,v=m):(p=m,v=this);for(var C=0,I=0;I<v.length;I++)b=(p.words[I]|0)+(v.words[I]|0)+C,this.words[I]=b&67108863,C=b>>>26;for(;C!==0&&I<p.length;I++)b=(p.words[I]|0)+C,this.words[I]=b&67108863,C=b>>>26;if(this.length=p.length,C!==0)this.words[this.length]=C,this.length++;else if(p!==this)for(;I<p.length;I++)this.words[I]=p.words[I];return this},"iadd"),i.prototype.add=s(function(m){var b;return m.negative!==0&&this.negative===0?(m.negative=0,b=this.sub(m),m.negative^=1,b):m.negative===0&&this.negative!==0?(this.negative=0,b=m.sub(this),this.negative=1,b):this.length>m.length?this.clone().iadd(m):m.clone().iadd(this)},"add"),i.prototype.isub=s(function(m){if(m.negative!==0){m.negative=0;var b=this.iadd(m);return m.negative=1,b._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(m),this.negative=1,this._normSign();var p=this.cmp(m);if(p===0)return this.negative=0,this.length=1,this.words[0]=0,this;var v,C;p>0?(v=this,C=m):(v=m,C=this);for(var I=0,k=0;k<C.length;k++)b=(v.words[k]|0)-(C.words[k]|0)+I,I=b>>26,this.words[k]=b&67108863;for(;I!==0&&k<v.length;k++)b=(v.words[k]|0)+I,I=b>>26,this.words[k]=b&67108863;if(I===0&&k<v.length&&v!==this)for(;k<v.length;k++)this.words[k]=v.words[k];return this.length=Math.max(this.length,k),v!==this&&(this.negative=1),this._strip()},"isub"),i.prototype.sub=s(function(m){return this.clone().isub(m)},"sub");function B(S,m,b){b.negative=m.negative^S.negative;var p=S.length+m.length|0;b.length=p,p=p-1|0;var v=S.words[0]|0,C=m.words[0]|0,I=v*C,k=I&67108863,w=I/67108864|0;b.words[0]=k;for(var A=1;A<p;A++){for(var R=w>>>26,D=w&67108863,M=Math.min(A,m.length-1),te=Math.max(0,A-S.length+1);te<=M;te++){var L=A-te|0;v=S.words[L]|0,C=m.words[te]|0,I=v*C+D,R+=I/67108864|0,D=I&67108863}b.words[A]=D|0,w=R|0}return w!==0?b.words[A]=w|0:b.length--,b._strip()}s(B,"smallMulTo");var F=s(function(m,b,p){var v=m.words,C=b.words,I=p.words,k=0,w,A,R,D=v[0]|0,M=D&8191,te=D>>>13,L=v[1]|0,Y=L&8191,Z=L>>>13,P=v[2]|0,z=P&8191,oe=P>>>13,ue=v[3]|0,me=ue&8191,ke=ue>>>13,Q=v[4]|0,j=Q&8191,$=Q>>>13,X=v[5]|0,se=X&8191,ee=X>>>13,le=v[6]|0,be=le&8191,Se=le>>>13,Te=v[7]|0,De=Te&8191,Ne=Te>>>13,ye=v[8]|0,pe=ye&8191,ne=ye>>>13,he=v[9]|0,Ee=he&8191,Ie=he>>>13,Re=C[0]|0,Oe=Re&8191,bt=Re>>>13,Qe=C[1]|0,qe=Qe&8191,vt=Qe>>>13,gt=C[2]|0,tt=gt&8191,Ut=gt>>>13,ht=C[3]|0,et=ht&8191,Dt=ht>>>13,pt=C[4]|0,Xe=pt&8191,Mt=pt>>>13,ft=C[5]|0,Ye=ft&8191,It=ft>>>13,lt=C[6]|0,Ze=lt&8191,Rt=lt>>>13,ut=C[7]|0,Je=ut&8191,Bt=ut>>>13,dt=C[8]|0,at=dt&8191,tr=dt>>>13,Tt=C[9]|0,rt=Tt&8191,Yt=Tt>>>13;p.negative=m.negative^b.negative,p.length=19,w=Math.imul(M,Oe),A=Math.imul(M,bt),A=A+Math.imul(te,Oe)|0,R=Math.imul(te,bt);var Kt=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Kt>>>26)|0,Kt&=67108863,w=Math.imul(Y,Oe),A=Math.imul(Y,bt),A=A+Math.imul(Z,Oe)|0,R=Math.imul(Z,bt),w=w+Math.imul(M,qe)|0,A=A+Math.imul(M,vt)|0,A=A+Math.imul(te,qe)|0,R=R+Math.imul(te,vt)|0;var Vt=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,w=Math.imul(z,Oe),A=Math.imul(z,bt),A=A+Math.imul(oe,Oe)|0,R=Math.imul(oe,bt),w=w+Math.imul(Y,qe)|0,A=A+Math.imul(Y,vt)|0,A=A+Math.imul(Z,qe)|0,R=R+Math.imul(Z,vt)|0,w=w+Math.imul(M,tt)|0,A=A+Math.imul(M,Ut)|0,A=A+Math.imul(te,tt)|0,R=R+Math.imul(te,Ut)|0;var Vr=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Vr>>>26)|0,Vr&=67108863,w=Math.imul(me,Oe),A=Math.imul(me,bt),A=A+Math.imul(ke,Oe)|0,R=Math.imul(ke,bt),w=w+Math.imul(z,qe)|0,A=A+Math.imul(z,vt)|0,A=A+Math.imul(oe,qe)|0,R=R+Math.imul(oe,vt)|0,w=w+Math.imul(Y,tt)|0,A=A+Math.imul(Y,Ut)|0,A=A+Math.imul(Z,tt)|0,R=R+Math.imul(Z,Ut)|0,w=w+Math.imul(M,et)|0,A=A+Math.imul(M,Dt)|0,A=A+Math.imul(te,et)|0,R=R+Math.imul(te,Dt)|0;var Wr=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Wr>>>26)|0,Wr&=67108863,w=Math.imul(j,Oe),A=Math.imul(j,bt),A=A+Math.imul($,Oe)|0,R=Math.imul($,bt),w=w+Math.imul(me,qe)|0,A=A+Math.imul(me,vt)|0,A=A+Math.imul(ke,qe)|0,R=R+Math.imul(ke,vt)|0,w=w+Math.imul(z,tt)|0,A=A+Math.imul(z,Ut)|0,A=A+Math.imul(oe,tt)|0,R=R+Math.imul(oe,Ut)|0,w=w+Math.imul(Y,et)|0,A=A+Math.imul(Y,Dt)|0,A=A+Math.imul(Z,et)|0,R=R+Math.imul(Z,Dt)|0,w=w+Math.imul(M,Xe)|0,A=A+Math.imul(M,Mt)|0,A=A+Math.imul(te,Xe)|0,R=R+Math.imul(te,Mt)|0;var Ir=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Ir>>>26)|0,Ir&=67108863,w=Math.imul(se,Oe),A=Math.imul(se,bt),A=A+Math.imul(ee,Oe)|0,R=Math.imul(ee,bt),w=w+Math.imul(j,qe)|0,A=A+Math.imul(j,vt)|0,A=A+Math.imul($,qe)|0,R=R+Math.imul($,vt)|0,w=w+Math.imul(me,tt)|0,A=A+Math.imul(me,Ut)|0,A=A+Math.imul(ke,tt)|0,R=R+Math.imul(ke,Ut)|0,w=w+Math.imul(z,et)|0,A=A+Math.imul(z,Dt)|0,A=A+Math.imul(oe,et)|0,R=R+Math.imul(oe,Dt)|0,w=w+Math.imul(Y,Xe)|0,A=A+Math.imul(Y,Mt)|0,A=A+Math.imul(Z,Xe)|0,R=R+Math.imul(Z,Mt)|0,w=w+Math.imul(M,Ye)|0,A=A+Math.imul(M,It)|0,A=A+Math.imul(te,Ye)|0,R=R+Math.imul(te,It)|0;var tn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(tn>>>26)|0,tn&=67108863,w=Math.imul(be,Oe),A=Math.imul(be,bt),A=A+Math.imul(Se,Oe)|0,R=Math.imul(Se,bt),w=w+Math.imul(se,qe)|0,A=A+Math.imul(se,vt)|0,A=A+Math.imul(ee,qe)|0,R=R+Math.imul(ee,vt)|0,w=w+Math.imul(j,tt)|0,A=A+Math.imul(j,Ut)|0,A=A+Math.imul($,tt)|0,R=R+Math.imul($,Ut)|0,w=w+Math.imul(me,et)|0,A=A+Math.imul(me,Dt)|0,A=A+Math.imul(ke,et)|0,R=R+Math.imul(ke,Dt)|0,w=w+Math.imul(z,Xe)|0,A=A+Math.imul(z,Mt)|0,A=A+Math.imul(oe,Xe)|0,R=R+Math.imul(oe,Mt)|0,w=w+Math.imul(Y,Ye)|0,A=A+Math.imul(Y,It)|0,A=A+Math.imul(Z,Ye)|0,R=R+Math.imul(Z,It)|0,w=w+Math.imul(M,Ze)|0,A=A+Math.imul(M,Rt)|0,A=A+Math.imul(te,Ze)|0,R=R+Math.imul(te,Rt)|0;var xn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(xn>>>26)|0,xn&=67108863,w=Math.imul(De,Oe),A=Math.imul(De,bt),A=A+Math.imul(Ne,Oe)|0,R=Math.imul(Ne,bt),w=w+Math.imul(be,qe)|0,A=A+Math.imul(be,vt)|0,A=A+Math.imul(Se,qe)|0,R=R+Math.imul(Se,vt)|0,w=w+Math.imul(se,tt)|0,A=A+Math.imul(se,Ut)|0,A=A+Math.imul(ee,tt)|0,R=R+Math.imul(ee,Ut)|0,w=w+Math.imul(j,et)|0,A=A+Math.imul(j,Dt)|0,A=A+Math.imul($,et)|0,R=R+Math.imul($,Dt)|0,w=w+Math.imul(me,Xe)|0,A=A+Math.imul(me,Mt)|0,A=A+Math.imul(ke,Xe)|0,R=R+Math.imul(ke,Mt)|0,w=w+Math.imul(z,Ye)|0,A=A+Math.imul(z,It)|0,A=A+Math.imul(oe,Ye)|0,R=R+Math.imul(oe,It)|0,w=w+Math.imul(Y,Ze)|0,A=A+Math.imul(Y,Rt)|0,A=A+Math.imul(Z,Ze)|0,R=R+Math.imul(Z,Rt)|0,w=w+Math.imul(M,Je)|0,A=A+Math.imul(M,Bt)|0,A=A+Math.imul(te,Je)|0,R=R+Math.imul(te,Bt)|0;var Pn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,w=Math.imul(pe,Oe),A=Math.imul(pe,bt),A=A+Math.imul(ne,Oe)|0,R=Math.imul(ne,bt),w=w+Math.imul(De,qe)|0,A=A+Math.imul(De,vt)|0,A=A+Math.imul(Ne,qe)|0,R=R+Math.imul(Ne,vt)|0,w=w+Math.imul(be,tt)|0,A=A+Math.imul(be,Ut)|0,A=A+Math.imul(Se,tt)|0,R=R+Math.imul(Se,Ut)|0,w=w+Math.imul(se,et)|0,A=A+Math.imul(se,Dt)|0,A=A+Math.imul(ee,et)|0,R=R+Math.imul(ee,Dt)|0,w=w+Math.imul(j,Xe)|0,A=A+Math.imul(j,Mt)|0,A=A+Math.imul($,Xe)|0,R=R+Math.imul($,Mt)|0,w=w+Math.imul(me,Ye)|0,A=A+Math.imul(me,It)|0,A=A+Math.imul(ke,Ye)|0,R=R+Math.imul(ke,It)|0,w=w+Math.imul(z,Ze)|0,A=A+Math.imul(z,Rt)|0,A=A+Math.imul(oe,Ze)|0,R=R+Math.imul(oe,Rt)|0,w=w+Math.imul(Y,Je)|0,A=A+Math.imul(Y,Bt)|0,A=A+Math.imul(Z,Je)|0,R=R+Math.imul(Z,Bt)|0,w=w+Math.imul(M,at)|0,A=A+Math.imul(M,tr)|0,A=A+Math.imul(te,at)|0,R=R+Math.imul(te,tr)|0;var li=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(li>>>26)|0,li&=67108863,w=Math.imul(Ee,Oe),A=Math.imul(Ee,bt),A=A+Math.imul(Ie,Oe)|0,R=Math.imul(Ie,bt),w=w+Math.imul(pe,qe)|0,A=A+Math.imul(pe,vt)|0,A=A+Math.imul(ne,qe)|0,R=R+Math.imul(ne,vt)|0,w=w+Math.imul(De,tt)|0,A=A+Math.imul(De,Ut)|0,A=A+Math.imul(Ne,tt)|0,R=R+Math.imul(Ne,Ut)|0,w=w+Math.imul(be,et)|0,A=A+Math.imul(be,Dt)|0,A=A+Math.imul(Se,et)|0,R=R+Math.imul(Se,Dt)|0,w=w+Math.imul(se,Xe)|0,A=A+Math.imul(se,Mt)|0,A=A+Math.imul(ee,Xe)|0,R=R+Math.imul(ee,Mt)|0,w=w+Math.imul(j,Ye)|0,A=A+Math.imul(j,It)|0,A=A+Math.imul($,Ye)|0,R=R+Math.imul($,It)|0,w=w+Math.imul(me,Ze)|0,A=A+Math.imul(me,Rt)|0,A=A+Math.imul(ke,Ze)|0,R=R+Math.imul(ke,Rt)|0,w=w+Math.imul(z,Je)|0,A=A+Math.imul(z,Bt)|0,A=A+Math.imul(oe,Je)|0,R=R+Math.imul(oe,Bt)|0,w=w+Math.imul(Y,at)|0,A=A+Math.imul(Y,tr)|0,A=A+Math.imul(Z,at)|0,R=R+Math.imul(Z,tr)|0,w=w+Math.imul(M,rt)|0,A=A+Math.imul(M,Yt)|0,A=A+Math.imul(te,rt)|0,R=R+Math.imul(te,Yt)|0;var ui=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(ui>>>26)|0,ui&=67108863,w=Math.imul(Ee,qe),A=Math.imul(Ee,vt),A=A+Math.imul(Ie,qe)|0,R=Math.imul(Ie,vt),w=w+Math.imul(pe,tt)|0,A=A+Math.imul(pe,Ut)|0,A=A+Math.imul(ne,tt)|0,R=R+Math.imul(ne,Ut)|0,w=w+Math.imul(De,et)|0,A=A+Math.imul(De,Dt)|0,A=A+Math.imul(Ne,et)|0,R=R+Math.imul(Ne,Dt)|0,w=w+Math.imul(be,Xe)|0,A=A+Math.imul(be,Mt)|0,A=A+Math.imul(Se,Xe)|0,R=R+Math.imul(Se,Mt)|0,w=w+Math.imul(se,Ye)|0,A=A+Math.imul(se,It)|0,A=A+Math.imul(ee,Ye)|0,R=R+Math.imul(ee,It)|0,w=w+Math.imul(j,Ze)|0,A=A+Math.imul(j,Rt)|0,A=A+Math.imul($,Ze)|0,R=R+Math.imul($,Rt)|0,w=w+Math.imul(me,Je)|0,A=A+Math.imul(me,Bt)|0,A=A+Math.imul(ke,Je)|0,R=R+Math.imul(ke,Bt)|0,w=w+Math.imul(z,at)|0,A=A+Math.imul(z,tr)|0,A=A+Math.imul(oe,at)|0,R=R+Math.imul(oe,tr)|0,w=w+Math.imul(Y,rt)|0,A=A+Math.imul(Y,Yt)|0,A=A+Math.imul(Z,rt)|0,R=R+Math.imul(Z,Yt)|0;var di=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(di>>>26)|0,di&=67108863,w=Math.imul(Ee,tt),A=Math.imul(Ee,Ut),A=A+Math.imul(Ie,tt)|0,R=Math.imul(Ie,Ut),w=w+Math.imul(pe,et)|0,A=A+Math.imul(pe,Dt)|0,A=A+Math.imul(ne,et)|0,R=R+Math.imul(ne,Dt)|0,w=w+Math.imul(De,Xe)|0,A=A+Math.imul(De,Mt)|0,A=A+Math.imul(Ne,Xe)|0,R=R+Math.imul(Ne,Mt)|0,w=w+Math.imul(be,Ye)|0,A=A+Math.imul(be,It)|0,A=A+Math.imul(Se,Ye)|0,R=R+Math.imul(Se,It)|0,w=w+Math.imul(se,Ze)|0,A=A+Math.imul(se,Rt)|0,A=A+Math.imul(ee,Ze)|0,R=R+Math.imul(ee,Rt)|0,w=w+Math.imul(j,Je)|0,A=A+Math.imul(j,Bt)|0,A=A+Math.imul($,Je)|0,R=R+Math.imul($,Bt)|0,w=w+Math.imul(me,at)|0,A=A+Math.imul(me,tr)|0,A=A+Math.imul(ke,at)|0,R=R+Math.imul(ke,tr)|0,w=w+Math.imul(z,rt)|0,A=A+Math.imul(z,Yt)|0,A=A+Math.imul(oe,rt)|0,R=R+Math.imul(oe,Yt)|0;var Hn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Hn>>>26)|0,Hn&=67108863,w=Math.imul(Ee,et),A=Math.imul(Ee,Dt),A=A+Math.imul(Ie,et)|0,R=Math.imul(Ie,Dt),w=w+Math.imul(pe,Xe)|0,A=A+Math.imul(pe,Mt)|0,A=A+Math.imul(ne,Xe)|0,R=R+Math.imul(ne,Mt)|0,w=w+Math.imul(De,Ye)|0,A=A+Math.imul(De,It)|0,A=A+Math.imul(Ne,Ye)|0,R=R+Math.imul(Ne,It)|0,w=w+Math.imul(be,Ze)|0,A=A+Math.imul(be,Rt)|0,A=A+Math.imul(Se,Ze)|0,R=R+Math.imul(Se,Rt)|0,w=w+Math.imul(se,Je)|0,A=A+Math.imul(se,Bt)|0,A=A+Math.imul(ee,Je)|0,R=R+Math.imul(ee,Bt)|0,w=w+Math.imul(j,at)|0,A=A+Math.imul(j,tr)|0,A=A+Math.imul($,at)|0,R=R+Math.imul($,tr)|0,w=w+Math.imul(me,rt)|0,A=A+Math.imul(me,Yt)|0,A=A+Math.imul(ke,rt)|0,R=R+Math.imul(ke,Yt)|0;var kn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(kn>>>26)|0,kn&=67108863,w=Math.imul(Ee,Xe),A=Math.imul(Ee,Mt),A=A+Math.imul(Ie,Xe)|0,R=Math.imul(Ie,Mt),w=w+Math.imul(pe,Ye)|0,A=A+Math.imul(pe,It)|0,A=A+Math.imul(ne,Ye)|0,R=R+Math.imul(ne,It)|0,w=w+Math.imul(De,Ze)|0,A=A+Math.imul(De,Rt)|0,A=A+Math.imul(Ne,Ze)|0,R=R+Math.imul(Ne,Rt)|0,w=w+Math.imul(be,Je)|0,A=A+Math.imul(be,Bt)|0,A=A+Math.imul(Se,Je)|0,R=R+Math.imul(Se,Bt)|0,w=w+Math.imul(se,at)|0,A=A+Math.imul(se,tr)|0,A=A+Math.imul(ee,at)|0,R=R+Math.imul(ee,tr)|0,w=w+Math.imul(j,rt)|0,A=A+Math.imul(j,Yt)|0,A=A+Math.imul($,rt)|0,R=R+Math.imul($,Yt)|0;var Qn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(Qn>>>26)|0,Qn&=67108863,w=Math.imul(Ee,Ye),A=Math.imul(Ee,It),A=A+Math.imul(Ie,Ye)|0,R=Math.imul(Ie,It),w=w+Math.imul(pe,Ze)|0,A=A+Math.imul(pe,Rt)|0,A=A+Math.imul(ne,Ze)|0,R=R+Math.imul(ne,Rt)|0,w=w+Math.imul(De,Je)|0,A=A+Math.imul(De,Bt)|0,A=A+Math.imul(Ne,Je)|0,R=R+Math.imul(Ne,Bt)|0,w=w+Math.imul(be,at)|0,A=A+Math.imul(be,tr)|0,A=A+Math.imul(Se,at)|0,R=R+Math.imul(Se,tr)|0,w=w+Math.imul(se,rt)|0,A=A+Math.imul(se,Yt)|0,A=A+Math.imul(ee,rt)|0,R=R+Math.imul(ee,Yt)|0;var zn=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(zn>>>26)|0,zn&=67108863,w=Math.imul(Ee,Ze),A=Math.imul(Ee,Rt),A=A+Math.imul(Ie,Ze)|0,R=Math.imul(Ie,Rt),w=w+Math.imul(pe,Je)|0,A=A+Math.imul(pe,Bt)|0,A=A+Math.imul(ne,Je)|0,R=R+Math.imul(ne,Bt)|0,w=w+Math.imul(De,at)|0,A=A+Math.imul(De,tr)|0,A=A+Math.imul(Ne,at)|0,R=R+Math.imul(Ne,tr)|0,w=w+Math.imul(be,rt)|0,A=A+Math.imul(be,Yt)|0,A=A+Math.imul(Se,rt)|0,R=R+Math.imul(Se,Yt)|0;var hi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(hi>>>26)|0,hi&=67108863,w=Math.imul(Ee,Je),A=Math.imul(Ee,Bt),A=A+Math.imul(Ie,Je)|0,R=Math.imul(Ie,Bt),w=w+Math.imul(pe,at)|0,A=A+Math.imul(pe,tr)|0,A=A+Math.imul(ne,at)|0,R=R+Math.imul(ne,tr)|0,w=w+Math.imul(De,rt)|0,A=A+Math.imul(De,Yt)|0,A=A+Math.imul(Ne,rt)|0,R=R+Math.imul(Ne,Yt)|0;var pi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(pi>>>26)|0,pi&=67108863,w=Math.imul(Ee,at),A=Math.imul(Ee,tr),A=A+Math.imul(Ie,at)|0,R=Math.imul(Ie,tr),w=w+Math.imul(pe,rt)|0,A=A+Math.imul(pe,Yt)|0,A=A+Math.imul(ne,rt)|0,R=R+Math.imul(ne,Yt)|0;var mi=(k+w|0)+((A&8191)<<13)|0;k=(R+(A>>>13)|0)+(mi>>>26)|0,mi&=67108863,w=Math.imul(Ee,rt),A=Math.imul(Ee,Yt),A=A+Math.imul(Ie,rt)|0,R=Math.imul(Ie,Yt);var ys=(k+w|0)+((A&8191)<<13)|0;return k=(R+(A>>>13)|0)+(ys>>>26)|0,ys&=67108863,I[0]=Kt,I[1]=Vt,I[2]=Vr,I[3]=Wr,I[4]=Ir,I[5]=tn,I[6]=xn,I[7]=Pn,I[8]=li,I[9]=ui,I[10]=di,I[11]=Hn,I[12]=kn,I[13]=Qn,I[14]=zn,I[15]=hi,I[16]=pi,I[17]=mi,I[18]=ys,k!==0&&(I[19]=k,p.length++),p},"comb10MulTo");Math.imul||(F=B);function H(S,m,b){b.negative=m.negative^S.negative,b.length=S.length+m.length;for(var p=0,v=0,C=0;C<b.length-1;C++){var I=v;v=0;for(var k=p&67108863,w=Math.min(C,m.length-1),A=Math.max(0,C-S.length+1);A<=w;A++){var R=C-A,D=S.words[R]|0,M=m.words[A]|0,te=D*M,L=te&67108863;I=I+(te/67108864|0)|0,L=L+k|0,k=L&67108863,I=I+(L>>>26)|0,v+=I>>>26,I&=67108863}b.words[C]=k,p=I,I=v}return p!==0?b.words[C]=p:b.length--,b._strip()}s(H,"bigMulTo");function U(S,m,b){return H(S,m,b)}s(U,"jumboMulTo"),i.prototype.mulTo=s(function(m,b){var p,v=this.length+m.length;return this.length===10&&m.length===10?p=F(this,m,b):v<63?p=B(this,m,b):v<1024?p=H(this,m,b):p=U(this,m,b),p},"mulTo");function q(S,m){this.x=S,this.y=m}s(q,"FFTM"),q.prototype.makeRBT=s(function(m){for(var b=new Array(m),p=i.prototype._countBits(m)-1,v=0;v<m;v++)b[v]=this.revBin(v,p,m);return b},"makeRBT"),q.prototype.revBin=s(function(m,b,p){if(m===0||m===p-1)return m;for(var v=0,C=0;C<b;C++)v|=(m&1)<<b-C-1,m>>=1;return v},"revBin"),q.prototype.permute=s(function(m,b,p,v,C,I){for(var k=0;k<I;k++)v[k]=b[m[k]],C[k]=p[m[k]]},"permute"),q.prototype.transform=s(function(m,b,p,v,C,I){this.permute(I,m,b,p,v,C);for(var k=1;k<C;k<<=1)for(var w=k<<1,A=Math.cos(2*Math.PI/w),R=Math.sin(2*Math.PI/w),D=0;D<C;D+=w)for(var M=A,te=R,L=0;L<k;L++){var Y=p[D+L],Z=v[D+L],P=p[D+L+k],z=v[D+L+k],oe=M*P-te*z;z=M*z+te*P,P=oe,p[D+L]=Y+P,v[D+L]=Z+z,p[D+L+k]=Y-P,v[D+L+k]=Z-z,L!==w&&(oe=A*M-R*te,te=A*te+R*M,M=oe)}},"transform"),q.prototype.guessLen13b=s(function(m,b){var p=Math.max(b,m)|1,v=p&1,C=0;for(p=p/2|0;p;p=p>>>1)C++;return 1<<C+1+v},"guessLen13b"),q.prototype.conjugate=s(function(m,b,p){if(!(p<=1))for(var v=0;v<p/2;v++){var C=m[v];m[v]=m[p-v-1],m[p-v-1]=C,C=b[v],b[v]=-b[p-v-1],b[p-v-1]=-C}},"conjugate"),q.prototype.normalize13b=s(function(m,b){for(var p=0,v=0;v<b/2;v++){var C=Math.round(m[2*v+1]/b)*8192+Math.round(m[2*v]/b)+p;m[v]=C&67108863,C<67108864?p=0:p=C/67108864|0}return m},"normalize13b"),q.prototype.convert13b=s(function(m,b,p,v){for(var C=0,I=0;I<b;I++)C=C+(m[I]|0),p[2*I]=C&8191,C=C>>>13,p[2*I+1]=C&8191,C=C>>>13;for(I=2*b;I<v;++I)p[I]=0;r(C===0),r((C&-8192)===0)},"convert13b"),q.prototype.stub=s(function(m){for(var b=new Array(m),p=0;p<m;p++)b[p]=0;return b},"stub"),q.prototype.mulp=s(function(m,b,p){var v=2*this.guessLen13b(m.length,b.length),C=this.makeRBT(v),I=this.stub(v),k=new Array(v),w=new Array(v),A=new Array(v),R=new Array(v),D=new Array(v),M=new Array(v),te=p.words;te.length=v,this.convert13b(m.words,m.length,k,v),this.convert13b(b.words,b.length,R,v),this.transform(k,I,w,A,v,C),this.transform(R,I,D,M,v,C);for(var L=0;L<v;L++){var Y=w[L]*D[L]-A[L]*M[L];A[L]=w[L]*M[L]+A[L]*D[L],w[L]=Y}return this.conjugate(w,A,v),this.transform(w,A,te,I,v,C),this.conjugate(te,I,v),this.normalize13b(te,v),p.negative=m.negative^b.negative,p.length=m.length+b.length,p._strip()},"mulp"),i.prototype.mul=s(function(m){var b=new i(null);return b.words=new Array(this.length+m.length),this.mulTo(m,b)},"mul"),i.prototype.mulf=s(function(m){var b=new i(null);return b.words=new Array(this.length+m.length),U(this,m,b)},"mulf"),i.prototype.imul=s(function(m){return this.clone().mulTo(m,this)},"imul"),i.prototype.imuln=s(function(m){var b=m<0;b&&(m=-m),r(typeof m=="number"),r(m<67108864);for(var p=0,v=0;v<this.length;v++){var C=(this.words[v]|0)*m,I=(C&67108863)+(p&67108863);p>>=26,p+=C/67108864|0,p+=I>>>26,this.words[v]=I&67108863}return p!==0&&(this.words[v]=p,this.length++),b?this.ineg():this},"imuln"),i.prototype.muln=s(function(m){return this.clone().imuln(m)},"muln"),i.prototype.sqr=s(function(){return this.mul(this)},"sqr"),i.prototype.isqr=s(function(){return this.imul(this.clone())},"isqr"),i.prototype.pow=s(function(m){var b=T(m);if(b.length===0)return new i(1);for(var p=this,v=0;v<b.length&&b[v]===0;v++,p=p.sqr());if(++v<b.length)for(var C=p.sqr();v<b.length;v++,C=C.sqr())b[v]!==0&&(p=p.mul(C));return p},"pow"),i.prototype.iushln=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26,v=67108863>>>26-b<<26-b,C;if(b!==0){var I=0;for(C=0;C<this.length;C++){var k=this.words[C]&v,w=(this.words[C]|0)-k<<b;this.words[C]=w|I,I=k>>>26-b}I&&(this.words[C]=I,this.length++)}if(p!==0){for(C=this.length-1;C>=0;C--)this.words[C+p]=this.words[C];for(C=0;C<p;C++)this.words[C]=0;this.length+=p}return this._strip()},"iushln"),i.prototype.ishln=s(function(m){return r(this.negative===0),this.iushln(m)},"ishln"),i.prototype.iushrn=s(function(m,b,p){r(typeof m=="number"&&m>=0);var v;b?v=(b-b%26)/26:v=0;var C=m%26,I=Math.min((m-C)/26,this.length),k=67108863^67108863>>>C<<C,w=p;if(v-=I,v=Math.max(0,v),w){for(var A=0;A<I;A++)w.words[A]=this.words[A];w.length=I}if(I!==0)if(this.length>I)for(this.length-=I,A=0;A<this.length;A++)this.words[A]=this.words[A+I];else this.words[0]=0,this.length=1;var R=0;for(A=this.length-1;A>=0&&(R!==0||A>=v);A--){var D=this.words[A]|0;this.words[A]=R<<26-C|D>>>C,R=D&k}return w&&R!==0&&(w.words[w.length++]=R),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},"iushrn"),i.prototype.ishrn=s(function(m,b,p){return r(this.negative===0),this.iushrn(m,b,p)},"ishrn"),i.prototype.shln=s(function(m){return this.clone().ishln(m)},"shln"),i.prototype.ushln=s(function(m){return this.clone().iushln(m)},"ushln"),i.prototype.shrn=s(function(m){return this.clone().ishrn(m)},"shrn"),i.prototype.ushrn=s(function(m){return this.clone().iushrn(m)},"ushrn"),i.prototype.testn=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26,v=1<<b;if(this.length<=p)return!1;var C=this.words[p];return!!(C&v)},"testn"),i.prototype.imaskn=s(function(m){r(typeof m=="number"&&m>=0);var b=m%26,p=(m-b)/26;if(r(this.negative===0,"imaskn works only with positive numbers"),this.length<=p)return this;if(b!==0&&p++,this.length=Math.min(p,this.length),b!==0){var v=67108863^67108863>>>b<<b;this.words[this.length-1]&=v}return this._strip()},"imaskn"),i.prototype.maskn=s(function(m){return this.clone().imaskn(m)},"maskn"),i.prototype.iaddn=s(function(m){return r(typeof m=="number"),r(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)},"iaddn"),i.prototype._iaddn=s(function(m){this.words[0]+=m;for(var b=0;b<this.length&&this.words[b]>=67108864;b++)this.words[b]-=67108864,b===this.length-1?this.words[b+1]=1:this.words[b+1]++;return this.length=Math.max(this.length,b+1),this},"_iaddn"),i.prototype.isubn=s(function(m){if(r(typeof m=="number"),r(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 b=0;b<this.length&&this.words[b]<0;b++)this.words[b]+=67108864,this.words[b+1]-=1;return this._strip()},"isubn"),i.prototype.addn=s(function(m){return this.clone().iaddn(m)},"addn"),i.prototype.subn=s(function(m){return this.clone().isubn(m)},"subn"),i.prototype.iabs=s(function(){return this.negative=0,this},"iabs"),i.prototype.abs=s(function(){return this.clone().iabs()},"abs"),i.prototype._ishlnsubmul=s(function(m,b,p){var v=m.length+p,C;this._expand(v);var I,k=0;for(C=0;C<m.length;C++){I=(this.words[C+p]|0)+k;var w=(m.words[C]|0)*b;I-=w&67108863,k=(I>>26)-(w/67108864|0),this.words[C+p]=I&67108863}for(;C<this.length-p;C++)I=(this.words[C+p]|0)+k,k=I>>26,this.words[C+p]=I&67108863;if(k===0)return this._strip();for(r(k===-1),k=0,C=0;C<this.length;C++)I=-(this.words[C]|0)+k,k=I>>26,this.words[C]=I&67108863;return this.negative=1,this._strip()},"_ishlnsubmul"),i.prototype._wordDiv=s(function(m,b){var p=this.length-m.length,v=this.clone(),C=m,I=C.words[C.length-1]|0,k=this._countBits(I);p=26-k,p!==0&&(C=C.ushln(p),v.iushln(p),I=C.words[C.length-1]|0);var w=v.length-C.length,A;if(b!=="mod"){A=new i(null),A.length=w+1,A.words=new Array(A.length);for(var R=0;R<A.length;R++)A.words[R]=0}var D=v.clone()._ishlnsubmul(C,1,w);D.negative===0&&(v=D,A&&(A.words[w]=1));for(var M=w-1;M>=0;M--){var te=(v.words[C.length+M]|0)*67108864+(v.words[C.length+M-1]|0);for(te=Math.min(te/I|0,67108863),v._ishlnsubmul(C,te,M);v.negative!==0;)te--,v.negative=0,v._ishlnsubmul(C,1,M),v.isZero()||(v.negative^=1);A&&(A.words[M]=te)}return A&&A._strip(),v._strip(),b!=="div"&&p!==0&&v.iushrn(p),{div:A||null,mod:v}},"_wordDiv"),i.prototype.divmod=s(function(m,b,p){if(r(!m.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var v,C,I;return this.negative!==0&&m.negative===0?(I=this.neg().divmod(m,b),b!=="mod"&&(v=I.div.neg()),b!=="div"&&(C=I.mod.neg(),p&&C.negative!==0&&C.iadd(m)),{div:v,mod:C}):this.negative===0&&m.negative!==0?(I=this.divmod(m.neg(),b),b!=="mod"&&(v=I.div.neg()),{div:v,mod:I.mod}):(this.negative&m.negative)!==0?(I=this.neg().divmod(m.neg(),b),b!=="div"&&(C=I.mod.neg(),p&&C.negative!==0&&C.isub(m)),{div:I.div,mod:C}):m.length>this.length||this.cmp(m)<0?{div:new i(0),mod:this}:m.length===1?b==="div"?{div:this.divn(m.words[0]),mod:null}:b==="mod"?{div:null,mod:new i(this.modrn(m.words[0]))}:{div:this.divn(m.words[0]),mod:new i(this.modrn(m.words[0]))}:this._wordDiv(m,b)},"divmod"),i.prototype.div=s(function(m){return this.divmod(m,"div",!1).div},"div"),i.prototype.mod=s(function(m){return this.divmod(m,"mod",!1).mod},"mod"),i.prototype.umod=s(function(m){return this.divmod(m,"mod",!0).mod},"umod"),i.prototype.divRound=s(function(m){var b=this.divmod(m);if(b.mod.isZero())return b.div;var p=b.div.negative!==0?b.mod.isub(m):b.mod,v=m.ushrn(1),C=m.andln(1),I=p.cmp(v);return I<0||C===1&&I===0?b.div:b.div.negative!==0?b.div.isubn(1):b.div.iaddn(1)},"divRound"),i.prototype.modrn=s(function(m){var b=m<0;b&&(m=-m),r(m<=67108863);for(var p=(1<<26)%m,v=0,C=this.length-1;C>=0;C--)v=(p*v+(this.words[C]|0))%m;return b?-v:v},"modrn"),i.prototype.modn=s(function(m){return this.modrn(m)},"modn"),i.prototype.idivn=s(function(m){var b=m<0;b&&(m=-m),r(m<=67108863);for(var p=0,v=this.length-1;v>=0;v--){var C=(this.words[v]|0)+p*67108864;this.words[v]=C/m|0,p=C%m}return this._strip(),b?this.ineg():this},"idivn"),i.prototype.divn=s(function(m){return this.clone().idivn(m)},"divn"),i.prototype.egcd=s(function(m){r(m.negative===0),r(!m.isZero());var b=this,p=m.clone();b.negative!==0?b=b.umod(m):b=b.clone();for(var v=new i(1),C=new i(0),I=new i(0),k=new i(1),w=0;b.isEven()&&p.isEven();)b.iushrn(1),p.iushrn(1),++w;for(var A=p.clone(),R=b.clone();!b.isZero();){for(var D=0,M=1;(b.words[0]&M)===0&&D<26;++D,M<<=1);if(D>0)for(b.iushrn(D);D-- >0;)(v.isOdd()||C.isOdd())&&(v.iadd(A),C.isub(R)),v.iushrn(1),C.iushrn(1);for(var te=0,L=1;(p.words[0]&L)===0&&te<26;++te,L<<=1);if(te>0)for(p.iushrn(te);te-- >0;)(I.isOdd()||k.isOdd())&&(I.iadd(A),k.isub(R)),I.iushrn(1),k.iushrn(1);b.cmp(p)>=0?(b.isub(p),v.isub(I),C.isub(k)):(p.isub(b),I.isub(v),k.isub(C))}return{a:I,b:k,gcd:p.iushln(w)}},"egcd"),i.prototype._invmp=s(function(m){r(m.negative===0),r(!m.isZero());var b=this,p=m.clone();b.negative!==0?b=b.umod(m):b=b.clone();for(var v=new i(1),C=new i(0),I=p.clone();b.cmpn(1)>0&&p.cmpn(1)>0;){for(var k=0,w=1;(b.words[0]&w)===0&&k<26;++k,w<<=1);if(k>0)for(b.iushrn(k);k-- >0;)v.isOdd()&&v.iadd(I),v.iushrn(1);for(var A=0,R=1;(p.words[0]&R)===0&&A<26;++A,R<<=1);if(A>0)for(p.iushrn(A);A-- >0;)C.isOdd()&&C.iadd(I),C.iushrn(1);b.cmp(p)>=0?(b.isub(p),v.isub(C)):(p.isub(b),C.isub(v))}var D;return b.cmpn(1)===0?D=v:D=C,D.cmpn(0)<0&&D.iadd(m),D},"_invmp"),i.prototype.gcd=s(function(m){if(this.isZero())return m.abs();if(m.isZero())return this.abs();var b=this.clone(),p=m.clone();b.negative=0,p.negative=0;for(var v=0;b.isEven()&&p.isEven();v++)b.iushrn(1),p.iushrn(1);do{for(;b.isEven();)b.iushrn(1);for(;p.isEven();)p.iushrn(1);var C=b.cmp(p);if(C<0){var I=b;b=p,p=I}else if(C===0||p.cmpn(1)===0)break;b.isub(p)}while(!0);return p.iushln(v)},"gcd"),i.prototype.invm=s(function(m){return this.egcd(m).a.umod(m)},"invm"),i.prototype.isEven=s(function(){return(this.words[0]&1)===0},"isEven"),i.prototype.isOdd=s(function(){return(this.words[0]&1)===1},"isOdd"),i.prototype.andln=s(function(m){return this.words[0]&m},"andln"),i.prototype.bincn=s(function(m){r(typeof m=="number");var b=m%26,p=(m-b)/26,v=1<<b;if(this.length<=p)return this._expand(p+1),this.words[p]|=v,this;for(var C=v,I=p;C!==0&&I<this.length;I++){var k=this.words[I]|0;k+=C,C=k>>>26,k&=67108863,this.words[I]=k}return C!==0&&(this.words[I]=C,this.length++),this},"bincn"),i.prototype.isZero=s(function(){return this.length===1&&this.words[0]===0},"isZero"),i.prototype.cmpn=s(function(m){var b=m<0;if(this.negative!==0&&!b)return-1;if(this.negative===0&&b)return 1;this._strip();var p;if(this.length>1)p=1;else{b&&(m=-m),r(m<=67108863,"Number is too big");var v=this.words[0]|0;p=v===m?0:v<m?-1:1}return this.negative!==0?-p|0:p},"cmpn"),i.prototype.cmp=s(function(m){if(this.negative!==0&&m.negative===0)return-1;if(this.negative===0&&m.negative!==0)return 1;var b=this.ucmp(m);return this.negative!==0?-b|0:b},"cmp"),i.prototype.ucmp=s(function(m){if(this.length>m.length)return 1;if(this.length<m.length)return-1;for(var b=0,p=this.length-1;p>=0;p--){var v=this.words[p]|0,C=m.words[p]|0;if(v!==C){v<C?b=-1:v>C&&(b=1);break}}return b},"ucmp"),i.prototype.gtn=s(function(m){return this.cmpn(m)===1},"gtn"),i.prototype.gt=s(function(m){return this.cmp(m)===1},"gt"),i.prototype.gten=s(function(m){return this.cmpn(m)>=0},"gten"),i.prototype.gte=s(function(m){return this.cmp(m)>=0},"gte"),i.prototype.ltn=s(function(m){return this.cmpn(m)===-1},"ltn"),i.prototype.lt=s(function(m){return this.cmp(m)===-1},"lt"),i.prototype.lten=s(function(m){return this.cmpn(m)<=0},"lten"),i.prototype.lte=s(function(m){return this.cmp(m)<=0},"lte"),i.prototype.eqn=s(function(m){return this.cmpn(m)===0},"eqn"),i.prototype.eq=s(function(m){return this.cmp(m)===0},"eq"),i.red=s(function(m){return new ae(m)},"red"),i.prototype.toRed=s(function(m){return r(!this.red,"Already a number in reduction context"),r(this.negative===0,"red works only with positives"),m.convertTo(this)._forceRed(m)},"toRed"),i.prototype.fromRed=s(function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},"fromRed"),i.prototype._forceRed=s(function(m){return this.red=m,this},"_forceRed"),i.prototype.forceRed=s(function(m){return r(!this.red,"Already a number in reduction context"),this._forceRed(m)},"forceRed"),i.prototype.redAdd=s(function(m){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,m)},"redAdd"),i.prototype.redIAdd=s(function(m){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,m)},"redIAdd"),i.prototype.redSub=s(function(m){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,m)},"redSub"),i.prototype.redISub=s(function(m){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,m)},"redISub"),i.prototype.redShl=s(function(m){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,m)},"redShl"),i.prototype.redMul=s(function(m){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.mul(this,m)},"redMul"),i.prototype.redIMul=s(function(m){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.imul(this,m)},"redIMul"),i.prototype.redSqr=s(function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},"redSqr"),i.prototype.redISqr=s(function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},"redISqr"),i.prototype.redSqrt=s(function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},"redSqrt"),i.prototype.redInvm=s(function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},"redInvm"),i.prototype.redNeg=s(function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},"redNeg"),i.prototype.redPow=s(function(m){return r(this.red&&!m.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,m)},"redPow");var K={k256:null,p224:null,p192:null,p25519:null};function W(S,m){this.name=S,this.p=new i(m,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}s(W,"MPrime"),W.prototype._tmp=s(function(){var m=new i(null);return m.words=new Array(Math.ceil(this.n/13)),m},"_tmp"),W.prototype.ireduce=s(function(m){var b=m,p;do this.split(b,this.tmp),b=this.imulK(b),b=b.iadd(this.tmp),p=b.bitLength();while(p>this.n);var v=p<this.n?-1:b.ucmp(this.p);return v===0?(b.words[0]=0,b.length=1):v>0?b.isub(this.p):b.strip!==void 0?b.strip():b._strip(),b},"ireduce"),W.prototype.split=s(function(m,b){m.iushrn(this.n,0,b)},"split"),W.prototype.imulK=s(function(m){return m.imul(this.k)},"imulK");function N(){W.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(N,"K256"),n(N,W),N.prototype.split=s(function(m,b){for(var p=4194303,v=Math.min(m.length,9),C=0;C<v;C++)b.words[C]=m.words[C];if(b.length=v,m.length<=9){m.words[0]=0,m.length=1;return}var I=m.words[9];for(b.words[b.length++]=I&p,C=10;C<m.length;C++){var k=m.words[C]|0;m.words[C-10]=(k&p)<<4|I>>>22,I=k}I>>>=22,m.words[C-10]=I,I===0&&m.length>10?m.length-=10:m.length-=9},"split"),N.prototype.imulK=s(function(m){m.words[m.length]=0,m.words[m.length+1]=0,m.length+=2;for(var b=0,p=0;p<m.length;p++){var v=m.words[p]|0;b+=v*977,m.words[p]=b&67108863,b=v*64+(b/67108864|0)}return m.words[m.length-1]===0&&(m.length--,m.words[m.length-1]===0&&m.length--),m},"imulK");function G(){W.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}s(G,"P224"),n(G,W);function ce(){W.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}s(ce,"P192"),n(ce,W);function re(){W.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}s(re,"P25519"),n(re,W),re.prototype.imulK=s(function(m){for(var b=0,p=0;p<m.length;p++){var v=(m.words[p]|0)*19+b,C=v&67108863;v>>>=26,m.words[p]=C,b=v}return b!==0&&(m.words[m.length++]=b),m},"imulK"),i._prime=s(function(m){if(K[m])return K[m];var b;if(m==="k256")b=new N;else if(m==="p224")b=new G;else if(m==="p192")b=new ce;else if(m==="p25519")b=new re;else throw new Error("Unknown prime "+m);return K[m]=b,b},"prime");function ae(S){if(typeof S=="string"){var m=i._prime(S);this.m=m.p,this.prime=m}else r(S.gtn(1),"modulus must be greater than 1"),this.m=S,this.prime=null}s(ae,"Red"),ae.prototype._verify1=s(function(m){r(m.negative===0,"red works only with positives"),r(m.red,"red works only with red numbers")},"_verify1"),ae.prototype._verify2=s(function(m,b){r((m.negative|b.negative)===0,"red works only with positives"),r(m.red&&m.red===b.red,"red works only with red numbers")},"_verify2"),ae.prototype.imod=s(function(m){return this.prime?this.prime.ireduce(m)._forceRed(this):(u(m,m.umod(this.m)._forceRed(this)),m)},"imod"),ae.prototype.neg=s(function(m){return m.isZero()?m.clone():this.m.sub(m)._forceRed(this)},"neg"),ae.prototype.add=s(function(m,b){this._verify2(m,b);var p=m.add(b);return p.cmp(this.m)>=0&&p.isub(this.m),p._forceRed(this)},"add"),ae.prototype.iadd=s(function(m,b){this._verify2(m,b);var p=m.iadd(b);return p.cmp(this.m)>=0&&p.isub(this.m),p},"iadd"),ae.prototype.sub=s(function(m,b){this._verify2(m,b);var p=m.sub(b);return p.cmpn(0)<0&&p.iadd(this.m),p._forceRed(this)},"sub"),ae.prototype.isub=s(function(m,b){this._verify2(m,b);var p=m.isub(b);return p.cmpn(0)<0&&p.iadd(this.m),p},"isub"),ae.prototype.shl=s(function(m,b){return this._verify1(m),this.imod(m.ushln(b))},"shl"),ae.prototype.imul=s(function(m,b){return this._verify2(m,b),this.imod(m.imul(b))},"imul"),ae.prototype.mul=s(function(m,b){return this._verify2(m,b),this.imod(m.mul(b))},"mul"),ae.prototype.isqr=s(function(m){return this.imul(m,m.clone())},"isqr"),ae.prototype.sqr=s(function(m){return this.mul(m,m)},"sqr"),ae.prototype.sqrt=s(function(m){if(m.isZero())return m.clone();var b=this.m.andln(3);if(r(b%2===1),b===3){var p=this.m.add(new i(1)).iushrn(2);return this.pow(m,p)}for(var v=this.m.subn(1),C=0;!v.isZero()&&v.andln(1)===0;)C++,v.iushrn(1);r(!v.isZero());var I=new i(1).toRed(this),k=I.redNeg(),w=this.m.subn(1).iushrn(1),A=this.m.bitLength();for(A=new i(2*A*A).toRed(this);this.pow(A,w).cmp(k)!==0;)A.redIAdd(k);for(var R=this.pow(A,v),D=this.pow(m,v.addn(1).iushrn(1)),M=this.pow(m,v),te=C;M.cmp(I)!==0;){for(var L=M,Y=0;L.cmp(I)!==0;Y++)L=L.redSqr();r(Y<te);var Z=this.pow(R,new i(1).iushln(te-Y-1));D=D.redMul(Z),R=Z.redSqr(),M=M.redMul(R),te=Y}return D},"sqrt"),ae.prototype.invm=s(function(m){var b=m._invmp(this.m);return b.negative!==0?(b.negative=0,this.imod(b).redNeg()):this.imod(b)},"invm"),ae.prototype.pow=s(function(m,b){if(b.isZero())return new i(1).toRed(this);if(b.cmpn(1)===0)return m.clone();var p=4,v=new Array(1<<p);v[0]=new i(1).toRed(this),v[1]=m;for(var C=2;C<v.length;C++)v[C]=this.mul(v[C-1],m);var I=v[0],k=0,w=0,A=b.bitLength()%26;for(A===0&&(A=26),C=b.length-1;C>=0;C--){for(var R=b.words[C],D=A-1;D>=0;D--){var M=R>>D&1;if(I!==v[0]&&(I=this.sqr(I)),M===0&&k===0){w=0;continue}k<<=1,k|=M,w++,!(w!==p&&(C!==0||D!==0))&&(I=this.mul(I,v[k]),w=0,k=0)}A=26}return I},"pow"),ae.prototype.convertTo=s(function(m){var b=m.umod(this.m);return b===m?b.clone():b},"convertTo"),ae.prototype.convertFrom=s(function(m){var b=m.clone();return b.red=null,b},"convertFrom"),i.mont=s(function(m){return new J(m)},"mont");function J(S){ae.call(this,S),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(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)}s(J,"Mont"),n(J,ae),J.prototype.convertTo=s(function(m){return this.imod(m.ushln(this.shift))},"convertTo"),J.prototype.convertFrom=s(function(m){var b=this.imod(m.mul(this.rinv));return b.red=null,b},"convertFrom"),J.prototype.imul=s(function(m,b){if(m.isZero()||b.isZero())return m.words[0]=0,m.length=1,m;var p=m.imul(b),v=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),C=p.isub(v).iushrn(this.shift),I=C;return C.cmp(this.m)>=0?I=C.isub(this.m):C.cmpn(0)<0&&(I=C.iadd(this.m)),I._forceRed(this)},"imul"),J.prototype.mul=s(function(m,b){if(m.isZero()||b.isZero())return new i(0)._forceRed(this);var p=m.mul(b),v=p.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),C=p.isub(v).iushrn(this.shift),I=C;return C.cmp(this.m)>=0?I=C.isub(this.m):C.cmpn(0)<0&&(I=C.iadd(this.m)),I._forceRed(this)},"mul"),J.prototype.invm=s(function(m){var b=this.imod(m._invmp(this.m).mul(this.r2));return b._forceRed(this)},"invm")})(typeof i3>"u"||i3,nS)});var kS=an((uoe,Ig)=>{(function(){"use strict";var t="input is invalid type",e="finalize already called",r=typeof window=="object",n=r?window:{};n.JS_SHA3_NO_WINDOW&&(r=!1);var i=!r&&typeof self=="object",o=!n.JS_SHA3_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node;o?n=global:i&&(n=self);var a=!n.JS_SHA3_NO_COMMON_JS&&typeof Ig=="object"&&Ig.exports,f=typeof define=="function"&&define.amd,l=!n.JS_SHA3_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",u="0123456789abcdef".split(""),h=[31,7936,2031616,520093696],g=[4,1024,262144,67108864],x=[1,256,65536,16777216],_=[6,1536,393216,100663296],E=[0,8,16,24],T=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],B=[224,256,384,512],F=[128,256],H=["hex","buffer","arrayBuffer","array","digest"],U={128:168,256:136};(n.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(M){return Object.prototype.toString.call(M)==="[object Array]"}),l&&(n.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(M){return typeof M=="object"&&M.buffer&&M.buffer.constructor===ArrayBuffer});for(var q=s(function(M,te,L){return function(Y){return new A(M,te,M).update(Y)[L]()}},"createOutputMethod"),K=s(function(M,te,L){return function(Y,Z){return new A(M,te,Z).update(Y)[L]()}},"createShakeOutputMethod"),W=s(function(M,te,L){return function(Y,Z,P,z){return m["cshake"+M].update(Y,Z,P,z)[L]()}},"createCshakeOutputMethod"),N=s(function(M,te,L){return function(Y,Z,P,z){return m["kmac"+M].update(Y,Z,P,z)[L]()}},"createKmacOutputMethod"),G=s(function(M,te,L,Y){for(var Z=0;Z<H.length;++Z){var P=H[Z];M[P]=te(L,Y,P)}return M},"createOutputMethods"),ce=s(function(M,te){var L=q(M,te,"hex");return L.create=function(){return new A(M,te,M)},L.update=function(Y){return L.create().update(Y)},G(L,q,M,te)},"createMethod"),re=s(function(M,te){var L=K(M,te,"hex");return L.create=function(Y){return new A(M,te,Y)},L.update=function(Y,Z){return L.create(Z).update(Y)},G(L,K,M,te)},"createShakeMethod"),ae=s(function(M,te){var L=U[M],Y=W(M,te,"hex");return Y.create=function(Z,P,z){return!P&&!z?m["shake"+M].create(Z):new A(M,te,Z).bytepad([P,z],L)},Y.update=function(Z,P,z,oe){return Y.create(P,z,oe).update(Z)},G(Y,W,M,te)},"createCshakeMethod"),J=s(function(M,te){var L=U[M],Y=N(M,te,"hex");return Y.create=function(Z,P,z){return new R(M,te,P).bytepad(["KMAC",z],L).bytepad([Z],L)},Y.update=function(Z,P,z,oe){return Y.create(Z,z,oe).update(P)},G(Y,N,M,te)},"createKmacMethod"),S=[{name:"keccak",padding:x,bits:B,createMethod:ce},{name:"sha3",padding:_,bits:B,createMethod:ce},{name:"shake",padding:h,bits:F,createMethod:re},{name:"cshake",padding:g,bits:F,createMethod:ae},{name:"kmac",padding:g,bits:F,createMethod:J}],m={},b=[],p=0;p<S.length;++p)for(var v=S[p],C=v.bits,I=0;I<C.length;++I){var k=v.name+"_"+C[I];if(b.push(k),m[k]=v.createMethod(C[I],v.padding),v.name!=="sha3"){var w=v.name+C[I];b.push(w),m[w]=m[k]}}function A(M,te,L){this.blocks=[],this.s=[],this.padding=te,this.outputBits=L,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(M<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=L>>5,this.extraBytes=(L&31)>>3;for(var Y=0;Y<50;++Y)this.s[Y]=0}s(A,"Keccak"),A.prototype.update=function(M){if(this.finalized)throw new Error(e);var te,L=typeof M;if(L!=="string"){if(L==="object"){if(M===null)throw new Error(t);if(l&&M.constructor===ArrayBuffer)M=new Uint8Array(M);else if(!Array.isArray(M)&&(!l||!ArrayBuffer.isView(M)))throw new Error(t)}else throw new Error(t);te=!0}for(var Y=this.blocks,Z=this.byteCount,P=M.length,z=this.blockCount,oe=0,ue=this.s,me,ke;oe<P;){if(this.reset)for(this.reset=!1,Y[0]=this.block,me=1;me<z+1;++me)Y[me]=0;if(te)for(me=this.start;oe<P&&me<Z;++oe)Y[me>>2]|=M[oe]<<E[me++&3];else for(me=this.start;oe<P&&me<Z;++oe)ke=M.charCodeAt(oe),ke<128?Y[me>>2]|=ke<<E[me++&3]:ke<2048?(Y[me>>2]|=(192|ke>>6)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]):ke<55296||ke>=57344?(Y[me>>2]|=(224|ke>>12)<<E[me++&3],Y[me>>2]|=(128|ke>>6&63)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]):(ke=65536+((ke&1023)<<10|M.charCodeAt(++oe)&1023),Y[me>>2]|=(240|ke>>18)<<E[me++&3],Y[me>>2]|=(128|ke>>12&63)<<E[me++&3],Y[me>>2]|=(128|ke>>6&63)<<E[me++&3],Y[me>>2]|=(128|ke&63)<<E[me++&3]);if(this.lastByteIndex=me,me>=Z){for(this.start=me-Z,this.block=Y[z],me=0;me<z;++me)ue[me]^=Y[me];D(ue),this.reset=!0}else this.start=me}return this},A.prototype.encode=function(M,te){var L=M&255,Y=1,Z=[L];for(M=M>>8,L=M&255;L>0;)Z.unshift(L),M=M>>8,L=M&255,++Y;return te?Z.push(Y):Z.unshift(Y),this.update(Z),Z.length},A.prototype.encodeString=function(M){var te,L=typeof M;if(L!=="string"){if(L==="object"){if(M===null)throw new Error(t);if(l&&M.constructor===ArrayBuffer)M=new Uint8Array(M);else if(!Array.isArray(M)&&(!l||!ArrayBuffer.isView(M)))throw new Error(t)}else throw new Error(t);te=!0}var Y=0,Z=M.length;if(te)Y=Z;else for(var P=0;P<M.length;++P){var z=M.charCodeAt(P);z<128?Y+=1:z<2048?Y+=2:z<55296||z>=57344?Y+=3:(z=65536+((z&1023)<<10|M.charCodeAt(++P)&1023),Y+=4)}return Y+=this.encode(Y*8),this.update(M),Y},A.prototype.bytepad=function(M,te){for(var L=this.encode(te),Y=0;Y<M.length;++Y)L+=this.encodeString(M[Y]);var Z=te-L%te,P=[];return P.length=Z,this.update(P),this},A.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var M=this.blocks,te=this.lastByteIndex,L=this.blockCount,Y=this.s;if(M[te>>2]|=this.padding[te&3],this.lastByteIndex===this.byteCount)for(M[0]=M[L],te=1;te<L+1;++te)M[te]=0;for(M[L-1]|=2147483648,te=0;te<L;++te)Y[te]^=M[te];D(Y)}},A.prototype.toString=A.prototype.hex=function(){this.finalize();for(var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z="",oe;P<L;){for(Z=0;Z<M&&P<L;++Z,++P)oe=te[Z],z+=u[oe>>4&15]+u[oe&15]+u[oe>>12&15]+u[oe>>8&15]+u[oe>>20&15]+u[oe>>16&15]+u[oe>>28&15]+u[oe>>24&15];P%M===0&&(D(te),Z=0)}return Y&&(oe=te[Z],z+=u[oe>>4&15]+u[oe&15],Y>1&&(z+=u[oe>>12&15]+u[oe>>8&15]),Y>2&&(z+=u[oe>>20&15]+u[oe>>16&15])),z},A.prototype.arrayBuffer=function(){this.finalize();var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z=this.outputBits>>3,oe;Y?oe=new ArrayBuffer(L+1<<2):oe=new ArrayBuffer(z);for(var ue=new Uint32Array(oe);P<L;){for(Z=0;Z<M&&P<L;++Z,++P)ue[P]=te[Z];P%M===0&&D(te)}return Y&&(ue[Z]=te[Z],oe=oe.slice(0,z)),oe},A.prototype.buffer=A.prototype.arrayBuffer,A.prototype.digest=A.prototype.array=function(){this.finalize();for(var M=this.blockCount,te=this.s,L=this.outputBlocks,Y=this.extraBytes,Z=0,P=0,z=[],oe,ue;P<L;){for(Z=0;Z<M&&P<L;++Z,++P)oe=P<<2,ue=te[Z],z[oe]=ue&255,z[oe+1]=ue>>8&255,z[oe+2]=ue>>16&255,z[oe+3]=ue>>24&255;P%M===0&&D(te)}return Y&&(oe=P<<2,ue=te[Z],z[oe]=ue&255,Y>1&&(z[oe+1]=ue>>8&255),Y>2&&(z[oe+2]=ue>>16&255)),z};function R(M,te,L){A.call(this,M,te,L)}s(R,"Kmac"),R.prototype=new A,R.prototype.finalize=function(){return this.encode(this.outputBits,!0),A.prototype.finalize.call(this)};var D=s(function(M){var te,L,Y,Z,P,z,oe,ue,me,ke,Q,j,$,X,se,ee,le,be,Se,Te,De,Ne,ye,pe,ne,he,Ee,Ie,Re,Oe,bt,Qe,qe,vt,gt,tt,Ut,ht,et,Dt,pt,Xe,Mt,ft,Ye,It,lt,Ze,Rt,ut,Je,Bt,dt,at,tr,Tt,rt,Yt,Kt,Vt,Vr,Wr,Ir;for(Y=0;Y<48;Y+=2)Z=M[0]^M[10]^M[20]^M[30]^M[40],P=M[1]^M[11]^M[21]^M[31]^M[41],z=M[2]^M[12]^M[22]^M[32]^M[42],oe=M[3]^M[13]^M[23]^M[33]^M[43],ue=M[4]^M[14]^M[24]^M[34]^M[44],me=M[5]^M[15]^M[25]^M[35]^M[45],ke=M[6]^M[16]^M[26]^M[36]^M[46],Q=M[7]^M[17]^M[27]^M[37]^M[47],j=M[8]^M[18]^M[28]^M[38]^M[48],$=M[9]^M[19]^M[29]^M[39]^M[49],te=j^(z<<1|oe>>>31),L=$^(oe<<1|z>>>31),M[0]^=te,M[1]^=L,M[10]^=te,M[11]^=L,M[20]^=te,M[21]^=L,M[30]^=te,M[31]^=L,M[40]^=te,M[41]^=L,te=Z^(ue<<1|me>>>31),L=P^(me<<1|ue>>>31),M[2]^=te,M[3]^=L,M[12]^=te,M[13]^=L,M[22]^=te,M[23]^=L,M[32]^=te,M[33]^=L,M[42]^=te,M[43]^=L,te=z^(ke<<1|Q>>>31),L=oe^(Q<<1|ke>>>31),M[4]^=te,M[5]^=L,M[14]^=te,M[15]^=L,M[24]^=te,M[25]^=L,M[34]^=te,M[35]^=L,M[44]^=te,M[45]^=L,te=ue^(j<<1|$>>>31),L=me^($<<1|j>>>31),M[6]^=te,M[7]^=L,M[16]^=te,M[17]^=L,M[26]^=te,M[27]^=L,M[36]^=te,M[37]^=L,M[46]^=te,M[47]^=L,te=ke^(Z<<1|P>>>31),L=Q^(P<<1|Z>>>31),M[8]^=te,M[9]^=L,M[18]^=te,M[19]^=L,M[28]^=te,M[29]^=L,M[38]^=te,M[39]^=L,M[48]^=te,M[49]^=L,X=M[0],se=M[1],It=M[11]<<4|M[10]>>>28,lt=M[10]<<4|M[11]>>>28,Ie=M[20]<<3|M[21]>>>29,Re=M[21]<<3|M[20]>>>29,Vt=M[31]<<9|M[30]>>>23,Vr=M[30]<<9|M[31]>>>23,Xe=M[40]<<18|M[41]>>>14,Mt=M[41]<<18|M[40]>>>14,vt=M[2]<<1|M[3]>>>31,gt=M[3]<<1|M[2]>>>31,ee=M[13]<<12|M[12]>>>20,le=M[12]<<12|M[13]>>>20,Ze=M[22]<<10|M[23]>>>22,Rt=M[23]<<10|M[22]>>>22,Oe=M[33]<<13|M[32]>>>19,bt=M[32]<<13|M[33]>>>19,Wr=M[42]<<2|M[43]>>>30,Ir=M[43]<<2|M[42]>>>30,at=M[5]<<30|M[4]>>>2,tr=M[4]<<30|M[5]>>>2,tt=M[14]<<6|M[15]>>>26,Ut=M[15]<<6|M[14]>>>26,be=M[25]<<11|M[24]>>>21,Se=M[24]<<11|M[25]>>>21,ut=M[34]<<15|M[35]>>>17,Je=M[35]<<15|M[34]>>>17,Qe=M[45]<<29|M[44]>>>3,qe=M[44]<<29|M[45]>>>3,pe=M[6]<<28|M[7]>>>4,ne=M[7]<<28|M[6]>>>4,Tt=M[17]<<23|M[16]>>>9,rt=M[16]<<23|M[17]>>>9,ht=M[26]<<25|M[27]>>>7,et=M[27]<<25|M[26]>>>7,Te=M[36]<<21|M[37]>>>11,De=M[37]<<21|M[36]>>>11,Bt=M[47]<<24|M[46]>>>8,dt=M[46]<<24|M[47]>>>8,ft=M[8]<<27|M[9]>>>5,Ye=M[9]<<27|M[8]>>>5,he=M[18]<<20|M[19]>>>12,Ee=M[19]<<20|M[18]>>>12,Yt=M[29]<<7|M[28]>>>25,Kt=M[28]<<7|M[29]>>>25,Dt=M[38]<<8|M[39]>>>24,pt=M[39]<<8|M[38]>>>24,Ne=M[48]<<14|M[49]>>>18,ye=M[49]<<14|M[48]>>>18,M[0]=X^~ee&be,M[1]=se^~le&Se,M[10]=pe^~he&Ie,M[11]=ne^~Ee&Re,M[20]=vt^~tt&ht,M[21]=gt^~Ut&et,M[30]=ft^~It&Ze,M[31]=Ye^~lt&Rt,M[40]=at^~Tt&Yt,M[41]=tr^~rt&Kt,M[2]=ee^~be&Te,M[3]=le^~Se&De,M[12]=he^~Ie&Oe,M[13]=Ee^~Re&bt,M[22]=tt^~ht&Dt,M[23]=Ut^~et&pt,M[32]=It^~Ze&ut,M[33]=lt^~Rt&Je,M[42]=Tt^~Yt&Vt,M[43]=rt^~Kt&Vr,M[4]=be^~Te&Ne,M[5]=Se^~De&ye,M[14]=Ie^~Oe&Qe,M[15]=Re^~bt&qe,M[24]=ht^~Dt&Xe,M[25]=et^~pt&Mt,M[34]=Ze^~ut&Bt,M[35]=Rt^~Je&dt,M[44]=Yt^~Vt&Wr,M[45]=Kt^~Vr&Ir,M[6]=Te^~Ne&X,M[7]=De^~ye&se,M[16]=Oe^~Qe&pe,M[17]=bt^~qe&ne,M[26]=Dt^~Xe&vt,M[27]=pt^~Mt>,M[36]=ut^~Bt&ft,M[37]=Je^~dt&Ye,M[46]=Vt^~Wr&at,M[47]=Vr^~Ir&tr,M[8]=Ne^~X&ee,M[9]=ye^~se&le,M[18]=Qe^~pe&he,M[19]=qe^~ne&Ee,M[28]=Xe^~vt&tt,M[29]=Mt^~gt&Ut,M[38]=Bt^~ft&It,M[39]=dt^~Ye<,M[48]=Wr^~at&Tt,M[49]=Ir^~tr&rt,M[0]^=T[Y],M[1]^=T[Y+1]},"f");if(a)Ig.exports=m;else{for(p=0;p<b.length;++p)n[b[p]]=m[b[p]];f&&define(function(){return m})}})()});var Qu=an((rfe,AI)=>{AI.exports=_I;function _I(t,e){if(!t)throw new Error(e||"Assertion failed")}s(_I,"assert");_I.equal=s(function(e,r,n){if(e!=r)throw new Error(n||"Assertion failed: "+e+" != "+r)},"assertEqual")});var EI=an((nfe,B3)=>{typeof Object.create=="function"?B3.exports=s(function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))},"inherits"):B3.exports=s(function(e,r){if(r){e.super_=r;var n=s(function(){},"TempCtor");n.prototype=r.prototype,e.prototype=new n,e.prototype.constructor=e}},"inherits")});var Io=an(zr=>{"use strict";var LG=Qu(),UG=EI();zr.inherits=UG;function jG(t,e){return(t.charCodeAt(e)&64512)!==55296||e<0||e+1>=t.length?!1:(t.charCodeAt(e+1)&64512)===56320}s(jG,"isSurrogatePair");function qG(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if(typeof t=="string")if(e){if(e==="hex")for(t=t.replace(/[^a-z0-9]+/ig,""),t.length%2!==0&&(t="0"+t),i=0;i<t.length;i+=2)r.push(parseInt(t[i]+t[i+1],16))}else for(var n=0,i=0;i<t.length;i++){var o=t.charCodeAt(i);o<128?r[n++]=o:o<2048?(r[n++]=o>>6|192,r[n++]=o&63|128):jG(t,i)?(o=65536+((o&1023)<<10)+(t.charCodeAt(++i)&1023),r[n++]=o>>18|240,r[n++]=o>>12&63|128,r[n++]=o>>6&63|128,r[n++]=o&63|128):(r[n++]=o>>12|224,r[n++]=o>>6&63|128,r[n++]=o&63|128)}else for(i=0;i<t.length;i++)r[i]=t[i]|0;return r}s(qG,"toArray");zr.toArray=qG;function HG(t){for(var e="",r=0;r<t.length;r++)e+=SI(t[r].toString(16));return e}s(HG,"toHex");zr.toHex=HG;function CI(t){var e=t>>>24|t>>>8&65280|t<<8&16711680|(t&255)<<24;return e>>>0}s(CI,"htonl");zr.htonl=CI;function zG(t,e){for(var r="",n=0;n<t.length;n++){var i=t[n];e==="little"&&(i=CI(i)),r+=II(i.toString(16))}return r}s(zG,"toHex32");zr.toHex32=zG;function SI(t){return t.length===1?"0"+t:t}s(SI,"zero2");zr.zero2=SI;function II(t){return t.length===7?"0"+t:t.length===6?"00"+t:t.length===5?"000"+t:t.length===4?"0000"+t:t.length===3?"00000"+t:t.length===2?"000000"+t:t.length===1?"0000000"+t:t}s(II,"zero8");zr.zero8=II;function $G(t,e,r,n){var i=r-e;LG(i%4===0);for(var o=new Array(i/4),a=0,f=e;a<o.length;a++,f+=4){var l;n==="big"?l=t[f]<<24|t[f+1]<<16|t[f+2]<<8|t[f+3]:l=t[f+3]<<24|t[f+2]<<16|t[f+1]<<8|t[f],o[a]=l>>>0}return o}s($G,"join32");zr.join32=$G;function GG(t,e){for(var r=new Array(t.length*4),n=0,i=0;n<t.length;n++,i+=4){var o=t[n];e==="big"?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=o&255):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=o&255)}return r}s(GG,"split32");zr.split32=GG;function KG(t,e){return t>>>e|t<<32-e}s(KG,"rotr32");zr.rotr32=KG;function VG(t,e){return t<<e|t>>>32-e}s(VG,"rotl32");zr.rotl32=VG;function WG(t,e){return t+e>>>0}s(WG,"sum32");zr.sum32=WG;function JG(t,e,r){return t+e+r>>>0}s(JG,"sum32_3");zr.sum32_3=JG;function YG(t,e,r,n){return t+e+r+n>>>0}s(YG,"sum32_4");zr.sum32_4=YG;function ZG(t,e,r,n,i){return t+e+r+n+i>>>0}s(ZG,"sum32_5");zr.sum32_5=ZG;function XG(t,e,r,n){var i=t[e],o=t[e+1],a=n+o>>>0,f=(a<n?1:0)+r+i;t[e]=f>>>0,t[e+1]=a}s(XG,"sum64");zr.sum64=XG;function QG(t,e,r,n){var i=e+n>>>0,o=(i<e?1:0)+t+r;return o>>>0}s(QG,"sum64_hi");zr.sum64_hi=QG;function eK(t,e,r,n){var i=e+n;return i>>>0}s(eK,"sum64_lo");zr.sum64_lo=eK;function tK(t,e,r,n,i,o,a,f){var l=0,u=e;u=u+n>>>0,l+=u<e?1:0,u=u+o>>>0,l+=u<o?1:0,u=u+f>>>0,l+=u<f?1:0;var h=t+r+i+a+l;return h>>>0}s(tK,"sum64_4_hi");zr.sum64_4_hi=tK;function rK(t,e,r,n,i,o,a,f){var l=e+n+o+f;return l>>>0}s(rK,"sum64_4_lo");zr.sum64_4_lo=rK;function nK(t,e,r,n,i,o,a,f,l,u){var h=0,g=e;g=g+n>>>0,h+=g<e?1:0,g=g+o>>>0,h+=g<o?1:0,g=g+f>>>0,h+=g<f?1:0,g=g+u>>>0,h+=g<u?1:0;var x=t+r+i+a+l+h;return x>>>0}s(nK,"sum64_5_hi");zr.sum64_5_hi=nK;function iK(t,e,r,n,i,o,a,f,l,u){var h=e+n+o+f+u;return h>>>0}s(iK,"sum64_5_lo");zr.sum64_5_lo=iK;function sK(t,e,r){var n=e<<32-r|t>>>r;return n>>>0}s(sK,"rotr64_hi");zr.rotr64_hi=sK;function oK(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}s(oK,"rotr64_lo");zr.rotr64_lo=oK;function aK(t,e,r){return t>>>r}s(aK,"shr64_hi");zr.shr64_hi=aK;function cK(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}s(cK,"shr64_lo");zr.shr64_lo=cK});var ed=an(TI=>{"use strict";var kI=Io(),fK=Qu();function Ug(){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}s(Ug,"BlockHash");TI.BlockHash=Ug;Ug.prototype.update=s(function(e,r){if(e=kI.toArray(e,r),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){e=this.pending;var n=e.length%this._delta8;this.pending=e.slice(e.length-n,e.length),this.pending.length===0&&(this.pending=null),e=kI.join32(e,0,e.length-n,this.endian);for(var i=0;i<e.length;i+=this._delta32)this._update(e,i,i+this._delta32)}return this},"update");Ug.prototype.digest=s(function(e){return this.update(this._pad()),fK(this.pending===null),this._digest(e)},"digest");Ug.prototype._pad=s(function(){var e=this.pendingTotal,r=this._delta8,n=r-(e+this.padLength)%r,i=new Array(n+this.padLength);i[0]=128;for(var o=1;o<n;o++)i[o]=0;if(e<<=3,this.endian==="big"){for(var a=8;a<this.padLength;a++)i[o++]=0;i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=e>>>24&255,i[o++]=e>>>16&255,i[o++]=e>>>8&255,i[o++]=e&255}else for(i[o++]=e&255,i[o++]=e>>>8&255,i[o++]=e>>>16&255,i[o++]=e>>>24&255,i[o++]=0,i[o++]=0,i[o++]=0,i[o++]=0,a=8;a<this.padLength;a++)i[o++]=0;return i},"pad")});var D3=an(yc=>{"use strict";var lK=Io(),wa=lK.rotr32;function uK(t,e,r,n){if(t===0)return MI(e,r,n);if(t===1||t===3)return BI(e,r,n);if(t===2)return RI(e,r,n)}s(uK,"ft_1");yc.ft_1=uK;function MI(t,e,r){return t&e^~t&r}s(MI,"ch32");yc.ch32=MI;function RI(t,e,r){return t&e^t&r^e&r}s(RI,"maj32");yc.maj32=RI;function BI(t,e,r){return t^e^r}s(BI,"p32");yc.p32=BI;function dK(t){return wa(t,2)^wa(t,13)^wa(t,22)}s(dK,"s0_256");yc.s0_256=dK;function hK(t){return wa(t,6)^wa(t,11)^wa(t,25)}s(hK,"s1_256");yc.s1_256=hK;function pK(t){return wa(t,7)^wa(t,18)^t>>>3}s(pK,"g0_256");yc.g0_256=pK;function mK(t){return wa(t,17)^wa(t,19)^t>>>10}s(mK,"g1_256");yc.g1_256=mK});var OI=an((afe,PI)=>{"use strict";var td=Io(),gK=ed(),bK=D3(),P3=td.rotl32,Z0=td.sum32,vK=td.sum32_5,yK=bK.ft_1,DI=gK.BlockHash,xK=[1518500249,1859775393,2400959708,3395469782];function _a(){if(!(this instanceof _a))return new _a;DI.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}s(_a,"SHA1");td.inherits(_a,DI);PI.exports=_a;_a.blockSize=512;_a.outSize=160;_a.hmacStrength=80;_a.padLength=64;_a.prototype._update=s(function(e,r){for(var n=this.W,i=0;i<16;i++)n[i]=e[r+i];for(;i<n.length;i++)n[i]=P3(n[i-3]^n[i-8]^n[i-14]^n[i-16],1);var o=this.h[0],a=this.h[1],f=this.h[2],l=this.h[3],u=this.h[4];for(i=0;i<n.length;i++){var h=~~(i/20),g=vK(P3(o,5),yK(h,a,f,l),u,n[i],xK[h]);u=l,l=f,f=P3(a,30),a=o,o=g}this.h[0]=Z0(this.h[0],o),this.h[1]=Z0(this.h[1],a),this.h[2]=Z0(this.h[2],f),this.h[3]=Z0(this.h[3],l),this.h[4]=Z0(this.h[4],u)},"_update");_a.prototype._digest=s(function(e){return e==="hex"?td.toHex32(this.h,"big"):td.split32(this.h,"big")},"digest")});var O3=an((cfe,NI)=>{"use strict";var rd=Io(),wK=ed(),nd=D3(),_K=Qu(),ko=rd.sum32,AK=rd.sum32_4,EK=rd.sum32_5,CK=nd.ch32,SK=nd.maj32,IK=nd.s0_256,kK=nd.s1_256,TK=nd.g0_256,MK=nd.g1_256,FI=wK.BlockHash,RK=[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 Aa(){if(!(this instanceof Aa))return new Aa;FI.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=RK,this.W=new Array(64)}s(Aa,"SHA256");rd.inherits(Aa,FI);NI.exports=Aa;Aa.blockSize=512;Aa.outSize=256;Aa.hmacStrength=192;Aa.padLength=64;Aa.prototype._update=s(function(e,r){for(var n=this.W,i=0;i<16;i++)n[i]=e[r+i];for(;i<n.length;i++)n[i]=AK(MK(n[i-2]),n[i-7],TK(n[i-15]),n[i-16]);var o=this.h[0],a=this.h[1],f=this.h[2],l=this.h[3],u=this.h[4],h=this.h[5],g=this.h[6],x=this.h[7];for(_K(this.k.length===n.length),i=0;i<n.length;i++){var _=EK(x,kK(u),CK(u,h,g),this.k[i],n[i]),E=ko(IK(o),SK(o,a,f));x=g,g=h,h=u,u=ko(l,_),l=f,f=a,a=o,o=ko(_,E)}this.h[0]=ko(this.h[0],o),this.h[1]=ko(this.h[1],a),this.h[2]=ko(this.h[2],f),this.h[3]=ko(this.h[3],l),this.h[4]=ko(this.h[4],u),this.h[5]=ko(this.h[5],h),this.h[6]=ko(this.h[6],g),this.h[7]=ko(this.h[7],x)},"_update");Aa.prototype._digest=s(function(e){return e==="hex"?rd.toHex32(this.h,"big"):rd.split32(this.h,"big")},"digest")});var jI=an((ffe,UI)=>{"use strict";var F3=Io(),LI=O3();function xc(){if(!(this instanceof xc))return new xc;LI.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}s(xc,"SHA224");F3.inherits(xc,LI);UI.exports=xc;xc.blockSize=512;xc.outSize=224;xc.hmacStrength=192;xc.padLength=64;xc.prototype._digest=s(function(e){return e==="hex"?F3.toHex32(this.h.slice(0,7),"big"):F3.split32(this.h.slice(0,7),"big")},"digest")});var U3=an((lfe,$I)=>{"use strict";var us=Io(),BK=ed(),DK=Qu(),Ea=us.rotr64_hi,Ca=us.rotr64_lo,qI=us.shr64_hi,HI=us.shr64_lo,Cf=us.sum64,N3=us.sum64_hi,L3=us.sum64_lo,PK=us.sum64_4_hi,OK=us.sum64_4_lo,FK=us.sum64_5_hi,NK=us.sum64_5_lo,zI=BK.BlockHash,LK=[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 To(){if(!(this instanceof To))return new To;zI.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=LK,this.W=new Array(160)}s(To,"SHA512");us.inherits(To,zI);$I.exports=To;To.blockSize=1024;To.outSize=512;To.hmacStrength=192;To.padLength=128;To.prototype._prepareBlock=s(function(e,r){for(var n=this.W,i=0;i<32;i++)n[i]=e[r+i];for(;i<n.length;i+=2){var o=JK(n[i-4],n[i-3]),a=YK(n[i-4],n[i-3]),f=n[i-14],l=n[i-13],u=VK(n[i-30],n[i-29]),h=WK(n[i-30],n[i-29]),g=n[i-32],x=n[i-31];n[i]=PK(o,a,f,l,u,h,g,x),n[i+1]=OK(o,a,f,l,u,h,g,x)}},"_prepareBlock");To.prototype._update=s(function(e,r){this._prepareBlock(e,r);var n=this.W,i=this.h[0],o=this.h[1],a=this.h[2],f=this.h[3],l=this.h[4],u=this.h[5],h=this.h[6],g=this.h[7],x=this.h[8],_=this.h[9],E=this.h[10],T=this.h[11],B=this.h[12],F=this.h[13],H=this.h[14],U=this.h[15];DK(this.k.length===n.length);for(var q=0;q<n.length;q+=2){var K=H,W=U,N=GK(x,_),G=KK(x,_),ce=UK(x,_,E,T,B,F),re=jK(x,_,E,T,B,F),ae=this.k[q],J=this.k[q+1],S=n[q],m=n[q+1],b=FK(K,W,N,G,ce,re,ae,J,S,m),p=NK(K,W,N,G,ce,re,ae,J,S,m);K=zK(i,o),W=$K(i,o),N=qK(i,o,a,f,l,u),G=HK(i,o,a,f,l,u);var v=N3(K,W,N,G),C=L3(K,W,N,G);H=B,U=F,B=E,F=T,E=x,T=_,x=N3(h,g,b,p),_=L3(g,g,b,p),h=l,g=u,l=a,u=f,a=i,f=o,i=N3(b,p,v,C),o=L3(b,p,v,C)}Cf(this.h,0,i,o),Cf(this.h,2,a,f),Cf(this.h,4,l,u),Cf(this.h,6,h,g),Cf(this.h,8,x,_),Cf(this.h,10,E,T),Cf(this.h,12,B,F),Cf(this.h,14,H,U)},"_update");To.prototype._digest=s(function(e){return e==="hex"?us.toHex32(this.h,"big"):us.split32(this.h,"big")},"digest");function UK(t,e,r,n,i){var o=t&r^~t&i;return o<0&&(o+=4294967296),o}s(UK,"ch64_hi");function jK(t,e,r,n,i,o){var a=e&n^~e&o;return a<0&&(a+=4294967296),a}s(jK,"ch64_lo");function qK(t,e,r,n,i){var o=t&r^t&i^r&i;return o<0&&(o+=4294967296),o}s(qK,"maj64_hi");function HK(t,e,r,n,i,o){var a=e&n^e&o^n&o;return a<0&&(a+=4294967296),a}s(HK,"maj64_lo");function zK(t,e){var r=Ea(t,e,28),n=Ea(e,t,2),i=Ea(e,t,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(zK,"s0_512_hi");function $K(t,e){var r=Ca(t,e,28),n=Ca(e,t,2),i=Ca(e,t,7),o=r^n^i;return o<0&&(o+=4294967296),o}s($K,"s0_512_lo");function GK(t,e){var r=Ea(t,e,14),n=Ea(t,e,18),i=Ea(e,t,9),o=r^n^i;return o<0&&(o+=4294967296),o}s(GK,"s1_512_hi");function KK(t,e){var r=Ca(t,e,14),n=Ca(t,e,18),i=Ca(e,t,9),o=r^n^i;return o<0&&(o+=4294967296),o}s(KK,"s1_512_lo");function VK(t,e){var r=Ea(t,e,1),n=Ea(t,e,8),i=qI(t,e,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(VK,"g0_512_hi");function WK(t,e){var r=Ca(t,e,1),n=Ca(t,e,8),i=HI(t,e,7),o=r^n^i;return o<0&&(o+=4294967296),o}s(WK,"g0_512_lo");function JK(t,e){var r=Ea(t,e,19),n=Ea(e,t,29),i=qI(t,e,6),o=r^n^i;return o<0&&(o+=4294967296),o}s(JK,"g1_512_hi");function YK(t,e){var r=Ca(t,e,19),n=Ca(e,t,29),i=HI(t,e,6),o=r^n^i;return o<0&&(o+=4294967296),o}s(YK,"g1_512_lo")});var VI=an((ufe,KI)=>{"use strict";var j3=Io(),GI=U3();function wc(){if(!(this instanceof wc))return new wc;GI.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}s(wc,"SHA384");j3.inherits(wc,GI);KI.exports=wc;wc.blockSize=1024;wc.outSize=384;wc.hmacStrength=192;wc.padLength=128;wc.prototype._digest=s(function(e){return e==="hex"?j3.toHex32(this.h.slice(0,12),"big"):j3.split32(this.h.slice(0,12),"big")},"digest")});var WI=an(id=>{"use strict";id.sha1=OI();id.sha224=jI();id.sha256=O3();id.sha384=VI();id.sha512=U3()});var ek=an(QI=>{"use strict";var Bl=Io(),ZK=ed(),jg=Bl.rotl32,JI=Bl.sum32,X0=Bl.sum32_3,YI=Bl.sum32_4,XI=ZK.BlockHash;function Sa(){if(!(this instanceof Sa))return new Sa;XI.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}s(Sa,"RIPEMD160");Bl.inherits(Sa,XI);QI.ripemd160=Sa;Sa.blockSize=512;Sa.outSize=160;Sa.hmacStrength=192;Sa.padLength=64;Sa.prototype._update=s(function(e,r){for(var n=this.h[0],i=this.h[1],o=this.h[2],a=this.h[3],f=this.h[4],l=n,u=i,h=o,g=a,x=f,_=0;_<80;_++){var E=JI(jg(YI(n,ZI(_,i,o,a),e[eV[_]+r],XK(_)),rV[_]),f);n=f,f=a,a=jg(o,10),o=i,i=E,E=JI(jg(YI(l,ZI(79-_,u,h,g),e[tV[_]+r],QK(_)),nV[_]),x),l=x,x=g,g=jg(h,10),h=u,u=E}E=X0(this.h[1],o,g),this.h[1]=X0(this.h[2],a,x),this.h[2]=X0(this.h[3],f,l),this.h[3]=X0(this.h[4],n,u),this.h[4]=X0(this.h[0],i,h),this.h[0]=E},"update");Sa.prototype._digest=s(function(e){return e==="hex"?Bl.toHex32(this.h,"little"):Bl.split32(this.h,"little")},"digest");function ZI(t,e,r,n){return t<=15?e^r^n:t<=31?e&r|~e&n:t<=47?(e|~r)^n:t<=63?e&n|r&~n:e^(r|~n)}s(ZI,"f");function XK(t){return t<=15?0:t<=31?1518500249:t<=47?1859775393:t<=63?2400959708:2840853838}s(XK,"K");function QK(t){return t<=15?1352829926:t<=31?1548603684:t<=47?1836072691:t<=63?2053994217:0}s(QK,"Kh");var eV=[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],tV=[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],rV=[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],nV=[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]});var rk=an((pfe,tk)=>{"use strict";var iV=Io(),sV=Qu();function sd(t,e,r){if(!(this instanceof sd))return new sd(t,e,r);this.Hash=t,this.blockSize=t.blockSize/8,this.outSize=t.outSize/8,this.inner=null,this.outer=null,this._init(iV.toArray(e,r))}s(sd,"Hmac");tk.exports=sd;sd.prototype._init=s(function(e){e.length>this.blockSize&&(e=new this.Hash().update(e).digest()),sV(e.length<=this.blockSize);for(var r=e.length;r<this.blockSize;r++)e.push(0);for(r=0;r<e.length;r++)e[r]^=54;for(this.inner=new this.Hash().update(e),r=0;r<e.length;r++)e[r]^=106;this.outer=new this.Hash().update(e)},"init");sd.prototype.update=s(function(e,r){return this.inner.update(e,r),this},"update");sd.prototype.digest=s(function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},"digest")});var q3=an(nk=>{var ni=nk;ni.utils=Io();ni.common=ed();ni.sha=WI();ni.ripemd=ek();ni.hmac=rk();ni.sha1=ni.sha.sha1;ni.sha256=ni.sha.sha256;ni.sha224=ni.sha.sha224;ni.sha384=ni.sha.sha384;ni.sha512=ni.sha.sha512;ni.ripemd160=ni.ripemd.ripemd160});var i4=an((n4,Rk)=>{"use strict";(function(t){function e(I){return parseInt(I)===I}s(e,"checkInt");function r(I){if(!e(I.length))return!1;for(var k=0;k<I.length;k++)if(!e(I[k])||I[k]<0||I[k]>255)return!1;return!0}s(r,"checkInts");function n(I,k){if(I.buffer&&ArrayBuffer.isView(I)&&I.name==="Uint8Array")return k&&(I.slice?I=I.slice():I=Array.prototype.slice.call(I)),I;if(Array.isArray(I)){if(!r(I))throw new Error("Array contains invalid value: "+I);return new Uint8Array(I)}if(e(I.length)&&r(I))return new Uint8Array(I);throw new Error("unsupported array-like object")}s(n,"coerceArray");function i(I){return new Uint8Array(I)}s(i,"createArray");function o(I,k,w,A,R){(A!=null||R!=null)&&(I.slice?I=I.slice(A,R):I=Array.prototype.slice.call(I,A,R)),k.set(I,w)}s(o,"copyArray");var a=function(){function I(w){var A=[],R=0;for(w=encodeURI(w);R<w.length;){var D=w.charCodeAt(R++);D===37?(A.push(parseInt(w.substr(R,2),16)),R+=2):A.push(D)}return n(A)}s(I,"toBytes");function k(w){for(var A=[],R=0;R<w.length;){var D=w[R];D<128?(A.push(String.fromCharCode(D)),R++):D>191&&D<224?(A.push(String.fromCharCode((D&31)<<6|w[R+1]&63)),R+=2):(A.push(String.fromCharCode((D&15)<<12|(w[R+1]&63)<<6|w[R+2]&63)),R+=3)}return A.join("")}return s(k,"fromBytes"),{toBytes:I,fromBytes:k}}(),f=function(){function I(A){for(var R=[],D=0;D<A.length;D+=2)R.push(parseInt(A.substr(D,2),16));return R}s(I,"toBytes");var k="0123456789abcdef";function w(A){for(var R=[],D=0;D<A.length;D++){var M=A[D];R.push(k[(M&240)>>4]+k[M&15])}return R.join("")}return s(w,"fromBytes"),{toBytes:I,fromBytes:w}}(),l={16:10,24:12,32:14},u=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],h=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],g=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],x=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],_=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],E=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],T=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],B=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],F=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],H=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],U=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],q=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],K=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],W=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],N=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function G(I){for(var k=[],w=0;w<I.length;w+=4)k.push(I[w]<<24|I[w+1]<<16|I[w+2]<<8|I[w+3]);return k}s(G,"convertToInt32");var ce=s(function(I){if(!(this instanceof ce))throw Error("AES must be instanitated with `new`");Object.defineProperty(this,"key",{value:n(I,!0)}),this._prepare()},"AES");ce.prototype._prepare=function(){var I=l[this.key.length];if(I==null)throw new Error("invalid key size (must be 16, 24 or 32 bytes)");this._Ke=[],this._Kd=[];for(var k=0;k<=I;k++)this._Ke.push([0,0,0,0]),this._Kd.push([0,0,0,0]);for(var w=(I+1)*4,A=this.key.length/4,R=G(this.key),D,k=0;k<A;k++)D=k>>2,this._Ke[D][k%4]=R[k],this._Kd[I-D][k%4]=R[k];for(var M=0,te=A,L;te<w;){if(L=R[A-1],R[0]^=h[L>>16&255]<<24^h[L>>8&255]<<16^h[L&255]<<8^h[L>>24&255]^u[M]<<24,M+=1,A!=8)for(var k=1;k<A;k++)R[k]^=R[k-1];else{for(var k=1;k<A/2;k++)R[k]^=R[k-1];L=R[A/2-1],R[A/2]^=h[L&255]^h[L>>8&255]<<8^h[L>>16&255]<<16^h[L>>24&255]<<24;for(var k=A/2+1;k<A;k++)R[k]^=R[k-1]}for(var k=0,Y,Z;k<A&&te<w;)Y=te>>2,Z=te%4,this._Ke[Y][Z]=R[k],this._Kd[I-Y][Z]=R[k++],te++}for(var Y=1;Y<I;Y++)for(var Z=0;Z<4;Z++)L=this._Kd[Y][Z],this._Kd[Y][Z]=q[L>>24&255]^K[L>>16&255]^W[L>>8&255]^N[L&255]},ce.prototype.encrypt=function(I){if(I.length!=16)throw new Error("invalid plaintext size (must be 16 bytes)");for(var k=this._Ke.length-1,w=[0,0,0,0],A=G(I),R=0;R<4;R++)A[R]^=this._Ke[0][R];for(var D=1;D<k;D++){for(var R=0;R<4;R++)w[R]=x[A[R]>>24&255]^_[A[(R+1)%4]>>16&255]^E[A[(R+2)%4]>>8&255]^T[A[(R+3)%4]&255]^this._Ke[D][R];A=w.slice()}for(var M=i(16),te,R=0;R<4;R++)te=this._Ke[k][R],M[4*R]=(h[A[R]>>24&255]^te>>24)&255,M[4*R+1]=(h[A[(R+1)%4]>>16&255]^te>>16)&255,M[4*R+2]=(h[A[(R+2)%4]>>8&255]^te>>8)&255,M[4*R+3]=(h[A[(R+3)%4]&255]^te)&255;return M},ce.prototype.decrypt=function(I){if(I.length!=16)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var k=this._Kd.length-1,w=[0,0,0,0],A=G(I),R=0;R<4;R++)A[R]^=this._Kd[0][R];for(var D=1;D<k;D++){for(var R=0;R<4;R++)w[R]=B[A[R]>>24&255]^F[A[(R+3)%4]>>16&255]^H[A[(R+2)%4]>>8&255]^U[A[(R+1)%4]&255]^this._Kd[D][R];A=w.slice()}for(var M=i(16),te,R=0;R<4;R++)te=this._Kd[k][R],M[4*R]=(g[A[R]>>24&255]^te>>24)&255,M[4*R+1]=(g[A[(R+3)%4]>>16&255]^te>>16)&255,M[4*R+2]=(g[A[(R+2)%4]>>8&255]^te>>8)&255,M[4*R+3]=(g[A[(R+1)%4]&255]^te)&255;return M};var re=s(function(I){if(!(this instanceof re))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new ce(I)},"ModeOfOperationECB");re.prototype.encrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16)o(I,w,0,A,A+16),w=this._aes.encrypt(w),o(w,k,A);return k},re.prototype.decrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16)o(I,w,0,A,A+16),w=this._aes.decrypt(w),o(w,k,A);return k};var ae=s(function(I,k){if(!(this instanceof ae))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Block Chaining",this.name="cbc",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 bytes)");this._lastCipherblock=n(k,!0),this._aes=new ce(I)},"ModeOfOperationCBC");ae.prototype.encrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16){o(I,w,0,A,A+16);for(var R=0;R<16;R++)w[R]^=this._lastCipherblock[R];this._lastCipherblock=this._aes.encrypt(w),o(this._lastCipherblock,k,A)}return k},ae.prototype.decrypt=function(I){if(I=n(I),I.length%16!==0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var k=i(I.length),w=i(16),A=0;A<I.length;A+=16){o(I,w,0,A,A+16),w=this._aes.decrypt(w);for(var R=0;R<16;R++)k[A+R]=w[R]^this._lastCipherblock[R];o(I,this._lastCipherblock,0,A,A+16)}return k};var J=s(function(I,k,w){if(!(this instanceof J))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Feedback",this.name="cfb",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 size)");w||(w=1),this.segmentSize=w,this._shiftRegister=n(k,!0),this._aes=new ce(I)},"ModeOfOperationCFB");J.prototype.encrypt=function(I){if(I.length%this.segmentSize!=0)throw new Error("invalid plaintext size (must be segmentSize bytes)");for(var k=n(I,!0),w,A=0;A<k.length;A+=this.segmentSize){w=this._aes.encrypt(this._shiftRegister);for(var R=0;R<this.segmentSize;R++)k[A+R]^=w[R];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(k,this._shiftRegister,16-this.segmentSize,A,A+this.segmentSize)}return k},J.prototype.decrypt=function(I){if(I.length%this.segmentSize!=0)throw new Error("invalid ciphertext size (must be segmentSize bytes)");for(var k=n(I,!0),w,A=0;A<k.length;A+=this.segmentSize){w=this._aes.encrypt(this._shiftRegister);for(var R=0;R<this.segmentSize;R++)k[A+R]^=w[R];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(I,this._shiftRegister,16-this.segmentSize,A,A+this.segmentSize)}return k};var S=s(function(I,k){if(!(this instanceof S))throw Error("AES must be instanitated with `new`");if(this.description="Output Feedback",this.name="ofb",!k)k=i(16);else if(k.length!=16)throw new Error("invalid initialation vector size (must be 16 bytes)");this._lastPrecipher=n(k,!0),this._lastPrecipherIndex=16,this._aes=new ce(I)},"ModeOfOperationOFB");S.prototype.encrypt=function(I){for(var k=n(I,!0),w=0;w<k.length;w++)this._lastPrecipherIndex===16&&(this._lastPrecipher=this._aes.encrypt(this._lastPrecipher),this._lastPrecipherIndex=0),k[w]^=this._lastPrecipher[this._lastPrecipherIndex++];return k},S.prototype.decrypt=S.prototype.encrypt;var m=s(function(I){if(!(this instanceof m))throw Error("Counter must be instanitated with `new`");I!==0&&!I&&(I=1),typeof I=="number"?(this._counter=i(16),this.setValue(I)):this.setBytes(I)},"Counter");m.prototype.setValue=function(I){if(typeof I!="number"||parseInt(I)!=I)throw new Error("invalid counter value (must be an integer)");for(var k=15;k>=0;--k)this._counter[k]=I%256,I=I>>8},m.prototype.setBytes=function(I){if(I=n(I,!0),I.length!=16)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=I},m.prototype.increment=function(){for(var I=15;I>=0;I--)if(this._counter[I]===255)this._counter[I]=0;else{this._counter[I]++;break}};var b=s(function(I,k){if(!(this instanceof b))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",k instanceof m||(k=new m(k)),this._counter=k,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new ce(I)},"ModeOfOperationCTR");b.prototype.encrypt=function(I){for(var k=n(I,!0),w=0;w<k.length;w++)this._remainingCounterIndex===16&&(this._remainingCounter=this._aes.encrypt(this._counter._counter),this._remainingCounterIndex=0,this._counter.increment()),k[w]^=this._remainingCounter[this._remainingCounterIndex++];return k},b.prototype.decrypt=b.prototype.encrypt;function p(I){I=n(I,!0);var k=16-I.length%16,w=i(I.length+k);o(I,w);for(var A=I.length;A<w.length;A++)w[A]=k;return w}s(p,"pkcs7pad");function v(I){if(I=n(I,!0),I.length<16)throw new Error("PKCS#7 invalid length");var k=I[I.length-1];if(k>16)throw new Error("PKCS#7 padding byte out of range");for(var w=I.length-k,A=0;A<k;A++)if(I[w+A]!==k)throw new Error("PKCS#7 invalid padding byte");var R=i(w);return o(I,R,0,0,w),R}s(v,"pkcs7strip");var C={AES:ce,Counter:m,ModeOfOperation:{ecb:re,cbc:ae,cfb:J,ofb:S,ctr:b},utils:{hex:f,utf8:a},padding:{pkcs7:{pad:p,strip:v}},_arrayTest:{coerceArray:n,createArray:i,copyArray:o}};typeof n4<"u"?Rk.exports=C:typeof define=="function"&&define.amd?define(C):(t.aesjs&&(C._aesjs=t.aesjs),t.aesjs=C)})(n4)});var Pk=an((c4,Dk)=>{"use strict";(function(t){function r(_){let E=new Uint32Array([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]),T=1779033703,B=3144134277,F=1013904242,H=2773480762,U=1359893119,q=2600822924,K=528734635,W=1541459225,N=new Uint32Array(64);function G(b){let p=0,v=b.length;for(;v>=64;){let C=T,I=B,k=F,w=H,A=U,R=q,D=K,M=W,te,L,Y,Z,P;for(L=0;L<16;L++)Y=p+L*4,N[L]=(b[Y]&255)<<24|(b[Y+1]&255)<<16|(b[Y+2]&255)<<8|b[Y+3]&255;for(L=16;L<64;L++)te=N[L-2],Z=(te>>>17|te<<32-17)^(te>>>19|te<<32-19)^te>>>10,te=N[L-15],P=(te>>>7|te<<32-7)^(te>>>18|te<<32-18)^te>>>3,N[L]=(Z+N[L-7]|0)+(P+N[L-16]|0)|0;for(L=0;L<64;L++)Z=(((A>>>6|A<<32-6)^(A>>>11|A<<32-11)^(A>>>25|A<<32-25))+(A&R^~A&D)|0)+(M+(E[L]+N[L]|0)|0)|0,P=((C>>>2|C<<32-2)^(C>>>13|C<<32-13)^(C>>>22|C<<32-22))+(C&I^C&k^I&k)|0,M=D,D=R,R=A,A=w+Z|0,w=k,k=I,I=C,C=Z+P|0;T=T+C|0,B=B+I|0,F=F+k|0,H=H+w|0,U=U+A|0,q=q+R|0,K=K+D|0,W=W+M|0,p+=64,v-=64}}s(G,"blocks"),G(_);let ce,re=_.length%64,ae=_.length/536870912|0,J=_.length<<3,S=re<56?56:120,m=_.slice(_.length-re,_.length);for(m.push(128),ce=re+1;ce<S;ce++)m.push(0);return m.push(ae>>>24&255),m.push(ae>>>16&255),m.push(ae>>>8&255),m.push(ae>>>0&255),m.push(J>>>24&255),m.push(J>>>16&255),m.push(J>>>8&255),m.push(J>>>0&255),G(m),[T>>>24&255,T>>>16&255,T>>>8&255,T>>>0&255,B>>>24&255,B>>>16&255,B>>>8&255,B>>>0&255,F>>>24&255,F>>>16&255,F>>>8&255,F>>>0&255,H>>>24&255,H>>>16&255,H>>>8&255,H>>>0&255,U>>>24&255,U>>>16&255,U>>>8&255,U>>>0&255,q>>>24&255,q>>>16&255,q>>>8&255,q>>>0&255,K>>>24&255,K>>>16&255,K>>>8&255,K>>>0&255,W>>>24&255,W>>>16&255,W>>>8&255,W>>>0&255]}s(r,"SHA256");function n(_,E,T){_=_.length<=64?_:r(_);let B=64+E.length+4,F=new Array(B),H=new Array(64),U,q=[];for(U=0;U<64;U++)F[U]=54;for(U=0;U<_.length;U++)F[U]^=_[U];for(U=0;U<E.length;U++)F[64+U]=E[U];for(U=B-4;U<B;U++)F[U]=0;for(U=0;U<64;U++)H[U]=92;for(U=0;U<_.length;U++)H[U]^=_[U];function K(){for(let W=B-1;W>=B-4;W--){if(F[W]++,F[W]<=255)return;F[W]=0}}for(s(K,"incrementCounter");T>=32;)K(),q=q.concat(r(H.concat(r(F)))),T-=32;return T>0&&(K(),q=q.concat(r(H.concat(r(F))).slice(0,T))),q}s(n,"PBKDF2_HMAC_SHA256_OneIter");function i(_,E,T,B,F){let H;for(l(_,(2*T-1)*16,F,0,16),H=0;H<2*T;H++)f(_,H*16,F,16),a(F,B),l(F,0,_,E+H*16,16);for(H=0;H<T;H++)l(_,E+H*2*16,_,H*16,16);for(H=0;H<T;H++)l(_,E+(H*2+1)*16,_,(H+T)*16,16)}s(i,"blockmix_salsa8");function o(_,E){return _<<E|_>>>32-E}s(o,"R");function a(_,E){l(_,0,E,0,16);for(let T=8;T>0;T-=2)E[4]^=o(E[0]+E[12],7),E[8]^=o(E[4]+E[0],9),E[12]^=o(E[8]+E[4],13),E[0]^=o(E[12]+E[8],18),E[9]^=o(E[5]+E[1],7),E[13]^=o(E[9]+E[5],9),E[1]^=o(E[13]+E[9],13),E[5]^=o(E[1]+E[13],18),E[14]^=o(E[10]+E[6],7),E[2]^=o(E[14]+E[10],9),E[6]^=o(E[2]+E[14],13),E[10]^=o(E[6]+E[2],18),E[3]^=o(E[15]+E[11],7),E[7]^=o(E[3]+E[15],9),E[11]^=o(E[7]+E[3],13),E[15]^=o(E[11]+E[7],18),E[1]^=o(E[0]+E[3],7),E[2]^=o(E[1]+E[0],9),E[3]^=o(E[2]+E[1],13),E[0]^=o(E[3]+E[2],18),E[6]^=o(E[5]+E[4],7),E[7]^=o(E[6]+E[5],9),E[4]^=o(E[7]+E[6],13),E[5]^=o(E[4]+E[7],18),E[11]^=o(E[10]+E[9],7),E[8]^=o(E[11]+E[10],9),E[9]^=o(E[8]+E[11],13),E[10]^=o(E[9]+E[8],18),E[12]^=o(E[15]+E[14],7),E[13]^=o(E[12]+E[15],9),E[14]^=o(E[13]+E[12],13),E[15]^=o(E[14]+E[13],18);for(let T=0;T<16;++T)_[T]+=E[T]}s(a,"salsa20_8");function f(_,E,T,B){for(let F=0;F<B;F++)T[F]^=_[E+F]}s(f,"blockxor");function l(_,E,T,B,F){for(;F--;)T[B++]=_[E++]}s(l,"arraycopy");function u(_){if(!_||typeof _.length!="number")return!1;for(let E=0;E<_.length;E++){let T=_[E];if(typeof T!="number"||T%1||T<0||T>=256)return!1}return!0}s(u,"checkBufferish");function h(_,E){if(typeof _!="number"||_%1)throw new Error("invalid "+E);return _}s(h,"ensureInteger");function g(_,E,T,B,F,H,U){if(T=h(T,"N"),B=h(B,"r"),F=h(F,"p"),H=h(H,"dkLen"),T===0||(T&T-1)!==0)throw new Error("N must be power of 2");if(T>2147483647/128/B)throw new Error("N too large");if(B>2147483647/128/F)throw new Error("r too large");if(!u(_))throw new Error("password must be an array or buffer");if(_=Array.prototype.slice.call(_),!u(E))throw new Error("salt must be an array or buffer");E=Array.prototype.slice.call(E);let q=n(_,E,F*128*B),K=new Uint32Array(F*32*B);for(let A=0;A<K.length;A++){let R=A*4;K[A]=(q[R+3]&255)<<24|(q[R+2]&255)<<16|(q[R+1]&255)<<8|(q[R+0]&255)<<0}let W=new Uint32Array(64*B),N=new Uint32Array(32*B*T),G=32*B,ce=new Uint32Array(16),re=new Uint32Array(16),ae=F*T*2,J=0,S=null,m=!1,b=0,p=0,v,C,I=U?parseInt(1e3/B):4294967295,k=typeof setImmediate<"u"?setImmediate:setTimeout,w=s(function(){if(m)return U(new Error("cancelled"),J/ae);let A;switch(b){case 0:C=p*32*B,l(K,C,W,0,G),b=1,v=0;case 1:A=T-v,A>I&&(A=I);for(let D=0;D<A;D++)l(W,0,N,(v+D)*G,G),i(W,G,B,ce,re);if(v+=A,J+=A,U){let D=parseInt(1e3*J/ae);if(D!==S){if(m=U(null,J/ae),m)break;S=D}}if(v<T)break;v=0,b=2;case 2:A=T-v,A>I&&(A=I);for(let D=0;D<A;D++){let M=(2*B-1)*16,te=W[M]&T-1;f(N,te*G,W,G),i(W,G,B,ce,re)}if(v+=A,J+=A,U){let D=parseInt(1e3*J/ae);if(D!==S){if(m=U(null,J/ae),m)break;S=D}}if(v<T)break;if(l(W,0,K,C,G),p++,p<F){b=0;break}q=[];for(let D=0;D<K.length;D++)q.push(K[D]>>0&255),q.push(K[D]>>8&255),q.push(K[D]>>16&255),q.push(K[D]>>24&255);let R=n(_,q,H);return U&&U(null,1,R),R}U&&k(w)},"incrementalSMix");if(!U)for(;;){let A=w();if(A!=null)return A}w()}s(g,"_scrypt");let x={scrypt:function(_,E,T,B,F,H,U){return new Promise(function(q,K){let W=0;U&&U(0),g(_,E,T,B,F,H,function(N,G,ce){if(N)K(N);else if(ce)U&&W!==1&&U(1),q(new Uint8Array(ce));else if(U&&G!==W)return W=G,U(G)})})},syncScrypt:function(_,E,T,B,F,H){return new Uint8Array(g(_,E,T,B,F,H))}};typeof c4<"u"?Dk.exports=x:typeof define=="function"&&define.amd?define(x):t&&(t.scrypt&&(t._scrypt=t.scrypt),t.scrypt=x)})(c4)});var iT=an((nde,nT)=>{"use strict";var ub="qpzry9x8gf2tvdw0s3jn54khce6mua7l",d4={};for(dp=0;dp<ub.length;dp++){if(lb=ub.charAt(dp),d4[lb]!==void 0)throw new TypeError(lb+" is ambiguous");d4[lb]=dp}var lb,dp;function md(t){var e=t>>25;return(t&33554431)<<5^-(e>>0&1)&996825010^-(e>>1&1)&642813549^-(e>>2&1)&513874426^-(e>>3&1)&1027748829^-(e>>4&1)&705979059}s(md,"polymodStep");function tT(t){for(var e=1,r=0;r<t.length;++r){var n=t.charCodeAt(r);if(n<33||n>126)return"Invalid prefix ("+t+")";e=md(e)^n>>5}for(e=md(e),r=0;r<t.length;++r){var i=t.charCodeAt(r);e=md(e)^i&31}return e}s(tT,"prefixChk");function HV(t,e,r){if(r=r||90,t.length+7+e.length>r)throw new TypeError("Exceeds length limit");t=t.toLowerCase();var n=tT(t);if(typeof n=="string")throw new Error(n);for(var i=t+"1",o=0;o<e.length;++o){var a=e[o];if(a>>5!==0)throw new Error("Non 5-bit word");n=md(n)^a,i+=ub.charAt(a)}for(o=0;o<6;++o)n=md(n);for(n^=1,o=0;o<6;++o){var f=n>>(5-o)*5&31;i+=ub.charAt(f)}return i}s(HV,"encode");function rT(t,e){if(e=e||90,t.length<8)return t+" too short";if(t.length>e)return"Exceeds length limit";var r=t.toLowerCase(),n=t.toUpperCase();if(t!==r&&t!==n)return"Mixed-case string "+t;t=r;var i=t.lastIndexOf("1");if(i===-1)return"No separator character for "+t;if(i===0)return"Missing prefix for "+t;var o=t.slice(0,i),a=t.slice(i+1);if(a.length<6)return"Data too short";var f=tT(o);if(typeof f=="string")return f;for(var l=[],u=0;u<a.length;++u){var h=a.charAt(u),g=d4[h];if(g===void 0)return"Unknown character "+h;f=md(f)^g,!(u+6>=a.length)&&l.push(g)}return f!==1?"Invalid checksum for "+t:{prefix:o,words:l}}s(rT,"__decode");function zV(){var t=rT.apply(null,arguments);if(typeof t=="object")return t}s(zV,"decodeUnsafe");function $V(t){var e=rT.apply(null,arguments);if(typeof e=="object")return e;throw new Error(e)}s($V,"decode");function db(t,e,r,n){for(var i=0,o=0,a=(1<<r)-1,f=[],l=0;l<t.length;++l)for(i=i<<e|t[l],o+=e;o>=r;)o-=r,f.push(i>>o&a);if(n)o>0&&f.push(i<<r-o&a);else{if(o>=e)return"Excess padding";if(i<<r-o&a)return"Non-zero padding"}return f}s(db,"convert");function GV(t){var e=db(t,8,5,!0);if(Array.isArray(e))return e}s(GV,"toWordsUnsafe");function KV(t){var e=db(t,8,5,!0);if(Array.isArray(e))return e;throw new Error(e)}s(KV,"toWords");function VV(t){var e=db(t,5,8,!1);if(Array.isArray(e))return e}s(VV,"fromWordsUnsafe");function WV(t){var e=db(t,5,8,!1);if(Array.isArray(e))return e;throw new Error(e)}s(WV,"fromWords");nT.exports={decodeUnsafe:zV,decode:$V,encode:HV,toWordsUnsafe:GV,toWords:KV,fromWordsUnsafe:VV,fromWords:WV}});var fie={};vl(fie,{getLearnCardNetworkPlugin:()=>Qy,getVerifyBoostPlugin:()=>e3,initNetworkLearnCard:()=>cie});module.exports=VH(fie);function WH(t){return t}s(WH,"identity");function JH(t){return t.length===0?WH:t.length===1?t[0]:s(function(r){return t.reduce((n,i)=>i(n),r)},"piped")}s(JH,"pipeFromArray");function la(t){let e={subscribe(r){let n=null,i=!1,o=!1,a=!1;function f(){if(n===null){a=!0;return}o||(o=!0,typeof n=="function"?n():n&&n.unsubscribe())}return s(f,"unsubscribe"),n=t({next(l){i||r.next?.(l)},error(l){i||(i=!0,r.error?.(l),f())},complete(){i||(i=!0,r.complete?.(),f())}}),a&&f(),{unsubscribe:f}},pipe(...r){return JH(r)(e)}};return e}s(la,"observable");function gC(t){return e=>{let r=0,n=null,i=[];function o(){n||(n=e.subscribe({next(f){for(let l of i)l.next?.(f)},error(f){for(let l of i)l.error?.(f)},complete(){for(let f of i)f.complete?.()}}))}s(o,"startIfNeeded");function a(){if(r===0&&n){let f=n;n=null,f.unsubscribe()}}return s(a,"resetIfNeeded"),{subscribe(f){return r++,i.push(f),o(),{unsubscribe(){r--,a();let l=i.findIndex(u=>u===f);l>-1&&i.splice(l,1)}}}}}}s(gC,"share");var Nu=class extends Error{constructor(e){super(e),this.name="ObservableAbortError",Object.setPrototypeOf(this,Nu.prototype)}};s(Nu,"ObservableAbortError");function bC(t){let e;return{promise:new Promise((n,i)=>{let o=!1;function a(){o||(o=!0,i(new Nu("This operation was aborted.")),f.unsubscribe())}s(a,"onDone");let f=t.subscribe({next(l){o=!0,n(l),a()},error(l){o=!0,i(l),a()},complete(){o=!0,a()}});e=a}),abort:e}}s(bC,"observableToPromise");var Gn=class extends Error{static from(e,r={}){return e instanceof Error?e.name==="TRPCClientError"?e:new Gn(e.message,{...r,cause:e,result:null}):new Gn(e.error.message??"",{...r,cause:void 0,result:e})}constructor(e,r){let n=r?.cause;super(e,{cause:n}),this.meta=r?.meta,this.cause=n,this.shape=r?.result?.error,this.data=r?.result?.error.data,this.name="TRPCClientError",Object.setPrototypeOf(this,Gn.prototype)}};s(Gn,"TRPCClientError");function YH(t,e){if("error"in t){let n=e.transformer.deserialize(t.error);return{ok:!1,error:{...t,error:n}}}let r={...t.result,...(!t.result.type||t.result.type==="data")&&{type:"data",data:e.transformer.deserialize(t.result.data)}};return{ok:!0,result:r}}s(YH,"transformResultInner");function vC(t){return!!t&&!Array.isArray(t)&&typeof t=="object"}s(vC,"isObject");function og(t,e){let r;try{r=YH(t,e)}catch{throw new Gn("Unable to transform response from server")}if(!r.ok&&(!vC(r.error.error)||typeof r.error.error.code!="number"))throw new Gn("Badly formatted response from server");if(r.ok&&!vC(r.result))throw new Gn("Badly formatted response from server");return r}s(og,"transformResult");function yC(t){return la(e=>{function r(i=0,o=t.op){let a=t.links[i];if(!a)throw new Error("No more links to execute - did you forget to add an ending link?");return a({op:o,next(l){return r(i+1,l)}})}return s(r,"execute"),r().subscribe(e)})}s(yC,"createChain");var xC=s(()=>{},"noop");function wC(t,e){return new Proxy(xC,{get(n,i){if(!(typeof i!="string"||i==="then"))return wC(t,[...e,i])},apply(n,i,o){return t({args:o,path:e})}})}s(wC,"createInnerProxy");var jy=s(t=>wC(t,[]),"createRecursiveProxy"),qy=s(t=>new Proxy(xC,{get(e,r){if(!(typeof r!="string"||r==="then"))return t(r)}}),"createFlatProxy");function _C(){return typeof window<"u"?window:globalThis}s(_C,"getWindow");function ZH(t){return t??_C().AbortController??null}s(ZH,"getAbortController");function AC(t){if(t)return t;let e=_C(),r=e.fetch;if(r)return typeof r.bind=="function"?r.bind(e):r;throw new Error("No fetch implementation found")}s(AC,"getFetch");function Hy(t){let e=t.headers||(()=>({}));return{url:t.url,fetch:AC(t.fetch),AbortController:ZH(t.AbortController),headers:typeof e=="function"?e:()=>e}}s(Hy,"resolveHTTPLinkOptions");function XH(t){let e={};for(let r=0;r<t.length;r++){let n=t[r];e[r]=n}return e}s(XH,"arrayToDict");var QH={query:"GET",mutation:"POST"};function EC(t){return"input"in t?t.runtime.transformer.serialize(t.input):XH(t.inputs.map(e=>t.runtime.transformer.serialize(e)))}s(EC,"getInput");function zy(t){let e=t.url+"/"+t.path,r=[];if("inputs"in t&&r.push("batch=1"),t.type==="query"){let n=EC(t);n!==void 0&&r.push(`input=${encodeURIComponent(JSON.stringify(n))}`)}return r.length&&(e+="?"+r.join("&")),e}s(zy,"getUrl");function ez(t){if(t.type==="query")return;let e=EC(t);return e!==void 0?JSON.stringify(e):void 0}s(ez,"getBody");function $y(t){let{type:e}=t,r=t.AbortController?new t.AbortController:null;return{promise:new Promise((o,a)=>{let f=zy(t),l=ez(t),u={};Promise.resolve(t.headers()).then(h=>{if(e==="subscription")throw new Error("Subscriptions should use wsLink");return t.fetch(f,{method:QH[e],signal:r?.signal,body:l,headers:{"content-type":"application/json",...h}})}).then(h=>(u.response=h,h.json())).then(h=>{o({json:h,meta:u})}).catch(a)}),cancel:s(()=>{r?.abort()},"cancel")}}s($y,"httpRequest");var Gy=s(()=>{throw new Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new")},"throwFatalError");function Ky(t){let e=null,r=null,n=s(()=>{clearTimeout(r),r=null,e=null},"destroyTimerAndPendingItems");function i(f){let l=[[]],u=0;for(;;){let h=f[u];if(!h)break;let g=l[l.length-1];if(h.aborted){h.reject(new Error("Aborted")),u++;continue}if(t.validate(g.concat(h).map(_=>_.key))){g.push(h),u++;continue}if(g.length===0){h.reject(new Error("Input is too big for a single dispatch")),u++;continue}l.push([])}return l}s(i,"groupItems");function o(){let f=i(e);n();for(let l of f){if(!l.length)continue;let u={items:l,cancel:Gy};for(let x of l)x.batch=u;let{promise:h,cancel:g}=t.fetch(u.items.map(x=>x.key));u.cancel=g,h.then(x=>{for(let _=0;_<x.length;_++){let E=x[_],T=u.items[_];T.resolve(E),T.batch=null}}).catch(x=>{for(let _ of u.items)_.reject(x),_.batch=null})}}s(o,"dispatch");function a(f){let l={aborted:!1,key:f,batch:null,resolve:Gy,reject:Gy},u=new Promise((g,x)=>{l.reject=x,l.resolve=g,e||(e=[]),e.push(l)});return r||(r=setTimeout(o)),{promise:u,cancel:s(()=>{l.aborted=!0,l.batch?.items.every(g=>g.aborted)&&(l.batch.cancel(),l.batch=null)},"cancel")}}return s(a,"load"),{load:a}}s(Ky,"dataLoader");function ag(t){let e=Hy(t);return r=>{let n=t.maxURLLength||1/0,i=s(u=>({validate:s(x=>{if(n===1/0)return!0;let _=x.map(B=>B.path).join(","),E=x.map(B=>B.input);return zy({...e,runtime:r,type:u,path:_,inputs:E}).length<=n},"validate"),fetch:s(x=>{let _=x.map(F=>F.path).join(","),E=x.map(F=>F.input),{promise:T,cancel:B}=$y({...e,runtime:r,type:u,path:_,inputs:E});return{promise:T.then(F=>(Array.isArray(F.json)?F.json:x.map(()=>F.json)).map(q=>({meta:F.meta,json:q}))),cancel:B}},"fetch")}),"batchLoader"),o=Ky(i("query")),a=Ky(i("mutation")),f=Ky(i("subscription")),l={query:o,subscription:f,mutation:a};return({op:u})=>la(h=>{let g=l[u.type],{promise:x,cancel:_}=g.load(u);return x.then(E=>{let T=og(E.json,r);if(!T.ok){h.error(Gn.from(T.error,{meta:E.meta}));return}h.next({context:E.meta,result:T.result}),h.complete()}).catch(E=>h.error(Gn.from(E))),()=>{_()}})}}s(ag,"httpBatchLink");var cg=class{$request({type:e,input:r,path:n,context:i={}}){return yC({links:this.links,op:{id:++this.requestId,type:e,path:n,input:r,context:i}}).pipe(gC())}requestAsPromise(e){let r=this.$request(e),{promise:n,abort:i}=bC(r);return new Promise((a,f)=>{e.signal?.addEventListener("abort",i),n.then(l=>{a(l.result.data)}).catch(l=>{f(Gn.from(l))})})}query(e,r,n){return this.requestAsPromise({type:"query",path:e,input:r,context:n?.context,signal:n?.signal})}mutation(e,r,n){return this.requestAsPromise({type:"mutation",path:e,input:r,context:n?.context,signal:n?.signal})}subscription(e,r,n){return this.$request({type:"subscription",path:e,input:r,context:n?.context}).subscribe({next(o){o.result.type==="started"?n.onStarted?.():o.result.type==="stopped"?n.onStopped?.():n.onData?.(o.result.data)},error(o){n.onError?.(o)},complete(){n.onComplete?.()}})}constructor(e){this.requestId=0;function r(){let n=e.transformer;return n?"input"in n?{serialize:n.input.serialize,deserialize:n.output.deserialize}:n:{serialize:i=>i,deserialize:i=>i}}s(r,"getTransformer"),this.runtime={transformer:r()},this.links=e.links.map(n=>n(this.runtime))}};s(cg,"TRPCUntypedClient");var tz={query:"query",mutate:"mutation",subscribe:"subscription"};function rz(t){return qy(e=>t.hasOwnProperty(e)?t[e]:jy(({path:r,args:n})=>{let i=[e,...r],o=i.pop(),a=tz[o],f=i.join(".");return t[a](f,...n)}))}s(rz,"createTRPCClientProxy");function Vy(t){let e=new cg(t);return rz(e)}s(Vy,"createTRPCProxyClient");var nz=Object.defineProperty,fg=s((t,e)=>nz(t,"name",{value:e,configurable:!0}),"__name"),iz=fg(t=>()=>({next:e,op:r})=>la(n=>{let i=null,o=0,a=!1,f=fg(()=>{o+=1,i?.unsubscribe(),i=e(r).subscribe({error:async l=>{if(o>5||l.data?.httpStatus!==401)return n.error(l);await t(),f()},next:l=>n.next(l),complete:()=>{a&&n.complete()}})},"attempt");return f(),()=>{a=!0,i?.unsubscribe()}}),"callbackLink"),CC=fg(async(t,e)=>{let r=[],n=Vy({links:[ag({url:t,headers:{Authorization:`Bearer ${await e()}`}})]}),i=fg(async(a=95+Math.round((Math.random()-.5)*5))=>n.utilities.getChallenges.query({amount:a}),"getChallenges");return r=await i(),Vy({links:[iz(async()=>{r=await i()}),ag({url:t,headers:async()=>(r.length===0&&r.push(...await i()),{Authorization:`Bearer ${await e(r.pop())}`})})]})},"getClient");var Mr;(function(t){t.assertEqual=i=>i;function e(i){}s(e,"assertIs"),t.assertIs=e;function r(i){throw new Error}s(r,"assertNever"),t.assertNever=r,t.arrayToEnum=i=>{let o={};for(let a of i)o[a]=a;return o},t.getValidEnumValues=i=>{let o=t.objectKeys(i).filter(f=>typeof i[i[f]]!="number"),a={};for(let f of o)a[f]=i[f];return t.objectValues(a)},t.objectValues=i=>t.objectKeys(i).map(function(o){return i[o]}),t.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{let o=[];for(let a in i)Object.prototype.hasOwnProperty.call(i,a)&&o.push(a);return o},t.find=(i,o)=>{for(let a of i)if(o(a))return a},t.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function n(i,o=" | "){return i.map(a=>typeof a=="string"?`'${a}'`:a).join(o)}s(n,"joinValues"),t.joinValues=n,t.jsonStringifyReplacer=(i,o)=>typeof o=="bigint"?o.toString():o})(Mr||(Mr={}));var yt=Mr.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),sf=s(t=>{switch(typeof t){case"undefined":return yt.undefined;case"string":return yt.string;case"number":return isNaN(t)?yt.nan:yt.number;case"boolean":return yt.boolean;case"function":return yt.function;case"bigint":return yt.bigint;case"symbol":return yt.symbol;case"object":return Array.isArray(t)?yt.array:t===null?yt.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?yt.promise:typeof Map<"u"&&t instanceof Map?yt.map:typeof Set<"u"&&t instanceof Set?yt.set:typeof Date<"u"&&t instanceof Date?yt.date:yt.object;default:return yt.unknown}},"getParsedType"),nt=Mr.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"]),sz=s(t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),"quotelessJson"),Ys=class extends Error{constructor(e){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};let r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){let r=e||function(o){return o.message},n={_errors:[]},i=s(o=>{for(let a of o.issues)if(a.code==="invalid_union")a.unionErrors.map(i);else if(a.code==="invalid_return_type")i(a.returnTypeError);else if(a.code==="invalid_arguments")i(a.argumentsError);else if(a.path.length===0)n._errors.push(r(a));else{let f=n,l=0;for(;l<a.path.length;){let u=a.path[l];l===a.path.length-1?(f[u]=f[u]||{_errors:[]},f[u]._errors.push(r(a))):f[u]=f[u]||{_errors:[]},f=f[u],l++}}},"processError");return i(this),n}toString(){return this.message}get message(){return JSON.stringify(this.issues,Mr.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=r=>r.message){let r={},n=[];for(let i of this.issues)i.path.length>0?(r[i.path[0]]=r[i.path[0]]||[],r[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:r}}get formErrors(){return this.flatten()}};s(Ys,"ZodError");Ys.create=t=>new Ys(t);var w0=s((t,e)=>{let r;switch(t.code){case nt.invalid_type:t.received===yt.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case nt.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,Mr.jsonStringifyReplacer)}`;break;case nt.unrecognized_keys:r=`Unrecognized key(s) in object: ${Mr.joinValues(t.keys,", ")}`;break;case nt.invalid_union:r="Invalid input";break;case nt.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${Mr.joinValues(t.options)}`;break;case nt.invalid_enum_value:r=`Invalid enum value. Expected ${Mr.joinValues(t.options)}, received '${t.received}'`;break;case nt.invalid_arguments:r="Invalid function arguments";break;case nt.invalid_return_type:r="Invalid function return type";break;case nt.invalid_date:r="Invalid date";break;case nt.invalid_string:typeof t.validation=="object"?"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:Mr.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case nt.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(t.minimum)}`:r="Invalid input";break;case nt.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(t.maximum)}`:r="Invalid input";break;case nt.custom:r="Invalid input";break;case nt.invalid_intersection_types:r="Intersection results could not be merged";break;case nt.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case nt.not_finite:r="Number must be finite";break;default:r=e.defaultError,Mr.assertNever(t)}return{message:r}},"errorMap"),kC=w0;function oz(t){kC=t}s(oz,"setErrorMap");function ug(){return kC}s(ug,"getErrorMap");var dg=s(t=>{let{data:e,path:r,errorMaps:n,issueData:i}=t,o=[...r,...i.path||[]],a={...i,path:o},f="",l=n.filter(u=>!!u).slice().reverse();for(let u of l)f=u(a,{data:e,defaultError:f}).message;return{...i,path:o,message:i.message||f}},"makeIssue"),az=[];function kt(t,e){let r=dg({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,ug(),w0].filter(n=>!!n)});t.common.issues.push(r)}s(kt,"addIssueToContext");var Kn=class{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,r){let n=[];for(let i of r){if(i.status==="aborted")return zt;i.status==="dirty"&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,r){let n=[];for(let i of r)n.push({key:await i.key,value:await i.value});return Kn.mergeObjectSync(e,n)}static mergeObjectSync(e,r){let n={};for(let i of r){let{key:o,value:a}=i;if(o.status==="aborted"||a.status==="aborted")return zt;o.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),(typeof a.value<"u"||i.alwaysSet)&&(n[o.value]=a.value)}return{status:e.value,value:n}}};s(Kn,"ParseStatus");var zt=Object.freeze({status:"aborted"}),TC=s(t=>({status:"dirty",value:t}),"DIRTY"),Ai=s(t=>({status:"valid",value:t}),"OK"),Wy=s(t=>t.status==="aborted","isAborted"),Jy=s(t=>t.status==="dirty","isDirty"),hg=s(t=>t.status==="valid","isValid"),pg=s(t=>typeof Promise<"u"&&t instanceof Promise,"isAsync"),pr;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(pr||(pr={}));var Ss=class{constructor(e,r,n,i){this.parent=e,this.data=r,this._path=n,this._key=i}get path(){return this._path.concat(this._key)}};s(Ss,"ParseInputLazyPath");var SC=s((t,e)=>{if(hg(e))return{success:!0,data:e.value};{if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");let r=new Ys(t.common.issues);return{success:!1,error:r}}},"handleResult");function nr(t){if(!t)return{};let{errorMap:e,invalid_type_error:r,required_error:n,description:i}=t;if(e&&(r||n))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:i}:{errorMap:s((a,f)=>a.code!=="invalid_type"?{message:f.defaultError}:typeof f.data>"u"?{message:n??f.defaultError}:{message:r??f.defaultError},"customMap"),description:i}}s(nr,"processCreateParams");var Xt=class{constructor(e){this.spa=this.safeParseAsync,this._def=e,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.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return sf(e.data)}_getOrReturnCtx(e,r){return r||{common:e.parent.common,data:e.data,parsedType:sf(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new Kn,ctx:{common:e.parent.common,data:e.data,parsedType:sf(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let r=this._parse(e);if(pg(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(e){let r=this._parse(e);return Promise.resolve(r)}parse(e,r){let n=this.safeParse(e,r);if(n.success)return n.data;throw n.error}safeParse(e,r){var n;let i={common:{issues:[],async:(n=r?.async)!==null&&n!==void 0?n:!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:sf(e)},o=this._parseSync({data:e,path:i.path,parent:i});return SC(i,o)}async parseAsync(e,r){let n=await this.safeParseAsync(e,r);if(n.success)return n.data;throw n.error}async safeParseAsync(e,r){let n={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:sf(e)},i=this._parse({data:e,path:n.path,parent:n}),o=await(pg(i)?i:Promise.resolve(i));return SC(n,o)}refine(e,r){let n=s(i=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(i):r,"getIssueProperties");return this._refinement((i,o)=>{let a=e(i),f=s(()=>o.addIssue({code:nt.custom,...n(i)}),"setError");return typeof Promise<"u"&&a instanceof Promise?a.then(l=>l?!0:(f(),!1)):a?!0:(f(),!1)})}refinement(e,r){return this._refinement((n,i)=>e(n)?!0:(i.addIssue(typeof r=="function"?r(n,i):r),!1))}_refinement(e){return new os({schema:this,typeName:jt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return Qs.create(this,this._def)}nullable(){return pa.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return ss.create(this,this._def)}promise(){return lc.create(this,this._def)}or(e){return lf.create([this,e],this._def)}and(e){return uf.create(this,e,this._def)}transform(e){return new os({...nr(this._def),schema:this,typeName:jt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let r=typeof e=="function"?e:()=>e;return new gf({...nr(this._def),innerType:this,defaultValue:r,typeName:jt.ZodDefault})}brand(){return new x0({typeName:jt.ZodBranded,type:this,...nr(this._def)})}catch(e){let r=typeof e=="function"?e:()=>e;return new Al({...nr(this._def),innerType:this,catchValue:r,typeName:jt.ZodCatch})}describe(e){let r=this.constructor;return new r({...this._def,description:e})}pipe(e){return bf.create(this,e)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}};s(Xt,"ZodType");var cz=/^c[^\s-]{8,}$/i,fz=/^[a-z][a-z0-9]*$/,lz=/^([a-f0-9]{8}-[a-f0-9]{4}-[1-5][a-f0-9]{3}-[a-f0-9]{4}-[a-f0-9]{12}|00000000-0000-0000-0000-000000000000)$/i,uz=/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|([^-]([a-zA-Z0-9-]*\.)+[a-zA-Z]{2,}))$/,dz=s(t=>t.precision?t.offset?new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${t.precision}}(([+-]\\d{2}(:?\\d{2})?)|Z)$`):new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${t.precision}}Z$`):t.precision===0?t.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$"):t.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?Z$"),"datetimeRegex"),Zs=class extends Xt{constructor(){super(...arguments),this._regex=(e,r,n)=>this.refinement(i=>e.test(i),{validation:r,code:nt.invalid_string,...pr.errToObj(n)}),this.nonempty=e=>this.min(1,pr.errToObj(e)),this.trim=()=>new Zs({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==yt.string){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.string,received:o.parsedType}),zt}let n=new Kn,i;for(let o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="max")e.data.length>o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="length"){let a=e.data.length>o.value,f=e.data.length<o.value;(a||f)&&(i=this._getOrReturnCtx(e,i),a?kt(i,{code:nt.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):f&&kt(i,{code:nt.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),n.dirty())}else if(o.kind==="email")uz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"email",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="uuid")lz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"uuid",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid")cz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"cuid",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid2")fz.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"cuid2",code:nt.invalid_string,message:o.message}),n.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{i=this._getOrReturnCtx(e,i),kt(i,{validation:"url",code:nt.invalid_string,message:o.message}),n.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{validation:"regex",code:nt.invalid_string,message:o.message}),n.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="startsWith"?e.data.startsWith(o.value)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:{startsWith:o.value},message:o.message}),n.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:{endsWith:o.value},message:o.message}),n.dirty()):o.kind==="datetime"?dz(o).test(e.data)||(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.invalid_string,validation:"datetime",message:o.message}),n.dirty()):Mr.assertNever(o);return{status:n.value,value:e.data}}_addCheck(e){return new Zs({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...pr.errToObj(e)})}url(e){return this._addCheck({kind:"url",...pr.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...pr.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...pr.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...pr.errToObj(e)})}datetime(e){var r;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:(r=e?.offset)!==null&&r!==void 0?r:!1,...pr.errToObj(e?.message)})}regex(e,r){return this._addCheck({kind:"regex",regex:e,...pr.errToObj(r)})}startsWith(e,r){return this._addCheck({kind:"startsWith",value:e,...pr.errToObj(r)})}endsWith(e,r){return this._addCheck({kind:"endsWith",value:e,...pr.errToObj(r)})}min(e,r){return this._addCheck({kind:"min",value:e,...pr.errToObj(r)})}max(e,r){return this._addCheck({kind:"max",value:e,...pr.errToObj(r)})}length(e,r){return this._addCheck({kind:"length",value:e,...pr.errToObj(r)})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get minLength(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxLength(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}};s(Zs,"ZodString");Zs.create=t=>{var e;return new Zs({checks:[],typeName:jt.ZodString,coerce:(e=t?.coerce)!==null&&e!==void 0?e:!1,...nr(t)})};function hz(t,e){let r=(t.toString().split(".")[1]||"").length,n=(e.toString().split(".")[1]||"").length,i=r>n?r:n,o=parseInt(t.toFixed(i).replace(".","")),a=parseInt(e.toFixed(i).replace(".",""));return o%a/Math.pow(10,i)}s(hz,"floatSafeRemainder");var Ao=class extends Xt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==yt.number){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.number,received:o.parsedType}),zt}let n,i=new Kn;for(let o of this._def.checks)o.kind==="int"?Mr.isInteger(e.data)||(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.invalid_type,expected:"integer",received:"float",message:o.message}),i.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="multipleOf"?hz(e.data,o.value)!==0&&(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(n=this._getOrReturnCtx(e,n),kt(n,{code:nt.not_finite,message:o.message}),i.dirty()):Mr.assertNever(o);return{status:i.value,value:e.data}}gte(e,r){return this.setLimit("min",e,!0,pr.toString(r))}gt(e,r){return this.setLimit("min",e,!1,pr.toString(r))}lte(e,r){return this.setLimit("max",e,!0,pr.toString(r))}lt(e,r){return this.setLimit("max",e,!1,pr.toString(r))}setLimit(e,r,n,i){return new Ao({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:n,message:pr.toString(i)}]})}_addCheck(e){return new Ao({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:pr.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:pr.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:pr.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:pr.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:pr.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:pr.toString(r)})}finite(e){return this._addCheck({kind:"finite",message:pr.toString(e)})}get minValue(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Mr.isInteger(e.value))}get isFinite(){let e=null,r=null;for(let 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"&&(e===null||n.value<e)&&(e=n.value)}return Number.isFinite(r)&&Number.isFinite(e)}};s(Ao,"ZodNumber");Ao.create=t=>new Ao({checks:[],typeName:jt.ZodNumber,coerce:t?.coerce||!1,...nr(t)});var of=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==yt.bigint){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.bigint,received:n.parsedType}),zt}return Ai(e.data)}};s(of,"ZodBigInt");of.create=t=>{var e;return new of({typeName:jt.ZodBigInt,coerce:(e=t?.coerce)!==null&&e!==void 0?e:!1,...nr(t)})};var af=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=Boolean(e.data)),this._getType(e)!==yt.boolean){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.boolean,received:n.parsedType}),zt}return Ai(e.data)}};s(af,"ZodBoolean");af.create=t=>new af({typeName:jt.ZodBoolean,coerce:t?.coerce||!1,...nr(t)});var ua=class extends Xt{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==yt.date){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_type,expected:yt.date,received:o.parsedType}),zt}if(isNaN(e.data.getTime())){let o=this._getOrReturnCtx(e);return kt(o,{code:nt.invalid_date}),zt}let n=new Kn,i;for(let o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),n.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(i=this._getOrReturnCtx(e,i),kt(i,{code:nt.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),n.dirty()):Mr.assertNever(o);return{status:n.value,value:new Date(e.data.getTime())}}_addCheck(e){return new ua({...this._def,checks:[...this._def.checks,e]})}min(e,r){return this._addCheck({kind:"min",value:e.getTime(),message:pr.toString(r)})}max(e,r){return this._addCheck({kind:"max",value:e.getTime(),message:pr.toString(r)})}get minDate(){let e=null;for(let r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(let r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e!=null?new Date(e):null}};s(ua,"ZodDate");ua.create=t=>new ua({checks:[],coerce:t?.coerce||!1,typeName:jt.ZodDate,...nr(t)});var yl=class extends Xt{_parse(e){if(this._getType(e)!==yt.symbol){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.symbol,received:n.parsedType}),zt}return Ai(e.data)}};s(yl,"ZodSymbol");yl.create=t=>new yl({typeName:jt.ZodSymbol,...nr(t)});var cf=class extends Xt{_parse(e){if(this._getType(e)!==yt.undefined){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.undefined,received:n.parsedType}),zt}return Ai(e.data)}};s(cf,"ZodUndefined");cf.create=t=>new cf({typeName:jt.ZodUndefined,...nr(t)});var ff=class extends Xt{_parse(e){if(this._getType(e)!==yt.null){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.null,received:n.parsedType}),zt}return Ai(e.data)}};s(ff,"ZodNull");ff.create=t=>new ff({typeName:jt.ZodNull,...nr(t)});var cc=class extends Xt{constructor(){super(...arguments),this._any=!0}_parse(e){return Ai(e.data)}};s(cc,"ZodAny");cc.create=t=>new cc({typeName:jt.ZodAny,...nr(t)});var da=class extends Xt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Ai(e.data)}};s(da,"ZodUnknown");da.create=t=>new da({typeName:jt.ZodUnknown,...nr(t)});var Xs=class extends Xt{_parse(e){let r=this._getOrReturnCtx(e);return kt(r,{code:nt.invalid_type,expected:yt.never,received:r.parsedType}),zt}};s(Xs,"ZodNever");Xs.create=t=>new Xs({typeName:jt.ZodNever,...nr(t)});var xl=class extends Xt{_parse(e){if(this._getType(e)!==yt.undefined){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.void,received:n.parsedType}),zt}return Ai(e.data)}};s(xl,"ZodVoid");xl.create=t=>new xl({typeName:jt.ZodVoid,...nr(t)});var ss=class extends Xt{_parse(e){let{ctx:r,status:n}=this._processInputParams(e),i=this._def;if(r.parsedType!==yt.array)return kt(r,{code:nt.invalid_type,expected:yt.array,received:r.parsedType}),zt;if(i.exactLength!==null){let a=r.data.length>i.exactLength.value,f=r.data.length<i.exactLength.value;(a||f)&&(kt(r,{code:a?nt.too_big:nt.too_small,minimum:f?i.exactLength.value:void 0,maximum:a?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&&(kt(r,{code:nt.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&&(kt(r,{code:nt.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((a,f)=>i.type._parseAsync(new Ss(r,a,r.path,f)))).then(a=>Kn.mergeArray(n,a));let o=[...r.data].map((a,f)=>i.type._parseSync(new Ss(r,a,r.path,f)));return Kn.mergeArray(n,o)}get element(){return this._def.type}min(e,r){return new ss({...this._def,minLength:{value:e,message:pr.toString(r)}})}max(e,r){return new ss({...this._def,maxLength:{value:e,message:pr.toString(r)}})}length(e,r){return new ss({...this._def,exactLength:{value:e,message:pr.toString(r)}})}nonempty(e){return this.min(1,e)}};s(ss,"ZodArray");ss.create=(t,e)=>new ss({type:t,minLength:null,maxLength:null,exactLength:null,typeName:jt.ZodArray,...nr(e)});var mg;(function(t){t.mergeShapes=(e,r)=>({...e,...r})})(mg||(mg={}));function Lu(t){if(t instanceof Jr){let e={};for(let r in t.shape){let n=t.shape[r];e[r]=Qs.create(Lu(n))}return new Jr({...t._def,shape:()=>e})}else return t instanceof ss?ss.create(Lu(t.element)):t instanceof Qs?Qs.create(Lu(t.unwrap())):t instanceof pa?pa.create(Lu(t.unwrap())):t instanceof Is?Is.create(t.items.map(e=>Lu(e))):t}s(Lu,"deepPartialify");var Jr=class extends Xt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),r=Mr.objectKeys(e);return this._cached={shape:e,keys:r}}_parse(e){if(this._getType(e)!==yt.object){let u=this._getOrReturnCtx(e);return kt(u,{code:nt.invalid_type,expected:yt.object,received:u.parsedType}),zt}let{status:n,ctx:i}=this._processInputParams(e),{shape:o,keys:a}=this._getCached(),f=[];if(!(this._def.catchall instanceof Xs&&this._def.unknownKeys==="strip"))for(let u in i.data)a.includes(u)||f.push(u);let l=[];for(let u of a){let h=o[u],g=i.data[u];l.push({key:{status:"valid",value:u},value:h._parse(new Ss(i,g,i.path,u)),alwaysSet:u in i.data})}if(this._def.catchall instanceof Xs){let u=this._def.unknownKeys;if(u==="passthrough")for(let h of f)l.push({key:{status:"valid",value:h},value:{status:"valid",value:i.data[h]}});else if(u==="strict")f.length>0&&(kt(i,{code:nt.unrecognized_keys,keys:f}),n.dirty());else if(u!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let u=this._def.catchall;for(let h of f){let g=i.data[h];l.push({key:{status:"valid",value:h},value:u._parse(new Ss(i,g,i.path,h)),alwaysSet:h in i.data})}}return i.common.async?Promise.resolve().then(async()=>{let u=[];for(let h of l){let g=await h.key;u.push({key:g,value:await h.value,alwaysSet:h.alwaysSet})}return u}).then(u=>Kn.mergeObjectSync(n,u)):Kn.mergeObjectSync(n,l)}get shape(){return this._def.shape()}strict(e){return pr.errToObj,new Jr({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(r,n)=>{var i,o,a,f;let l=(a=(o=(i=this._def).errorMap)===null||o===void 0?void 0:o.call(i,r,n).message)!==null&&a!==void 0?a:n.defaultError;return r.code==="unrecognized_keys"?{message:(f=pr.errToObj(e).message)!==null&&f!==void 0?f:l}:{message:l}}}:{}})}strip(){return new Jr({...this._def,unknownKeys:"strip"})}passthrough(){return new Jr({...this._def,unknownKeys:"passthrough"})}extend(e){return new Jr({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Jr({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>mg.mergeShapes(this._def.shape(),e._def.shape()),typeName:jt.ZodObject})}setKey(e,r){return this.augment({[e]:r})}catchall(e){return new Jr({...this._def,catchall:e})}pick(e){let r={};return Mr.objectKeys(e).forEach(n=>{e[n]&&this.shape[n]&&(r[n]=this.shape[n])}),new Jr({...this._def,shape:()=>r})}omit(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{e[n]||(r[n]=this.shape[n])}),new Jr({...this._def,shape:()=>r})}deepPartial(){return Lu(this)}partial(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{let i=this.shape[n];e&&!e[n]?r[n]=i:r[n]=i.optional()}),new Jr({...this._def,shape:()=>r})}required(e){let r={};return Mr.objectKeys(this.shape).forEach(n=>{if(e&&!e[n])r[n]=this.shape[n];else{let o=this.shape[n];for(;o instanceof Qs;)o=o._def.innerType;r[n]=o}}),new Jr({...this._def,shape:()=>r})}keyof(){return MC(Mr.objectKeys(this.shape))}};s(Jr,"ZodObject");Jr.create=(t,e)=>new Jr({shape:()=>t,unknownKeys:"strip",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});Jr.strictCreate=(t,e)=>new Jr({shape:()=>t,unknownKeys:"strict",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});Jr.lazycreate=(t,e)=>new Jr({shape:t,unknownKeys:"strip",catchall:Xs.create(),typeName:jt.ZodObject,...nr(e)});var lf=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=this._def.options;function i(o){for(let f of o)if(f.result.status==="valid")return f.result;for(let f of o)if(f.result.status==="dirty")return r.common.issues.push(...f.ctx.common.issues),f.result;let a=o.map(f=>new Ys(f.ctx.common.issues));return kt(r,{code:nt.invalid_union,unionErrors:a}),zt}if(s(i,"handleResults"),r.common.async)return Promise.all(n.map(async o=>{let a={...r,common:{...r.common,issues:[]},parent:null};return{result:await o._parseAsync({data:r.data,path:r.path,parent:a}),ctx:a}})).then(i);{let o,a=[];for(let l of n){let u={...r,common:{...r.common,issues:[]},parent:null},h=l._parseSync({data:r.data,path:r.path,parent:u});if(h.status==="valid")return h;h.status==="dirty"&&!o&&(o={result:h,ctx:u}),u.common.issues.length&&a.push(u.common.issues)}if(o)return r.common.issues.push(...o.ctx.common.issues),o.result;let f=a.map(l=>new Ys(l));return kt(r,{code:nt.invalid_union,unionErrors:f}),zt}}get options(){return this._def.options}};s(lf,"ZodUnion");lf.create=(t,e)=>new lf({options:t,typeName:jt.ZodUnion,...nr(e)});var lg=s(t=>t instanceof hf?lg(t.schema):t instanceof os?lg(t.innerType()):t instanceof pf?[t.value]:t instanceof Eo?t.options:t instanceof mf?Object.keys(t.enum):t instanceof gf?lg(t._def.innerType):t instanceof cf?[void 0]:t instanceof ff?[null]:null,"getDiscriminator"),wl=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.object)return kt(r,{code:nt.invalid_type,expected:yt.object,received:r.parsedType}),zt;let n=this.discriminator,i=r.data[n],o=this.optionsMap.get(i);return o?r.common.async?o._parseAsync({data:r.data,path:r.path,parent:r}):o._parseSync({data:r.data,path:r.path,parent:r}):(kt(r,{code:nt.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),zt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,r,n){let i=new Map;for(let o of r){let a=lg(o.shape[e]);if(!a)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let f of a){if(i.has(f))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(f)}`);i.set(f,o)}}return new wl({typeName:jt.ZodDiscriminatedUnion,discriminator:e,options:r,optionsMap:i,...nr(n)})}};s(wl,"ZodDiscriminatedUnion");function Yy(t,e){let r=sf(t),n=sf(e);if(t===e)return{valid:!0,data:t};if(r===yt.object&&n===yt.object){let i=Mr.objectKeys(e),o=Mr.objectKeys(t).filter(f=>i.indexOf(f)!==-1),a={...t,...e};for(let f of o){let l=Yy(t[f],e[f]);if(!l.valid)return{valid:!1};a[f]=l.data}return{valid:!0,data:a}}else if(r===yt.array&&n===yt.array){if(t.length!==e.length)return{valid:!1};let i=[];for(let o=0;o<t.length;o++){let a=t[o],f=e[o],l=Yy(a,f);if(!l.valid)return{valid:!1};i.push(l.data)}return{valid:!0,data:i}}else return r===yt.date&&n===yt.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}s(Yy,"mergeValues");var uf=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e),i=s((o,a)=>{if(Wy(o)||Wy(a))return zt;let f=Yy(o.value,a.value);return f.valid?((Jy(o)||Jy(a))&&r.dirty(),{status:r.value,value:f.data}):(kt(n,{code:nt.invalid_intersection_types}),zt)},"handleParsed");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(([o,a])=>i(o,a)):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}))}};s(uf,"ZodIntersection");uf.create=(t,e,r)=>new uf({left:t,right:e,typeName:jt.ZodIntersection,...nr(r)});var Is=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.array)return kt(n,{code:nt.invalid_type,expected:yt.array,received:n.parsedType}),zt;if(n.data.length<this._def.items.length)return kt(n,{code:nt.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),zt;!this._def.rest&&n.data.length>this._def.items.length&&(kt(n,{code:nt.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());let o=[...n.data].map((a,f)=>{let l=this._def.items[f]||this._def.rest;return l?l._parse(new Ss(n,a,n.path,f)):null}).filter(a=>!!a);return n.common.async?Promise.all(o).then(a=>Kn.mergeArray(r,a)):Kn.mergeArray(r,o)}get items(){return this._def.items}rest(e){return new Is({...this._def,rest:e})}};s(Is,"ZodTuple");Is.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Is({items:t,typeName:jt.ZodTuple,rest:null,...nr(e)})};var df=class extends Xt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.object)return kt(n,{code:nt.invalid_type,expected:yt.object,received:n.parsedType}),zt;let i=[],o=this._def.keyType,a=this._def.valueType;for(let f in n.data)i.push({key:o._parse(new Ss(n,f,n.path,f)),value:a._parse(new Ss(n,n.data[f],n.path,f))});return n.common.async?Kn.mergeObjectAsync(r,i):Kn.mergeObjectSync(r,i)}get element(){return this._def.valueType}static create(e,r,n){return r instanceof Xt?new df({keyType:e,valueType:r,typeName:jt.ZodRecord,...nr(n)}):new df({keyType:Zs.create(),valueType:e,typeName:jt.ZodRecord,...nr(r)})}};s(df,"ZodRecord");var _l=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.map)return kt(n,{code:nt.invalid_type,expected:yt.map,received:n.parsedType}),zt;let i=this._def.keyType,o=this._def.valueType,a=[...n.data.entries()].map(([f,l],u)=>({key:i._parse(new Ss(n,f,n.path,[u,"key"])),value:o._parse(new Ss(n,l,n.path,[u,"value"]))}));if(n.common.async){let f=new Map;return Promise.resolve().then(async()=>{for(let l of a){let u=await l.key,h=await l.value;if(u.status==="aborted"||h.status==="aborted")return zt;(u.status==="dirty"||h.status==="dirty")&&r.dirty(),f.set(u.value,h.value)}return{status:r.value,value:f}})}else{let f=new Map;for(let l of a){let u=l.key,h=l.value;if(u.status==="aborted"||h.status==="aborted")return zt;(u.status==="dirty"||h.status==="dirty")&&r.dirty(),f.set(u.value,h.value)}return{status:r.value,value:f}}}};s(_l,"ZodMap");_l.create=(t,e,r)=>new _l({valueType:e,keyType:t,typeName:jt.ZodMap,...nr(r)});var ha=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.parsedType!==yt.set)return kt(n,{code:nt.invalid_type,expected:yt.set,received:n.parsedType}),zt;let i=this._def;i.minSize!==null&&n.data.size<i.minSize.value&&(kt(n,{code:nt.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&&(kt(n,{code:nt.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),r.dirty());let o=this._def.valueType;function a(l){let u=new Set;for(let h of l){if(h.status==="aborted")return zt;h.status==="dirty"&&r.dirty(),u.add(h.value)}return{status:r.value,value:u}}s(a,"finalizeSet");let f=[...n.data.values()].map((l,u)=>o._parse(new Ss(n,l,n.path,u)));return n.common.async?Promise.all(f).then(l=>a(l)):a(f)}min(e,r){return new ha({...this._def,minSize:{value:e,message:pr.toString(r)}})}max(e,r){return new ha({...this._def,maxSize:{value:e,message:pr.toString(r)}})}size(e,r){return this.min(e,r).max(e,r)}nonempty(e){return this.min(1,e)}};s(ha,"ZodSet");ha.create=(t,e)=>new ha({valueType:t,minSize:null,maxSize:null,typeName:jt.ZodSet,...nr(e)});var fc=class extends Xt{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.function)return kt(r,{code:nt.invalid_type,expected:yt.function,received:r.parsedType}),zt;function n(f,l){return dg({data:f,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,ug(),w0].filter(u=>!!u),issueData:{code:nt.invalid_arguments,argumentsError:l}})}s(n,"makeArgsIssue");function i(f,l){return dg({data:f,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,ug(),w0].filter(u=>!!u),issueData:{code:nt.invalid_return_type,returnTypeError:l}})}s(i,"makeReturnsIssue");let o={errorMap:r.common.contextualErrorMap},a=r.data;return this._def.returns instanceof lc?Ai(async(...f)=>{let l=new Ys([]),u=await this._def.args.parseAsync(f,o).catch(x=>{throw l.addIssue(n(f,x)),l}),h=await a(...u);return await this._def.returns._def.type.parseAsync(h,o).catch(x=>{throw l.addIssue(i(h,x)),l})}):Ai((...f)=>{let l=this._def.args.safeParse(f,o);if(!l.success)throw new Ys([n(f,l.error)]);let u=a(...l.data),h=this._def.returns.safeParse(u,o);if(!h.success)throw new Ys([i(u,h.error)]);return h.data})}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new fc({...this._def,args:Is.create(e).rest(da.create())})}returns(e){return new fc({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,r,n){return new fc({args:e||Is.create([]).rest(da.create()),returns:r||da.create(),typeName:jt.ZodFunction,...nr(n)})}};s(fc,"ZodFunction");var hf=class extends Xt{get schema(){return this._def.getter()}_parse(e){let{ctx:r}=this._processInputParams(e);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}};s(hf,"ZodLazy");hf.create=(t,e)=>new hf({getter:t,typeName:jt.ZodLazy,...nr(e)});var pf=class extends Xt{_parse(e){if(e.data!==this._def.value){let r=this._getOrReturnCtx(e);return kt(r,{received:r.data,code:nt.invalid_literal,expected:this._def.value}),zt}return{status:"valid",value:e.data}}get value(){return this._def.value}};s(pf,"ZodLiteral");pf.create=(t,e)=>new pf({value:t,typeName:jt.ZodLiteral,...nr(e)});function MC(t,e){return new Eo({values:t,typeName:jt.ZodEnum,...nr(e)})}s(MC,"createZodEnum");var Eo=class extends Xt{_parse(e){if(typeof e.data!="string"){let r=this._getOrReturnCtx(e),n=this._def.values;return kt(r,{expected:Mr.joinValues(n),received:r.parsedType,code:nt.invalid_type}),zt}if(this._def.values.indexOf(e.data)===-1){let r=this._getOrReturnCtx(e),n=this._def.values;return kt(r,{received:r.data,code:nt.invalid_enum_value,options:n}),zt}return Ai(e.data)}get options(){return this._def.values}get enum(){let e={};for(let r of this._def.values)e[r]=r;return e}get Values(){let e={};for(let r of this._def.values)e[r]=r;return e}get Enum(){let e={};for(let r of this._def.values)e[r]=r;return e}extract(e){return Eo.create(e)}exclude(e){return Eo.create(this.options.filter(r=>!e.includes(r)))}};s(Eo,"ZodEnum");Eo.create=MC;var mf=class extends Xt{_parse(e){let r=Mr.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==yt.string&&n.parsedType!==yt.number){let i=Mr.objectValues(r);return kt(n,{expected:Mr.joinValues(i),received:n.parsedType,code:nt.invalid_type}),zt}if(r.indexOf(e.data)===-1){let i=Mr.objectValues(r);return kt(n,{received:n.data,code:nt.invalid_enum_value,options:i}),zt}return Ai(e.data)}get enum(){return this._def.values}};s(mf,"ZodNativeEnum");mf.create=(t,e)=>new mf({values:t,typeName:jt.ZodNativeEnum,...nr(e)});var lc=class extends Xt{unwrap(){return this._def.type}_parse(e){let{ctx:r}=this._processInputParams(e);if(r.parsedType!==yt.promise&&r.common.async===!1)return kt(r,{code:nt.invalid_type,expected:yt.promise,received:r.parsedType}),zt;let n=r.parsedType===yt.promise?r.data:Promise.resolve(r.data);return Ai(n.then(i=>this._def.type.parseAsync(i,{path:r.path,errorMap:r.common.contextualErrorMap})))}};s(lc,"ZodPromise");lc.create=(t,e)=>new lc({type:t,typeName:jt.ZodPromise,...nr(e)});var os=class extends Xt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===jt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:r,ctx:n}=this._processInputParams(e),i=this._def.effect||null;if(i.type==="preprocess"){let a=i.transform(n.data);return n.common.async?Promise.resolve(a).then(f=>this._def.schema._parseAsync({data:f,path:n.path,parent:n})):this._def.schema._parseSync({data:a,path:n.path,parent:n})}let o={addIssue:a=>{kt(n,a),a.fatal?r.abort():r.dirty()},get path(){return n.path}};if(o.addIssue=o.addIssue.bind(o),i.type==="refinement"){let a=s(f=>{let l=i.refinement(f,o);if(n.common.async)return Promise.resolve(l);if(l instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return f},"executeRefinement");if(n.common.async===!1){let f=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return f.status==="aborted"?zt:(f.status==="dirty"&&r.dirty(),a(f.value),{status:r.value,value:f.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(f=>f.status==="aborted"?zt:(f.status==="dirty"&&r.dirty(),a(f.value).then(()=>({status:r.value,value:f.value}))))}if(i.type==="transform")if(n.common.async===!1){let a=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!hg(a))return a;let f=i.transform(a.value,o);if(f instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:f}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(a=>hg(a)?Promise.resolve(i.transform(a.value,o)).then(f=>({status:r.value,value:f})):a);Mr.assertNever(i)}};s(os,"ZodEffects");os.create=(t,e,r)=>new os({schema:t,typeName:jt.ZodEffects,effect:e,...nr(r)});os.createWithPreprocess=(t,e,r)=>new os({schema:e,effect:{type:"preprocess",transform:t},typeName:jt.ZodEffects,...nr(r)});var Qs=class extends Xt{_parse(e){return this._getType(e)===yt.undefined?Ai(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};s(Qs,"ZodOptional");Qs.create=(t,e)=>new Qs({innerType:t,typeName:jt.ZodOptional,...nr(e)});var pa=class extends Xt{_parse(e){return this._getType(e)===yt.null?Ai(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};s(pa,"ZodNullable");pa.create=(t,e)=>new pa({innerType:t,typeName:jt.ZodNullable,...nr(e)});var gf=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=r.data;return r.parsedType===yt.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:r.path,parent:r})}removeDefault(){return this._def.innerType}};s(gf,"ZodDefault");gf.create=(t,e)=>new gf({innerType:t,typeName:jt.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...nr(e)});var Al=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r,common:{...r.common,issues:[]}}});return pg(n)?n.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue()})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue()}}removeCatch(){return this._def.innerType}};s(Al,"ZodCatch");Al.create=(t,e)=>new Al({innerType:t,typeName:jt.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...nr(e)});var El=class extends Xt{_parse(e){if(this._getType(e)!==yt.nan){let n=this._getOrReturnCtx(e);return kt(n,{code:nt.invalid_type,expected:yt.nan,received:n.parsedType}),zt}return{status:"valid",value:e.data}}};s(El,"ZodNaN");El.create=t=>new El({typeName:jt.ZodNaN,...nr(t)});var pz=Symbol("zod_brand"),x0=class extends Xt{_parse(e){let{ctx:r}=this._processInputParams(e),n=r.data;return this._def.type._parse({data:n,path:r.path,parent:r})}unwrap(){return this._def.type}};s(x0,"ZodBranded");var bf=class extends Xt{_parse(e){let{status:r,ctx:n}=this._processInputParams(e);if(n.common.async)return s(async()=>{let o=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return o.status==="aborted"?zt:o.status==="dirty"?(r.dirty(),TC(o.value)):this._def.out._parseAsync({data:o.value,path:n.path,parent:n})},"handleAsync")();{let i=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?zt:i.status==="dirty"?(r.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:n.path,parent:n})}}static create(e,r){return new bf({in:e,out:r,typeName:jt.ZodPipeline})}};s(bf,"ZodPipeline");var RC=s((t,e={},r)=>t?cc.create().superRefine((n,i)=>{if(!t(n)){let o=typeof e=="function"?e(n):e,a=typeof o=="string"?{message:o}:o;i.addIssue({code:"custom",...a,fatal:r})}}):cc.create(),"custom"),mz={object:Jr.lazycreate},jt;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline"})(jt||(jt={}));var gz=s((t,e={message:`Input not instance of ${t.name}`})=>RC(r=>r instanceof t,e,!0),"instanceOfType"),BC=Zs.create,DC=Ao.create,bz=El.create,vz=of.create,PC=af.create,yz=ua.create,xz=yl.create,wz=cf.create,_z=ff.create,Az=cc.create,Ez=da.create,Cz=Xs.create,Sz=xl.create,Iz=ss.create,kz=Jr.create,Tz=Jr.strictCreate,Mz=lf.create,Rz=wl.create,Bz=uf.create,Dz=Is.create,Pz=df.create,Oz=_l.create,Fz=ha.create,Nz=fc.create,Lz=hf.create,Uz=pf.create,jz=Eo.create,qz=mf.create,Hz=lc.create,IC=os.create,zz=Qs.create,$z=pa.create,Gz=os.createWithPreprocess,Kz=bf.create,Vz=s(()=>BC().optional(),"ostring"),Wz=s(()=>DC().optional(),"onumber"),Jz=s(()=>PC().optional(),"oboolean"),Yz={string:t=>Zs.create({...t,coerce:!0}),number:t=>Ao.create({...t,coerce:!0}),boolean:t=>af.create({...t,coerce:!0}),bigint:t=>of.create({...t,coerce:!0}),date:t=>ua.create({...t,coerce:!0})},Zz=zt,_e=Object.freeze({__proto__:null,defaultErrorMap:w0,setErrorMap:oz,getErrorMap:ug,makeIssue:dg,EMPTY_PATH:az,addIssueToContext:kt,ParseStatus:Kn,INVALID:zt,DIRTY:TC,OK:Ai,isAborted:Wy,isDirty:Jy,isValid:hg,isAsync:pg,get util(){return Mr},ZodParsedType:yt,getParsedType:sf,ZodType:Xt,ZodString:Zs,ZodNumber:Ao,ZodBigInt:of,ZodBoolean:af,ZodDate:ua,ZodSymbol:yl,ZodUndefined:cf,ZodNull:ff,ZodAny:cc,ZodUnknown:da,ZodNever:Xs,ZodVoid:xl,ZodArray:ss,get objectUtil(){return mg},ZodObject:Jr,ZodUnion:lf,ZodDiscriminatedUnion:wl,ZodIntersection:uf,ZodTuple:Is,ZodRecord:df,ZodMap:_l,ZodSet:ha,ZodFunction:fc,ZodLazy:hf,ZodLiteral:pf,ZodEnum:Eo,ZodNativeEnum:mf,ZodPromise:lc,ZodEffects:os,ZodTransformer:os,ZodOptional:Qs,ZodNullable:pa,ZodDefault:gf,ZodCatch:Al,ZodNaN:El,BRAND:pz,ZodBranded:x0,ZodPipeline:bf,custom:RC,Schema:Xt,ZodSchema:Xt,late:mz,get ZodFirstPartyTypeKind(){return jt},coerce:Yz,any:Az,array:Iz,bigint:vz,boolean:PC,date:yz,discriminatedUnion:Rz,effect:IC,enum:jz,function:Nz,instanceof:gz,intersection:Bz,lazy:Lz,literal:Uz,map:Oz,nan:bz,nativeEnum:qz,never:Cz,null:_z,nullable:$z,number:DC,object:kz,oboolean:Jz,onumber:Wz,optional:zz,ostring:Vz,pipeline:Kz,preprocess:Gz,promise:Hz,record:Pz,set:Fz,strictObject:Tz,string:BC,symbol:xz,transformer:IC,tuple:Dz,undefined:wz,union:Mz,unknown:Ez,void:Sz,NEVER:Zz,ZodIssueCode:nt,quotelessJson:sz,ZodError:Ys});var FC=_e.array(_e.string().or(_e.record(_e.any()))),ise=_e.object({type:_e.string().optional(),narrative:_e.string().optional()}),gg=_e.string().or(_e.object({id:_e.string(),type:_e.string(),caption:_e.string().optional()})),Xz=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),latitude:_e.number(),longitude:_e.number()}),Qz=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),addressCountry:_e.string().optional(),addressCountryCode:_e.string().optional(),addressRegion:_e.string().optional(),addressLocality:_e.string().optional(),streetAddress:_e.string().optional(),postOfficeBoxNumber:_e.string().optional(),postalCode:_e.string().optional(),geo:Xz.optional()}),e$=_e.enum(["sourcedId","systemId","productId","userName","accountId","emailAddress","nationalIdentityNumber","isbn","issn","lisSourcedId","oneRosterSourcedId","sisSourcedId","ltiContextId","ltiDeploymentId","ltiToolId","ltiPlatformId","ltiUserId","identifier"]).or(_e.string()),NC=_e.object({type:_e.string().min(1).or(_e.string().array().nonempty()),identifier:_e.string(),identifierType:e$}),_0=_e.string().or(_e.object({id:_e.string().optional(),type:_e.string().or(_e.string().array().nonempty().optional()),name:_e.string().optional(),url:_e.string().optional(),phone:_e.string().optional(),description:_e.string().optional(),endorsement:_e.any().array().optional(),image:gg.optional(),email:_e.string().email().optional(),address:Qz.optional(),otherIdentifier:NC.array().optional(),official:_e.string().optional(),parentOrg:_e.any().optional(),familyName:_e.string().optional(),givenName:_e.string().optional(),additionalName:_e.string().optional(),patronymicName:_e.string().optional(),honorificPrefix:_e.string().optional(),honorificSuffix:_e.string().optional(),familyNamePrefix:_e.string().optional(),dateOfBirth:_e.string().optional()}).catchall(_e.any())),Zy=_e.object({id:_e.string().optional()}).catchall(_e.any()),t$=_e.object({type:_e.string(),id:_e.string()}),r$=_e.object({id:_e.string(),type:_e.string()}),n$=_e.object({id:_e.string(),type:_e.string()}).catchall(_e.any()),Cl=_e.object({"@context":FC,id:_e.string().optional(),type:_e.string().array().nonempty(),issuer:_0,issuanceDate:_e.string(),expirationDate:_e.string().optional(),credentialSubject:Zy.or(Zy.array()),credentialStatus:t$.optional(),credentialSchema:r$.array().optional(),refreshService:n$.optional()}).catchall(_e.any()),vf=_e.object({type:_e.string(),created:_e.string(),challenge:_e.string().optional(),domain:_e.string().optional(),nonce:_e.string().optional(),proofPurpose:_e.string(),verificationMethod:_e.string(),jws:_e.string().optional()}).catchall(_e.any()),A0=Cl.extend({proof:vf.or(vf.array())}),i$=_e.object({"@context":FC,id:_e.string().optional(),type:_e.string().array().nonempty(),verifiableCredential:A0.or(A0.array()).optional(),holder:_e.string().optional()}).catchall(_e.any()),Xy=i$.extend({proof:vf.or(vf.array())}),s$=_e.enum(["ceasn:Competency","ceterms:Credential","CFItem","CFRubric","CFRubricCriterion","CFRubricCriterionLevel","CTDL"]).or(_e.string()),bg=_e.object({type:_e.string().array().nonempty(),targetCode:_e.string().optional(),targetDescription:_e.string().optional(),targetName:_e.string(),targetFramework:_e.string().optional(),targetType:s$.optional(),targetUrl:_e.string()}),o$=_e.enum(["Achievement","ApprenticeshipCertificate","Assessment","Assignment","AssociateDegree","Award","Badge","BachelorDegree","Certificate","CertificateOfCompletion","Certification","CommunityService","Competency","Course","CoCurricular","Degree","Diploma","DoctoralDegree","Fieldwork","GeneralEducationDevelopment","JourneymanCertificate","LearningProgram","License","Membership","ProfessionalDoctorate","QualityAssuranceCredential","MasterCertificate","MasterDegree","MicroCredential","ResearchDoctorate","SecondarySchoolDiploma"]),a$=o$.or(_e.string()),c$=_e.object({id:_e.string().optional(),narrative:_e.string().optional()}).catchall(_e.any()),f$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),endorsementComment:_e.string().optional()}),l$=Cl.extend({credentialSubject:f$,proof:vf.or(vf.array()).optional()}),u$=_e.object({id:_e.string(),"@language":_e.string().optional(),version:_e.string().optional()}),d$=_e.enum(["GradePointAverage","LetterGrade","Percent","PerformanceLevel","PredictedScore","RawScore","Result","RubricCriterion","RubricCriterionLevel","RubricScore","ScaledScore","Status"]).or(_e.string()),h$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),description:_e.string().optional(),level:_e.string().optional(),name:_e.string(),points:_e.string().optional()}).catchall(_e.any()),p$=_e.object({id:_e.string(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),allowedValue:_e.string().array().optional(),name:_e.string(),requiredLevel:_e.string().optional(),requiredValue:_e.string().optional(),resultType:d$,rubricCriterionLevel:h$.array().optional(),valueMax:_e.string().optional(),valueMin:_e.string().optional()}).catchall(_e.any()),m$=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),alignment:bg.array().optional(),achievementType:a$.optional(),creator:_0.optional(),creditsAvailable:_e.number().optional(),criteria:c$,description:_e.string(),endorsement:l$.array().optional(),fieldOfStudy:_e.string().optional(),humanCode:_e.string().optional(),image:gg.optional(),"@language":_e.string().optional(),name:_e.string(),otherIdentifier:NC.array().optional(),related:u$.array().optional(),resultDescription:p$.array().optional(),specialization:_e.string().optional(),tag:_e.string().array().optional(),version:_e.string().optional()}).catchall(_e.any()),g$=_e.object({type:_e.string(),hashed:_e.boolean(),identityHash:_e.string(),identityType:_e.string(),salt:_e.string().optional()}),b$=_e.enum(["Completed","Enrolled","Failed","InProgress","OnHold","Withdrew"]),v$=_e.object({type:_e.string().array().nonempty(),achievedLevel:_e.string().optional(),alignment:bg.array().optional(),resultDescription:_e.string().optional(),status:b$.optional(),value:_e.string().optional()}).catchall(_e.any()),OC=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),activityEndDate:_e.string().optional(),activityStartDate:_e.string().optional(),creditsEarned:_e.number().optional(),achievement:m$.optional(),identifier:g$.array().optional(),image:gg.optional(),licenseNumber:_e.string().optional(),narrative:_e.string().optional(),result:v$.array().optional(),role:_e.string().optional(),source:_0.optional(),term:_e.string().optional()}).catchall(_e.any()),y$=_e.object({id:_e.string().optional(),type:_e.string().array().nonempty(),narrative:_e.string().optional(),name:_e.string().optional(),description:_e.string().optional(),genre:_e.string().optional(),audience:_e.string().optional()}).catchall(_e.any()),x$=Cl.extend({name:_e.string().optional(),description:_e.string().optional(),image:gg.optional(),credentialSubject:OC.or(OC.array()),endorsement:Cl.array().optional(),evidence:y$.array().optional()}),ose=x$.extend({proof:vf.or(vf.array())}),cse=_e.object({checks:_e.string().array(),warnings:_e.string().array(),errors:_e.string().array()}),LC=_e.enum(["Success","Failed","Error"]),fse=LC.enum,lse=_e.object({check:_e.string(),status:LC,message:_e.string().optional(),details:_e.string().optional()}),use=_e.object({title:_e.string().optional(),createdAt:_e.string().optional(),issuer:_0.optional(),issuee:_0.optional(),credentialSubject:Zy.optional()}),dse=_e.object({id:_e.string(),uri:_e.string()}).catchall(_e.any()),w$=_e.object({profileId:_e.string().min(3).max(40),displayName:_e.string().default(""),did:_e.string(),email:_e.string().optional(),image:_e.string().optional(),isServiceProfile:_e.boolean().default(!1).optional()}),pse=_e.enum(["CONNECTED","PENDING_REQUEST_SENT","PENDING_REQUEST_RECEIVED","NOT_CONNECTED"]),mse=_e.object({uri:_e.string(),to:_e.string(),from:_e.string(),sent:_e.string().datetime(),received:_e.string().datetime().optional()}),gse=_e.object({uri:_e.string(),name:_e.string().optional(),type:_e.string().optional(),category:_e.string().optional()}),bse=_e.object({to:w$,from:_e.string(),received:_e.string()}),_$=_e.object({kty:_e.string(),crv:_e.string(),x:_e.string(),y:_e.string().optional(),n:_e.string().optional(),d:_e.string()}),A$=_e.object({alg:_e.string(),iv:_e.string(),tag:_e.string(),epk:_$.partial().optional(),kid:_e.string().optional(),apv:_e.string().optional(),apu:_e.string().optional()}),E$=_e.object({header:A$,encrypted_key:_e.string()}),UC=_e.object({protected:_e.string(),iv:_e.string(),ciphertext:_e.string(),tag:_e.string(),aad:_e.string().optional(),recipients:E$.array().optional()});var Qy=s(async(t,e)=>{let r=t.id.did(),n=await CC(e,async a=>{let f=await t.invoke.getDidAuthVp({proofFormat:"jwt",challenge:a});if(typeof f!="string")throw new Error("Error getting DID-Auth-JWT!");return f}),i;try{i=await n.profile.getProfile.query()}catch(a){t.debug?.("No profile!",a)}let o=i?.did||r;return{name:"LearnCard Network",displayName:"LearnCard Network",description:"LearnCard Network Integration",id:{did:(a,f)=>!f||f==="web"?o:t.id.did(f),keypair:(a,f)=>t.id.keypair(f)},read:{get:async(a,f)=>{if(a.debug?.("learnCard.read['LearnCard Network'].get"),!f)return;let l=f.split(":");if(l.length!==5)return;let[u,h]=l;if(!(u!=="lc"||h!=="network"))try{let g=await n.storage.resolve.query({uri:f});return"ciphertext"in g&&(g=await a.invoke.getDIDObject().decryptDagJWE(g)),await A0.or(Xy).parseAsync(g)}catch(g){a.debug?.(g);return}}},store:{upload:async(a,f)=>(a.debug?.("learnCard.store['LearnCard Network'].upload"),n.storage.store.mutate({item:f})),uploadEncrypted:async(a,f,{recipients:l=[]}={recipients:[]})=>{a.debug?.("learnCard.store['LearnCard Network'].upload");let u=await a.invoke.getDIDObject().createDagJWE(f,[a.id.did(),...l]);return n.storage.store.mutate({item:u})}},methods:{createProfile:async(a,f)=>{if(i)throw new Error("Account already exists!");let l=await n.profile.createProfile.mutate(f);return i=await n.profile.getProfile.query(),o=l,l},createServiceProfile:async(a,f)=>{if(i)throw new Error("Account already exists!");let l=await n.profile.createServiceProfile.mutate(f);return i=await n.profile.getProfile.query(),o=l,l},updateProfile:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return await n.profile.updateProfile.mutate(f)?(i=await n.profile.getProfile.query(),!0):!1},deleteProfile:async()=>{if(!i)throw new Error("Account does not exist!");return await n.profile.deleteProfile.mutate()?(i=void 0,!0):!1},getProfile:async(a,f)=>f?n.profile.getOtherProfile.query({profileId:f}):n.profile.getProfile.query(),searchProfiles:async(a,f="",{limit:l=25,includeSelf:u=!1,includeConnectionStatus:h=!1}={})=>n.profile.searchProfiles.query({input:f,limit:l,includeSelf:u,includeConnectionStatus:h}),connectWith:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectWith.mutate({profileId:f})},cancelConnectionRequest:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.cancelConnectionRequest.mutate({profileId:f})},connectWithInvite:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectWithInvite.mutate({profileId:f,challenge:l})},disconnectWith:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.disconnectWith.mutate({profileId:f})},acceptConnectionRequest:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.acceptConnectionRequest.mutate({profileId:f})},getConnections:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.connections.query()},getPendingConnections:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.pendingConnections.query()},getConnectionRequests:async()=>{if(!i)throw new Error("Please make an account first!");return n.profile.connectionRequests.query()},generateInvite:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.generateInvite.mutate({challenge:f})},sendCredential:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");if(!u)return n.credential.sendCredential.mutate({profileId:f,credential:l});let h=await a.invoke.getProfile(f);if(!h)throw new Error("Could not find target account");let g=await a.invoke.getDIDObject().createDagJWE(l,[i.did,h.did]);return n.credential.sendCredential.mutate({profileId:f,credential:g})},acceptCredential:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.acceptCredential.mutate({uri:f})},getReceivedCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.receivedCredentials.query({from:f})},getSentCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.sentCredentials.query({to:f})},getIncomingCredentials:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.incomingCredentials.query({from:f})},deleteCredential:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.credential.deleteCredential.mutate({uri:f})},sendPresentation:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");if(!u)return n.presentation.sendPresentation.mutate({profileId:f,presentation:l});let h=await a.invoke.getProfile(f);if(!h)throw new Error("Could not find target account");let g=await a.invoke.getDIDObject().createDagJWE(l,[i.did,h.did]);return n.presentation.sendPresentation.mutate({profileId:f,presentation:g})},acceptPresentation:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.acceptPresentation.mutate({uri:f})},getReceivedPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.receivedPresentations.query({from:f})},getSentPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.sentPresentations.query({to:f})},getIncomingPresentations:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.incomingPresentations.query({from:f})},deletePresentation:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.presentation.deletePresentation.mutate({uri:f})},createBoost:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.boost.createBoost.mutate({credential:f,...l})},getBoosts:async()=>{if(!i)throw new Error("Please make an account first!");return n.boost.getBoosts.query()},getBoostRecipients:async(a,f,l=25,u)=>{if(!i)throw new Error("Please make an account first!");return n.boost.getBoostRecipients.query({uri:f,limit:l,skip:u})},updateBoost:async(a,f,l)=>{if(!i)throw new Error("Please make an account first!");return n.boost.updateBoost.mutate({uri:f,updates:l})},deleteBoost:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.boost.deleteBoost.mutate({uri:f})},sendBoost:async(a,f,l,u=!0)=>{if(!i)throw new Error("Please make an account first!");let h=await a.invoke.resolveFromLCN(l),g=await Cl.spa(h);if(!g.success)throw new Error("Did not get a valid boost from URI");let x=await a.invoke.getProfile(f);if(!x)throw new Error("Target profile not found");let _=g.data;_.issuer=a.id.did(),Array.isArray(_.credentialSubject)?_.credentialSubject=_.credentialSubject.map(F=>({...F,id:x.did})):_.credentialSubject.id=x.did,_?.type?.includes("BoostCredential")&&(_.boostId=l);let E=await a.invoke.issueCredential(_);if(!u)return n.boost.sendBoost.mutate({profileId:f,uri:l,credential:E});let T=await n.utilities.getDid.query(),B=await a.invoke.getDIDObject().createDagJWE(E,[i.did,x.did,T]);return n.boost.sendBoost.mutate({profileId:f,uri:l,credential:B})},registerSigningAuthority:async(a,f)=>{if(!i)throw new Error("Please make an account first!");return n.profile.registerSigningAuthority.mutate({signingAuthority:f})},resolveFromLCN:async(a,f)=>{let l=await n.storage.resolve.query({uri:f});return Cl.or(A0).or(Xy).or(UC).parseAsync(l)},registerDeviceForPush:async(a,f)=>n.profile.registerDeviceForPush.mutate({deviceToken:f}),unregisterDeviceForPush:async(a,f)=>n.profile.unregisterDeviceForPush.mutate({deviceToken:f})}}},"getLearnCardNetworkPlugin"),e3=s(async(t,e)=>{let r=[{id:"LearnCard Network",url:"https://network.learncard.com",did:"did:web:network.learncard.com"}],n;if(e){let a=await fetch(e);a.status===200?n=JSON.parse(await a.text()):n=r}else n=r;let i=s(a=>{if(!!a)return typeof a=="string"?a:"id"in a&&typeof a.id=="string"?a.id:void 0},"getIssuerDID"),o=s(a=>{let f=i(a);if(!!f)return n.find(l=>l.did===f)},"getTrustedBoostVerifier");return{name:"VerifyBoost",displayName:"Verify Boost Extension",description:"Adds a check for validating Boost Credentials.",methods:{verifyCredential:async(a,f)=>{let l=await t.invoke.verifyCredential(f),u=f?.boostCredential;try{if(u){let h=await t.invoke.verifyCredential(u);if(!u?.boostId&&!f?.boostId&&l.warnings.push("Boost Authenticity could not be verified: Boost ID metadata is missing."),h.errors?.length>0)l.errors=[...h.errors||[],...l.errors||[],"Boost Credential could not be verified."];else if(u?.boostId!==f?.boostId)l.errors.push("Boost Authenticity could not be verified: Boost ID metadata is mismatched.");else{let g=o(f?.issuer);g?l.checks.push(`Boost is Authentic. Verified by ${g.id}.`):l.warnings.push(`Boost Authenticity could not be verified. Issuer is outside of trust network: ${i(f?.issuer)}`)}}}catch{l.errors.push("Boost authenticity could not be verified.")}return l}}}},"getVerifyBoostPlugin");var _pe=require("isomorphic-fetch"),gv=Js(XC()),aD=Js(require("isomorphic-webcrypto")),mU=Js(tS());var $i={};vl($i,{BaseContract:()=>ad,BigNumber:()=>ze,Contract:()=>Ol,ContractFactory:()=>ip,FixedNumber:()=>cn,Signer:()=>Hi,VoidSigner:()=>vc,Wallet:()=>Ro,Wordlist:()=>co,constants:()=>v3,errors:()=>ks,getDefaultProvider:()=>A4,logger:()=>AW,providers:()=>E4,utils:()=>I4,version:()=>k4,wordlists:()=>fd});var mS=Js(s3());var iS="logger/5.7.0";var sS=!1,oS=!1,_g={debug:1,default:2,info:2,warning:3,error:4,off:5},aS=_g.default,o3=null;function P$(){try{let t=[];if(["NFD","NFC","NFKD","NFKC"].forEach(e=>{try{if("test".normalize(e)!=="test")throw new Error("bad normalize")}catch{t.push(e)}}),t.length)throw new Error("missing "+t.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}s(P$,"_checkNormalize");var cS=P$(),a3;(function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARNING="WARNING",t.ERROR="ERROR",t.OFF="OFF"})(a3||(a3={}));var ks;(function(t){t.UNKNOWN_ERROR="UNKNOWN_ERROR",t.NOT_IMPLEMENTED="NOT_IMPLEMENTED",t.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",t.NETWORK_ERROR="NETWORK_ERROR",t.SERVER_ERROR="SERVER_ERROR",t.TIMEOUT="TIMEOUT",t.BUFFER_OVERRUN="BUFFER_OVERRUN",t.NUMERIC_FAULT="NUMERIC_FAULT",t.MISSING_NEW="MISSING_NEW",t.INVALID_ARGUMENT="INVALID_ARGUMENT",t.MISSING_ARGUMENT="MISSING_ARGUMENT",t.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",t.CALL_EXCEPTION="CALL_EXCEPTION",t.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",t.NONCE_EXPIRED="NONCE_EXPIRED",t.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",t.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",t.TRANSACTION_REPLACED="TRANSACTION_REPLACED",t.ACTION_REJECTED="ACTION_REJECTED"})(ks||(ks={}));var fS="0123456789abcdef",ve=class{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,r){let n=e.toLowerCase();_g[n]==null&&this.throwArgumentError("invalid log level name","logLevel",e),!(aS>_g[n])&&console.log.apply(console,r)}debug(...e){this._log(ve.levels.DEBUG,e)}info(...e){this._log(ve.levels.INFO,e)}warn(...e){this._log(ve.levels.WARNING,e)}makeError(e,r,n){if(oS)return this.makeError("censored error",r,{});r||(r=ve.errors.UNKNOWN_ERROR),n||(n={});let i=[];Object.keys(n).forEach(l=>{let u=n[l];try{if(u instanceof Uint8Array){let h="";for(let g=0;g<u.length;g++)h+=fS[u[g]>>4],h+=fS[u[g]&15];i.push(l+"=Uint8Array(0x"+h+")")}else i.push(l+"="+JSON.stringify(u))}catch{i.push(l+"="+JSON.stringify(n[l].toString()))}}),i.push(`code=${r}`),i.push(`version=${this.version}`);let o=e,a="";switch(r){case ks.NUMERIC_FAULT:{a="NUMERIC_FAULT";let l=e;switch(l){case"overflow":case"underflow":case"division-by-zero":a+="-"+l;break;case"negative-power":case"negative-width":a+="-unsupported";break;case"unbound-bitwise-result":a+="-unbound-result";break}break}case ks.CALL_EXCEPTION:case ks.INSUFFICIENT_FUNDS:case ks.MISSING_NEW:case ks.NONCE_EXPIRED:case ks.REPLACEMENT_UNDERPRICED:case ks.TRANSACTION_REPLACED:case ks.UNPREDICTABLE_GAS_LIMIT:a=r;break}a&&(e+=" [ See: https://links.ethers.org/v5-errors-"+a+" ]"),i.length&&(e+=" ("+i.join(", ")+")");let f=new Error(e);return f.reason=o,f.code=r,Object.keys(n).forEach(function(l){f[l]=n[l]}),f}throwError(e,r,n){throw this.makeError(e,r,n)}throwArgumentError(e,r,n){return this.throwError(e,ve.errors.INVALID_ARGUMENT,{argument:r,value:n})}assert(e,r,n,i){e||this.throwError(r,n,i)}assertArgument(e,r,n,i){e||this.throwArgumentError(r,n,i)}checkNormalize(e){e==null&&(e="platform missing String.prototype.normalize"),cS&&this.throwError("platform missing String.prototype.normalize",ve.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:cS})}checkSafeUint53(e,r){typeof e=="number"&&(r==null&&(r="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(r,ve.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(r,ve.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,r,n){n?n=": "+n:n="",e<r&&this.throwError("missing argument"+n,ve.errors.MISSING_ARGUMENT,{count:e,expectedCount:r}),e>r&&this.throwError("too many arguments"+n,ve.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:r})}checkNew(e,r){(e===Object||e==null)&&this.throwError("missing new",ve.errors.MISSING_NEW,{name:r.name})}checkAbstract(e,r){e===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",ve.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):(e===Object||e==null)&&this.throwError("missing new",ve.errors.MISSING_NEW,{name:r.name})}static globalLogger(){return o3||(o3=new ve(iS)),o3}static setCensorship(e,r){if(!e&&r&&this.globalLogger().throwError("cannot permanently disable censorship",ve.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),sS){if(!e)return;this.globalLogger().throwError("error censorship permanent",ve.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}oS=!!e,sS=!!r}static setLogLevel(e){let r=_g[e.toLowerCase()];if(r==null){ve.globalLogger().warn("invalid log level - "+e);return}aS=r}static from(e){return new ve(e)}};s(ve,"Logger");ve.errors=ks;ve.levels=a3;var lS="bytes/5.7.0";var gn=new ve(lS);function dS(t){return!!t.toHexString}s(dS,"isHexable");function qu(t){return t.slice||(t.slice=function(){let e=Array.prototype.slice.call(arguments);return qu(new Uint8Array(Array.prototype.slice.apply(t,e)))}),t}s(qu,"addSlice");function pc(t){return Pt(t)&&!(t.length%2)||eo(t)}s(pc,"isBytesLike");function uS(t){return typeof t=="number"&&t==t&&t%1===0}s(uS,"isInteger");function eo(t){if(t==null)return!1;if(t.constructor===Uint8Array)return!0;if(typeof t=="string"||!uS(t.length)||t.length<0)return!1;for(let e=0;e<t.length;e++){let r=t[e];if(!uS(r)||r<0||r>=256)return!1}return!0}s(eo,"isBytes");function je(t,e){if(e||(e={}),typeof t=="number"){gn.checkSafeUint53(t,"invalid arrayify value");let r=[];for(;t;)r.unshift(t&255),t=parseInt(String(t/256));return r.length===0&&r.push(0),qu(new Uint8Array(r))}if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),dS(t)&&(t=t.toHexString()),Pt(t)){let r=t.substring(2);r.length%2&&(e.hexPad==="left"?r="0"+r:e.hexPad==="right"?r+="0":gn.throwArgumentError("hex data is odd-length","value",t));let n=[];for(let i=0;i<r.length;i+=2)n.push(parseInt(r.substring(i,i+2),16));return qu(new Uint8Array(n))}return eo(t)?qu(new Uint8Array(t)):gn.throwArgumentError("invalid arrayify value","value",t)}s(je,"arrayify");function sr(t){let e=t.map(i=>je(i)),r=e.reduce((i,o)=>i+o.length,0),n=new Uint8Array(r);return e.reduce((i,o)=>(n.set(o,i),i+o.length),0),qu(n)}s(sr,"concat");function Ts(t){let e=je(t);if(e.length===0)return e;let r=0;for(;r<e.length&&e[r]===0;)r++;return r&&(e=e.slice(r)),e}s(Ts,"stripZeros");function Sl(t,e){t=je(t),t.length>e&&gn.throwArgumentError("value out of range","value",arguments[0]);let r=new Uint8Array(e);return r.set(t,e-t.length),qu(r)}s(Sl,"zeroPad");function Pt(t,e){return!(typeof t!="string"||!t.match(/^0x[0-9A-Fa-f]*$/)||e&&t.length!==2+2*e)}s(Pt,"isHexString");var c3="0123456789abcdef";function Ve(t,e){if(e||(e={}),typeof t=="number"){gn.checkSafeUint53(t,"invalid hexlify value");let r="";for(;t;)r=c3[t&15]+r,t=Math.floor(t/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if(typeof t=="bigint")return t=t.toString(16),t.length%2?"0x0"+t:"0x"+t;if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),dS(t))return t.toHexString();if(Pt(t))return t.length%2&&(e.hexPad==="left"?t="0x0"+t.substring(2):e.hexPad==="right"?t+="0":gn.throwArgumentError("hex data is odd-length","value",t)),t.toLowerCase();if(eo(t)){let r="0x";for(let n=0;n<t.length;n++){let i=t[n];r+=c3[(i&240)>>4]+c3[i&15]}return r}return gn.throwArgumentError("invalid hexlify value","value",t)}s(Ve,"hexlify");function Ei(t){if(typeof t!="string")t=Ve(t);else if(!Pt(t)||t.length%2)return null;return(t.length-2)/2}s(Ei,"hexDataLength");function Fr(t,e,r){return typeof t!="string"?t=Ve(t):(!Pt(t)||t.length%2)&&gn.throwArgumentError("invalid hexData","value",t),e=2+2*e,r!=null?"0x"+t.substring(e,2+2*r):"0x"+t.substring(e)}s(Fr,"hexDataSlice");function Mn(t){let e="0x";return t.forEach(r=>{e+=Ve(r).substring(2)}),e}s(Mn,"hexConcat");function ma(t){let e=f3(Ve(t,{hexPad:"left"}));return e==="0x"?"0x0":e}s(ma,"hexValue");function f3(t){typeof t!="string"&&(t=Ve(t)),Pt(t)||gn.throwArgumentError("invalid hex string","value",t),t=t.substring(2);let e=0;for(;e<t.length&&t[e]==="0";)e++;return"0x"+t.substring(e)}s(f3,"hexStripZeros");function ur(t,e){for(typeof t!="string"?t=Ve(t):Pt(t)||gn.throwArgumentError("invalid hex string","value",t),t.length>2*e+2&&gn.throwArgumentError("value out of range","value",arguments[1]);t.length<2*e+2;)t="0x0"+t.substring(2);return t}s(ur,"hexZeroPad");function ga(t){let e={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(pc(t)){let r=je(t);r.length===64?(e.v=27+(r[32]>>7),r[32]&=127,e.r=Ve(r.slice(0,32)),e.s=Ve(r.slice(32,64))):r.length===65?(e.r=Ve(r.slice(0,32)),e.s=Ve(r.slice(32,64)),e.v=r[64]):gn.throwArgumentError("invalid signature string","signature",t),e.v<27&&(e.v===0||e.v===1?e.v+=27:gn.throwArgumentError("signature invalid v byte","signature",t)),e.recoveryParam=1-e.v%2,e.recoveryParam&&(r[32]|=128),e._vs=Ve(r.slice(32,64))}else{if(e.r=t.r,e.s=t.s,e.v=t.v,e.recoveryParam=t.recoveryParam,e._vs=t._vs,e._vs!=null){let i=Sl(je(e._vs),32);e._vs=Ve(i);let o=i[0]>=128?1:0;e.recoveryParam==null?e.recoveryParam=o:e.recoveryParam!==o&&gn.throwArgumentError("signature recoveryParam mismatch _vs","signature",t),i[0]&=127;let a=Ve(i);e.s==null?e.s=a:e.s!==a&&gn.throwArgumentError("signature v mismatch _vs","signature",t)}if(e.recoveryParam==null)e.v==null?gn.throwArgumentError("signature missing v and recoveryParam","signature",t):e.v===0||e.v===1?e.recoveryParam=e.v:e.recoveryParam=1-e.v%2;else if(e.v==null)e.v=27+e.recoveryParam;else{let i=e.v===0||e.v===1?e.v:1-e.v%2;e.recoveryParam!==i&&gn.throwArgumentError("signature recoveryParam mismatch v","signature",t)}e.r==null||!Pt(e.r)?gn.throwArgumentError("signature missing or invalid r","signature",t):e.r=ur(e.r,32),e.s==null||!Pt(e.s)?gn.throwArgumentError("signature missing or invalid s","signature",t):e.s=ur(e.s,32);let r=je(e.s);r[0]>=128&&gn.throwArgumentError("signature s out of range","signature",t),e.recoveryParam&&(r[0]|=128);let n=Ve(r);e._vs&&(Pt(e._vs)||gn.throwArgumentError("signature invalid _vs","signature",t),e._vs=ur(e._vs,32)),e._vs==null?e._vs=n:e._vs!==n&&gn.throwArgumentError("signature _vs mismatch v and s","signature",t)}return e.yParityAndS=e._vs,e.compact=e.r+e.yParityAndS.substring(2),e}s(ga,"splitSignature");function T0(t){return t=ga(t),Ve(sr([t.r,t.s,t.recoveryParam?"0x1c":"0x1b"]))}s(T0,"joinSignature");var Ag="bignumber/5.7.0";var M0=mS.default.BN,mc=new ve(Ag),l3={},hS=9007199254740991;function gS(t){return t!=null&&(ze.isBigNumber(t)||typeof t=="number"&&t%1===0||typeof t=="string"&&!!t.match(/^-?[0-9]+$/)||Pt(t)||typeof t=="bigint"||eo(t))}s(gS,"isBigNumberish");var pS=!1,ze=class{constructor(e,r){e!==l3&&mc.throwError("cannot call constructor directly; use BigNumber.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}fromTwos(e){return as(br(this).fromTwos(e))}toTwos(e){return as(br(this).toTwos(e))}abs(){return this._hex[0]==="-"?ze.from(this._hex.substring(1)):this}add(e){return as(br(this).add(br(e)))}sub(e){return as(br(this).sub(br(e)))}div(e){return ze.from(e).isZero()&&to("division-by-zero","div"),as(br(this).div(br(e)))}mul(e){return as(br(this).mul(br(e)))}mod(e){let r=br(e);return r.isNeg()&&to("division-by-zero","mod"),as(br(this).umod(r))}pow(e){let r=br(e);return r.isNeg()&&to("negative-power","pow"),as(br(this).pow(r))}and(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","and"),as(br(this).and(r))}or(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","or"),as(br(this).or(r))}xor(e){let r=br(e);return(this.isNegative()||r.isNeg())&&to("unbound-bitwise-result","xor"),as(br(this).xor(r))}mask(e){return(this.isNegative()||e<0)&&to("negative-width","mask"),as(br(this).maskn(e))}shl(e){return(this.isNegative()||e<0)&&to("negative-width","shl"),as(br(this).shln(e))}shr(e){return(this.isNegative()||e<0)&&to("negative-width","shr"),as(br(this).shrn(e))}eq(e){return br(this).eq(br(e))}lt(e){return br(this).lt(br(e))}lte(e){return br(this).lte(br(e))}gt(e){return br(this).gt(br(e))}gte(e){return br(this).gte(br(e))}isNegative(){return this._hex[0]==="-"}isZero(){return br(this).isZero()}toNumber(){try{return br(this).toNumber()}catch{to("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch{}return mc.throwError("this platform does not support BigInt",ve.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(arguments[0]===10?pS||(pS=!0,mc.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):arguments[0]===16?mc.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",ve.errors.UNEXPECTED_ARGUMENT,{}):mc.throwError("BigNumber.toString does not accept parameters",ve.errors.UNEXPECTED_ARGUMENT,{})),br(this).toString(10)}toHexString(){return this._hex}toJSON(e){return{type:"BigNumber",hex:this.toHexString()}}static from(e){if(e instanceof ze)return e;if(typeof e=="string")return e.match(/^-?0x[0-9a-f]+$/i)?new ze(l3,R0(e)):e.match(/^-?[0-9]+$/)?new ze(l3,R0(new M0(e))):mc.throwArgumentError("invalid BigNumber string","value",e);if(typeof e=="number")return e%1&&to("underflow","BigNumber.from",e),(e>=hS||e<=-hS)&&to("overflow","BigNumber.from",e),ze.from(String(e));let r=e;if(typeof r=="bigint")return ze.from(r.toString());if(eo(r))return ze.from(Ve(r));if(r)if(r.toHexString){let n=r.toHexString();if(typeof n=="string")return ze.from(n)}else{let n=r._hex;if(n==null&&r.type==="BigNumber"&&(n=r.hex),typeof n=="string"&&(Pt(n)||n[0]==="-"&&Pt(n.substring(1))))return ze.from(n)}return mc.throwArgumentError("invalid BigNumber value","value",e)}static isBigNumber(e){return!!(e&&e._isBigNumber)}};s(ze,"BigNumber");function R0(t){if(typeof t!="string")return R0(t.toString(16));if(t[0]==="-")return t=t.substring(1),t[0]==="-"&&mc.throwArgumentError("invalid hex","value",t),t=R0(t),t==="0x00"?t:"-"+t;if(t.substring(0,2)!=="0x"&&(t="0x"+t),t==="0x")return"0x00";for(t.length%2&&(t="0x0"+t.substring(2));t.length>4&&t.substring(0,4)==="0x00";)t="0x"+t.substring(4);return t}s(R0,"toHex");function as(t){return ze.from(R0(t))}s(as,"toBigNumber");function br(t){let e=ze.from(t).toHexString();return e[0]==="-"?new M0("-"+e.substring(3),16):new M0(e.substring(2),16)}s(br,"toBN");function to(t,e,r){let n={fault:t,operation:e};return r!=null&&(n.value=r),mc.throwError(t,ve.errors.NUMERIC_FAULT,n)}s(to,"throwFault");function u3(t){return new M0(t,36).toString(16)}s(u3,"_base36To16");function d3(t){return new M0(t,16).toString(36)}s(d3,"_base16To36");var Ui=new ve(Ag),B0={},vS=ze.from(0),yS=ze.from(-1);function xS(t,e,r,n){let i={fault:e,operation:r};return n!==void 0&&(i.value=n),Ui.throwError(t,ve.errors.NUMERIC_FAULT,i)}s(xS,"throwFault");var D0="0";for(;D0.length<256;)D0+=D0;function h3(t){if(typeof t!="number")try{t=ze.from(t).toNumber()}catch{}return typeof t=="number"&&t>=0&&t<=256&&!(t%1)?"1"+D0.substring(0,t):Ui.throwArgumentError("invalid decimal size","decimals",t)}s(h3,"getMultiplier");function Hu(t,e){e==null&&(e=0);let r=h3(e);t=ze.from(t);let n=t.lt(vS);n&&(t=t.mul(yS));let i=t.mod(r).toString();for(;i.length<r.length-1;)i="0"+i;i=i.match(/^([0-9]*[1-9]|0)(0*)/)[1];let o=t.div(r).toString();return r.length===1?t=o:t=o+"."+i,n&&(t="-"+t),t}s(Hu,"formatFixed");function ro(t,e){e==null&&(e=0);let r=h3(e);(typeof t!="string"||!t.match(/^-?[0-9.]+$/))&&Ui.throwArgumentError("invalid decimal value","value",t);let n=t.substring(0,1)==="-";n&&(t=t.substring(1)),t==="."&&Ui.throwArgumentError("missing value","value",t);let i=t.split(".");i.length>2&&Ui.throwArgumentError("too many decimal points","value",t);let o=i[0],a=i[1];for(o||(o="0"),a||(a="0");a[a.length-1]==="0";)a=a.substring(0,a.length-1);for(a.length>r.length-1&&xS("fractional component exceeds decimals","underflow","parseFixed"),a===""&&(a="0");a.length<r.length-1;)a+="0";let f=ze.from(o),l=ze.from(a),u=f.mul(r).add(l);return n&&(u=u.mul(yS)),u}s(ro,"parseFixed");var ba=class{constructor(e,r,n,i){e!==B0&&Ui.throwError("cannot use FixedFormat constructor; use FixedFormat.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.signed=r,this.width=n,this.decimals=i,this.name=(r?"":"u")+"fixed"+String(n)+"x"+String(i),this._multiplier=h3(i),Object.freeze(this)}static from(e){if(e instanceof ba)return e;typeof e=="number"&&(e=`fixed128x${e}`);let r=!0,n=128,i=18;if(typeof e=="string"){if(e!=="fixed")if(e==="ufixed")r=!1;else{let o=e.match(/^(u?)fixed([0-9]+)x([0-9]+)$/);o||Ui.throwArgumentError("invalid fixed format","format",e),r=o[1]!=="u",n=parseInt(o[2]),i=parseInt(o[3])}}else if(e){let o=s((a,f,l)=>e[a]==null?l:(typeof e[a]!==f&&Ui.throwArgumentError("invalid fixed format ("+a+" not "+f+")","format."+a,e[a]),e[a]),"check");r=o("signed","boolean",r),n=o("width","number",n),i=o("decimals","number",i)}return n%8&&Ui.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",n),i>80&&Ui.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",i),new ba(B0,r,n,i)}};s(ba,"FixedFormat");var cn=class{constructor(e,r,n,i){e!==B0&&Ui.throwError("cannot use FixedNumber constructor; use FixedNumber.from",ve.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=i,this._hex=r,this._value=n,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(e){this.format.name!==e.format.name&&Ui.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}addUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.add(n),this.format.decimals,this.format)}subUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.sub(n),this.format.decimals,this.format)}mulUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(e){this._checkFormat(e);let r=ro(this._value,this.format.decimals),n=ro(e._value,e.format.decimals);return cn.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}floor(){let e=this.toString().split(".");e.length===1&&e.push("0");let r=cn.from(e[0],this.format),n=!e[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(bS.toFormat(r.format))),r}ceiling(){let e=this.toString().split(".");e.length===1&&e.push("0");let r=cn.from(e[0],this.format),n=!e[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(bS.toFormat(r.format))),r}round(e){e==null&&(e=0);let r=this.toString().split(".");if(r.length===1&&r.push("0"),(e<0||e>80||e%1)&&Ui.throwArgumentError("invalid decimal count","decimals",e),r[1].length<=e)return this;let n=cn.from("1"+D0.substring(0,e),this.format),i=O$.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(i).floor().divUnsafe(n)}isZero(){return this._value==="0.0"||this._value==="0"}isNegative(){return this._value[0]==="-"}toString(){return this._value}toHexString(e){if(e==null)return this._hex;e%8&&Ui.throwArgumentError("invalid byte width","width",e);let r=ze.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return ur(r,e/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(e){return cn.fromString(this._value,e)}static fromValue(e,r,n){return n==null&&r!=null&&!gS(r)&&(n=r,r=null),r==null&&(r=0),n==null&&(n="fixed"),cn.fromString(Hu(e,r),ba.from(n))}static fromString(e,r){r==null&&(r="fixed");let n=ba.from(r),i=ro(e,n.decimals);!n.signed&&i.lt(vS)&&xS("unsigned value cannot be negative","overflow","value",e);let o=null;n.signed?o=i.toTwos(n.width).toHexString():(o=i.toHexString(),o=ur(o,n.width/8));let a=Hu(i,n.decimals);return new cn(B0,o,a,n)}static fromBytes(e,r){r==null&&(r="fixed");let n=ba.from(r);if(je(e).length>n.width/8)throw new Error("overflow");let i=ze.from(e);n.signed&&(i=i.fromTwos(n.width));let o=i.toTwos((n.signed?0:1)+n.width).toHexString(),a=Hu(i,n.decimals);return new cn(B0,o,a,n)}static from(e,r){if(typeof e=="string")return cn.fromString(e,r);if(eo(e))return cn.fromBytes(e,r);try{return cn.fromValue(e,0,r)}catch(n){if(n.code!==ve.errors.INVALID_ARGUMENT)throw n}return Ui.throwArgumentError("invalid FixedNumber value","value",e)}static isFixedNumber(e){return!!(e&&e._isFixedNumber)}};s(cn,"FixedNumber");var bS=cn.from(1),O$=cn.from("0.5");var wS="properties/5.7.0";var F$=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},Eg=new ve(wS);function Pe(t,e,r){Object.defineProperty(t,e,{enumerable:!0,value:r,writable:!1})}s(Pe,"defineReadOnly");function ln(t,e){for(let r=0;r<32;r++){if(t[e])return t[e];if(!t.prototype||typeof t.prototype!="object")break;t=Object.getPrototypeOf(t.prototype).constructor}return null}s(ln,"getStatic");function Nr(t){return F$(this,void 0,void 0,function*(){let e=Object.keys(t).map(n=>{let i=t[n];return Promise.resolve(i).then(o=>({key:n,value:o}))});return(yield Promise.all(e)).reduce((n,i)=>(n[i.key]=i.value,n),{})})}s(Nr,"resolveProperties");function zu(t,e){(!t||typeof t!="object")&&Eg.throwArgumentError("invalid object","object",t),Object.keys(t).forEach(r=>{e[r]||Eg.throwArgumentError("invalid object key - "+r,"transaction:"+r,t)})}s(zu,"checkProperties");function Er(t){let e={};for(let r in t)e[r]=t[r];return e}s(Er,"shallowCopy");var N$={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function _S(t){if(t==null||N$[typeof t])return!0;if(Array.isArray(t)||typeof t=="object"){if(!Object.isFrozen(t))return!1;let e=Object.keys(t);for(let r=0;r<e.length;r++){let n=null;try{n=t[e[r]]}catch{continue}if(!_S(n))return!1}return!0}return Eg.throwArgumentError(`Cannot deepCopy ${typeof t}`,"object",t)}s(_S,"_isFrozen");function L$(t){if(_S(t))return t;if(Array.isArray(t))return Object.freeze(t.map(e=>fn(e)));if(typeof t=="object"){let e={};for(let r in t){let n=t[r];n!==void 0&&Pe(e,r,fn(n))}return e}return Eg.throwArgumentError(`Cannot deepCopy ${typeof t}`,"object",t)}s(L$,"_deepCopy");function fn(t){return L$(t)}s(fn,"deepCopy");var cs=class{constructor(e){for(let r in e)this[r]=fn(e[r])}};s(cs,"Description");var va="abi/5.7.0";var _r=new ve(va),Il={},AS={calldata:!0,memory:!0,storage:!0},U$={calldata:!0,memory:!0};function Cg(t,e){if(t==="bytes"||t==="string"){if(AS[e])return!0}else if(t==="address"){if(e==="payable")return!0}else if((t.indexOf("[")>=0||t==="tuple")&&U$[e])return!0;return(AS[e]||e==="payable")&&_r.throwArgumentError("invalid modifier","name",e),!1}s(Cg,"checkModifier");function j$(t,e){let r=t;function n(f){_r.throwArgumentError(`unexpected character at position ${f}`,"param",t)}s(n,"throwError"),t=t.replace(/\s/g," ");function i(f){let l={type:"",name:"",parent:f,state:{allowType:!0}};return e&&(l.indexed=!1),l}s(i,"newNode");let o={type:"",name:"",state:{allowType:!0}},a=o;for(let f=0;f<t.length;f++){let l=t[f];switch(l){case"(":a.state.allowType&&a.type===""?a.type="tuple":a.state.allowParams||n(f),a.state.allowType=!1,a.type=$u(a.type),a.components=[i(a)],a=a.components[0];break;case")":delete a.state,a.name==="indexed"&&(e||n(f),a.indexed=!0,a.name=""),Cg(a.type,a.name)&&(a.name=""),a.type=$u(a.type);let u=a;a=a.parent,a||n(f),delete u.parent,a.state.allowParams=!1,a.state.allowName=!0,a.state.allowArray=!0;break;case",":delete a.state,a.name==="indexed"&&(e||n(f),a.indexed=!0,a.name=""),Cg(a.type,a.name)&&(a.name=""),a.type=$u(a.type);let h=i(a.parent);a.parent.components.push(h),delete a.parent,a=h;break;case" ":a.state.allowType&&a.type!==""&&(a.type=$u(a.type),delete a.state.allowType,a.state.allowName=!0,a.state.allowParams=!0),a.state.allowName&&a.name!==""&&(a.name==="indexed"?(e||n(f),a.indexed&&n(f),a.indexed=!0,a.name=""):Cg(a.type,a.name)?a.name="":a.state.allowName=!1);break;case"[":a.state.allowArray||n(f),a.type+=l,a.state.allowArray=!1,a.state.allowName=!1,a.state.readArray=!0;break;case"]":a.state.readArray||n(f),a.type+=l,a.state.readArray=!1,a.state.allowArray=!0,a.state.allowName=!0;break;default:a.state.allowType?(a.type+=l,a.state.allowParams=!0,a.state.allowArray=!0):a.state.allowName?(a.name+=l,delete a.state.allowArray):a.state.readArray?a.type+=l:n(f)}}return a.parent&&_r.throwArgumentError("unexpected eof","param",t),delete o.state,a.name==="indexed"?(e||n(r.length-7),a.indexed&&n(r.length-7),a.indexed=!0,a.name=""):Cg(a.type,a.name)&&(a.name=""),o.type=$u(o.type),o}s(j$,"parseParamType");function Sg(t,e){for(let r in e)Pe(t,r,e[r])}s(Sg,"populate");var vr=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),q$=new RegExp(/^(.*)\[([0-9]*)\]$/),Yr=class{constructor(e,r){e!==Il&&_r.throwError("use fromString",ve.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),Sg(this,r);let n=this.type.match(q$);n?Sg(this,{arrayLength:parseInt(n[2]||"-1"),arrayChildren:Yr.fromObject({type:n[1],components:this.components}),baseType:"array"}):Sg(this,{arrayLength:null,arrayChildren:null,baseType:this.components!=null?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json){let n={type:this.baseType==="tuple"?"tuple":this.type,name:this.name||void 0};return typeof this.indexed=="boolean"&&(n.indexed=this.indexed),this.components&&(n.components=this.components.map(i=>JSON.parse(i.format(e)))),JSON.stringify(n)}let r="";return this.baseType==="array"?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):this.baseType==="tuple"?(e!==vr.sighash&&(r+=this.type),r+="("+this.components.map(n=>n.format(e)).join(e===vr.full?", ":",")+")"):r+=this.type,e!==vr.sighash&&(this.indexed===!0&&(r+=" indexed"),e===vr.full&&this.name&&(r+=" "+this.name)),r}static from(e,r){return typeof e=="string"?Yr.fromString(e,r):Yr.fromObject(e)}static fromObject(e){return Yr.isParamType(e)?e:new Yr(Il,{name:e.name||null,type:$u(e.type),indexed:e.indexed==null?null:!!e.indexed,components:e.components?e.components.map(Yr.fromObject):null})}static fromString(e,r){function n(i){return Yr.fromObject({name:i.name,type:i.type,indexed:i.indexed,components:i.components})}return s(n,"ParamTypify"),n(j$(e,!!r))}static isParamType(e){return!!(e!=null&&e._isParamType)}};s(Yr,"ParamType");function P0(t,e){return z$(t).map(r=>Yr.fromString(r,e))}s(P0,"parseParams");var Si=class{constructor(e,r){e!==Il&&_r.throwError("use a static from method",ve.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),Sg(this,r),this._isFragment=!0,Object.freeze(this)}static from(e){return Si.isFragment(e)?e:typeof e=="string"?Si.fromString(e):Si.fromObject(e)}static fromObject(e){if(Si.isFragment(e))return e;switch(e.type){case"function":return ri.fromObject(e);case"event":return Ci.fromObject(e);case"constructor":return ti.fromObject(e);case"error":return fs.fromObject(e);case"fallback":case"receive":return null}return _r.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return e=e.replace(/\s/g," "),e=e.replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," "),e=e.trim(),e.split(" ")[0]==="event"?Ci.fromString(e.substring(5).trim()):e.split(" ")[0]==="function"?ri.fromString(e.substring(8).trim()):e.split("(")[0].trim()==="constructor"?ti.fromString(e.trim()):e.split(" ")[0]==="error"?fs.fromString(e.substring(5).trim()):_r.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!!(e&&e._isFragment)}};s(Si,"Fragment");var Ci=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="event "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",e!==vr.sighash&&this.anonymous&&(r+="anonymous "),r.trim()}static from(e){return typeof e=="string"?Ci.fromString(e):Ci.fromObject(e)}static fromObject(e){if(Ci.isEventFragment(e))return e;e.type!=="event"&&_r.throwArgumentError("invalid event object","value",e);let r={name:O0(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],type:"event"};return new Ci(Il,r)}static fromString(e){let r=e.match(F0);r||_r.throwArgumentError("invalid event string","value",e);let n=!1;return r[3].split(" ").forEach(i=>{switch(i.trim()){case"anonymous":n=!0;break;case"":break;default:_r.warn("unknown modifier: "+i)}}),Ci.fromObject({name:r[1].trim(),anonymous:n,inputs:P0(r[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&e.type==="event"}};s(Ci,"EventFragment");function CS(t,e){e.gas=null;let r=t.split("@");return r.length!==1?(r.length>2&&_r.throwArgumentError("invalid human-readable ABI signature","value",t),r[1].match(/^[0-9]+$/)||_r.throwArgumentError("invalid human-readable ABI signature gas","value",t),e.gas=ze.from(r[1]),r[0]):t}s(CS,"parseGas");function SS(t,e){e.constant=!1,e.payable=!1,e.stateMutability="nonpayable",t.split(" ").forEach(r=>{switch(r.trim()){case"constant":e.constant=!0;break;case"payable":e.payable=!0,e.stateMutability="payable";break;case"nonpayable":e.payable=!1,e.stateMutability="nonpayable";break;case"pure":e.constant=!0,e.stateMutability="pure";break;case"view":e.constant=!0,e.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+r)}})}s(SS,"parseModifiers");function IS(t){let e={constant:!1,payable:!0,stateMutability:"payable"};return t.stateMutability!=null?(e.stateMutability=t.stateMutability,e.constant=e.stateMutability==="view"||e.stateMutability==="pure",t.constant!=null&&!!t.constant!==e.constant&&_r.throwArgumentError("cannot have constant function with mutability "+e.stateMutability,"value",t),e.payable=e.stateMutability==="payable",t.payable!=null&&!!t.payable!==e.payable&&_r.throwArgumentError("cannot have payable function with mutability "+e.stateMutability,"value",t)):t.payable!=null?(e.payable=!!t.payable,t.constant==null&&!e.payable&&t.type!=="constructor"&&_r.throwArgumentError("unable to determine stateMutability","value",t),e.constant=!!t.constant,e.constant?e.stateMutability="view":e.stateMutability=e.payable?"payable":"nonpayable",e.payable&&e.constant&&_r.throwArgumentError("cannot have constant payable function","value",t)):t.constant!=null?(e.constant=!!t.constant,e.payable=!e.constant,e.stateMutability=e.constant?"view":"payable"):t.type!=="constructor"&&_r.throwArgumentError("unable to determine stateMutability","value",t),e}s(IS,"verifyState");var ti=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"constructor",stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});e===vr.sighash&&_r.throwError("cannot format a constructor for sighash",ve.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let r="constructor("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ";return this.stateMutability&&this.stateMutability!=="nonpayable"&&(r+=this.stateMutability+" "),r.trim()}static from(e){return typeof e=="string"?ti.fromString(e):ti.fromObject(e)}static fromObject(e){if(ti.isConstructorFragment(e))return e;e.type!=="constructor"&&_r.throwArgumentError("invalid constructor object","value",e);let r=IS(e);r.constant&&_r.throwArgumentError("constructor cannot be constant","value",e);let n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],payable:r.payable,stateMutability:r.stateMutability,gas:e.gas?ze.from(e.gas):null};return new ti(Il,n)}static fromString(e){let r={type:"constructor"};e=CS(e,r);let n=e.match(F0);return(!n||n[1].trim()!=="constructor")&&_r.throwArgumentError("invalid constructor string","value",e),r.inputs=P0(n[2].trim(),!1),SS(n[3].trim(),r),ti.fromObject(r)}static isConstructorFragment(e){return e&&e._isFragment&&e.type==="constructor"}};s(ti,"ConstructorFragment");var ri=class extends ti{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map(n=>JSON.parse(n.format(e))),outputs:this.outputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="function "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",e!==vr.sighash&&(this.stateMutability?this.stateMutability!=="nonpayable"&&(r+=this.stateMutability+" "):this.constant&&(r+="view "),this.outputs&&this.outputs.length&&(r+="returns ("+this.outputs.map(n=>n.format(e)).join(", ")+") "),this.gas!=null&&(r+="@"+this.gas.toString()+" ")),r.trim()}static from(e){return typeof e=="string"?ri.fromString(e):ri.fromObject(e)}static fromObject(e){if(ri.isFunctionFragment(e))return e;e.type!=="function"&&_r.throwArgumentError("invalid function object","value",e);let r=IS(e),n={type:e.type,name:O0(e.name),constant:r.constant,inputs:e.inputs?e.inputs.map(Yr.fromObject):[],outputs:e.outputs?e.outputs.map(Yr.fromObject):[],payable:r.payable,stateMutability:r.stateMutability,gas:e.gas?ze.from(e.gas):null};return new ri(Il,n)}static fromString(e){let r={type:"function"};e=CS(e,r);let n=e.split(" returns ");n.length>2&&_r.throwArgumentError("invalid function string","value",e);let i=n[0].match(F0);if(i||_r.throwArgumentError("invalid function signature","value",e),r.name=i[1].trim(),r.name&&O0(r.name),r.inputs=P0(i[2],!1),SS(i[3].trim(),r),n.length>1){let o=n[1].match(F0);(o[1].trim()!=""||o[3].trim()!="")&&_r.throwArgumentError("unexpected tokens","value",e),r.outputs=P0(o[2],!1)}else r.outputs=[];return ri.fromObject(r)}static isFunctionFragment(e){return e&&e._isFragment&&e.type==="function"}};s(ri,"FunctionFragment");function ES(t){let e=t.format();return(e==="Error(string)"||e==="Panic(uint256)")&&_r.throwArgumentError(`cannot specify user defined ${e} error`,"fragment",t),t}s(ES,"checkForbidden");var fs=class extends Si{format(e){if(e||(e=vr.sighash),vr[e]||_r.throwArgumentError("invalid format type","format",e),e===vr.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});let r="";return e!==vr.sighash&&(r+="error "),r+=this.name+"("+this.inputs.map(n=>n.format(e)).join(e===vr.full?", ":",")+") ",r.trim()}static from(e){return typeof e=="string"?fs.fromString(e):fs.fromObject(e)}static fromObject(e){if(fs.isErrorFragment(e))return e;e.type!=="error"&&_r.throwArgumentError("invalid error object","value",e);let r={type:e.type,name:O0(e.name),inputs:e.inputs?e.inputs.map(Yr.fromObject):[]};return ES(new fs(Il,r))}static fromString(e){let r={type:"error"},n=e.match(F0);return n||_r.throwArgumentError("invalid error signature","value",e),r.name=n[1].trim(),r.name&&O0(r.name),r.inputs=P0(n[2],!1),ES(fs.fromObject(r))}static isErrorFragment(e){return e&&e._isFragment&&e.type==="error"}};s(fs,"ErrorFragment");function $u(t){return t.match(/^uint($|[^1-9])/)?t="uint256"+t.substring(4):t.match(/^int($|[^1-9])/)&&(t="int256"+t.substring(3)),t}s($u,"verifyType");var H$=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function O0(t){return(!t||!t.match(H$))&&_r.throwArgumentError(`invalid identifier "${t}"`,"value",t),t}s(O0,"verifyIdentifier");var F0=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");function z$(t){t=t.trim();let e=[],r="",n=0;for(let i=0;i<t.length;i++){let o=t[i];o===","&&n===0?(e.push(r),r=""):(r+=o,o==="("?n++:o===")"&&(n--,n===-1&&_r.throwArgumentError("unbalanced parenthesis","value",t)))}return r&&e.push(r),e}s(z$,"splitNesting");var p3=new ve(va);function Gu(t){let e=[],r=s(function(n,i){if(!!Array.isArray(i))for(let o in i){let a=n.slice();a.push(o);try{r(a,i[o])}catch(f){e.push({path:a,error:f})}}},"checkErrors");return r([],t),e}s(Gu,"checkResultErrors");var An=class{constructor(e,r,n,i){this.name=e,this.type=r,this.localName=n,this.dynamic=i}_throwError(e,r){p3.throwArgumentError(e,this.localName,r)}};s(An,"Coder");var yf=class{constructor(e){Pe(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return Mn(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(sr(e._data))}writeBytes(e){let r=je(e),n=r.length%this.wordSize;return n&&(r=sr([r,this._padding.slice(n)])),this._writeData(r)}_getValue(e){let r=je(ze.from(e));return r.length>this.wordSize&&p3.throwError("value out-of-bounds",ve.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:r.length}),r.length%this.wordSize&&(r=sr([this._padding.slice(r.length%this.wordSize),r])),r}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){let e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,r=>{this._data[e]=this._getValue(r)}}};s(yf,"Writer");var xf=class{constructor(e,r,n,i){Pe(this,"_data",je(e)),Pe(this,"wordSize",r||32),Pe(this,"_coerceFunc",n),Pe(this,"allowLoose",i),this._offset=0}get data(){return Ve(this._data)}get consumed(){return this._offset}static coerce(e,r){let n=e.match("^u?int([0-9]+)$");return n&&parseInt(n[1])<=48&&(r=r.toNumber()),r}coerce(e,r){return this._coerceFunc?this._coerceFunc(e,r):xf.coerce(e,r)}_peekBytes(e,r,n){let i=Math.ceil(r/this.wordSize)*this.wordSize;return this._offset+i>this._data.length&&(this.allowLoose&&n&&this._offset+r<=this._data.length?i=r:p3.throwError("data out-of-bounds",ve.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+i})),this._data.slice(this._offset,this._offset+i)}subReader(e){return new xf(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,r){let n=this._peekBytes(0,e,!!r);return this._offset+=n.length,n.slice(0,e)}readValue(){return ze.from(this.readBytes(this.wordSize))}};s(xf,"Reader");var TS=Js(kS());function or(t){return"0x"+TS.default.keccak_256(je(t))}s(or,"keccak256");var kg={};vl(kg,{decode:()=>N0,encode:()=>gc});var MS="rlp/5.7.0";var ya=new ve(MS);function RS(t){let e=[];for(;t;)e.unshift(t&255),t>>=8;return e}s(RS,"arrayifyInteger");function BS(t,e,r){let n=0;for(let i=0;i<r;i++)n=n*256+t[e+i];return n}s(BS,"unarrayifyInteger");function PS(t){if(Array.isArray(t)){let n=[];if(t.forEach(function(o){n=n.concat(PS(o))}),n.length<=55)return n.unshift(192+n.length),n;let i=RS(n.length);return i.unshift(247+i.length),i.concat(n)}pc(t)||ya.throwArgumentError("RLP object must be BytesLike","object",t);let e=Array.prototype.slice.call(je(t));if(e.length===1&&e[0]<=127)return e;if(e.length<=55)return e.unshift(128+e.length),e;let r=RS(e.length);return r.unshift(183+r.length),r.concat(e)}s(PS,"_encode");function gc(t){return Ve(PS(t))}s(gc,"encode");function DS(t,e,r,n){let i=[];for(;r<e+1+n;){let o=OS(t,r);i.push(o.result),r+=o.consumed,r>e+1+n&&ya.throwError("child data too short",ve.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:i}}s(DS,"_decodeChildren");function OS(t,e){if(t.length===0&&ya.throwError("data too short",ve.errors.BUFFER_OVERRUN,{}),t[e]>=248){let r=t[e]-247;e+1+r>t.length&&ya.throwError("data short segment too short",ve.errors.BUFFER_OVERRUN,{});let n=BS(t,e+1,r);return e+1+r+n>t.length&&ya.throwError("data long segment too short",ve.errors.BUFFER_OVERRUN,{}),DS(t,e,e+1+r,r+n)}else if(t[e]>=192){let r=t[e]-192;return e+1+r>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{}),DS(t,e,e+1,r)}else if(t[e]>=184){let r=t[e]-183;e+1+r>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{});let n=BS(t,e+1,r);e+1+r+n>t.length&&ya.throwError("data array too short",ve.errors.BUFFER_OVERRUN,{});let i=Ve(t.slice(e+1+r,e+1+r+n));return{consumed:1+r+n,result:i}}else if(t[e]>=128){let r=t[e]-128;e+1+r>t.length&&ya.throwError("data too short",ve.errors.BUFFER_OVERRUN,{});let n=Ve(t.slice(e+1,e+1+r));return{consumed:1+r,result:n}}return{consumed:1,result:Ve(t[e])}}s(OS,"_decode");function N0(t){let e=je(t),r=OS(e,0);return r.consumed!==e.length&&ya.throwArgumentError("invalid rlp data","data",t),r.result}s(N0,"decode");var FS="address/5.7.0";var wf=new ve(FS);function NS(t){Pt(t,20)||wf.throwArgumentError("invalid address","address",t),t=t.toLowerCase();let e=t.substring(2).split(""),r=new Uint8Array(40);for(let i=0;i<40;i++)r[i]=e[i].charCodeAt(0);let n=je(or(r));for(let i=0;i<40;i+=2)n[i>>1]>>4>=8&&(e[i]=e[i].toUpperCase()),(n[i>>1]&15)>=8&&(e[i+1]=e[i+1].toUpperCase());return"0x"+e.join("")}s(NS,"getChecksumAddress");var $$=9007199254740991;function G$(t){return Math.log10?Math.log10(t):Math.log(t)/Math.LN10}s(G$,"log10");var m3={};for(let t=0;t<10;t++)m3[String(t)]=String(t);for(let t=0;t<26;t++)m3[String.fromCharCode(65+t)]=String(10+t);var LS=Math.floor(G$($$));function US(t){t=t.toUpperCase(),t=t.substring(4)+t.substring(0,2)+"00";let e=t.split("").map(n=>m3[n]).join("");for(;e.length>=LS;){let n=e.substring(0,LS);e=parseInt(n,10)%97+e.substring(n.length)}let r=String(98-parseInt(e,10)%97);for(;r.length<2;)r="0"+r;return r}s(US,"ibanChecksum");function ar(t){let e=null;if(typeof t!="string"&&wf.throwArgumentError("invalid address","address",t),t.match(/^(0x)?[0-9a-fA-F]{40}$/))t.substring(0,2)!=="0x"&&(t="0x"+t),e=NS(t),t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&e!==t&&wf.throwArgumentError("bad address checksum","address",t);else if(t.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(t.substring(2,4)!==US(t)&&wf.throwArgumentError("bad icap checksum","address",t),e=u3(t.substring(4));e.length<40;)e="0"+e;e=NS("0x"+e)}else wf.throwArgumentError("invalid address","address",t);return e}s(ar,"getAddress");function jS(t){try{return ar(t),!0}catch{}return!1}s(jS,"isAddress");function qS(t){let e=d3(ar(t).substring(2)).toUpperCase();for(;e.length<30;)e="0"+e;return"XE"+US("XE00"+e)+e}s(qS,"getIcapAddress");function kl(t){let e=null;try{e=ar(t.from)}catch{wf.throwArgumentError("missing from address","transaction",t)}let r=Ts(je(ze.from(t.nonce).toHexString()));return ar(Fr(or(gc([e,r])),12))}s(kl,"getContractAddress");function HS(t,e,r){return Ei(e)!==32&&wf.throwArgumentError("salt must be 32 bytes","salt",e),Ei(r)!==32&&wf.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),ar(Fr(or(sr(["0xff",ar(t),e,r])),12))}s(HS,"getCreate2Address");var L0=class extends An{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,r){try{r=ar(r)}catch(n){this._throwError(n.message,r)}return e.writeValue(r)}decode(e){return ar(ur(e.readValue().toHexString(),20))}};s(L0,"AddressCoder");var U0=class extends An{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,r){return this.coder.encode(e,r)}decode(e){return this.coder.decode(e)}};s(U0,"AnonymousCoder");var Ku=new ve(va);function g3(t,e,r){let n=null;if(Array.isArray(r))n=r;else if(r&&typeof r=="object"){let l={};n=e.map(u=>{let h=u.localName;return h||Ku.throwError("cannot encode object for signature with missing names",ve.errors.INVALID_ARGUMENT,{argument:"values",coder:u,value:r}),l[h]&&Ku.throwError("cannot encode object for signature with duplicate names",ve.errors.INVALID_ARGUMENT,{argument:"values",coder:u,value:r}),l[h]=!0,r[h]})}else Ku.throwArgumentError("invalid tuple value","tuple",r);e.length!==n.length&&Ku.throwArgumentError("types/value length mismatch","tuple",r);let i=new yf(t.wordSize),o=new yf(t.wordSize),a=[];e.forEach((l,u)=>{let h=n[u];if(l.dynamic){let g=o.length;l.encode(o,h);let x=i.writeUpdatableValue();a.push(_=>{x(_+g)})}else l.encode(i,h)}),a.forEach(l=>{l(i.length)});let f=t.appendWriter(i);return f+=t.appendWriter(o),f}s(g3,"pack");function b3(t,e){let r=[],n=t.subReader(0);e.forEach(o=>{let a=null;if(o.dynamic){let f=t.readValue(),l=n.subReader(f.toNumber());try{a=o.decode(l)}catch(u){if(u.code===ve.errors.BUFFER_OVERRUN)throw u;a=u,a.baseType=o.name,a.name=o.localName,a.type=o.type}}else try{a=o.decode(t)}catch(f){if(f.code===ve.errors.BUFFER_OVERRUN)throw f;a=f,a.baseType=o.name,a.name=o.localName,a.type=o.type}a!=null&&r.push(a)});let i=e.reduce((o,a)=>{let f=a.localName;return f&&(o[f]||(o[f]=0),o[f]++),o},{});e.forEach((o,a)=>{let f=o.localName;if(!f||i[f]!==1||(f==="length"&&(f="_length"),r[f]!=null))return;let l=r[a];l instanceof Error?Object.defineProperty(r,f,{enumerable:!0,get:()=>{throw l}}):r[f]=l});for(let o=0;o<r.length;o++){let a=r[o];a instanceof Error&&Object.defineProperty(r,o,{enumerable:!0,get:()=>{throw a}})}return Object.freeze(r)}s(b3,"unpack");var j0=class extends An{constructor(e,r,n){let i=e.type+"["+(r>=0?r:"")+"]",o=r===-1||e.dynamic;super("array",i,n,o),this.coder=e,this.length=r}defaultValue(){let e=this.coder.defaultValue(),r=[];for(let n=0;n<this.length;n++)r.push(e);return r}encode(e,r){Array.isArray(r)||this._throwError("expected array value",r);let n=this.length;n===-1&&(n=r.length,e.writeValue(r.length)),Ku.checkArgumentCount(r.length,n,"coder array"+(this.localName?" "+this.localName:""));let i=[];for(let o=0;o<r.length;o++)i.push(this.coder);return g3(e,i,r)}decode(e){let r=this.length;r===-1&&(r=e.readValue().toNumber(),r*32>e._data.length&&Ku.throwError("insufficient data length",ve.errors.BUFFER_OVERRUN,{length:e._data.length,count:r}));let n=[];for(let i=0;i<r;i++)n.push(new U0(this.coder));return e.coerce(this.name,b3(e,n))}};s(j0,"ArrayCoder");var q0=class extends An{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,r){return e.writeValue(r?1:0)}decode(e){return e.coerce(this.type,!e.readValue().isZero())}};s(q0,"BooleanCoder");var Vu=class extends An{constructor(e,r){super(e,e,r,!0)}defaultValue(){return"0x"}encode(e,r){r=je(r);let n=e.writeValue(r.length);return n+=e.writeBytes(r),n}decode(e){return e.readBytes(e.readValue().toNumber(),!0)}};s(Vu,"DynamicBytesCoder");var H0=class extends Vu{constructor(e){super("bytes",e)}decode(e){return e.coerce(this.name,Ve(super.decode(e)))}};s(H0,"BytesCoder");var z0=class extends An{constructor(e,r){let n="bytes"+String(e);super(n,n,r,!1),this.size=e}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+this.size*2)}encode(e,r){let n=je(r);return n.length!==this.size&&this._throwError("incorrect data length",r),e.writeBytes(n)}decode(e){return e.coerce(this.name,Ve(e.readBytes(this.size)))}};s(z0,"FixedBytesCoder");var $0=class extends An{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,r){return r!=null&&this._throwError("not null",r),e.writeBytes([])}decode(e){return e.readBytes(0),e.coerce(this.name,null)}};s($0,"NullCoder");var v3={};vl(v3,{AddressZero:()=>Tg,EtherSymbol:()=>VS,HashZero:()=>Ju,MaxInt256:()=>KS,MaxUint256:()=>Bg,MinInt256:()=>GS,NegativeOne:()=>Mg,One:()=>Rg,Two:()=>zS,WeiPerEther:()=>$S,Zero:()=>Wu});var Tg="0x0000000000000000000000000000000000000000";var Mg=ze.from(-1),Wu=ze.from(0),Rg=ze.from(1),zS=ze.from(2),$S=ze.from("1000000000000000000"),Bg=ze.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),GS=ze.from("-0x8000000000000000000000000000000000000000000000000000000000000000"),KS=ze.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");var Ju="0x0000000000000000000000000000000000000000000000000000000000000000";var VS="\u039E";var G0=class extends An{constructor(e,r,n){let i=(r?"int":"uint")+e*8;super(i,i,n,!1),this.size=e,this.signed=r}defaultValue(){return 0}encode(e,r){let n=ze.from(r),i=Bg.mask(e.wordSize*8);if(this.signed){let o=i.mask(this.size*8-1);(n.gt(o)||n.lt(o.add(Rg).mul(Mg)))&&this._throwError("value out-of-bounds",r)}else(n.lt(Wu)||n.gt(i.mask(this.size*8)))&&this._throwError("value out-of-bounds",r);return n=n.toTwos(this.size*8).mask(this.size*8),this.signed&&(n=n.fromTwos(this.size*8).toTwos(8*e.wordSize)),e.writeValue(n)}decode(e){let r=e.readValue().mask(this.size*8);return this.signed&&(r=r.fromTwos(this.size*8)),e.coerce(this.name,r)}};s(G0,"NumberCoder");var WS="strings/5.7.0";var JS=new ve(WS),ji;(function(t){t.current="",t.NFC="NFC",t.NFD="NFD",t.NFKC="NFKC",t.NFKD="NFKD"})(ji||(ji={}));var Ii;(function(t){t.UNEXPECTED_CONTINUE="unexpected continuation byte",t.BAD_PREFIX="bad codepoint prefix",t.OVERRUN="string overrun",t.MISSING_CONTINUE="missing continuation byte",t.OUT_OF_RANGE="out of UTF-8 range",t.UTF16_SURROGATE="UTF-16 surrogate",t.OVERLONG="overlong representation"})(Ii||(Ii={}));function K$(t,e,r,n,i){return JS.throwArgumentError(`invalid codepoint at offset ${e}; ${t}`,"bytes",r)}s(K$,"errorFunc");function YS(t,e,r,n,i){if(t===Ii.BAD_PREFIX||t===Ii.UNEXPECTED_CONTINUE){let o=0;for(let a=e+1;a<r.length&&r[a]>>6===2;a++)o++;return o}return t===Ii.OVERRUN?r.length-e-1:0}s(YS,"ignoreFunc");function V$(t,e,r,n,i){return t===Ii.OVERLONG?(n.push(i),0):(n.push(65533),YS(t,e,r,n,i))}s(V$,"replaceFunc");var Dg=Object.freeze({error:K$,ignore:YS,replace:V$});function x3(t,e){e==null&&(e=Dg.error),t=je(t);let r=[],n=0;for(;n<t.length;){let i=t[n++];if(i>>7===0){r.push(i);continue}let o=null,a=null;if((i&224)===192)o=1,a=127;else if((i&240)===224)o=2,a=2047;else if((i&248)===240)o=3,a=65535;else{(i&192)===128?n+=e(Ii.UNEXPECTED_CONTINUE,n-1,t,r):n+=e(Ii.BAD_PREFIX,n-1,t,r);continue}if(n-1+o>=t.length){n+=e(Ii.OVERRUN,n-1,t,r);continue}let f=i&(1<<8-o-1)-1;for(let l=0;l<o;l++){let u=t[n];if((u&192)!=128){n+=e(Ii.MISSING_CONTINUE,n,t,r),f=null;break}f=f<<6|u&63,n++}if(f!==null){if(f>1114111){n+=e(Ii.OUT_OF_RANGE,n-1-o,t,r,f);continue}if(f>=55296&&f<=57343){n+=e(Ii.UTF16_SURROGATE,n-1-o,t,r,f);continue}if(f<=a){n+=e(Ii.OVERLONG,n-1-o,t,r,f);continue}r.push(f)}}return r}s(x3,"getUtf8CodePoints");function Ar(t,e=ji.current){e!=ji.current&&(JS.checkNormalize(),t=t.normalize(e));let r=[];for(let n=0;n<t.length;n++){let i=t.charCodeAt(n);if(i<128)r.push(i);else if(i<2048)r.push(i>>6|192),r.push(i&63|128);else if((i&64512)==55296){n++;let o=t.charCodeAt(n);if(n>=t.length||(o&64512)!==56320)throw new Error("invalid utf-8 string");let a=65536+((i&1023)<<10)+(o&1023);r.push(a>>18|240),r.push(a>>12&63|128),r.push(a>>6&63|128),r.push(a&63|128)}else r.push(i>>12|224),r.push(i>>6&63|128),r.push(i&63|128)}return je(r)}s(Ar,"toUtf8Bytes");function y3(t){let e="0000"+t.toString(16);return"\\u"+e.substring(e.length-4)}s(y3,"escapeChar");function w3(t,e){return'"'+x3(t,e).map(r=>{if(r<256){switch(r){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(r>=32&&r<127)return String.fromCharCode(r)}return r<=65535?y3(r):(r-=65536,y3((r>>10&1023)+55296)+y3((r&1023)+56320))}).join("")+'"'}s(w3,"_toEscapedUtf8String");function Pg(t){return t.map(e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode((e>>10&1023)+55296,(e&1023)+56320))).join("")}s(Pg,"_toUtf8String");function ls(t,e){return Pg(x3(t,e))}s(ls,"toUtf8String");function _f(t,e=ji.current){return x3(Ar(t,e))}s(_f,"toUtf8CodePoints");function _3(t){let e=Ar(t);if(e.length>31)throw new Error("bytes32 string must be less than 32 bytes");return Ve(sr([e,Ju]).slice(0,32))}s(_3,"formatBytes32String");function A3(t){let e=je(t);if(e.length!==32)throw new Error("invalid bytes32 - not 32 bytes long");if(e[31]!==0)throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;e[r-1]===0;)r--;return ls(e.slice(0,r))}s(A3,"parseBytes32String");function W$(t){if(t.length%4!==0)throw new Error("bad data");let e=[];for(let r=0;r<t.length;r+=4)e.push(parseInt(t.substring(r,r+4),16));return e}s(W$,"bytes2");function E3(t,e){e||(e=s(function(i){return[parseInt(i,16)]},"func"));let r=0,n={};return t.split(",").forEach(i=>{let o=i.split(":");r+=parseInt(o[0],16),n[r]=e(o[1])}),n}s(E3,"createTable");function ZS(t){let e=0;return t.split(",").map(r=>{let n=r.split("-");n.length===1?n[1]="0":n[1]===""&&(n[1]="1");let i=e+parseInt(n[0],16);return e=parseInt(n[1],16),{l:i,h:e}})}s(ZS,"createRangeTable");function C3(t,e){let r=0;for(let n=0;n<e.length;n++){let i=e[n];if(r+=i.l,t>=r&&t<=r+i.h&&(t-r)%(i.d||1)===0){if(i.e&&i.e.indexOf(t-r)!==-1)continue;return i}}return null}s(C3,"matchMap");var J$=ZS("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),Y$="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map(t=>parseInt(t,16)),Z$=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],X$=E3("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),Q$=E3("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),eG=E3("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",W$),tG=ZS("80-20,2a0-,39c,32,f71,18e,7f2-f,19-7,30-4,7-5,f81-b,5,a800-20ff,4d1-1f,110,fa-6,d174-7,2e84-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,ffff-,2,1f-5f,ff7f-20001");function rG(t){return t.reduce((e,r)=>(r.forEach(n=>{e.push(n)}),e),[])}s(rG,"flatten");function nG(t){return!!C3(t,J$)}s(nG,"_nameprepTableA1");function iG(t){let e=C3(t,Z$);if(e)return[t+e.s];let r=X$[t];if(r)return r;let n=Q$[t];if(n)return[t+n[0]];let i=eG[t];return i||null}s(iG,"_nameprepTableB2");function sG(t){return!!C3(t,tG)}s(sG,"_nameprepTableC");function S3(t){if(t.match(/^[a-z0-9-]*$/i)&&t.length<=59)return t.toLowerCase();let e=_f(t);e=rG(e.map(n=>{if(Y$.indexOf(n)>=0)return[];if(n>=65024&&n<=65039)return[];let i=iG(n);return i||[n]})),e=_f(Pg(e),ji.NFKC),e.forEach(n=>{if(sG(n))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")}),e.forEach(n=>{if(nG(n))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")});let r=Pg(e);if(r.substring(0,1)==="-"||r.substring(2,4)==="--"||r.substring(r.length-1)==="-")throw new Error("invalid hyphen");return r}s(S3,"nameprep");var K0=class extends Vu{constructor(e){super("string",e)}defaultValue(){return""}encode(e,r){return super.encode(e,Ar(r))}decode(e){return ls(super.decode(e))}};s(K0,"StringCoder");var Af=class extends An{constructor(e,r){let n=!1,i=[];e.forEach(a=>{a.dynamic&&(n=!0),i.push(a.type)});let o="tuple("+i.join(",")+")";super("tuple",o,r,n),this.coders=e}defaultValue(){let e=[];this.coders.forEach(n=>{e.push(n.defaultValue())});let r=this.coders.reduce((n,i)=>{let o=i.localName;return o&&(n[o]||(n[o]=0),n[o]++),n},{});return this.coders.forEach((n,i)=>{let o=n.localName;!o||r[o]!==1||(o==="length"&&(o="_length"),e[o]==null&&(e[o]=e[i]))}),Object.freeze(e)}encode(e,r){return g3(e,this.coders,r)}decode(e){return e.coerce(this.name,b3(e,this.coders))}};s(Af,"TupleCoder");var Og=new ve(va),oG=new RegExp(/^bytes([0-9]*)$/),aG=new RegExp(/^(u?int)([0-9]*)$/),Tl=class{constructor(e){Pe(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new L0(e.name);case"bool":return new q0(e.name);case"string":return new K0(e.name);case"bytes":return new H0(e.name);case"array":return new j0(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new Af((e.components||[]).map(n=>this._getCoder(n)),e.name);case"":return new $0(e.name)}let r=e.type.match(aG);if(r){let n=parseInt(r[2]||"256");return(n===0||n>256||n%8!==0)&&Og.throwArgumentError("invalid "+r[1]+" bit length","param",e),new G0(n/8,r[1]==="int",e.name)}if(r=e.type.match(oG),r){let n=parseInt(r[1]);return(n===0||n>32)&&Og.throwArgumentError("invalid bytes length","param",e),new z0(n,e.name)}return Og.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,r){return new xf(e,this._getWordSize(),this.coerceFunc,r)}_getWriter(){return new yf(this._getWordSize())}getDefaultValue(e){let r=e.map(i=>this._getCoder(Yr.from(i)));return new Af(r,"_").defaultValue()}encode(e,r){e.length!==r.length&&Og.throwError("types/values length mismatch",ve.errors.INVALID_ARGUMENT,{count:{types:e.length,values:r.length},value:{types:e,values:r}});let n=e.map(a=>this._getCoder(Yr.from(a))),i=new Af(n,"_"),o=this._getWriter();return i.encode(o,r),o.data}decode(e,r,n){let i=e.map(a=>this._getCoder(Yr.from(a)));return new Af(i,"_").decode(this._getReader(je(r),n))}};s(Tl,"AbiCoder");var V0=new Tl;function Ms(t){return or(Ar(t))}s(Ms,"id");var Fg="hash/5.7.0";var I3={};vl(I3,{decode:()=>Yu,encode:()=>Zu});function Yu(t){t=atob(t);let e=[];for(let r=0;r<t.length;r++)e.push(t.charCodeAt(r));return je(e)}s(Yu,"decode");function Zu(t){t=je(t);let e="";for(let r=0;r<t.length;r++)e+=String.fromCharCode(t[r]);return btoa(e)}s(Zu,"encode");function QS(t,e){e==null&&(e=1);let r=[],n=r.forEach,i=s(function(o,a){n.call(o,function(f){a>0&&Array.isArray(f)?i(f,a-1):r.push(f)})},"flatDeep");return i(t,e),r}s(QS,"flat");function cG(t){let e={};for(let r=0;r<t.length;r++){let n=t[r];e[n[0]]=n[1]}return e}s(cG,"fromEntries");function fG(t){let e=0;function r(){return t[e++]<<8|t[e++]}s(r,"u16");let n=r(),i=1,o=[0,1];for(let K=1;K<n;K++)o.push(i+=r());let a=r(),f=e;e+=a;let l=0,u=0;function h(){return l==0&&(u=u<<8|t[e++],l=8),u>>--l&1}s(h,"read_bit");let g=31,x=Math.pow(2,g),_=x>>>1,E=_>>1,T=x-1,B=0;for(let K=0;K<g;K++)B=B<<1|h();let F=[],H=0,U=x;for(;;){let K=Math.floor(((B-H+1)*i-1)/U),W=0,N=n;for(;N-W>1;){let re=W+N>>>1;K<o[re]?N=re:W=re}if(W==0)break;F.push(W);let G=H+Math.floor(U*o[W]/i),ce=H+Math.floor(U*o[W+1]/i)-1;for(;((G^ce)&_)==0;)B=B<<1&T|h(),G=G<<1&T,ce=ce<<1&T|1;for(;G&~ce&E;)B=B&_|B<<1&T>>>1|h(),G=G<<1^_,ce=(ce^_)<<1|_|1;H=G,U=1+ce-G}let q=n-4;return F.map(K=>{switch(K-q){case 3:return q+65792+(t[f++]<<16|t[f++]<<8|t[f++]);case 2:return q+256+(t[f++]<<8|t[f++]);case 1:return q+t[f++];default:return K-1}})}s(fG,"decode_arithmetic");function lG(t){let e=0;return()=>t[e++]}s(lG,"read_payload");function eI(t){return lG(fG(t))}s(eI,"read_compressed_payload");function uG(t){return t&1?~t>>1:t>>1}s(uG,"signed");function dG(t,e){let r=Array(t);for(let n=0;n<t;n++)r[n]=1+e();return r}s(dG,"read_counts");function XS(t,e){let r=Array(t);for(let n=0,i=-1;n<t;n++)r[n]=i+=1+e();return r}s(XS,"read_ascending");function hG(t,e){let r=Array(t);for(let n=0,i=0;n<t;n++)r[n]=i+=uG(e());return r}s(hG,"read_deltas");function W0(t,e){let r=XS(t(),t),n=t(),i=XS(n,t),o=dG(n,t);for(let a=0;a<n;a++)for(let f=0;f<o[a];f++)r.push(i[a]+f);return e?r.map(a=>e[a]):r}s(W0,"read_member_array");function tI(t){let e=[];for(;;){let r=t();if(r==0)break;e.push(mG(r,t))}for(;;){let r=t()-1;if(r<0)break;e.push(gG(r,t))}return cG(QS(e))}s(tI,"read_mapped_map");function pG(t){let e=[];for(;;){let r=t();if(r==0)break;e.push(r)}return e}s(pG,"read_zero_terminated_array");function rI(t,e,r){let n=Array(t).fill(void 0).map(()=>[]);for(let i=0;i<e;i++)hG(t,r).forEach((o,a)=>n[a].push(o));return n}s(rI,"read_transposed");function mG(t,e){let r=1+e(),n=e(),i=pG(e),o=rI(i.length,1+t,e);return QS(o.map((a,f)=>{let l=a[0],u=a.slice(1);return Array(i[f]).fill(void 0).map((h,g)=>{let x=g*n;return[l+g*r,u.map(_=>_+x)]})}))}s(mG,"read_linear_table");function gG(t,e){let r=1+e();return rI(r,1+t,e).map(i=>[i[0],i.slice(1)])}s(gG,"read_replacement_table");function nI(t){let e=W0(t).sort((n,i)=>n-i);return r();function r(){let n=[];for(;;){let u=W0(t,e);if(u.length==0)break;n.push({set:new Set(u),node:r()})}n.sort((u,h)=>h.set.size-u.set.size);let i=t(),o=i%3;i=i/3|0;let a=!!(i&1);i>>=1;let f=i==1,l=i==2;return{branches:n,valid:o,fe0f:a,save:f,check:l}}}s(nI,"read_emoji_trie");function iI(){return eI(Yu("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA=="))}s(iI,"getData");var Ng=iI(),bG=new Set(W0(Ng)),vG=new Set(W0(Ng)),yG=tI(Ng),xG=nI(Ng),sI=45,oI=95;function aI(t){return _f(t)}s(aI,"explode_cp");function wG(t){return t.filter(e=>e!=65039)}s(wG,"filter_fe0f");function cI(t){for(let e of t.split(".")){let r=aI(e);try{for(let n=r.lastIndexOf(oI)-1;n>=0;n--)if(r[n]!==oI)throw new Error("underscore only allowed at start");if(r.length>=4&&r.every(n=>n<128)&&r[2]===sI&&r[3]===sI)throw new Error("invalid label extension")}catch(n){throw new Error(`Invalid label "${e}": ${n.message}`)}}return t}s(cI,"ens_normalize_post_check");function fI(t){return cI(_G(t,wG))}s(fI,"ens_normalize");function _G(t,e){let r=aI(t).reverse(),n=[];for(;r.length;){let i=EG(r);if(i){n.push(...e(i));continue}let o=r.pop();if(bG.has(o)){n.push(o);continue}if(vG.has(o))continue;let a=yG[o];if(a){n.push(...a);continue}throw new Error(`Disallowed codepoint: 0x${o.toString(16).toUpperCase()}`)}return cI(AG(String.fromCodePoint(...n)))}s(_G,"normalize");function AG(t){return t.normalize("NFC")}s(AG,"nfc");function EG(t,e){var r;let n=xG,i,o,a=[],f=t.length;for(e&&(e.length=0);f;){let l=t[--f];if(n=(r=n.branches.find(u=>u.set.has(l)))===null||r===void 0?void 0:r.node,!n)break;if(n.save)o=l;else if(n.check&&l===o)break;a.push(l),n.fe0f&&(a.push(65039),f>0&&t[f-1]==65039&&f--),n.valid&&(i=a.slice(),n.valid==2&&i.splice(1,1),e&&e.push(...t.slice(f).reverse()),t.length=f)}return i}s(EG,"consume_emoji_reversed");var CG=new ve(Fg),uI=new Uint8Array(32);uI.fill(0);function lI(t){if(t.length===0)throw new Error("invalid ENS name; empty component");return t}s(lI,"checkComponent");function k3(t){let e=Ar(fI(t)),r=[];if(t.length===0)return r;let n=0;for(let i=0;i<e.length;i++)e[i]===46&&(r.push(lI(e.slice(n,i))),n=i+1);if(n>=e.length)throw new Error("invalid ENS name; empty component");return r.push(lI(e.slice(n))),r}s(k3,"ensNameSplit");function T3(t){try{return k3(t).length!==0}catch{}return!1}s(T3,"isValidName");function Ef(t){typeof t!="string"&&CG.throwArgumentError("invalid ENS name; not a string","name",t);let e=uI,r=k3(t);for(;r.length;)e=or(sr([e,or(r.pop())]));return Ve(e)}s(Ef,"namehash");function J0(t){return Ve(sr(k3(t).map(e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");let r=new Uint8Array(e.length+1);return r.set(e,1),r[0]=r.length-1,r})))+"00"}s(J0,"dnsEncode");var dI=`Ethereum Signed Message:
|
|
2
2
|
`;function Xu(t){return typeof t=="string"&&(t=Ar(t)),or(sr([Ar(dI),Ar(String(t.length)),t]))}s(Xu,"hashMessage");var SG=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},un=new ve(Fg),gI=new Uint8Array(32);gI.fill(0);var IG=ze.from(-1),bI=ze.from(0),vI=ze.from(1),kG=ze.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function TG(t){let e=je(t),r=e.length%32;return r?Mn([e,gI.slice(r)]):Ve(e)}s(TG,"hexPadRight");var MG=ur(vI.toHexString(),32),RG=ur(bI.toHexString(),32),hI={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},M3=["name","version","chainId","verifyingContract","salt"];function pI(t){return function(e){return typeof e!="string"&&un.throwArgumentError(`invalid domain value for ${JSON.stringify(t)}`,`domain.${t}`,e),e}}s(pI,"checkString");var BG={name:pI("name"),version:pI("version"),chainId:function(t){try{return ze.from(t).toString()}catch{}return un.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",t)},verifyingContract:function(t){try{return ar(t).toLowerCase()}catch{}return un.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",t)},salt:function(t){try{let e=je(t);if(e.length!==32)throw new Error("bad length");return Ve(e)}catch{}return un.throwArgumentError('invalid domain value "salt"',"domain.salt",t)}};function R3(t){{let e=t.match(/^(u?)int(\d*)$/);if(e){let r=e[1]==="",n=parseInt(e[2]||"256");(n%8!==0||n>256||e[2]&&e[2]!==String(n))&&un.throwArgumentError("invalid numeric width","type",t);let i=kG.mask(r?n-1:n),o=r?i.add(vI).mul(IG):bI;return function(a){let f=ze.from(a);return(f.lt(o)||f.gt(i))&&un.throwArgumentError(`value out-of-bounds for ${t}`,"value",a),ur(f.toTwos(256).toHexString(),32)}}}{let e=t.match(/^bytes(\d+)$/);if(e){let r=parseInt(e[1]);return(r===0||r>32||e[1]!==String(r))&&un.throwArgumentError("invalid bytes width","type",t),function(n){return je(n).length!==r&&un.throwArgumentError(`invalid length for ${t}`,"value",n),TG(n)}}}switch(t){case"address":return function(e){return ur(ar(e),32)};case"bool":return function(e){return e?MG:RG};case"bytes":return function(e){return or(e)};case"string":return function(e){return Ms(e)}}return null}s(R3,"getBaseEncoder");function mI(t,e){return`${t}(${e.map(({name:r,type:n})=>n+" "+r).join(",")})`}s(mI,"encodeType");var nn=class{constructor(e){Pe(this,"types",Object.freeze(fn(e))),Pe(this,"_encoderCache",{}),Pe(this,"_types",{});let r={},n={},i={};Object.keys(e).forEach(f=>{r[f]={},n[f]=[],i[f]={}});for(let f in e){let l={};e[f].forEach(u=>{l[u.name]&&un.throwArgumentError(`duplicate variable name ${JSON.stringify(u.name)} in ${JSON.stringify(f)}`,"types",e),l[u.name]=!0;let h=u.type.match(/^([^\x5b]*)(\x5b|$)/)[1];h===f&&un.throwArgumentError(`circular type reference to ${JSON.stringify(h)}`,"types",e),!R3(h)&&(n[h]||un.throwArgumentError(`unknown type ${JSON.stringify(h)}`,"types",e),n[h].push(f),r[f][h]=!0)})}let o=Object.keys(n).filter(f=>n[f].length===0);o.length===0?un.throwArgumentError("missing primary type","types",e):o.length>1&&un.throwArgumentError(`ambiguous primary types or unused types: ${o.map(f=>JSON.stringify(f)).join(", ")}`,"types",e),Pe(this,"primaryType",o[0]);function a(f,l){l[f]&&un.throwArgumentError(`circular type reference to ${JSON.stringify(f)}`,"types",e),l[f]=!0,Object.keys(r[f]).forEach(u=>{!n[u]||(a(u,l),Object.keys(l).forEach(h=>{i[h][u]=!0}))}),delete l[f]}s(a,"checkCircular"),a(this.primaryType,{});for(let f in i){let l=Object.keys(i[f]);l.sort(),this._types[f]=mI(f,e[f])+l.map(u=>mI(u,e[u])).join("")}}getEncoder(e){let r=this._encoderCache[e];return r||(r=this._encoderCache[e]=this._getEncoder(e)),r}_getEncoder(e){{let i=R3(e);if(i)return i}let r=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(r){let i=r[1],o=this.getEncoder(i),a=parseInt(r[3]);return f=>{a>=0&&f.length!==a&&un.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",f);let l=f.map(o);return this._types[i]&&(l=l.map(or)),or(Mn(l))}}let n=this.types[e];if(n){let i=Ms(this._types[e]);return o=>{let a=n.map(({name:f,type:l})=>{let u=this.getEncoder(l)(o[f]);return this._types[l]?or(u):u});return a.unshift(i),Mn(a)}}return un.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){let r=this._types[e];return r||un.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),r}encodeData(e,r){return this.getEncoder(e)(r)}hashStruct(e,r){return or(this.encodeData(e,r))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,r,n){if(R3(e))return n(e,r);let i=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(i){let a=i[1],f=parseInt(i[3]);return f>=0&&r.length!==f&&un.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",r),r.map(l=>this._visit(a,l,n))}let o=this.types[e];return o?o.reduce((a,{name:f,type:l})=>(a[f]=this._visit(l,r[f],n),a),{}):un.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,r){return this._visit(this.primaryType,e,r)}static from(e){return new nn(e)}static getPrimaryType(e){return nn.from(e).primaryType}static hashStruct(e,r,n){return nn.from(r).hashStruct(e,n)}static hashDomain(e){let r=[];for(let n in e){let i=hI[n];i||un.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(n)}`,"domain",e),r.push({name:n,type:i})}return r.sort((n,i)=>M3.indexOf(n.name)-M3.indexOf(i.name)),nn.hashStruct("EIP712Domain",{EIP712Domain:r},e)}static encode(e,r,n){return Mn(["0x1901",nn.hashDomain(e),nn.from(r).hash(n)])}static hash(e,r,n){return or(nn.encode(e,r,n))}static resolveNames(e,r,n,i){return SG(this,void 0,void 0,function*(){e=Er(e);let o={};e.verifyingContract&&!Pt(e.verifyingContract,20)&&(o[e.verifyingContract]="0x");let a=nn.from(r);a.visit(n,(f,l)=>(f==="address"&&!Pt(l,20)&&(o[l]="0x"),l));for(let f in o)o[f]=yield i(f);return e.verifyingContract&&o[e.verifyingContract]&&(e.verifyingContract=o[e.verifyingContract]),n=a.visit(n,(f,l)=>f==="address"&&o[l]?o[l]:l),{domain:e,value:n}})}static getPayload(e,r,n){nn.hashDomain(e);let i={},o=[];M3.forEach(l=>{let u=e[l];u!=null&&(i[l]=BG[l](u),o.push({name:l,type:hI[l]}))});let a=nn.from(r),f=Er(r);return f.EIP712Domain?un.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):f.EIP712Domain=o,a.encode(n),{types:f,domain:i,primaryType:a.primaryType,message:a.visit(n,(l,u)=>{if(l.match(/^bytes(\d*)/))return Ve(je(u));if(l.match(/^u?int/))return ze.from(u).toString();switch(l){case"address":return u.toLowerCase();case"bool":return!!u;case"string":return typeof u!="string"&&un.throwArgumentError("invalid string","value",u),u}return un.throwArgumentError("unsupported type","type",l)})}}};s(nn,"TypedDataEncoder");var dn=new ve(va);var Ml=class extends cs{};s(Ml,"LogDescription");var Rl=class extends cs{};s(Rl,"TransactionDescription");var Lg=class extends cs{};s(Lg,"ErrorDescription");var xa=class extends cs{static isIndexed(e){return!!(e&&e._isIndexed)}};s(xa,"Indexed");var DG={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function yI(t,e){let r=new Error(`deferred error during ABI decoding triggered accessing ${t}`);return r.error=e,r}s(yI,"wrapAccessError");var bc=class{constructor(e){let r=[];typeof e=="string"?r=JSON.parse(e):r=e,Pe(this,"fragments",r.map(n=>Si.from(n)).filter(n=>n!=null)),Pe(this,"_abiCoder",ln(new.target,"getAbiCoder")()),Pe(this,"functions",{}),Pe(this,"errors",{}),Pe(this,"events",{}),Pe(this,"structs",{}),this.fragments.forEach(n=>{let i=null;switch(n.type){case"constructor":if(this.deploy){dn.warn("duplicate definition - constructor");return}Pe(this,"deploy",n);return;case"function":i=this.functions;break;case"event":i=this.events;break;case"error":i=this.errors;break;default:return}let o=n.format();if(i[o]){dn.warn("duplicate definition - "+o);return}i[o]=n}),this.deploy||Pe(this,"deploy",ti.from({payable:!1,type:"constructor"})),Pe(this,"_isInterface",!0)}format(e){e||(e=vr.full),e===vr.sighash&&dn.throwArgumentError("interface does not support formatting sighash","format",e);let r=this.fragments.map(n=>n.format(e));return e===vr.json?JSON.stringify(r.map(n=>JSON.parse(n))):r}static getAbiCoder(){return V0}static getAddress(e){return ar(e)}static getSighash(e){return Fr(Ms(e.format()),0,4)}static getEventTopic(e){return Ms(e.format())}getFunction(e){if(Pt(e)){for(let n in this.functions)if(e===this.getSighash(n))return this.functions[n];dn.throwArgumentError("no matching function","sighash",e)}if(e.indexOf("(")===-1){let n=e.trim(),i=Object.keys(this.functions).filter(o=>o.split("(")[0]===n);return i.length===0?dn.throwArgumentError("no matching function","name",n):i.length>1&&dn.throwArgumentError("multiple matching functions","name",n),this.functions[i[0]]}let r=this.functions[ri.fromString(e).format()];return r||dn.throwArgumentError("no matching function","signature",e),r}getEvent(e){if(Pt(e)){let n=e.toLowerCase();for(let i in this.events)if(n===this.getEventTopic(i))return this.events[i];dn.throwArgumentError("no matching event","topichash",n)}if(e.indexOf("(")===-1){let n=e.trim(),i=Object.keys(this.events).filter(o=>o.split("(")[0]===n);return i.length===0?dn.throwArgumentError("no matching event","name",n):i.length>1&&dn.throwArgumentError("multiple matching events","name",n),this.events[i[0]]}let r=this.events[Ci.fromString(e).format()];return r||dn.throwArgumentError("no matching event","signature",e),r}getError(e){if(Pt(e)){let n=ln(this.constructor,"getSighash");for(let i in this.errors){let o=this.errors[i];if(e===n(o))return this.errors[i]}dn.throwArgumentError("no matching error","sighash",e)}if(e.indexOf("(")===-1){let n=e.trim(),i=Object.keys(this.errors).filter(o=>o.split("(")[0]===n);return i.length===0?dn.throwArgumentError("no matching error","name",n):i.length>1&&dn.throwArgumentError("multiple matching errors","name",n),this.errors[i[0]]}let r=this.errors[ri.fromString(e).format()];return r||dn.throwArgumentError("no matching error","signature",e),r}getSighash(e){if(typeof e=="string")try{e=this.getFunction(e)}catch(r){try{e=this.getError(e)}catch{throw r}}return ln(this.constructor,"getSighash")(e)}getEventTopic(e){return typeof e=="string"&&(e=this.getEvent(e)),ln(this.constructor,"getEventTopic")(e)}_decodeParams(e,r){return this._abiCoder.decode(e,r)}_encodeParams(e,r){return this._abiCoder.encode(e,r)}encodeDeploy(e){return this._encodeParams(this.deploy.inputs,e||[])}decodeErrorResult(e,r){typeof e=="string"&&(e=this.getError(e));let n=je(r);return Ve(n.slice(0,4))!==this.getSighash(e)&&dn.throwArgumentError(`data signature does not match error ${e.name}.`,"data",Ve(n)),this._decodeParams(e.inputs,n.slice(4))}encodeErrorResult(e,r){return typeof e=="string"&&(e=this.getError(e)),Ve(sr([this.getSighash(e),this._encodeParams(e.inputs,r||[])]))}decodeFunctionData(e,r){typeof e=="string"&&(e=this.getFunction(e));let n=je(r);return Ve(n.slice(0,4))!==this.getSighash(e)&&dn.throwArgumentError(`data signature does not match function ${e.name}.`,"data",Ve(n)),this._decodeParams(e.inputs,n.slice(4))}encodeFunctionData(e,r){return typeof e=="string"&&(e=this.getFunction(e)),Ve(sr([this.getSighash(e),this._encodeParams(e.inputs,r||[])]))}decodeFunctionResult(e,r){typeof e=="string"&&(e=this.getFunction(e));let n=je(r),i=null,o="",a=null,f=null,l=null;switch(n.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,n)}catch{}break;case 4:{let u=Ve(n.slice(0,4)),h=DG[u];if(h)a=this._abiCoder.decode(h.inputs,n.slice(4)),f=h.name,l=h.signature,h.reason&&(i=a[0]),f==="Error"?o=`; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(a[0])}`:f==="Panic"&&(o=`; VM Exception while processing transaction: reverted with panic code ${a[0]}`);else try{let g=this.getError(u);a=this._abiCoder.decode(g.inputs,n.slice(4)),f=g.name,l=g.format()}catch{}break}}return dn.throwError("call revert exception"+o,ve.errors.CALL_EXCEPTION,{method:e.format(),data:Ve(r),errorArgs:a,errorName:f,errorSignature:l,reason:i})}encodeFunctionResult(e,r){return typeof e=="string"&&(e=this.getFunction(e)),Ve(this._abiCoder.encode(e.outputs,r||[]))}encodeFilterTopics(e,r){typeof e=="string"&&(e=this.getEvent(e)),r.length>e.inputs.length&&dn.throwError("too many arguments for "+e.format(),ve.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:r});let n=[];e.anonymous||n.push(this.getEventTopic(e));let i=s((o,a)=>o.type==="string"?Ms(a):o.type==="bytes"?or(Ve(a)):(o.type==="bool"&&typeof a=="boolean"&&(a=a?"0x01":"0x00"),o.type.match(/^u?int/)&&(a=ze.from(a).toHexString()),o.type==="address"&&this._abiCoder.encode(["address"],[a]),ur(Ve(a),32)),"encodeTopic");for(r.forEach((o,a)=>{let f=e.inputs[a];if(!f.indexed){o!=null&&dn.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+f.name,o);return}o==null?n.push(null):f.baseType==="array"||f.baseType==="tuple"?dn.throwArgumentError("filtering with tuples or arrays not supported","contract."+f.name,o):Array.isArray(o)?n.push(o.map(l=>i(f,l))):n.push(i(f,o))});n.length&&n[n.length-1]===null;)n.pop();return n}encodeEventLog(e,r){typeof e=="string"&&(e=this.getEvent(e));let n=[],i=[],o=[];return e.anonymous||n.push(this.getEventTopic(e)),r.length!==e.inputs.length&&dn.throwArgumentError("event arguments/values mismatch","values",r),e.inputs.forEach((a,f)=>{let l=r[f];if(a.indexed)if(a.type==="string")n.push(Ms(l));else if(a.type==="bytes")n.push(or(l));else{if(a.baseType==="tuple"||a.baseType==="array")throw new Error("not implemented");n.push(this._abiCoder.encode([a.type],[l]))}else i.push(a),o.push(l)}),{data:this._abiCoder.encode(i,o),topics:n}}decodeEventLog(e,r,n){if(typeof e=="string"&&(e=this.getEvent(e)),n!=null&&!e.anonymous){let x=this.getEventTopic(e);(!Pt(n[0],32)||n[0].toLowerCase()!==x)&&dn.throwError("fragment/topic mismatch",ve.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:x,value:n[0]}),n=n.slice(1)}let i=[],o=[],a=[];e.inputs.forEach((x,_)=>{x.indexed?x.type==="string"||x.type==="bytes"||x.baseType==="tuple"||x.baseType==="array"?(i.push(Yr.fromObject({type:"bytes32",name:x.name})),a.push(!0)):(i.push(x),a.push(!1)):(o.push(x),a.push(!1))});let f=n!=null?this._abiCoder.decode(i,sr(n)):null,l=this._abiCoder.decode(o,r,!0),u=[],h=0,g=0;e.inputs.forEach((x,_)=>{if(x.indexed)if(f==null)u[_]=new xa({_isIndexed:!0,hash:null});else if(a[_])u[_]=new xa({_isIndexed:!0,hash:f[g++]});else try{u[_]=f[g++]}catch(E){u[_]=E}else try{u[_]=l[h++]}catch(E){u[_]=E}if(x.name&&u[x.name]==null){let E=u[_];E instanceof Error?Object.defineProperty(u,x.name,{enumerable:!0,get:()=>{throw yI(`property ${JSON.stringify(x.name)}`,E)}}):u[x.name]=E}});for(let x=0;x<u.length;x++){let _=u[x];_ instanceof Error&&Object.defineProperty(u,x,{enumerable:!0,get:()=>{throw yI(`index ${x}`,_)}})}return Object.freeze(u)}parseTransaction(e){let r=this.getFunction(e.data.substring(0,10).toLowerCase());return r?new Rl({args:this._abiCoder.decode(r.inputs,"0x"+e.data.substring(10)),functionFragment:r,name:r.name,signature:r.format(),sighash:this.getSighash(r),value:ze.from(e.value||"0")}):null}parseLog(e){let r=this.getEvent(e.topics[0]);return!r||r.anonymous?null:new Ml({eventFragment:r,name:r.name,signature:r.format(),topic:this.getEventTopic(r),args:this.decodeEventLog(r,e.data,e.topics)})}parseError(e){let r=Ve(e),n=this.getError(r.substring(0,10).toLowerCase());return n?new Lg({args:this._abiCoder.decode(n.inputs,"0x"+r.substring(10)),errorFragment:n,name:n.name,signature:n.format(),sighash:this.getSighash(n)}):null}static isInterface(e){return!!(e&&e._isInterface)}};s(bc,"Interface");var xI="abstract-provider/5.7.0";var PG=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},OG=new ve(xI),Y0=class extends cs{static isForkEvent(e){return!!(e&&e._isForkEvent)}};s(Y0,"ForkEvent");var qi=class{constructor(){OG.checkAbstract(new.target,qi),Pe(this,"_isProvider",!0)}getFeeData(){return PG(this,void 0,void 0,function*(){let{block:e,gasPrice:r}=yield Nr({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch(a=>null)}),n=null,i=null,o=null;return e&&e.baseFeePerGas&&(n=e.baseFeePerGas,o=ze.from("1500000000"),i=e.baseFeePerGas.mul(2).add(o)),{lastBaseFeePerGas:n,maxFeePerGas:i,maxPriorityFeePerGas:o,gasPrice:r}})}addListener(e,r){return this.on(e,r)}removeListener(e,r){return this.off(e,r)}static isProvider(e){return!!(e&&e._isProvider)}};s(qi,"Provider");var wI="abstract-signer/5.7.0";var So=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},no=new ve(wI),FG=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],NG=[ve.errors.INSUFFICIENT_FUNDS,ve.errors.NONCE_EXPIRED,ve.errors.REPLACEMENT_UNDERPRICED],Hi=class{constructor(){no.checkAbstract(new.target,Hi),Pe(this,"_isSigner",!0)}getBalance(e){return So(this,void 0,void 0,function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)})}getTransactionCount(e){return So(this,void 0,void 0,function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)})}estimateGas(e){return So(this,void 0,void 0,function*(){this._checkProvider("estimateGas");let r=yield Nr(this.checkTransaction(e));return yield this.provider.estimateGas(r)})}call(e,r){return So(this,void 0,void 0,function*(){this._checkProvider("call");let n=yield Nr(this.checkTransaction(e));return yield this.provider.call(n,r)})}sendTransaction(e){return So(this,void 0,void 0,function*(){this._checkProvider("sendTransaction");let r=yield this.populateTransaction(e),n=yield this.signTransaction(r);return yield this.provider.sendTransaction(n)})}getChainId(){return So(this,void 0,void 0,function*(){return this._checkProvider("getChainId"),(yield this.provider.getNetwork()).chainId})}getGasPrice(){return So(this,void 0,void 0,function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()})}getFeeData(){return So(this,void 0,void 0,function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()})}resolveName(e){return So(this,void 0,void 0,function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)})}checkTransaction(e){for(let n in e)FG.indexOf(n)===-1&&no.throwArgumentError("invalid transaction key: "+n,"transaction",e);let r=Er(e);return r.from==null?r.from=this.getAddress():r.from=Promise.all([Promise.resolve(r.from),this.getAddress()]).then(n=>(n[0].toLowerCase()!==n[1].toLowerCase()&&no.throwArgumentError("from address mismatch","transaction",e),n[0])),r}populateTransaction(e){return So(this,void 0,void 0,function*(){let r=yield Nr(this.checkTransaction(e));r.to!=null&&(r.to=Promise.resolve(r.to).then(i=>So(this,void 0,void 0,function*(){if(i==null)return null;let o=yield this.resolveName(i);return o==null&&no.throwArgumentError("provided ENS name resolves to null","tx.to",i),o})),r.to.catch(i=>{}));let n=r.maxFeePerGas!=null||r.maxPriorityFeePerGas!=null;if(r.gasPrice!=null&&(r.type===2||n)?no.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e):(r.type===0||r.type===1)&&n&&no.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e),(r.type===2||r.type==null)&&r.maxFeePerGas!=null&&r.maxPriorityFeePerGas!=null)r.type=2;else if(r.type===0||r.type===1)r.gasPrice==null&&(r.gasPrice=this.getGasPrice());else{let i=yield this.getFeeData();if(r.type==null)if(i.maxFeePerGas!=null&&i.maxPriorityFeePerGas!=null)if(r.type=2,r.gasPrice!=null){let o=r.gasPrice;delete r.gasPrice,r.maxFeePerGas=o,r.maxPriorityFeePerGas=o}else r.maxFeePerGas==null&&(r.maxFeePerGas=i.maxFeePerGas),r.maxPriorityFeePerGas==null&&(r.maxPriorityFeePerGas=i.maxPriorityFeePerGas);else i.gasPrice!=null?(n&&no.throwError("network does not support EIP-1559",ve.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),r.gasPrice==null&&(r.gasPrice=i.gasPrice),r.type=0):no.throwError("failed to get consistent fee data",ve.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else r.type===2&&(r.maxFeePerGas==null&&(r.maxFeePerGas=i.maxFeePerGas),r.maxPriorityFeePerGas==null&&(r.maxPriorityFeePerGas=i.maxPriorityFeePerGas))}return r.nonce==null&&(r.nonce=this.getTransactionCount("pending")),r.gasLimit==null&&(r.gasLimit=this.estimateGas(r).catch(i=>{if(NG.indexOf(i.code)>=0)throw i;return no.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ve.errors.UNPREDICTABLE_GAS_LIMIT,{error:i,tx:r})})),r.chainId==null?r.chainId=this.getChainId():r.chainId=Promise.all([Promise.resolve(r.chainId),this.getChainId()]).then(i=>(i[1]!==0&&i[0]!==i[1]&&no.throwArgumentError("chainId address mismatch","transaction",e),i[0])),yield Nr(r)})}_checkProvider(e){this.provider||no.throwError("missing provider",ve.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!!(e&&e._isSigner)}};s(Hi,"Signer");var vc=class extends Hi{constructor(e,r){super(),Pe(this,"address",e),Pe(this,"provider",r||null)}getAddress(){return Promise.resolve(this.address)}_fail(e,r){return Promise.resolve().then(()=>{no.throwError(e,ve.errors.UNSUPPORTED_OPERATION,{operation:r})})}signMessage(e){return this._fail("VoidSigner cannot sign messages","signMessage")}signTransaction(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}_signTypedData(e,r,n){return this._fail("VoidSigner cannot sign typed data","signTypedData")}connect(e){return new vc(this.address,e)}};s(vc,"VoidSigner");var Jt=Js(s3()),Ia=Js(q3());function od(t,e,r){return r={path:e,exports:{},require:function(n,i){return oV(n,i??r.path)}},t(r,r.exports),r.exports}s(od,"createCommonjsModule");function oV(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}s(oV,"commonjsRequire");var G3=sk;function sk(t,e){if(!t)throw new Error(e||"Assertion failed")}s(sk,"assert");sk.equal=s(function(e,r,n){if(e!=r)throw new Error(n||"Assertion failed: "+e+" != "+r)},"assertEqual");var Mo=od(function(t,e){"use strict";var r=e;function n(a,f){if(Array.isArray(a))return a.slice();if(!a)return[];var l=[];if(typeof a!="string"){for(var u=0;u<a.length;u++)l[u]=a[u]|0;return l}if(f==="hex"){a=a.replace(/[^a-z0-9]+/ig,""),a.length%2!==0&&(a="0"+a);for(var u=0;u<a.length;u+=2)l.push(parseInt(a[u]+a[u+1],16))}else for(var u=0;u<a.length;u++){var h=a.charCodeAt(u),g=h>>8,x=h&255;g?l.push(g,x):l.push(x)}return l}s(n,"toArray"),r.toArray=n;function i(a){return a.length===1?"0"+a:a}s(i,"zero2"),r.zero2=i;function o(a){for(var f="",l=0;l<a.length;l++)f+=i(a[l].toString(16));return f}s(o,"toHex"),r.toHex=o,r.encode=s(function(f,l){return l==="hex"?o(f):f},"encode")}),Rs=od(function(t,e){"use strict";var r=e;r.assert=G3,r.toArray=Mo.toArray,r.zero2=Mo.zero2,r.toHex=Mo.toHex,r.encode=Mo.encode;function n(l,u,h){var g=new Array(Math.max(l.bitLength(),h)+1);g.fill(0);for(var x=1<<u+1,_=l.clone(),E=0;E<g.length;E++){var T,B=_.andln(x-1);_.isOdd()?(B>(x>>1)-1?T=(x>>1)-B:T=B,_.isubn(T)):T=0,g[E]=T,_.iushrn(1)}return g}s(n,"getNAF"),r.getNAF=n;function i(l,u){var h=[[],[]];l=l.clone(),u=u.clone();for(var g=0,x=0,_;l.cmpn(-g)>0||u.cmpn(-x)>0;){var E=l.andln(3)+g&3,T=u.andln(3)+x&3;E===3&&(E=-1),T===3&&(T=-1);var B;(E&1)===0?B=0:(_=l.andln(7)+g&7,(_===3||_===5)&&T===2?B=-E:B=E),h[0].push(B);var F;(T&1)===0?F=0:(_=u.andln(7)+x&7,(_===3||_===5)&&E===2?F=-T:F=T),h[1].push(F),2*g===B+1&&(g=1-g),2*x===F+1&&(x=1-x),l.iushrn(1),u.iushrn(1)}return h}s(i,"getJSF"),r.getJSF=i;function o(l,u,h){var g="_"+u;l.prototype[u]=s(function(){return this[g]!==void 0?this[g]:this[g]=h.call(this)},"cachedProperty")}s(o,"cachedProperty"),r.cachedProperty=o;function a(l){return typeof l=="string"?r.toArray(l,"hex"):l}s(a,"parseBytes"),r.parseBytes=a;function f(l){return new Jt.default(l,"hex","le")}s(f,"intFromLE"),r.intFromLE=f}),zg=Rs.getNAF,aV=Rs.getJSF,$g=Rs.assert;function If(t,e){this.type=t,this.p=new Jt.default(e.p,16),this.red=e.prime?Jt.default.red(e.prime):Jt.default.mont(this.p),this.zero=new Jt.default(0).toRed(this.red),this.one=new Jt.default(1).toRed(this.red),this.two=new Jt.default(2).toRed(this.red),this.n=e.n&&new Jt.default(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.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))}s(If,"BaseCurve");var Dl=If;If.prototype.point=s(function(){throw new Error("Not implemented")},"point");If.prototype.validate=s(function(){throw new Error("Not implemented")},"validate");If.prototype._fixedNafMul=s(function(e,r){$g(e.precomputed);var n=e._getDoubles(),i=zg(r,1,this._bitLength),o=(1<<n.step+1)-(n.step%2===0?2:1);o/=3;var a=[],f,l;for(f=0;f<i.length;f+=n.step){l=0;for(var u=f+n.step-1;u>=f;u--)l=(l<<1)+i[u];a.push(l)}for(var h=this.jpoint(null,null,null),g=this.jpoint(null,null,null),x=o;x>0;x--){for(f=0;f<a.length;f++)l=a[f],l===x?g=g.mixedAdd(n.points[f]):l===-x&&(g=g.mixedAdd(n.points[f].neg()));h=h.add(g)}return h.toP()},"_fixedNafMul");If.prototype._wnafMul=s(function(e,r){var n=4,i=e._getNAFPoints(n);n=i.wnd;for(var o=i.points,a=zg(r,n,this._bitLength),f=this.jpoint(null,null,null),l=a.length-1;l>=0;l--){for(var u=0;l>=0&&a[l]===0;l--)u++;if(l>=0&&u++,f=f.dblp(u),l<0)break;var h=a[l];$g(h!==0),e.type==="affine"?h>0?f=f.mixedAdd(o[h-1>>1]):f=f.mixedAdd(o[-h-1>>1].neg()):h>0?f=f.add(o[h-1>>1]):f=f.add(o[-h-1>>1].neg())}return e.type==="affine"?f.toP():f},"_wnafMul");If.prototype._wnafMulAdd=s(function(e,r,n,i,o){var a=this._wnafT1,f=this._wnafT2,l=this._wnafT3,u=0,h,g,x;for(h=0;h<i;h++){x=r[h];var _=x._getNAFPoints(e);a[h]=_.wnd,f[h]=_.points}for(h=i-1;h>=1;h-=2){var E=h-1,T=h;if(a[E]!==1||a[T]!==1){l[E]=zg(n[E],a[E],this._bitLength),l[T]=zg(n[T],a[T],this._bitLength),u=Math.max(l[E].length,u),u=Math.max(l[T].length,u);continue}var B=[r[E],null,null,r[T]];r[E].y.cmp(r[T].y)===0?(B[1]=r[E].add(r[T]),B[2]=r[E].toJ().mixedAdd(r[T].neg())):r[E].y.cmp(r[T].y.redNeg())===0?(B[1]=r[E].toJ().mixedAdd(r[T]),B[2]=r[E].add(r[T].neg())):(B[1]=r[E].toJ().mixedAdd(r[T]),B[2]=r[E].toJ().mixedAdd(r[T].neg()));var F=[-3,-1,-5,-7,0,7,5,1,3],H=aV(n[E],n[T]);for(u=Math.max(H[0].length,u),l[E]=new Array(u),l[T]=new Array(u),g=0;g<u;g++){var U=H[0][g]|0,q=H[1][g]|0;l[E][g]=F[(U+1)*3+(q+1)],l[T][g]=0,f[E]=B}}var K=this.jpoint(null,null,null),W=this._wnafT4;for(h=u;h>=0;h--){for(var N=0;h>=0;){var G=!0;for(g=0;g<i;g++)W[g]=l[g][h]|0,W[g]!==0&&(G=!1);if(!G)break;N++,h--}if(h>=0&&N++,K=K.dblp(N),h<0)break;for(g=0;g<i;g++){var ce=W[g];ce!==0&&(ce>0?x=f[g][ce-1>>1]:ce<0&&(x=f[g][-ce-1>>1].neg()),x.type==="affine"?K=K.mixedAdd(x):K=K.add(x))}}for(h=0;h<i;h++)f[h]=null;return o?K:K.toP()},"_wnafMulAdd");function so(t,e){this.curve=t,this.type=e,this.precomputed=null}s(so,"BasePoint");If.BasePoint=so;so.prototype.eq=s(function(){throw new Error("Not implemented")},"eq");so.prototype.validate=s(function(){return this.curve.validate(this)},"validate");If.prototype.decodePoint=s(function(e,r){e=Rs.toArray(e,r);var n=this.p.byteLength();if((e[0]===4||e[0]===6||e[0]===7)&&e.length-1===2*n){e[0]===6?$g(e[e.length-1]%2===0):e[0]===7&&$g(e[e.length-1]%2===1);var i=this.point(e.slice(1,1+n),e.slice(1+n,1+2*n));return i}else if((e[0]===2||e[0]===3)&&e.length-1===n)return this.pointFromX(e.slice(1,1+n),e[0]===3);throw new Error("Unknown point format")},"decodePoint");so.prototype.encodeCompressed=s(function(e){return this.encode(e,!0)},"encodeCompressed");so.prototype._encode=s(function(e){var r=this.curve.p.byteLength(),n=this.getX().toArray("be",r);return e?[this.getY().isEven()?2:3].concat(n):[4].concat(n,this.getY().toArray("be",r))},"_encode");so.prototype.encode=s(function(e,r){return Rs.encode(this._encode(r),e)},"encode");so.prototype.precompute=s(function(e){if(this.precomputed)return this;var r={doubles:null,naf:null,beta:null};return r.naf=this._getNAFPoints(8),r.doubles=this._getDoubles(4,e),r.beta=this._getBeta(),this.precomputed=r,this},"precompute");so.prototype._hasDoubles=s(function(e){if(!this.precomputed)return!1;var r=this.precomputed.doubles;return r?r.points.length>=Math.ceil((e.bitLength()+1)/r.step):!1},"_hasDoubles");so.prototype._getDoubles=s(function(e,r){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var n=[this],i=this,o=0;o<r;o+=e){for(var a=0;a<e;a++)i=i.dbl();n.push(i)}return{step:e,points:n}},"_getDoubles");so.prototype._getNAFPoints=s(function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var r=[this],n=(1<<e)-1,i=n===1?null:this.dbl(),o=1;o<n;o++)r[o]=r[o-1].add(i);return{wnd:e,points:r}},"_getNAFPoints");so.prototype._getBeta=s(function(){return null},"_getBeta");so.prototype.dblp=s(function(e){for(var r=this,n=0;n<e;n++)r=r.dbl();return r},"dblp");var K3=od(function(t){typeof Object.create=="function"?t.exports=s(function(r,n){n&&(r.super_=n,r.prototype=Object.create(n.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}))},"inherits"):t.exports=s(function(r,n){if(n){r.super_=n;var i=s(function(){},"TempCtor");i.prototype=n.prototype,r.prototype=new i,r.prototype.constructor=r}},"inherits")}),cV=Rs.assert;function oo(t){Dl.call(this,"short",t),this.a=new Jt.default(t.a,16).toRed(this.red),this.b=new Jt.default(t.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(t),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}s(oo,"ShortCurve");K3(oo,Dl);var fV=oo;oo.prototype._getEndomorphism=s(function(e){if(!(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)){var r,n;if(e.beta)r=new Jt.default(e.beta,16).toRed(this.red);else{var i=this._getEndoRoots(this.p);r=i[0].cmp(i[1])<0?i[0]:i[1],r=r.toRed(this.red)}if(e.lambda)n=new Jt.default(e.lambda,16);else{var o=this._getEndoRoots(this.n);this.g.mul(o[0]).x.cmp(this.g.x.redMul(r))===0?n=o[0]:(n=o[1],cV(this.g.mul(n).x.cmp(this.g.x.redMul(r))===0))}var a;return e.basis?a=e.basis.map(function(f){return{a:new Jt.default(f.a,16),b:new Jt.default(f.b,16)}}):a=this._getEndoBasis(n),{beta:r,lambda:n,basis:a}}},"_getEndomorphism");oo.prototype._getEndoRoots=s(function(e){var r=e===this.p?this.red:Jt.default.mont(e),n=new Jt.default(2).toRed(r).redInvm(),i=n.redNeg(),o=new Jt.default(3).toRed(r).redNeg().redSqrt().redMul(n),a=i.redAdd(o).fromRed(),f=i.redSub(o).fromRed();return[a,f]},"_getEndoRoots");oo.prototype._getEndoBasis=s(function(e){for(var r=this.n.ushrn(Math.floor(this.n.bitLength()/2)),n=e,i=this.n.clone(),o=new Jt.default(1),a=new Jt.default(0),f=new Jt.default(0),l=new Jt.default(1),u,h,g,x,_,E,T,B=0,F,H;n.cmpn(0)!==0;){var U=i.div(n);F=i.sub(U.mul(n)),H=f.sub(U.mul(o));var q=l.sub(U.mul(a));if(!g&&F.cmp(r)<0)u=T.neg(),h=o,g=F.neg(),x=H;else if(g&&++B===2)break;T=F,i=n,n=F,f=o,o=H,l=a,a=q}_=F.neg(),E=H;var K=g.sqr().add(x.sqr()),W=_.sqr().add(E.sqr());return W.cmp(K)>=0&&(_=u,E=h),g.negative&&(g=g.neg(),x=x.neg()),_.negative&&(_=_.neg(),E=E.neg()),[{a:g,b:x},{a:_,b:E}]},"_getEndoBasis");oo.prototype._endoSplit=s(function(e){var r=this.endo.basis,n=r[0],i=r[1],o=i.b.mul(e).divRound(this.n),a=n.b.neg().mul(e).divRound(this.n),f=o.mul(n.a),l=a.mul(i.a),u=o.mul(n.b),h=a.mul(i.b),g=e.sub(f).sub(l),x=u.add(h).neg();return{k1:g,k2:x}},"_endoSplit");oo.prototype.pointFromX=s(function(e,r){e=new Jt.default(e,16),e.red||(e=e.toRed(this.red));var n=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),i=n.redSqrt();if(i.redSqr().redSub(n).cmp(this.zero)!==0)throw new Error("invalid point");var o=i.fromRed().isOdd();return(r&&!o||!r&&o)&&(i=i.redNeg()),this.point(e,i)},"pointFromX");oo.prototype.validate=s(function(e){if(e.inf)return!0;var r=e.x,n=e.y,i=this.a.redMul(r),o=r.redSqr().redMul(r).redIAdd(i).redIAdd(this.b);return n.redSqr().redISub(o).cmpn(0)===0},"validate");oo.prototype._endoWnafMulAdd=s(function(e,r,n){for(var i=this._endoWnafT1,o=this._endoWnafT2,a=0;a<e.length;a++){var f=this._endoSplit(r[a]),l=e[a],u=l._getBeta();f.k1.negative&&(f.k1.ineg(),l=l.neg(!0)),f.k2.negative&&(f.k2.ineg(),u=u.neg(!0)),i[a*2]=l,i[a*2+1]=u,o[a*2]=f.k1,o[a*2+1]=f.k2}for(var h=this._wnafMulAdd(1,i,o,a*2,n),g=0;g<a*2;g++)i[g]=null,o[g]=null;return h},"_endoWnafMulAdd");function Vn(t,e,r,n){Dl.BasePoint.call(this,t,"affine"),e===null&&r===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new Jt.default(e,16),this.y=new Jt.default(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)}s(Vn,"Point");K3(Vn,Dl.BasePoint);oo.prototype.point=s(function(e,r,n){return new Vn(this,e,r,n)},"point");oo.prototype.pointFromJSON=s(function(e,r){return Vn.fromJSON(this,e,r)},"pointFromJSON");Vn.prototype._getBeta=s(function(){if(!!this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var r=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var n=this.curve,i=s(function(o){return n.point(o.x.redMul(n.endo.beta),o.y)},"endoMul");e.beta=r,r.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(i)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(i)}}}return r}},"_getBeta");Vn.prototype.toJSON=s(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]},"toJSON");Vn.fromJSON=s(function(e,r,n){typeof r=="string"&&(r=JSON.parse(r));var i=e.point(r[0],r[1],n);if(!r[2])return i;function o(f){return e.point(f[0],f[1],n)}s(o,"obj2point");var a=r[2];return i.precomputed={beta:null,doubles:a.doubles&&{step:a.doubles.step,points:[i].concat(a.doubles.points.map(o))},naf:a.naf&&{wnd:a.naf.wnd,points:[i].concat(a.naf.points.map(o))}},i},"fromJSON");Vn.prototype.inspect=s(function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},"inspect");Vn.prototype.isInfinity=s(function(){return this.inf},"isInfinity");Vn.prototype.add=s(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 r=this.y.redSub(e.y);r.cmpn(0)!==0&&(r=r.redMul(this.x.redSub(e.x).redInvm()));var n=r.redSqr().redISub(this.x).redISub(e.x),i=r.redMul(this.x.redSub(n)).redISub(this.y);return this.curve.point(n,i)},"add");Vn.prototype.dbl=s(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 r=this.curve.a,n=this.x.redSqr(),i=e.redInvm(),o=n.redAdd(n).redIAdd(n).redIAdd(r).redMul(i),a=o.redSqr().redISub(this.x.redAdd(this.x)),f=o.redMul(this.x.redSub(a)).redISub(this.y);return this.curve.point(a,f)},"dbl");Vn.prototype.getX=s(function(){return this.x.fromRed()},"getX");Vn.prototype.getY=s(function(){return this.y.fromRed()},"getY");Vn.prototype.mul=s(function(e){return e=new Jt.default(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)},"mul");Vn.prototype.mulAdd=s(function(e,r,n){var i=[this,r],o=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(i,o):this.curve._wnafMulAdd(1,i,o,2)},"mulAdd");Vn.prototype.jmulAdd=s(function(e,r,n){var i=[this,r],o=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(i,o,!0):this.curve._wnafMulAdd(1,i,o,2,!0)},"jmulAdd");Vn.prototype.eq=s(function(e){return this===e||this.inf===e.inf&&(this.inf||this.x.cmp(e.x)===0&&this.y.cmp(e.y)===0)},"eq");Vn.prototype.neg=s(function(e){if(this.inf)return this;var r=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var n=this.precomputed,i=s(function(o){return o.neg()},"negate");r.precomputed={naf:n.naf&&{wnd:n.naf.wnd,points:n.naf.points.map(i)},doubles:n.doubles&&{step:n.doubles.step,points:n.doubles.points.map(i)}}}return r},"neg");Vn.prototype.toJ=s(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},"toJ");function ii(t,e,r,n){Dl.BasePoint.call(this,t,"jacobian"),e===null&&r===null&&n===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new Jt.default(0)):(this.x=new Jt.default(e,16),this.y=new Jt.default(r,16),this.z=new Jt.default(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}s(ii,"JPoint");K3(ii,Dl.BasePoint);oo.prototype.jpoint=s(function(e,r,n){return new ii(this,e,r,n)},"jpoint");ii.prototype.toP=s(function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),r=e.redSqr(),n=this.x.redMul(r),i=this.y.redMul(r).redMul(e);return this.curve.point(n,i)},"toP");ii.prototype.neg=s(function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},"neg");ii.prototype.add=s(function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var r=e.z.redSqr(),n=this.z.redSqr(),i=this.x.redMul(r),o=e.x.redMul(n),a=this.y.redMul(r.redMul(e.z)),f=e.y.redMul(n.redMul(this.z)),l=i.redSub(o),u=a.redSub(f);if(l.cmpn(0)===0)return u.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var h=l.redSqr(),g=h.redMul(l),x=i.redMul(h),_=u.redSqr().redIAdd(g).redISub(x).redISub(x),E=u.redMul(x.redISub(_)).redISub(a.redMul(g)),T=this.z.redMul(e.z).redMul(l);return this.curve.jpoint(_,E,T)},"add");ii.prototype.mixedAdd=s(function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var r=this.z.redSqr(),n=this.x,i=e.x.redMul(r),o=this.y,a=e.y.redMul(r).redMul(this.z),f=n.redSub(i),l=o.redSub(a);if(f.cmpn(0)===0)return l.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var u=f.redSqr(),h=u.redMul(f),g=n.redMul(u),x=l.redSqr().redIAdd(h).redISub(g).redISub(g),_=l.redMul(g.redISub(x)).redISub(o.redMul(h)),E=this.z.redMul(f);return this.curve.jpoint(x,_,E)},"mixedAdd");ii.prototype.dblp=s(function(e){if(e===0)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var r;if(this.curve.zeroA||this.curve.threeA){var n=this;for(r=0;r<e;r++)n=n.dbl();return n}var i=this.curve.a,o=this.curve.tinv,a=this.x,f=this.y,l=this.z,u=l.redSqr().redSqr(),h=f.redAdd(f);for(r=0;r<e;r++){var g=a.redSqr(),x=h.redSqr(),_=x.redSqr(),E=g.redAdd(g).redIAdd(g).redIAdd(i.redMul(u)),T=a.redMul(x),B=E.redSqr().redISub(T.redAdd(T)),F=T.redISub(B),H=E.redMul(F);H=H.redIAdd(H).redISub(_);var U=h.redMul(l);r+1<e&&(u=u.redMul(_)),a=B,l=U,h=H}return this.curve.jpoint(a,h.redMul(o),l)},"dblp");ii.prototype.dbl=s(function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},"dbl");ii.prototype._zeroDbl=s(function(){var e,r,n;if(this.zOne){var i=this.x.redSqr(),o=this.y.redSqr(),a=o.redSqr(),f=this.x.redAdd(o).redSqr().redISub(i).redISub(a);f=f.redIAdd(f);var l=i.redAdd(i).redIAdd(i),u=l.redSqr().redISub(f).redISub(f),h=a.redIAdd(a);h=h.redIAdd(h),h=h.redIAdd(h),e=u,r=l.redMul(f.redISub(u)).redISub(h),n=this.y.redAdd(this.y)}else{var g=this.x.redSqr(),x=this.y.redSqr(),_=x.redSqr(),E=this.x.redAdd(x).redSqr().redISub(g).redISub(_);E=E.redIAdd(E);var T=g.redAdd(g).redIAdd(g),B=T.redSqr(),F=_.redIAdd(_);F=F.redIAdd(F),F=F.redIAdd(F),e=B.redISub(E).redISub(E),r=T.redMul(E.redISub(e)).redISub(F),n=this.y.redMul(this.z),n=n.redIAdd(n)}return this.curve.jpoint(e,r,n)},"_zeroDbl");ii.prototype._threeDbl=s(function(){var e,r,n;if(this.zOne){var i=this.x.redSqr(),o=this.y.redSqr(),a=o.redSqr(),f=this.x.redAdd(o).redSqr().redISub(i).redISub(a);f=f.redIAdd(f);var l=i.redAdd(i).redIAdd(i).redIAdd(this.curve.a),u=l.redSqr().redISub(f).redISub(f);e=u;var h=a.redIAdd(a);h=h.redIAdd(h),h=h.redIAdd(h),r=l.redMul(f.redISub(u)).redISub(h),n=this.y.redAdd(this.y)}else{var g=this.z.redSqr(),x=this.y.redSqr(),_=this.x.redMul(x),E=this.x.redSub(g).redMul(this.x.redAdd(g));E=E.redAdd(E).redIAdd(E);var T=_.redIAdd(_);T=T.redIAdd(T);var B=T.redAdd(T);e=E.redSqr().redISub(B),n=this.y.redAdd(this.z).redSqr().redISub(x).redISub(g);var F=x.redSqr();F=F.redIAdd(F),F=F.redIAdd(F),F=F.redIAdd(F),r=E.redMul(T.redISub(e)).redISub(F)}return this.curve.jpoint(e,r,n)},"_threeDbl");ii.prototype._dbl=s(function(){var e=this.curve.a,r=this.x,n=this.y,i=this.z,o=i.redSqr().redSqr(),a=r.redSqr(),f=n.redSqr(),l=a.redAdd(a).redIAdd(a).redIAdd(e.redMul(o)),u=r.redAdd(r);u=u.redIAdd(u);var h=u.redMul(f),g=l.redSqr().redISub(h.redAdd(h)),x=h.redISub(g),_=f.redSqr();_=_.redIAdd(_),_=_.redIAdd(_),_=_.redIAdd(_);var E=l.redMul(x).redISub(_),T=n.redAdd(n).redMul(i);return this.curve.jpoint(g,E,T)},"_dbl");ii.prototype.trpl=s(function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),r=this.y.redSqr(),n=this.z.redSqr(),i=r.redSqr(),o=e.redAdd(e).redIAdd(e),a=o.redSqr(),f=this.x.redAdd(r).redSqr().redISub(e).redISub(i);f=f.redIAdd(f),f=f.redAdd(f).redIAdd(f),f=f.redISub(a);var l=f.redSqr(),u=i.redIAdd(i);u=u.redIAdd(u),u=u.redIAdd(u),u=u.redIAdd(u);var h=o.redIAdd(f).redSqr().redISub(a).redISub(l).redISub(u),g=r.redMul(h);g=g.redIAdd(g),g=g.redIAdd(g);var x=this.x.redMul(l).redISub(g);x=x.redIAdd(x),x=x.redIAdd(x);var _=this.y.redMul(h.redMul(u.redISub(h)).redISub(f.redMul(l)));_=_.redIAdd(_),_=_.redIAdd(_),_=_.redIAdd(_);var E=this.z.redAdd(f).redSqr().redISub(n).redISub(l);return this.curve.jpoint(x,_,E)},"trpl");ii.prototype.mul=s(function(e,r){return e=new Jt.default(e,r),this.curve._wnafMul(this,e)},"mul");ii.prototype.eq=s(function(e){if(e.type==="affine")return this.eq(e.toJ());if(this===e)return!0;var r=this.z.redSqr(),n=e.z.redSqr();if(this.x.redMul(n).redISub(e.x.redMul(r)).cmpn(0)!==0)return!1;var i=r.redMul(this.z),o=n.redMul(e.z);return this.y.redMul(o).redISub(e.y.redMul(i)).cmpn(0)===0},"eq");ii.prototype.eqXToP=s(function(e){var r=this.z.redSqr(),n=e.toRed(this.curve.red).redMul(r);if(this.x.cmp(n)===0)return!0;for(var i=e.clone(),o=this.curve.redN.redMul(r);;){if(i.iadd(this.curve.n),i.cmp(this.curve.p)>=0)return!1;if(n.redIAdd(o),this.x.cmp(n)===0)return!0}},"eqXToP");ii.prototype.inspect=s(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)+">"},"inspect");ii.prototype.isInfinity=s(function(){return this.z.cmpn(0)===0},"isInfinity");var qg=od(function(t,e){"use strict";var r=e;r.base=Dl,r.short=fV,r.mont=null,r.edwards=null}),Hg=od(function(t,e){"use strict";var r=e,n=Rs.assert;function i(f){f.type==="short"?this.curve=new qg.short(f):f.type==="edwards"?this.curve=new qg.edwards(f):this.curve=new qg.mont(f),this.g=this.curve.g,this.n=this.curve.n,this.hash=f.hash,n(this.g.validate(),"Invalid curve"),n(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}s(i,"PresetCurve"),r.PresetCurve=i;function o(f,l){Object.defineProperty(r,f,{configurable:!0,enumerable:!0,get:function(){var u=new i(l);return Object.defineProperty(r,f,{configurable:!0,enumerable:!0,value:u}),u}})}s(o,"defineCurve"),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:Ia.default.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:Ia.default.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:Ia.default.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:Ia.default.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:Ia.default.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:Ia.default.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:Ia.default.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var a;try{a=null.crash()}catch{a=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:Ia.default.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",a]})});function Sf(t){if(!(this instanceof Sf))return new Sf(t);this.hash=t.hash,this.predResist=!!t.predResist,this.outLen=this.hash.outSize,this.minEntropy=t.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var e=Mo.toArray(t.entropy,t.entropyEnc||"hex"),r=Mo.toArray(t.nonce,t.nonceEnc||"hex"),n=Mo.toArray(t.pers,t.persEnc||"hex");G3(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,n)}s(Sf,"HmacDRBG");var ok=Sf;Sf.prototype._init=s(function(e,r,n){var i=e.concat(r).concat(n);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var o=0;o<this.V.length;o++)this.K[o]=0,this.V[o]=1;this._update(i),this._reseed=1,this.reseedInterval=281474976710656},"init");Sf.prototype._hmac=s(function(){return new Ia.default.hmac(this.hash,this.K)},"hmac");Sf.prototype._update=s(function(e){var r=this._hmac().update(this.V).update([0]);e&&(r=r.update(e)),this.K=r.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())},"update");Sf.prototype.reseed=s(function(e,r,n,i){typeof r!="string"&&(i=n,n=r,r=null),e=Mo.toArray(e,r),n=Mo.toArray(n,i),G3(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(n||[])),this._reseed=1},"reseed");Sf.prototype.generate=s(function(e,r,n,i){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof r!="string"&&(i=n,n=r,r=null),n&&(n=Mo.toArray(n,i||"hex"),this._update(n));for(var o=[];o.length<e;)this.V=this._hmac().update(this.V).digest(),o=o.concat(this.V);var a=o.slice(0,e);return this._update(n),this._reseed++,Mo.encode(a,r)},"generate");var $3=Rs.assert;function ki(t,e){this.ec=t,this.priv=null,this.pub=null,e.priv&&this._importPrivate(e.priv,e.privEnc),e.pub&&this._importPublic(e.pub,e.pubEnc)}s(ki,"KeyPair");var V3=ki;ki.fromPublic=s(function(e,r,n){return r instanceof ki?r:new ki(e,{pub:r,pubEnc:n})},"fromPublic");ki.fromPrivate=s(function(e,r,n){return r instanceof ki?r:new ki(e,{priv:r,privEnc:n})},"fromPrivate");ki.prototype.validate=s(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"}},"validate");ki.prototype.getPublic=s(function(e,r){return typeof e=="string"&&(r=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),r?this.pub.encode(r,e):this.pub},"getPublic");ki.prototype.getPrivate=s(function(e){return e==="hex"?this.priv.toString(16,2):this.priv},"getPrivate");ki.prototype._importPrivate=s(function(e,r){this.priv=new Jt.default(e,r||16),this.priv=this.priv.umod(this.ec.curve.n)},"_importPrivate");ki.prototype._importPublic=s(function(e,r){if(e.x||e.y){this.ec.curve.type==="mont"?$3(e.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&$3(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,r)},"_importPublic");ki.prototype.derive=s(function(e){return e.validate()||$3(e.validate(),"public point not validated"),e.mul(this.priv).getX()},"derive");ki.prototype.sign=s(function(e,r,n){return this.ec.sign(e,this,r,n)},"sign");ki.prototype.verify=s(function(e,r){return this.ec.verify(e,r,this)},"verify");ki.prototype.inspect=s(function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"},"inspect");var lV=Rs.assert;function Gg(t,e){if(t instanceof Gg)return t;this._importDER(t,e)||(lV(t.r&&t.s,"Signature without r or s"),this.r=new Jt.default(t.r,16),this.s=new Jt.default(t.s,16),t.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}s(Gg,"Signature");var Kg=Gg;function uV(){this.place=0}s(uV,"Position");function H3(t,e){var r=t[e.place++];if(!(r&128))return r;var n=r&15;if(n===0||n>4)return!1;for(var i=0,o=0,a=e.place;o<n;o++,a++)i<<=8,i|=t[a],i>>>=0;return i<=127?!1:(e.place=a,i)}s(H3,"getLength");function ik(t){for(var e=0,r=t.length-1;!t[e]&&!(t[e+1]&128)&&e<r;)e++;return e===0?t:t.slice(e)}s(ik,"rmPadding");Gg.prototype._importDER=s(function(e,r){e=Rs.toArray(e,r);var n=new uV;if(e[n.place++]!==48)return!1;var i=H3(e,n);if(i===!1||i+n.place!==e.length||e[n.place++]!==2)return!1;var o=H3(e,n);if(o===!1)return!1;var a=e.slice(n.place,o+n.place);if(n.place+=o,e[n.place++]!==2)return!1;var f=H3(e,n);if(f===!1||e.length!==f+n.place)return!1;var l=e.slice(n.place,f+n.place);if(a[0]===0)if(a[1]&128)a=a.slice(1);else return!1;if(l[0]===0)if(l[1]&128)l=l.slice(1);else return!1;return this.r=new Jt.default(a),this.s=new Jt.default(l),this.recoveryParam=null,!0},"_importDER");function z3(t,e){if(e<128){t.push(e);return}var r=1+(Math.log(e)/Math.LN2>>>3);for(t.push(r|128);--r;)t.push(e>>>(r<<3)&255);t.push(e)}s(z3,"constructLength");Gg.prototype.toDER=s(function(e){var r=this.r.toArray(),n=this.s.toArray();for(r[0]&128&&(r=[0].concat(r)),n[0]&128&&(n=[0].concat(n)),r=ik(r),n=ik(n);!n[0]&&!(n[1]&128);)n=n.slice(1);var i=[2];z3(i,r.length),i=i.concat(r),i.push(2),z3(i,n.length);var o=i.concat(n),a=[48];return z3(a,o.length),a=a.concat(o),Rs.encode(a,e)},"toDER");var dV=s(function(){throw new Error("unsupported")},"rand"),ak=Rs.assert;function io(t){if(!(this instanceof io))return new io(t);typeof t=="string"&&(ak(Object.prototype.hasOwnProperty.call(Hg,t),"Unknown curve "+t),t=Hg[t]),t instanceof Hg.PresetCurve&&(t={curve:t}),this.curve=t.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=t.curve.g,this.g.precompute(t.curve.n.bitLength()+1),this.hash=t.hash||t.curve.hash}s(io,"EC");var hV=io;io.prototype.keyPair=s(function(e){return new V3(this,e)},"keyPair");io.prototype.keyFromPrivate=s(function(e,r){return V3.fromPrivate(this,e,r)},"keyFromPrivate");io.prototype.keyFromPublic=s(function(e,r){return V3.fromPublic(this,e,r)},"keyFromPublic");io.prototype.genKeyPair=s(function(e){e||(e={});for(var r=new ok({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||dV(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),n=this.n.byteLength(),i=this.n.sub(new Jt.default(2));;){var o=new Jt.default(r.generate(n));if(!(o.cmp(i)>0))return o.iaddn(1),this.keyFromPrivate(o)}},"genKeyPair");io.prototype._truncateToN=s(function(e,r){var n=e.byteLength()*8-this.n.bitLength();return n>0&&(e=e.ushrn(n)),!r&&e.cmp(this.n)>=0?e.sub(this.n):e},"_truncateToN");io.prototype.sign=s(function(e,r,n,i){typeof n=="object"&&(i=n,n=null),i||(i={}),r=this.keyFromPrivate(r,n),e=this._truncateToN(new Jt.default(e,16));for(var o=this.n.byteLength(),a=r.getPrivate().toArray("be",o),f=e.toArray("be",o),l=new ok({hash:this.hash,entropy:a,nonce:f,pers:i.pers,persEnc:i.persEnc||"utf8"}),u=this.n.sub(new Jt.default(1)),h=0;;h++){var g=i.k?i.k(h):new Jt.default(l.generate(this.n.byteLength()));if(g=this._truncateToN(g,!0),!(g.cmpn(1)<=0||g.cmp(u)>=0)){var x=this.g.mul(g);if(!x.isInfinity()){var _=x.getX(),E=_.umod(this.n);if(E.cmpn(0)!==0){var T=g.invm(this.n).mul(E.mul(r.getPrivate()).iadd(e));if(T=T.umod(this.n),T.cmpn(0)!==0){var B=(x.getY().isOdd()?1:0)|(_.cmp(E)!==0?2:0);return i.canonical&&T.cmp(this.nh)>0&&(T=this.n.sub(T),B^=1),new Kg({r:E,s:T,recoveryParam:B})}}}}}},"sign");io.prototype.verify=s(function(e,r,n,i){e=this._truncateToN(new Jt.default(e,16)),n=this.keyFromPublic(n,i),r=new Kg(r,"hex");var o=r.r,a=r.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0||a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var f=a.invm(this.n),l=f.mul(e).umod(this.n),u=f.mul(o).umod(this.n),h;return this.curve._maxwellTrick?(h=this.g.jmulAdd(l,n.getPublic(),u),h.isInfinity()?!1:h.eqXToP(o)):(h=this.g.mulAdd(l,n.getPublic(),u),h.isInfinity()?!1:h.getX().umod(this.n).cmp(o)===0)},"verify");io.prototype.recoverPubKey=function(t,e,r,n){ak((3&r)===r,"The recovery param is more than two bits"),e=new Kg(e,n);var i=this.n,o=new Jt.default(t),a=e.r,f=e.s,l=r&1,u=r>>1;if(a.cmp(this.curve.p.umod(this.curve.n))>=0&&u)throw new Error("Unable to find sencond key candinate");u?a=this.curve.pointFromX(a.add(this.curve.n),l):a=this.curve.pointFromX(a,l);var h=e.r.invm(i),g=i.sub(o).mul(h).umod(i),x=f.mul(h).umod(i);return this.g.mulAdd(g,a,x)};io.prototype.getKeyRecoveryParam=function(t,e,r,n){if(e=new Kg(e,n),e.recoveryParam!==null)return e.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(t,e,i)}catch{continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var pV=od(function(t,e){"use strict";var r=e;r.version="6.5.4",r.utils=Rs,r.rand=function(){throw new Error("unsupported")},r.curve=qg,r.curves=Hg,r.ec=hV,r.eddsa=null}),ck=pV.ec;var fk="signing-key/5.7.0";var J3=new ve(fk),W3=null;function ka(){return W3||(W3=new ck("secp256k1")),W3}s(ka,"getCurve");var Bs=class{constructor(e){Pe(this,"curve","secp256k1"),Pe(this,"privateKey",Ve(e)),Ei(this.privateKey)!==32&&J3.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");let r=ka().keyFromPrivate(je(this.privateKey));Pe(this,"publicKey","0x"+r.getPublic(!1,"hex")),Pe(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),Pe(this,"_isSigningKey",!0)}_addPoint(e){let r=ka().keyFromPublic(je(this.publicKey)),n=ka().keyFromPublic(je(e));return"0x"+r.pub.add(n.pub).encodeCompressed("hex")}signDigest(e){let r=ka().keyFromPrivate(je(this.privateKey)),n=je(e);n.length!==32&&J3.throwArgumentError("bad digest length","digest",e);let i=r.sign(n,{canonical:!0});return ga({recoveryParam:i.recoveryParam,r:ur("0x"+i.r.toString(16),32),s:ur("0x"+i.s.toString(16),32)})}computeSharedSecret(e){let r=ka().keyFromPrivate(je(this.privateKey)),n=ka().keyFromPublic(je(Q0(e)));return ur("0x"+r.derive(n.getPublic()).toString(16),32)}static isSigningKey(e){return!!(e&&e._isSigningKey)}};s(Bs,"SigningKey");function Vg(t,e){let r=ga(e),n={r:je(r.r),s:je(r.s)};return"0x"+ka().recoverPubKey(je(t),n,r.recoveryParam).encode("hex",!1)}s(Vg,"recoverPublicKey");function Q0(t,e){let r=je(t);if(r.length===32){let n=new Bs(r);return e?"0x"+ka().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}else{if(r.length===33)return e?Ve(r):"0x"+ka().keyFromPublic(r).getPublic(!1,"hex");if(r.length===65)return e?"0x"+ka().keyFromPublic(r).getPublic(!0,"hex"):Ve(r)}return J3.throwArgumentError("invalid public or private key","key","[REDACTED]")}s(Q0,"computePublicKey");var lk="transactions/5.7.0";var Mi=new ve(lk),Wg;(function(t){t[t.legacy=0]="legacy",t[t.eip2930=1]="eip2930",t[t.eip1559=2]="eip1559"})(Wg||(Wg={}));function Z3(t){return t==="0x"?null:ar(t)}s(Z3,"handleAddress");function Ti(t){return t==="0x"?Wu:ze.from(t)}s(Ti,"handleNumber");var mV=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],gV={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function ao(t){let e=Q0(t);return ar(Fr(or(Fr(e,1)),12))}s(ao,"computeAddress");function Pl(t,e){return ao(Vg(je(t),e))}s(Pl,"recoverAddress");function Ds(t,e){let r=Ts(ze.from(t).toHexString());return r.length>32&&Mi.throwArgumentError("invalid length for "+e,"transaction:"+e,t),r}s(Ds,"formatNumber");function Y3(t,e){return{address:ar(t),storageKeys:(e||[]).map((r,n)=>(Ei(r)!==32&&Mi.throwArgumentError("invalid access list storageKey",`accessList[${t}:${n}]`,r),r.toLowerCase()))}}s(Y3,"accessSetify");function Ps(t){if(Array.isArray(t))return t.map((r,n)=>Array.isArray(r)?(r.length>2&&Mi.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${n}]`,r),Y3(r[0],r[1])):Y3(r.address,r.storageKeys));let e=Object.keys(t).map(r=>{let n=t[r].reduce((i,o)=>(i[o]=!0,i),{});return Y3(r,Object.keys(n).sort())});return e.sort((r,n)=>r.address.localeCompare(n.address)),e}s(Ps,"accessListify");function uk(t){return Ps(t).map(e=>[e.address,e.storageKeys])}s(uk,"formatAccessList");function dk(t,e){if(t.gasPrice!=null){let n=ze.from(t.gasPrice),i=ze.from(t.maxFeePerGas||0);n.eq(i)||Mi.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:n,maxFeePerGas:i})}let r=[Ds(t.chainId||0,"chainId"),Ds(t.nonce||0,"nonce"),Ds(t.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),Ds(t.maxFeePerGas||0,"maxFeePerGas"),Ds(t.gasLimit||0,"gasLimit"),t.to!=null?ar(t.to):"0x",Ds(t.value||0,"value"),t.data||"0x",uk(t.accessList||[])];if(e){let n=ga(e);r.push(Ds(n.recoveryParam,"recoveryParam")),r.push(Ts(n.r)),r.push(Ts(n.s))}return Mn(["0x02",gc(r)])}s(dk,"_serializeEip1559");function hk(t,e){let r=[Ds(t.chainId||0,"chainId"),Ds(t.nonce||0,"nonce"),Ds(t.gasPrice||0,"gasPrice"),Ds(t.gasLimit||0,"gasLimit"),t.to!=null?ar(t.to):"0x",Ds(t.value||0,"value"),t.data||"0x",uk(t.accessList||[])];if(e){let n=ga(e);r.push(Ds(n.recoveryParam,"recoveryParam")),r.push(Ts(n.r)),r.push(Ts(n.s))}return Mn(["0x01",gc(r)])}s(hk,"_serializeEip2930");function bV(t,e){zu(t,gV);let r=[];mV.forEach(function(a){let f=t[a.name]||[],l={};a.numeric&&(l.hexPad="left"),f=je(Ve(f,l)),a.length&&f.length!==a.length&&f.length>0&&Mi.throwArgumentError("invalid length for "+a.name,"transaction:"+a.name,f),a.maxLength&&(f=Ts(f),f.length>a.maxLength&&Mi.throwArgumentError("invalid length for "+a.name,"transaction:"+a.name,f)),r.push(Ve(f))});let n=0;if(t.chainId!=null?(n=t.chainId,typeof n!="number"&&Mi.throwArgumentError("invalid transaction.chainId","transaction",t)):e&&!pc(e)&&e.v>28&&(n=Math.floor((e.v-35)/2)),n!==0&&(r.push(Ve(n)),r.push("0x"),r.push("0x")),!e)return gc(r);let i=ga(e),o=27+i.recoveryParam;return n!==0?(r.pop(),r.pop(),r.pop(),o+=n*2+8,i.v>28&&i.v!==o&&Mi.throwArgumentError("transaction.chainId/signature.v mismatch","signature",e)):i.v!==o&&Mi.throwArgumentError("transaction.chainId/signature.v mismatch","signature",e),r.push(Ve(o)),r.push(Ts(je(i.r))),r.push(Ts(je(i.s))),gc(r)}s(bV,"_serialize");function ep(t,e){if(t.type==null||t.type===0)return t.accessList!=null&&Mi.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",t),bV(t,e);switch(t.type){case 1:return hk(t,e);case 2:return dk(t,e);default:break}return Mi.throwError(`unsupported transaction type: ${t.type}`,ve.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:t.type})}s(ep,"serialize");function pk(t,e,r){try{let n=Ti(e[0]).toNumber();if(n!==0&&n!==1)throw new Error("bad recid");t.v=n}catch{Mi.throwArgumentError("invalid v for transaction type: 1","v",e[0])}t.r=ur(e[1],32),t.s=ur(e[2],32);try{let n=or(r(t));t.from=Pl(n,{r:t.r,s:t.s,recoveryParam:t.v})}catch{}}s(pk,"_parseEipSignature");function vV(t){let e=N0(t.slice(1));e.length!==9&&e.length!==12&&Mi.throwArgumentError("invalid component count for transaction type: 2","payload",Ve(t));let r=Ti(e[2]),n=Ti(e[3]),i={type:2,chainId:Ti(e[0]).toNumber(),nonce:Ti(e[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:Ti(e[4]),to:Z3(e[5]),value:Ti(e[6]),data:e[7],accessList:Ps(e[8])};return e.length===9||(i.hash=or(t),pk(i,e.slice(9),dk)),i}s(vV,"_parseEip1559");function yV(t){let e=N0(t.slice(1));e.length!==8&&e.length!==11&&Mi.throwArgumentError("invalid component count for transaction type: 1","payload",Ve(t));let r={type:1,chainId:Ti(e[0]).toNumber(),nonce:Ti(e[1]).toNumber(),gasPrice:Ti(e[2]),gasLimit:Ti(e[3]),to:Z3(e[4]),value:Ti(e[5]),data:e[6],accessList:Ps(e[7])};return e.length===8||(r.hash=or(t),pk(r,e.slice(8),hk)),r}s(yV,"_parseEip2930");function xV(t){let e=N0(t);e.length!==9&&e.length!==6&&Mi.throwArgumentError("invalid raw transaction","rawTransaction",t);let r={nonce:Ti(e[0]).toNumber(),gasPrice:Ti(e[1]),gasLimit:Ti(e[2]),to:Z3(e[3]),value:Ti(e[4]),data:e[5],chainId:0};if(e.length===6)return r;try{r.v=ze.from(e[6]).toNumber()}catch{return r}if(r.r=ur(e[7],32),r.s=ur(e[8],32),ze.from(r.r).isZero()&&ze.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);let n=r.v-27,i=e.slice(0,6);r.chainId!==0&&(i.push(Ve(r.chainId)),i.push("0x"),i.push("0x"),n-=r.chainId*2+8);let o=or(gc(i));try{r.from=Pl(o,{r:Ve(r.r),s:Ve(r.s),recoveryParam:n})}catch{}r.hash=or(t)}return r.type=null,r}s(xV,"_parse");function Jg(t){let e=je(t);if(e[0]>127)return xV(e);switch(e[0]){case 1:return yV(e);case 2:return vV(e);default:break}return Mi.throwError(`unsupported transaction type: ${e[0]}`,ve.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:e[0]})}s(Jg,"parse");var mk="contracts/5.7.0";var Tf=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},jr=new ve(mk),wV={chainId:!0,data:!0,from:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0,customData:!0,ccipReadEnabled:!0};function Zg(t,e){return Tf(this,void 0,void 0,function*(){let r=yield e;typeof r!="string"&&jr.throwArgumentError("invalid address or ENS name","name",r);try{return ar(r)}catch{}t||jr.throwError("a provider or signer is needed to resolve ENS names",ve.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"});let n=yield t.resolveName(r);return n==null&&jr.throwArgumentError("resolver or addr is not configured for ENS name","name",r),n})}s(Zg,"resolveName");function tp(t,e,r){return Tf(this,void 0,void 0,function*(){return Array.isArray(r)?yield Promise.all(r.map((n,i)=>tp(t,Array.isArray(e)?e[i]:e[n.name],n))):r.type==="address"?yield Zg(t,e):r.type==="tuple"?yield tp(t,e,r.components):r.baseType==="array"?Array.isArray(e)?yield Promise.all(e.map(n=>tp(t,n,r.arrayChildren))):Promise.reject(jr.makeError("invalid value for array",ve.errors.INVALID_ARGUMENT,{argument:"value",value:e})):e})}s(tp,"resolveAddresses");function Xg(t,e,r){return Tf(this,void 0,void 0,function*(){let n={};r.length===e.inputs.length+1&&typeof r[r.length-1]=="object"&&(n=Er(r.pop())),jr.checkArgumentCount(r.length,e.inputs.length,"passed to contract"),t.signer?n.from?n.from=Nr({override:Zg(t.signer,n.from),signer:t.signer.getAddress()}).then(u=>Tf(this,void 0,void 0,function*(){return ar(u.signer)!==u.override&&jr.throwError("Contract with a Signer cannot override from",ve.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),u.override})):n.from=t.signer.getAddress():n.from&&(n.from=Zg(t.provider,n.from));let i=yield Nr({args:tp(t.signer||t.provider,r,e.inputs),address:t.resolvedAddress,overrides:Nr(n)||{}}),o=t.interface.encodeFunctionData(e,i.args),a={data:o,to:i.address},f=i.overrides;if(f.nonce!=null&&(a.nonce=ze.from(f.nonce).toNumber()),f.gasLimit!=null&&(a.gasLimit=ze.from(f.gasLimit)),f.gasPrice!=null&&(a.gasPrice=ze.from(f.gasPrice)),f.maxFeePerGas!=null&&(a.maxFeePerGas=ze.from(f.maxFeePerGas)),f.maxPriorityFeePerGas!=null&&(a.maxPriorityFeePerGas=ze.from(f.maxPriorityFeePerGas)),f.from!=null&&(a.from=f.from),f.type!=null&&(a.type=f.type),f.accessList!=null&&(a.accessList=Ps(f.accessList)),a.gasLimit==null&&e.gas!=null){let u=21e3,h=je(o);for(let g=0;g<h.length;g++)u+=4,h[g]&&(u+=64);a.gasLimit=ze.from(e.gas).add(u)}if(f.value){let u=ze.from(f.value);!u.isZero()&&!e.payable&&jr.throwError("non-payable method cannot override value",ve.errors.UNSUPPORTED_OPERATION,{operation:"overrides.value",value:n.value}),a.value=u}f.customData&&(a.customData=Er(f.customData)),f.ccipReadEnabled&&(a.ccipReadEnabled=!!f.ccipReadEnabled),delete n.nonce,delete n.gasLimit,delete n.gasPrice,delete n.from,delete n.value,delete n.type,delete n.accessList,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas,delete n.customData,delete n.ccipReadEnabled;let l=Object.keys(n).filter(u=>n[u]!=null);return l.length&&jr.throwError(`cannot override ${l.map(u=>JSON.stringify(u)).join(",")}`,ve.errors.UNSUPPORTED_OPERATION,{operation:"overrides",overrides:l}),a})}s(Xg,"populateTransaction");function _V(t,e){return function(...r){return Xg(t,e,r)}}s(_V,"buildPopulate");function AV(t,e){let r=t.signer||t.provider;return function(...n){return Tf(this,void 0,void 0,function*(){r||jr.throwError("estimate require a provider or signer",ve.errors.UNSUPPORTED_OPERATION,{operation:"estimateGas"});let i=yield Xg(t,e,n);return yield r.estimateGas(i)})}}s(AV,"buildEstimate");function bk(t,e){let r=e.wait.bind(e);e.wait=n=>r(n).then(i=>(i.events=i.logs.map(o=>{let a=fn(o),f=null;try{f=t.interface.parseLog(o)}catch{}return f&&(a.args=f.args,a.decode=(l,u)=>t.interface.decodeEventLog(f.eventFragment,l,u),a.event=f.name,a.eventSignature=f.signature),a.removeListener=()=>t.provider,a.getBlock=()=>t.provider.getBlock(i.blockHash),a.getTransaction=()=>t.provider.getTransaction(i.transactionHash),a.getTransactionReceipt=()=>Promise.resolve(i),a}),i))}s(bk,"addContractWait");function vk(t,e,r){let n=t.signer||t.provider;return function(...i){return Tf(this,void 0,void 0,function*(){let o;if(i.length===e.inputs.length+1&&typeof i[i.length-1]=="object"){let l=Er(i.pop());l.blockTag!=null&&(o=yield l.blockTag),delete l.blockTag,i.push(l)}t.deployTransaction!=null&&(yield t._deployed(o));let a=yield Xg(t,e,i),f=yield n.call(a,o);try{let l=t.interface.decodeFunctionResult(e,f);return r&&e.outputs.length===1&&(l=l[0]),l}catch(l){throw l.code===ve.errors.CALL_EXCEPTION&&(l.address=t.address,l.args=i,l.transaction=a),l}})}}s(vk,"buildCall");function EV(t,e){return function(...r){return Tf(this,void 0,void 0,function*(){t.signer||jr.throwError("sending a transaction requires a signer",ve.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction"}),t.deployTransaction!=null&&(yield t._deployed());let n=yield Xg(t,e,r),i=yield t.signer.sendTransaction(n);return bk(t,i),i})}}s(EV,"buildSend");function gk(t,e,r){return e.constant?vk(t,e,r):EV(t,e)}s(gk,"buildDefault");function yk(t){return t.address&&(t.topics==null||t.topics.length===0)?"*":(t.address||"*")+"@"+(t.topics?t.topics.map(e=>Array.isArray(e)?e.join("|"):e).join(":"):"")}s(yk,"getEventTag");var kf=class{constructor(e,r){Pe(this,"tag",e),Pe(this,"filter",r),this._listeners=[]}addListener(e,r){this._listeners.push({listener:e,once:r})}removeListener(e){let r=!1;this._listeners=this._listeners.filter(n=>r||n.listener!==e?!0:(r=!0,!1))}removeAllListeners(){this._listeners=[]}listeners(){return this._listeners.map(e=>e.listener)}listenerCount(){return this._listeners.length}run(e){let r=this.listenerCount();return this._listeners=this._listeners.filter(n=>{let i=e.slice();return setTimeout(()=>{n.listener.apply(this,i)},0),!n.once}),r}prepareEvent(e){}getEmit(e){return[e]}};s(kf,"RunningEvent");var Yg=class extends kf{constructor(){super("error",null)}};s(Yg,"ErrorRunningEvent");var rp=class extends kf{constructor(e,r,n,i){let o={address:e},a=r.getEventTopic(n);i?(a!==i[0]&&jr.throwArgumentError("topic mismatch","topics",i),o.topics=i.slice()):o.topics=[a],super(yk(o),o),Pe(this,"address",e),Pe(this,"interface",r),Pe(this,"fragment",n)}prepareEvent(e){super.prepareEvent(e),e.event=this.fragment.name,e.eventSignature=this.fragment.format(),e.decode=(r,n)=>this.interface.decodeEventLog(this.fragment,r,n);try{e.args=this.interface.decodeEventLog(this.fragment,e.data,e.topics)}catch(r){e.args=null,e.decodeError=r}}getEmit(e){let r=Gu(e.args);if(r.length)throw r[0].error;let n=(e.args||[]).slice();return n.push(e),n}};s(rp,"FragmentRunningEvent");var np=class extends kf{constructor(e,r){super("*",{address:e}),Pe(this,"address",e),Pe(this,"interface",r)}prepareEvent(e){super.prepareEvent(e);try{let r=this.interface.parseLog(e);e.event=r.name,e.eventSignature=r.signature,e.decode=(n,i)=>this.interface.decodeEventLog(r.eventFragment,n,i),e.args=r.args}catch{}}};s(np,"WildcardRunningEvent");var ad=class{constructor(e,r,n){Pe(this,"interface",ln(new.target,"getInterface")(r)),n==null?(Pe(this,"provider",null),Pe(this,"signer",null)):Hi.isSigner(n)?(Pe(this,"provider",n.provider||null),Pe(this,"signer",n)):qi.isProvider(n)?(Pe(this,"provider",n),Pe(this,"signer",null)):jr.throwArgumentError("invalid signer or provider","signerOrProvider",n),Pe(this,"callStatic",{}),Pe(this,"estimateGas",{}),Pe(this,"functions",{}),Pe(this,"populateTransaction",{}),Pe(this,"filters",{});{let a={};Object.keys(this.interface.events).forEach(f=>{let l=this.interface.events[f];Pe(this.filters,f,(...u)=>({address:this.address,topics:this.interface.encodeFilterTopics(l,u)})),a[l.name]||(a[l.name]=[]),a[l.name].push(f)}),Object.keys(a).forEach(f=>{let l=a[f];l.length===1?Pe(this.filters,f,this.filters[l[0]]):jr.warn(`Duplicate definition of ${f} (${l.join(", ")})`)})}if(Pe(this,"_runningEvents",{}),Pe(this,"_wrappedEmits",{}),e==null&&jr.throwArgumentError("invalid contract address or ENS name","addressOrName",e),Pe(this,"address",e),this.provider)Pe(this,"resolvedAddress",Zg(this.provider,e));else try{Pe(this,"resolvedAddress",Promise.resolve(ar(e)))}catch{jr.throwError("provider is required to use ENS name as contract address",ve.errors.UNSUPPORTED_OPERATION,{operation:"new Contract"})}this.resolvedAddress.catch(a=>{});let i={},o={};Object.keys(this.interface.functions).forEach(a=>{let f=this.interface.functions[a];if(o[a]){jr.warn(`Duplicate ABI entry for ${JSON.stringify(a)}`);return}o[a]=!0;{let l=f.name;i[`%${l}`]||(i[`%${l}`]=[]),i[`%${l}`].push(a)}this[a]==null&&Pe(this,a,gk(this,f,!0)),this.functions[a]==null&&Pe(this.functions,a,gk(this,f,!1)),this.callStatic[a]==null&&Pe(this.callStatic,a,vk(this,f,!0)),this.populateTransaction[a]==null&&Pe(this.populateTransaction,a,_V(this,f)),this.estimateGas[a]==null&&Pe(this.estimateGas,a,AV(this,f))}),Object.keys(i).forEach(a=>{let f=i[a];if(f.length>1)return;a=a.substring(1);let l=f[0];try{this[a]==null&&Pe(this,a,this[l])}catch{}this.functions[a]==null&&Pe(this.functions,a,this.functions[l]),this.callStatic[a]==null&&Pe(this.callStatic,a,this.callStatic[l]),this.populateTransaction[a]==null&&Pe(this.populateTransaction,a,this.populateTransaction[l]),this.estimateGas[a]==null&&Pe(this.estimateGas,a,this.estimateGas[l])})}static getContractAddress(e){return kl(e)}static getInterface(e){return bc.isInterface(e)?e:new bc(e)}deployed(){return this._deployed()}_deployed(e){return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then(()=>this):this._deployedPromise=this.provider.getCode(this.address,e).then(r=>(r==="0x"&&jr.throwError("contract not deployed",ve.errors.UNSUPPORTED_OPERATION,{contractAddress:this.address,operation:"getDeployed"}),this))),this._deployedPromise}fallback(e){this.signer||jr.throwError("sending a transactions require a signer",ve.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});let r=Er(e||{});return["from","to"].forEach(function(n){r[n]!=null&&jr.throwError("cannot override "+n,ve.errors.UNSUPPORTED_OPERATION,{operation:n})}),r.to=this.resolvedAddress,this.deployed().then(()=>this.signer.sendTransaction(r))}connect(e){typeof e=="string"&&(e=new vc(e,this.provider));let r=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&Pe(r,"deployTransaction",this.deployTransaction),r}attach(e){return new this.constructor(e,this.interface,this.signer||this.provider)}static isIndexed(e){return xa.isIndexed(e)}_normalizeRunningEvent(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}_getRunningEvent(e){if(typeof e=="string"){if(e==="error")return this._normalizeRunningEvent(new Yg);if(e==="event")return this._normalizeRunningEvent(new kf("event",null));if(e==="*")return this._normalizeRunningEvent(new np(this.address,this.interface));let r=this.interface.getEvent(e);return this._normalizeRunningEvent(new rp(this.address,this.interface,r))}if(e.topics&&e.topics.length>0){try{let n=e.topics[0];if(typeof n!="string")throw new Error("invalid topic");let i=this.interface.getEvent(n);return this._normalizeRunningEvent(new rp(this.address,this.interface,i,e.topics))}catch{}let r={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new kf(yk(r),r))}return this._normalizeRunningEvent(new np(this.address,this.interface))}_checkRunningEvents(e){if(e.listenerCount()===0){delete this._runningEvents[e.tag];let r=this._wrappedEmits[e.tag];r&&e.filter&&(this.provider.off(e.filter,r),delete this._wrappedEmits[e.tag])}}_wrapEvent(e,r,n){let i=fn(r);return i.removeListener=()=>{!n||(e.removeListener(n),this._checkRunningEvents(e))},i.getBlock=()=>this.provider.getBlock(r.blockHash),i.getTransaction=()=>this.provider.getTransaction(r.transactionHash),i.getTransactionReceipt=()=>this.provider.getTransactionReceipt(r.transactionHash),e.prepareEvent(i),i}_addEventListener(e,r,n){if(this.provider||jr.throwError("events require a provider or a signer with a provider",ve.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(r,n),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){let i=s(o=>{let a=this._wrapEvent(e,o,r);if(a.decodeError==null)try{let f=e.getEmit(a);this.emit(e.filter,...f)}catch(f){a.decodeError=f.error}e.filter!=null&&this.emit("event",a),a.decodeError!=null&&this.emit("error",a.decodeError,a)},"wrappedEmit");this._wrappedEmits[e.tag]=i,e.filter!=null&&this.provider.on(e.filter,i)}}queryFilter(e,r,n){let i=this._getRunningEvent(e),o=Er(i.filter);return typeof r=="string"&&Pt(r,32)?(n!=null&&jr.throwArgumentError("cannot specify toBlock with blockhash","toBlock",n),o.blockHash=r):(o.fromBlock=r??0,o.toBlock=n??"latest"),this.provider.getLogs(o).then(a=>a.map(f=>this._wrapEvent(i,f,null)))}on(e,r){return this._addEventListener(this._getRunningEvent(e),r,!1),this}once(e,r){return this._addEventListener(this._getRunningEvent(e),r,!0),this}emit(e,...r){if(!this.provider)return!1;let n=this._getRunningEvent(e),i=n.run(r)>0;return this._checkRunningEvents(n),i}listenerCount(e){return this.provider?e==null?Object.keys(this._runningEvents).reduce((r,n)=>r+this._runningEvents[n].listenerCount(),0):this._getRunningEvent(e).listenerCount():0}listeners(e){if(!this.provider)return[];if(e==null){let r=[];for(let n in this._runningEvents)this._runningEvents[n].listeners().forEach(i=>{r.push(i)});return r}return this._getRunningEvent(e).listeners()}removeAllListeners(e){if(!this.provider)return this;if(e==null){for(let n in this._runningEvents){let i=this._runningEvents[n];i.removeAllListeners(),this._checkRunningEvents(i)}return this}let r=this._getRunningEvent(e);return r.removeAllListeners(),this._checkRunningEvents(r),this}off(e,r){if(!this.provider)return this;let n=this._getRunningEvent(e);return n.removeListener(r),this._checkRunningEvents(n),this}removeListener(e,r){return this.off(e,r)}};s(ad,"BaseContract");var Ol=class extends ad{};s(Ol,"Contract");var ip=class{constructor(e,r,n){let i=null;typeof r=="string"?i=r:eo(r)?i=Ve(r):r&&typeof r.object=="string"?i=r.object:i="!",i.substring(0,2)!=="0x"&&(i="0x"+i),(!Pt(i)||i.length%2)&&jr.throwArgumentError("invalid bytecode","bytecode",r),n&&!Hi.isSigner(n)&&jr.throwArgumentError("invalid signer","signer",n),Pe(this,"bytecode",i),Pe(this,"interface",ln(new.target,"getInterface")(e)),Pe(this,"signer",n||null)}getDeployTransaction(...e){let r={};if(e.length===this.interface.deploy.inputs.length+1&&typeof e[e.length-1]=="object"){r=Er(e.pop());for(let n in r)if(!wV[n])throw new Error("unknown transaction override "+n)}return["data","from","to"].forEach(n=>{r[n]!=null&&jr.throwError("cannot override "+n,ve.errors.UNSUPPORTED_OPERATION,{operation:n})}),r.value&&!ze.from(r.value).isZero()&&!this.interface.deploy.payable&&jr.throwError("non-payable constructor cannot override value",ve.errors.UNSUPPORTED_OPERATION,{operation:"overrides.value",value:r.value}),jr.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor"),r.data=Ve(sr([this.bytecode,this.interface.encodeDeploy(e)])),r}deploy(...e){return Tf(this,void 0,void 0,function*(){let r={};e.length===this.interface.deploy.inputs.length+1&&(r=e.pop()),jr.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor");let n=yield tp(this.signer,e,this.interface.deploy.inputs);n.push(r);let i=this.getDeployTransaction(...n),o=yield this.signer.sendTransaction(i),a=ln(this.constructor,"getContractAddress")(o),f=ln(this.constructor,"getContract")(a,this.interface,this.signer);return bk(f,o),Pe(f,"deployTransaction",o),f})}attach(e){return this.constructor.getContract(e,this.interface,this.signer)}connect(e){return new this.constructor(this.interface,this.bytecode,e)}static fromSolidity(e,r){e==null&&jr.throwError("missing compiler output",ve.errors.MISSING_ARGUMENT,{argument:"compilerOutput"}),typeof e=="string"&&(e=JSON.parse(e));let n=e.abi,i=null;return e.bytecode?i=e.bytecode:e.evm&&e.evm.bytecode&&(i=e.evm.bytecode),new this(n,i,r)}static getInterface(e){return Ol.getInterface(e)}static getContractAddress(e){return kl(e)}static getContract(e,r,n){return new Ol(e,r,n)}};s(ip,"ContractFactory");var sp=class{constructor(e){Pe(this,"alphabet",e),Pe(this,"base",e.length),Pe(this,"_alphabetMap",{}),Pe(this,"_leader",e.charAt(0));for(let r=0;r<e.length;r++)this._alphabetMap[e.charAt(r)]=r}encode(e){let r=je(e);if(r.length===0)return"";let n=[0];for(let o=0;o<r.length;++o){let a=r[o];for(let f=0;f<n.length;++f)a+=n[f]<<8,n[f]=a%this.base,a=a/this.base|0;for(;a>0;)n.push(a%this.base),a=a/this.base|0}let i="";for(let o=0;r[o]===0&&o<r.length-1;++o)i+=this._leader;for(let o=n.length-1;o>=0;--o)i+=this.alphabet[n[o]];return i}decode(e){if(typeof e!="string")throw new TypeError("Expected String");let r=[];if(e.length===0)return new Uint8Array(r);r.push(0);for(let n=0;n<e.length;n++){let i=this._alphabetMap[e[n]];if(i===void 0)throw new Error("Non-base"+this.base+" character");let o=i;for(let a=0;a<r.length;++a)o+=r[a]*this.base,r[a]=o&255,o>>=8;for(;o>0;)r.push(o&255),o>>=8}for(let n=0;e[n]===this._leader&&n<e.length-1;++n)r.push(0);return je(new Uint8Array(r.reverse()))}};s(sp,"BaseX");var Jfe=new sp("abcdefghijklmnopqrstuvwxyz234567"),_c=new sp("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz");var cd=Js(q3());var Ta;(function(t){t.sha256="sha256",t.sha512="sha512"})(Ta||(Ta={}));var xk="sha2/5.7.0";var CV=new ve(xk);function op(t){return"0x"+cd.default.ripemd160().update(je(t)).digest("hex")}s(op,"ripemd160");function ds(t){return"0x"+cd.default.sha256().update(je(t)).digest("hex")}s(ds,"sha256");function X3(t){return"0x"+cd.default.sha512().update(je(t)).digest("hex")}s(X3,"sha512");function Ac(t,e,r){return Ta[t]||CV.throwError("unsupported algorithm "+t,ve.errors.UNSUPPORTED_OPERATION,{operation:"hmac",algorithm:t}),"0x"+cd.default.hmac(cd.default[t],je(e)).update(je(r)).digest("hex")}s(Ac,"computeHmac");function Fl(t,e,r,n,i){t=je(t),e=je(e);let o,a=1,f=new Uint8Array(n),l=new Uint8Array(e.length+4);l.set(e);let u,h;for(let g=1;g<=a;g++){l[e.length]=g>>24&255,l[e.length+1]=g>>16&255,l[e.length+2]=g>>8&255,l[e.length+3]=g&255;let x=je(Ac(i,t,l));o||(o=x.length,h=new Uint8Array(o),a=Math.ceil(n/o),u=n-(a-1)*o),h.set(x);for(let T=1;T<r;T++){x=je(Ac(i,t,x));for(let B=0;B<o;B++)h[B]^=x[B]}let _=(g-1)*o,E=g===a?u:o;f.set(je(h).slice(0,E),_)}return Ve(f)}s(Fl,"pbkdf2");var wk="wordlists/5.7.0";var SV=!1,_k=new ve(wk),co=class{constructor(e){_k.checkAbstract(new.target,co),Pe(this,"locale",e)}split(e){return e.toLowerCase().split(/ +/g)}join(e){return e.join(" ")}static check(e){let r=[];for(let n=0;n<2048;n++){let i=e.getWord(n);if(n!==e.getWordIndex(i))return"0x";r.push(i)}return Ms(r.join(`
|
|
3
3
|
`)+`
|
|
4
4
|
`)}static register(e,r){if(r||(r=e.locale),SV)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[r]||Pe(n._ethers.wordlists,r,e))}catch{}}};s(co,"Wordlist");var IV="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ap=null;function Ak(t){if(ap==null&&(ap=IV.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),co.check(t)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ap=null,new Error("BIP39 Wordlist for en (English) FAILED")}s(Ak,"loadWords");var Qg=class extends co{constructor(){super("en")}getWord(e){return Ak(this),ap[e]}getWordIndex(e){return Ak(this),ap.indexOf(e)}};s(Qg,"LangEn");var Q3=new Qg;co.register(Q3);var fd={en:Q3};var Ek="hdnode/5.7.0";var cp=new ve(Ek),kV=ze.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),TV=Ar("Bitcoin seed"),ud=2147483648;function Sk(t){return(1<<t)-1<<8-t}s(Sk,"getUpperMask");function MV(t){return(1<<t)-1}s(MV,"getLowerMask");function eb(t){return ur(Ve(t),32)}s(eb,"bytes32");function Ck(t){return _c.encode(sr([t,Fr(ds(ds(t)),0,4)]))}s(Ck,"base58check");function e4(t){if(t==null)return fd.en;if(typeof t=="string"){let e=fd[t];return e==null&&cp.throwArgumentError("unknown locale","wordlist",t),e}return t}s(e4,"getWordlist");var ld={},Ec="m/44'/60'/0'/0/0",Ln=class{constructor(e,r,n,i,o,a,f,l){if(e!==ld)throw new Error("HDNode constructor cannot be called directly");if(r){let u=new Bs(r);Pe(this,"privateKey",u.privateKey),Pe(this,"publicKey",u.compressedPublicKey)}else Pe(this,"privateKey",null),Pe(this,"publicKey",Ve(n));Pe(this,"parentFingerprint",i),Pe(this,"fingerprint",Fr(op(ds(this.publicKey)),0,4)),Pe(this,"address",ao(this.publicKey)),Pe(this,"chainCode",o),Pe(this,"index",a),Pe(this,"depth",f),l==null?(Pe(this,"mnemonic",null),Pe(this,"path",null)):typeof l=="string"?(Pe(this,"mnemonic",null),Pe(this,"path",l)):(Pe(this,"mnemonic",l),Pe(this,"path",l.path))}get extendedKey(){if(this.depth>=256)throw new Error("Depth too large!");return Ck(sr([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",Ve(this.depth),this.parentFingerprint,ur(Ve(this.index),4),this.chainCode,this.privateKey!=null?sr(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new Ln(ld,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let r=this.path;r&&(r+="/"+(e&~ud));let n=new Uint8Array(37);if(e&ud){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(je(this.privateKey),1),r&&(r+="'")}else n.set(je(this.publicKey));for(let g=24;g>=0;g-=8)n[33+(g>>3)]=e>>24-g&255;let i=je(Ac(Ta.sha512,this.chainCode,n)),o=i.slice(0,32),a=i.slice(32),f=null,l=null;this.privateKey?f=eb(ze.from(o).add(this.privateKey).mod(kV)):l=new Bs(Ve(o))._addPoint(this.publicKey);let u=r,h=this.mnemonic;return h&&(u=Object.freeze({phrase:h.phrase,path:r,locale:h.locale||"en"})),new Ln(ld,f,l,this.fingerprint,eb(a),e,this.depth+1,u)}derivePath(e){let r=e.split("/");if(r.length===0||r[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);r[0]==="m"&&r.shift();let n=this;for(let i=0;i<r.length;i++){let o=r[i];if(o.match(/^[0-9]+'$/)){let a=parseInt(o.substring(0,o.length-1));if(a>=ud)throw new Error("invalid path index - "+o);n=n._derive(ud+a)}else if(o.match(/^[0-9]+$/)){let a=parseInt(o);if(a>=ud)throw new Error("invalid path index - "+o);n=n._derive(a)}else throw new Error("invalid path component - "+o)}return n}static _fromSeed(e,r){let n=je(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=je(Ac(Ta.sha512,TV,n));return new Ln(ld,eb(i.slice(0,32)),null,"0x00000000",eb(i.slice(32)),0,0,r)}static fromMnemonic(e,r,n){return n=e4(n),e=Nl(dd(e,n),n),Ln._fromSeed(t4(e,r),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return Ln._fromSeed(e,null)}static fromExtendedKey(e){let r=_c.decode(e);(r.length!==82||Ck(r.slice(0,78))!==e)&&cp.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=r[4],i=Ve(r.slice(5,9)),o=parseInt(Ve(r.slice(9,13)).substring(2),16),a=Ve(r.slice(13,45)),f=r.slice(45,78);switch(Ve(r.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new Ln(ld,null,Ve(f),i,a,o,n,null);case"0x0488ade4":case"0x04358394 ":if(f[0]!==0)break;return new Ln(ld,Ve(f.slice(1)),null,i,a,o,n,null)}return cp.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};s(Ln,"HDNode");function t4(t,e){e||(e="");let r=Ar("mnemonic"+e,ji.NFKD);return Fl(Ar(t,ji.NFKD),r,2048,64,"sha512")}s(t4,"mnemonicToSeed");function dd(t,e){e=e4(e),cp.checkNormalize();let r=e.split(t);if(r.length%3!==0)throw new Error("invalid mnemonic");let n=je(new Uint8Array(Math.ceil(11*r.length/8))),i=0;for(let u=0;u<r.length;u++){let h=e.getWordIndex(r[u].normalize("NFKD"));if(h===-1)throw new Error("invalid mnemonic");for(let g=0;g<11;g++)h&1<<10-g&&(n[i>>3]|=1<<7-i%8),i++}let o=32*r.length/3,a=r.length/3,f=Sk(a);if((je(ds(n.slice(0,o/8)))[0]&f)!==(n[n.length-1]&f))throw new Error("invalid checksum");return Ve(n.slice(0,o/8))}s(dd,"mnemonicToEntropy");function Nl(t,e){if(e=e4(e),t=je(t),t.length%4!==0||t.length<16||t.length>32)throw new Error("invalid entropy");let r=[0],n=11;for(let a=0;a<t.length;a++)n>8?(r[r.length-1]<<=8,r[r.length-1]|=t[a],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=t[a]>>8-n,r.push(t[a]&MV(8-n)),n+=3);let i=t.length/4,o=je(ds(t))[0]&Sk(i);return r[r.length-1]<<=i,r[r.length-1]|=o>>8-i,e.join(r.map(a=>e.getWord(a)))}s(Nl,"entropyToMnemonic");function Ik(t,e){try{return dd(t,e),!0}catch{}return!1}s(Ik,"isValidMnemonic");function kk(t){return(typeof t!="number"||t<0||t>=ud||t%1)&&cp.throwArgumentError("invalid account index","index",t),`m/44'/60'/${t}'/0/0`}s(kk,"getAccountPath");var Tk="random/5.7.0";var r4=new ve(Tk);function RV(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}s(RV,"getGlobal");var Mk=RV(),tb=Mk.crypto||Mk.msCrypto;(!tb||!tb.getRandomValues)&&(r4.warn("WARNING: Missing strong random number source"),tb={getRandomValues:function(t){return r4.throwError("no secure random source avaialble",ve.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Ma(t){(t<=0||t>1024||t%1||t!=t)&&r4.throwArgumentError("invalid length","length",t);let e=new Uint8Array(t);return tb.getRandomValues(e),je(e)}s(Ma,"randomBytes");function fp(t){t=t.slice();for(let e=t.length-1;e>0;e--){let r=Math.floor(Math.random()*(e+1)),n=t[e];t[e]=t[r],t[r]=n}return t}s(fp,"shuffled");var s4=Js(i4());var rb="json-wallets/5.7.0";function Cc(t){return typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),je(t)}s(Cc,"looseArrayify");function hd(t,e){for(t=String(t);t.length<e;)t="0"+t;return t}s(hd,"zpad");function lp(t){return typeof t=="string"?Ar(t,ji.NFKC):je(t)}s(lp,"getPassword");function hn(t,e){let r=t,n=e.toLowerCase().split("/");for(let i=0;i<n.length;i++){let o=null;for(let a in r)if(a.toLowerCase()===n[i]){o=r[a];break}if(o===null)return null;r=o}return r}s(hn,"searchPath");function Bk(t){let e=je(t);e[6]=e[6]&15|64,e[8]=e[8]&63|128;let r=Ve(e);return[r.substring(2,10),r.substring(10,14),r.substring(14,18),r.substring(18,22),r.substring(22,34)].join("-")}s(Bk,"uuidV4");var BV=new ve(rb),nb=class extends cs{isCrowdsaleAccount(e){return!!(e&&e._isCrowdsaleAccount)}};s(nb,"CrowdsaleAccount");function o4(t,e){let r=JSON.parse(t);e=lp(e);let n=ar(hn(r,"ethaddr")),i=Cc(hn(r,"encseed"));(!i||i.length%16!==0)&&BV.throwArgumentError("invalid encseed","json",t);let o=je(Fl(e,e,2e3,32,"sha256")).slice(0,16),a=i.slice(0,16),f=i.slice(16),l=new s4.default.ModeOfOperation.cbc(o,a),u=s4.default.padding.pkcs7.strip(je(l.decrypt(f))),h="";for(let _=0;_<u.length;_++)h+=String.fromCharCode(u[_]);let g=Ar(h),x=or(g);return new nb({_isCrowdsaleAccount:!0,address:n,privateKey:x})}s(o4,"decrypt");function ib(t){let e=null;try{e=JSON.parse(t)}catch{return!1}return e.encseed&&e.ethaddr}s(ib,"isCrowdsaleWallet");function sb(t){let e=null;try{e=JSON.parse(t)}catch{return!1}return!(!e.version||parseInt(e.version)!==e.version||parseInt(e.version)!==3)}s(sb,"isKeystoreWallet");function a4(t){if(ib(t))try{return ar(JSON.parse(t).ethaddr)}catch{return null}if(sb(t))try{return ar(JSON.parse(t).address)}catch{return null}return null}s(a4,"getJsonWalletAddress");var Sc=Js(i4()),ab=Js(Pk());var DV=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},f4=new ve(rb);function Ok(t){return t!=null&&t.mnemonic&&t.mnemonic.phrase}s(Ok,"hasMnemonic");var ob=class extends cs{isKeystoreAccount(e){return!!(e&&e._isKeystoreAccount)}};s(ob,"KeystoreAccount");function PV(t,e,r){if(hn(t,"crypto/cipher")==="aes-128-ctr"){let i=Cc(hn(t,"crypto/cipherparams/iv")),o=new Sc.default.Counter(i),a=new Sc.default.ModeOfOperation.ctr(e,o);return je(a.decrypt(r))}return null}s(PV,"_decrypt");function Fk(t,e){let r=Cc(hn(t,"crypto/ciphertext"));if(Ve(or(sr([e.slice(16,32),r]))).substring(2)!==hn(t,"crypto/mac").toLowerCase())throw new Error("invalid password");let i=PV(t,e.slice(0,16),r);i||f4.throwError("unsupported cipher",ve.errors.UNSUPPORTED_OPERATION,{operation:"decrypt"});let o=e.slice(32,64),a=ao(i);if(t.address){let l=t.address.toLowerCase();if(l.substring(0,2)!=="0x"&&(l="0x"+l),ar(l)!==a)throw new Error("address mismatch")}let f={_isKeystoreAccount:!0,address:a,privateKey:Ve(i)};if(hn(t,"x-ethers/version")==="0.1"){let l=Cc(hn(t,"x-ethers/mnemonicCiphertext")),u=Cc(hn(t,"x-ethers/mnemonicCounter")),h=new Sc.default.Counter(u),g=new Sc.default.ModeOfOperation.ctr(o,h),x=hn(t,"x-ethers/path")||Ec,_=hn(t,"x-ethers/locale")||"en",E=je(g.decrypt(l));try{let T=Nl(E,_),B=Ln.fromMnemonic(T,null,_).derivePath(x);if(B.privateKey!=f.privateKey)throw new Error("mnemonic mismatch");f.mnemonic=B.mnemonic}catch(T){if(T.code!==ve.errors.INVALID_ARGUMENT||T.argument!=="wordlist")throw T}}return new ob(f)}s(Fk,"_getAccount");function Nk(t,e,r,n,i){return je(Fl(t,e,r,n,i))}s(Nk,"pbkdf2Sync");function OV(t,e,r,n,i){return Promise.resolve(Nk(t,e,r,n,i))}s(OV,"pbkdf2");function Lk(t,e,r,n,i){let o=lp(e),a=hn(t,"crypto/kdf");if(a&&typeof a=="string"){let f=s(function(l,u){return f4.throwArgumentError("invalid key-derivation function parameters",l,u)},"throwError");if(a.toLowerCase()==="scrypt"){let l=Cc(hn(t,"crypto/kdfparams/salt")),u=parseInt(hn(t,"crypto/kdfparams/n")),h=parseInt(hn(t,"crypto/kdfparams/r")),g=parseInt(hn(t,"crypto/kdfparams/p"));(!u||!h||!g)&&f("kdf",a),(u&u-1)!==0&&f("N",u);let x=parseInt(hn(t,"crypto/kdfparams/dklen"));return x!==32&&f("dklen",x),n(o,l,u,h,g,64,i)}else if(a.toLowerCase()==="pbkdf2"){let l=Cc(hn(t,"crypto/kdfparams/salt")),u=null,h=hn(t,"crypto/kdfparams/prf");h==="hmac-sha256"?u="sha256":h==="hmac-sha512"?u="sha512":f("prf",h);let g=parseInt(hn(t,"crypto/kdfparams/c")),x=parseInt(hn(t,"crypto/kdfparams/dklen"));return x!==32&&f("dklen",x),r(o,l,g,x,u)}}return f4.throwArgumentError("unsupported key-derivation function","kdf",a)}s(Lk,"_computeKdfKey");function Uk(t,e){let r=JSON.parse(t),n=Lk(r,e,Nk,ab.default.syncScrypt);return Fk(r,n)}s(Uk,"decryptSync");function jk(t,e,r){return DV(this,void 0,void 0,function*(){let n=JSON.parse(t),i=yield Lk(n,e,OV,ab.default.scrypt,r);return Fk(n,i)})}s(jk,"decrypt");function l4(t,e,r,n){try{if(ar(t.address)!==ao(t.privateKey))throw new Error("address/privateKey mismatch");if(Ok(t)){let B=t.mnemonic;if(Ln.fromMnemonic(B.phrase,null,B.locale).derivePath(B.path||Ec).privateKey!=t.privateKey)throw new Error("mnemonic mismatch")}}catch(B){return Promise.reject(B)}typeof r=="function"&&!n&&(n=r,r={}),r||(r={});let i=je(t.privateKey),o=lp(e),a=null,f=null,l=null;if(Ok(t)){let B=t.mnemonic;a=je(dd(B.phrase,B.locale||"en")),f=B.path||Ec,l=B.locale||"en"}let u=r.client;u||(u="ethers.js");let h=null;r.salt?h=je(r.salt):h=Ma(32);let g=null;if(r.iv){if(g=je(r.iv),g.length!==16)throw new Error("invalid iv")}else g=Ma(16);let x=null;if(r.uuid){if(x=je(r.uuid),x.length!==16)throw new Error("invalid uuid")}else x=Ma(16);let _=1<<17,E=8,T=1;return r.scrypt&&(r.scrypt.N&&(_=r.scrypt.N),r.scrypt.r&&(E=r.scrypt.r),r.scrypt.p&&(T=r.scrypt.p)),ab.default.scrypt(o,h,_,E,T,64,n).then(B=>{B=je(B);let F=B.slice(0,16),H=B.slice(16,32),U=B.slice(32,64),q=new Sc.default.Counter(g),K=new Sc.default.ModeOfOperation.ctr(F,q),W=je(K.encrypt(i)),N=or(sr([H,W])),G={address:t.address.substring(2).toLowerCase(),id:Bk(x),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:Ve(g).substring(2)},ciphertext:Ve(W).substring(2),kdf:"scrypt",kdfparams:{salt:Ve(h).substring(2),n:_,dklen:32,p:T,r:E},mac:N.substring(2)}};if(a){let ce=Ma(16),re=new Sc.default.Counter(ce),ae=new Sc.default.ModeOfOperation.ctr(U,re),J=je(ae.encrypt(a)),S=new Date,m=S.getUTCFullYear()+"-"+hd(S.getUTCMonth()+1,2)+"-"+hd(S.getUTCDate(),2)+"T"+hd(S.getUTCHours(),2)+"-"+hd(S.getUTCMinutes(),2)+"-"+hd(S.getUTCSeconds(),2)+".0Z";G["x-ethers"]={client:u,gethFilename:"UTC--"+m+"--"+G.address,mnemonicCounter:Ve(ce).substring(2),mnemonicCiphertext:Ve(J).substring(2),path:f,locale:l,version:"0.1"}}return JSON.stringify(G)})}s(l4,"encrypt");function qk(t,e,r){if(ib(t)){r&&r(0);let n=o4(t,e);return r&&r(1),Promise.resolve(n)}return sb(t)?jk(t,e,r):Promise.reject(new Error("invalid JSON wallet"))}s(qk,"decryptJsonWallet");function Hk(t,e){if(ib(t))return o4(t,e);if(sb(t))return Uk(t,e);throw new Error("invalid JSON wallet")}s(Hk,"decryptJsonWalletSync");var zk="wallet/5.7.0";var $k=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},pd=new ve(zk);function FV(t){return t!=null&&Pt(t.privateKey,32)&&t.address!=null}s(FV,"isAccount");function NV(t){let e=t.mnemonic;return e&&e.phrase}s(NV,"hasMnemonic");var Ro=class extends Hi{constructor(e,r){if(super(),FV(e)){let n=new Bs(e.privateKey);if(Pe(this,"_signingKey",()=>n),Pe(this,"address",ao(this.publicKey)),this.address!==ar(e.address)&&pd.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),NV(e)){let i=e.mnemonic;Pe(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||Ec,locale:i.locale||"en"}));let o=this.mnemonic,a=Ln.fromMnemonic(o.phrase,null,o.locale).derivePath(o.path);ao(a.privateKey)!==this.address&&pd.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else Pe(this,"_mnemonic",()=>null)}else{if(Bs.isSigningKey(e))e.curve!=="secp256k1"&&pd.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),Pe(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new Bs(e);Pe(this,"_signingKey",()=>n)}Pe(this,"_mnemonic",()=>null),Pe(this,"address",ao(this.publicKey))}r&&!qi.isProvider(r)&&pd.throwArgumentError("invalid provider","provider",r),Pe(this,"provider",r||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Ro(this,e)}signTransaction(e){return Nr(e).then(r=>{r.from!=null&&(ar(r.from)!==this.address&&pd.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete r.from);let n=this._signingKey().signDigest(or(ep(r)));return ep(r,n)})}signMessage(e){return $k(this,void 0,void 0,function*(){return T0(this._signingKey().signDigest(Xu(e)))})}_signTypedData(e,r,n){return $k(this,void 0,void 0,function*(){let i=yield nn.resolveNames(e,r,n,o=>(this.provider==null&&pd.throwError("cannot resolve ENS names without a provider",ve.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:o}),this.provider.resolveName(o)));return T0(this._signingKey().signDigest(nn.hash(i.domain,r,i.value)))})}encrypt(e,r,n){if(typeof r=="function"&&!n&&(n=r,r={}),n&&typeof n!="function")throw new Error("invalid callback");return r||(r={}),l4(this,e,r,n)}static createRandom(e){let r=Ma(16);e||(e={}),e.extraEntropy&&(r=je(Fr(or(sr([r,e.extraEntropy])),0,16)));let n=Nl(r,e.locale);return Ro.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,r,n){return qk(e,r,n).then(i=>new Ro(i))}static fromEncryptedJsonSync(e,r){return new Ro(Hk(e,r))}static fromMnemonic(e,r,n){return r||(r=Ec),new Ro(Ln.fromMnemonic(e,null,n).derivePath(r))}};s(Ro,"Wallet");function Gk(t,e){return Pl(Xu(t),e)}s(Gk,"verifyMessage");function Kk(t,e,r,n){return Pl(nn.hash(t,e,r),n)}s(Kk,"verifyTypedData");var E4={};vl(E4,{AlchemyProvider:()=>jl,AlchemyWebSocketProvider:()=>yd,AnkrProvider:()=>xd,BaseProvider:()=>Oo,CloudflareProvider:()=>wd,EtherscanProvider:()=>_d,FallbackProvider:()=>Ed,Formatter:()=>xt,InfuraProvider:()=>Hl,InfuraWebSocketProvider:()=>Cd,IpcProvider:()=>w4,JsonRpcBatchProvider:()=>_p,JsonRpcProvider:()=>zi,JsonRpcSigner:()=>Ul,NodesmithProvider:()=>Sd,PocketProvider:()=>Id,Provider:()=>qi,Resolver:()=>Ll,StaticJsonRpcProvider:()=>vd,UrlJsonRpcProvider:()=>Un,Web3Provider:()=>kd,WebSocketProvider:()=>Ba,getDefaultProvider:()=>A4,getNetwork:()=>up,isCommunityResourcable:()=>h4,isCommunityResource:()=>pp,showThrottleMessage:()=>Ra});var Vk="networks/5.7.1";var Wk=new ve(Vk);function LV(t){return t&&typeof t.renetwork=="function"}s(LV,"isRenetworkable");function Ic(t){let e=s(function(r,n){n==null&&(n={});let i=[];if(r.InfuraProvider&&n.infura!=="-")try{i.push(new r.InfuraProvider(t,n.infura))}catch{}if(r.EtherscanProvider&&n.etherscan!=="-")try{i.push(new r.EtherscanProvider(t,n.etherscan))}catch{}if(r.AlchemyProvider&&n.alchemy!=="-")try{i.push(new r.AlchemyProvider(t,n.alchemy))}catch{}if(r.PocketProvider&&n.pocket!=="-"){let o=["goerli","ropsten","rinkeby","sepolia"];try{let a=new r.PocketProvider(t,n.pocket);a.network&&o.indexOf(a.network.name)===-1&&i.push(a)}catch{}}if(r.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new r.CloudflareProvider(t))}catch{}if(r.AnkrProvider&&n.ankr!=="-")try{let o=["ropsten"],a=new r.AnkrProvider(t,n.ankr);a.network&&o.indexOf(a.network.name)===-1&&i.push(a)}catch{}if(i.length===0)return null;if(r.FallbackProvider){let o=1;return n.quorum!=null?o=n.quorum:t==="homestead"&&(o=2),new r.FallbackProvider(i,o)}return i[0]},"func");return e.renetwork=function(r){return Ic(r)},e}s(Ic,"ethDefaultProvider");function fb(t,e){let r=s(function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(t,e):null},"func");return r.renetwork=function(n){return fb(t,n)},r}s(fb,"etcDefaultProvider");var Jk={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:Ic("homestead")},Yk={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:Ic("ropsten")},Zk={chainId:63,name:"classicMordor",_defaultProvider:fb("https://www.ethercluster.com/mordor","classicMordor")},cb={unspecified:{chainId:0,name:"unspecified"},homestead:Jk,mainnet:Jk,morden:{chainId:2,name:"morden"},ropsten:Yk,testnet:Yk,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:Ic("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:Ic("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:Ic("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:Ic("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:fb("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Zk,classicTestnet:Zk,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:fb("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:Ic("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:Ic("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function up(t){if(t==null)return null;if(typeof t=="number"){for(let n in cb){let i=cb[n];if(i.chainId===t)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:t,name:"unknown"}}if(typeof t=="string"){let n=cb[t];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=cb[t.name];if(!e)return typeof t.chainId!="number"&&Wk.throwArgumentError("invalid network chainId","network",t),t;t.chainId!==0&&t.chainId!==e.chainId&&Wk.throwArgumentError("network chainId mismatch","network",t);let r=t._defaultProvider||null;return r==null&&e._defaultProvider&&(LV(e._defaultProvider)?r=e._defaultProvider.renetwork(t):r=e._defaultProvider),{name:t.name,chainId:e.chainId,ensAddress:t.ensAddress||e.ensAddress||null,_defaultProvider:r}}s(up,"getNetwork");var Xk="web/5.7.1";var UV=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})};function Qk(t,e){return UV(this,void 0,void 0,function*(){e==null&&(e={});let r={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(r.mode="cors",r.cache="no-cache",r.credentials="same-origin",r.redirect="follow",r.referrer="client"),e.fetchOptions!=null){let a=e.fetchOptions;a.mode&&(r.mode=a.mode),a.cache&&(r.cache=a.cache),a.credentials&&(r.credentials=a.credentials),a.redirect&&(r.redirect=a.redirect),a.referrer&&(r.referrer=a.referrer)}let n=yield fetch(t,r),i=yield n.arrayBuffer(),o={};return n.headers.forEach?n.headers.forEach((a,f)=>{o[f.toLowerCase()]=a}):n.headers.keys().forEach(a=>{o[a.toLowerCase()]=n.headers.get(a)}),{headers:o,statusCode:n.status,statusMessage:n.statusText,body:je(new Uint8Array(i))}})}s(Qk,"getUrl");var jV=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},Bo=new ve(Xk);function eT(t){return new Promise(e=>{setTimeout(e,t)})}s(eT,"staller");function Mf(t,e){if(t==null)return null;if(typeof t=="string")return t;if(pc(t)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return ls(t)}catch{}return Ve(t)}return t}s(Mf,"bodyify");function qV(t){return Ar(t.replace(/%([0-9a-f][0-9a-f])/gi,(e,r)=>String.fromCharCode(parseInt(r,16))))}s(qV,"unpercent");function u4(t,e,r){let n=typeof t=="object"&&t.throttleLimit!=null?t.throttleLimit:12;Bo.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof t=="object"?t.throttleCallback:null,o=typeof t=="object"&&typeof t.throttleSlotInterval=="number"?t.throttleSlotInterval:100;Bo.assertArgument(o>0&&o%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",o);let a=typeof t=="object"?!!t.errorPassThrough:!1,f={},l=null,u={method:"GET"},h=!1,g=2*60*1e3;if(typeof t=="string")l=t;else if(typeof t=="object"){if((t==null||t.url==null)&&Bo.throwArgumentError("missing URL","connection.url",t),l=t.url,typeof t.timeout=="number"&&t.timeout>0&&(g=t.timeout),t.headers)for(let F in t.headers)f[F.toLowerCase()]={key:F,value:String(t.headers[F])},["if-none-match","if-modified-since"].indexOf(F.toLowerCase())>=0&&(h=!0);if(u.allowGzip=!!t.allowGzip,t.user!=null&&t.password!=null){l.substring(0,6)!=="https:"&&t.allowInsecureAuthentication!==!0&&Bo.throwError("basic authentication requires a secure https url",ve.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:t.user,password:"[REDACTED]"});let F=t.user+":"+t.password;f.authorization={key:"Authorization",value:"Basic "+Zu(Ar(F))}}t.skipFetchSetup!=null&&(u.skipFetchSetup=!!t.skipFetchSetup),t.fetchOptions!=null&&(u.fetchOptions=Er(t.fetchOptions))}let x=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(x):null;if(_)try{let F={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?Yu(_[3]):qV(_[3])},H=F.body;return r&&(H=r(F.body,F)),Promise.resolve(H)}catch(F){Bo.throwError("processing response error",ve.errors.SERVER_ERROR,{body:Mf(_[1],_[2]),error:F,requestBody:null,requestMethod:"GET",url:l})}e&&(u.method="POST",u.body=e,f["content-type"]==null&&(f["content-type"]={key:"Content-Type",value:"application/octet-stream"}),f["content-length"]==null&&(f["content-length"]={key:"Content-Length",value:String(e.length)}));let E={};Object.keys(f).forEach(F=>{let H=f[F];E[H.key]=H.value}),u.headers=E;let T=function(){let F=null;return{promise:new Promise(function(q,K){g&&(F=setTimeout(()=>{F!=null&&(F=null,K(Bo.makeError("timeout",ve.errors.TIMEOUT,{requestBody:Mf(u.body,E["content-type"]),requestMethod:u.method,timeout:g,url:l})))},g))}),cancel:s(function(){F!=null&&(clearTimeout(F),F=null)},"cancel")}}(),B=function(){return jV(this,void 0,void 0,function*(){for(let F=0;F<n;F++){let H=null;try{if(H=yield Qk(l,u),F<n){if(H.statusCode===301||H.statusCode===302){let q=H.headers.location||"";if(u.method==="GET"&&q.match(/^https:/)){l=H.headers.location;continue}}else if(H.statusCode===429){let q=!0;if(i&&(q=yield i(F,l)),q){let K=0,W=H.headers["retry-after"];typeof W=="string"&&W.match(/^[1-9][0-9]*$/)?K=parseInt(W)*1e3:K=o*parseInt(String(Math.random()*Math.pow(2,F))),yield eT(K);continue}}}}catch(q){H=q.response,H==null&&(T.cancel(),Bo.throwError("missing response",ve.errors.SERVER_ERROR,{requestBody:Mf(u.body,E["content-type"]),requestMethod:u.method,serverError:q,url:l}))}let U=H.body;if(h&&H.statusCode===304?U=null:!a&&(H.statusCode<200||H.statusCode>=300)&&(T.cancel(),Bo.throwError("bad response",ve.errors.SERVER_ERROR,{status:H.statusCode,headers:H.headers,body:Mf(U,H.headers?H.headers["content-type"]:null),requestBody:Mf(u.body,E["content-type"]),requestMethod:u.method,url:l})),r)try{let q=yield r(U,H);return T.cancel(),q}catch(q){if(q.throttleRetry&&F<n){let K=!0;if(i&&(K=yield i(F,l)),K){let W=o*parseInt(String(Math.random()*Math.pow(2,F)));yield eT(W);continue}}T.cancel(),Bo.throwError("processing response error",ve.errors.SERVER_ERROR,{body:Mf(U,H.headers?H.headers["content-type"]:null),error:q,requestBody:Mf(u.body,E["content-type"]),requestMethod:u.method,url:l})}return T.cancel(),U}return Bo.throwError("failed response",ve.errors.SERVER_ERROR,{requestBody:Mf(u.body,E["content-type"]),requestMethod:u.method,url:l})})}();return Promise.race([T.promise,B])}s(u4,"_fetchData");function Do(t,e,r){let n=s((o,a)=>{let f=null;if(o!=null)try{f=JSON.parse(ls(o))}catch(l){Bo.throwError("invalid JSON",ve.errors.SERVER_ERROR,{body:o,error:l})}return r&&(f=r(f,a)),f},"processJsonFunc"),i=null;if(e!=null){i=Ar(e);let o=typeof t=="string"?{url:t}:Er(t);o.headers?Object.keys(o.headers).filter(f=>f.toLowerCase()==="content-type").length!==0||(o.headers=Er(o.headers),o.headers["content-type"]="application/json"):o.headers={"content-type":"application/json"},t=o}return u4(t,i,n)}s(Do,"fetchJson");function Po(t,e){return e||(e={}),e=Er(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(r,n){let i=null,o=!1,a=s(()=>o?!1:(o=!0,i&&clearTimeout(i),!0),"cancel");e.timeout&&(i=setTimeout(()=>{a()&&n(new Error("timeout"))},e.timeout));let f=e.retryLimit,l=0;function u(){return t().then(function(h){if(h!==void 0)a()&&r(h);else if(e.oncePoll)e.oncePoll.once("poll",u);else if(e.onceBlock)e.onceBlock.once("block",u);else if(!o){if(l++,l>f){a()&&n(new Error("retry limit reached"));return}let g=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));g<e.floor&&(g=e.floor),g>e.ceiling&&(g=e.ceiling),setTimeout(u,g)}return null},function(h){a()&&n(h)})}s(u,"check"),u()})}s(Po,"poll");var b4=Js(iT());var Sr="providers/5.7.2";var hp=new ve(Sr),xt=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},r=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),o=this.data.bind(this),a=this.hash.bind(this),f=this.hex.bind(this),l=this.number.bind(this),u=this.type.bind(this),h=s(g=>this.data(g,!0),"strictData");return e.transaction={hash:a,type:u,accessList:xt.allowNull(this.accessList.bind(this),null),blockHash:xt.allowNull(a,null),blockNumber:xt.allowNull(l,null),transactionIndex:xt.allowNull(l,null),confirmations:xt.allowNull(l,null),from:r,gasPrice:xt.allowNull(n),maxPriorityFeePerGas:xt.allowNull(n),maxFeePerGas:xt.allowNull(n),gasLimit:n,to:xt.allowNull(r,null),value:n,nonce:l,data:o,r:xt.allowNull(this.uint256),s:xt.allowNull(this.uint256),v:xt.allowNull(l),creates:xt.allowNull(r,null),raw:xt.allowNull(o)},e.transactionRequest={from:xt.allowNull(r),nonce:xt.allowNull(l),gasLimit:xt.allowNull(n),gasPrice:xt.allowNull(n),maxPriorityFeePerGas:xt.allowNull(n),maxFeePerGas:xt.allowNull(n),to:xt.allowNull(r),value:xt.allowNull(n),data:xt.allowNull(h),type:xt.allowNull(l),accessList:xt.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:a,address:r,topics:xt.arrayOf(a),data:o,logIndex:l,blockHash:a},e.receipt={to:xt.allowNull(this.address,null),from:xt.allowNull(this.address,null),contractAddress:xt.allowNull(r,null),transactionIndex:l,root:xt.allowNull(f),gasUsed:n,logsBloom:xt.allowNull(o),blockHash:a,transactionHash:a,logs:xt.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:xt.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:xt.allowNull(n),status:xt.allowNull(l),type:u},e.block={hash:xt.allowNull(a),parentHash:a,number:l,timestamp:l,nonce:xt.allowNull(f),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:xt.allowNull(r),extraData:o,transactions:xt.allowNull(xt.arrayOf(a)),baseFeePerGas:xt.allowNull(n)},e.blockWithTransactions=Er(e.block),e.blockWithTransactions.transactions=xt.allowNull(xt.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:xt.allowNull(i,void 0),toBlock:xt.allowNull(i,void 0),blockHash:xt.allowNull(a,void 0),address:xt.allowNull(r,void 0),topics:xt.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:xt.allowNull(l),blockHash:xt.allowNull(a),transactionIndex:l,removed:xt.allowNull(this.boolean.bind(this)),address:r,data:xt.allowFalsish(o,"0x"),topics:xt.arrayOf(a),transactionHash:a,logIndex:l},e}accessList(e){return Ps(e||[])}number(e){return e==="0x"?0:ze.from(e).toNumber()}type(e){return e==="0x"||e==null?0:ze.from(e).toNumber()}bigNumber(e){return ze.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,r){return typeof e=="string"&&(!r&&e.substring(0,2)!=="0x"&&(e="0x"+e),Pt(e))?e.toLowerCase():hp.throwArgumentError("invalid hash","value",e)}data(e,r){let n=this.hex(e,r);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ar(e)}callAddress(e){if(!Pt(e,32))return null;let r=ar(Fr(e,12));return r===Tg?null:r}contractAddress(e){return kl(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||Pt(e))return ma(e);throw new Error("invalid blockTag")}hash(e,r){let n=this.hex(e,r);return Ei(n)!==32?hp.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let r=ze.from(e);try{return r.toNumber()}catch{}return null}uint256(e){if(!Pt(e))throw new Error("invalid uint256");return ur(e,32)}_block(e,r){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=xt.check(r,e);return i._difficulty=n==null?null:ze.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return xt.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&ze.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let r=xt.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;Pt(n)&&(n=ze.from(n).toNumber()),r.chainId=n}else{let n=e.networkId;n==null&&r.v==null&&(n=e.chainId),Pt(n)&&(n=ze.from(n).toNumber()),typeof n!="number"&&r.v!=null&&(n=(r.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),r.chainId=n}return r.blockHash&&r.blockHash.replace(/0/g,"")==="x"&&(r.blockHash=null),r}transaction(e){return Jg(e)}receiptLog(e){return xt.check(this.formats.receiptLog,e)}receipt(e){let r=xt.check(this.formats.receipt,e);if(r.root!=null)if(r.root.length<=4){let n=ze.from(r.root).toNumber();n===0||n===1?(r.status!=null&&r.status!==n&&hp.throwArgumentError("alt-root-status/status mismatch","value",{root:r.root,status:r.status}),r.status=n,delete r.root):hp.throwArgumentError("invalid alt-root-status","value.root",r.root)}else r.root.length!==66&&hp.throwArgumentError("invalid root hash","value.root",r.root);return r.status!=null&&(r.byzantium=!0),r}topics(e){return Array.isArray(e)?e.map(r=>this.topics(r)):e!=null?this.hash(e,!0):null}filter(e){return xt.check(this.formats.filter,e)}filterLog(e){return xt.check(this.formats.filterLog,e)}static check(e,r){let n={};for(let i in e)try{let o=e[i](r[i]);o!==void 0&&(n[i]=o)}catch(o){throw o.checkKey=i,o.checkValue=r[i],o}return n}static allowNull(e,r){return function(n){return n==null?r:e(n)}}static allowFalsish(e,r){return function(n){return n?e(n):r}}static arrayOf(e){return function(r){if(!Array.isArray(r))throw new Error("not an array");let n=[];return r.forEach(function(i){n.push(e(i))}),n}}};s(xt,"Formatter");function h4(t){return t&&typeof t.isCommunityResource=="function"}s(h4,"isCommunityResourcable");function pp(t){return h4(t)&&t.isCommunityResource()}s(pp,"isCommunityResource");var sT=!1;function Ra(){sT||(sT=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}s(Ra,"showThrottleMessage");var $t=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},dr=new ve(Sr),JV=10;function oT(t){return t==null?"null":(Ei(t)!==32&&dr.throwArgumentError("invalid topic","topic",t),t.toLowerCase())}s(oT,"checkTopic");function aT(t){for(t=t.slice();t.length>0&&t[t.length-1]==null;)t.pop();return t.map(e=>{if(Array.isArray(e)){let r={};e.forEach(i=>{r[oT(i)]=!0});let n=Object.keys(r);return n.sort(),n.join("|")}else return oT(e)}).join("&")}s(aT,"serializeTopics");function YV(t){return t===""?[]:t.split(/&/g).map(e=>{if(e==="")return[];let r=e.split("|").map(n=>n==="null"?null:n);return r.length===1?r[0]:r})}s(YV,"deserializeTopics");function gd(t){if(typeof t=="string"){if(t=t.toLowerCase(),Ei(t)===32)return"tx:"+t;if(t.indexOf(":")===-1)return t}else{if(Array.isArray(t))return"filter:*:"+aT(t);if(Y0.isForkEvent(t))throw dr.warn("not implemented"),new Error("not implemented");if(t&&typeof t=="object")return"filter:"+(t.address||"*")+":"+aT(t.topics||[])}throw new Error("invalid event - "+t)}s(gd,"getEventTag");function mp(){return new Date().getTime()}s(mp,"getTime");function cT(t){return new Promise(e=>{setTimeout(e,t)})}s(cT,"stall");var ZV=["block","network","pending","poll"],hb=class{constructor(e,r,n){Pe(this,"tag",e),Pe(this,"listener",r),Pe(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let r=e[1],n=YV(e[2]),i={};return n.length>0&&(i.topics=n),r&&r!=="*"&&(i.address=r),i}pollable(){return this.tag.indexOf(":")>=0||ZV.indexOf(this.tag)>=0}};s(hb,"Event");var XV={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function p4(t){return ur(ze.from(t).toHexString(),32)}s(p4,"bytes32ify");function fT(t){return _c.encode(sr([t,Fr(ds(ds(t)),0,4)]))}s(fT,"base58Encode");var dT=new RegExp("^(ipfs)://(.*)$","i"),lT=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),dT,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function pb(t,e){try{return ls(gp(t,e))}catch{}return null}s(pb,"_parseString");function gp(t,e){if(t==="0x")return null;let r=ze.from(Fr(t,e,e+32)).toNumber(),n=ze.from(Fr(t,r,r+32)).toNumber();return Fr(t,r+32,r+32+n)}s(gp,"_parseBytes");function m4(t){return t.match(/^ipfs:\/\/ipfs\//i)?t=t.substring(12):t.match(/^ipfs:\/\//i)?t=t.substring(7):dr.throwArgumentError("unsupported IPFS format","link",t),`https://gateway.ipfs.io/ipfs/${t}`}s(m4,"getIpfsLink");function uT(t){let e=je(t);if(e.length>32)throw new Error("internal; should not happen");let r=new Uint8Array(32);return r.set(e,32-e.length),r}s(uT,"numPad");function QV(t){if(t.length%32===0)return t;let e=new Uint8Array(Math.ceil(t.length/32)*32);return e.set(t),e}s(QV,"bytesPad");function hT(t){let e=[],r=0;for(let n=0;n<t.length;n++)e.push(null),r+=32;for(let n=0;n<t.length;n++){let i=je(t[n]);e[n]=uT(r),e.push(uT(i.length)),e.push(QV(i)),r+=32+Math.ceil(i.length/32)*32}return Mn(e)}s(hT,"encodeBytes");var Ll=class{constructor(e,r,n,i){Pe(this,"provider",e),Pe(this,"name",n),Pe(this,"address",e.formatter.address(r)),Pe(this,"_resolvedAddress",i)}supportsWildcard(){return this._supportsEip2544||(this._supportsEip2544=this.provider.call({to:this.address,data:"0x01ffc9a79061b92300000000000000000000000000000000000000000000000000000000"}).then(e=>ze.from(e).eq(1)).catch(e=>{if(e.code===ve.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,r){return $t(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:Mn([e,Ef(this.name),r||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=Mn(["0x9061b923",hT([J0(this.name),n.data])]));try{let o=yield this.provider.call(n);return je(o).length%32===4&&dr.throwError("resolver threw error",ve.errors.CALL_EXCEPTION,{transaction:n,data:o}),i&&(o=gp(o,0)),o}catch(o){if(o.code===ve.errors.CALL_EXCEPTION)return null;throw o}})}_fetchBytes(e,r){return $t(this,void 0,void 0,function*(){let n=yield this._fetch(e,r);return n!=null?gp(n,0):null})}_getAddress(e,r){let n=XV[String(e)];if(n==null&&dr.throwError(`unsupported coin type: ${e}`,ve.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(r);let i=je(r);if(n.p2pkh!=null){let o=r.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(o){let a=parseInt(o[1],16);if(o[2].length===a*2&&a>=1&&a<=75)return fT(sr([[n.p2pkh],"0x"+o[2]]))}}if(n.p2sh!=null){let o=r.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(o){let a=parseInt(o[1],16);if(o[2].length===a*2&&a>=1&&a<=75)return fT(sr([[n.p2sh],"0x"+o[2]]))}}if(n.prefix!=null){let o=i[1],a=i[0];if(a===0?o!==20&&o!==32&&(a=-1):a=-1,a>=0&&i.length===2+o&&o>=1&&o<=75){let f=b4.default.toWords(i.slice(2));return f.unshift(a),b4.default.encode(n.prefix,f)}}return null}getAddress(e){return $t(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Ju?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===ve.errors.CALL_EXCEPTION)return null;throw i}let r=yield this._fetchBytes("0xf1cb7e06",p4(e));if(r==null||r==="0x")return null;let n=this._getAddress(e,r);return n==null&&dr.throwError("invalid or unsupported coin data",ve.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:r}),n})}getAvatar(){return $t(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let r=yield this.getText("avatar");if(r==null)return null;for(let n=0;n<lT.length;n++){let i=r.match(lT[n]);if(i==null)continue;let o=i[1].toLowerCase();switch(o){case"https":return e.push({type:"url",content:r}),{linkage:e,url:r};case"data":return e.push({type:"data",content:r}),{linkage:e,url:r};case"ipfs":return e.push({type:"ipfs",content:r}),{linkage:e,url:m4(r)};case"erc721":case"erc1155":{let a=o==="erc721"?"0xc87b56dd":"0x0e89341c";e.push({type:o,content:r});let f=this._resolvedAddress||(yield this.getAddress()),l=(i[2]||"").split("/");if(l.length!==2)return null;let u=yield this.provider.formatter.address(l[0]),h=ur(ze.from(l[1]).toHexString(),32);if(o==="erc721"){let T=this.provider.formatter.callAddress(yield this.provider.call({to:u,data:Mn(["0x6352211e",h])}));if(f!==T)return null;e.push({type:"owner",content:T})}else if(o==="erc1155"){let T=ze.from(yield this.provider.call({to:u,data:Mn(["0x00fdd58e",ur(f,32),h])}));if(T.isZero())return null;e.push({type:"balance",content:T.toString()})}let g={to:this.provider.formatter.address(l[0]),data:Mn([a,h])},x=pb(yield this.provider.call(g),0);if(x==null)return null;e.push({type:"metadata-url-base",content:x}),o==="erc1155"&&(x=x.replace("{id}",h.substring(2)),e.push({type:"metadata-url-expanded",content:x})),x.match(/^ipfs:/i)&&(x=m4(x)),e.push({type:"metadata-url",content:x});let _=yield Do(x);if(!_)return null;e.push({type:"metadata",content:JSON.stringify(_)});let E=_.image;if(typeof E!="string")return null;if(!E.match(/^(https:\/\/|data:)/i)){if(E.match(dT)==null)return null;e.push({type:"url-ipfs",content:E}),E=m4(E)}return e.push({type:"url",content:E}),{linkage:e,url:E}}}}}catch{}return null})}getContentHash(){return $t(this,void 0,void 0,function*(){let e=yield this._fetchBytes("0xbc1c58d1");if(e==null||e==="0x")return null;let r=e.match(/^0xe3010170(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(r){let a=parseInt(r[3],16);if(r[4].length===a*2)return"ipfs://"+_c.encode("0x"+r[1])}let n=e.match(/^0xe5010172(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(n){let a=parseInt(n[3],16);if(n[4].length===a*2)return"ipns://"+_c.encode("0x"+n[1])}let i=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(i&&i[1].length===32*2)return"bzz://"+i[1];let o=e.match(/^0x90b2c605([0-9a-f]*)$/);if(o&&o[1].length===34*2){let a={"=":"","+":"-","/":"_"},f=Zu("0x"+o[1]).replace(/[=+\/]/g,l=>a[l]);return"sia://"+f}return dr.throwError("invalid or unsupported content hash data",ve.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return $t(this,void 0,void 0,function*(){let r=Ar(e);r=sr([p4(64),p4(r.length),r]),r.length%32!==0&&(r=sr([r,ur("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",Ve(r));return n==null||n==="0x"?null:ls(n)})}};s(Ll,"Resolver");var g4=null,eW=1,Oo=class extends qi{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),Pe(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(r=>{}),this._ready().catch(r=>{});else{let r=ln(new.target,"getNetwork")(e);r?(Pe(this,"_network",r),this.emit("network",r,null)):dr.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return $t(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||dr.throwError("no network detected",ve.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:Pe(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Po(()=>this._ready().then(e=>e,e=>{if(!(e.code===ve.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return g4==null&&(g4=new xt),g4}static getNetwork(e){return up(e??"homestead")}ccipReadFetch(e,r,n){return $t(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),o=r.toLowerCase(),a=[];for(let f=0;f<n.length;f++){let l=n[f],u=l.replace("{sender}",i).replace("{data}",o),h=l.indexOf("{data}")>=0?null:JSON.stringify({data:o,sender:i}),g=yield Do({url:u,errorPassThrough:!0},h,(_,E)=>(_.status=E.statusCode,_));if(g.data)return g.data;let x=g.message||"unknown error";if(g.status>=400&&g.status<500)return dr.throwError(`response not found during CCIP fetch: ${x}`,ve.errors.SERVER_ERROR,{url:l,errorMessage:x});a.push(x)}return dr.throwError(`error encountered during CCIP fetch: ${a.map(f=>JSON.stringify(f)).join(", ")}`,ve.errors.SERVER_ERROR,{urls:n,errorMessages:a})})}_getInternalBlockNumber(e){return $t(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let o=yield i;if(mp()-o.respTime<=e)return o.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let r=mp(),n=Nr({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:o})=>{if(o)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),o;let a=mp();return i=ze.from(i).toNumber(),i<this._maxInternalBlockNumber&&(i=this._maxInternalBlockNumber),this._maxInternalBlockNumber=i,this._setFastBlockNumber(i),{blockNumber:i,reqTime:r,respTime:a}});return this._internalBlockNumber=n,n.catch(i=>{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return $t(this,void 0,void 0,function*(){let e=eW++,r=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)dr.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",dr.makeError("network block skew detected",ve.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let o=this._emitted[i];o!=="pending"&&n-o>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let o=i.hash,a=this.getTransactionReceipt(o).then(f=>(!f||f.blockNumber==null||(this._emitted["t:"+o]=f.blockNumber,this.emit(o,f)),null)).catch(f=>{this.emit("error",f)});r.push(a);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let o=i.filter;o.fromBlock=i._lastBlockNumber+1,o.toBlock=n;let a=o.toBlock-this._maxFilterBlockRange;a>o.fromBlock&&(o.fromBlock=a),o.fromBlock<0&&(o.fromBlock=0);let f=this.getLogs(o).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(u=>{u.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=u.blockNumber),this._emitted["b:"+u.blockHash]=u.blockNumber,this._emitted["t:"+u.transactionHash]=u.blockNumber,this.emit(o,u)})}).catch(l=>{this.emit("error",l),i._inflight=!1});r.push(f)}break}}}),this._lastBlockNumber=n,Promise.all(r).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return $t(this,void 0,void 0,function*(){return dr.throwError("provider does not support network detection",ve.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return $t(this,void 0,void 0,function*(){let e=yield this._ready(),r=yield this.detectNetwork();if(e.chainId!==r.chainId){if(this.anyNetwork)return this._network=r,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",r,e),yield cT(0),this._network;let n=dr.makeError("underlying network changed",ve.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:r});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=mp();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(r=>((this._fastBlockNumber==null||r>this._fastBlockNumber)&&(this._fastBlockNumber=r),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&e<this._fastBlockNumber||(this._fastQueryDate=mp(),(this._fastBlockNumber==null||e>this._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,r,n){return $t(this,void 0,void 0,function*(){return this._waitForTransaction(e,r??1,n||0,null)})}_waitForTransaction(e,r,n,i){return $t(this,void 0,void 0,function*(){let o=yield this.getTransactionReceipt(e);return(o?o.confirmations:0)>=r?o:new Promise((a,f)=>{let l=[],u=!1,h=s(function(){return u?!0:(u=!0,l.forEach(x=>{x()}),!1)},"alreadyDone"),g=s(x=>{x.confirmations<r||h()||a(x)},"minedHandler");if(this.on(e,g),l.push(()=>{this.removeListener(e,g)}),i){let x=i.startBlock,_=null,E=s(T=>$t(this,void 0,void 0,function*(){u||(yield cT(1e3),this.getTransactionCount(i.from).then(B=>$t(this,void 0,void 0,function*(){if(!u){if(B<=i.nonce)x=T;else{{let F=yield this.getTransaction(e);if(F&&F.blockNumber!=null)return}for(_==null&&(_=x-3,_<i.startBlock&&(_=i.startBlock));_<=T;){if(u)return;let F=yield this.getBlockWithTransactions(_);for(let H=0;H<F.transactions.length;H++){let U=F.transactions[H];if(U.hash===e)return;if(U.from===i.from&&U.nonce===i.nonce){if(u)return;let q=yield this.waitForTransaction(U.hash,r);if(h())return;let K="replaced";U.data===i.data&&U.to===i.to&&U.value.eq(i.value)?K="repriced":U.data==="0x"&&U.from===U.to&&U.value.isZero()&&(K="cancelled"),f(dr.makeError("transaction was replaced",ve.errors.TRANSACTION_REPLACED,{cancelled:K==="replaced"||K==="cancelled",reason:K,replacement:this._wrapTransaction(U),hash:e,receipt:q}));return}}_++}}u||this.once("block",E)}}),B=>{u||this.once("block",E)}))}),"replaceHandler");if(u)return;this.once("block",E),l.push(()=>{this.removeListener("block",E)})}if(typeof n=="number"&&n>0){let x=setTimeout(()=>{h()||f(dr.makeError("timeout exceeded",ve.errors.TIMEOUT,{timeout:n}))},n);x.unref&&x.unref(),l.push(()=>{clearTimeout(x)})}})})}getBlockNumber(){return $t(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return ze.from(e)}catch(r){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:r})}})}getBalance(e,r){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Nr({address:this._getAddress(e),blockTag:this._getBlockTag(r)}),i=yield this.perform("getBalance",n);try{return ze.from(i)}catch(o){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:o})}})}getTransactionCount(e,r){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Nr({address:this._getAddress(e),blockTag:this._getBlockTag(r)}),i=yield this.perform("getTransactionCount",n);try{return ze.from(i).toNumber()}catch(o){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:o})}})}getCode(e,r){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Nr({address:this._getAddress(e),blockTag:this._getBlockTag(r)}),i=yield this.perform("getCode",n);try{return Ve(i)}catch(o){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:o})}})}getStorageAt(e,r,n){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Nr({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(r).then(a=>ma(a))}),o=yield this.perform("getStorageAt",i);try{return Ve(o)}catch(a){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:o,error:a})}})}_wrapTransaction(e,r,n){if(r!=null&&Ei(r)!==32)throw new Error("invalid response - sendTransaction");let i=e;return r!=null&&e.hash!==r&&dr.throwError("Transaction hash mismatch from Provider.sendTransaction.",ve.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:r}),i.wait=(o,a)=>$t(this,void 0,void 0,function*(){o==null&&(o=1),a==null&&(a=0);let f;o!==0&&n!=null&&(f={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,o,a,f);return l==null&&o===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&dr.throwError("transaction failed",ve.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let r=yield Promise.resolve(e).then(o=>Ve(o)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let o=yield this.perform("sendTransaction",{signedTransaction:r});return this._wrapTransaction(n,o,i)}catch(o){throw o.transaction=n,o.transactionHash=n.hash,o}})}_getTransactionRequest(e){return $t(this,void 0,void 0,function*(){let r=yield e,n={};return["from","to"].forEach(i=>{r[i]!=null&&(n[i]=Promise.resolve(r[i]).then(o=>o?this._getAddress(o):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{r[i]!=null&&(n[i]=Promise.resolve(r[i]).then(o=>o?ze.from(o):null))}),["type"].forEach(i=>{r[i]!=null&&(n[i]=Promise.resolve(r[i]).then(o=>o??null))}),r.accessList&&(n.accessList=this.formatter.accessList(r.accessList)),["data"].forEach(i=>{r[i]!=null&&(n[i]=Promise.resolve(r[i]).then(o=>o?Ve(o):null))}),this.formatter.transactionRequest(yield Nr(n))})}_getFilter(e){return $t(this,void 0,void 0,function*(){e=yield e;let r={};return e.address!=null&&(r.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(r[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(r[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Nr(r))})}_call(e,r,n){return $t(this,void 0,void 0,function*(){n>=JV&&dr.throwError("CCIP read exceeded maximum redirections",ve.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,o=yield this.perform("call",{transaction:e,blockTag:r});if(n>=0&&r==="latest"&&i!=null&&o.substring(0,10)==="0x556f1830"&&Ei(o)%32===4)try{let a=Fr(o,4),f=Fr(a,0,32);ze.from(f).eq(i)||dr.throwError("CCIP Read sender did not match",ve.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});let l=[],u=ze.from(Fr(a,32,64)).toNumber(),h=ze.from(Fr(a,u,u+32)).toNumber(),g=Fr(a,u+32);for(let F=0;F<h;F++){let H=pb(g,F*32);H==null&&dr.throwError("CCIP Read contained corrupt URL string",ve.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o}),l.push(H)}let x=gp(a,64);ze.from(Fr(a,100,128)).isZero()||dr.throwError("CCIP Read callback selector included junk",ve.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});let _=Fr(a,96,100),E=gp(a,128),T=yield this.ccipReadFetch(e,x,l);T==null&&dr.throwError("CCIP Read disabled or provided no URLs",ve.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});let B={to:i,data:Mn([_,hT([T,E])])};return this._call(B,r,n+1)}catch(a){if(a.code===ve.errors.SERVER_ERROR)throw a}try{return Ve(o)}catch(a){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"call",params:{transaction:e,blockTag:r},result:o,error:a})}})}call(e,r){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Nr({transaction:this._getTransactionRequest(e),blockTag:this._getBlockTag(r),ccipReadEnabled:Promise.resolve(e.ccipReadEnabled)});return this._call(n.transaction,n.blockTag,n.ccipReadEnabled?0:-1)})}estimateGas(e){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let r=yield Nr({transaction:this._getTransactionRequest(e)}),n=yield this.perform("estimateGas",r);try{return ze.from(n)}catch(i){return dr.throwError("bad result from backend",ve.errors.SERVER_ERROR,{method:"estimateGas",params:r,result:n,error:i})}})}_getAddress(e){return $t(this,void 0,void 0,function*(){e=yield e,typeof e!="string"&&dr.throwArgumentError("invalid address or ENS name","name",e);let r=yield this.resolveName(e);return r==null&&dr.throwError("ENS name not configured",ve.errors.UNSUPPORTED_OPERATION,{operation:`resolveName(${JSON.stringify(e)})`}),r})}_getBlock(e,r){return $t(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let n=-128,i={includeTransactions:!!r};if(Pt(e,32))i.blockHash=e;else try{i.blockTag=yield this._getBlockTag(e),Pt(i.blockTag)&&(n=parseInt(i.blockTag.substring(2),16))}catch{dr.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",e)}return Po(()=>$t(this,void 0,void 0,function*(){let o=yield this.perform("getBlock",i);if(o==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(r){let a=null;for(let l=0;l<o.transactions.length;l++){let u=o.transactions[l];if(u.blockNumber==null)u.confirmations=0;else if(u.confirmations==null){a==null&&(a=yield this._getInternalBlockNumber(100+2*this.pollingInterval));let h=a-u.blockNumber+1;h<=0&&(h=1),u.confirmations=h}}let f=this.formatter.blockWithTransactions(o);return f.transactions=f.transactions.map(l=>this._wrapTransaction(l)),f}return this.formatter.block(o)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return $t(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let r={transactionHash:this.formatter.hash(e,!0)};return Po(()=>$t(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",r);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let a=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;a<=0&&(a=1),i.confirmations=a}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return $t(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let r={transactionHash:this.formatter.hash(e,!0)};return Po(()=>$t(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",r);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let a=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;a<=0&&(a=1),i.confirmations=a}return i}),{oncePoll:this})})}getLogs(e){return $t(this,void 0,void 0,function*(){yield this.getNetwork();let r=yield Nr({filter:this._getFilter(e)}),n=yield this.perform("getLogs",r);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),xt.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return $t(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return $t(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&dr.throwArgumentError("invalid BlockTag","blockTag",e);let r=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return r+=e,r<0&&(r=0),this.formatter.blockTag(r)}return this.formatter.blockTag(e)})}getResolver(e){return $t(this,void 0,void 0,function*(){let r=e;for(;;){if(r===""||r==="."||e!=="eth"&&r==="eth")return null;let n=yield this._getResolver(r,"getResolver");if(n!=null){let i=new Ll(this,n,e);return r!==e&&!(yield i.supportsWildcard())?null:i}r=r.split(".").slice(1).join(".")}})}_getResolver(e,r){return $t(this,void 0,void 0,function*(){r==null&&(r="ENS");let n=yield this.getNetwork();n.ensAddress||dr.throwError("network does not support ENS",ve.errors.UNSUPPORTED_OPERATION,{operation:r,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ef(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return $t(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(Pt(e))throw n}typeof e!="string"&&dr.throwArgumentError("invalid ENS name","name",e);let r=yield this.getResolver(e);return r?yield r.getAddress():null})}lookupAddress(e){return $t(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let r=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(r,"lookupAddress");if(n==null)return null;let i=pb(yield this.call({to:n,data:"0x691f3431"+Ef(r).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return $t(this,void 0,void 0,function*(){let r=null;if(Pt(e)){let o=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",a=yield this._getResolver(o,"getAvatar");if(!a)return null;r=new Ll(this,a,o);try{let f=yield r.getAvatar();if(f)return f.url}catch(f){if(f.code!==ve.errors.CALL_EXCEPTION)throw f}try{let f=pb(yield this.call({to:a,data:"0x691f3431"+Ef(o).substring(2)}),0);r=yield this.getResolver(f)}catch(f){if(f.code!==ve.errors.CALL_EXCEPTION)throw f;return null}}else if(r=yield this.getResolver(e),!r)return null;let n=yield r.getAvatar();return n==null?null:n.url})}perform(e,r){return dr.throwError(e+" not implemented",ve.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(r=>r.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(r=>r.pollable()).length>0}_addEventListener(e,r,n){let i=new hb(gd(e),r,n);return this._events.push(i),this._startEvent(i),this}on(e,r){return this._addEventListener(e,r,!1)}once(e,r){return this._addEventListener(e,r,!0)}emit(e,...r){let n=!1,i=[],o=gd(e);return this._events=this._events.filter(a=>a.tag!==o?!0:(setTimeout(()=>{a.listener.apply(this,r)},0),n=!0,a.once?(i.push(a),!1):!0)),i.forEach(a=>{this._stopEvent(a)}),n}listenerCount(e){if(!e)return this._events.length;let r=gd(e);return this._events.filter(n=>n.tag===r).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let r=gd(e);return this._events.filter(n=>n.tag===r).map(n=>n.listener)}off(e,r){if(r==null)return this.removeAllListeners(e);let n=[],i=!1,o=gd(e);return this._events=this._events.filter(a=>a.tag!==o||a.listener!=r||i?!0:(i=!0,n.push(a),!1)),n.forEach(a=>{this._stopEvent(a)}),this}removeAllListeners(e){let r=[];if(e==null)r=this._events,this._events=[];else{let n=gd(e);this._events=this._events.filter(i=>i.tag!==n?!0:(r.push(i),!1))}return r.forEach(n=>{this._stopEvent(n)}),this}};s(Oo,"BaseProvider");var kc=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},Rn=new ve(Sr),tW=["call","estimateGas"];function vp(t,e){if(t==null)return null;if(typeof t.message=="string"&&t.message.match("reverted")){let r=Pt(t.data)?t.data:null;if(!e||r)return{message:t.message,data:r}}if(typeof t=="object"){for(let r in t){let n=vp(t[r],e);if(n)return n}return null}if(typeof t=="string")try{return vp(JSON.parse(t),e)}catch{}return null}s(vp,"spelunk");function mT(t,e,r){let n=r.transaction||r.signedTransaction;if(t==="call"){let o=vp(e,!0);if(o)return o.data;Rn.throwError("missing revert data in call exception; Transaction reverted without a reason string",ve.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(t==="estimateGas"){let o=vp(e.body,!1);o==null&&(o=vp(e,!1)),o&&Rn.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ve.errors.UNPREDICTABLE_GAS_LIMIT,{reason:o.message,method:t,transaction:n,error:e})}let i=e.message;throw e.code===ve.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Rn.throwError("insufficient funds for intrinsic transaction cost",ve.errors.INSUFFICIENT_FUNDS,{error:e,method:t,transaction:n}),i.match(/nonce (is )?too low/i)&&Rn.throwError("nonce has already been used",ve.errors.NONCE_EXPIRED,{error:e,method:t,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Rn.throwError("replacement fee too low",ve.errors.REPLACEMENT_UNDERPRICED,{error:e,method:t,transaction:n}),i.match(/only replay-protected/i)&&Rn.throwError("legacy pre-eip-155 transactions not supported",ve.errors.UNSUPPORTED_OPERATION,{error:e,method:t,transaction:n}),tW.indexOf(t)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Rn.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ve.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:t,transaction:n}),e}s(mT,"checkError");function pT(t){return new Promise(function(e){setTimeout(e,t)})}s(pT,"timer");function rW(t){if(t.error){let e=new Error(t.error.message);throw e.code=t.error.code,e.data=t.error.data,e}return t.result}s(rW,"getResult");function bp(t){return t&&t.toLowerCase()}s(bp,"getLowerCase");var v4={},Ul=class extends Hi{constructor(e,r,n){if(super(),e!==v4)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");Pe(this,"provider",r),n==null&&(n=0),typeof n=="string"?(Pe(this,"_address",this.provider.formatter.address(n)),Pe(this,"_index",null)):typeof n=="number"?(Pe(this,"_index",n),Pe(this,"_address",null)):Rn.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Rn.throwError("cannot alter JSON-RPC Signer connection",ve.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new mb(v4,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Rn.throwError("unknown account #"+this._index,ve.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=Er(e);let r=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=Er(e);n.from=r,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>kc(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Rn.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Nr({tx:Nr(e),sender:r}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Rn.throwArgumentError("from address mismatch","transaction",e):n.from=i;let o=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[o]).then(a=>a,a=>(typeof a.message=="string"&&a.message.match(/user denied/i)&&Rn.throwError("user rejected transaction",ve.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),mT("sendTransaction",a,o)))})}signTransaction(e){return Rn.throwError("signing transactions is unsupported",ve.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return kc(this,void 0,void 0,function*(){let r=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Po(()=>kc(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,r)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return kc(this,void 0,void 0,function*(){let r=typeof e=="string"?Ar(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[Ve(r),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Rn.throwError("user rejected signing",ve.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return kc(this,void 0,void 0,function*(){let r=typeof e=="string"?Ar(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),Ve(r)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Rn.throwError("user rejected signing",ve.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,r,n){return kc(this,void 0,void 0,function*(){let i=yield nn.resolveNames(e,r,n,a=>this.provider.resolveName(a)),o=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[o.toLowerCase(),JSON.stringify(nn.getPayload(i.domain,r,i.value))])}catch(a){throw typeof a.message=="string"&&a.message.match(/user denied/i)&&Rn.throwError("user rejected signing",ve.errors.ACTION_REJECTED,{action:"_signTypedData",from:o,messageData:{domain:i.domain,types:r,value:i.value}}),a}})}unlock(e){return kc(this,void 0,void 0,function*(){let r=this.provider,n=yield this.getAddress();return r.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}};s(Ul,"JsonRpcSigner");var mb=class extends Ul{sendTransaction(e){return this.sendUncheckedTransaction(e).then(r=>({hash:r,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(r,n)}))}};s(mb,"UncheckedJsonRpcSigner");var nW={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},zi=class extends Oo{constructor(e,r){let n=r;n==null&&(n=new Promise((i,o)=>{setTimeout(()=>{this.detectNetwork().then(a=>{i(a)},a=>{o(a)})},0)})),super(n),e||(e=ln(this.constructor,"defaultUrl")()),typeof e=="string"?Pe(this,"connection",Object.freeze({url:e})):Pe(this,"connection",Object.freeze(Er(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return kc(this,void 0,void 0,function*(){yield pT(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let r=ln(this.constructor,"getNetwork");try{return r(ze.from(e).toNumber())}catch(n){return Rn.throwError("could not detect network",ve.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Rn.throwError("could not detect network",ve.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new Ul(v4,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(r=>this.formatter.address(r)))}send(e,r){let n={method:e,params:r,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:fn(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let o=Do(this.connection,JSON.stringify(n),rW).then(a=>(this.emit("debug",{action:"response",request:n,response:a,provider:this}),a),a=>{throw this.emit("debug",{action:"response",error:a,request:n,provider:this}),a});return i&&(this._cache[e]=o,setTimeout(()=>{this._cache[e]=null},0)),o}prepareRequest(e,r){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[bp(r.address),r.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[bp(r.address),r.blockTag]];case"getCode":return["eth_getCode",[bp(r.address),r.blockTag]];case"getStorageAt":return["eth_getStorageAt",[bp(r.address),ur(r.position,32),r.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[r.signedTransaction]];case"getBlock":return r.blockTag?["eth_getBlockByNumber",[r.blockTag,!!r.includeTransactions]]:r.blockHash?["eth_getBlockByHash",[r.blockHash,!!r.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[r.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[r.transactionHash]];case"call":{let n=ln(this.constructor,"hexlifyTransaction");return["eth_call",[n(r.transaction,{from:!0}),r.blockTag]]}case"estimateGas":{let n=ln(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(r.transaction,{from:!0})]]}case"getLogs":return r.filter&&r.filter.address!=null&&(r.filter.address=bp(r.filter.address)),["eth_getLogs",[r.filter]];default:break}return null}perform(e,r){return kc(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=r.transaction;if(i&&i.type!=null&&ze.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let o=yield this.getFeeData();o.maxFeePerGas==null&&o.maxPriorityFeePerGas==null&&(r=Er(r),r.transaction=Er(i),delete r.transaction.type)}}let n=this.prepareRequest(e,r);n==null&&Rn.throwError(e+" not implemented",ve.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return mT(e,i,r)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,r=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=r,r.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(o){if(e._pendingFilter!=r)return null;let a=Promise.resolve();return o.forEach(function(f){e._emitted["t:"+f.toLowerCase()]="pending",a=a.then(function(){return e.getTransaction(f).then(function(l){return e.emit("pending",l),null})})}),a.then(function(){return pT(1e3)})}).then(function(){if(e._pendingFilter!=r){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(o=>{})}return s(i,"poll"),i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,r){let n=Er(nW);if(r)for(let o in r)r[o]&&(n[o]=!0);zu(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(o){if(e[o]==null)return;let a=ma(ze.from(e[o]));o==="gasLimit"&&(o="gas"),i[o]=a}),["from","to","data"].forEach(function(o){e[o]!=null&&(i[o]=Ve(e[o]))}),e.accessList&&(i.accessList=Ps(e.accessList)),i}};s(zi,"JsonRpcProvider");var bd=null;try{if(bd=WebSocket,bd==null)throw new Error("inject please")}catch{let e=new ve(Sr);bd=s(function(){e.throwError("WebSockets not supported in this environment",ve.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})},"WS")}var y4=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},gb=new ve(Sr),iW=1,Ba=class extends zi{constructor(e,r){r==="any"&&gb.throwError("WebSocketProvider does not support 'any' network yet",ve.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,r):super("_websocket",r),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?Pe(this,"_websocket",new bd(this.connection.url)):Pe(this,"_websocket",e),Pe(this,"_requests",{}),Pe(this,"_subs",{}),Pe(this,"_subIds",{}),Pe(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let o=i.data,a=JSON.parse(o);if(a.id!=null){let f=String(a.id),l=this._requests[f];if(delete this._requests[f],a.result!==void 0)l.callback(null,a.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:a.result,provider:this});else{let u=null;a.error?(u=new Error(a.error.message||"unknown error"),Pe(u,"code",a.error.code||null),Pe(u,"response",o)):u=new Error("unknown error"),l.callback(u,void 0),this.emit("debug",{action:"response",error:u,request:JSON.parse(l.payload),provider:this})}}else if(a.method==="eth_subscription"){let f=this._subs[a.params.subscription];f&&f.processFunc(a.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){gb.throwError("cannot reset events block on WebSocketProvider",ve.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){gb.throwError("cannot set polling interval on WebSocketProvider",ve.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return y4(this,void 0,void 0,function*(){return null})}set polling(e){!e||gb.throwError("cannot set polling on WebSocketProvider",ve.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,r){let n=iW++;return new Promise((i,o)=>{function a(l,u){return l?o(l):i(u)}s(a,"callback");let f=JSON.stringify({method:e,params:r,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(f),provider:this}),this._requests[String(n)]={callback:a,payload:f},this._wsReady&&this.websocket.send(f)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,r,n){return y4(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(r).then(a=>this.send("eth_subscribe",a)),this._subIds[e]=i);let o=yield i;this._subs[o]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],r=>{let n=ze.from(r.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],r=>{this.emit("pending",r)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],r=>{r.removed==null&&(r.removed=!1),this.emit(e.filter,this.formatter.filterLog(r))});break;case"tx":{let r=s(n=>{let i=n.hash;this.getTransactionReceipt(i).then(o=>{!o||this.emit(i,o)})},"emitReceipt");r(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(r)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let r=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;r="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[r];!n||(delete this._subIds[r],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return y4(this,void 0,void 0,function*(){this.websocket.readyState===bd.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};s(Ba,"WebSocketProvider");var sW=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},yp=new ve(Sr),vd=class extends zi{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return sW(this,void 0,void 0,function*(){let r=this.network;return r==null&&(r=yield e.detectNetwork.call(this),r||yp.throwError("no network detected",ve.errors.UNKNOWN_ERROR,{}),this._network==null&&(Pe(this,"_network",r),this.emit("network",r,null))),r})}};s(vd,"StaticJsonRpcProvider");var Un=class extends vd{constructor(e,r){yp.checkAbstract(new.target,Un),e=ln(new.target,"getNetwork")(e),r=ln(new.target,"getApiKey")(r);let n=ln(new.target,"getUrl")(e,r);super(n,e),typeof r=="string"?Pe(this,"apiKey",r):r!=null&&Object.keys(r).forEach(i=>{Pe(this,i,r[i])})}_startPending(){yp.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return yp.throwError("API provider does not support signing",ve.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,r){return yp.throwError("not implemented; sub-classes must override getUrl",ve.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};s(Un,"UrlJsonRpcProvider");var gT=new ve(Sr),bb="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",yd=class extends Ba{constructor(e,r){let n=new jl(e,r),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),Pe(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===bb}};s(yd,"AlchemyWebSocketProvider");var jl=class extends Un{static getWebSocketProvider(e,r){return new yd(e,r)}static getApiKey(e){return e==null?bb:(e&&typeof e!="string"&&gT.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,r){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:gT.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+r,throttleCallback:(i,o)=>(r===bb&&Ra(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===bb}};s(jl,"AlchemyProvider");var oW=new ve(Sr),vb="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function aW(t){switch(t){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return oW.throwArgumentError("unsupported network","name",t)}s(aW,"getHost");var xd=class extends Un{isCommunityResource(){return this.apiKey===vb}static getApiKey(e){return e??vb}static getUrl(e,r){r==null&&(r=vb);let n={allowGzip:!0,url:"https://"+aW(e.name)+r,throttleCallback:(i,o)=>(r.apiKey===vb&&Ra(),Promise.resolve(!0))};return r.projectSecret!=null&&(n.user="",n.password=r.projectSecret),n}};s(xd,"AnkrProvider");var cW=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},bT=new ve(Sr),wd=class extends Un{static getApiKey(e){return e!=null&&bT.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,r){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:bT.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,r){let n=Object.create(null,{perform:{get:()=>super.perform}});return cW(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,r)})}};s(wd,"CloudflareProvider");var yb=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},Rf=new ve(Sr);function vT(t){let e={};for(let r in t){if(t[r]==null)continue;let n=t[r];r==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?n=ma(Ve(n)):r==="accessList"?n="["+Ps(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=Ve(n),e[r]=n)}return e}s(vT,"getTransactionPostData");function fW(t){if(t.status==0&&(t.message==="No records found"||t.message==="No transactions found"))return t.result;if(t.status!=1||typeof t.message!="string"||!t.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(t),(t.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return t.result}s(fW,"getResult");function yT(t){if(t&&t.status==0&&t.message=="NOTOK"&&(t.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(t),e.throttleRetry=!0,e}if(t.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(t),e}if(t.error){let e=new Error(t.error.message||"unknown error");throw t.error.code&&(e.code=t.error.code),t.error.data&&(e.data=t.error.data),e}return t.result}s(yT,"getJsonResult");function xT(t){if(t==="pending")throw new Error("pending not supported");return t==="latest"?t:parseInt(t.substring(2),16)}s(xT,"checkLogTag");function x4(t,e,r){if(t==="call"&&e.code===ve.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let o=i.data;if(o&&(o="0x"+o.replace(/^.*0x/i,"")),Pt(o))return o;Rf.throwError("missing revert data in call exception",ve.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===ve.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Rf.throwError("insufficient funds for intrinsic transaction cost",ve.errors.INSUFFICIENT_FUNDS,{error:e,method:t,transaction:r}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Rf.throwError("nonce has already been used",ve.errors.NONCE_EXPIRED,{error:e,method:t,transaction:r}),n.match(/another transaction with same nonce/)&&Rf.throwError("replacement fee too low",ve.errors.REPLACEMENT_UNDERPRICED,{error:e,method:t,transaction:r}),n.match(/execution failed due to an exception|execution reverted/)&&Rf.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ve.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:t,transaction:r}),e}s(x4,"checkError");var _d=class extends Oo{constructor(e,r){super(e),Pe(this,"baseUrl",this.getBaseUrl()),Pe(this,"apiKey",r||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Rf.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,r){let n=Object.keys(r).reduce((o,a)=>{let f=r[a];return f!=null&&(o+=`&${a}=${f}`),o},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,r){return r.module=e,r.apikey=this.apiKey,r}fetch(e,r,n){return yb(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,r),o=n?this.getPostData(e,r):null,a=e==="proxy"?yT:fW;this.emit("debug",{action:"request",request:i,provider:this});let f={url:i,throttleSlotInterval:1e3,throttleCallback:(h,g)=>(this.isCommunityResource()&&Ra(),Promise.resolve(!0))},l=null;o&&(f.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(o).map(h=>`${h}=${o[h]}`).join("&"));let u=yield Do(f,l,a||yT);return this.emit("debug",{action:"response",request:i,response:fn(u),provider:this}),u})}detectNetwork(){return yb(this,void 0,void 0,function*(){return this.network})}perform(e,r){let n=Object.create(null,{perform:{get:()=>super.perform}});return yb(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:r.address,tag:r.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:r.address,tag:r.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:r.address,tag:r.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:r.address,position:r.position,tag:r.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:r.signedTransaction},!0).catch(i=>x4("sendTransaction",i,r.signedTransaction));case"getBlock":if(r.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:r.blockTag,boolean:r.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:r.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:r.transactionHash});case"call":{if(r.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=vT(r.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(o){return x4("call",o,r.transaction)}}case"estimateGas":{let i=vT(r.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(o){return x4("estimateGas",o,r.transaction)}}case"getLogs":{let i={action:"getLogs"};if(r.filter.fromBlock&&(i.fromBlock=xT(r.filter.fromBlock)),r.filter.toBlock&&(i.toBlock=xT(r.filter.toBlock)),r.filter.address&&(i.address=r.filter.address),r.filter.topics&&r.filter.topics.length>0&&(r.filter.topics.length>1&&Rf.throwError("unsupported topic count",ve.errors.UNSUPPORTED_OPERATION,{topics:r.filter.topics}),r.filter.topics.length===1)){let f=r.filter.topics[0];(typeof f!="string"||f.length!==66)&&Rf.throwError("unsupported topic format",ve.errors.UNSUPPORTED_OPERATION,{topic0:f}),i.topic0=f}let o=yield this.fetch("logs",i),a={};for(let f=0;f<o.length;f++){let l=o[f];if(l.blockHash==null){if(a[l.blockNumber]==null){let u=yield this.getBlock(l.blockNumber);u&&(a[l.blockNumber]=u.hash)}l.blockHash=a[l.blockNumber]}}return o}case"getEtherPrice":return this.network.name!=="homestead"?0:parseFloat((yield this.fetch("stats",{action:"ethprice"})).ethusd);default:break}return n.perform.call(this,e,r)})}getHistory(e,r,n){return yb(this,void 0,void 0,function*(){let i={action:"txlist",address:yield this.resolveName(e),startblock:r??0,endblock:n??99999999,sort:"asc"};return(yield this.fetch("account",i)).map(a=>{["contractAddress","to"].forEach(function(l){a[l]==""&&delete a[l]}),a.creates==null&&a.contractAddress!=null&&(a.creates=a.contractAddress);let f=this.formatter.transactionResponse(a);return a.timeStamp&&(f.timestamp=parseInt(a.timeStamp)),f})})}isCommunityResource(){return this.apiKey==null}};s(_d,"EtherscanProvider");var _b=function(t,e,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return s(i,"adopt"),new(r||(r=Promise))(function(o,a){function f(h){try{u(n.next(h))}catch(g){a(g)}}s(f,"fulfilled");function l(h){try{u(n.throw(h))}catch(g){a(g)}}s(l,"rejected");function u(h){h.done?o(h.value):i(h.value).then(f,l)}s(u,"step"),u((n=n.apply(t,e||[])).next())})},ql=new ve(Sr);function xb(){return new Date().getTime()}s(xb,"now");function wT(t){let e=null;for(let r=0;r<t.length;r++){let n=t[r];if(n==null)return null;e?e.name===n.name&&e.chainId===n.chainId&&(e.ensAddress===n.ensAddress||e.ensAddress==null&&n.ensAddress==null)||ql.throwArgumentError("provider mismatch","networks",t):e=n}return e}s(wT,"checkNetworks");function _T(t,e){t=t.slice().sort();let r=Math.floor(t.length/2);if(t.length%2)return t[r];let n=t[r-1],i=t[r];return e!=null&&Math.abs(n-i)>e?null:(n+i)/2}s(_T,"median");function Ad(t){if(t===null)return"null";if(typeof t=="number"||typeof t=="boolean")return JSON.stringify(t);if(typeof t=="string")return t;if(ze.isBigNumber(t))return t.toString();if(Array.isArray(t))return JSON.stringify(t.map(e=>Ad(e)));if(typeof t=="object"){let e=Object.keys(t);return e.sort(),"{"+e.map(r=>{let n=t[r];return typeof n=="function"?n="[function]":n=Ad(n),JSON.stringify(r)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof t)}s(Ad,"serialize");var lW=1;function AT(t){let e=null,r=null,n=new Promise(a=>{e=s(function(){r&&(clearTimeout(r),r=null),a()},"cancel"),r=setTimeout(e,t)}),i=s(a=>(n=n.then(a),n),"wait");function o(){return n}return s(o,"getPromise"),{cancel:e,getPromise:o,wait:i}}s(AT,"stall");var uW=[ve.errors.CALL_EXCEPTION,ve.errors.INSUFFICIENT_FUNDS,ve.errors.NONCE_EXPIRED,ve.errors.REPLACEMENT_UNDERPRICED,ve.errors.UNPREDICTABLE_GAS_LIMIT],dW=["address","args","errorArgs","errorSignature","method","transaction"];function wb(t,e){let r={weight:t.weight};return Object.defineProperty(r,"provider",{get:()=>t.provider}),t.start&&(r.start=t.start),e&&(r.duration=e-t.start),t.done&&(t.error?r.error=t.error:r.result=t.result||null),r}s(wb,"exposeDebugConfig");function hW(t,e){return function(r){let n={};r.forEach(o=>{let a=t(o.result);n[a]||(n[a]={count:0,result:o.result}),n[a].count++});let i=Object.keys(n);for(let o=0;o<i.length;o++){let a=n[i[o]];if(a.count>=e)return a.result}}}s(hW,"normalizedTally");function pW(t,e,r){let n=Ad;switch(e){case"getBlockNumber":return function(i){let o=i.map(f=>f.result),a=_T(i.map(f=>f.result),2);if(a!=null)return a=Math.ceil(a),o.indexOf(a+1)>=0&&a++,a>=t._highestBlockNumber&&(t._highestBlockNumber=a),t._highestBlockNumber};case"getGasPrice":return function(i){let o=i.map(a=>a.result);return o.sort(),o[Math.floor(o.length/2)]};case"getEtherPrice":return function(i){return _T(i.map(o=>o.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=s(function(i){return i==null?null:(i=Er(i),i.confirmations=-1,Ad(i))},"normalize");break;case"getBlock":r.includeTransactions?n=s(function(i){return i==null?null:(i=Er(i),i.transactions=i.transactions.map(o=>(o=Er(o),o.confirmations=-1,o)),Ad(i))},"normalize"):n=s(function(i){return i==null?null:Ad(i)},"normalize");break;default:throw new Error("unknown method: "+e)}return hW(n,t.quorum)}s(pW,"getProcessFunc");function xp(t,e){return _b(this,void 0,void 0,function*(){let r=t.provider;return r.blockNumber!=null&&r.blockNumber>=e||e===-1?r:Po(()=>new Promise((n,i)=>{setTimeout(function(){return r.blockNumber>=e?n(r):t.cancelled?n(null):n(void 0)},0)}),{oncePoll:r})})}s(xp,"waitForSync");function mW(t,e,r,n){return _b(this,void 0,void 0,function*(){let i=t.provider;switch(r){case"getBlockNumber":case"getGasPrice":return i[r]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&Pt(n.blockTag)&&(i=yield xp(t,e)),i[r](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&Pt(n.blockTag)&&(i=yield xp(t,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&Pt(n.blockTag)&&(i=yield xp(t,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&Pt(n.blockTag)&&(i=yield xp(t,e)),r==="call"&&n.blockTag?i[r](n.transaction,n.blockTag):i[r](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[r](n.transactionHash);case"getLogs":{let o=n.filter;return(o.fromBlock&&Pt(o.fromBlock)||o.toBlock&&Pt(o.toBlock))&&(i=yield xp(t,e)),i.getLogs(o)}}return ql.throwError("unknown method error",ve.errors.UNKNOWN_ERROR,{method:r,params:n})})}s(mW,"getRunner");var Ed=class extends Oo{constructor(e,r){e.length===0&&ql.throwArgumentError("missing providers","providers",e);let n=e.map((a,f)=>{if(qi.isProvider(a)){let h=pp(a)?2e3:750;return Object.freeze({provider:a,weight:1,stallTimeout:h,priority:1})}let l=Er(a);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=pp(a)?2e3:750),l.weight==null&&(l.weight=1);let u=l.weight;return(u%1||u>512||u<1)&&ql.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${f}].weight`,u),Object.freeze(l)}),i=n.reduce((a,f)=>a+f.weight,0);r==null?r=i/2:r>i&&ql.throwArgumentError("quorum will always fail; larger than total weight","quorum",r);let o=wT(n.map(a=>a.provider.network));o==null&&(o=new Promise((a,f)=>{setTimeout(()=>{this.detectNetwork().then(a,f)},0)})),super(o),Pe(this,"providerConfigs",Object.freeze(n)),Pe(this,"quorum",r),this._highestBlockNumber=-1}detectNetwork(){return _b(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(r=>r.provider.getNetwork()));return wT(e)})}perform(e,r){return _b(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(u=>u.provider.sendTransaction(r.signedTransaction).then(h=>h.hash,h=>h)));for(let u=0;u<l.length;u++){let h=l[u];if(typeof h=="string")return h}throw l[0]}this._highestBlockNumber===-1&&e!=="getBlockNumber"&&(yield this.getBlockNumber());let n=pW(this,e,r),i=fp(this.providerConfigs.map(Er));i.sort((l,u)=>l.priority-u.priority);let o=this._highestBlockNumber,a=0,f=!0;for(;;){let l=xb(),u=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,E)=>_+E.weight,0);for(;u<this.quorum&&a<i.length;){let _=i[a++],E=lW++;_.start=xb(),_.staller=AT(_.stallTimeout),_.staller.wait(()=>{_.staller=null}),_.runner=mW(_,o,e,r).then(T=>{_.done=!0,_.result=T,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:E,backend:wb(_,xb()),request:{method:e,params:fn(r)},provider:this})},T=>{_.done=!0,_.error=T,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:E,backend:wb(_,xb()),request:{method:e,params:fn(r)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:E,backend:wb(_,null),request:{method:e,params:fn(r)},provider:this}),u+=_.weight}let h=[];i.forEach(_=>{_.done||!_.runner||(h.push(_.runner),_.staller&&h.push(_.staller.getPromise()))}),h.length&&(yield Promise.race(h));let g=i.filter(_=>_.done&&_.error==null);if(g.length>=this.quorum){let _=n(g);if(_!==void 0)return i.forEach(E=>{E.staller&&E.staller.cancel(),E.cancelled=!0}),_;f||(yield AT(100).getPromise()),f=!1}let x=i.reduce((_,E)=>{if(!E.done||E.error==null)return _;let T=E.error.code;return uW.indexOf(T)>=0&&(_[T]||(_[T]={error:E.error,weight:0}),_[T].weight+=E.weight),_},{});if(Object.keys(x).forEach(_=>{let E=x[_];if(E.weight<this.quorum)return;i.forEach(F=>{F.staller&&F.staller.cancel(),F.cancelled=!0});let T=E.error,B={};dW.forEach(F=>{T[F]!=null&&(B[F]=T[F])}),ql.throwError(T.reason||T.message,_,B)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),ql.throwError("failed to meet quorum",ve.errors.SERVER_ERROR,{method:e,params:r,results:i.map(l=>wb(l)),provider:this})})}};s(Ed,"FallbackProvider");var w4=null;var Ab=new ve(Sr),wp="84842078b09946638c03157f83405213",Cd=class extends Ba{constructor(e,r){let n=new Hl(e,r),i=n.connection;i.password&&Ab.throwError("INFURA WebSocket project secrets unsupported",ve.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let o=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(o,e),Pe(this,"apiKey",n.projectId),Pe(this,"projectId",n.projectId),Pe(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===wp}};s(Cd,"InfuraWebSocketProvider");var Hl=class extends Un{static getWebSocketProvider(e,r){return new Cd(e,r)}static getApiKey(e){let r={apiKey:wp,projectId:wp,projectSecret:null};return e==null||(typeof e=="string"?r.projectId=e:e.projectSecret!=null?(Ab.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),Ab.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),r.projectId=e.projectId,r.projectSecret=e.projectSecret):e.projectId&&(r.projectId=e.projectId),r.apiKey=r.projectId),r}static getUrl(e,r){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:Ab.throwError("unsupported network",ve.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+r.projectId,throttleCallback:(o,a)=>(r.projectId===wp&&Ra(),Promise.resolve(!0))};return r.projectSecret!=null&&(i.user="",i.password=r.projectSecret),i}isCommunityResource(){return this.projectId===wp}};s(Hl,"InfuraProvider");var _p=class extends zi{send(e,r){let n={method:e,params:r,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},o=new Promise((a,f)=>{i.resolve=a,i.reject=f});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let a=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let f=a.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:fn(f),provider:this}),Do(this.connection,JSON.stringify(f)).then(l=>{this.emit("debug",{action:"response",request:f,response:l,provider:this}),a.forEach((u,h)=>{let g=l[h];if(g.error){let x=new Error(g.error.message);x.code=g.error.code,x.data=g.error.data,u.reject(x)}else u.resolve(g.result)})},l=>{this.emit("debug",{action:"response",error:l,request:f,provider:this}),a.forEach(u=>{u.reject(l)})})},10)),o}};s(_p,"JsonRpcBatchProvider");var _4=new ve(Sr),gW="ETHERS_JS_SHARED",Sd=class extends Un{static getApiKey(e){return e&&typeof e!="string"&&_4.throwArgumentError("invalid apiKey","apiKey",e),e||gW}static getUrl(e,r){_4.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:_4.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+r}};s(Sd,"NodesmithProvider");var ET=new ve(Sr),CT="62e1ad51b37b8e00394bda3b",Id=class extends Un{static getApiKey(e){let r={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?r.applicationId=CT:typeof e=="string"?r.applicationId=e:e.applicationSecretKey!=null?(r.applicationId=e.applicationId,r.applicationSecretKey=e.applicationSecretKey):e.applicationId?r.applicationId=e.applicationId:ET.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),r}static getUrl(e,r){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:ET.throwError("unsupported network",ve.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${r.applicationId}`,o={headers:{},url:i};return r.applicationSecretKey!=null&&(o.user="",o.password=r.applicationSecretKey),o}isCommunityResource(){return this.applicationId===CT}};s(Id,"PocketProvider");var ST=new ve(Sr),bW=1;function IT(t,e){let r="Web3LegacyFetcher";return function(n,i){let o={method:n,params:i,id:bW++,jsonrpc:"2.0"};return new Promise((a,f)=>{this.emit("debug",{action:"request",fetcher:r,request:fn(o),provider:this}),e(o,(l,u)=>{if(l)return this.emit("debug",{action:"response",fetcher:r,error:l,request:o,provider:this}),f(l);if(this.emit("debug",{action:"response",fetcher:r,request:o,response:u,provider:this}),u.error){let h=new Error(u.error.message);return h.code=u.error.code,h.data=u.error.data,f(h)}a(u.result)})})}}s(IT,"buildWeb3LegacyFetcher");function vW(t){return function(e,r){r==null&&(r=[]);let n={method:e,params:r};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:fn(n),provider:this}),t.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}s(vW,"buildEip1193Fetcher");var kd=class extends zi{constructor(e,r){e==null&&ST.throwArgumentError("missing provider","provider",e);let n=null,i=null,o=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),o=e,e.request?(n===""&&(n="eip-1193:"),i=vW(e)):e.sendAsync?i=IT(e,e.sendAsync.bind(e)):e.send?i=IT(e,e.send.bind(e)):ST.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,r),Pe(this,"jsonRpcFetchFunc",i),Pe(this,"provider",o)}send(e,r){return this.jsonRpcFetchFunc(e,r)}};s(kd,"Web3Provider");var kT=new ve(Sr);function A4(t,e){if(t==null&&(t="homestead"),typeof t=="string"){let n=t.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new zi(t);case"ws":case"wss":return new Ba(t);default:kT.throwArgumentError("unsupported URL scheme","network",t)}}let r=up(t);return(!r||!r._defaultProvider)&&kT.throwError("unsupported getDefaultProvider network",ve.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:t}),r._defaultProvider({FallbackProvider:Ed,AlchemyProvider:jl,AnkrProvider:xd,CloudflareProvider:wd,EtherscanProvider:_d,InfuraProvider:Hl,JsonRpcProvider:zi,NodesmithProvider:Sd,PocketProvider:Id,Web3Provider:kd,IpcProvider:null},e)}s(A4,"getDefaultProvider");var I4={};vl(I4,{AbiCoder:()=>Tl,ConstructorFragment:()=>ti,ErrorFragment:()=>fs,EventFragment:()=>Ci,FormatTypes:()=>vr,Fragment:()=>Si,FunctionFragment:()=>ri,HDNode:()=>Ln,Indexed:()=>xa,Interface:()=>bc,LogDescription:()=>Ml,Logger:()=>ve,ParamType:()=>Yr,RLP:()=>kg,SigningKey:()=>Bs,SupportedAlgorithm:()=>Ta,TransactionDescription:()=>Rl,TransactionTypes:()=>Wg,UnicodeNormalizationForm:()=>ji,Utf8ErrorFuncs:()=>Dg,Utf8ErrorReason:()=>Ii,_TypedDataEncoder:()=>nn,_fetchData:()=>u4,_toEscapedUtf8String:()=>w3,accessListify:()=>Ps,arrayify:()=>je,base58:()=>_c,base64:()=>I3,checkProperties:()=>zu,checkResultErrors:()=>Gu,commify:()=>FT,computeAddress:()=>ao,computeHmac:()=>Ac,computePublicKey:()=>Q0,concat:()=>sr,deepCopy:()=>fn,defaultAbiCoder:()=>V0,defaultPath:()=>Ec,defineReadOnly:()=>Pe,dnsEncode:()=>J0,entropyToMnemonic:()=>Nl,fetchJson:()=>Do,formatBytes32String:()=>_3,formatEther:()=>NT,formatUnits:()=>C4,getAccountPath:()=>kk,getAddress:()=>ar,getContractAddress:()=>kl,getCreate2Address:()=>HS,getIcapAddress:()=>qS,getJsonWalletAddress:()=>a4,getStatic:()=>ln,hashMessage:()=>Xu,hexConcat:()=>Mn,hexDataLength:()=>Ei,hexDataSlice:()=>Fr,hexStripZeros:()=>f3,hexValue:()=>ma,hexZeroPad:()=>ur,hexlify:()=>Ve,id:()=>Ms,isAddress:()=>jS,isBytes:()=>eo,isBytesLike:()=>pc,isHexString:()=>Pt,isValidMnemonic:()=>Ik,isValidName:()=>T3,joinSignature:()=>T0,keccak256:()=>or,mnemonicToEntropy:()=>dd,mnemonicToSeed:()=>t4,namehash:()=>Ef,nameprep:()=>S3,parseBytes32String:()=>A3,parseEther:()=>LT,parseTransaction:()=>Jg,parseUnits:()=>S4,poll:()=>Po,randomBytes:()=>Ma,recoverAddress:()=>Pl,recoverPublicKey:()=>Vg,resolveProperties:()=>Nr,ripemd160:()=>op,serializeTransaction:()=>ep,sha256:()=>ds,sha512:()=>X3,shallowCopy:()=>Er,shuffled:()=>fp,solidityKeccak256:()=>RT,solidityPack:()=>Eb,soliditySha256:()=>BT,splitSignature:()=>ga,stripZeros:()=>Ts,toUtf8Bytes:()=>Ar,toUtf8CodePoints:()=>_f,toUtf8String:()=>ls,verifyMessage:()=>Gk,verifyTypedData:()=>Kk,zeroPad:()=>Sl});var TT="solidity/5.7.0";var yW=new RegExp("^bytes([0-9]+)$"),xW=new RegExp("^(u?int)([0-9]*)$"),wW=new RegExp("^(.*)\\[([0-9]*)\\]$"),_W="0000000000000000000000000000000000000000000000000000000000000000",Td=new ve(TT);function MT(t,e,r){switch(t){case"address":return r?Sl(e,32):je(e);case"string":return Ar(e);case"bytes":return je(e);case"bool":return e=e?"0x01":"0x00",r?Sl(e,32):je(e)}let n=t.match(xW);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Td.throwArgumentError("invalid number type","type",t),r&&(i=256),e=ze.from(e).toTwos(i),Sl(e,i/8)}if(n=t.match(yW),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Td.throwArgumentError("invalid bytes type","type",t),je(e).byteLength!==i&&Td.throwArgumentError(`invalid value for ${t}`,"value",e),r?je((e+_W).substring(0,66)):e}if(n=t.match(wW),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Td.throwArgumentError(`invalid array length for ${t}`,"value",e);let a=[];return e.forEach(function(f){a.push(MT(i,f,!0))}),sr(a)}return Td.throwArgumentError("invalid type","type",t)}s(MT,"_pack");function Eb(t,e){t.length!=e.length&&Td.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let r=[];return t.forEach(function(n,i){r.push(MT(n,e[i]))}),Ve(sr(r))}s(Eb,"pack");function RT(t,e){return or(Eb(t,e))}s(RT,"keccak256");function BT(t,e){return ds(Eb(t,e))}s(BT,"sha256");var DT="units/5.7.0";var PT=new ve(DT),OT=["wei","kwei","mwei","gwei","szabo","finney","ether"];function FT(t){let e=String(t).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||t==="."||t==="-.")&&PT.throwArgumentError("invalid value","value",t);let r=e[0],n="";for(r.substring(0,1)==="-"&&(n="-",r=r.substring(1));r.substring(0,1)==="0";)r=r.substring(1);r===""&&(r="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let o=[];for(;r.length;)if(r.length<=3){o.unshift(r);break}else{let a=r.length-3;o.unshift(r.substring(a)),r=r.substring(0,a)}return n+o.join(",")+i}s(FT,"commify");function C4(t,e){if(typeof e=="string"){let r=OT.indexOf(e);r!==-1&&(e=3*r)}return Hu(t,e??18)}s(C4,"formatUnits");function S4(t,e){if(typeof t!="string"&&PT.throwArgumentError("value must be a string","value",t),typeof e=="string"){let r=OT.indexOf(e);r!==-1&&(e=3*r)}return ro(t,e??18)}s(S4,"parseUnits");function NT(t){return C4(t,18)}s(NT,"formatEther");function LT(t){return S4(t,18)}s(LT,"parseEther");var k4="ethers/5.7.2";var AW=new ve(k4);try{let t=window;t._ethers==null&&(t._ethers=$i)}catch{}var aie={};var EW=Object.create,m1=Object.defineProperty,CW=Object.getOwnPropertyDescriptor,E8=Object.getOwnPropertyNames,SW=Object.getPrototypeOf,IW=Object.prototype.hasOwnProperty,c=s((t,e)=>m1(t,"name",{value:e,configurable:!0}),"__name"),f5=(t=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(t,{get:(e,r)=>(typeof require<"u"?require:e)[r]}):t)(function(t){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+t+'" is not supported')}),Dr=s((t,e)=>s(function(){return t&&(e=(0,t[E8(t)[0]])(t=0)),e},"__init"),"__esm"),xe=s((t,e)=>s(function(){return e||(0,t[E8(t)[0]])((e={exports:{}}).exports,e),e.exports},"__require2"),"__commonJS"),Kr=s((t,e)=>{for(var r in e)m1(t,r,{get:e[r],enumerable:!0})},"__export"),vR=s((t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of E8(e))!IW.call(t,i)&&i!==r&&m1(t,i,{get:()=>e[i],enumerable:!(n=CW(e,i))||n.enumerable});return t},"__copyProps"),wr=s((t,e,r)=>(r=t!=null?EW(SW(t)):{},vR(e||!t||!t.__esModule?m1(r,"default",{value:t,enumerable:!0}):r,t)),"__toESM"),T4=s(t=>vR(m1({},"__esModule",{value:!0}),t),"__toCommonJS"),Bi=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/global.js"(t,e){var r=c(function(n){return n&&n.Math==Math&&n},"check");e.exports=r(typeof globalThis=="object"&&globalThis)||r(typeof window=="object"&&window)||r(typeof self=="object"&&self)||r(typeof global=="object"&&global)||function(){return this}()||Function("return this")()}}),vs=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/fails.js"(t,e){e.exports=function(r){try{return!!r()}catch{return!0}}}}),ja=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/descriptors.js"(t,e){var r=vs();e.exports=!r(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7})}}),J2=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-bind-native.js"(t,e){var r=vs();e.exports=!r(function(){var n=function(){}.bind();return typeof n!="function"||n.hasOwnProperty("prototype")})}}),Us=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-call.js"(t,e){var r=J2(),n=Function.prototype.call;e.exports=r?n.bind(n):function(){return n.apply(n,arguments)}}}),kW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-property-is-enumerable.js"(t){"use strict";var e={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,n=r&&!e.call({1:2},1);t.f=n?c(s(function(o){var a=r(this,o);return!!a&&a.enumerable},"propertyIsEnumerable"),"propertyIsEnumerable"):e}}),g1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/create-property-descriptor.js"(t,e){e.exports=function(r,n){return{enumerable:!(r&1),configurable:!(r&2),writable:!(r&4),value:n}}}}),Zi=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-uncurry-this.js"(t,e){var r=J2(),n=Function.prototype,i=n.call,o=r&&n.bind.bind(i,i);e.exports=r?o:function(a){return function(){return i.apply(a,arguments)}}}}),Y2=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/classof-raw.js"(t,e){var r=Zi(),n=r({}.toString),i=r("".slice);e.exports=function(o){return i(n(o),8,-1)}}}),TW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/indexed-object.js"(t,e){var r=Zi(),n=vs(),i=Y2(),o=Object,a=r("".split);e.exports=n(function(){return!o("z").propertyIsEnumerable(0)})?function(f){return i(f)=="String"?a(f,""):o(f)}:o}}),Z2=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-null-or-undefined.js"(t,e){e.exports=function(r){return r==null}}}),C8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/require-object-coercible.js"(t,e){var r=Z2(),n=TypeError;e.exports=function(i){if(r(i))throw n("Can't call method on "+i);return i}}}),b1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-indexed-object.js"(t,e){var r=TW(),n=C8();e.exports=function(i){return r(n(i))}}}),yR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/document-all.js"(t,e){var r=typeof document=="object"&&document.all,n=typeof r>"u"&&r!==void 0;e.exports={all:r,IS_HTMLDDA:n}}}),In=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-callable.js"(t,e){var r=yR(),n=r.all;e.exports=r.IS_HTMLDDA?function(i){return typeof i=="function"||i===n}:function(i){return typeof i=="function"}}}),qc=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-object.js"(t,e){var r=In(),n=yR(),i=n.all;e.exports=n.IS_HTMLDDA?function(o){return typeof o=="object"?o!==null:r(o)||o===i}:function(o){return typeof o=="object"?o!==null:r(o)}}}),Hc=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/get-built-in.js"(t,e){var r=Bi(),n=In(),i=c(function(o){return n(o)?o:void 0},"aFunction");e.exports=function(o,a){return arguments.length<2?i(r[o]):r[o]&&r[o][a]}}}),X2=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-is-prototype-of.js"(t,e){var r=Zi();e.exports=r({}.isPrototypeOf)}}),Q2=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-user-agent.js"(t,e){e.exports=typeof navigator<"u"&&String(navigator.userAgent)||""}}),xR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-v8-version.js"(t,e){var r=Bi(),n=Q2(),i=r.process,o=r.Deno,a=i&&i.versions||o&&o.version,f=a&&a.v8,l,u;f&&(l=f.split("."),u=l[0]>0&&l[0]<4?1:+(l[0]+l[1])),!u&&n&&(l=n.match(/Edge\/(\d+)/),(!l||l[1]>=74)&&(l=n.match(/Chrome\/(\d+)/),l&&(u=+l[1]))),e.exports=u}}),wR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/symbol-constructor-detection.js"(t,e){var r=xR(),n=vs();e.exports=!!Object.getOwnPropertySymbols&&!n(function(){var i=Symbol();return!String(i)||!(Object(i)instanceof Symbol)||!Symbol.sham&&r&&r<41})}}),_R=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/use-symbol-as-uid.js"(t,e){var r=wR();e.exports=r&&!Symbol.sham&&typeof Symbol.iterator=="symbol"}}),AR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-symbol.js"(t,e){var r=Hc(),n=In(),i=X2(),o=_R(),a=Object;e.exports=o?function(f){return typeof f=="symbol"}:function(f){var l=r("Symbol");return n(l)&&i(l.prototype,a(f))}}}),ev=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/try-to-string.js"(t,e){var r=String;e.exports=function(n){try{return r(n)}catch{return"Object"}}}}),qa=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/a-callable.js"(t,e){var r=In(),n=ev(),i=TypeError;e.exports=function(o){if(r(o))return o;throw i(n(o)+" is not a function")}}}),S8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/get-method.js"(t,e){var r=qa(),n=Z2();e.exports=function(i,o){var a=i[o];return n(a)?void 0:r(a)}}}),MW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/ordinary-to-primitive.js"(t,e){var r=Us(),n=In(),i=qc(),o=TypeError;e.exports=function(a,f){var l,u;if(f==="string"&&n(l=a.toString)&&!i(u=r(l,a))||n(l=a.valueOf)&&!i(u=r(l,a))||f!=="string"&&n(l=a.toString)&&!i(u=r(l,a)))return u;throw o("Can't convert object to primitive value")}}}),zc=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-pure.js"(t,e){e.exports=!1}}),I8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/define-global-property.js"(t,e){var r=Bi(),n=Object.defineProperty;e.exports=function(i,o){try{n(r,i,{value:o,configurable:!0,writable:!0})}catch{r[i]=o}return o}}}),k8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/shared-store.js"(t,e){var r=Bi(),n=I8(),i="__core-js_shared__",o=r[i]||n(i,{});e.exports=o}}),ER=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/shared.js"(t,e){var r=zc(),n=k8();(e.exports=function(i,o){return n[i]||(n[i]=o!==void 0?o:{})})("versions",[]).push({version:"3.28.0",mode:r?"pure":"global",copyright:"\xA9 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.28.0/LICENSE",source:"https://github.com/zloirock/core-js"})}}),CR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-object.js"(t,e){var r=C8(),n=Object;e.exports=function(i){return n(r(i))}}}),Ha=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/has-own-property.js"(t,e){var r=Zi(),n=CR(),i=r({}.hasOwnProperty);e.exports=Object.hasOwn||c(s(function(a,f){return i(n(a),f)},"hasOwn"),"hasOwn")}}),SR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/uid.js"(t,e){var r=Zi(),n=0,i=Math.random(),o=r(1 .toString);e.exports=function(a){return"Symbol("+(a===void 0?"":a)+")_"+o(++n+i,36)}}}),Xi=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/well-known-symbol.js"(t,e){var r=Bi(),n=ER(),i=Ha(),o=SR(),a=wR(),f=_R(),l=r.Symbol,u=n("wks"),h=f?l.for||l:l&&l.withoutSetter||o;e.exports=function(g){return i(u,g)||(u[g]=a&&i(l,g)?l[g]:h("Symbol."+g)),u[g]}}}),RW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-primitive.js"(t,e){var r=Us(),n=qc(),i=AR(),o=S8(),a=MW(),f=Xi(),l=TypeError,u=f("toPrimitive");e.exports=function(h,g){if(!n(h)||i(h))return h;var x=o(h,u),_;if(x){if(g===void 0&&(g="default"),_=r(x,h,g),!n(_)||i(_))return _;throw l("Can't convert object to primitive value")}return g===void 0&&(g="number"),a(h,g)}}}),IR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-property-key.js"(t,e){var r=RW(),n=AR();e.exports=function(i){var o=r(i,"string");return n(o)?o:o+""}}}),tv=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/document-create-element.js"(t,e){var r=Bi(),n=qc(),i=r.document,o=n(i)&&n(i.createElement);e.exports=function(a){return o?i.createElement(a):{}}}}),kR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/ie8-dom-define.js"(t,e){var r=ja(),n=vs(),i=tv();e.exports=!r&&!n(function(){return Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a!=7})}}),T8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-get-own-property-descriptor.js"(t){var e=ja(),r=Us(),n=kW(),i=g1(),o=b1(),a=IR(),f=Ha(),l=kR(),u=Object.getOwnPropertyDescriptor;t.f=e?u:c(s(function(g,x){if(g=o(g),x=a(x),l)try{return u(g,x)}catch{}if(f(g,x))return i(!r(n.f,g,x),g[x])},"getOwnPropertyDescriptor"),"getOwnPropertyDescriptor")}}),TR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/v8-prototype-define-bug.js"(t,e){var r=ja(),n=vs();e.exports=r&&n(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!=42})}}),za=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/an-object.js"(t,e){var r=qc(),n=String,i=TypeError;e.exports=function(o){if(r(o))return o;throw i(n(o)+" is not an object")}}}),Xf=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-define-property.js"(t){var e=ja(),r=kR(),n=TR(),i=za(),o=IR(),a=TypeError,f=Object.defineProperty,l=Object.getOwnPropertyDescriptor,u="enumerable",h="configurable",g="writable";t.f=e?n?c(s(function(_,E,T){if(i(_),E=o(E),i(T),typeof _=="function"&&E==="prototype"&&"value"in T&&g in T&&!T[g]){var B=l(_,E);B&&B[g]&&(_[E]=T.value,T={configurable:h in T?T[h]:B[h],enumerable:u in T?T[u]:B[u],writable:!1})}return f(_,E,T)},"defineProperty"),"defineProperty"):f:c(s(function(_,E,T){if(i(_),E=o(E),i(T),r)try{return f(_,E,T)}catch{}if("get"in T||"set"in T)throw a("Accessors not supported");return"value"in T&&(_[E]=T.value),_},"defineProperty"),"defineProperty")}}),cu=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/create-non-enumerable-property.js"(t,e){var r=ja(),n=Xf(),i=g1();e.exports=r?function(o,a,f){return n.f(o,a,i(1,f))}:function(o,a,f){return o[a]=f,o}}}),MR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-name.js"(t,e){var r=ja(),n=Ha(),i=Function.prototype,o=r&&Object.getOwnPropertyDescriptor,a=n(i,"name"),f=a&&c(s(function(){},"something"),"something").name==="something",l=a&&(!r||r&&o(i,"name").configurable);e.exports={EXISTS:a,PROPER:f,CONFIGURABLE:l}}}),M8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/inspect-source.js"(t,e){var r=Zi(),n=In(),i=k8(),o=r(Function.toString);n(i.inspectSource)||(i.inspectSource=function(a){return o(a)}),e.exports=i.inspectSource}}),BW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/weak-map-basic-detection.js"(t,e){var r=Bi(),n=In(),i=r.WeakMap;e.exports=n(i)&&/native code/.test(String(i))}}),R8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/shared-key.js"(t,e){var r=ER(),n=SR(),i=r("keys");e.exports=function(o){return i[o]||(i[o]=n(o))}}}),B8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/hidden-keys.js"(t,e){e.exports={}}}),rv=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/internal-state.js"(t,e){var r=BW(),n=Bi(),i=qc(),o=cu(),a=Ha(),f=k8(),l=R8(),u=B8(),h="Object already initialized",g=n.TypeError,x=n.WeakMap,_,E,T,B=c(function(q){return T(q)?E(q):_(q,{})},"enforce"),F=c(function(q){return function(K){var W;if(!i(K)||(W=E(K)).type!==q)throw g("Incompatible receiver, "+q+" required");return W}},"getterFor");r||f.state?(H=f.state||(f.state=new x),H.get=H.get,H.has=H.has,H.set=H.set,_=c(function(q,K){if(H.has(q))throw g(h);return K.facade=q,H.set(q,K),K},"set"),E=c(function(q){return H.get(q)||{}},"get"),T=c(function(q){return H.has(q)},"has")):(U=l("state"),u[U]=!0,_=c(function(q,K){if(a(q,U))throw g(h);return K.facade=q,o(q,U,K),K},"set"),E=c(function(q){return a(q,U)?q[U]:{}},"get"),T=c(function(q){return a(q,U)},"has"));var H,U;e.exports={set:_,get:E,has:T,enforce:B,getterFor:F}}}),RR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/make-built-in.js"(t,e){var r=Zi(),n=vs(),i=In(),o=Ha(),a=ja(),f=MR().CONFIGURABLE,l=M8(),u=rv(),h=u.enforce,g=u.get,x=String,_=Object.defineProperty,E=r("".slice),T=r("".replace),B=r([].join),F=a&&!n(function(){return _(function(){},"length",{value:8}).length!==8}),H=String(String).split("String"),U=e.exports=function(q,K,W){E(x(K),0,7)==="Symbol("&&(K="["+T(x(K),/^Symbol\(([^)]*)\)/,"$1")+"]"),W&&W.getter&&(K="get "+K),W&&W.setter&&(K="set "+K),(!o(q,"name")||f&&q.name!==K)&&(a?_(q,"name",{value:K,configurable:!0}):q.name=K),F&&W&&o(W,"arity")&&q.length!==W.arity&&_(q,"length",{value:W.arity});try{W&&o(W,"constructor")&&W.constructor?a&&_(q,"prototype",{writable:!1}):q.prototype&&(q.prototype=void 0)}catch{}var N=h(q);return o(N,"source")||(N.source=B(H,typeof K=="string"?K:"")),q};Function.prototype.toString=U(c(s(function(){return i(this)&&g(this).source||l(this)},"toString6"),"toString"),"toString")}}),fu=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/define-built-in.js"(t,e){var r=In(),n=Xf(),i=RR(),o=I8();e.exports=function(a,f,l,u){u||(u={});var h=u.enumerable,g=u.name!==void 0?u.name:f;if(r(l)&&i(l,g,u),u.global)h?a[f]=l:o(f,l);else{try{u.unsafe?a[f]&&(h=!0):delete a[f]}catch{}h?a[f]=l:n.f(a,f,{value:l,enumerable:!1,configurable:!u.nonConfigurable,writable:!u.nonWritable})}return a}}}),DW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/math-trunc.js"(t,e){var r=Math.ceil,n=Math.floor;e.exports=Math.trunc||c(s(function(o){var a=+o;return(a>0?n:r)(a)},"trunc"),"trunc")}}),D8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-integer-or-infinity.js"(t,e){var r=DW();e.exports=function(n){var i=+n;return i!==i||i===0?0:r(i)}}}),PW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-absolute-index.js"(t,e){var r=D8(),n=Math.max,i=Math.min;e.exports=function(o,a){var f=r(o);return f<0?n(f+a,0):i(f,a)}}}),OW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-length.js"(t,e){var r=D8(),n=Math.min;e.exports=function(i){return i>0?n(r(i),9007199254740991):0}}}),BR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/length-of-array-like.js"(t,e){var r=OW();e.exports=function(n){return r(n.length)}}}),FW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/array-includes.js"(t,e){var r=b1(),n=PW(),i=BR(),o=c(function(a){return function(f,l,u){var h=r(f),g=i(h),x=n(u,g),_;if(a&&l!=l){for(;g>x;)if(_=h[x++],_!=_)return!0}else for(;g>x;x++)if((a||x in h)&&h[x]===l)return a||x||0;return!a&&-1}},"createMethod");e.exports={includes:o(!0),indexOf:o(!1)}}}),DR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-keys-internal.js"(t,e){var r=Zi(),n=Ha(),i=b1(),o=FW().indexOf,a=B8(),f=r([].push);e.exports=function(l,u){var h=i(l),g=0,x=[],_;for(_ in h)!n(a,_)&&n(h,_)&&f(x,_);for(;u.length>g;)n(h,_=u[g++])&&(~o(x,_)||f(x,_));return x}}}),P8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/enum-bug-keys.js"(t,e){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]}}),NW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-get-own-property-names.js"(t){var e=DR(),r=P8(),n=r.concat("length","prototype");t.f=Object.getOwnPropertyNames||c(s(function(o){return e(o,n)},"getOwnPropertyNames"),"getOwnPropertyNames")}}),LW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-get-own-property-symbols.js"(t){t.f=Object.getOwnPropertySymbols}}),UW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/own-keys.js"(t,e){var r=Hc(),n=Zi(),i=NW(),o=LW(),a=za(),f=n([].concat);e.exports=r("Reflect","ownKeys")||c(s(function(u){var h=i.f(a(u)),g=o.f;return g?f(h,g(u)):h},"ownKeys"),"ownKeys")}}),PR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/copy-constructor-properties.js"(t,e){var r=Ha(),n=UW(),i=T8(),o=Xf();e.exports=function(a,f,l){for(var u=n(f),h=o.f,g=i.f,x=0;x<u.length;x++){var _=u[x];!r(a,_)&&!(l&&r(l,_))&&h(a,_,g(f,_))}}}}),OR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-forced.js"(t,e){var r=vs(),n=In(),i=/#|\.prototype\./,o=c(function(h,g){var x=f[a(h)];return x==u?!0:x==l?!1:n(g)?r(g):!!g},"isForced"),a=o.normalize=function(h){return String(h).replace(i,".").toLowerCase()},f=o.data={},l=o.NATIVE="N",u=o.POLYFILL="P";e.exports=o}}),Wo=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/export.js"(t,e){var r=Bi(),n=T8().f,i=cu(),o=fu(),a=I8(),f=PR(),l=OR();e.exports=function(u,h){var g=u.target,x=u.global,_=u.stat,E,T,B,F,H,U;if(x?T=r:_?T=r[g]||a(g,{}):T=(r[g]||{}).prototype,T)for(B in h){if(H=h[B],u.dontCallGetSet?(U=n(T,B),F=U&&U.value):F=T[B],E=l(x?B:g+(_?".":"#")+B,u.forced),!E&&F!==void 0){if(typeof H==typeof F)continue;f(H,F)}(u.sham||F&&F.sham)&&i(H,"sham",!0),o(T,B,H,u)}}}}),jW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/correct-prototype-getter.js"(t,e){var r=vs();e.exports=!r(function(){function n(){}return s(n,"F"),c(n,"F"),n.prototype.constructor=null,Object.getPrototypeOf(new n)!==n.prototype})}}),O8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-get-prototype-of.js"(t,e){var r=Ha(),n=In(),i=CR(),o=R8(),a=jW(),f=o("IE_PROTO"),l=Object,u=l.prototype;e.exports=a?l.getPrototypeOf:function(h){var g=i(h);if(r(g,f))return g[f];var x=g.constructor;return n(x)&&g instanceof x?x.prototype:g instanceof l?u:null}}}),qW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-uncurry-this-accessor.js"(t,e){var r=Zi(),n=qa();e.exports=function(i,o,a){try{return r(n(Object.getOwnPropertyDescriptor(i,o)[a]))}catch{}}}}),HW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/a-possible-prototype.js"(t,e){var r=In(),n=String,i=TypeError;e.exports=function(o){if(typeof o=="object"||r(o))return o;throw i("Can't set "+n(o)+" as a prototype")}}}),F8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-set-prototype-of.js"(t,e){var r=qW(),n=za(),i=HW();e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var o=!1,a={},f;try{f=r(Object.prototype,"__proto__","set"),f(a,[]),o=a instanceof Array}catch{}return c(s(function(u,h){return n(u),i(h),o?f(u,h):u.__proto__=h,u},"setPrototypeOf"),"setPrototypeOf")}():void 0)}}),zW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-keys.js"(t,e){var r=DR(),n=P8();e.exports=Object.keys||c(s(function(o){return r(o,n)},"keys"),"keys")}}),$W=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-define-properties.js"(t){var e=ja(),r=TR(),n=Xf(),i=za(),o=b1(),a=zW();t.f=e&&!r?Object.defineProperties:c(s(function(l,u){i(l);for(var h=o(u),g=a(u),x=g.length,_=0,E;x>_;)n.f(l,E=g[_++],h[E]);return l},"defineProperties"),"defineProperties")}}),FR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/html.js"(t,e){var r=Hc();e.exports=r("document","documentElement")}}),nv=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-create.js"(t,e){var r=za(),n=$W(),i=P8(),o=B8(),a=FR(),f=tv(),l=R8(),u=">",h="<",g="prototype",x="script",_=l("IE_PROTO"),E=c(function(){},"EmptyConstructor"),T=c(function(q){return h+x+u+q+h+"/"+x+u},"scriptTag"),B=c(function(q){q.write(T("")),q.close();var K=q.parentWindow.Object;return q=null,K},"NullProtoObjectViaActiveX"),F=c(function(){var q=f("iframe"),K="java"+x+":",W;return q.style.display="none",a.appendChild(q),q.src=String(K),W=q.contentWindow.document,W.open(),W.write(T("document.F=Object")),W.close(),W.F},"NullProtoObjectViaIFrame"),H,U=c(function(){try{H=new ActiveXObject("htmlfile")}catch{}U=typeof document<"u"?document.domain&&H?B(H):F():B(H);for(var q=i.length;q--;)delete U[g][i[q]];return U()},"NullProtoObject");o[_]=!0,e.exports=Object.create||c(s(function(K,W){var N;return K!==null?(E[g]=r(K),N=new E,E[g]=null,N[_]=K):N=U(),W===void 0?N:n.f(N,W)},"create2"),"create")}}),GW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/install-error-cause.js"(t,e){var r=qc(),n=cu();e.exports=function(i,o){r(o)&&"cause"in o&&n(i,"cause",o.cause)}}}),KW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/error-stack-clear.js"(t,e){var r=Zi(),n=Error,i=r("".replace),o=function(l){return String(n(l).stack)}("zxcasd"),a=/\n\s*at [^:]*:[^\n]*/,f=a.test(o);e.exports=function(l,u){if(f&&typeof l=="string"&&!n.prepareStackTrace)for(;u--;)l=i(l,a,"");return l}}}),VW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/error-stack-installable.js"(t,e){var r=vs(),n=g1();e.exports=!r(function(){var i=Error("a");return"stack"in i?(Object.defineProperty(i,"stack",n(1,7)),i.stack!==7):!0})}}),WW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/error-stack-install.js"(t,e){var r=cu(),n=KW(),i=VW(),o=Error.captureStackTrace;e.exports=function(a,f,l,u){i&&(o?o(a,f):r(a,"stack",n(l,u)))}}}),JW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-uncurry-this-clause.js"(t,e){var r=Y2(),n=Zi();e.exports=function(i){if(r(i)==="Function")return n(i)}}}),N8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-bind-context.js"(t,e){var r=JW(),n=qa(),i=J2(),o=r(r.bind);e.exports=function(a,f){return n(a),f===void 0?a:i?o(a,f):function(){return a.apply(f,arguments)}}}}),v1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterators.js"(t,e){e.exports={}}}),YW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-array-iterator-method.js"(t,e){var r=Xi(),n=v1(),i=r("iterator"),o=Array.prototype;e.exports=function(a){return a!==void 0&&(n.Array===a||o[i]===a)}}}),L8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-string-tag-support.js"(t,e){var r=Xi(),n=r("toStringTag"),i={};i[n]="z",e.exports=String(i)==="[object z]"}}),iv=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/classof.js"(t,e){var r=L8(),n=In(),i=Y2(),o=Xi(),a=o("toStringTag"),f=Object,l=i(function(){return arguments}())=="Arguments",u=c(function(h,g){try{return h[g]}catch{}},"tryGet");e.exports=r?i:function(h){var g,x,_;return h===void 0?"Undefined":h===null?"Null":typeof(x=u(g=f(h),a))=="string"?x:l?i(g):(_=i(g))=="Object"&&n(g.callee)?"Arguments":_}}}),NR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/get-iterator-method.js"(t,e){var r=iv(),n=S8(),i=Z2(),o=v1(),a=Xi(),f=a("iterator");e.exports=function(l){if(!i(l))return n(l,f)||n(l,"@@iterator")||o[r(l)]}}}),ZW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/get-iterator.js"(t,e){var r=Us(),n=qa(),i=za(),o=ev(),a=NR(),f=TypeError;e.exports=function(l,u){var h=arguments.length<2?a(l):u;if(n(h))return i(r(h,l));throw f(o(l)+" is not iterable")}}}),XW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterator-close.js"(t,e){var r=Us(),n=za(),i=S8();e.exports=function(o,a,f){var l,u;n(o);try{if(l=i(o,"return"),!l){if(a==="throw")throw f;return f}l=r(l,o)}catch(h){u=!0,l=h}if(a==="throw")throw f;if(u)throw l;return n(l),f}}}),y1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterate.js"(t,e){var r=N8(),n=Us(),i=za(),o=ev(),a=YW(),f=BR(),l=X2(),u=ZW(),h=NR(),g=XW(),x=TypeError,_=c(function(T,B){this.stopped=T,this.result=B},"Result"),E=_.prototype;e.exports=function(T,B,F){var H=F&&F.that,U=!!(F&&F.AS_ENTRIES),q=!!(F&&F.IS_RECORD),K=!!(F&&F.IS_ITERATOR),W=!!(F&&F.INTERRUPTED),N=r(B,H),G,ce,re,ae,J,S,m,b=c(function(v){return G&&g(G,"normal",v),new _(!0,v)},"stop"),p=c(function(v){return U?(i(v),W?N(v[0],v[1],b):N(v[0],v[1])):W?N(v,b):N(v)},"callFn");if(q)G=T.iterator;else if(K)G=T;else{if(ce=h(T),!ce)throw x(o(T)+" is not iterable");if(a(ce)){for(re=0,ae=f(T);ae>re;re++)if(J=p(T[re]),J&&l(E,J))return J;return new _(!1)}G=u(T,ce)}for(S=q?T.next:G.next;!(m=n(S,G)).done;){try{J=p(m.value)}catch(v){g(G,"throw",v)}if(typeof J=="object"&&J&&l(E,J))return J}return new _(!1)}}}),U8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/to-string.js"(t,e){var r=iv(),n=String;e.exports=function(i){if(r(i)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return n(i)}}}),QW=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/normalize-string-argument.js"(t,e){var r=U8();e.exports=function(n,i){return n===void 0?arguments.length<2?"":i:r(n)}}}),eJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.aggregate-error.constructor.js"(){"use strict";var t=Wo(),e=X2(),r=O8(),n=F8(),i=PR(),o=nv(),a=cu(),f=g1(),l=GW(),u=WW(),h=y1(),g=QW(),x=Xi(),_=x("toStringTag"),E=Error,T=[].push,B=c(s(function(U,q){var K=e(F,this),W;n?W=n(E(),K?r(this):F):(W=K?this:o(F),a(W,_,"Error")),q!==void 0&&a(W,"message",g(q)),u(W,B,W.stack,1),arguments.length>2&&l(W,arguments[2]);var N=[];return h(U,T,{that:N}),a(W,"errors",N),W},"AggregateError"),"AggregateError");n?n(B,E):i(B,E,{name:!0});var F=B.prototype=o(E.prototype,{constructor:f(1,B),message:f(1,""),name:f(1,"AggregateError")});t({global:!0,constructor:!0,arity:2},{AggregateError:B})}}),tJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.aggregate-error.js"(){eJ()}}),rJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/add-to-unscopables.js"(t,e){var r=Xi(),n=nv(),i=Xf().f,o=r("unscopables"),a=Array.prototype;a[o]==null&&i(a,o,{configurable:!0,value:n(null)}),e.exports=function(f){a[o][f]=!0}}}),LR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterators-core.js"(t,e){"use strict";var r=vs(),n=In(),i=qc(),o=nv(),a=O8(),f=fu(),l=Xi(),u=zc(),h=l("iterator"),g=!1,x,_,E;[].keys&&(E=[].keys(),"next"in E?(_=a(a(E)),_!==Object.prototype&&(x=_)):g=!0);var T=!i(x)||r(function(){var B={};return x[h].call(B)!==B});T?x={}:u&&(x=o(x)),n(x[h])||f(x,h,function(){return this}),e.exports={IteratorPrototype:x,BUGGY_SAFARI_ITERATORS:g}}}),j8=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/set-to-string-tag.js"(t,e){var r=Xf().f,n=Ha(),i=Xi(),o=i("toStringTag");e.exports=function(a,f,l){a&&!l&&(a=a.prototype),a&&!n(a,o)&&r(a,o,{configurable:!0,value:f})}}}),nJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterator-create-constructor.js"(t,e){"use strict";var r=LR().IteratorPrototype,n=nv(),i=g1(),o=j8(),a=v1(),f=c(function(){return this},"returnThis");e.exports=function(l,u,h,g){var x=u+" Iterator";return l.prototype=n(r,{next:i(+!g,h)}),o(l,x,!1,!0),a[x]=f,l}}}),UR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/iterator-define.js"(t,e){"use strict";var r=Wo(),n=Us(),i=zc(),o=MR(),a=In(),f=nJ(),l=O8(),u=F8(),h=j8(),g=cu(),x=fu(),_=Xi(),E=v1(),T=LR(),B=o.PROPER,F=o.CONFIGURABLE,H=T.IteratorPrototype,U=T.BUGGY_SAFARI_ITERATORS,q=_("iterator"),K="keys",W="values",N="entries",G=c(function(){return this},"returnThis");e.exports=function(ce,re,ae,J,S,m,b){f(ae,re,J);var p=c(function(te){if(te===S&&w)return w;if(!U&&te in I)return I[te];switch(te){case K:return c(s(function(){return new ae(this,te)},"keys"),"keys");case W:return c(s(function(){return new ae(this,te)},"values"),"values");case N:return c(s(function(){return new ae(this,te)},"entries"),"entries")}return function(){return new ae(this)}},"getIterationMethod"),v=re+" Iterator",C=!1,I=ce.prototype,k=I[q]||I["@@iterator"]||S&&I[S],w=!U&&k||p(S),A=re=="Array"&&I.entries||k,R,D,M;if(A&&(R=l(A.call(new ce)),R!==Object.prototype&&R.next&&(!i&&l(R)!==H&&(u?u(R,H):a(R[q])||x(R,q,G)),h(R,v,!0,!0),i&&(E[v]=G))),B&&S==W&&k&&k.name!==W&&(!i&&F?g(I,"name",W):(C=!0,w=c(s(function(){return n(k,this)},"values"),"values"))),S)if(D={values:p(W),keys:m?w:p(K),entries:p(N)},b)for(M in D)(U||C||!(M in I))&&x(I,M,D[M]);else r({target:re,proto:!0,forced:U||C},D);return(!i||b)&&I[q]!==w&&x(I,q,w,{name:S}),E[re]=w,D}}}),jR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/create-iter-result-object.js"(t,e){e.exports=function(r,n){return{value:r,done:n}}}}),qR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.array.iterator.js"(t,e){"use strict";var r=b1(),n=rJ(),i=v1(),o=rv(),a=Xf().f,f=UR(),l=jR(),u=zc(),h=ja(),g="Array Iterator",x=o.set,_=o.getterFor(g);e.exports=f(Array,"Array",function(T,B){x(this,{type:g,target:r(T),index:0,kind:B})},function(){var T=_(this),B=T.target,F=T.kind,H=T.index++;return!B||H>=B.length?(T.target=void 0,l(void 0,!0)):F=="keys"?l(H,!1):F=="values"?l(B[H],!1):l([H,B[H]],!1)},"values");var E=i.Arguments=i.Array;if(n("keys"),n("values"),n("entries"),!u&&h&&E.name!=="values")try{a(E,"name",{value:"values"})}catch{}}}),iJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/object-to-string.js"(t,e){"use strict";var r=L8(),n=iv();e.exports=r?{}.toString:c(s(function(){return"[object "+n(this)+"]"},"toString6"),"toString")}}),sJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.object.to-string.js"(){var t=L8(),e=fu(),r=iJ();t||e(Object.prototype,"toString",r,{unsafe:!0})}}),sv=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-node.js"(t,e){var r=Y2();e.exports=typeof process<"u"&&r(process)=="process"}}),oJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/define-built-in-accessor.js"(t,e){var r=RR(),n=Xf();e.exports=function(i,o,a){return a.get&&r(a.get,o,{getter:!0}),a.set&&r(a.set,o,{setter:!0}),n.f(i,o,a)}}}),aJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/set-species.js"(t,e){"use strict";var r=Hc(),n=oJ(),i=Xi(),o=ja(),a=i("species");e.exports=function(f){var l=r(f);o&&l&&!l[a]&&n(l,a,{configurable:!0,get:function(){return this}})}}}),cJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/an-instance.js"(t,e){var r=X2(),n=TypeError;e.exports=function(i,o){if(r(o,i))return i;throw n("Incorrect invocation")}}}),fJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/is-constructor.js"(t,e){var r=Zi(),n=vs(),i=In(),o=iv(),a=Hc(),f=M8(),l=c(function(){},"noop"),u=[],h=a("Reflect","construct"),g=/^\s*(?:class|function)\b/,x=r(g.exec),_=!g.exec(l),E=c(s(function(F){if(!i(F))return!1;try{return h(l,u,F),!0}catch{return!1}},"isConstructor"),"isConstructor"),T=c(s(function(F){if(!i(F))return!1;switch(o(F)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return _||!!x(g,f(F))}catch{return!0}},"isConstructor"),"isConstructor");T.sham=!0,e.exports=!h||n(function(){var B;return E(E.call)||!E(Object)||!E(function(){B=!0})||B})?T:E}}),lJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/a-constructor.js"(t,e){var r=fJ(),n=ev(),i=TypeError;e.exports=function(o){if(r(o))return o;throw i(n(o)+" is not a constructor")}}}),HR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/species-constructor.js"(t,e){var r=za(),n=lJ(),i=Z2(),o=Xi(),a=o("species");e.exports=function(f,l){var u=r(f).constructor,h;return u===void 0||i(h=r(u)[a])?l:n(h)}}}),uJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/function-apply.js"(t,e){var r=J2(),n=Function.prototype,i=n.apply,o=n.call;e.exports=typeof Reflect=="object"&&Reflect.apply||(r?o.bind(i):function(){return o.apply(i,arguments)})}}),dJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/array-slice.js"(t,e){var r=Zi();e.exports=r([].slice)}}),hJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/validate-arguments-length.js"(t,e){var r=TypeError;e.exports=function(n,i){if(n<i)throw r("Not enough arguments");return n}}}),zR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-ios.js"(t,e){var r=Q2();e.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)}}),$R=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/task.js"(t,e){var r=Bi(),n=uJ(),i=N8(),o=In(),a=Ha(),f=vs(),l=FR(),u=dJ(),h=tv(),g=hJ(),x=zR(),_=sv(),E=r.setImmediate,T=r.clearImmediate,B=r.process,F=r.Dispatch,H=r.Function,U=r.MessageChannel,q=r.String,K=0,W={},N="onreadystatechange",G,ce,re,ae;f(function(){G=r.location});var J=c(function(p){if(a(W,p)){var v=W[p];delete W[p],v()}},"run"),S=c(function(p){return function(){J(p)}},"runner"),m=c(function(p){J(p.data)},"eventListener"),b=c(function(p){r.postMessage(q(p),G.protocol+"//"+G.host)},"globalPostMessageDefer");(!E||!T)&&(E=c(s(function(v){g(arguments.length,1);var C=o(v)?v:H(v),I=u(arguments,1);return W[++K]=function(){n(C,void 0,I)},ce(K),K},"setImmediate2"),"setImmediate"),T=c(s(function(v){delete W[v]},"clearImmediate"),"clearImmediate"),_?ce=c(function(p){B.nextTick(S(p))},"defer"):F&&F.now?ce=c(function(p){F.now(S(p))},"defer"):U&&!x?(re=new U,ae=re.port2,re.port1.onmessage=m,ce=i(ae.postMessage,ae)):r.addEventListener&&o(r.postMessage)&&!r.importScripts&&G&&G.protocol!=="file:"&&!f(b)?(ce=b,r.addEventListener("message",m,!1)):N in h("script")?ce=c(function(p){l.appendChild(h("script"))[N]=function(){l.removeChild(this),J(p)}},"defer"):ce=c(function(p){setTimeout(S(p),0)},"defer")),e.exports={set:E,clear:T}}}),GR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/queue.js"(t,e){var r=c(function(){this.head=null,this.tail=null},"Queue");r.prototype={add:function(n){var i={item:n,next:null},o=this.tail;o?o.next=i:this.head=i,this.tail=i},get:function(){var n=this.head;if(n){var i=this.head=n.next;return i===null&&(this.tail=null),n.item}}},e.exports=r}}),pJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-ios-pebble.js"(t,e){var r=Q2();e.exports=/ipad|iphone|ipod/i.test(r)&&typeof Pebble<"u"}}),mJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-webos-webkit.js"(t,e){var r=Q2();e.exports=/web0s(?!.*chrome)/i.test(r)}}),gJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/microtask.js"(t,e){var r=Bi(),n=N8(),i=T8().f,o=$R().set,a=GR(),f=zR(),l=pJ(),u=mJ(),h=sv(),g=r.MutationObserver||r.WebKitMutationObserver,x=r.document,_=r.process,E=r.Promise,T=i(r,"queueMicrotask"),B=T&&T.value,F,H,U,q,K;B||(W=new a,N=c(function(){var G,ce;for(h&&(G=_.domain)&&G.exit();ce=W.get();)try{ce()}catch(re){throw W.head&&F(),re}G&&G.enter()},"flush"),!f&&!h&&!u&&g&&x?(H=!0,U=x.createTextNode(""),new g(N).observe(U,{characterData:!0}),F=c(function(){U.data=H=!H},"notify")):!l&&E&&E.resolve?(q=E.resolve(void 0),q.constructor=E,K=n(q.then,q),F=c(function(){K(N)},"notify")):h?F=c(function(){_.nextTick(N)},"notify"):(o=n(o,r),F=c(function(){o(N)},"notify")),B=c(function(G){W.head||F(),W.add(G)},"microtask"));var W,N;e.exports=B}}),bJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/host-report-errors.js"(t,e){e.exports=function(r,n){try{arguments.length==1?console.error(r):console.error(r,n)}catch{}}}}),x1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/perform.js"(t,e){e.exports=function(r){try{return{error:!1,value:r()}}catch(n){return{error:!0,value:n}}}}}),lh=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/promise-native-constructor.js"(t,e){var r=Bi();e.exports=r.Promise}}),KR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-deno.js"(t,e){e.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"}}),vJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/engine-is-browser.js"(t,e){var r=KR(),n=sv();e.exports=!r&&!n&&typeof window=="object"&&typeof document=="object"}}),w1=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/promise-constructor-detection.js"(t,e){var r=Bi(),n=lh(),i=In(),o=OR(),a=M8(),f=Xi(),l=vJ(),u=KR(),h=zc(),g=xR(),x=n&&n.prototype,_=f("species"),E=!1,T=i(r.PromiseRejectionEvent),B=o("Promise",function(){var F=a(n),H=F!==String(n);if(!H&&g===66||h&&!(x.catch&&x.finally))return!0;if(!g||g<51||!/native code/.test(F)){var U=new n(function(W){W(1)}),q=c(function(W){W(function(){},function(){})},"FakePromise"),K=U.constructor={};if(K[_]=q,E=U.then(function(){})instanceof q,!E)return!0}return!H&&(l||u)&&!T});e.exports={CONSTRUCTOR:B,REJECTION_EVENT:T,SUBCLASSING:E}}}),lu=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/new-promise-capability.js"(t,e){"use strict";var r=qa(),n=TypeError,i=c(function(o){var a,f;this.promise=new o(function(l,u){if(a!==void 0||f!==void 0)throw n("Bad Promise constructor");a=l,f=u}),this.resolve=r(a),this.reject=r(f)},"PromiseCapability");e.exports.f=function(o){return new i(o)}}}),yJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.constructor.js"(){"use strict";var t=Wo(),e=zc(),r=sv(),n=Bi(),i=Us(),o=fu(),a=F8(),f=j8(),l=aJ(),u=qa(),h=In(),g=qc(),x=cJ(),_=HR(),E=$R().set,T=gJ(),B=bJ(),F=x1(),H=GR(),U=rv(),q=lh(),K=w1(),W=lu(),N="Promise",G=K.CONSTRUCTOR,ce=K.REJECTION_EVENT,re=K.SUBCLASSING,ae=U.getterFor(N),J=U.set,S=q&&q.prototype,m=q,b=S,p=n.TypeError,v=n.document,C=n.process,I=W.f,k=I,w=!!(v&&v.createEvent&&n.dispatchEvent),A="unhandledrejection",R="rejectionhandled",D=0,M=1,te=2,L=1,Y=2,Z,P,z,oe,ue=c(function(be){var Se;return g(be)&&h(Se=be.then)?Se:!1},"isThenable"),me=c(function(be,Se){var Te=Se.value,De=Se.state==M,Ne=De?be.ok:be.fail,ye=be.resolve,pe=be.reject,ne=be.domain,he,Ee,Ie;try{Ne?(De||(Se.rejection===Y&&X(Se),Se.rejection=L),Ne===!0?he=Te:(ne&&ne.enter(),he=Ne(Te),ne&&(ne.exit(),Ie=!0)),he===be.promise?pe(p("Promise-chain cycle")):(Ee=ue(he))?i(Ee,he,ye,pe):ye(he)):pe(Te)}catch(Re){ne&&!Ie&&ne.exit(),pe(Re)}},"callReaction"),ke=c(function(be,Se){be.notified||(be.notified=!0,T(function(){for(var Te=be.reactions,De;De=Te.get();)me(De,be);be.notified=!1,Se&&!be.rejection&&j(be)}))},"notify"),Q=c(function(be,Se,Te){var De,Ne;w?(De=v.createEvent("Event"),De.promise=Se,De.reason=Te,De.initEvent(be,!1,!0),n.dispatchEvent(De)):De={promise:Se,reason:Te},!ce&&(Ne=n["on"+be])?Ne(De):be===A&&B("Unhandled promise rejection",Te)},"dispatchEvent"),j=c(function(be){i(E,n,function(){var Se=be.facade,Te=be.value,De=$(be),Ne;if(De&&(Ne=F(function(){r?C.emit("unhandledRejection",Te,Se):Q(A,Se,Te)}),be.rejection=r||$(be)?Y:L,Ne.error))throw Ne.value})},"onUnhandled"),$=c(function(be){return be.rejection!==L&&!be.parent},"isUnhandled"),X=c(function(be){i(E,n,function(){var Se=be.facade;r?C.emit("rejectionHandled",Se):Q(R,Se,be.value)})},"onHandleUnhandled"),se=c(function(be,Se,Te){return function(De){be(Se,De,Te)}},"bind"),ee=c(function(be,Se,Te){be.done||(be.done=!0,Te&&(be=Te),be.value=Se,be.state=te,ke(be,!0))},"internalReject"),le=c(function(be,Se,Te){if(!be.done){be.done=!0,Te&&(be=Te);try{if(be.facade===Se)throw p("Promise can't be resolved itself");var De=ue(Se);De?T(function(){var Ne={done:!1};try{i(De,Se,se(le,Ne,be),se(ee,Ne,be))}catch(ye){ee(Ne,ye,be)}}):(be.value=Se,be.state=M,ke(be,!1))}catch(Ne){ee({done:!1},Ne,be)}}},"internalResolve");if(G&&(m=c(s(function(Se){x(this,b),u(Se),i(Z,this);var Te=ae(this);try{Se(se(le,Te),se(ee,Te))}catch(De){ee(Te,De)}},"Promise2"),"Promise"),b=m.prototype,Z=c(s(function(Se){J(this,{type:N,done:!1,notified:!1,parent:!1,reactions:new H,rejection:!1,state:D,value:void 0})},"Promise2"),"Promise"),Z.prototype=o(b,"then",c(s(function(Se,Te){var De=ae(this),Ne=I(_(this,m));return De.parent=!0,Ne.ok=h(Se)?Se:!0,Ne.fail=h(Te)&&Te,Ne.domain=r?C.domain:void 0,De.state==D?De.reactions.add(Ne):T(function(){me(Ne,De)}),Ne.promise},"then"),"then")),P=c(function(){var be=new Z,Se=ae(be);this.promise=be,this.resolve=se(le,Se),this.reject=se(ee,Se)},"OwnPromiseCapability"),W.f=I=c(function(be){return be===m||be===z?new P(be):k(be)},"newPromiseCapability"),!e&&h(q)&&S!==Object.prototype)){oe=S.then,re||o(S,"then",c(s(function(Se,Te){var De=this;return new m(function(Ne,ye){i(oe,De,Ne,ye)}).then(Se,Te)},"then"),"then"),{unsafe:!0});try{delete S.constructor}catch{}a&&a(S,b)}t({global:!0,constructor:!0,wrap:!0,forced:G},{Promise:m}),f(m,N,!1,!0),l(N)}}),xJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/check-correctness-of-iteration.js"(t,e){var r=Xi(),n=r("iterator"),i=!1;try{o=0,a={next:function(){return{done:!!o++}},return:function(){i=!0}},a[n]=function(){return this},Array.from(a,function(){throw 2})}catch{}var o,a;e.exports=function(f,l){if(!l&&!i)return!1;var u=!1;try{var h={};h[n]=function(){return{next:function(){return{done:u=!0}}}},f(h)}catch{}return u}}}),ov=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/promise-statics-incorrect-iteration.js"(t,e){var r=lh(),n=xJ(),i=w1().CONSTRUCTOR;e.exports=i||!n(function(o){r.all(o).then(void 0,function(){})})}}),wJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.all.js"(){"use strict";var t=Wo(),e=Us(),r=qa(),n=lu(),i=x1(),o=y1(),a=ov();t({target:"Promise",stat:!0,forced:a},{all:c(s(function(l){var u=this,h=n.f(u),g=h.resolve,x=h.reject,_=i(function(){var E=r(u.resolve),T=[],B=0,F=1;o(l,function(H){var U=B++,q=!1;F++,e(E,u,H).then(function(K){q||(q=!0,T[U]=K,--F||g(T))},x)}),--F||g(T)});return _.error&&x(_.value),h.promise},"all"),"all")})}}),_J=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.catch.js"(){"use strict";var t=Wo(),e=zc(),r=w1().CONSTRUCTOR,n=lh(),i=Hc(),o=In(),a=fu(),f=n&&n.prototype;t({target:"Promise",proto:!0,forced:r,real:!0},{catch:function(u){return this.then(void 0,u)}}),!e&&o(n)&&(l=i("Promise").prototype.catch,f.catch!==l&&a(f,"catch",l,{unsafe:!0}));var l}}),AJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.race.js"(){"use strict";var t=Wo(),e=Us(),r=qa(),n=lu(),i=x1(),o=y1(),a=ov();t({target:"Promise",stat:!0,forced:a},{race:c(s(function(l){var u=this,h=n.f(u),g=h.reject,x=i(function(){var _=r(u.resolve);o(l,function(E){e(_,u,E).then(h.resolve,g)})});return x.error&&g(x.value),h.promise},"race"),"race")})}}),EJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.reject.js"(){"use strict";var t=Wo(),e=Us(),r=lu(),n=w1().CONSTRUCTOR;t({target:"Promise",stat:!0,forced:n},{reject:c(s(function(o){var a=r.f(this);return e(a.reject,void 0,o),a.promise},"reject"),"reject")})}}),VR=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/promise-resolve.js"(t,e){var r=za(),n=qc(),i=lu();e.exports=function(o,a){if(r(o),n(a)&&a.constructor===o)return a;var f=i.f(o),l=f.resolve;return l(a),f.promise}}}),CJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.resolve.js"(){"use strict";var t=Wo(),e=Hc(),r=zc(),n=lh(),i=w1().CONSTRUCTOR,o=VR(),a=e("Promise"),f=r&&!i;t({target:"Promise",stat:!0,forced:r||i},{resolve:c(s(function(u){return o(f&&this===a?n:this,u)},"resolve"),"resolve")})}}),SJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.js"(){yJ(),wJ(),_J(),AJ(),EJ(),CJ()}}),IJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.all-settled.js"(){"use strict";var t=Wo(),e=Us(),r=qa(),n=lu(),i=x1(),o=y1(),a=ov();t({target:"Promise",stat:!0,forced:a},{allSettled:c(s(function(l){var u=this,h=n.f(u),g=h.resolve,x=h.reject,_=i(function(){var E=r(u.resolve),T=[],B=0,F=1;o(l,function(H){var U=B++,q=!1;F++,e(E,u,H).then(function(K){q||(q=!0,T[U]={status:"fulfilled",value:K},--F||g(T))},function(K){q||(q=!0,T[U]={status:"rejected",reason:K},--F||g(T))})}),--F||g(T)});return _.error&&x(_.value),h.promise},"allSettled"),"allSettled")})}}),kJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.any.js"(){"use strict";var t=Wo(),e=Us(),r=qa(),n=Hc(),i=lu(),o=x1(),a=y1(),f=ov(),l="No one promise resolved";t({target:"Promise",stat:!0,forced:f},{any:c(s(function(h){var g=this,x=n("AggregateError"),_=i.f(g),E=_.resolve,T=_.reject,B=o(function(){var F=r(g.resolve),H=[],U=0,q=1,K=!1;a(h,function(W){var N=U++,G=!1;q++,e(F,g,W).then(function(ce){G||K||(K=!0,E(ce))},function(ce){G||K||(G=!0,H[N]=ce,--q||T(new x(H,l)))})}),--q||T(new x(H,l))});return B.error&&T(B.value),_.promise},"any"),"any")})}}),TJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.promise.finally.js"(){"use strict";var t=Wo(),e=zc(),r=lh(),n=vs(),i=Hc(),o=In(),a=HR(),f=VR(),l=fu(),u=r&&r.prototype,h=!!r&&n(function(){u.finally.call({then:function(){}},function(){})});t({target:"Promise",proto:!0,real:!0,forced:h},{finally:function(x){var _=a(this,i("Promise")),E=o(x);return this.then(E?function(T){return f(_,x()).then(function(){return T})}:x,E?function(T){return f(_,x()).then(function(){throw T})}:x)}}),!e&&o(r)&&(g=i("Promise").prototype.finally,u.finally!==g&&l(u,"finally",g,{unsafe:!0}));var g}}),MJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/string-multibyte.js"(t,e){var r=Zi(),n=D8(),i=U8(),o=C8(),a=r("".charAt),f=r("".charCodeAt),l=r("".slice),u=c(function(h){return function(g,x){var _=i(o(g)),E=n(x),T=_.length,B,F;return E<0||E>=T?h?"":void 0:(B=f(_,E),B<55296||B>56319||E+1===T||(F=f(_,E+1))<56320||F>57343?h?a(_,E):B:h?l(_,E,E+2):(B-55296<<10)+(F-56320)+65536)}},"createMethod");e.exports={codeAt:u(!1),charAt:u(!0)}}}),RJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/es.string.iterator.js"(){"use strict";var t=MJ().charAt,e=U8(),r=rv(),n=UR(),i=jR(),o="String Iterator",a=r.set,f=r.getterFor(o);n(String,"String",function(l){a(this,{type:o,string:e(l),index:0})},c(s(function(){var u=f(this),h=u.string,g=u.index,x;return g>=h.length?i(void 0,!0):(x=t(h,g),u.index+=x.length,i(x,!1))},"next"),"next"))}}),BJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/path.js"(t,e){var r=Bi();e.exports=r}}),DJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/es/promise/index.js"(t,e){tJ(),qR(),sJ(),SJ(),IJ(),kJ(),TJ(),RJ();var r=BJ();e.exports=r.Promise}}),PJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/dom-iterables.js"(t,e){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}}}),OJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/internals/dom-token-list-prototype.js"(t,e){var r=tv(),n=r("span").classList,i=n&&n.constructor&&n.constructor.prototype;e.exports=i===Object.prototype?void 0:i}}),FJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/modules/web.dom-collections.iterator.js"(){var t=Bi(),e=PJ(),r=OJ(),n=qR(),i=cu(),o=Xi(),a=o("iterator"),f=o("toStringTag"),l=n.values,u=c(function(g,x){if(g){if(g[a]!==l)try{i(g,a,l)}catch{g[a]=l}if(g[f]||i(g,f,x),e[x]){for(var _ in n)if(g[_]!==n[_])try{i(g,_,n[_])}catch{g[_]=n[_]}}}},"handlePrototype");for(h in e)u(t[h]&&t[h].prototype,h);var h;u(r,"DOMTokenList")}}),NJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/stable/promise/index.js"(t,e){var r=DJ();FJ(),e.exports=r}}),LJ=xe({"../../node_modules/.pnpm/core-js@3.28.0/node_modules/core-js/actual/promise/index.js"(t,e){var r=NJ();e.exports=r}}),UJ=xe({"../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js"(t,e){(function(){var r,n="4.17.21",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",f="Invalid `variable` option passed into `_.template`",l="__lodash_hash_undefined__",u=500,h="__lodash_placeholder__",g=1,x=2,_=4,E=1,T=2,B=1,F=2,H=4,U=8,q=16,K=32,W=64,N=128,G=256,ce=512,re=30,ae="...",J=800,S=16,m=1,b=2,p=3,v=1/0,C=9007199254740991,I=17976931348623157e292,k=0/0,w=4294967295,A=w-1,R=w>>>1,D=[["ary",N],["bind",B],["bindKey",F],["curry",U],["curryRight",q],["flip",ce],["partial",K],["partialRight",W],["rearg",G]],M="[object Arguments]",te="[object Array]",L="[object AsyncFunction]",Y="[object Boolean]",Z="[object Date]",P="[object DOMException]",z="[object Error]",oe="[object Function]",ue="[object GeneratorFunction]",me="[object Map]",ke="[object Number]",Q="[object Null]",j="[object Object]",$="[object Promise]",X="[object Proxy]",se="[object RegExp]",ee="[object Set]",le="[object String]",be="[object Symbol]",Se="[object Undefined]",Te="[object WeakMap]",De="[object WeakSet]",Ne="[object ArrayBuffer]",ye="[object DataView]",pe="[object Float32Array]",ne="[object Float64Array]",he="[object Int8Array]",Ee="[object Int16Array]",Ie="[object Int32Array]",Re="[object Uint8Array]",Oe="[object Uint8ClampedArray]",bt="[object Uint16Array]",Qe="[object Uint32Array]",qe=/\b__p \+= '';/g,vt=/\b(__p \+=) '' \+/g,gt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,tt=/&(?:amp|lt|gt|quot|#39);/g,Ut=/[&<>"']/g,ht=RegExp(tt.source),et=RegExp(Ut.source),Dt=/<%-([\s\S]+?)%>/g,pt=/<%([\s\S]+?)%>/g,Xe=/<%=([\s\S]+?)%>/g,Mt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ft=/^\w*$/,Ye=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,It=/[\\^$.*+?()[\]{}|]/g,lt=RegExp(It.source),Ze=/^\s+/,Rt=/\s/,ut=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Je=/\{\n\/\* \[wrapped with (.+)\] \*/,Bt=/,? & /,dt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,at=/[()=,{}\[\]\/\s]/,tr=/\\(\\)?/g,Tt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,rt=/\w*$/,Yt=/^[-+]0x[0-9a-f]+$/i,Kt=/^0b[01]+$/i,Vt=/^\[object .+?Constructor\]$/,Vr=/^0o[0-7]+$/i,Wr=/^(?:0|[1-9]\d*)$/,Ir=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,tn=/($^)/,xn=/['\n\r\u2028\u2029\\]/g,Pn="\\ud800-\\udfff",li="\\u0300-\\u036f",ui="\\ufe20-\\ufe2f",di="\\u20d0-\\u20ff",Hn=li+ui+di,kn="\\u2700-\\u27bf",Qn="a-z\\xdf-\\xf6\\xf8-\\xff",zn="\\xac\\xb1\\xd7\\xf7",hi="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",pi="\\u2000-\\u206f",mi=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ys="A-Z\\xc0-\\xd6\\xd8-\\xde",Za="\\ufe0e\\ufe0f",Xa=zn+hi+pi+mi,Vc="['\u2019]",G1="["+Pn+"]",Ih="["+Xa+"]",sl="["+Hn+"]",kh="\\d+",K1="["+kn+"]",Th="["+Qn+"]",Mh="[^"+Pn+Xa+kh+kn+Qn+ys+"]",ol="\\ud83c[\\udffb-\\udfff]",V1="(?:"+sl+"|"+ol+")",Rh="[^"+Pn+"]",Qa="(?:\\ud83c[\\udde6-\\uddff]){2}",vo="[\\ud800-\\udbff][\\udc00-\\udfff]",ec="["+ys+"]",Xo="\\u200d",Bh="(?:"+Th+"|"+Mh+")",W1="(?:"+ec+"|"+Mh+")",Dh="(?:"+Vc+"(?:d|ll|m|re|s|t|ve))?",Ph="(?:"+Vc+"(?:D|LL|M|RE|S|T|VE))?",Oh=V1+"?",Fh="["+Za+"]?",Nh="(?:"+Xo+"(?:"+[Rh,Qa,vo].join("|")+")"+Fh+Oh+")*",Qo="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",J1="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",xu=Fh+Oh+Nh,Y1="(?:"+[K1,Qa,vo].join("|")+")"+xu,Lh="(?:"+[Rh+sl+"?",sl,Qa,vo,G1].join("|")+")",Uh=RegExp(Vc,"g"),Z1=RegExp(sl,"g"),jh=RegExp(ol+"(?="+ol+")|"+Lh+xu,"g"),qh=RegExp([ec+"?"+Th+"+"+Dh+"(?="+[Ih,ec,"$"].join("|")+")",W1+"+"+Ph+"(?="+[Ih,ec+Bh,"$"].join("|")+")",ec+"?"+Bh+"+"+Dh,ec+"+"+Ph,J1,Qo,kh,Y1].join("|"),"g"),X1=RegExp("["+Xo+Pn+Hn+Za+"]"),al=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Q1=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],wu=-1,Ur={};Ur[pe]=Ur[ne]=Ur[he]=Ur[Ee]=Ur[Ie]=Ur[Re]=Ur[Oe]=Ur[bt]=Ur[Qe]=!0,Ur[M]=Ur[te]=Ur[Ne]=Ur[Y]=Ur[ye]=Ur[Z]=Ur[z]=Ur[oe]=Ur[me]=Ur[ke]=Ur[j]=Ur[se]=Ur[ee]=Ur[le]=Ur[Te]=!1;var Pr={};Pr[M]=Pr[te]=Pr[Ne]=Pr[ye]=Pr[Y]=Pr[Z]=Pr[pe]=Pr[ne]=Pr[he]=Pr[Ee]=Pr[Ie]=Pr[me]=Pr[ke]=Pr[j]=Pr[se]=Pr[ee]=Pr[le]=Pr[be]=Pr[Re]=Pr[Oe]=Pr[bt]=Pr[Qe]=!0,Pr[z]=Pr[oe]=Pr[Te]=!1;var ge={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},Fe={"&":"&","<":"<",">":">",'"':""","'":"'"},$e={"&":"&","<":"<",">":">",""":'"',"'":"'"},Et={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Tn=parseFloat,ei=parseInt,Pi=typeof global=="object"&&global&&global.Object===Object&&global,gi=typeof self=="object"&&self&&self.Object===Object&&self,wn=Pi||gi||Function("return this")(),ea=typeof t=="object"&&t&&!t.nodeType&&t,ta=ea&&typeof e=="object"&&e&&!e.nodeType&&e,Hh=ta&&ta.exports===ea,_u=Hh&&Pi.process,bi=function(){try{var Me=ta&&ta.require&&ta.require("util").types;return Me||_u&&_u.binding&&_u.binding("util")}catch{}}(),cl=bi&&bi.isArrayBuffer,e7=bi&&bi.isDate,t7=bi&&bi.isMap,r7=bi&&bi.isRegExp,n7=bi&&bi.isSet,i7=bi&&bi.isTypedArray;function Qi(Me,He,Le){switch(Le.length){case 0:return Me.call(He);case 1:return Me.call(He,Le[0]);case 2:return Me.call(He,Le[0],Le[1]);case 3:return Me.call(He,Le[0],Le[1],Le[2])}return Me.apply(He,Le)}s(Qi,"apply"),c(Qi,"apply");function s7(Me,He,Le,_t){for(var Ht=-1,kr=Me==null?0:Me.length;++Ht<kr;){var On=Me[Ht];He(_t,On,Le(On),Me)}return _t}s(s7,"arrayAggregator"),c(s7,"arrayAggregator");function xs(Me,He){for(var Le=-1,_t=Me==null?0:Me.length;++Le<_t&&He(Me[Le],Le,Me)!==!1;);return Me}s(xs,"arrayEach"),c(xs,"arrayEach");function o7(Me,He){for(var Le=Me==null?0:Me.length;Le--&&He(Me[Le],Le,Me)!==!1;);return Me}s(o7,"arrayEachRight"),c(o7,"arrayEachRight");function e6(Me,He){for(var Le=-1,_t=Me==null?0:Me.length;++Le<_t;)if(!He(Me[Le],Le,Me))return!1;return!0}s(e6,"arrayEvery"),c(e6,"arrayEvery");function tc(Me,He){for(var Le=-1,_t=Me==null?0:Me.length,Ht=0,kr=[];++Le<_t;){var On=Me[Le];He(On,Le,Me)&&(kr[Ht++]=On)}return kr}s(tc,"arrayFilter"),c(tc,"arrayFilter");function zh(Me,He){var Le=Me==null?0:Me.length;return!!Le&&fl(Me,He,0)>-1}s(zh,"arrayIncludes"),c(zh,"arrayIncludes");function em(Me,He,Le){for(var _t=-1,Ht=Me==null?0:Me.length;++_t<Ht;)if(Le(He,Me[_t]))return!0;return!1}s(em,"arrayIncludesWith"),c(em,"arrayIncludesWith");function Xr(Me,He){for(var Le=-1,_t=Me==null?0:Me.length,Ht=Array(_t);++Le<_t;)Ht[Le]=He(Me[Le],Le,Me);return Ht}s(Xr,"arrayMap"),c(Xr,"arrayMap");function rc(Me,He){for(var Le=-1,_t=He.length,Ht=Me.length;++Le<_t;)Me[Ht+Le]=He[Le];return Me}s(rc,"arrayPush"),c(rc,"arrayPush");function tm(Me,He,Le,_t){var Ht=-1,kr=Me==null?0:Me.length;for(_t&&kr&&(Le=Me[++Ht]);++Ht<kr;)Le=He(Le,Me[Ht],Ht,Me);return Le}s(tm,"arrayReduce"),c(tm,"arrayReduce");function a7(Me,He,Le,_t){var Ht=Me==null?0:Me.length;for(_t&&Ht&&(Le=Me[--Ht]);Ht--;)Le=He(Le,Me[Ht],Ht,Me);return Le}s(a7,"arrayReduceRight"),c(a7,"arrayReduceRight");function rm(Me,He){for(var Le=-1,_t=Me==null?0:Me.length;++Le<_t;)if(He(Me[Le],Le,Me))return!0;return!1}s(rm,"arraySome"),c(rm,"arraySome");var Yj=nm("length");function c7(Me){return Me.split("")}s(c7,"asciiToArray"),c(c7,"asciiToArray");function f7(Me){return Me.match(dt)||[]}s(f7,"asciiWords"),c(f7,"asciiWords");function t6(Me,He,Le){var _t;return Le(Me,function(Ht,kr,On){if(He(Ht,kr,On))return _t=kr,!1}),_t}s(t6,"baseFindKey"),c(t6,"baseFindKey");function $h(Me,He,Le,_t){for(var Ht=Me.length,kr=Le+(_t?1:-1);_t?kr--:++kr<Ht;)if(He(Me[kr],kr,Me))return kr;return-1}s($h,"baseFindIndex"),c($h,"baseFindIndex");function fl(Me,He,Le){return He===He?y7(Me,He,Le):$h(Me,r6,Le)}s(fl,"baseIndexOf"),c(fl,"baseIndexOf");function l7(Me,He,Le,_t){for(var Ht=Le-1,kr=Me.length;++Ht<kr;)if(_t(Me[Ht],He))return Ht;return-1}s(l7,"baseIndexOfWith"),c(l7,"baseIndexOfWith");function r6(Me){return Me!==Me}s(r6,"baseIsNaN"),c(r6,"baseIsNaN");function n6(Me,He){var Le=Me==null?0:Me.length;return Le?sm(Me,He)/Le:k}s(n6,"baseMean"),c(n6,"baseMean");function nm(Me){return function(He){return He==null?r:He[Me]}}s(nm,"baseProperty"),c(nm,"baseProperty");function im(Me){return function(He){return Me==null?r:Me[He]}}s(im,"basePropertyOf"),c(im,"basePropertyOf");function i6(Me,He,Le,_t,Ht){return Ht(Me,function(kr,On,Hr){Le=_t?(_t=!1,kr):He(Le,kr,On,Hr)}),Le}s(i6,"baseReduce"),c(i6,"baseReduce");function u7(Me,He){var Le=Me.length;for(Me.sort(He);Le--;)Me[Le]=Me[Le].value;return Me}s(u7,"baseSortBy"),c(u7,"baseSortBy");function sm(Me,He){for(var Le,_t=-1,Ht=Me.length;++_t<Ht;){var kr=He(Me[_t]);kr!==r&&(Le=Le===r?kr:Le+kr)}return Le}s(sm,"baseSum"),c(sm,"baseSum");function om(Me,He){for(var Le=-1,_t=Array(Me);++Le<Me;)_t[Le]=He(Le);return _t}s(om,"baseTimes"),c(om,"baseTimes");function d7(Me,He){return Xr(He,function(Le){return[Le,Me[Le]]})}s(d7,"baseToPairs"),c(d7,"baseToPairs");function s6(Me){return Me&&Me.slice(0,f6(Me)+1).replace(Ze,"")}s(s6,"baseTrim"),c(s6,"baseTrim");function es(Me){return function(He){return Me(He)}}s(es,"baseUnary"),c(es,"baseUnary");function am(Me,He){return Xr(He,function(Le){return Me[Le]})}s(am,"baseValues"),c(am,"baseValues");function Au(Me,He){return Me.has(He)}s(Au,"cacheHas"),c(Au,"cacheHas");function o6(Me,He){for(var Le=-1,_t=Me.length;++Le<_t&&fl(He,Me[Le],0)>-1;);return Le}s(o6,"charsStartIndex"),c(o6,"charsStartIndex");function a6(Me,He){for(var Le=Me.length;Le--&&fl(He,Me[Le],0)>-1;);return Le}s(a6,"charsEndIndex"),c(a6,"charsEndIndex");function h7(Me,He){for(var Le=Me.length,_t=0;Le--;)Me[Le]===He&&++_t;return _t}s(h7,"countHolders"),c(h7,"countHolders");var Zj=im(ge),Xj=im(Fe);function p7(Me){return"\\"+Et[Me]}s(p7,"escapeStringChar"),c(p7,"escapeStringChar");function m7(Me,He){return Me==null?r:Me[He]}s(m7,"getValue"),c(m7,"getValue");function ll(Me){return X1.test(Me)}s(ll,"hasUnicode"),c(ll,"hasUnicode");function g7(Me){return al.test(Me)}s(g7,"hasUnicodeWord"),c(g7,"hasUnicodeWord");function b7(Me){for(var He,Le=[];!(He=Me.next()).done;)Le.push(He.value);return Le}s(b7,"iteratorToArray"),c(b7,"iteratorToArray");function cm(Me){var He=-1,Le=Array(Me.size);return Me.forEach(function(_t,Ht){Le[++He]=[Ht,_t]}),Le}s(cm,"mapToArray"),c(cm,"mapToArray");function c6(Me,He){return function(Le){return Me(He(Le))}}s(c6,"overArg"),c(c6,"overArg");function nc(Me,He){for(var Le=-1,_t=Me.length,Ht=0,kr=[];++Le<_t;){var On=Me[Le];(On===He||On===h)&&(Me[Le]=h,kr[Ht++]=Le)}return kr}s(nc,"replaceHolders"),c(nc,"replaceHolders");function Gh(Me){var He=-1,Le=Array(Me.size);return Me.forEach(function(_t){Le[++He]=_t}),Le}s(Gh,"setToArray"),c(Gh,"setToArray");function v7(Me){var He=-1,Le=Array(Me.size);return Me.forEach(function(_t){Le[++He]=[_t,_t]}),Le}s(v7,"setToPairs"),c(v7,"setToPairs");function y7(Me,He,Le){for(var _t=Le-1,Ht=Me.length;++_t<Ht;)if(Me[_t]===He)return _t;return-1}s(y7,"strictIndexOf"),c(y7,"strictIndexOf");function x7(Me,He,Le){for(var _t=Le+1;_t--;)if(Me[_t]===He)return _t;return _t}s(x7,"strictLastIndexOf"),c(x7,"strictLastIndexOf");function ul(Me){return ll(Me)?w7(Me):Yj(Me)}s(ul,"stringSize"),c(ul,"stringSize");function Gs(Me){return ll(Me)?_7(Me):c7(Me)}s(Gs,"stringToArray"),c(Gs,"stringToArray");function f6(Me){for(var He=Me.length;He--&&Rt.test(Me.charAt(He)););return He}s(f6,"trimmedEndIndex"),c(f6,"trimmedEndIndex");var Qj=im($e);function w7(Me){for(var He=jh.lastIndex=0;jh.test(Me);)++He;return He}s(w7,"unicodeSize"),c(w7,"unicodeSize");function _7(Me){return Me.match(jh)||[]}s(_7,"unicodeToArray"),c(_7,"unicodeToArray");function A7(Me){return Me.match(qh)||[]}s(A7,"unicodeWords"),c(A7,"unicodeWords");var eq=c(s(function Me(He){He=He==null?wn:Wc.defaults(wn.Object(),He,Wc.pick(wn,Q1));var Le=He.Array,_t=He.Date,Ht=He.Error,kr=He.Function,On=He.Math,Hr=He.Object,l6=He.RegExp,tq=He.String,Ks=He.TypeError,fm=Le.prototype,rq=kr.prototype,Eu=Hr.prototype,lm=He["__core-js_shared__"],um=rq.toString,Or=Eu.hasOwnProperty,nq=0,E7=function(){var d=/[^.]+$/.exec(lm&&lm.keys&&lm.keys.IE_PROTO||"");return d?"Symbol(src)_1."+d:""}(),dm=Eu.toString,iq=um.call(Hr),sq=wn._,oq=l6("^"+um.call(Or).replace(It,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),hm=Hh?He.Buffer:r,Jc=He.Symbol,pm=He.Uint8Array,C7=hm?hm.allocUnsafe:r,mm=c6(Hr.getPrototypeOf,Hr),S7=Hr.create,I7=Eu.propertyIsEnumerable,gm=fm.splice,k7=Jc?Jc.isConcatSpreadable:r,Kh=Jc?Jc.iterator:r,dl=Jc?Jc.toStringTag:r,bm=function(){try{var d=tf(Hr,"defineProperty");return d({},"",{}),d}catch{}}(),aq=He.clearTimeout!==wn.clearTimeout&&He.clearTimeout,cq=_t&&_t.now!==wn.Date.now&&_t.now,fq=He.setTimeout!==wn.setTimeout&&He.setTimeout,vm=On.ceil,ym=On.floor,u6=Hr.getOwnPropertySymbols,lq=hm?hm.isBuffer:r,T7=He.isFinite,uq=fm.join,dq=c6(Hr.keys,Hr),Fn=On.max,vi=On.min,hq=_t.now,pq=He.parseInt,M7=On.random,mq=fm.reverse,d6=tf(He,"DataView"),Vh=tf(He,"Map"),h6=tf(He,"Promise"),Cu=tf(He,"Set"),Wh=tf(He,"WeakMap"),Jh=tf(Hr,"create"),xm=Wh&&new Wh,Su={},gq=rf(d6),bq=rf(Vh),vq=rf(h6),yq=rf(Cu),xq=rf(Wh),wm=Jc?Jc.prototype:r,Yh=wm?wm.valueOf:r,R7=wm?wm.toString:r;function fe(d){if(on(d)&&!Wt(d)&&!(d instanceof hr)){if(d instanceof ws)return d;if(Or.call(d,"__wrapped__"))return uy(d)}return new ws(d)}s(fe,"lodash"),c(fe,"lodash");var Iu=function(){function d(){}return s(d,"object"),c(d,"object"),function(y){if(!rn(y))return{};if(S7)return S7(y);d.prototype=y;var O=new d;return d.prototype=r,O}}();function Zh(){}s(Zh,"baseLodash"),c(Zh,"baseLodash");function ws(d,y){this.__wrapped__=d,this.__actions__=[],this.__chain__=!!y,this.__index__=0,this.__values__=r}s(ws,"LodashWrapper"),c(ws,"LodashWrapper"),fe.templateSettings={escape:Dt,evaluate:pt,interpolate:Xe,variable:"",imports:{_:fe}},fe.prototype=Zh.prototype,fe.prototype.constructor=fe,ws.prototype=Iu(Zh.prototype),ws.prototype.constructor=ws;function hr(d){this.__wrapped__=d,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=w,this.__views__=[]}s(hr,"LazyWrapper"),c(hr,"LazyWrapper");function B7(){var d=new hr(this.__wrapped__);return d.__actions__=Oi(this.__actions__),d.__dir__=this.__dir__,d.__filtered__=this.__filtered__,d.__iteratees__=Oi(this.__iteratees__),d.__takeCount__=this.__takeCount__,d.__views__=Oi(this.__views__),d}s(B7,"lazyClone"),c(B7,"lazyClone");function D7(){if(this.__filtered__){var d=new hr(this);d.__dir__=-1,d.__filtered__=!0}else d=this.clone(),d.__dir__*=-1;return d}s(D7,"lazyReverse"),c(D7,"lazyReverse");function P7(){var d=this.__wrapped__.value(),y=this.__dir__,O=Wt(d),V=y<0,ie=O?d.length:0,de=W9(0,ie,this.__views__),Ae=de.start,Ce=de.end,Be=Ce-Ae,Ge=V?Ce:Ae-1,Ke=this.__iteratees__,We=Ke.length,mt=0,Ct=vi(Be,this.__takeCount__);if(!O||!V&&ie==Be&&Ct==Be)return O6(d,this.__actions__);var Lt=[];e:for(;Be--&&mt<Ct;){Ge+=y;for(var rr=-1,Ft=d[Ge];++rr<We;){var lr=Ke[rr],gr=lr.iteratee,ns=lr.type,_i=gr(Ft);if(ns==b)Ft=_i;else if(!_i){if(ns==m)continue e;break e}}Lt[mt++]=Ft}return Lt}s(P7,"lazyValue"),c(P7,"lazyValue"),hr.prototype=Iu(Zh.prototype),hr.prototype.constructor=hr;function Yc(d){var y=-1,O=d==null?0:d.length;for(this.clear();++y<O;){var V=d[y];this.set(V[0],V[1])}}s(Yc,"Hash"),c(Yc,"Hash");function O7(){this.__data__=Jh?Jh(null):{},this.size=0}s(O7,"hashClear"),c(O7,"hashClear");function F7(d){var y=this.has(d)&&delete this.__data__[d];return this.size-=y?1:0,y}s(F7,"hashDelete"),c(F7,"hashDelete");function N7(d){var y=this.__data__;if(Jh){var O=y[d];return O===l?r:O}return Or.call(y,d)?y[d]:r}s(N7,"hashGet"),c(N7,"hashGet");function L7(d){var y=this.__data__;return Jh?y[d]!==r:Or.call(y,d)}s(L7,"hashHas"),c(L7,"hashHas");function U7(d,y){var O=this.__data__;return this.size+=this.has(d)?0:1,O[d]=Jh&&y===r?l:y,this}s(U7,"hashSet"),c(U7,"hashSet"),Yc.prototype.clear=O7,Yc.prototype.delete=F7,Yc.prototype.get=N7,Yc.prototype.has=L7,Yc.prototype.set=U7;function ra(d){var y=-1,O=d==null?0:d.length;for(this.clear();++y<O;){var V=d[y];this.set(V[0],V[1])}}s(ra,"ListCache"),c(ra,"ListCache");function j7(){this.__data__=[],this.size=0}s(j7,"listCacheClear"),c(j7,"listCacheClear");function q7(d){var y=this.__data__,O=Xh(y,d);if(O<0)return!1;var V=y.length-1;return O==V?y.pop():gm.call(y,O,1),--this.size,!0}s(q7,"listCacheDelete"),c(q7,"listCacheDelete");function H7(d){var y=this.__data__,O=Xh(y,d);return O<0?r:y[O][1]}s(H7,"listCacheGet"),c(H7,"listCacheGet");function z7(d){return Xh(this.__data__,d)>-1}s(z7,"listCacheHas"),c(z7,"listCacheHas");function $7(d,y){var O=this.__data__,V=Xh(O,d);return V<0?(++this.size,O.push([d,y])):O[V][1]=y,this}s($7,"listCacheSet"),c($7,"listCacheSet"),ra.prototype.clear=j7,ra.prototype.delete=q7,ra.prototype.get=H7,ra.prototype.has=z7,ra.prototype.set=$7;function na(d){var y=-1,O=d==null?0:d.length;for(this.clear();++y<O;){var V=d[y];this.set(V[0],V[1])}}s(na,"MapCache"),c(na,"MapCache");function G7(){this.size=0,this.__data__={hash:new Yc,map:new(Vh||ra),string:new Yc}}s(G7,"mapCacheClear"),c(G7,"mapCacheClear");function K7(d){var y=l0(this,d).delete(d);return this.size-=y?1:0,y}s(K7,"mapCacheDelete"),c(K7,"mapCacheDelete");function V7(d){return l0(this,d).get(d)}s(V7,"mapCacheGet"),c(V7,"mapCacheGet");function W7(d){return l0(this,d).has(d)}s(W7,"mapCacheHas"),c(W7,"mapCacheHas");function J7(d,y){var O=l0(this,d),V=O.size;return O.set(d,y),this.size+=O.size==V?0:1,this}s(J7,"mapCacheSet"),c(J7,"mapCacheSet"),na.prototype.clear=G7,na.prototype.delete=K7,na.prototype.get=V7,na.prototype.has=W7,na.prototype.set=J7;function Zc(d){var y=-1,O=d==null?0:d.length;for(this.__data__=new na;++y<O;)this.add(d[y])}s(Zc,"SetCache"),c(Zc,"SetCache");function Y7(d){return this.__data__.set(d,l),this}s(Y7,"setCacheAdd"),c(Y7,"setCacheAdd");function Z7(d){return this.__data__.has(d)}s(Z7,"setCacheHas"),c(Z7,"setCacheHas"),Zc.prototype.add=Zc.prototype.push=Y7,Zc.prototype.has=Z7;function Vs(d){var y=this.__data__=new ra(d);this.size=y.size}s(Vs,"Stack"),c(Vs,"Stack");function X7(){this.__data__=new ra,this.size=0}s(X7,"stackClear"),c(X7,"stackClear");function Q7(d){var y=this.__data__,O=y.delete(d);return this.size=y.size,O}s(Q7,"stackDelete"),c(Q7,"stackDelete");function e9(d){return this.__data__.get(d)}s(e9,"stackGet"),c(e9,"stackGet");function t9(d){return this.__data__.has(d)}s(t9,"stackHas"),c(t9,"stackHas");function r9(d,y){var O=this.__data__;if(O instanceof ra){var V=O.__data__;if(!Vh||V.length<i-1)return V.push([d,y]),this.size=++O.size,this;O=this.__data__=new na(V)}return O.set(d,y),this.size=O.size,this}s(r9,"stackSet"),c(r9,"stackSet"),Vs.prototype.clear=X7,Vs.prototype.delete=Q7,Vs.prototype.get=e9,Vs.prototype.has=t9,Vs.prototype.set=r9;function p6(d,y){var O=Wt(d),V=!O&&gl(d),ie=!O&&!V&&nf(d),de=!O&&!V&&!ie&&Fu(d),Ae=O||V||ie||de,Ce=Ae?om(d.length,tq):[],Be=Ce.length;for(var Ge in d)(y||Or.call(d,Ge))&&!(Ae&&(Ge=="length"||ie&&(Ge=="offset"||Ge=="parent")||de&&(Ge=="buffer"||Ge=="byteLength"||Ge=="byteOffset")||aa(Ge,Be)))&&Ce.push(Ge);return Ce}s(p6,"arrayLikeKeys"),c(p6,"arrayLikeKeys");function m6(d){var y=d.length;return y?d[Rm(0,y-1)]:r}s(m6,"arraySample"),c(m6,"arraySample");function n9(d,y){return d0(Oi(d),Xc(y,0,d.length))}s(n9,"arraySampleSize"),c(n9,"arraySampleSize");function i9(d){return d0(Oi(d))}s(i9,"arrayShuffle"),c(i9,"arrayShuffle");function _m(d,y,O){(O!==r&&!Ws(d[y],O)||O===r&&!(y in d))&&ia(d,y,O)}s(_m,"assignMergeValue"),c(_m,"assignMergeValue");function ku(d,y,O){var V=d[y];(!(Or.call(d,y)&&Ws(V,O))||O===r&&!(y in d))&&ia(d,y,O)}s(ku,"assignValue"),c(ku,"assignValue");function Xh(d,y){for(var O=d.length;O--;)if(Ws(d[O][0],y))return O;return-1}s(Xh,"assocIndexOf"),c(Xh,"assocIndexOf");function s9(d,y,O,V){return Qc(d,function(ie,de,Ae){y(V,ie,O(ie),Ae)}),V}s(s9,"baseAggregator"),c(s9,"baseAggregator");function g6(d,y){return d&&xo(y,Nn(y),d)}s(g6,"baseAssign"),c(g6,"baseAssign");function o9(d,y){return d&&xo(y,Ni(y),d)}s(o9,"baseAssignIn"),c(o9,"baseAssignIn");function ia(d,y,O){y=="__proto__"&&bm?bm(d,y,{configurable:!0,enumerable:!0,value:O,writable:!0}):d[y]=O}s(ia,"baseAssignValue"),c(ia,"baseAssignValue");function Am(d,y){for(var O=-1,V=y.length,ie=Le(V),de=d==null;++O<V;)ie[O]=de?r:Xm(d,y[O]);return ie}s(Am,"baseAt"),c(Am,"baseAt");function Xc(d,y,O){return d===d&&(O!==r&&(d=d<=O?d:O),y!==r&&(d=d>=y?d:y)),d}s(Xc,"baseClamp"),c(Xc,"baseClamp");function _s(d,y,O,V,ie,de){var Ae,Ce=y&g,Be=y&x,Ge=y&_;if(O&&(Ae=ie?O(d,V,ie,de):O(d)),Ae!==r)return Ae;if(!rn(d))return d;var Ke=Wt(d);if(Ke){if(Ae=Y9(d),!Ce)return Oi(d,Ae)}else{var We=xi(d),mt=We==oe||We==ue;if(nf(d))return N6(d,Ce);if(We==j||We==M||mt&&!ie){if(Ae=Be||mt?{}:ny(d),!Ce)return Be?U9(d,o9(Ae,d)):L9(d,g6(Ae,d))}else{if(!Pr[We])return ie?d:{};Ae=Z9(d,We,Ce)}}de||(de=new Vs);var Ct=de.get(d);if(Ct)return Ct;de.set(d,Ae),VA(d)?d.forEach(function(Ft){Ae.add(_s(Ft,y,O,Ft,d,de))}):UA(d)&&d.forEach(function(Ft,lr){Ae.set(lr,_s(Ft,y,O,lr,d,de))});var Lt=Ge?Be?Hm:qm:Be?Ni:Nn,rr=Ke?r:Lt(d);return xs(rr||d,function(Ft,lr){rr&&(lr=Ft,Ft=d[lr]),ku(Ae,lr,_s(Ft,y,O,lr,d,de))}),Ae}s(_s,"baseClone"),c(_s,"baseClone");function a9(d){var y=Nn(d);return function(O){return b6(O,d,y)}}s(a9,"baseConforms"),c(a9,"baseConforms");function b6(d,y,O){var V=O.length;if(d==null)return!V;for(d=Hr(d);V--;){var ie=O[V],de=y[ie],Ae=d[ie];if(Ae===r&&!(ie in d)||!de(Ae))return!1}return!0}s(b6,"baseConformsTo"),c(b6,"baseConformsTo");function v6(d,y,O){if(typeof d!="function")throw new Ks(a);return u0(function(){d.apply(r,O)},y)}s(v6,"baseDelay"),c(v6,"baseDelay");function Tu(d,y,O,V){var ie=-1,de=zh,Ae=!0,Ce=d.length,Be=[],Ge=y.length;if(!Ce)return Be;O&&(y=Xr(y,es(O))),V?(de=em,Ae=!1):y.length>=i&&(de=Au,Ae=!1,y=new Zc(y));e:for(;++ie<Ce;){var Ke=d[ie],We=O==null?Ke:O(Ke);if(Ke=V||Ke!==0?Ke:0,Ae&&We===We){for(var mt=Ge;mt--;)if(y[mt]===We)continue e;Be.push(Ke)}else de(y,We,V)||Be.push(Ke)}return Be}s(Tu,"baseDifference"),c(Tu,"baseDifference");var Qc=H6(yo),c9=H6(Em,!0);function f9(d,y){var O=!0;return Qc(d,function(V,ie,de){return O=!!y(V,ie,de),O}),O}s(f9,"baseEvery"),c(f9,"baseEvery");function Qh(d,y,O){for(var V=-1,ie=d.length;++V<ie;){var de=d[V],Ae=y(de);if(Ae!=null&&(Ce===r?Ae===Ae&&!rs(Ae):O(Ae,Ce)))var Ce=Ae,Be=de}return Be}s(Qh,"baseExtremum"),c(Qh,"baseExtremum");function l9(d,y,O,V){var ie=d.length;for(O=Zt(O),O<0&&(O=-O>ie?0:ie+O),V=V===r||V>ie?ie:Zt(V),V<0&&(V+=ie),V=O>V?0:By(V);O<V;)d[O++]=y;return d}s(l9,"baseFill"),c(l9,"baseFill");function y6(d,y){var O=[];return Qc(d,function(V,ie,de){y(V,ie,de)&&O.push(V)}),O}s(y6,"baseFilter"),c(y6,"baseFilter");function $n(d,y,O,V,ie){var de=-1,Ae=d.length;for(O||(O=Q9),ie||(ie=[]);++de<Ae;){var Ce=d[de];y>0&&O(Ce)?y>1?$n(Ce,y-1,O,V,ie):rc(ie,Ce):V||(ie[ie.length]=Ce)}return ie}s($n,"baseFlatten"),c($n,"baseFlatten");var x6=z6(),u9=z6(!0);function yo(d,y){return d&&x6(d,y,Nn)}s(yo,"baseForOwn"),c(yo,"baseForOwn");function Em(d,y){return d&&u9(d,y,Nn)}s(Em,"baseForOwnRight"),c(Em,"baseForOwnRight");function e0(d,y){return tc(y,function(O){return ca(d[O])})}s(e0,"baseFunctions"),c(e0,"baseFunctions");function ef(d,y){y=sc(y,d);for(var O=0,V=y.length;d!=null&&O<V;)d=d[wo(y[O++])];return O&&O==V?d:r}s(ef,"baseGet"),c(ef,"baseGet");function w6(d,y,O){var V=y(d);return Wt(d)?V:rc(V,O(d))}s(w6,"baseGetAllKeys"),c(w6,"baseGetAllKeys");function yi(d){return d==null?d===r?Se:Q:dl&&dl in Hr(d)?K9(d):s_(d)}s(yi,"baseGetTag"),c(yi,"baseGetTag");function Cm(d,y){return d>y}s(Cm,"baseGt"),c(Cm,"baseGt");function d9(d,y){return d!=null&&Or.call(d,y)}s(d9,"baseHas"),c(d9,"baseHas");function h9(d,y){return d!=null&&y in Hr(d)}s(h9,"baseHasIn"),c(h9,"baseHasIn");function p9(d,y,O){return d>=vi(y,O)&&d<Fn(y,O)}s(p9,"baseInRange"),c(p9,"baseInRange");function Sm(d,y,O){for(var V=O?em:zh,ie=d[0].length,de=d.length,Ae=de,Ce=Le(de),Be=1/0,Ge=[];Ae--;){var Ke=d[Ae];Ae&&y&&(Ke=Xr(Ke,es(y))),Be=vi(Ke.length,Be),Ce[Ae]=!O&&(y||ie>=120&&Ke.length>=120)?new Zc(Ae&&Ke):r}Ke=d[0];var We=-1,mt=Ce[0];e:for(;++We<ie&&Ge.length<Be;){var Ct=Ke[We],Lt=y?y(Ct):Ct;if(Ct=O||Ct!==0?Ct:0,!(mt?Au(mt,Lt):V(Ge,Lt,O))){for(Ae=de;--Ae;){var rr=Ce[Ae];if(!(rr?Au(rr,Lt):V(d[Ae],Lt,O)))continue e}mt&&mt.push(Lt),Ge.push(Ct)}}return Ge}s(Sm,"baseIntersection"),c(Sm,"baseIntersection");function m9(d,y,O,V){return yo(d,function(ie,de,Ae){y(V,O(ie),de,Ae)}),V}s(m9,"baseInverter"),c(m9,"baseInverter");function Mu(d,y,O){y=sc(y,d),d=ay(d,y);var V=d==null?d:d[wo(Es(y))];return V==null?r:Qi(V,d,O)}s(Mu,"baseInvoke"),c(Mu,"baseInvoke");function _6(d){return on(d)&&yi(d)==M}s(_6,"baseIsArguments"),c(_6,"baseIsArguments");function g9(d){return on(d)&&yi(d)==Ne}s(g9,"baseIsArrayBuffer"),c(g9,"baseIsArrayBuffer");function b9(d){return on(d)&&yi(d)==Z}s(b9,"baseIsDate"),c(b9,"baseIsDate");function Ru(d,y,O,V,ie){return d===y?!0:d==null||y==null||!on(d)&&!on(y)?d!==d&&y!==y:v9(d,y,O,V,Ru,ie)}s(Ru,"baseIsEqual"),c(Ru,"baseIsEqual");function v9(d,y,O,V,ie,de){var Ae=Wt(d),Ce=Wt(y),Be=Ae?te:xi(d),Ge=Ce?te:xi(y);Be=Be==M?j:Be,Ge=Ge==M?j:Ge;var Ke=Be==j,We=Ge==j,mt=Be==Ge;if(mt&&nf(d)){if(!nf(y))return!1;Ae=!0,Ke=!1}if(mt&&!Ke)return de||(de=new Vs),Ae||Fu(d)?Q6(d,y,O,V,ie,de):$9(d,y,Be,O,V,ie,de);if(!(O&E)){var Ct=Ke&&Or.call(d,"__wrapped__"),Lt=We&&Or.call(y,"__wrapped__");if(Ct||Lt){var rr=Ct?d.value():d,Ft=Lt?y.value():y;return de||(de=new Vs),ie(rr,Ft,O,V,de)}}return mt?(de||(de=new Vs),G9(d,y,O,V,ie,de)):!1}s(v9,"baseIsEqualDeep"),c(v9,"baseIsEqualDeep");function y9(d){return on(d)&&xi(d)==me}s(y9,"baseIsMap"),c(y9,"baseIsMap");function Im(d,y,O,V){var ie=O.length,de=ie,Ae=!V;if(d==null)return!de;for(d=Hr(d);ie--;){var Ce=O[ie];if(Ae&&Ce[2]?Ce[1]!==d[Ce[0]]:!(Ce[0]in d))return!1}for(;++ie<de;){Ce=O[ie];var Be=Ce[0],Ge=d[Be],Ke=Ce[1];if(Ae&&Ce[2]){if(Ge===r&&!(Be in d))return!1}else{var We=new Vs;if(V)var mt=V(Ge,Ke,Be,d,y,We);if(!(mt===r?Ru(Ke,Ge,E|T,V,We):mt))return!1}}return!0}s(Im,"baseIsMatch"),c(Im,"baseIsMatch");function A6(d){if(!rn(d)||t_(d))return!1;var y=ca(d)?oq:Vt;return y.test(rf(d))}s(A6,"baseIsNative"),c(A6,"baseIsNative");function x9(d){return on(d)&&yi(d)==se}s(x9,"baseIsRegExp"),c(x9,"baseIsRegExp");function w9(d){return on(d)&&xi(d)==ee}s(w9,"baseIsSet"),c(w9,"baseIsSet");function _9(d){return on(d)&&b0(d.length)&&!!Ur[yi(d)]}s(_9,"baseIsTypedArray"),c(_9,"baseIsTypedArray");function E6(d){return typeof d=="function"?d:d==null?Li:typeof d=="object"?Wt(d)?I6(d[0],d[1]):S6(d):Uy(d)}s(E6,"baseIteratee"),c(E6,"baseIteratee");function km(d){if(!Pu(d))return dq(d);var y=[];for(var O in Hr(d))Or.call(d,O)&&O!="constructor"&&y.push(O);return y}s(km,"baseKeys"),c(km,"baseKeys");function A9(d){if(!rn(d))return i_(d);var y=Pu(d),O=[];for(var V in d)V=="constructor"&&(y||!Or.call(d,V))||O.push(V);return O}s(A9,"baseKeysIn"),c(A9,"baseKeysIn");function Tm(d,y){return d<y}s(Tm,"baseLt"),c(Tm,"baseLt");function C6(d,y){var O=-1,V=Fi(d)?Le(d.length):[];return Qc(d,function(ie,de,Ae){V[++O]=y(ie,de,Ae)}),V}s(C6,"baseMap"),c(C6,"baseMap");function S6(d){var y=zm(d);return y.length==1&&y[0][2]?sy(y[0][0],y[0][1]):function(O){return O===d||Im(O,d,y)}}s(S6,"baseMatches"),c(S6,"baseMatches");function I6(d,y){return $m(d)&&iy(y)?sy(wo(d),y):function(O){var V=Xm(O,d);return V===r&&V===y?Qm(O,d):Ru(y,V,E|T)}}s(I6,"baseMatchesProperty"),c(I6,"baseMatchesProperty");function t0(d,y,O,V,ie){d!==y&&x6(y,function(de,Ae){if(ie||(ie=new Vs),rn(de))E9(d,y,Ae,O,t0,V,ie);else{var Ce=V?V(Km(d,Ae),de,Ae+"",d,y,ie):r;Ce===r&&(Ce=de),_m(d,Ae,Ce)}},Ni)}s(t0,"baseMerge"),c(t0,"baseMerge");function E9(d,y,O,V,ie,de,Ae){var Ce=Km(d,O),Be=Km(y,O),Ge=Ae.get(Be);if(Ge){_m(d,O,Ge);return}var Ke=de?de(Ce,Be,O+"",d,y,Ae):r,We=Ke===r;if(We){var mt=Wt(Be),Ct=!mt&&nf(Be),Lt=!mt&&!Ct&&Fu(Be);Ke=Be,mt||Ct||Lt?Wt(Ce)?Ke=Ce:mn(Ce)?Ke=Oi(Ce):Ct?(We=!1,Ke=N6(Be,!0)):Lt?(We=!1,Ke=L6(Be,!0)):Ke=[]:Ou(Be)||gl(Be)?(Ke=Ce,gl(Ce)?Ke=Dy(Ce):(!rn(Ce)||ca(Ce))&&(Ke=ny(Be))):We=!1}We&&(Ae.set(Be,Ke),ie(Ke,Be,V,de,Ae),Ae.delete(Be)),_m(d,O,Ke)}s(E9,"baseMergeDeep"),c(E9,"baseMergeDeep");function k6(d,y){var O=d.length;if(!!O)return y+=y<0?O:0,aa(y,O)?d[y]:r}s(k6,"baseNth"),c(k6,"baseNth");function T6(d,y,O){y.length?y=Xr(y,function(de){return Wt(de)?function(Ae){return ef(Ae,de.length===1?de[0]:de)}:de}):y=[Li];var V=-1;y=Xr(y,es(Ot()));var ie=C6(d,function(de,Ae,Ce){var Be=Xr(y,function(Ge){return Ge(de)});return{criteria:Be,index:++V,value:de}});return u7(ie,function(de,Ae){return N9(de,Ae,O)})}s(T6,"baseOrderBy"),c(T6,"baseOrderBy");function C9(d,y){return M6(d,y,function(O,V){return Qm(d,V)})}s(C9,"basePick"),c(C9,"basePick");function M6(d,y,O){for(var V=-1,ie=y.length,de={};++V<ie;){var Ae=y[V],Ce=ef(d,Ae);O(Ce,Ae)&&Bu(de,sc(Ae,d),Ce)}return de}s(M6,"basePickBy"),c(M6,"basePickBy");function S9(d){return function(y){return ef(y,d)}}s(S9,"basePropertyDeep"),c(S9,"basePropertyDeep");function Mm(d,y,O,V){var ie=V?l7:fl,de=-1,Ae=y.length,Ce=d;for(d===y&&(y=Oi(y)),O&&(Ce=Xr(d,es(O)));++de<Ae;)for(var Be=0,Ge=y[de],Ke=O?O(Ge):Ge;(Be=ie(Ce,Ke,Be,V))>-1;)Ce!==d&&gm.call(Ce,Be,1),gm.call(d,Be,1);return d}s(Mm,"basePullAll"),c(Mm,"basePullAll");function R6(d,y){for(var O=d?y.length:0,V=O-1;O--;){var ie=y[O];if(O==V||ie!==de){var de=ie;aa(ie)?gm.call(d,ie,1):Pm(d,ie)}}return d}s(R6,"basePullAt"),c(R6,"basePullAt");function Rm(d,y){return d+ym(M7()*(y-d+1))}s(Rm,"baseRandom"),c(Rm,"baseRandom");function I9(d,y,O,V){for(var ie=-1,de=Fn(vm((y-d)/(O||1)),0),Ae=Le(de);de--;)Ae[V?de:++ie]=d,d+=O;return Ae}s(I9,"baseRange"),c(I9,"baseRange");function Bm(d,y){var O="";if(!d||y<1||y>C)return O;do y%2&&(O+=d),y=ym(y/2),y&&(d+=d);while(y);return O}s(Bm,"baseRepeat"),c(Bm,"baseRepeat");function ir(d,y){return cy(oy(d,y,Li),d+"")}s(ir,"baseRest"),c(ir,"baseRest");function k9(d){return m6(bl(d))}s(k9,"baseSample"),c(k9,"baseSample");function T9(d,y){var O=bl(d);return d0(O,Xc(y,0,O.length))}s(T9,"baseSampleSize"),c(T9,"baseSampleSize");function Bu(d,y,O,V){if(!rn(d))return d;y=sc(y,d);for(var ie=-1,de=y.length,Ae=de-1,Ce=d;Ce!=null&&++ie<de;){var Be=wo(y[ie]),Ge=O;if(Be==="__proto__"||Be==="constructor"||Be==="prototype")return d;if(ie!=Ae){var Ke=Ce[Be];Ge=V?V(Ke,Be,Ce):r,Ge===r&&(Ge=rn(Ke)?Ke:aa(y[ie+1])?[]:{})}ku(Ce,Be,Ge),Ce=Ce[Be]}return d}s(Bu,"baseSet"),c(Bu,"baseSet");var M9=xm?function(d,y){return xm.set(d,y),d}:Li,wq=bm?function(d,y){return bm(d,"toString",{configurable:!0,enumerable:!1,value:eg(y),writable:!0})}:Li;function R9(d){return d0(bl(d))}s(R9,"baseShuffle"),c(R9,"baseShuffle");function As(d,y,O){var V=-1,ie=d.length;y<0&&(y=-y>ie?0:ie+y),O=O>ie?ie:O,O<0&&(O+=ie),ie=y>O?0:O-y>>>0,y>>>=0;for(var de=Le(ie);++V<ie;)de[V]=d[V+y];return de}s(As,"baseSlice"),c(As,"baseSlice");function B9(d,y){var O;return Qc(d,function(V,ie,de){return O=y(V,ie,de),!O}),!!O}s(B9,"baseSome"),c(B9,"baseSome");function r0(d,y,O){var V=0,ie=d==null?V:d.length;if(typeof y=="number"&&y===y&&ie<=R){for(;V<ie;){var de=V+ie>>>1,Ae=d[de];Ae!==null&&!rs(Ae)&&(O?Ae<=y:Ae<y)?V=de+1:ie=de}return ie}return Dm(d,y,Li,O)}s(r0,"baseSortedIndex"),c(r0,"baseSortedIndex");function Dm(d,y,O,V){var ie=0,de=d==null?0:d.length;if(de===0)return 0;y=O(y);for(var Ae=y!==y,Ce=y===null,Be=rs(y),Ge=y===r;ie<de;){var Ke=ym((ie+de)/2),We=O(d[Ke]),mt=We!==r,Ct=We===null,Lt=We===We,rr=rs(We);if(Ae)var Ft=V||Lt;else Ge?Ft=Lt&&(V||mt):Ce?Ft=Lt&&mt&&(V||!Ct):Be?Ft=Lt&&mt&&!Ct&&(V||!rr):Ct||rr?Ft=!1:Ft=V?We<=y:We<y;Ft?ie=Ke+1:de=Ke}return vi(de,A)}s(Dm,"baseSortedIndexBy"),c(Dm,"baseSortedIndexBy");function B6(d,y){for(var O=-1,V=d.length,ie=0,de=[];++O<V;){var Ae=d[O],Ce=y?y(Ae):Ae;if(!O||!Ws(Ce,Be)){var Be=Ce;de[ie++]=Ae===0?0:Ae}}return de}s(B6,"baseSortedUniq"),c(B6,"baseSortedUniq");function D6(d){return typeof d=="number"?d:rs(d)?k:+d}s(D6,"baseToNumber"),c(D6,"baseToNumber");function ts(d){if(typeof d=="string")return d;if(Wt(d))return Xr(d,ts)+"";if(rs(d))return R7?R7.call(d):"";var y=d+"";return y=="0"&&1/d==-v?"-0":y}s(ts,"baseToString"),c(ts,"baseToString");function ic(d,y,O){var V=-1,ie=zh,de=d.length,Ae=!0,Ce=[],Be=Ce;if(O)Ae=!1,ie=em;else if(de>=i){var Ge=y?null:Aq(d);if(Ge)return Gh(Ge);Ae=!1,ie=Au,Be=new Zc}else Be=y?[]:Ce;e:for(;++V<de;){var Ke=d[V],We=y?y(Ke):Ke;if(Ke=O||Ke!==0?Ke:0,Ae&&We===We){for(var mt=Be.length;mt--;)if(Be[mt]===We)continue e;y&&Be.push(We),Ce.push(Ke)}else ie(Be,We,O)||(Be!==Ce&&Be.push(We),Ce.push(Ke))}return Ce}s(ic,"baseUniq"),c(ic,"baseUniq");function Pm(d,y){return y=sc(y,d),d=ay(d,y),d==null||delete d[wo(Es(y))]}s(Pm,"baseUnset"),c(Pm,"baseUnset");function P6(d,y,O,V){return Bu(d,y,O(ef(d,y)),V)}s(P6,"baseUpdate"),c(P6,"baseUpdate");function n0(d,y,O,V){for(var ie=d.length,de=V?ie:-1;(V?de--:++de<ie)&&y(d[de],de,d););return O?As(d,V?0:de,V?de+1:ie):As(d,V?de+1:0,V?ie:de)}s(n0,"baseWhile"),c(n0,"baseWhile");function O6(d,y){var O=d;return O instanceof hr&&(O=O.value()),tm(y,function(V,ie){return ie.func.apply(ie.thisArg,rc([V],ie.args))},O)}s(O6,"baseWrapperValue"),c(O6,"baseWrapperValue");function Om(d,y,O){var V=d.length;if(V<2)return V?ic(d[0]):[];for(var ie=-1,de=Le(V);++ie<V;)for(var Ae=d[ie],Ce=-1;++Ce<V;)Ce!=ie&&(de[ie]=Tu(de[ie]||Ae,d[Ce],y,O));return ic($n(de,1),y,O)}s(Om,"baseXor"),c(Om,"baseXor");function F6(d,y,O){for(var V=-1,ie=d.length,de=y.length,Ae={};++V<ie;){var Ce=V<de?y[V]:r;O(Ae,d[V],Ce)}return Ae}s(F6,"baseZipObject"),c(F6,"baseZipObject");function Fm(d){return mn(d)?d:[]}s(Fm,"castArrayLikeObject"),c(Fm,"castArrayLikeObject");function Nm(d){return typeof d=="function"?d:Li}s(Nm,"castFunction"),c(Nm,"castFunction");function sc(d,y){return Wt(d)?d:$m(d,y)?[d]:c_(Tr(d))}s(sc,"castPath"),c(sc,"castPath");var _q=ir;function oc(d,y,O){var V=d.length;return O=O===r?V:O,!y&&O>=V?d:As(d,y,O)}s(oc,"castSlice"),c(oc,"castSlice");var D9=aq||function(d){return wn.clearTimeout(d)};function N6(d,y){if(y)return d.slice();var O=d.length,V=C7?C7(O):new d.constructor(O);return d.copy(V),V}s(N6,"cloneBuffer"),c(N6,"cloneBuffer");function Lm(d){var y=new d.constructor(d.byteLength);return new pm(y).set(new pm(d)),y}s(Lm,"cloneArrayBuffer"),c(Lm,"cloneArrayBuffer");function P9(d,y){var O=y?Lm(d.buffer):d.buffer;return new d.constructor(O,d.byteOffset,d.byteLength)}s(P9,"cloneDataView"),c(P9,"cloneDataView");function O9(d){var y=new d.constructor(d.source,rt.exec(d));return y.lastIndex=d.lastIndex,y}s(O9,"cloneRegExp"),c(O9,"cloneRegExp");function F9(d){return Yh?Hr(Yh.call(d)):{}}s(F9,"cloneSymbol"),c(F9,"cloneSymbol");function L6(d,y){var O=y?Lm(d.buffer):d.buffer;return new d.constructor(O,d.byteOffset,d.length)}s(L6,"cloneTypedArray"),c(L6,"cloneTypedArray");function U6(d,y){if(d!==y){var O=d!==r,V=d===null,ie=d===d,de=rs(d),Ae=y!==r,Ce=y===null,Be=y===y,Ge=rs(y);if(!Ce&&!Ge&&!de&&d>y||de&&Ae&&Be&&!Ce&&!Ge||V&&Ae&&Be||!O&&Be||!ie)return 1;if(!V&&!de&&!Ge&&d<y||Ge&&O&&ie&&!V&&!de||Ce&&O&&ie||!Ae&&ie||!Be)return-1}return 0}s(U6,"compareAscending"),c(U6,"compareAscending");function N9(d,y,O){for(var V=-1,ie=d.criteria,de=y.criteria,Ae=ie.length,Ce=O.length;++V<Ae;){var Be=U6(ie[V],de[V]);if(Be){if(V>=Ce)return Be;var Ge=O[V];return Be*(Ge=="desc"?-1:1)}}return d.index-y.index}s(N9,"compareMultiple"),c(N9,"compareMultiple");function j6(d,y,O,V){for(var ie=-1,de=d.length,Ae=O.length,Ce=-1,Be=y.length,Ge=Fn(de-Ae,0),Ke=Le(Be+Ge),We=!V;++Ce<Be;)Ke[Ce]=y[Ce];for(;++ie<Ae;)(We||ie<de)&&(Ke[O[ie]]=d[ie]);for(;Ge--;)Ke[Ce++]=d[ie++];return Ke}s(j6,"composeArgs"),c(j6,"composeArgs");function q6(d,y,O,V){for(var ie=-1,de=d.length,Ae=-1,Ce=O.length,Be=-1,Ge=y.length,Ke=Fn(de-Ce,0),We=Le(Ke+Ge),mt=!V;++ie<Ke;)We[ie]=d[ie];for(var Ct=ie;++Be<Ge;)We[Ct+Be]=y[Be];for(;++Ae<Ce;)(mt||ie<de)&&(We[Ct+O[Ae]]=d[ie++]);return We}s(q6,"composeArgsRight"),c(q6,"composeArgsRight");function Oi(d,y){var O=-1,V=d.length;for(y||(y=Le(V));++O<V;)y[O]=d[O];return y}s(Oi,"copyArray"),c(Oi,"copyArray");function xo(d,y,O,V){var ie=!O;O||(O={});for(var de=-1,Ae=y.length;++de<Ae;){var Ce=y[de],Be=V?V(O[Ce],d[Ce],Ce,O,d):r;Be===r&&(Be=d[Ce]),ie?ia(O,Ce,Be):ku(O,Ce,Be)}return O}s(xo,"copyObject"),c(xo,"copyObject");function L9(d,y){return xo(d,ty(d),y)}s(L9,"copySymbols"),c(L9,"copySymbols");function U9(d,y){return xo(d,V9(d),y)}s(U9,"copySymbolsIn"),c(U9,"copySymbolsIn");function i0(d,y){return function(O,V){var ie=Wt(O)?s7:s9,de=y?y():{};return ie(O,d,Ot(V,2),de)}}s(i0,"createAggregator"),c(i0,"createAggregator");function hl(d){return ir(function(y,O){var V=-1,ie=O.length,de=ie>1?O[ie-1]:r,Ae=ie>2?O[2]:r;for(de=d.length>3&&typeof de=="function"?(ie--,de):r,Ae&&wi(O[0],O[1],Ae)&&(de=ie<3?r:de,ie=1),y=Hr(y);++V<ie;){var Ce=O[V];Ce&&d(y,Ce,V,de)}return y})}s(hl,"createAssigner"),c(hl,"createAssigner");function H6(d,y){return function(O,V){if(O==null)return O;if(!Fi(O))return d(O,V);for(var ie=O.length,de=y?ie:-1,Ae=Hr(O);(y?de--:++de<ie)&&V(Ae[de],de,Ae)!==!1;);return O}}s(H6,"createBaseEach"),c(H6,"createBaseEach");function z6(d){return function(y,O,V){for(var ie=-1,de=Hr(y),Ae=V(y),Ce=Ae.length;Ce--;){var Be=Ae[d?Ce:++ie];if(O(de[Be],Be,de)===!1)break}return y}}s(z6,"createBaseFor"),c(z6,"createBaseFor");function j9(d,y,O){var V=y&B,ie=Du(d);function de(){var Ae=this&&this!==wn&&this instanceof de?ie:d;return Ae.apply(V?O:this,arguments)}return s(de,"wrapper"),c(de,"wrapper"),de}s(j9,"createBind"),c(j9,"createBind");function $6(d){return function(y){y=Tr(y);var O=ll(y)?Gs(y):r,V=O?O[0]:y.charAt(0),ie=O?oc(O,1).join(""):y.slice(1);return V[d]()+ie}}s($6,"createCaseFirst"),c($6,"createCaseFirst");function pl(d){return function(y){return tm(Ly(Fy(y).replace(Uh,"")),d,"")}}s(pl,"createCompounder"),c(pl,"createCompounder");function Du(d){return function(){var y=arguments;switch(y.length){case 0:return new d;case 1:return new d(y[0]);case 2:return new d(y[0],y[1]);case 3:return new d(y[0],y[1],y[2]);case 4:return new d(y[0],y[1],y[2],y[3]);case 5:return new d(y[0],y[1],y[2],y[3],y[4]);case 6:return new d(y[0],y[1],y[2],y[3],y[4],y[5]);case 7:return new d(y[0],y[1],y[2],y[3],y[4],y[5],y[6])}var O=Iu(d.prototype),V=d.apply(O,y);return rn(V)?V:O}}s(Du,"createCtor"),c(Du,"createCtor");function q9(d,y,O){var V=Du(d);function ie(){for(var de=arguments.length,Ae=Le(de),Ce=de,Be=ml(ie);Ce--;)Ae[Ce]=arguments[Ce];var Ge=de<3&&Ae[0]!==Be&&Ae[de-1]!==Be?[]:nc(Ae,Be);if(de-=Ge.length,de<O)return J6(d,y,s0,ie.placeholder,r,Ae,Ge,r,r,O-de);var Ke=this&&this!==wn&&this instanceof ie?V:d;return Qi(Ke,this,Ae)}return s(ie,"wrapper"),c(ie,"wrapper"),ie}s(q9,"createCurry"),c(q9,"createCurry");function G6(d){return function(y,O,V){var ie=Hr(y);if(!Fi(y)){var de=Ot(O,3);y=Nn(y),O=c(function(Ce){return de(ie[Ce],Ce,ie)},"predicate")}var Ae=d(y,O,V);return Ae>-1?ie[de?y[Ae]:Ae]:r}}s(G6,"createFind"),c(G6,"createFind");function K6(d){return oa(function(y){var O=y.length,V=O,ie=ws.prototype.thru;for(d&&y.reverse();V--;){var de=y[V];if(typeof de!="function")throw new Ks(a);if(ie&&!Ae&&f0(de)=="wrapper")var Ae=new ws([],!0)}for(V=Ae?V:O;++V<O;){de=y[V];var Ce=f0(de),Be=Ce=="wrapper"?ey(de):r;Be&&Gm(Be[0])&&Be[1]==(N|U|K|G)&&!Be[4].length&&Be[9]==1?Ae=Ae[f0(Be[0])].apply(Ae,Be[3]):Ae=de.length==1&&Gm(de)?Ae[Ce]():Ae.thru(de)}return function(){var Ge=arguments,Ke=Ge[0];if(Ae&&Ge.length==1&&Wt(Ke))return Ae.plant(Ke).value();for(var We=0,mt=O?y[We].apply(this,Ge):Ke;++We<O;)mt=y[We].call(this,mt);return mt}})}s(K6,"createFlow"),c(K6,"createFlow");function s0(d,y,O,V,ie,de,Ae,Ce,Be,Ge){var Ke=y&N,We=y&B,mt=y&F,Ct=y&(U|q),Lt=y&ce,rr=mt?r:Du(d);function Ft(){for(var lr=arguments.length,gr=Le(lr),ns=lr;ns--;)gr[ns]=arguments[ns];if(Ct)var _i=ml(Ft),is=h7(gr,_i);if(V&&(gr=j6(gr,V,ie,Ct)),de&&(gr=q6(gr,de,Ae,Ct)),lr-=is,Ct&&lr<Ge){var _n=nc(gr,_i);return J6(d,y,s0,Ft.placeholder,O,gr,_n,Ce,Be,Ge-lr)}var _o=We?O:this,ac=mt?_o[d]:d;return lr=gr.length,Ce?gr=o_(gr,Ce):Lt&&lr>1&&gr.reverse(),Ke&&Be<lr&&(gr.length=Be),this&&this!==wn&&this instanceof Ft&&(ac=rr||Du(ac)),ac.apply(_o,gr)}return s(Ft,"wrapper"),c(Ft,"wrapper"),Ft}s(s0,"createHybrid"),c(s0,"createHybrid");function V6(d,y){return function(O,V){return m9(O,d,y(V),{})}}s(V6,"createInverter"),c(V6,"createInverter");function o0(d,y){return function(O,V){var ie;if(O===r&&V===r)return y;if(O!==r&&(ie=O),V!==r){if(ie===r)return V;typeof O=="string"||typeof V=="string"?(O=ts(O),V=ts(V)):(O=D6(O),V=D6(V)),ie=d(O,V)}return ie}}s(o0,"createMathOperation"),c(o0,"createMathOperation");function Um(d){return oa(function(y){return y=Xr(y,es(Ot())),ir(function(O){var V=this;return d(y,function(ie){return Qi(ie,V,O)})})})}s(Um,"createOver"),c(Um,"createOver");function a0(d,y){y=y===r?" ":ts(y);var O=y.length;if(O<2)return O?Bm(y,d):y;var V=Bm(y,vm(d/ul(y)));return ll(y)?oc(Gs(V),0,d).join(""):V.slice(0,d)}s(a0,"createPadding"),c(a0,"createPadding");function H9(d,y,O,V){var ie=y&B,de=Du(d);function Ae(){for(var Ce=-1,Be=arguments.length,Ge=-1,Ke=V.length,We=Le(Ke+Be),mt=this&&this!==wn&&this instanceof Ae?de:d;++Ge<Ke;)We[Ge]=V[Ge];for(;Be--;)We[Ge++]=arguments[++Ce];return Qi(mt,ie?O:this,We)}return s(Ae,"wrapper"),c(Ae,"wrapper"),Ae}s(H9,"createPartial"),c(H9,"createPartial");function W6(d){return function(y,O,V){return V&&typeof V!="number"&&wi(y,O,V)&&(O=V=r),y=fa(y),O===r?(O=y,y=0):O=fa(O),V=V===r?y<O?1:-1:fa(V),I9(y,O,V,d)}}s(W6,"createRange"),c(W6,"createRange");function c0(d){return function(y,O){return typeof y=="string"&&typeof O=="string"||(y=Cs(y),O=Cs(O)),d(y,O)}}s(c0,"createRelationalOperation"),c(c0,"createRelationalOperation");function J6(d,y,O,V,ie,de,Ae,Ce,Be,Ge){var Ke=y&U,We=Ke?Ae:r,mt=Ke?r:Ae,Ct=Ke?de:r,Lt=Ke?r:de;y|=Ke?K:W,y&=~(Ke?W:K),y&H||(y&=~(B|F));var rr=[d,y,ie,Ct,We,Lt,mt,Ce,Be,Ge],Ft=O.apply(r,rr);return Gm(d)&&a_(Ft,rr),Ft.placeholder=V,fy(Ft,d,y)}s(J6,"createRecurry"),c(J6,"createRecurry");function jm(d){var y=On[d];return function(O,V){if(O=Cs(O),V=V==null?0:vi(Zt(V),292),V&&T7(O)){var ie=(Tr(O)+"e").split("e"),de=y(ie[0]+"e"+(+ie[1]+V));return ie=(Tr(de)+"e").split("e"),+(ie[0]+"e"+(+ie[1]-V))}return y(O)}}s(jm,"createRound"),c(jm,"createRound");var Aq=Cu&&1/Gh(new Cu([,-0]))[1]==v?function(d){return new Cu(d)}:ng;function Y6(d){return function(y){var O=xi(y);return O==me?cm(y):O==ee?v7(y):d7(y,d(y))}}s(Y6,"createToPairs"),c(Y6,"createToPairs");function sa(d,y,O,V,ie,de,Ae,Ce){var Be=y&F;if(!Be&&typeof d!="function")throw new Ks(a);var Ge=V?V.length:0;if(Ge||(y&=~(K|W),V=ie=r),Ae=Ae===r?Ae:Fn(Zt(Ae),0),Ce=Ce===r?Ce:Zt(Ce),Ge-=ie?ie.length:0,y&W){var Ke=V,We=ie;V=ie=r}var mt=Be?r:ey(d),Ct=[d,y,O,V,ie,Ke,We,de,Ae,Ce];if(mt&&n_(Ct,mt),d=Ct[0],y=Ct[1],O=Ct[2],V=Ct[3],ie=Ct[4],Ce=Ct[9]=Ct[9]===r?Be?0:d.length:Fn(Ct[9]-Ge,0),!Ce&&y&(U|q)&&(y&=~(U|q)),!y||y==B)var Lt=j9(d,y,O);else y==U||y==q?Lt=q9(d,y,Ce):(y==K||y==(B|K))&&!ie.length?Lt=H9(d,y,O,V):Lt=s0.apply(r,Ct);var rr=mt?M9:a_;return fy(rr(Lt,Ct),d,y)}s(sa,"createWrap"),c(sa,"createWrap");function Z6(d,y,O,V){return d===r||Ws(d,Eu[O])&&!Or.call(V,O)?y:d}s(Z6,"customDefaultsAssignIn"),c(Z6,"customDefaultsAssignIn");function X6(d,y,O,V,ie,de){return rn(d)&&rn(y)&&(de.set(y,d),t0(d,y,r,X6,de),de.delete(y)),d}s(X6,"customDefaultsMerge"),c(X6,"customDefaultsMerge");function z9(d){return Ou(d)?r:d}s(z9,"customOmitClone"),c(z9,"customOmitClone");function Q6(d,y,O,V,ie,de){var Ae=O&E,Ce=d.length,Be=y.length;if(Ce!=Be&&!(Ae&&Be>Ce))return!1;var Ge=de.get(d),Ke=de.get(y);if(Ge&&Ke)return Ge==y&&Ke==d;var We=-1,mt=!0,Ct=O&T?new Zc:r;for(de.set(d,y),de.set(y,d);++We<Ce;){var Lt=d[We],rr=y[We];if(V)var Ft=Ae?V(rr,Lt,We,y,d,de):V(Lt,rr,We,d,y,de);if(Ft!==r){if(Ft)continue;mt=!1;break}if(Ct){if(!rm(y,function(lr,gr){if(!Au(Ct,gr)&&(Lt===lr||ie(Lt,lr,O,V,de)))return Ct.push(gr)})){mt=!1;break}}else if(!(Lt===rr||ie(Lt,rr,O,V,de))){mt=!1;break}}return de.delete(d),de.delete(y),mt}s(Q6,"equalArrays"),c(Q6,"equalArrays");function $9(d,y,O,V,ie,de,Ae){switch(O){case ye:if(d.byteLength!=y.byteLength||d.byteOffset!=y.byteOffset)return!1;d=d.buffer,y=y.buffer;case Ne:return!(d.byteLength!=y.byteLength||!de(new pm(d),new pm(y)));case Y:case Z:case ke:return Ws(+d,+y);case z:return d.name==y.name&&d.message==y.message;case se:case le:return d==y+"";case me:var Ce=cm;case ee:var Be=V&E;if(Ce||(Ce=Gh),d.size!=y.size&&!Be)return!1;var Ge=Ae.get(d);if(Ge)return Ge==y;V|=T,Ae.set(d,y);var Ke=Q6(Ce(d),Ce(y),V,ie,de,Ae);return Ae.delete(d),Ke;case be:if(Yh)return Yh.call(d)==Yh.call(y)}return!1}s($9,"equalByTag"),c($9,"equalByTag");function G9(d,y,O,V,ie,de){var Ae=O&E,Ce=qm(d),Be=Ce.length,Ge=qm(y),Ke=Ge.length;if(Be!=Ke&&!Ae)return!1;for(var We=Be;We--;){var mt=Ce[We];if(!(Ae?mt in y:Or.call(y,mt)))return!1}var Ct=de.get(d),Lt=de.get(y);if(Ct&&Lt)return Ct==y&&Lt==d;var rr=!0;de.set(d,y),de.set(y,d);for(var Ft=Ae;++We<Be;){mt=Ce[We];var lr=d[mt],gr=y[mt];if(V)var ns=Ae?V(gr,lr,mt,y,d,de):V(lr,gr,mt,d,y,de);if(!(ns===r?lr===gr||ie(lr,gr,O,V,de):ns)){rr=!1;break}Ft||(Ft=mt=="constructor")}if(rr&&!Ft){var _i=d.constructor,is=y.constructor;_i!=is&&"constructor"in d&&"constructor"in y&&!(typeof _i=="function"&&_i instanceof _i&&typeof is=="function"&&is instanceof is)&&(rr=!1)}return de.delete(d),de.delete(y),rr}s(G9,"equalObjects"),c(G9,"equalObjects");function oa(d){return cy(oy(d,r,py),d+"")}s(oa,"flatRest"),c(oa,"flatRest");function qm(d){return w6(d,Nn,ty)}s(qm,"getAllKeys"),c(qm,"getAllKeys");function Hm(d){return w6(d,Ni,V9)}s(Hm,"getAllKeysIn"),c(Hm,"getAllKeysIn");var ey=xm?function(d){return xm.get(d)}:ng;function f0(d){for(var y=d.name+"",O=Su[y],V=Or.call(Su,y)?O.length:0;V--;){var ie=O[V],de=ie.func;if(de==null||de==d)return ie.name}return y}s(f0,"getFuncName"),c(f0,"getFuncName");function ml(d){var y=Or.call(fe,"placeholder")?fe:d;return y.placeholder}s(ml,"getHolder"),c(ml,"getHolder");function Ot(){var d=fe.iteratee||tg;return d=d===tg?E6:d,arguments.length?d(arguments[0],arguments[1]):d}s(Ot,"getIteratee"),c(Ot,"getIteratee");function l0(d,y){var O=d.__data__;return e_(y)?O[typeof y=="string"?"string":"hash"]:O.map}s(l0,"getMapData"),c(l0,"getMapData");function zm(d){for(var y=Nn(d),O=y.length;O--;){var V=y[O],ie=d[V];y[O]=[V,ie,iy(ie)]}return y}s(zm,"getMatchData"),c(zm,"getMatchData");function tf(d,y){var O=m7(d,y);return A6(O)?O:r}s(tf,"getNative"),c(tf,"getNative");function K9(d){var y=Or.call(d,dl),O=d[dl];try{d[dl]=r;var V=!0}catch{}var ie=dm.call(d);return V&&(y?d[dl]=O:delete d[dl]),ie}s(K9,"getRawTag"),c(K9,"getRawTag");var ty=u6?function(d){return d==null?[]:(d=Hr(d),tc(u6(d),function(y){return I7.call(d,y)}))}:ig,V9=u6?function(d){for(var y=[];d;)rc(y,ty(d)),d=mm(d);return y}:ig,xi=yi;(d6&&xi(new d6(new ArrayBuffer(1)))!=ye||Vh&&xi(new Vh)!=me||h6&&xi(h6.resolve())!=$||Cu&&xi(new Cu)!=ee||Wh&&xi(new Wh)!=Te)&&(xi=c(function(d){var y=yi(d),O=y==j?d.constructor:r,V=O?rf(O):"";if(V)switch(V){case gq:return ye;case bq:return me;case vq:return $;case yq:return ee;case xq:return Te}return y},"getTag"));function W9(d,y,O){for(var V=-1,ie=O.length;++V<ie;){var de=O[V],Ae=de.size;switch(de.type){case"drop":d+=Ae;break;case"dropRight":y-=Ae;break;case"take":y=vi(y,d+Ae);break;case"takeRight":d=Fn(d,y-Ae);break}}return{start:d,end:y}}s(W9,"getView"),c(W9,"getView");function J9(d){var y=d.match(Je);return y?y[1].split(Bt):[]}s(J9,"getWrapDetails"),c(J9,"getWrapDetails");function ry(d,y,O){y=sc(y,d);for(var V=-1,ie=y.length,de=!1;++V<ie;){var Ae=wo(y[V]);if(!(de=d!=null&&O(d,Ae)))break;d=d[Ae]}return de||++V!=ie?de:(ie=d==null?0:d.length,!!ie&&b0(ie)&&aa(Ae,ie)&&(Wt(d)||gl(d)))}s(ry,"hasPath"),c(ry,"hasPath");function Y9(d){var y=d.length,O=new d.constructor(y);return y&&typeof d[0]=="string"&&Or.call(d,"index")&&(O.index=d.index,O.input=d.input),O}s(Y9,"initCloneArray"),c(Y9,"initCloneArray");function ny(d){return typeof d.constructor=="function"&&!Pu(d)?Iu(mm(d)):{}}s(ny,"initCloneObject"),c(ny,"initCloneObject");function Z9(d,y,O){var V=d.constructor;switch(y){case Ne:return Lm(d);case Y:case Z:return new V(+d);case ye:return P9(d,O);case pe:case ne:case he:case Ee:case Ie:case Re:case Oe:case bt:case Qe:return L6(d,O);case me:return new V;case ke:case le:return new V(d);case se:return O9(d);case ee:return new V;case be:return F9(d)}}s(Z9,"initCloneByTag"),c(Z9,"initCloneByTag");function X9(d,y){var O=y.length;if(!O)return d;var V=O-1;return y[V]=(O>1?"& ":"")+y[V],y=y.join(O>2?", ":" "),d.replace(ut,`{
|