From 3e3b6990e3ce91e4cb145d70bdf29a3205e24d49 Mon Sep 17 00:00:00 2001 From: Mc Date: Mon, 3 May 2021 21:52:14 +0300 Subject: [PATCH] deploy --- assets/cake.b1a18790.png | Bin 0 -> 5443 bytes assets/index.ccce2ca3.css | 1 + assets/index.fafadd3c.js | 1 + assets/vendor.d24c7bfe.js | 9 +++++++++ favicon.ico | Bin 0 -> 15406 bytes index.html | 16 ++++++++++++++++ 6 files changed, 27 insertions(+) create mode 100644 assets/cake.b1a18790.png create mode 100644 assets/index.ccce2ca3.css create mode 100644 assets/index.fafadd3c.js create mode 100644 assets/vendor.d24c7bfe.js create mode 100644 favicon.ico create mode 100644 index.html diff --git a/assets/cake.b1a18790.png b/assets/cake.b1a18790.png new file mode 100644 index 0000000000000000000000000000000000000000..eb031107833509dff945cc941acdaeaf1aa9e216 GIT binary patch literal 5443 zcmV-J6};++P)NnnpCnSW<8DZju+jn;Rp|f?W`?pvIVR#i$5} zLl*%R5D@9rh7voX*f5GEVnI=g3K#?t0Z{=fiXChe3+t^lb7nXd4wl?JzwiG%XU?9z z_rLb)Gce3M_$M}GzO&P3W{CAQW9$qx_K6KN3heYXZXq5bnh=0^gt&_+78z)y+UaYq z5E(E|w!NADLBkns=Ks?_%K=OWu^uxCNo+<31~xXWHeGOTTutEeN9#HR*R0 z#IU~&adB_vE6HiUl;5zwS+@%tX8e$q<}>_6LD;xUMNvP#L_lje8#&=d)_k*^BzuF5 zaEs3h#Ri%$ln5hBq{j^YuMsEP6zenoVttJ|>5X{~>UeF3W1pjE!pC1$hpbuxiI`B6 zI(JBR$e2&gqYsf5LKA94qIEx}+h0oFMxXhoot{RnH1W`}pA_W=jV{0qH}M-k6+9YJ zJO;uJXCv6*WC(w_8$(Xus5cS@3buTORnKhH3PI!W5UTz%v#{4^`ik^5?(mDx9@Mew zM8L>X{00jn#=};z9{8GeQR&#chIWRHw%#RUnY^cdX{u4q zu8y!TpdI**(oz(XfhGix`Utk8shmMAYKtJy^v*c<(cupUO@o>Ec4PbZOgl*e!*2Gl z*N{v(uMHjpb-7bD)PQ4A?FG`RP`FAL+>EuAn#i2NonY6@zHJi1pCMyP9F4S}O6I7s zGhqJbtqB0tYCgZY?e<0)GENCki%yRH9X<5vmG3E#E#1@}&TVK9HFDQ0HtT}35oa1f zrkxjS3ejzVpEX?fJo)^L;GT%26fJjfHj3x`i zI4`}>`WgS0I4=!wH|9vJchZ(2cXO{U{1MtLgyaR9a6MU819tmye!vAyAcgpS%-D~>qc5ick-um_ z^&h%21Zz?|!rArhA%AT?U%m$nrOn#0JQVn9a@b7w^2}J z4uPY%`Q1^7i%ql@u*g&!=3-Q!F{^&7hN8sPw3ND`xo;Q;G}i@n{@e`YpI%t-5%bdEnqav}@I zc7@2Hnh=3-GUSLjBcbKC%}$Smk>slZN&Xt_Xa4$cC@9yyl8g`q7d}Ljol6-Ojpov7 zOm@^3z&e}n*?X|ehC_1(r%Rbb9-6j}dLht&nL{@@_R)rt#Xk#^yGxRum{DCI3^z_# zFh~>lN{uqXxkFJvRt&6nZzjFogMr1<81Na+jp4`o57ZFmQHE&q_XR(ot^l^o>L&<* zzHhSC%V-t?}_c8)NG*H7uviAL{{h7{f5kO=0K6hb(rN4Z|#pe+p!h(T} z3<40d`!NcFkSFfhmqFjbDBQ0Mp^{`vicE{B++YidavDI$2^y8xTzfFitqVY(ag|ha zuNsP?UY?7d$WCcIKRx2ohZ|91coqeNqFi4!9#Q)5S`iELhxX1tUbC)Doic%u4 zg%r8idlN-J$X1QPV+wgr)OK&R?}r1~5_5a-xSFPlSa@TUMmj_9qs zKoD;JO%XAo6LyW>7ktK6dp)&O|IVQ~KzqEh&rP`Zi1#p=F{njVfmQWm{=;Q3J3Otd`o}Jv3L?*R3O7!W{9_zf%}r zwqiAWa(^yZts(EQNBHdU!S23xvh$&qji`#7TwX$%PEokU_Nh2f|{` zeRaTNkS@#}@;)2Soh8MTJSfT9BJQnla>`J)d@`D3u&^Jp{h)E5a^*GFDW}6M6hq`D zar1h5%yg9km@z}_j{*RZd2g8w2I2zsMVu+zNcZ6cgNah4X$J^JuPqHCPIQ=??Rv9)giYv~ z={Z4)`vA7IRyVyRle@LY4W5_82*e35FD`-Y-h*XYX{zpTy!4w;CE83J@zUBFyN7cB zG;C}{*(`Z$s|J2>!OEEs`%81X$p;Z@{JyZ&}m=YVh;~9 z{NR<;i3?_kj(L^%2Vq~-JyO+2ymMeS)L&XBjJ5g20+8o%;@tey$3{Gf$P*G5`Iqp6 zOX5VVdM=stPpQ7XmLPx#BrT1ZgSdj}!X6i>$@GU?d)=Ti!3Hj@uwqFm=I;~XJlZtX z9927A;lVK!EI>ZOvv3v^n9mPjf? zO-`VY>+^^l_qocGFO9W?28rKFj-1AhpEvHCS03)O?@12(2-g6yv-@BC(nJ??b8|Bf zZiwLs;scK&Ngcq0?3a(%RPjX))slfa0%!|JNEG6>cpA&J&Pn*2M7>p-P$}B|v;0sl zN|didhs{NwEf?Y{q0=nf~~C>>g(!n9^4QOd^t=L$xj|B=?aqo zqK0Y7z_Bm4P&sC0uS>cSon3XBH>Aakhk54R6rxAO_|M>Ez(|$k$=vD-BZc`6#MyH> zi;)i8x_l8D>KkqlSB|rtBYJ<)PWloM5Lo%V@j37Ua6&RvV#+VD&%;;{Ks1t;hV({# z&^EVt4uC&bO@T|v&T#YaT)21KA8K<0p%zo?2Pfu3^-*uA*gF#n5~jm0e-j9q@VU~E zNv9uf@u@m6n#Cq91b)Y!f#1qH+!P{M}_1KI$`^GZFL=F~hNi&BH`T@Bufo ze7R%=L(r`(KgeG{9S#JT!gfrKHrn)p1Wb&m+DmdYK$98(>AogvJrATBpnUCgxV_&K zQ}PI+fKJc@KQl)q}Nbe9eu0{Y737p7;vQzF>2>n&J-6Fx8cJTIztR zz=tOT;B2A|ti(D%+3Poiqub(IBu^Z-Zr#QwLyt%U*qFF__1cW88_l6&mA92J>4Ty* zG8?(^yEALAs+`rac_wUUmiHA3Z-ZbzA#qk;d|dW36mPYI%ll?QRq7nLo8b$$u^zZ~ zz!NU*a)JE#X^eIbw(;LW{j+B+3gE`|8_0EahC~3DNdU*` zOJHDdL4JO|F!1h;D==%AqzgQvJ62TjGABZf$ntg8t-Z&?Y6d;ulYc<+CU8Zcv)a`V z3b#AM5(nevaCiJbi{uHXPoGAvK?R%u#F-?3D7Fl?cdA9(cu{?;x_R)CWI>(%EWUs` zIU(?EGVS2oI!Z(23W zL>RMUiBGHKZ{55__WvBYK9=MG5mX9~=2CLjkPo0Lcd5$o zM&YV*gN@8H#TH(TWnZ97!}J#W_H3VVyQ3lg-v?5BhQP_#Nl-~Xqc}=ot!HIxAk6CD z!oF5{O@_w$h8D@!J*$K4>}=wg%kxEyrY5KkHbd^vg|M*j(k5wXN5h0|6rV-%;o^3JvVkZ!@a}a@H8)^ z<%m%k2PFr>*h-b(%W9t~Q1|p{tEXRFTui4AAt9mp67tp91J&jmA~C#FQd3jU(!k2f zN|^~LuFf3P-0+-Z)&oipg~F@K6@NjzUj{c%#X`idy<`%dUCZaQc}r{LD=I2j@~NqZ z3!6`06e%=BrcZbJh(ZGW;O#x{64?peaP8_fnTc*zmO;4nK-pJd%|C)OyB9#i#no?} z_{)k_P@WzGkyCrg7D=P9<#zH=tHcRcuU=)z6DMzPp9>NJJQj<^AImfau`-&^OK1K1 zgmlSGaG~si%!DNItmJhtXQX23xq%U7JMi4RO!7#Cw~Viv9^%6(;qGziGXV-7ejSk9NfuY0oSvaK>5)~R(sOcxWH0- zW3X2d8Qh2WV7>f<+c(uBPJ5+2^ZQ3GC;6@yBA>V_ZH-%7+xO%%Ly^e7{@}rb1^guB zLGRqTqp%ohL~-_ENC>n850j7HTCAshKF(tzz!? zWAQaCa~lu4R|G(D&JlR}_>tPA36CE=mN|9F$)B>bb7+*1Zxo3{>b*sZgRKxRCB4EX z^a+`iB=HkxWMoiD$u8R3#z;f%RbPk8CHYX2o5ngX9waQvI9p3!TO&?;p*=~Ff3a>| zd=~9plJL+2AImnqE{DBBbMltF8~%F1HBG}Rn=d3h}8GhL(K z)SU-a{R+nR6HZR9wbFY+RJ^vzxB6EkmX;kbiSXiU2WfbD`Ic?mxGCevkt38zHmOUb z4QRr-FK*bdA=Ast`-1%Xl-uLJX4}}JcaFZwbWa=%U0p~qIb6Z=BOlYmY{a=)mEpl(2h^$dXqme|Cr2TeLqAd?4 t`FWG%^L>d)(U>H{URL.revokeObjectURL(e.src),e.remove()};self[a]=e=>new Promise(((n,o)=>{const l=new URL(e,t);if(self[a].moduleMap[l])return n(self[a].moduleMap[l]);const u=new Blob([`import * as m from '${l}';`,`${a}.moduleMap['${l}']=m;`],{type:"text/javascript"}),c=Object.assign(document.createElement("script"),{type:"module",src:URL.createObjectURL(u),onerror(){o(new Error(`Failed to import: ${e}`)),s(c)},onload(){n(self[a].moduleMap[l]),s(c)}});document.head.appendChild(c)})),self[a].moduleMap={}}}("/bsc-api/assets/");const i=l("b",null,"Auto",-1),b=r("  "),m=r("  "),f=r("  "),k=l("b",null,"Cake",-1),g=r("  "),w=r("  "),A=r("  "),U={expose:[],setup(r){const d="0xF7DE62B65768a169279be74b12FaA65a22FB38D3",U=new e("https://bsc-dataseed1.binance.org:443"),C=new a("0xf5cb93f18ed8bf23b00b78f2d0693aa60ca27538",["function get(string, uint, address) view returns (uint, uint, uint)"],U),E=n({auto:{},cake:{}});return C.get("auto",7,d).then((e=>{E.auto.balance=t(e[0]),E.auto.staked=t(e[1]),E.auto.pending=t(e[2])})),C.get("cake2",0,d).then((e=>{E.cake.balance=t(e[0]),E.cake.staked=t(e[1]),E.cake.pending=t(e[2])})),(e,a)=>(s(),o(p,null,[l("p",null,[i,b,l("span",null,"Balance: "+u(c(E).auto.balance)+" AUTO",1),m,l("span",null,"Staked: "+u(c(E).auto.staked)+" CAKE",1),f,l("span",null,"Pending: "+u(c(E).auto.pending)+" AUTO",1)]),l("p",null,[k,g,l("span",null,"Balance: "+u(c(E).cake.balance)+" CAKE",1),w,l("span",null,"Staked: "+u(c(E).cake.staked)+" CAKE",1),A,l("span",null,"Pending: "+u(c(E).cake.pending)+" CAKE",1)])],64))}};const C=l("img",{alt:"Vue logo",src:"/bsc-api/assets/cake.b1a18790.png"},null,-1);d({expose:[],setup:e=>(e,a)=>(s(),o(p,null,[C,l(U)],64))}).mount("#app"); diff --git a/assets/vendor.d24c7bfe.js b/assets/vendor.d24c7bfe.js new file mode 100644 index 0000000..0a6eae2 --- /dev/null +++ b/assets/vendor.d24c7bfe.js @@ -0,0 +1,9 @@ +function t(t,e){const r=Object.create(null),n=t.split(",");for(let i=0;i!!r[t.toLowerCase()]:t=>!!r[t]}const e=t("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt"),r=t("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function n(t){if(_(t)){const e={};for(let r=0;r{if(t){const r=t.split(o);r.length>1&&(e[r[0].trim()]=r[1].trim())}})),e}function a(t){let e="";if(k(t))e=t;else if(_(t))for(let r=0;rnull==t?"":x(t)?JSON.stringify(t,l,2):String(t),l=(t,e)=>E(e)?{[`Map(${e.size})`]:[...e.entries()].reduce(((t,[e,r])=>(t[`${e} =>`]=r,t)),{})}:A(e)?{[`Set(${e.size})`]:[...e.values()]}:!x(e)||_(e)||P(e)?e:String(e),h={},c=[],f=()=>{},d=()=>!1,p=/^on[^a-z]/,m=t=>p.test(t),g=t=>t.startsWith("onUpdate:"),v=Object.assign,y=(t,e)=>{const r=t.indexOf(e);r>-1&&t.splice(r,1)},b=Object.prototype.hasOwnProperty,w=(t,e)=>b.call(t,e),_=Array.isArray,E=t=>"[object Map]"===R(t),A=t=>"[object Set]"===R(t),M=t=>"function"==typeof t,k=t=>"string"==typeof t,N=t=>"symbol"==typeof t,x=t=>null!==t&&"object"==typeof t,S=t=>x(t)&&M(t.then)&&M(t.catch),I=Object.prototype.toString,R=t=>I.call(t),P=t=>"[object Object]"===R(t),T=t=>k(t)&&"NaN"!==t&&"-"!==t[0]&&""+parseInt(t,10)===t,O=t(",key,ref,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),B=t=>{const e=Object.create(null);return r=>e[r]||(e[r]=t(r))},C=/-(\w)/g,F=B((t=>t.replace(C,((t,e)=>e?e.toUpperCase():"")))),L=/\B([A-Z])/g,U=B((t=>t.replace(L,"-$1").toLowerCase())),j=B((t=>t.charAt(0).toUpperCase()+t.slice(1))),z=B((t=>t?`on${j(t)}`:"")),D=(t,e)=>t!==e&&(t==t||e==e),q=(t,e)=>{for(let r=0;r{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:r})},$=t=>{const e=parseFloat(t);return isNaN(e)?t:e},H=new WeakMap,G=[];let W;const J=Symbol(""),K=Symbol("");function Z(t,e=h){(function(t){return t&&!0===t._isEffect})(t)&&(t=t.raw);const r=function(t,e){const r=function(){if(!r.active)return e.scheduler?void 0:t();if(!G.includes(r)){Y(r);try{return et.push(tt),tt=!0,G.push(r),W=r,t()}finally{G.pop(),nt(),W=G[G.length-1]}}};return r.id=Q++,r.allowRecurse=!!e.allowRecurse,r._isEffect=!0,r.active=!0,r.raw=t,r.deps=[],r.options=e,r}(t,e);return e.lazy||r(),r}function X(t){t.active&&(Y(t),t.options.onStop&&t.options.onStop(),t.active=!1)}let Q=0;function Y(t){const{deps:e}=t;if(e.length){for(let r=0;r{t&&t.forEach((t=>{(t!==W||t.allowRecurse)&&a.add(t)}))};if("clear"===e)s.forEach(u);else if("length"===r&&_(t))s.forEach(((t,e)=>{("length"===e||e>=n)&&u(t)}));else switch(void 0!==r&&u(s.get(r)),e){case"add":_(t)?T(r)&&u(s.get("length")):(u(s.get(J)),E(t)&&u(s.get(K)));break;case"delete":_(t)||(u(s.get(J)),E(t)&&u(s.get(K)));break;case"set":E(t)&&u(s.get(J))}a.forEach((t=>{t.options.scheduler?t.options.scheduler(t):t()}))}const st=t("__proto__,__v_isRef,__isVue"),at=new Set(Object.getOwnPropertyNames(Symbol).map((t=>Symbol[t])).filter(N)),ut=dt(),lt=dt(!1,!0),ht=dt(!0),ct=dt(!0,!0),ft={};function dt(t=!1,e=!1){return function(r,n,i){if("__v_isReactive"===n)return!t;if("__v_isReadonly"===n)return t;if("__v_raw"===n&&i===(t?e?Vt:qt:e?Dt:zt).get(r))return r;const o=_(r);if(!t&&o&&w(ft,n))return Reflect.get(ft,n,i);const s=Reflect.get(r,n,i);if(N(n)?at.has(n):st(n))return s;if(t||it(r,0,n),e)return s;if(Qt(s)){return!o||!T(n)?s.value:s}return x(s)?t?Gt(s):Ht(s):s}}["includes","indexOf","lastIndexOf"].forEach((t=>{const e=Array.prototype[t];ft[t]=function(...t){const r=Xt(this);for(let e=0,i=this.length;e{const e=Array.prototype[t];ft[t]=function(...t){rt();const r=e.apply(this,t);return nt(),r}}));function pt(t=!1){return function(e,r,n,i){let o=e[r];if(!t&&(n=Xt(n),o=Xt(o),!_(e)&&Qt(o)&&!Qt(n)))return o.value=n,!0;const s=_(e)&&T(r)?Number(r)!0,deleteProperty:(t,e)=>!0},vt=v({},mt,{get:lt,set:pt(!0)});v({},gt,{get:ct});const yt=t=>x(t)?Ht(t):t,bt=t=>x(t)?Gt(t):t,wt=t=>t,_t=t=>Reflect.getPrototypeOf(t);function Et(t,e,r=!1,n=!1){const i=Xt(t=t.__v_raw),o=Xt(e);e!==o&&!r&&it(i,0,e),!r&&it(i,0,o);const{has:s}=_t(i),a=n?wt:r?bt:yt;return s.call(i,e)?a(t.get(e)):s.call(i,o)?a(t.get(o)):void 0}function At(t,e=!1){const r=this.__v_raw,n=Xt(r),i=Xt(t);return t!==i&&!e&&it(n,0,t),!e&&it(n,0,i),t===i?r.has(t):r.has(t)||r.has(i)}function Mt(t,e=!1){return t=t.__v_raw,!e&&it(Xt(t),0,J),Reflect.get(t,"size",t)}function kt(t){t=Xt(t);const e=Xt(this);return _t(e).has.call(e,t)||(e.add(t),ot(e,"add",t,t)),this}function Nt(t,e){e=Xt(e);const r=Xt(this),{has:n,get:i}=_t(r);let o=n.call(r,t);o||(t=Xt(t),o=n.call(r,t));const s=i.call(r,t);return r.set(t,e),o?D(e,s)&&ot(r,"set",t,e):ot(r,"add",t,e),this}function xt(t){const e=Xt(this),{has:r,get:n}=_t(e);let i=r.call(e,t);i||(t=Xt(t),i=r.call(e,t)),n&&n.call(e,t);const o=e.delete(t);return i&&ot(e,"delete",t,void 0),o}function St(){const t=Xt(this),e=0!==t.size,r=t.clear();return e&&ot(t,"clear",void 0,void 0),r}function It(t,e){return function(r,n){const i=this,o=i.__v_raw,s=Xt(o),a=e?wt:t?bt:yt;return!t&&it(s,0,J),o.forEach(((t,e)=>r.call(n,a(t),a(e),i)))}}function Rt(t,e,r){return function(...n){const i=this.__v_raw,o=Xt(i),s=E(o),a="entries"===t||t===Symbol.iterator&&s,u="keys"===t&&s,l=i[t](...n),h=r?wt:e?bt:yt;return!e&&it(o,0,u?K:J),{next(){const{value:t,done:e}=l.next();return e?{value:t,done:e}:{value:a?[h(t[0]),h(t[1])]:h(t),done:e}},[Symbol.iterator](){return this}}}}function Pt(t){return function(...e){return"delete"!==t&&this}}const Tt={get(t){return Et(this,t)},get size(){return Mt(this)},has:At,add:kt,set:Nt,delete:xt,clear:St,forEach:It(!1,!1)},Ot={get(t){return Et(this,t,!1,!0)},get size(){return Mt(this)},has:At,add:kt,set:Nt,delete:xt,clear:St,forEach:It(!1,!0)},Bt={get(t){return Et(this,t,!0)},get size(){return Mt(this,!0)},has(t){return At.call(this,t,!0)},add:Pt("add"),set:Pt("set"),delete:Pt("delete"),clear:Pt("clear"),forEach:It(!0,!1)},Ct={get(t){return Et(this,t,!0,!0)},get size(){return Mt(this,!0)},has(t){return At.call(this,t,!0)},add:Pt("add"),set:Pt("set"),delete:Pt("delete"),clear:Pt("clear"),forEach:It(!0,!0)};function Ft(t,e){const r=e?t?Ct:Ot:t?Bt:Tt;return(e,n,i)=>"__v_isReactive"===n?!t:"__v_isReadonly"===n?t:"__v_raw"===n?e:Reflect.get(w(r,n)&&n in e?r:e,n,i)}["keys","values","entries",Symbol.iterator].forEach((t=>{Tt[t]=Rt(t,!1,!1),Bt[t]=Rt(t,!0,!1),Ot[t]=Rt(t,!1,!0),Ct[t]=Rt(t,!0,!0)}));const Lt={get:Ft(!1,!1)},Ut={get:Ft(!1,!0)},jt={get:Ft(!0,!1)},zt=new WeakMap,Dt=new WeakMap,qt=new WeakMap,Vt=new WeakMap;function $t(t){return t.__v_skip||!Object.isExtensible(t)?0:function(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((t=>R(t).slice(8,-1))(t))}function Ht(t){return t&&t.__v_isReadonly?t:Wt(t,!1,mt,Lt,zt)}function Gt(t){return Wt(t,!0,gt,jt,qt)}function Wt(t,e,r,n,i){if(!x(t))return t;if(t.__v_raw&&(!e||!t.__v_isReactive))return t;const o=i.get(t);if(o)return o;const s=$t(t);if(0===s)return t;const a=new Proxy(t,2===s?n:r);return i.set(t,a),a}function Jt(t){return Kt(t)?Jt(t.__v_raw):!(!t||!t.__v_isReactive)}function Kt(t){return!(!t||!t.__v_isReadonly)}function Zt(t){return Jt(t)||Kt(t)}function Xt(t){return t&&Xt(t.__v_raw)||t}function Qt(t){return Boolean(t&&!0===t.__v_isRef)}function Yt(t){return Qt(t)?t.value:t}const te={get:(t,e,r)=>Yt(Reflect.get(t,e,r)),set:(t,e,r,n)=>{const i=t[e];return Qt(i)&&!Qt(r)?(i.value=r,!0):Reflect.set(t,e,r,n)}};function ee(t){return Jt(t)?t:new Proxy(t,te)}class re{constructor(t,e){this._object=t,this._key=e,this.__v_isRef=!0}get value(){return this._object[this._key]}set value(t){this._object[this._key]=t}}class ne{constructor(t,e,r){this._setter=e,this._dirty=!0,this.__v_isRef=!0,this.effect=Z(t,{lazy:!0,scheduler:()=>{this._dirty||(this._dirty=!0,ot(Xt(this),"set","value"))}}),this.__v_isReadonly=r}get value(){const t=Xt(this);return t._dirty&&(t._value=this.effect(),t._dirty=!1),it(t,0,"value"),t._value}set value(t){this._setter(t)}}function ie(t,e,r,n){let i;try{i=n?t(...n):t()}catch(o){se(o,e,r)}return i}function oe(t,e,r,n){if(M(t)){const i=ie(t,e,r,n);return i&&S(i)&&i.catch((t=>{se(t,e,r)})),i}const i=[];for(let o=0;o>>1;Ne(le[t])-1?le.splice(e,0,t):le.push(t),Ee()}}function Ee(){ae||ue||(ue=!0,ye=ve.then(xe))}function Ae(t,e,r,n){_(t)?r.push(...t):e&&e.includes(t,t.allowRecurse?n+1:n)||r.push(t),Ee()}function Me(t,e=null){if(ce.length){for(be=e,fe=[...new Set(ce)],ce.length=0,de=0;deNe(t)-Ne(e))),ge=0;genull==t.id?1/0:t.id;function xe(t){ue=!1,ae=!0,Me(t),le.sort(((t,e)=>Ne(t)-Ne(e)));try{for(he=0;het.trim())):e&&(i=r.map($))}let a,u=n[a=z(e)]||n[a=z(F(e))];!u&&o&&(u=n[a=z(U(e))]),u&&oe(u,t,6,i);const l=n[a+"Once"];if(l){if(t.emitted){if(t.emitted[a])return}else(t.emitted={})[a]=!0;oe(l,t,6,i)}}function Ie(t,e,r=!1){if(!e.deopt&&void 0!==t.__emits)return t.__emits;const n=t.emits;let i={},o=!1;if(!M(t)){const n=t=>{const r=Ie(t,e,!0);r&&(o=!0,v(i,r))};!r&&e.mixins.length&&e.mixins.forEach(n),t.extends&&n(t.extends),t.mixins&&t.mixins.forEach(n)}return n||o?(_(n)?n.forEach((t=>i[t]=null)):v(i,n),t.__emits=i):t.__emits=null}function Re(t,e){return!(!t||!m(e))&&(e=e.slice(2).replace(/Once$/,""),w(t,e[0].toLowerCase()+e.slice(1))||w(t,U(e))||w(t,e))}let Pe=0;const Te=t=>Pe+=t;let Oe=null,Be=null;function Ce(t){const e=Oe;return Oe=t,Be=t&&t.type.__scopeId||null,e}function Fe(t){const{type:e,vnode:r,proxy:n,withProxy:i,props:o,propsOptions:[s],slots:a,attrs:u,emit:l,render:h,renderCache:c,data:f,setupState:d,ctx:p}=t;let m;const v=Ce(t);try{let t;if(4&r.shapeFlag){const e=i||n;m=Wr(h.call(e,e,c,o,d,f,p)),t=u}else{const r=e;0,m=Wr(r.length>1?r(o,{attrs:u,slots:a,emit:l}):r(o,null)),t=e.props?u:Ue(u)}let v=m;if(!1!==e.inheritAttrs&&t){const e=Object.keys(t),{shapeFlag:r}=v;e.length&&(1&r||6&r)&&(s&&e.some(g)&&(t=je(t,s)),v=Hr(v,t))}r.dirs&&(v.dirs=v.dirs?v.dirs.concat(r.dirs):r.dirs),r.transition&&(v.transition=r.transition),m=v}catch(y){Br.length=0,se(y,t,1),m=$r(Tr)}return Ce(v),m}function Le(t){let e;for(let r=0;r{let e;for(const r in t)("class"===r||"style"===r||m(r))&&((e||(e={}))[r]=t[r]);return e},je=(t,e)=>{const r={};for(const n in t)g(n)&&n.slice(9)in e||(r[n]=t[n]);return r};function ze(t,e,r){const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!0;for(let i=0;i{s=!0;const[r,n]=He(t,e,!0);v(i,r),n&&o.push(...n)};!r&&e.mixins.length&&e.mixins.forEach(n),t.extends&&n(t.extends),t.mixins&&t.mixins.forEach(n)}if(!n&&!s)return t.__props=c;if(_(n))for(let a=0;a-1,r[1]=n<0||e-1||w(r,"default"))&&o.push(t)}}}return t.__props=[i,o]}function Ge(t){return"$"!==t[0]}function We(t){const e=t&&t.toString().match(/^\s*function (\w+)/);return e?e[1]:""}function Je(t,e){return We(t)===We(e)}function Ke(t,e){return _(e)?e.findIndex((e=>Je(e,t))):M(e)&&Je(e,t)?0:-1}function Ze(t,e,r=fn,n=!1){if(r){const i=r[t]||(r[t]=[]),o=e.__weh||(e.__weh=(...n)=>{if(r.isUnmounted)return;rt(),dn(r);const i=oe(e,r,t,n);return dn(null),nt(),i});return n?i.unshift(o):i.push(o),o}}const Xe=t=>(e,r=fn)=>!mn&&Ze(t,e,r),Qe=Xe("bm"),Ye=Xe("m"),tr=Xe("bu"),er=Xe("u"),rr=Xe("bum"),nr=Xe("um"),ir=Xe("rtg"),or=Xe("rtc"),sr={};function ar(t,e,r){return ur(t,e,r)}function ur(t,e,{immediate:r,deep:n,flush:i,onTrack:o,onTrigger:s}=h,a=fn){let u,l,c=!1;if(Qt(t)?(u=()=>t.value,c=!!t._shallow):Jt(t)?(u=()=>t,n=!0):u=_(t)?()=>t.map((t=>Qt(t)?t.value:Jt(t)?hr(t):M(t)?ie(t,a,2,[a&&a.proxy]):void 0)):M(t)?e?()=>ie(t,a,2,[a&&a.proxy]):()=>{if(!a||!a.isUnmounted)return l&&l(),oe(t,a,3,[d])}:f,e&&n){const t=u;u=()=>hr(t())}let d=t=>{l=v.options.onStop=()=>{ie(t,a,4)}},p=_(t)?[]:sr;const m=()=>{if(v.active)if(e){const t=v();(n||c||D(t,p))&&(l&&l(),oe(e,a,3,[t,p===sr?void 0:p,d]),p=t)}else v()};let g;m.allowRecurse=!!e,g="sync"===i?m:"post"===i?()=>Mr(m,a&&a.suspense):()=>{!a||a.isMounted?function(t){Ae(t,fe,ce,de)}(m):m()};const v=Z(u,{lazy:!0,onTrack:o,onTrigger:s,scheduler:g});return yn(v,a),e?r?m():p=v():"post"===i?Mr(v,a&&a.suspense):v(),()=>{X(v),a&&y(a.effects,v)}}function lr(t,e,r){const n=this.proxy;return ur(k(t)?()=>n[t]:t.bind(n),e.bind(n),r,this)}function hr(t,e=new Set){if(!x(t)||e.has(t))return t;if(e.add(t),Qt(t))hr(t.value,e);else if(_(t))for(let r=0;r{hr(t,e)}));else for(const r in t)hr(t[r],e);return t}const cr=t=>t.type.__isKeepAlive;function fr(t,e,r=fn){const n=t.__wdc||(t.__wdc=()=>{let e=r;for(;e;){if(e.isDeactivated)return;e=e.parent}t()});if(Ze(e,n,r),r){let t=r.parent;for(;t&&t.parent;)cr(t.parent.vnode)&&dr(n,e,r,t),t=t.parent}}function dr(t,e,r,n){const i=Ze(e,t,n,!0);nr((()=>{y(n[e],i)}),r)}const pr=t=>"_"===t[0]||"$stable"===t,mr=t=>_(t)?t.map(Wr):[Wr(t)],gr=(t,e,r)=>function(t,e=Oe){if(!e)return t;const r=(...r)=>{Pe||Fr(!0);const n=Ce(e),i=t(...r);return Ce(n),Pe||Lr(),i};return r._c=!0,r}((t=>mr(e(t))),r),vr=(t,e)=>{const r=t._ctx;for(const n in t){if(pr(n))continue;const i=t[n];if(M(i))e[n]=gr(0,i,r);else if(null!=i){const t=mr(i);e[n]=()=>t}}},yr=(t,e)=>{const r=mr(e);t.slots.default=()=>r};function br(t,e,r,n){const i=t.dirs,o=e&&e.dirs;for(let s=0;s(o.has(t)||(t&&M(t.install)?(o.add(t),t.install(a,...e)):M(t)&&(o.add(t),t(a,...e))),a),mixin:t=>(i.mixins.includes(t)||(i.mixins.push(t),(t.props||t.emits)&&(i.deopt=!0)),a),component:(t,e)=>e?(i.components[t]=e,a):i.components[t],directive:(t,e)=>e?(i.directives[t]=e,a):i.directives[t],mount(o,u,l){if(!s){const h=$r(r,n);return h.appContext=i,u&&e?e(h,o):t(h,o,l),s=!0,a._container=o,o.__vue_app__=a,h.component.proxy}},unmount(){s&&(t(null,a._container),delete a._container.__vue_app__)},provide:(t,e)=>(i.provides[t]=e,a)};return a}}const Ar={scheduler:_e,allowRecurse:!0},Mr=function(t,e){e&&e.pendingBranch?_(t)?e.effects.push(...t):e.effects.push(t):Ae(t,me,pe,ge)},kr=(t,e,r,n)=>{if(_(t))return void t.forEach(((t,i)=>kr(t,e&&(_(e)?e[i]:e),r,n)));let i;if(n){if(n.type.__asyncLoader)return;i=4&n.shapeFlag?n.component.exposed||n.component.proxy:n.el}else i=null;const{i:o,r:s}=t,a=e&&e.r,u=o.refs===h?o.refs={}:o.refs,l=o.setupState;if(null!=a&&a!==s&&(k(a)?(u[a]=null,w(l,a)&&(l[a]=null)):Qt(a)&&(a.value=null)),k(s)){const t=()=>{u[s]=i,w(l,s)&&(l[s]=i)};i?(t.id=-1,Mr(t,r)):t()}else if(Qt(s)){const t=()=>{s.value=i};i?(t.id=-1,Mr(t,r)):t()}else M(s)&&ie(s,o,12,[i,u])};function Nr(t){return function(t,e){const{insert:r,remove:n,patchProp:i,forcePatchProp:o,createElement:s,createText:a,createComment:u,setText:l,setElementText:d,parentNode:p,nextSibling:m,setScopeId:g=f,cloneNode:y,insertStaticContent:b}=t,_=(t,e,r,n=null,i=null,o=null,s=!1,a=null,u=!1)=>{t&&!zr(t,e)&&(n=st(t),Q(t,i,o,!0),t=null),-2===e.patchFlag&&(u=!1,e.dynamicChildren=null);const{type:l,ref:h,shapeFlag:c}=e;switch(l){case Pr:E(t,e,r,n);break;case Tr:A(t,e,r,n);break;case Or:null==t&&M(e,r,n,s);break;case Rr:L(t,e,r,n,i,o,s,a,u);break;default:1&c?x(t,e,r,n,i,o,s,a,u):6&c?j(t,e,r,n,i,o,s,a,u):(64&c||128&c)&&l.process(t,e,r,n,i,o,s,a,u,ut)}null!=h&&i&&kr(h,t&&t.ref,o,e)},E=(t,e,n,i)=>{if(null==t)r(e.el=a(e.children),n,i);else{const r=e.el=t.el;e.children!==t.children&&l(r,e.children)}},A=(t,e,n,i)=>{null==t?r(e.el=u(e.children||""),n,i):e.el=t.el},M=(t,e,r,n)=>{[t.el,t.anchor]=b(t.children,e,r,n)},k=({el:t,anchor:e},n,i)=>{let o;for(;t&&t!==e;)o=m(t),r(t,n,i),t=o;r(e,n,i)},N=({el:t,anchor:e})=>{let r;for(;t&&t!==e;)r=m(t),n(t),t=r;n(e)},x=(t,e,r,n,i,o,s,a,u)=>{s=s||"svg"===e.type,null==t?I(e,r,n,i,o,s,a,u):T(t,e,i,o,s,a,u)},I=(t,e,n,o,a,u,l,h)=>{let c,f;const{type:p,props:m,shapeFlag:g,transition:v,patchFlag:b,dirs:w}=t;if(t.el&&void 0!==y&&-1===b)c=t.el=y(t.el);else{if(c=t.el=s(t.type,u,m&&m.is,m),8&g?d(c,t.children):16&g&&P(t.children,c,null,o,a,u&&"foreignObject"!==p,l,h||!!t.dynamicChildren),w&&br(t,null,o,"created"),m){for(const e in m)O(e)||i(c,e,null,m[e],u,t.children,o,a,it);(f=m.onVnodeBeforeMount)&&xr(f,o,t)}R(c,t,t.scopeId,l,o)}w&&br(t,null,o,"beforeMount");const _=(!a||a&&!a.pendingBranch)&&v&&!v.persisted;_&&v.beforeEnter(c),r(c,e,n),((f=m&&m.onVnodeMounted)||_||w)&&Mr((()=>{f&&xr(f,o,t),_&&v.enter(c),w&&br(t,null,o,"mounted")}),a)},R=(t,e,r,n,i)=>{if(r&&g(t,r),n)for(let o=0;o{for(let l=u;l{const l=e.el=t.el;let{patchFlag:c,dynamicChildren:f,dirs:p}=e;c|=16&t.patchFlag;const m=t.props||h,g=e.props||h;let v;if((v=g.onVnodeBeforeUpdate)&&xr(v,r,e,t),p&&br(e,t,r,"beforeUpdate"),c>0){if(16&c)C(l,e,m,g,r,n,s);else if(2&c&&m.class!==g.class&&i(l,"class",null,g.class,s),4&c&&i(l,"style",m.style,g.style,s),8&c){const a=e.dynamicProps;for(let e=0;e{v&&xr(v,r,e,t),p&&br(e,t,r,"updated")}),n)},B=(t,e,r,n,i,o,s)=>{for(let a=0;a{if(r!==n){for(const l in n){if(O(l))continue;const h=n[l],c=r[l];(h!==c||o&&o(t,l))&&i(t,l,c,h,u,e.children,s,a,it)}if(r!==h)for(const o in r)O(o)||o in n||i(t,o,r[o],null,u,e.children,s,a,it)}},L=(t,e,n,i,o,s,u,l,h)=>{const c=e.el=t?t.el:a(""),f=e.anchor=t?t.anchor:a("");let{patchFlag:d,dynamicChildren:p,slotScopeIds:m}=e;d>0&&(h=!0),m&&(l=l?l.concat(m):m),null==t?(r(c,n,i),r(f,n,i),P(e.children,n,f,o,s,u,l,h)):d>0&&64&d&&p&&t.dynamicChildren?(B(t.dynamicChildren,p,n,o,s,u,l),(null!=e.key||o&&e===o.subTree)&&Sr(t,e,!0)):G(t,e,n,f,o,s,u,l,h)},j=(t,e,r,n,i,o,s,a,u)=>{e.slotScopeIds=a,null==t?512&e.shapeFlag?i.ctx.activate(e,r,n,s,u):z(e,r,n,i,o,s,u):D(t,e,u)},z=(t,e,r,n,i,o,s)=>{const a=t.component=function(t,e,r){const n=t.type,i=(e?e.appContext:t.appContext)||hn,o={uid:cn++,vnode:t,type:n,parent:e,appContext:i,root:null,next:null,subTree:null,update:null,render:null,proxy:null,exposed:null,withProxy:null,effects:null,provides:e?e.provides:Object.create(i.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:He(n,i),emitsOptions:Ie(n,i),emit:null,emitted:null,propsDefaults:h,ctx:h,data:h,props:h,attrs:h,slots:h,refs:h,setupState:h,setupContext:null,suspense:r,suspenseId:r?r.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null};return o.ctx={_:o},o.root=e?e.root:o,o.emit=Se.bind(null,o),o}(t,n,i);if(cr(t)&&(a.ctx.renderer=ut),function(t,e=!1){mn=e;const{props:r,children:n}=t.vnode,i=pn(t);qe(t,r,i,e),((t,e)=>{if(32&t.vnode.shapeFlag){const r=e._;r?(t.slots=e,V(e,"_",r)):vr(e,t.slots={})}else t.slots={},e&&yr(t,e);V(t.slots,Dr,1)})(t,n);const o=i?function(t,e){const r=t.type;t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,un);const{setup:n}=r;if(n){const r=t.setupContext=n.length>1?function(t){const e=e=>{t.exposed=ee(e)};return{attrs:t.attrs,slots:t.slots,emit:t.emit,expose:e}}(t):null;fn=t,rt();const i=ie(n,t,0,[t.props,r]);if(nt(),fn=null,S(i)){if(e)return i.then((e=>{gn(t,e)})).catch((e=>{se(e,t,0)}));t.asyncDep=i}else gn(t,i)}else vn(t)}(t,e):void 0;mn=!1}(a),a.asyncDep){if(i&&i.registerDep(a,$),!t.el){const t=a.subTree=$r(Tr);A(null,t,e,r)}}else $(a,t,e,r,i,o,s)},D=(t,e,r)=>{const n=e.component=t.component;if(function(t,e,r){const{props:n,children:i,component:o}=t,{props:s,children:a,patchFlag:u}=e,l=o.emitsOptions;if(e.dirs||e.transition)return!0;if(!(r&&u>=0))return!(!i&&!a||a&&a.$stable)||n!==s&&(n?!s||ze(n,s,l):!!s);if(1024&u)return!0;if(16&u)return n?ze(n,s,l):!!s;if(8&u){const t=e.dynamicProps;for(let e=0;ehe&&le.splice(e,1)}(n.update),n.update()}else e.component=t.component,e.el=t.el,n.vnode=e},$=(t,e,r,n,i,o,s)=>{t.update=Z((function(){if(t.isMounted){let e,{next:r,bu:n,u:a,parent:u,vnode:l}=t,h=r;r?(r.el=l.el,H(t,r,s)):r=l,n&&q(n),(e=r.props&&r.props.onVnodeBeforeUpdate)&&xr(e,u,r,l);const c=Fe(t),f=t.subTree;t.subTree=c,_(f,c,p(f.el),st(f),t,i,o),r.el=c.el,null===h&&function({vnode:t,parent:e},r){for(;e&&e.subTree===t;)(t=e.vnode).el=r,e=e.parent}(t,c.el),a&&Mr(a,i),(e=r.props&&r.props.onVnodeUpdated)&&Mr((()=>{xr(e,u,r,l)}),i)}else{let s;const{el:a,props:u}=e,{bm:l,m:h,parent:c}=t;l&&q(l),(s=u&&u.onVnodeBeforeMount)&&xr(s,c,e);const f=t.subTree=Fe(t);if(a&&ht?ht(e.el,f,t,i,null):(_(null,f,r,n,t,i,o),e.el=f.el),h&&Mr(h,i),s=u&&u.onVnodeMounted){const t=e;Mr((()=>{xr(s,c,t)}),i)}const{a:d}=t;d&&256&e.shapeFlag&&Mr(d,i),t.isMounted=!0,e=r=n=null}}),Ar)},H=(t,e,r)=>{e.component=t;const n=t.vnode.props;t.vnode=e,t.next=null,function(t,e,r,n){const{props:i,attrs:o,vnode:{patchFlag:s}}=t,a=Xt(i),[u]=t.propsOptions;if(!(n||s>0)||16&s){let n;Ve(t,e,i,o);for(const o in a)e&&(w(e,o)||(n=U(o))!==o&&w(e,n))||(u?!r||void 0===r[o]&&void 0===r[n]||(i[o]=$e(u,e||h,o,void 0,t)):delete i[o]);if(o!==a)for(const t in o)e&&w(e,t)||delete o[t]}else if(8&s){const r=t.vnode.dynamicProps;for(let n=0;n{const{vnode:n,slots:i}=t;let o=!0,s=h;if(32&n.shapeFlag){const t=e._;t?r&&1===t?o=!1:(v(i,e),r||1!==t||delete i._):(o=!e.$stable,vr(e,i)),s=e}else e&&(yr(t,e),s={default:1});if(o)for(const a in i)pr(a)||a in s||delete i[a]})(t,e.children,r),rt(),Me(void 0,t.update),nt()},G=(t,e,r,n,i,o,s,a,u=!1)=>{const l=t&&t.children,h=t?t.shapeFlag:0,c=e.children,{patchFlag:f,shapeFlag:p}=e;if(f>0){if(128&f)return void J(l,c,r,n,i,o,s,a,u);if(256&f)return void W(l,c,r,n,i,o,s,a,u)}8&p?(16&h&&it(l,i,o),c!==l&&d(r,c)):16&h?16&p?J(l,c,r,n,i,o,s,a,u):it(l,i,o,!0):(8&h&&d(r,""),16&p&&P(c,r,n,i,o,s,a,u))},W=(t,e,r,n,i,o,s,a,u)=>{e=e||c;const l=(t=t||c).length,h=e.length,f=Math.min(l,h);let d;for(d=0;dh?it(t,i,o,!0,!1,f):P(e,r,n,i,o,s,a,u,f)},J=(t,e,r,n,i,o,s,a,u)=>{let l=0;const h=e.length;let f=t.length-1,d=h-1;for(;l<=f&&l<=d;){const n=t[l],h=e[l]=u?Jr(e[l]):Wr(e[l]);if(!zr(n,h))break;_(n,h,r,null,i,o,s,a,u),l++}for(;l<=f&&l<=d;){const n=t[f],l=e[d]=u?Jr(e[d]):Wr(e[d]);if(!zr(n,l))break;_(n,l,r,null,i,o,s,a,u),f--,d--}if(l>f){if(l<=d){const t=d+1,c=td)for(;l<=f;)Q(t[l],i,o,!0),l++;else{const p=l,m=l,g=new Map;for(l=m;l<=d;l++){const t=e[l]=u?Jr(e[l]):Wr(e[l]);null!=t.key&&g.set(t.key,l)}let v,y=0;const b=d-m+1;let w=!1,E=0;const A=new Array(b);for(l=0;l=b){Q(n,i,o,!0);continue}let h;if(null!=n.key)h=g.get(n.key);else for(v=m;v<=d;v++)if(0===A[v-m]&&zr(n,e[v])){h=v;break}void 0===h?Q(n,i,o,!0):(A[h-m]=l+1,h>=E?E=h:w=!0,_(n,e[h],r,null,i,o,s,a,u),y++)}const M=w?function(t){const e=t.slice(),r=[0];let n,i,o,s,a;const u=t.length;for(n=0;n0&&(e[n]=r[o-1]),r[o]=n)}}o=r.length,s=r[o-1];for(;o-- >0;)r[o]=s,s=e[s];return r}(A):c;for(v=M.length-1,l=b-1;l>=0;l--){const t=m+l,c=e[t],f=t+1{const{el:s,type:a,transition:u,children:l,shapeFlag:h}=t;if(6&h)return void K(t.component.subTree,e,n,i);if(128&h)return void t.suspense.move(e,n,i);if(64&h)return void a.move(t,e,n,ut);if(a===Rr){r(s,e,n);for(let t=0;tu.enter(s)),o);else{const{leave:t,delayLeave:i,afterLeave:o}=u,a=()=>r(s,e,n),l=()=>{t(s,(()=>{a(),o&&o()}))};i?i(s,a,l):l()}else r(s,e,n)},Q=(t,e,r,n=!1,i=!1)=>{const{type:o,props:s,ref:a,children:u,dynamicChildren:l,shapeFlag:h,patchFlag:c,dirs:f}=t;if(null!=a&&kr(a,null,r,null),256&h)return void e.ctx.deactivate(t);const d=1&h&&f;let p;if((p=s&&s.onVnodeBeforeUnmount)&&xr(p,e,t),6&h)et(t.component,r,n);else{if(128&h)return void t.suspense.unmount(r,n);d&&br(t,null,e,"beforeUnmount"),64&h?t.type.remove(t,e,r,i,ut,n):l&&(o!==Rr||c>0&&64&c)?it(l,e,r,!1,!0):(o===Rr&&(128&c||256&c)||!i&&16&h)&&it(u,e,r),n&&Y(t)}((p=s&&s.onVnodeUnmounted)||d)&&Mr((()=>{p&&xr(p,e,t),d&&br(t,null,e,"unmounted")}),r)},Y=t=>{const{type:e,el:r,anchor:i,transition:o}=t;if(e===Rr)return void tt(r,i);if(e===Or)return void N(t);const s=()=>{n(r),o&&!o.persisted&&o.afterLeave&&o.afterLeave()};if(1&t.shapeFlag&&o&&!o.persisted){const{leave:e,delayLeave:n}=o,i=()=>e(r,s);n?n(t.el,s,i):i()}else s()},tt=(t,e)=>{let r;for(;t!==e;)r=m(t),n(t),t=r;n(e)},et=(t,e,r)=>{const{bum:n,effects:i,update:o,subTree:s,um:a}=t;if(n&&q(n),i)for(let u=0;u{t.isUnmounted=!0}),e),e&&e.pendingBranch&&!e.isUnmounted&&t.asyncDep&&!t.asyncResolved&&t.suspenseId===e.pendingId&&(e.deps--,0===e.deps&&e.resolve())},it=(t,e,r,n=!1,i=!1,o=0)=>{for(let s=o;s6&t.shapeFlag?st(t.component.subTree):128&t.shapeFlag?t.suspense.next():m(t.anchor||t.el),at=(t,e,r)=>{null==t?e._vnode&&Q(e._vnode,null,null,!0):_(e._vnode||null,t,e,null,null,null,r),ke(),e._vnode=t},ut={p:_,um:Q,m:K,r:Y,mt:z,mc:P,pc:G,pbc:B,n:st,o:t};let lt,ht;e&&([lt,ht]=e(ut));return{render:at,hydrate:lt,createApp:Er(at,lt)}}(t)}function xr(t,e,r,n=null){oe(t,e,7,[r,n])}function Sr(t,e,r=!1){const n=t.children,i=e.children;if(_(n)&&_(i))for(let o=0;onull!=t?t:null,Vr=({ref:t})=>null!=t?k(t)||Qt(t)||M(t)?{i:Oe,r:t}:t:null,$r=function(t,e=null,r=null,i=0,o=null,s=!1){t&&t!==Ir||(t=Tr);if(jr(t)){const n=Hr(t,e,!0);return r&&Kr(n,r),n}u=t,M(u)&&"__vccOpts"in u&&(t=t.__vccOpts);var u;if(e){(Zt(e)||Dr in e)&&(e=v({},e));let{class:t,style:r}=e;t&&!k(t)&&(e.class=a(t)),x(r)&&(Zt(r)&&!_(r)&&(r=v({},r)),e.style=n(r))}const l=k(t)?1:(t=>t.__isSuspense)(t)?128:(t=>t.__isTeleport)(t)?64:x(t)?4:M(t)?2:0,h={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&qr(e),ref:e&&Vr(e),scopeId:Be,slotScopeIds:null,children:null,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:l,patchFlag:i,dynamicProps:o,dynamicChildren:null,appContext:null};if(Kr(h,r),128&l){const{content:t,fallback:e}=function(t){const{shapeFlag:e,children:r}=t;let n,i;return 32&e?(n=De(r.default),i=De(r.fallback)):(n=De(r),i=Wr(null)),{content:n,fallback:i}}(h);h.ssContent=t,h.ssFallback=e}!s&&Cr&&(i>0||6&l)&&32!==i&&Cr.push(h);return h};function Hr(t,e,r=!1){const{props:i,ref:o,patchFlag:s,children:u}=t,l=e?function(...t){const e=v({},t[0]);for(let r=1;r1)return r&&M(e)?e():e}}let Xr=!0;function Qr(t,e,r=[],n=[],i=[],o=!1){const{mixins:s,extends:a,data:u,computed:l,methods:c,watch:d,provide:p,inject:m,components:g,directives:y,beforeMount:b,mounted:w,beforeUpdate:E,updated:A,activated:k,deactivated:N,beforeDestroy:S,beforeUnmount:I,destroyed:R,unmounted:P,render:T,renderTracked:O,renderTriggered:B,errorCaptured:C,expose:F}=e,L=t.proxy,U=t.ctx,j=t.appContext.mixins;if(o&&T&&t.render===f&&(t.render=T),o||(Xr=!1,Yr("beforeCreate","bc",e,t,j),Xr=!0,en(t,j,r,n,i)),a&&Qr(t,a,r,n,i,!0),s&&en(t,s,r,n,i),m)if(_(m))for(let h=0;hrn(t,e,L))),u&&rn(t,u,L)),l)for(const h in l){const t=l[h],e=bn({get:M(t)?t.bind(L,L):M(t.get)?t.get.bind(L,L):f,set:!M(t)&&M(t.set)?t.set.bind(L):f});Object.defineProperty(U,h,{enumerable:!0,configurable:!0,get:()=>e.value,set:t=>e.value=t})}var z;if(d&&n.push(d),!o&&n.length&&n.forEach((t=>{for(const e in t)nn(t[e],U,L,e)})),p&&i.push(p),!o&&i.length&&i.forEach((t=>{const e=M(t)?t.call(L):t;Reflect.ownKeys(e).forEach((t=>{!function(t,e){if(fn){let r=fn.provides;const n=fn.parent&&fn.parent.provides;n===r&&(r=fn.provides=Object.create(n)),r[t]=e}}(t,e[t])}))})),o&&(g&&v(t.components||(t.components=v({},t.type.components)),g),y&&v(t.directives||(t.directives=v({},t.type.directives)),y)),o||Yr("created","c",e,t,j),b&&Qe(b.bind(L)),w&&Ye(w.bind(L)),E&&tr(E.bind(L)),A&&er(A.bind(L)),k&&fr(k.bind(L),"a",z),N&&function(t,e){fr(t,"da",e)}(N.bind(L)),C&&((t,e=fn)=>{Ze("ec",t,e)})(C.bind(L)),O&&or(O.bind(L)),B&&ir(B.bind(L)),I&&rr(I.bind(L)),P&&nr(P.bind(L)),_(F)&&!o)if(F.length){const e=t.exposed||(t.exposed=ee({}));F.forEach((t=>{e[t]=function(t,e){return Qt(t[e])?t[e]:new re(t,e)}(L,t)}))}else t.exposed||(t.exposed=h)}function Yr(t,e,r,n,i){for(let o=0;o{let e=t;for(let t=0;tr[n];if(k(t)){const r=e[t];M(r)&&ar(i,r)}else if(M(t))ar(i,t.bind(r));else if(x(t))if(_(t))t.forEach((t=>nn(t,e,r,n)));else{const n=M(t.handler)?t.handler.bind(r):e[t.handler];M(n)&&ar(i,n,t)}}function on(t,e,r){const n=r.appContext.config.optionMergeStrategies,{mixins:i,extends:o}=e;o&&on(t,o,r),i&&i.forEach((e=>on(t,e,r)));for(const s in e)n&&w(n,s)?t[s]=n[s](t[s],e[s],r.proxy,s):t[s]=e[s]}const sn=t=>t?pn(t)?t.exposed?t.exposed:t.proxy:sn(t.parent):null,an=v(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>sn(t.parent),$root:t=>sn(t.root),$emit:t=>t.emit,$options:t=>function(t){const e=t.type,{__merged:r,mixins:n,extends:i}=e;if(r)return r;const o=t.appContext.mixins;if(!o.length&&!n&&!i)return e;const s={};return o.forEach((e=>on(s,e,t))),on(s,e,t),e.__merged=s}(t),$forceUpdate:t=>()=>_e(t.update),$nextTick:t=>we.bind(t.proxy),$watch:t=>lr.bind(t)}),un={get({_:t},e){const{ctx:r,setupState:n,data:i,props:o,accessCache:s,type:a,appContext:u}=t;if("__v_skip"===e)return!0;let l;if("$"!==e[0]){const a=s[e];if(void 0!==a)switch(a){case 0:return n[e];case 1:return i[e];case 3:return r[e];case 2:return o[e]}else{if(n!==h&&w(n,e))return s[e]=0,n[e];if(i!==h&&w(i,e))return s[e]=1,i[e];if((l=t.propsOptions[0])&&w(l,e))return s[e]=2,o[e];if(r!==h&&w(r,e))return s[e]=3,r[e];Xr&&(s[e]=4)}}const c=an[e];let f,d;return c?("$attrs"===e&&it(t,0,e),c(t)):(f=a.__cssModules)&&(f=f[e])?f:r!==h&&w(r,e)?(s[e]=3,r[e]):(d=u.config.globalProperties,w(d,e)?d[e]:void 0)},set({_:t},e,r){const{data:n,setupState:i,ctx:o}=t;if(i!==h&&w(i,e))i[e]=r;else if(n!==h&&w(n,e))n[e]=r;else if(w(t.props,e))return!1;return("$"!==e[0]||!(e.slice(1)in t))&&(o[e]=r,!0)},has({_:{data:t,setupState:e,accessCache:r,ctx:n,appContext:i,propsOptions:o}},s){let a;return void 0!==r[s]||t!==h&&w(t,s)||e!==h&&w(e,s)||(a=o[0])&&w(a,s)||w(n,s)||w(an,s)||w(i.config.globalProperties,s)}},ln=v({},un,{get(t,e){if(e!==Symbol.unscopables)return un.get(t,e,t)},has:(t,r)=>"_"!==r[0]&&!e(r)}),hn=wr();let cn=0;let fn=null;const dn=t=>{fn=t};function pn(t){return 4&t.vnode.shapeFlag}let mn=!1;function gn(t,e,r){M(e)?t.render=e:x(e)&&(t.setupState=ee(e)),vn(t)}function vn(t,e){const r=t.type;t.render||(t.render=r.render||f,t.render._rc&&(t.withProxy=new Proxy(t.ctx,ln))),fn=t,rt(),Qr(t,r),nt(),fn=null}function yn(t,e=fn){e&&(e.effects||(e.effects=[])).push(t)}function bn(t){const e=function(t){let e,r;return M(t)?(e=t,r=f):(e=t.get,r=t.set),new ne(e,r,M(t)||!t.set)}(t);return yn(e.effect),e}const wn="3.0.11",_n="http://www.w3.org/2000/svg",En="undefined"!=typeof document?document:null;let An,Mn;const kn={insert:(t,e,r)=>{e.insertBefore(t,r||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,r,n)=>{const i=e?En.createElementNS(_n,t):En.createElement(t,r?{is:r}:void 0);return"select"===t&&n&&null!=n.multiple&&i.setAttribute("multiple",n.multiple),i},createText:t=>En.createTextNode(t),createComment:t=>En.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>En.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},cloneNode(t){const e=t.cloneNode(!0);return"_value"in t&&(e._value=t._value),e},insertStaticContent(t,e,r,n){const i=n?Mn||(Mn=En.createElementNS(_n,"svg")):An||(An=En.createElement("div"));i.innerHTML=t;const o=i.firstChild;let s=o,a=s;for(;s;)a=s,kn.insert(s,e,r),s=i.firstChild;return[o,a]}};const Nn=/\s*!important$/;function xn(t,e,r){if(_(r))r.forEach((r=>xn(t,e,r)));else if(e.startsWith("--"))t.setProperty(e,r);else{const n=function(t,e){const r=In[e];if(r)return r;let n=F(e);if("filter"!==n&&n in t)return In[e]=n;n=j(n);for(let i=0;idocument.createEvent("Event").timeStamp&&(Pn=()=>performance.now());const t=navigator.userAgent.match(/firefox\/(\d+)/i);Tn=!!(t&&Number(t[1])<=53)}let On=0;const Bn=Promise.resolve(),Cn=()=>{On=0};function Fn(t,e,r,n,i=null){const o=t._vei||(t._vei={}),s=o[e];if(n&&s)s.value=n;else{const[r,a]=function(t){let e;if(Ln.test(t)){let r;for(e={};r=t.match(Ln);)t=t.slice(0,t.length-r[0].length),e[r[0].toLowerCase()]=!0}return[U(t.slice(2)),e]}(e);if(n){!function(t,e,r,n){t.addEventListener(e,r,n)}(t,r,o[e]=function(t,e){const r=t=>{const n=t.timeStamp||Pn();(Tn||n>=r.attached-1)&&oe(function(t,e){if(_(e)){const r=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{r.call(t),t._stopped=!0},e.map((t=>e=>!e._stopped&&t(e)))}return e}(t,r.value),e,5,[t])};return r.value=t,r.attached=(()=>On||(Bn.then(Cn),On=Pn()))(),r}(n,i),a)}else s&&(!function(t,e,r,n){t.removeEventListener(e,r,n)}(t,r,s,a),o[e]=void 0)}}const Ln=/(?:Once|Passive|Capture)$/;const Un=/^on[a-z]/;const jn=v({patchProp:(t,e,n,i,o=!1,s,a,u,l)=>{switch(e){case"class":!function(t,e,r){if(null==e&&(e=""),r)t.setAttribute("class",e);else{const r=t._vtc;r&&(e=(e?[e,...r]:[...r]).join(" ")),t.className=e}}(t,i,o);break;case"style":!function(t,e,r){const n=t.style;if(r)if(k(r)){if(e!==r){const e=n.display;n.cssText=r,"_vod"in t&&(n.display=e)}}else{for(const t in r)xn(n,t,r[t]);if(e&&!k(e))for(const t in e)null==r[t]&&xn(n,t,"")}else t.removeAttribute("style")}(t,n,i);break;default:m(e)?g(e)||Fn(t,e,0,i,a):function(t,e,r,n){if(n)return"innerHTML"===e||!!(e in t&&Un.test(e)&&M(r));if("spellcheck"===e||"draggable"===e)return!1;if("form"===e)return!1;if("list"===e&&"INPUT"===t.tagName)return!1;if("type"===e&&"TEXTAREA"===t.tagName)return!1;if(Un.test(e)&&k(r))return!1;return e in t}(t,e,i,o)?function(t,e,r,n,i,o,s){if("innerHTML"===e||"textContent"===e)return n&&s(n,i,o),void(t[e]=null==r?"":r);if("value"!==e||"PROGRESS"===t.tagName){if(""===r||null==r){const n=typeof t[e];if(""===r&&"boolean"===n)return void(t[e]=!0);if(null==r&&"string"===n)return t[e]="",void t.removeAttribute(e);if("number"===n)return t[e]=0,void t.removeAttribute(e)}try{t[e]=r}catch(a){}}else{t._value=r;const e=null==r?"":r;t.value!==e&&(t.value=e)}}(t,e,i,s,a,u,l):("true-value"===e?t._trueValue=i:"false-value"===e&&(t._falseValue=i),function(t,e,n,i){if(i&&e.startsWith("xlink:"))null==n?t.removeAttributeNS(Rn,e.slice(6,e.length)):t.setAttributeNS(Rn,e,n);else{const i=r(e);null==n||i&&!1===n?t.removeAttribute(e):t.setAttribute(e,i?"":n)}}(t,e,i,o))}},forcePatchProp:(t,e)=>"value"===e},kn);let zn;const Dn=(...t)=>{const e=(zn||(zn=Nr(jn))).createApp(...t),{mount:r}=e;return e.mount=t=>{const n=function(t){if(k(t)){return document.querySelector(t)}return t}(t);if(!n)return;const i=e._component;M(i)||i.render||i.template||(i.template=n.innerHTML),n.innerHTML="";const o=r(n,!1,n instanceof SVGElement);return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),o},e};var qn="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Vn(t){if(t.__esModule)return t;var e=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(t).forEach((function(r){var n=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,n.get?n:{enumerable:!0,get:function(){return t[r]}})})),e}function $n(t){var e={exports:{}};return t(e,e.exports),e.exports}var Hn=Vn(Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",default:{}})),Gn=$n((function(t){!function(t,e){function r(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function i(t,e,r){if(i.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var o;"object"==typeof t?t.exports=i:e.BN=i,i.BN=i,i.wordSize=26;try{o="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:Hn.Buffer}catch(M){}function s(t,e){var r=t.charCodeAt(e);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function a(t,e,r){var n=s(t,r);return r-1>=e&&(n|=s(t,r-1)<<4),n}function u(t,e,r,n){for(var i=0,o=Math.min(t.length,r),s=e;s=49?a-49+10:a>=17?a-17+10:a}return i}i.isBN=function(t){return t instanceof i||null!==t&&"object"==typeof t&&t.constructor.wordSize===i.wordSize&&Array.isArray(t.words)},i.max=function(t,e){return t.cmp(e)>0?t:e},i.min=function(t,e){return t.cmp(e)<0?t:e},i.prototype._init=function(t,e,n){if("number"==typeof t)return this._initNumber(t,e,n);if("object"==typeof t)return this._initArray(t,e,n);"hex"===e&&(e=16),r(e===(0|e)&&e>=2&&e<=36);var i=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)s=t[i]|t[i-1]<<8|t[i-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===n)for(i=0,o=0;i>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},i.prototype._parseHex=function(t,e,r){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var n=0;n=e;n-=2)i=a(t,e,n)<=18?(o-=18,s+=1,this.words[s]|=i>>>26):o+=8;else for(n=(t.length-e)%2==0?e+1:e;n=18?(o-=18,s+=1,this.words[s]|=i>>>26):o+=8;this.strip()},i.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=e)n++;n--,i=i/e|0;for(var o=t.length-r,s=o%n,a=Math.min(o,o-s)+r,l=0,h=r;h1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var l=["","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"],h=[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],c=[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];function f(t,e,r){r.negative=e.negative^t.negative;var n=t.length+e.length|0;r.length=n,n=n-1|0;var i=0|t.words[0],o=0|e.words[0],s=i*o,a=67108863&s,u=s/67108864|0;r.words[0]=a;for(var l=1;l>>26,c=67108863&u,f=Math.min(l,e.length-1),d=Math.max(0,l-t.length+1);d<=f;d++){var p=l-d|0;h+=(s=(i=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&s}r.words[l]=0|c,u=0|h}return 0!==u?r.words[l]=0|u:r.length--,r.strip()}i.prototype.toString=function(t,e){var n;if(e=0|e||1,16===(t=t||10)||"hex"===t){n="";for(var i=0,o=0,s=0;s>>24-i&16777215)||s!==this.length-1?l[6-u.length]+u+n:u+n,(i+=2)>=26&&(i-=26,s--)}for(0!==o&&(n=o.toString(16)+n);n.length%e!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}if(t===(0|t)&&t>=2&&t<=36){var f=h[t],d=c[t];n="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);n=(p=p.idivn(d)).isZero()?m+n:l[f-m.length]+m+n}for(this.isZero()&&(n="0"+n);n.length%e!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}r(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(t,e){return r(void 0!==o),this.toArrayLike(o,t,e)},i.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},i.prototype.toArrayLike=function(t,e,n){var i=this.byteLength(),o=n||Math.max(1,i);r(i<=o,"byte array longer than desired length"),r(o>0,"Requested array length <= 0"),this.strip();var s,a,u="le"===e,l=new t(o),h=this.clone();if(u){for(a=0;!h.isZero();a++)s=h.andln(255),h.iushrn(8),l[a]=s;for(;a=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},i.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0==(8191&e)&&(r+=13,e>>>=13),0==(127&e)&&(r+=7,e>>>=7),0==(15&e)&&(r+=4,e>>>=4),0==(3&e)&&(r+=2,e>>>=2),0==(1&e)&&r++,r},i.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},i.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},i.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},i.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},i.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var n=0;nt.length?this.clone().ixor(t):t.clone().ixor(this)},i.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},i.prototype.inotn=function(t){r("number"==typeof t&&t>=0);var e=0|Math.ceil(t/26),n=t%26;this._expand(e),n>0&&e--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-n),this.strip()},i.prototype.notn=function(t){return this.clone().inotn(t)},i.prototype.setn=function(t,e){r("number"==typeof t&&t>=0);var n=t/26|0,i=t%26;return this._expand(n+1),this.words[n]=e?this.words[n]|1<t.length?(r=this,n=t):(r=t,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},i.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,n,i=this.cmp(t);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=t):(r=t,n=this);for(var o=0,s=0;s>26,this.words[s]=67108863&e;for(;0!==o&&s>26,this.words[s]=67108863&e;if(0===o&&s>>13,d=0|s[1],p=8191&d,m=d>>>13,g=0|s[2],v=8191&g,y=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,E=0|s[4],A=8191&E,M=E>>>13,k=0|s[5],N=8191&k,x=k>>>13,S=0|s[6],I=8191&S,R=S>>>13,P=0|s[7],T=8191&P,O=P>>>13,B=0|s[8],C=8191&B,F=B>>>13,L=0|s[9],U=8191&L,j=L>>>13,z=0|a[0],D=8191&z,q=z>>>13,V=0|a[1],$=8191&V,H=V>>>13,G=0|a[2],W=8191&G,J=G>>>13,K=0|a[3],Z=8191&K,X=K>>>13,Q=0|a[4],Y=8191&Q,tt=Q>>>13,et=0|a[5],rt=8191&et,nt=et>>>13,it=0|a[6],ot=8191&it,st=it>>>13,at=0|a[7],ut=8191&at,lt=at>>>13,ht=0|a[8],ct=8191&ht,ft=ht>>>13,dt=0|a[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(l+(n=Math.imul(c,D))|0)+((8191&(i=(i=Math.imul(c,q))+Math.imul(f,D)|0))<<13)|0;l=((o=Math.imul(f,q))+(i>>>13)|0)+(gt>>>26)|0,gt&=67108863,n=Math.imul(p,D),i=(i=Math.imul(p,q))+Math.imul(m,D)|0,o=Math.imul(m,q);var vt=(l+(n=n+Math.imul(c,$)|0)|0)+((8191&(i=(i=i+Math.imul(c,H)|0)+Math.imul(f,$)|0))<<13)|0;l=((o=o+Math.imul(f,H)|0)+(i>>>13)|0)+(vt>>>26)|0,vt&=67108863,n=Math.imul(v,D),i=(i=Math.imul(v,q))+Math.imul(y,D)|0,o=Math.imul(y,q),n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,H)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,H)|0;var yt=(l+(n=n+Math.imul(c,W)|0)|0)+((8191&(i=(i=i+Math.imul(c,J)|0)+Math.imul(f,W)|0))<<13)|0;l=((o=o+Math.imul(f,J)|0)+(i>>>13)|0)+(yt>>>26)|0,yt&=67108863,n=Math.imul(w,D),i=(i=Math.imul(w,q))+Math.imul(_,D)|0,o=Math.imul(_,q),n=n+Math.imul(v,$)|0,i=(i=i+Math.imul(v,H)|0)+Math.imul(y,$)|0,o=o+Math.imul(y,H)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var bt=(l+(n=n+Math.imul(c,Z)|0)|0)+((8191&(i=(i=i+Math.imul(c,X)|0)+Math.imul(f,Z)|0))<<13)|0;l=((o=o+Math.imul(f,X)|0)+(i>>>13)|0)+(bt>>>26)|0,bt&=67108863,n=Math.imul(A,D),i=(i=Math.imul(A,q))+Math.imul(M,D)|0,o=Math.imul(M,q),n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,H)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,H)|0,n=n+Math.imul(v,W)|0,i=(i=i+Math.imul(v,J)|0)+Math.imul(y,W)|0,o=o+Math.imul(y,J)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,X)|0;var wt=(l+(n=n+Math.imul(c,Y)|0)|0)+((8191&(i=(i=i+Math.imul(c,tt)|0)+Math.imul(f,Y)|0))<<13)|0;l=((o=o+Math.imul(f,tt)|0)+(i>>>13)|0)+(wt>>>26)|0,wt&=67108863,n=Math.imul(N,D),i=(i=Math.imul(N,q))+Math.imul(x,D)|0,o=Math.imul(x,q),n=n+Math.imul(A,$)|0,i=(i=i+Math.imul(A,H)|0)+Math.imul(M,$)|0,o=o+Math.imul(M,H)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,n=n+Math.imul(v,Z)|0,i=(i=i+Math.imul(v,X)|0)+Math.imul(y,Z)|0,o=o+Math.imul(y,X)|0,n=n+Math.imul(p,Y)|0,i=(i=i+Math.imul(p,tt)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,tt)|0;var _t=(l+(n=n+Math.imul(c,rt)|0)|0)+((8191&(i=(i=i+Math.imul(c,nt)|0)+Math.imul(f,rt)|0))<<13)|0;l=((o=o+Math.imul(f,nt)|0)+(i>>>13)|0)+(_t>>>26)|0,_t&=67108863,n=Math.imul(I,D),i=(i=Math.imul(I,q))+Math.imul(R,D)|0,o=Math.imul(R,q),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,H)|0)+Math.imul(x,$)|0,o=o+Math.imul(x,H)|0,n=n+Math.imul(A,W)|0,i=(i=i+Math.imul(A,J)|0)+Math.imul(M,W)|0,o=o+Math.imul(M,J)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,X)|0,n=n+Math.imul(v,Y)|0,i=(i=i+Math.imul(v,tt)|0)+Math.imul(y,Y)|0,o=o+Math.imul(y,tt)|0,n=n+Math.imul(p,rt)|0,i=(i=i+Math.imul(p,nt)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,nt)|0;var Et=(l+(n=n+Math.imul(c,ot)|0)|0)+((8191&(i=(i=i+Math.imul(c,st)|0)+Math.imul(f,ot)|0))<<13)|0;l=((o=o+Math.imul(f,st)|0)+(i>>>13)|0)+(Et>>>26)|0,Et&=67108863,n=Math.imul(T,D),i=(i=Math.imul(T,q))+Math.imul(O,D)|0,o=Math.imul(O,q),n=n+Math.imul(I,$)|0,i=(i=i+Math.imul(I,H)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,H)|0,n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,J)|0)+Math.imul(x,W)|0,o=o+Math.imul(x,J)|0,n=n+Math.imul(A,Z)|0,i=(i=i+Math.imul(A,X)|0)+Math.imul(M,Z)|0,o=o+Math.imul(M,X)|0,n=n+Math.imul(w,Y)|0,i=(i=i+Math.imul(w,tt)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,tt)|0,n=n+Math.imul(v,rt)|0,i=(i=i+Math.imul(v,nt)|0)+Math.imul(y,rt)|0,o=o+Math.imul(y,nt)|0,n=n+Math.imul(p,ot)|0,i=(i=i+Math.imul(p,st)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,st)|0;var At=(l+(n=n+Math.imul(c,ut)|0)|0)+((8191&(i=(i=i+Math.imul(c,lt)|0)+Math.imul(f,ut)|0))<<13)|0;l=((o=o+Math.imul(f,lt)|0)+(i>>>13)|0)+(At>>>26)|0,At&=67108863,n=Math.imul(C,D),i=(i=Math.imul(C,q))+Math.imul(F,D)|0,o=Math.imul(F,q),n=n+Math.imul(T,$)|0,i=(i=i+Math.imul(T,H)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,H)|0,n=n+Math.imul(I,W)|0,i=(i=i+Math.imul(I,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,n=n+Math.imul(N,Z)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(x,Z)|0,o=o+Math.imul(x,X)|0,n=n+Math.imul(A,Y)|0,i=(i=i+Math.imul(A,tt)|0)+Math.imul(M,Y)|0,o=o+Math.imul(M,tt)|0,n=n+Math.imul(w,rt)|0,i=(i=i+Math.imul(w,nt)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,nt)|0,n=n+Math.imul(v,ot)|0,i=(i=i+Math.imul(v,st)|0)+Math.imul(y,ot)|0,o=o+Math.imul(y,st)|0,n=n+Math.imul(p,ut)|0,i=(i=i+Math.imul(p,lt)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,lt)|0;var Mt=(l+(n=n+Math.imul(c,ct)|0)|0)+((8191&(i=(i=i+Math.imul(c,ft)|0)+Math.imul(f,ct)|0))<<13)|0;l=((o=o+Math.imul(f,ft)|0)+(i>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,n=Math.imul(U,D),i=(i=Math.imul(U,q))+Math.imul(j,D)|0,o=Math.imul(j,q),n=n+Math.imul(C,$)|0,i=(i=i+Math.imul(C,H)|0)+Math.imul(F,$)|0,o=o+Math.imul(F,H)|0,n=n+Math.imul(T,W)|0,i=(i=i+Math.imul(T,J)|0)+Math.imul(O,W)|0,o=o+Math.imul(O,J)|0,n=n+Math.imul(I,Z)|0,i=(i=i+Math.imul(I,X)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,X)|0,n=n+Math.imul(N,Y)|0,i=(i=i+Math.imul(N,tt)|0)+Math.imul(x,Y)|0,o=o+Math.imul(x,tt)|0,n=n+Math.imul(A,rt)|0,i=(i=i+Math.imul(A,nt)|0)+Math.imul(M,rt)|0,o=o+Math.imul(M,nt)|0,n=n+Math.imul(w,ot)|0,i=(i=i+Math.imul(w,st)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,st)|0,n=n+Math.imul(v,ut)|0,i=(i=i+Math.imul(v,lt)|0)+Math.imul(y,ut)|0,o=o+Math.imul(y,lt)|0,n=n+Math.imul(p,ct)|0,i=(i=i+Math.imul(p,ft)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,ft)|0;var kt=(l+(n=n+Math.imul(c,pt)|0)|0)+((8191&(i=(i=i+Math.imul(c,mt)|0)+Math.imul(f,pt)|0))<<13)|0;l=((o=o+Math.imul(f,mt)|0)+(i>>>13)|0)+(kt>>>26)|0,kt&=67108863,n=Math.imul(U,$),i=(i=Math.imul(U,H))+Math.imul(j,$)|0,o=Math.imul(j,H),n=n+Math.imul(C,W)|0,i=(i=i+Math.imul(C,J)|0)+Math.imul(F,W)|0,o=o+Math.imul(F,J)|0,n=n+Math.imul(T,Z)|0,i=(i=i+Math.imul(T,X)|0)+Math.imul(O,Z)|0,o=o+Math.imul(O,X)|0,n=n+Math.imul(I,Y)|0,i=(i=i+Math.imul(I,tt)|0)+Math.imul(R,Y)|0,o=o+Math.imul(R,tt)|0,n=n+Math.imul(N,rt)|0,i=(i=i+Math.imul(N,nt)|0)+Math.imul(x,rt)|0,o=o+Math.imul(x,nt)|0,n=n+Math.imul(A,ot)|0,i=(i=i+Math.imul(A,st)|0)+Math.imul(M,ot)|0,o=o+Math.imul(M,st)|0,n=n+Math.imul(w,ut)|0,i=(i=i+Math.imul(w,lt)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,lt)|0,n=n+Math.imul(v,ct)|0,i=(i=i+Math.imul(v,ft)|0)+Math.imul(y,ct)|0,o=o+Math.imul(y,ft)|0;var Nt=(l+(n=n+Math.imul(p,pt)|0)|0)+((8191&(i=(i=i+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;l=((o=o+Math.imul(m,mt)|0)+(i>>>13)|0)+(Nt>>>26)|0,Nt&=67108863,n=Math.imul(U,W),i=(i=Math.imul(U,J))+Math.imul(j,W)|0,o=Math.imul(j,J),n=n+Math.imul(C,Z)|0,i=(i=i+Math.imul(C,X)|0)+Math.imul(F,Z)|0,o=o+Math.imul(F,X)|0,n=n+Math.imul(T,Y)|0,i=(i=i+Math.imul(T,tt)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,tt)|0,n=n+Math.imul(I,rt)|0,i=(i=i+Math.imul(I,nt)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,nt)|0,n=n+Math.imul(N,ot)|0,i=(i=i+Math.imul(N,st)|0)+Math.imul(x,ot)|0,o=o+Math.imul(x,st)|0,n=n+Math.imul(A,ut)|0,i=(i=i+Math.imul(A,lt)|0)+Math.imul(M,ut)|0,o=o+Math.imul(M,lt)|0,n=n+Math.imul(w,ct)|0,i=(i=i+Math.imul(w,ft)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,ft)|0;var xt=(l+(n=n+Math.imul(v,pt)|0)|0)+((8191&(i=(i=i+Math.imul(v,mt)|0)+Math.imul(y,pt)|0))<<13)|0;l=((o=o+Math.imul(y,mt)|0)+(i>>>13)|0)+(xt>>>26)|0,xt&=67108863,n=Math.imul(U,Z),i=(i=Math.imul(U,X))+Math.imul(j,Z)|0,o=Math.imul(j,X),n=n+Math.imul(C,Y)|0,i=(i=i+Math.imul(C,tt)|0)+Math.imul(F,Y)|0,o=o+Math.imul(F,tt)|0,n=n+Math.imul(T,rt)|0,i=(i=i+Math.imul(T,nt)|0)+Math.imul(O,rt)|0,o=o+Math.imul(O,nt)|0,n=n+Math.imul(I,ot)|0,i=(i=i+Math.imul(I,st)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,st)|0,n=n+Math.imul(N,ut)|0,i=(i=i+Math.imul(N,lt)|0)+Math.imul(x,ut)|0,o=o+Math.imul(x,lt)|0,n=n+Math.imul(A,ct)|0,i=(i=i+Math.imul(A,ft)|0)+Math.imul(M,ct)|0,o=o+Math.imul(M,ft)|0;var St=(l+(n=n+Math.imul(w,pt)|0)|0)+((8191&(i=(i=i+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;l=((o=o+Math.imul(_,mt)|0)+(i>>>13)|0)+(St>>>26)|0,St&=67108863,n=Math.imul(U,Y),i=(i=Math.imul(U,tt))+Math.imul(j,Y)|0,o=Math.imul(j,tt),n=n+Math.imul(C,rt)|0,i=(i=i+Math.imul(C,nt)|0)+Math.imul(F,rt)|0,o=o+Math.imul(F,nt)|0,n=n+Math.imul(T,ot)|0,i=(i=i+Math.imul(T,st)|0)+Math.imul(O,ot)|0,o=o+Math.imul(O,st)|0,n=n+Math.imul(I,ut)|0,i=(i=i+Math.imul(I,lt)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,lt)|0,n=n+Math.imul(N,ct)|0,i=(i=i+Math.imul(N,ft)|0)+Math.imul(x,ct)|0,o=o+Math.imul(x,ft)|0;var It=(l+(n=n+Math.imul(A,pt)|0)|0)+((8191&(i=(i=i+Math.imul(A,mt)|0)+Math.imul(M,pt)|0))<<13)|0;l=((o=o+Math.imul(M,mt)|0)+(i>>>13)|0)+(It>>>26)|0,It&=67108863,n=Math.imul(U,rt),i=(i=Math.imul(U,nt))+Math.imul(j,rt)|0,o=Math.imul(j,nt),n=n+Math.imul(C,ot)|0,i=(i=i+Math.imul(C,st)|0)+Math.imul(F,ot)|0,o=o+Math.imul(F,st)|0,n=n+Math.imul(T,ut)|0,i=(i=i+Math.imul(T,lt)|0)+Math.imul(O,ut)|0,o=o+Math.imul(O,lt)|0,n=n+Math.imul(I,ct)|0,i=(i=i+Math.imul(I,ft)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,ft)|0;var Rt=(l+(n=n+Math.imul(N,pt)|0)|0)+((8191&(i=(i=i+Math.imul(N,mt)|0)+Math.imul(x,pt)|0))<<13)|0;l=((o=o+Math.imul(x,mt)|0)+(i>>>13)|0)+(Rt>>>26)|0,Rt&=67108863,n=Math.imul(U,ot),i=(i=Math.imul(U,st))+Math.imul(j,ot)|0,o=Math.imul(j,st),n=n+Math.imul(C,ut)|0,i=(i=i+Math.imul(C,lt)|0)+Math.imul(F,ut)|0,o=o+Math.imul(F,lt)|0,n=n+Math.imul(T,ct)|0,i=(i=i+Math.imul(T,ft)|0)+Math.imul(O,ct)|0,o=o+Math.imul(O,ft)|0;var Pt=(l+(n=n+Math.imul(I,pt)|0)|0)+((8191&(i=(i=i+Math.imul(I,mt)|0)+Math.imul(R,pt)|0))<<13)|0;l=((o=o+Math.imul(R,mt)|0)+(i>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,n=Math.imul(U,ut),i=(i=Math.imul(U,lt))+Math.imul(j,ut)|0,o=Math.imul(j,lt),n=n+Math.imul(C,ct)|0,i=(i=i+Math.imul(C,ft)|0)+Math.imul(F,ct)|0,o=o+Math.imul(F,ft)|0;var Tt=(l+(n=n+Math.imul(T,pt)|0)|0)+((8191&(i=(i=i+Math.imul(T,mt)|0)+Math.imul(O,pt)|0))<<13)|0;l=((o=o+Math.imul(O,mt)|0)+(i>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,n=Math.imul(U,ct),i=(i=Math.imul(U,ft))+Math.imul(j,ct)|0,o=Math.imul(j,ft);var Ot=(l+(n=n+Math.imul(C,pt)|0)|0)+((8191&(i=(i=i+Math.imul(C,mt)|0)+Math.imul(F,pt)|0))<<13)|0;l=((o=o+Math.imul(F,mt)|0)+(i>>>13)|0)+(Ot>>>26)|0,Ot&=67108863;var Bt=(l+(n=Math.imul(U,pt))|0)+((8191&(i=(i=Math.imul(U,mt))+Math.imul(j,pt)|0))<<13)|0;return l=((o=Math.imul(j,mt))+(i>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,u[0]=gt,u[1]=vt,u[2]=yt,u[3]=bt,u[4]=wt,u[5]=_t,u[6]=Et,u[7]=At,u[8]=Mt,u[9]=kt,u[10]=Nt,u[11]=xt,u[12]=St,u[13]=It,u[14]=Rt,u[15]=Pt,u[16]=Tt,u[17]=Ot,u[18]=Bt,0!==l&&(u[19]=l,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=f),i.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?f(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,n=s,s=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=i.prototype._countBits(t)-1,n=0;n>=1;return n},m.prototype.permute=function(t,e,r,n,i,o){for(var s=0;s>>=1)i++;return 1<>>=13,n[2*s+1]=8191&o,o>>>=13;for(s=2*e;s>=26,e+=i/67108864|0,e+=o>>>26,this.words[n]=67108863&o}return 0!==e&&(this.words[n]=e,this.length++),this},i.prototype.muln=function(t){return this.clone().imuln(t)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>i}return e}(t);if(0===e.length)return new i(1);for(var r=this,n=0;n=0);var e,n=t%26,i=(t-n)/26,o=67108863>>>26-n<<26-n;if(0!==n){var s=0;for(e=0;e>>26-n}s&&(this.words[e]=s,this.length++)}if(0!==i){for(e=this.length-1;e>=0;e--)this.words[e+i]=this.words[e];for(e=0;e=0),i=e?(e-e%26)/26:0;var o=t%26,s=Math.min((t-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,l=0;l=0&&(0!==h||l>=i);l--){var c=0|this.words[l];this.words[l]=h<<26-o|c>>>o,h=c&a}return u&&0!==h&&(u.words[u.length++]=h),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(t,e,n){return r(0===this.negative),this.iushrn(t,e,n)},i.prototype.shln=function(t){return this.clone().ishln(t)},i.prototype.ushln=function(t){return this.clone().iushln(t)},i.prototype.shrn=function(t){return this.clone().ishrn(t)},i.prototype.ushrn=function(t){return this.clone().iushrn(t)},i.prototype.testn=function(t){r("number"==typeof t&&t>=0);var e=t%26,n=(t-e)/26,i=1<=0);var e=t%26,n=(t-e)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=n)return this;if(0!==e&&n++,this.length=Math.min(n,this.length),0!==e){var i=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},i.prototype.isubn=function(t){if(r("number"==typeof t),r(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[i+n]=67108863&o}for(;i>26,this.words[i+n]=67108863&o;if(0===a)return this.strip();for(r(-1===a),a=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},i.prototype._wordDiv=function(t,e){var r=(this.length,t.length),n=this.clone(),o=t,s=0|o.words[o.length-1];0!==(r=26-this._countBits(s))&&(o=o.ushln(r),n.iushln(r),s=0|o.words[o.length-1]);var a,u=n.length-o.length;if("mod"!==e){(a=new i(null)).length=u+1,a.words=new Array(a.length);for(var l=0;l=0;c--){var f=67108864*(0|n.words[o.length+c])+(0|n.words[o.length+c-1]);for(f=Math.min(f/s|0,67108863),n._ishlnsubmul(o,f,c);0!==n.negative;)f--,n.negative=0,n._ishlnsubmul(o,1,c),n.isZero()||(n.negative^=1);a&&(a.words[c]=f)}return a&&a.strip(),n.strip(),"div"!==e&&0!==r&&n.iushrn(r),{div:a||null,mod:n}},i.prototype.divmod=function(t,e,n){return r(!t.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===t.negative?(a=this.neg().divmod(t,e),"mod"!==e&&(o=a.div.neg()),"div"!==e&&(s=a.mod.neg(),n&&0!==s.negative&&s.iadd(t)),{div:o,mod:s}):0===this.negative&&0!==t.negative?(a=this.divmod(t.neg(),e),"mod"!==e&&(o=a.div.neg()),{div:o,mod:a.mod}):0!=(this.negative&t.negative)?(a=this.neg().divmod(t.neg(),e),"div"!==e&&(s=a.mod.neg(),n&&0!==s.negative&&s.isub(t)),{div:a.div,mod:s}):t.length>this.length||this.cmp(t)<0?{div:new i(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new i(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new i(this.modn(t.words[0]))}:this._wordDiv(t,e);var o,s,a},i.prototype.div=function(t){return this.divmod(t,"div",!1).div},i.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},i.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},i.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,n=t.ushrn(1),i=t.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},i.prototype.modn=function(t){r(t<=67108863);for(var e=(1<<26)%t,n=0,i=this.length-1;i>=0;i--)n=(e*n+(0|this.words[i]))%t;return n},i.prototype.idivn=function(t){r(t<=67108863);for(var e=0,n=this.length-1;n>=0;n--){var i=(0|this.words[n])+67108864*e;this.words[n]=i/t|0,e=i%t}return this.strip()},i.prototype.divn=function(t){return this.clone().idivn(t)},i.prototype.egcd=function(t){r(0===t.negative),r(!t.isZero());var e=this,n=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var o=new i(1),s=new i(0),a=new i(0),u=new i(1),l=0;e.isEven()&&n.isEven();)e.iushrn(1),n.iushrn(1),++l;for(var h=n.clone(),c=e.clone();!e.isZero();){for(var f=0,d=1;0==(e.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(e.iushrn(f);f-- >0;)(o.isOdd()||s.isOdd())&&(o.iadd(h),s.isub(c)),o.iushrn(1),s.iushrn(1);for(var p=0,m=1;0==(n.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(n.iushrn(p);p-- >0;)(a.isOdd()||u.isOdd())&&(a.iadd(h),u.isub(c)),a.iushrn(1),u.iushrn(1);e.cmp(n)>=0?(e.isub(n),o.isub(a),s.isub(u)):(n.isub(e),a.isub(o),u.isub(s))}return{a:a,b:u,gcd:n.iushln(l)}},i.prototype._invmp=function(t){r(0===t.negative),r(!t.isZero());var e=this,n=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var o,s=new i(1),a=new i(0),u=n.clone();e.cmpn(1)>0&&n.cmpn(1)>0;){for(var l=0,h=1;0==(e.words[0]&h)&&l<26;++l,h<<=1);if(l>0)for(e.iushrn(l);l-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);for(var c=0,f=1;0==(n.words[0]&f)&&c<26;++c,f<<=1);if(c>0)for(n.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);e.cmp(n)>=0?(e.isub(n),s.isub(a)):(n.isub(e),a.isub(s))}return(o=0===e.cmpn(1)?s:a).cmpn(0)<0&&o.iadd(t),o},i.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var n=0;e.isEven()&&r.isEven();n++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=e.cmp(r);if(i<0){var o=e;e=r,r=o}else if(0===i||0===r.cmpn(1))break;e.isub(r)}return r.iushln(n)},i.prototype.invm=function(t){return this.egcd(t).a.umod(t)},i.prototype.isEven=function(){return 0==(1&this.words[0])},i.prototype.isOdd=function(){return 1==(1&this.words[0])},i.prototype.andln=function(t){return this.words[0]&t},i.prototype.bincn=function(t){r("number"==typeof t);var e=t%26,n=(t-e)/26,i=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(t){var e,n=t<0;if(0!==this.negative&&!n)return-1;if(0===this.negative&&n)return 1;if(this.strip(),this.length>1)e=1;else{n&&(t=-t),r(t<=67108863,"Number is too big");var i=0|this.words[0];e=i===t?0:it.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|t.words[r];if(n!==i){ni&&(e=1);break}}return e},i.prototype.gtn=function(t){return 1===this.cmpn(t)},i.prototype.gt=function(t){return 1===this.cmp(t)},i.prototype.gten=function(t){return this.cmpn(t)>=0},i.prototype.gte=function(t){return this.cmp(t)>=0},i.prototype.ltn=function(t){return-1===this.cmpn(t)},i.prototype.lt=function(t){return-1===this.cmp(t)},i.prototype.lten=function(t){return this.cmpn(t)<=0},i.prototype.lte=function(t){return this.cmp(t)<=0},i.prototype.eqn=function(t){return 0===this.cmpn(t)},i.prototype.eq=function(t){return 0===this.cmp(t)},i.red=function(t){return new E(t)},i.prototype.toRed=function(t){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},i.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(t){return this.red=t,this},i.prototype.forceRed=function(t){return r(!this.red,"Already a number in reduction context"),this._forceRed(t)},i.prototype.redAdd=function(t){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},i.prototype.redIAdd=function(t){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},i.prototype.redSub=function(t){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},i.prototype.redISub=function(t){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},i.prototype.redShl=function(t){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},i.prototype.redMul=function(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},i.prototype.redIMul=function(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},i.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(t){return r(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function v(t,e){this.name=t,this.p=new i(e,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function y(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function b(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(t){if("string"==typeof t){var e=i._prime(t);this.m=e.p,this.prime=e}else r(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){E.call(this,t),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)}v.prototype._tmp=function(){var t=new i(null);return t.words=new Array(Math.ceil(this.n/13)),t},v.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var n=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(t,e){t.iushrn(this.n,0,e)},v.prototype.imulK=function(t){return t.imul(this.k)},n(y,v),y.prototype.split=function(t,e){for(var r=4194303,n=Math.min(t.length,9),i=0;i>>22,o=s}o>>>=22,t.words[i-10]=o,0===o&&t.length>10?t.length-=10:t.length-=9},y.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=i,e=n}return 0!==e&&(t.words[t.length++]=e),t},i._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new y;else if("p224"===t)e=new b;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},E.prototype._verify1=function(t){r(0===t.negative,"red works only with positives"),r(t.red,"red works only with red numbers")},E.prototype._verify2=function(t,e){r(0==(t.negative|e.negative),"red works only with positives"),r(t.red&&t.red===e.red,"red works only with red numbers")},E.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},E.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},E.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},E.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},E.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},E.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},E.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},E.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},E.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},E.prototype.isqr=function(t){return this.imul(t,t.clone())},E.prototype.sqr=function(t){return this.mul(t,t)},E.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(r(e%2==1),3===e){var n=this.m.add(new i(1)).iushrn(2);return this.pow(t,n)}for(var o=this.m.subn(1),s=0;!o.isZero()&&0===o.andln(1);)s++,o.iushrn(1);r(!o.isZero());var a=new i(1).toRed(this),u=a.redNeg(),l=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new i(2*h*h).toRed(this);0!==this.pow(h,l).cmp(u);)h.redIAdd(u);for(var c=this.pow(h,o),f=this.pow(t,o.addn(1).iushrn(1)),d=this.pow(t,o),p=s;0!==d.cmp(a);){for(var m=d,g=0;0!==m.cmp(a);g++)m=m.redSqr();r(g=0;n--){for(var l=e.words[n],h=u-1;h>=0;h--){var c=l>>h&1;o!==r[0]&&(o=this.sqr(o)),0!==c||0!==s?(s<<=1,s|=c,(4===++a||0===n&&0===h)&&(o=this.mul(o,r[s]),a=0,s=0)):a=0}u=26}return o},E.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},E.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},i.mont=function(t){return new A(t)},n(A,E),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new i(0)._forceRed(this);var r=t.mul(e),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),o=r.isub(n).iushrn(this.shift),s=o;return o.cmp(this.m)>=0?s=o.isub(this.m):o.cmpn(0)<0&&(s=o.iadd(this.m)),s._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,qn)}));let Wn=!1,Jn=!1;const Kn={debug:1,default:2,info:2,warning:3,error:4,off:5};let Zn=Kn.default,Xn=null;const Qn=function(){try{const t=[];if(["NFD","NFC","NFKD","NFKC"].forEach((e=>{try{if("test"!=="test".normalize(e))throw new Error("bad normalize")}catch(r){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}();var Yn,ti,ei,ri;(ti=Yn||(Yn={})).DEBUG="DEBUG",ti.INFO="INFO",ti.WARNING="WARNING",ti.ERROR="ERROR",ti.OFF="OFF",(ri=ei||(ei={})).UNKNOWN_ERROR="UNKNOWN_ERROR",ri.NOT_IMPLEMENTED="NOT_IMPLEMENTED",ri.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",ri.NETWORK_ERROR="NETWORK_ERROR",ri.SERVER_ERROR="SERVER_ERROR",ri.TIMEOUT="TIMEOUT",ri.BUFFER_OVERRUN="BUFFER_OVERRUN",ri.NUMERIC_FAULT="NUMERIC_FAULT",ri.MISSING_NEW="MISSING_NEW",ri.INVALID_ARGUMENT="INVALID_ARGUMENT",ri.MISSING_ARGUMENT="MISSING_ARGUMENT",ri.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",ri.CALL_EXCEPTION="CALL_EXCEPTION",ri.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",ri.NONCE_EXPIRED="NONCE_EXPIRED",ri.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",ri.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT";class ni{constructor(t){Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}_log(t,e){const r=t.toLowerCase();null==Kn[r]&&this.throwArgumentError("invalid log level name","logLevel",t),Zn>Kn[r]||console.log.apply(console,e)}debug(...t){this._log(ni.levels.DEBUG,t)}info(...t){this._log(ni.levels.INFO,t)}warn(...t){this._log(ni.levels.WARNING,t)}makeError(t,e,r){if(Jn)return this.makeError("censored error",e,{});e||(e=ni.errors.UNKNOWN_ERROR),r||(r={});const n=[];Object.keys(r).forEach((t=>{try{n.push(t+"="+JSON.stringify(r[t]))}catch(e){n.push(t+"="+JSON.stringify(r[t].toString()))}})),n.push(`code=${e}`),n.push(`version=${this.version}`);const i=t;n.length&&(t+=" ("+n.join(", ")+")");const o=new Error(t);return o.reason=i,o.code=e,Object.keys(r).forEach((function(t){o[t]=r[t]})),o}throwError(t,e,r){throw this.makeError(t,e,r)}throwArgumentError(t,e,r){return this.throwError(t,ni.errors.INVALID_ARGUMENT,{argument:e,value:r})}assert(t,e,r,n){t||this.throwError(e,r,n)}assertArgument(t,e,r,n){t||this.throwArgumentError(e,r,n)}checkNormalize(t){Qn&&this.throwError("platform missing String.prototype.normalize",ni.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:Qn})}checkSafeUint53(t,e){"number"==typeof t&&(null==e&&(e="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(e,ni.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(e,ni.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}checkArgumentCount(t,e,r){r=r?": "+r:"",te&&this.throwError("too many arguments"+r,ni.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:e})}checkNew(t,e){t!==Object&&null!=t||this.throwError("missing new",ni.errors.MISSING_NEW,{name:e.name})}checkAbstract(t,e){t===e?this.throwError("cannot instantiate abstract class "+JSON.stringify(e.name)+" directly; use a sub-class",ni.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",ni.errors.MISSING_NEW,{name:e.name})}static globalLogger(){return Xn||(Xn=new ni("logger/5.1.0")),Xn}static setCensorship(t,e){if(!t&&e&&this.globalLogger().throwError("cannot permanently disable censorship",ni.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),Wn){if(!t)return;this.globalLogger().throwError("error censorship permanent",ni.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}Jn=!!t,Wn=!!e}static setLogLevel(t){const e=Kn[t.toLowerCase()];null!=e?Zn=e:ni.globalLogger().warn("invalid log level - "+t)}static from(t){return new ni(t)}}ni.errors=ei,ni.levels=Yn;const ii=new ni("bytes/5.1.0");function oi(t){return!!t.toHexString}function si(t){return t.slice||(t.slice=function(){const e=Array.prototype.slice.call(arguments);return si(new Uint8Array(Array.prototype.slice.apply(t,e)))}),t}function ai(t){return fi(t)&&!(t.length%2)||ui(t)}function ui(t){if(null==t)return!1;if(t.constructor===Uint8Array)return!0;if("string"==typeof t)return!1;if(null==t.length)return!1;for(let e=0;e=256||r%1)return!1}return!0}function li(t,e){if(e||(e={}),"number"==typeof t){ii.checkSafeUint53(t,"invalid arrayify value");const e=[];for(;t;)e.unshift(255&t),t=parseInt(String(t/256));return 0===e.length&&e.push(0),si(new Uint8Array(e))}if(e.allowMissingPrefix&&"string"==typeof t&&"0x"!==t.substring(0,2)&&(t="0x"+t),oi(t)&&(t=t.toHexString()),fi(t)){let r=t.substring(2);r.length%2&&("left"===e.hexPad?r="0x0"+r.substring(2):"right"===e.hexPad?r+="0":ii.throwArgumentError("hex data is odd-length","value",t));const n=[];for(let t=0;tli(t))),r=e.reduce(((t,e)=>t+e.length),0),n=new Uint8Array(r);return e.reduce(((t,e)=>(n.set(e,t),t+e.length)),0),si(n)}function ci(t){let e=li(t);if(0===e.length)return e;let r=0;for(;r>4]+"0123456789abcdef"[15&n]}return e}return ii.throwArgumentError("invalid hexlify value","value",t)}function pi(t){if("string"!=typeof t)t=di(t);else if(!fi(t)||t.length%2)return null;return(t.length-2)/2}function mi(t,e,r){return"string"!=typeof t?t=di(t):(!fi(t)||t.length%2)&&ii.throwArgumentError("invalid hexData","value",t),e=2+2*e,null!=r?"0x"+t.substring(e,2+2*r):"0x"+t.substring(e)}function gi(t){let e="0x";return t.forEach((t=>{e+=di(t).substring(2)})),e}function vi(t){const e=function(t){"string"!=typeof t&&(t=di(t));fi(t)||ii.throwArgumentError("invalid hex string","value",t);t=t.substring(2);let e=0;for(;e2*e+2&&ii.throwArgumentError("value out of range","value",arguments[1]);t.length<2*e+2;)t="0x0"+t.substring(2);return t}function bi(t){const e={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0};if(ai(t)){const r=li(t);65!==r.length&&ii.throwArgumentError("invalid signature string; must be 65 bytes","signature",t),e.r=di(r.slice(0,32)),e.s=di(r.slice(32,64)),e.v=r[64],e.v<27&&(0===e.v||1===e.v?e.v+=27:ii.throwArgumentError("signature invalid v byte","signature",t)),e.recoveryParam=1-e.v%2,e.recoveryParam&&(r[32]|=128),e._vs=di(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,null!=e._vs){const r=function(t,e){(t=li(t)).length>e&&ii.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(e);return r.set(t,e-t.length),si(r)}(li(e._vs),32);e._vs=di(r);const n=r[0]>=128?1:0;null==e.recoveryParam?e.recoveryParam=n:e.recoveryParam!==n&&ii.throwArgumentError("signature recoveryParam mismatch _vs","signature",t),r[0]&=127;const i=di(r);null==e.s?e.s=i:e.s!==i&&ii.throwArgumentError("signature v mismatch _vs","signature",t)}null==e.recoveryParam?null==e.v?ii.throwArgumentError("signature missing v and recoveryParam","signature",t):0===e.v||1===e.v?e.recoveryParam=e.v:e.recoveryParam=1-e.v%2:null==e.v?e.v=27+e.recoveryParam:e.recoveryParam!==1-e.v%2&&ii.throwArgumentError("signature recoveryParam mismatch v","signature",t),null!=e.r&&fi(e.r)?e.r=yi(e.r,32):ii.throwArgumentError("signature missing or invalid r","signature",t),null!=e.s&&fi(e.s)?e.s=yi(e.s,32):ii.throwArgumentError("signature missing or invalid s","signature",t);const r=li(e.s);r[0]>=128&&ii.throwArgumentError("signature s out of range","signature",t),e.recoveryParam&&(r[0]|=128);const n=di(r);e._vs&&(fi(e._vs)||ii.throwArgumentError("signature invalid _vs","signature",t),e._vs=yi(e._vs,32)),null==e._vs?e._vs=n:e._vs!==n&&ii.throwArgumentError("signature _vs mismatch v and s","signature",t)}return e}var wi=Gn.BN;const _i=new ni("bignumber/5.1.1"),Ei={};let Ai=!1;class Mi{constructor(t,e){_i.checkNew(new.target,Mi),t!==Ei&&_i.throwError("cannot call constructor directly; use BigNumber.from",ni.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=e,this._isBigNumber=!0,Object.freeze(this)}fromTwos(t){return Ni(xi(this).fromTwos(t))}toTwos(t){return Ni(xi(this).toTwos(t))}abs(){return"-"===this._hex[0]?Mi.from(this._hex.substring(1)):this}add(t){return Ni(xi(this).add(xi(t)))}sub(t){return Ni(xi(this).sub(xi(t)))}div(t){return Mi.from(t).isZero()&&Si("division by zero","div"),Ni(xi(this).div(xi(t)))}mul(t){return Ni(xi(this).mul(xi(t)))}mod(t){const e=xi(t);return e.isNeg()&&Si("cannot modulo negative values","mod"),Ni(xi(this).umod(e))}pow(t){const e=xi(t);return e.isNeg()&&Si("cannot raise to negative values","pow"),Ni(xi(this).pow(e))}and(t){const e=xi(t);return(this.isNegative()||e.isNeg())&&Si("cannot 'and' negative values","and"),Ni(xi(this).and(e))}or(t){const e=xi(t);return(this.isNegative()||e.isNeg())&&Si("cannot 'or' negative values","or"),Ni(xi(this).or(e))}xor(t){const e=xi(t);return(this.isNegative()||e.isNeg())&&Si("cannot 'xor' negative values","xor"),Ni(xi(this).xor(e))}mask(t){return(this.isNegative()||t<0)&&Si("cannot mask negative values","mask"),Ni(xi(this).maskn(t))}shl(t){return(this.isNegative()||t<0)&&Si("cannot shift negative values","shl"),Ni(xi(this).shln(t))}shr(t){return(this.isNegative()||t<0)&&Si("cannot shift negative values","shr"),Ni(xi(this).shrn(t))}eq(t){return xi(this).eq(xi(t))}lt(t){return xi(this).lt(xi(t))}lte(t){return xi(this).lte(xi(t))}gt(t){return xi(this).gt(xi(t))}gte(t){return xi(this).gte(xi(t))}isNegative(){return"-"===this._hex[0]}isZero(){return xi(this).isZero()}toNumber(){try{return xi(this).toNumber()}catch(t){Si("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch(t){}return _i.throwError("this platform does not support BigInt",ni.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(10===arguments[0]?Ai||(Ai=!0,_i.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?_i.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",ni.errors.UNEXPECTED_ARGUMENT,{}):_i.throwError("BigNumber.toString does not accept parameters",ni.errors.UNEXPECTED_ARGUMENT,{})),xi(this).toString(10)}toHexString(){return this._hex}toJSON(t){return{type:"BigNumber",hex:this.toHexString()}}static from(t){if(t instanceof Mi)return t;if("string"==typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new Mi(Ei,ki(t)):t.match(/^-?[0-9]+$/)?new Mi(Ei,ki(new wi(t))):_i.throwArgumentError("invalid BigNumber string","value",t);if("number"==typeof t)return t%1&&Si("underflow","BigNumber.from",t),(t>=9007199254740991||t<=-9007199254740991)&&Si("overflow","BigNumber.from",t),Mi.from(String(t));const e=t;if("bigint"==typeof e)return Mi.from(e.toString());if(ui(e))return Mi.from(di(e));if(e)if(e.toHexString){const t=e.toHexString();if("string"==typeof t)return Mi.from(t)}else{let t=e._hex;if(null==t&&"BigNumber"===e.type&&(t=e.hex),"string"==typeof t&&(fi(t)||"-"===t[0]&&fi(t.substring(1))))return Mi.from(t)}return _i.throwArgumentError("invalid BigNumber value","value",t)}static isBigNumber(t){return!(!t||!t._isBigNumber)}}function ki(t){if("string"!=typeof t)return ki(t.toString(16));if("-"===t[0])return"-"===(t=t.substring(1))[0]&&_i.throwArgumentError("invalid hex","value",t),"0x00"===(t=ki(t))?t:"-"+t;if("0x"!==t.substring(0,2)&&(t="0x"+t),"0x"===t)return"0x00";for(t.length%2&&(t="0x0"+t.substring(2));t.length>4&&"0x00"===t.substring(0,4);)t="0x"+t.substring(4);return t}function Ni(t){return Mi.from(ki(t))}function xi(t){const e=Mi.from(t).toHexString();return"-"===e[0]?new wi("-"+e.substring(3),16):new wi(e.substring(2),16)}function Si(t,e,r){const n={fault:t,operation:e};return null!=r&&(n.value=r),_i.throwError(t,ni.errors.NUMERIC_FAULT,n)}const Ii=new ni("bignumber/5.1.1"),Ri={},Pi=Mi.from(0),Ti=Mi.from(-1);function Oi(t,e,r,n){const i={fault:e,operation:r};return void 0!==n&&(i.value=n),Ii.throwError(t,ni.errors.NUMERIC_FAULT,i)}let Bi="0";for(;Bi.length<256;)Bi+=Bi;function Ci(t){if("number"!=typeof t)try{t=Mi.from(t).toNumber()}catch(e){}return"number"==typeof t&&t>=0&&t<=256&&!(t%1)?"1"+Bi.substring(0,t):Ii.throwArgumentError("invalid decimal size","decimals",t)}function Fi(t,e){null==e&&(e=0);const r=Ci(e),n=(t=Mi.from(t)).lt(Pi);n&&(t=t.mul(Ti));let i=t.mod(r).toString();for(;i.length2&&Ii.throwArgumentError("too many decimal points","value",t);let o=i[0],s=i[1];for(o||(o="0"),s||(s="0"),s.length>r.length-1&&Oi("fractional component exceeds decimals","underflow","parseFixed");s.lengthnull==t[e]?n:(typeof t[e]!==r&&Ii.throwArgumentError("invalid fixed format ("+e+" not "+r+")","format."+e,t[e]),t[e]);e=i("signed","boolean",e),r=i("width","number",r),n=i("decimals","number",n)}return r%8&&Ii.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",r),n>80&&Ii.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",n),new Ui(Ri,e,r,n)}}class ji{constructor(t,e,r,n){Ii.checkNew(new.target,ji),t!==Ri&&Ii.throwError("cannot use FixedNumber constructor; use FixedNumber.from",ni.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=n,this._hex=e,this._value=r,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(t){this.format.name!==t.format.name&&Ii.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",t)}addUnsafe(t){this._checkFormat(t);const e=Li(this._value,this.format.decimals),r=Li(t._value,t.format.decimals);return ji.fromValue(e.add(r),this.format.decimals,this.format)}subUnsafe(t){this._checkFormat(t);const e=Li(this._value,this.format.decimals),r=Li(t._value,t.format.decimals);return ji.fromValue(e.sub(r),this.format.decimals,this.format)}mulUnsafe(t){this._checkFormat(t);const e=Li(this._value,this.format.decimals),r=Li(t._value,t.format.decimals);return ji.fromValue(e.mul(r).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(t){this._checkFormat(t);const e=Li(this._value,this.format.decimals),r=Li(t._value,t.format.decimals);return ji.fromValue(e.mul(this.format._multiplier).div(r),this.format.decimals,this.format)}floor(){let t=this.toString().split("."),e=ji.from(t[0],this.format);const r=!t[1].match(/^(0*)$/);return this.isNegative()&&r&&(e=e.subUnsafe(zi)),e}ceiling(){let t=this.toString().split("."),e=ji.from(t[0],this.format);const r=!t[1].match(/^(0*)$/);return!this.isNegative()&&r&&(e=e.addUnsafe(zi)),e}round(t){null==t&&(t=0);let e=this.toString().split(".");if((t<0||t>80||t%1)&&Ii.throwArgumentError("invalid decimal count","decimals",t),e[1].length<=t)return this;const r=ji.from("1"+Bi.substring(0,t));return this.mulUnsafe(r).addUnsafe(Di).floor().divUnsafe(r)}isZero(){return"0.0"===this._value}isNegative(){return"-"===this._value[0]}toString(){return this._value}toHexString(t){if(null==t)return this._hex;t%8&&Ii.throwArgumentError("invalid byte width","width",t);return yi(Mi.from(this._hex).fromTwos(this.format.width).toTwos(t).toHexString(),t/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(t){return ji.fromString(this._value,t)}static fromValue(t,e,r){return null!=r||null==e||function(t){return null!=t&&(Mi.isBigNumber(t)||"number"==typeof t&&t%1==0||"string"==typeof t&&!!t.match(/^-?[0-9]+$/)||fi(t)||"bigint"==typeof t||ui(t))}(e)||(r=e,e=null),null==e&&(e=0),null==r&&(r="fixed"),ji.fromString(Fi(t,e),Ui.from(r))}static fromString(t,e){null==e&&(e="fixed");const r=Ui.from(e),n=Li(t,r.decimals);!r.signed&&n.lt(Pi)&&Oi("unsigned value cannot be negative","overflow","value",t);let i=null;r.signed?i=n.toTwos(r.width).toHexString():(i=n.toHexString(),i=yi(i,r.width/8));const o=Fi(n,r.decimals);return new ji(Ri,i,o,r)}static fromBytes(t,e){null==e&&(e="fixed");const r=Ui.from(e);if(li(t).length>r.width/8)throw new Error("overflow");let n=Mi.from(t);r.signed&&(n=n.fromTwos(r.width));const i=n.toTwos((r.signed?0:1)+r.width).toHexString(),o=Fi(n,r.decimals);return new ji(Ri,i,o,r)}static from(t,e){if("string"==typeof t)return ji.fromString(t,e);if(ui(t))return ji.fromBytes(t,e);try{return ji.fromValue(t,0,e)}catch(r){if(r.code!==ni.errors.INVALID_ARGUMENT)throw r}return Ii.throwArgumentError("invalid FixedNumber value","value",t)}static isFixedNumber(t){return!(!t||!t._isFixedNumber)}}const zi=ji.from(1),Di=ji.from("0.5");var qi=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const Vi=new ni("properties/5.1.0");function $i(t,e,r){Object.defineProperty(t,e,{enumerable:!0,value:r,writable:!1})}function Hi(t,e){for(let r=0;r<32;r++){if(t[e])return t[e];if(!t.prototype||"object"!=typeof t.prototype)break;t=Object.getPrototypeOf(t.prototype).constructor}return null}function Gi(t){return qi(this,void 0,void 0,(function*(){const e=Object.keys(t).map((e=>{const r=t[e];return Promise.resolve(r).then((t=>({key:e,value:t})))}));return(yield Promise.all(e)).reduce(((t,e)=>(t[e.key]=e.value,t)),{})}))}function Wi(t){const e={};for(const r in t)e[r]=t[r];return e}const Ji={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function Ki(t){if(null==t||Ji[typeof t])return!0;if(Array.isArray(t)||"object"==typeof t){if(!Object.isFrozen(t))return!1;const e=Object.keys(t);for(let r=0;rXi(t))));if("object"==typeof t){const e={};for(const r in t){const n=t[r];void 0!==n&&$i(e,r,Xi(n))}return e}return Vi.throwArgumentError("Cannot deepCopy "+typeof t,"object",t)}function Xi(t){return Zi(t)}class Qi{constructor(t){for(const e in t)this[e]=Xi(t[e])}}const Yi=new ni("abi/5.1.1"),to={};let eo={calldata:!0,memory:!0,storage:!0},ro={calldata:!0,memory:!0};function no(t,e){if("bytes"===t||"string"===t){if(eo[e])return!0}else if("address"===t){if("payable"===e)return!0}else if((t.indexOf("[")>=0||"tuple"===t)&&ro[e])return!0;return(eo[e]||"payable"===e)&&Yi.throwArgumentError("invalid modifier","name",e),!1}function io(t,e){for(let r in e)$i(t,r,e[r])}const oo=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),so=new RegExp(/^(.*)\[([0-9]*)\]$/);class ao{constructor(t,e){t!==to&&Yi.throwError("use fromString",ni.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),io(this,e);let r=this.type.match(so);io(this,r?{arrayLength:parseInt(r[2]||"-1"),arrayChildren:ao.fromObject({type:r[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(t){if(t||(t=oo.sighash),oo[t]||Yi.throwArgumentError("invalid format type","format",t),t===oo.json){let e={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(e.indexed=this.indexed),this.components&&(e.components=this.components.map((e=>JSON.parse(e.format(t))))),JSON.stringify(e)}let e="";return"array"===this.baseType?(e+=this.arrayChildren.format(t),e+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(t!==oo.sighash&&(e+=this.type),e+="("+this.components.map((e=>e.format(t))).join(t===oo.full?", ":",")+")"):e+=this.type,t!==oo.sighash&&(!0===this.indexed&&(e+=" indexed"),t===oo.full&&this.name&&(e+=" "+this.name)),e}static from(t,e){return"string"==typeof t?ao.fromString(t,e):ao.fromObject(t)}static fromObject(t){return ao.isParamType(t)?t:new ao(to,{name:t.name||null,type:vo(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(ao.fromObject):null})}static fromString(t,e){return r=function(t,e){let r=t;function n(e){Yi.throwArgumentError(`unexpected character at position ${e}`,"param",t)}function i(t){let r={type:"",name:"",parent:t,state:{allowType:!0}};return e&&(r.indexed=!1),r}t=t.replace(/\s/g," ");let o={type:"",name:"",state:{allowType:!0}},s=o;for(let a=0;aao.fromString(t,e)))}class lo{constructor(t,e){t!==to&&Yi.throwError("use a static from method",ni.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),io(this,e),this._isFragment=!0,Object.freeze(this)}static from(t){return lo.isFragment(t)?t:"string"==typeof t?lo.fromString(t):lo.fromObject(t)}static fromObject(t){if(lo.isFragment(t))return t;switch(t.type){case"function":return go.fromObject(t);case"event":return ho.fromObject(t);case"constructor":return mo.fromObject(t);case"fallback":case"receive":return null}return Yi.throwArgumentError("invalid fragment object","value",t)}static fromString(t){return"event"===(t=(t=(t=t.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).split(" ")[0]?ho.fromString(t.substring(5).trim()):"function"===t.split(" ")[0]?go.fromString(t.substring(8).trim()):"constructor"===t.split("(")[0].trim()?mo.fromString(t.trim()):Yi.throwArgumentError("unsupported fragment","value",t)}static isFragment(t){return!(!t||!t._isFragment)}}class ho extends lo{format(t){if(t||(t=oo.sighash),oo[t]||Yi.throwArgumentError("invalid format type","format",t),t===oo.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((e=>JSON.parse(e.format(t))))});let e="";return t!==oo.sighash&&(e+="event "),e+=this.name+"("+this.inputs.map((e=>e.format(t))).join(t===oo.full?", ":",")+") ",t!==oo.sighash&&this.anonymous&&(e+="anonymous "),e.trim()}static from(t){return"string"==typeof t?ho.fromString(t):ho.fromObject(t)}static fromObject(t){if(ho.isEventFragment(t))return t;"event"!==t.type&&Yi.throwArgumentError("invalid event object","value",t);const e={name:bo(t.name),anonymous:t.anonymous,inputs:t.inputs?t.inputs.map(ao.fromObject):[],type:"event"};return new ho(to,e)}static fromString(t){let e=t.match(wo);e||Yi.throwArgumentError("invalid event string","value",t);let r=!1;return e[3].split(" ").forEach((t=>{switch(t.trim()){case"anonymous":r=!0;break;case"":break;default:Yi.warn("unknown modifier: "+t)}})),ho.fromObject({name:e[1].trim(),anonymous:r,inputs:uo(e[2],!0),type:"event"})}static isEventFragment(t){return t&&t._isFragment&&"event"===t.type}}function co(t,e){e.gas=null;let r=t.split("@");return 1!==r.length?(r.length>2&&Yi.throwArgumentError("invalid human-readable ABI signature","value",t),r[1].match(/^[0-9]+$/)||Yi.throwArgumentError("invalid human-readable ABI signature gas","value",t),e.gas=Mi.from(r[1]),r[0]):t}function fo(t,e){e.constant=!1,e.payable=!1,e.stateMutability="nonpayable",t.split(" ").forEach((t=>{switch(t.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: "+t)}}))}function po(t){let e={constant:!1,payable:!0,stateMutability:"payable"};return null!=t.stateMutability?(e.stateMutability=t.stateMutability,e.constant="view"===e.stateMutability||"pure"===e.stateMutability,null!=t.constant&&!!t.constant!==e.constant&&Yi.throwArgumentError("cannot have constant function with mutability "+e.stateMutability,"value",t),e.payable="payable"===e.stateMutability,null!=t.payable&&!!t.payable!==e.payable&&Yi.throwArgumentError("cannot have payable function with mutability "+e.stateMutability,"value",t)):null!=t.payable?(e.payable=!!t.payable,null!=t.constant||e.payable||"constructor"===t.type||Yi.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&&Yi.throwArgumentError("cannot have constant payable function","value",t)):null!=t.constant?(e.constant=!!t.constant,e.payable=!e.constant,e.stateMutability=e.constant?"view":"payable"):"constructor"!==t.type&&Yi.throwArgumentError("unable to determine stateMutability","value",t),e}class mo extends lo{format(t){if(t||(t=oo.sighash),oo[t]||Yi.throwArgumentError("invalid format type","format",t),t===oo.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((e=>JSON.parse(e.format(t))))});t===oo.sighash&&Yi.throwError("cannot format a constructor for sighash",ni.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let e="constructor("+this.inputs.map((e=>e.format(t))).join(t===oo.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(e+=this.stateMutability+" "),e.trim()}static from(t){return"string"==typeof t?mo.fromString(t):mo.fromObject(t)}static fromObject(t){if(mo.isConstructorFragment(t))return t;"constructor"!==t.type&&Yi.throwArgumentError("invalid constructor object","value",t);let e=po(t);e.constant&&Yi.throwArgumentError("constructor cannot be constant","value",t);const r={name:null,type:t.type,inputs:t.inputs?t.inputs.map(ao.fromObject):[],payable:e.payable,stateMutability:e.stateMutability,gas:t.gas?Mi.from(t.gas):null};return new mo(to,r)}static fromString(t){let e={type:"constructor"},r=(t=co(t,e)).match(wo);return r&&"constructor"===r[1].trim()||Yi.throwArgumentError("invalid constructor string","value",t),e.inputs=uo(r[2].trim(),!1),fo(r[3].trim(),e),mo.fromObject(e)}static isConstructorFragment(t){return t&&t._isFragment&&"constructor"===t.type}}class go extends mo{format(t){if(t||(t=oo.sighash),oo[t]||Yi.throwArgumentError("invalid format type","format",t),t===oo.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((e=>JSON.parse(e.format(t)))),outputs:this.outputs.map((e=>JSON.parse(e.format(t))))});let e="";return t!==oo.sighash&&(e+="function "),e+=this.name+"("+this.inputs.map((e=>e.format(t))).join(t===oo.full?", ":",")+") ",t!==oo.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(e+=this.stateMutability+" "):this.constant&&(e+="view "),this.outputs&&this.outputs.length&&(e+="returns ("+this.outputs.map((e=>e.format(t))).join(", ")+") "),null!=this.gas&&(e+="@"+this.gas.toString()+" ")),e.trim()}static from(t){return"string"==typeof t?go.fromString(t):go.fromObject(t)}static fromObject(t){if(go.isFunctionFragment(t))return t;"function"!==t.type&&Yi.throwArgumentError("invalid function object","value",t);let e=po(t);const r={type:t.type,name:bo(t.name),constant:e.constant,inputs:t.inputs?t.inputs.map(ao.fromObject):[],outputs:t.outputs?t.outputs.map(ao.fromObject):[],payable:e.payable,stateMutability:e.stateMutability,gas:t.gas?Mi.from(t.gas):null};return new go(to,r)}static fromString(t){let e={type:"function"},r=(t=co(t,e)).split(" returns ");r.length>2&&Yi.throwArgumentError("invalid function string","value",t);let n=r[0].match(wo);if(n||Yi.throwArgumentError("invalid function signature","value",t),e.name=n[1].trim(),e.name&&bo(e.name),e.inputs=uo(n[2],!1),fo(n[3].trim(),e),r.length>1){let n=r[1].match(wo);""==n[1].trim()&&""==n[3].trim()||Yi.throwArgumentError("unexpected tokens","value",t),e.outputs=uo(n[2],!1)}else e.outputs=[];return go.fromObject(e)}static isFunctionFragment(t){return t&&t._isFragment&&"function"===t.type}}function vo(t){return t.match(/^uint($|[^1-9])/)?t="uint256"+t.substring(4):t.match(/^int($|[^1-9])/)&&(t="int256"+t.substring(3)),t}const yo=new RegExp("^[A-Za-z_][A-Za-z0-9_]*$");function bo(t){return t&&t.match(yo)||Yi.throwArgumentError(`invalid identifier "${t}"`,"value",t),t}const wo=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");const _o=new ni("abi/5.1.1");class Eo{constructor(t,e,r,n){this.name=t,this.type=e,this.localName=r,this.dynamic=n}_throwError(t,e){_o.throwArgumentError(t,this.localName,e)}}class Ao{constructor(t){$i(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}get data(){return gi(this._data)}get length(){return this._dataLength}_writeData(t){return this._data.push(t),this._dataLength+=t.length,t.length}appendWriter(t){return this._writeData(hi(t._data))}writeBytes(t){let e=li(t);const r=e.length%this.wordSize;return r&&(e=hi([e,this._padding.slice(r)])),this._writeData(e)}_getValue(t){let e=li(Mi.from(t));return e.length>this.wordSize&&_o.throwError("value out-of-bounds",ni.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:e.length}),e.length%this.wordSize&&(e=hi([this._padding.slice(e.length%this.wordSize),e])),e}writeValue(t){return this._writeData(this._getValue(t))}writeUpdatableValue(){const t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,e=>{this._data[t]=this._getValue(e)}}}class Mo{constructor(t,e,r,n){$i(this,"_data",li(t)),$i(this,"wordSize",e||32),$i(this,"_coerceFunc",r),$i(this,"allowLoose",n),this._offset=0}get data(){return di(this._data)}get consumed(){return this._offset}static coerce(t,e){let r=t.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(e=e.toNumber()),e}coerce(t,e){return this._coerceFunc?this._coerceFunc(t,e):Mo.coerce(t,e)}_peekBytes(t,e,r){let n=Math.ceil(e/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+e<=this._data.length?n=e:_o.throwError("data out-of-bounds",ni.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}subReader(t){return new Mo(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(t,e){let r=this._peekBytes(0,t,!!e);return this._offset+=r.length,r.slice(0,t)}readValue(){return Mi.from(this.readBytes(this.wordSize))}} +/** + * [js-sha3]{@link https://github.com/emn178/js-sha3} + * + * @version 0.5.7 + * @author Chen, Yi-Cyuan [emn178@gmail.com] + * @copyright Chen, Yi-Cyuan 2015-2016 + * @license MIT + */var ko=$n((function(t){!function(){var e="object"==typeof window?window:{};!e.JS_SHA3_NO_NODE_JS&&"object"==typeof process&&process.versions&&process.versions.node&&(e=qn);for(var r=!e.JS_SHA3_NO_COMMON_JS&&t.exports,n="0123456789abcdef".split(""),i=[0,8,16,24],o=[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],s=[224,256,384,512],a=["hex","buffer","arrayBuffer","array"],u=function(t,e,r){return function(n){return new b(t,e,t).update(n)[r]()}},l=function(t,e,r){return function(n,i){return new b(t,e,i).update(n)[r]()}},h=function(t,e){var r=u(t,e,"hex");r.create=function(){return new b(t,e,t)},r.update=function(t){return r.create().update(t)};for(var n=0;n>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}b.prototype.update=function(t){var e="string"!=typeof t;e&&t.constructor===ArrayBuffer&&(t=new Uint8Array(t));for(var r,n,o=t.length,s=this.blocks,a=this.byteCount,u=this.blockCount,l=0,h=this.s;l>2]|=t[l]<>2]|=n<>2]|=(192|n>>6)<>2]|=(128|63&n)<=57344?(s[r>>2]|=(224|n>>12)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<>2]|=(240|n>>18)<>2]|=(128|n>>12&63)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<=a){for(this.start=r-a,this.block=s[u],r=0;r>2]|=this.padding[3&e],this.lastByteIndex===this.byteCount)for(t[0]=t[r],e=1;e>4&15]+n[15&t]+n[t>>12&15]+n[t>>8&15]+n[t>>20&15]+n[t>>16&15]+n[t>>28&15]+n[t>>24&15];a%e==0&&(w(r),s=0)}return o&&(t=r[s],o>0&&(u+=n[t>>4&15]+n[15&t]),o>1&&(u+=n[t>>12&15]+n[t>>8&15]),o>2&&(u+=n[t>>20&15]+n[t>>16&15])),u},b.prototype.arrayBuffer=function(){this.finalize();var t,e=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,s=0,a=this.outputBits>>3;t=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(a);for(var u=new Uint32Array(t);s>8&255,u[t+2]=e>>16&255,u[t+3]=e>>24&255;a%r==0&&w(n)}return o&&(t=a<<2,e=n[s],o>0&&(u[t]=255&e),o>1&&(u[t+1]=e>>8&255),o>2&&(u[t+2]=e>>16&255)),u};var w=function(t){var e,r,n,i,s,a,u,l,h,c,f,d,p,m,g,v,y,b,w,_,E,A,M,k,N,x,S,I,R,P,T,O,B,C,F,L,U,j,z,D,q,V,$,H,G,W,J,K,Z,X,Q,Y,tt,et,rt,nt,it,ot,st,at,ut,lt,ht;for(n=0;n<48;n+=2)i=t[0]^t[10]^t[20]^t[30]^t[40],s=t[1]^t[11]^t[21]^t[31]^t[41],a=t[2]^t[12]^t[22]^t[32]^t[42],u=t[3]^t[13]^t[23]^t[33]^t[43],l=t[4]^t[14]^t[24]^t[34]^t[44],h=t[5]^t[15]^t[25]^t[35]^t[45],c=t[6]^t[16]^t[26]^t[36]^t[46],f=t[7]^t[17]^t[27]^t[37]^t[47],e=(d=t[8]^t[18]^t[28]^t[38]^t[48])^(a<<1|u>>>31),r=(p=t[9]^t[19]^t[29]^t[39]^t[49])^(u<<1|a>>>31),t[0]^=e,t[1]^=r,t[10]^=e,t[11]^=r,t[20]^=e,t[21]^=r,t[30]^=e,t[31]^=r,t[40]^=e,t[41]^=r,e=i^(l<<1|h>>>31),r=s^(h<<1|l>>>31),t[2]^=e,t[3]^=r,t[12]^=e,t[13]^=r,t[22]^=e,t[23]^=r,t[32]^=e,t[33]^=r,t[42]^=e,t[43]^=r,e=a^(c<<1|f>>>31),r=u^(f<<1|c>>>31),t[4]^=e,t[5]^=r,t[14]^=e,t[15]^=r,t[24]^=e,t[25]^=r,t[34]^=e,t[35]^=r,t[44]^=e,t[45]^=r,e=l^(d<<1|p>>>31),r=h^(p<<1|d>>>31),t[6]^=e,t[7]^=r,t[16]^=e,t[17]^=r,t[26]^=e,t[27]^=r,t[36]^=e,t[37]^=r,t[46]^=e,t[47]^=r,e=c^(i<<1|s>>>31),r=f^(s<<1|i>>>31),t[8]^=e,t[9]^=r,t[18]^=e,t[19]^=r,t[28]^=e,t[29]^=r,t[38]^=e,t[39]^=r,t[48]^=e,t[49]^=r,m=t[0],g=t[1],W=t[11]<<4|t[10]>>>28,J=t[10]<<4|t[11]>>>28,I=t[20]<<3|t[21]>>>29,R=t[21]<<3|t[20]>>>29,at=t[31]<<9|t[30]>>>23,ut=t[30]<<9|t[31]>>>23,V=t[40]<<18|t[41]>>>14,$=t[41]<<18|t[40]>>>14,C=t[2]<<1|t[3]>>>31,F=t[3]<<1|t[2]>>>31,v=t[13]<<12|t[12]>>>20,y=t[12]<<12|t[13]>>>20,K=t[22]<<10|t[23]>>>22,Z=t[23]<<10|t[22]>>>22,P=t[33]<<13|t[32]>>>19,T=t[32]<<13|t[33]>>>19,lt=t[42]<<2|t[43]>>>30,ht=t[43]<<2|t[42]>>>30,et=t[5]<<30|t[4]>>>2,rt=t[4]<<30|t[5]>>>2,L=t[14]<<6|t[15]>>>26,U=t[15]<<6|t[14]>>>26,b=t[25]<<11|t[24]>>>21,w=t[24]<<11|t[25]>>>21,X=t[34]<<15|t[35]>>>17,Q=t[35]<<15|t[34]>>>17,O=t[45]<<29|t[44]>>>3,B=t[44]<<29|t[45]>>>3,k=t[6]<<28|t[7]>>>4,N=t[7]<<28|t[6]>>>4,nt=t[17]<<23|t[16]>>>9,it=t[16]<<23|t[17]>>>9,j=t[26]<<25|t[27]>>>7,z=t[27]<<25|t[26]>>>7,_=t[36]<<21|t[37]>>>11,E=t[37]<<21|t[36]>>>11,Y=t[47]<<24|t[46]>>>8,tt=t[46]<<24|t[47]>>>8,H=t[8]<<27|t[9]>>>5,G=t[9]<<27|t[8]>>>5,x=t[18]<<20|t[19]>>>12,S=t[19]<<20|t[18]>>>12,ot=t[29]<<7|t[28]>>>25,st=t[28]<<7|t[29]>>>25,D=t[38]<<8|t[39]>>>24,q=t[39]<<8|t[38]>>>24,A=t[48]<<14|t[49]>>>18,M=t[49]<<14|t[48]>>>18,t[0]=m^~v&b,t[1]=g^~y&w,t[10]=k^~x&I,t[11]=N^~S&R,t[20]=C^~L&j,t[21]=F^~U&z,t[30]=H^~W&K,t[31]=G^~J&Z,t[40]=et^~nt&ot,t[41]=rt^~it&st,t[2]=v^~b&_,t[3]=y^~w&E,t[12]=x^~I&P,t[13]=S^~R&T,t[22]=L^~j&D,t[23]=U^~z&q,t[32]=W^~K&X,t[33]=J^~Z&Q,t[42]=nt^~ot&at,t[43]=it^~st&ut,t[4]=b^~_&A,t[5]=w^~E&M,t[14]=I^~P&O,t[15]=R^~T&B,t[24]=j^~D&V,t[25]=z^~q&$,t[34]=K^~X&Y,t[35]=Z^~Q&tt,t[44]=ot^~at<,t[45]=st^~ut&ht,t[6]=_^~A&m,t[7]=E^~M&g,t[16]=P^~O&k,t[17]=T^~B&N,t[26]=D^~V&C,t[27]=q^~$&F,t[36]=X^~Y&H,t[37]=Q^~tt&G,t[46]=at^~lt&et,t[47]=ut^~ht&rt,t[8]=A^~m&v,t[9]=M^~g&y,t[18]=O^~k&x,t[19]=B^~N&S,t[28]=V^~C&L,t[29]=$^~F&U,t[38]=Y^~H&W,t[39]=tt^~G&J,t[48]=lt^~et&nt,t[49]=ht^~rt&it,t[0]^=o[n],t[1]^=o[n+1]};if(r)t.exports=f;else for(p=0;p>=8;return e}function Io(t,e,r){let n=0;for(let i=0;ie+1+n&&xo.throwError("child data too short",ni.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:i}}function Oo(t,e){if(0===t.length&&xo.throwError("data too short",ni.errors.BUFFER_OVERRUN,{}),t[e]>=248){const r=t[e]-247;e+1+r>t.length&&xo.throwError("data short segment too short",ni.errors.BUFFER_OVERRUN,{});const n=Io(t,e+1,r);return e+1+r+n>t.length&&xo.throwError("data long segment too short",ni.errors.BUFFER_OVERRUN,{}),To(t,e,e+1+r,r+n)}if(t[e]>=192){const r=t[e]-192;return e+1+r>t.length&&xo.throwError("data array too short",ni.errors.BUFFER_OVERRUN,{}),To(t,e,e+1,r)}if(t[e]>=184){const r=t[e]-183;e+1+r>t.length&&xo.throwError("data array too short",ni.errors.BUFFER_OVERRUN,{});const n=Io(t,e+1,r);e+1+r+n>t.length&&xo.throwError("data array too short",ni.errors.BUFFER_OVERRUN,{});return{consumed:1+r+n,result:di(t.slice(e+1+r,e+1+r+n))}}if(t[e]>=128){const r=t[e]-128;e+1+r>t.length&&xo.throwError("data too short",ni.errors.BUFFER_OVERRUN,{});return{consumed:1+r,result:di(t.slice(e+1,e+1+r))}}return{consumed:1,result:di(t[e])}}function Bo(t){const e=li(t),r=Oo(e,0);return r.consumed!==e.length&&xo.throwArgumentError("invalid rlp data","data",t),r.result}const Co=new ni("address/5.1.0");function Fo(t){fi(t,20)||Co.throwArgumentError("invalid address","address",t);const e=(t=t.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let i=0;i<40;i++)r[i]=e[i].charCodeAt(0);const n=li(No(r));for(let i=0;i<40;i+=2)n[i>>1]>>4>=8&&(e[i]=e[i].toUpperCase()),(15&n[i>>1])>=8&&(e[i+1]=e[i+1].toUpperCase());return"0x"+e.join("")}const Lo={};for(let sc=0;sc<10;sc++)Lo[String(sc)]=String(sc);for(let sc=0;sc<26;sc++)Lo[String.fromCharCode(65+sc)]=String(10+sc);const Uo=Math.floor(function(t){return Math.log10?Math.log10(t):Math.log(t)/Math.LN10}(9007199254740991));function jo(t){let e=null;if("string"!=typeof t&&Co.throwArgumentError("invalid address","address",t),t.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==t.substring(0,2)&&(t="0x"+t),e=Fo(t),t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&e!==t&&Co.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)!==function(t){let e=(t=(t=t.toUpperCase()).substring(4)+t.substring(0,2)+"00").split("").map((t=>Lo[t])).join("");for(;e.length>=Uo;){let t=e.substring(0,Uo);e=parseInt(t,10)%97+e.substring(t.length)}let r=String(98-parseInt(e,10)%97);for(;r.length<2;)r="0"+r;return r}(t)&&Co.throwArgumentError("bad icap checksum","address",t),r=t.substring(4),e=new wi(r,36).toString(16);e.length<40;)e="0"+e;e=Fo("0x"+e)}else Co.throwArgumentError("invalid address","address",t);var r;return e}function zo(t){let e=null;try{e=jo(t.from)}catch(r){Co.throwArgumentError("missing from address","transaction",t)}return jo(mi(No(Po([e,ci(li(Mi.from(t.nonce).toHexString()))])),12))}class Do extends Eo{constructor(t){super("address","address",t,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(t,e){try{jo(e)}catch(r){this._throwError(r.message,e)}return t.writeValue(e)}decode(t){return jo(yi(t.readValue().toHexString(),20))}}class qo extends Eo{constructor(t){super(t.name,t.type,void 0,t.dynamic),this.coder=t}defaultValue(){return this.coder.defaultValue()}encode(t,e){return this.coder.encode(t,e)}decode(t){return this.coder.decode(t)}}const Vo=new ni("abi/5.1.1");function $o(t,e,r){let n=null;if(Array.isArray(r))n=r;else if(r&&"object"==typeof r){let t={};n=e.map((e=>{const n=e.localName;return n||Vo.throwError("cannot encode object for signature with missing names",ni.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),t[n]&&Vo.throwError("cannot encode object for signature with duplicate names",ni.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),t[n]=!0,r[n]}))}else Vo.throwArgumentError("invalid tuple value","tuple",r);e.length!==n.length&&Vo.throwArgumentError("types/value length mismatch","tuple",r);let i=new Ao(t.wordSize),o=new Ao(t.wordSize),s=[];e.forEach(((t,e)=>{let r=n[e];if(t.dynamic){let e=o.length;t.encode(o,r);let n=i.writeUpdatableValue();s.push((t=>{n(t+e)}))}else t.encode(i,r)})),s.forEach((t=>{t(i.length)}));let a=t.appendWriter(i);return a+=t.appendWriter(o),a}function Ho(t,e){let r=[],n=t.subReader(0);e.forEach((e=>{let i=null;if(e.dynamic){let r=t.readValue(),s=n.subReader(r.toNumber());try{i=e.decode(s)}catch(o){if(o.code===ni.errors.BUFFER_OVERRUN)throw o;i=o,i.baseType=e.name,i.name=e.localName,i.type=e.type}}else try{i=e.decode(t)}catch(o){if(o.code===ni.errors.BUFFER_OVERRUN)throw o;i=o,i.baseType=e.name,i.name=e.localName,i.type=e.type}null!=i&&r.push(i)}));const i=e.reduce(((t,e)=>{const r=e.localName;return r&&(t[r]||(t[r]=0),t[r]++),t}),{});e.forEach(((t,e)=>{let n=t.localName;if(!n||1!==i[n])return;if("length"===n&&(n="_length"),null!=r[n])return;const o=r[e];o instanceof Error?Object.defineProperty(r,n,{get:()=>{throw o}}):r[n]=o}));for(let o=0;o{throw t}})}return Object.freeze(r)}class Go extends Eo{constructor(t,e,r){super("array",t.type+"["+(e>=0?e:"")+"]",r,-1===e||t.dynamic),this.coder=t,this.length=e}defaultValue(){const t=this.coder.defaultValue(),e=[];for(let r=0;rt._data.length&&Vo.throwError("insufficient data length",ni.errors.BUFFER_OVERRUN,{length:t._data.length,count:e}));let r=[];for(let n=0;n>6==2;n++)t++;return t}return t===ss.OVERRUN?r.length-e-1:0}(os=is||(is={})).current="",os.NFC="NFC",os.NFD="NFD",os.NFKC="NFKC",os.NFKD="NFKD",(as=ss||(ss={})).UNEXPECTED_CONTINUE="unexpected continuation byte",as.BAD_PREFIX="bad codepoint prefix",as.OVERRUN="string overrun",as.MISSING_CONTINUE="missing continuation byte",as.OUT_OF_RANGE="out of UTF-8 range",as.UTF16_SURROGATE="UTF-16 surrogate",as.OVERLONG="overlong representation";const ls=Object.freeze({error:function(t,e,r,n,i){return ns.throwArgumentError(`invalid codepoint at offset ${e}; ${t}`,"bytes",r)},ignore:us,replace:function(t,e,r,n,i){return t===ss.OVERLONG?(n.push(i),0):(n.push(65533),us(t,e,r))}});function hs(t,e){null==e&&(e=ls.error),t=li(t);const r=[];let n=0;for(;n>7==0){r.push(i);continue}let o=null,s=null;if(192==(224&i))o=1,s=127;else if(224==(240&i))o=2,s=2047;else{if(240!=(248&i)){n+=e(128==(192&i)?ss.UNEXPECTED_CONTINUE:ss.BAD_PREFIX,n-1,t,r);continue}o=3,s=65535}if(n-1+o>=t.length){n+=e(ss.OVERRUN,n-1,t,r);continue}let a=i&(1<<8-o-1)-1;for(let u=0;u1114111?n+=e(ss.OUT_OF_RANGE,n-1-o,t,r,a):a>=55296&&a<=57343?n+=e(ss.UTF16_SURROGATE,n-1-o,t,r,a):a<=s?n+=e(ss.OVERLONG,n-1-o,t,r,a):r.push(a))}return r}function cs(t,e=is.current){e!=is.current&&(ns.checkNormalize(),t=t.normalize(e));let r=[];for(let n=0;n>6|192),r.push(63&e|128);else if(55296==(64512&e)){n++;const i=t.charCodeAt(n);if(n>=t.length||56320!=(64512&i))throw new Error("invalid utf-8 string");const o=65536+((1023&e)<<10)+(1023&i);r.push(o>>18|240),r.push(o>>12&63|128),r.push(o>>6&63|128),r.push(63&o|128)}else r.push(e>>12|224),r.push(e>>6&63|128),r.push(63&e|128)}return li(r)}function fs(t){return t.map((t=>t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode(55296+(t>>10&1023),56320+(1023&t))))).join("")}function ds(t,e){return fs(hs(t,e))}function ps(t,e=is.current){return hs(cs(t,e))}function ms(t,e){e||(e=function(t){return[parseInt(t,16)]});let r=0,n={};return t.split(",").forEach((t=>{let i=t.split(":");r+=parseInt(i[0],16),n[r]=e(i[1])})),n}function gs(t){let e=0;return t.split(",").map((t=>{let r=t.split("-");1===r.length?r[1]="0":""===r[1]&&(r[1]="1");let n=e+parseInt(r[0],16);return e=parseInt(r[1],16),{l:n,h:e}}))}function vs(t,e){let r=0;for(let n=0;n=r&&t<=r+i.h&&(t-r)%(i.d||1)==0){if(i.e&&-1!==i.e.indexOf(t-r))continue;return i}}return null}const ys=gs("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"),bs="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((t=>parseInt(t,16))),ws=[{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}],_s=ms("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"),Es=ms("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"),As=ms("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",(function(t){if(t.length%4!=0)throw new Error("bad data");let e=[];for(let r=0;r{if(bs.indexOf(t)>=0)return[];if(t>=65024&&t<=65039)return[];let e=function(t){let e=vs(t,ws);if(e)return[t+e.s];let r=_s[t];if(r)return r;let n=Es[t];return n?[t+n[0]]:As[t]||null}(t);return e||[t]})),e=r.reduce(((t,e)=>(e.forEach((e=>{t.push(e)})),t)),[]),e=ps(fs(e),is.NFKC),e.forEach((t=>{if(vs(t,Ms))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),e.forEach((t=>{if(vs(t,ys))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));let n=fs(e);if("-"===n.substring(0,1)||"--"===n.substring(2,4)||"-"===n.substring(n.length-1))throw new Error("invalid hyphen");if(n.length>63)throw new Error("too long");return n}class Ns extends Jo{constructor(t){super("string",t)}defaultValue(){return""}encode(t,e){return super.encode(t,cs(e))}decode(t){return ds(super.decode(t))}}class xs extends Eo{constructor(t,e){let r=!1;const n=[];t.forEach((t=>{t.dynamic&&(r=!0),n.push(t.type)}));super("tuple","tuple("+n.join(",")+")",e,r),this.coders=t}defaultValue(){const t=[];this.coders.forEach((e=>{t.push(e.defaultValue())}));const e=this.coders.reduce(((t,e)=>{const r=e.localName;return r&&(t[r]||(t[r]=0),t[r]++),t}),{});return this.coders.forEach(((r,n)=>{let i=r.localName;i&&1===e[i]&&("length"===i&&(i="_length"),null==t[i]&&(t[i]=t[n]))})),Object.freeze(t)}encode(t,e){return $o(t,this.coders,e)}decode(t){return t.coerce(this.name,Ho(t,this.coders))}}const Ss=new ni("abi/5.1.1"),Is=new RegExp(/^bytes([0-9]*)$/),Rs=new RegExp(/^(u?int)([0-9]*)$/);class Ps{constructor(t){Ss.checkNew(new.target,Ps),$i(this,"coerceFunc",t||null)}_getCoder(t){switch(t.baseType){case"address":return new Do(t.name);case"bool":return new Wo(t.name);case"string":return new Ns(t.name);case"bytes":return new Ko(t.name);case"array":return new Go(this._getCoder(t.arrayChildren),t.arrayLength,t.name);case"tuple":return new xs((t.components||[]).map((t=>this._getCoder(t))),t.name);case"":return new Xo(t.name)}let e=t.type.match(Rs);if(e){let r=parseInt(e[2]||"256");return(0===r||r>256||r%8!=0)&&Ss.throwArgumentError("invalid "+e[1]+" bit length","param",t),new rs(r/8,"int"===e[1],t.name)}if(e=t.type.match(Is),e){let r=parseInt(e[1]);return(0===r||r>32)&&Ss.throwArgumentError("invalid bytes length","param",t),new Zo(r,t.name)}return Ss.throwArgumentError("invalid type","type",t.type)}_getWordSize(){return 32}_getReader(t,e){return new Mo(t,this._getWordSize(),this.coerceFunc,e)}_getWriter(){return new Ao(this._getWordSize())}getDefaultValue(t){const e=t.map((t=>this._getCoder(ao.from(t))));return new xs(e,"_").defaultValue()}encode(t,e){t.length!==e.length&&Ss.throwError("types/values length mismatch",ni.errors.INVALID_ARGUMENT,{count:{types:t.length,values:e.length},value:{types:t,values:e}});const r=t.map((t=>this._getCoder(ao.from(t)))),n=new xs(r,"_"),i=this._getWriter();return n.encode(i,e),i.data}decode(t,e,r){const n=t.map((t=>this._getCoder(ao.from(t))));return new xs(n,"_").decode(this._getReader(li(e),r))}}const Ts=new Ps;function Os(t){return No(cs(t))}const Bs=new ni("hash/5.1.0"),Cs=new Uint8Array(32);Cs.fill(0);const Fs=new RegExp("^((.*)\\.)?([^.]+)$");function Ls(t){"string"!=typeof t&&Bs.throwArgumentError("invalid address - "+String(t),"name",t);let e=Cs;for(;t.length;){const r=t.match(Fs);e=No(hi([e,No(cs(ks(r[3])))])),t=r[2]||""}return di(e)}var Us=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const js=new ni("hash/5.1.0"),zs=new Uint8Array(32);zs.fill(0);const Ds=Mi.from(-1),qs=Mi.from(0),Vs=Mi.from(1),$s=Mi.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const Hs=yi(Vs.toHexString(),32),Gs=yi(qs.toHexString(),32),Ws={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},Js=["name","version","chainId","verifyingContract","salt"];function Ks(t){return function(e){return"string"!=typeof e&&js.throwArgumentError(`invalid domain value for ${JSON.stringify(t)}`,`domain.${t}`,e),e}}const Zs={name:Ks("name"),version:Ks("version"),chainId:function(t){try{return Mi.from(t).toString()}catch(e){}return js.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",t)},verifyingContract:function(t){try{return jo(t).toLowerCase()}catch(e){}return js.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",t)},salt:function(t){try{const e=li(t);if(32!==e.length)throw new Error("bad length");return di(e)}catch(e){}return js.throwArgumentError('invalid domain value "salt"',"domain.salt",t)}};function Xs(t){{const e=t.match(/^(u?)int(\d*)$/);if(e){const r=""===e[1],n=parseInt(e[2]||"256");(n%8!=0||n>256||e[2]&&e[2]!==String(n))&&js.throwArgumentError("invalid numeric width","type",t);const i=$s.mask(r?n-1:n),o=r?i.add(Vs).mul(Ds):qs;return function(e){const r=Mi.from(e);return(r.lt(o)||r.gt(i))&&js.throwArgumentError(`value out-of-bounds for ${t}`,"value",e),yi(r.toTwos(256).toHexString(),32)}}}{const e=t.match(/^bytes(\d+)$/);if(e){const r=parseInt(e[1]);return(0===r||r>32||e[1]!==String(r))&&js.throwArgumentError("invalid bytes width","type",t),function(e){return li(e).length!==r&&js.throwArgumentError(`invalid length for ${t}`,"value",e),function(t){const e=li(t),r=e.length%32;return r?gi([e,zs.slice(r)]):di(e)}(e)}}}switch(t){case"address":return function(t){return yi(jo(t),32)};case"bool":return function(t){return t?Hs:Gs};case"bytes":return function(t){return No(t)};case"string":return function(t){return Os(t)}}return null}function Qs(t,e){return`${t}(${e.map((({name:t,type:e})=>e+" "+t)).join(",")})`}class Ys{constructor(t){$i(this,"types",Object.freeze(Xi(t))),$i(this,"_encoderCache",{}),$i(this,"_types",{});const e={},r={},n={};Object.keys(t).forEach((t=>{e[t]={},r[t]=[],n[t]={}}));for(const o in t){const n={};t[o].forEach((i=>{n[i.name]&&js.throwArgumentError(`duplicate variable name ${JSON.stringify(i.name)} in ${JSON.stringify(o)}`,"types",t),n[i.name]=!0;const s=i.type.match(/^([^\x5b]*)(\x5b|$)/)[1];s===o&&js.throwArgumentError(`circular type reference to ${JSON.stringify(s)}`,"types",t);Xs(s)||(r[s]||js.throwArgumentError(`unknown type ${JSON.stringify(s)}`,"types",t),r[s].push(o),e[o][s]=!0)}))}const i=Object.keys(r).filter((t=>0===r[t].length));0===i.length?js.throwArgumentError("missing primary type","types",t):i.length>1&&js.throwArgumentError(`ambiguous primary types or unused types: ${i.map((t=>JSON.stringify(t))).join(", ")}`,"types",t),$i(this,"primaryType",i[0]),function i(o,s){s[o]&&js.throwArgumentError(`circular type reference to ${JSON.stringify(o)}`,"types",t),s[o]=!0,Object.keys(e[o]).forEach((t=>{r[t]&&(i(t,s),Object.keys(s).forEach((e=>{n[e][t]=!0})))})),delete s[o]}(this.primaryType,{});for(const o in n){const e=Object.keys(n[o]);e.sort(),this._types[o]=Qs(o,t[o])+e.map((e=>Qs(e,t[e]))).join("")}}getEncoder(t){let e=this._encoderCache[t];return e||(e=this._encoderCache[t]=this._getEncoder(t)),e}_getEncoder(t){{const e=Xs(t);if(e)return e}const e=t.match(/^(.*)(\x5b(\d*)\x5d)$/);if(e){const t=e[1],r=this.getEncoder(t),n=parseInt(e[3]);return e=>{n>=0&&e.length!==n&&js.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);let i=e.map(r);return this._types[t]&&(i=i.map(No)),No(gi(i))}}const r=this.types[t];if(r){const e=Os(this._types[t]);return t=>{const n=r.map((({name:e,type:r})=>{const n=this.getEncoder(r)(t[e]);return this._types[r]?No(n):n}));return n.unshift(e),gi(n)}}return js.throwArgumentError(`unknown type: ${t}`,"type",t)}encodeType(t){const e=this._types[t];return e||js.throwArgumentError(`unknown type: ${JSON.stringify(t)}`,"name",t),e}encodeData(t,e){return this.getEncoder(t)(e)}hashStruct(t,e){return No(this.encodeData(t,e))}encode(t){return this.encodeData(this.primaryType,t)}hash(t){return this.hashStruct(this.primaryType,t)}_visit(t,e,r){if(Xs(t))return r(t,e);const n=t.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){const t=n[1],i=parseInt(n[3]);return i>=0&&e.length!==i&&js.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e),e.map((e=>this._visit(t,e,r)))}const i=this.types[t];return i?i.reduce(((t,{name:n,type:i})=>(t[n]=this._visit(i,e[n],r),t)),{}):js.throwArgumentError(`unknown type: ${t}`,"type",t)}visit(t,e){return this._visit(this.primaryType,t,e)}static from(t){return new Ys(t)}static getPrimaryType(t){return Ys.from(t).primaryType}static hashStruct(t,e,r){return Ys.from(e).hashStruct(t,r)}static hashDomain(t){const e=[];for(const r in t){const n=Ws[r];n||js.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",t),e.push({name:r,type:n})}return e.sort(((t,e)=>Js.indexOf(t.name)-Js.indexOf(e.name))),Ys.hashStruct("EIP712Domain",{EIP712Domain:e},t)}static encode(t,e,r){return gi(["0x1901",Ys.hashDomain(t),Ys.from(e).hash(r)])}static hash(t,e,r){return No(Ys.encode(t,e,r))}static resolveNames(t,e,r,n){return Us(this,void 0,void 0,(function*(){t=Wi(t);const i={};t.verifyingContract&&!fi(t.verifyingContract,20)&&(i[t.verifyingContract]="0x");const o=Ys.from(e);o.visit(r,((t,e)=>("address"!==t||fi(e,20)||(i[e]="0x"),e)));for(const t in i)i[t]=yield n(t);return t.verifyingContract&&i[t.verifyingContract]&&(t.verifyingContract=i[t.verifyingContract]),r=o.visit(r,((t,e)=>"address"===t&&i[e]?i[e]:e)),{domain:t,value:r}}))}static getPayload(t,e,r){Ys.hashDomain(t);const n={},i=[];Js.forEach((e=>{const r=t[e];null!=r&&(n[e]=Zs[e](r),i.push({name:e,type:Ws[e]}))}));const o=Ys.from(e),s=Wi(e);return s.EIP712Domain?js.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",e):s.EIP712Domain=i,o.encode(r),{types:s,domain:n,primaryType:o.primaryType,message:o.visit(r,((t,e)=>{if(t.match(/^bytes(\d*)/))return di(li(e));if(t.match(/^u?int/))return Mi.from(e).toString();switch(t){case"address":return e.toLowerCase();case"bool":return!!e;case"string":return"string"!=typeof e&&js.throwArgumentError("invalid string","value",e),e}return js.throwArgumentError("unsupported type","type",t)}))}}}const ta=new ni("abi/5.1.1");class ea extends Qi{}class ra extends Qi{}class na extends Qi{static isIndexed(t){return!(!t||!t._isIndexed)}}function ia(t,e){const r=new Error(`deferred error during ABI decoding triggered accessing ${t}`);return r.error=e,r}class oa{constructor(t){ta.checkNew(new.target,oa);let e=[];e="string"==typeof t?JSON.parse(t):t,$i(this,"fragments",e.map((t=>lo.from(t))).filter((t=>null!=t))),$i(this,"_abiCoder",Hi(new.target,"getAbiCoder")()),$i(this,"functions",{}),$i(this,"errors",{}),$i(this,"events",{}),$i(this,"structs",{}),this.fragments.forEach((t=>{let e=null;switch(t.type){case"constructor":return this.deploy?void ta.warn("duplicate definition - constructor"):void $i(this,"deploy",t);case"function":e=this.functions;break;case"event":e=this.events;break;default:return}let r=t.format();e[r]?ta.warn("duplicate definition - "+r):e[r]=t})),this.deploy||$i(this,"deploy",mo.from({payable:!1,type:"constructor"})),$i(this,"_isInterface",!0)}format(t){t||(t=oo.full),t===oo.sighash&&ta.throwArgumentError("interface does not support formatting sighash","format",t);const e=this.fragments.map((e=>e.format(t)));return t===oo.json?JSON.stringify(e.map((t=>JSON.parse(t)))):e}static getAbiCoder(){return Ts}static getAddress(t){return jo(t)}static getSighash(t){return mi(Os(t.format()),0,4)}static getEventTopic(t){return Os(t.format())}getFunction(t){if(fi(t)){for(const e in this.functions)if(t===this.getSighash(e))return this.functions[e];ta.throwArgumentError("no matching function","sighash",t)}if(-1===t.indexOf("(")){const e=t.trim(),r=Object.keys(this.functions).filter((t=>t.split("(")[0]===e));return 0===r.length?ta.throwArgumentError("no matching function","name",e):r.length>1&&ta.throwArgumentError("multiple matching functions","name",e),this.functions[r[0]]}const e=this.functions[go.fromString(t).format()];return e||ta.throwArgumentError("no matching function","signature",t),e}getEvent(t){if(fi(t)){const e=t.toLowerCase();for(const t in this.events)if(e===this.getEventTopic(t))return this.events[t];ta.throwArgumentError("no matching event","topichash",e)}if(-1===t.indexOf("(")){const e=t.trim(),r=Object.keys(this.events).filter((t=>t.split("(")[0]===e));return 0===r.length?ta.throwArgumentError("no matching event","name",e):r.length>1&&ta.throwArgumentError("multiple matching events","name",e),this.events[r[0]]}const e=this.events[ho.fromString(t).format()];return e||ta.throwArgumentError("no matching event","signature",t),e}getSighash(t){return"string"==typeof t&&(t=this.getFunction(t)),Hi(this.constructor,"getSighash")(t)}getEventTopic(t){return"string"==typeof t&&(t=this.getEvent(t)),Hi(this.constructor,"getEventTopic")(t)}_decodeParams(t,e){return this._abiCoder.decode(t,e)}_encodeParams(t,e){return this._abiCoder.encode(t,e)}encodeDeploy(t){return this._encodeParams(this.deploy.inputs,t||[])}decodeFunctionData(t,e){"string"==typeof t&&(t=this.getFunction(t));const r=li(e);return di(r.slice(0,4))!==this.getSighash(t)&&ta.throwArgumentError(`data signature does not match function ${t.name}.`,"data",di(r)),this._decodeParams(t.inputs,r.slice(4))}encodeFunctionData(t,e){return"string"==typeof t&&(t=this.getFunction(t)),di(hi([this.getSighash(t),this._encodeParams(t.inputs,e||[])]))}decodeFunctionResult(t,e){"string"==typeof t&&(t=this.getFunction(t));let r=li(e),n=null,i=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(t.outputs,r)}catch(o){}break;case 4:"0x08c379a0"===di(r.slice(0,4))&&(i="Error(string)",n=this._abiCoder.decode(["string"],r.slice(4))[0])}return ta.throwError("call revert exception",ni.errors.CALL_EXCEPTION,{method:t.format(),errorSignature:i,errorArgs:[n],reason:n})}encodeFunctionResult(t,e){return"string"==typeof t&&(t=this.getFunction(t)),di(this._abiCoder.encode(t.outputs,e||[]))}encodeFilterTopics(t,e){"string"==typeof t&&(t=this.getEvent(t)),e.length>t.inputs.length&&ta.throwError("too many arguments for "+t.format(),ni.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:e});let r=[];t.anonymous||r.push(this.getEventTopic(t));const n=(t,e)=>"string"===t.type?Os(e):"bytes"===t.type?No(di(e)):("address"===t.type&&this._abiCoder.encode(["address"],[e]),yi(di(e),32));for(e.forEach(((e,i)=>{let o=t.inputs[i];o.indexed?null==e?r.push(null):"array"===o.baseType||"tuple"===o.baseType?ta.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,e):Array.isArray(e)?r.push(e.map((t=>n(o,t)))):r.push(n(o,e)):null!=e&&ta.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,e)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(t,e){"string"==typeof t&&(t=this.getEvent(t));const r=[],n=[],i=[];return t.anonymous||r.push(this.getEventTopic(t)),e.length!==t.inputs.length&&ta.throwArgumentError("event arguments/values mismatch","values",e),t.inputs.forEach(((t,o)=>{const s=e[o];if(t.indexed)if("string"===t.type)r.push(Os(s));else if("bytes"===t.type)r.push(No(s));else{if("tuple"===t.baseType||"array"===t.baseType)throw new Error("not implemented");r.push(this._abiCoder.encode([t.type],[s]))}else n.push(t),i.push(s)})),{data:this._abiCoder.encode(n,i),topics:r}}decodeEventLog(t,e,r){if("string"==typeof t&&(t=this.getEvent(t)),null!=r&&!t.anonymous){let e=this.getEventTopic(t);fi(r[0],32)&&r[0].toLowerCase()===e||ta.throwError("fragment/topic mismatch",ni.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:e,value:r[0]}),r=r.slice(1)}let n=[],i=[],o=[];t.inputs.forEach(((t,e)=>{t.indexed?"string"===t.type||"bytes"===t.type||"tuple"===t.baseType||"array"===t.baseType?(n.push(ao.fromObject({type:"bytes32",name:t.name})),o.push(!0)):(n.push(t),o.push(!1)):(i.push(t),o.push(!1))}));let s=null!=r?this._abiCoder.decode(n,hi(r)):null,a=this._abiCoder.decode(i,e,!0),u=[],l=0,h=0;t.inputs.forEach(((t,e)=>{if(t.indexed)if(null==s)u[e]=new na({_isIndexed:!0,hash:null});else if(o[e])u[e]=new na({_isIndexed:!0,hash:s[h++]});else try{u[e]=s[h++]}catch(r){u[e]=r}else try{u[e]=a[l++]}catch(r){u[e]=r}if(t.name&&null==u[t.name]){const r=u[e];r instanceof Error?Object.defineProperty(u,t.name,{get:()=>{throw ia(`property ${JSON.stringify(t.name)}`,r)}}):u[t.name]=r}}));for(let c=0;c{throw ia(`index ${c}`,t)}})}return Object.freeze(u)}parseTransaction(t){let e=this.getFunction(t.data.substring(0,10).toLowerCase());return e?new ra({args:this._abiCoder.decode(e.inputs,"0x"+t.data.substring(10)),functionFragment:e,name:e.name,signature:e.format(),sighash:this.getSighash(e),value:Mi.from(t.value||"0")}):null}parseLog(t){let e=this.getEvent(t.topics[0]);return!e||e.anonymous?null:new ea({eventFragment:e,name:e.name,signature:e.format(),topic:this.getEventTopic(e),args:this.decodeEventLog(e,t.data,t.topics)})}static isInterface(t){return!(!t||!t._isInterface)}}const sa=new ni("abstract-provider/5.1.0");class aa extends Qi{static isForkEvent(t){return!(!t||!t._isForkEvent)}}class ua{constructor(){sa.checkAbstract(new.target,ua),$i(this,"_isProvider",!0)}addListener(t,e){return this.on(t,e)}removeListener(t,e){return this.off(t,e)}static isProvider(t){return!(!t||!t._isProvider)}}var la=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const ha=new ni("abstract-signer/5.1.0"),ca=["accessList","chainId","data","from","gasLimit","gasPrice","nonce","to","type","value"],fa=[ni.errors.INSUFFICIENT_FUNDS,ni.errors.NONCE_EXPIRED,ni.errors.REPLACEMENT_UNDERPRICED];class da{constructor(){ha.checkAbstract(new.target,da),$i(this,"_isSigner",!0)}getBalance(t){return la(this,void 0,void 0,(function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),t)}))}getTransactionCount(t){return la(this,void 0,void 0,(function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),t)}))}estimateGas(t){return la(this,void 0,void 0,(function*(){this._checkProvider("estimateGas");const e=yield Gi(this.checkTransaction(t));return yield this.provider.estimateGas(e)}))}call(t,e){return la(this,void 0,void 0,(function*(){this._checkProvider("call");const r=yield Gi(this.checkTransaction(t));return yield this.provider.call(r,e)}))}sendTransaction(t){return this._checkProvider("sendTransaction"),this.populateTransaction(t).then((t=>this.signTransaction(t).then((t=>this.provider.sendTransaction(t)))))}getChainId(){return la(this,void 0,void 0,(function*(){this._checkProvider("getChainId");return(yield this.provider.getNetwork()).chainId}))}getGasPrice(){return la(this,void 0,void 0,(function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()}))}resolveName(t){return la(this,void 0,void 0,(function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(t)}))}checkTransaction(t){for(const r in t)-1===ca.indexOf(r)&&ha.throwArgumentError("invalid transaction key: "+r,"transaction",t);const e=Wi(t);return null==e.from?e.from=this.getAddress():e.from=Promise.all([Promise.resolve(e.from),this.getAddress()]).then((e=>(e[0].toLowerCase()!==e[1].toLowerCase()&&ha.throwArgumentError("from address mismatch","transaction",t),e[0]))),e}populateTransaction(t){return la(this,void 0,void 0,(function*(){const e=yield Gi(this.checkTransaction(t));return null!=e.to&&(e.to=Promise.resolve(e.to).then((t=>la(this,void 0,void 0,(function*(){if(null==t)return null;const e=yield this.resolveName(t);return null==e&&ha.throwArgumentError("provided ENS name resolves to null","tx.to",t),e}))))),null==e.gasPrice&&(e.gasPrice=this.getGasPrice()),null==e.nonce&&(e.nonce=this.getTransactionCount("pending")),null==e.gasLimit&&(e.gasLimit=this.estimateGas(e).catch((t=>{if(fa.indexOf(t.code)>=0)throw t;return ha.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ni.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,tx:e})}))),null==e.chainId?e.chainId=this.getChainId():e.chainId=Promise.all([Promise.resolve(e.chainId),this.getChainId()]).then((e=>(0!==e[1]&&e[0]!==e[1]&&ha.throwArgumentError("chainId address mismatch","transaction",t),e[0]))),yield Gi(e)}))}_checkProvider(t){this.provider||ha.throwError("missing provider",ni.errors.UNSUPPORTED_OPERATION,{operation:t||"_checkProvider"})}static isSigner(t){return!(!t||!t._isSigner)}}class pa extends da{constructor(t,e){ha.checkNew(new.target,pa),super(),$i(this,"address",t),$i(this,"provider",e||null)}getAddress(){return Promise.resolve(this.address)}_fail(t,e){return Promise.resolve().then((()=>{ha.throwError(t,ni.errors.UNSUPPORTED_OPERATION,{operation:e})}))}signMessage(t){return this._fail("VoidSigner cannot sign messages","signMessage")}signTransaction(t){return this._fail("VoidSigner cannot sign transactions","signTransaction")}_signTypedData(t,e,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}connect(t){return new pa(this.address,t)}}var ma=ga;function ga(t,e){if(!t)throw new Error(e||"Assertion failed")}function va(t){return(t>>>24|t>>>8&65280|t<<8&16711680|(255&t)<<24)>>>0}function ya(t){return 1===t.length?"0"+t:t}function ba(t){return 7===t.length?"0"+t:6===t.length?"00"+t:5===t.length?"000"+t:4===t.length?"0000"+t:3===t.length?"00000"+t:2===t.length?"000000"+t:1===t.length?"0000000"+t:t}ga.equal=function(t,e,r){if(t!=e)throw new Error(r||"Assertion failed: "+t+" != "+e)};var wa={inherits:$n((function(t){"function"==typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}})),toArray:function(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if("string"==typeof t)if(e){if("hex"===e)for((t=t.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(t="0"+t),n=0;n>8,s=255&i;o?r.push(o,s):r.push(s)}else for(n=0;n>>0}return o},split32:function(t,e){for(var r=new Array(4*t.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},rotr32:function(t,e){return t>>>e|t<<32-e},rotl32:function(t,e){return t<>>32-e},sum32:function(t,e){return t+e>>>0},sum32_3:function(t,e,r){return t+e+r>>>0},sum32_4:function(t,e,r,n){return t+e+r+n>>>0},sum32_5:function(t,e,r,n,i){return t+e+r+n+i>>>0},sum64:function(t,e,r,n){var i=t[e],o=n+t[e+1]>>>0,s=(o>>0,t[e+1]=o},sum64_hi:function(t,e,r,n){return(e+n>>>0>>0},sum64_lo:function(t,e,r,n){return e+n>>>0},sum64_4_hi:function(t,e,r,n,i,o,s,a){var u=0,l=e;return u+=(l=l+n>>>0)>>0)>>0)>>0},sum64_4_lo:function(t,e,r,n,i,o,s,a){return e+n+o+a>>>0},sum64_5_hi:function(t,e,r,n,i,o,s,a,u,l){var h=0,c=e;return h+=(c=c+n>>>0)>>0)>>0)>>0)>>0},sum64_5_lo:function(t,e,r,n,i,o,s,a,u,l){return e+n+o+a+l>>>0},rotr64_hi:function(t,e,r){return(e<<32-r|t>>>r)>>>0},rotr64_lo:function(t,e,r){return(t<<32-r|e>>>r)>>>0},shr64_hi:function(t,e,r){return t>>>r},shr64_lo:function(t,e,r){return(t<<32-r|e>>>r)>>>0}};function _a(){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}var Ea=_a;_a.prototype.update=function(t,e){if(t=wa.toArray(t,e),this.pending?this.pending=this.pending.concat(t):this.pending=t,this.pendingTotal+=t.length,this.pending.length>=this._delta8){var r=(t=this.pending).length%this._delta8;this.pending=t.slice(t.length-r,t.length),0===this.pending.length&&(this.pending=null),t=wa.join32(t,0,t.length-r,this.endian);for(var n=0;n>>24&255,n[i++]=t>>>16&255,n[i++]=t>>>8&255,n[i++]=255&t}else for(n[i++]=255&t,n[i++]=t>>>8&255,n[i++]=t>>>16&255,n[i++]=t>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o>>3},g1_256:function(t){return Ma(t,17)^Ma(t,19)^t>>>10}},Ia=wa.rotl32,Ra=wa.sum32,Pa=wa.sum32_5,Ta=Sa.ft_1,Oa=Aa.BlockHash,Ba=[1518500249,1859775393,2400959708,3395469782];function Ca(){if(!(this instanceof Ca))return new Ca;Oa.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}wa.inherits(Ca,Oa);var Fa=Ca;Ca.blockSize=512,Ca.outSize=160,Ca.hmacStrength=80,Ca.padLength=64,Ca.prototype._update=function(t,e){for(var r=this.W,n=0;n<16;n++)r[n]=t[e+n];for(;nthis.blockSize&&(t=(new this.Hash).update(t).digest()),ma(t.length<=this.blockSize);for(var e=t.length;e>8,s=255&i;o?r.push(o,s):r.push(s)}return r},r.zero2=n,r.toHex=i,r.encode=function(t,e){return"hex"===e?i(t):t}})),Zu=Gu((function(t,e){var r=e;r.assert=Wu,r.toArray=Ku.toArray,r.zero2=Ku.zero2,r.toHex=Ku.toHex,r.encode=Ku.encode,r.getNAF=function(t,e,r){var n=new Array(Math.max(t.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(a)):a=0,n[s]=a,o.iushrn(1)}return n},r.getJSF=function(t,e){var r=[[],[]];t=t.clone(),e=e.clone();for(var n,i=0,o=0;t.cmpn(-i)>0||e.cmpn(-o)>0;){var s,a,u=t.andln(3)+i&3,l=e.andln(3)+o&3;3===u&&(u=-1),3===l&&(l=-1),s=0==(1&u)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==l?u:-u,r[0].push(s),a=0==(1&l)?0:3!==(n=e.andln(7)+o&7)&&5!==n||2!==u?l:-l,r[1].push(a),2*i===s+1&&(i=1-i),2*o===a+1&&(o=1-o),t.iushrn(1),e.iushrn(1)}return r},r.cachedProperty=function(t,e,r){var n="_"+e;t.prototype[e]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(t){return"string"==typeof t?r.toArray(t,"hex"):t},r.intFromLE=function(t){return new Gn(t,"hex","le")}})),Xu=Zu.getNAF,Qu=Zu.getJSF,Yu=Zu.assert;function tl(t,e){this.type=t,this.p=new Gn(e.p,16),this.red=e.prime?Gn.red(e.prime):Gn.mont(this.p),this.zero=new Gn(0).toRed(this.red),this.one=new Gn(1).toRed(this.red),this.two=new Gn(2).toRed(this.red),this.n=e.n&&new Gn(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))}var el=tl;function rl(t,e){this.curve=t,this.type=e,this.precomputed=null}tl.prototype.point=function(){throw new Error("Not implemented")},tl.prototype.validate=function(){throw new Error("Not implemented")},tl.prototype._fixedNafMul=function(t,e){Yu(t.precomputed);var r=t._getDoubles(),n=Xu(e,1,this._bitLength),i=(1<=o;u--)s=(s<<1)+n[u];a.push(s)}for(var l=this.jpoint(null,null,null),h=this.jpoint(null,null,null),c=i;c>0;c--){for(o=0;o=0;a--){for(var u=0;a>=0&&0===o[a];a--)u++;if(a>=0&&u++,s=s.dblp(u),a<0)break;var l=o[a];Yu(0!==l),s="affine"===t.type?l>0?s.mixedAdd(i[l-1>>1]):s.mixedAdd(i[-l-1>>1].neg()):l>0?s.add(i[l-1>>1]):s.add(i[-l-1>>1].neg())}return"affine"===t.type?s.toP():s},tl.prototype._wnafMulAdd=function(t,e,r,n,i){var o,s,a,u=this._wnafT1,l=this._wnafT2,h=this._wnafT3,c=0;for(o=0;o=1;o-=2){var d=o-1,p=o;if(1===u[d]&&1===u[p]){var m=[e[d],null,null,e[p]];0===e[d].y.cmp(e[p].y)?(m[1]=e[d].add(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg())):0===e[d].y.cmp(e[p].y.redNeg())?(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].add(e[p].neg())):(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],v=Qu(r[d],r[p]);for(c=Math.max(v[0].length,c),h[d]=new Array(c),h[p]=new Array(c),s=0;s=0;o--){for(var E=0;o>=0;){var A=!0;for(s=0;s=0&&E++,w=w.dblp(E),o<0)break;for(s=0;s0?a=l[s][M-1>>1]:M<0&&(a=l[s][-M-1>>1].neg()),w="affine"===a.type?w.mixedAdd(a):w.add(a))}}for(o=0;o=Math.ceil((t.bitLength()+1)/e.step)},rl.prototype._getDoubles=function(t,e){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(o=e,s=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),s=s.neg()),[{a:n,b:i},{a:o,b:s}]},ol.prototype._endoSplit=function(t){var e=this.endo.basis,r=e[0],n=e[1],i=n.b.mul(t).divRound(this.n),o=r.b.neg().mul(t).divRound(this.n),s=i.mul(r.a),a=o.mul(n.a),u=i.mul(r.b),l=o.mul(n.b);return{k1:t.sub(s).sub(a),k2:u.add(l).neg()}},ol.prototype.pointFromX=function(t,e){(t=new Gn(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr().redMul(t).redIAdd(t.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(e&&!i||!e&&i)&&(n=n.redNeg()),this.point(t,n)},ol.prototype.validate=function(t){if(t.inf)return!0;var e=t.x,r=t.y,n=this.a.redMul(e),i=e.redSqr().redMul(e).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},ol.prototype._endoWnafMulAdd=function(t,e,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},al.prototype.isInfinity=function(){return this.inf},al.prototype.add=function(t){if(this.inf)return t;if(t.inf)return this;if(this.eq(t))return this.dbl();if(this.neg().eq(t))return this.curve.point(null,null);if(0===this.x.cmp(t.x))return this.curve.point(null,null);var e=this.y.redSub(t.y);0!==e.cmpn(0)&&(e=e.redMul(this.x.redSub(t.x).redInvm()));var r=e.redSqr().redISub(this.x).redISub(t.x),n=e.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},al.prototype.dbl=function(){if(this.inf)return this;var t=this.y.redAdd(this.y);if(0===t.cmpn(0))return this.curve.point(null,null);var e=this.curve.a,r=this.x.redSqr(),n=t.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(e).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),s=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,s)},al.prototype.getX=function(){return this.x.fromRed()},al.prototype.getY=function(){return this.y.fromRed()},al.prototype.mul=function(t){return t=new Gn(t,16),this.isInfinity()?this:this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve.endo?this.curve._endoWnafMulAdd([this],[t]):this.curve._wnafMul(this,t)},al.prototype.mulAdd=function(t,e,r){var n=[this,e],i=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},al.prototype.jmulAdd=function(t,e,r){var n=[this,e],i=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},al.prototype.eq=function(t){return this===t||this.inf===t.inf&&(this.inf||0===this.x.cmp(t.x)&&0===this.y.cmp(t.y))},al.prototype.neg=function(t){if(this.inf)return this;var e=this.curve.point(this.x,this.y.redNeg());if(t&&this.precomputed){var r=this.precomputed,n=function(t){return t.neg()};e.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return e},al.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},nl(ul,el.BasePoint),ol.prototype.jpoint=function(t,e,r){return new ul(this,t,e,r)},ul.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var t=this.z.redInvm(),e=t.redSqr(),r=this.x.redMul(e),n=this.y.redMul(e).redMul(t);return this.curve.point(r,n)},ul.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},ul.prototype.add=function(t){if(this.isInfinity())return t;if(t.isInfinity())return this;var e=t.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(e),i=t.x.redMul(r),o=this.y.redMul(e.redMul(t.z)),s=t.y.redMul(r.redMul(this.z)),a=n.redSub(i),u=o.redSub(s);if(0===a.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=a.redSqr(),h=l.redMul(a),c=n.redMul(l),f=u.redSqr().redIAdd(h).redISub(c).redISub(c),d=u.redMul(c.redISub(f)).redISub(o.redMul(h)),p=this.z.redMul(t.z).redMul(a);return this.curve.jpoint(f,d,p)},ul.prototype.mixedAdd=function(t){if(this.isInfinity())return t.toJ();if(t.isInfinity())return this;var e=this.z.redSqr(),r=this.x,n=t.x.redMul(e),i=this.y,o=t.y.redMul(e).redMul(this.z),s=r.redSub(n),a=i.redSub(o);if(0===s.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=s.redSqr(),l=u.redMul(s),h=r.redMul(u),c=a.redSqr().redIAdd(l).redISub(h).redISub(h),f=a.redMul(h.redISub(c)).redISub(i.redMul(l)),d=this.z.redMul(s);return this.curve.jpoint(c,f,d)},ul.prototype.dblp=function(t){if(0===t)return this;if(this.isInfinity())return this;if(!t)return this.dbl();var e;if(this.curve.zeroA||this.curve.threeA){var r=this;for(e=0;e=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},ul.prototype.inspect=function(){return this.isInfinity()?"":""},ul.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var ll=Gu((function(t,e){var r=e;r.base=el,r.short=sl,r.mont=null,r.edwards=null})),hl=Gu((function(t,e){var r,n=e,i=Zu.assert;function o(t){"short"===t.type?this.curve=new ll.short(t):"edwards"===t.type?this.curve=new ll.edwards(t):this.curve=new ll.mont(t),this.g=this.curve.g,this.n=this.curve.n,this.hash=t.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function s(t,e){Object.defineProperty(n,t,{configurable:!0,enumerable:!0,get:function(){var r=new o(e);return Object.defineProperty(n,t,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,s("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:Hu.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),s("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:Hu.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),s("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:Hu.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),s("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:Hu.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"]}),s("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:Hu.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"]}),s("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Hu.sha256,gRed:!1,g:["9"]}),s("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:Hu.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(a){r=void 0}s("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:Hu.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function cl(t){if(!(this instanceof cl))return new cl(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=Ku.toArray(t.entropy,t.entropyEnc||"hex"),r=Ku.toArray(t.nonce,t.nonceEnc||"hex"),n=Ku.toArray(t.pers,t.persEnc||"hex");Wu(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,n)}var fl=cl;cl.prototype._init=function(t,e,r){var n=t.concat(e).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(t.concat(r||[])),this._reseed=1},cl.prototype.generate=function(t,e,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof e&&(n=r,r=e,e=null),r&&(r=Ku.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var gl=Zu.assert;function vl(t,e){if(t instanceof vl)return t;this._importDER(t,e)||(gl(t.r&&t.s,"Signature without r or s"),this.r=new Gn(t.r,16),this.s=new Gn(t.s,16),void 0===t.recoveryParam?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}var yl=vl;function bl(){this.place=0}function wl(t,e){var r=t[e.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,s=e.place;o>>=0;return!(i<=127)&&(e.place=s,i)}function _l(t){for(var e=0,r=t.length-1;!t[e]&&!(128&t[e+1])&&e>>3);for(t.push(128|r);--r;)t.push(e>>>(r<<3)&255);t.push(e)}}vl.prototype._importDER=function(t,e){t=Zu.toArray(t,e);var r=new bl;if(48!==t[r.place++])return!1;var n=wl(t,r);if(!1===n)return!1;if(n+r.place!==t.length)return!1;if(2!==t[r.place++])return!1;var i=wl(t,r);if(!1===i)return!1;var o=t.slice(r.place,i+r.place);if(r.place+=i,2!==t[r.place++])return!1;var s=wl(t,r);if(!1===s)return!1;if(t.length!==s+r.place)return!1;var a=t.slice(r.place,s+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===a[0]){if(!(128&a[1]))return!1;a=a.slice(1)}return this.r=new Gn(o),this.s=new Gn(a),this.recoveryParam=null,!0},vl.prototype.toDER=function(t){var e=this.r.toArray(),r=this.s.toArray();for(128&e[0]&&(e=[0].concat(e)),128&r[0]&&(r=[0].concat(r)),e=_l(e),r=_l(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];El(n,e.length),(n=n.concat(e)).push(2),El(n,r.length);var i=n.concat(r),o=[48];return El(o,i.length),o=o.concat(i),Zu.encode(o,t)};var Al=function(){throw new Error("unsupported")},Ml=Zu.assert;function kl(t){if(!(this instanceof kl))return new kl(t);"string"==typeof t&&(Ml(Object.prototype.hasOwnProperty.call(hl,t),"Unknown curve "+t),t=hl[t]),t instanceof hl.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}var Nl=kl;kl.prototype.keyPair=function(t){return new ml(this,t)},kl.prototype.keyFromPrivate=function(t,e){return ml.fromPrivate(this,t,e)},kl.prototype.keyFromPublic=function(t,e){return ml.fromPublic(this,t,e)},kl.prototype.genKeyPair=function(t){t||(t={});for(var e=new fl({hash:this.hash,pers:t.pers,persEnc:t.persEnc||"utf8",entropy:t.entropy||Al(this.hash.hmacStrength),entropyEnc:t.entropy&&t.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new Gn(2));;){var i=new Gn(e.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},kl.prototype._truncateToN=function(t,e){var r=8*t.byteLength()-this.n.bitLength();return r>0&&(t=t.ushrn(r)),!e&&t.cmp(this.n)>=0?t.sub(this.n):t},kl.prototype.sign=function(t,e,r,n){"object"==typeof r&&(n=r,r=null),n||(n={}),e=this.keyFromPrivate(e,r),t=this._truncateToN(new Gn(t,16));for(var i=this.n.byteLength(),o=e.getPrivate().toArray("be",i),s=t.toArray("be",i),a=new fl({hash:this.hash,entropy:o,nonce:s,pers:n.pers,persEnc:n.persEnc||"utf8"}),u=this.n.sub(new Gn(1)),l=0;;l++){var h=n.k?n.k(l):new Gn(a.generate(this.n.byteLength()));if(!((h=this._truncateToN(h,!0)).cmpn(1)<=0||h.cmp(u)>=0)){var c=this.g.mul(h);if(!c.isInfinity()){var f=c.getX(),d=f.umod(this.n);if(0!==d.cmpn(0)){var p=h.invm(this.n).mul(d.mul(e.getPrivate()).iadd(t));if(0!==(p=p.umod(this.n)).cmpn(0)){var m=(c.getY().isOdd()?1:0)|(0!==f.cmp(d)?2:0);return n.canonical&&p.cmp(this.nh)>0&&(p=this.n.sub(p),m^=1),new yl({r:d,s:p,recoveryParam:m})}}}}}},kl.prototype.verify=function(t,e,r,n){t=this._truncateToN(new Gn(t,16)),r=this.keyFromPublic(r,n);var i=(e=new yl(e,"hex")).r,o=e.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var s,a=o.invm(this.n),u=a.mul(t).umod(this.n),l=a.mul(i).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(u,r.getPublic(),l)).isInfinity()&&s.eqXToP(i):!(s=this.g.mulAdd(u,r.getPublic(),l)).isInfinity()&&0===s.getX().umod(this.n).cmp(i)},kl.prototype.recoverPubKey=function(t,e,r,n){Ml((3&r)===r,"The recovery param is more than two bits"),e=new yl(e,n);var i=this.n,o=new Gn(t),s=e.r,a=e.s,u=1&r,l=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&l)throw new Error("Unable to find sencond key candinate");s=l?this.curve.pointFromX(s.add(this.curve.n),u):this.curve.pointFromX(s,u);var h=e.r.invm(i),c=i.sub(o).mul(h).umod(i),f=a.mul(h).umod(i);return this.g.mulAdd(c,s,f)},kl.prototype.getKeyRecoveryParam=function(t,e,r,n){if(null!==(e=new yl(e,n)).recoveryParam)return e.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(t,e,i)}catch(s){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var xl=Gu((function(t,e){var r=e;r.version="6.5.4",r.utils=Zu,r.rand=function(){throw new Error("unsupported")},r.curve=ll,r.curves=hl,r.ec=Nl,r.eddsa=null})).ec;const Sl=new ni("signing-key/5.1.0");let Il=null;function Rl(){return Il||(Il=new xl("secp256k1")),Il}class Pl{constructor(t){$i(this,"curve","secp256k1"),$i(this,"privateKey",di(t));const e=Rl().keyFromPrivate(li(this.privateKey));$i(this,"publicKey","0x"+e.getPublic(!1,"hex")),$i(this,"compressedPublicKey","0x"+e.getPublic(!0,"hex")),$i(this,"_isSigningKey",!0)}_addPoint(t){const e=Rl().keyFromPublic(li(this.publicKey)),r=Rl().keyFromPublic(li(t));return"0x"+e.pub.add(r.pub).encodeCompressed("hex")}signDigest(t){const e=Rl().keyFromPrivate(li(this.privateKey)),r=li(t);32!==r.length&&Sl.throwArgumentError("bad digest length","digest",t);const n=e.sign(r,{canonical:!0});return bi({recoveryParam:n.recoveryParam,r:yi("0x"+n.r.toString(16),32),s:yi("0x"+n.s.toString(16),32)})}computeSharedSecret(t){const e=Rl().keyFromPrivate(li(this.privateKey)),r=Rl().keyFromPublic(li(Tl(t)));return yi("0x"+e.derive(r.getPublic()).toString(16),32)}static isSigningKey(t){return!(!t||!t._isSigningKey)}}function Tl(t,e){const r=li(t);if(32===r.length){const t=new Pl(r);return e?"0x"+Rl().keyFromPrivate(r).getPublic(!0,"hex"):t.publicKey}return 33===r.length?e?di(r):"0x"+Rl().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?e?"0x"+Rl().keyFromPublic(r).getPublic(!0,"hex"):di(r):Sl.throwArgumentError("invalid public or private key","key","[REDACTED]")}const Ol=new ni("transactions/5.1.1");function Bl(t){return"0x"===t?null:jo(t)}function Cl(t){return"0x"===t?Yo:Mi.from(t)}function Fl(t,e){return jo(mi(No(mi(Tl(function(t,e){const r=bi(e),n={r:li(r.r),s:li(r.s)};return"0x"+Rl().recoverPubKey(li(t),n,r.recoveryParam).encode("hex",!1)}(li(t),e)),1)),12))}function Ll(t,e){const r=ci(Mi.from(t).toHexString());return r.length>32&&Ol.throwArgumentError("invalid length for "+e,"transaction:"+e,t),r}function Ul(t,e){return{address:jo(t),storageKeys:(e||[]).map(((e,r)=>(32!==pi(e)&&Ol.throwArgumentError("invalid access list storageKey",`accessList[${t}:${r}]`,e),e.toLowerCase())))}}function jl(t){if(Array.isArray(t))return t.map(((t,e)=>Array.isArray(t)?(t.length>2&&Ol.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${e}]`,t),Ul(t[0],t[1])):Ul(t.address,t.storageKeys)));const e=Object.keys(t).map((e=>{const r=t[e].reduce(((t,e)=>(t[e]=!0,t)),{});return Ul(e,Object.keys(r).sort())}));return e.sort(((t,e)=>t.address.localeCompare(e.address))),e}function zl(t){const e=Bo(t.slice(1));8!==e.length&&11!==e.length&&Ol.throwArgumentError("invalid component count for transaction type: 1","payload",di(t));const r={type:1,chainId:Cl(e[0]).toNumber(),nonce:Cl(e[1]).toNumber(),gasPrice:Cl(e[2]),gasLimit:Cl(e[3]),to:Bl(e[4]),value:Cl(e[5]),data:e[6],accessList:jl(e[7])};if(8===e.length)return r;try{const t=Cl(e[8]).toNumber();if(0!==t&&1!==t)throw new Error("bad recid");r.v=t}catch(n){Ol.throwArgumentError("invalid v for transaction type: 1","v",e[8])}r.r=yi(e[9],32),r.s=yi(e[10],32);try{const t=No(function(t,e){const r=[Ll(t.chainId||0,"chainId"),Ll(t.nonce||0,"nonce"),Ll(t.gasPrice||0,"gasPrice"),Ll(t.gasLimit||0,"gasLimit"),null!=t.to?jo(t.to):"0x",Ll(t.value||0,"value"),t.data||"0x",(n=t.accessList||[],jl(n).map((t=>[t.address,t.storageKeys])))];var n;if(e){const t=bi(e);r.push(Ll(t.recoveryParam,"recoveryParam")),r.push(ci(t.r)),r.push(ci(t.s))}return gi(["0x01",Po(r)])}(r));r.from=Fl(t,{r:r.r,s:r.s,recoveryParam:r.v})}catch(n){console.log(n)}return r.hash=No(t),r}function Dl(t){const e=li(t);if(e[0]>127)return function(t){const e=Bo(t);9!==e.length&&6!==e.length&&Ol.throwArgumentError("invalid raw transaction","rawTransaction",t);const r={nonce:Cl(e[0]).toNumber(),gasPrice:Cl(e[1]),gasLimit:Cl(e[2]),to:Bl(e[3]),value:Cl(e[4]),data:e[5],chainId:0};if(6===e.length)return r;try{r.v=Mi.from(e[6]).toNumber()}catch(n){return console.log(n),r}if(r.r=yi(e[7],32),r.s=yi(e[8],32),Mi.from(r.r).isZero()&&Mi.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 i=r.v-27;const o=e.slice(0,6);0!==r.chainId&&(o.push(di(r.chainId)),o.push("0x"),o.push("0x"),i-=2*r.chainId+8);const s=No(Po(o));try{r.from=Fl(s,{r:di(r.r),s:di(r.s),recoveryParam:i})}catch(n){console.log(n)}r.hash=No(t)}return r.type=null,r}(e);switch(e[0]){case 1:return zl(e)}return Ol.throwError(`unsupported transaction type: ${e[0]}`,ni.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:e[0]})}var ql=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const Vl=new ni("contracts/5.1.1");function $l(t,e){return ql(this,void 0,void 0,(function*(){const r=yield e;try{return jo(r)}catch(i){}t||Vl.throwError("a provider or signer is needed to resolve ENS names",ni.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"});const n=yield t.resolveName(r);return null==n&&Vl.throwArgumentError("resolver or addr is not configured for ENS name","name",r),n}))}function Hl(t,e,r){return ql(this,void 0,void 0,(function*(){return Array.isArray(r)?yield Promise.all(r.map(((r,n)=>Hl(t,Array.isArray(e)?e[n]:e[r.name],r)))):"address"===r.type?yield $l(t,e):"tuple"===r.type?yield Hl(t,e,r.components):"array"===r.baseType?Array.isArray(e)?yield Promise.all(e.map((e=>Hl(t,e,r.arrayChildren)))):Promise.reject(new Error("invalid value for array")):e}))}function Gl(t,e,r){return ql(this,void 0,void 0,(function*(){let n={};r.length===e.inputs.length+1&&"object"==typeof r[r.length-1]&&(n=Wi(r.pop())),Vl.checkArgumentCount(r.length,e.inputs.length,"passed to contract"),t.signer?n.from?n.from=Gi({override:$l(t.signer,n.from),signer:t.signer.getAddress()}).then((t=>ql(this,void 0,void 0,(function*(){return jo(t.signer)!==t.override&&Vl.throwError("Contract with a Signer cannot override from",ni.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),t.override})))):n.from=t.signer.getAddress():n.from&&(n.from=$l(t.provider,n.from));const i=yield Gi({args:Hl(t.signer||t.provider,r,e.inputs),address:t.resolvedAddress,overrides:Gi(n)||{}}),o=t.interface.encodeFunctionData(e,i.args),s={data:o,to:i.address},a=i.overrides;if(null!=a.nonce&&(s.nonce=Mi.from(a.nonce).toNumber()),null!=a.gasLimit&&(s.gasLimit=Mi.from(a.gasLimit)),null!=a.gasPrice&&(s.gasPrice=Mi.from(a.gasPrice)),null!=a.from&&(s.from=a.from),null!=a.type&&(s.type=a.type),null!=a.accessList&&(s.accessList=jl(a.accessList)),null==s.gasLimit&&null!=e.gas){let t=21e3;const r=li(o);for(let e=0;enull!=n[t]));return u.length&&Vl.throwError(`cannot override ${u.map((t=>JSON.stringify(t))).join(",")}`,ni.errors.UNSUPPORTED_OPERATION,{operation:"overrides",overrides:u}),s}))}function Wl(t,e,r){const n=t.signer||t.provider;return function(...i){return ql(this,void 0,void 0,(function*(){let o;if(i.length===e.inputs.length+1&&"object"==typeof i[i.length-1]){const t=Wi(i.pop());null!=t.blockTag&&(o=yield t.blockTag),delete t.blockTag,i.push(t)}null!=t.deployTransaction&&(yield t._deployed(o));const s=yield Gl(t,e,i),a=yield n.call(s,o);try{let n=t.interface.decodeFunctionResult(e,a);return r&&1===e.outputs.length&&(n=n[0]),n}catch(u){throw u.code===ni.errors.CALL_EXCEPTION&&(u.address=t.address,u.args=i,u.transaction=s),u}}))}}function Jl(t,e,r){return e.constant?Wl(t,e,r):function(t,e){return function(...r){return ql(this,void 0,void 0,(function*(){t.signer||Vl.throwError("sending a transaction requires a signer",ni.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction"}),null!=t.deployTransaction&&(yield t._deployed());const n=yield Gl(t,e,r),i=yield t.signer.sendTransaction(n),o=i.wait.bind(i);return i.wait=e=>o(e).then((e=>(e.events=e.logs.map((r=>{let n=Xi(r),i=null;try{i=t.interface.parseLog(r)}catch(o){}return i&&(n.args=i.args,n.decode=(e,r)=>t.interface.decodeEventLog(i.eventFragment,e,r),n.event=i.name,n.eventSignature=i.signature),n.removeListener=()=>t.provider,n.getBlock=()=>t.provider.getBlock(e.blockHash),n.getTransaction=()=>t.provider.getTransaction(e.transactionHash),n.getTransactionReceipt=()=>Promise.resolve(e),n})),e))),i}))}}(t,e)}function Kl(t){return!t.address||null!=t.topics&&0!==t.topics.length?(t.address||"*")+"@"+(t.topics?t.topics.map((t=>Array.isArray(t)?t.join("|"):t)).join(":"):""):"*"}class Zl{constructor(t,e){$i(this,"tag",t),$i(this,"filter",e),this._listeners=[]}addListener(t,e){this._listeners.push({listener:t,once:e})}removeListener(t){let e=!1;this._listeners=this._listeners.filter((r=>!(!e&&r.listener===t)||(e=!0,!1)))}removeAllListeners(){this._listeners=[]}listeners(){return this._listeners.map((t=>t.listener))}listenerCount(){return this._listeners.length}run(t){const e=this.listenerCount();return this._listeners=this._listeners.filter((e=>{const r=t.slice();return setTimeout((()=>{e.listener.apply(this,r)}),0),!e.once})),e}prepareEvent(t){}getEmit(t){return[t]}}class Xl extends Zl{constructor(){super("error",null)}}class Ql extends Zl{constructor(t,e,r,n){const i={address:t};let o=e.getEventTopic(r);n?(o!==n[0]&&Vl.throwArgumentError("topic mismatch","topics",n),i.topics=n.slice()):i.topics=[o],super(Kl(i),i),$i(this,"address",t),$i(this,"interface",e),$i(this,"fragment",r)}prepareEvent(t){super.prepareEvent(t),t.event=this.fragment.name,t.eventSignature=this.fragment.format(),t.decode=(t,e)=>this.interface.decodeEventLog(this.fragment,t,e);try{t.args=this.interface.decodeEventLog(this.fragment,t.data,t.topics)}catch(e){t.args=null,t.decodeError=e}}getEmit(t){const e=function(t){const e=[],r=function(t,n){if(Array.isArray(n))for(let o in n){const s=t.slice();s.push(o);try{r(s,n[o])}catch(i){e.push({path:s,error:i})}}};return r([],t),e}(t.args);if(e.length)throw e[0].error;const r=(t.args||[]).slice();return r.push(t),r}}class Yl extends Zl{constructor(t,e){super("*",{address:t}),$i(this,"address",t),$i(this,"interface",e)}prepareEvent(t){super.prepareEvent(t);try{const e=this.interface.parseLog(t);t.event=e.name,t.eventSignature=e.signature,t.decode=(t,r)=>this.interface.decodeEventLog(e.eventFragment,t,r),t.args=e.args}catch(e){}}}class th extends class{constructor(t,e,r){Vl.checkNew(new.target,th),$i(this,"interface",Hi(new.target,"getInterface")(e)),null==r?($i(this,"provider",null),$i(this,"signer",null)):da.isSigner(r)?($i(this,"provider",r.provider||null),$i(this,"signer",r)):ua.isProvider(r)?($i(this,"provider",r),$i(this,"signer",null)):Vl.throwArgumentError("invalid signer or provider","signerOrProvider",r),$i(this,"callStatic",{}),$i(this,"estimateGas",{}),$i(this,"functions",{}),$i(this,"populateTransaction",{}),$i(this,"filters",{});{const t={};Object.keys(this.interface.events).forEach((e=>{const r=this.interface.events[e];$i(this.filters,e,((...t)=>({address:this.address,topics:this.interface.encodeFilterTopics(r,t)}))),t[r.name]||(t[r.name]=[]),t[r.name].push(e)})),Object.keys(t).forEach((e=>{const r=t[e];1===r.length?$i(this.filters,e,this.filters[r[0]]):Vl.warn(`Duplicate definition of ${e} (${r.join(", ")})`)}))}if($i(this,"_runningEvents",{}),$i(this,"_wrappedEmits",{}),null==t&&Vl.throwArgumentError("invalid contract address or ENS name","addressOrName",t),$i(this,"address",t),this.provider)$i(this,"resolvedAddress",$l(this.provider,t));else try{$i(this,"resolvedAddress",Promise.resolve(jo(t)))}catch(o){Vl.throwError("provider is required to use ENS name as contract address",ni.errors.UNSUPPORTED_OPERATION,{operation:"new Contract"})}const n={},i={};Object.keys(this.interface.functions).forEach((t=>{const e=this.interface.functions[t];if(i[t])Vl.warn(`Duplicate ABI entry for ${JSON.stringify(name)}`);else{i[t]=!0;{const r=e.name;n[r]||(n[r]=[]),n[r].push(t)}null==this[t]&&$i(this,t,Jl(this,e,!0)),null==this.functions[t]&&$i(this.functions,t,Jl(this,e,!1)),null==this.callStatic[t]&&$i(this.callStatic,t,Wl(this,e,!0)),null==this.populateTransaction[t]&&$i(this.populateTransaction,t,function(t,e){return function(...r){return Gl(t,e,r)}}(this,e)),null==this.estimateGas[t]&&$i(this.estimateGas,t,function(t,e){const r=t.signer||t.provider;return function(...n){return ql(this,void 0,void 0,(function*(){r||Vl.throwError("estimate require a provider or signer",ni.errors.UNSUPPORTED_OPERATION,{operation:"estimateGas"});const i=yield Gl(t,e,n);return yield r.estimateGas(i)}))}}(this,e))}})),Object.keys(n).forEach((t=>{const e=n[t];if(e.length>1)return;const r=e[0];try{null==this[t]&&$i(this,t,this[r])}catch(i){}null==this.functions[t]&&$i(this.functions,t,this.functions[r]),null==this.callStatic[t]&&$i(this.callStatic,t,this.callStatic[r]),null==this.populateTransaction[t]&&$i(this.populateTransaction,t,this.populateTransaction[r]),null==this.estimateGas[t]&&$i(this.estimateGas,t,this.estimateGas[r])}))}static getContractAddress(t){return zo(t)}static getInterface(t){return oa.isInterface(t)?t:new oa(t)}deployed(){return this._deployed()}_deployed(t){return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((()=>this)):this._deployedPromise=this.provider.getCode(this.address,t).then((t=>("0x"===t&&Vl.throwError("contract not deployed",ni.errors.UNSUPPORTED_OPERATION,{contractAddress:this.address,operation:"getDeployed"}),this)))),this._deployedPromise}fallback(t){this.signer||Vl.throwError("sending a transactions require a signer",ni.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});const e=Wi(t||{});return["from","to"].forEach((function(t){null!=e[t]&&Vl.throwError("cannot override "+t,ni.errors.UNSUPPORTED_OPERATION,{operation:t})})),e.to=this.resolvedAddress,this.deployed().then((()=>this.signer.sendTransaction(e)))}connect(t){"string"==typeof t&&(t=new pa(t,this.provider));const e=new this.constructor(this.address,this.interface,t);return this.deployTransaction&&$i(e,"deployTransaction",this.deployTransaction),e}attach(t){return new this.constructor(t,this.interface,this.signer||this.provider)}static isIndexed(t){return na.isIndexed(t)}_normalizeRunningEvent(t){return this._runningEvents[t.tag]?this._runningEvents[t.tag]:t}_getRunningEvent(t){if("string"==typeof t){if("error"===t)return this._normalizeRunningEvent(new Xl);if("event"===t)return this._normalizeRunningEvent(new Zl("event",null));if("*"===t)return this._normalizeRunningEvent(new Yl(this.address,this.interface));const e=this.interface.getEvent(t);return this._normalizeRunningEvent(new Ql(this.address,this.interface,e))}if(t.topics&&t.topics.length>0){try{const e=t.topics[0];if("string"!=typeof e)throw new Error("invalid topic");const r=this.interface.getEvent(e);return this._normalizeRunningEvent(new Ql(this.address,this.interface,r,t.topics))}catch(e){}const r={address:this.address,topics:t.topics};return this._normalizeRunningEvent(new Zl(Kl(r),r))}return this._normalizeRunningEvent(new Yl(this.address,this.interface))}_checkRunningEvents(t){if(0===t.listenerCount()){delete this._runningEvents[t.tag];const e=this._wrappedEmits[t.tag];e&&t.filter&&(this.provider.off(t.filter,e),delete this._wrappedEmits[t.tag])}}_wrapEvent(t,e,r){const n=Xi(e);return n.removeListener=()=>{r&&(t.removeListener(r),this._checkRunningEvents(t))},n.getBlock=()=>this.provider.getBlock(e.blockHash),n.getTransaction=()=>this.provider.getTransaction(e.transactionHash),n.getTransactionReceipt=()=>this.provider.getTransactionReceipt(e.transactionHash),t.prepareEvent(n),n}_addEventListener(t,e,r){if(this.provider||Vl.throwError("events require a provider or a signer with a provider",ni.errors.UNSUPPORTED_OPERATION,{operation:"once"}),t.addListener(e,r),this._runningEvents[t.tag]=t,!this._wrappedEmits[t.tag]){const r=r=>{let n=this._wrapEvent(t,r,e);if(null==n.decodeError)try{const e=t.getEmit(n);this.emit(t.filter,...e)}catch(i){n.decodeError=i.error}null!=t.filter&&this.emit("event",n),null!=n.decodeError&&this.emit("error",n.decodeError,n)};this._wrappedEmits[t.tag]=r,null!=t.filter&&this.provider.on(t.filter,r)}}queryFilter(t,e,r){const n=this._getRunningEvent(t),i=Wi(n.filter);return"string"==typeof e&&fi(e,32)?(null!=r&&Vl.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),i.blockHash=e):(i.fromBlock=null!=e?e:0,i.toBlock=null!=r?r:"latest"),this.provider.getLogs(i).then((t=>t.map((t=>this._wrapEvent(n,t,null)))))}on(t,e){return this._addEventListener(this._getRunningEvent(t),e,!1),this}once(t,e){return this._addEventListener(this._getRunningEvent(t),e,!0),this}emit(t,...e){if(!this.provider)return!1;const r=this._getRunningEvent(t),n=r.run(e)>0;return this._checkRunningEvents(r),n}listenerCount(t){return this.provider?null==t?Object.keys(this._runningEvents).reduce(((t,e)=>t+this._runningEvents[e].listenerCount()),0):this._getRunningEvent(t).listenerCount():0}listeners(t){if(!this.provider)return[];if(null==t){const t=[];for(let e in this._runningEvents)this._runningEvents[e].listeners().forEach((e=>{t.push(e)}));return t}return this._getRunningEvent(t).listeners()}removeAllListeners(t){if(!this.provider)return this;if(null==t){for(const t in this._runningEvents){const e=this._runningEvents[t];e.removeAllListeners(),this._checkRunningEvents(e)}return this}const e=this._getRunningEvent(t);return e.removeAllListeners(),this._checkRunningEvents(e),this}off(t,e){if(!this.provider)return this;const r=this._getRunningEvent(t);return r.removeListener(e),this._checkRunningEvents(r),this}removeListener(t,e){return this.off(t,e)}}{}class eh{constructor(t){$i(this,"alphabet",t),$i(this,"base",t.length),$i(this,"_alphabetMap",{}),$i(this,"_leader",t.charAt(0));for(let e=0;e0;)r.push(t%this.base),t=t/this.base|0}let n="";for(let i=0;0===e[i]&&i=0;--i)n+=this.alphabet[r[i]];return n}decode(t){if("string"!=typeof t)throw new TypeError("Expected String");let e=[];if(0===t.length)return new Uint8Array(e);e.push(0);for(let r=0;r>=8;for(;i>0;)e.push(255&i),i>>=8}for(let r=0;t[r]===this._leader&&r{o[e.toLowerCase()]=t})):n.headers.keys().forEach((t=>{o[t.toLowerCase()]=n.headers.get(t)})),{headers:o,statusCode:n.status,statusMessage:n.statusText,body:li(new Uint8Array(i))}}))}var ph=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const mh=new ni("web/5.1.0");function gh(t){return new Promise((e=>{setTimeout(e,t)}))}function vh(t,e){if(null==t)return null;if("string"==typeof t)return t;if(ai(t)){if(e&&("text"===e.split("/")[0]||"application/json"===e.split(";")[0].trim()))try{return ds(t)}catch(r){}return di(t)}return t}function yh(t,e,r){let n=null;if(null!=e){n=cs(e);const r="string"==typeof t?{url:t}:Wi(t);if(r.headers){0!==Object.keys(r.headers).filter((t=>"content-type"===t.toLowerCase())).length||(r.headers=Wi(r.headers),r.headers["content-type"]="application/json")}else r.headers={"content-type":"application/json"};t=r}return function(t,e,r){const n="object"==typeof t&&null!=t.throttleLimit?t.throttleLimit:12;mh.assertArgument(n>0&&n%1==0,"invalid connection throttle limit","connection.throttleLimit",n);const i="object"==typeof t?t.throttleCallback:null,o="object"==typeof t&&"number"==typeof t.throttleSlotInterval?t.throttleSlotInterval:100;mh.assertArgument(o>0&&o%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",o);const s={};let a=null;const u={method:"GET"};let l=!1,h=12e4;if("string"==typeof t)a=t;else if("object"==typeof t){if(null!=t&&null!=t.url||mh.throwArgumentError("missing URL","connection.url",t),a=t.url,"number"==typeof t.timeout&&t.timeout>0&&(h=t.timeout),t.headers)for(const e in t.headers)s[e.toLowerCase()]={key:e,value:String(t.headers[e])},["if-none-match","if-modified-since"].indexOf(e.toLowerCase())>=0&&(l=!0);if(u.allowGzip=!!t.allowGzip,null!=t.user&&null!=t.password){"https:"!==a.substring(0,6)&&!0!==t.allowInsecureAuthentication&&mh.throwError("basic authentication requires a secure https url",ni.errors.INVALID_ARGUMENT,{argument:"url",url:a,user:t.user,password:"[REDACTED]"});const e=t.user+":"+t.password;s.authorization={key:"Authorization",value:"Basic "+ch(cs(e))}}}e&&(u.method="POST",u.body=e,null==s["content-type"]&&(s["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==s["content-length"]&&(s["content-length"]={key:"Content-Length",value:String(e.length)}));const c={};Object.keys(s).forEach((t=>{const e=s[t];c[e.key]=e.value})),u.headers=c;const f=function(){let t=null;return{promise:new Promise((function(e,r){h&&(t=setTimeout((()=>{null!=t&&(t=null,r(mh.makeError("timeout",ni.errors.TIMEOUT,{requestBody:vh(u.body,c["content-type"]),requestMethod:u.method,timeout:h,url:a})))}),h))})),cancel:function(){null!=t&&(clearTimeout(t),t=null)}}}(),d=function(){return ph(this,void 0,void 0,(function*(){for(let e=0;e=300)&&(f.cancel(),mh.throwError("bad response",ni.errors.SERVER_ERROR,{status:s.statusCode,headers:s.headers,body:vh(h,s.headers?s.headers["content-type"]:null),requestBody:vh(u.body,c["content-type"]),requestMethod:u.method,url:a})),r)try{const t=yield r(h,s);return f.cancel(),t}catch(t){if(t.throttleRetry&&e{let n=null;if(null!=t)try{n=JSON.parse(ds(t))}catch(i){mh.throwError("invalid JSON",ni.errors.SERVER_ERROR,{body:t,error:i})}return r&&(n=r(n,e)),n}))}function bh(t,e){return e||(e={}),null==(e=Wi(e)).floor&&(e.floor=0),null==e.ceiling&&(e.ceiling=1e4),null==e.interval&&(e.interval=250),new Promise((function(r,n){let i=null,o=!1;const s=()=>!o&&(o=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout((()=>{s()&&n(new Error("timeout"))}),e.timeout));const a=e.retryLimit;let u=0;!function i(){return t().then((function(t){if(void 0!==t)s()&&r(t);else if(e.oncePoll)e.oncePoll.once("poll",i);else if(e.onceBlock)e.onceBlock.once("block",i);else if(!o){if(u++,u>a)return void(s()&&n(new Error("retry limit reached")));let t=e.interval*parseInt(String(Math.random()*Math.pow(2,u)));te.ceiling&&(t=e.ceiling),setTimeout(i,t)}return null}),(function(t){s()&&n(t)}))}()}))}for(var wh="qpzry9x8gf2tvdw0s3jn54khce6mua7l",_h={},Eh=0;Eh>25;return(33554431&t)<<5^996825010&-(e>>0&1)^642813549&-(e>>1&1)^513874426&-(e>>2&1)^1027748829&-(e>>3&1)^705979059&-(e>>4&1)}function kh(t){for(var e=1,r=0;r126)return"Invalid prefix ("+t+")";e=Mh(e)^n>>5}for(e=Mh(e),r=0;re)return"Exceeds length limit";var r=t.toLowerCase(),n=t.toUpperCase();if(t!==r&&t!==n)return"Mixed-case string "+t;var i=(t=r).lastIndexOf("1");if(-1===i)return"No separator character for "+t;if(0===i)return"Missing prefix for "+t;var o=t.slice(0,i),s=t.slice(i+1);if(s.length<6)return"Data too short";var a=kh(o);if("string"==typeof a)return a;for(var u=[],l=0;l=s.length||u.push(c)}return 1!==a?"Invalid checksum for "+t:{prefix:o,words:u}}function xh(t,e,r,n){for(var i=0,o=0,s=(1<=r;)o-=r,a.push(i>>o&s);if(n)o>0&&a.push(i<=e)return"Excess padding";if(i<r)throw new TypeError("Exceeds length limit");var n=kh(t=t.toLowerCase());if("string"==typeof n)throw new Error(n);for(var i=t+"1",o=0;o>5!=0)throw new Error("Non 5-bit word");n=Mh(n)^s,i+=wh.charAt(s)}for(o=0;o<6;++o)n=Mh(n);for(n^=1,o=0;o<6;++o){i+=wh.charAt(n>>5*(5-o)&31)}return i},toWordsUnsafe:function(t){var e=xh(t,8,5,!0);if(Array.isArray(e))return e},toWords:function(t){var e=xh(t,8,5,!0);if(Array.isArray(e))return e;throw new Error(e)},fromWordsUnsafe:function(t){var e=xh(t,5,8,!1);if(Array.isArray(e))return e},fromWords:function(t){var e=xh(t,5,8,!1);if(Array.isArray(e))return e;throw new Error(e)}};const Ih=new ni("providers/5.1.2");class Rh{constructor(){Ih.checkNew(new.target,Rh),this.formats=this.getDefaultFormats()}getDefaultFormats(){const t={},e=this.address.bind(this),r=this.bigNumber.bind(this),n=this.blockTag.bind(this),i=this.data.bind(this),o=this.hash.bind(this),s=this.hex.bind(this),a=this.number.bind(this);return t.transaction={hash:o,type:Rh.allowNull(a,null),accessList:Rh.allowNull(this.accessList.bind(this),null),blockHash:Rh.allowNull(o,null),blockNumber:Rh.allowNull(a,null),transactionIndex:Rh.allowNull(a,null),confirmations:Rh.allowNull(a,null),from:e,gasPrice:r,gasLimit:r,to:Rh.allowNull(e,null),value:r,nonce:a,data:i,r:Rh.allowNull(this.uint256),s:Rh.allowNull(this.uint256),v:Rh.allowNull(a),creates:Rh.allowNull(e,null),raw:Rh.allowNull(i)},t.transactionRequest={from:Rh.allowNull(e),nonce:Rh.allowNull(a),gasLimit:Rh.allowNull(r),gasPrice:Rh.allowNull(r),to:Rh.allowNull(e),value:Rh.allowNull(r),data:Rh.allowNull((t=>this.data(t,!0))),type:Rh.allowNull(a),accessList:Rh.allowNull(this.accessList.bind(this),null)},t.receiptLog={transactionIndex:a,blockNumber:a,transactionHash:o,address:e,topics:Rh.arrayOf(o),data:i,logIndex:a,blockHash:o},t.receipt={to:Rh.allowNull(this.address,null),from:Rh.allowNull(this.address,null),contractAddress:Rh.allowNull(e,null),transactionIndex:a,root:Rh.allowNull(s),gasUsed:r,logsBloom:Rh.allowNull(i),blockHash:o,transactionHash:o,logs:Rh.arrayOf(this.receiptLog.bind(this)),blockNumber:a,confirmations:Rh.allowNull(a,null),cumulativeGasUsed:r,status:Rh.allowNull(a)},t.block={hash:o,parentHash:o,number:a,timestamp:a,nonce:Rh.allowNull(s),difficulty:this.difficulty.bind(this),gasLimit:r,gasUsed:r,miner:e,extraData:i,transactions:Rh.allowNull(Rh.arrayOf(o))},t.blockWithTransactions=Wi(t.block),t.blockWithTransactions.transactions=Rh.allowNull(Rh.arrayOf(this.transactionResponse.bind(this))),t.filter={fromBlock:Rh.allowNull(n,void 0),toBlock:Rh.allowNull(n,void 0),blockHash:Rh.allowNull(o,void 0),address:Rh.allowNull(e,void 0),topics:Rh.allowNull(this.topics.bind(this),void 0)},t.filterLog={blockNumber:Rh.allowNull(a),blockHash:Rh.allowNull(o),transactionIndex:a,removed:Rh.allowNull(this.boolean.bind(this)),address:e,data:Rh.allowFalsish(i,"0x"),topics:Rh.arrayOf(o),transactionHash:o,logIndex:a},t}accessList(t){return jl(t||[])}number(t){return"0x"===t?0:Mi.from(t).toNumber()}bigNumber(t){return Mi.from(t)}boolean(t){if("boolean"==typeof t)return t;if("string"==typeof t){if("true"===(t=t.toLowerCase()))return!0;if("false"===t)return!1}throw new Error("invalid boolean - "+t)}hex(t,e){return"string"==typeof t&&(e||"0x"===t.substring(0,2)||(t="0x"+t),fi(t))?t.toLowerCase():Ih.throwArgumentError("invalid hash","value",t)}data(t,e){const r=this.hex(t,e);if(r.length%2!=0)throw new Error("invalid data; odd-length - "+t);return r}address(t){return jo(t)}callAddress(t){if(!fi(t,32))return null;const e=jo(mi(t,12));return"0x0000000000000000000000000000000000000000"===e?null:e}contractAddress(t){return zo(t)}blockTag(t){if(null==t)return"latest";if("earliest"===t)return"0x0";if("latest"===t||"pending"===t)return t;if("number"==typeof t||fi(t))return vi(t);throw new Error("invalid blockTag")}hash(t,e){const r=this.hex(t,e);return 32!==pi(r)?Ih.throwArgumentError("invalid hash","value",t):r}difficulty(t){if(null==t)return null;const e=Mi.from(t);try{return e.toNumber()}catch(r){}return null}uint256(t){if(!fi(t))throw new Error("invalid uint256");return yi(t,32)}_block(t,e){return null!=t.author&&null==t.miner&&(t.miner=t.author),Rh.check(e,t)}block(t){return this._block(t,this.formats.block)}blockWithTransactions(t){return this._block(t,this.formats.blockWithTransactions)}transactionRequest(t){return Rh.check(this.formats.transactionRequest,t)}transactionResponse(t){null!=t.gas&&null==t.gasLimit&&(t.gasLimit=t.gas),t.to&&Mi.from(t.to).isZero()&&(t.to="0x0000000000000000000000000000000000000000"),null!=t.input&&null==t.data&&(t.data=t.input),null==t.to&&null==t.creates&&(t.creates=this.contractAddress(t)),1===t.type&&null==t.accessList&&(t.accessList=[]);const e=Rh.check(this.formats.transaction,t);if(null!=t.chainId){let r=t.chainId;fi(r)&&(r=Mi.from(r).toNumber()),e.chainId=r}else{let r=t.networkId;null==r&&null==e.v&&(r=t.chainId),fi(r)&&(r=Mi.from(r).toNumber()),"number"!=typeof r&&null!=e.v&&(r=(e.v-35)/2,r<0&&(r=0),r=parseInt(r)),"number"!=typeof r&&(r=0),e.chainId=r}return e.blockHash&&"x"===e.blockHash.replace(/0/g,"")&&(e.blockHash=null),e}transaction(t){return Dl(t)}receiptLog(t){return Rh.check(this.formats.receiptLog,t)}receipt(t){const e=Rh.check(this.formats.receipt,t);if(null!=e.root)if(e.root.length<=4){const t=Mi.from(e.root).toNumber();0===t||1===t?(null!=e.status&&e.status!==t&&Ih.throwArgumentError("alt-root-status/status mismatch","value",{root:e.root,status:e.status}),e.status=t,delete e.root):Ih.throwArgumentError("invalid alt-root-status","value.root",e.root)}else 66!==e.root.length&&Ih.throwArgumentError("invalid root hash","value.root",e.root);return null!=e.status&&(e.byzantium=!0),e}topics(t){return Array.isArray(t)?t.map((t=>this.topics(t))):null!=t?this.hash(t,!0):null}filter(t){return Rh.check(this.formats.filter,t)}filterLog(t){return Rh.check(this.formats.filterLog,t)}static check(t,e){const r={};for(const i in t)try{const n=t[i](e[i]);void 0!==n&&(r[i]=n)}catch(n){throw n.checkKey=i,n.checkValue=e[i],n}return r}static allowNull(t,e){return function(r){return null==r?e:t(r)}}static allowFalsish(t,e){return function(r){return r?t(r):e}}static arrayOf(t){return function(e){if(!Array.isArray(e))throw new Error("not an array");const r=[];return e.forEach((function(e){r.push(t(e))})),r}}}var Ph=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const Th=new ni("providers/5.1.2");function Oh(t){return null==t?"null":(32!==pi(t)&&Th.throwArgumentError("invalid topic","topic",t),t.toLowerCase())}function Bh(t){for(t=t.slice();t.length>0&&null==t[t.length-1];)t.pop();return t.map((t=>{if(Array.isArray(t)){const e={};t.forEach((t=>{e[Oh(t)]=!0}));const r=Object.keys(e);return r.sort(),r.join("|")}return Oh(t)})).join("&")}function Ch(t){if("string"==typeof t){if(32===pi(t=t.toLowerCase()))return"tx:"+t;if(-1===t.indexOf(":"))return t}else{if(Array.isArray(t))return"filter:*:"+Bh(t);if(aa.isForkEvent(t))throw Th.warn("not implemented"),new Error("not implemented");if(t&&"object"==typeof t)return"filter:"+(t.address||"*")+":"+Bh(t.topics||[])}throw new Error("invalid event - "+t)}function Fh(){return(new Date).getTime()}const Lh=["block","network","pending","poll"];class Uh{constructor(t,e,r){$i(this,"tag",t),$i(this,"listener",e),$i(this,"once",r)}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(){const t=this.tag.split(":");return"tx"!==t[0]?null:t[1]}get filter(){const t=this.tag.split(":");if("filter"!==t[0])return null;const e=t[1],r=""===(n=t[2])?[]:n.split(/&/g).map((t=>{if(""===t)return[];const e=t.split("|").map((t=>"null"===t?null:t));return 1===e.length?e[0]:e}));var n;const i={};return r.length>0&&(i.topics=r),e&&"*"!==e&&(i.address=e),i}pollable(){return this.tag.indexOf(":")>=0||Lh.indexOf(this.tag)>=0}}const jh={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 zh(t){return yi(Mi.from(t).toHexString(),32)}function Dh(t){return rh.encode(hi([t,mi(nh(nh(t)),0,4)]))}class qh{constructor(t,e,r){$i(this,"provider",t),$i(this,"name",r),$i(this,"address",t.formatter.address(e))}_fetchBytes(t,e){return Ph(this,void 0,void 0,(function*(){const r={to:this.address,data:gi([t,Ls(this.name),e||"0x"])},n=yield this.provider.call(r);if("0x"===n)return null;const i=Mi.from(mi(n,0,32)).toNumber(),o=Mi.from(mi(n,i,i+32)).toNumber();return mi(n,i+32,i+32+o)}))}_getAddress(t,e){const r=jh[String(t)];if(null==r&&Th.throwError(`unsupported coin type: ${t}`,ni.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${t})`}),"eth"===r.ilk)return this.provider.formatter.address(e);const n=li(e);if(null!=r.p2pkh){const t=e.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(t){const e=parseInt(t[1],16);if(t[2].length===2*e&&e>=1&&e<=75)return Dh(hi([[r.p2pkh],"0x"+t[2]]))}}if(null!=r.p2sh){const t=e.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(t){const e=parseInt(t[1],16);if(t[2].length===2*e&&e>=1&&e<=75)return Dh(hi([[r.p2sh],"0x"+t[2]]))}}if(null!=r.prefix){const t=n[1];let e=n[0];if(0===e?20!==t&&32!==t&&(e=-1):e=-1,e>=0&&n.length===2+t&&t>=1&&t<=75){const t=Sh.toWords(n.slice(2));return t.unshift(e),Sh.encode(r.prefix,t)}}return null}getAddress(t){return Ph(this,void 0,void 0,(function*(){if(null==t&&(t=60),60===t){const t={to:this.address,data:"0x3b3b57de"+Ls(this.name).substring(2)},e=yield this.provider.call(t);return"0x"===e||"0x0000000000000000000000000000000000000000000000000000000000000000"===e?null:this.provider.formatter.callAddress(e)}const e=yield this._fetchBytes("0xf1cb7e06",zh(t));if(null==e||"0x"===e)return null;const r=this._getAddress(t,e);return null==r&&Th.throwError("invalid or unsupported coin data",ni.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${t})`,coinType:t,data:e}),r}))}getContentHash(){return Ph(this,void 0,void 0,(function*(){const t=yield this._fetchBytes("0xbc1c58d1");if(null==t||"0x"===t)return null;const e=t.match(/^0xe3010170(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(e){const t=parseInt(e[3],16);if(e[4].length===2*t)return"ipfs://"+rh.encode("0x"+e[1])}const r=t.match(/^0xe40101fa011b20([0-9a-f]*)$/);return r&&64===r[1].length?"bzz://"+r[1]:Th.throwError("invalid or unsupported content hash data",ni.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:t})}))}getText(t){return Ph(this,void 0,void 0,(function*(){let e=cs(t);e=hi([zh(64),zh(e.length),e]),e.length%32!=0&&(e=hi([e,yi("0x",32-t.length%32)]));const r=yield this._fetchBytes("0x59d1d43c",di(e));return null==r||"0x"===r?null:ds(r)}))}}let Vh=null,$h=1;class Hh extends ua{constructor(t){if(Th.checkNew(new.target,ua),super(),this._events=[],this._emitted={block:-2},this.formatter=new.target.getFormatter(),$i(this,"anyNetwork","any"===t),this.anyNetwork&&(t=this.detectNetwork()),t instanceof Promise)this._networkPromise=t,t.catch((t=>{})),this._ready().catch((t=>{}));else{const e=Hi(new.target,"getNetwork")(t);e?($i(this,"_network",e),this.emit("network",e,null)):Th.throwArgumentError("invalid network","network",t)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return Ph(this,void 0,void 0,(function*(){if(null==this._network){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch(t){}null==e&&(e=yield this.detectNetwork()),e||Th.throwError("no network detected",ni.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=e:$i(this,"_network",e),this.emit("network",e,null))}return this._network}))}get ready(){return bh((()=>this._ready().then((t=>t),(t=>{if(t.code!==ni.errors.NETWORK_ERROR||"noNetwork"!==t.event)throw t}))))}static getFormatter(){return null==Vh&&(Vh=new Rh),Vh}static getNetwork(t){return function(t){if(null==t)return null;if("number"==typeof t){for(const e in hh){const r=hh[e];if(r.chainId===t)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:t,name:"unknown"}}if("string"==typeof t){const e=hh[t];return null==e?null:{name:e.name,chainId:e.chainId,ensAddress:e.ensAddress,_defaultProvider:e._defaultProvider||null}}const e=hh[t.name];if(!e)return"number"!=typeof t.chainId&&ih.throwArgumentError("invalid network chainId","network",t),t;0!==t.chainId&&t.chainId!==e.chainId&&ih.throwArgumentError("network chainId mismatch","network",t);let r=t._defaultProvider||null;var n;return null==r&&e._defaultProvider&&(r=(n=e._defaultProvider)&&"function"==typeof n.renetwork?e._defaultProvider.renetwork(t):e._defaultProvider),{name:t.name,chainId:e.chainId,ensAddress:t.ensAddress||e.ensAddress||null,_defaultProvider:r}}(null==t?"homestead":t)}_getInternalBlockNumber(t){return Ph(this,void 0,void 0,(function*(){if(yield this._ready(),t>0)for(;this._internalBlockNumber;){const e=this._internalBlockNumber;try{const r=yield e;if(Fh()-r.respTime<=t)return r.blockNumber;break}catch(n){if(this._internalBlockNumber===e)break}}const e=Fh(),r=Gi({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((t=>null),(t=>t))}).then((({blockNumber:t,networkError:n})=>{if(n)throw this._internalBlockNumber===r&&(this._internalBlockNumber=null),n;const i=Fh();return(t=Mi.from(t).toNumber()){this._internalBlockNumber===r&&(this._internalBlockNumber=null)})),(yield r).blockNumber}))}poll(){return Ph(this,void 0,void 0,(function*(){const t=$h++,e=[];let r=null;try{r=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(n){return void this.emit("error",n)}if(this._setFastBlockNumber(r),this.emit("poll",t,r),r!==this._lastBlockNumber){if(-2===this._emitted.block&&(this._emitted.block=r-1),Math.abs(this._emitted.block-r)>1e3)Th.warn("network block skew detected; skipping block events"),this.emit("error",Th.makeError("network block skew detected",ni.errors.NETWORK_ERROR,{blockNumber:r,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",r);else for(let t=this._emitted.block+1;t<=r;t++)this.emit("block",t);this._emitted.block!==r&&(this._emitted.block=r,Object.keys(this._emitted).forEach((t=>{if("block"===t)return;const e=this._emitted[t];"pending"!==e&&r-e>12&&delete this._emitted[t]}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=r-1),this._events.forEach((t=>{switch(t.type){case"tx":{const r=t.hash;let n=this.getTransactionReceipt(r).then((t=>t&&null!=t.blockNumber?(this._emitted["t:"+r]=t.blockNumber,this.emit(r,t),null):null)).catch((t=>{this.emit("error",t)}));e.push(n);break}case"filter":{const n=t.filter;n.fromBlock=this._lastBlockNumber+1,n.toBlock=r;const i=this.getLogs(n).then((t=>{0!==t.length&&t.forEach((t=>{this._emitted["b:"+t.blockHash]=t.blockNumber,this._emitted["t:"+t.transactionHash]=t.blockNumber,this.emit(n,t)}))})).catch((t=>{this.emit("error",t)}));e.push(i);break}}})),this._lastBlockNumber=r,Promise.all(e).then((()=>{this.emit("didPoll",t)})).catch((t=>{this.emit("error",t)}))}else this.emit("didPoll",t)}))}resetEventsBlock(t){this._lastBlockNumber=t-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return Ph(this,void 0,void 0,(function*(){return Th.throwError("provider does not support network detection",ni.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})}))}getNetwork(){return Ph(this,void 0,void 0,(function*(){const t=yield this._ready(),e=yield this.detectNetwork();if(t.chainId!==e.chainId){if(this.anyNetwork)return this._network=e,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",e,t),yield(r=0,new Promise((t=>{setTimeout(t,r)}))),this._network;const n=Th.makeError("underlying network changed",ni.errors.NETWORK_ERROR,{event:"changed",network:t,detectedNetwork:e});throw this.emit("error",n),n}var r;return t}))}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then((t=>{this._setFastBlockNumber(t)}),(t=>{})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(t){t&&!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))):!t&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(t){if("number"!=typeof t||t<=0||parseInt(String(t))!=t)throw new Error("invalid polling interval");this._pollingInterval=t,this._poller&&(clearInterval(this._poller),this._poller=setInterval((()=>{this.poll()}),this._pollingInterval))}_getFastBlockNumber(){const t=Fh();return t-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=t,this._fastBlockNumberPromise=this.getBlockNumber().then((t=>((null==this._fastBlockNumber||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber)))),this._fastBlockNumberPromise}_setFastBlockNumber(t){null!=this._fastBlockNumber&&tthis._fastBlockNumber)&&(this._fastBlockNumber=t,this._fastBlockNumberPromise=Promise.resolve(t)))}waitForTransaction(t,e,r){return Ph(this,void 0,void 0,(function*(){null==e&&(e=1);const n=yield this.getTransactionReceipt(t);return(n?n.confirmations:0)>=e?n:new Promise(((n,i)=>{let o=null,s=!1;const a=r=>{r.confirmations0&&(o=setTimeout((()=>{s||(o=null,s=!0,this.removeListener(t,a),i(Th.makeError("timeout exceeded",ni.errors.TIMEOUT,{timeout:r})))}),r),o.unref&&o.unref())}))}))}getBlockNumber(){return Ph(this,void 0,void 0,(function*(){return this._getInternalBlockNumber(0)}))}getGasPrice(){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield this.perform("getGasPrice",{});try{return Mi.from(t)}catch(e){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"getGasPrice",result:t,error:e})}}))}getBalance(t,e){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Gi({address:this._getAddress(t),blockTag:this._getBlockTag(e)}),n=yield this.perform("getBalance",r);try{return Mi.from(n)}catch(i){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"getBalance",params:r,result:n,error:i})}}))}getTransactionCount(t,e){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Gi({address:this._getAddress(t),blockTag:this._getBlockTag(e)}),n=yield this.perform("getTransactionCount",r);try{return Mi.from(n).toNumber()}catch(i){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"getTransactionCount",params:r,result:n,error:i})}}))}getCode(t,e){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Gi({address:this._getAddress(t),blockTag:this._getBlockTag(e)}),n=yield this.perform("getCode",r);try{return di(n)}catch(i){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"getCode",params:r,result:n,error:i})}}))}getStorageAt(t,e,r){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const n=yield Gi({address:this._getAddress(t),blockTag:this._getBlockTag(r),position:Promise.resolve(e).then((t=>vi(t)))}),i=yield this.perform("getStorageAt",n);try{return di(i)}catch(o){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"getStorageAt",params:n,result:i,error:o})}}))}_wrapTransaction(t,e){if(null!=e&&32!==pi(e))throw new Error("invalid response - sendTransaction");const r=t;return null!=e&&t.hash!==e&&Th.throwError("Transaction hash mismatch from Provider.sendTransaction.",ni.errors.UNKNOWN_ERROR,{expectedHash:t.hash,returnedHash:e}),r.wait=e=>Ph(this,void 0,void 0,(function*(){0!==e&&(this._emitted["t:"+t.hash]="pending");const r=yield this.waitForTransaction(t.hash,e);return null==r&&0===e?null:(this._emitted["t:"+t.hash]=r.blockNumber,0===r.status&&Th.throwError("transaction failed",ni.errors.CALL_EXCEPTION,{transactionHash:t.hash,transaction:t,receipt:r}),r)})),r}sendTransaction(t){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield Promise.resolve(t).then((t=>di(t))),r=this.formatter.transaction(t);try{const t=yield this.perform("sendTransaction",{signedTransaction:e});return this._wrapTransaction(r,t)}catch(n){throw n.transaction=r,n.transactionHash=r.hash,n}}))}_getTransactionRequest(t){return Ph(this,void 0,void 0,(function*(){const e=yield t,r={};return["from","to"].forEach((t=>{null!=e[t]&&(r[t]=Promise.resolve(e[t]).then((t=>t?this._getAddress(t):null)))})),["gasLimit","gasPrice","value"].forEach((t=>{null!=e[t]&&(r[t]=Promise.resolve(e[t]).then((t=>t?Mi.from(t):null)))})),["type"].forEach((t=>{null!=e[t]&&(r[t]=Promise.resolve(e[t]).then((t=>null!=t?t:null)))})),e.accessList&&(r.accessList=this.formatter.accessList(e.accessList)),["data"].forEach((t=>{null!=e[t]&&(r[t]=Promise.resolve(e[t]).then((t=>t?di(t):null)))})),this.formatter.transactionRequest(yield Gi(r))}))}_getFilter(t){return Ph(this,void 0,void 0,(function*(){t=yield t;const e={};return null!=t.address&&(e.address=this._getAddress(t.address)),["blockHash","topics"].forEach((r=>{null!=t[r]&&(e[r]=t[r])})),["fromBlock","toBlock"].forEach((r=>{null!=t[r]&&(e[r]=this._getBlockTag(t[r]))})),this.formatter.filter(yield Gi(e))}))}call(t,e){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Gi({transaction:this._getTransactionRequest(t),blockTag:this._getBlockTag(e)}),n=yield this.perform("call",r);try{return di(n)}catch(i){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"call",params:r,result:n,error:i})}}))}estimateGas(t){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield Gi({transaction:this._getTransactionRequest(t)}),r=yield this.perform("estimateGas",e);try{return Mi.from(r)}catch(n){return Th.throwError("bad result from backend",ni.errors.SERVER_ERROR,{method:"estimateGas",params:e,result:r,error:n})}}))}_getAddress(t){return Ph(this,void 0,void 0,(function*(){const e=yield this.resolveName(t);return null==e&&Th.throwError("ENS name not configured",ni.errors.UNSUPPORTED_OPERATION,{operation:`resolveName(${JSON.stringify(t)})`}),e}))}_getBlock(t,e){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork(),t=yield t;let r=-128;const n={includeTransactions:!!e};if(fi(t,32))n.blockHash=t;else try{n.blockTag=this.formatter.blockTag(yield this._getBlockTag(t)),fi(n.blockTag)&&(r=parseInt(n.blockTag.substring(2),16))}catch(i){Th.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",t)}return bh((()=>Ph(this,void 0,void 0,(function*(){const t=yield this.perform("getBlock",n);if(null==t)return null!=n.blockHash&&null==this._emitted["b:"+n.blockHash]||null!=n.blockTag&&r>this._emitted.block?null:void 0;if(e){let e=null;for(let r=0;rPh(this,void 0,void 0,(function*(){const r=yield this.perform("getTransaction",e);if(null==r)return null==this._emitted["t:"+t]?null:void 0;const n=this.formatter.transactionResponse(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let t=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;t<=0&&(t=1),n.confirmations=t}return this._wrapTransaction(n)}))),{oncePoll:this})}))}getTransactionReceipt(t){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork(),t=yield t;const e={transactionHash:this.formatter.hash(t,!0)};return bh((()=>Ph(this,void 0,void 0,(function*(){const r=yield this.perform("getTransactionReceipt",e);if(null==r)return null==this._emitted["t:"+t]?null:void 0;if(null==r.blockHash)return;const n=this.formatter.receipt(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let t=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;t<=0&&(t=1),n.confirmations=t}return n}))),{oncePoll:this})}))}getLogs(t){return Ph(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield Gi({filter:this._getFilter(t)}),r=yield this.perform("getLogs",e);return r.forEach((t=>{null==t.removed&&(t.removed=!1)})),Rh.arrayOf(this.formatter.filterLog.bind(this.formatter))(r)}))}getEtherPrice(){return Ph(this,void 0,void 0,(function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})}))}_getBlockTag(t){return Ph(this,void 0,void 0,(function*(){if("number"==typeof(t=yield t)&&t<0){t%1&&Th.throwArgumentError("invalid BlockTag","blockTag",t);let e=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return e+=t,e<0&&(e=0),this.formatter.blockTag(e)}return this.formatter.blockTag(t)}))}getResolver(t){return Ph(this,void 0,void 0,(function*(){const e=yield this._getResolver(t);return null==e?null:new qh(this,e,t)}))}_getResolver(t){return Ph(this,void 0,void 0,(function*(){const e=yield this.getNetwork();e.ensAddress||Th.throwError("network does not support ENS",ni.errors.UNSUPPORTED_OPERATION,{operation:"ENS",network:e.name});const r={to:e.ensAddress,data:"0x0178b8bf"+Ls(t).substring(2)};return this.formatter.callAddress(yield this.call(r))}))}resolveName(t){return Ph(this,void 0,void 0,(function*(){t=yield t;try{return Promise.resolve(this.formatter.address(t))}catch(r){if(fi(t))throw r}"string"!=typeof t&&Th.throwArgumentError("invalid ENS name","name",t);const e=yield this.getResolver(t);return e?yield e.getAddress():null}))}lookupAddress(t){return Ph(this,void 0,void 0,(function*(){t=yield t;const e=(t=this.formatter.address(t)).substring(2).toLowerCase()+".addr.reverse",r=yield this._getResolver(e);if(!r)return null;let n=li(yield this.call({to:r,data:"0x691f3431"+Ls(e).substring(2)}));if(n.length<32||!Mi.from(n.slice(0,32)).eq(32))return null;if(n=n.slice(32),n.length<32)return null;const i=Mi.from(n.slice(0,32)).toNumber();if(n=n.slice(32),i>n.length)return null;const o=ds(n.slice(0,i));return(yield this.resolveName(o))!=t?null:o}))}perform(t,e){return Th.throwError(t+" not implemented",ni.errors.NOT_IMPLEMENTED,{operation:t})}_startEvent(t){this.polling=this._events.filter((t=>t.pollable())).length>0}_stopEvent(t){this.polling=this._events.filter((t=>t.pollable())).length>0}_addEventListener(t,e,r){const n=new Uh(Ch(t),e,r);return this._events.push(n),this._startEvent(n),this}on(t,e){return this._addEventListener(t,e,!1)}once(t,e){return this._addEventListener(t,e,!0)}emit(t,...e){let r=!1,n=[],i=Ch(t);return this._events=this._events.filter((t=>t.tag!==i||(setTimeout((()=>{t.listener.apply(this,e)}),0),r=!0,!t.once||(n.push(t),!1)))),n.forEach((t=>{this._stopEvent(t)})),r}listenerCount(t){if(!t)return this._events.length;let e=Ch(t);return this._events.filter((t=>t.tag===e)).length}listeners(t){if(null==t)return this._events.map((t=>t.listener));let e=Ch(t);return this._events.filter((t=>t.tag===e)).map((t=>t.listener))}off(t,e){if(null==e)return this.removeAllListeners(t);const r=[];let n=!1,i=Ch(t);return this._events=this._events.filter((t=>t.tag!==i||t.listener!=e||(!!n||(n=!0,r.push(t),!1)))),r.forEach((t=>{this._stopEvent(t)})),this}removeAllListeners(t){let e=[];if(null==t)e=this._events,this._events=[];else{const r=Ch(t);this._events=this._events.filter((t=>t.tag!==r||(e.push(t),!1)))}return e.forEach((t=>{this._stopEvent(t)})),this}}var Gh=function(t,e,r,n){return new(r||(r=Promise))((function(i,o){function s(t){try{u(n.next(t))}catch(e){o(e)}}function a(t){try{u(n.throw(t))}catch(e){o(e)}}function u(t){var e;t.done?i(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))};const Wh=new ni("providers/5.1.2"),Jh=["call","estimateGas"];function Kh(t,e,r){if("call"===t&&e.code===ni.errors.SERVER_ERROR){const t=e.error;if(t&&t.message.match("reverted")&&fi(t.data))return t.data}let n=e.message;e.code===ni.errors.SERVER_ERROR&&e.error&&"string"==typeof e.error.message?n=e.error.message:"string"==typeof e.body?n=e.body:"string"==typeof e.responseText&&(n=e.responseText),n=(n||"").toLowerCase();const i=r.transaction||r.signedTransaction;throw n.match(/insufficient funds/)&&Wh.throwError("insufficient funds for intrinsic transaction cost",ni.errors.INSUFFICIENT_FUNDS,{error:e,method:t,transaction:i}),n.match(/nonce too low/)&&Wh.throwError("nonce has already been used",ni.errors.NONCE_EXPIRED,{error:e,method:t,transaction:i}),n.match(/replacement transaction underpriced/)&&Wh.throwError("replacement fee too low",ni.errors.REPLACEMENT_UNDERPRICED,{error:e,method:t,transaction:i}),n.match(/only replay-protected/)&&Wh.throwError("legacy pre-eip-155 transactions not supported",ni.errors.UNSUPPORTED_OPERATION,{error:e,method:t,transaction:i}),Jh.indexOf(t)>=0&&n.match(/gas required exceeds allowance|always failing transaction|execution reverted/)&&Wh.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ni.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:t,transaction:i}),e}function Zh(t){return new Promise((function(e){setTimeout(e,t)}))}function Xh(t){if(t.error){const e=new Error(t.error.message);throw e.code=t.error.code,e.data=t.error.data,e}return t.result}function Qh(t){return t?t.toLowerCase():t}const Yh={};class tc extends da{constructor(t,e,r){if(Wh.checkNew(new.target,tc),super(),t!==Yh)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");$i(this,"provider",e),null==r&&(r=0),"string"==typeof r?($i(this,"_address",this.provider.formatter.address(r)),$i(this,"_index",null)):"number"==typeof r?($i(this,"_index",r),$i(this,"_address",null)):Wh.throwArgumentError("invalid address or index","addressOrIndex",r)}connect(t){return Wh.throwError("cannot alter JSON-RPC Signer connection",ni.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new ec(Yh,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((t=>(t.length<=this._index&&Wh.throwError("unknown account #"+this._index,ni.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(t[this._index]))))}sendUncheckedTransaction(t){t=Wi(t);const e=this.getAddress().then((t=>(t&&(t=t.toLowerCase()),t)));if(null==t.gasLimit){const r=Wi(t);r.from=e,t.gasLimit=this.provider.estimateGas(r)}return Gi({tx:Gi(t),sender:e}).then((({tx:e,sender:r})=>{null!=e.from?e.from.toLowerCase()!==r&&Wh.throwArgumentError("from address mismatch","transaction",t):e.from=r;const n=this.provider.constructor.hexlifyTransaction(e,{from:!0});return this.provider.send("eth_sendTransaction",[n]).then((t=>t),(t=>Kh("sendTransaction",t,n)))}))}signTransaction(t){return Wh.throwError("signing transactions is unsupported",ni.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(t){return this.sendUncheckedTransaction(t).then((t=>bh((()=>this.provider.getTransaction(t).then((e=>{if(null!==e)return this.provider._wrapTransaction(e,t)}))),{onceBlock:this.provider}).catch((e=>{throw e.transactionHash=t,e}))))}signMessage(t){return Gh(this,void 0,void 0,(function*(){const e="string"==typeof t?cs(t):t,r=yield this.getAddress();return yield this.provider.send("eth_sign",[r.toLowerCase(),di(e)])}))}_signTypedData(t,e,r){return Gh(this,void 0,void 0,(function*(){const n=yield Ys.resolveNames(t,e,r,(t=>this.provider.resolveName(t))),i=yield this.getAddress();return yield this.provider.send("eth_signTypedData_v4",[i.toLowerCase(),JSON.stringify(Ys.getPayload(n.domain,e,n.value))])}))}unlock(t){return Gh(this,void 0,void 0,(function*(){const e=this.provider,r=yield this.getAddress();return e.send("personal_unlockAccount",[r.toLowerCase(),t,null])}))}}class ec extends tc{sendTransaction(t){return this.sendUncheckedTransaction(t).then((t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:e=>this.provider.waitForTransaction(t,e)})))}}const rc={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0};class nc extends Hh{constructor(t,e){Wh.checkNew(new.target,nc);let r=e;null==r&&(r=new Promise(((t,e)=>{setTimeout((()=>{this.detectNetwork().then((e=>{t(e)}),(t=>{e(t)}))}),0)}))),super(r),t||(t=Hi(this.constructor,"defaultUrl")()),$i(this,"connection","string"==typeof t?Object.freeze({url:t}):Object.freeze(Wi(t))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(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 Gh(this,void 0,void 0,(function*(){yield Zh(0);let t=null;try{t=yield this.send("eth_chainId",[])}catch(e){try{t=yield this.send("net_version",[])}catch(r){}}if(null!=t){const r=Hi(this.constructor,"getNetwork");try{return r(Mi.from(t).toNumber())}catch(e){return Wh.throwError("could not detect network",ni.errors.NETWORK_ERROR,{chainId:t,event:"invalidNetwork",serverError:e})}}return Wh.throwError("could not detect network",ni.errors.NETWORK_ERROR,{event:"noNetwork"})}))}getSigner(t){return new tc(Yh,this,t)}getUncheckedSigner(t){return this.getSigner(t).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then((t=>t.map((t=>this.formatter.address(t)))))}send(t,e){const r={method:t,params:e,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:Xi(r),provider:this});const n=["eth_chainId","eth_blockNumber"].indexOf(t)>=0;if(n&&this._cache[t])return this._cache[t];const i=yh(this.connection,JSON.stringify(r),Xh).then((t=>(this.emit("debug",{action:"response",request:r,response:t,provider:this}),t)),(t=>{throw this.emit("debug",{action:"response",error:t,request:r,provider:this}),t}));return n&&(this._cache[t]=i,setTimeout((()=>{this._cache[t]=null}),0)),i}prepareRequest(t,e){switch(t){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[Qh(e.address),e.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[Qh(e.address),e.blockTag]];case"getCode":return["eth_getCode",[Qh(e.address),e.blockTag]];case"getStorageAt":return["eth_getStorageAt",[Qh(e.address),e.position,e.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[e.signedTransaction]];case"getBlock":return e.blockTag?["eth_getBlockByNumber",[e.blockTag,!!e.includeTransactions]]:e.blockHash?["eth_getBlockByHash",[e.blockHash,!!e.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[e.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[e.transactionHash]];case"call":return["eth_call",[Hi(this.constructor,"hexlifyTransaction")(e.transaction,{from:!0}),e.blockTag]];case"estimateGas":return["eth_estimateGas",[Hi(this.constructor,"hexlifyTransaction")(e.transaction,{from:!0})]];case"getLogs":return e.filter&&null!=e.filter.address&&(e.filter.address=Qh(e.filter.address)),["eth_getLogs",[e.filter]]}return null}perform(t,e){return Gh(this,void 0,void 0,(function*(){const r=this.prepareRequest(t,e);null==r&&Wh.throwError(t+" not implemented",ni.errors.NOT_IMPLEMENTED,{operation:t});try{return yield this.send(r[0],r[1])}catch(n){return Kh(t,n,e)}}))}_startEvent(t){"pending"===t.tag&&this._startPending(),super._startEvent(t)}_startPending(){if(null!=this._pendingFilter)return;const t=this,e=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=e,e.then((function(r){return function n(){t.send("eth_getFilterChanges",[r]).then((function(r){if(t._pendingFilter!=e)return null;let n=Promise.resolve();return r.forEach((function(e){t._emitted["t:"+e.toLowerCase()]="pending",n=n.then((function(){return t.getTransaction(e).then((function(e){return t.emit("pending",e),null}))}))})),n.then((function(){return Zh(1e3)}))})).then((function(){if(t._pendingFilter==e)return setTimeout((function(){n()}),0),null;t.send("eth_uninstallFilter",[r])})).catch((t=>{}))}(),r})).catch((t=>{}))}_stopEvent(t){"pending"===t.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(t)}static hexlifyTransaction(t,e){const r=Wi(rc);if(e)for(const s in e)e[s]&&(r[s]=!0);var n,i;i=r,(n=t)&&"object"==typeof n||Vi.throwArgumentError("invalid object","object",n),Object.keys(n).forEach((t=>{i[t]||Vi.throwArgumentError("invalid object key - "+t,"transaction:"+t,n)}));const o={};return["gasLimit","gasPrice","type","nonce","value"].forEach((function(e){if(null==t[e])return;const r=vi(t[e]);"gasLimit"===e&&(e="gas"),o[e]=r})),["from","to","data"].forEach((function(e){null!=t[e]&&(o[e]=di(t[e]))})),t.accessList&&(o.accessList=jl(t.accessList)),o}}new ni("units/5.1.0");const ic=["wei","kwei","mwei","gwei","szabo","finney","ether"];function oc(t){return function(t,e){if("string"==typeof e){const t=ic.indexOf(e);-1!==t&&(e=3*t)}return Fi(t,null!=e?e:18)}(t,18)}export{th as C,Rr as F,nc as J,$r as a,Gr as b,Ur as c,Dn as d,oc as f,Fr as o,Ht as r,u as t,Yt as u}; diff --git a/favicon.ico b/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..b2008345391252aeef9cc0bcc66fd0478b34dc69 GIT binary patch literal 15406 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 If6u`G07U6&P5=M^ literal 0 HcmV?d00001 diff --git a/index.html b/index.html new file mode 100644 index 0000000..0618458 --- /dev/null +++ b/index.html @@ -0,0 +1,16 @@ + + + + + + + BSC API + + + + + +
+ + +