@wormhole-foundation/wormhole-connect 0.3.0 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/assets/{cosmos-9t5ds48M.js → cosmos-TcYN7x14.js} +1 -1
- package/dist/assets/index-7UgR9Epe.js +3 -0
- package/dist/assets/{solana-QOFlt-jY.js → solana-r3vOVfGL.js} +2 -2
- package/dist/assets/{solanaEmbed.esm-bag_3ej_.js → solanaEmbed.esm-8lU7Qhqn.js} +1 -1
- package/dist/main.js +81 -81
- package/dist/src/components/FooterNavBar.d.ts.map +1 -1
- package/dist/src/components/Modal.d.ts.map +1 -1
- package/lib/{aptos-UAGgJW-c.js → aptos-AmR02Xhn.js} +1 -1
- package/lib/{aptos-sQp7-Pbn.mjs → aptos-bgjJGWdx.mjs} +1 -1
- package/lib/{ccip-tWrKqmrC.mjs → ccip-0jzIZP4k.mjs} +3 -3
- package/lib/{ccip-3-5aDC6j.js → ccip-9jom-vjr.js} +1 -1
- package/lib/{cosmos-c0ANwRMm.js → cosmos-3y9vDcfR.js} +1 -1
- package/lib/{cosmos-Ut9Azo4e.mjs → cosmos-A4yQRFAh.mjs} +3 -3
- package/lib/{evm-TvfKhHM5.mjs → evm-qmzQ2Gf7.mjs} +4 -4
- package/lib/{evm-y8VI9cdI.js → evm-rKNnB0WS.js} +3 -3
- package/lib/{index-OFCgmgva.js → index-61YO3GC1.js} +1 -1
- package/lib/{index-mQGs2c35.js → index-7-k4mNvr.js} +1 -1
- package/lib/{index-lCZxCUl7.mjs → index-CAnkw_lf.mjs} +2 -2
- package/lib/{index-wJ2yRAWl.js → index-EmNF44zZ.js} +1 -1
- package/lib/{index-h6aptDQb.mjs → index-MNnSI-Yg.mjs} +1 -1
- package/lib/{index-GHV801ue.js → index-N7deTcq6.js} +1 -1
- package/lib/{index-1cOPtvwQ.mjs → index-NUHQsO5_.mjs} +1 -1
- package/lib/{index-1YV56LdA.mjs → index-T-tTHNJx.mjs} +3 -3
- package/lib/{index-gu6kGHH5.mjs → index-niFlyU4I.mjs} +95 -87
- package/lib/{index-5alBFtnd.js → index-xIg_X2Ur.js} +4 -4
- package/lib/{index.es-Y-BkjrQb.js → index.es-6-qO16vM.js} +1 -1
- package/lib/{index.es-xARlRLjN.js → index.es-KiFU950X.js} +2 -2
- package/lib/{index.es-8zczxkxh.mjs → index.es-UHrIJ6HA.mjs} +4 -4
- package/lib/{index.es-HPVa6RUM.js → index.es-W9XPcaAI.js} +1 -1
- package/lib/{index.es-T8CoHm6Q.mjs → index.es-mluIIub3.mjs} +1 -1
- package/lib/{index.es-5qEu2hYx.mjs → index.es-rpqf6luo.mjs} +2 -2
- package/lib/index.js +1 -1
- package/lib/index.mjs +1 -1
- package/lib/{libsodium-wrappers-Xf3S9F8U.js → libsodium-wrappers-K-0Dw1pQ.js} +1 -1
- package/lib/{libsodium-wrappers-Osw_Ockb.mjs → libsodium-wrappers-uIN0mQDN.mjs} +1 -1
- package/lib/{sei-HANHbz2S.mjs → sei-66eAwSMC.mjs} +2 -2
- package/lib/{sei-klsEZJod.js → sei-pCQSS2uT.js} +1 -1
- package/lib/{solana-Yvow0N4F.js → solana-m5L2uZJk.js} +1 -1
- package/lib/{solana-044Ctc8v.mjs → solana-xIgSDPR3.mjs} +3 -3
- package/lib/{solanaEmbed.esm-z7Y2BuKh.mjs → solanaEmbed.esm--PQnDX84.mjs} +2 -2
- package/lib/{solanaEmbed.esm-D9vb9koN.js → solanaEmbed.esm-_zfRQrsu.js} +1 -1
- package/lib/src/components/FooterNavBar.d.ts.map +1 -1
- package/lib/src/components/Modal.d.ts.map +1 -1
- package/lib/{sui-s59NViRM.js → sui-IirB7twW.js} +1 -1
- package/lib/{sui-_2GUfwPV.mjs → sui-NuwWjuO0.mjs} +1 -1
- package/package.json +1 -1
- package/dist/assets/index-bti7uInf.js +0 -3
package/README.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Wormhole Connect
|
|
2
2
|
[](https://docs.wormhole.com/wormhole/wormhole-connect/overview) [](https://www.npmjs.com/package/@wormhole-foundation/wormhole-connect) 
|
|
3
3
|
|
|
4
|
-
Wormhole Connect is a customizable React widget
|
|
4
|
+
Wormhole Connect is a customizable React widget for cross-chain asset transfers powered by Wormhole.
|
|
5
5
|
|
|
6
6
|
[](https://portalbridge.com/)
|
|
7
7
|
|
|
@@ -11,7 +11,7 @@ Wormhole Connect is deployed live in several production apps. Here are a few:
|
|
|
11
11
|
|
|
12
12
|
- [Portal Bridge](https://portalbridge.com/)
|
|
13
13
|
- [Jupiter](https://jup.ag/bridge/wormhole)
|
|
14
|
-
- [
|
|
14
|
+
- [PancakeSwap](https://bridge.pancakeswap.finance/wormhole)
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
## Getting Started
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var kr=Object.defineProperty;var Ur=(e,a,c)=>a in e?kr(e,a,{enumerable:!0,configurable:!0,writable:!0,value:c}):e[a]=c;var Ce=(e,a,c)=>(Ur(e,typeof a!="symbol"?a+"":a,c),c);import{p as tb,g as bb,q as G,r as x8,s as vf,t as Cf,u as ub,v as a9,w as m6,d as T,x as nb,y as E6,z as E9,A as Rr,D as wf,E as m1,F as Lr,G as Bf,H as If,I as rb,J as $r,W as Gr,K as Hr,c as z8,f as xc,B as jr,L as zr,M as sc,O as Jr,P as q4,Q as N,R,S as Z1,T as Wr,U as qr,V as Kr,X as Yr,Y as Vr,Z as Zr,$ as Qr,a0 as Xr,a1 as ei,a2 as ib,a3 as ai,a4 as ci,a5 as ob,a6 as di,a7 as fi,a8 as ti,o as lc,a9 as bi}from"../main.js";import{s as ui,h as ni,u as ri}from"./index-
|
|
1
|
+
var kr=Object.defineProperty;var Ur=(e,a,c)=>a in e?kr(e,a,{enumerable:!0,configurable:!0,writable:!0,value:c}):e[a]=c;var Ce=(e,a,c)=>(Ur(e,typeof a!="symbol"?a+"":a,c),c);import{p as tb,g as bb,q as G,r as x8,s as vf,t as Cf,u as ub,v as a9,w as m6,d as T,x as nb,y as E6,z as E9,A as Rr,D as wf,E as m1,F as Lr,G as Bf,H as If,I as rb,J as $r,W as Gr,K as Hr,c as z8,f as xc,B as jr,L as zr,M as sc,O as Jr,P as q4,Q as N,R,S as Z1,T as Wr,U as qr,V as Kr,X as Yr,Y as Vr,Z as Zr,$ as Qr,a0 as Xr,a1 as ei,a2 as ib,a3 as ai,a4 as ci,a5 as ob,a6 as di,a7 as fi,a8 as ti,o as lc,a9 as bi}from"../main.js";import{s as ui,h as ni,u as ri}from"./index-7UgR9Epe.js";import{r as ii}from"./libsodium-wrappers-XgohdhTj.js";var V2=function(){return V2=Object.assign||function(a){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var t in c)Object.prototype.hasOwnProperty.call(c,t)&&(a[t]=c[t])}return a},V2.apply(this,arguments)};var Sf={exports:{}};const xb=e=>typeof e=="object"&&e!==null,sb=Symbol("skip"),K4=e=>xb(e)&&!(e instanceof RegExp)&&!(e instanceof Error)&&!(e instanceof Date),vd=(e,a,c,d=new WeakMap)=>{if(c={deep:!1,target:{},...c},d.has(e))return d.get(e);d.set(e,c.target);const{target:f}=c;delete c.target;const t=n=>n.map(s=>K4(s)?vd(s,a,c,d):s);if(Array.isArray(e))return t(e);for(const[n,s]of Object.entries(e)){const p=a(n,s,e);if(p===sb)continue;let[A,S,{shouldRecurse:_=!0}={}]=p;A!=="__proto__"&&(c.deep&&_&&K4(S)&&(S=Array.isArray(S)?t(S):vd(S,a,c,d)),f[A]=S)}return f};Sf.exports=(e,a,c)=>{if(!xb(e))throw new TypeError(`Expected an object, got \`${e}\` (${typeof e})`);return vd(e,a,c)};Sf.exports.mapObjectSkip=sb;var oi=Sf.exports;function xi(e){return e.toLowerCase()}var si=[/([a-z0-9])([A-Z])/g,/([A-Z])([A-Z][a-z])/g],li=/[^A-Z0-9]+/gi;function Di(e,a){a===void 0&&(a={});for(var c=a.splitRegexp,d=c===void 0?si:c,f=a.stripRegexp,t=f===void 0?li:f,n=a.transform,s=n===void 0?xi:n,p=a.delimiter,A=p===void 0?" ":p,S=Y4(Y4(e,d,"$1\0$2"),t,"\0"),_=0,C=S.length;S.charAt(_)==="\0";)_++;for(;S.charAt(C-1)==="\0";)C--;return S.slice(_,C).split("\0").map(s).join(A)}function Y4(e,a,c){return a instanceof RegExp?e.replace(a,c):a.reduce(function(d,f){return d.replace(f,c)},e)}function hi(e,a){return a===void 0&&(a={}),Di(e,V2({delimiter:"."},a))}function pi(e,a){return a===void 0&&(a={}),hi(e,V2({delimiter:"_"},a))}const mi=Object.freeze(Object.defineProperty({__proto__:null,snakeCase:pi},Symbol.toStringTag,{value:"Module"})),Ei=tb(mi),Ai=oi,{snakeCase:Fi}=Ei;var yi=function(e,a){return a=Object.assign({deep:!0,exclude:[],parsingOptions:{}},a),Ai(e,function(c,d){return[gi(a.exclude,c)?c:Fi(c,a.parsingOptions),d]},a)};function gi(e,a){return e.some(function(c){return typeof c=="string"?c===a:c.test(a)})}const a8=bb(yi);var vi={exports:{}};/*! store2 - v2.14.2 - 2022-07-18
|
|
2
2
|
* Copyright (c) 2022 Nathan Bubna; Licensed (MIT OR GPL-3.0) */(function(e){(function(a,c){var d={version:"2.14.2",areas:{},apis:{},nsdelim:".",inherit:function(t,n){for(var s in t)n.hasOwnProperty(s)||Object.defineProperty(n,s,Object.getOwnPropertyDescriptor(t,s));return n},stringify:function(t,n){return t===void 0||typeof t=="function"?t+"":JSON.stringify(t,n||d.replace)},parse:function(t,n){try{return JSON.parse(t,n||d.revive)}catch{return t}},fn:function(t,n){d.storeAPI[t]=n;for(var s in d.apis)d.apis[s][t]=n},get:function(t,n){return t.getItem(n)},set:function(t,n,s){t.setItem(n,s)},remove:function(t,n){t.removeItem(n)},key:function(t,n){return t.key(n)},length:function(t){return t.length},clear:function(t){t.clear()},Store:function(t,n,s){var p=d.inherit(d.storeAPI,function(S,_,C){return arguments.length===0?p.getAll():typeof _=="function"?p.transact(S,_,C):_!==void 0?p.set(S,_,C):typeof S=="string"||typeof S=="number"?p.get(S):typeof S=="function"?p.each(S):S?p.setAll(S,_):p.clear()});p._id=t;try{var A="__store2_test";n.setItem(A,"ok"),p._area=n,n.removeItem(A)}catch{p._area=d.storage("fake")}return p._ns=s||"",d.areas[t]||(d.areas[t]=p._area),d.apis[p._ns+p._id]||(d.apis[p._ns+p._id]=p),p},storeAPI:{area:function(t,n){var s=this[t];return(!s||!s.area)&&(s=d.Store(t,n,this._ns),this[t]||(this[t]=s)),s},namespace:function(t,n,s){if(s=s||this._delim||d.nsdelim,!t)return this._ns?this._ns.substring(0,this._ns.length-s.length):"";var p=t,A=this[p];if((!A||!A.namespace)&&(A=d.Store(this._id,this._area,this._ns+p+s),A._delim=s,this[p]||(this[p]=A),!n))for(var S in d.areas)A.area(S,d.areas[S]);return A},isFake:function(t){return t?(this._real=this._area,this._area=d.storage("fake")):t===!1&&(this._area=this._real||this._area),this._area.name==="fake"},toString:function(){return"store"+(this._ns?"."+this.namespace():"")+"["+this._id+"]"},has:function(t){return this._area.has?this._area.has(this._in(t)):this._in(t)in this._area},size:function(){return this.keys().length},each:function(t,n){for(var s=0,p=d.length(this._area);s<p;s++){var A=this._out(d.key(this._area,s));if(A!==void 0&&t.call(this,A,this.get(A),n)===!1)break;p>d.length(this._area)&&(p--,s--)}return n||this},keys:function(t){return this.each(function(n,s,p){p.push(n)},t||[])},get:function(t,n){var s=d.get(this._area,this._in(t)),p;return typeof n=="function"&&(p=n,n=null),s!==null?d.parse(s,p):n??s},getAll:function(t){return this.each(function(n,s,p){p[n]=s},t||{})},transact:function(t,n,s){var p=this.get(t,s),A=n(p);return this.set(t,A===void 0?p:A),this},set:function(t,n,s){var p=this.get(t),A;return p!=null&&s===!1?n:(typeof s=="function"&&(A=s,s=void 0),d.set(this._area,this._in(t),d.stringify(n,A),s)||p)},setAll:function(t,n){var s,p;for(var A in t)p=t[A],this.set(A,p,n)!==p&&(s=!0);return s},add:function(t,n,s){var p=this.get(t);if(p instanceof Array)n=p.concat(n);else if(p!==null){var A=typeof p;if(A===typeof n&&A==="object"){for(var S in n)p[S]=n[S];n=p}else n=p+n}return d.set(this._area,this._in(t),d.stringify(n,s)),n},remove:function(t,n){var s=this.get(t,n);return d.remove(this._area,this._in(t)),s},clear:function(){return this._ns?this.each(function(t){d.remove(this._area,this._in(t))},1):d.clear(this._area),this},clearAll:function(){var t=this._area;for(var n in d.areas)d.areas.hasOwnProperty(n)&&(this._area=d.areas[n],this.clear());return this._area=t,this},_in:function(t){return typeof t!="string"&&(t=d.stringify(t)),this._ns?this._ns+t:t},_out:function(t){return this._ns?t&&t.indexOf(this._ns)===0?t.substring(this._ns.length):void 0:t}},storage:function(t){return d.inherit(d.storageAPI,{items:{},name:t})},storageAPI:{length:0,has:function(t){return this.items.hasOwnProperty(t)},key:function(t){var n=0;for(var s in this.items)if(this.has(s)&&t===n++)return s},setItem:function(t,n){this.has(t)||this.length++,this.items[t]=n},removeItem:function(t){this.has(t)&&(delete this.items[t],this.length--)},getItem:function(t){return this.has(t)?this.items[t]:null},clear:function(){for(var t in this.items)this.removeItem(t)}}},f=d.Store("local",function(){try{return localStorage}catch{}}());f.local=f,f._=d,f.area("session",function(){try{return sessionStorage}catch{}}()),f.area("page",d.storage("page")),typeof c=="function"&&c.amd!==void 0?c("store2",[],function(){return f}):e.exports?e.exports=f:(a.store&&(d.conflict=a.store),a.store=f)})(G,G&&G.define)})(vi);var lb={exports:{}};(function(e,a){(function(c,d){e.exports=d()})(G,function(){return c={418:function(f,t){(function(n,s){for(var p in s)n[p]=s[p]})(t,function(n){var s={};function p(A){if(s[A])return s[A].exports;var S=s[A]={i:A,l:!1,exports:{}};return n[A].call(S.exports,S,S.exports,p),S.l=!0,S.exports}return p.m=n,p.c=s,p.i=function(A){return A},p.d=function(A,S,_){p.o(A,S)||Object.defineProperty(A,S,{configurable:!1,enumerable:!0,get:_})},p.n=function(A){var S=A&&A.__esModule?function(){return A.default}:function(){return A};return p.d(S,"a",S),S},p.o=function(A,S){return Object.prototype.hasOwnProperty.call(A,S)},p.p="",p(p.s=1)}([function(n,s,p){Object.defineProperty(s,"__esModule",{value:!0});var A=p(3),S=function(){function _(C,h){C===void 0&&(C={}),h===void 0&&(h={splitValues:!1});var l,x=this;this.headersMap={},C&&(typeof Headers<"u"&&C instanceof Headers?A.getHeaderKeys(C).forEach(function(i){A.getHeaderValues(C,i).forEach(function(E){h.splitValues?x.append(i,A.splitHeaderValue(E)):x.append(i,E)})}):typeof(l=C)=="object"&&typeof l.headersMap=="object"&&typeof l.forEach=="function"?C.forEach(function(i,E){x.append(i,E)}):typeof Map<"u"&&C instanceof Map?C.forEach(function(i,E){x.append(E,i)}):typeof C=="string"?this.appendFromString(C):typeof C=="object"&&Object.getOwnPropertyNames(C).forEach(function(i){var E=C[i];Array.isArray(E)?E.forEach(function(y){x.append(i,y)}):x.append(i,E)}))}return _.prototype.appendFromString=function(C){for(var h=C.split(`\r
|
|
3
3
|
`),l=0;l<h.length;l++){var x=h[l],i=x.indexOf(":");if(i>0){var E=x.substring(0,i).trim(),y=x.substring(i+1).trim();this.append(E,y)}}},_.prototype.delete=function(C,h){var l=A.normalizeName(C);if(h===void 0)delete this.headersMap[l];else{var x=this.headersMap[l];if(x){var i=x.indexOf(h);i>=0&&x.splice(i,1),x.length===0&&delete this.headersMap[l]}}},_.prototype.append=function(C,h){var l=this,x=A.normalizeName(C);Array.isArray(this.headersMap[x])||(this.headersMap[x]=[]),Array.isArray(h)?h.forEach(function(i){l.headersMap[x].push(A.normalizeValue(i))}):this.headersMap[x].push(A.normalizeValue(h))},_.prototype.set=function(C,h){var l=A.normalizeName(C);if(Array.isArray(h)){var x=[];h.forEach(function(i){x.push(A.normalizeValue(i))}),this.headersMap[l]=x}else this.headersMap[l]=[A.normalizeValue(h)]},_.prototype.has=function(C,h){var l=this.headersMap[A.normalizeName(C)];if(!Array.isArray(l))return!1;if(h!==void 0){var x=A.normalizeValue(h);return l.indexOf(x)>=0}return!0},_.prototype.get=function(C){var h=this.headersMap[A.normalizeName(C)];return h!==void 0?h.concat():[]},_.prototype.forEach=function(C){var h=this;Object.getOwnPropertyNames(this.headersMap).forEach(function(l){C(l,h.headersMap[l])},this)},_.prototype.toHeaders=function(){if(typeof Headers<"u"){var C=new Headers;return this.forEach(function(h,l){l.forEach(function(x){C.append(h,x)})}),C}throw new Error("Headers class is not defined")},_}();s.BrowserHeaders=S},function(n,s,p){Object.defineProperty(s,"__esModule",{value:!0});var A=p(0);s.BrowserHeaders=A.BrowserHeaders},function(n,s,p){Object.defineProperty(s,"__esModule",{value:!0}),s.iterateHeaders=function(A,S){for(var _=A[Symbol.iterator](),C=_.next();!C.done;)S(C.value[0]),C=_.next()},s.iterateHeadersKeys=function(A,S){for(var _=A.keys(),C=_.next();!C.done;)S(C.value),C=_.next()}},function(n,s,p){Object.defineProperty(s,"__esModule",{value:!0});var A=p(2);s.normalizeName=function(S){if(typeof S!="string"&&(S=String(S)),/[^a-z0-9\-#$%&'*+.\^_`|~]/i.test(S))throw new TypeError("Invalid character in header field name");return S.toLowerCase()},s.normalizeValue=function(S){return typeof S!="string"&&(S=String(S)),S},s.getHeaderValues=function(S,_){var C=S;if(C instanceof Headers&&C.getAll)return C.getAll(_);var h=C.get(_);return h&&typeof h=="string"?[h]:h},s.getHeaderKeys=function(S){var _=S,C={},h=[];return _.keys?A.iterateHeadersKeys(_,function(l){C[l]||(C[l]=!0,h.push(l))}):_.forEach?_.forEach(function(l,x){C[x]||(C[x]=!0,h.push(x))}):A.iterateHeaders(_,function(l){var x=l[0];C[x]||(C[x]=!0,h.push(x))}),h},s.splitHeaderValue=function(S){var _=[];return S.split(", ").forEach(function(C){C.split(",").forEach(function(h){_.push(h)})}),_}}]))},617:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.ChunkParser=t.ChunkType=t.encodeASCII=t.decodeASCII=void 0;var s,p=n(65);function A(i){return(E=i)===9||E===10||E===13||i>=32&&i<=126;var E}function S(i){for(var E=0;E!==i.length;++E)if(!A(i[E]))throw new Error("Metadata is not valid (printable) ASCII");return String.fromCharCode.apply(String,Array.prototype.slice.call(i))}function _(i){return(128&i.getUint8(0))==128}function C(i){return i.getUint32(1,!1)}function h(i,E,y){return i.byteLength-E>=y}function l(i,E,y){if(i.slice)return i.slice(E,y);var P=i.length;y!==void 0&&(P=y);for(var u=new Uint8Array(P-E),D=0,g=E;g<P;g++)u[D++]=i[g];return u}t.decodeASCII=S,t.encodeASCII=function(i){for(var E=new Uint8Array(i.length),y=0;y!==i.length;++y){var P=i.charCodeAt(y);if(!A(P))throw new Error("Metadata contains invalid ASCII");E[y]=P}return E},function(i){i[i.MESSAGE=1]="MESSAGE",i[i.TRAILERS=2]="TRAILERS"}(s=t.ChunkType||(t.ChunkType={}));var x=function(){function i(){this.buffer=null,this.position=0}return i.prototype.parse=function(E,y){if(E.length===0&&y)return[];var P,u=[];if(this.buffer==null)this.buffer=E,this.position=0;else if(this.position===this.buffer.byteLength)this.buffer=E,this.position=0;else{var D=this.buffer.byteLength-this.position,g=new Uint8Array(D+E.byteLength),H=l(this.buffer,this.position);g.set(H,0);var U=new Uint8Array(E);g.set(U,D),this.buffer=g,this.position=0}for(;;){if(!h(this.buffer,this.position,5))return u;var $=l(this.buffer,this.position,this.position+5),q=new DataView($.buffer,$.byteOffset,$.byteLength),v=C(q);if(!h(this.buffer,this.position,5+v))return u;var b=l(this.buffer,this.position+5,this.position+5+v);if(this.position+=5+v,_(q))return u.push({chunkType:s.TRAILERS,trailers:(P=b,new p.Metadata(S(P)))}),u;u.push({chunkType:s.MESSAGE,data:b})}},i}();t.ChunkParser=x},8:function(f,t){var n;Object.defineProperty(t,"__esModule",{value:!0}),t.httpStatusToCode=t.Code=void 0,function(s){s[s.OK=0]="OK",s[s.Canceled=1]="Canceled",s[s.Unknown=2]="Unknown",s[s.InvalidArgument=3]="InvalidArgument",s[s.DeadlineExceeded=4]="DeadlineExceeded",s[s.NotFound=5]="NotFound",s[s.AlreadyExists=6]="AlreadyExists",s[s.PermissionDenied=7]="PermissionDenied",s[s.ResourceExhausted=8]="ResourceExhausted",s[s.FailedPrecondition=9]="FailedPrecondition",s[s.Aborted=10]="Aborted",s[s.OutOfRange=11]="OutOfRange",s[s.Unimplemented=12]="Unimplemented",s[s.Internal=13]="Internal",s[s.Unavailable=14]="Unavailable",s[s.DataLoss=15]="DataLoss",s[s.Unauthenticated=16]="Unauthenticated"}(n=t.Code||(t.Code={})),t.httpStatusToCode=function(s){switch(s){case 0:return n.Internal;case 200:return n.OK;case 400:return n.InvalidArgument;case 401:return n.Unauthenticated;case 403:return n.PermissionDenied;case 404:return n.NotFound;case 409:return n.Aborted;case 412:return n.FailedPrecondition;case 429:return n.ResourceExhausted;case 499:return n.Canceled;case 500:return n.Unknown;case 501:return n.Unimplemented;case 503:return n.Unavailable;case 504:return n.DeadlineExceeded;default:return n.Unknown}}},934:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.client=void 0;var s=n(65),p=n(617),A=n(8),S=n(346),_=n(57),C=n(882);t.client=function(x,i){return new h(x,i)};var h=function(){function x(i,E){this.started=!1,this.sentFirstMessage=!1,this.completed=!1,this.closed=!1,this.finishedSending=!1,this.onHeadersCallbacks=[],this.onMessageCallbacks=[],this.onEndCallbacks=[],this.parser=new p.ChunkParser,this.methodDefinition=i,this.props=E,this.createTransport()}return x.prototype.createTransport=function(){var i=this.props.host+"/"+this.methodDefinition.service.serviceName+"/"+this.methodDefinition.methodName,E={methodDefinition:this.methodDefinition,debug:this.props.debug||!1,url:i,onHeaders:this.onTransportHeaders.bind(this),onChunk:this.onTransportChunk.bind(this),onEnd:this.onTransportEnd.bind(this)};this.props.transport?this.transport=this.props.transport(E):this.transport=_.makeDefaultTransport(E)},x.prototype.onTransportHeaders=function(i,E){if(this.props.debug&&S.debug("onHeaders",i,E),this.closed)this.props.debug&&S.debug("grpc.onHeaders received after request was closed - ignoring");else if(E!==0){this.responseHeaders=i,this.props.debug&&S.debug("onHeaders.responseHeaders",JSON.stringify(this.responseHeaders,null,2));var y=l(i);this.props.debug&&S.debug("onHeaders.gRPCStatus",y);var P=y&&y>=0?y:A.httpStatusToCode(E);this.props.debug&&S.debug("onHeaders.code",P);var u=i.get("grpc-message")||[];if(this.props.debug&&S.debug("onHeaders.gRPCMessage",u),this.rawOnHeaders(i),P!==A.Code.OK){var D=this.decodeGRPCStatus(u[0]);this.rawOnError(P,D,i)}}},x.prototype.onTransportChunk=function(i){var E=this;if(this.closed)this.props.debug&&S.debug("grpc.onChunk received after request was closed - ignoring");else{var y=[];try{y=this.parser.parse(i)}catch(P){return this.props.debug&&S.debug("onChunk.parsing error",P,P.message),void this.rawOnError(A.Code.Internal,"parsing error: "+P.message)}y.forEach(function(P){if(P.chunkType===p.ChunkType.MESSAGE){var u=E.methodDefinition.responseType.deserializeBinary(P.data);E.rawOnMessage(u)}else P.chunkType===p.ChunkType.TRAILERS&&(E.responseHeaders?(E.responseTrailers=new s.Metadata(P.trailers),E.props.debug&&S.debug("onChunk.trailers",E.responseTrailers)):(E.responseHeaders=new s.Metadata(P.trailers),E.rawOnHeaders(E.responseHeaders)))})}},x.prototype.onTransportEnd=function(){if(this.props.debug&&S.debug("grpc.onEnd"),this.closed)this.props.debug&&S.debug("grpc.onEnd received after request was closed - ignoring");else if(this.responseTrailers!==void 0){var i=l(this.responseTrailers);if(i!==null){var E=this.responseTrailers.get("grpc-message"),y=this.decodeGRPCStatus(E[0]);this.rawOnEnd(i,y,this.responseTrailers)}else this.rawOnError(A.Code.Internal,"Response closed without grpc-status (Trailers provided)")}else{if(this.responseHeaders===void 0)return void this.rawOnError(A.Code.Unknown,"Response closed without headers");var P=l(this.responseHeaders),u=this.responseHeaders.get("grpc-message");if(this.props.debug&&S.debug("grpc.headers only response ",P,u),P===null)return void this.rawOnEnd(A.Code.Unknown,"Response closed without grpc-status (Headers only)",this.responseHeaders);var D=this.decodeGRPCStatus(u[0]);this.rawOnEnd(P,D,this.responseHeaders)}},x.prototype.decodeGRPCStatus=function(i){if(!i)return"";try{return decodeURIComponent(i)}catch{return i}},x.prototype.rawOnEnd=function(i,E,y){var P=this;this.props.debug&&S.debug("rawOnEnd",i,E,y),this.completed||(this.completed=!0,this.onEndCallbacks.forEach(function(u){if(!P.closed)try{u(i,E,y)}catch(D){setTimeout(function(){throw D},0)}}))},x.prototype.rawOnHeaders=function(i){this.props.debug&&S.debug("rawOnHeaders",i),this.completed||this.onHeadersCallbacks.forEach(function(E){try{E(i)}catch(y){setTimeout(function(){throw y},0)}})},x.prototype.rawOnError=function(i,E,y){var P=this;y===void 0&&(y=new s.Metadata),this.props.debug&&S.debug("rawOnError",i,E),this.completed||(this.completed=!0,this.onEndCallbacks.forEach(function(u){if(!P.closed)try{u(i,E,y)}catch(D){setTimeout(function(){throw D},0)}}))},x.prototype.rawOnMessage=function(i){var E=this;this.props.debug&&S.debug("rawOnMessage",i.toObject()),this.completed||this.closed||this.onMessageCallbacks.forEach(function(y){if(!E.closed)try{y(i)}catch(P){setTimeout(function(){throw P},0)}})},x.prototype.onHeaders=function(i){this.onHeadersCallbacks.push(i)},x.prototype.onMessage=function(i){this.onMessageCallbacks.push(i)},x.prototype.onEnd=function(i){this.onEndCallbacks.push(i)},x.prototype.start=function(i){if(this.started)throw new Error("Client already started - cannot .start()");this.started=!0;var E=new s.Metadata(i||{});E.set("content-type","application/grpc-web+proto"),E.set("x-grpc-web","1"),this.transport.start(E)},x.prototype.send=function(i){if(!this.started)throw new Error("Client not started - .start() must be called before .send()");if(this.closed)throw new Error("Client already closed - cannot .send()");if(this.finishedSending)throw new Error("Client already finished sending - cannot .send()");if(!this.methodDefinition.requestStream&&this.sentFirstMessage)throw new Error("Message already sent for non-client-streaming method - cannot .send()");this.sentFirstMessage=!0;var E=C.frameRequest(i);this.transport.sendMessage(E)},x.prototype.finishSend=function(){if(!this.started)throw new Error("Client not started - .finishSend() must be called before .close()");if(this.closed)throw new Error("Client already closed - cannot .send()");if(this.finishedSending)throw new Error("Client already finished sending - cannot .finishSend()");this.finishedSending=!0,this.transport.finishSend()},x.prototype.close=function(){if(!this.started)throw new Error("Client not started - .start() must be called before .close()");if(this.closed)throw new Error("Client already closed - cannot .close()");this.closed=!0,this.props.debug&&S.debug("request.abort aborting request"),this.transport.cancel()},x}();function l(x){var i=x.get("grpc-status")||[];if(i.length>0)try{var E=i[0];return parseInt(E,10)}catch{return null}return null}},346:function(f,t){Object.defineProperty(t,"__esModule",{value:!0}),t.debug=void 0,t.debug=function(){for(var n=[],s=0;s<arguments.length;s++)n[s]=arguments[s];console.debug?console.debug.apply(null,n):console.log.apply(null,n)}},607:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.grpc=void 0;var s,p=n(418),A=n(57),S=n(229),_=n(540),C=n(210),h=n(859),l=n(8),x=n(938),i=n(35),E=n(934);(s=t.grpc||(t.grpc={})).setDefaultTransport=A.setDefaultTransportFactory,s.CrossBrowserHttpTransport=h.CrossBrowserHttpTransport,s.FetchReadableStreamTransport=S.FetchReadableStreamTransport,s.XhrTransport=C.XhrTransport,s.WebsocketTransport=_.WebsocketTransport,s.Code=l.Code,s.Metadata=p.BrowserHeaders,s.client=function(y,P){return E.client(y,P)},s.invoke=x.invoke,s.unary=i.unary},938:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.invoke=void 0;var s=n(934);t.invoke=function(p,A){if(p.requestStream)throw new Error(".invoke cannot be used with client-streaming methods. Use .client instead.");var S=s.client(p,{host:A.host,transport:A.transport,debug:A.debug});return A.onHeaders&&S.onHeaders(A.onHeaders),A.onMessage&&S.onMessage(A.onMessage),A.onEnd&&S.onEnd(A.onEnd),S.start(A.metadata),S.send(A.request),S.finishSend(),{close:function(){S.close()}}}},65:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.Metadata=void 0;var s=n(418);Object.defineProperty(t,"Metadata",{enumerable:!0,get:function(){return s.BrowserHeaders}})},57:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.makeDefaultTransport=t.setDefaultTransportFactory=void 0;var s=n(859),p=function(A){return s.CrossBrowserHttpTransport({withCredentials:!1})(A)};t.setDefaultTransportFactory=function(A){p=A},t.makeDefaultTransport=function(A){return p(A)}},229:function(f,t,n){var s=this&&this.__assign||function(){return(s=Object.assign||function(_){for(var C,h=1,l=arguments.length;h<l;h++)for(var x in C=arguments[h])Object.prototype.hasOwnProperty.call(C,x)&&(_[x]=C[x]);return _}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.detectFetchSupport=t.FetchReadableStreamTransport=void 0;var p=n(65),A=n(346);t.FetchReadableStreamTransport=function(_){return function(C){return function(h,l){return h.debug&&A.debug("fetchRequest",h),new S(h,l)}(C,_)}};var S=function(){function _(C,h){this.cancelled=!1,this.controller=self.AbortController&&new AbortController,this.options=C,this.init=h}return _.prototype.pump=function(C,h){var l=this;if(this.reader=C,this.cancelled)return this.options.debug&&A.debug("Fetch.pump.cancel at first pump"),void this.reader.cancel().catch(function(x){l.options.debug&&A.debug("Fetch.pump.reader.cancel exception",x)});this.reader.read().then(function(x){if(x.done)return l.options.onEnd(),h;l.options.onChunk(x.value),l.pump(l.reader,h)}).catch(function(x){l.cancelled?l.options.debug&&A.debug("Fetch.catch - request cancelled"):(l.cancelled=!0,l.options.debug&&A.debug("Fetch.catch",x.message),l.options.onEnd(x))})},_.prototype.send=function(C){var h=this;fetch(this.options.url,s(s({},this.init),{headers:this.metadata.toHeaders(),method:"POST",body:C,signal:this.controller&&this.controller.signal})).then(function(l){if(h.options.debug&&A.debug("Fetch.response",l),h.options.onHeaders(new p.Metadata(l.headers),l.status),!l.body)return l;h.pump(l.body.getReader(),l)}).catch(function(l){h.cancelled?h.options.debug&&A.debug("Fetch.catch - request cancelled"):(h.cancelled=!0,h.options.debug&&A.debug("Fetch.catch",l.message),h.options.onEnd(l))})},_.prototype.sendMessage=function(C){this.send(C)},_.prototype.finishSend=function(){},_.prototype.start=function(C){this.metadata=C},_.prototype.cancel=function(){var C=this;this.cancelled?this.options.debug&&A.debug("Fetch.cancel already cancelled"):(this.cancelled=!0,this.controller?(this.options.debug&&A.debug("Fetch.cancel.controller.abort"),this.controller.abort()):this.options.debug&&A.debug("Fetch.cancel.missing abort controller"),this.reader?(this.options.debug&&A.debug("Fetch.cancel.reader.cancel"),this.reader.cancel().catch(function(h){C.options.debug&&A.debug("Fetch.cancel.reader.cancel exception",h)})):this.options.debug&&A.debug("Fetch.cancel before reader"))},_}();t.detectFetchSupport=function(){return typeof Response<"u"&&Response.prototype.hasOwnProperty("body")&&typeof Headers=="function"}},859:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.CrossBrowserHttpTransport=void 0;var s=n(229),p=n(210);t.CrossBrowserHttpTransport=function(A){if(s.detectFetchSupport()){var S={credentials:A.withCredentials?"include":"same-origin"};return s.FetchReadableStreamTransport(S)}return p.XhrTransport({withCredentials:A.withCredentials})}},210:function(f,t,n){var s,p=this&&this.__extends||(s=function(i,E){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,P){y.__proto__=P}||function(y,P){for(var u in P)Object.prototype.hasOwnProperty.call(P,u)&&(y[u]=P[u])})(i,E)},function(i,E){function y(){this.constructor=i}s(i,E),i.prototype=E===null?Object.create(E):(y.prototype=E.prototype,new y)});Object.defineProperty(t,"__esModule",{value:!0}),t.stringToArrayBuffer=t.MozChunkedArrayBufferXHR=t.XHR=t.XhrTransport=void 0;var A=n(65),S=n(346),_=n(849);t.XhrTransport=function(i){return function(E){if(_.detectMozXHRSupport())return new h(E,i);if(_.detectXHROverrideMimeTypeSupport())return new C(E,i);throw new Error("This environment's XHR implementation cannot support binary transfer.")}};var C=function(){function i(E,y){this.options=E,this.init=y}return i.prototype.onProgressEvent=function(){this.options.debug&&S.debug("XHR.onProgressEvent.length: ",this.xhr.response.length);var E=this.xhr.response.substr(this.index);this.index=this.xhr.response.length;var y=x(E);this.options.onChunk(y)},i.prototype.onLoadEvent=function(){this.options.debug&&S.debug("XHR.onLoadEvent"),this.options.onEnd()},i.prototype.onStateChange=function(){this.options.debug&&S.debug("XHR.onStateChange",this.xhr.readyState),this.xhr.readyState===XMLHttpRequest.HEADERS_RECEIVED&&this.options.onHeaders(new A.Metadata(this.xhr.getAllResponseHeaders()),this.xhr.status)},i.prototype.sendMessage=function(E){this.xhr.send(E)},i.prototype.responseCallback=function(E){this.options.onHeaders(new A.Metadata(function(y){var P={};for(var u in y){var D=y[u];y.hasOwnProperty(u)&&D!==void 0&&(P[u]=D)}return P}(E.headers)),E.statusCode)},i.prototype.finishSend=function(){},i.prototype.start=function(E){var y=this;this.metadata=E;var P=new XMLHttpRequest;this.xhr=P,P.open("POST",this.options.url),this.configureXhr(),this.metadata.forEach(function(u,D){P.setRequestHeader(u,D.join(", "))}),P.withCredentials=!!this.init.withCredentials,P.addEventListener("readystatechange",this.onStateChange.bind(this)),P.addEventListener("progress",this.onProgressEvent.bind(this)),P.addEventListener("loadend",this.onLoadEvent.bind(this)),P.addEventListener("error",function(u){y.options.debug&&S.debug("XHR.error",u),y.options.onEnd(u.error)})},i.prototype.configureXhr=function(){this.xhr.responseType="text",this.xhr.overrideMimeType("text/plain; charset=x-user-defined")},i.prototype.cancel=function(){this.options.debug&&S.debug("XHR.abort"),this.xhr.abort()},i}();t.XHR=C;var h=function(i){function E(){return i!==null&&i.apply(this,arguments)||this}return p(E,i),E.prototype.configureXhr=function(){this.options.debug&&S.debug("MozXHR.configureXhr: setting responseType to 'moz-chunked-arraybuffer'"),this.xhr.responseType="moz-chunked-arraybuffer"},E.prototype.onProgressEvent=function(){var y=this.xhr.response;this.options.debug&&S.debug("MozXHR.onProgressEvent: ",new Uint8Array(y)),this.options.onChunk(new Uint8Array(y))},E}(C);function l(i,E){var y=i.charCodeAt(E);if(y>=55296&&y<=56319){var P=i.charCodeAt(E+1);P>=56320&&P<=57343&&(y=65536+(y-55296<<10)+(P-56320))}return y}function x(i){for(var E=new Uint8Array(i.length),y=0,P=0;P<i.length;P++){var u=String.prototype.codePointAt?i.codePointAt(P):l(i,P);E[y++]=255&u}return E}t.MozChunkedArrayBufferXHR=h,t.stringToArrayBuffer=x},849:function(f,t){var n;function s(){if(n!==void 0)return n;if(XMLHttpRequest){n=new XMLHttpRequest;try{n.open("GET","https://localhost")}catch{}}return n}function p(A){var S=s();if(!S)return!1;try{return S.responseType=A,S.responseType===A}catch{}return!1}Object.defineProperty(t,"__esModule",{value:!0}),t.detectXHROverrideMimeTypeSupport=t.detectMozXHRSupport=t.xhrSupportsResponseType=void 0,t.xhrSupportsResponseType=p,t.detectMozXHRSupport=function(){return typeof XMLHttpRequest<"u"&&p("moz-chunked-arraybuffer")},t.detectXHROverrideMimeTypeSupport=function(){return typeof XMLHttpRequest<"u"&&XMLHttpRequest.prototype.hasOwnProperty("overrideMimeType")}},540:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.WebsocketTransport=void 0;var s,p=n(346),A=n(617);(function(_){_[_.FINISH_SEND=1]="FINISH_SEND"})(s||(s={}));var S=new Uint8Array([1]);t.WebsocketTransport=function(){return function(_){return function(C){C.debug&&p.debug("websocketRequest",C);var h,l=function(E){if(E.substr(0,8)==="https://")return"wss://"+E.substr(8);if(E.substr(0,7)==="http://")return"ws://"+E.substr(7);throw new Error("Websocket transport constructed with non-https:// or http:// host.")}(C.url),x=[];function i(E){if(E===s.FINISH_SEND)h.send(S);else{var y=E,P=new Int8Array(y.byteLength+1);P.set(new Uint8Array([0])),P.set(y,1),h.send(P)}}return{sendMessage:function(E){h&&h.readyState!==h.CONNECTING?i(E):x.push(E)},finishSend:function(){h&&h.readyState!==h.CONNECTING?i(s.FINISH_SEND):x.push(s.FINISH_SEND)},start:function(E){(h=new WebSocket(l,["grpc-websockets"])).binaryType="arraybuffer",h.onopen=function(){var y;C.debug&&p.debug("websocketRequest.onopen"),h.send((y="",E.forEach(function(P,u){y+=P+": "+u.join(", ")+`\r
|
|
4
4
|
`}),A.encodeASCII(y))),x.forEach(function(P){i(P)})},h.onclose=function(y){C.debug&&p.debug("websocketRequest.onclose",y),C.onEnd()},h.onerror=function(y){C.debug&&p.debug("websocketRequest.onerror",y)},h.onmessage=function(y){C.onChunk(new Uint8Array(y.data))}},cancel:function(){C.debug&&p.debug("websocket.abort"),h.close()}}}(_)}}},35:function(f,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.unary=void 0;var s=n(65),p=n(934);t.unary=function(A,S){if(A.responseStream)throw new Error(".unary cannot be used with server-streaming methods. Use .invoke or .client instead.");if(A.requestStream)throw new Error(".unary cannot be used with client-streaming methods. Use .client instead.");var _=null,C=null,h=p.client(A,{host:S.host,transport:S.transport,debug:S.debug});return h.onHeaders(function(l){_=l}),h.onMessage(function(l){C=l}),h.onEnd(function(l,x,i){S.onEnd({status:l,statusMessage:x,headers:_||new s.Metadata,message:C,trailers:i})}),h.start(S.metadata),h.send(S.request),h.finishSend(),{close:function(){h.close()}}}},882:function(f,t){Object.defineProperty(t,"__esModule",{value:!0}),t.frameRequest=void 0,t.frameRequest=function(n){var s=n.serializeBinary(),p=new ArrayBuffer(s.byteLength+5);return new DataView(p,1,4).setUint32(0,s.length,!1),new Uint8Array(p,5).set(s),new Uint8Array(p)}}},d={},function f(t){if(d[t])return d[t].exports;var n=d[t]={exports:{}};return c[t].call(n.exports,n,n.exports,f),n.exports}(607);var c,d})})(lb);var A9=lb.exports,_f=G&&G.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const Ci=_f(x8),wi=_f(vf),Bi=_f(Cf),Za=wi.default.Buffer;function Db(e){return e=Ii(e),(0,Bi.default)("keccak256").update(e).digest()}function Ii(e){if(!Za.isBuffer(e))if(Array.isArray(e))e=Za.from(e);else if(typeof e=="string")Si(e)?e=Za.from(hb(_i(e)),"hex"):e=Za.from(e);else if(typeof e=="number")e=Ni(e);else if(e==null)e=Za.allocUnsafe(0);else if(Ci.default.isBN(e))e=e.toArrayLike(Za);else if(e.toArray)e=Za.from(e.toArray());else throw new Error("invalid type");return e}function Si(e,a){return!(typeof e!="string"||!e.match(/^0x[0-9A-Fa-f]*$/)||a&&e.length!==2+2*a)}function hb(e){if(typeof e!="string")throw new Error(`while padding to even, value must be string, is currently ${typeof e}, while padToEven.`);return e.length%2&&(e=`0${e}`),e}function _i(e){return typeof e!="string"?e:Ti(e)?e.slice(2):e}function Ti(e){if(typeof e!="string")throw new Error("value must be type 'string', is currently type "+typeof e+", while checking isHexPrefixed.");return e.slice(0,2)==="0x"}function Ni(e){const a=Pi(e);return Za.from(hb(a.slice(2)),"hex")}function Pi(e){return`0x${e.toString(16)}`}typeof window<"u"&&(window.keccak256=Db);var Mi=Db;const Oi=bb(Mi);var ki={},f1={},F9={},y9={},pb={},g9={};Object.defineProperty(g9,"__esModule",{value:!0});var mb=ub();function Ui(e){return new Promise(function(a,c){mb(e,function(d,f){if(d){c(d);return}a(f)})})}g9.getRandomBytes=Ui;function Ri(e){return mb(e)}g9.getRandomBytesSync=Ri;(function(e){var a=G&&G.__awaiter||function(A,S,_,C){function h(l){return l instanceof _?l:new _(function(x){x(l)})}return new(_||(_=Promise))(function(l,x){function i(P){try{y(C.next(P))}catch(u){x(u)}}function E(P){try{y(C.throw(P))}catch(u){x(u)}}function y(P){P.done?l(P.value):h(P.value).then(i,E)}y((C=C.apply(A,S||[])).next())})},c=G&&G.__generator||function(A,S){var _={label:0,sent:function(){if(l[0]&1)throw l[1];return l[1]},trys:[],ops:[]},C,h,l,x;return x={next:i(0),throw:i(1),return:i(2)},typeof Symbol=="function"&&(x[Symbol.iterator]=function(){return this}),x;function i(y){return function(P){return E([y,P])}}function E(y){if(C)throw new TypeError("Generator is already executing.");for(;_;)try{if(C=1,h&&(l=y[0]&2?h.return:y[0]?h.throw||((l=h.return)&&l.call(h),0):h.next)&&!(l=l.call(h,y[1])).done)return l;switch(h=0,l&&(y=[y[0]&2,l.value]),y[0]){case 0:case 1:l=y;break;case 4:return _.label++,{value:y[1],done:!1};case 5:_.label++,h=y[1],y=[0];continue;case 7:y=_.ops.pop(),_.trys.pop();continue;default:if(l=_.trys,!(l=l.length>0&&l[l.length-1])&&(y[0]===6||y[0]===2)){_=0;continue}if(y[0]===3&&(!l||y[1]>l[0]&&y[1]<l[3])){_.label=y[1];break}if(y[0]===6&&_.label<l[1]){_.label=l[1],l=y;break}if(l&&_.label<l[2]){_.label=l[2],_.ops.push(y);break}l[2]&&_.ops.pop(),_.trys.pop();continue}y=S.call(A,_)}catch(P){y=[6,P],h=0}finally{C=l=0}if(y[0]&5)throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}};function d(A){for(var S in A)e.hasOwnProperty(S)||(e[S]=A[S])}Object.defineProperty(e,"__esModule",{value:!0});var f=a9,t=g9,n=32;function s(){return a(this,void 0,void 0,function(){var A;return c(this,function(S){switch(S.label){case 0:return[4,t.getRandomBytes(n)];case 1:return A=S.sent(),f.privateKeyVerify(A)?[2,A]:[3,0];case 2:return[2]}})})}e.createPrivateKey=s;function p(){for(;;){var A=t.getRandomBytesSync(n);if(f.privateKeyVerify(A))return A}}e.createPrivateKeySync=p,d(a9)})(pb);var A6={},Tf={exports:{}};Tf.exports;(function(e){(function(a,c){function d(v,b){if(!v)throw new Error(b||"Assertion failed")}function f(v,b){v.super_=b;var o=function(){};o.prototype=b.prototype,v.prototype=new o,v.prototype.constructor=v}function t(v,b,o){if(t.isBN(v))return v;this.negative=0,this.words=null,this.length=0,this.red=null,v!==null&&((b==="le"||b==="be")&&(o=b,b=10),this._init(v||0,b||10,o||"be"))}typeof a=="object"?a.exports=t:c.BN=t,t.BN=t,t.wordSize=26;var n;try{typeof window<"u"&&typeof window.Buffer<"u"?n=window.Buffer:n=vf.Buffer}catch{}t.isBN=function(b){return b instanceof t?!0:b!==null&&typeof b=="object"&&b.constructor.wordSize===t.wordSize&&Array.isArray(b.words)},t.max=function(b,o){return b.cmp(o)>0?b:o},t.min=function(b,o){return b.cmp(o)<0?b:o},t.prototype._init=function(b,o,m){if(typeof b=="number")return this._initNumber(b,o,m);if(typeof b=="object")return this._initArray(b,o,m);o==="hex"&&(o=16),d(o===(o|0)&&o>=2&&o<=36),b=b.toString().replace(/\s+/g,"");var F=0;b[0]==="-"&&(F++,this.negative=1),F<b.length&&(o===16?this._parseHex(b,F,m):(this._parseBase(b,o,F),m==="le"&&this._initArray(this.toArray(),o,m)))},t.prototype._initNumber=function(b,o,m){b<0&&(this.negative=1,b=-b),b<67108864?(this.words=[b&67108863],this.length=1):b<4503599627370496?(this.words=[b&67108863,b/67108864&67108863],this.length=2):(d(b<9007199254740992),this.words=[b&67108863,b/67108864&67108863,1],this.length=3),m==="le"&&this._initArray(this.toArray(),o,m)},t.prototype._initArray=function(b,o,m){if(d(typeof b.length=="number"),b.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(b.length/3),this.words=new Array(this.length);for(var F=0;F<this.length;F++)this.words[F]=0;var I,M,k=0;if(m==="be")for(F=b.length-1,I=0;F>=0;F-=3)M=b[F]|b[F-1]<<8|b[F-2]<<16,this.words[I]|=M<<k&67108863,this.words[I+1]=M>>>26-k&67108863,k+=24,k>=26&&(k-=26,I++);else if(m==="le")for(F=0,I=0;F<b.length;F+=3)M=b[F]|b[F+1]<<8|b[F+2]<<16,this.words[I]|=M<<k&67108863,this.words[I+1]=M>>>26-k&67108863,k+=24,k>=26&&(k-=26,I++);return this.strip()};function s(v,b){var o=v.charCodeAt(b);return o>=65&&o<=70?o-55:o>=97&&o<=102?o-87:o-48&15}function p(v,b,o){var m=s(v,o);return o-1>=b&&(m|=s(v,o-1)<<4),m}t.prototype._parseHex=function(b,o,m){this.length=Math.ceil((b.length-o)/6),this.words=new Array(this.length);for(var F=0;F<this.length;F++)this.words[F]=0;var I=0,M=0,k;if(m==="be")for(F=b.length-1;F>=o;F-=2)k=p(b,o,F)<<I,this.words[M]|=k&67108863,I>=18?(I-=18,M+=1,this.words[M]|=k>>>26):I+=8;else{var w=b.length-o;for(F=w%2===0?o+1:o;F<b.length;F+=2)k=p(b,o,F)<<I,this.words[M]|=k&67108863,I>=18?(I-=18,M+=1,this.words[M]|=k>>>26):I+=8}this.strip()};function A(v,b,o,m){for(var F=0,I=Math.min(v.length,o),M=b;M<I;M++){var k=v.charCodeAt(M)-48;F*=m,k>=49?F+=k-49+10:k>=17?F+=k-17+10:F+=k}return F}t.prototype._parseBase=function(b,o,m){this.words=[0],this.length=1;for(var F=0,I=1;I<=67108863;I*=o)F++;F--,I=I/o|0;for(var M=b.length-m,k=M%F,w=Math.min(M,M-k)+m,r=0,B=m;B<w;B+=F)r=A(b,B,B+F,o),this.imuln(I),this.words[0]+r<67108864?this.words[0]+=r:this._iaddn(r);if(k!==0){var W=1;for(r=A(b,B,b.length,o),B=0;B<k;B++)W*=o;this.imuln(W),this.words[0]+r<67108864?this.words[0]+=r:this._iaddn(r)}this.strip()},t.prototype.copy=function(b){b.words=new Array(this.length);for(var o=0;o<this.length;o++)b.words[o]=this.words[o];b.length=this.length,b.negative=this.negative,b.red=this.red},t.prototype.clone=function(){var b=new t(null);return this.copy(b),b},t.prototype._expand=function(b){for(;this.length<b;)this.words[this.length++]=0;return this},t.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},t.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},t.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var S=["","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"],_=[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];t.prototype.toString=function(b,o){b=b||10,o=o|0||1;var m;if(b===16||b==="hex"){m="";for(var F=0,I=0,M=0;M<this.length;M++){var k=this.words[M],w=((k<<F|I)&16777215).toString(16);I=k>>>24-F&16777215,I!==0||M!==this.length-1?m=S[6-w.length]+w+m:m=w+m,F+=2,F>=26&&(F-=26,M--)}for(I!==0&&(m=I.toString(16)+m);m.length%o!==0;)m="0"+m;return this.negative!==0&&(m="-"+m),m}if(b===(b|0)&&b>=2&&b<=36){var r=_[b],B=C[b];m="";var W=this.clone();for(W.negative=0;!W.isZero();){var K=W.modn(B).toString(b);W=W.idivn(B),W.isZero()?m=K+m:m=S[r-K.length]+K+m}for(this.isZero()&&(m="0"+m);m.length%o!==0;)m="0"+m;return this.negative!==0&&(m="-"+m),m}d(!1,"Base should be between 2 and 36")},t.prototype.toNumber=function(){var b=this.words[0];return this.length===2?b+=this.words[1]*67108864:this.length===3&&this.words[2]===1?b+=4503599627370496+this.words[1]*67108864:this.length>2&&d(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-b:b},t.prototype.toJSON=function(){return this.toString(16)},t.prototype.toBuffer=function(b,o){return d(typeof n<"u"),this.toArrayLike(n,b,o)},t.prototype.toArray=function(b,o){return this.toArrayLike(Array,b,o)},t.prototype.toArrayLike=function(b,o,m){var F=this.byteLength(),I=m||Math.max(1,F);d(F<=I,"byte array longer than desired length"),d(I>0,"Requested array length <= 0"),this.strip();var M=o==="le",k=new b(I),w,r,B=this.clone();if(M){for(r=0;!B.isZero();r++)w=B.andln(255),B.iushrn(8),k[r]=w;for(;r<I;r++)k[r]=0}else{for(r=0;r<I-F;r++)k[r]=0;for(r=0;!B.isZero();r++)w=B.andln(255),B.iushrn(8),k[I-r-1]=w}return k},Math.clz32?t.prototype._countBits=function(b){return 32-Math.clz32(b)}:t.prototype._countBits=function(b){var o=b,m=0;return o>=4096&&(m+=13,o>>>=13),o>=64&&(m+=7,o>>>=7),o>=8&&(m+=4,o>>>=4),o>=2&&(m+=2,o>>>=2),m+o},t.prototype._zeroBits=function(b){if(b===0)return 26;var o=b,m=0;return o&8191||(m+=13,o>>>=13),o&127||(m+=7,o>>>=7),o&15||(m+=4,o>>>=4),o&3||(m+=2,o>>>=2),o&1||m++,m},t.prototype.bitLength=function(){var b=this.words[this.length-1],o=this._countBits(b);return(this.length-1)*26+o};function h(v){for(var b=new Array(v.bitLength()),o=0;o<b.length;o++){var m=o/26|0,F=o%26;b[o]=(v.words[m]&1<<F)>>>F}return b}t.prototype.zeroBits=function(){if(this.isZero())return 0;for(var b=0,o=0;o<this.length;o++){var m=this._zeroBits(this.words[o]);if(b+=m,m!==26)break}return b},t.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},t.prototype.toTwos=function(b){return this.negative!==0?this.abs().inotn(b).iaddn(1):this.clone()},t.prototype.fromTwos=function(b){return this.testn(b-1)?this.notn(b).iaddn(1).ineg():this.clone()},t.prototype.isNeg=function(){return this.negative!==0},t.prototype.neg=function(){return this.clone().ineg()},t.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},t.prototype.iuor=function(b){for(;this.length<b.length;)this.words[this.length++]=0;for(var o=0;o<b.length;o++)this.words[o]=this.words[o]|b.words[o];return this.strip()},t.prototype.ior=function(b){return d((this.negative|b.negative)===0),this.iuor(b)},t.prototype.or=function(b){return this.length>b.length?this.clone().ior(b):b.clone().ior(this)},t.prototype.uor=function(b){return this.length>b.length?this.clone().iuor(b):b.clone().iuor(this)},t.prototype.iuand=function(b){var o;this.length>b.length?o=b:o=this;for(var m=0;m<o.length;m++)this.words[m]=this.words[m]&b.words[m];return this.length=o.length,this.strip()},t.prototype.iand=function(b){return d((this.negative|b.negative)===0),this.iuand(b)},t.prototype.and=function(b){return this.length>b.length?this.clone().iand(b):b.clone().iand(this)},t.prototype.uand=function(b){return this.length>b.length?this.clone().iuand(b):b.clone().iuand(this)},t.prototype.iuxor=function(b){var o,m;this.length>b.length?(o=this,m=b):(o=b,m=this);for(var F=0;F<m.length;F++)this.words[F]=o.words[F]^m.words[F];if(this!==o)for(;F<o.length;F++)this.words[F]=o.words[F];return this.length=o.length,this.strip()},t.prototype.ixor=function(b){return d((this.negative|b.negative)===0),this.iuxor(b)},t.prototype.xor=function(b){return this.length>b.length?this.clone().ixor(b):b.clone().ixor(this)},t.prototype.uxor=function(b){return this.length>b.length?this.clone().iuxor(b):b.clone().iuxor(this)},t.prototype.inotn=function(b){d(typeof b=="number"&&b>=0);var o=Math.ceil(b/26)|0,m=b%26;this._expand(o),m>0&&o--;for(var F=0;F<o;F++)this.words[F]=~this.words[F]&67108863;return m>0&&(this.words[F]=~this.words[F]&67108863>>26-m),this.strip()},t.prototype.notn=function(b){return this.clone().inotn(b)},t.prototype.setn=function(b,o){d(typeof b=="number"&&b>=0);var m=b/26|0,F=b%26;return this._expand(m+1),o?this.words[m]=this.words[m]|1<<F:this.words[m]=this.words[m]&~(1<<F),this.strip()},t.prototype.iadd=function(b){var o;if(this.negative!==0&&b.negative===0)return this.negative=0,o=this.isub(b),this.negative^=1,this._normSign();if(this.negative===0&&b.negative!==0)return b.negative=0,o=this.isub(b),b.negative=1,o._normSign();var m,F;this.length>b.length?(m=this,F=b):(m=b,F=this);for(var I=0,M=0;M<F.length;M++)o=(m.words[M]|0)+(F.words[M]|0)+I,this.words[M]=o&67108863,I=o>>>26;for(;I!==0&&M<m.length;M++)o=(m.words[M]|0)+I,this.words[M]=o&67108863,I=o>>>26;if(this.length=m.length,I!==0)this.words[this.length]=I,this.length++;else if(m!==this)for(;M<m.length;M++)this.words[M]=m.words[M];return this},t.prototype.add=function(b){var o;return b.negative!==0&&this.negative===0?(b.negative=0,o=this.sub(b),b.negative^=1,o):b.negative===0&&this.negative!==0?(this.negative=0,o=b.sub(this),this.negative=1,o):this.length>b.length?this.clone().iadd(b):b.clone().iadd(this)},t.prototype.isub=function(b){if(b.negative!==0){b.negative=0;var o=this.iadd(b);return b.negative=1,o._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(b),this.negative=1,this._normSign();var m=this.cmp(b);if(m===0)return this.negative=0,this.length=1,this.words[0]=0,this;var F,I;m>0?(F=this,I=b):(F=b,I=this);for(var M=0,k=0;k<I.length;k++)o=(F.words[k]|0)-(I.words[k]|0)+M,M=o>>26,this.words[k]=o&67108863;for(;M!==0&&k<F.length;k++)o=(F.words[k]|0)+M,M=o>>26,this.words[k]=o&67108863;if(M===0&&k<F.length&&F!==this)for(;k<F.length;k++)this.words[k]=F.words[k];return this.length=Math.max(this.length,k),F!==this&&(this.negative=1),this.strip()},t.prototype.sub=function(b){return this.clone().isub(b)};function l(v,b,o){o.negative=b.negative^v.negative;var m=v.length+b.length|0;o.length=m,m=m-1|0;var F=v.words[0]|0,I=b.words[0]|0,M=F*I,k=M&67108863,w=M/67108864|0;o.words[0]=k;for(var r=1;r<m;r++){for(var B=w>>>26,W=w&67108863,K=Math.min(r,b.length-1),V=Math.max(0,r-v.length+1);V<=K;V++){var O=r-V|0;F=v.words[O]|0,I=b.words[V]|0,M=F*I+W,B+=M/67108864|0,W=M&67108863}o.words[r]=W|0,w=B|0}return w!==0?o.words[r]=w|0:o.length--,o.strip()}var x=function(b,o,m){var F=b.words,I=o.words,M=m.words,k=0,w,r,B,W=F[0]|0,K=W&8191,V=W>>>13,O=F[1]|0,Y=O&8191,Z=O>>>13,i0=F[2]|0,t0=i0&8191,n0=i0>>>13,G0=F[3]|0,u0=G0&8191,d0=G0>>>13,K0=F[4]|0,m0=K0&8191,E0=K0>>>13,Le=F[5]|0,A0=Le&8191,F0=Le>>>13,pe=F[6]|0,X=pe&8191,g0=pe>>>13,L=F[7]|0,z=L&8191,J=L>>>13,f0=F[8]|0,e0=f0&8191,Q=f0>>>13,r0=F[9]|0,a0=r0&8191,b0=r0>>>13,h0=I[0]|0,x0=h0&8191,s0=h0>>>13,Q0=I[1]|0,o0=Q0&8191,l0=Q0>>>13,ge=I[2]|0,p0=ge&8191,y0=ge>>>13,sa=I[3]|0,w0=sa&8191,B0=sa>>>13,la=I[4]|0,I0=la&8191,S0=la>>>13,Da=I[5]|0,_0=Da&8191,T0=Da>>>13,ha=I[6]|0,N0=ha&8191,P0=ha>>>13,pa=I[7]|0,M0=pa&8191,O0=pa>>>13,ma=I[8]|0,k0=ma&8191,U0=ma>>>13,Ea=I[9]|0,R0=Ea&8191,L0=Ea>>>13;m.negative=b.negative^o.negative,m.length=19,w=Math.imul(K,x0),r=Math.imul(K,s0),r=r+Math.imul(V,x0)|0,B=Math.imul(V,s0);var $e=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+($e>>>26)|0,$e&=67108863,w=Math.imul(Y,x0),r=Math.imul(Y,s0),r=r+Math.imul(Z,x0)|0,B=Math.imul(Z,s0),w=w+Math.imul(K,o0)|0,r=r+Math.imul(K,l0)|0,r=r+Math.imul(V,o0)|0,B=B+Math.imul(V,l0)|0;var Ge=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(Ge>>>26)|0,Ge&=67108863,w=Math.imul(t0,x0),r=Math.imul(t0,s0),r=r+Math.imul(n0,x0)|0,B=Math.imul(n0,s0),w=w+Math.imul(Y,o0)|0,r=r+Math.imul(Y,l0)|0,r=r+Math.imul(Z,o0)|0,B=B+Math.imul(Z,l0)|0,w=w+Math.imul(K,p0)|0,r=r+Math.imul(K,y0)|0,r=r+Math.imul(V,p0)|0,B=B+Math.imul(V,y0)|0;var He=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(He>>>26)|0,He&=67108863,w=Math.imul(u0,x0),r=Math.imul(u0,s0),r=r+Math.imul(d0,x0)|0,B=Math.imul(d0,s0),w=w+Math.imul(t0,o0)|0,r=r+Math.imul(t0,l0)|0,r=r+Math.imul(n0,o0)|0,B=B+Math.imul(n0,l0)|0,w=w+Math.imul(Y,p0)|0,r=r+Math.imul(Y,y0)|0,r=r+Math.imul(Z,p0)|0,B=B+Math.imul(Z,y0)|0,w=w+Math.imul(K,w0)|0,r=r+Math.imul(K,B0)|0,r=r+Math.imul(V,w0)|0,B=B+Math.imul(V,B0)|0;var je=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(je>>>26)|0,je&=67108863,w=Math.imul(m0,x0),r=Math.imul(m0,s0),r=r+Math.imul(E0,x0)|0,B=Math.imul(E0,s0),w=w+Math.imul(u0,o0)|0,r=r+Math.imul(u0,l0)|0,r=r+Math.imul(d0,o0)|0,B=B+Math.imul(d0,l0)|0,w=w+Math.imul(t0,p0)|0,r=r+Math.imul(t0,y0)|0,r=r+Math.imul(n0,p0)|0,B=B+Math.imul(n0,y0)|0,w=w+Math.imul(Y,w0)|0,r=r+Math.imul(Y,B0)|0,r=r+Math.imul(Z,w0)|0,B=B+Math.imul(Z,B0)|0,w=w+Math.imul(K,I0)|0,r=r+Math.imul(K,S0)|0,r=r+Math.imul(V,I0)|0,B=B+Math.imul(V,S0)|0;var ze=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(ze>>>26)|0,ze&=67108863,w=Math.imul(A0,x0),r=Math.imul(A0,s0),r=r+Math.imul(F0,x0)|0,B=Math.imul(F0,s0),w=w+Math.imul(m0,o0)|0,r=r+Math.imul(m0,l0)|0,r=r+Math.imul(E0,o0)|0,B=B+Math.imul(E0,l0)|0,w=w+Math.imul(u0,p0)|0,r=r+Math.imul(u0,y0)|0,r=r+Math.imul(d0,p0)|0,B=B+Math.imul(d0,y0)|0,w=w+Math.imul(t0,w0)|0,r=r+Math.imul(t0,B0)|0,r=r+Math.imul(n0,w0)|0,B=B+Math.imul(n0,B0)|0,w=w+Math.imul(Y,I0)|0,r=r+Math.imul(Y,S0)|0,r=r+Math.imul(Z,I0)|0,B=B+Math.imul(Z,S0)|0,w=w+Math.imul(K,_0)|0,r=r+Math.imul(K,T0)|0,r=r+Math.imul(V,_0)|0,B=B+Math.imul(V,T0)|0;var Je=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(Je>>>26)|0,Je&=67108863,w=Math.imul(X,x0),r=Math.imul(X,s0),r=r+Math.imul(g0,x0)|0,B=Math.imul(g0,s0),w=w+Math.imul(A0,o0)|0,r=r+Math.imul(A0,l0)|0,r=r+Math.imul(F0,o0)|0,B=B+Math.imul(F0,l0)|0,w=w+Math.imul(m0,p0)|0,r=r+Math.imul(m0,y0)|0,r=r+Math.imul(E0,p0)|0,B=B+Math.imul(E0,y0)|0,w=w+Math.imul(u0,w0)|0,r=r+Math.imul(u0,B0)|0,r=r+Math.imul(d0,w0)|0,B=B+Math.imul(d0,B0)|0,w=w+Math.imul(t0,I0)|0,r=r+Math.imul(t0,S0)|0,r=r+Math.imul(n0,I0)|0,B=B+Math.imul(n0,S0)|0,w=w+Math.imul(Y,_0)|0,r=r+Math.imul(Y,T0)|0,r=r+Math.imul(Z,_0)|0,B=B+Math.imul(Z,T0)|0,w=w+Math.imul(K,N0)|0,r=r+Math.imul(K,P0)|0,r=r+Math.imul(V,N0)|0,B=B+Math.imul(V,P0)|0;var We=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(We>>>26)|0,We&=67108863,w=Math.imul(z,x0),r=Math.imul(z,s0),r=r+Math.imul(J,x0)|0,B=Math.imul(J,s0),w=w+Math.imul(X,o0)|0,r=r+Math.imul(X,l0)|0,r=r+Math.imul(g0,o0)|0,B=B+Math.imul(g0,l0)|0,w=w+Math.imul(A0,p0)|0,r=r+Math.imul(A0,y0)|0,r=r+Math.imul(F0,p0)|0,B=B+Math.imul(F0,y0)|0,w=w+Math.imul(m0,w0)|0,r=r+Math.imul(m0,B0)|0,r=r+Math.imul(E0,w0)|0,B=B+Math.imul(E0,B0)|0,w=w+Math.imul(u0,I0)|0,r=r+Math.imul(u0,S0)|0,r=r+Math.imul(d0,I0)|0,B=B+Math.imul(d0,S0)|0,w=w+Math.imul(t0,_0)|0,r=r+Math.imul(t0,T0)|0,r=r+Math.imul(n0,_0)|0,B=B+Math.imul(n0,T0)|0,w=w+Math.imul(Y,N0)|0,r=r+Math.imul(Y,P0)|0,r=r+Math.imul(Z,N0)|0,B=B+Math.imul(Z,P0)|0,w=w+Math.imul(K,M0)|0,r=r+Math.imul(K,O0)|0,r=r+Math.imul(V,M0)|0,B=B+Math.imul(V,O0)|0;var F1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(F1>>>26)|0,F1&=67108863,w=Math.imul(e0,x0),r=Math.imul(e0,s0),r=r+Math.imul(Q,x0)|0,B=Math.imul(Q,s0),w=w+Math.imul(z,o0)|0,r=r+Math.imul(z,l0)|0,r=r+Math.imul(J,o0)|0,B=B+Math.imul(J,l0)|0,w=w+Math.imul(X,p0)|0,r=r+Math.imul(X,y0)|0,r=r+Math.imul(g0,p0)|0,B=B+Math.imul(g0,y0)|0,w=w+Math.imul(A0,w0)|0,r=r+Math.imul(A0,B0)|0,r=r+Math.imul(F0,w0)|0,B=B+Math.imul(F0,B0)|0,w=w+Math.imul(m0,I0)|0,r=r+Math.imul(m0,S0)|0,r=r+Math.imul(E0,I0)|0,B=B+Math.imul(E0,S0)|0,w=w+Math.imul(u0,_0)|0,r=r+Math.imul(u0,T0)|0,r=r+Math.imul(d0,_0)|0,B=B+Math.imul(d0,T0)|0,w=w+Math.imul(t0,N0)|0,r=r+Math.imul(t0,P0)|0,r=r+Math.imul(n0,N0)|0,B=B+Math.imul(n0,P0)|0,w=w+Math.imul(Y,M0)|0,r=r+Math.imul(Y,O0)|0,r=r+Math.imul(Z,M0)|0,B=B+Math.imul(Z,O0)|0,w=w+Math.imul(K,k0)|0,r=r+Math.imul(K,U0)|0,r=r+Math.imul(V,k0)|0,B=B+Math.imul(V,U0)|0;var y1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(y1>>>26)|0,y1&=67108863,w=Math.imul(a0,x0),r=Math.imul(a0,s0),r=r+Math.imul(b0,x0)|0,B=Math.imul(b0,s0),w=w+Math.imul(e0,o0)|0,r=r+Math.imul(e0,l0)|0,r=r+Math.imul(Q,o0)|0,B=B+Math.imul(Q,l0)|0,w=w+Math.imul(z,p0)|0,r=r+Math.imul(z,y0)|0,r=r+Math.imul(J,p0)|0,B=B+Math.imul(J,y0)|0,w=w+Math.imul(X,w0)|0,r=r+Math.imul(X,B0)|0,r=r+Math.imul(g0,w0)|0,B=B+Math.imul(g0,B0)|0,w=w+Math.imul(A0,I0)|0,r=r+Math.imul(A0,S0)|0,r=r+Math.imul(F0,I0)|0,B=B+Math.imul(F0,S0)|0,w=w+Math.imul(m0,_0)|0,r=r+Math.imul(m0,T0)|0,r=r+Math.imul(E0,_0)|0,B=B+Math.imul(E0,T0)|0,w=w+Math.imul(u0,N0)|0,r=r+Math.imul(u0,P0)|0,r=r+Math.imul(d0,N0)|0,B=B+Math.imul(d0,P0)|0,w=w+Math.imul(t0,M0)|0,r=r+Math.imul(t0,O0)|0,r=r+Math.imul(n0,M0)|0,B=B+Math.imul(n0,O0)|0,w=w+Math.imul(Y,k0)|0,r=r+Math.imul(Y,U0)|0,r=r+Math.imul(Z,k0)|0,B=B+Math.imul(Z,U0)|0,w=w+Math.imul(K,R0)|0,r=r+Math.imul(K,L0)|0,r=r+Math.imul(V,R0)|0,B=B+Math.imul(V,L0)|0;var g1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(g1>>>26)|0,g1&=67108863,w=Math.imul(a0,o0),r=Math.imul(a0,l0),r=r+Math.imul(b0,o0)|0,B=Math.imul(b0,l0),w=w+Math.imul(e0,p0)|0,r=r+Math.imul(e0,y0)|0,r=r+Math.imul(Q,p0)|0,B=B+Math.imul(Q,y0)|0,w=w+Math.imul(z,w0)|0,r=r+Math.imul(z,B0)|0,r=r+Math.imul(J,w0)|0,B=B+Math.imul(J,B0)|0,w=w+Math.imul(X,I0)|0,r=r+Math.imul(X,S0)|0,r=r+Math.imul(g0,I0)|0,B=B+Math.imul(g0,S0)|0,w=w+Math.imul(A0,_0)|0,r=r+Math.imul(A0,T0)|0,r=r+Math.imul(F0,_0)|0,B=B+Math.imul(F0,T0)|0,w=w+Math.imul(m0,N0)|0,r=r+Math.imul(m0,P0)|0,r=r+Math.imul(E0,N0)|0,B=B+Math.imul(E0,P0)|0,w=w+Math.imul(u0,M0)|0,r=r+Math.imul(u0,O0)|0,r=r+Math.imul(d0,M0)|0,B=B+Math.imul(d0,O0)|0,w=w+Math.imul(t0,k0)|0,r=r+Math.imul(t0,U0)|0,r=r+Math.imul(n0,k0)|0,B=B+Math.imul(n0,U0)|0,w=w+Math.imul(Y,R0)|0,r=r+Math.imul(Y,L0)|0,r=r+Math.imul(Z,R0)|0,B=B+Math.imul(Z,L0)|0;var v1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(v1>>>26)|0,v1&=67108863,w=Math.imul(a0,p0),r=Math.imul(a0,y0),r=r+Math.imul(b0,p0)|0,B=Math.imul(b0,y0),w=w+Math.imul(e0,w0)|0,r=r+Math.imul(e0,B0)|0,r=r+Math.imul(Q,w0)|0,B=B+Math.imul(Q,B0)|0,w=w+Math.imul(z,I0)|0,r=r+Math.imul(z,S0)|0,r=r+Math.imul(J,I0)|0,B=B+Math.imul(J,S0)|0,w=w+Math.imul(X,_0)|0,r=r+Math.imul(X,T0)|0,r=r+Math.imul(g0,_0)|0,B=B+Math.imul(g0,T0)|0,w=w+Math.imul(A0,N0)|0,r=r+Math.imul(A0,P0)|0,r=r+Math.imul(F0,N0)|0,B=B+Math.imul(F0,P0)|0,w=w+Math.imul(m0,M0)|0,r=r+Math.imul(m0,O0)|0,r=r+Math.imul(E0,M0)|0,B=B+Math.imul(E0,O0)|0,w=w+Math.imul(u0,k0)|0,r=r+Math.imul(u0,U0)|0,r=r+Math.imul(d0,k0)|0,B=B+Math.imul(d0,U0)|0,w=w+Math.imul(t0,R0)|0,r=r+Math.imul(t0,L0)|0,r=r+Math.imul(n0,R0)|0,B=B+Math.imul(n0,L0)|0;var C1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(C1>>>26)|0,C1&=67108863,w=Math.imul(a0,w0),r=Math.imul(a0,B0),r=r+Math.imul(b0,w0)|0,B=Math.imul(b0,B0),w=w+Math.imul(e0,I0)|0,r=r+Math.imul(e0,S0)|0,r=r+Math.imul(Q,I0)|0,B=B+Math.imul(Q,S0)|0,w=w+Math.imul(z,_0)|0,r=r+Math.imul(z,T0)|0,r=r+Math.imul(J,_0)|0,B=B+Math.imul(J,T0)|0,w=w+Math.imul(X,N0)|0,r=r+Math.imul(X,P0)|0,r=r+Math.imul(g0,N0)|0,B=B+Math.imul(g0,P0)|0,w=w+Math.imul(A0,M0)|0,r=r+Math.imul(A0,O0)|0,r=r+Math.imul(F0,M0)|0,B=B+Math.imul(F0,O0)|0,w=w+Math.imul(m0,k0)|0,r=r+Math.imul(m0,U0)|0,r=r+Math.imul(E0,k0)|0,B=B+Math.imul(E0,U0)|0,w=w+Math.imul(u0,R0)|0,r=r+Math.imul(u0,L0)|0,r=r+Math.imul(d0,R0)|0,B=B+Math.imul(d0,L0)|0;var w1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(w1>>>26)|0,w1&=67108863,w=Math.imul(a0,I0),r=Math.imul(a0,S0),r=r+Math.imul(b0,I0)|0,B=Math.imul(b0,S0),w=w+Math.imul(e0,_0)|0,r=r+Math.imul(e0,T0)|0,r=r+Math.imul(Q,_0)|0,B=B+Math.imul(Q,T0)|0,w=w+Math.imul(z,N0)|0,r=r+Math.imul(z,P0)|0,r=r+Math.imul(J,N0)|0,B=B+Math.imul(J,P0)|0,w=w+Math.imul(X,M0)|0,r=r+Math.imul(X,O0)|0,r=r+Math.imul(g0,M0)|0,B=B+Math.imul(g0,O0)|0,w=w+Math.imul(A0,k0)|0,r=r+Math.imul(A0,U0)|0,r=r+Math.imul(F0,k0)|0,B=B+Math.imul(F0,U0)|0,w=w+Math.imul(m0,R0)|0,r=r+Math.imul(m0,L0)|0,r=r+Math.imul(E0,R0)|0,B=B+Math.imul(E0,L0)|0;var B1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(B1>>>26)|0,B1&=67108863,w=Math.imul(a0,_0),r=Math.imul(a0,T0),r=r+Math.imul(b0,_0)|0,B=Math.imul(b0,T0),w=w+Math.imul(e0,N0)|0,r=r+Math.imul(e0,P0)|0,r=r+Math.imul(Q,N0)|0,B=B+Math.imul(Q,P0)|0,w=w+Math.imul(z,M0)|0,r=r+Math.imul(z,O0)|0,r=r+Math.imul(J,M0)|0,B=B+Math.imul(J,O0)|0,w=w+Math.imul(X,k0)|0,r=r+Math.imul(X,U0)|0,r=r+Math.imul(g0,k0)|0,B=B+Math.imul(g0,U0)|0,w=w+Math.imul(A0,R0)|0,r=r+Math.imul(A0,L0)|0,r=r+Math.imul(F0,R0)|0,B=B+Math.imul(F0,L0)|0;var I1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(I1>>>26)|0,I1&=67108863,w=Math.imul(a0,N0),r=Math.imul(a0,P0),r=r+Math.imul(b0,N0)|0,B=Math.imul(b0,P0),w=w+Math.imul(e0,M0)|0,r=r+Math.imul(e0,O0)|0,r=r+Math.imul(Q,M0)|0,B=B+Math.imul(Q,O0)|0,w=w+Math.imul(z,k0)|0,r=r+Math.imul(z,U0)|0,r=r+Math.imul(J,k0)|0,B=B+Math.imul(J,U0)|0,w=w+Math.imul(X,R0)|0,r=r+Math.imul(X,L0)|0,r=r+Math.imul(g0,R0)|0,B=B+Math.imul(g0,L0)|0;var S1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(S1>>>26)|0,S1&=67108863,w=Math.imul(a0,M0),r=Math.imul(a0,O0),r=r+Math.imul(b0,M0)|0,B=Math.imul(b0,O0),w=w+Math.imul(e0,k0)|0,r=r+Math.imul(e0,U0)|0,r=r+Math.imul(Q,k0)|0,B=B+Math.imul(Q,U0)|0,w=w+Math.imul(z,R0)|0,r=r+Math.imul(z,L0)|0,r=r+Math.imul(J,R0)|0,B=B+Math.imul(J,L0)|0;var _1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(_1>>>26)|0,_1&=67108863,w=Math.imul(a0,k0),r=Math.imul(a0,U0),r=r+Math.imul(b0,k0)|0,B=Math.imul(b0,U0),w=w+Math.imul(e0,R0)|0,r=r+Math.imul(e0,L0)|0,r=r+Math.imul(Q,R0)|0,B=B+Math.imul(Q,L0)|0;var T1=(k+w|0)+((r&8191)<<13)|0;k=(B+(r>>>13)|0)+(T1>>>26)|0,T1&=67108863,w=Math.imul(a0,R0),r=Math.imul(a0,L0),r=r+Math.imul(b0,R0)|0,B=Math.imul(b0,L0);var N1=(k+w|0)+((r&8191)<<13)|0;return k=(B+(r>>>13)|0)+(N1>>>26)|0,N1&=67108863,M[0]=$e,M[1]=Ge,M[2]=He,M[3]=je,M[4]=ze,M[5]=Je,M[6]=We,M[7]=F1,M[8]=y1,M[9]=g1,M[10]=v1,M[11]=C1,M[12]=w1,M[13]=B1,M[14]=I1,M[15]=S1,M[16]=_1,M[17]=T1,M[18]=N1,k!==0&&(M[19]=k,m.length++),m};Math.imul||(x=l);function i(v,b,o){o.negative=b.negative^v.negative,o.length=v.length+b.length;for(var m=0,F=0,I=0;I<o.length-1;I++){var M=F;F=0;for(var k=m&67108863,w=Math.min(I,b.length-1),r=Math.max(0,I-v.length+1);r<=w;r++){var B=I-r,W=v.words[B]|0,K=b.words[r]|0,V=W*K,O=V&67108863;M=M+(V/67108864|0)|0,O=O+k|0,k=O&67108863,M=M+(O>>>26)|0,F+=M>>>26,M&=67108863}o.words[I]=k,m=M,M=F}return m!==0?o.words[I]=m:o.length--,o.strip()}function E(v,b,o){var m=new y;return m.mulp(v,b,o)}t.prototype.mulTo=function(b,o){var m,F=this.length+b.length;return this.length===10&&b.length===10?m=x(this,b,o):F<63?m=l(this,b,o):F<1024?m=i(this,b,o):m=E(this,b,o),m};function y(v,b){this.x=v,this.y=b}y.prototype.makeRBT=function(b){for(var o=new Array(b),m=t.prototype._countBits(b)-1,F=0;F<b;F++)o[F]=this.revBin(F,m,b);return o},y.prototype.revBin=function(b,o,m){if(b===0||b===m-1)return b;for(var F=0,I=0;I<o;I++)F|=(b&1)<<o-I-1,b>>=1;return F},y.prototype.permute=function(b,o,m,F,I,M){for(var k=0;k<M;k++)F[k]=o[b[k]],I[k]=m[b[k]]},y.prototype.transform=function(b,o,m,F,I,M){this.permute(M,b,o,m,F,I);for(var k=1;k<I;k<<=1)for(var w=k<<1,r=Math.cos(2*Math.PI/w),B=Math.sin(2*Math.PI/w),W=0;W<I;W+=w)for(var K=r,V=B,O=0;O<k;O++){var Y=m[W+O],Z=F[W+O],i0=m[W+O+k],t0=F[W+O+k],n0=K*i0-V*t0;t0=K*t0+V*i0,i0=n0,m[W+O]=Y+i0,F[W+O]=Z+t0,m[W+O+k]=Y-i0,F[W+O+k]=Z-t0,O!==w&&(n0=r*K-B*V,V=r*V+B*K,K=n0)}},y.prototype.guessLen13b=function(b,o){var m=Math.max(o,b)|1,F=m&1,I=0;for(m=m/2|0;m;m=m>>>1)I++;return 1<<I+1+F},y.prototype.conjugate=function(b,o,m){if(!(m<=1))for(var F=0;F<m/2;F++){var I=b[F];b[F]=b[m-F-1],b[m-F-1]=I,I=o[F],o[F]=-o[m-F-1],o[m-F-1]=-I}},y.prototype.normalize13b=function(b,o){for(var m=0,F=0;F<o/2;F++){var I=Math.round(b[2*F+1]/o)*8192+Math.round(b[2*F]/o)+m;b[F]=I&67108863,I<67108864?m=0:m=I/67108864|0}return b},y.prototype.convert13b=function(b,o,m,F){for(var I=0,M=0;M<o;M++)I=I+(b[M]|0),m[2*M]=I&8191,I=I>>>13,m[2*M+1]=I&8191,I=I>>>13;for(M=2*o;M<F;++M)m[M]=0;d(I===0),d((I&-8192)===0)},y.prototype.stub=function(b){for(var o=new Array(b),m=0;m<b;m++)o[m]=0;return o},y.prototype.mulp=function(b,o,m){var F=2*this.guessLen13b(b.length,o.length),I=this.makeRBT(F),M=this.stub(F),k=new Array(F),w=new Array(F),r=new Array(F),B=new Array(F),W=new Array(F),K=new Array(F),V=m.words;V.length=F,this.convert13b(b.words,b.length,k,F),this.convert13b(o.words,o.length,B,F),this.transform(k,M,w,r,F,I),this.transform(B,M,W,K,F,I);for(var O=0;O<F;O++){var Y=w[O]*W[O]-r[O]*K[O];r[O]=w[O]*K[O]+r[O]*W[O],w[O]=Y}return this.conjugate(w,r,F),this.transform(w,r,V,M,F,I),this.conjugate(V,M,F),this.normalize13b(V,F),m.negative=b.negative^o.negative,m.length=b.length+o.length,m.strip()},t.prototype.mul=function(b){var o=new t(null);return o.words=new Array(this.length+b.length),this.mulTo(b,o)},t.prototype.mulf=function(b){var o=new t(null);return o.words=new Array(this.length+b.length),E(this,b,o)},t.prototype.imul=function(b){return this.clone().mulTo(b,this)},t.prototype.imuln=function(b){d(typeof b=="number"),d(b<67108864);for(var o=0,m=0;m<this.length;m++){var F=(this.words[m]|0)*b,I=(F&67108863)+(o&67108863);o>>=26,o+=F/67108864|0,o+=I>>>26,this.words[m]=I&67108863}return o!==0&&(this.words[m]=o,this.length++),this},t.prototype.muln=function(b){return this.clone().imuln(b)},t.prototype.sqr=function(){return this.mul(this)},t.prototype.isqr=function(){return this.imul(this.clone())},t.prototype.pow=function(b){var o=h(b);if(o.length===0)return new t(1);for(var m=this,F=0;F<o.length&&o[F]===0;F++,m=m.sqr());if(++F<o.length)for(var I=m.sqr();F<o.length;F++,I=I.sqr())o[F]!==0&&(m=m.mul(I));return m},t.prototype.iushln=function(b){d(typeof b=="number"&&b>=0);var o=b%26,m=(b-o)/26,F=67108863>>>26-o<<26-o,I;if(o!==0){var M=0;for(I=0;I<this.length;I++){var k=this.words[I]&F,w=(this.words[I]|0)-k<<o;this.words[I]=w|M,M=k>>>26-o}M&&(this.words[I]=M,this.length++)}if(m!==0){for(I=this.length-1;I>=0;I--)this.words[I+m]=this.words[I];for(I=0;I<m;I++)this.words[I]=0;this.length+=m}return this.strip()},t.prototype.ishln=function(b){return d(this.negative===0),this.iushln(b)},t.prototype.iushrn=function(b,o,m){d(typeof b=="number"&&b>=0);var F;o?F=(o-o%26)/26:F=0;var I=b%26,M=Math.min((b-I)/26,this.length),k=67108863^67108863>>>I<<I,w=m;if(F-=M,F=Math.max(0,F),w){for(var r=0;r<M;r++)w.words[r]=this.words[r];w.length=M}if(M!==0)if(this.length>M)for(this.length-=M,r=0;r<this.length;r++)this.words[r]=this.words[r+M];else this.words[0]=0,this.length=1;var B=0;for(r=this.length-1;r>=0&&(B!==0||r>=F);r--){var W=this.words[r]|0;this.words[r]=B<<26-I|W>>>I,B=W&k}return w&&B!==0&&(w.words[w.length++]=B),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},t.prototype.ishrn=function(b,o,m){return d(this.negative===0),this.iushrn(b,o,m)},t.prototype.shln=function(b){return this.clone().ishln(b)},t.prototype.ushln=function(b){return this.clone().iushln(b)},t.prototype.shrn=function(b){return this.clone().ishrn(b)},t.prototype.ushrn=function(b){return this.clone().iushrn(b)},t.prototype.testn=function(b){d(typeof b=="number"&&b>=0);var o=b%26,m=(b-o)/26,F=1<<o;if(this.length<=m)return!1;var I=this.words[m];return!!(I&F)},t.prototype.imaskn=function(b){d(typeof b=="number"&&b>=0);var o=b%26,m=(b-o)/26;if(d(this.negative===0,"imaskn works only with positive numbers"),this.length<=m)return this;if(o!==0&&m++,this.length=Math.min(m,this.length),o!==0){var F=67108863^67108863>>>o<<o;this.words[this.length-1]&=F}return this.strip()},t.prototype.maskn=function(b){return this.clone().imaskn(b)},t.prototype.iaddn=function(b){return d(typeof b=="number"),d(b<67108864),b<0?this.isubn(-b):this.negative!==0?this.length===1&&(this.words[0]|0)<b?(this.words[0]=b-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(b),this.negative=1,this):this._iaddn(b)},t.prototype._iaddn=function(b){this.words[0]+=b;for(var o=0;o<this.length&&this.words[o]>=67108864;o++)this.words[o]-=67108864,o===this.length-1?this.words[o+1]=1:this.words[o+1]++;return this.length=Math.max(this.length,o+1),this},t.prototype.isubn=function(b){if(d(typeof b=="number"),d(b<67108864),b<0)return this.iaddn(-b);if(this.negative!==0)return this.negative=0,this.iaddn(b),this.negative=1,this;if(this.words[0]-=b,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var o=0;o<this.length&&this.words[o]<0;o++)this.words[o]+=67108864,this.words[o+1]-=1;return this.strip()},t.prototype.addn=function(b){return this.clone().iaddn(b)},t.prototype.subn=function(b){return this.clone().isubn(b)},t.prototype.iabs=function(){return this.negative=0,this},t.prototype.abs=function(){return this.clone().iabs()},t.prototype._ishlnsubmul=function(b,o,m){var F=b.length+m,I;this._expand(F);var M,k=0;for(I=0;I<b.length;I++){M=(this.words[I+m]|0)+k;var w=(b.words[I]|0)*o;M-=w&67108863,k=(M>>26)-(w/67108864|0),this.words[I+m]=M&67108863}for(;I<this.length-m;I++)M=(this.words[I+m]|0)+k,k=M>>26,this.words[I+m]=M&67108863;if(k===0)return this.strip();for(d(k===-1),k=0,I=0;I<this.length;I++)M=-(this.words[I]|0)+k,k=M>>26,this.words[I]=M&67108863;return this.negative=1,this.strip()},t.prototype._wordDiv=function(b,o){var m=this.length-b.length,F=this.clone(),I=b,M=I.words[I.length-1]|0,k=this._countBits(M);m=26-k,m!==0&&(I=I.ushln(m),F.iushln(m),M=I.words[I.length-1]|0);var w=F.length-I.length,r;if(o!=="mod"){r=new t(null),r.length=w+1,r.words=new Array(r.length);for(var B=0;B<r.length;B++)r.words[B]=0}var W=F.clone()._ishlnsubmul(I,1,w);W.negative===0&&(F=W,r&&(r.words[w]=1));for(var K=w-1;K>=0;K--){var V=(F.words[I.length+K]|0)*67108864+(F.words[I.length+K-1]|0);for(V=Math.min(V/M|0,67108863),F._ishlnsubmul(I,V,K);F.negative!==0;)V--,F.negative=0,F._ishlnsubmul(I,1,K),F.isZero()||(F.negative^=1);r&&(r.words[K]=V)}return r&&r.strip(),F.strip(),o!=="div"&&m!==0&&F.iushrn(m),{div:r||null,mod:F}},t.prototype.divmod=function(b,o,m){if(d(!b.isZero()),this.isZero())return{div:new t(0),mod:new t(0)};var F,I,M;return this.negative!==0&&b.negative===0?(M=this.neg().divmod(b,o),o!=="mod"&&(F=M.div.neg()),o!=="div"&&(I=M.mod.neg(),m&&I.negative!==0&&I.iadd(b)),{div:F,mod:I}):this.negative===0&&b.negative!==0?(M=this.divmod(b.neg(),o),o!=="mod"&&(F=M.div.neg()),{div:F,mod:M.mod}):this.negative&b.negative?(M=this.neg().divmod(b.neg(),o),o!=="div"&&(I=M.mod.neg(),m&&I.negative!==0&&I.isub(b)),{div:M.div,mod:I}):b.length>this.length||this.cmp(b)<0?{div:new t(0),mod:this}:b.length===1?o==="div"?{div:this.divn(b.words[0]),mod:null}:o==="mod"?{div:null,mod:new t(this.modn(b.words[0]))}:{div:this.divn(b.words[0]),mod:new t(this.modn(b.words[0]))}:this._wordDiv(b,o)},t.prototype.div=function(b){return this.divmod(b,"div",!1).div},t.prototype.mod=function(b){return this.divmod(b,"mod",!1).mod},t.prototype.umod=function(b){return this.divmod(b,"mod",!0).mod},t.prototype.divRound=function(b){var o=this.divmod(b);if(o.mod.isZero())return o.div;var m=o.div.negative!==0?o.mod.isub(b):o.mod,F=b.ushrn(1),I=b.andln(1),M=m.cmp(F);return M<0||I===1&&M===0?o.div:o.div.negative!==0?o.div.isubn(1):o.div.iaddn(1)},t.prototype.modn=function(b){d(b<=67108863);for(var o=(1<<26)%b,m=0,F=this.length-1;F>=0;F--)m=(o*m+(this.words[F]|0))%b;return m},t.prototype.idivn=function(b){d(b<=67108863);for(var o=0,m=this.length-1;m>=0;m--){var F=(this.words[m]|0)+o*67108864;this.words[m]=F/b|0,o=F%b}return this.strip()},t.prototype.divn=function(b){return this.clone().idivn(b)},t.prototype.egcd=function(b){d(b.negative===0),d(!b.isZero());var o=this,m=b.clone();o.negative!==0?o=o.umod(b):o=o.clone();for(var F=new t(1),I=new t(0),M=new t(0),k=new t(1),w=0;o.isEven()&&m.isEven();)o.iushrn(1),m.iushrn(1),++w;for(var r=m.clone(),B=o.clone();!o.isZero();){for(var W=0,K=1;!(o.words[0]&K)&&W<26;++W,K<<=1);if(W>0)for(o.iushrn(W);W-- >0;)(F.isOdd()||I.isOdd())&&(F.iadd(r),I.isub(B)),F.iushrn(1),I.iushrn(1);for(var V=0,O=1;!(m.words[0]&O)&&V<26;++V,O<<=1);if(V>0)for(m.iushrn(V);V-- >0;)(M.isOdd()||k.isOdd())&&(M.iadd(r),k.isub(B)),M.iushrn(1),k.iushrn(1);o.cmp(m)>=0?(o.isub(m),F.isub(M),I.isub(k)):(m.isub(o),M.isub(F),k.isub(I))}return{a:M,b:k,gcd:m.iushln(w)}},t.prototype._invmp=function(b){d(b.negative===0),d(!b.isZero());var o=this,m=b.clone();o.negative!==0?o=o.umod(b):o=o.clone();for(var F=new t(1),I=new t(0),M=m.clone();o.cmpn(1)>0&&m.cmpn(1)>0;){for(var k=0,w=1;!(o.words[0]&w)&&k<26;++k,w<<=1);if(k>0)for(o.iushrn(k);k-- >0;)F.isOdd()&&F.iadd(M),F.iushrn(1);for(var r=0,B=1;!(m.words[0]&B)&&r<26;++r,B<<=1);if(r>0)for(m.iushrn(r);r-- >0;)I.isOdd()&&I.iadd(M),I.iushrn(1);o.cmp(m)>=0?(o.isub(m),F.isub(I)):(m.isub(o),I.isub(F))}var W;return o.cmpn(1)===0?W=F:W=I,W.cmpn(0)<0&&W.iadd(b),W},t.prototype.gcd=function(b){if(this.isZero())return b.abs();if(b.isZero())return this.abs();var o=this.clone(),m=b.clone();o.negative=0,m.negative=0;for(var F=0;o.isEven()&&m.isEven();F++)o.iushrn(1),m.iushrn(1);do{for(;o.isEven();)o.iushrn(1);for(;m.isEven();)m.iushrn(1);var I=o.cmp(m);if(I<0){var M=o;o=m,m=M}else if(I===0||m.cmpn(1)===0)break;o.isub(m)}while(!0);return m.iushln(F)},t.prototype.invm=function(b){return this.egcd(b).a.umod(b)},t.prototype.isEven=function(){return(this.words[0]&1)===0},t.prototype.isOdd=function(){return(this.words[0]&1)===1},t.prototype.andln=function(b){return this.words[0]&b},t.prototype.bincn=function(b){d(typeof b=="number");var o=b%26,m=(b-o)/26,F=1<<o;if(this.length<=m)return this._expand(m+1),this.words[m]|=F,this;for(var I=F,M=m;I!==0&&M<this.length;M++){var k=this.words[M]|0;k+=I,I=k>>>26,k&=67108863,this.words[M]=k}return I!==0&&(this.words[M]=I,this.length++),this},t.prototype.isZero=function(){return this.length===1&&this.words[0]===0},t.prototype.cmpn=function(b){var o=b<0;if(this.negative!==0&&!o)return-1;if(this.negative===0&&o)return 1;this.strip();var m;if(this.length>1)m=1;else{o&&(b=-b),d(b<=67108863,"Number is too big");var F=this.words[0]|0;m=F===b?0:F<b?-1:1}return this.negative!==0?-m|0:m},t.prototype.cmp=function(b){if(this.negative!==0&&b.negative===0)return-1;if(this.negative===0&&b.negative!==0)return 1;var o=this.ucmp(b);return this.negative!==0?-o|0:o},t.prototype.ucmp=function(b){if(this.length>b.length)return 1;if(this.length<b.length)return-1;for(var o=0,m=this.length-1;m>=0;m--){var F=this.words[m]|0,I=b.words[m]|0;if(F!==I){F<I?o=-1:F>I&&(o=1);break}}return o},t.prototype.gtn=function(b){return this.cmpn(b)===1},t.prototype.gt=function(b){return this.cmp(b)===1},t.prototype.gten=function(b){return this.cmpn(b)>=0},t.prototype.gte=function(b){return this.cmp(b)>=0},t.prototype.ltn=function(b){return this.cmpn(b)===-1},t.prototype.lt=function(b){return this.cmp(b)===-1},t.prototype.lten=function(b){return this.cmpn(b)<=0},t.prototype.lte=function(b){return this.cmp(b)<=0},t.prototype.eqn=function(b){return this.cmpn(b)===0},t.prototype.eq=function(b){return this.cmp(b)===0},t.red=function(b){return new $(b)},t.prototype.toRed=function(b){return d(!this.red,"Already a number in reduction context"),d(this.negative===0,"red works only with positives"),b.convertTo(this)._forceRed(b)},t.prototype.fromRed=function(){return d(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},t.prototype._forceRed=function(b){return this.red=b,this},t.prototype.forceRed=function(b){return d(!this.red,"Already a number in reduction context"),this._forceRed(b)},t.prototype.redAdd=function(b){return d(this.red,"redAdd works only with red numbers"),this.red.add(this,b)},t.prototype.redIAdd=function(b){return d(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,b)},t.prototype.redSub=function(b){return d(this.red,"redSub works only with red numbers"),this.red.sub(this,b)},t.prototype.redISub=function(b){return d(this.red,"redISub works only with red numbers"),this.red.isub(this,b)},t.prototype.redShl=function(b){return d(this.red,"redShl works only with red numbers"),this.red.shl(this,b)},t.prototype.redMul=function(b){return d(this.red,"redMul works only with red numbers"),this.red._verify2(this,b),this.red.mul(this,b)},t.prototype.redIMul=function(b){return d(this.red,"redMul works only with red numbers"),this.red._verify2(this,b),this.red.imul(this,b)},t.prototype.redSqr=function(){return d(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},t.prototype.redISqr=function(){return d(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},t.prototype.redSqrt=function(){return d(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},t.prototype.redInvm=function(){return d(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},t.prototype.redNeg=function(){return d(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},t.prototype.redPow=function(b){return d(this.red&&!b.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,b)};var P={k256:null,p224:null,p192:null,p25519:null};function u(v,b){this.name=v,this.p=new t(b,16),this.n=this.p.bitLength(),this.k=new t(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}u.prototype._tmp=function(){var b=new t(null);return b.words=new Array(Math.ceil(this.n/13)),b},u.prototype.ireduce=function(b){var o=b,m;do this.split(o,this.tmp),o=this.imulK(o),o=o.iadd(this.tmp),m=o.bitLength();while(m>this.n);var F=m<this.n?-1:o.ucmp(this.p);return F===0?(o.words[0]=0,o.length=1):F>0?o.isub(this.p):o.strip!==void 0?o.strip():o._strip(),o},u.prototype.split=function(b,o){b.iushrn(this.n,0,o)},u.prototype.imulK=function(b){return b.imul(this.k)};function D(){u.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}f(D,u),D.prototype.split=function(b,o){for(var m=4194303,F=Math.min(b.length,9),I=0;I<F;I++)o.words[I]=b.words[I];if(o.length=F,b.length<=9){b.words[0]=0,b.length=1;return}var M=b.words[9];for(o.words[o.length++]=M&m,I=10;I<b.length;I++){var k=b.words[I]|0;b.words[I-10]=(k&m)<<4|M>>>22,M=k}M>>>=22,b.words[I-10]=M,M===0&&b.length>10?b.length-=10:b.length-=9},D.prototype.imulK=function(b){b.words[b.length]=0,b.words[b.length+1]=0,b.length+=2;for(var o=0,m=0;m<b.length;m++){var F=b.words[m]|0;o+=F*977,b.words[m]=o&67108863,o=F*64+(o/67108864|0)}return b.words[b.length-1]===0&&(b.length--,b.words[b.length-1]===0&&b.length--),b};function g(){u.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}f(g,u);function H(){u.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}f(H,u);function U(){u.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}f(U,u),U.prototype.imulK=function(b){for(var o=0,m=0;m<b.length;m++){var F=(b.words[m]|0)*19+o,I=F&67108863;F>>>=26,b.words[m]=I,o=F}return o!==0&&(b.words[b.length++]=o),b},t._prime=function(b){if(P[b])return P[b];var o;if(b==="k256")o=new D;else if(b==="p224")o=new g;else if(b==="p192")o=new H;else if(b==="p25519")o=new U;else throw new Error("Unknown prime "+b);return P[b]=o,o};function $(v){if(typeof v=="string"){var b=t._prime(v);this.m=b.p,this.prime=b}else d(v.gtn(1),"modulus must be greater than 1"),this.m=v,this.prime=null}$.prototype._verify1=function(b){d(b.negative===0,"red works only with positives"),d(b.red,"red works only with red numbers")},$.prototype._verify2=function(b,o){d((b.negative|o.negative)===0,"red works only with positives"),d(b.red&&b.red===o.red,"red works only with red numbers")},$.prototype.imod=function(b){return this.prime?this.prime.ireduce(b)._forceRed(this):b.umod(this.m)._forceRed(this)},$.prototype.neg=function(b){return b.isZero()?b.clone():this.m.sub(b)._forceRed(this)},$.prototype.add=function(b,o){this._verify2(b,o);var m=b.add(o);return m.cmp(this.m)>=0&&m.isub(this.m),m._forceRed(this)},$.prototype.iadd=function(b,o){this._verify2(b,o);var m=b.iadd(o);return m.cmp(this.m)>=0&&m.isub(this.m),m},$.prototype.sub=function(b,o){this._verify2(b,o);var m=b.sub(o);return m.cmpn(0)<0&&m.iadd(this.m),m._forceRed(this)},$.prototype.isub=function(b,o){this._verify2(b,o);var m=b.isub(o);return m.cmpn(0)<0&&m.iadd(this.m),m},$.prototype.shl=function(b,o){return this._verify1(b),this.imod(b.ushln(o))},$.prototype.imul=function(b,o){return this._verify2(b,o),this.imod(b.imul(o))},$.prototype.mul=function(b,o){return this._verify2(b,o),this.imod(b.mul(o))},$.prototype.isqr=function(b){return this.imul(b,b.clone())},$.prototype.sqr=function(b){return this.mul(b,b)},$.prototype.sqrt=function(b){if(b.isZero())return b.clone();var o=this.m.andln(3);if(d(o%2===1),o===3){var m=this.m.add(new t(1)).iushrn(2);return this.pow(b,m)}for(var F=this.m.subn(1),I=0;!F.isZero()&&F.andln(1)===0;)I++,F.iushrn(1);d(!F.isZero());var M=new t(1).toRed(this),k=M.redNeg(),w=this.m.subn(1).iushrn(1),r=this.m.bitLength();for(r=new t(2*r*r).toRed(this);this.pow(r,w).cmp(k)!==0;)r.redIAdd(k);for(var B=this.pow(r,F),W=this.pow(b,F.addn(1).iushrn(1)),K=this.pow(b,F),V=I;K.cmp(M)!==0;){for(var O=K,Y=0;O.cmp(M)!==0;Y++)O=O.redSqr();d(Y<V);var Z=this.pow(B,new t(1).iushln(V-Y-1));W=W.redMul(Z),B=Z.redSqr(),K=K.redMul(B),V=Y}return W},$.prototype.invm=function(b){var o=b._invmp(this.m);return o.negative!==0?(o.negative=0,this.imod(o).redNeg()):this.imod(o)},$.prototype.pow=function(b,o){if(o.isZero())return new t(1).toRed(this);if(o.cmpn(1)===0)return b.clone();var m=4,F=new Array(1<<m);F[0]=new t(1).toRed(this),F[1]=b;for(var I=2;I<F.length;I++)F[I]=this.mul(F[I-1],b);var M=F[0],k=0,w=0,r=o.bitLength()%26;for(r===0&&(r=26),I=o.length-1;I>=0;I--){for(var B=o.words[I],W=r-1;W>=0;W--){var K=B>>W&1;if(M!==F[0]&&(M=this.sqr(M)),K===0&&k===0){w=0;continue}k<<=1,k|=K,w++,!(w!==m&&(I!==0||W!==0))&&(M=this.mul(M,F[k]),w=0,k=0)}r=26}return M},$.prototype.convertTo=function(b){var o=b.umod(this.m);return o===b?o.clone():o},$.prototype.convertFrom=function(b){var o=b.clone();return o.red=null,o},t.mont=function(b){return new q(b)};function q(v){$.call(this,v),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new t(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)}f(q,$),q.prototype.convertTo=function(b){return this.imod(b.ushln(this.shift))},q.prototype.convertFrom=function(b){var o=this.imod(b.mul(this.rinv));return o.red=null,o},q.prototype.imul=function(b,o){if(b.isZero()||o.isZero())return b.words[0]=0,b.length=1,b;var m=b.imul(o),F=m.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),I=m.isub(F).iushrn(this.shift),M=I;return I.cmp(this.m)>=0?M=I.isub(this.m):I.cmpn(0)<0&&(M=I.iadd(this.m)),M._forceRed(this)},q.prototype.mul=function(b,o){if(b.isZero()||o.isZero())return new t(0)._forceRed(this);var m=b.mul(o),F=m.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),I=m.isub(F).iushrn(this.shift),M=I;return I.cmp(this.m)>=0?M=I.isub(this.m):I.cmpn(0)<0&&(M=I.iadd(this.m)),M._forceRed(this)},q.prototype.invm=function(b){var o=this.imod(b._invmp(this.m).mul(this.r2));return o._forceRed(this)}})(e,G)})(Tf);var F6=Tf.exports;Object.defineProperty(A6,"__esModule",{value:!0});var j1=F6,Li=m6().ec,Nf=new Li("secp256k1"),Z2=Nf.curve;A6.privateKeyExport=function(e,a){a===void 0&&(a=!0);var c=new j1(e);if(c.ucmp(Z2.n)>=0)throw new Error("couldn't export to DER format");var d=Nf.g.mul(c);return Eb(d.getX(),d.getY(),a)};A6.privateKeyModInverse=function(e){var a=new j1(e);if(a.ucmp(Z2.n)>=0||a.isZero())throw new Error("private key range is invalid");return a.invm(Z2.n).toArrayLike(T.Buffer,"be",32)};A6.signatureImport=function(e){var a=new j1(e.r);a.ucmp(Z2.n)>=0&&(a=new j1(0));var c=new j1(e.s);return c.ucmp(Z2.n)>=0&&(c=new j1(0)),T.Buffer.concat([a.toArrayLike(T.Buffer,"be",32),c.toArrayLike(T.Buffer,"be",32)])};A6.ecdhUnsafe=function(e,a,c){c===void 0&&(c=!0);var d=Nf.keyFromPublic(e),f=new j1(a);if(f.ucmp(Z2.n)>=0||f.isZero())throw new Error("scalar was invalid (zero or overflow)");var t=d.pub.mul(f);return Eb(t.getX(),t.getY(),c)};var Eb=function(e,a,c){var d;return c?(d=T.Buffer.alloc(33),d[0]=a.isOdd()?3:2,e.toArrayLike(T.Buffer,"be",32).copy(d,1)):(d=T.Buffer.alloc(65),d[0]=4,e.toArrayLike(T.Buffer,"be",32).copy(d,1),a.toArrayLike(T.Buffer,"be",32).copy(d,33)),d},s8={};Object.defineProperty(s8,"__esModule",{value:!0});var $i=T.Buffer.from([48,129,211,2,1,1,4,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,129,133,48,129,130,2,1,1,48,44,6,7,42,134,72,206,61,1,1,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,255,252,47,48,6,4,1,0,4,1,7,4,33,2,121,190,102,126,249,220,187,172,85,160,98,149,206,135,11,7,2,155,252,219,45,206,40,217,89,242,129,91,22,248,23,152,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,186,174,220,230,175,72,160,59,191,210,94,140,208,54,65,65,2,1,1,161,36,3,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),Gi=T.Buffer.from([48,130,1,19,2,1,1,4,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,129,165,48,129,162,2,1,1,48,44,6,7,42,134,72,206,61,1,1,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,255,252,47,48,6,4,1,0,4,1,7,4,65,4,121,190,102,126,249,220,187,172,85,160,98,149,206,135,11,7,2,155,252,219,45,206,40,217,89,242,129,91,22,248,23,152,72,58,218,119,38,163,196,101,93,164,251,252,14,17,8,168,253,23,180,72,166,133,84,25,156,71,208,143,251,16,212,184,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,186,174,220,230,175,72,160,59,191,210,94,140,208,54,65,65,2,1,1,161,68,3,66,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);s8.privateKeyExport=function(e,a,c){c===void 0&&(c=!0);var d=T.Buffer.from(c?$i:Gi);return e.copy(d,c?8:9),a.copy(d,c?181:214),d};s8.privateKeyImport=function(e){var a=e.length,c=0;if(a<c+1||e[c]!==48||(c+=1,a<c+1||!(e[c]&128)))return null;var d=e[c]&127;if(c+=1,d<1||d>2||a<c+d)return null;var f=e[c+d-1]|(d>1?e[c+d-2]<<8:0);return c+=d,a<c+f||a<c+3||e[c]!==2||e[c+1]!==1||e[c+2]!==1||(c+=3,a<c+2||e[c]!==4||e[c+1]>32||a<c+2+e[c+1])?null:e.slice(c+2,c+2+e[c+1])};s8.signatureImportLax=function(e){var a=T.Buffer.alloc(32,0),c=T.Buffer.alloc(32,0),d=e.length,f=0;if(e[f++]!==48)return null;var t=e[f++];if(t&128&&(f+=t-128,f>d)||e[f++]!==2)return null;var n=e[f++];if(n&128){if(t=n-128,f+t>d)return null;for(;t>0&&e[f]===0;f+=1,t-=1);for(n=0;t>0;f+=1,t-=1)n=(n<<8)+e[f]}if(n>d-f)return null;var s=f;if(f+=n,e[f++]!==2)return null;var p=e[f++];if(p&128){if(t=p-128,f+t>d)return null;for(;t>0&&e[f]===0;f+=1,t-=1);for(p=0;t>0;f+=1,t-=1)p=(p<<8)+e[f]}if(p>d-f)return null;var A=f;for(f+=p;n>0&&e[s]===0;n-=1,s+=1);if(n>32)return null;var S=e.slice(s,s+n);for(S.copy(a,32-S.length);p>0&&e[A]===0;p-=1,A+=1);if(p>32)return null;var _=e.slice(A,A+p);return _.copy(c,32-_.length),{r:a,s:c}};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ecdhUnsafe=e.ecdh=e.recover=e.verify=e.sign=e.signatureImportLax=e.signatureImport=e.signatureExport=e.signatureNormalize=e.publicKeyCombine=e.publicKeyTweakMul=e.publicKeyTweakAdd=e.publicKeyVerify=e.publicKeyConvert=e.publicKeyCreate=e.privateKeyTweakMul=e.privateKeyTweakAdd=e.privateKeyModInverse=e.privateKeyNegate=e.privateKeyImport=e.privateKeyExport=e.privateKeyVerify=void 0;var a=pb,c=A6,d=s8;e.privateKeyVerify=function(f){return f.length!==32?!1:a.privateKeyVerify(Uint8Array.from(f))},e.privateKeyExport=function(f,t){if(f.length!==32)throw new RangeError("private key length is invalid");var n=c.privateKeyExport(f,t);return d.privateKeyExport(f,n,t)},e.privateKeyImport=function(f){if(f=d.privateKeyImport(f),f!==null&&f.length===32&&e.privateKeyVerify(f))return f;throw new Error("couldn't import from DER format")},e.privateKeyNegate=function(f){return T.Buffer.from(a.privateKeyNegate(Uint8Array.from(f)))},e.privateKeyModInverse=function(f){if(f.length!==32)throw new Error("private key length is invalid");return T.Buffer.from(c.privateKeyModInverse(Uint8Array.from(f)))},e.privateKeyTweakAdd=function(f,t){return T.Buffer.from(a.privateKeyTweakAdd(Uint8Array.from(f),t))},e.privateKeyTweakMul=function(f,t){return T.Buffer.from(a.privateKeyTweakMul(Uint8Array.from(f),Uint8Array.from(t)))},e.publicKeyCreate=function(f,t){return T.Buffer.from(a.publicKeyCreate(Uint8Array.from(f),t))},e.publicKeyConvert=function(f,t){return T.Buffer.from(a.publicKeyConvert(Uint8Array.from(f),t))},e.publicKeyVerify=function(f){return f.length!==33&&f.length!==65?!1:a.publicKeyVerify(Uint8Array.from(f))},e.publicKeyTweakAdd=function(f,t,n){return T.Buffer.from(a.publicKeyTweakAdd(Uint8Array.from(f),Uint8Array.from(t),n))},e.publicKeyTweakMul=function(f,t,n){return T.Buffer.from(a.publicKeyTweakMul(Uint8Array.from(f),Uint8Array.from(t),n))},e.publicKeyCombine=function(f,t){var n=[];return f.forEach(function(s){n.push(Uint8Array.from(s))}),T.Buffer.from(a.publicKeyCombine(n,t))},e.signatureNormalize=function(f){return T.Buffer.from(a.signatureNormalize(Uint8Array.from(f)))},e.signatureExport=function(f){return T.Buffer.from(a.signatureExport(Uint8Array.from(f)))},e.signatureImport=function(f){return T.Buffer.from(a.signatureImport(Uint8Array.from(f)))},e.signatureImportLax=function(f){if(f.length===0)throw new RangeError("signature length is invalid");var t=d.signatureImportLax(f);if(t===null)throw new Error("couldn't parse DER signature");return c.signatureImport(t)},e.sign=function(f,t,n){if(n===null)throw new TypeError("options should be an Object");var s=void 0;if(n){if(s={},n.data===null)throw new TypeError("options.data should be a Buffer");if(n.data){if(n.data.length!=32)throw new RangeError("options.data length is invalid");s.data=new Uint8Array(n.data)}if(n.noncefn===null)throw new TypeError("options.noncefn should be a Function");n.noncefn&&(s.noncefn=function(A,S,_,C,h){var l=_!=null?T.Buffer.from(_):null,x=C!=null?T.Buffer.from(C):null,i=T.Buffer.from("");return n.noncefn&&(i=n.noncefn(T.Buffer.from(A),T.Buffer.from(S),l,x,h)),new Uint8Array(i)})}var p=a.ecdsaSign(Uint8Array.from(f),Uint8Array.from(t),s);return{signature:T.Buffer.from(p.signature),recovery:p.recid}},e.verify=function(f,t,n){return a.ecdsaVerify(Uint8Array.from(t),Uint8Array.from(f),n)},e.recover=function(f,t,n,s){return T.Buffer.from(a.ecdsaRecover(Uint8Array.from(t),n,Uint8Array.from(f),s))},e.ecdh=function(f,t){return T.Buffer.from(a.ecdh(Uint8Array.from(f),Uint8Array.from(t),{}))},e.ecdhUnsafe=function(f,t,n){if(f.length!==33&&f.length!==65)throw new RangeError("public key length is invalid");if(t.length!==32)throw new RangeError("private key length is invalid");return T.Buffer.from(c.ecdhUnsafe(Uint8Array.from(f),Uint8Array.from(t),n))}})(y9);var Ab=function(a){if(typeof a!="string")throw new Error("[is-hex-prefixed] value must be type 'string', is currently type "+typeof a+", while checking isHexPrefixed.");return a.slice(0,2)==="0x"},Hi=Ab,ji=function(a){return typeof a!="string"?a:Hi(a)?a.slice(2):a},zi=Ab,Fb=ji;function v9(e){var a=e;if(typeof a!="string")throw new Error("[ethjs-util] while padding to even, value must be string, is currently "+typeof a+", while padToEven.");return a.length%2&&(a="0"+a),a}function yb(e){var a=e.toString(16);return"0x"+a}function Ji(e){var a=yb(e);return new T.Buffer(v9(a.slice(2)),"hex")}function Wi(e){if(typeof e!="string")throw new Error("[ethjs-util] while getting binary size, method getBinarySize requires input 'str' to be type String, got '"+typeof e+"'.");return T.Buffer.byteLength(e,"utf8")}function qi(e,a,c){if(Array.isArray(e)!==!0)throw new Error("[ethjs-util] method arrayContainsArray requires input 'superset' to be an array got type '"+typeof e+"'");if(Array.isArray(a)!==!0)throw new Error("[ethjs-util] method arrayContainsArray requires input 'subset' to be an array got type '"+typeof a+"'");return a[!!c&&"some"||"every"](function(d){return e.indexOf(d)>=0})}function Ki(e){var a=new T.Buffer(v9(Fb(e).replace(/^0+|0+$/g,"")),"hex");return a.toString("utf8")}function Yi(e){var a="",c=0,d=e.length;for(e.substring(0,2)==="0x"&&(c=2);c<d;c+=2){var f=parseInt(e.substr(c,2),16);a+=String.fromCharCode(f)}return a}function Vi(e){var a=new T.Buffer(e,"utf8");return"0x"+v9(a.toString("hex")).replace(/^0+|0+$/g,"")}function Zi(e){for(var a="",c=0;c<e.length;c++){var d=e.charCodeAt(c),f=d.toString(16);a+=f.length<2?"0"+f:f}return"0x"+a}function Qi(e,a,c){if(!Array.isArray(e))throw new Error("[ethjs-util] method getKeys expecting type Array as 'params' input, got '"+typeof e+"'");if(typeof a!="string")throw new Error("[ethjs-util] method getKeys expecting type String for input 'key' got '"+typeof a+"'.");for(var d=[],f=0;f<e.length;f++){var t=e[f][a];if(c&&!t)t="";else if(typeof t!="string")throw new Error("invalid abi");d.push(t)}return d}function Xi(e,a){return!(typeof e!="string"||!e.match(/^0x[0-9A-Fa-f]*$/)||a&&e.length!==2+2*a)}var oa={arrayContainsArray:qi,intToBuffer:Ji,getBinarySize:Wi,isHexPrefixed:zi,stripHexPrefix:Fb,padToEven:v9,intToHex:yb,fromAscii:Zi,fromUtf8:Vi,toAscii:Yi,toUtf8:Ki,getKeys:Qi,isHexString:Xi},gb={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.KECCAK256_RLP=e.KECCAK256_RLP_S=e.KECCAK256_RLP_ARRAY=e.KECCAK256_RLP_ARRAY_S=e.KECCAK256_NULL=e.KECCAK256_NULL_S=e.TWO_POW256=e.MAX_INTEGER=void 0;var a=F6;e.MAX_INTEGER=new a("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16),e.TWO_POW256=new a("10000000000000000000000000000000000000000000000000000000000000000",16),e.KECCAK256_NULL_S="c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",e.KECCAK256_NULL=T.Buffer.from(e.KECCAK256_NULL_S,"hex"),e.KECCAK256_RLP_ARRAY_S="1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",e.KECCAK256_RLP_ARRAY=T.Buffer.from(e.KECCAK256_RLP_ARRAY_S,"hex"),e.KECCAK256_RLP_S="56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",e.KECCAK256_RLP=T.Buffer.from(e.KECCAK256_RLP_S,"hex")})(gb);var vb={},y6={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.baToJSON=e.addHexPrefix=e.toUnsigned=e.fromSigned=e.bufferToHex=e.bufferToInt=e.toBuffer=e.stripZeros=e.unpad=e.setLengthRight=e.setLength=e.setLengthLeft=e.zeros=void 0;var a=oa,c=F6;e.zeros=function(d){return T.Buffer.allocUnsafe(d).fill(0)},e.setLengthLeft=function(d,f,t){t===void 0&&(t=!1);var n=e.zeros(f);return d=e.toBuffer(d),t?d.length<f?(d.copy(n),n):d.slice(0,f):d.length<f?(d.copy(n,f-d.length),n):d.slice(-f)},e.setLength=e.setLengthLeft,e.setLengthRight=function(d,f){return e.setLength(d,f,!0)},e.unpad=function(d){d=a.stripHexPrefix(d);for(var f=d[0];d.length>0&&f.toString()==="0";)d=d.slice(1),f=d[0];return d},e.stripZeros=e.unpad,e.toBuffer=function(d){if(!T.Buffer.isBuffer(d))if(Array.isArray(d))d=T.Buffer.from(d);else if(typeof d=="string")if(a.isHexString(d))d=T.Buffer.from(a.padToEven(a.stripHexPrefix(d)),"hex");else throw new Error("Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: "+d);else if(typeof d=="number")d=a.intToBuffer(d);else if(d==null)d=T.Buffer.allocUnsafe(0);else if(c.isBN(d))d=d.toArrayLike(T.Buffer);else if(d.toArray)d=T.Buffer.from(d.toArray());else throw new Error("invalid type");return d},e.bufferToInt=function(d){return new c(e.toBuffer(d)).toNumber()},e.bufferToHex=function(d){return d=e.toBuffer(d),"0x"+d.toString("hex")},e.fromSigned=function(d){return new c(d).fromTwos(256)},e.toUnsigned=function(d){return T.Buffer.from(d.toTwos(256).toArray())},e.addHexPrefix=function(d){return typeof d!="string"||a.isHexPrefixed(d)?d:"0x"+d},e.baToJSON=function(d){if(T.Buffer.isBuffer(d))return"0x"+d.toString("hex");if(d instanceof Array){for(var f=[],t=0;t<d.length;t++)f.push(e.baToJSON(d[t]));return f}}})(y6);var C9={},g6={},Pf={};Object.defineProperty(Pf,"__esModule",{value:!0});function eo(e){return function(a){var c=e();return c.update(a),T.Buffer.from(c.digest())}}Pf.createHashFunction=eo;Object.defineProperty(g6,"__esModule",{value:!0});var w9=Pf,B9=Cf;g6.keccak224=w9.createHashFunction(function(){return B9("keccak224")});g6.keccak256=w9.createHashFunction(function(){return B9("keccak256")});g6.keccak384=w9.createHashFunction(function(){return B9("keccak384")});g6.keccak512=w9.createHashFunction(function(){return B9("keccak512")});(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.rlphash=e.ripemd160=e.sha256=e.keccak256=e.keccak=void 0;var a=g6,c=a.keccak224,d=a.keccak384,f=a.keccak256,t=a.keccak512,n=nb(),s=oa,p=E6,A=y6;e.keccak=function(S,_){switch(_===void 0&&(_=256),typeof S=="string"&&!s.isHexString(S)?S=T.Buffer.from(S,"utf8"):S=A.toBuffer(S),_||(_=256),_){case 224:return c(S);case 256:return f(S);case 384:return d(S);case 512:return t(S);default:throw new Error("Invald algorithm: keccak"+_)}},e.keccak256=function(S){return e.keccak(S)},e.sha256=function(S){return S=A.toBuffer(S),n("sha256").update(S).digest()},e.ripemd160=function(S,_){S=A.toBuffer(S);var C=n("rmd160").update(S).digest();return _===!0?A.setLength(C,32):C},e.rlphash=function(S){return e.keccak(p.encode(S))}})(C9);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.importPublic=e.privateToPublic=e.privateToAddress=e.publicToAddress=e.pubToAddress=e.isValidPublic=e.isValidPrivate=e.isPrecompiled=e.generateAddress2=e.generateAddress=e.isValidChecksumAddress=e.toChecksumAddress=e.isZeroAddress=e.isValidAddress=e.zeroAddress=void 0;var a=E9(),c=oa,d=y9,f=F6,t=y6,n=C9;e.zeroAddress=function(){var s=20,p=t.zeros(s);return t.bufferToHex(p)},e.isValidAddress=function(s){return/^0x[0-9a-fA-F]{40}$/.test(s)},e.isZeroAddress=function(s){var p=e.zeroAddress();return p===t.addHexPrefix(s)},e.toChecksumAddress=function(s,p){s=c.stripHexPrefix(s).toLowerCase();for(var A=p!==void 0?p.toString()+"0x":"",S=n.keccak(A+s).toString("hex"),_="0x",C=0;C<s.length;C++)parseInt(S[C],16)>=8?_+=s[C].toUpperCase():_+=s[C];return _},e.isValidChecksumAddress=function(s,p){return e.isValidAddress(s)&&e.toChecksumAddress(s,p)===s},e.generateAddress=function(s,p){s=t.toBuffer(s);var A=new f(p);return A.isZero()?n.rlphash([s,null]).slice(-20):n.rlphash([s,T.Buffer.from(A.toArray())]).slice(-20)},e.generateAddress2=function(s,p,A){var S=t.toBuffer(s),_=t.toBuffer(p),C=t.toBuffer(A);a(S.length===20),a(_.length===32);var h=n.keccak256(T.Buffer.concat([T.Buffer.from("ff","hex"),S,_,n.keccak256(C)]));return h.slice(-20)},e.isPrecompiled=function(s){var p=t.unpad(s);return p.length===1&&p[0]>=1&&p[0]<=8},e.isValidPrivate=function(s){return d.privateKeyVerify(s)},e.isValidPublic=function(s,p){return p===void 0&&(p=!1),s.length===64?d.publicKeyVerify(T.Buffer.concat([T.Buffer.from([4]),s])):p?d.publicKeyVerify(s):!1},e.pubToAddress=function(s,p){return p===void 0&&(p=!1),s=t.toBuffer(s),p&&s.length!==64&&(s=d.publicKeyConvert(s,!1).slice(1)),a(s.length===64),n.keccak(s).slice(-20)},e.publicToAddress=e.pubToAddress,e.privateToAddress=function(s){return e.publicToAddress(e.privateToPublic(s))},e.privateToPublic=function(s){return s=t.toBuffer(s),d.publicKeyCreate(s,!1).slice(1)},e.importPublic=function(s){return s=t.toBuffer(s),s.length!==64&&(s=d.publicKeyConvert(s,!1).slice(1)),s}})(vb);var Be={};Object.defineProperty(Be,"__esModule",{value:!0});Be.hashPersonalMessage=Be.isValidSignature=Be.fromRpcSig=Be.toRpcSig=Be.ecrecover=Be.ecsign=void 0;var Cd=y9,I8=F6,z1=y6,ao=C9;Be.ecsign=function(e,a,c){var d=Cd.sign(e,a),f=d.recovery,t={r:d.signature.slice(0,32),s:d.signature.slice(32,64),v:c?f+(c*2+35):f+27};return t};Be.ecrecover=function(e,a,c,d,f){var t=T.Buffer.concat([z1.setLength(c,32),z1.setLength(d,32)],64),n=Mf(a,f);if(!Of(n))throw new Error("Invalid signature v value");var s=Cd.recover(e,t,n);return Cd.publicKeyConvert(s,!1).slice(1)};Be.toRpcSig=function(e,a,c,d){var f=Mf(e,d);if(!Of(f))throw new Error("Invalid signature v value");return z1.bufferToHex(T.Buffer.concat([z1.setLengthLeft(a,32),z1.setLengthLeft(c,32),z1.toBuffer(e)]))};Be.fromRpcSig=function(e){var a=z1.toBuffer(e);if(a.length!==65)throw new Error("Invalid signature length");var c=a[64];return c<27&&(c+=27),{v:c,r:a.slice(0,32),s:a.slice(32,64)}};Be.isValidSignature=function(e,a,c,d,f){d===void 0&&(d=!0);var t=new I8("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16),n=new I8("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141",16);if(a.length!==32||c.length!==32||!Of(Mf(e,f)))return!1;var s=new I8(a),p=new I8(c);return!(s.isZero()||s.gt(n)||p.isZero()||p.gt(n)||d&&p.cmp(t)===1)};Be.hashPersonalMessage=function(e){var a=T.Buffer.from(`Ethereum Signed Message:
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{q as P,b2 as Ye,d as Z,b3 as Ze,aY as it}from"../main.js";var Je={},Qe={exports:{}},je={};(function(o){o.fetch=n(P.fetch)&&n(P.ReadableStream),o.writableStream=n(P.WritableStream),o.abortController=n(P.AbortController);var r;function h(){if(r!==void 0)return r;if(P.XMLHttpRequest){r=new P.XMLHttpRequest;try{r.open("GET",P.XDomainRequest?"/":"https://example.com")}catch{r=null}}else r=null;return r}function f(g){var u=h();if(!u)return!1;try{return u.responseType=g,u.responseType===g}catch{}return!1}o.arraybuffer=o.fetch||f("arraybuffer"),o.msstream=!o.fetch&&f("ms-stream"),o.mozchunkedarraybuffer=!o.fetch&&f("moz-chunked-arraybuffer"),o.overrideMimeType=o.fetch||(h()?n(h().overrideMimeType):!1);function n(g){return typeof g=="function"}r=null})(je);var xe={},Ke=je,ft=Ze,et=Ye(),Ae=xe.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},$e=xe.IncomingMessage=function(o,r,h,f){var n=this;if(et.Readable.call(n),n._mode=h,n.headers={},n.rawHeaders=[],n.trailers={},n.rawTrailers=[],n.on("end",function(){Z.process.nextTick(function(){n.emit("close")})}),h==="fetch"){let C=function(){u.read().then(function(m){if(!n._destroyed){if(f(m.done),m.done){n.push(null);return}n.push(Z.Buffer.from(m.value)),C()}}).catch(function(m){f(!0),n._destroyed||n.emit("error",m)})};if(n._fetchResponse=r,n.url=r.url,n.statusCode=r.status,n.statusMessage=r.statusText,r.headers.forEach(function(m,A){n.headers[A.toLowerCase()]=m,n.rawHeaders.push(A,m)}),Ke.writableStream){var g=new WritableStream({write:function(m){return f(!1),new Promise(function(A,te){n._destroyed?te():n.push(Z.Buffer.from(m))?A():n._resumeFetch=A})},close:function(){f(!0),n._destroyed||n.push(null)},abort:function(m){f(!0),n._destroyed||n.emit("error",m)}});try{r.body.pipeTo(g).catch(function(m){f(!0),n._destroyed||n.emit("error",m)});return}catch{}}var u=r.body.getReader();C()}else{n._xhr=o,n._pos=0,n.url=o.responseURL,n.statusCode=o.status,n.statusMessage=o.statusText;var a=o.getAllResponseHeaders().split(/\r?\n/);if(a.forEach(function(C){var m=C.match(/^([^:]+):\s*(.*)/);if(m){var A=m[1].toLowerCase();A==="set-cookie"?(n.headers[A]===void 0&&(n.headers[A]=[]),n.headers[A].push(m[2])):n.headers[A]!==void 0?n.headers[A]+=", "+m[2]:n.headers[A]=m[2],n.rawHeaders.push(m[1],m[2])}}),n._charset="x-user-defined",!Ke.overrideMimeType){var v=n.rawHeaders["mime-type"];if(v){var T=v.match(/;\s*charset=([^;])(;|$)/);T&&(n._charset=T[1].toLowerCase())}n._charset||(n._charset="utf-8")}}};ft($e,et.Readable);$e.prototype._read=function(){var o=this,r=o._resumeFetch;r&&(o._resumeFetch=null,r())};$e.prototype._onXHRProgress=function(o){var r=this,h=r._xhr,f=null;switch(r._mode){case"text":if(f=h.responseText,f.length>r._pos){var n=f.substr(r._pos);if(r._charset==="x-user-defined"){for(var g=Z.Buffer.alloc(n.length),u=0;u<n.length;u++)g[u]=n.charCodeAt(u)&255;r.push(g)}else r.push(n,r._charset);r._pos=f.length}break;case"arraybuffer":if(h.readyState!==Ae.DONE||!h.response)break;f=h.response,r.push(Z.Buffer.from(new Uint8Array(f)));break;case"moz-chunked-arraybuffer":if(f=h.response,h.readyState!==Ae.LOADING||!f)break;r.push(Z.Buffer.from(new Uint8Array(f)));break;case"ms-stream":if(f=h.response,h.readyState!==Ae.LOADING)break;var a=new P.MSStreamReader;a.onprogress=function(){a.result.byteLength>r._pos&&(r.push(Z.Buffer.from(new Uint8Array(a.result.slice(r._pos)))),r._pos=a.result.byteLength)},a.onload=function(){o(!0),r.push(null)},a.readAsArrayBuffer(f);break}r._xhr.readyState===Ae.DONE&&r._mode!=="ms-stream"&&(o(!0),r.push(null))};var he=je,ht=Ze,tt=xe,ke=Ye(),ut=tt.IncomingMessage,Ve=tt.readyStates;function ct(o,r){return he.fetch&&r?"fetch":he.mozchunkedarraybuffer?"moz-chunked-arraybuffer":he.msstream?"ms-stream":he.arraybuffer&&o?"arraybuffer":"text"}var S=Qe.exports=function(o){var r=this;ke.Writable.call(r),r._opts=o,r._body=[],r._headers={},o.auth&&r.setHeader("Authorization","Basic "+Z.Buffer.from(o.auth).toString("base64")),Object.keys(o.headers).forEach(function(n){r.setHeader(n,o.headers[n])});var h,f=!0;if(o.mode==="disable-fetch"||"requestTimeout"in o&&!he.abortController)f=!1,h=!0;else if(o.mode==="prefer-streaming")h=!1;else if(o.mode==="allow-wrong-content-type")h=!he.overrideMimeType;else if(!o.mode||o.mode==="default"||o.mode==="prefer-fast")h=!0;else throw new Error("Invalid value for opts.mode");r._mode=ct(h,f),r._fetchTimer=null,r._socketTimeout=null,r._socketTimer=null,r.on("finish",function(){r._onFinish()})};ht(S,ke.Writable);S.prototype.setHeader=function(o,r){var h=this,f=o.toLowerCase();pt.indexOf(f)===-1&&(h._headers[f]={name:o,value:r})};S.prototype.getHeader=function(o){var r=this._headers[o.toLowerCase()];return r?r.value:null};S.prototype.removeHeader=function(o){var r=this;delete r._headers[o.toLowerCase()]};S.prototype._onFinish=function(){var o=this;if(!o._destroyed){var r=o._opts;"timeout"in r&&r.timeout!==0&&o.setTimeout(r.timeout);var h=o._headers,f=null;r.method!=="GET"&&r.method!=="HEAD"&&(f=new Blob(o._body,{type:(h["content-type"]||{}).value||""}));var n=[];if(Object.keys(h).forEach(function(v){var T=h[v].name,C=h[v].value;Array.isArray(C)?C.forEach(function(m){n.push([T,m])}):n.push([T,C])}),o._mode==="fetch"){var g=null;if(he.abortController){var u=new AbortController;g=u.signal,o._fetchAbortController=u,"requestTimeout"in r&&r.requestTimeout!==0&&(o._fetchTimer=P.setTimeout(function(){o.emit("requestTimeout"),o._fetchAbortController&&o._fetchAbortController.abort()},r.requestTimeout))}P.fetch(o._opts.url,{method:o._opts.method,headers:n,body:f||void 0,mode:"cors",credentials:r.withCredentials?"include":"same-origin",signal:g}).then(function(v){o._fetchResponse=v,o._resetTimers(!1),o._connect()},function(v){o._resetTimers(!0),o._destroyed||o.emit("error",v)})}else{var a=o._xhr=new P.XMLHttpRequest;try{a.open(o._opts.method,o._opts.url,!0)}catch(v){Z.process.nextTick(function(){o.emit("error",v)});return}"responseType"in a&&(a.responseType=o._mode),"withCredentials"in a&&(a.withCredentials=!!r.withCredentials),o._mode==="text"&&"overrideMimeType"in a&&a.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in r&&(a.timeout=r.requestTimeout,a.ontimeout=function(){o.emit("requestTimeout")}),n.forEach(function(v){a.setRequestHeader(v[0],v[1])}),o._response=null,a.onreadystatechange=function(){switch(a.readyState){case Ve.LOADING:case Ve.DONE:o._onXHRProgress();break}},o._mode==="moz-chunked-arraybuffer"&&(a.onprogress=function(){o._onXHRProgress()}),a.onerror=function(){o._destroyed||(o._resetTimers(!0),o.emit("error",new Error("XHR error")))};try{a.send(f)}catch(v){Z.process.nextTick(function(){o.emit("error",v)});return}}}};function lt(o){try{var r=o.status;return r!==null&&r!==0}catch{return!1}}S.prototype._onXHRProgress=function(){var o=this;o._resetTimers(!1),!(!lt(o._xhr)||o._destroyed)&&(o._response||o._connect(),o._response._onXHRProgress(o._resetTimers.bind(o)))};S.prototype._connect=function(){var o=this;o._destroyed||(o._response=new ut(o._xhr,o._fetchResponse,o._mode,o._resetTimers.bind(o)),o._response.on("error",function(r){o.emit("error",r)}),o.emit("response",o._response))};S.prototype._write=function(o,r,h){var f=this;f._body.push(o),h()};S.prototype._resetTimers=function(o){var r=this;P.clearTimeout(r._socketTimer),r._socketTimer=null,o?(P.clearTimeout(r._fetchTimer),r._fetchTimer=null):r._socketTimeout&&(r._socketTimer=P.setTimeout(function(){r.emit("timeout")},r._socketTimeout))};S.prototype.abort=S.prototype.destroy=function(o){var r=this;r._destroyed=!0,r._resetTimers(!0),r._response&&(r._response._destroyed=!0),r._xhr?r._xhr.abort():r._fetchAbortController&&r._fetchAbortController.abort(),o&&r.emit("error",o)};S.prototype.end=function(o,r,h){var f=this;typeof o=="function"&&(h=o,o=void 0),ke.Writable.prototype.end.call(f,o,r,h)};S.prototype.setTimeout=function(o,r){var h=this;r&&h.once("timeout",r),h._socketTimeout=o,h._resetTimers(!1)};S.prototype.flushHeaders=function(){};S.prototype.setNoDelay=function(){};S.prototype.setSocketKeepAlive=function(){};var pt=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"],dt=Qe.exports,mt=yt,vt=Object.prototype.hasOwnProperty;function yt(){for(var o={},r=0;r<arguments.length;r++){var h=arguments[r];for(var f in h)vt.call(h,f)&&(o[f]=h[f])}return o}var gt={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"},He={exports:{}},qe={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */qe.exports;(function(o,r){(function(h){var f=r&&!r.nodeType&&r,n=o&&!o.nodeType&&o,g=typeof P=="object"&&P;(g.global===g||g.window===g||g.self===g)&&(h=g);var u,a=2147483647,v=36,T=1,C=26,m=38,A=700,te=72,ae=128,I="-",Oe=/^xn--/,Ee=/[^\x20-\x7E]/,Ue=/[\x2E\u3002\uFF0E\uFF61]/g,Le={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},pe=v-T,M=Math.floor,re=String.fromCharCode,ie;function J(i){throw new RangeError(Le[i])}function de(i,p){for(var y=i.length,b=[];y--;)b[y]=p(i[y]);return b}function be(i,p){var y=i.split("@"),b="";y.length>1&&(b=y[0]+"@",i=y[1]),i=i.replace(Ue,".");var w=i.split("."),U=de(w,p).join(".");return b+U}function Te(i){for(var p=[],y=0,b=i.length,w,U;y<b;)w=i.charCodeAt(y++),w>=55296&&w<=56319&&y<b?(U=i.charCodeAt(y++),(U&64512)==56320?p.push(((w&1023)<<10)+(U&1023)+65536):(p.push(w),y--)):p.push(w);return p}function ue(i){return de(i,function(p){var y="";return p>65535&&(p-=65536,y+=re(p>>>10&1023|55296),p=56320|p&1023),y+=re(p),y}).join("")}function oe(i){return i-48<10?i-22:i-65<26?i-65:i-97<26?i-97:v}function ce(i,p){return i+22+75*(i<26)-((p!=0)<<5)}function ne(i,p,y){var b=0;for(i=y?M(i/A):i>>1,i+=M(i/p);i>pe*C>>1;b+=v)i=M(i/pe);return M(b+(pe+1)*i/(i+m))}function we(i){var p=[],y=i.length,b,w=0,U=ae,q=te,R,N,B,G,L,H,k,W,Q;for(R=i.lastIndexOf(I),R<0&&(R=0),N=0;N<R;++N)i.charCodeAt(N)>=128&&J("not-basic"),p.push(i.charCodeAt(N));for(B=R>0?R+1:0;B<y;){for(G=w,L=1,H=v;B>=y&&J("invalid-input"),k=oe(i.charCodeAt(B++)),(k>=v||k>M((a-w)/L))&&J("overflow"),w+=k*L,W=H<=q?T:H>=q+C?C:H-q,!(k<W);H+=v)Q=v-W,L>M(a/Q)&&J("overflow"),L*=Q;b=p.length+1,q=ne(w-G,b,G==0),M(w/b)>a-U&&J("overflow"),U+=M(w/b),w%=b,p.splice(w++,0,U)}return ue(p)}function Re(i){var p,y,b,w,U,q,R,N,B,G,L,H=[],k,W,Q,me;for(i=Te(i),k=i.length,p=ae,y=0,U=te,q=0;q<k;++q)L=i[q],L<128&&H.push(re(L));for(b=w=H.length,w&&H.push(I);b<k;){for(R=a,q=0;q<k;++q)L=i[q],L>=p&&L<R&&(R=L);for(W=b+1,R-p>M((a-y)/W)&&J("overflow"),y+=(R-p)*W,p=R,q=0;q<k;++q)if(L=i[q],L<p&&++y>a&&J("overflow"),L==p){for(N=y,B=v;G=B<=U?T:B>=U+C?C:B-U,!(N<G);B+=v)me=N-G,Q=v-G,H.push(re(ce(G+me%Q,0))),N=M(me/Q);H.push(re(ce(N,0))),U=ne(y,W,b==w),y=0,++b}++y,++p}return H.join("")}function Pe(i){return be(i,function(p){return Oe.test(p)?we(p.slice(4).toLowerCase()):p})}function Se(i){return be(i,function(p){return Ee.test(p)?"xn--"+Re(p):p})}if(u={version:"1.4.1",ucs2:{decode:Te,encode:ue},decode:we,encode:Re,toASCII:Se,toUnicode:Pe},f&&n)if(o.exports==f)n.exports=u;else for(ie in u)u.hasOwnProperty(ie)&&(f[ie]=u[ie]);else h.punycode=u})(P)})(qe,qe.exports);var _t=qe.exports;(function(o,r){Object.defineProperty(r,"__esModule",{value:!0});var h=_t,f=it;function n(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var g=n(h),u=n(f),a={isString:function(e){return typeof e=="string"},isObject:function(e){return typeof e=="object"&&e!==null},isNull:function(e){return e===null},isNullOrUndefined:function(e){return e==null}},v=g.default,T=a,C=ne,m=Re,A=Pe,te=we,ae=I;function I(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var Oe=/^([a-z0-9.+-]+:)/i,Ee=/:[0-9]*$/,Ue=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Le=["<",">",'"',"`"," ","\r",`
|
|
2
|
+
`," "],pe=["{","}","|","\\","^","`"].concat(Le),M=["'"].concat(pe),re=["%","/","?",";","#"].concat(M),ie=["/","?","#"],J=255,de=/^[+a-z0-9A-Z_-]{0,63}$/,be=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Te={javascript:!0,"javascript:":!0},ue={javascript:!0,"javascript:":!0},oe={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},ce=u.default;function ne(e,s,t){if(e&&T.isObject(e)&&e instanceof I)return e;var l=new I;return l.parse(e,s,t),l}I.prototype.parse=function(e,s,t){if(!T.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var l=e.indexOf("?"),_=l!==-1&&l<e.indexOf("#")?"?":"#",D=e.split(_),j=/\\/g;D[0]=D[0].replace(j,"/"),e=D.join(_);var c=e;if(c=c.trim(),!t&&e.split("#").length===1){var K=Ue.exec(c);if(K)return this.path=c,this.href=c,this.pathname=K[1],K[2]?(this.search=K[2],s?this.query=ce.parse(this.search.substr(1)):this.query=this.search.substr(1)):s&&(this.search="",this.query={}),this}var x=Oe.exec(c);if(x){x=x[0];var fe=x.toLowerCase();this.protocol=fe,c=c.substr(x.length)}if(t||x||c.match(/^\/\/[^@\/]+@[^@\/]+/)){var ve=c.substr(0,2)==="//";ve&&!(x&&ue[x])&&(c=c.substr(2),this.slashes=!0)}if(!ue[x]&&(ve||x&&!oe[x])){for(var F=-1,O=0;O<ie.length;O++){var ee=c.indexOf(ie[O]);ee!==-1&&(F===-1||ee<F)&&(F=ee)}var ye,$;F===-1?$=c.lastIndexOf("@"):$=c.lastIndexOf("@",F),$!==-1&&(ye=c.slice(0,$),c=c.slice($+1),this.auth=decodeURIComponent(ye)),F=-1;for(var O=0;O<re.length;O++){var ee=c.indexOf(re[O]);ee!==-1&&(F===-1||ee<F)&&(F=ee)}F===-1&&(F=c.length),this.host=c.slice(0,F),c=c.slice(F),this.parseHost(),this.hostname=this.hostname||"";var ge=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!ge)for(var d=this.hostname.split(/\./),O=0,E=d.length;O<E;O++){var V=d[O];if(V&&!V.match(de)){for(var z="",X=0,Ie=V.length;X<Ie;X++)V.charCodeAt(X)>127?z+="x":z+=V[X];if(!z.match(de)){var se=d.slice(0,O),Y=d.slice(O+1),le=V.match(be);le&&(se.push(le[1]),Y.unshift(le[2])),Y.length&&(c="/"+Y.join(".")+c),this.hostname=se.join(".");break}}}this.hostname.length>J?this.hostname="":this.hostname=this.hostname.toLowerCase(),ge||(this.hostname=v.toASCII(this.hostname));var Fe=this.port?":"+this.port:"",st=this.hostname||"";this.host=st+Fe,this.href+=this.host,ge&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),c[0]!=="/"&&(c="/"+c))}if(!Te[fe])for(var O=0,E=M.length;O<E;O++){var _e=M[O];if(c.indexOf(_e)!==-1){var Me=encodeURIComponent(_e);Me===_e&&(Me=escape(_e)),c=c.split(_e).join(Me)}}var Ne=c.indexOf("#");Ne!==-1&&(this.hash=c.substr(Ne),c=c.slice(0,Ne));var Ce=c.indexOf("?");if(Ce!==-1?(this.search=c.substr(Ce),this.query=c.substr(Ce+1),s&&(this.query=ce.parse(this.query)),c=c.slice(0,Ce)):s&&(this.search="",this.query={}),c&&(this.pathname=c),oe[fe]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var Fe=this.pathname||"",at=this.search||"";this.path=Fe+at}return this.href=this.format(),this};function we(e){return T.isString(e)&&(e=ne(e)),e instanceof I?e.format():I.prototype.format.call(e)}I.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var s=this.protocol||"",t=this.pathname||"",l=this.hash||"",_=!1,D="";this.host?_=e+this.host:this.hostname&&(_=e+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(_+=":"+this.port)),this.query&&T.isObject(this.query)&&Object.keys(this.query).length&&(D=ce.stringify(this.query));var j=this.search||D&&"?"+D||"";return s&&s.substr(-1)!==":"&&(s+=":"),this.slashes||(!s||oe[s])&&_!==!1?(_="//"+(_||""),t&&t.charAt(0)!=="/"&&(t="/"+t)):_||(_=""),l&&l.charAt(0)!=="#"&&(l="#"+l),j&&j.charAt(0)!=="?"&&(j="?"+j),t=t.replace(/[?#]/g,function(c){return encodeURIComponent(c)}),j=j.replace("#","%23"),s+_+t+j+l};function Re(e,s){return ne(e,!1,!0).resolve(s)}I.prototype.resolve=function(e){return this.resolveObject(ne(e,!1,!0)).format()};function Pe(e,s){return e?ne(e,!1,!0).resolveObject(s):s}I.prototype.resolveObject=function(e){if(T.isString(e)){var s=new I;s.parse(e,!1,!0),e=s}for(var t=new I,l=Object.keys(this),_=0;_<l.length;_++){var D=l[_];t[D]=this[D]}if(t.hash=e.hash,e.href==="")return t.href=t.format(),t;if(e.slashes&&!e.protocol){for(var j=Object.keys(e),c=0;c<j.length;c++){var K=j[c];K!=="protocol"&&(t[K]=e[K])}return oe[t.protocol]&&t.hostname&&!t.pathname&&(t.path=t.pathname="/"),t.href=t.format(),t}if(e.protocol&&e.protocol!==t.protocol){if(!oe[e.protocol]){for(var x=Object.keys(e),fe=0;fe<x.length;fe++){var ve=x[fe];t[ve]=e[ve]}return t.href=t.format(),t}if(t.protocol=e.protocol,!e.host&&!ue[e.protocol]){for(var E=(e.pathname||"").split("/");E.length&&!(e.host=E.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),E[0]!==""&&E.unshift(""),E.length<2&&E.unshift(""),t.pathname=E.join("/")}else t.pathname=e.pathname;if(t.search=e.search,t.query=e.query,t.host=e.host||"",t.auth=e.auth,t.hostname=e.hostname||e.host,t.port=e.port,t.pathname||t.search){var F=t.pathname||"",O=t.search||"";t.path=F+O}return t.slashes=t.slashes||e.slashes,t.href=t.format(),t}var ee=t.pathname&&t.pathname.charAt(0)==="/",ye=e.host||e.pathname&&e.pathname.charAt(0)==="/",$=ye||ee||t.host&&e.pathname,ge=$,d=t.pathname&&t.pathname.split("/")||[],E=e.pathname&&e.pathname.split("/")||[],V=t.protocol&&!oe[t.protocol];if(V&&(t.hostname="",t.port=null,t.host&&(d[0]===""?d[0]=t.host:d.unshift(t.host)),t.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(E[0]===""?E[0]=e.host:E.unshift(e.host)),e.host=null),$=$&&(E[0]===""||d[0]==="")),ye)t.host=e.host||e.host===""?e.host:t.host,t.hostname=e.hostname||e.hostname===""?e.hostname:t.hostname,t.search=e.search,t.query=e.query,d=E;else if(E.length)d||(d=[]),d.pop(),d=d.concat(E),t.search=e.search,t.query=e.query;else if(!T.isNullOrUndefined(e.search)){if(V){t.hostname=t.host=d.shift();var z=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;z&&(t.auth=z.shift(),t.host=t.hostname=z.shift())}return t.search=e.search,t.query=e.query,(!T.isNull(t.pathname)||!T.isNull(t.search))&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.href=t.format(),t}if(!d.length)return t.pathname=null,t.search?t.path="/"+t.search:t.path=null,t.href=t.format(),t;for(var X=d.slice(-1)[0],Ie=(t.host||e.host||d.length>1)&&(X==="."||X==="..")||X==="",se=0,Y=d.length;Y>=0;Y--)X=d[Y],X==="."?d.splice(Y,1):X===".."?(d.splice(Y,1),se++):se&&(d.splice(Y,1),se--);if(!$&&!ge)for(;se--;se)d.unshift("..");$&&d[0]!==""&&(!d[0]||d[0].charAt(0)!=="/")&&d.unshift(""),Ie&&d.join("/").substr(-1)!=="/"&&d.push("");var le=d[0]===""||d[0]&&d[0].charAt(0)==="/";if(V){t.hostname=t.host=le?"":d.length?d.shift():"";var z=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;z&&(t.auth=z.shift(),t.host=t.hostname=z.shift())}return $=$||t.host&&d.length,$&&!le&&d.unshift(""),d.length?t.pathname=d.join("/"):(t.pathname=null,t.path=null),(!T.isNull(t.pathname)||!T.isNull(t.search))&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.auth=e.auth||t.auth,t.slashes=t.slashes||e.slashes,t.href=t.format(),t},I.prototype.parseHost=function(){var e=this.host,s=Ee.exec(e);s&&(s=s[0],s!==":"&&(this.port=s.substr(1)),e=e.substr(0,e.length-s.length)),e&&(this.hostname=e)};function Se(e,s){for(var t=0,l=e.length-1;l>=0;l--){var _=e[l];_==="."?e.splice(l,1):_===".."?(e.splice(l,1),t++):t&&(e.splice(l,1),t--)}if(s)for(;t--;t)e.unshift("..");return e}function i(){for(var e="",s=!1,t=arguments.length-1;t>=-1&&!s;t--){var l=t>=0?arguments[t]:"/";if(typeof l!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!l)continue;e=l+"/"+e,s=l.charAt(0)==="/"}return e=Se(p(e.split("/"),function(_){return!!_}),!s).join("/"),(s?"/":"")+e||"."}function p(e,s){if(e.filter)return e.filter(s);for(var t=[],l=0;l<e.length;l++)s(e[l],l,e)&&t.push(e[l]);return t}var y=function(e){function s(){var l=this||self;return delete e.prototype.__magic__,l}if(typeof globalThis=="object")return globalThis;if(this)return s();e.defineProperty(e.prototype,"__magic__",{configurable:!0,get:s});var t=__magic__;return t}(Object),b=te,w=C,U=m,q=ae,R=y.URL,N=y.URLSearchParams,B=/%/g,G=/\\/g,L=/\n/g,H=/\r/g,k=/\t/g,W=47;function Q(e){var s=e??null;return!!(s!==null&&(s!=null&&s.href)&&(s!=null&&s.origin))}function me(e){if(e.hostname!=="")throw new TypeError('File URL host must be "localhost" or empty on browser');for(var s=e.pathname,t=0;t<s.length;t++)if(s[t]==="%"){var l=s.codePointAt(t+2)|32;if(s[t+1]==="2"&&l===102)throw new TypeError("File URL path must not include encoded / characters")}return decodeURIComponent(s)}function nt(e){return e.includes("%")&&(e=e.replace(B,"%25")),e.includes("\\")&&(e=e.replace(G,"%5C")),e.includes(`
|
|
3
|
+
`)&&(e=e.replace(L,"%0A")),e.includes("\r")&&(e=e.replace(H,"%0D")),e.includes(" ")&&(e=e.replace(k,"%09")),e}var De=function(s){if(typeof s>"u")throw new TypeError('The "domain" argument must be specified');return new R("http://"+s).hostname},Be=function(s){if(typeof s>"u")throw new TypeError('The "domain" argument must be specified');return new R("http://"+s).hostname},Ge=function(s){var t=new R("file://"),l=i(s),_=s.charCodeAt(s.length-1);return _===W&&l[l.length-1]!=="/"&&(l+="/"),t.pathname=nt(l),t},ze=function(s){if(!Q(s)&&typeof s!="string")throw new TypeError('The "path" argument must be of type string or an instance of URL. Received type '+typeof s+" ("+s+")");var t=new R(s);if(t.protocol!=="file:")throw new TypeError("The URL must be of scheme file");return me(t)},Xe=function(s,t){var l,_,D;if(t===void 0&&(t={}),!(s instanceof R))return b(s);if(typeof t!="object"||t===null)throw new TypeError('The "options" argument must be of type object.');var j=(l=t.auth)!=null?l:!0,c=(_=t.fragment)!=null?_:!0,K=(D=t.search)!=null?D:!0,x=new R(s.toString());return j||(x.username="",x.password=""),c||(x.hash=""),K||(x.search=""),x.toString()},We={format:Xe,parse:w,resolve:U,resolveObject:A,Url:q,URL:R,URLSearchParams:N,domainToASCII:De,domainToUnicode:Be,pathToFileURL:Ge,fileURLToPath:ze};r.URL=R,r.URLSearchParams=N,r.Url=q,r.default=We,r.domainToASCII=De,r.domainToUnicode=Be,r.fileURLToPath=ze,r.format=Xe,r.parse=w,r.pathToFileURL=Ge,r.resolve=U,r.resolveObject=A,r=o.exports=We})(He,He.exports);var rt=He.exports;(function(o){var r=dt,h=xe,f=mt,n=gt,g=rt,u=o;u.request=function(a,v){typeof a=="string"?a=g.parse(a):a=f(a);var T=P.location.protocol.search(/^https?:$/)===-1?"http:":"",C=a.protocol||T,m=a.hostname||a.host,A=a.port,te=a.path||"/";m&&m.indexOf(":")!==-1&&(m="["+m+"]"),a.url=(m?C+"//"+m:"")+(A?":"+A:"")+te,a.method=(a.method||"GET").toUpperCase(),a.headers=a.headers||{};var ae=new r(a);return v&&ae.on("response",v),ae},u.get=function(v,T){var C=u.request(v,T);return C.end(),C},u.ClientRequest=r,u.IncomingMessage=h.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=n,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]})(Je);var ot={exports:{}};(function(o){var r=Je,h=rt,f=o.exports;for(var n in r)r.hasOwnProperty(n)&&(f[n]=r[n]);f.request=function(u,a){return u=g(u),r.request.call(this,u,a)},f.get=function(u,a){return u=g(u),r.get.call(this,u,a)};function g(u){if(typeof u=="string"&&(u=h.parse(u)),u.protocol||(u.protocol="https:"),u.protocol!=="https:")throw new Error('Protocol "'+u.protocol+'" not supported. Expected "https:"');return u}})(ot);var Tt=ot.exports;export{Tt as h,Je as s,rt as u};
|