diff --git a/CNAME b/CNAME index 5c9dd452..8ab7e579 100644 --- a/CNAME +++ b/CNAME @@ -1 +1 @@ -safe2link.xyz \ No newline at end of file +safelink.zenguard.xyz \ No newline at end of file diff --git a/assets/ccip-9e679818.js b/assets/ccip-9e679818.js new file mode 100644 index 00000000..70917b23 --- /dev/null +++ b/assets/ccip-9e679818.js @@ -0,0 +1 @@ +import{B as p,g as w,s as b,i as h,I as m,d as O,c as L,a as E,e as x,H as y,b as M}from"./index-fb499c6a.js";class R extends p{constructor({callbackSelector:e,cause:t,data:n,extraData:c,sender:u,urls:r}){var i;super(t.shortMessage||"An error occurred while fetching for an offchain result.",{cause:t,metaMessages:[...t.metaMessages||[],(i=t.metaMessages)!=null&&i.length?"":[],"Offchain Gateway Call:",r&&[" Gateway URL(s):",...r.map(d=>` ${w(d)}`)],` Sender: ${u}`,` Data: ${n}`,` Callback selector: ${e}`,` Extra data: ${c}`].flat()}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupError"})}}class $ extends p{constructor({result:e,url:t}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${w(t)}`,`Response: ${b(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupResponseMalformedError"})}}class S extends p{constructor({sender:e,to:t}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${t}`,`OffchainLookup sender address: ${e}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupSenderMismatchError"})}}function A(a,e){if(!h(a,{strict:!1}))throw new m({address:a});if(!h(e,{strict:!1}))throw new m({address:e});return a.toLowerCase()===e.toLowerCase()}const P="0x556f1830",q={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]};async function j(a,{blockNumber:e,blockTag:t,data:n,to:c}){const{args:u}=O({data:n,abi:[q]}),[r,i,d,s,o]=u,{ccipRead:f}=a,g=f&&typeof(f==null?void 0:f.request)=="function"?f.request:v;try{if(!A(c,r))throw new S({sender:r,to:c});const l=await g({data:d,sender:r,urls:i}),{data:k}=await L(a,{blockNumber:e,blockTag:t,data:E([s,x([{type:"bytes"},{type:"bytes"}],[l,o])]),to:c});return k}catch(l){throw new R({callbackSelector:s,cause:l,data:n,extraData:o,sender:r,urls:i})}}async function v({data:a,sender:e,urls:t}){var c;let n=new Error("An unknown error occurred.");for(let u=0;u - - - - - - - - - - - - - - - - - - - - - - diff --git a/assets/eure-2379d6fa.svg b/assets/eure-2379d6fa.svg new file mode 100644 index 00000000..14f8618f --- /dev/null +++ b/assets/eure-2379d6fa.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/assets/favicon-17ab2fb7.svg b/assets/favicon-17ab2fb7.svg deleted file mode 100644 index 7dff201e..00000000 --- a/assets/favicon-17ab2fb7.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/assets/favicon-23148f3f.ico b/assets/favicon-23148f3f.ico new file mode 100644 index 00000000..94f9cdcd Binary files /dev/null and b/assets/favicon-23148f3f.ico differ diff --git a/assets/index-96283bad.js b/assets/index-96283bad.js deleted file mode 100644 index b2345820..00000000 --- a/assets/index-96283bad.js +++ /dev/null @@ -1,207 +0,0 @@ -var rW=Object.defineProperty;var nW=(t,e,r)=>e in t?rW(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Ie=(t,e,r)=>(nW(t,typeof e!="symbol"?e+"":e,r),r),Zw=(t,e,r)=>{if(!e.has(t))throw TypeError("Cannot "+r)};var X=(t,e,r)=>(Zw(t,e,"read from private field"),r?r.call(t):e.get(t)),Te=(t,e,r)=>{if(e.has(t))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(t):e.set(t,r)},fe=(t,e,r,n)=>(Zw(t,e,"write to private field"),n?n.call(t,r):e.set(t,r),r);var R1=(t,e,r,n)=>({set _(s){fe(t,e,s,r)},get _(){return X(t,e,n)}}),Ge=(t,e,r)=>(Zw(t,e,"access private method"),r);function JB(t,e){for(var r=0;rn[s]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))n(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function r(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(s){if(s.ep)return;s.ep=!0;const i=r(s);fetch(s.href,i)}})();var Ke=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Qs(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function iW(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var s=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:function(){return t[n]}})}),r}var Ln={},h5={};h5.byteLength=aW;h5.toByteArray=cW;h5.fromByteArray=hW;var xa=[],As=[],sW=typeof Uint8Array<"u"?Uint8Array:Array,Qw="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var Vl=0,oW=Qw.length;Vl0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");r===-1&&(r=e);var n=r===e?0:4-r%4;return[r,n]}function aW(t){var e=ZB(t),r=e[0],n=e[1];return(r+n)*3/4-n}function fW(t,e,r){return(e+r)*3/4-r}function cW(t){var e,r=ZB(t),n=r[0],s=r[1],i=new sW(fW(t,n,s)),o=0,f=s>0?n-4:n,h;for(h=0;h>16&255,i[o++]=e>>8&255,i[o++]=e&255;return s===2&&(e=As[t.charCodeAt(h)]<<2|As[t.charCodeAt(h+1)]>>4,i[o++]=e&255),s===1&&(e=As[t.charCodeAt(h)]<<10|As[t.charCodeAt(h+1)]<<4|As[t.charCodeAt(h+2)]>>2,i[o++]=e>>8&255,i[o++]=e&255),i}function uW(t){return xa[t>>18&63]+xa[t>>12&63]+xa[t>>6&63]+xa[t&63]}function lW(t,e,r){for(var n,s=[],i=e;if?f:o+i));return n===1?(e=t[r-1],s.push(xa[e>>2]+xa[e<<4&63]+"==")):n===2&&(e=(t[r-2]<<8)+t[r-1],s.push(xa[e>>10]+xa[e>>4&63]+xa[e<<2&63]+"=")),s.join("")}var wA={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */wA.read=function(t,e,r,n,s){var i,o,f=s*8-n-1,h=(1<>1,b=-7,v=r?s-1:0,E=r?-1:1,_=t[e+v];for(v+=E,i=_&(1<<-b)-1,_>>=-b,b+=f;b>0;i=i*256+t[e+v],v+=E,b-=8);for(o=i&(1<<-b)-1,i>>=-b,b+=n;b>0;o=o*256+t[e+v],v+=E,b-=8);if(i===0)i=1-p;else{if(i===h)return o?NaN:(_?-1:1)*(1/0);o=o+Math.pow(2,n),i=i-p}return(_?-1:1)*o*Math.pow(2,i-n)};wA.write=function(t,e,r,n,s,i){var o,f,h,p=i*8-s-1,b=(1<>1,E=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,_=n?0:i-1,S=n?1:-1,P=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(f=isNaN(e)?1:0,o=b):(o=Math.floor(Math.log(e)/Math.LN2),e*(h=Math.pow(2,-o))<1&&(o--,h*=2),o+v>=1?e+=E/h:e+=E*Math.pow(2,1-v),e*h>=2&&(o++,h/=2),o+v>=b?(f=0,o=b):o+v>=1?(f=(e*h-1)*Math.pow(2,s),o=o+v):(f=e*Math.pow(2,v-1)*Math.pow(2,s),o=0));s>=8;t[r+_]=f&255,_+=S,f/=256,s-=8);for(o=o<0;t[r+_]=o&255,_+=S,o/=256,p-=8);t[r+_-S]|=P*128};/*! - * The buffer module from node.js, for the browser. - * - * @author Feross Aboukhadijeh - * @license MIT - */(function(t){const e=h5,r=wA,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=f,t.SlowBuffer=T,t.INSPECT_MAX_BYTES=50;const s=2147483647;t.kMaxLength=s,f.TYPED_ARRAY_SUPPORT=i(),!f.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function i(){try{const j=new Uint8Array(1),O={foo:function(){return 42}};return Object.setPrototypeOf(O,Uint8Array.prototype),Object.setPrototypeOf(j,O),j.foo()===42}catch{return!1}}Object.defineProperty(f.prototype,"parent",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.buffer}}),Object.defineProperty(f.prototype,"offset",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.byteOffset}});function o(j){if(j>s)throw new RangeError('The value "'+j+'" is invalid for option "size"');const O=new Uint8Array(j);return Object.setPrototypeOf(O,f.prototype),O}function f(j,O,F){if(typeof j=="number"){if(typeof O=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return v(j)}return h(j,O,F)}f.poolSize=8192;function h(j,O,F){if(typeof j=="string")return E(j,O);if(ArrayBuffer.isView(j))return S(j);if(j==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof j);if(be(j,ArrayBuffer)||j&&be(j.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(be(j,SharedArrayBuffer)||j&&be(j.buffer,SharedArrayBuffer)))return P(j,O,F);if(typeof j=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const W=j.valueOf&&j.valueOf();if(W!=null&&W!==j)return f.from(W,O,F);const te=I(j);if(te)return te;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof j[Symbol.toPrimitive]=="function")return f.from(j[Symbol.toPrimitive]("string"),O,F);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof j)}f.from=function(j,O,F){return h(j,O,F)},Object.setPrototypeOf(f.prototype,Uint8Array.prototype),Object.setPrototypeOf(f,Uint8Array);function p(j){if(typeof j!="number")throw new TypeError('"size" argument must be of type number');if(j<0)throw new RangeError('The value "'+j+'" is invalid for option "size"')}function b(j,O,F){return p(j),j<=0?o(j):O!==void 0?typeof F=="string"?o(j).fill(O,F):o(j).fill(O):o(j)}f.alloc=function(j,O,F){return b(j,O,F)};function v(j){return p(j),o(j<0?0:C(j)|0)}f.allocUnsafe=function(j){return v(j)},f.allocUnsafeSlow=function(j){return v(j)};function E(j,O){if((typeof O!="string"||O==="")&&(O="utf8"),!f.isEncoding(O))throw new TypeError("Unknown encoding: "+O);const F=B(j,O)|0;let W=o(F);const te=W.write(j,O);return te!==F&&(W=W.slice(0,te)),W}function _(j){const O=j.length<0?0:C(j.length)|0,F=o(O);for(let W=0;W=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return j|0}function T(j){return+j!=j&&(j=0),f.alloc(+j)}f.isBuffer=function(O){return O!=null&&O._isBuffer===!0&&O!==f.prototype},f.compare=function(O,F){if(be(O,Uint8Array)&&(O=f.from(O,O.offset,O.byteLength)),be(F,Uint8Array)&&(F=f.from(F,F.offset,F.byteLength)),!f.isBuffer(O)||!f.isBuffer(F))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(O===F)return 0;let W=O.length,te=F.length;for(let le=0,ne=Math.min(W,te);lete.length?(f.isBuffer(ne)||(ne=f.from(ne)),ne.copy(te,le)):Uint8Array.prototype.set.call(te,ne,le);else if(f.isBuffer(ne))ne.copy(te,le);else throw new TypeError('"list" argument must be an Array of Buffers');le+=ne.length}return te};function B(j,O){if(f.isBuffer(j))return j.length;if(ArrayBuffer.isView(j)||be(j,ArrayBuffer))return j.byteLength;if(typeof j!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof j);const F=j.length,W=arguments.length>2&&arguments[2]===!0;if(!W&&F===0)return 0;let te=!1;for(;;)switch(O){case"ascii":case"latin1":case"binary":return F;case"utf8":case"utf-8":return je(j).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F*2;case"hex":return F>>>1;case"base64":return Qe(j).length;default:if(te)return W?-1:je(j).length;O=(""+O).toLowerCase(),te=!0}}f.byteLength=B;function N(j,O,F){let W=!1;if((O===void 0||O<0)&&(O=0),O>this.length||((F===void 0||F>this.length)&&(F=this.length),F<=0)||(F>>>=0,O>>>=0,F<=O))return"";for(j||(j="utf8");;)switch(j){case"hex":return y(this,O,F);case"utf8":case"utf-8":return l(this,O,F);case"ascii":return x(this,O,F);case"latin1":case"binary":return A(this,O,F);case"base64":return u(this,O,F);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return c(this,O,F);default:if(W)throw new TypeError("Unknown encoding: "+j);j=(j+"").toLowerCase(),W=!0}}f.prototype._isBuffer=!0;function $(j,O,F){const W=j[O];j[O]=j[F],j[F]=W}f.prototype.swap16=function(){const O=this.length;if(O%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let F=0;FF&&(O+=" ... "),""},n&&(f.prototype[n]=f.prototype.inspect),f.prototype.compare=function(O,F,W,te,le){if(be(O,Uint8Array)&&(O=f.from(O,O.offset,O.byteLength)),!f.isBuffer(O))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof O);if(F===void 0&&(F=0),W===void 0&&(W=O?O.length:0),te===void 0&&(te=0),le===void 0&&(le=this.length),F<0||W>O.length||te<0||le>this.length)throw new RangeError("out of range index");if(te>=le&&F>=W)return 0;if(te>=le)return-1;if(F>=W)return 1;if(F>>>=0,W>>>=0,te>>>=0,le>>>=0,this===O)return 0;let ne=le-te,pe=W-F;const Ye=Math.min(ne,pe),de=this.slice(te,le),ve=O.slice(F,W);for(let Je=0;Je2147483647?F=2147483647:F<-2147483648&&(F=-2147483648),F=+F,ot(F)&&(F=te?0:j.length-1),F<0&&(F=j.length+F),F>=j.length){if(te)return-1;F=j.length-1}else if(F<0)if(te)F=0;else return-1;if(typeof O=="string"&&(O=f.from(O,W)),f.isBuffer(O))return O.length===0?-1:J(j,O,F,W,te);if(typeof O=="number")return O=O&255,typeof Uint8Array.prototype.indexOf=="function"?te?Uint8Array.prototype.indexOf.call(j,O,F):Uint8Array.prototype.lastIndexOf.call(j,O,F):J(j,[O],F,W,te);throw new TypeError("val must be string, number or Buffer")}function J(j,O,F,W,te){let le=1,ne=j.length,pe=O.length;if(W!==void 0&&(W=String(W).toLowerCase(),W==="ucs2"||W==="ucs-2"||W==="utf16le"||W==="utf-16le")){if(j.length<2||O.length<2)return-1;le=2,ne/=2,pe/=2,F/=2}function Ye(ve,Je){return le===1?ve[Je]:ve.readUInt16BE(Je*le)}let de;if(te){let ve=-1;for(de=F;dene&&(F=ne-pe),de=F;de>=0;de--){let ve=!0;for(let Je=0;Jete&&(W=te)):W=te;const le=O.length;W>le/2&&(W=le/2);let ne;for(ne=0;ne>>0,isFinite(W)?(W=W>>>0,te===void 0&&(te="utf8")):(te=W,W=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const le=this.length-F;if((W===void 0||W>le)&&(W=le),O.length>0&&(W<0||F<0)||F>this.length)throw new RangeError("Attempt to write outside buffer bounds");te||(te="utf8");let ne=!1;for(;;)switch(te){case"hex":return Q(this,O,F,W);case"utf8":case"utf-8":return K(this,O,F,W);case"ascii":case"latin1":case"binary":return se(this,O,F,W);case"base64":return w(this,O,F,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return a(this,O,F,W);default:if(ne)throw new TypeError("Unknown encoding: "+te);te=(""+te).toLowerCase(),ne=!0}},f.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function u(j,O,F){return O===0&&F===j.length?e.fromByteArray(j):e.fromByteArray(j.slice(O,F))}function l(j,O,F){F=Math.min(j.length,F);const W=[];let te=O;for(;te239?4:le>223?3:le>191?2:1;if(te+pe<=F){let Ye,de,ve,Je;switch(pe){case 1:le<128&&(ne=le);break;case 2:Ye=j[te+1],(Ye&192)===128&&(Je=(le&31)<<6|Ye&63,Je>127&&(ne=Je));break;case 3:Ye=j[te+1],de=j[te+2],(Ye&192)===128&&(de&192)===128&&(Je=(le&15)<<12|(Ye&63)<<6|de&63,Je>2047&&(Je<55296||Je>57343)&&(ne=Je));break;case 4:Ye=j[te+1],de=j[te+2],ve=j[te+3],(Ye&192)===128&&(de&192)===128&&(ve&192)===128&&(Je=(le&15)<<18|(Ye&63)<<12|(de&63)<<6|ve&63,Je>65535&&Je<1114112&&(ne=Je))}}ne===null?(ne=65533,pe=1):ne>65535&&(ne-=65536,W.push(ne>>>10&1023|55296),ne=56320|ne&1023),W.push(ne),te+=pe}return m(W)}const d=4096;function m(j){const O=j.length;if(O<=d)return String.fromCharCode.apply(String,j);let F="",W=0;for(;WW)&&(F=W);let te="";for(let le=O;leW&&(O=W),F<0?(F+=W,F<0&&(F=0)):F>W&&(F=W),FF)throw new RangeError("Trying to access beyond buffer length")}f.prototype.readUintLE=f.prototype.readUIntLE=function(O,F,W){O=O>>>0,F=F>>>0,W||g(O,F,this.length);let te=this[O],le=1,ne=0;for(;++ne>>0,F=F>>>0,W||g(O,F,this.length);let te=this[O+--F],le=1;for(;F>0&&(le*=256);)te+=this[O+--F]*le;return te},f.prototype.readUint8=f.prototype.readUInt8=function(O,F){return O=O>>>0,F||g(O,1,this.length),this[O]},f.prototype.readUint16LE=f.prototype.readUInt16LE=function(O,F){return O=O>>>0,F||g(O,2,this.length),this[O]|this[O+1]<<8},f.prototype.readUint16BE=f.prototype.readUInt16BE=function(O,F){return O=O>>>0,F||g(O,2,this.length),this[O]<<8|this[O+1]},f.prototype.readUint32LE=f.prototype.readUInt32LE=function(O,F){return O=O>>>0,F||g(O,4,this.length),(this[O]|this[O+1]<<8|this[O+2]<<16)+this[O+3]*16777216},f.prototype.readUint32BE=f.prototype.readUInt32BE=function(O,F){return O=O>>>0,F||g(O,4,this.length),this[O]*16777216+(this[O+1]<<16|this[O+2]<<8|this[O+3])},f.prototype.readBigUInt64LE=xe(function(O){O=O>>>0,ee(O,"offset");const F=this[O],W=this[O+7];(F===void 0||W===void 0)&&re(O,this.length-8);const te=F+this[++O]*2**8+this[++O]*2**16+this[++O]*2**24,le=this[++O]+this[++O]*2**8+this[++O]*2**16+W*2**24;return BigInt(te)+(BigInt(le)<>>0,ee(O,"offset");const F=this[O],W=this[O+7];(F===void 0||W===void 0)&&re(O,this.length-8);const te=F*2**24+this[++O]*2**16+this[++O]*2**8+this[++O],le=this[++O]*2**24+this[++O]*2**16+this[++O]*2**8+W;return(BigInt(te)<>>0,F=F>>>0,W||g(O,F,this.length);let te=this[O],le=1,ne=0;for(;++ne=le&&(te-=Math.pow(2,8*F)),te},f.prototype.readIntBE=function(O,F,W){O=O>>>0,F=F>>>0,W||g(O,F,this.length);let te=F,le=1,ne=this[O+--te];for(;te>0&&(le*=256);)ne+=this[O+--te]*le;return le*=128,ne>=le&&(ne-=Math.pow(2,8*F)),ne},f.prototype.readInt8=function(O,F){return O=O>>>0,F||g(O,1,this.length),this[O]&128?(255-this[O]+1)*-1:this[O]},f.prototype.readInt16LE=function(O,F){O=O>>>0,F||g(O,2,this.length);const W=this[O]|this[O+1]<<8;return W&32768?W|4294901760:W},f.prototype.readInt16BE=function(O,F){O=O>>>0,F||g(O,2,this.length);const W=this[O+1]|this[O]<<8;return W&32768?W|4294901760:W},f.prototype.readInt32LE=function(O,F){return O=O>>>0,F||g(O,4,this.length),this[O]|this[O+1]<<8|this[O+2]<<16|this[O+3]<<24},f.prototype.readInt32BE=function(O,F){return O=O>>>0,F||g(O,4,this.length),this[O]<<24|this[O+1]<<16|this[O+2]<<8|this[O+3]},f.prototype.readBigInt64LE=xe(function(O){O=O>>>0,ee(O,"offset");const F=this[O],W=this[O+7];(F===void 0||W===void 0)&&re(O,this.length-8);const te=this[O+4]+this[O+5]*2**8+this[O+6]*2**16+(W<<24);return(BigInt(te)<>>0,ee(O,"offset");const F=this[O],W=this[O+7];(F===void 0||W===void 0)&&re(O,this.length-8);const te=(F<<24)+this[++O]*2**16+this[++O]*2**8+this[++O];return(BigInt(te)<>>0,F||g(O,4,this.length),r.read(this,O,!0,23,4)},f.prototype.readFloatBE=function(O,F){return O=O>>>0,F||g(O,4,this.length),r.read(this,O,!1,23,4)},f.prototype.readDoubleLE=function(O,F){return O=O>>>0,F||g(O,8,this.length),r.read(this,O,!0,52,8)},f.prototype.readDoubleBE=function(O,F){return O=O>>>0,F||g(O,8,this.length),r.read(this,O,!1,52,8)};function M(j,O,F,W,te,le){if(!f.isBuffer(j))throw new TypeError('"buffer" argument must be a Buffer instance');if(O>te||Oj.length)throw new RangeError("Index out of range")}f.prototype.writeUintLE=f.prototype.writeUIntLE=function(O,F,W,te){if(O=+O,F=F>>>0,W=W>>>0,!te){const pe=Math.pow(2,8*W)-1;M(this,O,F,W,pe,0)}let le=1,ne=0;for(this[F]=O&255;++ne>>0,W=W>>>0,!te){const pe=Math.pow(2,8*W)-1;M(this,O,F,W,pe,0)}let le=W-1,ne=1;for(this[F+le]=O&255;--le>=0&&(ne*=256);)this[F+le]=O/ne&255;return F+W},f.prototype.writeUint8=f.prototype.writeUInt8=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,1,255,0),this[F]=O&255,F+1},f.prototype.writeUint16LE=f.prototype.writeUInt16LE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,2,65535,0),this[F]=O&255,this[F+1]=O>>>8,F+2},f.prototype.writeUint16BE=f.prototype.writeUInt16BE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,2,65535,0),this[F]=O>>>8,this[F+1]=O&255,F+2},f.prototype.writeUint32LE=f.prototype.writeUInt32LE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,4,4294967295,0),this[F+3]=O>>>24,this[F+2]=O>>>16,this[F+1]=O>>>8,this[F]=O&255,F+4},f.prototype.writeUint32BE=f.prototype.writeUInt32BE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,4,4294967295,0),this[F]=O>>>24,this[F+1]=O>>>16,this[F+2]=O>>>8,this[F+3]=O&255,F+4};function R(j,O,F,W,te){z(O,W,te,j,F,7);let le=Number(O&BigInt(4294967295));j[F++]=le,le=le>>8,j[F++]=le,le=le>>8,j[F++]=le,le=le>>8,j[F++]=le;let ne=Number(O>>BigInt(32)&BigInt(4294967295));return j[F++]=ne,ne=ne>>8,j[F++]=ne,ne=ne>>8,j[F++]=ne,ne=ne>>8,j[F++]=ne,F}function L(j,O,F,W,te){z(O,W,te,j,F,7);let le=Number(O&BigInt(4294967295));j[F+7]=le,le=le>>8,j[F+6]=le,le=le>>8,j[F+5]=le,le=le>>8,j[F+4]=le;let ne=Number(O>>BigInt(32)&BigInt(4294967295));return j[F+3]=ne,ne=ne>>8,j[F+2]=ne,ne=ne>>8,j[F+1]=ne,ne=ne>>8,j[F]=ne,F+8}f.prototype.writeBigUInt64LE=xe(function(O,F=0){return R(this,O,F,BigInt(0),BigInt("0xffffffffffffffff"))}),f.prototype.writeBigUInt64BE=xe(function(O,F=0){return L(this,O,F,BigInt(0),BigInt("0xffffffffffffffff"))}),f.prototype.writeIntLE=function(O,F,W,te){if(O=+O,F=F>>>0,!te){const Ye=Math.pow(2,8*W-1);M(this,O,F,W,Ye-1,-Ye)}let le=0,ne=1,pe=0;for(this[F]=O&255;++le>0)-pe&255;return F+W},f.prototype.writeIntBE=function(O,F,W,te){if(O=+O,F=F>>>0,!te){const Ye=Math.pow(2,8*W-1);M(this,O,F,W,Ye-1,-Ye)}let le=W-1,ne=1,pe=0;for(this[F+le]=O&255;--le>=0&&(ne*=256);)O<0&&pe===0&&this[F+le+1]!==0&&(pe=1),this[F+le]=(O/ne>>0)-pe&255;return F+W},f.prototype.writeInt8=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,1,127,-128),O<0&&(O=255+O+1),this[F]=O&255,F+1},f.prototype.writeInt16LE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,2,32767,-32768),this[F]=O&255,this[F+1]=O>>>8,F+2},f.prototype.writeInt16BE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,2,32767,-32768),this[F]=O>>>8,this[F+1]=O&255,F+2},f.prototype.writeInt32LE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,4,2147483647,-2147483648),this[F]=O&255,this[F+1]=O>>>8,this[F+2]=O>>>16,this[F+3]=O>>>24,F+4},f.prototype.writeInt32BE=function(O,F,W){return O=+O,F=F>>>0,W||M(this,O,F,4,2147483647,-2147483648),O<0&&(O=4294967295+O+1),this[F]=O>>>24,this[F+1]=O>>>16,this[F+2]=O>>>8,this[F+3]=O&255,F+4},f.prototype.writeBigInt64LE=xe(function(O,F=0){return R(this,O,F,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),f.prototype.writeBigInt64BE=xe(function(O,F=0){return L(this,O,F,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function k(j,O,F,W,te,le){if(F+W>j.length)throw new RangeError("Index out of range");if(F<0)throw new RangeError("Index out of range")}function D(j,O,F,W,te){return O=+O,F=F>>>0,te||k(j,O,F,4),r.write(j,O,F,W,23,4),F+4}f.prototype.writeFloatLE=function(O,F,W){return D(this,O,F,!0,W)},f.prototype.writeFloatBE=function(O,F,W){return D(this,O,F,!1,W)};function U(j,O,F,W,te){return O=+O,F=F>>>0,te||k(j,O,F,8),r.write(j,O,F,W,52,8),F+8}f.prototype.writeDoubleLE=function(O,F,W){return U(this,O,F,!0,W)},f.prototype.writeDoubleBE=function(O,F,W){return U(this,O,F,!1,W)},f.prototype.copy=function(O,F,W,te){if(!f.isBuffer(O))throw new TypeError("argument should be a Buffer");if(W||(W=0),!te&&te!==0&&(te=this.length),F>=O.length&&(F=O.length),F||(F=0),te>0&&te=this.length)throw new RangeError("Index out of range");if(te<0)throw new RangeError("sourceEnd out of bounds");te>this.length&&(te=this.length),O.length-F>>0,W=W===void 0?this.length:W>>>0,O||(O=0);let le;if(typeof O=="number")for(le=F;le2**32?te=Y(String(F)):typeof F=="bigint"&&(te=String(F),(F>BigInt(2)**BigInt(32)||F<-(BigInt(2)**BigInt(32)))&&(te=Y(te)),te+="n"),W+=` It must be ${O}. Received ${te}`,W},RangeError);function Y(j){let O="",F=j.length;const W=j[0]==="-"?1:0;for(;F>=W+4;F-=3)O=`_${j.slice(F-3,F)}${O}`;return`${j.slice(0,F)}${O}`}function q(j,O,F){ee(O,"offset"),(j[O]===void 0||j[O+F]===void 0)&&re(O,j.length-(F+1))}function z(j,O,F,W,te,le){if(j>F||j3?O===0||O===BigInt(0)?pe=`>= 0${ne} and < 2${ne} ** ${(le+1)*8}${ne}`:pe=`>= -(2${ne} ** ${(le+1)*8-1}${ne}) and < 2 ** ${(le+1)*8-1}${ne}`:pe=`>= ${O}${ne} and <= ${F}${ne}`,new V.ERR_OUT_OF_RANGE("value",pe,j)}q(W,te,le)}function ee(j,O){if(typeof j!="number")throw new V.ERR_INVALID_ARG_TYPE(O,"number",j)}function re(j,O,F){throw Math.floor(j)!==j?(ee(j,F),new V.ERR_OUT_OF_RANGE(F||"offset","an integer",j)):O<0?new V.ERR_BUFFER_OUT_OF_BOUNDS:new V.ERR_OUT_OF_RANGE(F||"offset",`>= ${F?1:0} and <= ${O}`,j)}const ie=/[^+/0-9A-Za-z-_]/g;function ae(j){if(j=j.split("=")[0],j=j.trim().replace(ie,""),j.length<2)return"";for(;j.length%4!==0;)j=j+"=";return j}function je(j,O){O=O||1/0;let F;const W=j.length;let te=null;const le=[];for(let ne=0;ne55295&&F<57344){if(!te){if(F>56319){(O-=3)>-1&&le.push(239,191,189);continue}else if(ne+1===W){(O-=3)>-1&&le.push(239,191,189);continue}te=F;continue}if(F<56320){(O-=3)>-1&&le.push(239,191,189),te=F;continue}F=(te-55296<<10|F-56320)+65536}else te&&(O-=3)>-1&&le.push(239,191,189);if(te=null,F<128){if((O-=1)<0)break;le.push(F)}else if(F<2048){if((O-=2)<0)break;le.push(F>>6|192,F&63|128)}else if(F<65536){if((O-=3)<0)break;le.push(F>>12|224,F>>6&63|128,F&63|128)}else if(F<1114112){if((O-=4)<0)break;le.push(F>>18|240,F>>12&63|128,F>>6&63|128,F&63|128)}else throw new Error("Invalid code point")}return le}function he(j){const O=[];for(let F=0;F>8,te=F%256,le.push(te),le.push(W);return le}function Qe(j){return e.toByteArray(ae(j))}function ge(j,O,F,W){let te;for(te=0;te=O.length||te>=j.length);++te)O[te+F]=j[te];return te}function be(j,O){return j instanceof O||j!=null&&j.constructor!=null&&j.constructor.name!=null&&j.constructor.name===O.name}function ot(j){return j!==j}const ye=function(){const j="0123456789abcdef",O=new Array(256);for(let F=0;F<16;++F){const W=F*16;for(let te=0;te<16;++te)O[W+te]=j[F]+j[te]}return O}();function xe(j){return typeof BigInt>"u"?at:j}function at(){throw new Error("BigInt not supported")}})(Ln);var QB={exports:{}},Zr=QB.exports={},ua,la;function v4(){throw new Error("setTimeout has not been defined")}function x4(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?ua=setTimeout:ua=v4}catch{ua=v4}try{typeof clearTimeout=="function"?la=clearTimeout:la=x4}catch{la=x4}})();function YB(t){if(ua===setTimeout)return setTimeout(t,0);if((ua===v4||!ua)&&setTimeout)return ua=setTimeout,setTimeout(t,0);try{return ua(t,0)}catch{try{return ua.call(null,t,0)}catch{return ua.call(this,t,0)}}}function dW(t){if(la===clearTimeout)return clearTimeout(t);if((la===x4||!la)&&clearTimeout)return la=clearTimeout,clearTimeout(t);try{return la(t)}catch{try{return la.call(null,t)}catch{return la.call(this,t)}}}var wf=[],Fh=!1,ou,lv=-1;function pW(){!Fh||!ou||(Fh=!1,ou.length?wf=ou.concat(wf):lv=-1,wf.length&&XB())}function XB(){if(!Fh){var t=YB(pW);Fh=!0;for(var e=wf.length;e;){for(ou=wf,wf=[];++lv1)for(var r=1;r>>1,M=A[g];if(0>>1;gs(k,c))Ds(U,k)?(A[g]=U,A[D]=c,g=D):(A[g]=k,A[L]=c,g=L);else if(Ds(U,c))A[g]=U,A[D]=c,g=D;else break e}}return y}function s(A,y){var c=A.sortIndex-y.sortIndex;return c!==0?c:A.id-y.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;t.unstable_now=function(){return i.now()}}else{var o=Date,f=o.now();t.unstable_now=function(){return o.now()-f}}var h=[],p=[],b=1,v=null,E=3,_=!1,S=!1,P=!1,I=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,T=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function B(A){for(var y=r(p);y!==null;){if(y.callback===null)n(p);else if(y.startTime<=A)n(p),y.sortIndex=y.expirationTime,e(h,y);else break;y=r(p)}}function N(A){if(P=!1,B(A),!S)if(r(h)!==null)S=!0,m($);else{var y=r(p);y!==null&&x(N,y.startTime-A)}}function $(A,y){S=!1,P&&(P=!1,C(Q),Q=-1),_=!0;var c=E;try{for(B(y),v=r(h);v!==null&&(!(v.expirationTime>y)||A&&!w());){var g=v.callback;if(typeof g=="function"){v.callback=null,E=v.priorityLevel;var M=g(v.expirationTime<=y);y=t.unstable_now(),typeof M=="function"?v.callback=M:v===r(h)&&n(h),B(y)}else n(h);v=r(h)}if(v!==null)var R=!0;else{var L=r(p);L!==null&&x(N,L.startTime-y),R=!1}return R}finally{v=null,E=c,_=!1}}var H=!1,J=null,Q=-1,K=5,se=-1;function w(){return!(t.unstable_now()-seA||125g?(A.sortIndex=c,e(p,A),r(h)===null&&A===r(p)&&(P?(C(Q),Q=-1):P=!0,x(N,c-g))):(A.sortIndex=M,e(h,A),S||_||(S=!0,m($))),A},t.unstable_shouldYield=w,t.unstable_wrapCallback=function(A){var y=E;return function(){var c=E;E=y;try{return A.apply(this,arguments)}finally{E=c}}}})(pO);dO.exports=pO;var DW=dO.exports;/** - * @license React - * react-dom.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var mO=Z,os=DW;function qe(t){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+t,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),A4=Object.prototype.hasOwnProperty,$W=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,TP={},kP={};function FW(t){return A4.call(kP,t)?!0:A4.call(TP,t)?!1:$W.test(t)?kP[t]=!0:(TP[t]=!0,!1)}function UW(t,e,r,n){if(r!==null&&r.type===0)return!1;switch(typeof e){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function zW(t,e,r,n){if(e===null||typeof e>"u"||UW(t,e,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!e;case 4:return e===!1;case 5:return isNaN(e);case 6:return isNaN(e)||1>e}return!1}function yi(t,e,r,n,s,i,o){this.acceptsBooleans=e===2||e===3||e===4,this.attributeName=n,this.attributeNamespace=s,this.mustUseProperty=r,this.propertyName=t,this.type=e,this.sanitizeURL=i,this.removeEmptyString=o}var Nn={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){Nn[t]=new yi(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var e=t[0];Nn[e]=new yi(e,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){Nn[t]=new yi(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Nn[t]=new yi(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){Nn[t]=new yi(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){Nn[t]=new yi(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){Nn[t]=new yi(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){Nn[t]=new yi(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){Nn[t]=new yi(t,5,!1,t.toLowerCase(),null,!1,!1)});var PA=/[\-:]([a-z])/g;function CA(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var e=t.replace(PA,CA);Nn[e]=new yi(e,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var e=t.replace(PA,CA);Nn[e]=new yi(e,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var e=t.replace(PA,CA);Nn[e]=new yi(e,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){Nn[t]=new yi(t,1,!1,t.toLowerCase(),null,!1,!1)});Nn.xlinkHref=new yi("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){Nn[t]=new yi(t,1,!1,t.toLowerCase(),null,!0,!0)});function IA(t,e,r,n){var s=Nn.hasOwnProperty(e)?Nn[e]:null;(s!==null?s.type!==0:n||!(2f||s[o]!==i[f]){var h=` -`+s[o].replace(" at new "," at ");return t.displayName&&h.includes("")&&(h=h.replace("",t.displayName)),h}while(1<=o&&0<=f);break}}}finally{e3=!1,Error.prepareStackTrace=r}return(t=t?t.displayName||t.name:"")?cm(t):""}function jW(t){switch(t.tag){case 5:return cm(t.type);case 16:return cm("Lazy");case 13:return cm("Suspense");case 19:return cm("SuspenseList");case 0:case 2:case 15:return t=t3(t.type,!1),t;case 11:return t=t3(t.type.render,!1),t;case 1:return t=t3(t.type,!0),t;default:return""}}function _4(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case gh:return"Fragment";case mh:return"Portal";case E4:return"Profiler";case TA:return"StrictMode";case M4:return"Suspense";case S4:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case bO:return(t.displayName||"Context")+".Consumer";case yO:return(t._context.displayName||"Context")+".Provider";case kA:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case RA:return e=t.displayName||null,e!==null?e:_4(t.type)||"Memo";case A0:e=t._payload,t=t._init;try{return _4(t(e))}catch{}}return null}function HW(t){var e=t.type;switch(t.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=e.render,t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return _4(e);case 8:return e===TA?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function mc(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function xO(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function qW(t){var e=xO(t)?"checked":"value",r=Object.getOwnPropertyDescriptor(t.constructor.prototype,e),n=""+t[e];if(!t.hasOwnProperty(e)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var s=r.get,i=r.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return s.call(this)},set:function(o){n=""+o,i.call(this,o)}}),Object.defineProperty(t,e,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function mb(t){t._valueTracker||(t._valueTracker=qW(t))}function wO(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var r=e.getValue(),n="";return t&&(n=xO(t)?t.checked?"true":"false":t.value),t=n,t!==r?(e.setValue(t),!0):!1}function m2(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function P4(t,e){var r=e.checked;return Or({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??t._wrapperState.initialChecked})}function BP(t,e){var r=e.defaultValue==null?"":e.defaultValue,n=e.checked!=null?e.checked:e.defaultChecked;r=mc(e.value!=null?e.value:r),t._wrapperState={initialChecked:n,initialValue:r,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function AO(t,e){e=e.checked,e!=null&&IA(t,"checked",e,!1)}function C4(t,e){AO(t,e);var r=mc(e.value),n=e.type;if(r!=null)n==="number"?(r===0&&t.value===""||t.value!=r)&&(t.value=""+r):t.value!==""+r&&(t.value=""+r);else if(n==="submit"||n==="reset"){t.removeAttribute("value");return}e.hasOwnProperty("value")?I4(t,e.type,r):e.hasOwnProperty("defaultValue")&&I4(t,e.type,mc(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(t.defaultChecked=!!e.defaultChecked)}function OP(t,e,r){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var n=e.type;if(!(n!=="submit"&&n!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+t._wrapperState.initialValue,r||e===t.value||(t.value=e),t.defaultValue=e}r=t.name,r!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,r!==""&&(t.name=r)}function I4(t,e,r){(e!=="number"||m2(t.ownerDocument)!==t)&&(r==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+r&&(t.defaultValue=""+r))}var um=Array.isArray;function Uh(t,e,r,n){if(t=t.options,e){e={};for(var s=0;s"+e.valueOf().toString()+"",e=gb.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;e.firstChild;)t.appendChild(e.firstChild)}});function Km(t,e){if(e){var r=t.firstChild;if(r&&r===t.lastChild&&r.nodeType===3){r.nodeValue=e;return}}t.textContent=e}var Sm={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},GW=["Webkit","ms","Moz","O"];Object.keys(Sm).forEach(function(t){GW.forEach(function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),Sm[e]=Sm[t]})});function _O(t,e,r){return e==null||typeof e=="boolean"||e===""?"":r||typeof e!="number"||e===0||Sm.hasOwnProperty(t)&&Sm[t]?(""+e).trim():e+"px"}function PO(t,e){t=t.style;for(var r in e)if(e.hasOwnProperty(r)){var n=r.indexOf("--")===0,s=_O(r,e[r],n);r==="float"&&(r="cssFloat"),n?t.setProperty(r,s):t[r]=s}}var VW=Or({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function R4(t,e){if(e){if(VW[t]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(qe(137,t));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(qe(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(qe(61))}if(e.style!=null&&typeof e.style!="object")throw Error(qe(62))}}function B4(t,e){if(t.indexOf("-")===-1)return typeof e.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var O4=null;function BA(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var N4=null,zh=null,jh=null;function DP(t){if(t=ly(t)){if(typeof N4!="function")throw Error(qe(280));var e=t.stateNode;e&&(e=b5(e),N4(t.stateNode,t.type,e))}}function CO(t){zh?jh?jh.push(t):jh=[t]:zh=t}function IO(){if(zh){var t=zh,e=jh;if(jh=zh=null,DP(t),e)for(t=0;t>>=0,t===0?32:31-(nJ(t)/iJ|0)|0}var yb=64,bb=4194304;function lm(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function v2(t,e){var r=t.pendingLanes;if(r===0)return 0;var n=0,s=t.suspendedLanes,i=t.pingedLanes,o=r&268435455;if(o!==0){var f=o&~s;f!==0?n=lm(f):(i&=o,i!==0&&(n=lm(i)))}else o=r&~s,o!==0?n=lm(o):i!==0&&(n=lm(i));if(n===0)return 0;if(e!==0&&e!==n&&!(e&s)&&(s=n&-n,i=e&-e,s>=i||s===16&&(i&4194240)!==0))return e;if(n&4&&(n|=r&16),e=t.entangledLanes,e!==0)for(t=t.entanglements,e&=n;0r;r++)e.push(t);return e}function cy(t,e,r){t.pendingLanes|=e,e!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,e=31-Do(e),t[e]=r}function fJ(t,e){var r=t.pendingLanes&~e;t.pendingLanes=e,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=e,t.mutableReadLanes&=e,t.entangledLanes&=e,e=t.entanglements;var n=t.eventTimes;for(t=t.expirationTimes;0=Pm),VP=String.fromCharCode(32),KP=!1;function JO(t,e){switch(t){case"keyup":return LJ.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ZO(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var yh=!1;function $J(t,e){switch(t){case"compositionend":return ZO(e);case"keypress":return e.which!==32?null:(KP=!0,VP);case"textInput":return t=e.data,t===VP&&KP?null:t;default:return null}}function FJ(t,e){if(yh)return t==="compositionend"||!zA&&JO(t,e)?(t=KO(),mv=$A=V0=null,yh=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1=e)return{node:r,offset:e-t};t=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=QP(r)}}function eN(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?eN(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function tN(){for(var t=window,e=m2();e instanceof t.HTMLIFrameElement;){try{var r=typeof e.contentWindow.location.href=="string"}catch{r=!1}if(r)t=e.contentWindow;else break;e=m2(t.document)}return e}function jA(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function WJ(t){var e=tN(),r=t.focusedElem,n=t.selectionRange;if(e!==r&&r&&r.ownerDocument&&eN(r.ownerDocument.documentElement,r)){if(n!==null&&jA(r)){if(e=n.start,t=n.end,t===void 0&&(t=e),"selectionStart"in r)r.selectionStart=e,r.selectionEnd=Math.min(t,r.value.length);else if(t=(e=r.ownerDocument||document)&&e.defaultView||window,t.getSelection){t=t.getSelection();var s=r.textContent.length,i=Math.min(n.start,s);n=n.end===void 0?i:Math.min(n.end,s),!t.extend&&i>n&&(s=n,n=i,i=s),s=YP(r,i);var o=YP(r,n);s&&o&&(t.rangeCount!==1||t.anchorNode!==s.node||t.anchorOffset!==s.offset||t.focusNode!==o.node||t.focusOffset!==o.offset)&&(e=e.createRange(),e.setStart(s.node,s.offset),t.removeAllRanges(),i>n?(t.addRange(e),t.extend(o.node,o.offset)):(e.setEnd(o.node,o.offset),t.addRange(e)))}}for(e=[],t=r;t=t.parentNode;)t.nodeType===1&&e.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r=document.documentMode,bh=null,z4=null,Im=null,j4=!1;function XP(t,e,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;j4||bh==null||bh!==m2(n)||(n=bh,"selectionStart"in n&&jA(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Im&&Xm(Im,n)||(Im=n,n=A2(z4,"onSelect"),0wh||(t.current=W4[wh],W4[wh]=null,wh--)}function gr(t,e){wh++,W4[wh]=t.current,t.current=e}var gc={},ti=Bc(gc),Bi=Bc(!1),Yu=gc;function Yd(t,e){var r=t.type.contextTypes;if(!r)return gc;var n=t.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===e)return n.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in r)s[i]=e[i];return n&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=e,t.__reactInternalMemoizedMaskedChildContext=s),s}function Oi(t){return t=t.childContextTypes,t!=null}function M2(){xr(Bi),xr(ti)}function oC(t,e,r){if(ti.current!==gc)throw Error(qe(168));gr(ti,e),gr(Bi,r)}function uN(t,e,r){var n=t.stateNode;if(e=e.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var s in n)if(!(s in e))throw Error(qe(108,HW(t)||"Unknown",s));return Or({},r,n)}function S2(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||gc,Yu=ti.current,gr(ti,t),gr(Bi,Bi.current),!0}function aC(t,e,r){var n=t.stateNode;if(!n)throw Error(qe(169));r?(t=uN(t,e,Yu),n.__reactInternalMemoizedMergedChildContext=t,xr(Bi),xr(ti),gr(ti,t)):xr(Bi),gr(Bi,r)}var tf=null,v5=!1,m3=!1;function lN(t){tf===null?tf=[t]:tf.push(t)}function oZ(t){v5=!0,lN(t)}function Oc(){if(!m3&&tf!==null){m3=!0;var t=0,e=Yt;try{var r=tf;for(Yt=1;t>=o,s-=o,Af=1<<32-Do(e)+s|r<Q?(K=J,J=null):K=J.sibling;var se=E(C,J,B[Q],N);if(se===null){J===null&&(J=K);break}t&&J&&se.alternate===null&&e(C,J),T=i(se,T,Q),H===null?$=se:H.sibling=se,H=se,J=K}if(Q===B.length)return r(C,J),Mr&&tu(C,Q),$;if(J===null){for(;QQ?(K=J,J=null):K=J.sibling;var w=E(C,J,se.value,N);if(w===null){J===null&&(J=K);break}t&&J&&w.alternate===null&&e(C,J),T=i(w,T,Q),H===null?$=w:H.sibling=w,H=w,J=K}if(se.done)return r(C,J),Mr&&tu(C,Q),$;if(J===null){for(;!se.done;Q++,se=B.next())se=v(C,se.value,N),se!==null&&(T=i(se,T,Q),H===null?$=se:H.sibling=se,H=se);return Mr&&tu(C,Q),$}for(J=n(C,J);!se.done;Q++,se=B.next())se=_(J,C,Q,se.value,N),se!==null&&(t&&se.alternate!==null&&J.delete(se.key===null?Q:se.key),T=i(se,T,Q),H===null?$=se:H.sibling=se,H=se);return t&&J.forEach(function(a){return e(C,a)}),Mr&&tu(C,Q),$}function I(C,T,B,N){if(typeof B=="object"&&B!==null&&B.type===gh&&B.key===null&&(B=B.props.children),typeof B=="object"&&B!==null){switch(B.$$typeof){case pb:e:{for(var $=B.key,H=T;H!==null;){if(H.key===$){if($=B.type,$===gh){if(H.tag===7){r(C,H.sibling),T=s(H,B.props.children),T.return=C,C=T;break e}}else if(H.elementType===$||typeof $=="object"&&$!==null&&$.$$typeof===A0&&pC($)===H.type){r(C,H.sibling),T=s(H,B.props),T.ref=$1(C,H,B),T.return=C,C=T;break e}r(C,H);break}else e(C,H);H=H.sibling}B.type===gh?(T=$u(B.props.children,C.mode,N,B.key),T.return=C,C=T):(N=Ev(B.type,B.key,B.props,null,C.mode,N),N.ref=$1(C,T,B),N.return=C,C=N)}return o(C);case mh:e:{for(H=B.key;T!==null;){if(T.key===H)if(T.tag===4&&T.stateNode.containerInfo===B.containerInfo&&T.stateNode.implementation===B.implementation){r(C,T.sibling),T=s(T,B.children||[]),T.return=C,C=T;break e}else{r(C,T);break}else e(C,T);T=T.sibling}T=E3(B,C.mode,N),T.return=C,C=T}return o(C);case A0:return H=B._init,I(C,T,H(B._payload),N)}if(um(B))return S(C,T,B,N);if(B1(B))return P(C,T,B,N);Sb(C,B)}return typeof B=="string"&&B!==""||typeof B=="number"?(B=""+B,T!==null&&T.tag===6?(r(C,T.sibling),T=s(T,B),T.return=C,C=T):(r(C,T),T=A3(B,C.mode,N),T.return=C,C=T),o(C)):r(C,T)}return I}var ep=vN(!0),xN=vN(!1),hy={},Ca=Bc(hy),ng=Bc(hy),ig=Bc(hy);function cu(t){if(t===hy)throw Error(qe(174));return t}function QA(t,e){switch(gr(ig,e),gr(ng,t),gr(Ca,hy),t=e.nodeType,t){case 9:case 11:e=(e=e.documentElement)?e.namespaceURI:k4(null,"");break;default:t=t===8?e.parentNode:e,e=t.namespaceURI||null,t=t.tagName,e=k4(e,t)}xr(Ca),gr(Ca,e)}function tp(){xr(Ca),xr(ng),xr(ig)}function wN(t){cu(ig.current);var e=cu(Ca.current),r=k4(e,t.type);e!==r&&(gr(ng,t),gr(Ca,r))}function YA(t){ng.current===t&&(xr(Ca),xr(ng))}var Cr=Bc(0);function k2(t){for(var e=t;e!==null;){if(e.tag===13){var r=e.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return e}else if(e.tag===19&&e.memoizedProps.revealOrder!==void 0){if(e.flags&128)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var g3=[];function XA(){for(var t=0;tr?r:4,t(!0);var n=y3.transition;y3.transition={};try{t(!1),e()}finally{Yt=r,y3.transition=n}}function DN(){return Us().memoizedState}function uZ(t,e,r){var n=oc(t);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},$N(t))FN(e,r);else if(r=mN(t,e,r,n),r!==null){var s=ui();$o(r,t,n,s),UN(r,e,n)}}function lZ(t,e,r){var n=oc(t),s={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if($N(t))FN(e,s);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=e.lastRenderedReducer,i!==null))try{var o=e.lastRenderedState,f=i(o,r);if(s.hasEagerState=!0,s.eagerState=f,qo(f,o)){var h=e.interleaved;h===null?(s.next=s,JA(e)):(s.next=h.next,h.next=s),e.interleaved=s;return}}catch{}finally{}r=mN(t,e,s,n),r!==null&&(s=ui(),$o(r,t,n,s),UN(r,e,n))}}function $N(t){var e=t.alternate;return t===Br||e!==null&&e===Br}function FN(t,e){Tm=R2=!0;var r=t.pending;r===null?e.next=e:(e.next=r.next,r.next=e),t.pending=e}function UN(t,e,r){if(r&4194240){var n=e.lanes;n&=t.pendingLanes,r|=n,e.lanes=r,NA(t,r)}}var B2={readContext:Fs,useCallback:Fn,useContext:Fn,useEffect:Fn,useImperativeHandle:Fn,useInsertionEffect:Fn,useLayoutEffect:Fn,useMemo:Fn,useReducer:Fn,useRef:Fn,useState:Fn,useDebugValue:Fn,useDeferredValue:Fn,useTransition:Fn,useMutableSource:Fn,useSyncExternalStore:Fn,useId:Fn,unstable_isNewReconciler:!1},hZ={readContext:Fs,useCallback:function(t,e){return ca().memoizedState=[t,e===void 0?null:e],t},useContext:Fs,useEffect:gC,useImperativeHandle:function(t,e,r){return r=r!=null?r.concat([t]):null,vv(4194308,4,RN.bind(null,e,t),r)},useLayoutEffect:function(t,e){return vv(4194308,4,t,e)},useInsertionEffect:function(t,e){return vv(4,2,t,e)},useMemo:function(t,e){var r=ca();return e=e===void 0?null:e,t=t(),r.memoizedState=[t,e],t},useReducer:function(t,e,r){var n=ca();return e=r!==void 0?r(e):e,n.memoizedState=n.baseState=e,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:e},n.queue=t,t=t.dispatch=uZ.bind(null,Br,t),[n.memoizedState,t]},useRef:function(t){var e=ca();return t={current:t},e.memoizedState=t},useState:mC,useDebugValue:iE,useDeferredValue:function(t){return ca().memoizedState=t},useTransition:function(){var t=mC(!1),e=t[0];return t=cZ.bind(null,t[1]),ca().memoizedState=t,[e,t]},useMutableSource:function(){},useSyncExternalStore:function(t,e,r){var n=Br,s=ca();if(Mr){if(r===void 0)throw Error(qe(407));r=r()}else{if(r=e(),wn===null)throw Error(qe(349));el&30||MN(n,e,r)}s.memoizedState=r;var i={value:r,getSnapshot:e};return s.queue=i,gC(_N.bind(null,n,i,t),[t]),n.flags|=2048,ag(9,SN.bind(null,n,i,r,e),void 0,null),r},useId:function(){var t=ca(),e=wn.identifierPrefix;if(Mr){var r=Ef,n=Af;r=(n&~(1<<32-Do(n)-1)).toString(32)+r,e=":"+e+"R"+r,r=sg++,0<\/script>",t=t.removeChild(t.firstChild)):typeof n.is=="string"?t=o.createElement(r,{is:n.is}):(t=o.createElement(r),r==="select"&&(o=t,n.multiple?o.multiple=!0:n.size&&(o.size=n.size))):t=o.createElementNS(t,r),t[wa]=e,t[rg]=n,JN(t,e,!1,!1),e.stateNode=t;e:{switch(o=B4(r,n),r){case"dialog":br("cancel",t),br("close",t),s=n;break;case"iframe":case"object":case"embed":br("load",t),s=n;break;case"video":case"audio":for(s=0;snp&&(e.flags|=128,n=!0,F1(i,!1),e.lanes=4194304)}else{if(!n)if(t=k2(o),t!==null){if(e.flags|=128,n=!0,r=t.updateQueue,r!==null&&(e.updateQueue=r,e.flags|=4),F1(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!Mr)return Un(e),null}else 2*Vr()-i.renderingStartTime>np&&r!==1073741824&&(e.flags|=128,n=!0,F1(i,!1),e.lanes=4194304);i.isBackwards?(o.sibling=e.child,e.child=o):(r=i.last,r!==null?r.sibling=o:e.child=o,i.last=o)}return i.tail!==null?(e=i.tail,i.rendering=e,i.tail=e.sibling,i.renderingStartTime=Vr(),e.sibling=null,r=Cr.current,gr(Cr,n?r&1|2:r&1),e):(Un(e),null);case 22:case 23:return uE(),n=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==n&&(e.flags|=8192),n&&e.mode&1?Ji&1073741824&&(Un(e),e.subtreeFlags&6&&(e.flags|=8192)):Un(e),null;case 24:return null;case 25:return null}throw Error(qe(156,e.tag))}function xZ(t,e){switch(qA(e),e.tag){case 1:return Oi(e.type)&&M2(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return tp(),xr(Bi),xr(ti),XA(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return YA(e),null;case 13:if(xr(Cr),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(qe(340));Xd()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return xr(Cr),null;case 4:return tp(),null;case 10:return WA(e.type._context),null;case 22:case 23:return uE(),null;case 24:return null;default:return null}}var Pb=!1,Jn=!1,wZ=typeof WeakSet=="function"?WeakSet:Set,tt=null;function Sh(t,e){var r=t.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Dr(t,e,n)}else r.current=null}function o9(t,e,r){try{r()}catch(n){Dr(t,e,n)}}var SC=!1;function AZ(t,e){if(H4=x2,t=tN(),jA(t)){if("selectionStart"in t)var r={start:t.selectionStart,end:t.selectionEnd};else e:{r=(r=t.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var s=n.anchorOffset,i=n.focusNode;n=n.focusOffset;try{r.nodeType,i.nodeType}catch{r=null;break e}var o=0,f=-1,h=-1,p=0,b=0,v=t,E=null;t:for(;;){for(var _;v!==r||s!==0&&v.nodeType!==3||(f=o+s),v!==i||n!==0&&v.nodeType!==3||(h=o+n),v.nodeType===3&&(o+=v.nodeValue.length),(_=v.firstChild)!==null;)E=v,v=_;for(;;){if(v===t)break t;if(E===r&&++p===s&&(f=o),E===i&&++b===n&&(h=o),(_=v.nextSibling)!==null)break;v=E,E=v.parentNode}v=_}r=f===-1||h===-1?null:{start:f,end:h}}else r=null}r=r||{start:0,end:0}}else r=null;for(q4={focusedElem:t,selectionRange:r},x2=!1,tt=e;tt!==null;)if(e=tt,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,tt=t;else for(;tt!==null;){e=tt;try{var S=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(S!==null){var P=S.memoizedProps,I=S.memoizedState,C=e.stateNode,T=C.getSnapshotBeforeUpdate(e.elementType===e.type?P:bo(e.type,P),I);C.__reactInternalSnapshotBeforeUpdate=T}break;case 3:var B=e.stateNode.containerInfo;B.nodeType===1?B.textContent="":B.nodeType===9&&B.documentElement&&B.removeChild(B.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(qe(163))}}catch(N){Dr(e,e.return,N)}if(t=e.sibling,t!==null){t.return=e.return,tt=t;break}tt=e.return}return S=SC,SC=!1,S}function km(t,e,r){var n=e.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var s=n=n.next;do{if((s.tag&t)===t){var i=s.destroy;s.destroy=void 0,i!==void 0&&o9(e,r,i)}s=s.next}while(s!==n)}}function A5(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var r=e=e.next;do{if((r.tag&t)===t){var n=r.create;r.destroy=n()}r=r.next}while(r!==e)}}function a9(t){var e=t.ref;if(e!==null){var r=t.stateNode;switch(t.tag){case 5:t=r;break;default:t=r}typeof e=="function"?e(t):e.current=t}}function YN(t){var e=t.alternate;e!==null&&(t.alternate=null,YN(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[wa],delete e[rg],delete e[K4],delete e[iZ],delete e[sZ])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function XN(t){return t.tag===5||t.tag===3||t.tag===4}function _C(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||XN(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function f9(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.nodeType===8?r.parentNode.insertBefore(t,e):r.insertBefore(t,e):(r.nodeType===8?(e=r.parentNode,e.insertBefore(t,r)):(e=r,e.appendChild(t)),r=r._reactRootContainer,r!=null||e.onclick!==null||(e.onclick=E2));else if(n!==4&&(t=t.child,t!==null))for(f9(t,e,r),t=t.sibling;t!==null;)f9(t,e,r),t=t.sibling}function c9(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.insertBefore(t,e):r.appendChild(t);else if(n!==4&&(t=t.child,t!==null))for(c9(t,e,r),t=t.sibling;t!==null;)c9(t,e,r),t=t.sibling}var Cn=null,_o=!1;function f0(t,e,r){for(r=r.child;r!==null;)eL(t,e,r),r=r.sibling}function eL(t,e,r){if(Pa&&typeof Pa.onCommitFiberUnmount=="function")try{Pa.onCommitFiberUnmount(p5,r)}catch{}switch(r.tag){case 5:Jn||Sh(r,e);case 6:var n=Cn,s=_o;Cn=null,f0(t,e,r),Cn=n,_o=s,Cn!==null&&(_o?(t=Cn,r=r.stateNode,t.nodeType===8?t.parentNode.removeChild(r):t.removeChild(r)):Cn.removeChild(r.stateNode));break;case 18:Cn!==null&&(_o?(t=Cn,r=r.stateNode,t.nodeType===8?p3(t.parentNode,r):t.nodeType===1&&p3(t,r),Qm(t)):p3(Cn,r.stateNode));break;case 4:n=Cn,s=_o,Cn=r.stateNode.containerInfo,_o=!0,f0(t,e,r),Cn=n,_o=s;break;case 0:case 11:case 14:case 15:if(!Jn&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){s=n=n.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&o9(r,e,o),s=s.next}while(s!==n)}f0(t,e,r);break;case 1:if(!Jn&&(Sh(r,e),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(f){Dr(r,e,f)}f0(t,e,r);break;case 21:f0(t,e,r);break;case 22:r.mode&1?(Jn=(n=Jn)||r.memoizedState!==null,f0(t,e,r),Jn=n):f0(t,e,r);break;default:f0(t,e,r)}}function PC(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var r=t.stateNode;r===null&&(r=t.stateNode=new wZ),e.forEach(function(n){var s=kZ.bind(null,t,n);r.has(n)||(r.add(n),n.then(s,s))})}}function ho(t,e){var r=e.deletions;if(r!==null)for(var n=0;ns&&(s=o),n&=~i}if(n=s,n=Vr()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*MZ(n/1960))-n,10t?16:t,K0===null)var n=!1;else{if(t=K0,K0=null,L2=0,zt&6)throw Error(qe(331));var s=zt;for(zt|=4,tt=t.current;tt!==null;){var i=tt,o=i.child;if(tt.flags&16){var f=i.deletions;if(f!==null){for(var h=0;hVr()-fE?Du(t,0):aE|=r),Ni(t,e)}function fL(t,e){e===0&&(t.mode&1?(e=bb,bb<<=1,!(bb&130023424)&&(bb=4194304)):e=1);var r=ui();t=$f(t,e),t!==null&&(cy(t,e,r),Ni(t,r))}function TZ(t){var e=t.memoizedState,r=0;e!==null&&(r=e.retryLane),fL(t,r)}function kZ(t,e){var r=0;switch(t.tag){case 13:var n=t.stateNode,s=t.memoizedState;s!==null&&(r=s.retryLane);break;case 19:n=t.stateNode;break;default:throw Error(qe(314))}n!==null&&n.delete(e),fL(t,r)}var cL;cL=function(t,e,r){if(t!==null)if(t.memoizedProps!==e.pendingProps||Bi.current)ki=!0;else{if(!(t.lanes&r)&&!(e.flags&128))return ki=!1,bZ(t,e,r);ki=!!(t.flags&131072)}else ki=!1,Mr&&e.flags&1048576&&hN(e,P2,e.index);switch(e.lanes=0,e.tag){case 2:var n=e.type;xv(t,e),t=e.pendingProps;var s=Yd(e,ti.current);qh(e,r),s=tE(null,e,n,t,s,r);var i=rE();return e.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,Oi(n)?(i=!0,S2(e)):i=!1,e.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,ZA(e),s.updater=x5,e.stateNode=s,s._reactInternals=e,X4(e,n,t,r),e=r9(null,e,n,!0,i,r)):(e.tag=0,Mr&&i&&HA(e),ii(null,e,s,r),e=e.child),e;case 16:n=e.elementType;e:{switch(xv(t,e),t=e.pendingProps,s=n._init,n=s(n._payload),e.type=n,s=e.tag=BZ(n),t=bo(n,t),s){case 0:e=t9(null,e,n,t,r);break e;case 1:e=AC(null,e,n,t,r);break e;case 11:e=xC(null,e,n,t,r);break e;case 14:e=wC(null,e,n,bo(n.type,t),r);break e}throw Error(qe(306,n,""))}return e;case 0:return n=e.type,s=e.pendingProps,s=e.elementType===n?s:bo(n,s),t9(t,e,n,s,r);case 1:return n=e.type,s=e.pendingProps,s=e.elementType===n?s:bo(n,s),AC(t,e,n,s,r);case 3:e:{if(VN(e),t===null)throw Error(qe(387));n=e.pendingProps,i=e.memoizedState,s=i.element,gN(t,e),T2(e,n,null,r);var o=e.memoizedState;if(n=o.element,i.isDehydrated)if(i={element:n,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},e.updateQueue.baseState=i,e.memoizedState=i,e.flags&256){s=rp(Error(qe(423)),e),e=EC(t,e,n,r,s);break e}else if(n!==s){s=rp(Error(qe(424)),e),e=EC(t,e,n,r,s);break e}else for(ts=nc(e.stateNode.containerInfo.firstChild),ns=e,Mr=!0,Po=null,r=xN(e,null,n,r),e.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Xd(),n===s){e=Ff(t,e,r);break e}ii(t,e,n,r)}e=e.child}return e;case 5:return wN(e),t===null&&Z4(e),n=e.type,s=e.pendingProps,i=t!==null?t.memoizedProps:null,o=s.children,G4(n,s)?o=null:i!==null&&G4(n,i)&&(e.flags|=32),GN(t,e),ii(t,e,o,r),e.child;case 6:return t===null&&Z4(e),null;case 13:return KN(t,e,r);case 4:return QA(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=ep(e,null,n,r):ii(t,e,n,r),e.child;case 11:return n=e.type,s=e.pendingProps,s=e.elementType===n?s:bo(n,s),xC(t,e,n,s,r);case 7:return ii(t,e,e.pendingProps,r),e.child;case 8:return ii(t,e,e.pendingProps.children,r),e.child;case 12:return ii(t,e,e.pendingProps.children,r),e.child;case 10:e:{if(n=e.type._context,s=e.pendingProps,i=e.memoizedProps,o=s.value,gr(C2,n._currentValue),n._currentValue=o,i!==null)if(qo(i.value,o)){if(i.children===s.children&&!Bi.current){e=Ff(t,e,r);break e}}else for(i=e.child,i!==null&&(i.return=e);i!==null;){var f=i.dependencies;if(f!==null){o=i.child;for(var h=f.firstContext;h!==null;){if(h.context===n){if(i.tag===1){h=Pf(-1,r&-r),h.tag=2;var p=i.updateQueue;if(p!==null){p=p.shared;var b=p.pending;b===null?h.next=h:(h.next=b.next,b.next=h),p.pending=h}}i.lanes|=r,h=i.alternate,h!==null&&(h.lanes|=r),Q4(i.return,r,e),f.lanes|=r;break}h=h.next}}else if(i.tag===10)o=i.type===e.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(qe(341));o.lanes|=r,f=o.alternate,f!==null&&(f.lanes|=r),Q4(o,r,e),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===e){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}ii(t,e,s.children,r),e=e.child}return e;case 9:return s=e.type,n=e.pendingProps.children,qh(e,r),s=Fs(s),n=n(s),e.flags|=1,ii(t,e,n,r),e.child;case 14:return n=e.type,s=bo(n,e.pendingProps),s=bo(n.type,s),wC(t,e,n,s,r);case 15:return HN(t,e,e.type,e.pendingProps,r);case 17:return n=e.type,s=e.pendingProps,s=e.elementType===n?s:bo(n,s),xv(t,e),e.tag=1,Oi(n)?(t=!0,S2(e)):t=!1,qh(e,r),bN(e,n,s),X4(e,n,s,r),r9(null,e,n,!0,t,r);case 19:return WN(t,e,r);case 22:return qN(t,e,r)}throw Error(qe(156,e.tag))};function uL(t,e){return LO(t,e)}function RZ(t,e,r,n){this.tag=t,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Rs(t,e,r,n){return new RZ(t,e,r,n)}function hE(t){return t=t.prototype,!(!t||!t.isReactComponent)}function BZ(t){if(typeof t=="function")return hE(t)?1:0;if(t!=null){if(t=t.$$typeof,t===kA)return 11;if(t===RA)return 14}return 2}function ac(t,e){var r=t.alternate;return r===null?(r=Rs(t.tag,e,t.key,t.mode),r.elementType=t.elementType,r.type=t.type,r.stateNode=t.stateNode,r.alternate=t,t.alternate=r):(r.pendingProps=e,r.type=t.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=t.flags&14680064,r.childLanes=t.childLanes,r.lanes=t.lanes,r.child=t.child,r.memoizedProps=t.memoizedProps,r.memoizedState=t.memoizedState,r.updateQueue=t.updateQueue,e=t.dependencies,r.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},r.sibling=t.sibling,r.index=t.index,r.ref=t.ref,r}function Ev(t,e,r,n,s,i){var o=2;if(n=t,typeof t=="function")hE(t)&&(o=1);else if(typeof t=="string")o=5;else e:switch(t){case gh:return $u(r.children,s,i,e);case TA:o=8,s|=8;break;case E4:return t=Rs(12,r,e,s|2),t.elementType=E4,t.lanes=i,t;case M4:return t=Rs(13,r,e,s),t.elementType=M4,t.lanes=i,t;case S4:return t=Rs(19,r,e,s),t.elementType=S4,t.lanes=i,t;case vO:return M5(r,s,i,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case yO:o=10;break e;case bO:o=9;break e;case kA:o=11;break e;case RA:o=14;break e;case A0:o=16,n=null;break e}throw Error(qe(130,t==null?t:typeof t,""))}return e=Rs(o,r,e,s),e.elementType=t,e.type=n,e.lanes=i,e}function $u(t,e,r,n){return t=Rs(7,t,n,e),t.lanes=r,t}function M5(t,e,r,n){return t=Rs(22,t,n,e),t.elementType=vO,t.lanes=r,t.stateNode={isHidden:!1},t}function A3(t,e,r){return t=Rs(6,t,null,e),t.lanes=r,t}function E3(t,e,r){return e=Rs(4,t.children!==null?t.children:[],t.key,e),e.lanes=r,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function OZ(t,e,r,n,s){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=n3(0),this.expirationTimes=n3(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=n3(0),this.identifierPrefix=n,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function dE(t,e,r,n,s,i,o,f,h){return t=new OZ(t,e,r,f,h),e===1?(e=1,i===!0&&(e|=8)):e=0,i=Rs(3,null,null,e),t.current=i,i.stateNode=t,i.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},ZA(i),t}function NZ(t,e,r){var n=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(pL)}catch(t){console.error(t)}}pL(),hO.exports=us;var yE=hO.exports,NC=yE;w4.createRoot=NC.createRoot,w4.hydrateRoot=NC.hydrateRoot;var $r=function(){return $r=Object.assign||function(e){for(var r,n=1,s=arguments.length;n"u")return tQ;var e=rQ(t),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:e[0],top:e[1],right:e[2],gap:Math.max(0,n-r+e[2]-e[0])}},iQ=bL(),sQ=function(t,e,r,n){var s=t.left,i=t.top,o=t.right,f=t.gap;return r===void 0&&(r="margin"),` - .`.concat(UZ,` { - overflow: hidden `).concat(n,`; - padding-right: `).concat(f,"px ").concat(n,`; - } - body { - overflow: hidden `).concat(n,`; - overscroll-behavior: contain; - `).concat([e&&"position: relative ".concat(n,";"),r==="margin"&&` - padding-left: `.concat(s,`px; - padding-top: `).concat(i,`px; - padding-right: `).concat(o,`px; - margin-left:0; - margin-top:0; - margin-right: `).concat(f,"px ").concat(n,`; - `),r==="padding"&&"padding-right: ".concat(f,"px ").concat(n,";")].filter(Boolean).join(""),` - } - - .`).concat(Mv,` { - right: `).concat(f,"px ").concat(n,`; - } - - .`).concat(Sv,` { - margin-right: `).concat(f,"px ").concat(n,`; - } - - .`).concat(Mv," .").concat(Mv,` { - right: 0 `).concat(n,`; - } - - .`).concat(Sv," .").concat(Sv,` { - margin-right: 0 `).concat(n,`; - } - - body { - `).concat(zZ,": ").concat(f,`px; - } -`)},oQ=function(t){var e=t.noRelative,r=t.noImportant,n=t.gapMode,s=n===void 0?"margin":n,i=Z.useMemo(function(){return nQ(s)},[s]);return Z.createElement(iQ,{styles:sQ(i,!e,s,r?"":"!important")})},p9=!1;if(typeof window<"u")try{var Tb=Object.defineProperty({},"passive",{get:function(){return p9=!0,!0}});window.addEventListener("test",Tb,Tb),window.removeEventListener("test",Tb,Tb)}catch{p9=!1}var Wl=p9?{passive:!1}:!1,aQ=function(t){return t.tagName==="TEXTAREA"},vL=function(t,e){var r=window.getComputedStyle(t);return r[e]!=="hidden"&&!(r.overflowY===r.overflowX&&!aQ(t)&&r[e]==="visible")},fQ=function(t){return vL(t,"overflowY")},cQ=function(t){return vL(t,"overflowX")},DC=function(t,e){var r=e.ownerDocument,n=e;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var s=xL(t,n);if(s){var i=wL(t,n),o=i[1],f=i[2];if(o>f)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},uQ=function(t){var e=t.scrollTop,r=t.scrollHeight,n=t.clientHeight;return[e,r,n]},lQ=function(t){var e=t.scrollLeft,r=t.scrollWidth,n=t.clientWidth;return[e,r,n]},xL=function(t,e){return t==="v"?fQ(e):cQ(e)},wL=function(t,e){return t==="v"?uQ(e):lQ(e)},hQ=function(t,e){return t==="h"&&e==="rtl"?-1:1},dQ=function(t,e,r,n,s){var i=hQ(t,window.getComputedStyle(e).direction),o=i*n,f=r.target,h=e.contains(f),p=!1,b=o>0,v=0,E=0;do{var _=wL(t,f),S=_[0],P=_[1],I=_[2],C=P-I-i*S;(S||C)&&xL(t,f)&&(v+=C,E+=S),f instanceof ShadowRoot?f=f.host:f=f.parentNode}while(!h&&f!==document.body||h&&(e.contains(f)||e===f));return(b&&(s&&Math.abs(v)<1||!s&&o>v)||!b&&(s&&Math.abs(E)<1||!s&&-o>E))&&(p=!0),p},kb=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},$C=function(t){return[t.deltaX,t.deltaY]},FC=function(t){return t&&"current"in t?t.current:t},pQ=function(t,e){return t[0]===e[0]&&t[1]===e[1]},mQ=function(t){return` - .block-interactivity-`.concat(t,` {pointer-events: none;} - .allow-interactivity-`).concat(t,` {pointer-events: all;} -`)},gQ=0,Jl=[];function yQ(t){var e=Z.useRef([]),r=Z.useRef([0,0]),n=Z.useRef(),s=Z.useState(gQ++)[0],i=Z.useState(bL)[0],o=Z.useRef(t);Z.useEffect(function(){o.current=t},[t]),Z.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(s));var P=cg([t.lockRef.current],(t.shards||[]).map(FC),!0).filter(Boolean);return P.forEach(function(I){return I.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),P.forEach(function(I){return I.classList.remove("allow-interactivity-".concat(s))})}}},[t.inert,t.lockRef.current,t.shards]);var f=Z.useCallback(function(P,I){if("touches"in P&&P.touches.length===2)return!o.current.allowPinchZoom;var C=kb(P),T=r.current,B="deltaX"in P?P.deltaX:T[0]-C[0],N="deltaY"in P?P.deltaY:T[1]-C[1],$,H=P.target,J=Math.abs(B)>Math.abs(N)?"h":"v";if("touches"in P&&J==="h"&&H.type==="range")return!1;var Q=DC(J,H);if(!Q)return!0;if(Q?$=J:($=J==="v"?"h":"v",Q=DC(J,H)),!Q)return!1;if(!n.current&&"changedTouches"in P&&(B||N)&&(n.current=$),!$)return!0;var K=n.current||$;return dQ(K,I,P,K==="h"?B:N,!0)},[]),h=Z.useCallback(function(P){var I=P;if(!(!Jl.length||Jl[Jl.length-1]!==i)){var C="deltaY"in I?$C(I):kb(I),T=e.current.filter(function($){return $.name===I.type&&($.target===I.target||I.target===$.shadowParent)&&pQ($.delta,C)})[0];if(T&&T.should){I.cancelable&&I.preventDefault();return}if(!T){var B=(o.current.shards||[]).map(FC).filter(Boolean).filter(function($){return $.contains(I.target)}),N=B.length>0?f(I,B[0]):!o.current.noIsolation;N&&I.cancelable&&I.preventDefault()}}},[]),p=Z.useCallback(function(P,I,C,T){var B={name:P,delta:I,target:C,should:T,shadowParent:bQ(C)};e.current.push(B),setTimeout(function(){e.current=e.current.filter(function(N){return N!==B})},1)},[]),b=Z.useCallback(function(P){r.current=kb(P),n.current=void 0},[]),v=Z.useCallback(function(P){p(P.type,$C(P),P.target,f(P,t.lockRef.current))},[]),E=Z.useCallback(function(P){p(P.type,kb(P),P.target,f(P,t.lockRef.current))},[]);Z.useEffect(function(){return Jl.push(i),t.setCallbacks({onScrollCapture:v,onWheelCapture:v,onTouchMoveCapture:E}),document.addEventListener("wheel",h,Wl),document.addEventListener("touchmove",h,Wl),document.addEventListener("touchstart",b,Wl),function(){Jl=Jl.filter(function(P){return P!==i}),document.removeEventListener("wheel",h,Wl),document.removeEventListener("touchmove",h,Wl),document.removeEventListener("touchstart",b,Wl)}},[]);var _=t.removeScrollBar,S=t.inert;return Z.createElement(Z.Fragment,null,S?Z.createElement(i,{styles:mQ(s)}):null,_?Z.createElement(oQ,{gapMode:t.gapMode}):null)}function bQ(t){for(var e=null;t!==null;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}const vQ=WZ(yL,yQ);var AL=Z.forwardRef(function(t,e){return Z.createElement(I5,$r({},t,{ref:e,sideCar:vQ}))});AL.classNames=I5.classNames;const bE=AL;function Bn(t){return Object.keys(t)}function _3(t){return t&&typeof t=="object"&&!Array.isArray(t)}function vE(t,e){const r={...t},n=e;return _3(t)&&_3(e)&&Object.keys(e).forEach(s=>{_3(n[s])&&s in t?r[s]=vE(r[s],n[s]):r[s]=n[s]}),r}function xQ(t){return t.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}function wQ(t){var e;return typeof t!="string"||!t.includes("var(--mantine-scale)")?t:(e=t.match(/^calc\((.*?)\)$/))==null?void 0:e[1].split("*")[0].trim()}function m9(t){const e=wQ(t);return typeof e=="number"?e:typeof e=="string"?e.includes("calc")||e.includes("var")?e:e.includes("px")?Number(e.replace("px","")):e.includes("rem")?Number(e.replace("rem",""))*16:e.includes("em")?Number(e.replace("em",""))*16:Number(e):NaN}function P3(t){return`calc(${t} * var(--mantine-scale))`}function EL(t,{shouldScale:e=!1}={}){function r(n){if(n===0||n==="0")return"0";if(typeof n=="number"){const s=`${n/16}${t}`;return e?P3(s):s}if(typeof n=="string"){if(n.startsWith("calc(")||n.startsWith("var("))return n;if(n.includes(" "))return n.split(" ").map(i=>r(i)).join(" ");if(n.includes(t))return e?P3(n):n;const s=n.replace("px","");if(!Number.isNaN(Number(s))){const i=`${Number(s)/16}${t}`;return e?P3(i):i}}return n}return r}const ke=EL("rem",{shouldScale:!0}),F2=EL("em");function xE(t){return Object.keys(t).reduce((e,r)=>(t[r]!==void 0&&(e[r]=t[r]),e),{})}function ML(t){return typeof t=="number"?!0:typeof t=="string"?t.startsWith("calc(")||t.startsWith("var(")||t.includes(" ")&&t.trim()!==""?!0:/[0-9]/.test(t.trim().replace("-","")[0]):!1}function El(t){return Array.isArray(t)||t===null?!1:typeof t=="object"?t.type!==ue.Fragment:!1}function dy(t){const e=Z.createContext(null);return[({children:s,value:i})=>ue.createElement(e.Provider,{value:i},s),()=>{const s=Z.useContext(e);if(s===null)throw new Error(t);return s}]}function AQ(t=null){const e=Z.createContext(t);return[({children:s,value:i})=>ue.createElement(e.Provider,{value:i},s),()=>Z.useContext(e)]}const EQ={app:100,modal:200,popover:300,overlay:400,max:9999};function Ua(t){return EQ[t]}const MQ=()=>{};function SQ(t,e={active:!0}){return typeof t!="function"||!e.active?e.onKeyDown||MQ:r=>{var n;r.key==="Escape"&&(t(r),(n=e.onTrigger)==null||n.call(e))}}function jr(t,e="size",r=!0){if(t!==void 0)return ML(t)?r?ke(t):t:`var(--${e}-${t})`}function py(t){return jr(t,"mantine-spacing")}function ri(t){return t===void 0?"var(--mantine-radius-default)":jr(t,"mantine-radius")}function Os(t){return jr(t,"mantine-font-size")}function _Q(t){return jr(t,"mantine-line-height",!1)}function wE(t){if(t)return jr(t,"mantine-shadow",!1)}function AE(t,e){return t in e.breakpoints?m9(e.breakpoints[t]):m9(t)}function UC(t,e){const r=t.map(n=>({value:n,px:AE(n,e)}));return r.sort((n,s)=>n.px-s.px),r}function SL(t){var e,r,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t))for(e=0;e{Object.entries(r).forEach(([n,s])=>{e[n]?e[n]=En(e[n],s):e[n]=s})}),e}function EE({theme:t,classNames:e,props:r,stylesCtx:n}){const i=(Array.isArray(e)?e:[e]).map(o=>typeof o=="function"?o(t,r,n):o||PQ);return CQ(i)}function g9({theme:t,styles:e,props:r,stylesCtx:n}){return(Array.isArray(e)?e:[e]).reduce((i,o)=>typeof o=="function"?{...i,...o(t,r,n)}:{...i,...o},{})}function _L(){return`mantine-${Math.random().toString(36).slice(2,11)}`}const zC=["mousedown","touchstart"];function IQ(t,e,r){const n=Z.useRef();return Z.useEffect(()=>{const s=i=>{const{target:o}=i??{};if(Array.isArray(r)){const f=(o==null?void 0:o.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(o)&&o.tagName!=="HTML";r.every(p=>!!p&&!i.composedPath().includes(p))&&!f&&t()}else n.current&&!n.current.contains(o)&&t()};return(e||zC).forEach(i=>document.addEventListener(i,s)),()=>{(e||zC).forEach(i=>document.removeEventListener(i,s))}},[n,t,r]),n}function TQ({timeout:t=2e3}={}){const[e,r]=Z.useState(null),[n,s]=Z.useState(!1),[i,o]=Z.useState(null),f=b=>{window.clearTimeout(i),o(window.setTimeout(()=>s(!1),t)),s(b)};return{copy:b=>{"clipboard"in navigator?navigator.clipboard.writeText(b).then(()=>f(!0)).catch(v=>r(v)):r(new Error("useClipboard: navigator.clipboard is not supported"))},reset:()=>{s(!1),r(null),window.clearTimeout(i)},error:e,copied:n}}function kQ(t,e){try{return t.addEventListener("change",e),()=>t.removeEventListener("change",e)}catch{return t.addListener(e),()=>t.removeListener(e)}}function RQ(t,e){return typeof e=="boolean"?e:typeof window<"u"&&"matchMedia"in window?window.matchMedia(t).matches:!1}function PL(t,e,{getInitialValueInEffect:r}={getInitialValueInEffect:!0}){const[n,s]=Z.useState(r?e:RQ(t,e)),i=Z.useRef();return Z.useEffect(()=>{if("matchMedia"in window)return i.current=window.matchMedia(t),s(i.current.matches),kQ(i.current,o=>s(o.matches))},[t]),n}function BQ(t,e){return PL("(prefers-color-scheme: dark)",t==="dark",e)?"dark":"light"}const my=typeof document<"u"?Z.useLayoutEffect:Z.useEffect;function nl(t,e){const r=Z.useRef(!1);Z.useEffect(()=>()=>{r.current=!1},[]),Z.useEffect(()=>{if(r.current)return t();r.current=!0},e)}function CL({opened:t,shouldReturnFocus:e=!0}){const r=Z.useRef(),n=()=>{var s;r.current&&"focus"in r.current&&typeof r.current.focus=="function"&&((s=r.current)==null||s.focus({preventScroll:!0}))};return nl(()=>{let s=-1;const i=o=>{o.key==="Tab"&&window.clearTimeout(s)};return document.addEventListener("keydown",i),t?r.current=document.activeElement:e&&(s=window.setTimeout(n,10)),()=>{window.clearTimeout(s),document.removeEventListener("keydown",i)}},[t,e]),n}const OQ=/input|select|textarea|button|object/,IL="a, input, select, textarea, button, object, [tabindex]";function NQ(t){return t.style.display==="none"}function LQ(t){if(t.getAttribute("aria-hidden")||t.getAttribute("hidden")||t.getAttribute("type")==="hidden")return!1;let r=t;for(;r&&!(r===document.body||r.nodeType===11);){if(NQ(r))return!1;r=r.parentNode}return!0}function TL(t){let e=t.getAttribute("tabindex");return e===null&&(e=void 0),parseInt(e,10)}function y9(t){const e=t.nodeName.toLowerCase(),r=!Number.isNaN(TL(t));return(OQ.test(e)&&!t.disabled||t instanceof HTMLAnchorElement&&t.href||r)&&LQ(t)}function kL(t){const e=TL(t);return(Number.isNaN(e)||e>=0)&&y9(t)}function DQ(t){return Array.from(t.querySelectorAll(IL)).filter(kL)}function $Q(t,e){const r=DQ(t);if(!r.length){e.preventDefault();return}const n=r[e.shiftKey?0:r.length-1],s=t.getRootNode();let i=n===s.activeElement||t===s.activeElement;const o=s.activeElement;if(o.tagName==="INPUT"&&o.getAttribute("type")==="radio"&&(i=r.filter(b=>b.getAttribute("type")==="radio"&&b.getAttribute("name")===o.getAttribute("name")).includes(n)),!i)return;e.preventDefault();const h=r[e.shiftKey?r.length-1:0];h&&h.focus()}function FQ(t,e="body > :not(script)"){const r=_L(),n=Array.from(document.querySelectorAll(e)).map(s=>{var h;if((h=s==null?void 0:s.shadowRoot)!=null&&h.contains(t)||s.contains(t))return;const i=s.getAttribute("aria-hidden"),o=s.getAttribute("data-hidden"),f=s.getAttribute("data-focus-id");return s.setAttribute("data-focus-id",r),i===null||i==="false"?s.setAttribute("aria-hidden","true"):!o&&!f&&s.setAttribute("data-hidden",i),{node:s,ariaHidden:o||null}});return()=>{n.forEach(s=>{!s||r!==s.node.getAttribute("data-focus-id")||(s.ariaHidden===null?s.node.removeAttribute("aria-hidden"):s.node.setAttribute("aria-hidden",s.ariaHidden),s.node.removeAttribute("data-focus-id"),s.node.removeAttribute("data-hidden"))})}}function UQ(t=!0){const e=Z.useRef(),r=Z.useRef(null),n=i=>{let o=i.querySelector("[data-autofocus]");if(!o){const f=Array.from(i.querySelectorAll(IL));o=f.find(kL)||f.find(y9)||null,!o&&y9(i)&&(o=i)}o&&o.focus({preventScroll:!0})},s=Z.useCallback(i=>{if(t){if(i===null){r.current&&(r.current(),r.current=null);return}r.current=FQ(i),e.current!==i&&(i?(setTimeout(()=>{i.getRootNode()&&n(i)}),e.current=i):e.current=null)}},[t]);return Z.useEffect(()=>{if(!t)return;e.current&&setTimeout(()=>n(e.current));const i=o=>{o.key==="Tab"&&e.current&&$Q(e.current,o)};return document.addEventListener("keydown",i),()=>{document.removeEventListener("keydown",i),r.current&&r.current()}},[t]),s}const zQ=ue["useId".toString()]||(()=>{});function jQ(){const t=zQ();return t?`mantine-${t.replace(/:/g,"")}`:""}function t1(t){const e=jQ(),[r,n]=Z.useState(e);return my(()=>{n(_L())},[]),typeof t=="string"?t:typeof window>"u"?e:r}function RL(t,e,r){Z.useEffect(()=>(window.addEventListener(t,e,r),()=>window.removeEventListener(t,e,r)),[t,e])}function BL(t,e){typeof t=="function"?t(e):typeof t=="object"&&t!==null&&"current"in t&&(t.current=e)}function HQ(...t){return e=>{t.forEach(r=>BL(r,e))}}function Nc(...t){return Z.useCallback(HQ(...t),t)}function OL({value:t,defaultValue:e,finalValue:r,onChange:n=()=>{}}){const[s,i]=Z.useState(e!==void 0?e:r),o=f=>{i(f),n==null||n(f)};return t!==void 0?[t,n,!0]:[s,o,!1]}function NL(t,e){return PL("(prefers-reduced-motion: reduce)",t,e)}function ME(t=!1,e){const{onOpen:r,onClose:n}=e||{},[s,i]=Z.useState(t),o=Z.useCallback(()=>{i(p=>p||(r==null||r(),!0))},[r]),f=Z.useCallback(()=>{i(p=>p&&(n==null||n(),!1))},[n]),h=Z.useCallback(()=>{s?f():o()},[f,o,s]);return[s,{open:o,close:f,toggle:h}]}const SE=Z.createContext(null);function T5(){const t=Z.useContext(SE);if(!t)throw new Error("[@mantine/core] MantineProvider was not found in tree");return t}function qQ(){return T5().cssVariablesResolver}function GQ(){return T5().classNamesPrefix}function _E(){return T5().getStyleNonce}const VQ={dark:["#C9C9C9","#b8b8b8","#828282","#696969","#4a4a4a","#404040","#383838","#2e2e2e","#242424","#212121"],gray:["#f8f9fa","#f1f3f5","#e9ecef","#dee2e6","#ced4da","#adb5bd","#868e96","#495057","#343a40","#212529"],red:["#fff5f5","#ffe3e3","#ffc9c9","#ffa8a8","#ff8787","#ff6b6b","#fa5252","#f03e3e","#e03131","#c92a2a"],pink:["#fff0f6","#ffdeeb","#fcc2d7","#faa2c1","#f783ac","#f06595","#e64980","#d6336c","#c2255c","#a61e4d"],grape:["#f8f0fc","#f3d9fa","#eebefa","#e599f7","#da77f2","#cc5de8","#be4bdb","#ae3ec9","#9c36b5","#862e9c"],violet:["#f3f0ff","#e5dbff","#d0bfff","#b197fc","#9775fa","#845ef7","#7950f2","#7048e8","#6741d9","#5f3dc4"],indigo:["#edf2ff","#dbe4ff","#bac8ff","#91a7ff","#748ffc","#5c7cfa","#4c6ef5","#4263eb","#3b5bdb","#364fc7"],blue:["#e7f5ff","#d0ebff","#a5d8ff","#74c0fc","#4dabf7","#339af0","#228be6","#1c7ed6","#1971c2","#1864ab"],cyan:["#e3fafc","#c5f6fa","#99e9f2","#66d9e8","#3bc9db","#22b8cf","#15aabf","#1098ad","#0c8599","#0b7285"],teal:["#e6fcf5","#c3fae8","#96f2d7","#63e6be","#38d9a9","#20c997","#12b886","#0ca678","#099268","#087f5b"],green:["#ebfbee","#d3f9d8","#b2f2bb","#8ce99a","#69db7c","#51cf66","#40c057","#37b24d","#2f9e44","#2b8a3e"],lime:["#f4fce3","#e9fac8","#d8f5a2","#c0eb75","#a9e34b","#94d82d","#82c91e","#74b816","#66a80f","#5c940d"],yellow:["#fff9db","#fff3bf","#ffec99","#ffe066","#ffd43b","#fcc419","#fab005","#f59f00","#f08c00","#e67700"],orange:["#fff4e6","#ffe8cc","#ffd8a8","#ffc078","#ffa94d","#ff922b","#fd7e14","#f76707","#e8590c","#d9480f"]};function b9(t,e){return typeof t.primaryShade=="number"?t.primaryShade:e==="dark"?t.primaryShade.dark:t.primaryShade.light}function PE({color:t,theme:e,colorScheme:r}){if(typeof t!="string")throw new Error(`[@mantine/core] Failed to parse color. Instead got ${typeof t}`);if(t==="white"||t==="black")return{color:t,value:t==="white"?e.white:e.black,shade:void 0,isThemeColor:!1,variable:`--mantine-color-${t}`};const[n,s]=t.split("."),i=s?Number(s):void 0,o=n in e.colors;return o?{color:n,value:i!==void 0?e.colors[n][i]:e.colors[n][b9(e,r||"light")],shade:i,isThemeColor:o,variable:s?`--mantine-color-${n}-${i}`:`--mantine-color-${n}-filled`}:{color:t,value:t,isThemeColor:o,shade:i,variable:void 0}}function Uf(t,e){const r=PE({color:t||e.primaryColor,theme:e});return r.variable?`var(${r.variable})`:t}function v9(t,e){const r={from:(t==null?void 0:t.from)||e.defaultGradient.from,to:(t==null?void 0:t.to)||e.defaultGradient.to,deg:(t==null?void 0:t.deg)||e.defaultGradient.deg||0},n=Uf(r.from,e),s=Uf(r.to,e);return`linear-gradient(${r.deg}deg, ${n} 0%, ${s} 100%)`}function KQ(t){return/^#?([0-9A-F]{3}){1,2}$/i.test(t)}function WQ(t){let e=t.replace("#","");if(e.length===3){const o=e.split("");e=[o[0],o[0],o[1],o[1],o[2],o[2]].join("")}const r=parseInt(e,16),n=r>>16&255,s=r>>8&255,i=r&255;return{r:n,g:s,b:i,a:1}}function JQ(t){const[e,r,n,s]=t.replace(/[^0-9,.]/g,"").split(",").map(Number);return{r:e,g:r,b:n,a:s||1}}function ZQ(t){const e=/^hsla?\(\s*(\d+)\s*,\s*(\d+%)\s*,\s*(\d+%)\s*(,\s*(0?\.\d+|\d+(\.\d+)?))?\s*\)$/i,r=t.match(e);if(!r)return{r:0,g:0,b:0,a:1};const n=parseInt(r[1],10),s=parseInt(r[2],10)/100,i=parseInt(r[3],10)/100,o=r[5]?parseFloat(r[5]):void 0,f=(1-Math.abs(2*i-1))*s,h=n/60,p=f*(1-Math.abs(h%2-1)),b=i-f/2;let v,E,_;return h>=0&&h<1?(v=f,E=p,_=0):h>=1&&h<2?(v=p,E=f,_=0):h>=2&&h<3?(v=0,E=f,_=p):h>=3&&h<4?(v=0,E=p,_=f):h>=4&&h<5?(v=p,E=0,_=f):(v=f,E=0,_=p),{r:Math.round((v+b)*255),g:Math.round((E+b)*255),b:Math.round((_+b)*255),a:o||1}}function LL(t){return KQ(t)?WQ(t):t.startsWith("rgb")?JQ(t):t.startsWith("hsl")?ZQ(t):{r:0,g:0,b:0,a:1}}function Rb(t,e){if(t.startsWith("var("))return t;const{r,g:n,b:s,a:i}=LL(t),o=1-e,f=h=>Math.round(h*o);return`rgba(${f(r)}, ${f(n)}, ${f(s)}, ${i})`}function oi(t,e){if(typeof t!="string"||e>1||e<0)return"rgba(0, 0, 0, 1)";const{r,g:n,b:s}=LL(t);return`rgba(${r}, ${n}, ${s}, ${e})`}const QQ=({color:t,theme:e,variant:r,gradient:n})=>{const s=PE({color:t,theme:e});if(r==="filled")return s.isThemeColor?s.shade===void 0?{background:`var(--mantine-color-${t}-filled)`,hover:`var(--mantine-color-${t}-filled-hover)`,color:"var(--mantine-color-white)",border:`${ke(1)} solid transparent`}:{background:`var(--mantine-color-${s.color}-${s.shade})`,hover:`var(--mantine-color-${s.color}-${s.shade===9?8:s.shade+1})`,color:"var(--mantine-color-white)",border:`${ke(1)} solid transparent`}:{background:t,hover:Rb(t,.1),color:"var(--mantine-color-white)",border:`${ke(1)} solid transparent`};if(r==="light"){if(s.isThemeColor){if(s.shade===void 0)return{background:`var(--mantine-color-${t}-light)`,hover:`var(--mantine-color-${t}-light-hover)`,color:`var(--mantine-color-${t}-light-color)`,border:`${ke(1)} solid transparent`};const i=e.colors[s.color][s.shade];return{background:oi(i,.1),hover:oi(i,.12),color:`var(--mantine-color-${s.color}-${Math.min(s.shade,6)})`,border:`${ke(1)} solid transparent`}}return{background:oi(t,.1),hover:oi(t,.12),color:t,border:`${ke(1)} solid transparent`}}if(r==="outline")return s.isThemeColor?s.shade===void 0?{background:"transparent",hover:`var(--mantine-color-${t}-outline-hover)`,color:`var(--mantine-color-${t}-outline)`,border:`${ke(1)} solid var(--mantine-color-${t}-outline)`}:{background:"transparent",hover:oi(e.colors[s.color][s.shade],.05),color:`var(--mantine-color-${s.color}-${s.shade})`,border:`${ke(1)} solid var(--mantine-color-${s.color}-${s.shade})`}:{background:"transparent",hover:oi(t,.05),color:t,border:`${ke(1)} solid ${t}`};if(r==="subtle"){if(s.isThemeColor){if(s.shade===void 0)return{background:"transparent",hover:`var(--mantine-color-${t}-light-hover)`,color:`var(--mantine-color-${t}-light-color)`,border:`${ke(1)} solid transparent`};const i=e.colors[s.color][s.shade];return{background:"transparent",hover:oi(i,.12),color:`var(--mantine-color-${s.color}-${Math.min(s.shade,6)})`,border:`${ke(1)} solid transparent`}}return{background:"transparent",hover:oi(t,.12),color:t,border:`${ke(1)} solid transparent`}}return r==="transparent"?s.isThemeColor?s.shade===void 0?{background:"transparent",hover:"transparent",color:`var(--mantine-color-${t}-light-color)`,border:`${ke(1)} solid transparent`}:{background:"transparent",hover:"transparent",color:`var(--mantine-color-${s.color}-${Math.min(s.shade,6)})`,border:`${ke(1)} solid transparent`}:{background:"transparent",hover:"transparent",color:t,border:`${ke(1)} solid transparent`}:r==="white"?s.isThemeColor?s.shade===void 0?{background:"var(--mantine-color-white)",hover:Rb(e.white,.01),color:`var(--mantine-color-${t}-filled)`,border:`${ke(1)} solid transparent`}:{background:"var(--mantine-color-white)",hover:Rb(e.white,.01),color:`var(--mantine-color-${s.color}-${s.shade})`,border:`${ke(1)} solid transparent`}:{background:"var(--mantine-color-white)",hover:Rb(e.white,.01),color:t,border:`${ke(1)} solid transparent`}:r==="gradient"?{background:v9(n,e),hover:v9(n,e),color:"var(--mantine-color-white)",border:"none"}:r==="default"?{background:"var(--mantine-color-default)",hover:"var(--mantine-color-default-hover)",color:"var(--mantine-color-default-color)",border:`${ke(1)} solid var(--mantine-color-default-border)`}:{}},jC="-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",CE={scale:1,fontSmoothing:!0,focusRing:"auto",white:"#fff",black:"#000",colors:VQ,primaryShade:{light:6,dark:8},primaryColor:"blue",variantColorResolver:QQ,fontFamily:jC,fontFamilyMonospace:"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace",respectReducedMotion:!1,cursorType:"default",defaultGradient:{from:"blue",to:"cyan",deg:45},defaultRadius:"sm",activeClassName:"mantine-active",focusClassName:"",headings:{fontFamily:jC,fontWeight:"700",sizes:{h1:{fontSize:ke(34),lineHeight:"1.3"},h2:{fontSize:ke(26),lineHeight:"1.35"},h3:{fontSize:ke(22),lineHeight:"1.4"},h4:{fontSize:ke(18),lineHeight:"1.45"},h5:{fontSize:ke(16),lineHeight:"1.5"},h6:{fontSize:ke(14),lineHeight:"1.5"}}},fontSizes:{xs:ke(12),sm:ke(14),md:ke(16),lg:ke(18),xl:ke(20)},lineHeights:{xs:"1.4",sm:"1.45",md:"1.55",lg:"1.6",xl:"1.65"},radius:{xs:ke(2),sm:ke(4),md:ke(8),lg:ke(16),xl:ke(32)},spacing:{xs:ke(10),sm:ke(12),md:ke(16),lg:ke(20),xl:ke(32)},breakpoints:{xs:"36em",sm:"48em",md:"62em",lg:"75em",xl:"88em"},shadows:{xs:`0 ${ke(1)} ${ke(3)} rgba(0, 0, 0, 0.05), 0 ${ke(1)} ${ke(2)} rgba(0, 0, 0, 0.1)`,sm:`0 ${ke(1)} ${ke(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${ke(10)} ${ke(15)} ${ke(-5)}, rgba(0, 0, 0, 0.04) 0 ${ke(7)} ${ke(7)} ${ke(-5)}`,md:`0 ${ke(1)} ${ke(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${ke(20)} ${ke(25)} ${ke(-5)}, rgba(0, 0, 0, 0.04) 0 ${ke(10)} ${ke(10)} ${ke(-5)}`,lg:`0 ${ke(1)} ${ke(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${ke(28)} ${ke(23)} ${ke(-7)}, rgba(0, 0, 0, 0.04) 0 ${ke(12)} ${ke(12)} ${ke(-7)}`,xl:`0 ${ke(1)} ${ke(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${ke(36)} ${ke(28)} ${ke(-7)}, rgba(0, 0, 0, 0.04) 0 ${ke(17)} ${ke(17)} ${ke(-7)}`},other:{},components:{}};function YQ(){const t=console.error;console.error=(...e)=>{e.length>1&&typeof e[0]=="string"&&e[0].toLowerCase().includes("extra attributes from the server")&&typeof e[1]=="string"&&e[1].toLowerCase().includes("data-mantine-color-scheme")||t(...e)}}const XQ="[@mantine/core] MantineProvider: Invalid theme.primaryColor, it accepts only key of theme.colors, learn more – https://mantine.dev/theming/colors/#primary-color",HC="[@mantine/core] MantineProvider: Invalid theme.primaryShade, it accepts only 0-9 integers or an object { light: 0-9, dark: 0-9 }";function C3(t){return t<0||t>9?!1:parseInt(t.toString(),10)===t}function qC(t){if(!(t.primaryColor in t.colors))throw new Error(XQ);if(typeof t.primaryShade=="object"&&(!C3(t.primaryShade.dark)||!C3(t.primaryShade.light)))throw new Error(HC);if(typeof t.primaryShade=="number"&&!C3(t.primaryShade))throw new Error(HC)}function eY(t,e){var n;if(!e)return qC(t),t;const r=vE(t,e);return e.fontFamily&&!((n=e.headings)!=null&&n.fontFamily)&&(r.headings.fontFamily=e.fontFamily),qC(r),r}const IE=Z.createContext(null),tY=()=>Z.useContext(IE)||CE;function za(){const t=Z.useContext(IE);if(!t)throw new Error("@mantine/core: MantineProvider was not found in component tree, make sure you have it in your app");return t}function DL({theme:t,children:e,inherit:r=!0}){const n=tY(),s=Z.useMemo(()=>eY(r?n:CE,t),[t,n,r]);return ue.createElement(IE.Provider,{value:s},e)}DL.displayName="@mantine/core/MantineThemeProvider";function I3(t){return Object.entries(t).map(([e,r])=>`${e}: ${r};`).join("")}function T3(t,e){return(Array.isArray(t)?t:[t]).reduce((n,s)=>`${s}{${n}}`,e)}function rY(t,e){const r=I3(t.variables),n=r?T3(e,r):"",s=I3(t.dark),i=s?T3(`${e}[data-mantine-color-scheme="dark"]`,s):"",o=I3(t.light),f=o?T3(`${e}[data-mantine-color-scheme="light"]`,o):"";return`${n}${i}${f}`}function Zl(t,e,r){Bn(e).forEach(n=>Object.assign(t,{[`--mantine-${r}-${n}`]:e[n]}))}const $L=t=>{const e=b9(t,"dark"),r=b9(t,"light"),n=t.defaultRadius in t.radius?t.radius[t.defaultRadius]:ke(t.defaultRadius),s={variables:{"--mantine-scale":t.scale.toString(),"--mantine-cursor-type":t.cursorType,"--mantine-webkit-font-smoothing":t.fontSmoothing?"antialiased":"unset","--mantine-color-scheme":"light dark","--mantine-moz-font-smoothing":t.fontSmoothing?"grayscale":"unset","--mantine-color-white":t.white,"--mantine-color-black":t.black,"--mantine-line-height":t.lineHeights.md,"--mantine-font-family":t.fontFamily,"--mantine-font-family-monospace":t.fontFamilyMonospace,"--mantine-font-family-headings":t.headings.fontFamily,"--mantine-heading-font-weight":t.headings.fontWeight,"--mantine-radius-default":n,"--mantine-primary-color-filled":`var(--mantine-color-${t.primaryColor}-filled)`,"--mantine-primary-color-filled-hover":`var(--mantine-color-${t.primaryColor}-filled-hover)`,"--mantine-primary-color-light":`var(--mantine-color-${t.primaryColor}-light)`,"--mantine-primary-color-light-hover":`var(--mantine-color-${t.primaryColor}-light-hover)`,"--mantine-primary-color-light-color":`var(--mantine-color-${t.primaryColor}-light-color)`},light:{"--mantine-color-bright":"var(--mantine-color-black)","--mantine-color-text":t.black,"--mantine-color-body":t.white,"--mantine-color-error":"var(--mantine-color-red-6)","--mantine-color-placeholder":"var(--mantine-color-gray-5)","--mantine-color-anchor":`var(--mantine-color-${t.primaryColor}-${r})`,"--mantine-color-default":"var(--mantine-color-white)","--mantine-color-default-hover":"var(--mantine-color-gray-0)","--mantine-color-default-color":"var(--mantine-color-black)","--mantine-color-default-border":"var(--mantine-color-gray-4)"},dark:{"--mantine-color-bright":"var(--mantine-color-white)","--mantine-color-text":"var(--mantine-color-dark-0)","--mantine-color-body":"var(--mantine-color-dark-7)","--mantine-color-error":"var(--mantine-color-red-8)","--mantine-color-placeholder":"var(--mantine-color-dark-3)","--mantine-color-anchor":`var(--mantine-color-${t.primaryColor}-4)`,"--mantine-color-default":"var(--mantine-color-dark-6)","--mantine-color-default-hover":"var(--mantine-color-dark-5)","--mantine-color-default-color":"var(--mantine-color-white)","--mantine-color-default-border":"var(--mantine-color-dark-4)"}};Zl(s.variables,t.breakpoints,"breakpoint"),Zl(s.variables,t.spacing,"spacing"),Zl(s.variables,t.fontSizes,"font-size"),Zl(s.variables,t.lineHeights,"line-height"),Zl(s.variables,t.shadows,"shadow"),Zl(s.variables,t.radius,"radius"),Bn(t.colors).forEach(o=>{t.colors[o].forEach((p,b)=>{s.variables[`--mantine-color-${o}-${b}`]=p});const f=`var(--mantine-color-${o}-${r===9?8:r+1})`,h=`var(--mantine-color-${o}-${e===9?8:e+1})`;s.light["--mantine-color-dimmed"]="var(--mantine-color-gray-6)",s.light[`--mantine-color-${o}-text`]=`var(--mantine-color-${o}-filled)`,s.light[`--mantine-color-${o}-filled`]=`var(--mantine-color-${o}-${r})`,s.light[`--mantine-color-${o}-filled-hover`]=f,s.light[`--mantine-color-${o}-light`]=oi(t.colors[o][r],.1),s.light[`--mantine-color-${o}-light-hover`]=oi(t.colors[o][r],.12),s.light[`--mantine-color-${o}-light-color`]=`var(--mantine-color-${o}-${r})`,s.light[`--mantine-color-${o}-outline`]=`var(--mantine-color-${o}-${r})`,s.light[`--mantine-color-${o}-outline-hover`]=oi(t.colors[o][r],.05),s.dark["--mantine-color-dimmed"]="var(--mantine-color-dark-2)",s.dark[`--mantine-color-${o}-text`]=`var(--mantine-color-${o}-4)`,s.dark[`--mantine-color-${o}-filled`]=`var(--mantine-color-${o}-${e})`,s.dark[`--mantine-color-${o}-filled-hover`]=h,s.dark[`--mantine-color-${o}-light`]=oi(t.colors[o][Math.max(0,e-2)],.15),s.dark[`--mantine-color-${o}-light-hover`]=oi(t.colors[o][Math.max(0,e-2)],.2),s.dark[`--mantine-color-${o}-light-color`]=`var(--mantine-color-${o}-${Math.max(e-5,0)})`,s.dark[`--mantine-color-${o}-outline`]=`var(--mantine-color-${o}-${Math.max(e-4,0)})`,s.dark[`--mantine-color-${o}-outline-hover`]=oi(t.colors[o][Math.max(e-4,0)],.05)});const i=t.headings.sizes;return Bn(i).forEach(o=>{s.variables[`--mantine-${o}-font-size`]=i[o].fontSize,s.variables[`--mantine-${o}-line-height`]=i[o].lineHeight,s.variables[`--mantine-${o}-font-weight`]=i[o].fontWeight||t.headings.fontWeight}),s};function nY({theme:t,generator:e}){const r=$L(t),n=e==null?void 0:e(t);return n?vE(r,n):r}const k3=$L(CE);function iY(t){const e={variables:{},light:{},dark:{}};return Bn(t.variables).forEach(r=>{k3.variables[r]!==t.variables[r]&&(e.variables[r]=t.variables[r])}),Bn(t.light).forEach(r=>{k3.light[r]!==t.light[r]&&(e.light[r]=t.light[r])}),Bn(t.dark).forEach(r=>{k3.dark[r]!==t.dark[r]&&(e.dark[r]=t.dark[r])}),e}function sY(t){return` - ${t}[data-mantine-color-scheme="dark"] { --mantine-color-scheme: dark; } - ${t}[data-mantine-color-scheme="light"] { --mantine-color-scheme: light; } -`}function FL({cssVariablesSelector:t}){const e=za(),r=_E(),n=qQ(),s=nY({theme:e,generator:n}),i=t===":root",o=i?iY(s):s,f=rY(o,t);return f?ue.createElement("style",{"data-mantine-styles":!0,nonce:r==null?void 0:r(),dangerouslySetInnerHTML:{__html:`${f}${i?"":sY(t)}`}}):null}FL.displayName="@mantine/CssVariables";function oY(){const t=za(),e=_E(),r=Bn(t.breakpoints).reduce((n,s)=>{const i=m9(t.breakpoints[s]);return`${n}@media (max-width: ${F2(i-.1)}) {.mantine-visible-from-${s} {display: none !important;}}@media (min-width: ${F2(i)}) {.mantine-hidden-from-${s} {display: none !important;}}`},"");return ue.createElement("style",{"data-mantine-styles":"classes",nonce:e==null?void 0:e(),dangerouslySetInnerHTML:{__html:r}})}function GC(t){return t==="auto"||t==="dark"||t==="light"}function aY({key:t="mantine-color-scheme-value"}={}){let e;return{get:r=>{if(typeof window>"u")return r;try{const n=window.localStorage.getItem(t);return GC(n)?n:r}catch{return r}},set:r=>{try{window.localStorage.setItem(t,r)}catch(n){console.warn("[@mantine/core] Local storage color scheme manager was unable to save color scheme.",n)}},subscribe:r=>{e=n=>{n.storageArea===window.localStorage&&n.key===t&&GC(n.newValue)&&r(n.newValue)},window.addEventListener("storage",e)},unsubscribe:()=>{window.removeEventListener("storage",e)},clear:()=>{window.localStorage.removeItem(t)}}}function z1(t,e){var n;const r=t!=="auto"?t:window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";(n=e())==null||n.setAttribute("data-mantine-color-scheme",r)}function fY({manager:t,defaultColorScheme:e,getRootElement:r,forceColorScheme:n}){const s=Z.useRef(),[i,o]=Z.useState(()=>t.get(e)),f=n||i,h=Z.useCallback(b=>{n||(z1(b,r),o(b),t.set(b))},[t.set,f,n]),p=Z.useCallback(()=>{o(e),z1(e,r),t.clear()},[t.clear,e]);return Z.useEffect(()=>(t.subscribe(h),t.unsubscribe),[t.subscribe,t.unsubscribe]),my(()=>{z1(t.get(e),r)},[]),Z.useEffect(()=>{var v;if(n)return z1(n,r),()=>{};s.current=window.matchMedia("(prefers-color-scheme: dark)");const b=E=>{i==="auto"&&z1(E.matches?"dark":"light",r)};return(v=s.current)==null||v.addEventListener("change",b),()=>{var E;return(E=s.current)==null?void 0:E.removeEventListener("change",b)}},[i,n]),{colorScheme:f,setColorScheme:h,clearColorScheme:p}}function cY({respectReducedMotion:t,getRootElement:e}){my(()=>{var r;t&&((r=e())==null||r.setAttribute("data-respect-reduced-motion","true"))},[t])}YQ();function UL({theme:t,children:e,getStyleNonce:r,withCssVariables:n=!0,cssVariablesSelector:s=":root",classNamesPrefix:i="mantine",colorSchemeManager:o=aY(),defaultColorScheme:f="light",getRootElement:h=()=>document.documentElement,cssVariablesResolver:p,forceColorScheme:b}){const{colorScheme:v,setColorScheme:E,clearColorScheme:_}=fY({defaultColorScheme:f,forceColorScheme:b,manager:o,getRootElement:h});return cY({respectReducedMotion:(t==null?void 0:t.respectReducedMotion)||!1,getRootElement:h}),ue.createElement(SE.Provider,{value:{colorSchemeManager:o,colorScheme:v,setColorScheme:E,clearColorScheme:_,getRootElement:h,classNamesPrefix:i,getStyleNonce:r,cssVariablesResolver:p,cssVariablesSelector:s}},ue.createElement(DL,{theme:t},n&&ue.createElement(FL,{cssVariablesSelector:s}),ue.createElement(oY,null),e))}UL.displayName="@mantine/core/MantineProvider";const uY={always:"mantine-focus-always",auto:"mantine-focus-auto",never:"mantine-focus-never"};function lY({theme:t,options:e,unstyled:r}){return En((e==null?void 0:e.focusable)&&!r&&(t.focusClassName||uY[t.focusRing]),(e==null?void 0:e.active)&&!r&&t.activeClassName)}function hY({themeName:t,classNamesPrefix:e,selector:r}){return t.map(n=>`${e}-${n}-${r}`)}function dY({themeName:t,theme:e,selector:r,props:n,stylesCtx:s}){return t.map(i=>{var o,f;return(f=EE({theme:e,classNames:(o=e.components[i])==null?void 0:o.classNames,props:n,stylesCtx:s}))==null?void 0:f[r]})}function pY({options:t,classes:e,selector:r,unstyled:n}){return t!=null&&t.variant&&!n?e[`${r}--${t.variant}`]:void 0}function mY({rootSelector:t,selector:e,className:r}){return t===e?r:void 0}function gY({selector:t,classes:e,unstyled:r}){return r?void 0:e[t]}function yY({selector:t,stylesCtx:e,theme:r,classNames:n,props:s}){return EE({theme:r,classNames:n,props:s,stylesCtx:e})[t]}function bY({selector:t,stylesCtx:e,options:r,props:n,theme:s}){return EE({theme:s,classNames:r==null?void 0:r.classNames,props:(r==null?void 0:r.props)||n,stylesCtx:e})[t]}function vY({theme:t,options:e,themeName:r,selector:n,classNamesPrefix:s,classNames:i,classes:o,unstyled:f,className:h,rootSelector:p,props:b,stylesCtx:v}){return En(lY({theme:t,options:e,unstyled:f}),dY({theme:t,themeName:r,selector:n,props:b,stylesCtx:v}),pY({options:e,classes:o,selector:n,unstyled:f}),yY({selector:n,stylesCtx:v,theme:t,classNames:i,props:b}),bY({selector:n,stylesCtx:v,options:e,props:b,theme:t}),mY({rootSelector:p,selector:n,className:h}),gY({selector:n,classes:o,unstyled:f}),hY({themeName:r,classNamesPrefix:s,selector:n}),e==null?void 0:e.className)}function xY({theme:t,themeName:e,props:r,stylesCtx:n,selector:s}){return e.map(i=>{var o;return g9({theme:t,styles:(o=t.components[i])==null?void 0:o.styles,props:r,stylesCtx:n})[s]}).reduce((i,o)=>({...i,...o}),{})}function x9({style:t,theme:e}){return Array.isArray(t)?[...t].reduce((r,n)=>({...r,...x9({style:n,theme:e})}),{}):typeof t=="function"?t(e):t??{}}function wY(t){return t.reduce((e,r)=>(r&&Object.keys(r).forEach(n=>{e[n]={...e[n],...xE(r[n])}}),e),{})}function AY({vars:t,varsResolver:e,theme:r,props:n,stylesCtx:s,selector:i,themeName:o}){var f;return(f=wY([e==null?void 0:e(r,n,s),...o.map(h=>{var p,b,v;return(v=(b=(p=r.components)==null?void 0:p[h])==null?void 0:b.vars)==null?void 0:v.call(b,r,n,s)}),t==null?void 0:t(r,n,s)]))==null?void 0:f[i]}function EY({theme:t,themeName:e,selector:r,options:n,props:s,stylesCtx:i,rootSelector:o,styles:f,style:h,vars:p,varsResolver:b}){return{...xY({theme:t,themeName:e,props:s,stylesCtx:i,selector:r}),...g9({theme:t,styles:f,props:s,stylesCtx:i})[r],...g9({theme:t,styles:n==null?void 0:n.styles,props:(n==null?void 0:n.props)||s,stylesCtx:i})[r],...AY({theme:t,props:s,stylesCtx:i,vars:p,varsResolver:b,selector:r,themeName:e}),...o===r?x9({style:h,theme:t}):null,...x9({style:n==null?void 0:n.style,theme:t})}}function Dt({name:t,classes:e,props:r,stylesCtx:n,className:s,style:i,rootSelector:o="root",unstyled:f,classNames:h,styles:p,vars:b,varsResolver:v}){const E=za(),_=GQ(),S=(Array.isArray(t)?t:[t]).filter(P=>P);return(P,I)=>({className:vY({theme:E,options:I,themeName:S,selector:P,classNamesPrefix:_,classNames:h,classes:e,unstyled:f,className:s,rootSelector:o,props:r,stylesCtx:n}),style:EY({theme:E,themeName:S,selector:P,options:I,props:r,stylesCtx:n,rootSelector:o,styles:p,style:i,vars:b,varsResolver:v})})}function VC(){const t=document.createElement("style");return t.innerHTML="*, *::before, *::after {transition: none !important;}",t.setAttribute("data-mantine-disable-transition","true"),document.head.appendChild(t),()=>document.querySelectorAll("[data-mantine-disable-transition]").forEach(r=>r.remove())}function TE({keepTransitions:t}={}){const e=Z.useRef(),r=Z.useRef(),n=Z.useContext(SE);if(!n)throw new Error("[@mantine/core] MantineProvider was not found in tree");const s=p=>{n.setColorScheme(p),e.current=t?()=>{}:VC(),window.clearTimeout(r.current),r.current=window.setTimeout(()=>{var b;(b=e.current)==null||b.call(e)},10)},i=()=>{n.clearColorScheme(),e.current=t?()=>{}:VC(),window.clearTimeout(r.current),r.current=window.setTimeout(()=>{var p;(p=e.current)==null||p.call(e)},10)},o=BQ("light",{getInitialValueInEffect:!1}),f=n.colorScheme==="auto"?o:n.colorScheme,h=Z.useCallback(()=>s(f==="light"?"dark":"light"),[s,f]);return Z.useEffect(()=>()=>{var p;(p=e.current)==null||p.call(e),window.clearTimeout(r.current)},[]),{colorScheme:n.colorScheme,setColorScheme:s,clearColorScheme:i,toggleColorScheme:h}}function We(t,e,r){var o;const n=za(),s=(o=n.components[t])==null?void 0:o.defaultProps,i=typeof s=="function"?s(n):s;return{...e,...i,...xE(r)}}function KC(t){return Bn(t).reduce((e,r)=>t[r]!==void 0?`${e}${xQ(r)}:${t[r]};`:e,"").trim()}function MY({selector:t,styles:e,media:r}){const n=e?KC(e):"",s=Array.isArray(r)?r.map(i=>`@media${i.query}{${t}{${KC(i.styles)}}}`):[];return`${n?`${t}{${n}}`:""}${s.join("")}`.trim()}function zL({selector:t,styles:e,media:r}){const n=_E();return ue.createElement("style",{"data-mantine-styles":"inline",nonce:n==null?void 0:n(),dangerouslySetInnerHTML:{__html:MY({selector:t,styles:e,media:r})}})}function kE(t){const{m:e,mx:r,my:n,mt:s,mb:i,ml:o,mr:f,p:h,px:p,py:b,pt:v,pb:E,pl:_,pr:S,bg:P,c:I,opacity:C,ff:T,fz:B,fw:N,lts:$,ta:H,lh:J,fs:Q,tt:K,td:se,w,miw:a,maw:u,h:l,mih:d,mah:m,bgsz:x,bgp:A,bgr:y,bga:c,pos:g,top:M,left:R,bottom:L,right:k,inset:D,display:U,hiddenFrom:V,visibleFrom:G,lightHidden:Y,darkHidden:q,...z}=t;return{styleProps:xE({m:e,mx:r,my:n,mt:s,mb:i,ml:o,mr:f,p:h,px:p,py:b,pt:v,pb:E,pl:_,pr:S,bg:P,c:I,opacity:C,ff:T,fz:B,fw:N,lts:$,ta:H,lh:J,fs:Q,tt:K,td:se,w,miw:a,maw:u,h:l,mih:d,mah:m,bgsz:x,bgp:A,bgr:y,bga:c,pos:g,top:M,left:R,bottom:L,right:k,inset:D,display:U,hiddenFrom:V,visibleFrom:G,lightHidden:Y,darkHidden:q}),rest:z}}const SY={m:{type:"spacing",property:"margin"},mt:{type:"spacing",property:"marginTop"},mb:{type:"spacing",property:"marginBottom"},ml:{type:"spacing",property:"marginLeft"},mr:{type:"spacing",property:"marginRight"},mx:{type:"spacing",property:["marginRight","marginLeft"]},my:{type:"spacing",property:["marginTop","marginBottom"]},p:{type:"spacing",property:"padding"},pt:{type:"spacing",property:"paddingTop"},pb:{type:"spacing",property:"paddingBottom"},pl:{type:"spacing",property:"paddingLeft"},pr:{type:"spacing",property:"paddingRight"},px:{type:"spacing",property:["paddingRight","paddingLeft"]},py:{type:"spacing",property:["paddingTop","paddingBottom"]},bg:{type:"color",property:"background"},c:{type:"color",property:"color"},opacity:{type:"identity",property:"opacity"},ff:{type:"identity",property:"fontFamily"},fz:{type:"fontSize",property:"fontSize"},fw:{type:"identity",property:"fontWeight"},lts:{type:"size",property:"letterSpacing"},ta:{type:"identity",property:"textAlign"},lh:{type:"lineHeight",property:"lineHeight"},fs:{type:"identity",property:"fontStyle"},tt:{type:"identity",property:"textTransform"},td:{type:"identity",property:"textDecoration"},w:{type:"spacing",property:"width"},miw:{type:"spacing",property:"minWidth"},maw:{type:"spacing",property:"maxWidth"},h:{type:"spacing",property:"height"},mih:{type:"spacing",property:"minHeight"},mah:{type:"spacing",property:"maxHeight"},bgsz:{type:"size",property:"backgroundSize"},bgp:{type:"identity",property:"backgroundPosition"},bgr:{type:"identity",property:"backgroundRepeat"},bga:{type:"identity",property:"backgroundAttachment"},pos:{type:"identity",property:"position"},top:{type:"identity",property:"top"},left:{type:"size",property:"left"},bottom:{type:"size",property:"bottom"},right:{type:"size",property:"right"},inset:{type:"size",property:"inset"},display:{type:"identity",property:"display"}};function _Y(t,e){const r=PE({color:t,theme:e});return r.color==="dimmed"?"var(--mantine-color-dimmed)":r.color==="bright"?"var(--mantine-color-bright)":r.isThemeColor&&r.shade===void 0?`var(--mantine-color-${r.color}-text)`:r.variable?`var(${r.variable})`:r.color}function PY(t,e){return typeof t=="string"&&t in e.fontSizes?`var(--mantine-font-size-${t})`:typeof t=="number"||typeof t=="string"?ke(t):t}function CY(t,e){if(typeof t=="number")return ke(t);if(typeof t=="string"){const r=t.replace("-","");if(!(r in e.spacing))return ke(t);const n=`--mantine-spacing-${r}`;return t.startsWith("-")?`calc(var(${n}) * -1)`:`var(${n})`}return t}function IY(t){return t}function TY(t){return typeof t=="number"?ke(t):t}function kY(t,e){return typeof t=="string"&&t in e.fontSizes?`var(--mantine-line-height-${t})`:t}const R3={color:_Y,fontSize:PY,spacing:CY,identity:IY,size:TY,lineHeight:kY};function WC(t){return t.replace("(min-width: ","").replace("em)","")}function RY({media:t,...e}){const n=Object.keys(t).sort((s,i)=>Number(WC(s))-Number(WC(i))).map(s=>({query:s,styles:t[s]}));return{...e,media:n}}function BY(t){if(typeof t!="object"||t===null)return!1;const e=Object.keys(t);return!(e.length===1&&e[0]==="base")}function OY(t){return typeof t=="object"&&t!==null?"base"in t?t.base:void 0:t}function NY(t){return typeof t=="object"&&t!==null?Bn(t).filter(e=>e!=="base"):[]}function LY(t,e){return typeof t=="object"&&t!==null&&e in t?t[e]:t}function DY({styleProps:t,data:e,theme:r}){return RY(Bn(t).reduce((n,s)=>{if(s==="hiddenFrom"||s==="visibleFrom")return n;const i=e[s],o=Array.isArray(i.property)?i.property:[i.property],f=OY(t[s]);if(!BY(t[s]))return o.forEach(p=>{n.inlineStyles[p]=R3[i.type](f,r)}),n;n.hasResponsiveStyles=!0;const h=NY(t[s]);return o.forEach(p=>{f&&(n.styles[p]=R3[i.type](f,r)),h.forEach(b=>{const v=`(min-width: ${r.breakpoints[b]})`;n.media[v]={...n.media[v],[p]:R3[i.type](LY(t[s],b),r)}})}),n},{hasResponsiveStyles:!1,styles:{},inlineStyles:{},media:{}}))}function $Y(){return`__m__-${Z.useId().replace(/:/g,"")}`}function jL(t,e){return Array.isArray(t)?[...t].reduce((r,n)=>({...r,...jL(n,e)}),{}):typeof t=="function"?t(e):t??{}}function w9(t,e){return Array.isArray(t)?[...t].reduce((r,n)=>({...r,...w9(n,e)}),{}):typeof t=="function"?t(e):t??{}}function FY({theme:t,style:e,vars:r,styleProps:n}){const s=w9(e,t),i=w9(r,t);return{...s,...i,...n}}function HL(t){return t.startsWith("data-")?t:`data-${t}`}function UY(t){return Object.keys(t).reduce((e,r)=>{const n=t[r];return n===void 0||n===""||n===!1||n===null||(e[HL(r)]=t[r]),e},{})}function qL(t){return t?typeof t=="string"?{[HL(t)]:!0}:Array.isArray(t)?[...t].reduce((e,r)=>({...e,...qL(r)}),{}):UY(t):null}const GL=Z.forwardRef(({component:t,style:e,__vars:r,className:n,variant:s,mod:i,size:o,hiddenFrom:f,visibleFrom:h,lightHidden:p,darkHidden:b,renderRoot:v,...E},_)=>{const S=za(),P=t||"div",{styleProps:I,rest:C}=kE(E),T=$Y(),B=DY({styleProps:I,theme:S,data:SY}),N={ref:_,style:FY({theme:S,style:e,vars:r,styleProps:B.inlineStyles}),className:En(n,{[T]:B.hasResponsiveStyles,"mantine-light-hidden":p,"mantine-dark-hidden":b,[`mantine-hidden-from-${f}`]:f,[`mantine-visible-from-${h}`]:h}),"data-variant":s,"data-size":ML(o)?void 0:o||void 0,...qL(i),...C};return ue.createElement(ue.Fragment,null,B.hasResponsiveStyles&&ue.createElement(zL,{selector:`.${T}`,styles:B.styles,media:B.media}),typeof v=="function"?v(N):ue.createElement(P,{...N}))});GL.displayName="@mantine/core/Box";const st=GL;function VL(t){return t}function mt(t){const e=Z.forwardRef(t);return e.extend=VL,e}function Ui(t){const e=Z.forwardRef(t);return e.extend=VL,e}const zY=Z.createContext({dir:"ltr",toggleDirection:()=>{},setDirection:()=>{}});function RE(){return Z.useContext(zY)}var KL={root:"m-87cf2631"};const jY={__staticSelector:"UnstyledButton"},gy=Ui((t,e)=>{const r=We("UnstyledButton",jY,t),{className:n,component:s="button",__staticSelector:i,unstyled:o,classNames:f,styles:h,style:p,...b}=r,v=Dt({name:i,props:r,classes:KL,className:n,style:p,classNames:f,styles:h,unstyled:o});return ue.createElement(st,{...v("root",{focusable:!0}),component:s,ref:e,type:s==="button"?"button":void 0,...b})});gy.classes=KL;gy.displayName="@mantine/core/UnstyledButton";var WL={root:"m-1b7284a3"};const HY={},qY=(t,{radius:e,shadow:r})=>({root:{"--paper-radius":e===void 0?void 0:ri(e),"--paper-shadow":wE(r)}}),zf=Ui((t,e)=>{const r=We("Paper",HY,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,withBorder:h,vars:p,radius:b,shadow:v,variant:E,..._}=r,S=Dt({name:"Paper",props:r,classes:WL,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:p,varsResolver:qY});return ue.createElement(st,{ref:e,mod:{"data-with-border":h},...S("root"),variant:E,..._})});zf.classes=WL;zf.displayName="@mantine/core/Paper";const Go=Math.min,Zn=Math.max,U2=Math.round,Bb=Math.floor,yc=t=>({x:t,y:t}),GY={left:"right",right:"left",bottom:"top",top:"bottom"},VY={start:"end",end:"start"};function A9(t,e,r){return Zn(t,Go(e,r))}function jf(t,e){return typeof t=="function"?t(e):t}function Vo(t){return t.split("-")[0]}function r1(t){return t.split("-")[1]}function BE(t){return t==="x"?"y":"x"}function OE(t){return t==="y"?"height":"width"}function Ml(t){return["top","bottom"].includes(Vo(t))?"y":"x"}function NE(t){return BE(Ml(t))}function KY(t,e,r){r===void 0&&(r=!1);const n=r1(t),s=NE(t),i=OE(s);let o=s==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[i]>e.floating[i]&&(o=z2(o)),[o,z2(o)]}function WY(t){const e=z2(t);return[E9(t),e,E9(e)]}function E9(t){return t.replace(/start|end/g,e=>VY[e])}function JY(t,e,r){const n=["left","right"],s=["right","left"],i=["top","bottom"],o=["bottom","top"];switch(t){case"top":case"bottom":return r?e?s:n:e?n:s;case"left":case"right":return e?i:o;default:return[]}}function ZY(t,e,r,n){const s=r1(t);let i=JY(Vo(t),r==="start",n);return s&&(i=i.map(o=>o+"-"+s),e&&(i=i.concat(i.map(E9)))),i}function z2(t){return t.replace(/left|right|bottom|top/g,e=>GY[e])}function QY(t){return{top:0,right:0,bottom:0,left:0,...t}}function LE(t){return typeof t!="number"?QY(t):{top:t,right:t,bottom:t,left:t}}function ip(t){return{...t,top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height}}function JC(t,e,r){let{reference:n,floating:s}=t;const i=Ml(e),o=NE(e),f=OE(o),h=Vo(e),p=i==="y",b=n.x+n.width/2-s.width/2,v=n.y+n.height/2-s.height/2,E=n[f]/2-s[f]/2;let _;switch(h){case"top":_={x:b,y:n.y-s.height};break;case"bottom":_={x:b,y:n.y+n.height};break;case"right":_={x:n.x+n.width,y:v};break;case"left":_={x:n.x-s.width,y:v};break;default:_={x:n.x,y:n.y}}switch(r1(e)){case"start":_[o]-=E*(r&&p?-1:1);break;case"end":_[o]+=E*(r&&p?-1:1);break}return _}const YY=async(t,e,r)=>{const{placement:n="bottom",strategy:s="absolute",middleware:i=[],platform:o}=r,f=i.filter(Boolean),h=await(o.isRTL==null?void 0:o.isRTL(e));let p=await o.getElementRects({reference:t,floating:e,strategy:s}),{x:b,y:v}=JC(p,n,h),E=n,_={},S=0;for(let P=0;P({name:"arrow",options:t,async fn(e){const{x:r,y:n,placement:s,rects:i,platform:o,elements:f,middlewareData:h}=e,{element:p,padding:b=0}=jf(t,e)||{};if(p==null)return{};const v=LE(b),E={x:r,y:n},_=NE(s),S=OE(_),P=await o.getDimensions(p),I=_==="y",C=I?"top":"left",T=I?"bottom":"right",B=I?"clientHeight":"clientWidth",N=i.reference[S]+i.reference[_]-E[_]-i.floating[S],$=E[_]-i.reference[_],H=await(o.getOffsetParent==null?void 0:o.getOffsetParent(p));let J=H?H[B]:0;(!J||!await(o.isElement==null?void 0:o.isElement(H)))&&(J=f.floating[B]||i.floating[S]);const Q=N/2-$/2,K=J/2-P[S]/2-1,se=Go(v[C],K),w=Go(v[T],K),a=se,u=J-P[S]-w,l=J/2-P[S]/2+Q,d=A9(a,l,u),m=!h.arrow&&r1(s)!=null&&l!=d&&i.reference[S]/2-(la<=0)){var K,se;const a=(((K=i.flip)==null?void 0:K.index)||0)+1,u=$[a];if(u)return{data:{index:a,overflows:Q},reset:{placement:u}};let l=(se=Q.filter(d=>d.overflows[0]<=0).sort((d,m)=>d.overflows[1]-m.overflows[1])[0])==null?void 0:se.placement;if(!l)switch(_){case"bestFit":{var w;const d=(w=Q.map(m=>[m.placement,m.overflows.filter(x=>x>0).reduce((x,A)=>x+A,0)]).sort((m,x)=>m[1]-x[1])[0])==null?void 0:w[0];d&&(l=d);break}case"initialPlacement":l=f;break}if(s!==l)return{reset:{placement:l}}}return{}}}};function ZL(t){const e=Go(...t.map(i=>i.left)),r=Go(...t.map(i=>i.top)),n=Zn(...t.map(i=>i.right)),s=Zn(...t.map(i=>i.bottom));return{x:e,y:r,width:n-e,height:s-r}}function XY(t){const e=t.slice().sort((s,i)=>s.y-i.y),r=[];let n=null;for(let s=0;sn.height/2?r.push([i]):r[r.length-1].push(i),n=i}return r.map(s=>ip(ZL(s)))}const QL=function(t){return t===void 0&&(t={}),{name:"inline",options:t,async fn(e){const{placement:r,elements:n,rects:s,platform:i,strategy:o}=e,{padding:f=2,x:h,y:p}=jf(t,e),b=Array.from(await(i.getClientRects==null?void 0:i.getClientRects(n.reference))||[]),v=XY(b),E=ip(ZL(b)),_=LE(f);function S(){if(v.length===2&&v[0].left>v[1].right&&h!=null&&p!=null)return v.find(I=>h>I.left-_.left&&hI.top-_.top&&p=2){if(Ml(r)==="y"){const se=v[0],w=v[v.length-1],a=Vo(r)==="top",u=se.top,l=w.bottom,d=a?se.left:w.left,m=a?se.right:w.right,x=m-d,A=l-u;return{top:u,bottom:l,left:d,right:m,width:x,height:A,x:d,y:u}}const I=Vo(r)==="left",C=Zn(...v.map(se=>se.right)),T=Go(...v.map(se=>se.left)),B=v.filter(se=>I?se.left===T:se.right===C),N=B[0].top,$=B[B.length-1].bottom,H=T,J=C,Q=J-H,K=$-N;return{top:N,bottom:$,left:H,right:J,width:Q,height:K,x:H,y:N}}return E}const P=await i.getElementRects({reference:{getBoundingClientRect:S},floating:n.floating,strategy:o});return s.reference.x!==P.reference.x||s.reference.y!==P.reference.y||s.reference.width!==P.reference.width||s.reference.height!==P.reference.height?{reset:{rects:P}}:{}}}};async function eX(t,e){const{placement:r,platform:n,elements:s}=t,i=await(n.isRTL==null?void 0:n.isRTL(s.floating)),o=Vo(r),f=r1(r),h=Ml(r)==="y",p=["left","top"].includes(o)?-1:1,b=i&&h?-1:1,v=jf(e,t);let{mainAxis:E,crossAxis:_,alignmentAxis:S}=typeof v=="number"?{mainAxis:v,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...v};return f&&typeof S=="number"&&(_=f==="end"?S*-1:S),h?{x:_*b,y:E*p}:{x:E*p,y:_*b}}const YL=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var r,n;const{x:s,y:i,placement:o,middlewareData:f}=e,h=await eX(e,t);return o===((r=f.offset)==null?void 0:r.placement)&&(n=f.arrow)!=null&&n.alignmentOffset?{}:{x:s+h.x,y:i+h.y,data:{...h,placement:o}}}}},$E=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:r,y:n,placement:s}=e,{mainAxis:i=!0,crossAxis:o=!1,limiter:f={fn:I=>{let{x:C,y:T}=I;return{x:C,y:T}}},...h}=jf(t,e),p={x:r,y:n},b=await DE(e,h),v=Ml(Vo(s)),E=BE(v);let _=p[E],S=p[v];if(i){const I=E==="y"?"top":"left",C=E==="y"?"bottom":"right",T=_+b[I],B=_-b[C];_=A9(T,_,B)}if(o){const I=v==="y"?"top":"left",C=v==="y"?"bottom":"right",T=S+b[I],B=S-b[C];S=A9(T,S,B)}const P=f.fn({...e,[E]:_,[v]:S});return{...P,data:{x:P.x-r,y:P.y-n}}}}},tX=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:r,y:n,placement:s,rects:i,middlewareData:o}=e,{offset:f=0,mainAxis:h=!0,crossAxis:p=!0}=jf(t,e),b={x:r,y:n},v=Ml(s),E=BE(v);let _=b[E],S=b[v];const P=jf(f,e),I=typeof P=="number"?{mainAxis:P,crossAxis:0}:{mainAxis:0,crossAxis:0,...P};if(h){const B=E==="y"?"height":"width",N=i.reference[E]-i.floating[B]+I.mainAxis,$=i.reference[E]+i.reference[B]-I.mainAxis;_$&&(_=$)}if(p){var C,T;const B=E==="y"?"width":"height",N=["top","left"].includes(Vo(s)),$=i.reference[v]-i.floating[B]+(N&&((C=o.offset)==null?void 0:C[v])||0)+(N?0:I.crossAxis),H=i.reference[v]+i.reference[B]+(N?0:((T=o.offset)==null?void 0:T[v])||0)-(N?I.crossAxis:0);S<$?S=$:S>H&&(S=H)}return{[E]:_,[v]:S}}}},rX=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){const{placement:r,rects:n,platform:s,elements:i}=e,{apply:o=()=>{},...f}=jf(t,e),h=await DE(e,f),p=Vo(r),b=r1(r),v=Ml(r)==="y",{width:E,height:_}=n.floating;let S,P;p==="top"||p==="bottom"?(S=p,P=b===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(P=p,S=b==="end"?"top":"bottom");const I=_-h[S],C=E-h[P],T=!e.middlewareData.shift;let B=I,N=C;if(v){const H=E-h.left-h.right;N=b||T?Go(C,H):H}else{const H=_-h.top-h.bottom;B=b||T?Go(I,H):H}if(T&&!b){const H=Zn(h.left,0),J=Zn(h.right,0),Q=Zn(h.top,0),K=Zn(h.bottom,0);v?N=E-2*(H!==0||J!==0?H+J:Zn(h.left,h.right)):B=_-2*(Q!==0||K!==0?Q+K:Zn(h.top,h.bottom))}await o({...e,availableWidth:N,availableHeight:B});const $=await s.getDimensions(i.floating);return E!==$.width||_!==$.height?{reset:{rects:!0}}:{}}}};function bc(t){return XL(t)?(t.nodeName||"").toLowerCase():"#document"}function is(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Xf(t){var e;return(e=(XL(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function XL(t){return t instanceof Node||t instanceof is(t).Node}function Hf(t){return t instanceof Element||t instanceof is(t).Element}function Ba(t){return t instanceof HTMLElement||t instanceof is(t).HTMLElement}function QC(t){return typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof is(t).ShadowRoot}function yy(t){const{overflow:e,overflowX:r,overflowY:n,display:s}=zs(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+r)&&!["inline","contents"].includes(s)}function nX(t){return["table","td","th"].includes(bc(t))}function FE(t){const e=UE(),r=zs(t);return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":!1)||!e&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!e&&(r.filter?r.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function iX(t){let e=sp(t);for(;Ba(e)&&!k5(e);){if(FE(e))return e;e=sp(e)}return null}function UE(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function k5(t){return["html","body","#document"].includes(bc(t))}function zs(t){return is(t).getComputedStyle(t)}function R5(t){return Hf(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function sp(t){if(bc(t)==="html")return t;const e=t.assignedSlot||t.parentNode||QC(t)&&t.host||Xf(t);return QC(e)?e.host:e}function eD(t){const e=sp(t);return k5(e)?t.ownerDocument?t.ownerDocument.body:t.body:Ba(e)&&yy(e)?e:eD(e)}function Cf(t,e,r){var n;e===void 0&&(e=[]),r===void 0&&(r=!0);const s=eD(t),i=s===((n=t.ownerDocument)==null?void 0:n.body),o=is(s);return i?e.concat(o,o.visualViewport||[],yy(s)?s:[],o.frameElement&&r?Cf(o.frameElement):[]):e.concat(s,Cf(s,[],r))}function tD(t){const e=zs(t);let r=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const s=Ba(t),i=s?t.offsetWidth:r,o=s?t.offsetHeight:n,f=U2(r)!==i||U2(n)!==o;return f&&(r=i,n=o),{width:r,height:n,$:f}}function zE(t){return Hf(t)?t:t.contextElement}function Vh(t){const e=zE(t);if(!Ba(e))return yc(1);const r=e.getBoundingClientRect(),{width:n,height:s,$:i}=tD(e);let o=(i?U2(r.width):r.width)/n,f=(i?U2(r.height):r.height)/s;return(!o||!Number.isFinite(o))&&(o=1),(!f||!Number.isFinite(f))&&(f=1),{x:o,y:f}}const sX=yc(0);function rD(t){const e=is(t);return!UE()||!e.visualViewport?sX:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function oX(t,e,r){return e===void 0&&(e=!1),!r||e&&r!==is(t)?!1:e}function il(t,e,r,n){e===void 0&&(e=!1),r===void 0&&(r=!1);const s=t.getBoundingClientRect(),i=zE(t);let o=yc(1);e&&(n?Hf(n)&&(o=Vh(n)):o=Vh(t));const f=oX(i,r,n)?rD(i):yc(0);let h=(s.left+f.x)/o.x,p=(s.top+f.y)/o.y,b=s.width/o.x,v=s.height/o.y;if(i){const E=is(i),_=n&&Hf(n)?is(n):n;let S=E.frameElement;for(;S&&n&&_!==E;){const P=Vh(S),I=S.getBoundingClientRect(),C=zs(S),T=I.left+(S.clientLeft+parseFloat(C.paddingLeft))*P.x,B=I.top+(S.clientTop+parseFloat(C.paddingTop))*P.y;h*=P.x,p*=P.y,b*=P.x,v*=P.y,h+=T,p+=B,S=is(S).frameElement}}return ip({width:b,height:v,x:h,y:p})}function aX(t){let{rect:e,offsetParent:r,strategy:n}=t;const s=Ba(r),i=Xf(r);if(r===i)return e;let o={scrollLeft:0,scrollTop:0},f=yc(1);const h=yc(0);if((s||!s&&n!=="fixed")&&((bc(r)!=="body"||yy(i))&&(o=R5(r)),Ba(r))){const p=il(r);f=Vh(r),h.x=p.x+r.clientLeft,h.y=p.y+r.clientTop}return{width:e.width*f.x,height:e.height*f.y,x:e.x*f.x-o.scrollLeft*f.x+h.x,y:e.y*f.y-o.scrollTop*f.y+h.y}}function fX(t){return Array.from(t.getClientRects())}function nD(t){return il(Xf(t)).left+R5(t).scrollLeft}function cX(t){const e=Xf(t),r=R5(t),n=t.ownerDocument.body,s=Zn(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Zn(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let o=-r.scrollLeft+nD(t);const f=-r.scrollTop;return zs(n).direction==="rtl"&&(o+=Zn(e.clientWidth,n.clientWidth)-s),{width:s,height:i,x:o,y:f}}function uX(t,e){const r=is(t),n=Xf(t),s=r.visualViewport;let i=n.clientWidth,o=n.clientHeight,f=0,h=0;if(s){i=s.width,o=s.height;const p=UE();(!p||p&&e==="fixed")&&(f=s.offsetLeft,h=s.offsetTop)}return{width:i,height:o,x:f,y:h}}function lX(t,e){const r=il(t,!0,e==="fixed"),n=r.top+t.clientTop,s=r.left+t.clientLeft,i=Ba(t)?Vh(t):yc(1),o=t.clientWidth*i.x,f=t.clientHeight*i.y,h=s*i.x,p=n*i.y;return{width:o,height:f,x:h,y:p}}function YC(t,e,r){let n;if(e==="viewport")n=uX(t,r);else if(e==="document")n=cX(Xf(t));else if(Hf(e))n=lX(e,r);else{const s=rD(t);n={...e,x:e.x-s.x,y:e.y-s.y}}return ip(n)}function iD(t,e){const r=sp(t);return r===e||!Hf(r)||k5(r)?!1:zs(r).position==="fixed"||iD(r,e)}function hX(t,e){const r=e.get(t);if(r)return r;let n=Cf(t,[],!1).filter(f=>Hf(f)&&bc(f)!=="body"),s=null;const i=zs(t).position==="fixed";let o=i?sp(t):t;for(;Hf(o)&&!k5(o);){const f=zs(o),h=FE(o);!h&&f.position==="fixed"&&(s=null),(i?!h&&!s:!h&&f.position==="static"&&!!s&&["absolute","fixed"].includes(s.position)||yy(o)&&!h&&iD(t,o))?n=n.filter(b=>b!==o):s=f,o=sp(o)}return e.set(t,n),n}function dX(t){let{element:e,boundary:r,rootBoundary:n,strategy:s}=t;const o=[...r==="clippingAncestors"?hX(e,this._c):[].concat(r),n],f=o[0],h=o.reduce((p,b)=>{const v=YC(e,b,s);return p.top=Zn(v.top,p.top),p.right=Go(v.right,p.right),p.bottom=Go(v.bottom,p.bottom),p.left=Zn(v.left,p.left),p},YC(e,f,s));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function pX(t){return tD(t)}function mX(t,e,r){const n=Ba(e),s=Xf(e),i=r==="fixed",o=il(t,!0,i,e);let f={scrollLeft:0,scrollTop:0};const h=yc(0);if(n||!n&&!i)if((bc(e)!=="body"||yy(s))&&(f=R5(e)),n){const p=il(e,!0,i,e);h.x=p.x+e.clientLeft,h.y=p.y+e.clientTop}else s&&(h.x=nD(s));return{x:o.left+f.scrollLeft-h.x,y:o.top+f.scrollTop-h.y,width:o.width,height:o.height}}function XC(t,e){return!Ba(t)||zs(t).position==="fixed"?null:e?e(t):t.offsetParent}function sD(t,e){const r=is(t);if(!Ba(t))return r;let n=XC(t,e);for(;n&&nX(n)&&zs(n).position==="static";)n=XC(n,e);return n&&(bc(n)==="html"||bc(n)==="body"&&zs(n).position==="static"&&!FE(n))?r:n||iX(t)||r}const gX=async function(t){let{reference:e,floating:r,strategy:n}=t;const s=this.getOffsetParent||sD,i=this.getDimensions;return{reference:mX(e,await s(r),n),floating:{x:0,y:0,...await i(r)}}};function yX(t){return zs(t).direction==="rtl"}const bX={convertOffsetParentRelativeRectToViewportRelativeRect:aX,getDocumentElement:Xf,getClippingRect:dX,getOffsetParent:sD,getElementRects:gX,getClientRects:fX,getDimensions:pX,getScale:Vh,isElement:Hf,isRTL:yX};function vX(t,e){let r=null,n;const s=Xf(t);function i(){clearTimeout(n),r&&r.disconnect(),r=null}function o(f,h){f===void 0&&(f=!1),h===void 0&&(h=1),i();const{left:p,top:b,width:v,height:E}=t.getBoundingClientRect();if(f||e(),!v||!E)return;const _=Bb(b),S=Bb(s.clientWidth-(p+v)),P=Bb(s.clientHeight-(b+E)),I=Bb(p),T={rootMargin:-_+"px "+-S+"px "+-P+"px "+-I+"px",threshold:Zn(0,Go(1,h))||1};let B=!0;function N($){const H=$[0].intersectionRatio;if(H!==h){if(!B)return o();H?o(!1,H):n=setTimeout(()=>{o(!1,1e-7)},100)}B=!1}try{r=new IntersectionObserver(N,{...T,root:s.ownerDocument})}catch{r=new IntersectionObserver(N,T)}r.observe(t)}return o(!0),i}function xX(t,e,r,n){n===void 0&&(n={});const{ancestorScroll:s=!0,ancestorResize:i=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:f=typeof IntersectionObserver=="function",animationFrame:h=!1}=n,p=zE(t),b=s||i?[...p?Cf(p):[],...Cf(e)]:[];b.forEach(C=>{s&&C.addEventListener("scroll",r,{passive:!0}),i&&C.addEventListener("resize",r)});const v=p&&f?vX(p,r):null;let E=-1,_=null;o&&(_=new ResizeObserver(C=>{let[T]=C;T&&T.target===p&&_&&(_.unobserve(e),cancelAnimationFrame(E),E=requestAnimationFrame(()=>{_&&_.observe(e)})),r()}),p&&!h&&_.observe(p),_.observe(e));let S,P=h?il(t):null;h&&I();function I(){const C=il(t);P&&(C.x!==P.x||C.y!==P.y||C.width!==P.width||C.height!==P.height)&&r(),P=C,S=requestAnimationFrame(I)}return r(),()=>{b.forEach(C=>{s&&C.removeEventListener("scroll",r),i&&C.removeEventListener("resize",r)}),v&&v(),_&&_.disconnect(),_=null,h&&cancelAnimationFrame(S)}}const wX=(t,e,r)=>{const n=new Map,s={platform:bX,...r},i={...s.platform,_c:n};return YY(t,e,{...s,platform:i})},oD=t=>{function e(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:t,fn(r){const{element:n,padding:s}=typeof t=="function"?t(r):t;return n&&e(n)?n.current!=null?ZC({element:n.current,padding:s}).fn(r):{}:n?ZC({element:n,padding:s}).fn(r):{}}}};var _v=typeof document<"u"?Z.useLayoutEffect:Z.useEffect;function j2(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let r,n,s;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(r=t.length,r!=e.length)return!1;for(n=r;n--!==0;)if(!j2(t[n],e[n]))return!1;return!0}if(s=Object.keys(t),r=s.length,r!==Object.keys(e).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(e,s[n]))return!1;for(n=r;n--!==0;){const i=s[n];if(!(i==="_owner"&&t.$$typeof)&&!j2(t[i],e[i]))return!1}return!0}return t!==t&&e!==e}function aD(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function eI(t,e){const r=aD(t);return Math.round(e*r)/r}function tI(t){const e=Z.useRef(t);return _v(()=>{e.current=t}),e}function AX(t){t===void 0&&(t={});const{placement:e="bottom",strategy:r="absolute",middleware:n=[],platform:s,elements:{reference:i,floating:o}={},transform:f=!0,whileElementsMounted:h,open:p}=t,[b,v]=Z.useState({x:0,y:0,strategy:r,placement:e,middlewareData:{},isPositioned:!1}),[E,_]=Z.useState(n);j2(E,n)||_(n);const[S,P]=Z.useState(null),[I,C]=Z.useState(null),T=Z.useCallback(m=>{m!=H.current&&(H.current=m,P(m))},[P]),B=Z.useCallback(m=>{m!==J.current&&(J.current=m,C(m))},[C]),N=i||S,$=o||I,H=Z.useRef(null),J=Z.useRef(null),Q=Z.useRef(b),K=tI(h),se=tI(s),w=Z.useCallback(()=>{if(!H.current||!J.current)return;const m={placement:e,strategy:r,middleware:E};se.current&&(m.platform=se.current),wX(H.current,J.current,m).then(x=>{const A={...x,isPositioned:!0};a.current&&!j2(Q.current,A)&&(Q.current=A,yE.flushSync(()=>{v(A)}))})},[E,e,r,se]);_v(()=>{p===!1&&Q.current.isPositioned&&(Q.current.isPositioned=!1,v(m=>({...m,isPositioned:!1})))},[p]);const a=Z.useRef(!1);_v(()=>(a.current=!0,()=>{a.current=!1}),[]),_v(()=>{if(N&&(H.current=N),$&&(J.current=$),N&&$){if(K.current)return K.current(N,$,w);w()}},[N,$,w,K]);const u=Z.useMemo(()=>({reference:H,floating:J,setReference:T,setFloating:B}),[T,B]),l=Z.useMemo(()=>({reference:N,floating:$}),[N,$]),d=Z.useMemo(()=>{const m={position:r,left:0,top:0};if(!l.floating)return m;const x=eI(l.floating,b.x),A=eI(l.floating,b.y);return f?{...m,transform:"translate("+x+"px, "+A+"px)",...aD(l.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:x,top:A}},[r,f,l.floating,b.x,b.y]);return Z.useMemo(()=>({...b,update:w,refs:u,elements:l,floatingStyles:d}),[b,w,u,l,d])}var If=typeof document<"u"?Z.useLayoutEffect:Z.useEffect;let B3=!1,EX=0;const rI=()=>"floating-ui-"+EX++;function MX(){const[t,e]=Z.useState(()=>B3?rI():void 0);return If(()=>{t==null&&e(rI())},[]),Z.useEffect(()=>{B3||(B3=!0)},[]),t}const SX=_A["useId".toString()],fD=SX||MX;function _X(){const t=new Map;return{emit(e,r){var n;(n=t.get(e))==null||n.forEach(s=>s(r))},on(e,r){t.set(e,[...t.get(e)||[],r])},off(e,r){var n;t.set(e,((n=t.get(e))==null?void 0:n.filter(s=>s!==r))||[])}}}const PX=Z.createContext(null),CX=Z.createContext(null),cD=()=>{var t;return((t=Z.useContext(PX))==null?void 0:t.id)||null},jE=()=>Z.useContext(CX);function W0(t){return(t==null?void 0:t.ownerDocument)||document}function IX(){const t=navigator.userAgentData;return t!=null&&t.platform?t.platform:navigator.platform}function TX(){const t=navigator.userAgentData;return t&&Array.isArray(t.brands)?t.brands.map(e=>{let{brand:r,version:n}=e;return r+"/"+n}).join(" "):navigator.userAgent}function B5(t){return W0(t).defaultView||window}function Ma(t){return t?t instanceof Element||t instanceof B5(t).Element:!1}function uD(t){return t?t instanceof HTMLElement||t instanceof B5(t).HTMLElement:!1}function kX(t){if(typeof ShadowRoot>"u")return!1;const e=B5(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}function RX(t){if(t.mozInputSource===0&&t.isTrusted)return!0;const e=/Android/i;return(e.test(IX())||e.test(TX()))&&t.pointerType?t.type==="click"&&t.buttons===1:t.detail===0&&!t.pointerType}function BX(t){return t.width===0&&t.height===0||t.width===1&&t.height===1&&t.pressure===0&&t.detail===0&&t.pointerType!=="mouse"||t.width<1&&t.height<1&&t.pressure===0&&t.detail===0}function lD(t,e){const r=["mouse","pen"];return e||r.push("",void 0),r.includes(t)}function OX(t){return"nativeEvent"in t}function M9(t,e){if(!t||!e)return!1;const r=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(r&&kX(r)){let n=e;for(;n;){if(t===n)return!0;n=n.parentNode||n.host}}return!1}function hD(t){return"data-floating-ui-"+t}function nI(t){const e=Z.useRef(t);return If(()=>{e.current=t}),e}const iI=hD("safe-polygon");function Pv(t,e,r){return r&&!lD(r)?0:typeof t=="number"?t:t==null?void 0:t[e]}function NX(t,e){e===void 0&&(e={});const{open:r,onOpenChange:n,dataRef:s,events:i,elements:{domReference:o,floating:f},refs:h}=t,{enabled:p=!0,delay:b=0,handleClose:v=null,mouseOnly:E=!1,restMs:_=0,move:S=!0}=e,P=jE(),I=cD(),C=nI(v),T=nI(b),B=Z.useRef(),N=Z.useRef(),$=Z.useRef(),H=Z.useRef(),J=Z.useRef(!0),Q=Z.useRef(!1),K=Z.useRef(()=>{}),se=Z.useCallback(()=>{var l;const d=(l=s.current.openEvent)==null?void 0:l.type;return(d==null?void 0:d.includes("mouse"))&&d!=="mousedown"},[s]);Z.useEffect(()=>{if(!p)return;function l(){clearTimeout(N.current),clearTimeout(H.current),J.current=!0}return i.on("dismiss",l),()=>{i.off("dismiss",l)}},[p,i]),Z.useEffect(()=>{if(!p||!C.current||!r)return;function l(m){se()&&n(!1,m)}const d=W0(f).documentElement;return d.addEventListener("mouseleave",l),()=>{d.removeEventListener("mouseleave",l)}},[f,r,n,p,C,s,se]);const w=Z.useCallback(function(l,d){d===void 0&&(d=!0);const m=Pv(T.current,"close",B.current);m&&!$.current?(clearTimeout(N.current),N.current=setTimeout(()=>n(!1,l),m)):d&&(clearTimeout(N.current),n(!1,l))},[T,n]),a=Z.useCallback(()=>{K.current(),$.current=void 0},[]),u=Z.useCallback(()=>{if(Q.current){const l=W0(h.floating.current).body;l.style.pointerEvents="",l.removeAttribute(iI),Q.current=!1}},[h]);return Z.useEffect(()=>{if(!p)return;function l(){return s.current.openEvent?["click","mousedown"].includes(s.current.openEvent.type):!1}function d(A){if(clearTimeout(N.current),J.current=!1,E&&!lD(B.current)||_>0&&Pv(T.current,"open")===0)return;const y=Pv(T.current,"open",B.current);y?N.current=setTimeout(()=>{n(!0,A)},y):n(!0,A)}function m(A){if(l())return;K.current();const y=W0(f);if(clearTimeout(H.current),C.current){r||clearTimeout(N.current),$.current=C.current({...t,tree:P,x:A.clientX,y:A.clientY,onClose(){u(),a(),w(A)}});const g=$.current;y.addEventListener("mousemove",g),K.current=()=>{y.removeEventListener("mousemove",g)};return}(B.current==="touch"?!M9(f,A.relatedTarget):!0)&&w(A)}function x(A){l()||C.current==null||C.current({...t,tree:P,x:A.clientX,y:A.clientY,onClose(){u(),a(),w(A)}})(A)}if(Ma(o)){const A=o;return r&&A.addEventListener("mouseleave",x),f==null||f.addEventListener("mouseleave",x),S&&A.addEventListener("mousemove",d,{once:!0}),A.addEventListener("mouseenter",d),A.addEventListener("mouseleave",m),()=>{r&&A.removeEventListener("mouseleave",x),f==null||f.removeEventListener("mouseleave",x),S&&A.removeEventListener("mousemove",d),A.removeEventListener("mouseenter",d),A.removeEventListener("mouseleave",m)}}},[o,f,p,t,E,_,S,w,a,u,n,r,P,T,C,s]),If(()=>{var l;if(p&&r&&(l=C.current)!=null&&l.__options.blockPointerEvents&&se()){const x=W0(f).body;if(x.setAttribute(iI,""),x.style.pointerEvents="none",Q.current=!0,Ma(o)&&f){var d,m;const A=o,y=P==null||(d=P.nodesRef.current.find(c=>c.id===I))==null||(m=d.context)==null?void 0:m.elements.floating;return y&&(y.style.pointerEvents=""),A.style.pointerEvents="auto",f.style.pointerEvents="auto",()=>{A.style.pointerEvents="",f.style.pointerEvents=""}}}},[p,r,I,f,o,P,C,s,se]),If(()=>{r||(B.current=void 0,a(),u())},[r,a,u]),Z.useEffect(()=>()=>{a(),clearTimeout(N.current),clearTimeout(H.current),u()},[p,a,u]),Z.useMemo(()=>{if(!p)return{};function l(d){B.current=d.pointerType}return{reference:{onPointerDown:l,onPointerEnter:l,onMouseMove(d){r||_===0||(clearTimeout(H.current),H.current=setTimeout(()=>{J.current||n(!0,d.nativeEvent)},_))}},floating:{onMouseEnter(){clearTimeout(N.current)},onMouseLeave(d){i.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),w(d.nativeEvent,!1)}}}},[i,p,_,r,n,w])}const dD=Z.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:()=>{},setState:()=>{},isInstantPhase:!1}),pD=()=>Z.useContext(dD),LX=t=>{let{children:e,delay:r,timeoutMs:n=0}=t;const[s,i]=Z.useReducer((h,p)=>({...h,...p}),{delay:r,timeoutMs:n,initialDelay:r,currentId:null,isInstantPhase:!1}),o=Z.useRef(null),f=Z.useCallback(h=>{i({currentId:h})},[]);return If(()=>{s.currentId?o.current===null?o.current=s.currentId:i({isInstantPhase:!0}):(i({isInstantPhase:!1}),o.current=null)},[s.currentId]),Z.createElement(dD.Provider,{value:Z.useMemo(()=>({...s,setState:i,setCurrentId:f}),[s,i,f])},e)},DX=(t,e)=>{let{open:r,onOpenChange:n}=t,{id:s}=e;const{currentId:i,setCurrentId:o,initialDelay:f,setState:h,timeoutMs:p}=pD();If(()=>{i&&(h({delay:{open:1,close:Pv(f,"close")}}),i!==s&&n(!1))},[s,n,h,i,f]),If(()=>{function b(){n(!1),h({delay:f,currentId:null})}if(!r&&i===s)if(p){const v=window.setTimeout(b,p);return()=>{clearTimeout(v)}}else b()},[r,h,i,s,n,f,p]),If(()=>{r&&o(s)},[r,o,s])};function $X(t){let e=t.activeElement;for(;((r=e)==null||(n=r.shadowRoot)==null?void 0:n.activeElement)!=null;){var r,n;e=e.shadowRoot.activeElement}return e}function O3(t,e){let r=t.filter(s=>{var i;return s.parentId===e&&((i=s.context)==null?void 0:i.open)}),n=r;for(;n.length;)n=t.filter(s=>{var i;return(i=n)==null?void 0:i.some(o=>{var f;return s.parentId===o.id&&((f=s.context)==null?void 0:f.open)})}),r=r.concat(n);return r}function FX(t){return"composedPath"in t?t.composedPath()[0]:t.target}const UX=_A["useInsertionEffect".toString()],zX=UX||(t=>t());function Cv(t){const e=Z.useRef(()=>{});return zX(()=>{e.current=t}),Z.useCallback(function(){for(var r=arguments.length,n=new Array(r),s=0;s{var e,r;return{escapeKeyBubbles:typeof t=="boolean"?t:(e=t==null?void 0:t.escapeKey)!=null?e:!1,outsidePressBubbles:typeof t=="boolean"?t:(r=t==null?void 0:t.outsidePress)!=null?r:!0}};function GX(t,e){e===void 0&&(e={});const{open:r,onOpenChange:n,events:s,nodeId:i,elements:{reference:o,domReference:f,floating:h},dataRef:p}=t,{enabled:b=!0,escapeKey:v=!0,outsidePress:E=!0,outsidePressEvent:_="pointerdown",referencePress:S=!1,referencePressEvent:P="pointerdown",ancestorScroll:I=!1,bubbles:C}=e,T=jE(),B=cD()!=null,N=Cv(typeof E=="function"?E:()=>!1),$=typeof E=="function"?N:E,H=Z.useRef(!1),{escapeKeyBubbles:J,outsidePressBubbles:Q}=qX(C),K=Cv(w=>{if(!r||!b||!v||w.key!=="Escape")return;const a=T?O3(T.nodesRef.current,i):[];if(!J&&(w.stopPropagation(),a.length>0)){let u=!0;if(a.forEach(l=>{var d;if((d=l.context)!=null&&d.open&&!l.context.dataRef.current.__escapeKeyBubbles){u=!1;return}}),!u)return}s.emit("dismiss",{type:"escapeKey",data:{returnFocus:{preventScroll:!1}}}),n(!1,OX(w)?w.nativeEvent:w)}),se=Cv(w=>{const a=H.current;if(H.current=!1,a||typeof $=="function"&&!$(w))return;const u=FX(w);if(uD(u)&&h){const m=u.clientWidth>0&&u.scrollWidth>u.clientWidth,x=u.clientHeight>0&&u.scrollHeight>u.clientHeight;let A=x&&w.offsetX>u.clientWidth;if(x&&B5(h).getComputedStyle(u).direction==="rtl"&&(A=w.offsetX<=u.offsetWidth-u.clientWidth),A||m&&w.offsetY>u.clientHeight)return}const l=T&&O3(T.nodesRef.current,i).some(m=>{var x;return Iv(w,(x=m.context)==null?void 0:x.elements.floating)});if(Iv(w,h)||Iv(w,f)||l)return;const d=T?O3(T.nodesRef.current,i):[];if(d.length>0){let m=!0;if(d.forEach(x=>{var A;if((A=x.context)!=null&&A.open&&!x.context.dataRef.current.__outsidePressBubbles){m=!1;return}}),!m)return}s.emit("dismiss",{type:"outsidePress",data:{returnFocus:B?{preventScroll:!0}:RX(w)||BX(w)}}),n(!1,w)});return Z.useEffect(()=>{if(!r||!b)return;p.current.__escapeKeyBubbles=J,p.current.__outsidePressBubbles=Q;function w(l){n(!1,l)}const a=W0(h);v&&a.addEventListener("keydown",K),$&&a.addEventListener(_,se);let u=[];return I&&(Ma(f)&&(u=Cf(f)),Ma(h)&&(u=u.concat(Cf(h))),!Ma(o)&&o&&o.contextElement&&(u=u.concat(Cf(o.contextElement)))),u=u.filter(l=>{var d;return l!==((d=a.defaultView)==null?void 0:d.visualViewport)}),u.forEach(l=>{l.addEventListener("scroll",w,{passive:!0})}),()=>{v&&a.removeEventListener("keydown",K),$&&a.removeEventListener(_,se),u.forEach(l=>{l.removeEventListener("scroll",w)})}},[p,h,f,o,v,$,_,r,n,I,b,J,Q,K,se]),Z.useEffect(()=>{H.current=!1},[$,_]),Z.useMemo(()=>b?{reference:{onKeyDown:K,[jX[P]]:w=>{S&&(s.emit("dismiss",{type:"referencePress",data:{returnFocus:!1}}),n(!1,w.nativeEvent))}},floating:{onKeyDown:K,[HX[_]]:()=>{H.current=!0}}}:{},[b,s,S,_,P,n,K])}function HE(t){var e;t===void 0&&(t={});const{open:r=!1,onOpenChange:n,nodeId:s}=t,[i,o]=Z.useState(null),f=((e=t.elements)==null?void 0:e.reference)||i,h=AX(t),p=jE(),b=Cv((N,$)=>{N&&(E.current.openEvent=$),n==null||n(N,$)}),v=Z.useRef(null),E=Z.useRef({}),_=Z.useState(()=>_X())[0],S=fD(),P=Z.useCallback(N=>{const $=Ma(N)?{getBoundingClientRect:()=>N.getBoundingClientRect(),contextElement:N}:N;h.refs.setReference($)},[h.refs]),I=Z.useCallback(N=>{(Ma(N)||N===null)&&(v.current=N,o(N)),(Ma(h.refs.reference.current)||h.refs.reference.current===null||N!==null&&!Ma(N))&&h.refs.setReference(N)},[h.refs]),C=Z.useMemo(()=>({...h.refs,setReference:I,setPositionReference:P,domReference:v}),[h.refs,I,P]),T=Z.useMemo(()=>({...h.elements,domReference:f}),[h.elements,f]),B=Z.useMemo(()=>({...h,refs:C,elements:T,dataRef:E,nodeId:s,floatingId:S,events:_,open:r,onOpenChange:b}),[h,s,S,_,r,b,C,T]);return If(()=>{const N=p==null?void 0:p.nodesRef.current.find($=>$.id===s);N&&(N.context=B)}),Z.useMemo(()=>({...h,context:B,refs:C,elements:T}),[h,C,T,B])}function VX(t,e){e===void 0&&(e={});const{open:r,onOpenChange:n,dataRef:s,events:i,refs:o,elements:{floating:f,domReference:h}}=t,{enabled:p=!0,keyboardOnly:b=!0}=e,v=Z.useRef(""),E=Z.useRef(!1),_=Z.useRef();return Z.useEffect(()=>{if(!p)return;const P=W0(f).defaultView||window;function I(){!r&&uD(h)&&h===$X(W0(h))&&(E.current=!0)}return P.addEventListener("blur",I),()=>{P.removeEventListener("blur",I)}},[f,h,r,p]),Z.useEffect(()=>{if(!p)return;function S(P){(P.type==="referencePress"||P.type==="escapeKey")&&(E.current=!0)}return i.on("dismiss",S),()=>{i.off("dismiss",S)}},[i,p]),Z.useEffect(()=>()=>{clearTimeout(_.current)},[]),Z.useMemo(()=>p?{reference:{onPointerDown(S){let{pointerType:P}=S;v.current=P,E.current=!!(P&&b)},onMouseLeave(){E.current=!1},onFocus(S){var P;E.current||S.type==="focus"&&((P=s.current.openEvent)==null?void 0:P.type)==="mousedown"&&Iv(s.current.openEvent,h)||n(!0,S.nativeEvent)},onBlur(S){E.current=!1;const P=S.relatedTarget,I=Ma(P)&&P.hasAttribute(hD("focus-guard"))&&P.getAttribute("data-type")==="outside";_.current=setTimeout(()=>{M9(o.floating.current,P)||M9(h,P)||I||n(!1,S.nativeEvent)})}}}:{},[p,b,h,o,s,n])}function N3(t,e,r){const n=new Map;return{...r==="floating"&&{tabIndex:-1},...t,...e.map(s=>s?s[r]:null).concat(t).reduce((s,i)=>(i&&Object.entries(i).forEach(o=>{let[f,h]=o;if(f.indexOf("on")===0){if(n.has(f)||n.set(f,[]),typeof h=="function"){var p;(p=n.get(f))==null||p.push(h),s[f]=function(){for(var b,v=arguments.length,E=new Array(v),_=0;_S(...E)).find(S=>S!==void 0)}}}else s[f]=h}),s),{})}}function KX(t){t===void 0&&(t=[]);const e=t,r=Z.useCallback(i=>N3(i,t,"reference"),e),n=Z.useCallback(i=>N3(i,t,"floating"),e),s=Z.useCallback(i=>N3(i,t,"item"),t.map(i=>i==null?void 0:i.item));return Z.useMemo(()=>({getReferenceProps:r,getFloatingProps:n,getItemProps:s}),[r,n,s])}function WX(t,e){e===void 0&&(e={});const{open:r,floatingId:n}=t,{enabled:s=!0,role:i="dialog"}=e,o=fD();return Z.useMemo(()=>{const f={id:n,role:i};return s?i==="tooltip"?{reference:{"aria-describedby":r?n:void 0},floating:f}:{reference:{"aria-expanded":r?"true":"false","aria-haspopup":i==="alertdialog"?"dialog":i,"aria-controls":r?n:void 0,...i==="listbox"&&{role:"combobox"},...i==="menu"&&{id:o}},floating:{...f,...i==="menu"&&{"aria-labelledby":o}}}:{}},[s,i,r,n,o])}function mD(t,e){if(t==="rtl"&&(e.includes("right")||e.includes("left"))){const[r,n]=e.split("-"),s=r==="right"?"left":"right";return n===void 0?s:`${s}-${n}`}return e}function sI(t,e,r,n){return t==="center"||n==="center"?{top:e}:t==="end"?{bottom:r}:t==="start"?{top:r}:{}}function oI(t,e,r,n,s){return t==="center"||n==="center"?{left:e}:t==="end"?{[s==="ltr"?"right":"left"]:r}:t==="start"?{[s==="ltr"?"left":"right"]:r}:{}}const JX={bottom:"borderTopLeftRadius",left:"borderTopRightRadius",right:"borderBottomLeftRadius",top:"borderBottomRightRadius"};function ZX({position:t,arrowSize:e,arrowOffset:r,arrowRadius:n,arrowPosition:s,arrowX:i,arrowY:o,dir:f}){const[h,p="center"]=t.split("-"),b={width:ke(e),height:ke(e),transform:"rotate(45deg)",position:"absolute",[JX[h]]:ke(n)},v=ke(-e/2);return h==="left"?{...b,...sI(p,o,r,s),right:v,borderLeftColor:"transparent",borderBottomColor:"transparent"}:h==="right"?{...b,...sI(p,o,r,s),left:v,borderRightColor:"transparent",borderTopColor:"transparent"}:h==="top"?{...b,...oI(p,i,r,s,f),bottom:v,borderTopColor:"transparent",borderLeftColor:"transparent"}:h==="bottom"?{...b,...oI(p,i,r,s,f),top:v,borderBottomColor:"transparent",borderRightColor:"transparent"}:{}}const qE=Z.forwardRef(({position:t,arrowSize:e,arrowOffset:r,arrowRadius:n,arrowPosition:s,visible:i,arrowX:o,arrowY:f,style:h,...p},b)=>{const{dir:v}=RE();return i?ue.createElement("div",{...p,ref:b,style:{...h,...ZX({position:t,arrowSize:e,arrowOffset:r,arrowRadius:n,arrowPosition:s,dir:v,arrowX:o,arrowY:f})}}):null});qE.displayName="@mantine/core/FloatingArrow";function gD({opened:t,floating:e,position:r,positionDependencies:n}){const[s,i]=Z.useState(0);Z.useEffect(()=>{if(e.refs.reference.current&&e.refs.floating.current)return xX(e.refs.reference.current,e.refs.floating.current,e.update)},[e.refs.reference.current,e.refs.floating.current,t,s,r]),nl(()=>{e.update()},n),nl(()=>{i(o=>o+1)},[t])}function QX(t,e){var n,s,i,o;const r=[YL(t.offset)];return(n=t.middlewares)!=null&&n.shift&&r.push($E({limiter:tX()})),(s=t.middlewares)!=null&&s.flip&&r.push(JL()),(i=t.middlewares)!=null&&i.inline&&r.push(QL()),r.push(oD({element:t.arrowRef,padding:t.arrowOffset})),((o=t.middlewares)!=null&&o.size||t.width==="target")&&r.push(rX({apply({rects:f,availableWidth:h,availableHeight:p}){var E,_;const v=((E=e().refs.floating.current)==null?void 0:E.style)??{};(_=t.middlewares)!=null&&_.size&&Object.assign(v,{maxWidth:`${h}px`,maxHeight:`${p}px`}),t.width==="target"&&Object.assign(v,{width:`${f.reference.width}px`})}})),r}function YX(t){const[e,r]=OL({value:t.opened,defaultValue:t.defaultOpened,finalValue:!1,onChange:t.onChange}),n=()=>{var o;e&&((o=t.onClose)==null||o.call(t),r(!1))},s=()=>{var o,f;e?((o=t.onClose)==null||o.call(t),r(!1)):((f=t.onOpen)==null||f.call(t),r(!0))},i=HE({placement:t.position,middleware:QX(t,()=>i)});return gD({opened:t.opened,position:t.position,positionDependencies:t.positionDependencies||[],floating:i}),nl(()=>{var o;(o=t.onPositionChange)==null||o.call(t,i.placement)},[i.placement]),nl(()=>{var o,f;t.opened?(f=t.onOpen)==null||f.call(t):(o=t.onClose)==null||o.call(t)},[t.opened]),{floating:i,controlled:typeof t.opened=="boolean",opened:e,onClose:n,onToggle:s}}const[XX,yD]=dy("Popover component was not found in the tree"),eee={refProp:"ref",popupType:"dialog"},bD=mt((t,e)=>{const{children:r,refProp:n,popupType:s,...i}=We("PopoverTarget",eee,t);if(!El(r))throw new Error("Popover.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const o=i,f=yD(),h=Nc(f.reference,r.ref,e),p=f.withRoles?{"aria-haspopup":s,"aria-expanded":f.opened,"aria-controls":f.getDropdownId(),id:f.getTargetId()}:{};return Z.cloneElement(r,{...o,...p,...f.targetProps,className:En(f.targetProps.className,o.className,r.props.className),[n]:h,...f.controlled?null:{onClick:f.onToggle}})});bD.displayName="@mantine/core/PopoverTarget";function tee(t){const e=document.createElement("div");return e.setAttribute("data-portal","true"),typeof t.className=="string"&&e.classList.add(...t.className.split(" ")),typeof t.style=="object"&&Object.assign(e.style,t.style),typeof t.id=="string"&&e.setAttribute("id",t.id),e}const ree={},vD=Z.forwardRef((t,e)=>{const{children:r,target:n,...s}=We("Portal",ree,t),[i,o]=Z.useState(!1),f=Z.useRef(null);return my(()=>(o(!0),f.current=n?typeof n=="string"?document.querySelector(n):n:tee(s),BL(e,f.current),!n&&f.current&&document.body.appendChild(f.current),()=>{!n&&f.current&&document.body.removeChild(f.current)}),[n]),!i||!f.current?null:yE.createPortal(ue.createElement(ue.Fragment,null,r),f.current)});vD.displayName="@mantine/core/Portal";function n1({withinPortal:t=!0,children:e,...r}){return t?ue.createElement(vD,{...r},e):ue.createElement(ue.Fragment,null,e)}n1.displayName="@mantine/core/OptionalPortal";const j1=t=>({in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:`scale(.9) translateY(${ke(t==="bottom"?10:-10)})`},transitionProperty:"transform, opacity"}),Ob={fade:{in:{opacity:1},out:{opacity:0},transitionProperty:"opacity"},scale:{in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-y":{in:{opacity:1,transform:"scaleY(1)"},out:{opacity:0,transform:"scaleY(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-x":{in:{opacity:1,transform:"scaleX(1)"},out:{opacity:0,transform:"scaleX(0)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"skew-up":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:`translateY(-${ke(20)}) skew(-10deg, -5deg)`},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"skew-down":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:`translateY(${ke(20)}) skew(-10deg, -5deg)`},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-left":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:`translateY(${ke(20)}) rotate(-5deg)`},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-right":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:`translateY(${ke(20)}) rotate(5deg)`},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(-100%)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(100%)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"slide-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(100%)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"slide-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(-100%)"},common:{transformOrigin:"right"},transitionProperty:"transform, opacity"},pop:{...j1("bottom"),common:{transformOrigin:"center center"}},"pop-bottom-left":{...j1("bottom"),common:{transformOrigin:"bottom left"}},"pop-bottom-right":{...j1("bottom"),common:{transformOrigin:"bottom right"}},"pop-top-left":{...j1("top"),common:{transformOrigin:"top left"}},"pop-top-right":{...j1("top"),common:{transformOrigin:"top right"}}},aI={entering:"in",entered:"in",exiting:"out",exited:"out","pre-exiting":"out","pre-entering":"out"};function nee({transition:t,state:e,duration:r,timingFunction:n}){const s={transitionDuration:`${r}ms`,transitionTimingFunction:n};return typeof t=="string"?t in Ob?{transitionProperty:Ob[t].transitionProperty,...s,...Ob[t].common,...Ob[t][aI[e]]}:{}:{transitionProperty:t.transitionProperty,...s,...t.common,...t[aI[e]]}}function iee({duration:t,exitDuration:e,timingFunction:r,mounted:n,onEnter:s,onExit:i,onEntered:o,onExited:f}){const h=za(),p=NL(),b=h.respectReducedMotion?p:!1,[v,E]=Z.useState(b?0:t),[_,S]=Z.useState(n?"entered":"exited"),P=Z.useRef(-1),I=C=>{const T=C?s:i,B=C?o:f;S(C?"pre-entering":"pre-exiting"),window.clearTimeout(P.current);const N=b?0:C?t:e;if(E(N),N===0)typeof T=="function"&&T(),typeof B=="function"&&B(),S(C?"entered":"exited");else{const $=window.setTimeout(()=>{typeof T=="function"&&T(),S(C?"entering":"exiting")},10);P.current=window.setTimeout(()=>{window.clearTimeout($),typeof B=="function"&&B(),S(C?"entered":"exited")},N)}};return nl(()=>{I(n)},[n]),Z.useEffect(()=>()=>window.clearTimeout(P.current),[]),{transitionDuration:v,transitionStatus:_,transitionTimingFunction:r||"ease"}}function Sl({keepMounted:t,transition:e="fade",duration:r=250,exitDuration:n=r,mounted:s,children:i,timingFunction:o="ease",onExit:f,onEntered:h,onEnter:p,onExited:b}){const{transitionDuration:v,transitionStatus:E,transitionTimingFunction:_}=iee({mounted:s,exitDuration:n,duration:r,timingFunction:o,onExit:f,onEntered:h,onEnter:p,onExited:b});return v===0?s?ue.createElement(ue.Fragment,null,i({})):t?i({display:"none"}):null:E==="exited"?t?i({display:"none"}):null:ue.createElement(ue.Fragment,null,i(nee({transition:e,duration:v,state:E,timingFunction:_})))}Sl.displayName="@mantine/core/Transition";function GE({children:t,active:e=!0,refProp:r="ref"}){const n=UQ(e),s=Nc(n,t==null?void 0:t.ref);return El(t)?Z.cloneElement(t,{[r]:s}):t}GE.displayName="@mantine/core/FocusTrap";var xD={dropdown:"m-38a85659",arrow:"m-a31dc6c1"};const see={},VE=mt((t,e)=>{var I,C,T,B;const r=We("PopoverDropdown",see,t),{className:n,style:s,vars:i,children:o,onKeyDownCapture:f,variant:h,classNames:p,styles:b,...v}=r,E=yD(),_=CL({opened:E.opened,shouldReturnFocus:E.returnFocus}),S=E.withRoles?{"aria-labelledby":E.getTargetId(),id:E.getDropdownId(),role:"dialog",tabIndex:-1}:{},P=Nc(e,E.floating);return E.disabled?null:ue.createElement(n1,{...E.portalProps,withinPortal:E.withinPortal},ue.createElement(Sl,{mounted:E.opened,...E.transitionProps,transition:((I=E.transitionProps)==null?void 0:I.transition)||"fade",duration:((C=E.transitionProps)==null?void 0:C.duration)??150,keepMounted:E.keepMounted,exitDuration:typeof((T=E.transitionProps)==null?void 0:T.exitDuration)=="number"?E.transitionProps.exitDuration:(B=E.transitionProps)==null?void 0:B.duration},N=>ue.createElement(GE,{active:E.trapFocus},ue.createElement(st,{...S,...v,variant:h,ref:P,onKeyDownCapture:SQ(E.onClose,{active:E.closeOnEscape,onTrigger:_,onKeyDown:f}),"data-position":E.placement,...E.getStyles("dropdown",{className:n,props:r,classNames:p,styles:b,style:[{...N,zIndex:E.zIndex,top:E.y??0,left:E.x??0,width:E.width==="target"?void 0:ke(E.width)},s]})},o,ue.createElement(qE,{ref:E.arrowRef,arrowX:E.arrowX,arrowY:E.arrowY,visible:E.withArrow,position:E.placement,arrowSize:E.arrowSize,arrowRadius:E.arrowRadius,arrowOffset:E.arrowOffset,arrowPosition:E.arrowPosition,...E.getStyles("arrow",{props:r,classNames:p,styles:b})})))))});VE.classes=xD;VE.displayName="@mantine/core/PopoverDropdown";const oee={position:"bottom",offset:8,positionDependencies:[],transitionProps:{transition:"fade",duration:150},middlewares:{flip:!0,shift:!0,inline:!1},arrowSize:7,arrowOffset:5,arrowRadius:0,arrowPosition:"side",closeOnClickOutside:!0,withinPortal:!0,closeOnEscape:!0,trapFocus:!1,withRoles:!0,returnFocus:!1,clickOutsideEvents:["mousedown","touchstart"],zIndex:Ua("popover"),__staticSelector:"Popover",width:"max-content"},aee=(t,{radius:e,shadow:r})=>({dropdown:{"--popover-radius":e===void 0?void 0:ri(e),"--popover-shadow":wE(r)}});function Lc(t){var ae,je,he,oe,Qe,ge;const e=We("Popover",oee,t),{children:r,position:n,offset:s,onPositionChange:i,positionDependencies:o,opened:f,transitionProps:h,width:p,middlewares:b,withArrow:v,arrowSize:E,arrowOffset:_,arrowRadius:S,arrowPosition:P,unstyled:I,classNames:C,styles:T,closeOnClickOutside:B,withinPortal:N,portalProps:$,closeOnEscape:H,clickOutsideEvents:J,trapFocus:Q,onClose:K,onOpen:se,onChange:w,zIndex:a,radius:u,shadow:l,id:d,defaultOpened:m,__staticSelector:x,withRoles:A,disabled:y,returnFocus:c,variant:g,keepMounted:M,vars:R,...L}=e,k=Dt({name:x,props:e,classes:xD,classNames:C,styles:T,unstyled:I,rootSelector:"dropdown",vars:R,varsResolver:aee}),D=Z.useRef(null),[U,V]=Z.useState(null),[G,Y]=Z.useState(null),{dir:q}=RE(),z=t1(d),ee=YX({middlewares:b,width:p,position:mD(q,n),offset:typeof s=="number"?s+(v?E/2:0):s,arrowRef:D,arrowOffset:_,onPositionChange:i,positionDependencies:o,opened:f,defaultOpened:m,onChange:w,onOpen:se,onClose:K});IQ(()=>B&&ee.onClose(),J,[U,G]);const re=Z.useCallback(be=>{V(be),ee.floating.refs.setReference(be)},[ee.floating.refs.setReference]),ie=Z.useCallback(be=>{Y(be),ee.floating.refs.setFloating(be)},[ee.floating.refs.setFloating]);return ue.createElement(XX,{value:{returnFocus:c,disabled:y,controlled:ee.controlled,reference:re,floating:ie,x:ee.floating.x,y:ee.floating.y,arrowX:(he=(je=(ae=ee.floating)==null?void 0:ae.middlewareData)==null?void 0:je.arrow)==null?void 0:he.x,arrowY:(ge=(Qe=(oe=ee.floating)==null?void 0:oe.middlewareData)==null?void 0:Qe.arrow)==null?void 0:ge.y,opened:ee.opened,arrowRef:D,transitionProps:h,width:p,withArrow:v,arrowSize:E,arrowOffset:_,arrowRadius:S,arrowPosition:P,placement:ee.floating.placement,trapFocus:Q,withinPortal:N,portalProps:$,zIndex:a,radius:u,shadow:l,closeOnEscape:H,onClose:ee.onClose,onToggle:ee.onToggle,getTargetId:()=>`${z}-target`,getDropdownId:()=>`${z}-dropdown`,withRoles:A,targetProps:L,__staticSelector:x,classNames:C,styles:T,unstyled:I,variant:g,keepMounted:M,getStyles:k}},r)}Lc.Target=bD;Lc.Dropdown=VE;Lc.displayName="@mantine/core/Popover";Lc.extend=t=>t;var Oo={root:"m-5ae2e3c",barsLoader:"m-7a2bd4cd",bar:"m-870bb79","bars-loader-animation":"m-5d2b3b9d",dotsLoader:"m-4e3f22d7",dot:"m-870c4af","loader-dots-animation":"m-aac34a1",ovalLoader:"m-b34414df","oval-loader-animation":"m-f8e89c4b"};const fee=Z.forwardRef(({className:t,...e},r)=>ue.createElement(st,{component:"span",className:En(Oo.barsLoader,t),...e,ref:r},ue.createElement("span",{className:Oo.bar}),ue.createElement("span",{className:Oo.bar}),ue.createElement("span",{className:Oo.bar}))),cee=Z.forwardRef(({className:t,...e},r)=>ue.createElement(st,{component:"span",className:En(Oo.ovalLoader,t),...e,ref:r})),uee=Z.forwardRef(({className:t,...e},r)=>ue.createElement(st,{component:"span",className:En(Oo.dotsLoader,t),...e,ref:r},ue.createElement("span",{className:Oo.dot}),ue.createElement("span",{className:Oo.dot}),ue.createElement("span",{className:Oo.dot}))),lee={bars:fee,oval:cee,dots:uee},hee={loaders:lee,type:"oval"},dee=(t,{size:e,color:r})=>({root:{"--loader-size":jr(e,"loader-size"),"--loader-color":r?Uf(r,t):void 0}}),_l=mt((t,e)=>{const r=We("Loader",hee,t),{size:n,color:s,type:i,vars:o,className:f,style:h,classNames:p,styles:b,unstyled:v,loaders:E,variant:_,children:S,...P}=r,I=Dt({name:"Loader",props:r,classes:Oo,className:f,style:h,classNames:p,styles:b,unstyled:v,vars:o,varsResolver:dee});return S?ue.createElement(st,{...I("root"),ref:e,...P},S):ue.createElement(st,{...I("root"),ref:e,component:E[i],variant:_,size:n,...P})});_l.classes=Oo;_l.displayName="@mantine/core/Loader";var O5={root:"m-8d3f4000",loader:"m-302b9fb1",group:"m-1a0f1b21"};const fI={orientation:"horizontal"},pee=(t,{borderWidth:e})=>({group:{"--ai-border-width":ke(e)}}),KE=mt((t,e)=>{const r=We("ActionIconGroup",fI,t),{className:n,style:s,classNames:i,styles:o,unstyled:f,orientation:h,vars:p,borderWidth:b,variant:v,...E}=We("ActionIconGroup",fI,t),_=Dt({name:"ActionIconGroup",props:r,classes:O5,className:n,style:s,classNames:i,styles:o,unstyled:f,vars:p,varsResolver:pee,rootSelector:"group"});return ue.createElement(st,{..._("group"),ref:e,variant:v,mod:{"data-orientation":h},role:"group",...E})});KE.classes=O5;KE.displayName="@mantine/core/ActionIconGroup";const mee={},gee=(t,{size:e,radius:r,variant:n,gradient:s,color:i})=>{const o=t.variantColorResolver({color:i||t.primaryColor,theme:t,gradient:s,variant:n||"filled"});return{root:{"--ai-size":jr(e,"ai-size"),"--ai-radius":r===void 0?void 0:ri(r),"--ai-bg":i||n?o.background:void 0,"--ai-hover":i||n?o.hover:void 0,"--ai-hover-color":i||n?o.hoverColor:void 0,"--ai-color":i||n?o.color:void 0,"--ai-bd":i||n?o.border:void 0}}},N5=Ui((t,e)=>{const r=We("ActionIcon",mee,t),{className:n,unstyled:s,variant:i,classNames:o,styles:f,style:h,loading:p,loaderProps:b,size:v,color:E,radius:_,__staticSelector:S,gradient:P,vars:I,children:C,disabled:T,"data-disabled":B,...N}=r,$=Dt({name:["ActionIcon",S],props:r,className:n,style:h,classes:O5,classNames:o,styles:f,unstyled:s,vars:I,varsResolver:gee});return ue.createElement(gy,{...$("root",{active:!T&&!p&&!B}),...N,unstyled:s,variant:i,size:v,disabled:T||p,ref:e,mod:{loading:p,disabled:T||B}},p?ue.createElement(_l,{...$("loader"),color:"var(--ai-color)",size:"calc(var(--ai-size) * 0.55)",...b}):C)});N5.classes=O5;N5.displayName="@mantine/core/ActionIcon";N5.Group=KE;const wD=Z.forwardRef(({size:t="var(--cb-icon-size, 70%)",style:e,...r},n)=>ue.createElement("svg",{viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{...e,width:t,height:t},ref:n,...r},ue.createElement("path",{d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"})));wD.displayName="@mantine/core/CloseIcon";var AD={root:"m-86a44da5","root--subtle":"m-220c80f2"};const yee={variant:"subtle"},bee=(t,{size:e,radius:r,iconSize:n})=>({root:{"--cb-size":jr(e,"cb-size"),"--cb-radius":r===void 0?void 0:ri(r),"--cb-icon-size":ke(n)}}),Pl=Ui((t,e)=>{const r=We("CloseButton",yee,t),{iconSize:n,children:s,vars:i,radius:o,className:f,classNames:h,style:p,styles:b,unstyled:v,"data-disabled":E,disabled:_,variant:S,...P}=r,I=Dt({name:"CloseButton",props:r,className:f,style:p,classes:AD,classNames:h,styles:b,unstyled:v,vars:i,varsResolver:bee});return ue.createElement(gy,{ref:e,...P,unstyled:v,variant:S,disabled:_,mod:{disabled:_||E},...I("root",{variant:S,active:!0})},ue.createElement(wD,null),s)});Pl.classes=AD;Pl.displayName="@mantine/core/CloseButton";function vee(t){return Z.Children.toArray(t).filter(Boolean)}var ED={root:"m-4081bf90"};const xee={preventGrowOverflow:!0,gap:"md",align:"center",justify:"flex-start",wrap:"wrap"},wee=(t,{grow:e,preventGrowOverflow:r,gap:n,align:s,justify:i,wrap:o},{childWidth:f})=>({root:{"--group-child-width":e&&r?f:void 0,"--group-gap":py(n),"--group-align":s,"--group-justify":i,"--group-wrap":o}}),Tf=mt((t,e)=>{const r=We("Group",xee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,children:h,gap:p,align:b,justify:v,wrap:E,grow:_,preventGrowOverflow:S,vars:P,variant:I,__size:C,...T}=r,B=vee(h),N=B.length,$=py(p??"md"),J={childWidth:`calc(${100/N}% - (${$} - ${$} / ${N}))`},Q=Dt({name:"Group",props:r,stylesCtx:J,className:s,style:i,classes:ED,classNames:n,styles:o,unstyled:f,vars:P,varsResolver:wee});return ue.createElement(st,{...Q("root"),ref:e,variant:I,mod:{grow:_},size:C,...T},B)});Tf.classes=ED;Tf.displayName="@mantine/core/Group";var MD={root:"m-9814e45f"};const Aee={zIndex:Ua("modal")},Eee=(t,{gradient:e,color:r,backgroundOpacity:n,blur:s,radius:i,zIndex:o})=>({root:{"--overlay-bg":e||(r!==void 0||n!==void 0)&&oi(r||"#000",n??.6)||void 0,"--overlay-filter":s?`blur(${ke(s)})`:void 0,"--overlay-radius":i===void 0?void 0:ri(i),"--overlay-z-index":o==null?void 0:o.toString()}}),ug=Ui((t,e)=>{const r=We("Overlay",Aee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,fixed:p,center:b,children:v,radius:E,zIndex:_,gradient:S,blur:P,color:I,backgroundOpacity:C,...T}=r,B=Dt({name:"Overlay",props:r,classes:MD,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Eee});return ue.createElement(st,{ref:e,...B("root"),mod:{center:b,fixed:p},...T},v)});ug.classes=MD;ug.displayName="@mantine/core/Overlay";const[Mee,e0]=dy("ModalBase component was not found in tree");function See({opened:t,transitionDuration:e}){const[r,n]=Z.useState(t),s=Z.useRef(),o=NL()?0:e;return Z.useEffect(()=>(t?(n(!0),window.clearTimeout(s.current)):o===0?n(!1):s.current=window.setTimeout(()=>n(!1),o),()=>window.clearTimeout(s.current)),[t,o]),r}function _ee({id:t,transitionProps:e,opened:r,trapFocus:n,closeOnEscape:s,onClose:i,returnFocus:o}){const f=t1(t),[h,p]=Z.useState(!1),[b,v]=Z.useState(!1),E=typeof(e==null?void 0:e.duration)=="number"?e==null?void 0:e.duration:200,_=See({opened:r,transitionDuration:E});return RL("keydown",S=>{!n&&S.key==="Escape"&&s&&i()}),CL({opened:r,shouldReturnFocus:n&&o}),{_id:f,titleMounted:h,bodyMounted:b,shouldLockScroll:_,setTitleMounted:p,setBodyMounted:v}}const Pee=Z.forwardRef(({keepMounted:t,opened:e,onClose:r,id:n,transitionProps:s,trapFocus:i,closeOnEscape:o,returnFocus:f,closeOnClickOutside:h,withinPortal:p,portalProps:b,lockScroll:v,children:E,zIndex:_,shadow:S,padding:P,__vars:I,unstyled:C,removeScrollProps:T,...B},N)=>{const{_id:$,titleMounted:H,bodyMounted:J,shouldLockScroll:Q,setTitleMounted:K,setBodyMounted:se}=_ee({id:n,transitionProps:s,opened:e,trapFocus:i,closeOnEscape:o,onClose:r,returnFocus:f});return ue.createElement(n1,{...b,withinPortal:p},ue.createElement(Mee,{value:{opened:e,onClose:r,closeOnClickOutside:h,transitionProps:{...s,keepMounted:t},getTitleId:()=>`${$}-title`,getBodyId:()=>`${$}-body`,titleMounted:H,bodyMounted:J,setTitleMounted:K,setBodyMounted:se,trapFocus:i,closeOnEscape:o,zIndex:_,unstyled:C}},ue.createElement(bE,{enabled:Q&&v,...T},ue.createElement(st,{ref:N,...B,__vars:{...I,"--mb-z-index":(_||Ua("modal")).toString(),"--mb-shadow":wE(S),"--mb-padding":py(P)}},E))))});function Cee(){const t=e0();return Z.useEffect(()=>(t.setBodyMounted(!0),()=>t.setBodyMounted(!1)),[]),t.getBodyId()}var op={title:"m-615af6c9",header:"m-b5489c3c",inner:"m-60c222c7",content:"m-fd1ab0aa",close:"m-606cb269",body:"m-5df29311"};const SD=Z.forwardRef(({className:t,...e},r)=>{const n=Cee(),s=e0();return ue.createElement(st,{ref:r,...e,id:n,className:En({[op.body]:!s.unstyled},t)})});SD.displayName="@mantine/core/ModalBaseBody";const _D=Z.forwardRef(({className:t,onClick:e,...r},n)=>{const s=e0();return ue.createElement(Pl,{ref:n,...r,onClick:i=>{s.onClose(),e==null||e(i)},className:En({[op.close]:!s.unstyled},t),unstyled:s.unstyled})});_D.displayName="@mantine/core/ModalBaseCloseButton";const Iee=Z.forwardRef(({transitionProps:t,className:e,innerProps:r,onKeyDown:n,style:s,...i},o)=>{const f=e0(),h=p=>{var v;((v=p.target)==null?void 0:v.getAttribute("data-mantine-stop-propagation"))!=="true"&&p.key==="Escape"&&f.closeOnEscape&&f.onClose(),n==null||n(p)};return ue.createElement(Sl,{mounted:f.opened,transition:"pop",...f.transitionProps,...t},p=>ue.createElement("div",{...r,className:En({[op.inner]:!f.unstyled},r.className)},ue.createElement(GE,{active:f.opened&&f.trapFocus},ue.createElement(zf,{...i,component:"section",role:"dialog",tabIndex:-1,"aria-modal":!0,"aria-describedby":f.bodyMounted?f.getBodyId():void 0,"aria-labelledby":f.titleMounted?f.getTitleId():void 0,onKeyDown:h,ref:o,style:[s,p],className:En({[op.content]:!f.unstyled},e),unstyled:f.unstyled},i.children))))}),PD=Z.forwardRef(({className:t,...e},r)=>{const n=e0();return ue.createElement(st,{ref:r,className:En({[op.header]:!n.unstyled},t),...e})});PD.displayName="@mantine/core/ModalBaseHeader";const Tee={duration:200,timingFunction:"ease",transition:"fade"};function kee(t){const e=e0();return{...Tee,...e.transitionProps,...t}}const CD=Z.forwardRef(({onClick:t,transitionProps:e,style:r,...n},s)=>{const i=e0(),o=kee(e);return ue.createElement(Sl,{mounted:i.opened,...o,transition:"fade"},f=>ue.createElement(ug,{ref:s,fixed:!0,style:[r,f],zIndex:i.zIndex,unstyled:i.unstyled,onClick:h=>{t==null||t(h),i.closeOnClickOutside&&i.onClose()},...n}))});CD.displayName="@mantine/core/ModalBaseOverlay";function Ree(){const t=e0();return Z.useEffect(()=>(t.setTitleMounted(!0),()=>t.setTitleMounted(!1)),[]),t.getTitleId()}const ID=Z.forwardRef(({className:t,...e},r)=>{const n=Ree(),s=e0();return ue.createElement(st,{component:"h2",ref:r,className:En({[op.title]:!s.unstyled},t),...e,id:n})});ID.displayName="@mantine/core/ModalBaseTitle";function Bee({children:t}){return ue.createElement(ue.Fragment,null,t)}const[Oee,L5]=AQ({offsetBottom:!1,offsetTop:!1,describedBy:void 0,getStyles:null,inputId:void 0,labelId:void 0});var Ys={wrapper:"m-6c018570",input:"m-8fb7ebe7",section:"m-82577fc2",placeholder:"m-88bacfd0",root:"m-46b77525",label:"m-8fdc1311",required:"m-78a94662",error:"m-8f816625",description:"m-fe47ce59"};const cI={labelElement:"label"},Nee=(t,{size:e})=>({label:{"--input-label-size":Os(e),"--input-asterisk-color":void 0}}),D5=mt((t,e)=>{const r=We("InputLabel",cI,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,labelElement:p,size:b,required:v,htmlFor:E,onMouseDown:_,children:S,__staticSelector:P,variant:I,...C}=We("InputLabel",cI,r),T=Dt({name:["InputWrapper",P],props:r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,rootSelector:"label",vars:h,varsResolver:Nee}),B=L5(),N=(B==null?void 0:B.getStyles)||T;return ue.createElement(st,{...N("label"),component:p,variant:I,size:b,ref:e,htmlFor:p==="label"?E:void 0,mod:{required:v},onMouseDown:$=>{_==null||_($),!$.defaultPrevented&&$.detail>1&&$.preventDefault()},...C},S,v&&ue.createElement("span",{...N("required"),"aria-hidden":!0}," *"))});D5.classes=Ys;D5.displayName="@mantine/core/InputLabel";const Lee={},Dee=(t,{size:e})=>({error:{"--input-error-size":e===void 0?void 0:`calc(${Os(e)} - ${ke(2)})`}}),$5=mt((t,e)=>{const r=We("InputError",Lee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,size:p,__staticSelector:b,__inheritStyles:v=!0,variant:E,..._}=r,S=Dt({name:["InputWrapper",b],props:r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,rootSelector:"error",vars:h,varsResolver:Dee}),P=L5(),I=v&&(P==null?void 0:P.getStyles)||S;return ue.createElement(st,{component:"p",ref:e,variant:E,size:p,...I("error"),..._})});$5.classes=Ys;$5.displayName="@mantine/core/InputError";const uI={},$ee=(t,{size:e})=>({description:{"--input-description-size":e===void 0?void 0:`calc(${Os(e)} - ${ke(2)})`}}),F5=mt((t,e)=>{const r=We("InputDescription",uI,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,size:p,__staticSelector:b,__inheritStyles:v=!0,variant:E,..._}=We("InputDescription",uI,r),S=L5(),P=Dt({name:["InputWrapper",b],props:r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,rootSelector:"description",vars:h,varsResolver:$ee}),I=v&&(S==null?void 0:S.getStyles)||P;return ue.createElement(st,{component:"p",ref:e,variant:E,size:p,...I("description"),..._})});F5.classes=Ys;F5.displayName="@mantine/core/InputDescription";const lI={},WE=mt((t,e)=>{const r=We("InputPlaceholder",lI,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,__staticSelector:p,variant:b,error:v,...E}=We("InputPlaceholder",lI,r),_=Dt({name:["InputPlaceholder",p],props:r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,rootSelector:"placeholder"});return ue.createElement(st,{..._("placeholder"),mod:{error:!!v},component:"span",variant:b,ref:e,...E})});WE.classes=Ys;WE.displayName="@mantine/core/InputPlaceholder";function Fee(t,{hasDescription:e,hasError:r}){const n=t.findIndex(h=>h==="input"),s=t[n-1],i=t[n+1];return{offsetBottom:e&&i==="description"||r&&i==="error",offsetTop:e&&s==="description"||r&&s==="error"}}const Uee={labelElement:"label",inputContainer:t=>t,inputWrapperOrder:["label","description","input","error"]},zee=(t,{size:e})=>({label:{"--input-label-size":Os(e),"--input-asterisk-color":void 0},error:{"--input-error-size":e===void 0?void 0:`calc(${Os(e)} - ${ke(2)})`},description:{"--input-description-size":e===void 0?void 0:`calc(${Os(e)} - ${ke(2)})`}}),JE=mt((t,e)=>{const r=We("InputWrapper",Uee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,size:p,variant:b,__staticSelector:v,inputContainer:E,inputWrapperOrder:_,label:S,error:P,description:I,labelProps:C,descriptionProps:T,errorProps:B,labelElement:N,children:$,withAsterisk:H,id:J,required:Q,__stylesApiProps:K,...se}=r,w=Dt({name:["InputWrapper",v],props:K||r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:zee}),a={size:p,variant:b,__staticSelector:v},u=t1(J),l=typeof H=="boolean"?H:Q,d=(B==null?void 0:B.id)||`${u}-error`,m=(T==null?void 0:T.id)||`${u}-description`,x=u,A=!!P&&typeof P!="boolean",y=!!I,c=`${A?d:""} ${y?m:""}`,g=c.trim().length>0?c.trim():void 0,M=(C==null?void 0:C.id)||`${u}-label`,R=S&&ue.createElement(D5,{key:"label",labelElement:N,id:M,htmlFor:x,required:l,...a,...C},S),L=y&&ue.createElement(F5,{key:"description",...T,...a,size:(T==null?void 0:T.size)||a.size,id:(T==null?void 0:T.id)||m},I),k=ue.createElement(ue.Fragment,{key:"input"},E($)),D=A&&ue.createElement($5,{...B,...a,size:(B==null?void 0:B.size)||a.size,key:"error",id:(B==null?void 0:B.id)||d},P),U=_.map(V=>{switch(V){case"label":return R;case"input":return k;case"description":return L;case"error":return D;default:return null}});return ue.createElement(Oee,{value:{getStyles:w,describedBy:g,inputId:x,labelId:M,...Fee(_,{hasDescription:y,hasError:A})}},ue.createElement(st,{ref:e,variant:b,size:p,...w("root"),...se},U))});JE.classes=Ys;JE.displayName="@mantine/core/InputWrapper";const jee={variant:"default",leftSectionPointerEvents:"none",rightSectionPointerEvents:"none",withAria:!0,withErrorStyles:!0},Hee=(t,e,r)=>({wrapper:{"--input-margin-top":r.offsetTop?"calc(var(--mantine-spacing-xs) / 2)":void 0,"--input-margin-bottom":r.offsetBottom?"calc(var(--mantine-spacing-xs) / 2)":void 0,"--input-height":jr(e.size,"input-height"),"--input-fz":Os(e.size),"--input-radius":e.radius===void 0?void 0:ri(e.radius),"--input-left-section-width":e.leftSectionWidth!==void 0?ke(e.leftSectionWidth):void 0,"--input-right-section-width":e.rightSectionWidth!==void 0?ke(e.rightSectionWidth):void 0,"--input-padding-y":e.multiline?jr(e.size,"input-padding-y"):void 0,"--input-left-section-pointer-events":e.leftSectionPointerEvents,"--input-right-section-pointer-events":e.rightSectionPointerEvents}}),Tr=Ui((t,e)=>{const r=We("Input",jee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,required:h,__staticSelector:p,__stylesApiProps:b,size:v,wrapperProps:E,error:_,disabled:S,leftSection:P,leftSectionProps:I,leftSectionWidth:C,rightSection:T,rightSectionProps:B,rightSectionWidth:N,rightSectionPointerEvents:$,leftSectionPointerEvents:H,variant:J,vars:Q,pointer:K,multiline:se,radius:w,id:a,withAria:u,withErrorStyles:l,...d}=r,{styleProps:m,rest:x}=kE(d),A=L5(),y={offsetBottom:A==null?void 0:A.offsetBottom,offsetTop:A==null?void 0:A.offsetTop},c=Dt({name:["Input",p],props:b||r,classes:Ys,className:s,style:i,classNames:n,styles:o,unstyled:f,stylesCtx:y,rootSelector:"wrapper",vars:Q,varsResolver:Hee}),g=u?{required:h,disabled:S,"aria-invalid":!!_,"aria-describedby":A==null?void 0:A.describedBy,id:(A==null?void 0:A.inputId)||a}:{};return ue.createElement(st,{...c("wrapper"),...m,...E,mod:{error:!!_&&l,pointer:K,disabled:S,multiline:se,"data-with-right-section":!!T,"data-with-left-section":!!P},variant:J,size:v},P&&ue.createElement("div",{...I,"data-position":"left",...c("section",{className:I==null?void 0:I.className,style:I==null?void 0:I.style})},P),ue.createElement(st,{component:"input",...x,...g,ref:e,required:h,mod:{disabled:S,error:!!_&&l},variant:J,...c("input")}),T&&ue.createElement("div",{...B,"data-position":"right",...c("section",{className:B==null?void 0:B.className,style:B==null?void 0:B.style})},T))});Tr.classes=Ys;Tr.Wrapper=JE;Tr.Label=D5;Tr.Error=$5;Tr.Description=F5;Tr.Placeholder=WE;Tr.displayName="@mantine/core/Input";function qee(t,e,r){const n=We(t,e,r),{label:s,description:i,error:o,required:f,classNames:h,styles:p,className:b,unstyled:v,__staticSelector:E,__stylesApiProps:_,errorProps:S,labelProps:P,descriptionProps:I,wrapperProps:C,id:T,size:B,style:N,inputContainer:$,inputWrapperOrder:H,withAsterisk:J,variant:Q,vars:K,...se}=n,{styleProps:w,rest:a}=kE(se),u={label:s,description:i,error:o,required:f,classNames:h,className:b,__staticSelector:E,__stylesApiProps:_||n,errorProps:S,labelProps:P,descriptionProps:I,unstyled:v,styles:p,size:B,style:N,inputContainer:$,inputWrapperOrder:H,withAsterisk:J,variant:Q,id:T,...C};return{...a,classNames:h,styles:p,unstyled:v,wrapperProps:{...u,...w},inputProps:{required:f,classNames:h,styles:p,unstyled:v,size:B,__staticSelector:E,__stylesApiProps:_||n,error:o,variant:Q,id:T}}}const Gee={__staticSelector:"InputBase",withAria:!0},U5=Ui((t,e)=>{const{inputProps:r,wrapperProps:n,...s}=qee("InputBase",Gee,t);return ue.createElement(Tr.Wrapper,{...n},ue.createElement(Tr,{...r,...s,ref:e}))});U5.classes={...Tr.classes,...Tr.Wrapper.classes};U5.displayName="@mantine/core/InputBase";var TD={root:"m-7f854edf"};const Vee={position:{bottom:0,right:0},zIndex:Ua("modal"),withinPortal:!0},Kee=(t,{zIndex:e,position:r})=>({root:{"--affix-z-index":e==null?void 0:e.toString(),"--affix-top":ke(r==null?void 0:r.top),"--affix-left":ke(r==null?void 0:r.left),"--affix-bottom":ke(r==null?void 0:r.bottom),"--affix-right":ke(r==null?void 0:r.right)}}),ZE=mt((t,e)=>{const r=We("Affix",Vee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,portalProps:p,zIndex:b,withinPortal:v,position:E,..._}=r,S=Dt({name:"Affix",classes:TD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Kee});return ue.createElement(n1,{...p,withinPortal:v},ue.createElement(st,{ref:e,...S("root"),..._}))});ZE.classes=TD;ZE.displayName="@mantine/core/Affix";var kD={root:"m-66836ed3","root--filled":"m-12b2e6d5","root--white":"m-cffd1856",wrapper:"m-a5d60502",body:"m-667c2793",title:"m-6a03f287",label:"m-698f4f23",icon:"m-667f2a6a",message:"m-7fa78076",closeButton:"m-87f54839"};const Wee={},Jee=(t,{radius:e,color:r,variant:n})=>{const s=t.variantColorResolver({color:r||t.primaryColor,theme:t,variant:n||"light"});return{root:{"--alert-radius":e===void 0?void 0:ri(e),"--alert-bg":r||n?s.background:void 0,"--alert-color":r||n?s.color:void 0,"--alert-bd":r||n?s.border:void 0}}},ap=mt((t,e)=>{const r=We("Alert",Wee,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,radius:p,color:b,title:v,children:E,id:_,icon:S,withCloseButton:P,onClose:I,closeButtonLabel:C,variant:T,...B}=r,N=Dt({name:"Alert",classes:kD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Jee}),$=t1(_),H=v&&`${$}-title`||void 0,J=`${$}-body`;return ue.createElement(st,{id:$,...N("root",{variant:T}),variant:T,ref:e,...B,role:"alert","aria-describedby":J,"aria-labelledby":H},ue.createElement("div",{...N("wrapper")},S&&ue.createElement("div",{...N("icon")},S),ue.createElement("div",{...N("body")},v&&ue.createElement("div",{...N("title"),"data-with-close-button":P||void 0},ue.createElement("span",{id:H,...N("label")},v)),E&&ue.createElement("div",{id:J,...N("message")},E)),P&&ue.createElement(Pl,{...N("closeButton"),onClick:I,variant:"transparent",size:16,iconSize:16,"aria-label":C,unstyled:f})))});ap.classes=kD;ap.displayName="@mantine/core/Alert";var RD={root:"m-b6d8b162"};function Zee(t){if(t==="start")return"start";if(t==="end"||t)return"end"}const Qee={inherit:!1},Yee=(t,{variant:e,lineClamp:r,gradient:n,size:s,color:i})=>({root:{"--text-fz":Os(s),"--text-lh":_Q(s),"--text-gradient":e==="gradient"?v9(n,t):void 0,"--text-line-clamp":typeof r=="number"?r.toString():void 0,"--text-color":i?Uf(i,t):void 0}}),Fu=Ui((t,e)=>{const r=We("Text",Qee,t),{lineClamp:n,truncate:s,inline:i,inherit:o,gradient:f,span:h,__staticSelector:p,vars:b,className:v,style:E,classNames:_,styles:S,unstyled:P,variant:I,mod:C,size:T,...B}=r,N=Dt({name:["Text",p],props:r,classes:RD,className:v,style:E,classNames:_,styles:S,unstyled:P,vars:b,varsResolver:Yee});return ue.createElement(st,{...N("root",{focusable:!0}),ref:e,component:h?"span":"p",variant:I,mod:[{"data-truncate":Zee(s),"data-line-clamp":typeof n=="number","data-inline":i,"data-inherit":o},C],size:T,...B})});Fu.classes=RD;Fu.displayName="@mantine/core/Text";var BD={root:"m-849cf0da"};const Xee={underline:"hover"},lg=Ui((t,e)=>{const{underline:r,className:n,unstyled:s,...i}=We("Anchor",Xee,t);return ue.createElement(Fu,{component:"a",ref:e,className:En({[BD.root]:!s},n),...i,mod:{underline:r},__staticSelector:"Anchor",unstyled:s})});lg.classes=BD;lg.displayName="@mantine/core/Anchor";const[ete,i1]=dy("AppShell was not found in tree");var Dc={root:"m-89ab340",navbar:"m-45252eee",aside:"m-9cdde9a",header:"m-3b16f56b",main:"m-8983817",footer:"m-3840c879",section:"m-6dcfc7c7"};const tte={},QE=mt((t,e)=>{const r=We("AppShellNavbar",tte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,withBorder:p,zIndex:b,...v}=r,E=i1();return E.disabled?null:ue.createElement(st,{component:"nav",ref:e,mod:{"with-border":p??E.withBorder},...E.getStyles("navbar",{className:s,classNames:n,styles:o,style:i}),...v,__vars:{"--app-shell-navbar-z-index":`calc(${b??E.zIndex} + 1)`}})});QE.classes=Dc;QE.displayName="@mantine/core/AppShellNavbar";const rte={},YE=mt((t,e)=>{var _;const r=We("AppShellHeader",rte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,withBorder:p,zIndex:b,...v}=r,E=i1();return E.disabled?null:ue.createElement(st,{component:"header",ref:e,mod:{"with-border":p??E.withBorder},...E.getStyles("header",{className:En({[bE.classNames.zeroRight]:E.offsetScrollbars},s),classNames:n,styles:o,style:i}),...v,__vars:{"--app-shell-header-z-index":(_=b??E.zIndex)==null?void 0:_.toString()}})});YE.classes=Dc;YE.displayName="@mantine/core/AppShellHeader";const nte={},XE=mt((t,e)=>{var _;const r=We("AppShellFooter",nte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,withBorder:p,zIndex:b,...v}=r,E=i1();return E.disabled?null:ue.createElement(st,{component:"footer",ref:e,mod:{"with-border":p??E.withBorder},...E.getStyles("footer",{className:En({[bE.classNames.zeroRight]:E.offsetScrollbars},s),classNames:n,styles:o,style:i}),...v,__vars:{"--app-shell-footer-z-index":(_=b??E.zIndex)==null?void 0:_.toString()}})});XE.classes=Dc;XE.displayName="@mantine/core/AppShellFooter";const ite={},eM=mt((t,e)=>{const r=We("AppShellAside",ite,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,withBorder:p,zIndex:b,...v}=r,E=i1();return E.disabled?null:ue.createElement(st,{component:"aside",ref:e,mod:{"with-border":p??E.withBorder},...E.getStyles("aside",{className:s,classNames:n,styles:o,style:i}),...v,__vars:{"--app-shell-aside-z-index":`calc(${b??E.zIndex} + 1)`}})});eM.classes=Dc;eM.displayName="@mantine/core/AppShellAside";const ste={},tM=mt((t,e)=>{const r=We("AppShellMain",ste,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=i1();return ue.createElement(st,{component:"main",ref:e,...p.getStyles("main",{className:s,style:i,classNames:n,styles:o}),...h})});tM.classes=Dc;tM.displayName="@mantine/core/AppShellMain";const ote={},rM=Ui((t,e)=>{const r=We("AppShellSection",ote,t),{classNames:n,className:s,style:i,styles:o,vars:f,grow:h,...p}=r,b=i1();return ue.createElement(st,{ref:e,mod:{grow:h},...b.getStyles("section",{className:s,style:i,classNames:n,styles:o}),...p})});rM.classes=Dc;rM.displayName="@mantine/core/AppShellSection";function by(t){return!(typeof t!="object"||t===null||Object.keys(t).length===1&&"base"in t)}function vy(t){const e=typeof t=="object"&&t!==null&&typeof t.base<"u"&&Object.keys(t).length===1;return typeof t=="number"||typeof t=="string"||e}function xy(t){return typeof t=="object"?t.base:t}function ate({baseStyles:t,minMediaStyles:e,maxMediaStyles:r,aside:n,theme:s}){var h,p,b;const i=n==null?void 0:n.width,o="translateX(var(--app-shell-aside-width))",f="translateX(calc(var(--app-shell-aside-width) * -1))";if(n!=null&&n.breakpoint&&!((h=n==null?void 0:n.collapsed)!=null&&h.mobile)&&(r[n==null?void 0:n.breakpoint]=r[n==null?void 0:n.breakpoint]||{},r[n==null?void 0:n.breakpoint]["--app-shell-aside-width"]="100%",r[n==null?void 0:n.breakpoint]["--app-shell-aside-offset"]="0px"),vy(i)){const v=ke(xy(i));t["--app-shell-aside-width"]=v,t["--app-shell-aside-offset"]=v}if(by(i)&&(typeof i.base<"u"&&(t["--app-shell-aside-width"]=ke(i.base),t["--app-shell-aside-offset"]=ke(i.base)),Bn(i).forEach(v=>{v!=="base"&&(e[v]=e[v]||{},e[v]["--app-shell-aside-width"]=ke(i[v]),e[v]["--app-shell-aside-offset"]=ke(i[v]))})),(p=n==null?void 0:n.collapsed)!=null&&p.desktop){const v=n.breakpoint;e[v]=e[v]||{},e[v]["--app-shell-aside-transform"]=o,e[v]["--app-shell-aside-transform-rtl"]=f,e[v]["--app-shell-aside-offset"]="0px !important"}if((b=n==null?void 0:n.collapsed)!=null&&b.mobile){const v=AE(n.breakpoint,s)-.1;r[v]=r[v]||{},r[v]["--app-shell-aside-width"]="100%",r[v]["--app-shell-aside-offset"]="0px",r[v]["--app-shell-aside-transform"]=o,r[v]["--app-shell-aside-transform-rtl"]=f}}function fte({baseStyles:t,minMediaStyles:e,footer:r}){const n=r==null?void 0:r.height,s="translateY(var(--app-shell-footer-height))",i=(r==null?void 0:r.offset)??!0;if(vy(n)){const o=ke(xy(n));t["--app-shell-footer-height"]=o,i&&(t["--app-shell-footer-offset"]=o)}by(n)&&(typeof n.base<"u"&&(t["--app-shell-footer-height"]=ke(n.base),i&&(t["--app-shell-footer-offset"]=ke(n.base))),Bn(n).forEach(o=>{o!=="base"&&(e[o]=e[o]||{},e[o]["--app-shell-footer-height"]=ke(n[o]),i&&(e[o]["--app-shell-footer-offset"]=ke(n[o])))})),r!=null&&r.collapsed&&(t["--app-shell-footer-transform"]=s,t["--app-shell-footer-offset"]="0px !important")}function cte({baseStyles:t,minMediaStyles:e,header:r}){const n=r==null?void 0:r.height,s="translateY(calc(var(--app-shell-header-height) * -1))",i=(r==null?void 0:r.offset)??!0;if(vy(n)){const o=ke(xy(n));t["--app-shell-header-height"]=o,i&&(t["--app-shell-header-offset"]=o)}by(n)&&(typeof n.base<"u"&&(t["--app-shell-header-height"]=ke(n.base),i&&(t["--app-shell-header-offset"]=ke(n.base))),Bn(n).forEach(o=>{o!=="base"&&(e[o]=e[o]||{},e[o]["--app-shell-header-height"]=ke(n[o]),i&&(e[o]["--app-shell-header-offset"]=ke(n[o])))})),r!=null&&r.collapsed&&(t["--app-shell-header-transform"]=s,t["--app-shell-header-offset"]="0px !important")}function ute({baseStyles:t,minMediaStyles:e,maxMediaStyles:r,navbar:n,theme:s}){var h,p,b;const i=n==null?void 0:n.width,o="translateX(calc(var(--app-shell-navbar-width) * -1))",f="translateX(var(--app-shell-navbar-width))";if(n!=null&&n.breakpoint&&!((h=n==null?void 0:n.collapsed)!=null&&h.mobile)&&(r[n==null?void 0:n.breakpoint]=r[n==null?void 0:n.breakpoint]||{},r[n==null?void 0:n.breakpoint]["--app-shell-navbar-width"]="100%",r[n==null?void 0:n.breakpoint]["--app-shell-navbar-offset"]="0px"),vy(i)){const v=ke(xy(i));t["--app-shell-navbar-width"]=v,t["--app-shell-navbar-offset"]=v}if(by(i)&&(typeof i.base<"u"&&(t["--app-shell-navbar-width"]=ke(i.base),t["--app-shell-navbar-offset"]=ke(i.base)),Bn(i).forEach(v=>{v!=="base"&&(e[v]=e[v]||{},e[v]["--app-shell-navbar-width"]=ke(i[v]),e[v]["--app-shell-navbar-offset"]=ke(i[v]))})),(p=n==null?void 0:n.collapsed)!=null&&p.desktop){const v=n.breakpoint;e[v]=e[v]||{},e[v]["--app-shell-navbar-transform"]=o,e[v]["--app-shell-navbar-transform-rtl"]=f,e[v]["--app-shell-navbar-offset"]="0px !important"}if((b=n==null?void 0:n.collapsed)!=null&&b.mobile){const v=AE(n.breakpoint,s)-.1;r[v]=r[v]||{},r[v]["--app-shell-navbar-width"]="100%",r[v]["--app-shell-navbar-offset"]="0px",r[v]["--app-shell-navbar-transform"]=o,r[v]["--app-shell-navbar-transform-rtl"]=f}}function L3(t){return Number(t)===0?"0px":py(t)}function lte({padding:t,baseStyles:e,minMediaStyles:r}){vy(t)&&(e["--app-shell-padding"]=L3(xy(t))),by(t)&&(t.base&&(e["--app-shell-padding"]=L3(t.base)),Bn(t).forEach(n=>{n!=="base"&&(r[n]=r[n]||{},r[n]["--app-shell-padding"]=L3(t[n]))}))}function hte({navbar:t,header:e,footer:r,aside:n,padding:s,theme:i}){const o={},f={},h={};ute({baseStyles:h,minMediaStyles:o,maxMediaStyles:f,navbar:t,theme:i}),ate({baseStyles:h,minMediaStyles:o,maxMediaStyles:f,aside:n,theme:i}),cte({baseStyles:h,minMediaStyles:o,header:e}),fte({baseStyles:h,minMediaStyles:o,footer:r}),lte({baseStyles:h,minMediaStyles:o,padding:s});const p=UC(Bn(o),i).map(E=>({query:`(min-width: ${F2(E.px)})`,styles:o[E.value]})),b=UC(Bn(f),i).map(E=>({query:`(max-width: ${F2(E.px)})`,styles:f[E.value]})),v=[...p,...b];return{baseStyles:h,media:v}}function dte({navbar:t,header:e,aside:r,footer:n,padding:s}){const i=za(),o=T5(),{media:f,baseStyles:h}=hte({navbar:t,header:e,footer:n,aside:r,padding:s,theme:i});return ue.createElement(zL,{media:f,styles:h,selector:o.cssVariablesSelector})}function pte({transitionDuration:t,disabled:e}){const[r,n]=Z.useState(!1),s=Z.useRef(),i=Z.useRef();return RL("resize",()=>{n(!0),clearTimeout(s.current),s.current=window.setTimeout(()=>n(!1),200)}),my(()=>{n(!0),clearTimeout(i.current),i.current=window.setTimeout(()=>n(!1),t||0)},[e,t]),r}const mte={withBorder:!0,offsetScrollbars:!0,padding:0,transitionDuration:200,transitionTimingFunction:"ease",zIndex:Ua("app")},gte=(t,{transitionDuration:e,transitionTimingFunction:r})=>({root:{"--app-shell-transition-duration":`${e}ms`,"--app-shell-transition-timing-function":r}}),Ko=mt((t,e)=>{const r=We("AppShell",mte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,navbar:p,withBorder:b,padding:v,transitionDuration:E,transitionTimingFunction:_,header:S,zIndex:P,layout:I,disabled:C,aside:T,footer:B,offsetScrollbars:N,...$}=r,H=Dt({name:"AppShell",classes:Dc,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:gte}),J=pte({disabled:C,transitionDuration:E});return ue.createElement(ete,{value:{getStyles:H,withBorder:b,zIndex:P,disabled:C,offsetScrollbars:N}},ue.createElement(dte,{navbar:p,header:S,aside:T,footer:B,padding:v}),ue.createElement(st,{ref:e,...H("root"),mod:{resizing:J,layout:I,disabled:C},...$}))});Ko.classes=Dc;Ko.displayName="@mantine/core/AppShell";Ko.Navbar=QE;Ko.Header=YE;Ko.Main=tM;Ko.Aside=eM;Ko.Footer=XE;Ko.Section=rM;var Xs={dropdown:"m-88b62a41",options:"m-b2821a6e",option:"m-92253aa5",search:"m-985517d8",empty:"m-2530cd1d",header:"m-858f94bd",footer:"m-82b967cb",group:"m-254f3e4f",groupLabel:"m-2bb2e9e5",chevron:"m-2943220b",optionsDropdownScrollArea:"m-71d052f9",optionsDropdownOption:"m-390b5f4",optionsDropdownCheckIcon:"m-8ee53fc2"};const yte={error:null},bte=(t,{size:e})=>({chevron:{"--combobox-chevron-size":jr(e,"combobox-chevron-size")}}),nM=mt((t,e)=>{const r=We("ComboboxChevron",yte,t),{size:n,error:s,style:i,className:o,classNames:f,styles:h,unstyled:p,vars:b,...v}=r,E=Dt({name:"ComboboxChevron",classes:Xs,props:r,style:i,className:o,classNames:f,styles:h,unstyled:p,vars:b,varsResolver:bte,rootSelector:"chevron"});return ue.createElement(st,{component:"svg",...v,...E("chevron"),size:n,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",mod:["combobox-chevron",{error:s}],ref:e},ue.createElement("path",{d:"M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))});nM.classes=Xs;nM.displayName="@mantine/core/ComboboxChevron";function vte(t,e,r){for(let n=t-1;n>=0;n-=1)if(!e[n].hasAttribute("data-combobox-disabled"))return n;if(r){for(let n=e.length-1;n>-1;n-=1)if(!e[n].hasAttribute("data-combobox-disabled"))return n}return t}function xte(t,e,r){for(let n=t+1;n{f||(h(!0),s==null||s(d))},[h,s,f]),C=Z.useCallback((d="unknown")=>{f&&(h(!1),n==null||n(d))},[h,n,f]),T=Z.useCallback((d="unknown")=>{f?C(d):I(d)},[C,I,f]),B=Z.useCallback(()=>{const d=document.querySelector(`#${p.current} [data-combobox-selected]`);d==null||d.removeAttribute("data-combobox-selected"),d==null||d.removeAttribute("aria-selected")},[]),N=Z.useCallback(d=>{const m=document.getElementById(p.current),x=m==null?void 0:m.querySelectorAll("[data-combobox-option]");if(!x)return null;const A=d>=x.length?0:d<0?x.length-1:d;return b.current=A,x!=null&&x[A]&&!x[A].hasAttribute("data-combobox-disabled")?(B(),x[A].setAttribute("data-combobox-selected","true"),x[A].setAttribute("aria-selected","true"),x[A].scrollIntoView({block:"nearest",behavior:o}),x[A].id):null},[o,B]),$=Z.useCallback(()=>{const d=document.querySelector(`#${p.current} [data-combobox-active]`);if(d){const m=document.querySelectorAll(`#${p.current} [data-combobox-option]`),x=Array.from(m).findIndex(A=>A===d);return N(x)}return N(0)},[N]),H=Z.useCallback(()=>N(xte(b.current,document.querySelectorAll(`#${p.current} [data-combobox-option]`),i)),[N,i]),J=Z.useCallback(()=>N(vte(b.current,document.querySelectorAll(`#${p.current} [data-combobox-option]`),i)),[N,i]),Q=Z.useCallback(()=>N(wte(document.querySelectorAll(`#${p.current} [data-combobox-option]`))),[N]),K=Z.useCallback((d="selected")=>{P.current=window.setTimeout(()=>{const m=document.querySelectorAll(`#${p.current} [data-combobox-option]`),x=Array.from(m).findIndex(A=>A.hasAttribute(`data-combobox-${d}`));b.current=x},0)},[]),se=Z.useCallback(()=>{b.current=-1,B()},[B]),w=Z.useCallback(()=>{const d=document.querySelectorAll(`#${p.current} [data-combobox-option]`),m=d==null?void 0:d[b.current];m==null||m.click()},[]),a=Z.useCallback(d=>{p.current=d},[]),u=Z.useCallback(()=>{_.current=window.setTimeout(()=>v.current.focus(),0)},[]),l=Z.useCallback(()=>{S.current=window.setTimeout(()=>E.current.focus(),0)},[]);return Z.useEffect(()=>()=>{window.clearTimeout(_.current),window.clearTimeout(S.current),window.clearTimeout(P.current)},[]),{dropdownOpened:f,openDropdown:I,closeDropdown:C,toggleDropdown:T,selectedOptionIndex:b.current,selectOption:N,selectFirstOption:Q,selectActiveOption:$,selectNextOption:H,selectPreviousOption:J,resetSelectedOption:se,updateSelectedOptionIndex:K,listId:p.current,setListId:a,clickSelectedOption:w,searchRef:v,focusSearchInput:u,targetRef:E,focusTarget:l}}const[Ate,eo]=dy("Combobox component was not found in tree");function iM({onKeyDown:t,withKeyboardNavigation:e,withAriaAttributes:r,withExpandedAttribute:n,targetType:s}){const i=eo(),[o,f]=Z.useState(null),h=b=>{t==null||t(b),!i.readOnly&&e&&(b.nativeEvent.code==="ArrowDown"&&(b.preventDefault(),i.store.dropdownOpened?f(i.store.selectNextOption()):(i.store.openDropdown("keyboard"),f(i.store.selectActiveOption()))),b.nativeEvent.code==="ArrowUp"&&(b.preventDefault(),i.store.dropdownOpened?f(i.store.selectPreviousOption()):(i.store.openDropdown("keyboard"),f(i.store.selectActiveOption()))),b.nativeEvent.code==="Enter"&&(i.store.dropdownOpened?(b.preventDefault(),i.store.clickSelectedOption()):s==="button"&&(b.preventDefault(),i.store.openDropdown("keyboard"))),b.nativeEvent.code==="Escape"&&i.store.closeDropdown("keyboard"),b.nativeEvent.code==="Space"&&s==="button"&&(b.preventDefault(),i.store.toggleDropdown("keyboard")))};return{...r?{"aria-haspopup":"listbox","aria-expanded":n&&!!(i.store.listId&&i.store.dropdownOpened)||void 0,"aria-controls":i.store.listId,"aria-activedescendant":i.store.dropdownOpened&&o||void 0,autoComplete:"off","data-expanded":i.store.dropdownOpened?!0:void 0}:{},onKeyDown:h}}const Ete={refProp:"ref",targetType:"input",withKeyboardNavigation:!0,withAriaAttributes:!0,withExpandedAttribute:!1},OD=mt((t,e)=>{const{children:r,refProp:n,withKeyboardNavigation:s,withAriaAttributes:i,withExpandedAttribute:o,targetType:f,...h}=We("ComboboxTarget",Ete,t);if(!El(r))throw new Error("Combobox.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const p=eo(),b=iM({targetType:f,withAriaAttributes:i,withKeyboardNavigation:s,withExpandedAttribute:o,onKeyDown:r.props.onKeyDown}),v=Z.cloneElement(r,{...b,...h});return ue.createElement(Lc.Target,{ref:Nc(e,p.store.targetRef)},v)});OD.displayName="@mantine/core/ComboboxTarget";const Mte={},sM=mt((t,e)=>{const{classNames:r,styles:n,className:s,style:i,hidden:o,...f}=We("ComboboxDropdown",Mte,t),h=eo();return ue.createElement(Lc.Dropdown,{...f,ref:e,role:"presentation","data-hidden":o||void 0,...h.getStyles("dropdown",{className:s,style:i,classNames:r,styles:n})})});sM.classes=Xs;sM.displayName="@mantine/core/ComboboxDropdown";const Ste={},oM=mt((t,e)=>{const r=We("ComboboxOptions",Ste,t),{classNames:n,className:s,style:i,styles:o,id:f,onMouseDown:h,labelledBy:p,...b}=r,v=eo(),E=t1(f);return Z.useEffect(()=>{v.store.setListId(E)},[E]),ue.createElement(st,{ref:e,...v.getStyles("options",{className:s,style:i,classNames:n,styles:o}),...b,id:E,role:"listbox","aria-labelledby":p,onMouseDown:_=>{_.preventDefault(),h==null||h(_)}})});oM.classes=Xs;oM.displayName="@mantine/core/ComboboxOptions";const _te={},aM=mt((t,e)=>{const r=We("ComboboxOption",_te,t),{classNames:n,className:s,style:i,styles:o,vars:f,onClick:h,id:p,active:b,onMouseDown:v,onMouseOver:E,disabled:_,selected:S,...P}=r,I=eo(),C=Z.useId(),T=p||C;return ue.createElement(st,{...I.getStyles("option",{className:s,classNames:n,styles:o,style:i}),...P,ref:e,id:T,mod:["combobox-option",{"combobox-active":b,"combobox-disabled":_,"combobox-selected":S}],role:"option",onClick:B=>{var N;_?B.preventDefault():((N=I.onOptionSubmit)==null||N.call(I,r.value,r),h==null||h(B))},onMouseDown:B=>{B.preventDefault(),v==null||v(B)},onMouseOver:B=>{I.resetSelectionOnOptionHover&&I.store.resetSelectedOption(),E==null||E(B)}})});aM.classes=Xs;aM.displayName="@mantine/core/ComboboxOption";const Pte={withAriaAttributes:!0,withKeyboardNavigation:!0},fM=mt((t,e)=>{const r=We("ComboboxSearch",Pte,t),{classNames:n,styles:s,unstyled:i,vars:o,withAriaAttributes:f,onKeyDown:h,withKeyboardNavigation:p,size:b,...v}=r,E=eo(),_=E.getStyles("search"),S=iM({targetType:"input",withAriaAttributes:f,withKeyboardNavigation:p,withExpandedAttribute:!1,onKeyDown:h});return ue.createElement(Tr,{ref:Nc(e,E.store.searchRef),classNames:[{input:_.className},n],styles:[{input:_.style},s],size:b||E.size,...S,...v,__staticSelector:"Combobox"})});fM.classes=Xs;fM.displayName="@mantine/core/ComboboxSearch";const Cte={},cM=mt((t,e)=>{const{classNames:r,className:n,style:s,styles:i,vars:o,...f}=We("ComboboxEmpty",Cte,t),h=eo();return ue.createElement(st,{ref:e,...h.getStyles("empty",{className:n,classNames:r,styles:i,style:s}),...f})});cM.classes=Xs;cM.displayName="@mantine/core/ComboboxEmpty";const Ite={},uM=mt((t,e)=>{const{classNames:r,className:n,style:s,styles:i,vars:o,...f}=We("ComboboxFooter",Ite,t),h=eo();return ue.createElement(st,{ref:e,...h.getStyles("footer",{className:n,classNames:r,style:s,styles:i}),...f})});uM.classes=Xs;uM.displayName="@mantine/core/ComboboxFooter";const Tte={},lM=mt((t,e)=>{const{classNames:r,className:n,style:s,styles:i,vars:o,...f}=We("ComboboxHeader",Tte,t),h=eo();return ue.createElement(st,{ref:e,...h.getStyles("header",{className:n,classNames:r,style:s,styles:i}),...f})});lM.classes=Xs;lM.displayName="@mantine/core/ComboboxHeader";const kte={refProp:"ref",targetType:"input",withKeyboardNavigation:!0,withAriaAttributes:!0,withExpandedAttribute:!1},ND=mt((t,e)=>{const{children:r,refProp:n,withKeyboardNavigation:s,withAriaAttributes:i,withExpandedAttribute:o,targetType:f,...h}=We("ComboboxEventsTarget",kte,t);if(!El(r))throw new Error("Combobox.EventsTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const p=eo(),b=iM({targetType:f,withAriaAttributes:i,withKeyboardNavigation:s,withExpandedAttribute:o,onKeyDown:r.props.onKeyDown});return Z.cloneElement(r,{...b,...h,[n]:Nc(e,p.store.targetRef,r==null?void 0:r.ref)})});ND.displayName="@mantine/core/ComboboxEventsTarget";const Rte={refProp:"ref"},LD=mt((t,e)=>{const{children:r,refProp:n}=We("ComboboxDropdownTarget",Rte,t);if(eo(),!El(r))throw new Error("Combobox.DropdownTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");return ue.createElement(Lc.Target,{ref:e,refProp:n},r)});LD.displayName="@mantine/core/ComboboxDropdownTarget";const Bte={},hM=mt((t,e)=>{const{classNames:r,className:n,style:s,styles:i,vars:o,children:f,label:h,...p}=We("ComboboxGroup",Bte,t),b=eo();return ue.createElement(st,{ref:e,...b.getStyles("group",{className:n,classNames:r,style:s,styles:i}),...p},h&&ue.createElement("div",{...b.getStyles("groupLabel",{classNames:r,styles:i})},h),f)});hM.classes=Xs;hM.displayName="@mantine/core/ComboboxGroup";const DD=Z.forwardRef(({size:t,onMouseDown:e,onClick:r,onClear:n,...s},i)=>ue.createElement(Pl,{ref:i,size:t||"sm",variant:"transparent",tabIndex:-1,"aria-hidden":!0,...s,onMouseDown:o=>{o.preventDefault(),e==null||e(o)},onClick:o=>{n(),r==null||r(o)}}));DD.displayName="@mantine/core/ComboboxClearButton";const Ote={keepMounted:!0,withinPortal:!0,resetSelectionOnOptionHover:!1,width:"target",transitionProps:{transition:"fade",duration:0}},Nte=(t,{size:e,dropdownPadding:r})=>({options:{"--combobox-option-fz":Os(e),"--combobox-option-padding":jr(e,"combobox-option-padding")},dropdown:{"--combobox-padding":r===void 0?void 0:ke(r),"--combobox-option-fz":Os(e),"--combobox-option-padding":jr(e,"combobox-option-padding")}});function kt(t){const e=We("Combobox",Ote,t),{classNames:r,styles:n,unstyled:s,children:i,store:o,vars:f,onOptionSubmit:h,size:p,dropdownPadding:b,resetSelectionOnOptionHover:v,__staticSelector:E,readOnly:_,...S}=e,P=H2(),I=o||P,C=Dt({name:E||"Combobox",classes:Xs,props:e,classNames:r,styles:n,unstyled:s,vars:f,varsResolver:Nte});return ue.createElement(Ate,{value:{getStyles:C,store:I,onOptionSubmit:h,size:p,resetSelectionOnOptionHover:v,readOnly:_}},ue.createElement(Lc,{opened:I.dropdownOpened,...S,onClose:I.closeDropdown,withRoles:!1,unstyled:s},i))}const Lte=t=>t;kt.extend=Lte;kt.classes=Xs;kt.displayName="@mantine/core/Combobox";kt.Target=OD;kt.Dropdown=sM;kt.Options=oM;kt.Option=aM;kt.Search=fM;kt.Empty=cM;kt.Chevron=nM;kt.Footer=uM;kt.Header=lM;kt.EventsTarget=ND;kt.DropdownTarget=LD;kt.Group=hM;kt.ClearButton=DD;const $D=Z.createContext(null),Dte=$D.Provider;function $te(){return{withinGroup:!!Z.useContext($D)}}var z5={root:"m-f85678b6",image:"m-11f8ac07",placeholder:"m-104cd71f",group:"m-11def92b"};const Fte={},Ute=(t,{spacing:e})=>({group:{"--ag-spacing":py(e)}}),dM=mt((t,e)=>{const r=We("AvatarGroup",Fte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,spacing:p,...b}=r,v=Dt({name:"AvatarGroup",classes:z5,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Ute,rootSelector:"group"});return ue.createElement(Dte,{value:!0},ue.createElement(st,{ref:e,...v("group"),...b}))});dM.classes=z5;dM.displayName="@mantine/core/AvatarGroup";function zte(t){return ue.createElement("svg",{...t,"data-avatar-placeholder-icon":!0,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},ue.createElement("path",{d:"M0.877014 7.49988C0.877014 3.84219 3.84216 0.877045 7.49985 0.877045C11.1575 0.877045 14.1227 3.84219 14.1227 7.49988C14.1227 11.1575 11.1575 14.1227 7.49985 14.1227C3.84216 14.1227 0.877014 11.1575 0.877014 7.49988ZM7.49985 1.82704C4.36683 1.82704 1.82701 4.36686 1.82701 7.49988C1.82701 8.97196 2.38774 10.3131 3.30727 11.3213C4.19074 9.94119 5.73818 9.02499 7.50023 9.02499C9.26206 9.02499 10.8093 9.94097 11.6929 11.3208C12.6121 10.3127 13.1727 8.97172 13.1727 7.49988C13.1727 4.36686 10.6328 1.82704 7.49985 1.82704ZM10.9818 11.9787C10.2839 10.7795 8.9857 9.97499 7.50023 9.97499C6.01458 9.97499 4.71624 10.7797 4.01845 11.9791C4.97952 12.7272 6.18765 13.1727 7.49985 13.1727C8.81227 13.1727 10.0206 12.727 10.9818 11.9787ZM5.14999 6.50487C5.14999 5.207 6.20212 4.15487 7.49999 4.15487C8.79786 4.15487 9.84999 5.207 9.84999 6.50487C9.84999 7.80274 8.79786 8.85487 7.49999 8.85487C6.20212 8.85487 5.14999 7.80274 5.14999 6.50487ZM7.49999 5.10487C6.72679 5.10487 6.09999 5.73167 6.09999 6.50487C6.09999 7.27807 6.72679 7.90487 7.49999 7.90487C8.27319 7.90487 8.89999 7.27807 8.89999 6.50487C8.89999 5.73167 8.27319 5.10487 7.49999 5.10487Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const jte={},Hte=(t,{size:e,radius:r,variant:n,gradient:s,color:i})=>{const o=t.variantColorResolver({color:i||"gray",theme:t,gradient:s,variant:n||"light"});return{root:{"--avatar-size":jr(e,"avatar-size"),"--avatar-radius":r===void 0?void 0:ri(r),"--avatar-bg":i||n?o.background:void 0,"--avatar-color":i||n?o.color:void 0,"--avatar-bd":i||n?o.border:void 0}}},kf=Ui((t,e)=>{const r=We("Avatar",jte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,src:p,alt:b,radius:v,color:E,gradient:_,imageProps:S,children:P,...I}=r,C=$te(),[T,B]=Z.useState(!p),N=Dt({name:"Avatar",props:r,classes:z5,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Hte});return Z.useEffect(()=>B(!p),[p]),ue.createElement(st,{...N("root"),mod:{"within-group":C.withinGroup},ref:e,...I},T?ue.createElement("span",{...N("placeholder"),title:b},P||ue.createElement(zte,null)):ue.createElement("img",{...S,...N("image"),src:p,alt:b,onError:$=>{var H;B(!0),(H=S==null?void 0:S.onError)==null||H.call(S,$)}}))});kf.classes=z5;kf.displayName="@mantine/core/Avatar";kf.Group=dM;var FD={root:"m-347db0ec","root--dot":"m-fbd81e3d",label:"m-5add502a",section:"m-91fdda9b"};const qte={},Gte=(t,{radius:e,color:r,gradient:n,variant:s,size:i})=>{const o=t.variantColorResolver({color:r||t.primaryColor,theme:t,gradient:n,variant:s||"filled"});return{root:{"--badge-height":jr(i,"badge-height"),"--badge-padding-x":jr(i,"badge-padding-x"),"--badge-fz":jr(i,"badge-fz"),"--badge-radius":e===void 0?void 0:ri(e),"--badge-bg":r||s?o.background:void 0,"--badge-color":r||s?o.color:void 0,"--badge-bd":r||s?o.border:void 0,"--badge-dot-color":s==="dot"?Uf(r,t):void 0}}},j5=Ui((t,e)=>{const r=We("Badge",qte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,radius:p,color:b,gradient:v,leftSection:E,rightSection:_,children:S,variant:P,fullWidth:I,...C}=r,T=Dt({name:"Badge",props:r,classes:FD,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Gte});return ue.createElement(st,{variant:P,mod:{block:I},...T("root",{variant:P}),ref:e,...C},E&&ue.createElement("span",{...T("section"),"data-position":"left"},E),ue.createElement("span",{...T("label")},S),_&&ue.createElement("span",{...T("section"),"data-position":"right"},_))});j5.classes=FD;j5.displayName="@mantine/core/Badge";var H5={root:"m-77c9d27d",inner:"m-80f1301b",loader:"m-a25b86ee",label:"m-811560b9",section:"m-a74036a",group:"m-80d6d844"};const hI={orientation:"horizontal"},Vte=(t,{borderWidth:e})=>({group:{"--button-border-width":ke(e)}}),pM=mt((t,e)=>{const r=We("ButtonGroup",hI,t),{className:n,style:s,classNames:i,styles:o,unstyled:f,orientation:h,vars:p,borderWidth:b,variant:v,...E}=We("ButtonGroup",hI,t),_=Dt({name:"ButtonGroup",props:r,classes:H5,className:n,style:s,classNames:i,styles:o,unstyled:f,vars:p,varsResolver:Vte,rootSelector:"group"});return ue.createElement(st,{..._("group"),ref:e,variant:v,mod:{"data-orientation":h},role:"group",...E})});pM.classes=H5;pM.displayName="@mantine/core/ButtonGroup";const Kte={},Wte=(t,{radius:e,color:r,gradient:n,variant:s,size:i,justify:o})=>{const f=t.variantColorResolver({color:r||t.primaryColor,theme:t,gradient:n,variant:s||"filled"});return{root:{"--button-justify":o,"--button-height":jr(i,"button-height"),"--button-padding-x":jr(i,"button-padding-x"),"--button-fz":i!=null&&i.includes("compact")?Os(i.replace("compact-","")):Os(i),"--button-radius":e===void 0?void 0:ri(e),"--button-bg":r||s?f.background:void 0,"--button-hover":r||s?f.hover:void 0,"--button-color":r||s?f.color:void 0,"--button-bd":r||s?f.border:void 0,"--button-hover-color":r||s?f.hoverColor:void 0}}},Ii=Ui((t,e)=>{const r=We("Button",Kte,t),{style:n,vars:s,className:i,color:o,disabled:f,children:h,leftSection:p,rightSection:b,fullWidth:v,variant:E,radius:_,loading:S,loaderProps:P,gradient:I,classNames:C,styles:T,unstyled:B,"data-disabled":N,...$}=r,H=Dt({name:"Button",props:r,classes:H5,className:i,style:n,classNames:C,styles:T,unstyled:B,vars:s,varsResolver:Wte}),J=!!p,Q=!!b;return ue.createElement(gy,{ref:e,...H("root",{active:!f&&!S&&!N}),unstyled:B,variant:E,disabled:f||S,mod:{disabled:f||N,loading:S,block:v,"with-left-section":J,"with-right-section":Q},...$},ue.createElement(st,{component:"span",...H("loader"),"aria-hidden":!0},ue.createElement(_l,{color:"var(--button-color)",size:"calc(var(--button-height) / 1.8)",...P})),ue.createElement("span",{...H("inner")},p&&ue.createElement(st,{component:"span",...H("section"),mod:{position:"left"}},p),ue.createElement(st,{component:"span",mod:{loading:S},...H("label")},h),b&&ue.createElement(st,{component:"span",...H("section"),mod:{position:"right"}},b)))});Ii.classes=H5;Ii.displayName="@mantine/core/Button";Ii.Group=pM;const Jte={timeout:1e3};function UD(t){const{children:e,timeout:r,value:n,...s}=We("CopyButton",Jte,t),i=TQ({timeout:r}),o=()=>i.copy(n);return ue.createElement(ue.Fragment,null,e({copy:o,copied:i.copied,...s}))}UD.displayName="@mantine/core/CopyButton";var zD={root:"m-e2125a27",closeButton:"m-5abab665"};const Zte={shadow:"md",p:"md",withBorder:!1,transitionProps:{transition:"pop-top-right",duration:200},position:{bottom:30,right:30}},Qte=(t,{size:e})=>({root:{"--dialog-size":jr(e,"dialog-size")}}),q2=mt((t,e)=>{const r=We("Dialog",Zte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,zIndex:p,position:b,keepMounted:v,opened:E,transitionProps:_,withCloseButton:S,withinPortal:P,children:I,onClose:C,portalProps:T,...B}=r,N=Dt({name:"Dialog",classes:zD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Qte});return ue.createElement(ZE,{zIndex:p,position:b,ref:e,withinPortal:P,portalProps:T,unstyled:f},ue.createElement(Sl,{keepMounted:v,mounted:E,..._},$=>ue.createElement(zf,{unstyled:f,...N("root",{style:$}),...B},S&&ue.createElement(Pl,{onClick:C,unstyled:f,...N("closeButton")}),I)))});q2.classes=zD;q2.displayName="@mantine/core/Dialog";var jD={root:"m-3eebeb36",label:"m-9e365f20"};const Yte={orientation:"horizontal"},Xte=(t,{color:e,variant:r,size:n})=>({root:{"--divider-color":e?Uf(e,t):void 0,"--divider-border-style":r,"--divider-size":jr(n,"divider-size")}}),q5=mt((t,e)=>{const r=We("Divider",Yte,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,color:p,orientation:b,label:v,labelPosition:E,..._}=r,S=Dt({name:"Divider",classes:jD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:Xte});return ue.createElement(st,{ref:e,mod:{orientation:b,"with-label":!!v},...S("root"),..._,role:"separator"},v&&ue.createElement(st,{component:"span",mod:{position:E},...S("label")},v))});q5.classes=jD;q5.displayName="@mantine/core/Divider";var HD={root:"m-9e117634"};const ere={},tre=(t,{radius:e,fit:r})=>({root:{"--image-radius":e===void 0?void 0:ri(e),"--image-object-fit":r}}),mM=Ui((t,e)=>{const r=We("Image",ere,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,onError:p,src:b,radius:v,fit:E,fallbackSrc:_,...S}=r,[P,I]=Z.useState(!b);Z.useEffect(()=>I(!b),[b]);const C=Dt({name:"Image",classes:HD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:tre});return P&&_?ue.createElement(st,{component:"img",src:_,...C("root"),onError:p,mod:"fallback",...S}):ue.createElement(st,{component:"img",ref:e,...C("root"),src:b,onError:T=>{p==null||p(T),I(!0)},...S})});mM.classes=HD;mM.displayName="@mantine/core/Image";var qD={root:"m-6e45937b",loader:"m-e8eb006c",overlay:"m-df587f17"};const dI={transitionProps:{transition:"fade",duration:0},overlayProps:{backgroundOpacity:.75},zIndex:Ua("overlay")},rre=(t,{zIndex:e})=>({root:{"--lo-z-index":e==null?void 0:e.toString()}}),gM=mt((t,e)=>{const r=We("LoadingOverlay",dI,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,transitionProps:p,loaderProps:b,overlayProps:v,visible:E,zIndex:_,...S}=r,P=za(),I=Dt({name:"LoadingOverlay",classes:qD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:rre}),C={...dI.overlayProps,...v};return ue.createElement(Sl,{transition:"fade",...p,mounted:!!E},T=>ue.createElement(st,{...I("root",{style:T}),ref:e,...S},ue.createElement(_l,{...I("loader"),unstyled:f,...b}),ue.createElement(ug,{...C,...I("overlay"),"data-light":!0,unstyled:f,color:(v==null?void 0:v.color)||P.white}),ue.createElement(ug,{...C,...I("overlay"),"data-dark":!0,unstyled:f,color:(v==null?void 0:v.color)||P.colors.dark[5]})))});gM.classes=qD;gM.displayName="@mantine/core/LoadingOverlay";const[nre,s1]=dy("Modal component was not found in tree");var t0={root:"m-9df02822",content:"m-54c44539",inner:"m-1f958f16",header:"m-d0e2b9cd"};const ire={__staticSelector:"Modal",closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:Ua("modal"),transitionProps:{duration:200,transition:"pop"},yOffset:"5dvh"},sre=(t,{radius:e,size:r,yOffset:n,xOffset:s})=>({root:{"--modal-radius":e===void 0?void 0:ri(e),"--modal-size":jr(r,"modal-size"),"--modal-y-offset":ke(n),"--modal-x-offset":ke(s)}}),G5=mt((t,e)=>{const r=We("ModalRoot",ire,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,yOffset:p,scrollAreaComponent:b,radius:v,fullScreen:E,centered:_,xOffset:S,__staticSelector:P,...I}=r,C=Dt({name:P,classes:t0,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:sre});return ue.createElement(nre,{value:{yOffset:p,scrollAreaComponent:b,getStyles:C}},ue.createElement(Pee,{ref:e,...C("root"),"data-full-screen":E||void 0,"data-centered":_||void 0,unstyled:f,...I}))});G5.classes=t0;G5.displayName="@mantine/core/ModalRoot";const ore={},V5=mt((t,e)=>{const r=We("ModalBody",ore,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=s1();return ue.createElement(SD,{ref:e,...p.getStyles("body",{classNames:n,style:i,styles:o,className:s}),...h})});V5.classes=t0;V5.displayName="@mantine/core/ModalBody";const are={},K5=mt((t,e)=>{const r=We("ModalCloseButton",are,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=s1();return ue.createElement(_D,{ref:e,...p.getStyles("close",{classNames:n,style:i,styles:o,className:s}),...h})});K5.classes=t0;K5.displayName="@mantine/core/ModalCloseButton";const fre={},W5=mt((t,e)=>{const r=We("ModalOverlay",fre,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=s1();return ue.createElement(CD,{ref:e,...p.getStyles("overlay",{classNames:n,style:i,styles:o,className:s}),...h})});W5.classes=t0;W5.displayName="@mantine/core/ModalOverlay";const cre={},J5=mt((t,e)=>{const r=We("ModalContent",cre,t),{classNames:n,className:s,style:i,styles:o,vars:f,children:h,...p}=r,b=s1(),v=b.scrollAreaComponent||Bee;return ue.createElement(Iee,{...b.getStyles("content",{className:s,style:i,styles:o,classNames:n}),innerProps:b.getStyles("inner",{className:s,style:i,styles:o,classNames:n}),ref:e,...p},ue.createElement(v,{style:{maxHeight:`calc(100vh - (${ke(b.yOffset)} * 2))`}},h))});J5.classes=t0;J5.displayName="@mantine/core/ModalContent";const ure={},Z5=mt((t,e)=>{const r=We("ModalTitle",ure,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=s1();return ue.createElement(ID,{ref:e,...p.getStyles("title",{classNames:n,style:i,styles:o,className:s}),...h})});Z5.classes=t0;Z5.displayName="@mantine/core/ModalTitle";const lre={},Q5=mt((t,e)=>{const r=We("ModalHeader",lre,t),{classNames:n,className:s,style:i,styles:o,vars:f,...h}=r,p=s1();return ue.createElement(PD,{ref:e,...p.getStyles("header",{classNames:n,style:i,styles:o,className:s}),...h})});Q5.classes=t0;Q5.displayName="@mantine/core/ModalHeader";const hre={closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:Ua("modal"),transitionProps:{duration:200,transition:"pop"},withOverlay:!0,withCloseButton:!0},js=mt((t,e)=>{const{title:r,withOverlay:n,overlayProps:s,withCloseButton:i,closeButtonProps:o,children:f,radius:h,...p}=We("Modal",hre,t),b=!!r||i;return ue.createElement(G5,{ref:e,radius:h,...p},n&&ue.createElement(W5,{...s}),ue.createElement(J5,{radius:h},b&&ue.createElement(Q5,null,r&&ue.createElement(Z5,null,r),i&&ue.createElement(K5,{...o})),ue.createElement(V5,null,f)))});js.classes=t0;js.displayName="@mantine/core/Modal";js.Root=G5;js.Overlay=W5;js.Content=J5;js.Body=V5;js.Header=Q5;js.Title=Z5;js.CloseButton=K5;var GD={root:"m-a513464",icon:"m-a4ceffb",loader:"m-b0920b15",body:"m-a49ed24",title:"m-3feedf16",description:"m-3d733a3a",closeButton:"m-919a4d88"};const dre={withCloseButton:!0},pre=(t,{radius:e,color:r})=>({root:{"--notification-radius":e===void 0?void 0:ri(e),"--notification-color":r?Uf(r,t):void 0}}),G2=mt((t,e)=>{const r=We("Notification",dre,t),{className:n,color:s,radius:i,loading:o,withCloseButton:f,withBorder:h,title:p,icon:b,children:v,onClose:E,closeButtonProps:_,classNames:S,style:P,styles:I,unstyled:C,variant:T,vars:B,...N}=r,$=Dt({name:"Notification",classes:GD,props:r,className:n,style:P,classNames:S,styles:I,unstyled:C,vars:B,varsResolver:pre});return ue.createElement(st,{...$("root"),mod:{"data-with-icon":!!b||o,"data-with-border":h},ref:e,variant:T,...N,role:"alert"},b&&!o&&ue.createElement("div",{...$("icon")},b),o&&ue.createElement(_l,{size:28,color:s,...$("loader")}),ue.createElement("div",{...$("body")},p&&ue.createElement("div",{...$("title")},p),ue.createElement(st,{...$("description"),mod:{"data-with-title":!!p}},v)),f&&ue.createElement(Pl,{iconSize:16,color:"gray",..._,unstyled:C,onClick:E,...$("closeButton")}))});G2.classes=GD;G2.displayName="@mantine/core/Notification";const mre={duration:100,transition:"fade"};function gre(t,e){return{...mre,...e,...t}}var Y5={tooltip:"m-1b3c8819",arrow:"m-f898399f"};function yre({offset:t,position:e}){const[r,n]=Z.useState(!1),s=Z.useRef(),{x:i,y:o,elements:f,refs:h,update:p,placement:b}=HE({placement:e,middleware:[$E({crossAxis:!0,padding:5,rootBoundary:"document"})]}),v=b.includes("right")?t:e.includes("left")?t*-1:0,E=b.includes("bottom")?t:e.includes("top")?t*-1:0,_=Z.useCallback(({clientX:S,clientY:P})=>{h.setPositionReference({getBoundingClientRect(){return{width:0,height:0,x:S,y:P,left:S+v,top:P+E,right:S,bottom:P}}})},[f.reference]);return Z.useEffect(()=>{if(h.floating.current){const S=s.current;S.addEventListener("mousemove",_);const P=Cf(h.floating.current);return P.forEach(I=>{I.addEventListener("scroll",p)}),()=>{S.removeEventListener("mousemove",_),P.forEach(I=>{I.removeEventListener("scroll",p)})}}},[f.reference,h.floating.current,p,_,r]),{handleMouseMove:_,x:i,y:o,opened:r,setOpened:n,boundaryRef:s,floating:h.setFloating}}const bre={refProp:"ref",withinPortal:!0,offset:10,position:"right",zIndex:Ua("popover")},vre=(t,{radius:e,color:r})=>({tooltip:{"--tooltip-radius":e===void 0?void 0:ri(e),"--tooltip-bg":r?Uf(r,t):void 0,"--tooltip-color":r?"var(--mantine-color-white)":void 0}}),yM=mt((t,e)=>{const r=We("TooltipFloating",bre,t),{children:n,refProp:s,withinPortal:i,style:o,className:f,classNames:h,styles:p,unstyled:b,radius:v,color:E,label:_,offset:S,position:P,multiline:I,zIndex:C,disabled:T,variant:B,vars:N,portalProps:$,...H}=r,J=za(),Q=Dt({name:"TooltipFloating",props:r,classes:Y5,className:f,style:o,classNames:h,styles:p,unstyled:b,rootSelector:"tooltip",vars:N,varsResolver:vre}),{handleMouseMove:K,x:se,y:w,opened:a,boundaryRef:u,floating:l,setOpened:d}=yre({offset:S,position:P});if(!El(n))throw new Error("[@mantine/core] Tooltip.Floating component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported");const m=Nc(u,n.ref,e),x=y=>{var c,g;(g=(c=n.props).onMouseEnter)==null||g.call(c,y),K(y),d(!0)},A=y=>{var c,g;(g=(c=n.props).onMouseLeave)==null||g.call(c,y),d(!1)};return ue.createElement(ue.Fragment,null,ue.createElement(n1,{...$,withinPortal:i},ue.createElement(st,{...H,...Q("tooltip",{style:{...jL(o,J),zIndex:C,display:!T&&a?"block":"none",top:(w&&Math.round(w))??"",left:(se&&Math.round(se))??""}}),variant:B,ref:l},_)),Z.cloneElement(n,{...n.props,[s]:m,onMouseEnter:x,onMouseLeave:A}))});yM.classes=Y5;yM.displayName="@mantine/core/TooltipFloating";const VD=Z.createContext(!1),xre=VD.Provider,wre=()=>Z.useContext(VD),Are={openDelay:0,closeDelay:0};function KD(t){const{openDelay:e,closeDelay:r,children:n}=We("TooltipGroup",Are,t);return ue.createElement(xre,{value:!0},ue.createElement(LX,{delay:{open:e,close:r}},n))}KD.displayName="@mantine/core/TooltipGroup";function Ere(t){var H,J,Q;const[e,r]=Z.useState(!1),s=typeof t.opened=="boolean"?t.opened:e,i=wre(),o=t1(),{delay:f,currentId:h,setCurrentId:p}=pD(),b=Z.useCallback(K=>{r(K),K&&p(o)},[p,o]),{x:v,y:E,context:_,refs:S,update:P,placement:I,middlewareData:{arrow:{x:C,y:T}={}}}=HE({placement:t.position,open:s,onOpenChange:b,middleware:[YL(t.offset),$E({padding:8}),JL(),oD({element:t.arrowRef,padding:t.arrowOffset}),...t.inline?[QL()]:[]]}),{getReferenceProps:B,getFloatingProps:N}=KX([NX(_,{enabled:(H=t.events)==null?void 0:H.hover,delay:i?f:{open:t.openDelay,close:t.closeDelay},mouseOnly:!((J=t.events)!=null&&J.touch)}),VX(_,{enabled:(Q=t.events)==null?void 0:Q.focus,keyboardOnly:!0}),WX(_,{role:"tooltip"}),GX(_,{enabled:typeof t.opened>"u"}),DX(_,{id:o})]);gD({opened:s,position:t.position,positionDependencies:t.positionDependencies,floating:{refs:S,update:P}}),nl(()=>{var K;(K=t.onPositionChange)==null||K.call(t,I)},[I]);const $=s&&h&&h!==o;return{x:v,y:E,arrowX:C,arrowY:T,reference:S.setReference,floating:S.setFloating,getFloatingProps:N,getReferenceProps:B,isGroupPhase:$,opened:s,placement:I}}const pI={position:"top",refProp:"ref",withinPortal:!0,inline:!1,arrowSize:4,arrowOffset:5,arrowRadius:0,arrowPosition:"side",offset:5,transitionProps:{duration:100,transition:"fade"},events:{hover:!0,focus:!1,touch:!1},zIndex:Ua("popover"),positionDependencies:[]},Mre=(t,{radius:e,color:r})=>({tooltip:{"--tooltip-radius":e===void 0?void 0:ri(e),"--tooltip-bg":r?Uf(r,t):void 0,"--tooltip-color":r?"var(--mantine-color-white)":void 0}}),wy=mt((t,e)=>{const r=We("Tooltip",pI,t),{children:n,position:s,refProp:i,label:o,openDelay:f,closeDelay:h,onPositionChange:p,opened:b,withinPortal:v,radius:E,color:_,classNames:S,styles:P,unstyled:I,style:C,className:T,withArrow:B,arrowSize:N,arrowOffset:$,arrowRadius:H,arrowPosition:J,offset:Q,transitionProps:K,multiline:se,events:w,zIndex:a,disabled:u,positionDependencies:l,onClick:d,onMouseEnter:m,onMouseLeave:x,inline:A,variant:y,keepMounted:c,vars:g,portalProps:M,...R}=We("Tooltip",pI,r),{dir:L}=RE(),k=Z.useRef(null),D=Ere({position:mD(L,s),closeDelay:h,openDelay:f,onPositionChange:p,opened:b,events:w,arrowRef:k,arrowOffset:$,offset:typeof Q=="number"?Q+(B?N/2:0):Q,positionDependencies:[...l,n],inline:A}),U=Dt({name:"Tooltip",props:r,classes:Y5,className:T,style:C,classNames:S,styles:P,unstyled:I,rootSelector:"tooltip",vars:g,varsResolver:Mre});if(!El(n))throw new Error("[@mantine/core] Tooltip component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported");const V=Nc(D.reference,n.ref,e),G=gre(K,{duration:100,transition:"fade"});return ue.createElement(ue.Fragment,null,ue.createElement(n1,{...M,withinPortal:v},ue.createElement(Sl,{...G,keepMounted:c,mounted:!u&&!!D.opened,duration:D.isGroupPhase?10:G.duration},Y=>ue.createElement(st,{...R,variant:y,mod:{multiline:se},...D.getFloatingProps({ref:D.floating,className:U("tooltip").className,style:{...U("tooltip").style,...Y,zIndex:a,top:D.y??0,left:D.x??0}})},o,ue.createElement(qE,{ref:k,arrowX:D.arrowX,arrowY:D.arrowY,visible:B,position:D.placement,arrowSize:N,arrowOffset:$,arrowRadius:H,arrowPosition:J,...U("arrow")})))),Z.cloneElement(n,D.getReferenceProps({onClick:d,onMouseEnter:m,onMouseLeave:x,onMouseMove:r.onMouseMove,onPointerDown:r.onPointerDown,onPointerEnter:r.onPointerEnter,[i]:V,className:En(T,n.props.className),...n.props})))});wy.classes=Y5;wy.displayName="@mantine/core/Tooltip";wy.Floating=yM;wy.Group=KD;var WD={root:"m-18320242","skeleton-fade":"m-299c329c"};const Sre={visible:!0,animate:!0},_re=(t,{width:e,height:r,radius:n,circle:s})=>({root:{"--skeleton-height":ke(r),"--skeleton-width":ke(s?r:e),"--skeleton-radius":s?"1000px":n===void 0?void 0:ri(n)}}),Uu=mt((t,e)=>{const r=We("Skeleton",Sre,t),{classNames:n,className:s,style:i,styles:o,unstyled:f,vars:h,width:p,height:b,circle:v,visible:E,radius:_,animate:S,...P}=r,I=Dt({name:"Skeleton",classes:WD,props:r,className:s,style:i,classNames:n,styles:o,unstyled:f,vars:h,varsResolver:_re});return ue.createElement(st,{ref:e,...I("root"),mod:{visible:E,animate:S},...P})});Uu.classes=WD;Uu.displayName="@mantine/core/Skeleton";const mI=t=>{let e;const r=new Set,n=(h,p)=>{const b=typeof h=="function"?h(e):h;if(!Object.is(b,e)){const v=e;e=p??(typeof b!="object"||b===null)?b:Object.assign({},e,b),r.forEach(E=>E(e,v))}},s=()=>e,f={setState:n,getState:s,subscribe:h=>(r.add(h),()=>r.delete(h)),destroy:()=>{r.clear()}};return e=t(n,s,f),f},Pre=t=>t?mI(t):mI;var JD={exports:{}},ZD={},QD={exports:{}},YD={};/** - * @license React - * use-sync-external-store-shim.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var fp=Z;function Cre(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Ire=typeof Object.is=="function"?Object.is:Cre,Tre=fp.useState,kre=fp.useEffect,Rre=fp.useLayoutEffect,Bre=fp.useDebugValue;function Ore(t,e){var r=e(),n=Tre({inst:{value:r,getSnapshot:e}}),s=n[0].inst,i=n[1];return Rre(function(){s.value=r,s.getSnapshot=e,D3(s)&&i({inst:s})},[t,r,e]),kre(function(){return D3(s)&&i({inst:s}),t(function(){D3(s)&&i({inst:s})})},[t]),Bre(r),r}function D3(t){var e=t.getSnapshot;t=t.value;try{var r=e();return!Ire(t,r)}catch{return!0}}function Nre(t,e){return e()}var Lre=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?Nre:Ore;YD.useSyncExternalStore=fp.useSyncExternalStore!==void 0?fp.useSyncExternalStore:Lre;QD.exports=YD;var Dre=QD.exports;/** - * @license React - * use-sync-external-store-shim/with-selector.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var X5=Z,$re=Dre;function Fre(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Ure=typeof Object.is=="function"?Object.is:Fre,zre=$re.useSyncExternalStore,jre=X5.useRef,Hre=X5.useEffect,qre=X5.useMemo,Gre=X5.useDebugValue;ZD.useSyncExternalStoreWithSelector=function(t,e,r,n,s){var i=jre(null);if(i.current===null){var o={hasValue:!1,value:null};i.current=o}else o=i.current;i=qre(function(){function h(_){if(!p){if(p=!0,b=_,_=n(_),s!==void 0&&o.hasValue){var S=o.value;if(s(S,_))return v=S}return v=_}if(S=v,Ure(b,_))return S;var P=n(_);return s!==void 0&&s(S,P)?S:(b=_,v=P)}var p=!1,b,v,E=r===void 0?null:r;return[function(){return h(e())},E===null?void 0:function(){return h(E())}]},[e,r,n,s]);var f=zre(t,i[0],i[1]);return Hre(function(){o.hasValue=!0,o.value=f},[f]),Gre(f),f};JD.exports=ZD;var Vre=JD.exports;const Kre=Qs(Vre),{useDebugValue:Wre}=ue,{useSyncExternalStoreWithSelector:Jre}=Kre;function Zre(t,e=t.getState,r){const n=Jre(t.subscribe,t.getState,t.getServerState||t.getState,e,r);return Wre(n),n}const gI=t=>{const e=typeof t=="function"?Pre(t):t,r=(n,s)=>Zre(e,n,s);return Object.assign(r,e),r},Qre=t=>t?gI(t):gI;var Yre=t=>Qre(t);const bM=Yre(t=>({fetching:!1,accountDetails:{},authDetails:{},chainId:localStorage.getItem("chainId")?parseInt(localStorage.getItem("chainId")):11155111,confirming:!1,confirmed:!1,claimDetails:{chainId:11155111},wallet:{},setChainId:e=>{t(r=>({...r,chainId:e}))},setClaimDetails:e=>{t(r=>({...r,claimDetails:e}))},setWallet:e=>{t(r=>({...r,wallet:e}))},setConfirming:e=>{t(r=>({...r,confirming:e}))},setConfirmed:e=>{t(r=>({...r,confirmed:e}))},setFetching:e=>{t(r=>({...r,fetching:e}))},setAccountDetails:e=>t(r=>({accountDetails:e})),setAuthDetails:e=>t(r=>({authDetails:e}))}));var Ve={};(function(t){Object.defineProperty(t,Symbol.toStringTag,{value:"Module"});const e=Ln,r=tO,n=o=>o&&o.__esModule?o:{default:o},s=n(r),i=globalThis||void 0||self;Object.defineProperty(t,"Buffer",{enumerable:!0,get:()=>e.Buffer}),Object.defineProperty(t,"process",{enumerable:!0,get:()=>s.default}),t.global=i})(Ve);var vr="-ms-",Om="-moz-",Qt="-webkit-",XD="comm",ex="rule",vM="decl",Xre="@import",e$="@keyframes",ene="@layer",tne=Math.abs,xM=String.fromCharCode,S9=Object.assign;function rne(t,e){return yn(t,0)^45?(((e<<2^yn(t,0))<<2^yn(t,1))<<2^yn(t,2))<<2^yn(t,3):0}function t$(t){return t.trim()}function Qa(t,e){return(t=e.exec(t))?t[0]:t}function Pt(t,e,r){return t.replace(e,r)}function Tv(t,e){return t.indexOf(e)}function yn(t,e){return t.charCodeAt(e)|0}function cp(t,e,r){return t.slice(e,r)}function va(t){return t.length}function r$(t){return t.length}function dm(t,e){return e.push(t),t}function nne(t,e){return t.map(e).join("")}function yI(t,e){return t.filter(function(r){return!Qa(r,e)})}var tx=1,up=1,n$=0,Hs=0,Xr=0,o1="";function rx(t,e,r,n,s,i,o,f){return{value:t,root:e,parent:r,type:n,props:s,children:i,line:tx,column:up,length:o,return:"",siblings:f}}function x0(t,e){return S9(rx("",null,null,"",null,null,0,t.siblings),t,{length:-t.length},e)}function Ql(t){for(;t.root;)t=x0(t.root,{children:[t]});dm(t,t.siblings)}function ine(){return Xr}function sne(){return Xr=Hs>0?yn(o1,--Hs):0,up--,Xr===10&&(up=1,tx--),Xr}function Fo(){return Xr=Hs2||_9(Xr)>3?"":" "}function cne(t,e){for(;--e&&Fo()&&!(Xr<48||Xr>102||Xr>57&&Xr<65||Xr>70&&Xr<97););return nx(t,kv()+(e<6&&zu()==32&&Fo()==32))}function P9(t){for(;Fo();)switch(Xr){case t:return Hs;case 34:case 39:t!==34&&t!==39&&P9(Xr);break;case 40:t===41&&P9(t);break;case 92:Fo();break}return Hs}function une(t,e){for(;Fo()&&t+Xr!==47+10;)if(t+Xr===42+42&&zu()===47)break;return"/*"+nx(e,Hs-1)+"*"+xM(t===47?t:Fo())}function lne(t){for(;!_9(zu());)Fo();return nx(t,Hs)}function hne(t){return ane(Rv("",null,null,null,[""],t=one(t),0,[0],t))}function Rv(t,e,r,n,s,i,o,f,h){for(var p=0,b=0,v=o,E=0,_=0,S=0,P=1,I=1,C=1,T=0,B="",N=s,$=i,H=n,J=B;I;)switch(S=T,T=Fo()){case 40:if(S!=108&&yn(J,v-1)==58){Tv(J+=Pt($3(T),"&","&\f"),"&\f")!=-1&&(C=-1);break}case 34:case 39:case 91:J+=$3(T);break;case 9:case 10:case 13:case 32:J+=fne(S);break;case 92:J+=cne(kv()-1,7);continue;case 47:switch(zu()){case 42:case 47:dm(dne(une(Fo(),kv()),e,r,h),h);break;default:J+="/"}break;case 123*P:f[p++]=va(J)*C;case 125*P:case 59:case 0:switch(T){case 0:case 125:I=0;case 59+b:C==-1&&(J=Pt(J,/\f/g,"")),_>0&&va(J)-v&&dm(_>32?vI(J+";",n,r,v-1,h):vI(Pt(J," ","")+";",n,r,v-2,h),h);break;case 59:J+=";";default:if(dm(H=bI(J,e,r,p,b,s,f,B,N=[],$=[],v,i),i),T===123)if(b===0)Rv(J,e,H,H,N,i,v,f,$);else switch(E===99&&yn(J,3)===110?100:E){case 100:case 108:case 109:case 115:Rv(t,H,H,n&&dm(bI(t,H,H,0,0,s,f,B,s,N=[],v,$),$),s,$,v,f,n?N:$);break;default:Rv(J,H,H,H,[""],$,0,f,$)}}p=b=_=0,P=C=1,B=J="",v=o;break;case 58:v=1+va(J),_=S;default:if(P<1){if(T==123)--P;else if(T==125&&P++==0&&sne()==125)continue}switch(J+=xM(T),T*P){case 38:C=b>0?1:(J+="\f",-1);break;case 44:f[p++]=(va(J)-1)*C,C=1;break;case 64:zu()===45&&(J+=$3(Fo())),E=zu(),b=v=va(B=J+=lne(kv())),T++;break;case 45:S===45&&va(J)==2&&(P=0)}}return i}function bI(t,e,r,n,s,i,o,f,h,p,b,v){for(var E=s-1,_=s===0?i:[""],S=r$(_),P=0,I=0,C=0;P0?_[T]+" "+B:Pt(B,/&\f/g,_[T])))&&(h[C++]=N);return rx(t,e,r,s===0?ex:f,h,p,b,v)}function dne(t,e,r,n){return rx(t,e,r,XD,xM(ine()),cp(t,2,-2),0,n)}function vI(t,e,r,n,s){return rx(t,e,r,vM,cp(t,0,n),cp(t,n+1,-1),n,s)}function i$(t,e,r){switch(rne(t,e)){case 5103:return Qt+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Qt+t+t;case 4789:return Om+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return Qt+t+Om+t+vr+t+t;case 5936:switch(yn(t,e+11)){case 114:return Qt+t+vr+Pt(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return Qt+t+vr+Pt(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return Qt+t+vr+Pt(t,/[svh]\w+-[tblr]{2}/,"lr")+t}case 6828:case 4268:case 2903:return Qt+t+vr+t+t;case 6165:return Qt+t+vr+"flex-"+t+t;case 5187:return Qt+t+Pt(t,/(\w+).+(:[^]+)/,Qt+"box-$1$2"+vr+"flex-$1$2")+t;case 5443:return Qt+t+vr+"flex-item-"+Pt(t,/flex-|-self/g,"")+(Qa(t,/flex-|baseline/)?"":vr+"grid-row-"+Pt(t,/flex-|-self/g,""))+t;case 4675:return Qt+t+vr+"flex-line-pack"+Pt(t,/align-content|flex-|-self/g,"")+t;case 5548:return Qt+t+vr+Pt(t,"shrink","negative")+t;case 5292:return Qt+t+vr+Pt(t,"basis","preferred-size")+t;case 6060:return Qt+"box-"+Pt(t,"-grow","")+Qt+t+vr+Pt(t,"grow","positive")+t;case 4554:return Qt+Pt(t,/([^-])(transform)/g,"$1"+Qt+"$2")+t;case 6187:return Pt(Pt(Pt(t,/(zoom-|grab)/,Qt+"$1"),/(image-set)/,Qt+"$1"),t,"")+t;case 5495:case 3959:return Pt(t,/(image-set\([^]*)/,Qt+"$1$`$1");case 4968:return Pt(Pt(t,/(.+:)(flex-)?(.*)/,Qt+"box-pack:$3"+vr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Qt+t+t;case 4200:if(!Qa(t,/flex-|baseline/))return vr+"grid-column-align"+cp(t,e)+t;break;case 2592:case 3360:return vr+Pt(t,"template-","")+t;case 4384:case 3616:return r&&r.some(function(n,s){return e=s,Qa(n.props,/grid-\w+-end/)})?~Tv(t+(r=r[e].value),"span")?t:vr+Pt(t,"-start","")+t+vr+"grid-row-span:"+(~Tv(r,"span")?Qa(r,/\d+/):+Qa(r,/\d+/)-+Qa(t,/\d+/))+";":vr+Pt(t,"-start","")+t;case 4896:case 4128:return r&&r.some(function(n){return Qa(n.props,/grid-\w+-start/)})?t:vr+Pt(Pt(t,"-end","-span"),"span ","")+t;case 4095:case 3583:case 4068:case 2532:return Pt(t,/(.+)-inline(.+)/,Qt+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(va(t)-1-e>6)switch(yn(t,e+1)){case 109:if(yn(t,e+4)!==45)break;case 102:return Pt(t,/(.+:)(.+)-([^]+)/,"$1"+Qt+"$2-$3$1"+Om+(yn(t,e+3)==108?"$3":"$2-$3"))+t;case 115:return~Tv(t,"stretch")?i$(Pt(t,"stretch","fill-available"),e,r)+t:t}break;case 5152:case 5920:return Pt(t,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,s,i,o,f,h,p){return vr+s+":"+i+p+(o?vr+s+"-span:"+(f?h:+h-+i)+p:"")+t});case 4949:if(yn(t,e+6)===121)return Pt(t,":",":"+Qt)+t;break;case 6444:switch(yn(t,yn(t,14)===45?18:11)){case 120:return Pt(t,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+Qt+(yn(t,14)===45?"inline-":"")+"box$3$1"+Qt+"$2$3$1"+vr+"$2box$3")+t;case 100:return Pt(t,":",":"+vr)+t}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Pt(t,"scroll-","scroll-snap-")+t}return t}function V2(t,e){for(var r="",n=0;n-1&&!t.return)switch(t.type){case vM:t.return=i$(t.value,t.length,r);return;case e$:return V2([x0(t,{value:Pt(t.value,"@","@"+Qt)})],n);case ex:if(t.length)return nne(r=t.props,function(s){switch(Qa(s,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":Ql(x0(t,{props:[Pt(s,/:(read-\w+)/,":"+Om+"$1")]})),Ql(x0(t,{props:[s]})),S9(t,{props:yI(r,n)});break;case"::placeholder":Ql(x0(t,{props:[Pt(s,/:(plac\w+)/,":"+Qt+"input-$1")]})),Ql(x0(t,{props:[Pt(s,/:(plac\w+)/,":"+Om+"$1")]})),Ql(x0(t,{props:[Pt(s,/:(plac\w+)/,vr+"input-$1")]})),Ql(x0(t,{props:[s]})),S9(t,{props:yI(r,n)});break}return""})}}var bne={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},lp=typeof Ve.process<"u"&&Ve.process.env!==void 0&&({}.REACT_APP_SC_ATTR||{}.SC_ATTR)||"data-styled",wM=typeof window<"u"&&"HTMLElement"in window,vne=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof Ve.process<"u"&&Ve.process.env!==void 0&&{}.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&{}.REACT_APP_SC_DISABLE_SPEEDY!==""?{}.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&{}.REACT_APP_SC_DISABLE_SPEEDY:typeof Ve.process<"u"&&Ve.process.env!==void 0&&{}.SC_DISABLE_SPEEDY!==void 0&&{}.SC_DISABLE_SPEEDY!==""&&{}.SC_DISABLE_SPEEDY!=="false"&&{}.SC_DISABLE_SPEEDY),ix=Object.freeze([]),hp=Object.freeze({});function xne(t,e,r){return r===void 0&&(r=hp),t.theme!==r.theme&&t.theme||e||r.theme}var s$=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),wne=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,Ane=/(^-|-$)/g;function xI(t){return t.replace(wne,"-").replace(Ane,"")}var Ene=/(a)(d)/gi,wI=function(t){return String.fromCharCode(t+(t>25?39:97))};function C9(t){var e,r="";for(e=Math.abs(t);e>52;e=e/52|0)r=wI(e%52)+r;return(wI(e%52)+r).replace(Ene,"$1-$2")}var F3,Ph=function(t,e){for(var r=e.length;r;)t=33*t^e.charCodeAt(--r);return t},o$=function(t){return Ph(5381,t)};function Mne(t){return C9(o$(t)>>>0)}function Sne(t){return t.displayName||t.name||"Component"}function U3(t){return typeof t=="string"&&!0}var a$=typeof Symbol=="function"&&Symbol.for,f$=a$?Symbol.for("react.memo"):60115,_ne=a$?Symbol.for("react.forward_ref"):60112,Pne={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Cne={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},c$={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Ine=((F3={})[_ne]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},F3[f$]=c$,F3);function AI(t){return("type"in(e=t)&&e.type.$$typeof)===f$?c$:"$$typeof"in t?Ine[t.$$typeof]:Pne;var e}var Tne=Object.defineProperty,kne=Object.getOwnPropertyNames,EI=Object.getOwnPropertySymbols,Rne=Object.getOwnPropertyDescriptor,Bne=Object.getPrototypeOf,MI=Object.prototype;function u$(t,e,r){if(typeof e!="string"){if(MI){var n=Bne(e);n&&n!==MI&&u$(t,n,r)}var s=kne(e);EI&&(s=s.concat(EI(e)));for(var i=AI(t),o=AI(e),f=0;f0?" Args: ".concat(e.join(", ")):""))}var One=function(){function t(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}return t.prototype.indexOfGroup=function(e){for(var r=0,n=0;n=this.groupSizes.length){for(var n=this.groupSizes,s=n.length,i=s;e>=i;)if((i<<=1)<0)throw Ay(16,"".concat(e));this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var o=s;o=this.length||this.groupSizes[e]===0)return r;for(var n=this.groupSizes[e],s=this.indexOfGroup(e),i=s+n,o=s;o=0){var n=document.createTextNode(r);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,!0}return!1},t.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.prototype.getRule=function(e){return e0&&(I+="".concat(C,","))}),h+="".concat(S).concat(P,'{content:"').concat(I,'"}').concat(`/*!sc*/ -`)},b=0;b0?".".concat(e):E},b=h.slice();b.push(function(E){E.type===ex&&E.value.includes("&")&&(E.props[0]=E.props[0].replace(Gne,r).replace(n,p))}),o.prefix&&b.push(yne),b.push(pne);var v=function(E,_,S,P){_===void 0&&(_=""),S===void 0&&(S=""),P===void 0&&(P="&"),e=P,r=_,n=new RegExp("\\".concat(r,"\\b"),"g");var I=E.replace(Vne,""),C=hne(S||_?"".concat(S," ").concat(_," { ").concat(I," }"):I);o.namespace&&(C=d$(C,o.namespace));var T=[];return V2(C,mne(b.concat(gne(function(B){return T.push(B)})))),T};return v.hash=h.length?h.reduce(function(E,_){return _.name||Ay(15),Ph(E,_.name)},5381).toString():"",v}var Wne=new h$,T9=Kne(),p$=ue.createContext({shouldForwardProp:void 0,styleSheet:Wne,stylis:T9});p$.Consumer;ue.createContext(void 0);function PI(){return Z.useContext(p$)}var Jne=function(){function t(e,r){var n=this;this.inject=function(s,i){i===void 0&&(i=T9);var o=n.name+i.hash;s.hasNameForId(n.id,o)||s.insertRules(n.id,o,i(n.rules,o,"@keyframes"))},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=r,EM(this,function(){throw Ay(12,String(n.name))})}return t.prototype.getName=function(e){return e===void 0&&(e=T9),this.name+e.hash},t}(),Zne=function(t){return t>="A"&&t<="Z"};function CI(t){for(var e="",r=0;r>>0);if(!r.hasNameForId(this.componentId,o)){var f=n(i,".".concat(o),void 0,this.componentId);r.insertRules(this.componentId,o,f)}s=uu(s,o),this.staticRulesId=o}else{for(var h=Ph(this.baseHash,n.hash),p="",b=0;b>>0);r.hasNameForId(this.componentId,_)||r.insertRules(this.componentId,_,n(p,".".concat(_),void 0,this.componentId)),s=uu(s,_)}}return s},t}(),y$=ue.createContext(void 0);y$.Consumer;var z3={};function eie(t,e,r){var n=AM(t),s=t,i=!U3(t),o=e.attrs,f=o===void 0?ix:o,h=e.componentId,p=h===void 0?function(N,$){var H=typeof N!="string"?"sc":xI(N);z3[H]=(z3[H]||0)+1;var J="".concat(H,"-").concat(Mne("6.1.1"+H+z3[H]));return $?"".concat($,"-").concat(J):J}(e.displayName,e.parentComponentId):h,b=e.displayName,v=b===void 0?function(N){return U3(N)?"styled.".concat(N):"Styled(".concat(Sne(N),")")}(t):b,E=e.displayName&&e.componentId?"".concat(xI(e.displayName),"-").concat(e.componentId):e.componentId||p,_=n&&s.attrs?s.attrs.concat(f).filter(Boolean):f,S=e.shouldForwardProp;if(n&&s.shouldForwardProp){var P=s.shouldForwardProp;if(e.shouldForwardProp){var I=e.shouldForwardProp;S=function(N,$){return P(N,$)&&I(N,$)}}else S=P}var C=new Xne(r,E,n?s.componentStyle:void 0);function T(N,$){return function(H,J,Q){var K=H.attrs,se=H.componentStyle,w=H.defaultProps,a=H.foldedComponentIds,u=H.styledComponentId,l=H.target,d=ue.useContext(y$),m=PI(),x=H.shouldForwardProp||m.shouldForwardProp,A=function(L,k,D){for(var U,V=$r($r({},k),{className:void 0,theme:D}),G=0;G{const{children:e}=t;za();const{confirming:r,confirmed:n}=bM(s=>s);return ce.jsxs(rie,{children:[ce.jsx(q2,{position:{bottom:20,right:100},opened:r,withCloseButton:!0,size:"lg",radius:"md",style:{backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},children:ce.jsx(G2,{withBorder:!1,withCloseButton:!1,style:{margin:10,backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},loading:!0,title:"Confirming the transaction",children:"Waiting for the transaction to get confirmed"})}),ce.jsx(q2,{position:{bottom:20,right:100},opened:n,withCloseButton:!0,size:"lg",radius:"md",style:{backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},children:ce.jsx(G2,{withBorder:!1,withCloseButton:!1,style:{margin:10,backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},title:"Transaction confirmed!",children:"Transaction has been confirmed now"})}),e]})};/** - * @remix-run/router v1.13.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function dg(){return dg=Object.assign?Object.assign.bind():function(t){for(var e=1;e"u")throw new Error(e)}function sx(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function sie(){return Math.random().toString(36).substr(2,8)}function RI(t,e){return{usr:t.state,key:t.key,idx:e}}function R9(t,e,r,n){return r===void 0&&(r=null),dg({pathname:typeof t=="string"?t:t.pathname,search:"",hash:""},typeof e=="string"?Cl(e):e,{state:r,key:e&&e.key||n||sie()})}function x$(t){let{pathname:e="/",search:r="",hash:n=""}=t;return r&&r!=="?"&&(e+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Cl(t){let e={};if(t){let r=t.indexOf("#");r>=0&&(e.hash=t.substr(r),t=t.substr(0,r));let n=t.indexOf("?");n>=0&&(e.search=t.substr(n),t=t.substr(0,n)),t&&(e.pathname=t)}return e}function oie(t,e,r,n){n===void 0&&(n={});let{window:s=document.defaultView,v5Compat:i=!1}=n,o=s.history,f=J0.Pop,h=null,p=b();p==null&&(p=0,o.replaceState(dg({},o.state,{idx:p}),""));function b(){return(o.state||{idx:null}).idx}function v(){f=J0.Pop;let I=b(),C=I==null?null:I-p;p=I,h&&h({action:f,location:P.location,delta:C})}function E(I,C){f=J0.Push;let T=R9(P.location,I,C);r&&r(T,I),p=b()+1;let B=RI(T,p),N=P.createHref(T);try{o.pushState(B,"",N)}catch($){if($ instanceof DOMException&&$.name==="DataCloneError")throw $;s.location.assign(N)}i&&h&&h({action:f,location:P.location,delta:1})}function _(I,C){f=J0.Replace;let T=R9(P.location,I,C);r&&r(T,I),p=b();let B=RI(T,p),N=P.createHref(T);o.replaceState(B,"",N),i&&h&&h({action:f,location:P.location,delta:0})}function S(I){let C=s.location.origin!=="null"?s.location.origin:s.location.href,T=typeof I=="string"?I:x$(I);return fn(C,"No window.location.(origin|href) available to create URL for href: "+T),new URL(T,C)}let P={get action(){return f},get location(){return t(s,o)},listen(I){if(h)throw new Error("A history only accepts one active listener");return s.addEventListener(kI,v),h=I,()=>{s.removeEventListener(kI,v),h=null}},createHref(I){return e(s,I)},createURL:S,encodeLocation(I){let C=S(I);return{pathname:C.pathname,search:C.search,hash:C.hash}},push:E,replace:_,go(I){return o.go(I)}};return P}var BI;(function(t){t.data="data",t.deferred="deferred",t.redirect="redirect",t.error="error"})(BI||(BI={}));function aie(t,e,r){r===void 0&&(r="/");let n=typeof e=="string"?Cl(e):e,s=E$(n.pathname||"/",r);if(s==null)return null;let i=w$(t);fie(i);let o=null;for(let f=0;o==null&&f{let h={relativePath:f===void 0?i.path||"":f,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};h.relativePath.startsWith("/")&&(fn(h.relativePath.startsWith(n),'Absolute route path "'+h.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),h.relativePath=h.relativePath.slice(n.length));let p=Hu([n,h.relativePath]),b=r.concat(h);i.children&&i.children.length>0&&(fn(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+p+'".')),w$(i.children,e,b,p)),!(i.path==null&&!i.index)&&e.push({path:p,score:mie(p,i.index),routesMeta:b})};return t.forEach((i,o)=>{var f;if(i.path===""||!((f=i.path)!=null&&f.includes("?")))s(i,o);else for(let h of A$(i.path))s(i,o,h)}),e}function A$(t){let e=t.split("/");if(e.length===0)return[];let[r,...n]=e,s=r.endsWith("?"),i=r.replace(/\?$/,"");if(n.length===0)return s?[i,""]:[i];let o=A$(n.join("/")),f=[];return f.push(...o.map(h=>h===""?i:[i,h].join("/"))),s&&f.push(...o),f.map(h=>t.startsWith("/")&&h===""?"/":h)}function fie(t){t.sort((e,r)=>e.score!==r.score?r.score-e.score:gie(e.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const cie=/^:\w+$/,uie=3,lie=2,hie=1,die=10,pie=-2,OI=t=>t==="*";function mie(t,e){let r=t.split("/"),n=r.length;return r.some(OI)&&(n+=pie),e&&(n+=lie),r.filter(s=>!OI(s)).reduce((s,i)=>s+(cie.test(i)?uie:i===""?hie:die),n)}function gie(t,e){return t.length===e.length&&t.slice(0,-1).every((n,s)=>n===e[s])?t[t.length-1]-e[e.length-1]:0}function yie(t,e){let{routesMeta:r}=t,n={},s="/",i=[];for(let o=0;o{let{paramName:E,isOptional:_}=b;if(E==="*"){let P=f[v]||"";o=i.slice(0,i.length-P.length).replace(/(.)\/+$/,"$1")}const S=f[v];return _&&!S?p[E]=void 0:p[E]=wie(S||"",E),p},{}),pathname:i,pathnameBase:o,pattern:t}}function vie(t,e,r){e===void 0&&(e=!1),r===void 0&&(r=!0),sx(t==="*"||!t.endsWith("*")||t.endsWith("/*"),'Route path "'+t+'" will be treated as if it were '+('"'+t.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+t.replace(/\*$/,"/*")+'".'));let n=[],s="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:(\w+)(\?)?/g,(o,f,h)=>(n.push({paramName:f,isOptional:h!=null}),h?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(n.push({paramName:"*"}),s+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?s+="\\/*$":t!==""&&t!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,e?void 0:"i"),n]}function xie(t){try{return decodeURI(t)}catch(e){return sx(!1,'The URL path "'+t+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+e+").")),t}}function wie(t,e){try{return decodeURIComponent(t)}catch(r){return sx(!1,'The value for the URL param "'+e+'" will not be decoded because'+(' the string "'+t+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+r+").")),t}}function E$(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let r=e.endsWith("/")?e.length-1:e.length,n=t.charAt(r);return n&&n!=="/"?null:t.slice(r)||"/"}function Aie(t,e){e===void 0&&(e="/");let{pathname:r,search:n="",hash:s=""}=typeof t=="string"?Cl(t):t;return{pathname:r?r.startsWith("/")?r:Eie(r,e):e,search:Pie(n),hash:Cie(s)}}function Eie(t,e){let r=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(s=>{s===".."?r.length>1&&r.pop():s!=="."&&r.push(s)}),r.length>1?r.join("/"):"/"}function j3(t,e,r,n){return"Cannot include a '"+t+"' character in a manually specified "+("`to."+e+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function Mie(t){return t.filter((e,r)=>r===0||e.route.path&&e.route.path.length>0)}function Sie(t,e,r,n){n===void 0&&(n=!1);let s;typeof t=="string"?s=Cl(t):(s=dg({},t),fn(!s.pathname||!s.pathname.includes("?"),j3("?","pathname","search",s)),fn(!s.pathname||!s.pathname.includes("#"),j3("#","pathname","hash",s)),fn(!s.search||!s.search.includes("#"),j3("#","search","hash",s)));let i=t===""||s.pathname==="",o=i?"/":s.pathname,f;if(o==null)f=r;else if(n){let v=e[e.length-1].replace(/^\//,"").split("/");if(o.startsWith("..")){let E=o.split("/");for(;E[0]==="..";)E.shift(),v.pop();s.pathname=E.join("/")}f="/"+v.join("/")}else{let v=e.length-1;if(o.startsWith("..")){let E=o.split("/");for(;E[0]==="..";)E.shift(),v-=1;s.pathname=E.join("/")}f=v>=0?e[v]:"/"}let h=Aie(s,f),p=o&&o!=="/"&&o.endsWith("/"),b=(i||o===".")&&r.endsWith("/");return!h.pathname.endsWith("/")&&(p||b)&&(h.pathname+="/"),h}const Hu=t=>t.join("/").replace(/\/\/+/g,"/"),_ie=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),Pie=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,Cie=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t;function Iie(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}const M$=["post","put","patch","delete"];new Set(M$);const Tie=["get",...M$];new Set(Tie);/** - * React Router v6.20.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function W2(){return W2=Object.assign?Object.assign.bind():function(t){for(var e=1;eh.pathnameBase)),o=Z.useRef(!1);return P$(()=>{o.current=!0}),Z.useCallback(function(h,p){if(p===void 0&&(p={}),!o.current)return;if(typeof h=="number"){r.go(h);return}let b=Sie(h,JSON.parse(i),s,p.relative==="path");t==null&&e!=="/"&&(b.pathname=b.pathname==="/"?e:Hu([e,b.pathname])),(p.replace?r.replace:r.push)(b,p.state,p)},[e,r,i,s,t])}function Bie(t,e){return Oie(t,e)}function Oie(t,e,r){fx()||fn(!1);let{navigator:n}=Z.useContext(ox),{matches:s}=Z.useContext(a1),i=s[s.length-1],o=i?i.params:{};i&&i.pathname;let f=i?i.pathnameBase:"/";i&&i.route;let h=_$(),p;if(e){var b;let P=typeof e=="string"?Cl(e):e;f==="/"||(b=P.pathname)!=null&&b.startsWith(f)||fn(!1),p=P}else p=h;let v=p.pathname||"/",E=f==="/"?v:v.slice(f.length)||"/",_=aie(t,{pathname:E}),S=Fie(_&&_.map(P=>Object.assign({},P,{params:Object.assign({},o,P.params),pathname:Hu([f,n.encodeLocation?n.encodeLocation(P.pathname).pathname:P.pathname]),pathnameBase:P.pathnameBase==="/"?f:Hu([f,n.encodeLocation?n.encodeLocation(P.pathnameBase).pathname:P.pathnameBase])})),s,r);return e&&S?Z.createElement(ax.Provider,{value:{location:W2({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:J0.Pop}},S):S}function Nie(){let t=Hie(),e=Iie(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},i=null;return Z.createElement(Z.Fragment,null,Z.createElement("h2",null,"Unexpected Application Error!"),Z.createElement("h3",{style:{fontStyle:"italic"}},e),r?Z.createElement("pre",{style:s},r):null,i)}const Lie=Z.createElement(Nie,null);class Die extends Z.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,r){return r.location!==e.location||r.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error||r.error,location:r.location,revalidation:e.revalidation||r.revalidation}}componentDidCatch(e,r){console.error("React Router caught the following error during render",e,r)}render(){return this.state.error?Z.createElement(a1.Provider,{value:this.props.routeContext},Z.createElement(S$.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function $ie(t){let{routeContext:e,match:r,children:n}=t,s=Z.useContext(MM);return s&&s.static&&s.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=r.route.id),Z.createElement(a1.Provider,{value:e},n)}function Fie(t,e,r){var n;if(e===void 0&&(e=[]),r===void 0&&(r=null),t==null){var s;if((s=r)!=null&&s.errors)t=r.matches;else return null}let i=t,o=(n=r)==null?void 0:n.errors;if(o!=null){let f=i.findIndex(h=>h.route.id&&(o==null?void 0:o[h.route.id]));f>=0||fn(!1),i=i.slice(0,Math.min(i.length,f+1))}return i.reduceRight((f,h,p)=>{let b=h.route.id?o==null?void 0:o[h.route.id]:null,v=null;r&&(v=h.route.errorElement||Lie);let E=e.concat(i.slice(0,p+1)),_=()=>{let S;return b?S=v:h.route.Component?S=Z.createElement(h.route.Component,null):h.route.element?S=h.route.element:S=f,Z.createElement($ie,{match:h,routeContext:{outlet:f,matches:E,isDataRoute:r!=null},children:S})};return r&&(h.route.ErrorBoundary||h.route.errorElement||p===0)?Z.createElement(Die,{location:r.location,revalidation:r.revalidation,component:v,error:b,children:_(),routeContext:{outlet:null,matches:E,isDataRoute:!0}}):_()},null)}var I$=function(t){return t.UseBlocker="useBlocker",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t}(I$||{}),J2=function(t){return t.UseBlocker="useBlocker",t.UseLoaderData="useLoaderData",t.UseActionData="useActionData",t.UseRouteError="useRouteError",t.UseNavigation="useNavigation",t.UseRouteLoaderData="useRouteLoaderData",t.UseMatches="useMatches",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t.UseRouteId="useRouteId",t}(J2||{});function Uie(t){let e=Z.useContext(MM);return e||fn(!1),e}function zie(t){let e=Z.useContext(kie);return e||fn(!1),e}function jie(t){let e=Z.useContext(a1);return e||fn(!1),e}function T$(t){let e=jie(),r=e.matches[e.matches.length-1];return r.route.id||fn(!1),r.route.id}function Hie(){var t;let e=Z.useContext(S$),r=zie(J2.UseRouteError),n=T$(J2.UseRouteError);return e||((t=r.errors)==null?void 0:t[n])}function qie(){let{router:t}=Uie(I$.UseNavigateStable),e=T$(J2.UseNavigateStable),r=Z.useRef(!1);return P$(()=>{r.current=!0}),Z.useCallback(function(s,i){i===void 0&&(i={}),r.current&&(typeof s=="number"?t.navigate(s):t.navigate(s,W2({fromRouteId:e},i)))},[t,e])}function Nv(t){fn(!1)}function Gie(t){let{basename:e="/",children:r=null,location:n,navigationType:s=J0.Pop,navigator:i,static:o=!1}=t;fx()&&fn(!1);let f=e.replace(/^\/*/,"/"),h=Z.useMemo(()=>({basename:f,navigator:i,static:o}),[f,i,o]);typeof n=="string"&&(n=Cl(n));let{pathname:p="/",search:b="",hash:v="",state:E=null,key:_="default"}=n,S=Z.useMemo(()=>{let P=E$(p,f);return P==null?null:{location:{pathname:P,search:b,hash:v,state:E,key:_},navigationType:s}},[f,p,b,v,E,_,s]);return S==null?null:Z.createElement(ox.Provider,{value:h},Z.createElement(ax.Provider,{children:r,value:S}))}function Vie(t){let{children:e,location:r}=t;return Bie(B9(e),r)}new Promise(()=>{});function B9(t,e){e===void 0&&(e=[]);let r=[];return Z.Children.forEach(t,(n,s)=>{if(!Z.isValidElement(n))return;let i=[...e,s];if(n.type===Z.Fragment){r.push.apply(r,B9(n.props.children,i));return}n.type!==Nv&&fn(!1),!n.props.index||!n.props.children||fn(!1);let o={id:n.props.id||i.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,loader:n.props.loader,action:n.props.action,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(o.children=B9(n.props.children,i)),r.push(o)}),r}/** - * React Router DOM v6.20.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */const Kie="startTransition",NI=_A[Kie];function Wie(t){let{basename:e,children:r,future:n,window:s}=t,i=Z.useRef();i.current==null&&(i.current=iie({window:s,v5Compat:!0}));let o=i.current,[f,h]=Z.useState({action:o.action,location:o.location}),{v7_startTransition:p}=n||{},b=Z.useCallback(v=>{p&&NI?NI(()=>h(v)):h(v)},[h,p]);return Z.useLayoutEffect(()=>o.listen(b),[o,b]),Z.createElement(Gie,{basename:e,children:r,location:f.location,navigationType:f.action,navigator:o})}var LI;(function(t){t.UseScrollRestoration="useScrollRestoration",t.UseSubmit="useSubmit",t.UseSubmitFetcher="useSubmitFetcher",t.UseFetcher="useFetcher",t.useViewTransitionState="useViewTransitionState"})(LI||(LI={}));var DI;(function(t){t.UseFetcher="useFetcher",t.UseFetchers="useFetchers",t.UseScrollRestoration="useScrollRestoration"})(DI||(DI={}));function qs(){return qs=Object.assign?Object.assign.bind():function(t){for(var e=1;e=0||(b[h]=o[h]);return b}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(s[r]=t[r])}return s}var Jie=["size","color","stroke"];function Zie(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,Jie);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-brand-github",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("path",{d:"M9 19c-4.3 1.4 -4.3 -2.5 -6 -3m12 5v-3.5c0 -1 .1 -1.4 -.5 -2c2.8 -.3 5.5 -1.4 5.5 -6a4.6 4.6 0 0 0 -1.3 -3.2a4.2 4.2 0 0 0 -.1 -3.2s-1.1 -.3 -3.5 1.3a12.3 12.3 0 0 0 -6.2 0c-2.4 -1.6 -3.5 -1.3 -3.5 -1.3a4.2 4.2 0 0 0 -.1 3.2a4.6 4.6 0 0 0 -1.3 3.2c0 4.6 2.7 5.7 5.5 6c-.6 .6 -.6 1.2 -.5 2v3.5"}))}var Qie=["size","color","stroke"];function Yie(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,Qie);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-check",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("path",{d:"M5 12l5 5l10 -10"}))}var Xie=["size","color","stroke"];function ese(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,Xie);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-chevron-down",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("polyline",{points:"6 9 12 15 18 9"}))}var tse=["size","color","stroke"];function O9(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,tse);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-coin",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("circle",{cx:12,cy:12,r:9}),Z.createElement("path",{d:"M14.8 9a2 2 0 0 0 -1.8 -1h-2a2 2 0 1 0 0 4h2a2 2 0 1 1 0 4h-2a2 2 0 0 1 -1.8 -1"}),Z.createElement("path",{d:"M12 7v10"}))}var rse=["size","color","stroke"];function nse(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,rse);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-confetti",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("path",{d:"M4 5h2"}),Z.createElement("path",{d:"M5 4v2"}),Z.createElement("path",{d:"M11.5 4l-.5 2"}),Z.createElement("path",{d:"M18 5h2"}),Z.createElement("path",{d:"M19 4v2"}),Z.createElement("path",{d:"M15 9l-1 1"}),Z.createElement("path",{d:"M18 13l2 -.5"}),Z.createElement("path",{d:"M18 19h2"}),Z.createElement("path",{d:"M19 18v2"}),Z.createElement("path",{d:"M14 16.518l-6.518 -6.518l-4.39 9.58a1.003 1.003 0 0 0 1.329 1.329l9.579 -4.39z"}))}var ise=["size","color","stroke"];function sse(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,ise);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-copy",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("rect",{x:8,y:8,width:12,height:12,rx:2}),Z.createElement("path",{d:"M16 8v-2a2 2 0 0 0 -2 -2h-8a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h2"}))}var ose=["size","color","stroke"];function ase(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,ose);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-gift",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("rect",{x:3,y:8,width:18,height:4,rx:1}),Z.createElement("line",{x1:12,y1:8,x2:12,y2:21}),Z.createElement("path",{d:"M19 12v7a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-7"}),Z.createElement("path",{d:"M7.5 8a2.5 2.5 0 0 1 0 -5a4.8 8 0 0 1 4.5 5a4.8 8 0 0 1 4.5 -5a2.5 2.5 0 0 1 0 5"}))}var fse=["size","color","stroke"];function cse(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,fse);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-moon-stars",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("path",{d:"M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454z"}),Z.createElement("path",{d:"M17 4a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"}),Z.createElement("path",{d:"M19 11h2m-1 -1v2"}))}var use=["size","color","stroke"];function lse(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,use);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-sun",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("circle",{cx:12,cy:12,r:4}),Z.createElement("path",{d:"M3 12h1m8 -9v1m8 8h1m-9 8v1m-6.4 -15.4l.7 .7m12.1 -.7l-.7 .7m0 11.4l.7 .7m-12.1 -.7l-.7 .7"}))}var hse=["size","color","stroke"];function dse(t){var e=t.size,r=e===void 0?24:e,n=t.color,s=n===void 0?"currentColor":n,i=t.stroke,o=i===void 0?2:i,f=ja(t,hse);return Z.createElement("svg",qs({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-wallet",width:r,height:r,viewBox:"0 0 24 24",strokeWidth:o,stroke:s,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},f),Z.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),Z.createElement("path",{d:"M17 8v-3a1 1 0 0 0 -1 -1h-10a2 2 0 0 0 0 4h12a1 1 0 0 1 1 1v3m0 4v3a1 1 0 0 1 -1 1h-12a2 2 0 0 1 -2 -2v-12"}),Z.createElement("path",{d:"M20 12v4h-4a2 2 0 0 1 0 -4h4"}))}const pse="/assets/logo-light-a2d4109f.svg",mse="/assets/logo-dark-9ba4d21d.svg",gse="/assets/base-8a61917f.png",pm="/assets/eth-dc2fb7da.svg";var fc=(t=>(t.home="/",t.claim="/claim",t.account="/account",t.notFound="*",t))(fc||{});const H3="05d830413c5a4ac8873c84319679c7b2",Wc="H8IGZCCS8XCJYSXIA3GUUKW6CDECYYMNPG",yse="GVZS4QAMWFBGS5PK2BR76FNFPJ7X2GR44I",bse="",$I={localhost:{name:"Local Chain",chainId:31337,type:"Testnet",url:"http://localhost:8545",safeService:"",blockExplorer:"",api:"",easExplorer:""},mainnet:{name:"Ethereum",type:"mainnet",chainId:1,url:`https://mainnet.infura.io/v3/${H3}`,safeService:"https://safe-transaction-mainnet.safe.global",blockExplorer:"https://etherscan.io",api:`https://api.etherscan.io/api?apikey=${Wc}`,easExplorer:""},goerli:{name:"Goerli",type:"testnet",chainId:5,url:`https://goerli.infura.io/v3/${H3}`,safeService:"https://safe-transaction-goerli.safe.global",blockExplorer:"https://goerli.etherscan.io",api:`https://api-goerli.etherscan.io/api?apikey=${Wc}`,easExplorer:""},sepolia:{name:"Sepolia",type:"testnet",chainId:11155111,url:"https://eth-sepolia.g.alchemy.com/v2/eCr9bFDzgYgDrox-mnXPPh7_koP-agKo",safeService:"https://safe-transaction-sepolia.safe.global",blockExplorer:"https://sepolia.etherscan.io",api:`https://api-sepolia.etherscan.io/api?apikey=${Wc}`,easExplorer:""},basegoerli:{name:"Base Goerli",type:"testnet",chainId:84531,url:"https://base-goerli.g.alchemy.com/v2/K1GZzIiF6-PthdjPtfzvTOMcej2zOWWA",blockExplorer:"https://goerli.basescan.org",safeService:"https://safe-transaction-base-testnet.safe.global",api:`https://api-goerli.etherscan.io/api?apikey=${Wc}`,easExplorer:"https://base-goerli.easscan.org/attestation/view/"},base:{name:"Base",type:"mainnet",chainId:8453,url:"https://base-mainnet.g.alchemy.com/v2/NTGkSXMuKkoHwQ_W4eNpGlihUScplXYV",blockExplorer:"https://basescan.org",safeService:"https://safe-transaction-base.safe.global",api:`https://api-goerli.etherscan.io/api?apikey=${Wc}`,easExplorer:""},optimism:{name:"Optimism",type:"mainnet",chainId:10,url:`https://optimism-mainnet.infura.io/v3/${H3}`,blockExplorer:"https://optimistic.etherscan.io",safeService:"https://safe-transaction-optimism.safe.global",api:`https://api-optimistic.etherscan.io/api?apikey=${Wc}`,easExplorer:"https://optimism.easscan.org/attestation/view/"},gnosis:{name:"Gnosis",type:"mainnet",chainId:100,url:"https://rpc.ankr.com/gnosis",safeService:"https://safe-transaction-gnosis-chain.safe.global",blockExplorer:"https://gnosisscan.io",api:`https://api-goerli.etherscan.io/api?apikey=${Wc}`,easExplorer:""},polygontestnet:{name:"Polygon",type:"testnet",chainId:80001,url:"https://matic-mumbai.chainstacklabs.com",safeService:"",blockExplorer:"https://mumbai.polygonscan.com",api:`https://api-testnet.polygonscan.com/api?module=account&action=balance&address=${bse}&apikey=${yse}`,easExplorer:""},polygon:{name:"Polygon",type:"mainnet",chainId:137,url:"https://rpc.ankr.com/polygon",safeService:"https://safe-transaction-polygon.safe.global",blockExplorer:"https://polygonscan.com",api:"",easExplorer:""},celo:{name:"Celo",type:"mainnet",chainId:42220,url:"https://1rpc.io/celo ",safeService:"https://safe-transaction-polygon.safe.global",blockExplorer:"https://celoscan.com",api:"",easExplorer:""}};class Yr{static getNetworkById(e){return Object.values($I).find(n=>e===n.chainId)}static getNetworkByName(e){return $I[e]}}const vse="6.7.1";function xse(t,e,r){const n=e.split("|").map(i=>i.trim());for(let i=0;iPromise.resolve(t[n])))).reduce((n,s,i)=>(n[e[i]]=s,n),{})}function lt(t,e,r){for(let n in e){let s=e[n];const i=r?r[n]:null;i&&xse(s,i,n),Object.defineProperty(t,n,{enumerable:!0,value:s,writable:!1})}}function Ch(t){if(t==null)return"null";if(Array.isArray(t))return"[ "+t.map(Ch).join(", ")+" ]";if(t instanceof Uint8Array){const e="0123456789abcdef";let r="0x";for(let n=0;n>4],r+=e[t[n]&15];return r}if(typeof t=="object"&&typeof t.toJSON=="function")return Ch(t.toJSON());switch(typeof t){case"boolean":case"symbol":return t.toString();case"bigint":return BigInt(t).toString();case"number":return t.toString();case"string":return JSON.stringify(t);case"object":{const e=Object.keys(t);return e.sort(),"{ "+e.map(r=>`${Ch(r)}: ${Ch(t[r])}`).join(", ")+" }"}}return"[ COULD NOT SERIALIZE ]"}function Ns(t,e){return t&&t.code===e}function SM(t){return Ns(t,"CALL_EXCEPTION")}function nn(t,e,r){{const s=[];if(r){if("message"in r||"code"in r||"name"in r)throw new Error(`value will overwrite populated values: ${Ch(r)}`);for(const i in r){const o=r[i];s.push(i+"="+Ch(o))}}s.push(`code=${e}`),s.push(`version=${vse}`),s.length&&(t+=" ("+s.join(", ")+")")}let n;switch(e){case"INVALID_ARGUMENT":n=new TypeError(t);break;case"NUMERIC_FAULT":case"BUFFER_OVERRUN":n=new RangeError(t);break;default:n=new Error(t)}return lt(n,{code:e}),r&&Object.assign(n,r),n}function He(t,e,r,n){if(!t)throw nn(e,r,n)}function me(t,e,r,n){He(t,e,"INVALID_ARGUMENT",{argument:r,value:n})}function k$(t,e,r){r==null&&(r=""),r&&(r=": "+r),He(t>=e,"missing arguemnt"+r,"MISSING_ARGUMENT",{count:t,expectedCount:e}),He(t<=e,"too many arguemnts"+r,"UNEXPECTED_ARGUMENT",{count:t,expectedCount:e})}const wse=["NFD","NFC","NFKD","NFKC"].reduce((t,e)=>{try{if("test".normalize(e)!=="test")throw new Error("bad");if(e==="NFD"){const r=String.fromCharCode(233).normalize("NFD"),n=String.fromCharCode(101,769);if(r!==n)throw new Error("broken")}t.push(e)}catch{}return t},[]);function Ase(t){He(wse.indexOf(t)>=0,"platform missing String.prototype.normalize","UNSUPPORTED_OPERATION",{operation:"String.prototype.normalize",info:{form:t}})}function Ey(t,e,r){if(r==null&&(r=""),t!==e){let n=r,s="new";r&&(n+=".",s+=" "+r),He(!1,`private constructor; use ${n}from* methods`,"UNSUPPORTED_OPERATION",{operation:s})}}function R$(t,e,r){if(t instanceof Uint8Array)return r?new Uint8Array(t):t;if(typeof t=="string"&&t.match(/^0x([0-9a-f][0-9a-f])*$/i)){const n=new Uint8Array((t.length-2)/2);let s=2;for(let i=0;i>4]+FI[s&15]}return r}function tn(t){return"0x"+t.map(e=>nt(e).substring(2)).join("")}function Kh(t){return Rr(t,!0)?(t.length-2)/2:$t(t).length}function Nr(t,e,r){const n=$t(t);return r!=null&&r>n.length&&He(!1,"cannot slice beyond data bounds","BUFFER_OVERRUN",{buffer:n,length:n.length,offset:r}),nt(n.slice(e??0,r??n.length))}function B$(t,e,r){const n=$t(t);He(e>=n.length,"padding exceeds data length","BUFFER_OVERRUN",{buffer:new Uint8Array(n),length:e,offset:e+1});const s=new Uint8Array(e);return s.fill(0),r?s.set(n,e-n.length):s.set(n,0),nt(s)}function sl(t,e){return B$(t,e,!0)}function Mse(t,e){return B$(t,e,!1)}const cx=BigInt(0),Io=BigInt(1),Ih=9007199254740991;function Z2(t,e){const r=ux(t,"value"),n=BigInt(Ct(e,"width"));if(He(r>>n===cx,"overflow","NUMERIC_FAULT",{operation:"fromTwos",fault:"overflow",value:t}),r>>n-Io){const s=(Io<=-Ih&&t<=Ih,"overflow",e||"value",t),BigInt(t);case"string":try{if(t==="")throw new Error("empty string");return t[0]==="-"&&t[1]!=="-"?-BigInt(t.substring(1)):BigInt(t)}catch(r){me(!1,`invalid BigNumberish string: ${r.message}`,e||"value",t)}}me(!1,"invalid BigNumberish value",e||"value",t)}function ux(t,e){const r=ft(t,e);return He(r>=cx,"unsigned value cannot be negative","NUMERIC_FAULT",{fault:"overflow",operation:"getUint",value:t}),r}const UI="0123456789abcdef";function lx(t){if(t instanceof Uint8Array){let e="0x0";for(const r of t)e+=UI[r>>4],e+=UI[r&15];return BigInt(e)}return ft(t)}function Ct(t,e){switch(typeof t){case"bigint":return me(t>=-Ih&&t<=Ih,"overflow",e||"value",t),Number(t);case"number":return me(Number.isInteger(t),"underflow",e||"value",t),me(t>=-Ih&&t<=Ih,"overflow",e||"value",t),t;case"string":try{if(t==="")throw new Error("empty string");return Ct(BigInt(t),e)}catch(r){me(!1,`invalid numeric string: ${r.message}`,e||"value",t)}}me(!1,"invalid numeric value",e||"value",t)}function Sse(t){return Ct(lx(t))}function vc(t,e){let n=ux(t,"value").toString(16);if(e==null)n.length%2&&(n="0"+n);else{const s=Ct(e,"width");for(He(s*2>=n.length,`value exceeds width (${s} bits)`,"NUMERIC_FAULT",{operation:"toBeHex",fault:"overflow",value:t});n.length>6===2;o++)i++;return i}return t==="OVERRUN"?r.length-e-1:0}function kse(t,e,r,n,s){return t==="OVERLONG"?(me(typeof s=="number","invalid bad code point for replacement","badCodepoint",s),n.push(s),0):(n.push(65533),L$(t,e,r))}const Rse=Object.freeze({error:Tse,ignore:L$,replace:kse});function Bse(t,e){e==null&&(e=Rse.error);const r=$t(t,"bytes"),n=[];let s=0;for(;s>7)){n.push(i);continue}let o=null,f=null;if((i&224)===192)o=1,f=127;else if((i&240)===224)o=2,f=2047;else if((i&248)===240)o=3,f=65535;else{(i&192)===128?s+=e("UNEXPECTED_CONTINUE",s-1,r,n):s+=e("BAD_PREFIX",s-1,r,n);continue}if(s-1+o>=r.length){s+=e("OVERRUN",s-1,r,n);continue}let h=i&(1<<8-o-1)-1;for(let p=0;p1114111){s+=e("OUT_OF_RANGE",s-1-o,r,n,h);continue}if(h>=55296&&h<=57343){s+=e("UTF16_SURROGATE",s-1-o,r,n,h);continue}if(h<=f){s+=e("OVERLONG",s-1-o,r,n,h);continue}n.push(h)}}return n}function Rf(t,e){e!=null&&(Ase(e),t=t.normalize(e));let r=[];for(let n=0;n>6|192),r.push(s&63|128);else if((s&64512)==55296){n++;const i=t.charCodeAt(n);me(n>18|240),r.push(o>>12&63|128),r.push(o>>6&63|128),r.push(o&63|128)}else r.push(s>>12|224),r.push(s>>6&63|128),r.push(s&63|128)}return new Uint8Array(r)}function Ose(t){return t.map(e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode((e>>10&1023)+55296,(e&1023)+56320))).join("")}function _M(t,e){return Ose(Bse(t,e))}async function Nse(t,e){const r=t.url.split(":")[0].toLowerCase();He(r==="http"||r==="https",`unsupported protocol ${r}`,"UNSUPPORTED_OPERATION",{info:{protocol:r},operation:"request"}),He(r==="https"||!t.credentials||t.allowInsecureAuthentication,"insecure authorized connections unsupported","UNSUPPORTED_OPERATION",{operation:"request"});let n;if(e){const p=new AbortController;n=p.signal,e.addListener(()=>{p.abort()})}const s={method:t.method,headers:new Headers(Array.from(t)),body:t.body||void 0,signal:n},i=await fetch(t.url,s),o={};i.headers.forEach((p,b)=>{o[b.toLowerCase()]=p});const f=await i.arrayBuffer(),h=f==null?null:new Uint8Array(f);return{statusCode:i.status,statusMessage:i.statusText,headers:o,body:h}}const Lse=12,Dse=250;let jI=Nse;const $se=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),Fse=new RegExp("^ipfs://(ipfs/)?(.*)$","i");let q3=!1;async function D$(t,e){try{const r=t.match($se);if(!r)throw new Error("invalid data");return new cc(200,"OK",{"content-type":r[1]||"text/plain"},r[2]?Cse(r[3]):zse(r[3]))}catch{return new cc(599,"BAD REQUEST (invalid data: URI)",{},null,new qf(t))}}function $$(t){async function e(r,n){try{const s=r.match(Fse);if(!s)throw new Error("invalid link");return new qf(`${t}${s[2]}`)}catch{return new cc(599,"BAD REQUEST (invalid IPFS URI)",{},null,new qf(r))}}return e}const Lb={data:D$,ipfs:$$("https://gateway.ipfs.io/ipfs/")},F$=new WeakMap;var bu,R0;class Use{constructor(e){Te(this,bu,void 0);Te(this,R0,void 0);fe(this,bu,[]),fe(this,R0,!1),F$.set(e,()=>{if(!X(this,R0)){fe(this,R0,!0);for(const r of X(this,bu))setTimeout(()=>{r()},0);fe(this,bu,[])}})}addListener(e){He(!X(this,R0),"singal already cancelled","UNSUPPORTED_OPERATION",{operation:"fetchCancelSignal.addCancelListener"}),X(this,bu).push(e)}get cancelled(){return X(this,R0)}checkSignal(){He(!this.cancelled,"cancelled","CANCELLED",{})}}bu=new WeakMap,R0=new WeakMap;function Db(t){if(t==null)throw new Error("missing signal; should not happen");return t.checkSignal(),t}var hd,dd,xo,sf,pd,md,pn,Gi,of,vu,xu,wu,ha,af,Au,mm;const i5=class i5{constructor(e){Te(this,Au);Te(this,hd,void 0);Te(this,dd,void 0);Te(this,xo,void 0);Te(this,sf,void 0);Te(this,pd,void 0);Te(this,md,void 0);Te(this,pn,void 0);Te(this,Gi,void 0);Te(this,of,void 0);Te(this,vu,void 0);Te(this,xu,void 0);Te(this,wu,void 0);Te(this,ha,void 0);Te(this,af,void 0);fe(this,md,String(e)),fe(this,hd,!1),fe(this,dd,!0),fe(this,xo,{}),fe(this,sf,""),fe(this,pd,3e5),fe(this,af,{slotInterval:Dse,maxAttempts:Lse})}get url(){return X(this,md)}set url(e){fe(this,md,String(e))}get body(){return X(this,pn)==null?null:new Uint8Array(X(this,pn))}set body(e){if(e==null)fe(this,pn,void 0),fe(this,Gi,void 0);else if(typeof e=="string")fe(this,pn,Rf(e)),fe(this,Gi,"text/plain");else if(e instanceof Uint8Array)fe(this,pn,e),fe(this,Gi,"application/octet-stream");else if(typeof e=="object")fe(this,pn,Rf(JSON.stringify(e))),fe(this,Gi,"application/json");else throw new Error("invalid body")}hasBody(){return X(this,pn)!=null}get method(){return X(this,sf)?X(this,sf):this.hasBody()?"POST":"GET"}set method(e){e==null&&(e=""),fe(this,sf,String(e).toUpperCase())}get headers(){const e=Object.assign({},X(this,xo));return X(this,of)&&(e.authorization=`Basic ${Ise(Rf(X(this,of)))}`),this.allowGzip&&(e["accept-encoding"]="gzip"),e["content-type"]==null&&X(this,Gi)&&(e["content-type"]=X(this,Gi)),this.body&&(e["content-length"]=String(this.body.length)),e}getHeader(e){return this.headers[e.toLowerCase()]}setHeader(e,r){X(this,xo)[String(e).toLowerCase()]=String(r)}clearHeaders(){fe(this,xo,{})}[Symbol.iterator](){const e=this.headers,r=Object.keys(e);let n=0;return{next:()=>{if(n=0,"timeout must be non-zero","timeout",e),fe(this,pd,e)}get preflightFunc(){return X(this,vu)||null}set preflightFunc(e){fe(this,vu,e)}get processFunc(){return X(this,xu)||null}set processFunc(e){fe(this,xu,e)}get retryFunc(){return X(this,wu)||null}set retryFunc(e){fe(this,wu,e)}toString(){return``}setThrottleParams(e){e.slotInterval!=null&&(X(this,af).slotInterval=e.slotInterval),e.maxAttempts!=null&&(X(this,af).maxAttempts=e.maxAttempts)}send(){return He(X(this,ha)==null,"request already sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.send"}),fe(this,ha,new Use(this)),Ge(this,Au,mm).call(this,0,HI()+this.timeout,0,this,new cc(0,"",{},null,this))}cancel(){He(X(this,ha)!=null,"request has not been sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.cancel"});const e=F$.get(this);if(!e)throw new Error("missing signal; should not happen");e()}redirect(e){const r=this.url.split(":")[0].toLowerCase(),n=e.split(":")[0].toLowerCase();He(this.method==="GET"&&(r!=="https"||n!=="http")&&e.match(/^https?:/),"unsupported redirect","UNSUPPORTED_OPERATION",{operation:`redirect(${this.method} ${JSON.stringify(this.url)} => ${JSON.stringify(e)})`});const s=new i5(e);return s.method="GET",s.allowGzip=this.allowGzip,s.timeout=this.timeout,fe(s,xo,Object.assign({},X(this,xo))),X(this,pn)&&fe(s,pn,new Uint8Array(X(this,pn))),fe(s,Gi,X(this,Gi)),s}clone(){const e=new i5(this.url);return fe(e,sf,X(this,sf)),X(this,pn)&&fe(e,pn,X(this,pn)),fe(e,Gi,X(this,Gi)),fe(e,xo,Object.assign({},X(this,xo))),fe(e,of,X(this,of)),this.allowGzip&&(e.allowGzip=!0),e.timeout=this.timeout,this.allowInsecureAuthentication&&(e.allowInsecureAuthentication=!0),fe(e,vu,X(this,vu)),fe(e,xu,X(this,xu)),fe(e,wu,X(this,wu)),e}static lockConfig(){q3=!0}static getGateway(e){return Lb[e.toLowerCase()]||null}static registerGateway(e,r){if(e=e.toLowerCase(),e==="http"||e==="https")throw new Error(`cannot intercept ${e}; use registerGetUrl`);if(q3)throw new Error("gateways locked");Lb[e]=r}static registerGetUrl(e){if(q3)throw new Error("gateways locked");jI=e}static createDataGateway(){return D$}static createIpfsGatewayFunc(e){return $$(e)}};hd=new WeakMap,dd=new WeakMap,xo=new WeakMap,sf=new WeakMap,pd=new WeakMap,md=new WeakMap,pn=new WeakMap,Gi=new WeakMap,of=new WeakMap,vu=new WeakMap,xu=new WeakMap,wu=new WeakMap,ha=new WeakMap,af=new WeakMap,Au=new WeakSet,mm=async function(e,r,n,s,i){var b,v,E;if(e>=X(this,af).maxAttempts)return i.makeServerError("exceeded maximum retry limit");He(HI()<=r,"timeout","TIMEOUT",{operation:"request.send",reason:"timeout",request:s}),n>0&&await jse(n);let o=this.clone();const f=(o.url.split(":")[0]||"").toLowerCase();if(f in Lb){const _=await Lb[f](o.url,Db(X(s,ha)));if(_ instanceof cc){let S=_;if(this.processFunc){Db(X(s,ha));try{S=await this.processFunc(o,S)}catch(P){(P.throttle==null||typeof P.stall!="number")&&S.makeServerError("error in post-processing function",P).assertOk()}}return S}o=_}this.preflightFunc&&(o=await this.preflightFunc(o));const h=await jI(o,Db(X(s,ha)));let p=new cc(h.statusCode,h.statusMessage,h.headers,h.body,s);if(p.statusCode===301||p.statusCode===302){try{const _=p.headers.location||"";return Ge(b=o.redirect(_),Au,mm).call(b,e+1,r,0,s,p)}catch{}return p}else if(p.statusCode===429&&(this.retryFunc==null||await this.retryFunc(o,p,e))){const _=p.headers["retry-after"];let S=X(this,af).slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return typeof _=="string"&&_.match(/^[1-9][0-9]*$/)&&(S=parseInt(_)),Ge(v=o.clone(),Au,mm).call(v,e+1,r,S,s,p)}if(this.processFunc){Db(X(s,ha));try{p=await this.processFunc(o,p)}catch(_){(_.throttle==null||typeof _.stall!="number")&&p.makeServerError("error in post-processing function",_).assertOk();let S=X(this,af).slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return _.stall>=0&&(S=_.stall),Ge(E=o.clone(),Au,mm).call(E,e+1,r,S,s,p)}}return p};let qf=i5;var zg,jg,Hg,wo,gd,Eu;const MP=class MP{constructor(e,r,n,s,i){Te(this,zg,void 0);Te(this,jg,void 0);Te(this,Hg,void 0);Te(this,wo,void 0);Te(this,gd,void 0);Te(this,Eu,void 0);fe(this,zg,e),fe(this,jg,r),fe(this,Hg,Object.keys(n).reduce((o,f)=>(o[f.toLowerCase()]=String(n[f]),o),{})),fe(this,wo,s==null?null:new Uint8Array(s)),fe(this,gd,i||null),fe(this,Eu,{message:""})}toString(){return``}get statusCode(){return X(this,zg)}get statusMessage(){return X(this,jg)}get headers(){return Object.assign({},X(this,Hg))}get body(){return X(this,wo)==null?null:new Uint8Array(X(this,wo))}get bodyText(){try{return X(this,wo)==null?"":_M(X(this,wo))}catch{He(!1,"response body is not valid UTF-8 data","UNSUPPORTED_OPERATION",{operation:"bodyText",info:{response:this}})}}get bodyJson(){try{return JSON.parse(this.bodyText)}catch{He(!1,"response body is not valid JSON","UNSUPPORTED_OPERATION",{operation:"bodyJson",info:{response:this}})}}[Symbol.iterator](){const e=this.headers,r=Object.keys(e);let n=0;return{next:()=>{if(n=0,"invalid stall timeout","stall",r);const n=new Error(e||"throttling requests");throw lt(n,{stall:r,throttle:!0}),n}getHeader(e){return this.headers[e.toLowerCase()]}hasBody(){return X(this,wo)!=null}get request(){return X(this,gd)}ok(){return X(this,Eu).message===""&&this.statusCode>=200&&this.statusCode<300}assertOk(){if(this.ok())return;let{message:e,error:r}=X(this,Eu);e===""&&(e=`server response ${this.statusCode} ${this.statusMessage}`),He(!1,e,"SERVER_ERROR",{request:this.request||"unknown request",response:this,error:r})}};zg=new WeakMap,jg=new WeakMap,Hg=new WeakMap,wo=new WeakMap,gd=new WeakMap,Eu=new WeakMap;let cc=MP;function HI(){return new Date().getTime()}function zse(t){return Rf(t.replace(/%([0-9a-f][0-9a-f])/gi,(e,r)=>String.fromCharCode(parseInt(r,16))))}function jse(t){return new Promise(e=>setTimeout(e,t))}const Hse=BigInt(-1),yo=BigInt(0),kh=BigInt(1),qse=BigInt(5),Yl={};let Wh="0000";for(;Wh.length<80;)Wh+=Wh;function Jc(t){let e=Wh;for(;e.length=-s&&tyo?t=Z2(lu(t,n),n):t=-Z2(lu(-t,n),n)}else{const s=kh<=0&&ti[f]==null?p:(me(typeof i[f]===h,"invalid fixed format ("+f+" not "+h+")","format."+f,i[f]),i[f]);e=o("signed","boolean",e),r=o("width","number",r),n=o("decimals","number",n)}me(r%8===0,"invalid FixedNumber width (not byte aligned)","format.width",r),me(n<=80,"invalid FixedNumber decimals (too large)","format.decimals",n);const s=(e?"":"u")+"fixed"+String(r)+"x"+String(n);return{signed:e,width:r,decimals:n,name:s}}function Gse(t,e){let r="";t0?n*=Jc(s):s<0&&(r*=Jc(-s)),rn?1:0}eq(e){return this.cmp(e)===0}lt(e){return this.cmp(e)<0}lte(e){return this.cmp(e)<=0}gt(e){return this.cmp(e)>0}gte(e){return this.cmp(e)>=0}floor(){let e=X(this,Xt);return X(this,Xt)yo&&(e+=X(this,ni)-kh),e=X(this,Xt)/X(this,ni)*X(this,ni),Ge(this,Eo,Ja).call(this,e,"ceiling")}round(e){if(e==null&&(e=0),e>=this.decimals)return this;const r=this.decimals-e,n=qse*Jc(r-1);let s=this.value+n;const i=Jc(r);return s=s/i*i,H1(s,X(this,Ao),"round"),new _0(Yl,s,X(this,Ao))}isZero(){return X(this,Xt)===yo}isNegative(){return X(this,Xt)0){const h=Jc(f);He(o%h===yo,"value loses precision for format","NUMERIC_FAULT",{operation:"fromValue",fault:"underflow",value:e}),o/=h}else f<0&&(o*=Jc(-f));return H1(o,i,"fromValue"),new _0(Yl,o,i)}static fromString(e,r){const n=e.match(/^(-?)([0-9]*)\.?([0-9]*)$/);me(n&&n[2].length+n[3].length>0,"invalid FixedNumber string value","value",e);const s=G3(r);let i=n[2]||"0",o=n[3]||"";for(;o.length{He(n<=t.length,"data short segment too short","BUFFER_OVERRUN",{buffer:t,length:t.length,offset:n})};if(t[e]>=248){const n=t[e]-247;r(e+1+n);const s=qI(t,e+1,n);return r(e+1+n+s),GI(t,e,e+1+n,n+s)}else if(t[e]>=192){const n=t[e]-192;return r(e+1+n),GI(t,e,e+1,n)}else if(t[e]>=184){const n=t[e]-183;r(e+1+n);const s=qI(t,e+1,n);r(e+1+n+s);const i=nt(t.slice(e+1+n,e+1+n+s));return{consumed:1+n+s,result:i}}else if(t[e]>=128){const n=t[e]-128;r(e+1+n);const s=nt(t.slice(e+1,e+1+n));return{consumed:1+n,result:s}}return{consumed:1,result:Vse(t[e])}}function PM(t){const e=$t(t,"data"),r=U$(e,0);return me(r.consumed===e.length,"unexpected junk after rlp payload","data",t),r.result}function VI(t){const e=[];for(;t;)e.unshift(t&255),t>>=8;return e}function z$(t){if(Array.isArray(t)){let n=[];if(t.forEach(function(i){n=n.concat(z$(i))}),n.length<=55)return n.unshift(192+n.length),n;const s=VI(n.length);return s.unshift(247+s.length),s.concat(n)}const e=Array.prototype.slice.call($t(t,"object"));if(e.length===1&&e[0]<=127)return e;if(e.length<=55)return e.unshift(128+e.length),e;const r=VI(e.length);return r.unshift(183+r.length),r.concat(e)}const KI="0123456789abcdef";function pg(t){let e="0x";for(const r of z$(t))e+=KI[r>>4],e+=KI[r&15];return e}const j$=["wei","kwei","mwei","gwei","szabo","finney","ether"];function CM(t,e){let r=18;if(typeof e=="string"){const n=j$.indexOf(e);me(n>=0,"invalid unit","unit",e),r=3*n}else e!=null&&(r=Ct(e,"unit"));return Q2.fromValue(t,r,{decimals:r,width:512}).toString()}function IM(t,e){me(typeof t=="string","value must be a string","value",t);let r=18;if(typeof e=="string"){const n=j$.indexOf(e);me(n>=0,"invalid unit","unit",e),r=3*n}else e!=null&&(r=Ct(e,"unit"));return Q2.fromString(t,{decimals:r,width:512}).value}function H$(t){return CM(t,18)}function q$(t){return IM(t,18)}const fi=32,F9=new Uint8Array(fi),Kse=["then"],$b={};function q1(t,e){const r=new Error(`deferred error during ABI decoding triggered accessing ${t}`);throw r.error=e,r}var B0;const qm=class qm extends Array{constructor(...r){const n=r[0];let s=r[1],i=(r[2]||[]).slice(),o=!0;n!==$b&&(s=r,i=[],o=!1);super(s.length);Te(this,B0,void 0);s.forEach((h,p)=>{this[p]=h});const f=i.reduce((h,p)=>(typeof p=="string"&&h.set(p,(h.get(p)||0)+1),h),new Map);if(fe(this,B0,Object.freeze(s.map((h,p)=>{const b=i[p];return b!=null&&f.get(b)===1?b:null}))),!!o)return Object.freeze(this),new Proxy(this,{get:(h,p,b)=>{if(typeof p=="string"){if(p.match(/^[0-9]+$/)){const E=Ct(p,"%index");if(E<0||E>=this.length)throw new RangeError("out of result range");const _=h[E];return _ instanceof Error&&q1(`index ${E}`,_),_}if(Kse.indexOf(p)>=0)return Reflect.get(h,p,b);const v=h[p];if(v instanceof Function)return function(...E){return v.apply(this===b?h:this,E)};if(!(p in h))return h.getValue.apply(this===b?h:this,[p])}return Reflect.get(h,p,b)}})}toArray(){const r=[];return this.forEach((n,s)=>{n instanceof Error&&q1(`index ${s}`,n),r.push(n)}),r}toObject(){return X(this,B0).reduce((r,n,s)=>(He(n!=null,"value at index ${ index } unnamed","UNSUPPORTED_OPERATION",{operation:"toObject()"}),n in r||(r[n]=this.getValue(n)),r),{})}slice(r,n){r==null&&(r=0),r<0&&(r+=this.length,r<0&&(r=0)),n==null&&(n=this.length),n<0&&(n+=this.length,n<0&&(n=0)),n>this.length&&(n=this.length);const s=[],i=[];for(let o=r;o{X(this,cf)[e]=WI(r)}}}cf=new WeakMap,Mu=new WeakMap,yd=new WeakSet,Lv=function(e){return X(this,cf).push(e),fe(this,Mu,X(this,Mu)+e.length),e.length};var Vi,Es,s5,G$;const SP=class SP{constructor(e,r){Te(this,s5);Ie(this,"allowLoose");Te(this,Vi,void 0);Te(this,Es,void 0);lt(this,{allowLoose:!!r}),fe(this,Vi,Ti(e)),fe(this,Es,0)}get data(){return nt(X(this,Vi))}get dataLength(){return X(this,Vi).length}get consumed(){return X(this,Es)}get bytes(){return new Uint8Array(X(this,Vi))}subReader(e){return new SP(X(this,Vi).slice(X(this,Es)+e),this.allowLoose)}readBytes(e,r){let n=Ge(this,s5,G$).call(this,0,e,!!r);return fe(this,Es,X(this,Es)+n.length),n.slice(0,e)}readValue(){return lx(this.readBytes(fi))}readIndex(){return Sse(this.readBytes(fi))}};Vi=new WeakMap,Es=new WeakMap,s5=new WeakSet,G$=function(e,r,n){let s=Math.ceil(r/fi)*fi;return X(this,Es)+s>X(this,Vi).length&&(this.allowLoose&&n&&X(this,Es)+r<=X(this,Vi).length?s=r:He(!1,"data out-of-bounds","BUFFER_OVERRUN",{buffer:Ti(X(this,Vi)),length:X(this,Vi).length,offset:X(this,Es)+s})),X(this,Vi).slice(X(this,Es),X(this,Es)+s)};let z9=SP;function j9(t){if(!Number.isSafeInteger(t)||t<0)throw new Error(`Wrong positive integer: ${t}`)}function Wse(t){if(typeof t!="boolean")throw new Error(`Expected boolean, not ${t}`)}function V$(t,...e){if(!(t instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(e.length>0&&!e.includes(t.length))throw new TypeError(`Expected Uint8Array of length ${e}, not of length=${t.length}`)}function Jse(t){if(typeof t!="function"||typeof t.create!="function")throw new Error("Hash should be wrapped by utils.wrapConstructor");j9(t.outputLen),j9(t.blockLen)}function Zse(t,e=!0){if(t.destroyed)throw new Error("Hash instance has been destroyed");if(e&&t.finished)throw new Error("Hash#digest() has already been called")}function Qse(t,e){V$(t);const r=e.outputLen;if(t.lengthnew Uint32Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/4)),V3=t=>new DataView(t.buffer,t.byteOffset,t.byteLength),aa=(t,e)=>t<<32-e|t>>>e,Xse=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;if(!Xse)throw new Error("Non little-endian hardware is not supported");Array.from({length:256},(t,e)=>e.toString(16).padStart(2,"0"));function eoe(t){if(typeof t!="string")throw new TypeError(`utf8ToBytes expected string, got ${typeof t}`);return new TextEncoder().encode(t)}function My(t){if(typeof t=="string"&&(t=eoe(t)),!(t instanceof Uint8Array))throw new TypeError(`Expected input type is Uint8Array (got ${typeof t})`);return t}let X2=class{clone(){return this._cloneInto()}};function Sy(t){const e=n=>t().update(My(n)).digest(),r=t();return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=()=>t(),e}function toe(t){const e=(n,s)=>t(s).update(My(n)).digest(),r=t({});return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=n=>t(n),e}let K$=class extends X2{constructor(e,r){super(),this.finished=!1,this.destroyed=!1,Yi.hash(e);const n=My(r);if(this.iHash=e.create(),!(this.iHash instanceof X2))throw new TypeError("Expected instance of class which extends utils.Hash");const s=this.blockLen=this.iHash.blockLen;this.outputLen=this.iHash.outputLen;const i=new Uint8Array(s);i.set(n.length>this.iHash.blockLen?e.create().update(n).digest():n);for(let o=0;onew K$(t,e).update(r).digest();W$.create=(t,e)=>new K$(t,e);function roe(t,e,r,n){if(typeof t.setBigUint64=="function")return t.setBigUint64(e,r,n);const s=BigInt(32),i=BigInt(4294967295),o=Number(r>>s&i),f=Number(r&i),h=n?4:0,p=n?0:4;t.setUint32(e+h,o,n),t.setUint32(e+p,f,n)}let J$=class extends X2{constructor(e,r,n,s){super(),this.blockLen=e,this.outputLen=r,this.padOffset=n,this.isLE=s,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=V3(this.buffer)}update(e){Yi.exists(this);const{view:r,buffer:n,blockLen:s}=this;e=My(e);const i=e.length;for(let o=0;os-o&&(this.process(n,0),o=0);for(let h=o;hf.setUint32(4*p,h,i))}digest(){const{buffer:e,outputLen:r}=this;this.digestInto(e);const n=e.slice(0,r);return this.destroy(),n}_cloneInto(e){e||(e=new this.constructor),e.set(...this.get());const{blockLen:r,buffer:n,length:s,finished:i,destroyed:o,pos:f}=this;return e.length=s,e.pos=f,e.finished=i,e.destroyed=o,s%r&&e.buffer.set(n),e}};const noe=(t,e,r)=>t&e^~t&r,ioe=(t,e,r)=>t&e^t&r^e&r,soe=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),c0=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),u0=new Uint32Array(64);let ooe=class extends J${constructor(){super(64,32,8,!1),this.A=c0[0]|0,this.B=c0[1]|0,this.C=c0[2]|0,this.D=c0[3]|0,this.E=c0[4]|0,this.F=c0[5]|0,this.G=c0[6]|0,this.H=c0[7]|0}get(){const{A:e,B:r,C:n,D:s,E:i,F:o,G:f,H:h}=this;return[e,r,n,s,i,o,f,h]}set(e,r,n,s,i,o,f,h){this.A=e|0,this.B=r|0,this.C=n|0,this.D=s|0,this.E=i|0,this.F=o|0,this.G=f|0,this.H=h|0}process(e,r){for(let v=0;v<16;v++,r+=4)u0[v]=e.getUint32(r,!1);for(let v=16;v<64;v++){const E=u0[v-15],_=u0[v-2],S=aa(E,7)^aa(E,18)^E>>>3,P=aa(_,17)^aa(_,19)^_>>>10;u0[v]=P+u0[v-7]+S+u0[v-16]|0}let{A:n,B:s,C:i,D:o,E:f,F:h,G:p,H:b}=this;for(let v=0;v<64;v++){const E=aa(f,6)^aa(f,11)^aa(f,25),_=b+E+noe(f,h,p)+soe[v]+u0[v]|0,P=(aa(n,2)^aa(n,13)^aa(n,22))+ioe(n,s,i)|0;b=p,p=h,h=f,f=o+_|0,o=i,i=s,s=n,n=_+P|0}n=n+this.A|0,s=s+this.B|0,i=i+this.C|0,o=o+this.D|0,f=f+this.E|0,h=h+this.F|0,p=p+this.G|0,b=b+this.H|0,this.set(n,s,i,o,f,h,p,b)}roundClean(){u0.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}};const aoe=Sy(()=>new ooe),Fb=BigInt(2**32-1),H9=BigInt(32);function Z$(t,e=!1){return e?{h:Number(t&Fb),l:Number(t>>H9&Fb)}:{h:Number(t>>H9&Fb)|0,l:Number(t&Fb)|0}}function foe(t,e=!1){let r=new Uint32Array(t.length),n=new Uint32Array(t.length);for(let s=0;sBigInt(t>>>0)<>>0),uoe=(t,e,r)=>t>>>r,loe=(t,e,r)=>t<<32-r|e>>>r,hoe=(t,e,r)=>t>>>r|e<<32-r,doe=(t,e,r)=>t<<32-r|e>>>r,poe=(t,e,r)=>t<<64-r|e>>>r-32,moe=(t,e,r)=>t>>>r-32|e<<64-r,goe=(t,e)=>e,yoe=(t,e)=>t,boe=(t,e,r)=>t<>>32-r,voe=(t,e,r)=>e<>>32-r,xoe=(t,e,r)=>e<>>64-r,woe=(t,e,r)=>t<>>64-r;function Aoe(t,e,r,n){const s=(e>>>0)+(n>>>0);return{h:t+r+(s/2**32|0)|0,l:s|0}}const Eoe=(t,e,r)=>(t>>>0)+(e>>>0)+(r>>>0),Moe=(t,e,r,n)=>e+r+n+(t/2**32|0)|0,Soe=(t,e,r,n)=>(t>>>0)+(e>>>0)+(r>>>0)+(n>>>0),_oe=(t,e,r,n,s)=>e+r+n+s+(t/2**32|0)|0,Poe=(t,e,r,n,s)=>(t>>>0)+(e>>>0)+(r>>>0)+(n>>>0)+(s>>>0),Coe=(t,e,r,n,s,i)=>e+r+n+s+i+(t/2**32|0)|0,gt={fromBig:Z$,split:foe,toBig:coe,shrSH:uoe,shrSL:loe,rotrSH:hoe,rotrSL:doe,rotrBH:poe,rotrBL:moe,rotr32H:goe,rotr32L:yoe,rotlSH:boe,rotlSL:voe,rotlBH:xoe,rotlBL:woe,add:Aoe,add3L:Eoe,add3H:Moe,add4L:Soe,add4H:_oe,add5H:Coe,add5L:Poe},[Ioe,Toe]=gt.split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(t=>BigInt(t))),l0=new Uint32Array(80),h0=new Uint32Array(80);let TM=class extends J${constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:e,Al:r,Bh:n,Bl:s,Ch:i,Cl:o,Dh:f,Dl:h,Eh:p,El:b,Fh:v,Fl:E,Gh:_,Gl:S,Hh:P,Hl:I}=this;return[e,r,n,s,i,o,f,h,p,b,v,E,_,S,P,I]}set(e,r,n,s,i,o,f,h,p,b,v,E,_,S,P,I){this.Ah=e|0,this.Al=r|0,this.Bh=n|0,this.Bl=s|0,this.Ch=i|0,this.Cl=o|0,this.Dh=f|0,this.Dl=h|0,this.Eh=p|0,this.El=b|0,this.Fh=v|0,this.Fl=E|0,this.Gh=_|0,this.Gl=S|0,this.Hh=P|0,this.Hl=I|0}process(e,r){for(let B=0;B<16;B++,r+=4)l0[B]=e.getUint32(r),h0[B]=e.getUint32(r+=4);for(let B=16;B<80;B++){const N=l0[B-15]|0,$=h0[B-15]|0,H=gt.rotrSH(N,$,1)^gt.rotrSH(N,$,8)^gt.shrSH(N,$,7),J=gt.rotrSL(N,$,1)^gt.rotrSL(N,$,8)^gt.shrSL(N,$,7),Q=l0[B-2]|0,K=h0[B-2]|0,se=gt.rotrSH(Q,K,19)^gt.rotrBH(Q,K,61)^gt.shrSH(Q,K,6),w=gt.rotrSL(Q,K,19)^gt.rotrBL(Q,K,61)^gt.shrSL(Q,K,6),a=gt.add4L(J,w,h0[B-7],h0[B-16]),u=gt.add4H(a,H,se,l0[B-7],l0[B-16]);l0[B]=u|0,h0[B]=a|0}let{Ah:n,Al:s,Bh:i,Bl:o,Ch:f,Cl:h,Dh:p,Dl:b,Eh:v,El:E,Fh:_,Fl:S,Gh:P,Gl:I,Hh:C,Hl:T}=this;for(let B=0;B<80;B++){const N=gt.rotrSH(v,E,14)^gt.rotrSH(v,E,18)^gt.rotrBH(v,E,41),$=gt.rotrSL(v,E,14)^gt.rotrSL(v,E,18)^gt.rotrBL(v,E,41),H=v&_^~v&P,J=E&S^~E&I,Q=gt.add5L(T,$,J,Toe[B],h0[B]),K=gt.add5H(Q,C,N,H,Ioe[B],l0[B]),se=Q|0,w=gt.rotrSH(n,s,28)^gt.rotrBH(n,s,34)^gt.rotrBH(n,s,39),a=gt.rotrSL(n,s,28)^gt.rotrBL(n,s,34)^gt.rotrBL(n,s,39),u=n&i^n&f^i&f,l=s&o^s&h^o&h;C=P|0,T=I|0,P=_|0,I=S|0,_=v|0,S=E|0,{h:v,l:E}=gt.add(p|0,b|0,K|0,se|0),p=f|0,b=h|0,f=i|0,h=o|0,i=n|0,o=s|0;const d=gt.add3L(se,a,l);n=gt.add3H(d,K,w,u),s=d|0}({h:n,l:s}=gt.add(this.Ah|0,this.Al|0,n|0,s|0)),{h:i,l:o}=gt.add(this.Bh|0,this.Bl|0,i|0,o|0),{h:f,l:h}=gt.add(this.Ch|0,this.Cl|0,f|0,h|0),{h:p,l:b}=gt.add(this.Dh|0,this.Dl|0,p|0,b|0),{h:v,l:E}=gt.add(this.Eh|0,this.El|0,v|0,E|0),{h:_,l:S}=gt.add(this.Fh|0,this.Fl|0,_|0,S|0),{h:P,l:I}=gt.add(this.Gh|0,this.Gl|0,P|0,I|0),{h:C,l:T}=gt.add(this.Hh|0,this.Hl|0,C|0,T|0),this.set(n,s,i,o,f,h,p,b,v,E,_,S,P,I,C,T)}roundClean(){l0.fill(0),h0.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}};class koe extends TM{constructor(){super(),this.Ah=573645204,this.Al=-64227540,this.Bh=-1621794909,this.Bl=-934517566,this.Ch=596883563,this.Cl=1867755857,this.Dh=-1774684391,this.Dl=1497426621,this.Eh=-1775747358,this.El=-1467023389,this.Fh=-1101128155,this.Fl=1401305490,this.Gh=721525244,this.Gl=746961066,this.Hh=246885852,this.Hl=-2117784414,this.outputLen=32}}let Roe=class extends TM{constructor(){super(),this.Ah=-876896931,this.Al=-1056596264,this.Bh=1654270250,this.Bl=914150663,this.Ch=-1856437926,this.Cl=812702999,this.Dh=355462360,this.Dl=-150054599,this.Eh=1731405415,this.El=-4191439,this.Fh=-1900787065,this.Fl=1750603025,this.Gh=-619958771,this.Gl=1694076839,this.Hh=1203062813,this.Hl=-1090891868,this.outputLen=48}};const Boe=Sy(()=>new TM);Sy(()=>new koe);Sy(()=>new Roe);function Ooe(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof Ve.global<"u")return Ve.global;throw new Error("unable to locate global object")}const JI=Ooe();JI.crypto||JI.msCrypto;function Noe(t,e){const r={sha256:aoe,sha512:Boe}[t];return me(r!=null,"invalid hmac algorithm","algorithm",t),W$.create(r,e)}let Q$=!1;const Y$=function(t,e,r){return Noe(t,e).update(r).digest()};let X$=Y$;function _y(t,e,r){const n=$t(e,"key"),s=$t(r,"data");return nt(X$(t,n,s))}_y._=Y$;_y.lock=function(){Q$=!0};_y.register=function(t){if(Q$)throw new Error("computeHmac is locked");X$=t};Object.freeze(_y);const[eF,tF,rF]=[[],[],[]],Loe=BigInt(0),G1=BigInt(1),Doe=BigInt(2),$oe=BigInt(7),Foe=BigInt(256),Uoe=BigInt(113);for(let t=0,e=G1,r=1,n=0;t<24;t++){[r,n]=[n,(2*r+3*n)%5],eF.push(2*(5*n+r)),tF.push((t+1)*(t+2)/2%64);let s=Loe;for(let i=0;i<7;i++)e=(e<>$oe)*Uoe)%Foe,e&Doe&&(s^=G1<<(G1<r>32?gt.rotlBH(t,e,r):gt.rotlSH(t,e,r),QI=(t,e,r)=>r>32?gt.rotlBL(t,e,r):gt.rotlSL(t,e,r);function Hoe(t,e=24){const r=new Uint32Array(10);for(let n=24-e;n<24;n++){for(let o=0;o<10;o++)r[o]=t[o]^t[o+10]^t[o+20]^t[o+30]^t[o+40];for(let o=0;o<10;o+=2){const f=(o+8)%10,h=(o+2)%10,p=r[h],b=r[h+1],v=ZI(p,b,1)^r[f],E=QI(p,b,1)^r[f+1];for(let _=0;_<50;_+=10)t[o+_]^=v,t[o+_+1]^=E}let s=t[2],i=t[3];for(let o=0;o<24;o++){const f=tF[o],h=ZI(s,i,f),p=QI(s,i,f),b=eF[o];s=t[b],i=t[b+1],t[b]=h,t[b+1]=p}for(let o=0;o<50;o+=10){for(let f=0;f<10;f++)r[f]=t[o+f];for(let f=0;f<10;f++)t[o+f]^=~r[(f+2)%10]&r[(f+4)%10]}t[0]^=zoe[n],t[1]^=joe[n]}r.fill(0)}let nF=class iF extends X2{constructor(e,r,n,s=!1,i=24){if(super(),this.blockLen=e,this.suffix=r,this.outputLen=n,this.enableXOF=s,this.rounds=i,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,Yi.number(n),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=Yse(this.state)}keccak(){Hoe(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){Yi.exists(this);const{blockLen:r,state:n}=this;e=My(e);const s=e.length;for(let i=0;i=n&&this.keccak();const o=Math.min(n-this.posOut,i-s);e.set(r.subarray(this.posOut,this.posOut+o),s),this.posOut+=o,s+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return Yi.number(e),this.xofInto(new Uint8Array(e))}digestInto(e){if(Yi.output(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(e){const{blockLen:r,suffix:n,outputLen:s,rounds:i,enableXOF:o}=this;return e||(e=new iF(r,n,s,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=n,e.outputLen=s,e.enableXOF=o,e.destroyed=this.destroyed,e}};const $c=(t,e,r)=>Sy(()=>new nF(e,t,r));$c(6,144,224/8);$c(6,136,256/8);$c(6,104,384/8);$c(6,72,512/8);$c(1,144,224/8);const qoe=$c(1,136,256/8);$c(1,104,384/8);$c(1,72,512/8);const sF=(t,e,r)=>toe((n={})=>new nF(e,t,n.dkLen===void 0?r:n.dkLen,!0));sF(31,168,128/8);sF(31,136,256/8);let oF=!1;const aF=function(t){return qoe(t)};let fF=aF;function kr(t){const e=$t(t,"data");return nt(fF(e))}kr._=aF;kr.lock=function(){oF=!0};kr.register=function(t){if(oF)throw new TypeError("keccak256 is locked");fF=t};Object.freeze(kr);var _t={},q9={exports:{}},G9={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh */(function(t,e){var r=Ln,n=r.Buffer;function s(o,f){for(var h in o)f[h]=o[h]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=r:(s(r,e),e.Buffer=i);function i(o,f,h){return n(o,f,h)}i.prototype=Object.create(n.prototype),s(n,i),i.from=function(o,f,h){if(typeof o=="number")throw new TypeError("Argument must not be a number");return n(o,f,h)},i.alloc=function(o,f,h){if(typeof o!="number")throw new TypeError("Argument must be a number");var p=n(o);return f!==void 0?typeof h=="string"?p.fill(f,h):p.fill(f):p.fill(0),p},i.allocUnsafe=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return n(o)},i.allocUnsafeSlow=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(o)}})(G9,G9.exports);var Tt=G9.exports,K3=65536,Goe=4294967295;function Voe(){throw new Error(`Secure random number generation is not supported by this browser. -Use Chrome, Firefox or Internet Explorer 11`)}var Koe=Tt.Buffer,e6=Ke.crypto||Ke.msCrypto;e6&&e6.getRandomValues?q9.exports=Woe:q9.exports=Voe;function Woe(t,e){if(t>Goe)throw new RangeError("requested too many random bytes");var r=Koe.allocUnsafe(t);if(t>0)if(t>K3)for(var n=0;n0&&(o=r[0]),o instanceof Error)throw o;var f=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw f.context=o,f}var h=i[e];if(h===void 0)return!1;if(typeof h=="function")YI(h,this,r);else for(var p=h.length,b=mF(h,p),n=0;n0&&o.length>s&&!o.warned){o.warned=!0;var f=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");f.name="MaxListenersExceededWarning",f.emitter=t,f.type=e,f.count=o.length,Joe(f)}return t}tr.prototype.addListener=function(e,r){return lF(this,e,r,!1)};tr.prototype.on=tr.prototype.addListener;tr.prototype.prependListener=function(e,r){return lF(this,e,r,!0)};function Zoe(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function hF(t,e,r){var n={fired:!1,wrapFn:void 0,target:t,type:e,listener:r},s=Zoe.bind(n);return s.listener=r,n.wrapFn=s,s}tr.prototype.once=function(e,r){return hx(r),this.on(e,hF(this,e,r)),this};tr.prototype.prependOnceListener=function(e,r){return hx(r),this.prependListener(e,hF(this,e,r)),this};tr.prototype.removeListener=function(e,r){var n,s,i,o,f;if(hx(r),s=this._events,s===void 0)return this;if(n=s[e],n===void 0)return this;if(n===r||n.listener===r)--this._eventsCount===0?this._events=Object.create(null):(delete s[e],s.removeListener&&this.emit("removeListener",e,n.listener||r));else if(typeof n!="function"){for(i=-1,o=n.length-1;o>=0;o--)if(n[o]===r||n[o].listener===r){f=n[o].listener,i=o;break}if(i<0)return this;i===0?n.shift():Qoe(n,i),n.length===1&&(s[e]=n[0]),s.removeListener!==void 0&&this.emit("removeListener",e,f||r)}return this};tr.prototype.off=tr.prototype.removeListener;tr.prototype.removeAllListeners=function(e){var r,n,s;if(n=this._events,n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[e]),this;if(arguments.length===0){var i=Object.keys(n),o;for(s=0;s=0;s--)this.removeListener(e,r[s]);return this};function dF(t,e,r){var n=t._events;if(n===void 0)return[];var s=n[e];return s===void 0?[]:typeof s=="function"?r?[s.listener||s]:[s]:r?Yoe(s):mF(s,s.length)}tr.prototype.listeners=function(e){return dF(this,e,!0)};tr.prototype.rawListeners=function(e){return dF(this,e,!1)};tr.listenerCount=function(t,e){return typeof t.listenerCount=="function"?t.listenerCount(e):pF.call(t,e)};tr.prototype.listenerCount=pF;function pF(t){var e=this._events;if(e!==void 0){var r=e[t];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}tr.prototype.eventNames=function(){return this._eventsCount>0?Dv(this._events):[]};function mF(t,e){for(var r=new Array(e),n=0;n"u"||!mn?Ot:mn(Uint8Array),Gu={"%AggregateError%":typeof AggregateError>"u"?Ot:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Ot:ArrayBuffer,"%ArrayIteratorPrototype%":Xl&&mn?mn([][Symbol.iterator]()):Ot,"%AsyncFromSyncIteratorPrototype%":Ot,"%AsyncFunction%":ch,"%AsyncGenerator%":ch,"%AsyncGeneratorFunction%":ch,"%AsyncIteratorPrototype%":ch,"%Atomics%":typeof Atomics>"u"?Ot:Atomics,"%BigInt%":typeof BigInt>"u"?Ot:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?Ot:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?Ot:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Ot:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?Ot:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Ot:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Ot:FinalizationRegistry,"%Function%":xF,"%GeneratorFunction%":ch,"%Int8Array%":typeof Int8Array>"u"?Ot:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Ot:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Ot:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Xl&&mn?mn(mn([][Symbol.iterator]())):Ot,"%JSON%":typeof JSON=="object"?JSON:Ot,"%Map%":typeof Map>"u"?Ot:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Xl||!mn?Ot:mn(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Ot:Promise,"%Proxy%":typeof Proxy>"u"?Ot:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?Ot:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Ot:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Xl||!mn?Ot:mn(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Ot:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Xl&&mn?mn(""[Symbol.iterator]()):Ot,"%Symbol%":Xl?Symbol:Ot,"%SyntaxError%":pp,"%ThrowTypeError%":dae,"%TypedArray%":mae,"%TypeError%":Zh,"%Uint8Array%":typeof Uint8Array>"u"?Ot:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Ot:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Ot:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Ot:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?Ot:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Ot:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Ot:WeakSet};if(mn)try{null.error}catch(t){var gae=mn(mn(t));Gu["%Error.prototype%"]=gae}var yae=function t(e){var r;if(e==="%AsyncFunction%")r=J3("async function () {}");else if(e==="%GeneratorFunction%")r=J3("function* () {}");else if(e==="%AsyncGeneratorFunction%")r=J3("async function* () {}");else if(e==="%AsyncGenerator%"){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(e==="%AsyncIteratorPrototype%"){var s=t("%AsyncGenerator%");s&&mn&&(r=mn(s.prototype))}return Gu[e]=r,r},rT={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Py=OM,t6=hae,bae=Py.call(Function.call,Array.prototype.concat),vae=Py.call(Function.apply,Array.prototype.splice),nT=Py.call(Function.call,String.prototype.replace),r6=Py.call(Function.call,String.prototype.slice),xae=Py.call(Function.call,RegExp.prototype.exec),wae=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Aae=/\\(\\)?/g,Eae=function(e){var r=r6(e,0,1),n=r6(e,-1);if(r==="%"&&n!=="%")throw new pp("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new pp("invalid intrinsic syntax, expected opening `%`");var s=[];return nT(e,wae,function(i,o,f,h){s[s.length]=f?nT(h,Aae,"$1"):o||i}),s},Mae=function(e,r){var n=e,s;if(t6(rT,n)&&(s=rT[n],n="%"+s[0]+"%"),t6(Gu,n)){var i=Gu[n];if(i===ch&&(i=yae(n)),typeof i>"u"&&!r)throw new Zh("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:s,name:n,value:i}}throw new pp("intrinsic "+e+" does not exist!")},Fc=function(e,r){if(typeof e!="string"||e.length===0)throw new Zh("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new Zh('"allowMissing" argument must be a boolean');if(xae(/^%?[^%]*%?$/,e)===null)throw new pp("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Eae(e),s=n.length>0?n[0]:"",i=Mae("%"+s+"%",r),o=i.name,f=i.value,h=!1,p=i.alias;p&&(s=p[0],vae(n,bae([0,1],p)));for(var b=1,v=!0;b=n.length){var P=qu(f,E);v=!!P,v&&"get"in P&&!("originalValue"in P.get)?f=P.get:f=f[E]}else v=t6(f,E),f=f[E];v&&!h&&(Gu[o]=f)}}return f},wF={exports:{}};(function(t){var e=OM,r=Fc,n=r("%Function.prototype.apply%"),s=r("%Function.prototype.call%"),i=r("%Reflect.apply%",!0)||e.call(s,n),o=r("%Object.getOwnPropertyDescriptor%",!0),f=r("%Object.defineProperty%",!0),h=r("%Math.max%");if(f)try{f({},"a",{value:1})}catch{f=null}t.exports=function(v){var E=i(e,s,arguments);if(o&&f){var _=o(E,"length");_.configurable&&f(E,"length",{value:1+h(0,v.length-(arguments.length-1))})}return E};var p=function(){return i(e,n,arguments)};f?f(t.exports,"apply",{value:p}):t.exports.apply=p})(wF);var Sae=wF.exports,AF=Fc,EF=Sae,_ae=EF(AF("String.prototype.indexOf")),Pae=function(e,r){var n=AF(e,!!r);return typeof n=="function"&&_ae(e,".prototype.")>-1?EF(n):n},Cae=BM(),Iae=Pae,W9=Iae("Object.prototype.toString"),px=function(e){return Cae&&e&&typeof e=="object"&&Symbol.toStringTag in e?!1:W9(e)==="[object Arguments]"},MF=function(e){return px(e)?!0:e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&W9(e)!=="[object Array]"&&W9(e.callee)==="[object Function]"},Tae=function(){return px(arguments)}();px.isLegacyArguments=MF;var kae=Tae?px:MF,Rae=Object.prototype.toString,Bae=Function.prototype.toString,Oae=/^\s*(?:function)?\*/,SF=BM(),Q3=Object.getPrototypeOf,Nae=function(){if(!SF)return!1;try{return Function("return function*() {}")()}catch{}},Y3,Lae=function(e){if(typeof e!="function")return!1;if(Oae.test(Bae.call(e)))return!0;if(!SF){var r=Rae.call(e);return r==="[object GeneratorFunction]"}if(!Q3)return!1;if(typeof Y3>"u"){var n=Nae();Y3=n?Q3(n):!1}return Q3(e)===Y3},_F=Function.prototype.toString,Rh=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,J9,$v;if(typeof Rh=="function"&&typeof Object.defineProperty=="function")try{J9=Object.defineProperty({},"length",{get:function(){throw $v}}),$v={},Rh(function(){throw 42},null,J9)}catch(t){t!==$v&&(Rh=null)}else Rh=null;var Dae=/^\s*class\b/,Z9=function(e){try{var r=_F.call(e);return Dae.test(r)}catch{return!1}},X3=function(e){try{return Z9(e)?!1:(_F.call(e),!0)}catch{return!1}},Fv=Object.prototype.toString,$ae="[object Object]",Fae="[object Function]",Uae="[object GeneratorFunction]",zae="[object HTMLAllCollection]",jae="[object HTML document.all class]",Hae="[object HTMLCollection]",qae=typeof Symbol=="function"&&!!Symbol.toStringTag,Gae=!(0 in[,]),Q9=function(){return!1};if(typeof document=="object"){var Vae=document.all;Fv.call(Vae)===Fv.call(document.all)&&(Q9=function(e){if((Gae||!e)&&(typeof e>"u"||typeof e=="object"))try{var r=Fv.call(e);return(r===zae||r===jae||r===Hae||r===$ae)&&e("")==null}catch{}return!1})}var Kae=Rh?function(e){if(Q9(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;try{Rh(e,null,J9)}catch(r){if(r!==$v)return!1}return!Z9(e)&&X3(e)}:function(e){if(Q9(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;if(qae)return X3(e);if(Z9(e))return!1;var r=Fv.call(e);return r!==Fae&&r!==Uae&&!/^\[object HTML/.test(r)?!1:X3(e)},Wae=Kae,Jae=Object.prototype.toString,PF=Object.prototype.hasOwnProperty,Zae=function(e,r,n){for(var s=0,i=e.length;s=3&&(s=n),Jae.call(e)==="[object Array]"?Zae(e,r,s):typeof e=="string"?Qae(e,r,s):Yae(e,r,s)},efe=Xae,e8=["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],tfe=typeof globalThis>"u"?Ke:globalThis,rfe=function(){for(var e=[],r=0;r3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new eh("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new eh("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new eh("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new eh("`loose`, if provided, must be a boolean");var s=arguments.length>3?arguments[3]:null,i=arguments.length>4?arguments[4]:null,o=arguments.length>5?arguments[5]:null,f=arguments.length>6?arguments[6]:!1,h=!!sT&&sT(e,r);if(Nm)Nm(e,r,{configurable:o===null&&h?h.configurable:!o,enumerable:s===null&&h?h.enumerable:!s,value:n,writable:i===null&&h?h.writable:!i});else if(f||!s&&!i&&!o)e[r]=n;else throw new mfe("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},TF=Fc,oT=gfe,yfe=IF(),aT=NM,fT=TF("%TypeError%"),bfe=TF("%Math.floor%"),vfe=function(e,r){if(typeof e!="function")throw new fT("`fn` is not a function");if(typeof r!="number"||r<0||r>4294967295||bfe(r)!==r)throw new fT("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],s=!0,i=!0;if("length"in e&&aT){var o=aT(e,"length");o&&!o.configurable&&(s=!1),o&&!o.writable&&(i=!1)}return(s||i||!n)&&(yfe?oT(e,"length",r,!0,!0):oT(e,"length",r)),e};(function(t){var e=lfe,r=Fc,n=vfe,s=r("%TypeError%"),i=r("%Function.prototype.apply%"),o=r("%Function.prototype.call%"),f=r("%Reflect.apply%",!0)||e.call(o,i),h=r("%Object.defineProperty%",!0),p=r("%Math.max%");if(h)try{h({},"a",{value:1})}catch{h=null}t.exports=function(E){if(typeof E!="function")throw new s("a function is required");var _=f(e,o,arguments);return n(_,1+p(0,E.length-(arguments.length-1)),!0)};var b=function(){return f(e,i,arguments)};h?h(t.exports,"apply",{value:b}):t.exports.apply=b})(CF);var kF=CF.exports,RF=Fc,BF=kF,xfe=BF(RF("String.prototype.indexOf")),wfe=function(e,r){var n=RF(e,!!r);return typeof n=="function"&&xfe(e,".prototype.")>-1?BF(n):n},n6=efe,Afe=rfe,cT=kF,DM=wfe,zv=NM,Efe=DM("Object.prototype.toString"),OF=BM(),uT=typeof globalThis>"u"?Ke:globalThis,e7=Afe(),$M=DM("String.prototype.slice"),t8=Object.getPrototypeOf,Mfe=DM("Array.prototype.indexOf",!0)||function(e,r){for(var n=0;n-1?r:r!=="Object"?!1:_fe(e)}return zv?Sfe(e):null},Pfe=NF,Cfe=function(e){return!!Pfe(e)};(function(t){var e=kae,r=Lae,n=NF,s=Cfe;function i(oe){return oe.call.bind(oe)}var o=typeof BigInt<"u",f=typeof Symbol<"u",h=i(Object.prototype.toString),p=i(Number.prototype.valueOf),b=i(String.prototype.valueOf),v=i(Boolean.prototype.valueOf);if(o)var E=i(BigInt.prototype.valueOf);if(f)var _=i(Symbol.prototype.valueOf);function S(oe,Qe){if(typeof oe!="object")return!1;try{return Qe(oe),!0}catch{return!1}}t.isArgumentsObject=e,t.isGeneratorFunction=r,t.isTypedArray=s;function P(oe){return typeof Promise<"u"&&oe instanceof Promise||oe!==null&&typeof oe=="object"&&typeof oe.then=="function"&&typeof oe.catch=="function"}t.isPromise=P;function I(oe){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(oe):s(oe)||R(oe)}t.isArrayBufferView=I;function C(oe){return n(oe)==="Uint8Array"}t.isUint8Array=C;function T(oe){return n(oe)==="Uint8ClampedArray"}t.isUint8ClampedArray=T;function B(oe){return n(oe)==="Uint16Array"}t.isUint16Array=B;function N(oe){return n(oe)==="Uint32Array"}t.isUint32Array=N;function $(oe){return n(oe)==="Int8Array"}t.isInt8Array=$;function H(oe){return n(oe)==="Int16Array"}t.isInt16Array=H;function J(oe){return n(oe)==="Int32Array"}t.isInt32Array=J;function Q(oe){return n(oe)==="Float32Array"}t.isFloat32Array=Q;function K(oe){return n(oe)==="Float64Array"}t.isFloat64Array=K;function se(oe){return n(oe)==="BigInt64Array"}t.isBigInt64Array=se;function w(oe){return n(oe)==="BigUint64Array"}t.isBigUint64Array=w;function a(oe){return h(oe)==="[object Map]"}a.working=typeof Map<"u"&&a(new Map);function u(oe){return typeof Map>"u"?!1:a.working?a(oe):oe instanceof Map}t.isMap=u;function l(oe){return h(oe)==="[object Set]"}l.working=typeof Set<"u"&&l(new Set);function d(oe){return typeof Set>"u"?!1:l.working?l(oe):oe instanceof Set}t.isSet=d;function m(oe){return h(oe)==="[object WeakMap]"}m.working=typeof WeakMap<"u"&&m(new WeakMap);function x(oe){return typeof WeakMap>"u"?!1:m.working?m(oe):oe instanceof WeakMap}t.isWeakMap=x;function A(oe){return h(oe)==="[object WeakSet]"}A.working=typeof WeakSet<"u"&&A(new WeakSet);function y(oe){return A(oe)}t.isWeakSet=y;function c(oe){return h(oe)==="[object ArrayBuffer]"}c.working=typeof ArrayBuffer<"u"&&c(new ArrayBuffer);function g(oe){return typeof ArrayBuffer>"u"?!1:c.working?c(oe):oe instanceof ArrayBuffer}t.isArrayBuffer=g;function M(oe){return h(oe)==="[object DataView]"}M.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&M(new DataView(new ArrayBuffer(1),0,1));function R(oe){return typeof DataView>"u"?!1:M.working?M(oe):oe instanceof DataView}t.isDataView=R;var L=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function k(oe){return h(oe)==="[object SharedArrayBuffer]"}function D(oe){return typeof L>"u"?!1:(typeof k.working>"u"&&(k.working=k(new L)),k.working?k(oe):oe instanceof L)}t.isSharedArrayBuffer=D;function U(oe){return h(oe)==="[object AsyncFunction]"}t.isAsyncFunction=U;function V(oe){return h(oe)==="[object Map Iterator]"}t.isMapIterator=V;function G(oe){return h(oe)==="[object Set Iterator]"}t.isSetIterator=G;function Y(oe){return h(oe)==="[object Generator]"}t.isGeneratorObject=Y;function q(oe){return h(oe)==="[object WebAssembly.Module]"}t.isWebAssemblyCompiledModule=q;function z(oe){return S(oe,p)}t.isNumberObject=z;function ee(oe){return S(oe,b)}t.isStringObject=ee;function re(oe){return S(oe,v)}t.isBooleanObject=re;function ie(oe){return o&&S(oe,E)}t.isBigIntObject=ie;function ae(oe){return f&&S(oe,_)}t.isSymbolObject=ae;function je(oe){return z(oe)||ee(oe)||re(oe)||ie(oe)||ae(oe)}t.isBoxedPrimitive=je;function he(oe){return typeof Uint8Array<"u"&&(g(oe)||D(oe))}t.isAnyArrayBuffer=he,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(oe){Object.defineProperty(t,oe,{enumerable:!1,value:function(){throw new Error(oe+" is not supported in userland")}})})})(bF);var Ife=function(e){return e&&typeof e=="object"&&typeof e.copy=="function"&&typeof e.fill=="function"&&typeof e.readUInt8=="function"};(function(t){var e=Object.getOwnPropertyDescriptors||function(R){for(var L=Object.keys(R),k={},D=0;D=D)return G;switch(G){case"%s":return String(k[L++]);case"%d":return Number(k[L++]);case"%j":try{return JSON.stringify(k[L++])}catch{return"[Circular]"}default:return G}}),V=k[L];L"u")return function(){return t.deprecate(M,R).apply(this,arguments)};var L=!1;function k(){if(!L){if(Ve.process.throwDeprecation)throw new Error(R);Ve.process.traceDeprecation?console.trace(R):console.error(R),L=!0}return M.apply(this,arguments)}return k};var n={},s=/^$/;if({}.NODE_DEBUG){var i={}.NODE_DEBUG;i=i.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),s=new RegExp("^"+i+"$","i")}t.debuglog=function(M){if(M=M.toUpperCase(),!n[M])if(s.test(M)){var R=Ve.process.pid;n[M]=function(){var L=t.format.apply(t,arguments);console.error("%s %d: %s",M,R,L)}}else n[M]=function(){};return n[M]};function o(M,R){var L={seen:[],stylize:h};return arguments.length>=3&&(L.depth=arguments[2]),arguments.length>=4&&(L.colors=arguments[3]),C(R)?L.showHidden=R:R&&t._extend(L,R),J(L.showHidden)&&(L.showHidden=!1),J(L.depth)&&(L.depth=2),J(L.colors)&&(L.colors=!1),J(L.customInspect)&&(L.customInspect=!0),L.colors&&(L.stylize=f),b(L,M,L.depth)}t.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function f(M,R){var L=o.styles[R];return L?"\x1B["+o.colors[L][0]+"m"+M+"\x1B["+o.colors[L][1]+"m":M}function h(M,R){return M}function p(M){var R={};return M.forEach(function(L,k){R[L]=!0}),R}function b(M,R,L){if(M.customInspect&&R&&a(R.inspect)&&R.inspect!==t.inspect&&!(R.constructor&&R.constructor.prototype===R)){var k=R.inspect(L,M);return $(k)||(k=b(M,k,L)),k}var D=v(M,R);if(D)return D;var U=Object.keys(R),V=p(U);if(M.showHidden&&(U=Object.getOwnPropertyNames(R)),w(R)&&(U.indexOf("message")>=0||U.indexOf("description")>=0))return E(R);if(U.length===0){if(a(R)){var G=R.name?": "+R.name:"";return M.stylize("[Function"+G+"]","special")}if(Q(R))return M.stylize(RegExp.prototype.toString.call(R),"regexp");if(se(R))return M.stylize(Date.prototype.toString.call(R),"date");if(w(R))return E(R)}var Y="",q=!1,z=["{","}"];if(I(R)&&(q=!0,z=["[","]"]),a(R)){var ee=R.name?": "+R.name:"";Y=" [Function"+ee+"]"}if(Q(R)&&(Y=" "+RegExp.prototype.toString.call(R)),se(R)&&(Y=" "+Date.prototype.toUTCString.call(R)),w(R)&&(Y=" "+E(R)),U.length===0&&(!q||R.length==0))return z[0]+Y+z[1];if(L<0)return Q(R)?M.stylize(RegExp.prototype.toString.call(R),"regexp"):M.stylize("[Object]","special");M.seen.push(R);var re;return q?re=_(M,R,L,V,U):re=U.map(function(ie){return S(M,R,L,V,ie,q)}),M.seen.pop(),P(re,Y,z)}function v(M,R){if(J(R))return M.stylize("undefined","undefined");if($(R)){var L="'"+JSON.stringify(R).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return M.stylize(L,"string")}if(N(R))return M.stylize(""+R,"number");if(C(R))return M.stylize(""+R,"boolean");if(T(R))return M.stylize("null","null")}function E(M){return"["+Error.prototype.toString.call(M)+"]"}function _(M,R,L,k,D){for(var U=[],V=0,G=R.length;V-1&&(U?G=G.split(` -`).map(function(q){return" "+q}).join(` -`).slice(2):G=` -`+G.split(` -`).map(function(q){return" "+q}).join(` -`))):G=M.stylize("[Circular]","special")),J(V)){if(U&&D.match(/^\d+$/))return G;V=JSON.stringify(""+D),V.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(V=V.slice(1,-1),V=M.stylize(V,"name")):(V=V.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),V=M.stylize(V,"string"))}return V+": "+G}function P(M,R,L){var k=M.reduce(function(D,U){return U.indexOf(` -`)>=0,D+U.replace(/\u001b\[\d\d?m/g,"").length+1},0);return k>60?L[0]+(R===""?"":R+` - `)+" "+M.join(`, - `)+" "+L[1]:L[0]+R+" "+M.join(", ")+" "+L[1]}t.types=bF;function I(M){return Array.isArray(M)}t.isArray=I;function C(M){return typeof M=="boolean"}t.isBoolean=C;function T(M){return M===null}t.isNull=T;function B(M){return M==null}t.isNullOrUndefined=B;function N(M){return typeof M=="number"}t.isNumber=N;function $(M){return typeof M=="string"}t.isString=$;function H(M){return typeof M=="symbol"}t.isSymbol=H;function J(M){return M===void 0}t.isUndefined=J;function Q(M){return K(M)&&l(M)==="[object RegExp]"}t.isRegExp=Q,t.types.isRegExp=Q;function K(M){return typeof M=="object"&&M!==null}t.isObject=K;function se(M){return K(M)&&l(M)==="[object Date]"}t.isDate=se,t.types.isDate=se;function w(M){return K(M)&&(l(M)==="[object Error]"||M instanceof Error)}t.isError=w,t.types.isNativeError=w;function a(M){return typeof M=="function"}t.isFunction=a;function u(M){return M===null||typeof M=="boolean"||typeof M=="number"||typeof M=="string"||typeof M=="symbol"||typeof M>"u"}t.isPrimitive=u,t.isBuffer=Ife;function l(M){return Object.prototype.toString.call(M)}function d(M){return M<10?"0"+M.toString(10):M.toString(10)}var m=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function x(){var M=new Date,R=[d(M.getHours()),d(M.getMinutes()),d(M.getSeconds())].join(":");return[M.getDate(),m[M.getMonth()],R].join(" ")}t.log=function(){console.log("%s - %s",x(),t.format.apply(t,arguments))},t.inherits=It,t._extend=function(M,R){if(!R||!K(R))return M;for(var L=Object.keys(R),k=L.length;k--;)M[L[k]]=R[L[k]];return M};function A(M,R){return Object.prototype.hasOwnProperty.call(M,R)}var y=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;t.promisify=function(R){if(typeof R!="function")throw new TypeError('The "original" argument must be of type Function');if(y&&R[y]){var L=R[y];if(typeof L!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(L,y,{value:L,enumerable:!1,writable:!1,configurable:!0}),L}function L(){for(var k,D,U=new Promise(function(Y,q){k=Y,D=q}),V=[],G=0;G0?this.tail.next=C:this.head=C,this.tail=C,++this.length}},{key:"unshift",value:function(I){var C={data:I,next:this.head};this.length===0&&(this.tail=C),this.head=C,++this.length}},{key:"shift",value:function(){if(this.length!==0){var I=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,I}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(I){if(this.length===0)return"";for(var C=this.head,T=""+C.data;C=C.next;)T+=I+C.data;return T}},{key:"concat",value:function(I){if(this.length===0)return p.alloc(0);for(var C=p.allocUnsafe(I>>>0),T=this.head,B=0;T;)_(T.data,C,B),B+=T.data.length,T=T.next;return C}},{key:"consume",value:function(I,C){var T;return IN.length?N.length:I;if($===N.length?B+=N:B+=N.slice(0,I),I-=$,I===0){$===N.length?(++T,C.next?this.head=C.next:this.head=this.tail=null):(this.head=C,C.data=N.slice($));break}++T}return this.length-=T,B}},{key:"_getBuffer",value:function(I){var C=p.allocUnsafe(I),T=this.head,B=1;for(T.data.copy(C),I-=T.data.length;T=T.next;){var N=T.data,$=I>N.length?N.length:I;if(N.copy(C,C.length-I,0,$),I-=$,I===0){$===N.length?(++B,T.next?this.head=T.next:this.head=this.tail=null):(this.head=T,T.data=N.slice($));break}++B}return this.length-=B,C}},{key:E,value:function(I,C){return v(this,e(e({},C),{},{depth:0,customInspect:!1}))}}]),S}(),r8}function kfe(t,e){var r=this,n=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return n||s?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,Ve.process.nextTick(t7,this,t)):Ve.process.nextTick(t7,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(i){!e&&i?r._writableState?r._writableState.errorEmitted?Ve.process.nextTick(jv,r):(r._writableState.errorEmitted=!0,Ve.process.nextTick(hT,r,i)):Ve.process.nextTick(hT,r,i):e?(Ve.process.nextTick(jv,r),e(i)):Ve.process.nextTick(jv,r)}),this)}function hT(t,e){t7(t,e),jv(t)}function jv(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function Rfe(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function t7(t,e){t.emit("error",e)}function Bfe(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}var LF={destroy:kfe,undestroy:Rfe,errorOrDestroy:Bfe},Il={};function Ofe(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var DF={};function to(t,e,r){r||(r=Error);function n(i,o,f){return typeof e=="string"?e:e(i,o,f)}var s=function(i){Ofe(o,i);function o(f,h,p){return i.call(this,n(f,h,p))||this}return o}(r);s.prototype.name=r.name,s.prototype.code=t,DF[t]=s}function dT(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(n){return String(n)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:r===2?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}else return"of ".concat(e," ").concat(String(t))}function Nfe(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function Lfe(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function Dfe(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}to("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);to("ERR_INVALID_ARG_TYPE",function(t,e,r){var n;typeof e=="string"&&Nfe(e,"not ")?(n="must not be",e=e.replace(/^not /,"")):n="must be";var s;if(Lfe(t," argument"))s="The ".concat(t," ").concat(n," ").concat(dT(e,"type"));else{var i=Dfe(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(i," ").concat(n," ").concat(dT(e,"type"))}return s+=". Received type ".concat(typeof r),s},TypeError);to("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");to("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});to("ERR_STREAM_PREMATURE_CLOSE","Premature close");to("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});to("ERR_MULTIPLE_CALLBACK","Callback called multiple times");to("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");to("ERR_STREAM_WRITE_AFTER_END","write after end");to("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);to("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);to("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Il.codes=DF;var $fe=Il.codes.ERR_INVALID_OPT_VALUE;function Ffe(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function Ufe(t,e,r,n){var s=Ffe(e,n,r);if(s!=null){if(!(isFinite(s)&&Math.floor(s)===s)||s<0){var i=n?r:"highWaterMark";throw new $fe(i,s)}return Math.floor(s)}return t.objectMode?16:16*1024}var $F={getHighWaterMark:Ufe},zfe=jfe;function jfe(t,e){if(n8("noDeprecation"))return t;var r=!1;function n(){if(!r){if(n8("throwDeprecation"))throw new Error(e);n8("traceDeprecation")?console.trace(e):console.warn(e),r=!0}return t.apply(this,arguments)}return n}function n8(t){try{if(!Ke.localStorage)return!1}catch{return!1}var e=Ke.localStorage[t];return e==null?!1:String(e).toLowerCase()==="true"}var i8,pT;function FM(){if(pT)return i8;pT=1,i8=Q;function t(D){var U=this;this.next=null,this.entry=null,this.finish=function(){k(U,D)}}var e;Q.WritableState=H;var r={deprecate:zfe},n=yF,s=Ln.Buffer,i=(typeof Ke<"u"?Ke:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function o(D){return s.from(D)}function f(D){return s.isBuffer(D)||D instanceof i}var h=LF,p=$F,b=p.getHighWaterMark,v=Il.codes,E=v.ERR_INVALID_ARG_TYPE,_=v.ERR_METHOD_NOT_IMPLEMENTED,S=v.ERR_MULTIPLE_CALLBACK,P=v.ERR_STREAM_CANNOT_PIPE,I=v.ERR_STREAM_DESTROYED,C=v.ERR_STREAM_NULL_VALUES,T=v.ERR_STREAM_WRITE_AFTER_END,B=v.ERR_UNKNOWN_ENCODING,N=h.errorOrDestroy;It(Q,n);function $(){}function H(D,U,V){e=e||ol(),D=D||{},typeof V!="boolean"&&(V=U instanceof e),this.objectMode=!!D.objectMode,V&&(this.objectMode=this.objectMode||!!D.writableObjectMode),this.highWaterMark=b(this,D,"writableHighWaterMark",V),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var G=D.decodeStrings===!1;this.decodeStrings=!G,this.defaultEncoding=D.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Y){m(U,Y)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=D.emitClose!==!1,this.autoDestroy=!!D.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}H.prototype.getBuffer=function(){for(var U=this.bufferedRequest,V=[];U;)V.push(U),U=U.next;return V},function(){try{Object.defineProperty(H.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var J;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(J=Function.prototype[Symbol.hasInstance],Object.defineProperty(Q,Symbol.hasInstance,{value:function(U){return J.call(this,U)?!0:this!==Q?!1:U&&U._writableState instanceof H}})):J=function(U){return U instanceof this};function Q(D){e=e||ol();var U=this instanceof e;if(!U&&!J.call(Q,this))return new Q(D);this._writableState=new H(D,this,U),this.writable=!0,D&&(typeof D.write=="function"&&(this._write=D.write),typeof D.writev=="function"&&(this._writev=D.writev),typeof D.destroy=="function"&&(this._destroy=D.destroy),typeof D.final=="function"&&(this._final=D.final)),n.call(this)}Q.prototype.pipe=function(){N(this,new P)};function K(D,U){var V=new T;N(D,V),Ve.process.nextTick(U,V)}function se(D,U,V,G){var Y;return V===null?Y=new C:typeof V!="string"&&!U.objectMode&&(Y=new E("chunk",["string","Buffer"],V)),Y?(N(D,Y),Ve.process.nextTick(G,Y),!1):!0}Q.prototype.write=function(D,U,V){var G=this._writableState,Y=!1,q=!G.objectMode&&f(D);return q&&!s.isBuffer(D)&&(D=o(D)),typeof U=="function"&&(V=U,U=null),q?U="buffer":U||(U=G.defaultEncoding),typeof V!="function"&&(V=$),G.ending?K(this,V):(q||se(this,G,D,V))&&(G.pendingcb++,Y=a(this,G,q,D,U,V)),Y},Q.prototype.cork=function(){this._writableState.corked++},Q.prototype.uncork=function(){var D=this._writableState;D.corked&&(D.corked--,!D.writing&&!D.corked&&!D.bufferProcessing&&D.bufferedRequest&&y(this,D))},Q.prototype.setDefaultEncoding=function(U){if(typeof U=="string"&&(U=U.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((U+"").toLowerCase())>-1))throw new B(U);return this._writableState.defaultEncoding=U,this},Object.defineProperty(Q.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function w(D,U,V){return!D.objectMode&&D.decodeStrings!==!1&&typeof U=="string"&&(U=s.from(U,V)),U}Object.defineProperty(Q.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function a(D,U,V,G,Y,q){if(!V){var z=w(U,G,Y);G!==z&&(V=!0,Y="buffer",G=z)}var ee=U.objectMode?1:G.length;U.length+=ee;var re=U.length>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function Gfe(t,e,r){var n=e.length-1;if(n=0?(s>0&&(t.lastNeed=s-1),s):--n=0?(s>0&&(t.lastNeed=s-2),s):--n=0?(s>0&&(s===2?s=0:t.lastNeed=s-3),s):0))}function Vfe(t,e,r){if((e[0]&192)!==128)return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!==128)return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!==128)return t.lastNeed=2,"�"}}function Kfe(t){var e=this.lastTotal-this.lastNeed,r=Vfe(this,t);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function Wfe(t,e){var r=Gfe(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)}function Jfe(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e}function Zfe(t,e){if((t.length-e)%2===0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function Qfe(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function Yfe(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function Xfe(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function e0e(t){return t.toString(this.encoding)}function t0e(t){return t&&t.length?this.write(t):""}var yT=Il.codes.ERR_STREAM_PREMATURE_CLOSE;function r0e(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,n=new Array(r),s=0;s0)if(typeof z!="string"&&!ae.objectMode&&Object.getPrototypeOf(z)!==n.prototype&&(z=i(z)),re)ae.endEmitted?$(q,new C):w(q,ae,z,!0);else if(ae.ended)$(q,new P);else{if(ae.destroyed)return!1;ae.reading=!1,ae.decoder&&!ee?(z=ae.decoder.write(z),ae.objectMode||z.length!==0?w(q,ae,z,!1):y(q,ae)):w(q,ae,z,!1)}else re||(ae.reading=!1,y(q,ae))}return!ae.ended&&(ae.length=u?q=u:(q--,q|=q>>>1,q|=q>>>2,q|=q>>>4,q|=q>>>8,q|=q>>>16,q++),q}function d(q,z){return q<=0||z.length===0&&z.ended?0:z.objectMode?1:q!==q?z.flowing&&z.length?z.buffer.head.data.length:z.length:(q>z.highWaterMark&&(z.highWaterMark=l(q)),q<=z.length?q:z.ended?z.length:(z.needReadable=!0,0))}K.prototype.read=function(q){h("read",q),q=parseInt(q,10);var z=this._readableState,ee=q;if(q!==0&&(z.emittedReadable=!1),q===0&&z.needReadable&&((z.highWaterMark!==0?z.length>=z.highWaterMark:z.length>0)||z.ended))return h("read: emitReadable",z.length,z.ended),z.length===0&&z.ended?V(this):x(this),null;if(q=d(q,z),q===0&&z.ended)return z.length===0&&V(this),null;var re=z.needReadable;h("need readable",re),(z.length===0||z.length-q0?ie=U(q,z):ie=null,ie===null?(z.needReadable=z.length<=z.highWaterMark,q=0):(z.length-=q,z.awaitDrain=0),z.length===0&&(z.ended||(z.needReadable=!0),ee!==q&&z.ended&&V(this)),ie!==null&&this.emit("data",ie),ie};function m(q,z){if(h("onEofChunk"),!z.ended){if(z.decoder){var ee=z.decoder.end();ee&&ee.length&&(z.buffer.push(ee),z.length+=z.objectMode?1:ee.length)}z.ended=!0,z.sync?x(q):(z.needReadable=!1,z.emittedReadable||(z.emittedReadable=!0,A(q)))}}function x(q){var z=q._readableState;h("emitReadable",z.needReadable,z.emittedReadable),z.needReadable=!1,z.emittedReadable||(h("emitReadable",z.flowing),z.emittedReadable=!0,Ve.process.nextTick(A,q))}function A(q){var z=q._readableState;h("emitReadable_",z.destroyed,z.length,z.ended),!z.destroyed&&(z.length||z.ended)&&(q.emit("readable"),z.emittedReadable=!1),z.needReadable=!z.flowing&&!z.ended&&z.length<=z.highWaterMark,D(q)}function y(q,z){z.readingMore||(z.readingMore=!0,Ve.process.nextTick(c,q,z))}function c(q,z){for(;!z.reading&&!z.ended&&(z.length1&&Y(re.pipes,q)!==-1)&&!Qe&&(h("false write response, pause",re.awaitDrain),re.awaitDrain++),ee.pause())}function ot(j){h("onerror",j),at(),q.removeListener("error",ot),e(q,"error")===0&&$(q,j)}J(q,"error",ot);function ye(){q.removeListener("finish",xe),at()}q.once("close",ye);function xe(){h("onfinish"),q.removeListener("close",ye),at()}q.once("finish",xe);function at(){h("unpipe"),ee.unpipe(q)}return q.emit("pipe",ee),re.flowing||(h("pipe resume"),ee.resume()),q};function g(q){return function(){var ee=q._readableState;h("pipeOnDrain",ee.awaitDrain),ee.awaitDrain&&ee.awaitDrain--,ee.awaitDrain===0&&e(q,"data")&&(ee.flowing=!0,D(q))}}K.prototype.unpipe=function(q){var z=this._readableState,ee={hasUnpiped:!1};if(z.pipesCount===0)return this;if(z.pipesCount===1)return q&&q!==z.pipes?this:(q||(q=z.pipes),z.pipes=null,z.pipesCount=0,z.flowing=!1,q&&q.emit("unpipe",this,ee),this);if(!q){var re=z.pipes,ie=z.pipesCount;z.pipes=null,z.pipesCount=0,z.flowing=!1;for(var ae=0;ae0,re.flowing!==!1&&this.resume()):q==="readable"&&!re.endEmitted&&!re.readableListening&&(re.readableListening=re.needReadable=!0,re.flowing=!1,re.emittedReadable=!1,h("on readable",re.length,re.reading),re.length?x(this):re.reading||Ve.process.nextTick(R,this)),ee},K.prototype.addListener=K.prototype.on,K.prototype.removeListener=function(q,z){var ee=r.prototype.removeListener.call(this,q,z);return q==="readable"&&Ve.process.nextTick(M,this),ee},K.prototype.removeAllListeners=function(q){var z=r.prototype.removeAllListeners.apply(this,arguments);return(q==="readable"||q===void 0)&&Ve.process.nextTick(M,this),z};function M(q){var z=q._readableState;z.readableListening=q.listenerCount("readable")>0,z.resumeScheduled&&!z.paused?z.flowing=!0:q.listenerCount("data")>0&&q.resume()}function R(q){h("readable nexttick read 0"),q.read(0)}K.prototype.resume=function(){var q=this._readableState;return q.flowing||(h("resume"),q.flowing=!q.readableListening,L(this,q)),q.paused=!1,this};function L(q,z){z.resumeScheduled||(z.resumeScheduled=!0,Ve.process.nextTick(k,q,z))}function k(q,z){h("resume",z.reading),z.reading||q.read(0),z.resumeScheduled=!1,q.emit("resume"),D(q),z.flowing&&!z.reading&&q.read(0)}K.prototype.pause=function(){return h("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(h("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function D(q){var z=q._readableState;for(h("flow",z.flowing);z.flowing&&q.read()!==null;);}K.prototype.wrap=function(q){var z=this,ee=this._readableState,re=!1;q.on("end",function(){if(h("wrapped end"),ee.decoder&&!ee.ended){var je=ee.decoder.end();je&&je.length&&z.push(je)}z.push(null)}),q.on("data",function(je){if(h("wrapped data"),ee.decoder&&(je=ee.decoder.write(je)),!(ee.objectMode&&je==null)&&!(!ee.objectMode&&(!je||!je.length))){var he=z.push(je);he||(re=!0,q.pause())}});for(var ie in q)this[ie]===void 0&&typeof q[ie]=="function"&&(this[ie]=function(he){return function(){return q[he].apply(q,arguments)}}(ie));for(var ae=0;ae=z.length?(z.decoder?ee=z.buffer.join(""):z.buffer.length===1?ee=z.buffer.first():ee=z.buffer.concat(z.length),z.buffer.clear()):ee=z.buffer.consume(q,z.decoder),ee}function V(q){var z=q._readableState;h("endReadable",z.endEmitted),z.endEmitted||(z.ended=!0,Ve.process.nextTick(G,z,q))}function G(q,z){if(h("endReadableNT",q.endEmitted,q.length),!q.endEmitted&&q.length===0&&(q.endEmitted=!0,z.readable=!1,z.emit("end"),q.autoDestroy)){var ee=z._writableState;(!ee||ee.autoDestroy&&ee.finished)&&z.destroy()}}typeof Symbol=="function"&&(K.from=function(q,z){return N===void 0&&(N=o0e()),N(K,q,z)});function Y(q,z){for(var ee=0,re=q.length;ee0;return y0e(o,h,p,function(b){s||(s=b),b&&i.forEach(ET),!h&&(i.forEach(ET),n(s))})});return e.reduce(b0e)}var HF=x0e;(function(t,e){e=t.exports=zM(),e.Stream=e,e.Readable=e,e.Writable=FM(),e.Duplex=ol(),e.Transform=jM,e.PassThrough=UF,e.finished=mx,e.pipeline=HF})(K9,K9.exports);var qF=K9.exports,o6=Tt.Buffer,GF=qF.Transform,w0e=It;function A0e(t,e){if(!o6.isBuffer(t)&&typeof t!="string")throw new TypeError(e+" must be a string or a buffer")}function Uc(t){GF.call(this),this._block=o6.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}w0e(Uc,GF);Uc.prototype._transform=function(t,e,r){var n=null;try{this.update(t,e)}catch(s){n=s}r(n)};Uc.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(r){e=r}t(e)};Uc.prototype.update=function(t,e){if(A0e(t,"Data"),this._finalized)throw new Error("Digest already called");o6.isBuffer(t)||(t=o6.from(t,e));for(var r=this._block,n=0;this._blockOffset+t.length-n>=this._blockSize;){for(var s=this._blockOffset;s0;++i)this._length[i]+=o,o=this._length[i]/4294967296|0,o>0&&(this._length[i]-=4294967296*o);return this};Uc.prototype._update=function(){throw new Error("_update is not implemented")};Uc.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();t!==void 0&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return e};Uc.prototype._digest=function(){throw new Error("_digest is not implemented")};var VF=Uc,E0e=It,KF=VF,M0e=Tt.Buffer,S0e=new Array(16);function bx(){KF.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}E0e(bx,KF);bx.prototype._update=function(){for(var t=S0e,e=0;e<16;++e)t[e]=this._block.readInt32LE(e*4);var r=this._a,n=this._b,s=this._c,i=this._d;r=zn(r,n,s,i,t[0],3614090360,7),i=zn(i,r,n,s,t[1],3905402710,12),s=zn(s,i,r,n,t[2],606105819,17),n=zn(n,s,i,r,t[3],3250441966,22),r=zn(r,n,s,i,t[4],4118548399,7),i=zn(i,r,n,s,t[5],1200080426,12),s=zn(s,i,r,n,t[6],2821735955,17),n=zn(n,s,i,r,t[7],4249261313,22),r=zn(r,n,s,i,t[8],1770035416,7),i=zn(i,r,n,s,t[9],2336552879,12),s=zn(s,i,r,n,t[10],4294925233,17),n=zn(n,s,i,r,t[11],2304563134,22),r=zn(r,n,s,i,t[12],1804603682,7),i=zn(i,r,n,s,t[13],4254626195,12),s=zn(s,i,r,n,t[14],2792965006,17),n=zn(n,s,i,r,t[15],1236535329,22),r=jn(r,n,s,i,t[1],4129170786,5),i=jn(i,r,n,s,t[6],3225465664,9),s=jn(s,i,r,n,t[11],643717713,14),n=jn(n,s,i,r,t[0],3921069994,20),r=jn(r,n,s,i,t[5],3593408605,5),i=jn(i,r,n,s,t[10],38016083,9),s=jn(s,i,r,n,t[15],3634488961,14),n=jn(n,s,i,r,t[4],3889429448,20),r=jn(r,n,s,i,t[9],568446438,5),i=jn(i,r,n,s,t[14],3275163606,9),s=jn(s,i,r,n,t[3],4107603335,14),n=jn(n,s,i,r,t[8],1163531501,20),r=jn(r,n,s,i,t[13],2850285829,5),i=jn(i,r,n,s,t[2],4243563512,9),s=jn(s,i,r,n,t[7],1735328473,14),n=jn(n,s,i,r,t[12],2368359562,20),r=Hn(r,n,s,i,t[5],4294588738,4),i=Hn(i,r,n,s,t[8],2272392833,11),s=Hn(s,i,r,n,t[11],1839030562,16),n=Hn(n,s,i,r,t[14],4259657740,23),r=Hn(r,n,s,i,t[1],2763975236,4),i=Hn(i,r,n,s,t[4],1272893353,11),s=Hn(s,i,r,n,t[7],4139469664,16),n=Hn(n,s,i,r,t[10],3200236656,23),r=Hn(r,n,s,i,t[13],681279174,4),i=Hn(i,r,n,s,t[0],3936430074,11),s=Hn(s,i,r,n,t[3],3572445317,16),n=Hn(n,s,i,r,t[6],76029189,23),r=Hn(r,n,s,i,t[9],3654602809,4),i=Hn(i,r,n,s,t[12],3873151461,11),s=Hn(s,i,r,n,t[15],530742520,16),n=Hn(n,s,i,r,t[2],3299628645,23),r=qn(r,n,s,i,t[0],4096336452,6),i=qn(i,r,n,s,t[7],1126891415,10),s=qn(s,i,r,n,t[14],2878612391,15),n=qn(n,s,i,r,t[5],4237533241,21),r=qn(r,n,s,i,t[12],1700485571,6),i=qn(i,r,n,s,t[3],2399980690,10),s=qn(s,i,r,n,t[10],4293915773,15),n=qn(n,s,i,r,t[1],2240044497,21),r=qn(r,n,s,i,t[8],1873313359,6),i=qn(i,r,n,s,t[15],4264355552,10),s=qn(s,i,r,n,t[6],2734768916,15),n=qn(n,s,i,r,t[13],1309151649,21),r=qn(r,n,s,i,t[4],4149444226,6),i=qn(i,r,n,s,t[11],3174756917,10),s=qn(s,i,r,n,t[2],718787259,15),n=qn(n,s,i,r,t[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+s|0,this._d=this._d+i|0};bx.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=M0e.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t};function vx(t,e){return t<>>32-e}function zn(t,e,r,n,s,i,o){return vx(t+(e&r|~e&n)+s+i|0,o)+e|0}function jn(t,e,r,n,s,i,o){return vx(t+(e&n|r&~n)+s+i|0,o)+e|0}function Hn(t,e,r,n,s,i,o){return vx(t+(e^r^n)+s+i|0,o)+e|0}function qn(t,e,r,n,s,i,o){return vx(t+(r^(e|~n))+s+i|0,o)+e|0}var HM=bx,l8=Ln.Buffer,_0e=It,WF=VF,P0e=new Array(16),V1=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],K1=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],W1=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],J1=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],Z1=[0,1518500249,1859775393,2400959708,2840853838],Q1=[1352829926,1548603684,1836072691,2053994217,0];function xx(){WF.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}_0e(xx,WF);xx.prototype._update=function(){for(var t=P0e,e=0;e<16;++e)t[e]=this._block.readInt32LE(e*4);for(var r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,f=this._a|0,h=this._b|0,p=this._c|0,b=this._d|0,v=this._e|0,E=0;E<80;E+=1){var _,S;E<16?(_=MT(r,n,s,i,o,t[V1[E]],Z1[0],W1[E]),S=CT(f,h,p,b,v,t[K1[E]],Q1[0],J1[E])):E<32?(_=ST(r,n,s,i,o,t[V1[E]],Z1[1],W1[E]),S=PT(f,h,p,b,v,t[K1[E]],Q1[1],J1[E])):E<48?(_=_T(r,n,s,i,o,t[V1[E]],Z1[2],W1[E]),S=_T(f,h,p,b,v,t[K1[E]],Q1[2],J1[E])):E<64?(_=PT(r,n,s,i,o,t[V1[E]],Z1[3],W1[E]),S=ST(f,h,p,b,v,t[K1[E]],Q1[3],J1[E])):(_=CT(r,n,s,i,o,t[V1[E]],Z1[4],W1[E]),S=MT(f,h,p,b,v,t[K1[E]],Q1[4],J1[E])),r=o,o=i,i=al(s,10),s=n,n=_,f=v,v=b,b=al(p,10),p=h,h=S}var P=this._b+s+b|0;this._b=this._c+i+v|0,this._c=this._d+o+f|0,this._d=this._e+r+h|0,this._e=this._a+n+p|0,this._a=P};xx.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=l8.alloc?l8.alloc(20):new l8(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t};function al(t,e){return t<>>32-e}function MT(t,e,r,n,s,i,o,f){return al(t+(e^r^n)+i+o|0,f)+s|0}function ST(t,e,r,n,s,i,o,f){return al(t+(e&r|~e&n)+i+o|0,f)+s|0}function _T(t,e,r,n,s,i,o,f){return al(t+((e|~r)^n)+i+o|0,f)+s|0}function PT(t,e,r,n,s,i,o,f){return al(t+(e&n|r&~n)+i+o|0,f)+s|0}function CT(t,e,r,n,s,i,o,f){return al(t+(e^(r|~n))+i+o|0,f)+s|0}var qM=xx,JF={exports:{}},ZF=Tt.Buffer;function wx(t,e){this._block=ZF.alloc(t),this._finalSize=e,this._blockSize=t,this._len=0}wx.prototype.update=function(t,e){typeof t=="string"&&(e=e||"utf8",t=ZF.from(t,e));for(var r=this._block,n=this._blockSize,s=t.length,i=this._len,o=0;o=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=this._len*8;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(r&4294967295)>>>0,s=(r-n)/4294967296;this._block.writeUInt32BE(s,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var i=this._hash();return t?i.toString(t):i};wx.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var c1=wx,C0e=It,QF=c1,I0e=Tt.Buffer,T0e=[1518500249,1859775393,-1894007588,-899497514],k0e=new Array(80);function Iy(){this.init(),this._w=k0e,QF.call(this,64,56)}C0e(Iy,QF);Iy.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function R0e(t){return t<<5|t>>>27}function B0e(t){return t<<30|t>>>2}function O0e(t,e,r,n){return t===0?e&r|~e&n:t===2?e&r|e&n|r&n:e^r^n}Iy.prototype._update=function(t){for(var e=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,f=0;f<16;++f)e[f]=t.readInt32BE(f*4);for(;f<80;++f)e[f]=e[f-3]^e[f-8]^e[f-14]^e[f-16];for(var h=0;h<80;++h){var p=~~(h/20),b=R0e(r)+O0e(p,n,s,i)+o+e[h]+T0e[p]|0;o=i,i=s,s=B0e(n),n=r,r=b}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};Iy.prototype._hash=function(){var t=I0e.allocUnsafe(20);return t.writeInt32BE(this._a|0,0),t.writeInt32BE(this._b|0,4),t.writeInt32BE(this._c|0,8),t.writeInt32BE(this._d|0,12),t.writeInt32BE(this._e|0,16),t};var N0e=Iy,L0e=It,YF=c1,D0e=Tt.Buffer,$0e=[1518500249,1859775393,-1894007588,-899497514],F0e=new Array(80);function Ty(){this.init(),this._w=F0e,YF.call(this,64,56)}L0e(Ty,YF);Ty.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function U0e(t){return t<<1|t>>>31}function z0e(t){return t<<5|t>>>27}function j0e(t){return t<<30|t>>>2}function H0e(t,e,r,n){return t===0?e&r|~e&n:t===2?e&r|e&n|r&n:e^r^n}Ty.prototype._update=function(t){for(var e=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,f=0;f<16;++f)e[f]=t.readInt32BE(f*4);for(;f<80;++f)e[f]=U0e(e[f-3]^e[f-8]^e[f-14]^e[f-16]);for(var h=0;h<80;++h){var p=~~(h/20),b=z0e(r)+H0e(p,n,s,i)+o+e[h]+$0e[p]|0;o=i,i=s,s=j0e(n),n=r,r=b}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};Ty.prototype._hash=function(){var t=D0e.allocUnsafe(20);return t.writeInt32BE(this._a|0,0),t.writeInt32BE(this._b|0,4),t.writeInt32BE(this._c|0,8),t.writeInt32BE(this._d|0,12),t.writeInt32BE(this._e|0,16),t};var q0e=Ty,G0e=It,XF=c1,V0e=Tt.Buffer,K0e=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],W0e=new Array(64);function ky(){this.init(),this._w=W0e,XF.call(this,64,56)}G0e(ky,XF);ky.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function J0e(t,e,r){return r^t&(e^r)}function Z0e(t,e,r){return t&e|r&(t|e)}function Q0e(t){return(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function Y0e(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function X0e(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}function ece(t){return(t>>>17|t<<15)^(t>>>19|t<<13)^t>>>10}ky.prototype._update=function(t){for(var e=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,f=this._f|0,h=this._g|0,p=this._h|0,b=0;b<16;++b)e[b]=t.readInt32BE(b*4);for(;b<64;++b)e[b]=ece(e[b-2])+e[b-7]+X0e(e[b-15])+e[b-16]|0;for(var v=0;v<64;++v){var E=p+Y0e(o)+J0e(o,f,h)+K0e[v]+e[v]|0,_=Q0e(r)+Z0e(r,n,s)|0;p=h,h=f,f=o,o=i+E|0,i=s,s=n,n=r,r=E+_|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0,this._f=f+this._f|0,this._g=h+this._g|0,this._h=p+this._h|0};ky.prototype._hash=function(){var t=V0e.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t};var eU=ky,tce=It,rce=eU,nce=c1,ice=Tt.Buffer,sce=new Array(64);function Ax(){this.init(),this._w=sce,nce.call(this,64,56)}tce(Ax,rce);Ax.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this};Ax.prototype._hash=function(){var t=ice.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t};var oce=Ax,ace=It,tU=c1,fce=Tt.Buffer,IT=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],cce=new Array(160);function Ry(){this.init(),this._w=cce,tU.call(this,128,112)}ace(Ry,tU);Ry.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function TT(t,e,r){return r^t&(e^r)}function kT(t,e,r){return t&e|r&(t|e)}function RT(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function BT(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function uce(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function lce(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function hce(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function dce(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function hn(t,e){return t>>>0>>0?1:0}Ry.prototype._update=function(t){for(var e=this._w,r=this._ah|0,n=this._bh|0,s=this._ch|0,i=this._dh|0,o=this._eh|0,f=this._fh|0,h=this._gh|0,p=this._hh|0,b=this._al|0,v=this._bl|0,E=this._cl|0,_=this._dl|0,S=this._el|0,P=this._fl|0,I=this._gl|0,C=this._hl|0,T=0;T<32;T+=2)e[T]=t.readInt32BE(T*4),e[T+1]=t.readInt32BE(T*4+4);for(;T<160;T+=2){var B=e[T-30],N=e[T-15*2+1],$=uce(B,N),H=lce(N,B);B=e[T-2*2],N=e[T-2*2+1];var J=hce(B,N),Q=dce(N,B),K=e[T-7*2],se=e[T-7*2+1],w=e[T-16*2],a=e[T-16*2+1],u=H+se|0,l=$+K+hn(u,H)|0;u=u+Q|0,l=l+J+hn(u,Q)|0,u=u+a|0,l=l+w+hn(u,a)|0,e[T]=l,e[T+1]=u}for(var d=0;d<160;d+=2){l=e[d],u=e[d+1];var m=kT(r,n,s),x=kT(b,v,E),A=RT(r,b),y=RT(b,r),c=BT(o,S),g=BT(S,o),M=IT[d],R=IT[d+1],L=TT(o,f,h),k=TT(S,P,I),D=C+g|0,U=p+c+hn(D,C)|0;D=D+k|0,U=U+L+hn(D,k)|0,D=D+R|0,U=U+M+hn(D,R)|0,D=D+u|0,U=U+l+hn(D,u)|0;var V=y+x|0,G=A+m+hn(V,y)|0;p=h,C=I,h=f,I=P,f=o,P=S,S=_+D|0,o=i+U+hn(S,_)|0,i=s,_=E,s=n,E=v,n=r,v=b,b=D+V|0,r=U+G+hn(b,D)|0}this._al=this._al+b|0,this._bl=this._bl+v|0,this._cl=this._cl+E|0,this._dl=this._dl+_|0,this._el=this._el+S|0,this._fl=this._fl+P|0,this._gl=this._gl+I|0,this._hl=this._hl+C|0,this._ah=this._ah+r+hn(this._al,b)|0,this._bh=this._bh+n+hn(this._bl,v)|0,this._ch=this._ch+s+hn(this._cl,E)|0,this._dh=this._dh+i+hn(this._dl,_)|0,this._eh=this._eh+o+hn(this._el,S)|0,this._fh=this._fh+f+hn(this._fl,P)|0,this._gh=this._gh+h+hn(this._gl,I)|0,this._hh=this._hh+p+hn(this._hl,C)|0};Ry.prototype._hash=function(){var t=fce.allocUnsafe(64);function e(r,n,s){t.writeInt32BE(r,s),t.writeInt32BE(n,s+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),e(this._gh,this._gl,48),e(this._hh,this._hl,56),t};var rU=Ry,pce=It,mce=rU,gce=c1,yce=Tt.Buffer,bce=new Array(160);function Ex(){this.init(),this._w=bce,gce.call(this,128,112)}pce(Ex,mce);Ex.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this};Ex.prototype._hash=function(){var t=yce.allocUnsafe(48);function e(r,n,s){t.writeInt32BE(r,s),t.writeInt32BE(n,s+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),t};var vce=Ex,Tl=JF.exports=function(e){e=e.toLowerCase();var r=Tl[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r};Tl.sha=N0e;Tl.sha1=q0e;Tl.sha224=oce;Tl.sha256=eU;Tl.sha384=vce;Tl.sha512=rU;var GM=JF.exports,xce=Gs,VM=dx.EventEmitter,wce=It;wce(Gs,VM);Gs.Readable=zM();Gs.Writable=FM();Gs.Duplex=ol();Gs.Transform=jM;Gs.PassThrough=UF;Gs.finished=mx;Gs.pipeline=HF;Gs.Stream=Gs;function Gs(){VM.call(this)}Gs.prototype.pipe=function(t,e){var r=this;function n(b){t.writable&&t.write(b)===!1&&r.pause&&r.pause()}r.on("data",n);function s(){r.readable&&r.resume&&r.resume()}t.on("drain",s),!t._isStdio&&(!e||e.end!==!1)&&(r.on("end",o),r.on("close",f));var i=!1;function o(){i||(i=!0,t.end())}function f(){i||(i=!0,typeof t.destroy=="function"&&t.destroy())}function h(b){if(p(),VM.listenerCount(this,"error")===0)throw b}r.on("error",h),t.on("error",h);function p(){r.removeListener("data",n),t.removeListener("drain",s),r.removeListener("end",o),r.removeListener("close",f),r.removeListener("error",h),t.removeListener("error",h),r.removeListener("end",p),r.removeListener("close",p),t.removeListener("close",p)}return r.on("end",p),r.on("close",p),t.on("close",p),t.emit("pipe",r),t};var nU=Tt.Buffer,iU=xce.Transform,Ace=s6.StringDecoder,Ece=It;function ea(t){iU.call(this),this.hashMode=typeof t=="string",this.hashMode?this[t]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}Ece(ea,iU);ea.prototype.update=function(t,e,r){typeof t=="string"&&(t=nU.from(t,e));var n=this._update(t);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)};ea.prototype.setAutoPadding=function(){};ea.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")};ea.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")};ea.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")};ea.prototype._transform=function(t,e,r){var n;try{this.hashMode?this._update(t):this.push(this._update(t))}catch(s){n=s}finally{r(n)}};ea.prototype._flush=function(t){var e;try{this.push(this.__final())}catch(r){e=r}t(e)};ea.prototype._finalOrDigest=function(t){var e=this.__final()||nU.alloc(0);return t&&(e=this._toString(e,t,!0)),e};ea.prototype._toString=function(t,e,r){if(this._decoder||(this._decoder=new Ace(e),this._encoding=e),this._encoding!==e)throw new Error("can't switch encodings");var n=this._decoder.write(t);return r&&(n+=this._decoder.end()),n};var zc=ea,Mce=It,Sce=HM,_ce=qM,Pce=GM,sU=zc;function Mx(t){sU.call(this,"digest"),this._hash=t}Mce(Mx,sU);Mx.prototype._update=function(t){this._hash.update(t)};Mx.prototype._final=function(){return this._hash.digest()};var By=function(e){return e=e.toLowerCase(),e==="md5"?new Sce:e==="rmd160"||e==="ripemd160"?new _ce:new Mx(Pce(e))},Cce=It,hu=Tt.Buffer,oU=zc,Ice=hu.alloc(128),th=64;function Sx(t,e){oU.call(this,"digest"),typeof e=="string"&&(e=hu.from(e)),this._alg=t,this._key=e,e.length>th?e=t(e):e.lengthr){var n=t==="rmd160"?new r7:n7(t);e=n.update(e).digest()}else e.lengthWce||e!==e)throw new TypeError("Bad key length")},Hv;if(Ke.process&&Ke.process.browser)Hv="utf-8";else if(Ke.process&&Ke.process.version){var Jce=parseInt(Ve.process.version.split(".")[0].slice(1),10);Hv=Jce>=6?"utf-8":"binary"}else Hv="utf-8";var hU=Hv,h8=Tt.Buffer,dU=function(t,e,r){if(h8.isBuffer(t))return t;if(typeof t=="string")return h8.from(t,e);if(ArrayBuffer.isView(t))return h8.from(t.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")},Zce=aU,Qce=qM,Yce=GM,du=Tt.Buffer,Xce=lU,OT=hU,NT=dU,eue=du.alloc(128),qv={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function pU(t,e,r){var n=tue(t),s=t==="sha512"||t==="sha384"?128:64;e.length>s?e=n(e):e.length>>0};hs.writeUInt32BE=function(e,r,n){e[0+n]=r>>>24,e[1+n]=r>>>16&255,e[2+n]=r>>>8&255,e[3+n]=r&255};hs.ip=function(e,r,n,s){for(var i=0,o=0,f=6;f>=0;f-=2){for(var h=0;h<=24;h+=8)i<<=1,i|=r>>>h+f&1;for(var h=0;h<=24;h+=8)i<<=1,i|=e>>>h+f&1}for(var f=6;f>=0;f-=2){for(var h=1;h<=25;h+=8)o<<=1,o|=r>>>h+f&1;for(var h=1;h<=25;h+=8)o<<=1,o|=e>>>h+f&1}n[s+0]=i>>>0,n[s+1]=o>>>0};hs.rip=function(e,r,n,s){for(var i=0,o=0,f=0;f<4;f++)for(var h=24;h>=0;h-=8)i<<=1,i|=r>>>h+f&1,i<<=1,i|=e>>>h+f&1;for(var f=4;f<8;f++)for(var h=24;h>=0;h-=8)o<<=1,o|=r>>>h+f&1,o<<=1,o|=e>>>h+f&1;n[s+0]=i>>>0,n[s+1]=o>>>0};hs.pc1=function(e,r,n,s){for(var i=0,o=0,f=7;f>=5;f--){for(var h=0;h<=24;h+=8)i<<=1,i|=r>>h+f&1;for(var h=0;h<=24;h+=8)i<<=1,i|=e>>h+f&1}for(var h=0;h<=24;h+=8)i<<=1,i|=r>>h+f&1;for(var f=1;f<=3;f++){for(var h=0;h<=24;h+=8)o<<=1,o|=r>>h+f&1;for(var h=0;h<=24;h+=8)o<<=1,o|=e>>h+f&1}for(var h=0;h<=24;h+=8)o<<=1,o|=e>>h+f&1;n[s+0]=i>>>0,n[s+1]=o>>>0};hs.r28shl=function(e,r){return e<>>28-r};var zb=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];hs.pc2=function(e,r,n,s){for(var i=0,o=0,f=zb.length>>>1,h=0;h>>zb[h]&1;for(var h=f;h>>zb[h]&1;n[s+0]=i>>>0,n[s+1]=o>>>0};hs.expand=function(e,r,n){var s=0,i=0;s=(e&1)<<5|e>>>27;for(var o=23;o>=15;o-=4)s<<=6,s|=e>>>o&63;for(var o=11;o>=3;o-=4)i|=e>>>o&63,i<<=6;i|=(e&31)<<1|e>>>31,r[n+0]=s>>>0,r[n+1]=i>>>0};var FT=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];hs.substitute=function(e,r){for(var n=0,s=0;s<4;s++){var i=e>>>18-s*6&63,o=FT[s*64+i];n<<=4,n|=o}for(var s=0;s<4;s++){var i=r>>>18-s*6&63,o=FT[4*64+s*64+i];n<<=4,n|=o}return n>>>0};var UT=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];hs.permute=function(e){for(var r=0,n=0;n>>UT[n]&1;return r>>>0};hs.padSplit=function(e,r,n){for(var s=e.toString(2);s.length0;s--)r+=this._buffer(e,r),n+=this._flushBuffer(i,n);return r+=this._buffer(e,r),i};no.prototype.final=function(e){var r;e&&(r=this.update(e));var n;return this.type==="encrypt"?n=this._finalEncrypt():n=this._finalDecrypt(),r?r.concat(n):n};no.prototype._pad=function(e,r){if(r===0)return!1;for(;r>>1];n=on.r28shl(n,o),s=on.r28shl(s,o),on.pc2(n,s,e.keys,i)}};Oa.prototype._update=function(e,r,n,s){var i=this._desState,o=on.readUInt32BE(e,r),f=on.readUInt32BE(e,r+4);on.ip(o,f,i.tmp,0),o=i.tmp[0],f=i.tmp[1],this.type==="encrypt"?this._encrypt(i,o,f,i.tmp,0):this._decrypt(i,o,f,i.tmp,0),o=i.tmp[0],f=i.tmp[1],on.writeUInt32BE(n,o,s),on.writeUInt32BE(n,f,s+4)};Oa.prototype._pad=function(e,r){if(this.padding===!1)return!1;for(var n=e.length-r,s=r;s>>0,o=_}on.rip(f,o,s,i)};Oa.prototype._decrypt=function(e,r,n,s,i){for(var o=n,f=r,h=e.keys.length-2;h>=0;h-=2){var p=e.keys[h],b=e.keys[h+1];on.expand(o,e.tmp,0),p^=e.tmp[0],b^=e.tmp[1];var v=on.substitute(p,b),E=on.permute(v),_=o;o=(f^E)>>>0,f=_}on.rip(o,f,s,i)};var AU={},hue=ro,due=It,a6={};function pue(t){hue.equal(t.length,8,"Invalid IV length"),this.iv=new Array(8);for(var e=0;e>s%8,t._prev=Sue(t._prev,r?f:h);return o}function Sue(t,e){var r=t.length,n=-1,s=Gv.allocUnsafe(t.length);for(t=Gv.concat([t,Gv.from([e])]);++n>7;return s}CU.encrypt=function(t,e,r){for(var n=e.length,s=Gv.allocUnsafe(n),i=-1;++i>>24]^o[b>>>16&255]^f[v>>>8&255]^h[E&255]^e[C++],S=i[b>>>24]^o[v>>>16&255]^f[E>>>8&255]^h[p&255]^e[C++],P=i[v>>>24]^o[E>>>16&255]^f[p>>>8&255]^h[b&255]^e[C++],I=i[E>>>24]^o[p>>>16&255]^f[b>>>8&255]^h[v&255]^e[C++],p=_,b=S,v=P,E=I;return _=(n[p>>>24]<<24|n[b>>>16&255]<<16|n[v>>>8&255]<<8|n[E&255])^e[C++],S=(n[b>>>24]<<24|n[v>>>16&255]<<16|n[E>>>8&255]<<8|n[p&255])^e[C++],P=(n[v>>>24]<<24|n[E>>>16&255]<<16|n[p>>>8&255]<<8|n[b&255])^e[C++],I=(n[E>>>24]<<24|n[p>>>16&255]<<16|n[b>>>8&255]<<8|n[v&255])^e[C++],_=_>>>0,S=S>>>0,P=P>>>0,I=I>>>0,[_,S,P,I]}var Lue=[0,1,2,4,8,16,32,64,128,27,54],Qr=function(){for(var t=new Array(256),e=0;e<256;e++)e<128?t[e]=e<<1:t[e]=e<<1^283;for(var r=[],n=[],s=[[],[],[],[]],i=[[],[],[],[]],o=0,f=0,h=0;h<256;++h){var p=f^f<<1^f<<2^f<<3^f<<4;p=p>>>8^p&255^99,r[o]=p,n[p]=o;var b=t[o],v=t[b],E=t[v],_=t[p]*257^p*16843008;s[0][o]=_<<24|_>>>8,s[1][o]=_<<16|_>>>16,s[2][o]=_<<8|_>>>24,s[3][o]=_,_=E*16843009^v*65537^b*257^o*16843008,i[0][p]=_<<24|_>>>8,i[1][p]=_<<16|_>>>16,i[2][p]=_<<8|_>>>24,i[3][p]=_,o===0?o=f=1:(o=b^t[t[t[E^b]]],f^=t[t[f]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:s,INV_SUB_MIX:i}}();function Vs(t){this._key=YM(t),this._reset()}Vs.blockSize=4*4;Vs.keySize=256/8;Vs.prototype.blockSize=Vs.blockSize;Vs.prototype.keySize=Vs.keySize;Vs.prototype._reset=function(){for(var t=this._key,e=t.length,r=e+6,n=(r+1)*4,s=[],i=0;i>>24,o=Qr.SBOX[o>>>24]<<24|Qr.SBOX[o>>>16&255]<<16|Qr.SBOX[o>>>8&255]<<8|Qr.SBOX[o&255],o^=Lue[i/e|0]<<24):e>6&&i%e===4&&(o=Qr.SBOX[o>>>24]<<24|Qr.SBOX[o>>>16&255]<<16|Qr.SBOX[o>>>8&255]<<8|Qr.SBOX[o&255]),s[i]=s[i-e]^o}for(var f=[],h=0;h>>24]]^Qr.INV_SUB_MIX[1][Qr.SBOX[b>>>16&255]]^Qr.INV_SUB_MIX[2][Qr.SBOX[b>>>8&255]]^Qr.INV_SUB_MIX[3][Qr.SBOX[b&255]]}this._nRounds=r,this._keySchedule=s,this._invKeySchedule=f};Vs.prototype.encryptBlockRaw=function(t){return t=YM(t),RU(t,this._keySchedule,Qr.SUB_MIX,Qr.SBOX,this._nRounds)};Vs.prototype.encryptBlock=function(t){var e=this.encryptBlockRaw(t),r=f6.allocUnsafe(16);return r.writeUInt32BE(e[0],0),r.writeUInt32BE(e[1],4),r.writeUInt32BE(e[2],8),r.writeUInt32BE(e[3],12),r};Vs.prototype.decryptBlock=function(t){t=YM(t);var e=t[1];t[1]=t[3],t[3]=e;var r=RU(t,this._invKeySchedule,Qr.INV_SUB_MIX,Qr.INV_SBOX,this._nRounds),n=f6.allocUnsafe(16);return n.writeUInt32BE(r[0],0),n.writeUInt32BE(r[3],4),n.writeUInt32BE(r[2],8),n.writeUInt32BE(r[1],12),n};Vs.prototype.scrub=function(){m8(this._keySchedule),m8(this._invKeySchedule),m8(this._key)};Ny.AES=Vs;var mp=Tt.Buffer,Due=mp.alloc(16,0);function $ue(t){return[t.readUInt32BE(0),t.readUInt32BE(4),t.readUInt32BE(8),t.readUInt32BE(12)]}function BU(t){var e=mp.allocUnsafe(16);return e.writeUInt32BE(t[0]>>>0,0),e.writeUInt32BE(t[1]>>>0,4),e.writeUInt32BE(t[2]>>>0,8),e.writeUInt32BE(t[3]>>>0,12),e}function Ly(t){this.h=t,this.state=mp.alloc(16,0),this.cache=mp.allocUnsafe(0)}Ly.prototype.ghash=function(t){for(var e=-1;++e0;r--)t[r]=t[r]>>>1|(t[r-1]&1)<<31;t[0]=t[0]>>>1,s&&(t[0]=t[0]^225<<24)}this.state=BU(e)};Ly.prototype.update=function(t){this.cache=mp.concat([this.cache,t]);for(var e;this.cache.length>=16;)e=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(e)};Ly.prototype.final=function(t,e){return this.cache.length&&this.ghash(mp.concat([this.cache,Due],16)),this.ghash(BU([0,t,0,e])),this.state};var Fue=Ly,Uue=Ny,Si=Tt.Buffer,OU=zc,zue=It,NU=Fue,jue=Oy,Hue=TU;function que(t,e){var r=0;t.length!==e.length&&r++;for(var n=Math.min(t.length,e.length),s=0;s0||n>0;){var h=new Wue;h.update(f),h.update(t),e&&h.update(e),f=h.digest();var p=0;if(s>0){var b=i.length-s;p=Math.min(s,f.length),f.copy(i,b,0,p),s-=p}if(p0){var v=o.length-n,E=Math.min(n,f.length-p);f.copy(o,v,p,p+E),n-=E}}return f.fill(0),{key:i,iv:o}}var Ix=Jue,FU=QM,Zue=LU,Vf=Tt.Buffer,Que=$U,UU=zc,Yue=Ny,Xue=Ix,ele=It;function Dy(t,e,r){UU.call(this),this._cache=new Tx,this._cipher=new Yue.AES(e),this._prev=Vf.from(r),this._mode=t,this._autopadding=!0}ele(Dy,UU);Dy.prototype._update=function(t){this._cache.add(t);for(var e,r,n=[];e=this._cache.get();)r=this._mode.encrypt(this,e),n.push(r);return Vf.concat(n)};var tle=Vf.alloc(16,16);Dy.prototype._final=function(){var t=this._cache.flush();if(this._autopadding)return t=this._mode.encrypt(this,t),this._cipher.scrub(),t;if(!t.equals(tle))throw this._cipher.scrub(),new Error("data not multiple of block length")};Dy.prototype.setAutoPadding=function(t){return this._autopadding=!!t,this};function Tx(){this.cache=Vf.allocUnsafe(0)}Tx.prototype.add=function(t){this.cache=Vf.concat([this.cache,t])};Tx.prototype.get=function(){if(this.cache.length>15){var t=this.cache.slice(0,16);return this.cache=this.cache.slice(16),t}return null};Tx.prototype.flush=function(){for(var t=16-this.cache.length,e=Vf.allocUnsafe(t),r=-1;++r16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e}else if(this.cache.length>=16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e;return null};kx.prototype.flush=function(){if(this.cache.length)return this.cache};function fle(t){var e=t[15];if(e<1||e>16)throw new Error("unable to decrypt data");for(var r=-1;++r0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(tS);var YU=tS.exports,rS={exports:{}};rS.exports;(function(t){(function(e,r){function n(w,a){if(!w)throw new Error(a||"Assertion failed")}function s(w,a){w.super_=a;var u=function(){};u.prototype=a.prototype,w.prototype=new u,w.prototype.constructor=w}function i(w,a,u){if(i.isBN(w))return w;this.negative=0,this.words=null,this.length=0,this.red=null,w!==null&&((a==="le"||a==="be")&&(u=a,a=10),this._init(w||0,a||10,u||"be"))}typeof e=="object"?e.exports=i:r.BN=i,i.BN=i,i.wordSize=26;var o;try{typeof window<"u"&&typeof window.Buffer<"u"?o=window.Buffer:o=Ln.Buffer}catch{}i.isBN=function(a){return a instanceof i?!0:a!==null&&typeof a=="object"&&a.constructor.wordSize===i.wordSize&&Array.isArray(a.words)},i.max=function(a,u){return a.cmp(u)>0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(rS);var mle=rS.exports,jb={exports:{}},qT;function nS(){if(qT)return jb.exports;qT=1;var t;jb.exports=function(s){return t||(t=new e(null)),t.generate(s)};function e(n){this.rand=n}if(jb.exports.Rand=e,e.prototype.generate=function(s){return this._rand(s)},e.prototype._rand=function(s){if(this.rand.getBytes)return this.rand.getBytes(s);for(var i=new Uint8Array(s),o=0;o=0);return f},r.prototype._randrange=function(s,i){var o=i.sub(s);return s.add(this._randbelow(o))},r.prototype.test=function(s,i,o){var f=s.bitLength(),h=t.mont(s),p=new t(1).toRed(h);i||(i=Math.max(1,f/48|0));for(var b=s.subn(1),v=0;!b.testn(v);v++);for(var E=s.shrn(v),_=b.toRed(h),S=!0;i>0;i--){var P=this._randrange(new t(2),b);o&&o(P);var I=P.toRed(h).redPow(E);if(!(I.cmp(p)===0||I.cmp(_)===0)){for(var C=1;C0;i--){var _=this._randrange(new t(2),p),S=s.gcd(_);if(S.cmpn(1)!==0)return S;var P=_.toRed(f).redPow(v);if(!(P.cmp(h)===0||P.cmp(E)===0)){for(var I=1;IC;)B.ishrn(1);if(B.isEven()&&B.iadd(i),B.testn(1)||B.iadd(o),T.cmp(o)){if(!T.cmp(f))for(;B.mod(h).cmp(p);)B.iadd(v)}else for(;B.mod(r).cmp(b);)B.iadd(v);if(N=B.shrn(1),S(N)&&S(B)&&P(N)&&P(B)&&s.test(N)&&s.test(B))return B}}return b8}const gle={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},yle={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},ble={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},vle={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},xle={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},wle={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},Ale={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},Ele={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"},Mle={modp1:gle,modp2:yle,modp5:ble,modp14:vle,modp15:xle,modp16:wle,modp17:Ale,modp18:Ele};var v8,KT;function Sle(){if(KT)return v8;KT=1;var t=YU,e=XU(),r=new e,n=new t(24),s=new t(11),i=new t(10),o=new t(3),f=new t(7),h=ez(),p=f1;v8=S;function b(I,C){return C=C||"utf8",Ve.Buffer.isBuffer(I)||(I=new Ve.Buffer(I,C)),this._pub=new t(I),this}function v(I,C){return C=C||"utf8",Ve.Buffer.isBuffer(I)||(I=new Ve.Buffer(I,C)),this._priv=new t(I),this}var E={};function _(I,C){var T=C.toString("hex"),B=[T,I.toString(16)].join("_");if(B in E)return E[B];var N=0;if(I.isEven()||!h.simpleSieve||!h.fermatTest(I)||!r.test(I))return N+=1,T==="02"||T==="05"?N+=8:N+=4,E[B]=N,N;r.test(I.shrn(1))||(N+=2);var $;switch(T){case"02":I.mod(n).cmp(s)&&(N+=8);break;case"05":$=I.mod(i),$.cmp(o)&&$.cmp(f)&&(N+=8);break;default:N+=4}return E[B]=N,N}function S(I,C,T){this.setGenerator(C),this.__prime=new t(I),this._prime=t.mont(this.__prime),this._primeLen=I.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,T?(this.setPublicKey=b,this.setPrivateKey=v):this._primeCode=8}Object.defineProperty(S.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=_(this.__prime,this.__gen)),this._primeCode}}),S.prototype.generateKeys=function(){return this._priv||(this._priv=new t(p(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},S.prototype.computeSecret=function(I){I=new t(I),I=I.toRed(this._prime);var C=I.redPow(this._priv).fromRed(),T=new Ve.Buffer(C.toArray()),B=this.getPrime();if(T.length0?l:d},i.min=function(l,d){return l.cmp(d)<0?l:d},i.prototype._init=function(l,d,m){if(typeof l=="number")return this._initNumber(l,d,m);if(typeof l=="object")return this._initArray(l,d,m);d==="hex"&&(d=16),n(d===(d|0)&&d>=2&&d<=36),l=l.toString().replace(/\s+/g,"");var x=0;l[0]==="-"&&(x++,this.negative=1),x=0;x-=3)y=l[x]|l[x-1]<<8|l[x-2]<<16,this.words[A]|=y<>>26-c&67108863,c+=24,c>=26&&(c-=26,A++);else if(m==="le")for(x=0,A=0;x>>26-c&67108863,c+=24,c>=26&&(c-=26,A++);return this._strip()};function f(u,l){var d=u.charCodeAt(l);if(d>=48&&d<=57)return d-48;if(d>=65&&d<=70)return d-55;if(d>=97&&d<=102)return d-87;n(!1,"Invalid character in "+u)}function h(u,l,d){var m=f(u,d);return d-1>=l&&(m|=f(u,d-1)<<4),m}i.prototype._parseHex=function(l,d,m){this.length=Math.ceil((l.length-d)/6),this.words=new Array(this.length);for(var x=0;x=d;x-=2)c=h(l,d,x)<=18?(A-=18,y+=1,this.words[y]|=c>>>26):A+=8;else{var g=l.length-d;for(x=g%2===0?d+1:d;x=18?(A-=18,y+=1,this.words[y]|=c>>>26):A+=8}this._strip()};function p(u,l,d,m){for(var x=0,A=0,y=Math.min(u.length,d),c=l;c=49?A=g-49+10:g>=17?A=g-17+10:A=g,n(g>=0&&A1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{i.prototype[Symbol.for("nodejs.util.inspect.custom")]=v}catch{i.prototype.inspect=v}else i.prototype.inspect=v;function v(){return(this.red?""}var E=["","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],S=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(l,d){l=l||10,d=d|0||1;var m;if(l===16||l==="hex"){m="";for(var x=0,A=0,y=0;y>>24-x&16777215,x+=2,x>=26&&(x-=26,y--),A!==0||y!==this.length-1?m=E[6-g.length]+g+m:m=g+m}for(A!==0&&(m=A.toString(16)+m);m.length%d!==0;)m="0"+m;return this.negative!==0&&(m="-"+m),m}if(l===(l|0)&&l>=2&&l<=36){var M=_[l],R=S[l];m="";var L=this.clone();for(L.negative=0;!L.isZero();){var k=L.modrn(R).toString(l);L=L.idivn(R),L.isZero()?m=k+m:m=E[M-k.length]+k+m}for(this.isZero()&&(m="0"+m);m.length%d!==0;)m="0"+m;return this.negative!==0&&(m="-"+m),m}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var l=this.words[0];return this.length===2?l+=this.words[1]*67108864:this.length===3&&this.words[2]===1?l+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-l:l},i.prototype.toJSON=function(){return this.toString(16,2)},o&&(i.prototype.toBuffer=function(l,d){return this.toArrayLike(o,l,d)}),i.prototype.toArray=function(l,d){return this.toArrayLike(Array,l,d)};var P=function(l,d){return l.allocUnsafe?l.allocUnsafe(d):new l(d)};i.prototype.toArrayLike=function(l,d,m){this._strip();var x=this.byteLength(),A=m||Math.max(1,x);n(x<=A,"byte array longer than desired length"),n(A>0,"Requested array length <= 0");var y=P(l,A),c=d==="le"?"LE":"BE";return this["_toArrayLike"+c](y,x),y},i.prototype._toArrayLikeLE=function(l,d){for(var m=0,x=0,A=0,y=0;A>8&255),m>16&255),y===6?(m>24&255),x=0,y=0):(x=c>>>24,y+=2)}if(m=0&&(l[m--]=c>>8&255),m>=0&&(l[m--]=c>>16&255),y===6?(m>=0&&(l[m--]=c>>24&255),x=0,y=0):(x=c>>>24,y+=2)}if(m>=0)for(l[m--]=x;m>=0;)l[m--]=0},Math.clz32?i.prototype._countBits=function(l){return 32-Math.clz32(l)}:i.prototype._countBits=function(l){var d=l,m=0;return d>=4096&&(m+=13,d>>>=13),d>=64&&(m+=7,d>>>=7),d>=8&&(m+=4,d>>>=4),d>=2&&(m+=2,d>>>=2),m+d},i.prototype._zeroBits=function(l){if(l===0)return 26;var d=l,m=0;return d&8191||(m+=13,d>>>=13),d&127||(m+=7,d>>>=7),d&15||(m+=4,d>>>=4),d&3||(m+=2,d>>>=2),d&1||m++,m},i.prototype.bitLength=function(){var l=this.words[this.length-1],d=this._countBits(l);return(this.length-1)*26+d};function I(u){for(var l=new Array(u.bitLength()),d=0;d>>x&1}return l}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var l=0,d=0;dl.length?this.clone().ior(l):l.clone().ior(this)},i.prototype.uor=function(l){return this.length>l.length?this.clone().iuor(l):l.clone().iuor(this)},i.prototype.iuand=function(l){var d;this.length>l.length?d=l:d=this;for(var m=0;ml.length?this.clone().iand(l):l.clone().iand(this)},i.prototype.uand=function(l){return this.length>l.length?this.clone().iuand(l):l.clone().iuand(this)},i.prototype.iuxor=function(l){var d,m;this.length>l.length?(d=this,m=l):(d=l,m=this);for(var x=0;xl.length?this.clone().ixor(l):l.clone().ixor(this)},i.prototype.uxor=function(l){return this.length>l.length?this.clone().iuxor(l):l.clone().iuxor(this)},i.prototype.inotn=function(l){n(typeof l=="number"&&l>=0);var d=Math.ceil(l/26)|0,m=l%26;this._expand(d),m>0&&d--;for(var x=0;x0&&(this.words[x]=~this.words[x]&67108863>>26-m),this._strip()},i.prototype.notn=function(l){return this.clone().inotn(l)},i.prototype.setn=function(l,d){n(typeof l=="number"&&l>=0);var m=l/26|0,x=l%26;return this._expand(m+1),d?this.words[m]=this.words[m]|1<l.length?(m=this,x=l):(m=l,x=this);for(var A=0,y=0;y>>26;for(;A!==0&&y>>26;if(this.length=m.length,A!==0)this.words[this.length]=A,this.length++;else if(m!==this)for(;yl.length?this.clone().iadd(l):l.clone().iadd(this)},i.prototype.isub=function(l){if(l.negative!==0){l.negative=0;var d=this.iadd(l);return l.negative=1,d._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(l),this.negative=1,this._normSign();var m=this.cmp(l);if(m===0)return this.negative=0,this.length=1,this.words[0]=0,this;var x,A;m>0?(x=this,A=l):(x=l,A=this);for(var y=0,c=0;c>26,this.words[c]=d&67108863;for(;y!==0&&c>26,this.words[c]=d&67108863;if(y===0&&c>>26,L=g&67108863,k=Math.min(M,l.length-1),D=Math.max(0,M-u.length+1);D<=k;D++){var U=M-D|0;x=u.words[U]|0,A=l.words[D]|0,y=x*A+L,R+=y/67108864|0,L=y&67108863}d.words[M]=L|0,g=R|0}return g!==0?d.words[M]=g|0:d.length--,d._strip()}var T=function(l,d,m){var x=l.words,A=d.words,y=m.words,c=0,g,M,R,L=x[0]|0,k=L&8191,D=L>>>13,U=x[1]|0,V=U&8191,G=U>>>13,Y=x[2]|0,q=Y&8191,z=Y>>>13,ee=x[3]|0,re=ee&8191,ie=ee>>>13,ae=x[4]|0,je=ae&8191,he=ae>>>13,oe=x[5]|0,Qe=oe&8191,ge=oe>>>13,be=x[6]|0,ot=be&8191,ye=be>>>13,xe=x[7]|0,at=xe&8191,j=xe>>>13,O=x[8]|0,F=O&8191,W=O>>>13,te=x[9]|0,le=te&8191,ne=te>>>13,pe=A[0]|0,Ye=pe&8191,de=pe>>>13,ve=A[1]|0,Je=ve&8191,we=ve>>>13,Re=A[2]|0,yt=Re&8191,Ae=Re>>>13,Be=A[3]|0,bt=Be&8191,Ee=Be>>>13,Oe=A[4]|0,vt=Oe&8191,Me=Oe>>>13,Ne=A[5]|0,xt=Ne&8191,Se=Ne>>>13,Le=A[6]|0,wt=Le&8191,_e=Le>>>13,De=A[7]|0,At=De&8191,Pe=De>>>13,$e=A[8]|0,Et=$e&8191,Ce=$e>>>13,Fe=A[9]|0,ht=Fe&8191,dt=Fe>>>13;m.negative=l.negative^d.negative,m.length=19,g=Math.imul(k,Ye),M=Math.imul(k,de),M=M+Math.imul(D,Ye)|0,R=Math.imul(D,de);var jt=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(jt>>>26)|0,jt&=67108863,g=Math.imul(V,Ye),M=Math.imul(V,de),M=M+Math.imul(G,Ye)|0,R=Math.imul(G,de),g=g+Math.imul(k,Je)|0,M=M+Math.imul(k,we)|0,M=M+Math.imul(D,Je)|0,R=R+Math.imul(D,we)|0;var Ht=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,g=Math.imul(q,Ye),M=Math.imul(q,de),M=M+Math.imul(z,Ye)|0,R=Math.imul(z,de),g=g+Math.imul(V,Je)|0,M=M+Math.imul(V,we)|0,M=M+Math.imul(G,Je)|0,R=R+Math.imul(G,we)|0,g=g+Math.imul(k,yt)|0,M=M+Math.imul(k,Ae)|0,M=M+Math.imul(D,yt)|0,R=R+Math.imul(D,Ae)|0;var qt=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(qt>>>26)|0,qt&=67108863,g=Math.imul(re,Ye),M=Math.imul(re,de),M=M+Math.imul(ie,Ye)|0,R=Math.imul(ie,de),g=g+Math.imul(q,Je)|0,M=M+Math.imul(q,we)|0,M=M+Math.imul(z,Je)|0,R=R+Math.imul(z,we)|0,g=g+Math.imul(V,yt)|0,M=M+Math.imul(V,Ae)|0,M=M+Math.imul(G,yt)|0,R=R+Math.imul(G,Ae)|0,g=g+Math.imul(k,bt)|0,M=M+Math.imul(k,Ee)|0,M=M+Math.imul(D,bt)|0,R=R+Math.imul(D,Ee)|0;var Gt=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,g=Math.imul(je,Ye),M=Math.imul(je,de),M=M+Math.imul(he,Ye)|0,R=Math.imul(he,de),g=g+Math.imul(re,Je)|0,M=M+Math.imul(re,we)|0,M=M+Math.imul(ie,Je)|0,R=R+Math.imul(ie,we)|0,g=g+Math.imul(q,yt)|0,M=M+Math.imul(q,Ae)|0,M=M+Math.imul(z,yt)|0,R=R+Math.imul(z,Ae)|0,g=g+Math.imul(V,bt)|0,M=M+Math.imul(V,Ee)|0,M=M+Math.imul(G,bt)|0,R=R+Math.imul(G,Ee)|0,g=g+Math.imul(k,vt)|0,M=M+Math.imul(k,Me)|0,M=M+Math.imul(D,vt)|0,R=R+Math.imul(D,Me)|0;var Vt=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,g=Math.imul(Qe,Ye),M=Math.imul(Qe,de),M=M+Math.imul(ge,Ye)|0,R=Math.imul(ge,de),g=g+Math.imul(je,Je)|0,M=M+Math.imul(je,we)|0,M=M+Math.imul(he,Je)|0,R=R+Math.imul(he,we)|0,g=g+Math.imul(re,yt)|0,M=M+Math.imul(re,Ae)|0,M=M+Math.imul(ie,yt)|0,R=R+Math.imul(ie,Ae)|0,g=g+Math.imul(q,bt)|0,M=M+Math.imul(q,Ee)|0,M=M+Math.imul(z,bt)|0,R=R+Math.imul(z,Ee)|0,g=g+Math.imul(V,vt)|0,M=M+Math.imul(V,Me)|0,M=M+Math.imul(G,vt)|0,R=R+Math.imul(G,Me)|0,g=g+Math.imul(k,xt)|0,M=M+Math.imul(k,Se)|0,M=M+Math.imul(D,xt)|0,R=R+Math.imul(D,Se)|0;var nr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(nr>>>26)|0,nr&=67108863,g=Math.imul(ot,Ye),M=Math.imul(ot,de),M=M+Math.imul(ye,Ye)|0,R=Math.imul(ye,de),g=g+Math.imul(Qe,Je)|0,M=M+Math.imul(Qe,we)|0,M=M+Math.imul(ge,Je)|0,R=R+Math.imul(ge,we)|0,g=g+Math.imul(je,yt)|0,M=M+Math.imul(je,Ae)|0,M=M+Math.imul(he,yt)|0,R=R+Math.imul(he,Ae)|0,g=g+Math.imul(re,bt)|0,M=M+Math.imul(re,Ee)|0,M=M+Math.imul(ie,bt)|0,R=R+Math.imul(ie,Ee)|0,g=g+Math.imul(q,vt)|0,M=M+Math.imul(q,Me)|0,M=M+Math.imul(z,vt)|0,R=R+Math.imul(z,Me)|0,g=g+Math.imul(V,xt)|0,M=M+Math.imul(V,Se)|0,M=M+Math.imul(G,xt)|0,R=R+Math.imul(G,Se)|0,g=g+Math.imul(k,wt)|0,M=M+Math.imul(k,_e)|0,M=M+Math.imul(D,wt)|0,R=R+Math.imul(D,_e)|0;var ir=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(ir>>>26)|0,ir&=67108863,g=Math.imul(at,Ye),M=Math.imul(at,de),M=M+Math.imul(j,Ye)|0,R=Math.imul(j,de),g=g+Math.imul(ot,Je)|0,M=M+Math.imul(ot,we)|0,M=M+Math.imul(ye,Je)|0,R=R+Math.imul(ye,we)|0,g=g+Math.imul(Qe,yt)|0,M=M+Math.imul(Qe,Ae)|0,M=M+Math.imul(ge,yt)|0,R=R+Math.imul(ge,Ae)|0,g=g+Math.imul(je,bt)|0,M=M+Math.imul(je,Ee)|0,M=M+Math.imul(he,bt)|0,R=R+Math.imul(he,Ee)|0,g=g+Math.imul(re,vt)|0,M=M+Math.imul(re,Me)|0,M=M+Math.imul(ie,vt)|0,R=R+Math.imul(ie,Me)|0,g=g+Math.imul(q,xt)|0,M=M+Math.imul(q,Se)|0,M=M+Math.imul(z,xt)|0,R=R+Math.imul(z,Se)|0,g=g+Math.imul(V,wt)|0,M=M+Math.imul(V,_e)|0,M=M+Math.imul(G,wt)|0,R=R+Math.imul(G,_e)|0,g=g+Math.imul(k,At)|0,M=M+Math.imul(k,Pe)|0,M=M+Math.imul(D,At)|0,R=R+Math.imul(D,Pe)|0;var sr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(sr>>>26)|0,sr&=67108863,g=Math.imul(F,Ye),M=Math.imul(F,de),M=M+Math.imul(W,Ye)|0,R=Math.imul(W,de),g=g+Math.imul(at,Je)|0,M=M+Math.imul(at,we)|0,M=M+Math.imul(j,Je)|0,R=R+Math.imul(j,we)|0,g=g+Math.imul(ot,yt)|0,M=M+Math.imul(ot,Ae)|0,M=M+Math.imul(ye,yt)|0,R=R+Math.imul(ye,Ae)|0,g=g+Math.imul(Qe,bt)|0,M=M+Math.imul(Qe,Ee)|0,M=M+Math.imul(ge,bt)|0,R=R+Math.imul(ge,Ee)|0,g=g+Math.imul(je,vt)|0,M=M+Math.imul(je,Me)|0,M=M+Math.imul(he,vt)|0,R=R+Math.imul(he,Me)|0,g=g+Math.imul(re,xt)|0,M=M+Math.imul(re,Se)|0,M=M+Math.imul(ie,xt)|0,R=R+Math.imul(ie,Se)|0,g=g+Math.imul(q,wt)|0,M=M+Math.imul(q,_e)|0,M=M+Math.imul(z,wt)|0,R=R+Math.imul(z,_e)|0,g=g+Math.imul(V,At)|0,M=M+Math.imul(V,Pe)|0,M=M+Math.imul(G,At)|0,R=R+Math.imul(G,Pe)|0,g=g+Math.imul(k,Et)|0,M=M+Math.imul(k,Ce)|0,M=M+Math.imul(D,Et)|0,R=R+Math.imul(D,Ce)|0;var or=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(or>>>26)|0,or&=67108863,g=Math.imul(le,Ye),M=Math.imul(le,de),M=M+Math.imul(ne,Ye)|0,R=Math.imul(ne,de),g=g+Math.imul(F,Je)|0,M=M+Math.imul(F,we)|0,M=M+Math.imul(W,Je)|0,R=R+Math.imul(W,we)|0,g=g+Math.imul(at,yt)|0,M=M+Math.imul(at,Ae)|0,M=M+Math.imul(j,yt)|0,R=R+Math.imul(j,Ae)|0,g=g+Math.imul(ot,bt)|0,M=M+Math.imul(ot,Ee)|0,M=M+Math.imul(ye,bt)|0,R=R+Math.imul(ye,Ee)|0,g=g+Math.imul(Qe,vt)|0,M=M+Math.imul(Qe,Me)|0,M=M+Math.imul(ge,vt)|0,R=R+Math.imul(ge,Me)|0,g=g+Math.imul(je,xt)|0,M=M+Math.imul(je,Se)|0,M=M+Math.imul(he,xt)|0,R=R+Math.imul(he,Se)|0,g=g+Math.imul(re,wt)|0,M=M+Math.imul(re,_e)|0,M=M+Math.imul(ie,wt)|0,R=R+Math.imul(ie,_e)|0,g=g+Math.imul(q,At)|0,M=M+Math.imul(q,Pe)|0,M=M+Math.imul(z,At)|0,R=R+Math.imul(z,Pe)|0,g=g+Math.imul(V,Et)|0,M=M+Math.imul(V,Ce)|0,M=M+Math.imul(G,Et)|0,R=R+Math.imul(G,Ce)|0,g=g+Math.imul(k,ht)|0,M=M+Math.imul(k,dt)|0,M=M+Math.imul(D,ht)|0,R=R+Math.imul(D,dt)|0;var ar=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(ar>>>26)|0,ar&=67108863,g=Math.imul(le,Je),M=Math.imul(le,we),M=M+Math.imul(ne,Je)|0,R=Math.imul(ne,we),g=g+Math.imul(F,yt)|0,M=M+Math.imul(F,Ae)|0,M=M+Math.imul(W,yt)|0,R=R+Math.imul(W,Ae)|0,g=g+Math.imul(at,bt)|0,M=M+Math.imul(at,Ee)|0,M=M+Math.imul(j,bt)|0,R=R+Math.imul(j,Ee)|0,g=g+Math.imul(ot,vt)|0,M=M+Math.imul(ot,Me)|0,M=M+Math.imul(ye,vt)|0,R=R+Math.imul(ye,Me)|0,g=g+Math.imul(Qe,xt)|0,M=M+Math.imul(Qe,Se)|0,M=M+Math.imul(ge,xt)|0,R=R+Math.imul(ge,Se)|0,g=g+Math.imul(je,wt)|0,M=M+Math.imul(je,_e)|0,M=M+Math.imul(he,wt)|0,R=R+Math.imul(he,_e)|0,g=g+Math.imul(re,At)|0,M=M+Math.imul(re,Pe)|0,M=M+Math.imul(ie,At)|0,R=R+Math.imul(ie,Pe)|0,g=g+Math.imul(q,Et)|0,M=M+Math.imul(q,Ce)|0,M=M+Math.imul(z,Et)|0,R=R+Math.imul(z,Ce)|0,g=g+Math.imul(V,ht)|0,M=M+Math.imul(V,dt)|0,M=M+Math.imul(G,ht)|0,R=R+Math.imul(G,dt)|0;var fr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(fr>>>26)|0,fr&=67108863,g=Math.imul(le,yt),M=Math.imul(le,Ae),M=M+Math.imul(ne,yt)|0,R=Math.imul(ne,Ae),g=g+Math.imul(F,bt)|0,M=M+Math.imul(F,Ee)|0,M=M+Math.imul(W,bt)|0,R=R+Math.imul(W,Ee)|0,g=g+Math.imul(at,vt)|0,M=M+Math.imul(at,Me)|0,M=M+Math.imul(j,vt)|0,R=R+Math.imul(j,Me)|0,g=g+Math.imul(ot,xt)|0,M=M+Math.imul(ot,Se)|0,M=M+Math.imul(ye,xt)|0,R=R+Math.imul(ye,Se)|0,g=g+Math.imul(Qe,wt)|0,M=M+Math.imul(Qe,_e)|0,M=M+Math.imul(ge,wt)|0,R=R+Math.imul(ge,_e)|0,g=g+Math.imul(je,At)|0,M=M+Math.imul(je,Pe)|0,M=M+Math.imul(he,At)|0,R=R+Math.imul(he,Pe)|0,g=g+Math.imul(re,Et)|0,M=M+Math.imul(re,Ce)|0,M=M+Math.imul(ie,Et)|0,R=R+Math.imul(ie,Ce)|0,g=g+Math.imul(q,ht)|0,M=M+Math.imul(q,dt)|0,M=M+Math.imul(z,ht)|0,R=R+Math.imul(z,dt)|0;var cr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(cr>>>26)|0,cr&=67108863,g=Math.imul(le,bt),M=Math.imul(le,Ee),M=M+Math.imul(ne,bt)|0,R=Math.imul(ne,Ee),g=g+Math.imul(F,vt)|0,M=M+Math.imul(F,Me)|0,M=M+Math.imul(W,vt)|0,R=R+Math.imul(W,Me)|0,g=g+Math.imul(at,xt)|0,M=M+Math.imul(at,Se)|0,M=M+Math.imul(j,xt)|0,R=R+Math.imul(j,Se)|0,g=g+Math.imul(ot,wt)|0,M=M+Math.imul(ot,_e)|0,M=M+Math.imul(ye,wt)|0,R=R+Math.imul(ye,_e)|0,g=g+Math.imul(Qe,At)|0,M=M+Math.imul(Qe,Pe)|0,M=M+Math.imul(ge,At)|0,R=R+Math.imul(ge,Pe)|0,g=g+Math.imul(je,Et)|0,M=M+Math.imul(je,Ce)|0,M=M+Math.imul(he,Et)|0,R=R+Math.imul(he,Ce)|0,g=g+Math.imul(re,ht)|0,M=M+Math.imul(re,dt)|0,M=M+Math.imul(ie,ht)|0,R=R+Math.imul(ie,dt)|0;var ur=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(ur>>>26)|0,ur&=67108863,g=Math.imul(le,vt),M=Math.imul(le,Me),M=M+Math.imul(ne,vt)|0,R=Math.imul(ne,Me),g=g+Math.imul(F,xt)|0,M=M+Math.imul(F,Se)|0,M=M+Math.imul(W,xt)|0,R=R+Math.imul(W,Se)|0,g=g+Math.imul(at,wt)|0,M=M+Math.imul(at,_e)|0,M=M+Math.imul(j,wt)|0,R=R+Math.imul(j,_e)|0,g=g+Math.imul(ot,At)|0,M=M+Math.imul(ot,Pe)|0,M=M+Math.imul(ye,At)|0,R=R+Math.imul(ye,Pe)|0,g=g+Math.imul(Qe,Et)|0,M=M+Math.imul(Qe,Ce)|0,M=M+Math.imul(ge,Et)|0,R=R+Math.imul(ge,Ce)|0,g=g+Math.imul(je,ht)|0,M=M+Math.imul(je,dt)|0,M=M+Math.imul(he,ht)|0,R=R+Math.imul(he,dt)|0;var lr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(lr>>>26)|0,lr&=67108863,g=Math.imul(le,xt),M=Math.imul(le,Se),M=M+Math.imul(ne,xt)|0,R=Math.imul(ne,Se),g=g+Math.imul(F,wt)|0,M=M+Math.imul(F,_e)|0,M=M+Math.imul(W,wt)|0,R=R+Math.imul(W,_e)|0,g=g+Math.imul(at,At)|0,M=M+Math.imul(at,Pe)|0,M=M+Math.imul(j,At)|0,R=R+Math.imul(j,Pe)|0,g=g+Math.imul(ot,Et)|0,M=M+Math.imul(ot,Ce)|0,M=M+Math.imul(ye,Et)|0,R=R+Math.imul(ye,Ce)|0,g=g+Math.imul(Qe,ht)|0,M=M+Math.imul(Qe,dt)|0,M=M+Math.imul(ge,ht)|0,R=R+Math.imul(ge,dt)|0;var hr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(hr>>>26)|0,hr&=67108863,g=Math.imul(le,wt),M=Math.imul(le,_e),M=M+Math.imul(ne,wt)|0,R=Math.imul(ne,_e),g=g+Math.imul(F,At)|0,M=M+Math.imul(F,Pe)|0,M=M+Math.imul(W,At)|0,R=R+Math.imul(W,Pe)|0,g=g+Math.imul(at,Et)|0,M=M+Math.imul(at,Ce)|0,M=M+Math.imul(j,Et)|0,R=R+Math.imul(j,Ce)|0,g=g+Math.imul(ot,ht)|0,M=M+Math.imul(ot,dt)|0,M=M+Math.imul(ye,ht)|0,R=R+Math.imul(ye,dt)|0;var dr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(dr>>>26)|0,dr&=67108863,g=Math.imul(le,At),M=Math.imul(le,Pe),M=M+Math.imul(ne,At)|0,R=Math.imul(ne,Pe),g=g+Math.imul(F,Et)|0,M=M+Math.imul(F,Ce)|0,M=M+Math.imul(W,Et)|0,R=R+Math.imul(W,Ce)|0,g=g+Math.imul(at,ht)|0,M=M+Math.imul(at,dt)|0,M=M+Math.imul(j,ht)|0,R=R+Math.imul(j,dt)|0;var pr=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(pr>>>26)|0,pr&=67108863,g=Math.imul(le,Et),M=Math.imul(le,Ce),M=M+Math.imul(ne,Et)|0,R=Math.imul(ne,Ce),g=g+Math.imul(F,ht)|0,M=M+Math.imul(F,dt)|0,M=M+Math.imul(W,ht)|0,R=R+Math.imul(W,dt)|0;var Ww=(c+g|0)+((M&8191)<<13)|0;c=(R+(M>>>13)|0)+(Ww>>>26)|0,Ww&=67108863,g=Math.imul(le,ht),M=Math.imul(le,dt),M=M+Math.imul(ne,ht)|0,R=Math.imul(ne,dt);var Jw=(c+g|0)+((M&8191)<<13)|0;return c=(R+(M>>>13)|0)+(Jw>>>26)|0,Jw&=67108863,y[0]=jt,y[1]=Ht,y[2]=qt,y[3]=Gt,y[4]=Vt,y[5]=nr,y[6]=ir,y[7]=sr,y[8]=or,y[9]=ar,y[10]=fr,y[11]=cr,y[12]=ur,y[13]=lr,y[14]=hr,y[15]=dr,y[16]=pr,y[17]=Ww,y[18]=Jw,c!==0&&(y[19]=c,m.length++),m};Math.imul||(T=C);function B(u,l,d){d.negative=l.negative^u.negative,d.length=u.length+l.length;for(var m=0,x=0,A=0;A>>26)|0,x+=y>>>26,y&=67108863}d.words[A]=c,m=y,y=x}return m!==0?d.words[A]=m:d.length--,d._strip()}function N(u,l,d){return B(u,l,d)}i.prototype.mulTo=function(l,d){var m,x=this.length+l.length;return this.length===10&&l.length===10?m=T(this,l,d):x<63?m=C(this,l,d):x<1024?m=B(this,l,d):m=N(this,l,d),m},i.prototype.mul=function(l){var d=new i(null);return d.words=new Array(this.length+l.length),this.mulTo(l,d)},i.prototype.mulf=function(l){var d=new i(null);return d.words=new Array(this.length+l.length),N(this,l,d)},i.prototype.imul=function(l){return this.clone().mulTo(l,this)},i.prototype.imuln=function(l){var d=l<0;d&&(l=-l),n(typeof l=="number"),n(l<67108864);for(var m=0,x=0;x>=26,m+=A/67108864|0,m+=y>>>26,this.words[x]=y&67108863}return m!==0&&(this.words[x]=m,this.length++),d?this.ineg():this},i.prototype.muln=function(l){return this.clone().imuln(l)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(l){var d=I(l);if(d.length===0)return new i(1);for(var m=this,x=0;x=0);var d=l%26,m=(l-d)/26,x=67108863>>>26-d<<26-d,A;if(d!==0){var y=0;for(A=0;A>>26-d}y&&(this.words[A]=y,this.length++)}if(m!==0){for(A=this.length-1;A>=0;A--)this.words[A+m]=this.words[A];for(A=0;A=0);var x;d?x=(d-d%26)/26:x=0;var A=l%26,y=Math.min((l-A)/26,this.length),c=67108863^67108863>>>A<y)for(this.length-=y,M=0;M=0&&(R!==0||M>=x);M--){var L=this.words[M]|0;this.words[M]=R<<26-A|L>>>A,R=L&c}return g&&R!==0&&(g.words[g.length++]=R),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},i.prototype.ishrn=function(l,d,m){return n(this.negative===0),this.iushrn(l,d,m)},i.prototype.shln=function(l){return this.clone().ishln(l)},i.prototype.ushln=function(l){return this.clone().iushln(l)},i.prototype.shrn=function(l){return this.clone().ishrn(l)},i.prototype.ushrn=function(l){return this.clone().iushrn(l)},i.prototype.testn=function(l){n(typeof l=="number"&&l>=0);var d=l%26,m=(l-d)/26,x=1<=0);var d=l%26,m=(l-d)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=m)return this;if(d!==0&&m++,this.length=Math.min(m,this.length),d!==0){var x=67108863^67108863>>>d<=67108864;d++)this.words[d]-=67108864,d===this.length-1?this.words[d+1]=1:this.words[d+1]++;return this.length=Math.max(this.length,d+1),this},i.prototype.isubn=function(l){if(n(typeof l=="number"),n(l<67108864),l<0)return this.iaddn(-l);if(this.negative!==0)return this.negative=0,this.iaddn(l),this.negative=1,this;if(this.words[0]-=l,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var d=0;d>26)-(g/67108864|0),this.words[A+m]=y&67108863}for(;A>26,this.words[A+m]=y&67108863;if(c===0)return this._strip();for(n(c===-1),c=0,A=0;A>26,this.words[A]=y&67108863;return this.negative=1,this._strip()},i.prototype._wordDiv=function(l,d){var m=this.length-l.length,x=this.clone(),A=l,y=A.words[A.length-1]|0,c=this._countBits(y);m=26-c,m!==0&&(A=A.ushln(m),x.iushln(m),y=A.words[A.length-1]|0);var g=x.length-A.length,M;if(d!=="mod"){M=new i(null),M.length=g+1,M.words=new Array(M.length);for(var R=0;R=0;k--){var D=(x.words[A.length+k]|0)*67108864+(x.words[A.length+k-1]|0);for(D=Math.min(D/y|0,67108863),x._ishlnsubmul(A,D,k);x.negative!==0;)D--,x.negative=0,x._ishlnsubmul(A,1,k),x.isZero()||(x.negative^=1);M&&(M.words[k]=D)}return M&&M._strip(),x._strip(),d!=="div"&&m!==0&&x.iushrn(m),{div:M||null,mod:x}},i.prototype.divmod=function(l,d,m){if(n(!l.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var x,A,y;return this.negative!==0&&l.negative===0?(y=this.neg().divmod(l,d),d!=="mod"&&(x=y.div.neg()),d!=="div"&&(A=y.mod.neg(),m&&A.negative!==0&&A.iadd(l)),{div:x,mod:A}):this.negative===0&&l.negative!==0?(y=this.divmod(l.neg(),d),d!=="mod"&&(x=y.div.neg()),{div:x,mod:y.mod}):this.negative&l.negative?(y=this.neg().divmod(l.neg(),d),d!=="div"&&(A=y.mod.neg(),m&&A.negative!==0&&A.isub(l)),{div:y.div,mod:A}):l.length>this.length||this.cmp(l)<0?{div:new i(0),mod:this}:l.length===1?d==="div"?{div:this.divn(l.words[0]),mod:null}:d==="mod"?{div:null,mod:new i(this.modrn(l.words[0]))}:{div:this.divn(l.words[0]),mod:new i(this.modrn(l.words[0]))}:this._wordDiv(l,d)},i.prototype.div=function(l){return this.divmod(l,"div",!1).div},i.prototype.mod=function(l){return this.divmod(l,"mod",!1).mod},i.prototype.umod=function(l){return this.divmod(l,"mod",!0).mod},i.prototype.divRound=function(l){var d=this.divmod(l);if(d.mod.isZero())return d.div;var m=d.div.negative!==0?d.mod.isub(l):d.mod,x=l.ushrn(1),A=l.andln(1),y=m.cmp(x);return y<0||A===1&&y===0?d.div:d.div.negative!==0?d.div.isubn(1):d.div.iaddn(1)},i.prototype.modrn=function(l){var d=l<0;d&&(l=-l),n(l<=67108863);for(var m=(1<<26)%l,x=0,A=this.length-1;A>=0;A--)x=(m*x+(this.words[A]|0))%l;return d?-x:x},i.prototype.modn=function(l){return this.modrn(l)},i.prototype.idivn=function(l){var d=l<0;d&&(l=-l),n(l<=67108863);for(var m=0,x=this.length-1;x>=0;x--){var A=(this.words[x]|0)+m*67108864;this.words[x]=A/l|0,m=A%l}return this._strip(),d?this.ineg():this},i.prototype.divn=function(l){return this.clone().idivn(l)},i.prototype.egcd=function(l){n(l.negative===0),n(!l.isZero());var d=this,m=l.clone();d.negative!==0?d=d.umod(l):d=d.clone();for(var x=new i(1),A=new i(0),y=new i(0),c=new i(1),g=0;d.isEven()&&m.isEven();)d.iushrn(1),m.iushrn(1),++g;for(var M=m.clone(),R=d.clone();!d.isZero();){for(var L=0,k=1;!(d.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(d.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(M),A.isub(R)),x.iushrn(1),A.iushrn(1);for(var D=0,U=1;!(m.words[0]&U)&&D<26;++D,U<<=1);if(D>0)for(m.iushrn(D);D-- >0;)(y.isOdd()||c.isOdd())&&(y.iadd(M),c.isub(R)),y.iushrn(1),c.iushrn(1);d.cmp(m)>=0?(d.isub(m),x.isub(y),A.isub(c)):(m.isub(d),y.isub(x),c.isub(A))}return{a:y,b:c,gcd:m.iushln(g)}},i.prototype._invmp=function(l){n(l.negative===0),n(!l.isZero());var d=this,m=l.clone();d.negative!==0?d=d.umod(l):d=d.clone();for(var x=new i(1),A=new i(0),y=m.clone();d.cmpn(1)>0&&m.cmpn(1)>0;){for(var c=0,g=1;!(d.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(d.iushrn(c);c-- >0;)x.isOdd()&&x.iadd(y),x.iushrn(1);for(var M=0,R=1;!(m.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(m.iushrn(M);M-- >0;)A.isOdd()&&A.iadd(y),A.iushrn(1);d.cmp(m)>=0?(d.isub(m),x.isub(A)):(m.isub(d),A.isub(x))}var L;return d.cmpn(1)===0?L=x:L=A,L.cmpn(0)<0&&L.iadd(l),L},i.prototype.gcd=function(l){if(this.isZero())return l.abs();if(l.isZero())return this.abs();var d=this.clone(),m=l.clone();d.negative=0,m.negative=0;for(var x=0;d.isEven()&&m.isEven();x++)d.iushrn(1),m.iushrn(1);do{for(;d.isEven();)d.iushrn(1);for(;m.isEven();)m.iushrn(1);var A=d.cmp(m);if(A<0){var y=d;d=m,m=y}else if(A===0||m.cmpn(1)===0)break;d.isub(m)}while(!0);return m.iushln(x)},i.prototype.invm=function(l){return this.egcd(l).a.umod(l)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(l){return this.words[0]&l},i.prototype.bincn=function(l){n(typeof l=="number");var d=l%26,m=(l-d)/26,x=1<>>26,c&=67108863,this.words[y]=c}return A!==0&&(this.words[y]=A,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(l){var d=l<0;if(this.negative!==0&&!d)return-1;if(this.negative===0&&d)return 1;this._strip();var m;if(this.length>1)m=1;else{d&&(l=-l),n(l<=67108863,"Number is too big");var x=this.words[0]|0;m=x===l?0:xl.length)return 1;if(this.length=0;m--){var x=this.words[m]|0,A=l.words[m]|0;if(x!==A){xA&&(d=1);break}}return d},i.prototype.gtn=function(l){return this.cmpn(l)===1},i.prototype.gt=function(l){return this.cmp(l)===1},i.prototype.gten=function(l){return this.cmpn(l)>=0},i.prototype.gte=function(l){return this.cmp(l)>=0},i.prototype.ltn=function(l){return this.cmpn(l)===-1},i.prototype.lt=function(l){return this.cmp(l)===-1},i.prototype.lten=function(l){return this.cmpn(l)<=0},i.prototype.lte=function(l){return this.cmp(l)<=0},i.prototype.eqn=function(l){return this.cmpn(l)===0},i.prototype.eq=function(l){return this.cmp(l)===0},i.red=function(l){return new w(l)},i.prototype.toRed=function(l){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),l.convertTo(this)._forceRed(l)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(l){return this.red=l,this},i.prototype.forceRed=function(l){return n(!this.red,"Already a number in reduction context"),this._forceRed(l)},i.prototype.redAdd=function(l){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,l)},i.prototype.redIAdd=function(l){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,l)},i.prototype.redSub=function(l){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,l)},i.prototype.redISub=function(l){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,l)},i.prototype.redShl=function(l){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,l)},i.prototype.redMul=function(l){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,l),this.red.mul(this,l)},i.prototype.redIMul=function(l){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,l),this.red.imul(this,l)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(l){return n(this.red&&!l.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,l)};var $={k256:null,p224:null,p192:null,p25519:null};function H(u,l){this.name=u,this.p=new i(l,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}H.prototype._tmp=function(){var l=new i(null);return l.words=new Array(Math.ceil(this.n/13)),l},H.prototype.ireduce=function(l){var d=l,m;do this.split(d,this.tmp),d=this.imulK(d),d=d.iadd(this.tmp),m=d.bitLength();while(m>this.n);var x=m0?d.isub(this.p):d.strip!==void 0?d.strip():d._strip(),d},H.prototype.split=function(l,d){l.iushrn(this.n,0,d)},H.prototype.imulK=function(l){return l.imul(this.k)};function J(){H.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(J,H),J.prototype.split=function(l,d){for(var m=4194303,x=Math.min(l.length,9),A=0;A>>22,y=c}y>>>=22,l.words[A-10]=y,y===0&&l.length>10?l.length-=10:l.length-=9},J.prototype.imulK=function(l){l.words[l.length]=0,l.words[l.length+1]=0,l.length+=2;for(var d=0,m=0;m>>=26,l.words[m]=A,d=x}return d!==0&&(l.words[l.length++]=d),l},i._prime=function(l){if($[l])return $[l];var d;if(l==="k256")d=new J;else if(l==="p224")d=new Q;else if(l==="p192")d=new K;else if(l==="p25519")d=new se;else throw new Error("Unknown prime "+l);return $[l]=d,d};function w(u){if(typeof u=="string"){var l=i._prime(u);this.m=l.p,this.prime=l}else n(u.gtn(1),"modulus must be greater than 1"),this.m=u,this.prime=null}w.prototype._verify1=function(l){n(l.negative===0,"red works only with positives"),n(l.red,"red works only with red numbers")},w.prototype._verify2=function(l,d){n((l.negative|d.negative)===0,"red works only with positives"),n(l.red&&l.red===d.red,"red works only with red numbers")},w.prototype.imod=function(l){return this.prime?this.prime.ireduce(l)._forceRed(this):(b(l,l.umod(this.m)._forceRed(this)),l)},w.prototype.neg=function(l){return l.isZero()?l.clone():this.m.sub(l)._forceRed(this)},w.prototype.add=function(l,d){this._verify2(l,d);var m=l.add(d);return m.cmp(this.m)>=0&&m.isub(this.m),m._forceRed(this)},w.prototype.iadd=function(l,d){this._verify2(l,d);var m=l.iadd(d);return m.cmp(this.m)>=0&&m.isub(this.m),m},w.prototype.sub=function(l,d){this._verify2(l,d);var m=l.sub(d);return m.cmpn(0)<0&&m.iadd(this.m),m._forceRed(this)},w.prototype.isub=function(l,d){this._verify2(l,d);var m=l.isub(d);return m.cmpn(0)<0&&m.iadd(this.m),m},w.prototype.shl=function(l,d){return this._verify1(l),this.imod(l.ushln(d))},w.prototype.imul=function(l,d){return this._verify2(l,d),this.imod(l.imul(d))},w.prototype.mul=function(l,d){return this._verify2(l,d),this.imod(l.mul(d))},w.prototype.isqr=function(l){return this.imul(l,l.clone())},w.prototype.sqr=function(l){return this.mul(l,l)},w.prototype.sqrt=function(l){if(l.isZero())return l.clone();var d=this.m.andln(3);if(n(d%2===1),d===3){var m=this.m.add(new i(1)).iushrn(2);return this.pow(l,m)}for(var x=this.m.subn(1),A=0;!x.isZero()&&x.andln(1)===0;)A++,x.iushrn(1);n(!x.isZero());var y=new i(1).toRed(this),c=y.redNeg(),g=this.m.subn(1).iushrn(1),M=this.m.bitLength();for(M=new i(2*M*M).toRed(this);this.pow(M,g).cmp(c)!==0;)M.redIAdd(c);for(var R=this.pow(M,x),L=this.pow(l,x.addn(1).iushrn(1)),k=this.pow(l,x),D=A;k.cmp(y)!==0;){for(var U=k,V=0;U.cmp(y)!==0;V++)U=U.redSqr();n(V=0;A--){for(var R=d.words[A],L=M-1;L>=0;L--){var k=R>>L&1;if(y!==x[0]&&(y=this.sqr(y)),k===0&&c===0){g=0;continue}c<<=1,c|=k,g++,!(g!==m&&(A!==0||L!==0))&&(y=this.mul(y,x[c]),g=0,c=0)}M=26}return y},w.prototype.convertTo=function(l){var d=l.umod(this.m);return d===l?d.clone():d},w.prototype.convertFrom=function(l){var d=l.clone();return d.red=null,d},i.mont=function(l){return new a(l)};function a(u){w.call(this,u),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(a,w),a.prototype.convertTo=function(l){return this.imod(l.ushln(this.shift))},a.prototype.convertFrom=function(l){var d=this.imod(l.mul(this.rinv));return d.red=null,d},a.prototype.imul=function(l,d){if(l.isZero()||d.isZero())return l.words[0]=0,l.length=1,l;var m=l.imul(d),x=m.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),A=m.isub(x).iushrn(this.shift),y=A;return A.cmp(this.m)>=0?y=A.isub(this.m):A.cmpn(0)<0&&(y=A.iadd(this.m)),y._forceRed(this)},a.prototype.mul=function(l,d){if(l.isZero()||d.isZero())return new i(0)._forceRed(this);var m=l.mul(d),x=m.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),A=m.isub(x).iushrn(this.shift),y=A;return A.cmp(this.m)>=0?y=A.isub(this.m):A.cmpn(0)<0&&(y=A.iadd(this.m)),y._forceRed(this)},a.prototype.invm=function(l){var d=this.imod(l._invmp(this.m).mul(this.r2));return d._forceRed(this)}})(t,Ke)})(iS);var Rx=iS.exports;const Mt=Qs(Rx);var Qh=Rx,Ple=f1;function Cle(t){var e=tz(t),r=e.toRed(Qh.mont(t.modulus)).redPow(new Qh(t.publicExponent)).fromRed();return{blinder:r,unblinder:e.invm(t.modulus)}}function tz(t){var e=t.modulus.byteLength(),r;do r=new Qh(Ple(e));while(r.cmp(t.modulus)>=0||!r.umod(t.prime1)||!r.umod(t.prime2));return r}function rz(t,e){var r=Cle(e),n=e.modulus.byteLength(),s=new Qh(t).mul(r.blinder).umod(e.modulus),i=s.toRed(Qh.mont(e.prime1)),o=s.toRed(Qh.mont(e.prime2)),f=e.coefficient,h=e.prime1,p=e.prime2,b=i.redPow(e.exponent1).fromRed(),v=o.redPow(e.exponent2).fromRed(),E=b.isub(v).imul(f).umod(h).imul(p);return v.iadd(E).imul(r.unblinder).umod(e.modulus).toArrayLike(Ve.Buffer,"be",n)}rz.getr=tz;var sS=rz,x8={};const Ile="elliptic",Tle="6.5.4",kle="EC cryptography",Rle="lib/elliptic.js",Ble=["lib"],Ole={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},Nle={type:"git",url:"git@github.com:indutny/elliptic"},Lle=["EC","Elliptic","curve","Cryptography"],Dle="Fedor Indutny ",$le="MIT",Fle={url:"https://github.com/indutny/elliptic/issues"},Ule="https://github.com/indutny/elliptic",zle={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},jle={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},Hle={name:Ile,version:Tle,description:kle,main:Rle,files:Ble,scripts:Ole,repository:Nle,keywords:Lle,author:Dle,license:$le,bugs:Fle,homepage:Ule,devDependencies:zle,dependencies:jle};var ds={},oS={exports:{}};oS.exports;(function(t){(function(e,r){function n(w,a){if(!w)throw new Error(a||"Assertion failed")}function s(w,a){w.super_=a;var u=function(){};u.prototype=a.prototype,w.prototype=new u,w.prototype.constructor=w}function i(w,a,u){if(i.isBN(w))return w;this.negative=0,this.words=null,this.length=0,this.red=null,w!==null&&((a==="le"||a==="be")&&(u=a,a=10),this._init(w||0,a||10,u||"be"))}typeof e=="object"?e.exports=i:r.BN=i,i.BN=i,i.wordSize=26;var o;try{typeof window<"u"&&typeof window.Buffer<"u"?o=window.Buffer:o=Ln.Buffer}catch{}i.isBN=function(a){return a instanceof i?!0:a!==null&&typeof a=="object"&&a.constructor.wordSize===i.wordSize&&Array.isArray(a.words)},i.max=function(a,u){return a.cmp(u)>0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(oS);var n0=oS.exports,aS={};(function(t){var e=t;function r(i,o){if(Array.isArray(i))return i.slice();if(!i)return[];var f=[];if(typeof i!="string"){for(var h=0;h>8,v=p&255;b?f.push(b,v):f.push(v)}return f}e.toArray=r;function n(i){return i.length===1?"0"+i:i}e.zero2=n;function s(i){for(var o="",f=0;f(S>>1)-1?C=(S>>1)-T:C=T,P.isubn(C)):C=0,_[I]=C,P.iushrn(1)}return _}e.getNAF=i;function o(b,v){var E=[[],[]];b=b.clone(),v=v.clone();for(var _=0,S=0,P;b.cmpn(-_)>0||v.cmpn(-S)>0;){var I=b.andln(3)+_&3,C=v.andln(3)+S&3;I===3&&(I=-1),C===3&&(C=-1);var T;I&1?(P=b.andln(7)+_&7,(P===3||P===5)&&C===2?T=-I:T=I):T=0,E[0].push(T);var B;C&1?(P=v.andln(7)+S&7,(P===3||P===5)&&I===2?B=-C:B=C):B=0,E[1].push(B),2*_===T+1&&(_=1-_),2*S===B+1&&(S=1-S),b.iushrn(1),v.iushrn(1)}return E}e.getJSF=o;function f(b,v,E){var _="_"+v;b.prototype[v]=function(){return this[_]!==void 0?this[_]:this[_]=E.call(this)}}e.cachedProperty=f;function h(b){return typeof b=="string"?e.toArray(b,"hex"):b}e.parseBytes=h;function p(b){return new r(b,"hex","le")}e.intFromLE=p})(ds);var fS={},Xc=n0,Fy=ds,c6=Fy.getNAF,qle=Fy.getJSF,u6=Fy.assert;function jc(t,e){this.type=t,this.p=new Xc(e.p,16),this.red=e.prime?Xc.red(e.prime):Xc.mont(this.p),this.zero=new Xc(0).toRed(this.red),this.one=new Xc(1).toRed(this.red),this.two=new Xc(2).toRed(this.red),this.n=e.n&&new Xc(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var Bx=jc;jc.prototype.point=function(){throw new Error("Not implemented")};jc.prototype.validate=function(){throw new Error("Not implemented")};jc.prototype._fixedNafMul=function(e,r){u6(e.precomputed);var n=e._getDoubles(),s=c6(r,1,this._bitLength),i=(1<=f;p--)h=(h<<1)+s[p];o.push(h)}for(var b=this.jpoint(null,null,null),v=this.jpoint(null,null,null),E=i;E>0;E--){for(f=0;f=0;h--){for(var p=0;h>=0&&o[h]===0;h--)p++;if(h>=0&&p++,f=f.dblp(p),h<0)break;var b=o[h];u6(b!==0),e.type==="affine"?b>0?f=f.mixedAdd(i[b-1>>1]):f=f.mixedAdd(i[-b-1>>1].neg()):b>0?f=f.add(i[b-1>>1]):f=f.add(i[-b-1>>1].neg())}return e.type==="affine"?f.toP():f};jc.prototype._wnafMulAdd=function(e,r,n,s,i){var o=this._wnafT1,f=this._wnafT2,h=this._wnafT3,p=0,b,v,E;for(b=0;b=1;b-=2){var S=b-1,P=b;if(o[S]!==1||o[P]!==1){h[S]=c6(n[S],o[S],this._bitLength),h[P]=c6(n[P],o[P],this._bitLength),p=Math.max(h[S].length,p),p=Math.max(h[P].length,p);continue}var I=[r[S],null,null,r[P]];r[S].y.cmp(r[P].y)===0?(I[1]=r[S].add(r[P]),I[2]=r[S].toJ().mixedAdd(r[P].neg())):r[S].y.cmp(r[P].y.redNeg())===0?(I[1]=r[S].toJ().mixedAdd(r[P]),I[2]=r[S].add(r[P].neg())):(I[1]=r[S].toJ().mixedAdd(r[P]),I[2]=r[S].toJ().mixedAdd(r[P].neg()));var C=[-3,-1,-5,-7,0,7,5,1,3],T=qle(n[S],n[P]);for(p=Math.max(T[0].length,p),h[S]=new Array(p),h[P]=new Array(p),v=0;v=0;b--){for(var J=0;b>=0;){var Q=!0;for(v=0;v=0&&J++,$=$.dblp(J),b<0)break;for(v=0;v0?E=f[v][K-1>>1]:K<0&&(E=f[v][-K-1>>1].neg()),E.type==="affine"?$=$.mixedAdd(E):$=$.add(E))}}for(b=0;b=Math.ceil((e.bitLength()+1)/r.step):!1};io.prototype._getDoubles=function(e,r){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var n=[this],s=this,i=0;i=0&&(_=p,S=b),v.negative&&(v=v.neg(),E=E.neg()),_.negative&&(_=_.neg(),S=S.neg()),[{a:v,b:E},{a:_,b:S}]};so.prototype._endoSplit=function(e){var r=this.endo.basis,n=r[0],s=r[1],i=s.b.mul(e).divRound(this.n),o=n.b.neg().mul(e).divRound(this.n),f=i.mul(n.a),h=o.mul(s.a),p=i.mul(n.b),b=o.mul(s.b),v=e.sub(f).sub(h),E=p.add(b).neg();return{k1:v,k2:E}};so.prototype.pointFromX=function(e,r){e=new Ur(e,16),e.red||(e=e.toRed(this.red));var n=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),s=n.redSqrt();if(s.redSqr().redSub(n).cmp(this.zero)!==0)throw new Error("invalid point");var i=s.fromRed().isOdd();return(r&&!i||!r&&i)&&(s=s.redNeg()),this.point(e,s)};so.prototype.validate=function(e){if(e.inf)return!0;var r=e.x,n=e.y,s=this.a.redMul(r),i=r.redSqr().redMul(r).redIAdd(s).redIAdd(this.b);return n.redSqr().redISub(i).cmpn(0)===0};so.prototype._endoWnafMulAdd=function(e,r,n){for(var s=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""};Sn.prototype.isInfinity=function(){return this.inf};Sn.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(this.x.cmp(e.x)===0)return this.curve.point(null,null);var r=this.y.redSub(e.y);r.cmpn(0)!==0&&(r=r.redMul(this.x.redSub(e.x).redInvm()));var n=r.redSqr().redISub(this.x).redISub(e.x),s=r.redMul(this.x.redSub(n)).redISub(this.y);return this.curve.point(n,s)};Sn.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(e.cmpn(0)===0)return this.curve.point(null,null);var r=this.curve.a,n=this.x.redSqr(),s=e.redInvm(),i=n.redAdd(n).redIAdd(n).redIAdd(r).redMul(s),o=i.redSqr().redISub(this.x.redAdd(this.x)),f=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,f)};Sn.prototype.getX=function(){return this.x.fromRed()};Sn.prototype.getY=function(){return this.y.fromRed()};Sn.prototype.mul=function(e){return e=new Ur(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)};Sn.prototype.mulAdd=function(e,r,n){var s=[this,r],i=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(s,i):this.curve._wnafMulAdd(1,s,i,2)};Sn.prototype.jmulAdd=function(e,r,n){var s=[this,r],i=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(s,i,!0):this.curve._wnafMulAdd(1,s,i,2,!0)};Sn.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||this.x.cmp(e.x)===0&&this.y.cmp(e.y)===0)};Sn.prototype.neg=function(e){if(this.inf)return this;var r=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var n=this.precomputed,s=function(i){return i.neg()};r.precomputed={naf:n.naf&&{wnd:n.naf.wnd,points:n.naf.points.map(s)},doubles:n.doubles&&{step:n.doubles.step,points:n.doubles.points.map(s)}}}return r};Sn.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var e=this.curve.jpoint(this.x,this.y,this.curve.one);return e};function Dn(t,e,r,n){l1.BasePoint.call(this,t,"jacobian"),e===null&&r===null&&n===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new Ur(0)):(this.x=new Ur(e,16),this.y=new Ur(r,16),this.z=new Ur(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}cS(Dn,l1.BasePoint);so.prototype.jpoint=function(e,r,n){return new Dn(this,e,r,n)};Dn.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),r=e.redSqr(),n=this.x.redMul(r),s=this.y.redMul(r).redMul(e);return this.curve.point(n,s)};Dn.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};Dn.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var r=e.z.redSqr(),n=this.z.redSqr(),s=this.x.redMul(r),i=e.x.redMul(n),o=this.y.redMul(r.redMul(e.z)),f=e.y.redMul(n.redMul(this.z)),h=s.redSub(i),p=o.redSub(f);if(h.cmpn(0)===0)return p.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var b=h.redSqr(),v=b.redMul(h),E=s.redMul(b),_=p.redSqr().redIAdd(v).redISub(E).redISub(E),S=p.redMul(E.redISub(_)).redISub(o.redMul(v)),P=this.z.redMul(e.z).redMul(h);return this.curve.jpoint(_,S,P)};Dn.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var r=this.z.redSqr(),n=this.x,s=e.x.redMul(r),i=this.y,o=e.y.redMul(r).redMul(this.z),f=n.redSub(s),h=i.redSub(o);if(f.cmpn(0)===0)return h.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var p=f.redSqr(),b=p.redMul(f),v=n.redMul(p),E=h.redSqr().redIAdd(b).redISub(v).redISub(v),_=h.redMul(v.redISub(E)).redISub(i.redMul(b)),S=this.z.redMul(f);return this.curve.jpoint(E,_,S)};Dn.prototype.dblp=function(e){if(e===0)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var r;if(this.curve.zeroA||this.curve.threeA){var n=this;for(r=0;r=0)return!1;if(n.redIAdd(i),this.x.cmp(n)===0)return!0}};Dn.prototype.inspect=function(){return this.isInfinity()?"":""};Dn.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var Bh=n0,nz=It,Ox=Bx,Wle=ds;function h1(t){Ox.call(this,"mont",t),this.a=new Bh(t.a,16).toRed(this.red),this.b=new Bh(t.b,16).toRed(this.red),this.i4=new Bh(4).toRed(this.red).redInvm(),this.two=new Bh(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}nz(h1,Ox);var Jle=h1;h1.prototype.validate=function(e){var r=e.normalize().x,n=r.redSqr(),s=n.redMul(r).redAdd(n.redMul(this.a)).redAdd(r),i=s.redSqrt();return i.redSqr().cmp(s)===0};function Mn(t,e,r){Ox.BasePoint.call(this,t,"projective"),e===null&&r===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new Bh(e,16),this.z=new Bh(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}nz(Mn,Ox.BasePoint);h1.prototype.decodePoint=function(e,r){return this.point(Wle.toArray(e,r),1)};h1.prototype.point=function(e,r){return new Mn(this,e,r)};h1.prototype.pointFromJSON=function(e){return Mn.fromJSON(this,e)};Mn.prototype.precompute=function(){};Mn.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())};Mn.fromJSON=function(e,r){return new Mn(e,r[0],r[1]||e.one)};Mn.prototype.inspect=function(){return this.isInfinity()?"":""};Mn.prototype.isInfinity=function(){return this.z.cmpn(0)===0};Mn.prototype.dbl=function(){var e=this.x.redAdd(this.z),r=e.redSqr(),n=this.x.redSub(this.z),s=n.redSqr(),i=r.redSub(s),o=r.redMul(s),f=i.redMul(s.redAdd(this.curve.a24.redMul(i)));return this.curve.point(o,f)};Mn.prototype.add=function(){throw new Error("Not supported on Montgomery curve")};Mn.prototype.diffAdd=function(e,r){var n=this.x.redAdd(this.z),s=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z),f=o.redMul(n),h=i.redMul(s),p=r.z.redMul(f.redAdd(h).redSqr()),b=r.x.redMul(f.redISub(h).redSqr());return this.curve.point(p,b)};Mn.prototype.mul=function(e){for(var r=e.clone(),n=this,s=this.curve.point(null,null),i=this,o=[];r.cmpn(0)!==0;r.iushrn(1))o.push(r.andln(1));for(var f=o.length-1;f>=0;f--)o[f]===0?(n=n.diffAdd(s,i),s=s.dbl()):(s=n.diffAdd(s,i),n=n.dbl());return s};Mn.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")};Mn.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")};Mn.prototype.eq=function(e){return this.getX().cmp(e.getX())===0};Mn.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this};Mn.prototype.getX=function(){return this.normalize(),this.x.fromRed()};var Zle=ds,Mf=n0,iz=It,Nx=Bx,Qle=Zle.assert;function Ha(t){this.twisted=(t.a|0)!==1,this.mOneA=this.twisted&&(t.a|0)===-1,this.extended=this.mOneA,Nx.call(this,"edwards",t),this.a=new Mf(t.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new Mf(t.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new Mf(t.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),Qle(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(t.c|0)===1}iz(Ha,Nx);var Yle=Ha;Ha.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)};Ha.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)};Ha.prototype.jpoint=function(e,r,n,s){return this.point(e,r,n,s)};Ha.prototype.pointFromX=function(e,r){e=new Mf(e,16),e.red||(e=e.toRed(this.red));var n=e.redSqr(),s=this.c2.redSub(this.a.redMul(n)),i=this.one.redSub(this.c2.redMul(this.d).redMul(n)),o=s.redMul(i.redInvm()),f=o.redSqrt();if(f.redSqr().redSub(o).cmp(this.zero)!==0)throw new Error("invalid point");var h=f.fromRed().isOdd();return(r&&!h||!r&&h)&&(f=f.redNeg()),this.point(e,f)};Ha.prototype.pointFromY=function(e,r){e=new Mf(e,16),e.red||(e=e.toRed(this.red));var n=e.redSqr(),s=n.redSub(this.c2),i=n.redMul(this.d).redMul(this.c2).redSub(this.a),o=s.redMul(i.redInvm());if(o.cmp(this.zero)===0){if(r)throw new Error("invalid point");return this.point(this.zero,e)}var f=o.redSqrt();if(f.redSqr().redSub(o).cmp(this.zero)!==0)throw new Error("invalid point");return f.fromRed().isOdd()!==r&&(f=f.redNeg()),this.point(f,e)};Ha.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var r=e.x.redSqr(),n=e.y.redSqr(),s=r.redMul(this.a).redAdd(n),i=this.c2.redMul(this.one.redAdd(this.d.redMul(r).redMul(n)));return s.cmp(i)===0};function yr(t,e,r,n,s){Nx.BasePoint.call(this,t,"projective"),e===null&&r===null&&n===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new Mf(e,16),this.y=new Mf(r,16),this.z=n?new Mf(n,16):this.curve.one,this.t=s&&new Mf(s,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}iz(yr,Nx.BasePoint);Ha.prototype.pointFromJSON=function(e){return yr.fromJSON(this,e)};Ha.prototype.point=function(e,r,n,s){return new yr(this,e,r,n,s)};yr.fromJSON=function(e,r){return new yr(e,r[0],r[1],r[2])};yr.prototype.inspect=function(){return this.isInfinity()?"":""};yr.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)};yr.prototype._extDbl=function(){var e=this.x.redSqr(),r=this.y.redSqr(),n=this.z.redSqr();n=n.redIAdd(n);var s=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(r),o=s.redAdd(r),f=o.redSub(n),h=s.redSub(r),p=i.redMul(f),b=o.redMul(h),v=i.redMul(h),E=f.redMul(o);return this.curve.point(p,b,E,v)};yr.prototype._projDbl=function(){var e=this.x.redAdd(this.y).redSqr(),r=this.x.redSqr(),n=this.y.redSqr(),s,i,o,f,h,p;if(this.curve.twisted){f=this.curve._mulA(r);var b=f.redAdd(n);this.zOne?(s=e.redSub(r).redSub(n).redMul(b.redSub(this.curve.two)),i=b.redMul(f.redSub(n)),o=b.redSqr().redSub(b).redSub(b)):(h=this.z.redSqr(),p=b.redSub(h).redISub(h),s=e.redSub(r).redISub(n).redMul(p),i=b.redMul(f.redSub(n)),o=b.redMul(p))}else f=r.redAdd(n),h=this.curve._mulC(this.z).redSqr(),p=f.redSub(h).redSub(h),s=this.curve._mulC(e.redISub(f)).redMul(p),i=this.curve._mulC(f).redMul(r.redISub(n)),o=f.redMul(p);return this.curve.point(s,i,o)};yr.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()};yr.prototype._extAdd=function(e){var r=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),n=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),s=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=n.redSub(r),f=i.redSub(s),h=i.redAdd(s),p=n.redAdd(r),b=o.redMul(f),v=h.redMul(p),E=o.redMul(p),_=f.redMul(h);return this.curve.point(b,v,_,E)};yr.prototype._projAdd=function(e){var r=this.z.redMul(e.z),n=r.redSqr(),s=this.x.redMul(e.x),i=this.y.redMul(e.y),o=this.curve.d.redMul(s).redMul(i),f=n.redSub(o),h=n.redAdd(o),p=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(s).redISub(i),b=r.redMul(f).redMul(p),v,E;return this.curve.twisted?(v=r.redMul(h).redMul(i.redSub(this.curve._mulA(s))),E=f.redMul(h)):(v=r.redMul(h).redMul(i.redSub(s)),E=this.curve._mulC(f).redMul(h)),this.curve.point(b,v,E)};yr.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)};yr.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)};yr.prototype.mulAdd=function(e,r,n){return this.curve._wnafMulAdd(1,[this,r],[e,n],2,!1)};yr.prototype.jmulAdd=function(e,r,n){return this.curve._wnafMulAdd(1,[this,r],[e,n],2,!0)};yr.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this};yr.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())};yr.prototype.getX=function(){return this.normalize(),this.x.fromRed()};yr.prototype.getY=function(){return this.normalize(),this.y.fromRed()};yr.prototype.eq=function(e){return this===e||this.getX().cmp(e.getX())===0&&this.getY().cmp(e.getY())===0};yr.prototype.eqXToP=function(e){var r=e.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(r)===0)return!0;for(var n=e.clone(),s=this.curve.redN.redMul(this.z);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(s),this.x.cmp(r)===0)return!0}};yr.prototype.toP=yr.prototype.normalize;yr.prototype.mixedAdd=yr.prototype.add;(function(t){var e=t;e.base=Bx,e.short=Kle,e.mont=Jle,e.edwards=Yle})(fS);var Lx={},Uy={},Lt={},Xle=ro,ehe=It;Lt.inherits=ehe;function the(t,e){return(t.charCodeAt(e)&64512)!==55296||e<0||e+1>=t.length?!1:(t.charCodeAt(e+1)&64512)===56320}function rhe(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if(typeof t=="string")if(e){if(e==="hex")for(t=t.replace(/[^a-z0-9]+/ig,""),t.length%2!==0&&(t="0"+t),s=0;s>6|192,r[n++]=i&63|128):the(t,s)?(i=65536+((i&1023)<<10)+(t.charCodeAt(++s)&1023),r[n++]=i>>18|240,r[n++]=i>>12&63|128,r[n++]=i>>6&63|128,r[n++]=i&63|128):(r[n++]=i>>12|224,r[n++]=i>>6&63|128,r[n++]=i&63|128)}else for(s=0;s>>24|t>>>8&65280|t<<8&16711680|(t&255)<<24;return e>>>0}Lt.htonl=sz;function ihe(t,e){for(var r="",n=0;n>>0}return i}Lt.join32=she;function ohe(t,e){for(var r=new Array(t.length*4),n=0,s=0;n>>24,r[s+1]=i>>>16&255,r[s+2]=i>>>8&255,r[s+3]=i&255):(r[s+3]=i>>>24,r[s+2]=i>>>16&255,r[s+1]=i>>>8&255,r[s]=i&255)}return r}Lt.split32=ohe;function ahe(t,e){return t>>>e|t<<32-e}Lt.rotr32=ahe;function fhe(t,e){return t<>>32-e}Lt.rotl32=fhe;function che(t,e){return t+e>>>0}Lt.sum32=che;function uhe(t,e,r){return t+e+r>>>0}Lt.sum32_3=uhe;function lhe(t,e,r,n){return t+e+r+n>>>0}Lt.sum32_4=lhe;function hhe(t,e,r,n,s){return t+e+r+n+s>>>0}Lt.sum32_5=hhe;function dhe(t,e,r,n){var s=t[e],i=t[e+1],o=n+i>>>0,f=(o>>0,t[e+1]=o}Lt.sum64=dhe;function phe(t,e,r,n){var s=e+n>>>0,i=(s>>0}Lt.sum64_hi=phe;function mhe(t,e,r,n){var s=e+n;return s>>>0}Lt.sum64_lo=mhe;function ghe(t,e,r,n,s,i,o,f){var h=0,p=e;p=p+n>>>0,h+=p>>0,h+=p>>0,h+=p>>0}Lt.sum64_4_hi=ghe;function yhe(t,e,r,n,s,i,o,f){var h=e+n+i+f;return h>>>0}Lt.sum64_4_lo=yhe;function bhe(t,e,r,n,s,i,o,f,h,p){var b=0,v=e;v=v+n>>>0,b+=v>>0,b+=v>>0,b+=v>>0,b+=v>>0}Lt.sum64_5_hi=bhe;function vhe(t,e,r,n,s,i,o,f,h,p){var b=e+n+i+f+p;return b>>>0}Lt.sum64_5_lo=vhe;function xhe(t,e,r){var n=e<<32-r|t>>>r;return n>>>0}Lt.rotr64_hi=xhe;function whe(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}Lt.rotr64_lo=whe;function Ahe(t,e,r){return t>>>r}Lt.shr64_hi=Ahe;function Ehe(t,e,r){var n=t<<32-r|e>>>r;return n>>>0}Lt.shr64_lo=Ehe;var d1={},JT=Lt,Mhe=ro;function Dx(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}d1.BlockHash=Dx;Dx.prototype.update=function(e,r){if(e=JT.toArray(e,r),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){e=this.pending;var n=e.length%this._delta8;this.pending=e.slice(e.length-n,e.length),this.pending.length===0&&(this.pending=null),e=JT.join32(e,0,e.length-n,this.endian);for(var s=0;s>>24&255,s[i++]=e>>>16&255,s[i++]=e>>>8&255,s[i++]=e&255}else for(s[i++]=e&255,s[i++]=e>>>8&255,s[i++]=e>>>16&255,s[i++]=e>>>24&255,s[i++]=0,s[i++]=0,s[i++]=0,s[i++]=0,o=8;o>>3}qa.g0_256=Ihe;function The(t){return Ia(t,17)^Ia(t,19)^t>>>10}qa.g1_256=The;var yp=Lt,khe=d1,Rhe=qa,w8=yp.rotl32,X1=yp.sum32,Bhe=yp.sum32_5,Ohe=Rhe.ft_1,lz=khe.BlockHash,Nhe=[1518500249,1859775393,2400959708,3395469782];function Na(){if(!(this instanceof Na))return new Na;lz.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}yp.inherits(Na,lz);var Lhe=Na;Na.blockSize=512;Na.outSize=160;Na.hmacStrength=80;Na.padLength=64;Na.prototype._update=function(e,r){for(var n=this.W,s=0;s<16;s++)n[s]=e[r+s];for(;sthis.blockSize&&(e=new this.Hash().update(e).digest()),Ede(e.length<=this.blockSize);for(var r=e.length;r=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,n)}var Pde=xc;xc.prototype._init=function(e,r,n){var s=e.concat(r).concat(n);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(n||[])),this._reseed=1};xc.prototype.generate=function(e,r,n,s){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof r!="string"&&(s=n,n=r,r=null),n&&(n=Vu.toArray(n,s||"hex"),this._update(n));for(var i=[];i.length"};var l6=n0,uS=ds,kde=uS.assert;function $x(t,e){if(t instanceof $x)return t;this._importDER(t,e)||(kde(t.r&&t.s,"Signature without r or s"),this.r=new l6(t.r,16),this.s=new l6(t.s,16),t.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}var Rde=$x;function Bde(){this.place=0}function S8(t,e){var r=t[e.place++];if(!(r&128))return r;var n=r&15;if(n===0||n>4)return!1;for(var s=0,i=0,o=e.place;i>>=0;return s<=127?!1:(e.place=o,s)}function ek(t){for(var e=0,r=t.length-1;!t[e]&&!(t[e+1]&128)&&e>>3);for(t.push(r|128);--r;)t.push(e>>>(r<<3)&255);t.push(e)}$x.prototype.toDER=function(e){var r=this.r.toArray(),n=this.s.toArray();for(r[0]&128&&(r=[0].concat(r)),n[0]&128&&(n=[0].concat(n)),r=ek(r),n=ek(n);!n[0]&&!(n[1]&128);)n=n.slice(1);var s=[2];_8(s,r.length),s=s.concat(r),s.push(2),_8(s,n.length);var i=s.concat(n),o=[48];return _8(o,i.length),o=o.concat(i),uS.encode(o,e)};var P8,tk;function Ode(){if(tk)return P8;tk=1;var t=n0,e=Pde,r=ds,n=Lx,s=nS(),i=r.assert,o=Tde,f=Rde;function h(p){if(!(this instanceof h))return new h(p);typeof p=="string"&&(i(Object.prototype.hasOwnProperty.call(n,p),"Unknown curve "+p),p=n[p]),p instanceof n.PresetCurve&&(p={curve:p}),this.curve=p.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=p.curve.g,this.g.precompute(p.curve.n.bitLength()+1),this.hash=p.hash||p.curve.hash}return P8=h,h.prototype.keyPair=function(b){return new o(this,b)},h.prototype.keyFromPrivate=function(b,v){return o.fromPrivate(this,b,v)},h.prototype.keyFromPublic=function(b,v){return o.fromPublic(this,b,v)},h.prototype.genKeyPair=function(b){b||(b={});for(var v=new e({hash:this.hash,pers:b.pers,persEnc:b.persEnc||"utf8",entropy:b.entropy||s(this.hash.hmacStrength),entropyEnc:b.entropy&&b.entropyEnc||"utf8",nonce:this.n.toArray()}),E=this.n.byteLength(),_=this.n.sub(new t(2));;){var S=new t(v.generate(E));if(!(S.cmp(_)>0))return S.iaddn(1),this.keyFromPrivate(S)}},h.prototype._truncateToN=function(b,v){var E=b.byteLength()*8-this.n.bitLength();return E>0&&(b=b.ushrn(E)),!v&&b.cmp(this.n)>=0?b.sub(this.n):b},h.prototype.sign=function(b,v,E,_){typeof E=="object"&&(_=E,E=null),_||(_={}),v=this.keyFromPrivate(v,E),b=this._truncateToN(new t(b,16));for(var S=this.n.byteLength(),P=v.getPrivate().toArray("be",S),I=b.toArray("be",S),C=new e({hash:this.hash,entropy:P,nonce:I,pers:_.pers,persEnc:_.persEnc||"utf8"}),T=this.n.sub(new t(1)),B=0;;B++){var N=_.k?_.k(B):new t(C.generate(this.n.byteLength()));if(N=this._truncateToN(N,!0),!(N.cmpn(1)<=0||N.cmp(T)>=0)){var $=this.g.mul(N);if(!$.isInfinity()){var H=$.getX(),J=H.umod(this.n);if(J.cmpn(0)!==0){var Q=N.invm(this.n).mul(J.mul(v.getPrivate()).iadd(b));if(Q=Q.umod(this.n),Q.cmpn(0)!==0){var K=($.getY().isOdd()?1:0)|(H.cmp(J)!==0?2:0);return _.canonical&&Q.cmp(this.nh)>0&&(Q=this.n.sub(Q),K^=1),new f({r:J,s:Q,recoveryParam:K})}}}}}},h.prototype.verify=function(b,v,E,_){b=this._truncateToN(new t(b,16)),E=this.keyFromPublic(E,_),v=new f(v,"hex");var S=v.r,P=v.s;if(S.cmpn(1)<0||S.cmp(this.n)>=0||P.cmpn(1)<0||P.cmp(this.n)>=0)return!1;var I=P.invm(this.n),C=I.mul(b).umod(this.n),T=I.mul(S).umod(this.n),B;return this.curve._maxwellTrick?(B=this.g.jmulAdd(C,E.getPublic(),T),B.isInfinity()?!1:B.eqXToP(S)):(B=this.g.mulAdd(C,E.getPublic(),T),B.isInfinity()?!1:B.getX().umod(this.n).cmp(S)===0)},h.prototype.recoverPubKey=function(p,b,v,E){i((3&v)===v,"The recovery param is more than two bits"),b=new f(b,E);var _=this.n,S=new t(p),P=b.r,I=b.s,C=v&1,T=v>>1;if(P.cmp(this.curve.p.umod(this.curve.n))>=0&&T)throw new Error("Unable to find sencond key candinate");T?P=this.curve.pointFromX(P.add(this.curve.n),C):P=this.curve.pointFromX(P,C);var B=b.r.invm(_),N=_.sub(S).mul(B).umod(_),$=I.mul(B).umod(_);return this.g.mulAdd(N,P,$)},h.prototype.getKeyRecoveryParam=function(p,b,v,E){if(b=new f(b,E),b.recoveryParam!==null)return b.recoveryParam;for(var _=0;_<4;_++){var S;try{S=this.recoverPubKey(p,b,_)}catch{continue}if(S.eq(v))return _}throw new Error("Unable to find valid recovery factor")},P8}var zy=ds,Ez=zy.assert,rk=zy.parseBytes,g1=zy.cachedProperty;function An(t,e){this.eddsa=t,this._secret=rk(e.secret),t.isPoint(e.pub)?this._pub=e.pub:this._pubBytes=rk(e.pub)}An.fromPublic=function(e,r){return r instanceof An?r:new An(e,{pub:r})};An.fromSecret=function(e,r){return r instanceof An?r:new An(e,{secret:r})};An.prototype.secret=function(){return this._secret};g1(An,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())});g1(An,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())});g1(An,"privBytes",function(){var e=this.eddsa,r=this.hash(),n=e.encodingLength-1,s=r.slice(0,e.encodingLength);return s[0]&=248,s[n]&=127,s[n]|=64,s});g1(An,"priv",function(){return this.eddsa.decodeInt(this.privBytes())});g1(An,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()});g1(An,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)});An.prototype.sign=function(e){return Ez(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)};An.prototype.verify=function(e,r){return this.eddsa.verify(e,r,this)};An.prototype.getSecret=function(e){return Ez(this._secret,"KeyPair is public only"),zy.encode(this.secret(),e)};An.prototype.getPublic=function(e){return zy.encode(this.pubBytes(),e)};var Nde=An,Lde=n0,Fx=ds,Dde=Fx.assert,Ux=Fx.cachedProperty,$de=Fx.parseBytes;function Rl(t,e){this.eddsa=t,typeof e!="object"&&(e=$de(e)),Array.isArray(e)&&(e={R:e.slice(0,t.encodingLength),S:e.slice(t.encodingLength)}),Dde(e.R&&e.S,"Signature without R or S"),t.isPoint(e.R)&&(this._R=e.R),e.S instanceof Lde&&(this._S=e.S),this._Rencoded=Array.isArray(e.R)?e.R:e.Rencoded,this._Sencoded=Array.isArray(e.S)?e.S:e.Sencoded}Ux(Rl,"S",function(){return this.eddsa.decodeInt(this.Sencoded())});Ux(Rl,"R",function(){return this.eddsa.decodePoint(this.Rencoded())});Ux(Rl,"Rencoded",function(){return this.eddsa.encodePoint(this.R())});Ux(Rl,"Sencoded",function(){return this.eddsa.encodeInt(this.S())});Rl.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())};Rl.prototype.toHex=function(){return Fx.encode(this.toBytes(),"hex").toUpperCase()};var Fde=Rl,Ude=Uy,zde=Lx,xp=ds,jde=xp.assert,Mz=xp.parseBytes,Sz=Nde,nk=Fde;function Di(t){if(jde(t==="ed25519","only tested with ed25519 so far"),!(this instanceof Di))return new Di(t);t=zde[t].curve,this.curve=t,this.g=t.g,this.g.precompute(t.n.bitLength()+1),this.pointClass=t.point().constructor,this.encodingLength=Math.ceil(t.n.bitLength()/8),this.hash=Ude.sha512}var Hde=Di;Di.prototype.sign=function(e,r){e=Mz(e);var n=this.keyFromSecret(r),s=this.hashInt(n.messagePrefix(),e),i=this.g.mul(s),o=this.encodePoint(i),f=this.hashInt(o,n.pubBytes(),e).mul(n.priv()),h=s.add(f).umod(this.curve.n);return this.makeSignature({R:i,S:h,Rencoded:o})};Di.prototype.verify=function(e,r,n){e=Mz(e),r=this.makeSignature(r);var s=this.keyFromPublic(n),i=this.hashInt(r.Rencoded(),s.pubBytes(),e),o=this.g.mul(r.S()),f=r.R().add(s.pub().mul(i));return f.eq(o)};Di.prototype.hashInt=function(){for(var e=this.hash(),r=0;r0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(dS);var _z=dS.exports,Pz={},pS={},Kv=Ln,Yh=Kv.Buffer,Ts={},ks;for(ks in Kv)Kv.hasOwnProperty(ks)&&(ks==="SlowBuffer"||ks==="Buffer"||(Ts[ks]=Kv[ks]));var Xh=Ts.Buffer={};for(ks in Yh)Yh.hasOwnProperty(ks)&&(ks==="allocUnsafe"||ks==="allocUnsafeSlow"||(Xh[ks]=Yh[ks]));Ts.Buffer.prototype=Yh.prototype;(!Xh.from||Xh.from===Uint8Array.from)&&(Xh.from=function(t,e,r){if(typeof t=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+typeof t);if(t&&typeof t.length>"u")throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);return Yh(t,e,r)});Xh.alloc||(Xh.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError('The "size" argument must be of type number. Received type '+typeof t);if(t<0||t>=2*(1<<30))throw new RangeError('The value "'+t+'" is invalid for option "size"');var n=Yh(t);return!e||e.length===0?n.fill(0):typeof r=="string"?n.fill(e,r):n.fill(e),n});if(!Ts.kStringMaxLength)try{Ts.kStringMaxLength=Ve.process.binding("buffer").kStringMaxLength}catch{}Ts.constants||(Ts.constants={MAX_LENGTH:Ts.kMaxLength},Ts.kStringMaxLength&&(Ts.constants.MAX_STRING_LENGTH=Ts.kStringMaxLength));var mS=Ts,zx={};const qde=It;function oo(t){this._reporterState={obj:null,path:[],options:t||{},errors:[]}}zx.Reporter=oo;oo.prototype.isError=function(e){return e instanceof wp};oo.prototype.save=function(){const e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}};oo.prototype.restore=function(e){const r=this._reporterState;r.obj=e.obj,r.path=r.path.slice(0,e.pathLen)};oo.prototype.enterKey=function(e){return this._reporterState.path.push(e)};oo.prototype.exitKey=function(e){const r=this._reporterState;r.path=r.path.slice(0,e-1)};oo.prototype.leaveKey=function(e,r,n){const s=this._reporterState;this.exitKey(e),s.obj!==null&&(s.obj[r]=n)};oo.prototype.path=function(){return this._reporterState.path.join("/")};oo.prototype.enterObject=function(){const e=this._reporterState,r=e.obj;return e.obj={},r};oo.prototype.leaveObject=function(e){const r=this._reporterState,n=r.obj;return r.obj=e,n};oo.prototype.error=function(e){let r;const n=this._reporterState,s=e instanceof wp;if(s?r=e:r=new wp(n.path.map(function(i){return"["+JSON.stringify(i)+"]"}).join(""),e.message||e,e.stack),!n.options.partial)throw r;return s||n.errors.push(r),r};oo.prototype.wrapResult=function(e){const r=this._reporterState;return r.options.partial?{result:this.isError(e)?null:e,errors:r.errors}:e};function wp(t,e){this.path=t,this.rethrow(e)}qde(wp,Error);wp.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,wp),!this.stack)try{throw new Error(this.message)}catch(r){this.stack=r.stack}return this};var ul={};const Gde=It,jx=zx.Reporter,Ap=mS.Buffer;function Ks(t,e){if(jx.call(this,e),!Ap.isBuffer(t)){this.error("Input not Buffer");return}this.base=t,this.offset=0,this.length=t.length}Gde(Ks,jx);ul.DecoderBuffer=Ks;Ks.isDecoderBuffer=function(e){return e instanceof Ks?!0:typeof e=="object"&&Ap.isBuffer(e.base)&&e.constructor.name==="DecoderBuffer"&&typeof e.offset=="number"&&typeof e.length=="number"&&typeof e.save=="function"&&typeof e.restore=="function"&&typeof e.isEmpty=="function"&&typeof e.readUInt8=="function"&&typeof e.skip=="function"&&typeof e.raw=="function"};Ks.prototype.save=function(){return{offset:this.offset,reporter:jx.prototype.save.call(this)}};Ks.prototype.restore=function(e){const r=new Ks(this.base);return r.offset=e.offset,r.length=this.offset,this.offset=e.offset,jx.prototype.restore.call(this,e.reporter),r};Ks.prototype.isEmpty=function(){return this.offset===this.length};Ks.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")};Ks.prototype.skip=function(e,r){if(!(this.offset+e<=this.length))return this.error(r||"DecoderBuffer overrun");const n=new Ks(this.base);return n._reporterState=this._reporterState,n.offset=this.offset,n.length=this.offset+e,this.offset+=e,n};Ks.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)};function Ep(t,e){if(Array.isArray(t))this.length=0,this.value=t.map(function(r){return Ep.isEncoderBuffer(r)||(r=new Ep(r,e)),this.length+=r.length,r},this);else if(typeof t=="number"){if(!(0<=t&&t<=255))return e.error("non-byte EncoderBuffer value");this.value=t,this.length=1}else if(typeof t=="string")this.value=t,this.length=Ap.byteLength(t);else if(Ap.isBuffer(t))this.value=t,this.length=t.length;else return e.error("Unsupported type: "+typeof t)}ul.EncoderBuffer=Ep;Ep.isEncoderBuffer=function(e){return e instanceof Ep?!0:typeof e=="object"&&e.constructor.name==="EncoderBuffer"&&typeof e.length=="number"&&typeof e.join=="function"};Ep.prototype.join=function(e,r){return e||(e=Ap.alloc(this.length)),r||(r=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(n){n.join(e,r),r+=n.length}):(typeof this.value=="number"?e[r]=this.value:typeof this.value=="string"?e.write(this.value,r):Ap.isBuffer(this.value)&&this.value.copy(e,r),r+=this.length)),e};const Vde=zx.Reporter,Kde=ul.EncoderBuffer,Wde=ul.DecoderBuffer,pi=ro,Cz=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],Jde=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(Cz),Zde=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function rr(t,e,r){const n={};this._baseState=n,n.name=r,n.enc=t,n.parent=e||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}var gS=rr;const Qde=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];rr.prototype.clone=function(){const e=this._baseState,r={};Qde.forEach(function(s){r[s]=e[s]});const n=new this.constructor(r.parent);return n._baseState=r,n};rr.prototype._wrap=function(){const e=this._baseState;Jde.forEach(function(r){this[r]=function(){const s=new this.constructor(this);return e.children.push(s),s[r].apply(s,arguments)}},this)};rr.prototype._init=function(e){const r=this._baseState;pi(r.parent===null),e.call(this),r.children=r.children.filter(function(n){return n._baseState.parent===this},this),pi.equal(r.children.length,1,"Root node can have only one child")};rr.prototype._useArgs=function(e){const r=this._baseState,n=e.filter(function(s){return s instanceof this.constructor},this);e=e.filter(function(s){return!(s instanceof this.constructor)},this),n.length!==0&&(pi(r.children===null),r.children=n,n.forEach(function(s){s._baseState.parent=this},this)),e.length!==0&&(pi(r.args===null),r.args=e,r.reverseArgs=e.map(function(s){if(typeof s!="object"||s.constructor!==Object)return s;const i={};return Object.keys(s).forEach(function(o){o==(o|0)&&(o|=0);const f=s[o];i[f]=o}),i}))};Zde.forEach(function(t){rr.prototype[t]=function(){const r=this._baseState;throw new Error(t+" not implemented for encoding: "+r.enc)}});Cz.forEach(function(t){rr.prototype[t]=function(){const r=this._baseState,n=Array.prototype.slice.call(arguments);return pi(r.tag===null),r.tag=t,this._useArgs(n),this}});rr.prototype.use=function(e){pi(e);const r=this._baseState;return pi(r.use===null),r.use=e,this};rr.prototype.optional=function(){const e=this._baseState;return e.optional=!0,this};rr.prototype.def=function(e){const r=this._baseState;return pi(r.default===null),r.default=e,r.optional=!0,this};rr.prototype.explicit=function(e){const r=this._baseState;return pi(r.explicit===null&&r.implicit===null),r.explicit=e,this};rr.prototype.implicit=function(e){const r=this._baseState;return pi(r.explicit===null&&r.implicit===null),r.implicit=e,this};rr.prototype.obj=function(){const e=this._baseState,r=Array.prototype.slice.call(arguments);return e.obj=!0,r.length!==0&&this._useArgs(r),this};rr.prototype.key=function(e){const r=this._baseState;return pi(r.key===null),r.key=e,this};rr.prototype.any=function(){const e=this._baseState;return e.any=!0,this};rr.prototype.choice=function(e){const r=this._baseState;return pi(r.choice===null),r.choice=e,this._useArgs(Object.keys(e).map(function(n){return e[n]})),this};rr.prototype.contains=function(e){const r=this._baseState;return pi(r.use===null),r.contains=e,this};rr.prototype._decode=function(e,r){const n=this._baseState;if(n.parent===null)return e.wrapResult(n.children[0]._decode(e,r));let s=n.default,i=!0,o=null;if(n.key!==null&&(o=e.enterKey(n.key)),n.optional){let h=null;if(n.explicit!==null?h=n.explicit:n.implicit!==null?h=n.implicit:n.tag!==null&&(h=n.tag),h===null&&!n.any){const p=e.save();try{n.choice===null?this._decodeGeneric(n.tag,e,r):this._decodeChoice(e,r),i=!0}catch{i=!1}e.restore(p)}else if(i=this._peekTag(e,h,n.any),e.isError(i))return i}let f;if(n.obj&&i&&(f=e.enterObject()),i){if(n.explicit!==null){const p=this._decodeTag(e,n.explicit);if(e.isError(p))return p;e=p}const h=e.offset;if(n.use===null&&n.choice===null){let p;n.any&&(p=e.save());const b=this._decodeTag(e,n.implicit!==null?n.implicit:n.tag,n.any);if(e.isError(b))return b;n.any?s=e.raw(p):e=b}if(r&&r.track&&n.tag!==null&&r.track(e.path(),h,e.length,"tagged"),r&&r.track&&n.tag!==null&&r.track(e.path(),e.offset,e.length,"content"),n.any||(n.choice===null?s=this._decodeGeneric(n.tag,e,r):s=this._decodeChoice(e,r)),e.isError(s))return s;if(!n.any&&n.choice===null&&n.children!==null&&n.children.forEach(function(b){b._decode(e,r)}),n.contains&&(n.tag==="octstr"||n.tag==="bitstr")){const p=new Wde(s);s=this._getUse(n.contains,e._reporterState.obj)._decode(p,r)}}return n.obj&&i&&(s=e.leaveObject(f)),n.key!==null&&(s!==null||i===!0)?e.leaveKey(o,n.key,s):o!==null&&e.exitKey(o),s};rr.prototype._decodeGeneric=function(e,r,n){const s=this._baseState;return e==="seq"||e==="set"?null:e==="seqof"||e==="setof"?this._decodeList(r,e,s.args[0],n):/str$/.test(e)?this._decodeStr(r,e,n):e==="objid"&&s.args?this._decodeObjid(r,s.args[0],s.args[1],n):e==="objid"?this._decodeObjid(r,null,null,n):e==="gentime"||e==="utctime"?this._decodeTime(r,e,n):e==="null_"?this._decodeNull(r,n):e==="bool"?this._decodeBool(r,n):e==="objDesc"?this._decodeStr(r,e,n):e==="int"||e==="enum"?this._decodeInt(r,s.args&&s.args[0],n):s.use!==null?this._getUse(s.use,r._reporterState.obj)._decode(r,n):r.error("unknown tag: "+e)};rr.prototype._getUse=function(e,r){const n=this._baseState;return n.useDecoder=this._use(e,r),pi(n.useDecoder._baseState.parent===null),n.useDecoder=n.useDecoder._baseState.children[0],n.implicit!==n.useDecoder._baseState.implicit&&(n.useDecoder=n.useDecoder.clone(),n.useDecoder._baseState.implicit=n.implicit),n.useDecoder};rr.prototype._decodeChoice=function(e,r){const n=this._baseState;let s=null,i=!1;return Object.keys(n.choice).some(function(o){const f=e.save(),h=n.choice[o];try{const p=h._decode(e,r);if(e.isError(p))return!1;s={type:o,value:p},i=!0}catch{return e.restore(f),!1}return!0},this),i?s:e.error("Choice not matched")};rr.prototype._createEncoderBuffer=function(e){return new Kde(e,this.reporter)};rr.prototype._encode=function(e,r,n){const s=this._baseState;if(s.default!==null&&s.default===e)return;const i=this._encodeValue(e,r,n);if(i!==void 0&&!this._skipDefault(i,r,n))return i};rr.prototype._encodeValue=function(e,r,n){const s=this._baseState;if(s.parent===null)return s.children[0]._encode(e,r||new Vde);let i=null;if(this.reporter=r,s.optional&&e===void 0)if(s.default!==null)e=s.default;else return;let o=null,f=!1;if(s.any)i=this._createEncoderBuffer(e);else if(s.choice)i=this._encodeChoice(e,r);else if(s.contains)o=this._getUse(s.contains,n)._encode(e,r),f=!0;else if(s.children)o=s.children.map(function(h){if(h._baseState.tag==="null_")return h._encode(null,r,e);if(h._baseState.key===null)return r.error("Child should have a key");const p=r.enterKey(h._baseState.key);if(typeof e!="object")return r.error("Child expected, but input is not object");const b=h._encode(e[h._baseState.key],r,e);return r.leaveKey(p),b},this).filter(function(h){return h}),o=this._createEncoderBuffer(o);else if(s.tag==="seqof"||s.tag==="setof"){if(!(s.args&&s.args.length===1))return r.error("Too many args for : "+s.tag);if(!Array.isArray(e))return r.error("seqof/setof, but data is not Array");const h=this.clone();h._baseState.implicit=null,o=this._createEncoderBuffer(e.map(function(p){const b=this._baseState;return this._getUse(b.args[0],e)._encode(p,r)},h))}else s.use!==null?i=this._getUse(s.use,n)._encode(e,r):(o=this._encodePrimitive(s.tag,e),f=!0);if(!s.any&&s.choice===null){const h=s.implicit!==null?s.implicit:s.tag,p=s.implicit===null?"universal":"context";h===null?s.use===null&&r.error("Tag could be omitted only for .use()"):s.use===null&&(i=this._encodeComposite(h,f,p,o))}return s.explicit!==null&&(i=this._encodeComposite(s.explicit,!1,"context",i)),i};rr.prototype._encodeChoice=function(e,r){const n=this._baseState,s=n.choice[e.type];return s||pi(!1,e.type+" not found in "+JSON.stringify(Object.keys(n.choice))),s._encode(e.value,r)};rr.prototype._encodePrimitive=function(e,r){const n=this._baseState;if(/str$/.test(e))return this._encodeStr(r,e);if(e==="objid"&&n.args)return this._encodeObjid(r,n.reverseArgs[0],n.args[1]);if(e==="objid")return this._encodeObjid(r,null,null);if(e==="gentime"||e==="utctime")return this._encodeTime(r,e);if(e==="null_")return this._encodeNull();if(e==="int"||e==="enum")return this._encodeInt(r,n.args&&n.reverseArgs[0]);if(e==="bool")return this._encodeBool(r);if(e==="objDesc")return this._encodeStr(r,e);throw new Error("Unsupported tag: "+e)};rr.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)};rr.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)};var Hx={};(function(t){function e(r){const n={};return Object.keys(r).forEach(function(s){(s|0)==s&&(s=s|0);const i=r[s];n[i]=s}),n}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=e(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=e(t.tag)})(Hx);const Yde=It,vf=mS.Buffer,Iz=gS,C8=Hx;function Tz(t){this.enc="der",this.name=t.name,this.entity=t,this.tree=new ra,this.tree._init(t.body)}var kz=Tz;Tz.prototype.encode=function(e,r){return this.tree._encode(e,r).join()};function ra(t){Iz.call(this,"der",t)}Yde(ra,Iz);ra.prototype._encodeComposite=function(e,r,n,s){const i=Xde(e,r,n,this.reporter);if(s.length<128){const h=vf.alloc(2);return h[0]=i,h[1]=s.length,this._createEncoderBuffer([h,s])}let o=1;for(let h=s.length;h>=256;h>>=8)o++;const f=vf.alloc(1+1+o);f[0]=i,f[1]=128|o;for(let h=1+o,p=s.length;p>0;h--,p>>=8)f[h]=p&255;return this._createEncoderBuffer([f,s])};ra.prototype._encodeStr=function(e,r){if(r==="bitstr")return this._createEncoderBuffer([e.unused|0,e.data]);if(r==="bmpstr"){const n=vf.alloc(e.length*2);for(let s=0;s=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,e[0]*40+e[1])}let s=0;for(let f=0;f=128;h>>=7)s++}const i=vf.alloc(s);let o=i.length-1;for(let f=e.length-1;f>=0;f--){let h=e[f];for(i[o--]=h&127;(h>>=7)>0;)i[o--]=128|h&127}return this._createEncoderBuffer(i)};function gs(t){return t<10?"0"+t:t}ra.prototype._encodeTime=function(e,r){let n;const s=new Date(e);return r==="gentime"?n=[gs(s.getUTCFullYear()),gs(s.getUTCMonth()+1),gs(s.getUTCDate()),gs(s.getUTCHours()),gs(s.getUTCMinutes()),gs(s.getUTCSeconds()),"Z"].join(""):r==="utctime"?n=[gs(s.getUTCFullYear()%100),gs(s.getUTCMonth()+1),gs(s.getUTCDate()),gs(s.getUTCHours()),gs(s.getUTCMinutes()),gs(s.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+r+" time is not supported yet"),this._encodeStr(n,"octstr")};ra.prototype._encodeNull=function(){return this._createEncoderBuffer("")};ra.prototype._encodeInt=function(e,r){if(typeof e=="string"){if(!r)return this.reporter.error("String int or enum given, but no values map");if(!r.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=r[e]}if(typeof e!="number"&&!vf.isBuffer(e)){const i=e.toArray();!e.sign&&i[0]&128&&i.unshift(0),e=vf.from(i)}if(vf.isBuffer(e)){let i=e.length;e.length===0&&i++;const o=vf.alloc(i);return e.copy(o),e.length===0&&(o[0]=0),this._createEncoderBuffer(o)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);let n=1;for(let i=e;i>=256;i>>=8)n++;const s=new Array(n);for(let i=s.length-1;i>=0;i--)s[i]=e&255,e>>=8;return s[0]&128&&s.unshift(0),this._createEncoderBuffer(vf.from(s))};ra.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)};ra.prototype._use=function(e,r){return typeof e=="function"&&(e=e(r)),e._getEncoder("der").tree};ra.prototype._skipDefault=function(e,r,n){const s=this._baseState;let i;if(s.default===null)return!1;const o=e.join();if(s.defaultBuffer===void 0&&(s.defaultBuffer=this._encodeValue(s.default,r,n).join()),o.length!==s.defaultBuffer.length)return!1;for(i=0;i=31?n.error("Multi-octet tag encoding unsupported"):(e||(s|=32),s|=C8.tagClassByName[r||"universal"]<<6,s)}const epe=It,yS=kz;function bS(t){yS.call(this,t),this.enc="pem"}epe(bS,yS);var tpe=bS;bS.prototype.encode=function(e,r){const s=yS.prototype.encode.call(this,e).toString("base64"),i=["-----BEGIN "+r.label+"-----"];for(let o=0;o>6],s=(r&32)===0;if((r&31)===31){let o=r;for(r=0;(o&128)===128;){if(o=t.readUInt8(e),t.isError(o))return o;r<<=7,r|=o&127}}else r&=31;const i=ok.tag[r];return{cls:n,primitive:s,tag:r,tagStr:i}}function Nz(t,e,r){let n=t.readUInt8(r);if(t.isError(n))return n;if(!e&&n===128)return null;if(!(n&128))return n;const s=n&127;if(s>4)return t.error("length octect is too long");n=0;for(let i=0;i0&&B.ishrn(N),B}function S(C,T){C=_(C,T),C=C.mod(T);var B=t.from(C.toArray());if(B.length=0)throw new Error("invalid sig")}return I8=i,I8}var T8,lk;function $pe(){if(lk)return T8;lk=1;var t=Tt.Buffer,e=By,r=qF,n=It,s=Lpe(),i=Dpe(),o=uU;Object.keys(o).forEach(function(v){o[v].id=t.from(o[v].id,"hex"),o[v.toLowerCase()]=o[v]});function f(v){r.Writable.call(this);var E=o[v];if(!E)throw new Error("Unknown message digest");this._hashType=E.hash,this._hash=e(E.hash),this._tag=E.id,this._signType=E.sign}n(f,r.Writable),f.prototype._write=function(E,_,S){this._hash.update(E),S()},f.prototype.update=function(E,_){return this._hash.update(typeof E=="string"?t.from(E,_):E),this},f.prototype.sign=function(E,_){this.end();var S=this._hash.digest(),P=s(S,E,this._hashType,this._signType,this._tag);return _?P.toString(_):P};function h(v){r.Writable.call(this);var E=o[v];if(!E)throw new Error("Unknown message digest");this._hash=e(E.hash),this._tag=E.id,this._signType=E.sign}n(h,r.Writable),h.prototype._write=function(E,_,S){this._hash.update(E),S()},h.prototype.update=function(E,_){return this._hash.update(typeof E=="string"?t.from(E,_):E),this},h.prototype.verify=function(E,_,S){var P=typeof _=="string"?t.from(_,S):_;this.end();var I=this._hash.digest();return i(P,I,E,this._signType,this._tag)};function p(v){return new f(v)}function b(v){return new h(v)}return T8={Sign:p,Verify:b,createSign:p,createVerify:b},T8}var MS={exports:{}};MS.exports;(function(t){(function(e,r){function n(w,a){if(!w)throw new Error(a||"Assertion failed")}function s(w,a){w.super_=a;var u=function(){};u.prototype=a.prototype,w.prototype=new u,w.prototype.constructor=w}function i(w,a,u){if(i.isBN(w))return w;this.negative=0,this.words=null,this.length=0,this.red=null,w!==null&&((a==="le"||a==="be")&&(u=a,a=10),this._init(w||0,a||10,u||"be"))}typeof e=="object"?e.exports=i:r.BN=i,i.BN=i,i.wordSize=26;var o;try{typeof window<"u"&&typeof window.Buffer<"u"?o=window.Buffer:o=Ln.Buffer}catch{}i.isBN=function(a){return a instanceof i?!0:a!==null&&typeof a=="object"&&a.constructor.wordSize===i.wordSize&&Array.isArray(a.words)},i.max=function(a,u){return a.cmp(u)>0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(MS);var Fpe=MS.exports,k8,hk;function Upe(){if(hk)return k8;hk=1;var t=lS(),e=Fpe;k8=function(o){return new n(o)};var r={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};r.p224=r.secp224r1,r.p256=r.secp256r1=r.prime256v1,r.p192=r.secp192r1=r.prime192v1,r.p384=r.secp384r1,r.p521=r.secp521r1;function n(i){this.curveType=r[i],this.curveType||(this.curveType={name:i}),this.curve=new t.ec(this.curveType.name),this.keys=void 0}n.prototype.generateKeys=function(i,o){return this.keys=this.curve.genKeyPair(),this.getPublicKey(i,o)},n.prototype.computeSecret=function(i,o,f){o=o||"utf8",Ve.Buffer.isBuffer(i)||(i=new Ve.Buffer(i,o));var h=this.curve.keyFromPublic(i).getPublic(),p=h.mul(this.keys.getPrivate()).getX();return s(p,f,this.curveType.byteLength)},n.prototype.getPublicKey=function(i,o){var f=this.keys.getPublic(o==="compressed",!0);return o==="hybrid"&&(f[f.length-1]%2?f[0]=7:f[0]=6),s(f,i)},n.prototype.getPrivateKey=function(i){return s(this.keys.getPrivate(),i)},n.prototype.setPublicKey=function(i,o){return o=o||"utf8",Ve.Buffer.isBuffer(i)||(i=new Ve.Buffer(i,o)),this.keys._importPublic(i),this},n.prototype.setPrivateKey=function(i,o){o=o||"utf8",Ve.Buffer.isBuffer(i)||(i=new Ve.Buffer(i,o));var f=new e(i);return f=f.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(f),this};function s(i,o,f){Array.isArray(i)||(i=i.toArray());var h=new Ve.Buffer(i);if(f&&h.length0?a:u},i.min=function(a,u){return a.cmp(u)<0?a:u},i.prototype._init=function(a,u,l){if(typeof a=="number")return this._initNumber(a,u,l);if(typeof a=="object")return this._initArray(a,u,l);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),a=a.toString().replace(/\s+/g,"");var d=0;a[0]==="-"&&(d++,this.negative=1),d=0;d-=3)x=a[d]|a[d-1]<<8|a[d-2]<<16,this.words[m]|=x<>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);else if(l==="le")for(d=0,m=0;d>>26-A&67108863,A+=24,A>=26&&(A-=26,m++);return this.strip()};function f(w,a){var u=w.charCodeAt(a);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function h(w,a,u){var l=f(w,u);return u-1>=a&&(l|=f(w,u-1)<<4),l}i.prototype._parseHex=function(a,u,l){this.length=Math.ceil((a.length-u)/6),this.words=new Array(this.length);for(var d=0;d=u;d-=2)A=h(a,u,d)<=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8;else{var y=a.length-u;for(d=y%2===0?u+1:u;d=18?(m-=18,x+=1,this.words[x]|=A>>>26):m+=8}this.strip()};function p(w,a,u,l){for(var d=0,m=Math.min(w.length,u),x=a;x=49?d+=A-49+10:A>=17?d+=A-17+10:d+=A}return d}i.prototype._parseBase=function(a,u,l){this.words=[0],this.length=1;for(var d=0,m=1;m<=67108863;m*=u)d++;d--,m=m/u|0;for(var x=a.length-l,A=x%d,y=Math.min(x,x-A)+l,c=0,g=l;g1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var b=["","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"],v=[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],E=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(a,u){a=a||10,u=u|0||1;var l;if(a===16||a==="hex"){l="";for(var d=0,m=0,x=0;x>>24-d&16777215,m!==0||x!==this.length-1?l=b[6-y.length]+y+l:l=y+l,d+=2,d>=26&&(d-=26,x--)}for(m!==0&&(l=m.toString(16)+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(a===(a|0)&&a>=2&&a<=36){var c=v[a],g=E[a];l="";var M=this.clone();for(M.negative=0;!M.isZero();){var R=M.modn(g).toString(a);M=M.idivn(g),M.isZero()?l=R+l:l=b[c-R.length]+R+l}for(this.isZero()&&(l="0"+l);l.length%u!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var a=this.words[0];return this.length===2?a+=this.words[1]*67108864:this.length===3&&this.words[2]===1?a+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-a:a},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(a,u){return n(typeof o<"u"),this.toArrayLike(o,a,u)},i.prototype.toArray=function(a,u){return this.toArrayLike(Array,a,u)},i.prototype.toArrayLike=function(a,u,l){var d=this.byteLength(),m=l||Math.max(1,d);n(d<=m,"byte array longer than desired length"),n(m>0,"Requested array length <= 0"),this.strip();var x=u==="le",A=new a(m),y,c,g=this.clone();if(x){for(c=0;!g.isZero();c++)y=g.andln(255),g.iushrn(8),A[c]=y;for(;c=4096&&(l+=13,u>>>=13),u>=64&&(l+=7,u>>>=7),u>=8&&(l+=4,u>>>=4),u>=2&&(l+=2,u>>>=2),l+u},i.prototype._zeroBits=function(a){if(a===0)return 26;var u=a,l=0;return u&8191||(l+=13,u>>>=13),u&127||(l+=7,u>>>=7),u&15||(l+=4,u>>>=4),u&3||(l+=2,u>>>=2),u&1||l++,l},i.prototype.bitLength=function(){var a=this.words[this.length-1],u=this._countBits(a);return(this.length-1)*26+u};function _(w){for(var a=new Array(w.bitLength()),u=0;u>>d}return a}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var a=0,u=0;ua.length?this.clone().ior(a):a.clone().ior(this)},i.prototype.uor=function(a){return this.length>a.length?this.clone().iuor(a):a.clone().iuor(this)},i.prototype.iuand=function(a){var u;this.length>a.length?u=a:u=this;for(var l=0;la.length?this.clone().iand(a):a.clone().iand(this)},i.prototype.uand=function(a){return this.length>a.length?this.clone().iuand(a):a.clone().iuand(this)},i.prototype.iuxor=function(a){var u,l;this.length>a.length?(u=this,l=a):(u=a,l=this);for(var d=0;da.length?this.clone().ixor(a):a.clone().ixor(this)},i.prototype.uxor=function(a){return this.length>a.length?this.clone().iuxor(a):a.clone().iuxor(this)},i.prototype.inotn=function(a){n(typeof a=="number"&&a>=0);var u=Math.ceil(a/26)|0,l=a%26;this._expand(u),l>0&&u--;for(var d=0;d0&&(this.words[d]=~this.words[d]&67108863>>26-l),this.strip()},i.prototype.notn=function(a){return this.clone().inotn(a)},i.prototype.setn=function(a,u){n(typeof a=="number"&&a>=0);var l=a/26|0,d=a%26;return this._expand(l+1),u?this.words[l]=this.words[l]|1<a.length?(l=this,d=a):(l=a,d=this);for(var m=0,x=0;x>>26;for(;m!==0&&x>>26;if(this.length=l.length,m!==0)this.words[this.length]=m,this.length++;else if(l!==this)for(;xa.length?this.clone().iadd(a):a.clone().iadd(this)},i.prototype.isub=function(a){if(a.negative!==0){a.negative=0;var u=this.iadd(a);return a.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(a),this.negative=1,this._normSign();var l=this.cmp(a);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var d,m;l>0?(d=this,m=a):(d=a,m=this);for(var x=0,A=0;A>26,this.words[A]=u&67108863;for(;x!==0&&A>26,this.words[A]=u&67108863;if(x===0&&A>>26,M=y&67108863,R=Math.min(c,a.length-1),L=Math.max(0,c-w.length+1);L<=R;L++){var k=c-L|0;d=w.words[k]|0,m=a.words[L]|0,x=d*m+M,g+=x/67108864|0,M=x&67108863}u.words[c]=M|0,y=g|0}return y!==0?u.words[c]=y|0:u.length--,u.strip()}var P=function(a,u,l){var d=a.words,m=u.words,x=l.words,A=0,y,c,g,M=d[0]|0,R=M&8191,L=M>>>13,k=d[1]|0,D=k&8191,U=k>>>13,V=d[2]|0,G=V&8191,Y=V>>>13,q=d[3]|0,z=q&8191,ee=q>>>13,re=d[4]|0,ie=re&8191,ae=re>>>13,je=d[5]|0,he=je&8191,oe=je>>>13,Qe=d[6]|0,ge=Qe&8191,be=Qe>>>13,ot=d[7]|0,ye=ot&8191,xe=ot>>>13,at=d[8]|0,j=at&8191,O=at>>>13,F=d[9]|0,W=F&8191,te=F>>>13,le=m[0]|0,ne=le&8191,pe=le>>>13,Ye=m[1]|0,de=Ye&8191,ve=Ye>>>13,Je=m[2]|0,we=Je&8191,Re=Je>>>13,yt=m[3]|0,Ae=yt&8191,Be=yt>>>13,bt=m[4]|0,Ee=bt&8191,Oe=bt>>>13,vt=m[5]|0,Me=vt&8191,Ne=vt>>>13,xt=m[6]|0,Se=xt&8191,Le=xt>>>13,wt=m[7]|0,_e=wt&8191,De=wt>>>13,At=m[8]|0,Pe=At&8191,$e=At>>>13,Et=m[9]|0,Ce=Et&8191,Fe=Et>>>13;l.negative=a.negative^u.negative,l.length=19,y=Math.imul(R,ne),c=Math.imul(R,pe),c=c+Math.imul(L,ne)|0,g=Math.imul(L,pe);var ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(D,ne),c=Math.imul(D,pe),c=c+Math.imul(U,ne)|0,g=Math.imul(U,pe),y=y+Math.imul(R,de)|0,c=c+Math.imul(R,ve)|0,c=c+Math.imul(L,de)|0,g=g+Math.imul(L,ve)|0;var dt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dt>>>26)|0,dt&=67108863,y=Math.imul(G,ne),c=Math.imul(G,pe),c=c+Math.imul(Y,ne)|0,g=Math.imul(Y,pe),y=y+Math.imul(D,de)|0,c=c+Math.imul(D,ve)|0,c=c+Math.imul(U,de)|0,g=g+Math.imul(U,ve)|0,y=y+Math.imul(R,we)|0,c=c+Math.imul(R,Re)|0,c=c+Math.imul(L,we)|0,g=g+Math.imul(L,Re)|0;var jt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(jt>>>26)|0,jt&=67108863,y=Math.imul(z,ne),c=Math.imul(z,pe),c=c+Math.imul(ee,ne)|0,g=Math.imul(ee,pe),y=y+Math.imul(G,de)|0,c=c+Math.imul(G,ve)|0,c=c+Math.imul(Y,de)|0,g=g+Math.imul(Y,ve)|0,y=y+Math.imul(D,we)|0,c=c+Math.imul(D,Re)|0,c=c+Math.imul(U,we)|0,g=g+Math.imul(U,Re)|0,y=y+Math.imul(R,Ae)|0,c=c+Math.imul(R,Be)|0,c=c+Math.imul(L,Ae)|0,g=g+Math.imul(L,Be)|0;var Ht=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,y=Math.imul(ie,ne),c=Math.imul(ie,pe),c=c+Math.imul(ae,ne)|0,g=Math.imul(ae,pe),y=y+Math.imul(z,de)|0,c=c+Math.imul(z,ve)|0,c=c+Math.imul(ee,de)|0,g=g+Math.imul(ee,ve)|0,y=y+Math.imul(G,we)|0,c=c+Math.imul(G,Re)|0,c=c+Math.imul(Y,we)|0,g=g+Math.imul(Y,Re)|0,y=y+Math.imul(D,Ae)|0,c=c+Math.imul(D,Be)|0,c=c+Math.imul(U,Ae)|0,g=g+Math.imul(U,Be)|0,y=y+Math.imul(R,Ee)|0,c=c+Math.imul(R,Oe)|0,c=c+Math.imul(L,Ee)|0,g=g+Math.imul(L,Oe)|0;var qt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(qt>>>26)|0,qt&=67108863,y=Math.imul(he,ne),c=Math.imul(he,pe),c=c+Math.imul(oe,ne)|0,g=Math.imul(oe,pe),y=y+Math.imul(ie,de)|0,c=c+Math.imul(ie,ve)|0,c=c+Math.imul(ae,de)|0,g=g+Math.imul(ae,ve)|0,y=y+Math.imul(z,we)|0,c=c+Math.imul(z,Re)|0,c=c+Math.imul(ee,we)|0,g=g+Math.imul(ee,Re)|0,y=y+Math.imul(G,Ae)|0,c=c+Math.imul(G,Be)|0,c=c+Math.imul(Y,Ae)|0,g=g+Math.imul(Y,Be)|0,y=y+Math.imul(D,Ee)|0,c=c+Math.imul(D,Oe)|0,c=c+Math.imul(U,Ee)|0,g=g+Math.imul(U,Oe)|0,y=y+Math.imul(R,Me)|0,c=c+Math.imul(R,Ne)|0,c=c+Math.imul(L,Me)|0,g=g+Math.imul(L,Ne)|0;var Gt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Gt>>>26)|0,Gt&=67108863,y=Math.imul(ge,ne),c=Math.imul(ge,pe),c=c+Math.imul(be,ne)|0,g=Math.imul(be,pe),y=y+Math.imul(he,de)|0,c=c+Math.imul(he,ve)|0,c=c+Math.imul(oe,de)|0,g=g+Math.imul(oe,ve)|0,y=y+Math.imul(ie,we)|0,c=c+Math.imul(ie,Re)|0,c=c+Math.imul(ae,we)|0,g=g+Math.imul(ae,Re)|0,y=y+Math.imul(z,Ae)|0,c=c+Math.imul(z,Be)|0,c=c+Math.imul(ee,Ae)|0,g=g+Math.imul(ee,Be)|0,y=y+Math.imul(G,Ee)|0,c=c+Math.imul(G,Oe)|0,c=c+Math.imul(Y,Ee)|0,g=g+Math.imul(Y,Oe)|0,y=y+Math.imul(D,Me)|0,c=c+Math.imul(D,Ne)|0,c=c+Math.imul(U,Me)|0,g=g+Math.imul(U,Ne)|0,y=y+Math.imul(R,Se)|0,c=c+Math.imul(R,Le)|0,c=c+Math.imul(L,Se)|0,g=g+Math.imul(L,Le)|0;var Vt=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(Vt>>>26)|0,Vt&=67108863,y=Math.imul(ye,ne),c=Math.imul(ye,pe),c=c+Math.imul(xe,ne)|0,g=Math.imul(xe,pe),y=y+Math.imul(ge,de)|0,c=c+Math.imul(ge,ve)|0,c=c+Math.imul(be,de)|0,g=g+Math.imul(be,ve)|0,y=y+Math.imul(he,we)|0,c=c+Math.imul(he,Re)|0,c=c+Math.imul(oe,we)|0,g=g+Math.imul(oe,Re)|0,y=y+Math.imul(ie,Ae)|0,c=c+Math.imul(ie,Be)|0,c=c+Math.imul(ae,Ae)|0,g=g+Math.imul(ae,Be)|0,y=y+Math.imul(z,Ee)|0,c=c+Math.imul(z,Oe)|0,c=c+Math.imul(ee,Ee)|0,g=g+Math.imul(ee,Oe)|0,y=y+Math.imul(G,Me)|0,c=c+Math.imul(G,Ne)|0,c=c+Math.imul(Y,Me)|0,g=g+Math.imul(Y,Ne)|0,y=y+Math.imul(D,Se)|0,c=c+Math.imul(D,Le)|0,c=c+Math.imul(U,Se)|0,g=g+Math.imul(U,Le)|0,y=y+Math.imul(R,_e)|0,c=c+Math.imul(R,De)|0,c=c+Math.imul(L,_e)|0,g=g+Math.imul(L,De)|0;var nr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(nr>>>26)|0,nr&=67108863,y=Math.imul(j,ne),c=Math.imul(j,pe),c=c+Math.imul(O,ne)|0,g=Math.imul(O,pe),y=y+Math.imul(ye,de)|0,c=c+Math.imul(ye,ve)|0,c=c+Math.imul(xe,de)|0,g=g+Math.imul(xe,ve)|0,y=y+Math.imul(ge,we)|0,c=c+Math.imul(ge,Re)|0,c=c+Math.imul(be,we)|0,g=g+Math.imul(be,Re)|0,y=y+Math.imul(he,Ae)|0,c=c+Math.imul(he,Be)|0,c=c+Math.imul(oe,Ae)|0,g=g+Math.imul(oe,Be)|0,y=y+Math.imul(ie,Ee)|0,c=c+Math.imul(ie,Oe)|0,c=c+Math.imul(ae,Ee)|0,g=g+Math.imul(ae,Oe)|0,y=y+Math.imul(z,Me)|0,c=c+Math.imul(z,Ne)|0,c=c+Math.imul(ee,Me)|0,g=g+Math.imul(ee,Ne)|0,y=y+Math.imul(G,Se)|0,c=c+Math.imul(G,Le)|0,c=c+Math.imul(Y,Se)|0,g=g+Math.imul(Y,Le)|0,y=y+Math.imul(D,_e)|0,c=c+Math.imul(D,De)|0,c=c+Math.imul(U,_e)|0,g=g+Math.imul(U,De)|0,y=y+Math.imul(R,Pe)|0,c=c+Math.imul(R,$e)|0,c=c+Math.imul(L,Pe)|0,g=g+Math.imul(L,$e)|0;var ir=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ir>>>26)|0,ir&=67108863,y=Math.imul(W,ne),c=Math.imul(W,pe),c=c+Math.imul(te,ne)|0,g=Math.imul(te,pe),y=y+Math.imul(j,de)|0,c=c+Math.imul(j,ve)|0,c=c+Math.imul(O,de)|0,g=g+Math.imul(O,ve)|0,y=y+Math.imul(ye,we)|0,c=c+Math.imul(ye,Re)|0,c=c+Math.imul(xe,we)|0,g=g+Math.imul(xe,Re)|0,y=y+Math.imul(ge,Ae)|0,c=c+Math.imul(ge,Be)|0,c=c+Math.imul(be,Ae)|0,g=g+Math.imul(be,Be)|0,y=y+Math.imul(he,Ee)|0,c=c+Math.imul(he,Oe)|0,c=c+Math.imul(oe,Ee)|0,g=g+Math.imul(oe,Oe)|0,y=y+Math.imul(ie,Me)|0,c=c+Math.imul(ie,Ne)|0,c=c+Math.imul(ae,Me)|0,g=g+Math.imul(ae,Ne)|0,y=y+Math.imul(z,Se)|0,c=c+Math.imul(z,Le)|0,c=c+Math.imul(ee,Se)|0,g=g+Math.imul(ee,Le)|0,y=y+Math.imul(G,_e)|0,c=c+Math.imul(G,De)|0,c=c+Math.imul(Y,_e)|0,g=g+Math.imul(Y,De)|0,y=y+Math.imul(D,Pe)|0,c=c+Math.imul(D,$e)|0,c=c+Math.imul(U,Pe)|0,g=g+Math.imul(U,$e)|0,y=y+Math.imul(R,Ce)|0,c=c+Math.imul(R,Fe)|0,c=c+Math.imul(L,Ce)|0,g=g+Math.imul(L,Fe)|0;var sr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(sr>>>26)|0,sr&=67108863,y=Math.imul(W,de),c=Math.imul(W,ve),c=c+Math.imul(te,de)|0,g=Math.imul(te,ve),y=y+Math.imul(j,we)|0,c=c+Math.imul(j,Re)|0,c=c+Math.imul(O,we)|0,g=g+Math.imul(O,Re)|0,y=y+Math.imul(ye,Ae)|0,c=c+Math.imul(ye,Be)|0,c=c+Math.imul(xe,Ae)|0,g=g+Math.imul(xe,Be)|0,y=y+Math.imul(ge,Ee)|0,c=c+Math.imul(ge,Oe)|0,c=c+Math.imul(be,Ee)|0,g=g+Math.imul(be,Oe)|0,y=y+Math.imul(he,Me)|0,c=c+Math.imul(he,Ne)|0,c=c+Math.imul(oe,Me)|0,g=g+Math.imul(oe,Ne)|0,y=y+Math.imul(ie,Se)|0,c=c+Math.imul(ie,Le)|0,c=c+Math.imul(ae,Se)|0,g=g+Math.imul(ae,Le)|0,y=y+Math.imul(z,_e)|0,c=c+Math.imul(z,De)|0,c=c+Math.imul(ee,_e)|0,g=g+Math.imul(ee,De)|0,y=y+Math.imul(G,Pe)|0,c=c+Math.imul(G,$e)|0,c=c+Math.imul(Y,Pe)|0,g=g+Math.imul(Y,$e)|0,y=y+Math.imul(D,Ce)|0,c=c+Math.imul(D,Fe)|0,c=c+Math.imul(U,Ce)|0,g=g+Math.imul(U,Fe)|0;var or=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(or>>>26)|0,or&=67108863,y=Math.imul(W,we),c=Math.imul(W,Re),c=c+Math.imul(te,we)|0,g=Math.imul(te,Re),y=y+Math.imul(j,Ae)|0,c=c+Math.imul(j,Be)|0,c=c+Math.imul(O,Ae)|0,g=g+Math.imul(O,Be)|0,y=y+Math.imul(ye,Ee)|0,c=c+Math.imul(ye,Oe)|0,c=c+Math.imul(xe,Ee)|0,g=g+Math.imul(xe,Oe)|0,y=y+Math.imul(ge,Me)|0,c=c+Math.imul(ge,Ne)|0,c=c+Math.imul(be,Me)|0,g=g+Math.imul(be,Ne)|0,y=y+Math.imul(he,Se)|0,c=c+Math.imul(he,Le)|0,c=c+Math.imul(oe,Se)|0,g=g+Math.imul(oe,Le)|0,y=y+Math.imul(ie,_e)|0,c=c+Math.imul(ie,De)|0,c=c+Math.imul(ae,_e)|0,g=g+Math.imul(ae,De)|0,y=y+Math.imul(z,Pe)|0,c=c+Math.imul(z,$e)|0,c=c+Math.imul(ee,Pe)|0,g=g+Math.imul(ee,$e)|0,y=y+Math.imul(G,Ce)|0,c=c+Math.imul(G,Fe)|0,c=c+Math.imul(Y,Ce)|0,g=g+Math.imul(Y,Fe)|0;var ar=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ar>>>26)|0,ar&=67108863,y=Math.imul(W,Ae),c=Math.imul(W,Be),c=c+Math.imul(te,Ae)|0,g=Math.imul(te,Be),y=y+Math.imul(j,Ee)|0,c=c+Math.imul(j,Oe)|0,c=c+Math.imul(O,Ee)|0,g=g+Math.imul(O,Oe)|0,y=y+Math.imul(ye,Me)|0,c=c+Math.imul(ye,Ne)|0,c=c+Math.imul(xe,Me)|0,g=g+Math.imul(xe,Ne)|0,y=y+Math.imul(ge,Se)|0,c=c+Math.imul(ge,Le)|0,c=c+Math.imul(be,Se)|0,g=g+Math.imul(be,Le)|0,y=y+Math.imul(he,_e)|0,c=c+Math.imul(he,De)|0,c=c+Math.imul(oe,_e)|0,g=g+Math.imul(oe,De)|0,y=y+Math.imul(ie,Pe)|0,c=c+Math.imul(ie,$e)|0,c=c+Math.imul(ae,Pe)|0,g=g+Math.imul(ae,$e)|0,y=y+Math.imul(z,Ce)|0,c=c+Math.imul(z,Fe)|0,c=c+Math.imul(ee,Ce)|0,g=g+Math.imul(ee,Fe)|0;var fr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(fr>>>26)|0,fr&=67108863,y=Math.imul(W,Ee),c=Math.imul(W,Oe),c=c+Math.imul(te,Ee)|0,g=Math.imul(te,Oe),y=y+Math.imul(j,Me)|0,c=c+Math.imul(j,Ne)|0,c=c+Math.imul(O,Me)|0,g=g+Math.imul(O,Ne)|0,y=y+Math.imul(ye,Se)|0,c=c+Math.imul(ye,Le)|0,c=c+Math.imul(xe,Se)|0,g=g+Math.imul(xe,Le)|0,y=y+Math.imul(ge,_e)|0,c=c+Math.imul(ge,De)|0,c=c+Math.imul(be,_e)|0,g=g+Math.imul(be,De)|0,y=y+Math.imul(he,Pe)|0,c=c+Math.imul(he,$e)|0,c=c+Math.imul(oe,Pe)|0,g=g+Math.imul(oe,$e)|0,y=y+Math.imul(ie,Ce)|0,c=c+Math.imul(ie,Fe)|0,c=c+Math.imul(ae,Ce)|0,g=g+Math.imul(ae,Fe)|0;var cr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(cr>>>26)|0,cr&=67108863,y=Math.imul(W,Me),c=Math.imul(W,Ne),c=c+Math.imul(te,Me)|0,g=Math.imul(te,Ne),y=y+Math.imul(j,Se)|0,c=c+Math.imul(j,Le)|0,c=c+Math.imul(O,Se)|0,g=g+Math.imul(O,Le)|0,y=y+Math.imul(ye,_e)|0,c=c+Math.imul(ye,De)|0,c=c+Math.imul(xe,_e)|0,g=g+Math.imul(xe,De)|0,y=y+Math.imul(ge,Pe)|0,c=c+Math.imul(ge,$e)|0,c=c+Math.imul(be,Pe)|0,g=g+Math.imul(be,$e)|0,y=y+Math.imul(he,Ce)|0,c=c+Math.imul(he,Fe)|0,c=c+Math.imul(oe,Ce)|0,g=g+Math.imul(oe,Fe)|0;var ur=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(ur>>>26)|0,ur&=67108863,y=Math.imul(W,Se),c=Math.imul(W,Le),c=c+Math.imul(te,Se)|0,g=Math.imul(te,Le),y=y+Math.imul(j,_e)|0,c=c+Math.imul(j,De)|0,c=c+Math.imul(O,_e)|0,g=g+Math.imul(O,De)|0,y=y+Math.imul(ye,Pe)|0,c=c+Math.imul(ye,$e)|0,c=c+Math.imul(xe,Pe)|0,g=g+Math.imul(xe,$e)|0,y=y+Math.imul(ge,Ce)|0,c=c+Math.imul(ge,Fe)|0,c=c+Math.imul(be,Ce)|0,g=g+Math.imul(be,Fe)|0;var lr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(lr>>>26)|0,lr&=67108863,y=Math.imul(W,_e),c=Math.imul(W,De),c=c+Math.imul(te,_e)|0,g=Math.imul(te,De),y=y+Math.imul(j,Pe)|0,c=c+Math.imul(j,$e)|0,c=c+Math.imul(O,Pe)|0,g=g+Math.imul(O,$e)|0,y=y+Math.imul(ye,Ce)|0,c=c+Math.imul(ye,Fe)|0,c=c+Math.imul(xe,Ce)|0,g=g+Math.imul(xe,Fe)|0;var hr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(hr>>>26)|0,hr&=67108863,y=Math.imul(W,Pe),c=Math.imul(W,$e),c=c+Math.imul(te,Pe)|0,g=Math.imul(te,$e),y=y+Math.imul(j,Ce)|0,c=c+Math.imul(j,Fe)|0,c=c+Math.imul(O,Ce)|0,g=g+Math.imul(O,Fe)|0;var dr=(A+y|0)+((c&8191)<<13)|0;A=(g+(c>>>13)|0)+(dr>>>26)|0,dr&=67108863,y=Math.imul(W,Ce),c=Math.imul(W,Fe),c=c+Math.imul(te,Ce)|0,g=Math.imul(te,Fe);var pr=(A+y|0)+((c&8191)<<13)|0;return A=(g+(c>>>13)|0)+(pr>>>26)|0,pr&=67108863,x[0]=ht,x[1]=dt,x[2]=jt,x[3]=Ht,x[4]=qt,x[5]=Gt,x[6]=Vt,x[7]=nr,x[8]=ir,x[9]=sr,x[10]=or,x[11]=ar,x[12]=fr,x[13]=cr,x[14]=ur,x[15]=lr,x[16]=hr,x[17]=dr,x[18]=pr,A!==0&&(x[19]=A,l.length++),l};Math.imul||(P=S);function I(w,a,u){u.negative=a.negative^w.negative,u.length=w.length+a.length;for(var l=0,d=0,m=0;m>>26)|0,d+=x>>>26,x&=67108863}u.words[m]=A,l=x,x=d}return l!==0?u.words[m]=l:u.length--,u.strip()}function C(w,a,u){var l=new T;return l.mulp(w,a,u)}i.prototype.mulTo=function(a,u){var l,d=this.length+a.length;return this.length===10&&a.length===10?l=P(this,a,u):d<63?l=S(this,a,u):d<1024?l=I(this,a,u):l=C(this,a,u),l};function T(w,a){this.x=w,this.y=a}T.prototype.makeRBT=function(a){for(var u=new Array(a),l=i.prototype._countBits(a)-1,d=0;d>=1;return d},T.prototype.permute=function(a,u,l,d,m,x){for(var A=0;A>>1)m++;return 1<>>13,l[2*x+1]=m&8191,m=m>>>13;for(x=2*u;x>=26,u+=d/67108864|0,u+=m>>>26,this.words[l]=m&67108863}return u!==0&&(this.words[l]=u,this.length++),this},i.prototype.muln=function(a){return this.clone().imuln(a)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(a){var u=_(a);if(u.length===0)return new i(1);for(var l=this,d=0;d=0);var u=a%26,l=(a-u)/26,d=67108863>>>26-u<<26-u,m;if(u!==0){var x=0;for(m=0;m>>26-u}x&&(this.words[m]=x,this.length++)}if(l!==0){for(m=this.length-1;m>=0;m--)this.words[m+l]=this.words[m];for(m=0;m=0);var d;u?d=(u-u%26)/26:d=0;var m=a%26,x=Math.min((a-m)/26,this.length),A=67108863^67108863>>>m<x)for(this.length-=x,c=0;c=0&&(g!==0||c>=d);c--){var M=this.words[c]|0;this.words[c]=g<<26-m|M>>>m,g=M&A}return y&&g!==0&&(y.words[y.length++]=g),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(a,u,l){return n(this.negative===0),this.iushrn(a,u,l)},i.prototype.shln=function(a){return this.clone().ishln(a)},i.prototype.ushln=function(a){return this.clone().iushln(a)},i.prototype.shrn=function(a){return this.clone().ishrn(a)},i.prototype.ushrn=function(a){return this.clone().iushrn(a)},i.prototype.testn=function(a){n(typeof a=="number"&&a>=0);var u=a%26,l=(a-u)/26,d=1<=0);var u=a%26,l=(a-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(u!==0&&l++,this.length=Math.min(l,this.length),u!==0){var d=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},i.prototype.isubn=function(a){if(n(typeof a=="number"),n(a<67108864),a<0)return this.iaddn(-a);if(this.negative!==0)return this.negative=0,this.iaddn(a),this.negative=1,this;if(this.words[0]-=a,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(y/67108864|0),this.words[m+l]=x&67108863}for(;m>26,this.words[m+l]=x&67108863;if(A===0)return this.strip();for(n(A===-1),A=0,m=0;m>26,this.words[m]=x&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(a,u){var l=this.length-a.length,d=this.clone(),m=a,x=m.words[m.length-1]|0,A=this._countBits(x);l=26-A,l!==0&&(m=m.ushln(l),d.iushln(l),x=m.words[m.length-1]|0);var y=d.length-m.length,c;if(u!=="mod"){c=new i(null),c.length=y+1,c.words=new Array(c.length);for(var g=0;g=0;R--){var L=(d.words[m.length+R]|0)*67108864+(d.words[m.length+R-1]|0);for(L=Math.min(L/x|0,67108863),d._ishlnsubmul(m,L,R);d.negative!==0;)L--,d.negative=0,d._ishlnsubmul(m,1,R),d.isZero()||(d.negative^=1);c&&(c.words[R]=L)}return c&&c.strip(),d.strip(),u!=="div"&&l!==0&&d.iushrn(l),{div:c||null,mod:d}},i.prototype.divmod=function(a,u,l){if(n(!a.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var d,m,x;return this.negative!==0&&a.negative===0?(x=this.neg().divmod(a,u),u!=="mod"&&(d=x.div.neg()),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.iadd(a)),{div:d,mod:m}):this.negative===0&&a.negative!==0?(x=this.divmod(a.neg(),u),u!=="mod"&&(d=x.div.neg()),{div:d,mod:x.mod}):this.negative&a.negative?(x=this.neg().divmod(a.neg(),u),u!=="div"&&(m=x.mod.neg(),l&&m.negative!==0&&m.isub(a)),{div:x.div,mod:m}):a.length>this.length||this.cmp(a)<0?{div:new i(0),mod:this}:a.length===1?u==="div"?{div:this.divn(a.words[0]),mod:null}:u==="mod"?{div:null,mod:new i(this.modn(a.words[0]))}:{div:this.divn(a.words[0]),mod:new i(this.modn(a.words[0]))}:this._wordDiv(a,u)},i.prototype.div=function(a){return this.divmod(a,"div",!1).div},i.prototype.mod=function(a){return this.divmod(a,"mod",!1).mod},i.prototype.umod=function(a){return this.divmod(a,"mod",!0).mod},i.prototype.divRound=function(a){var u=this.divmod(a);if(u.mod.isZero())return u.div;var l=u.div.negative!==0?u.mod.isub(a):u.mod,d=a.ushrn(1),m=a.andln(1),x=l.cmp(d);return x<0||m===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},i.prototype.modn=function(a){n(a<=67108863);for(var u=(1<<26)%a,l=0,d=this.length-1;d>=0;d--)l=(u*l+(this.words[d]|0))%a;return l},i.prototype.idivn=function(a){n(a<=67108863);for(var u=0,l=this.length-1;l>=0;l--){var d=(this.words[l]|0)+u*67108864;this.words[l]=d/a|0,u=d%a}return this.strip()},i.prototype.divn=function(a){return this.clone().idivn(a)},i.prototype.egcd=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=new i(0),A=new i(1),y=0;u.isEven()&&l.isEven();)u.iushrn(1),l.iushrn(1),++y;for(var c=l.clone(),g=u.clone();!u.isZero();){for(var M=0,R=1;!(u.words[0]&R)&&M<26;++M,R<<=1);if(M>0)for(u.iushrn(M);M-- >0;)(d.isOdd()||m.isOdd())&&(d.iadd(c),m.isub(g)),d.iushrn(1),m.iushrn(1);for(var L=0,k=1;!(l.words[0]&k)&&L<26;++L,k<<=1);if(L>0)for(l.iushrn(L);L-- >0;)(x.isOdd()||A.isOdd())&&(x.iadd(c),A.isub(g)),x.iushrn(1),A.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(x),m.isub(A)):(l.isub(u),x.isub(d),A.isub(m))}return{a:x,b:A,gcd:l.iushln(y)}},i.prototype._invmp=function(a){n(a.negative===0),n(!a.isZero());var u=this,l=a.clone();u.negative!==0?u=u.umod(a):u=u.clone();for(var d=new i(1),m=new i(0),x=l.clone();u.cmpn(1)>0&&l.cmpn(1)>0;){for(var A=0,y=1;!(u.words[0]&y)&&A<26;++A,y<<=1);if(A>0)for(u.iushrn(A);A-- >0;)d.isOdd()&&d.iadd(x),d.iushrn(1);for(var c=0,g=1;!(l.words[0]&g)&&c<26;++c,g<<=1);if(c>0)for(l.iushrn(c);c-- >0;)m.isOdd()&&m.iadd(x),m.iushrn(1);u.cmp(l)>=0?(u.isub(l),d.isub(m)):(l.isub(u),m.isub(d))}var M;return u.cmpn(1)===0?M=d:M=m,M.cmpn(0)<0&&M.iadd(a),M},i.prototype.gcd=function(a){if(this.isZero())return a.abs();if(a.isZero())return this.abs();var u=this.clone(),l=a.clone();u.negative=0,l.negative=0;for(var d=0;u.isEven()&&l.isEven();d++)u.iushrn(1),l.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;l.isEven();)l.iushrn(1);var m=u.cmp(l);if(m<0){var x=u;u=l,l=x}else if(m===0||l.cmpn(1)===0)break;u.isub(l)}while(!0);return l.iushln(d)},i.prototype.invm=function(a){return this.egcd(a).a.umod(a)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(a){return this.words[0]&a},i.prototype.bincn=function(a){n(typeof a=="number");var u=a%26,l=(a-u)/26,d=1<>>26,A&=67108863,this.words[x]=A}return m!==0&&(this.words[x]=m,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(a){var u=a<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var l;if(this.length>1)l=1;else{u&&(a=-a),n(a<=67108863,"Number is too big");var d=this.words[0]|0;l=d===a?0:da.length)return 1;if(this.length=0;l--){var d=this.words[l]|0,m=a.words[l]|0;if(d!==m){dm&&(u=1);break}}return u},i.prototype.gtn=function(a){return this.cmpn(a)===1},i.prototype.gt=function(a){return this.cmp(a)===1},i.prototype.gten=function(a){return this.cmpn(a)>=0},i.prototype.gte=function(a){return this.cmp(a)>=0},i.prototype.ltn=function(a){return this.cmpn(a)===-1},i.prototype.lt=function(a){return this.cmp(a)===-1},i.prototype.lten=function(a){return this.cmpn(a)<=0},i.prototype.lte=function(a){return this.cmp(a)<=0},i.prototype.eqn=function(a){return this.cmpn(a)===0},i.prototype.eq=function(a){return this.cmp(a)===0},i.red=function(a){return new K(a)},i.prototype.toRed=function(a){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),a.convertTo(this)._forceRed(a)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(a){return this.red=a,this},i.prototype.forceRed=function(a){return n(!this.red,"Already a number in reduction context"),this._forceRed(a)},i.prototype.redAdd=function(a){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,a)},i.prototype.redIAdd=function(a){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,a)},i.prototype.redSub=function(a){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,a)},i.prototype.redISub=function(a){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,a)},i.prototype.redShl=function(a){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,a)},i.prototype.redMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.mul(this,a)},i.prototype.redIMul=function(a){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,a),this.red.imul(this,a)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(a){return n(this.red&&!a.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,a)};var B={k256:null,p224:null,p192:null,p25519:null};function N(w,a){this.name=w,this.p=new i(a,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}N.prototype._tmp=function(){var a=new i(null);return a.words=new Array(Math.ceil(this.n/13)),a},N.prototype.ireduce=function(a){var u=a,l;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),l=u.bitLength();while(l>this.n);var d=l0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},N.prototype.split=function(a,u){a.iushrn(this.n,0,u)},N.prototype.imulK=function(a){return a.imul(this.k)};function $(){N.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s($,N),$.prototype.split=function(a,u){for(var l=4194303,d=Math.min(a.length,9),m=0;m>>22,x=A}x>>>=22,a.words[m-10]=x,x===0&&a.length>10?a.length-=10:a.length-=9},$.prototype.imulK=function(a){a.words[a.length]=0,a.words[a.length+1]=0,a.length+=2;for(var u=0,l=0;l>>=26,a.words[l]=m,u=d}return u!==0&&(a.words[a.length++]=u),a},i._prime=function(a){if(B[a])return B[a];var u;if(a==="k256")u=new $;else if(a==="p224")u=new H;else if(a==="p192")u=new J;else if(a==="p25519")u=new Q;else throw new Error("Unknown prime "+a);return B[a]=u,u};function K(w){if(typeof w=="string"){var a=i._prime(w);this.m=a.p,this.prime=a}else n(w.gtn(1),"modulus must be greater than 1"),this.m=w,this.prime=null}K.prototype._verify1=function(a){n(a.negative===0,"red works only with positives"),n(a.red,"red works only with red numbers")},K.prototype._verify2=function(a,u){n((a.negative|u.negative)===0,"red works only with positives"),n(a.red&&a.red===u.red,"red works only with red numbers")},K.prototype.imod=function(a){return this.prime?this.prime.ireduce(a)._forceRed(this):a.umod(this.m)._forceRed(this)},K.prototype.neg=function(a){return a.isZero()?a.clone():this.m.sub(a)._forceRed(this)},K.prototype.add=function(a,u){this._verify2(a,u);var l=a.add(u);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},K.prototype.iadd=function(a,u){this._verify2(a,u);var l=a.iadd(u);return l.cmp(this.m)>=0&&l.isub(this.m),l},K.prototype.sub=function(a,u){this._verify2(a,u);var l=a.sub(u);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},K.prototype.isub=function(a,u){this._verify2(a,u);var l=a.isub(u);return l.cmpn(0)<0&&l.iadd(this.m),l},K.prototype.shl=function(a,u){return this._verify1(a),this.imod(a.ushln(u))},K.prototype.imul=function(a,u){return this._verify2(a,u),this.imod(a.imul(u))},K.prototype.mul=function(a,u){return this._verify2(a,u),this.imod(a.mul(u))},K.prototype.isqr=function(a){return this.imul(a,a.clone())},K.prototype.sqr=function(a){return this.mul(a,a)},K.prototype.sqrt=function(a){if(a.isZero())return a.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(a,l)}for(var d=this.m.subn(1),m=0;!d.isZero()&&d.andln(1)===0;)m++,d.iushrn(1);n(!d.isZero());var x=new i(1).toRed(this),A=x.redNeg(),y=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new i(2*c*c).toRed(this);this.pow(c,y).cmp(A)!==0;)c.redIAdd(A);for(var g=this.pow(c,d),M=this.pow(a,d.addn(1).iushrn(1)),R=this.pow(a,d),L=m;R.cmp(x)!==0;){for(var k=R,D=0;k.cmp(x)!==0;D++)k=k.redSqr();n(D=0;m--){for(var g=u.words[m],M=c-1;M>=0;M--){var R=g>>M&1;if(x!==d[0]&&(x=this.sqr(x)),R===0&&A===0){y=0;continue}A<<=1,A|=R,y++,!(y!==l&&(m!==0||M!==0))&&(x=this.mul(x,d[A]),y=0,A=0)}c=26}return x},K.prototype.convertTo=function(a){var u=a.umod(this.m);return u===a?u.clone():u},K.prototype.convertFrom=function(a){var u=a.clone();return u.red=null,u},i.mont=function(a){return new se(a)};function se(w){K.call(this,w),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(se,K),se.prototype.convertTo=function(a){return this.imod(a.ushln(this.shift))},se.prototype.convertFrom=function(a){var u=this.imod(a.mul(this.rinv));return u.red=null,u},se.prototype.imul=function(a,u){if(a.isZero()||u.isZero())return a.words[0]=0,a.length=1,a;var l=a.imul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.mul=function(a,u){if(a.isZero()||u.isZero())return new i(0)._forceRed(this);var l=a.mul(u),d=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),m=l.isub(d).iushrn(this.shift),x=m;return m.cmp(this.m)>=0?x=m.isub(this.m):m.cmpn(0)<0&&(x=m.iadd(this.m)),x._forceRed(this)},se.prototype.invm=function(a){var u=this.imod(a._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(t,Ke)})(SS);var _S=SS.exports,dk=_S,Hpe=Tt.Buffer;function qpe(t,e){return Hpe.from(t.toRed(dk.mont(e.modulus)).redPow(new dk(e.publicExponent)).fromRed().toArray())}var qz=qpe,Gpe=qx,h7=f1,Vpe=By,pk=jz,mk=Hz,PS=_S,Kpe=qz,Wpe=sS,Co=Tt.Buffer,Jpe=function(e,r,n){var s;e.padding?s=e.padding:n?s=1:s=4;var i=Gpe(e),o;if(s===4)o=Zpe(i,r);else if(s===1)o=Qpe(i,r,n);else if(s===3){if(o=new PS(r),o.cmp(i.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return n?Wpe(o,i):Kpe(o,i)};function Zpe(t,e){var r=t.modulus.byteLength(),n=e.length,s=Vpe("sha1").update(Co.alloc(0)).digest(),i=s.length,o=2*i;if(n>r-o-2)throw new Error("message too long");var f=Co.alloc(r-n-o-2),h=r-i-1,p=h7(i),b=mk(Co.concat([s,f,Co.alloc(1,1),e],h),pk(p,h)),v=mk(p,pk(b,i));return new PS(Co.concat([Co.alloc(1),v,b],r))}function Qpe(t,e,r){var n=e.length,s=t.modulus.byteLength();if(n>s-11)throw new Error("message too long");var i;return r?i=Co.alloc(s-n-3,255):i=Ype(s-n-3),new PS(Co.concat([Co.from([0,r?1:2]),i,Co.alloc(1),e],s))}function Ype(t){for(var e=Co.allocUnsafe(t),r=0,n=h7(t*2),s=0,i;ro||new bk(r).cmp(i.modulus)>=0)throw new Error("decryption error");var f;n?f=r1e(new bk(r),i):f=e1e(r,i);var h=bg.alloc(o-f.length);if(f=bg.concat([h,f],o),s===4)return i1e(i,f);if(s===1)return s1e(i,f,n);if(s===3)return f;throw new Error("unknown padding")};function i1e(t,e){var r=t.modulus.byteLength(),n=t1e("sha1").update(bg.alloc(0)).digest(),s=n.length;if(e[0]!==0)throw new Error("decryption error");var i=e.slice(1,s+1),o=e.slice(s+1),f=yk(i,gk(o,s)),h=yk(o,gk(f,r-s-1));if(o1e(n,h.slice(0,s)))throw new Error("decryption error");for(var p=s;h[p]===0;)p++;if(h[p++]!==1)throw new Error("decryption error");return h.slice(p)}function s1e(t,e,r){for(var n=e.slice(0,2),s=2,i=0;e[s++]!==0;)if(s>=e.length){i++;break}var o=e.slice(2,s-1);if((n.toString("hex")!=="0002"&&!r||n.toString("hex")!=="0001"&&r)&&i++,o.length<8&&i++,i)throw new Error("decryption error");return e.slice(s)}function o1e(t,e){t=bg.from(t),e=bg.from(e);var r=0,n=t.length;t.length!==e.length&&(r++,n=Math.min(t.length,e.length));for(var s=-1;++sWz||t<0)throw new TypeError("offset must be a uint32");if(t>Kz||t>e)throw new RangeError("offset out of range")}function Zz(t,e,r){if(typeof t!="number"||t!==t)throw new TypeError("size must be a number");if(t>Wz||t<0)throw new TypeError("size must be a uint32");if(t+e>r||t>Kz)throw new RangeError("buffer too small")}d7&&d7.getRandomValues||!Ve.process.browser?(bm.randomFill=a1e,bm.randomFillSync=f1e):(bm.randomFill=vk,bm.randomFillSync=vk);function a1e(t,e,r,n){if(!Vz.isBuffer(t)&&!(t instanceof Ke.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof e=="function")n=e,e=0,r=t.length;else if(typeof r=="function")n=r,r=t.length-e;else if(typeof n!="function")throw new TypeError('"cb" argument must be a function');return Jz(e,t.length),Zz(r,e,t.length),Qz(t,e,r,n)}function Qz(t,e,r,n){if(Ve.process.browser){var s=t.buffer,i=new Uint8Array(s,e,r);if(d7.getRandomValues(i),n){Ve.process.nextTick(function(){n(null,t)});return}return t}if(n){xk(r,function(f,h){if(f)return n(f);h.copy(t,e),n(null,t)});return}var o=xk(r);return o.copy(t,e),t}function f1e(t,e,r){if(typeof e>"u"&&(e=0),!Vz.isBuffer(t)&&!(t instanceof Ke.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return Jz(e,t.length),r===void 0&&(r=t.length-e),Zz(r,e,t.length),Qz(t,e,r)}var wk;function Yz(){if(wk)return _t;wk=1,_t.randomBytes=_t.rng=_t.pseudoRandomBytes=_t.prng=f1,_t.createHash=_t.Hash=By,_t.createHmac=_t.Hmac=cU;var t=Kce,e=Object.keys(t),r=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(e);_t.getHashes=function(){return r};var n=_x;_t.pbkdf2=n.pbkdf2,_t.pbkdf2Sync=n.pbkdf2Sync;var s=Wo;_t.Cipher=s.Cipher,_t.createCipher=s.createCipher,_t.Cipheriv=s.Cipheriv,_t.createCipheriv=s.createCipheriv,_t.Decipher=s.Decipher,_t.createDecipher=s.createDecipher,_t.Decipheriv=s.Decipheriv,_t.createDecipheriv=s.createDecipheriv,_t.getCiphers=s.getCiphers,_t.listCiphers=s.listCiphers;var i=_le();_t.DiffieHellmanGroup=i.DiffieHellmanGroup,_t.createDiffieHellmanGroup=i.createDiffieHellmanGroup,_t.getDiffieHellman=i.getDiffieHellman,_t.createDiffieHellman=i.createDiffieHellman,_t.DiffieHellman=i.DiffieHellman;var o=$pe();_t.createSign=o.createSign,_t.Sign=o.Sign,_t.createVerify=o.createVerify,_t.Verify=o.Verify,_t.createECDH=Upe();var f=zz;_t.publicEncrypt=f.publicEncrypt,_t.privateEncrypt=f.privateEncrypt,_t.publicDecrypt=f.publicDecrypt,_t.privateDecrypt=f.privateDecrypt;var h=bm;return _t.randomFill=h.randomFill,_t.randomFillSync=h.randomFillSync,_t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(` -`))},_t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},_t}var Xz=Yz();const c1e=Qs(Xz),u1e=JB({__proto__:null,default:c1e},[Xz]);/*! noble-secp256k1 - MIT License (c) 2019 Paul Miller (paulmillr.com) */const Ft=BigInt(0),Er=BigInt(1),Z0=BigInt(2),Dm=BigInt(3),Ak=BigInt(8),Jr=Object.freeze({a:Ft,b:BigInt(7),P:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),n:BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),h:Er,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee")}),Ek=(t,e)=>(t+e/Z0)/e,Gb={beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar(t){const{n:e}=Jr,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),n=-Er*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),s=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),i=r,o=BigInt("0x100000000000000000000000000000000"),f=Ek(i*t,e),h=Ek(-n*t,e);let p=et(t-f*r-h*s,e),b=et(-f*n-h*i,e);const v=p>o,E=b>o;if(v&&(p=e-p),E&&(b=e-b),p>o||b>o)throw new Error("splitScalarEndo: Endomorphism failed, k="+t);return{k1neg:v,k1:p,k2neg:E,k2:b}}},No=32,Mp=32,l1e=32,h6=No+1,d6=2*No+1;function Mk(t){const{a:e,b:r}=Jr,n=et(t*t),s=et(n*t);return et(s+e*t+r)}const Vb=Jr.a===Ft;class ej extends Error{constructor(e){super(e)}}function Sk(t){if(!(t instanceof Jt))throw new TypeError("JacobianPoint expected")}class Jt{constructor(e,r,n){this.x=e,this.y=r,this.z=n}static fromAffine(e){if(!(e instanceof Fr))throw new TypeError("JacobianPoint#fromAffine: expected Point");return e.equals(Fr.ZERO)?Jt.ZERO:new Jt(e.x,e.y,Er)}static toAffineBatch(e){const r=g1e(e.map(n=>n.z));return e.map((n,s)=>n.toAffine(r[s]))}static normalizeZ(e){return Jt.toAffineBatch(e).map(Jt.fromAffine)}equals(e){Sk(e);const{x:r,y:n,z:s}=this,{x:i,y:o,z:f}=e,h=et(s*s),p=et(f*f),b=et(r*p),v=et(i*h),E=et(et(n*f)*p),_=et(et(o*s)*h);return b===v&&E===_}negate(){return new Jt(this.x,et(-this.y),this.z)}double(){const{x:e,y:r,z:n}=this,s=et(e*e),i=et(r*r),o=et(i*i),f=e+i,h=et(Z0*(et(f*f)-s-o)),p=et(Dm*s),b=et(p*p),v=et(b-Z0*h),E=et(p*(h-v)-Ak*o),_=et(Z0*r*n);return new Jt(v,E,_)}add(e){Sk(e);const{x:r,y:n,z:s}=this,{x:i,y:o,z:f}=e;if(i===Ft||o===Ft)return this;if(r===Ft||n===Ft)return e;const h=et(s*s),p=et(f*f),b=et(r*p),v=et(i*h),E=et(et(n*f)*p),_=et(et(o*s)*h),S=et(v-b),P=et(_-E);if(S===Ft)return P===Ft?this.double():Jt.ZERO;const I=et(S*S),C=et(S*I),T=et(b*I),B=et(P*P-C-Z0*T),N=et(P*(T-B)-E*C),$=et(s*f*S);return new Jt(B,N,$)}subtract(e){return this.add(e.negate())}multiplyUnsafe(e){const r=Jt.ZERO;if(typeof e=="bigint"&&e===Ft)return r;let n=Ck(e);if(n===Er)return this;if(!Vb){let v=r,E=this;for(;n>Ft;)n&Er&&(v=v.add(E)),E=E.double(),n>>=Er;return v}let{k1neg:s,k1:i,k2neg:o,k2:f}=Gb.splitScalar(n),h=r,p=r,b=this;for(;i>Ft||f>Ft;)i&Er&&(h=h.add(b)),f&Er&&(p=p.add(b)),b=b.double(),i>>=Er,f>>=Er;return s&&(h=h.negate()),o&&(p=p.negate()),p=new Jt(et(p.x*Gb.beta),p.y,p.z),h.add(p)}precomputeWindow(e){const r=Vb?128/e+1:256/e+1,n=[];let s=this,i=s;for(let o=0;o>=v,S>h&&(S-=b,e+=Er);const P=_,I=_+Math.abs(S)-1,C=E%2!==0,T=S<0;S===0?o=o.add(Kb(C,s[P])):i=i.add(Kb(T,s[I]))}return{p:i,f:o}}multiply(e,r){let n=Ck(e),s,i;if(Vb){const{k1neg:o,k1:f,k2neg:h,k2:p}=Gb.splitScalar(n);let{p:b,f:v}=this.wNAF(f,r),{p:E,f:_}=this.wNAF(p,r);b=Kb(o,b),E=Kb(h,E),E=new Jt(et(E.x*Gb.beta),E.y,E.z),s=b.add(E),i=v.add(_)}else{const{p:o,f}=this.wNAF(n,r);s=o,i=f}return Jt.normalizeZ([s,i])[0]}toAffine(e){const{x:r,y:n,z:s}=this,i=this.equals(Jt.ZERO);e==null&&(e=i?Ak:jy(s));const o=e,f=et(o*o),h=et(f*o),p=et(r*f),b=et(n*h),v=et(s*o);if(i)return Fr.ZERO;if(v!==Er)throw new Error("invZ was invalid");return new Fr(p,b)}}Jt.BASE=new Jt(Jr.Gx,Jr.Gy,Er);Jt.ZERO=new Jt(Ft,Er,Ft);function Kb(t,e){const r=e.negate();return t?r:e}const p7=new WeakMap;let Fr=class w0{constructor(e,r){this.x=e,this.y=r}_setWindowSize(e){this._WINDOW_SIZE=e,p7.delete(this)}hasEvenY(){return this.y%Z0===Ft}static fromCompressedHex(e){const r=e.length===32,n=lc(r?e:e.subarray(1));if(!R8(n))throw new Error("Point is not on curve");const s=Mk(n);let i=m1e(s);const o=(i&Er)===Er;r?o&&(i=et(-i)):(e[0]&1)===1!==o&&(i=et(-i));const f=new w0(n,i);return f.assertValidity(),f}static fromUncompressedHex(e){const r=lc(e.subarray(1,No+1)),n=lc(e.subarray(No+1,No*2+1)),s=new w0(r,n);return s.assertValidity(),s}static fromHex(e){const r=vg(e),n=r.length,s=r[0];if(n===No)return this.fromCompressedHex(r);if(n===h6&&(s===2||s===3))return this.fromCompressedHex(r);if(n===d6&&s===4)return this.fromUncompressedHex(r);throw new Error(`Point.fromHex: received invalid point. Expected 32-${h6} compressed bytes or ${d6} uncompressed bytes, not ${n}`)}static fromPrivateKey(e){return w0.BASE.multiply(wg(e))}static fromSignature(e,r,n){const{r:s,s:i}=w1e(r);if(![0,1,2,3].includes(n))throw new Error("Cannot recover: invalid recovery bit");const o=tj(vg(e)),{n:f}=Jr,h=n===2||n===3?s+f:s,p=jy(h,f),b=et(-o*p,f),v=et(i*p,f),E=n&1?"03":"02",_=w0.fromHex(E+td(h)),S=w0.BASE.multiplyAndAddUnsafe(_,b,v);if(!S)throw new Error("Cannot recover signature: point at infinify");return S.assertValidity(),S}toRawBytes(e=!1){return Ku(this.toHex(e))}toHex(e=!1){const r=td(this.x);return e?`${this.hasEvenY()?"02":"03"}${r}`:`04${r}${td(this.y)}`}toHexX(){return this.toHex(!0).slice(2)}toRawX(){return this.toRawBytes(!0).slice(1)}assertValidity(){const e="Point is not on elliptic curve",{x:r,y:n}=this;if(!R8(r)||!R8(n))throw new Error(e);const s=et(n*n),i=Mk(r);if(et(s-i)!==Ft)throw new Error(e)}equals(e){return this.x===e.x&&this.y===e.y}negate(){return new w0(this.x,et(-this.y))}double(){return Jt.fromAffine(this).double().toAffine()}add(e){return Jt.fromAffine(this).add(Jt.fromAffine(e)).toAffine()}subtract(e){return this.add(e.negate())}multiply(e){return Jt.fromAffine(this).multiply(e,this).toAffine()}multiplyAndAddUnsafe(e,r,n){const s=Jt.fromAffine(this),i=r===Ft||r===Er||this!==w0.BASE?s.multiplyUnsafe(r):s.multiply(r),o=Jt.fromAffine(e).multiplyUnsafe(n),f=i.add(o);return f.equals(Jt.ZERO)?void 0:f.toAffine()}};Fr.BASE=new Fr(Jr.Gx,Jr.Gy);Fr.ZERO=new Fr(Ft,Ft);function _k(t){return Number.parseInt(t[0],16)>=8?"00"+t:t}function Pk(t){if(t.length<2||t[0]!==2)throw new Error(`Invalid signature integer tag: ${Sp(t)}`);const e=t[1],r=t.subarray(2,e+2);if(!e||r.length!==e)throw new Error("Invalid signature integer: wrong length");if(r[0]===0&&r[1]<=127)throw new Error("Invalid signature integer: trailing length");return{data:lc(r),left:t.subarray(e+2)}}function h1e(t){if(t.length<2||t[0]!=48)throw new Error(`Invalid signature tag: ${Sp(t)}`);if(t[1]!==t.length-2)throw new Error("Invalid signature: incorrect length");const{data:e,left:r}=Pk(t.subarray(2)),{data:n,left:s}=Pk(r);if(s.length)throw new Error(`Invalid signature: left bytes after parsing: ${Sp(s)}`);return{r:e,s:n}}let ed=class Wv{constructor(e,r){this.r=e,this.s=r,this.assertValidity()}static fromCompact(e){const r=e instanceof Uint8Array,n="Signature.fromCompact";if(typeof e!="string"&&!r)throw new TypeError(`${n}: Expected string or Uint8Array`);const s=r?Sp(e):e;if(s.length!==128)throw new Error(`${n}: Expected 64-byte hex`);return new Wv(p6(s.slice(0,64)),p6(s.slice(64,128)))}static fromDER(e){const r=e instanceof Uint8Array;if(typeof e!="string"&&!r)throw new TypeError("Signature.fromDER: Expected string or Uint8Array");const{r:n,s}=h1e(r?e:Ku(e));return new Wv(n,s)}static fromHex(e){return this.fromDER(e)}assertValidity(){const{r:e,s:r}=this;if(!xg(e))throw new Error("Invalid Signature: r must be 0 < r < n");if(!xg(r))throw new Error("Invalid Signature: s must be 0 < s < n")}hasHighS(){const e=Jr.n>>Er;return this.s>e}normalizeS(){return this.hasHighS()?new Wv(this.r,et(-this.s,Jr.n)):this}toDERRawBytes(){return Ku(this.toDERHex())}toDERHex(){const e=_k(tm(this.s)),r=_k(tm(this.r)),n=e.length/2,s=r.length/2,i=tm(n),o=tm(s);return`30${tm(s+n+4)}02${o}${r}02${i}${e}`}toRawBytes(){return this.toDERRawBytes()}toHex(){return this.toDERHex()}toCompactRawBytes(){return Ku(this.toCompactHex())}toCompactHex(){return td(this.r)+td(this.s)}};function T0(...t){if(!t.every(n=>n instanceof Uint8Array))throw new Error("Uint8Array list expected");if(t.length===1)return t[0];const e=t.reduce((n,s)=>n+s.length,0),r=new Uint8Array(e);for(let n=0,s=0;ne.toString(16).padStart(2,"0"));function Sp(t){if(!(t instanceof Uint8Array))throw new Error("Expected Uint8Array");let e="";for(let r=0;r0)return BigInt(t);if(typeof t=="bigint"&&xg(t))return t;throw new TypeError("Expected valid private scalar: 0 < scalar < curve.n")}function et(t,e=Jr.P){const r=t%e;return r>=Ft?r:e+r}function ys(t,e){const{P:r}=Jr;let n=t;for(;e-- >Ft;)n*=n,n%=r;return n}function m1e(t){const{P:e}=Jr,r=BigInt(6),n=BigInt(11),s=BigInt(22),i=BigInt(23),o=BigInt(44),f=BigInt(88),h=t*t*t%e,p=h*h*t%e,b=ys(p,Dm)*p%e,v=ys(b,Dm)*p%e,E=ys(v,Z0)*h%e,_=ys(E,n)*E%e,S=ys(_,s)*_%e,P=ys(S,o)*S%e,I=ys(P,f)*P%e,C=ys(I,o)*S%e,T=ys(C,Dm)*p%e,B=ys(T,i)*_%e,N=ys(B,r)*h%e,$=ys(N,Z0);if($*$%e!==t)throw new Error("Cannot find square root");return $}function jy(t,e=Jr.P){if(t===Ft||e<=Ft)throw new Error(`invert: expected positive integers, got n=${t} mod=${e}`);let r=et(t,e),n=e,s=Ft,i=Er;for(;r!==Ft;){const f=n/r,h=n%r,p=s-i*f;n=r,r=h,s=i,i=p}if(n!==Er)throw new Error("invert: does not exist");return et(s,e)}function g1e(t,e=Jr.P){const r=new Array(t.length),n=t.reduce((i,o,f)=>o===Ft?i:(r[f]=i,et(i*o,e)),Er),s=jy(n,e);return t.reduceRight((i,o,f)=>o===Ft?i:(r[f]=et(i*r[f],e),et(i*o,e)),s),r}function y1e(t){const e=t.length*8-Mp*8,r=lc(t);return e>0?r>>BigInt(e):r}function tj(t,e=!1){const r=y1e(t);if(e)return r;const{n}=Jr;return r>=n?r-n:r}let rd,$m;class b1e{constructor(e,r){if(this.hashLen=e,this.qByteLen=r,typeof e!="number"||e<2)throw new Error("hashLen must be a number");if(typeof r!="number"||r<2)throw new Error("qByteLen must be a number");this.v=new Uint8Array(e).fill(1),this.k=new Uint8Array(e).fill(0),this.counter=0}hmac(...e){return Q0.hmacSha256(this.k,...e)}hmacSync(...e){return $m(this.k,...e)}checkSync(){if(typeof $m!="function")throw new ej("hmacSha256Sync needs to be set")}incr(){if(this.counter>=1e3)throw new Error("Tried 1,000 k values for sign(), all were invalid");this.counter+=1}async reseed(e=new Uint8Array){this.k=await this.hmac(this.v,Uint8Array.from([0]),e),this.v=await this.hmac(this.v),e.length!==0&&(this.k=await this.hmac(this.v,Uint8Array.from([1]),e),this.v=await this.hmac(this.v))}reseedSync(e=new Uint8Array){this.checkSync(),this.k=this.hmacSync(this.v,Uint8Array.from([0]),e),this.v=this.hmacSync(this.v),e.length!==0&&(this.k=this.hmacSync(this.v,Uint8Array.from([1]),e),this.v=this.hmacSync(this.v))}async generate(){this.incr();let e=0;const r=[];for(;e0)e=BigInt(t);else if(typeof t=="string"){if(t.length!==2*Mp)throw new Error("Expected 32 bytes of private key");e=p6(t)}else if(t instanceof Uint8Array){if(t.length!==Mp)throw new Error("Expected 32 bytes of private key");e=lc(t)}else throw new TypeError("Expected valid private key");if(!xg(e))throw new Error("Expected private key: 0 < key < n");return e}function x1e(t){return t instanceof Fr?(t.assertValidity(),t):Fr.fromHex(t)}function w1e(t){if(t instanceof ed)return t.assertValidity(),t;try{return ed.fromDER(t)}catch{return ed.fromCompact(t)}}function A1e(t,e=!1){return Fr.fromPrivateKey(t).toRawBytes(e)}function E1e(t,e,r,n=!1){return Fr.fromSignature(t,e,r).toRawBytes(n)}function Ik(t){const e=t instanceof Uint8Array,r=typeof t=="string",n=(e||r)&&t.length;return e?n===h6||n===d6:r?n===h6*2||n===d6*2:t instanceof Fr}function M1e(t,e,r=!1){if(Ik(t))throw new TypeError("getSharedSecret: first arg must be private key");if(!Ik(e))throw new TypeError("getSharedSecret: second arg must be public key");const n=x1e(e);return n.assertValidity(),n.multiply(wg(t)).toRawBytes(r)}function rj(t){const e=t.length>No?t.slice(0,No):t;return lc(e)}function S1e(t){const e=rj(t),r=et(e,Jr.n);return nj(r{t=vg(t);const e=Mp+8;if(t.length1024)throw new Error("Expected valid bytes of private key as per FIPS 186");const r=et(lc(t),Jr.n-Er)+Er;return m7(r)},randomBytes:(t=32)=>{if(zi.web)return zi.web.getRandomValues(new Uint8Array(t));if(zi.node){const{randomBytes:e}=zi.node;return Uint8Array.from(e(t))}else throw new Error("The environment doesn't have randomBytes function")},randomPrivateKey:()=>Q0.hashToPrivateKey(Q0.randomBytes(Mp+8)),precompute(t=8,e=Fr.BASE){const r=e===Fr.BASE?e:new Fr(e.x,e.y);return r._setWindowSize(t),r.multiply(Dm),r},sha256:async(...t)=>{if(zi.web){const e=await zi.web.subtle.digest("SHA-256",T0(...t));return new Uint8Array(e)}else if(zi.node){const{createHash:e}=zi.node,r=e("sha256");return t.forEach(n=>r.update(n)),Uint8Array.from(r.digest())}else throw new Error("The environment doesn't have sha256 function")},hmacSha256:async(t,...e)=>{if(zi.web){const r=await zi.web.subtle.importKey("raw",t,{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),n=T0(...e),s=await zi.web.subtle.sign("HMAC",r,n);return new Uint8Array(s)}else if(zi.node){const{createHmac:r}=zi.node,n=r("sha256",t);return e.forEach(s=>n.update(s)),Uint8Array.from(n.digest())}else throw new Error("The environment doesn't have hmac-sha256 function")},sha256Sync:void 0,hmacSha256Sync:void 0,taggedHash:async(t,...e)=>{let r=Wb[t];if(r===void 0){const n=await Q0.sha256(Uint8Array.from(t,s=>s.charCodeAt(0)));r=T0(n,n),Wb[t]=r}return Q0.sha256(r,...e)},taggedHashSync:(t,...e)=>{if(typeof rd!="function")throw new ej("sha256Sync is undefined, you need to set it");let r=Wb[t];if(r===void 0){const n=rd(Uint8Array.from(t,s=>s.charCodeAt(0)));r=T0(n,n),Wb[t]=r}return rd(r,...e)},_JacobianPoint:Jt};Object.defineProperties(Q0,{sha256Sync:{configurable:!1,get(){return rd},set(t){rd||(rd=t)}},hmacSha256Sync:{configurable:!1,get(){return $m},set(t){$m||($m=t)}}});const To="0x0000000000000000000000000000000000000000",Tk="0x0000000000000000000000000000000000000000000000000000000000000000",kk=BigInt(0),Rk=BigInt(1),Bk=BigInt(2),Ok=BigInt(27),Nk=BigInt(28),Jb=BigInt(35),rh={};function Lk(t){return sl(rs(t),32)}var bd,vd,xd,Su,Wi;let Jf=(Wi=class{constructor(e,r,n,s){Te(this,bd,void 0);Te(this,vd,void 0);Te(this,xd,void 0);Te(this,Su,void 0);Ey(e,rh,"Signature"),fe(this,bd,r),fe(this,vd,n),fe(this,xd,s),fe(this,Su,null)}get r(){return X(this,bd)}set r(e){me(Kh(e)===32,"invalid r","value",e),fe(this,bd,nt(e))}get s(){return X(this,vd)}set s(e){me(Kh(e)===32,"invalid s","value",e);const r=nt(e);me(parseInt(r.substring(0,3))<8,"non-canonical s","value",r),fe(this,vd,r)}get v(){return X(this,xd)}set v(e){const r=Ct(e,"value");me(r===27||r===28,"invalid v","v",e),fe(this,xd,r)}get networkV(){return X(this,Su)}get legacyChainId(){const e=this.networkV;return e==null?null:Wi.getChainId(e)}get yParity(){return this.v===27?0:1}get yParityAndS(){const e=$t(this.s);return this.yParity&&(e[0]|=128),nt(e)}get compactSerialized(){return tn([this.r,this.yParityAndS])}get serialized(){return tn([this.r,this.s,this.yParity?"0x1c":"0x1b"])}[Symbol.for("nodejs.util.inspect.custom")](){return`Signature { r: "${this.r}", s: "${this.s}", yParity: ${this.yParity}, networkV: ${this.networkV} }`}clone(){const e=new Wi(rh,this.r,this.s,this.v);return this.networkV&&fe(e,Su,this.networkV),e}toJSON(){const e=this.networkV;return{_type:"signature",networkV:e!=null?e.toString():null,r:this.r,s:this.s,v:this.v}}static getChainId(e){const r=ft(e,"v");return r==Ok||r==Nk?kk:(me(r>=Jb,"invalid EIP-155 v","v",e),(r-Jb)/Bk)}static getChainIdV(e,r){return ft(e)*Bk+BigInt(35+r-27)}static getNormalizedV(e){const r=ft(e);return r===kk||r===Ok?27:r===Rk||r===Nk?28:(me(r>=Jb,"invalid v","v",e),r&Rk?27:28)}static from(e){function r(p,b){me(p,b,"signature",e)}if(e==null)return new Wi(rh,Tk,Tk,27);if(typeof e=="string"){const p=$t(e,"signature");if(p.length===64){const b=nt(p.slice(0,32)),v=p.slice(32,64),E=v[0]&128?28:27;return v[0]&=127,new Wi(rh,b,nt(v),E)}if(p.length===65){const b=nt(p.slice(0,32)),v=p.slice(32,64);r((v[0]&128)===0,"non-canonical s");const E=Wi.getNormalizedV(p[64]);return new Wi(rh,b,nt(v),E)}r(!1,"invalid raw signature length")}if(e instanceof Wi)return e.clone();const n=e.r;r(n!=null,"missing r");const s=Lk(n),i=function(p,b){if(p!=null)return Lk(p);if(b!=null){r(Rr(b,32),"invalid yParityAndS");const v=$t(b);return v[0]&=127,nt(v)}r(!1,"missing s")}(e.s,e.yParityAndS);r(($t(i)[0]&128)==0,"non-canonical s");const{networkV:o,v:f}=function(p,b,v){if(p!=null){const E=ft(p);return{networkV:E>=Jb?E:void 0,v:Wi.getNormalizedV(E)}}if(b!=null)return r(Rr(b,32),"invalid yParityAndS"),{v:$t(b)[0]&128?28:27};if(v!=null){switch(Ct(v,"sig.yParity")){case 0:return{v:27};case 1:return{v:28}}r(!1,"invalid yParity")}r(!1,"missing v")}(e.v,e.yParityAndS,e.yParity),h=new Wi(rh,s,i,f);return o&&fe(h,Su,o),r(e.yParity==null||Ct(e.yParity,"sig.yParity")===h.yParity,"yParity mismatch"),r(e.yParityAndS==null||e.yParityAndS===h.yParityAndS,"yParityAndS mismatch"),h}},bd=new WeakMap,vd=new WeakMap,xd=new WeakMap,Su=new WeakMap,Wi);Q0.hmacSha256Sync=function(t,...e){return $t(_y("sha256",t,tn(e)))};var uf,xf;let CS=(xf=class{constructor(e){Te(this,uf,void 0);me(Kh(e)===32,"invalid private key","privateKey","[REDACTED]"),fe(this,uf,nt(e))}get privateKey(){return X(this,uf)}get publicKey(){return xf.computePublicKey(X(this,uf))}get compressedPublicKey(){return xf.computePublicKey(X(this,uf),!0)}sign(e){me(Kh(e)===32,"invalid digest length","digest",e);const[r,n]=C1e(Ti(e),Ti(X(this,uf)),{recovered:!0,canonical:!0}),s=ed.fromHex(r);return Jf.from({r:vc("0x"+s.r.toString(16),32),s:vc("0x"+s.s.toString(16),32),v:n?28:27})}computeSharedSecret(e){const r=xf.computePublicKey(e);return nt(M1e(Ti(X(this,uf)),$t(r)))}static computePublicKey(e,r){let n=$t(e,"key");if(n.length===32){const i=A1e(n,!!r);return nt(i)}if(n.length===64){const i=new Uint8Array(65);i[0]=4,i.set(n,1),n=i}const s=Fr.fromHex(n);return nt(s.toRawBytes(r))}static recoverPublicKey(e,r){me(Kh(e)===32,"invalid digest length","digest",e);const n=Jf.from(r),s=ed.fromCompact(Ti(tn([n.r,n.s]))).toDERRawBytes(),i=E1e(Ti(e),s,n.yParity);return me(i!=null,"invalid signature for digest","signature",r),nt(i)}static addPoints(e,r,n){const s=Fr.fromHex(xf.computePublicKey(e).substring(2)),i=Fr.fromHex(xf.computePublicKey(r).substring(2));return"0x"+s.add(i).toHex(!!n)}},uf=new WeakMap,xf);const I1e=BigInt(0),T1e=BigInt(36);function Dk(t){t=t.toLowerCase();const e=t.substring(2).split(""),r=new Uint8Array(40);for(let s=0;s<40;s++)r[s]=e[s].charCodeAt(0);const n=$t(kr(r));for(let s=0;s<40;s+=2)n[s>>1]>>4>=8&&(e[s]=e[s].toUpperCase()),(n[s>>1]&15)>=8&&(e[s+1]=e[s+1].toUpperCase());return"0x"+e.join("")}const IS={};for(let t=0;t<10;t++)IS[String(t)]=String(t);for(let t=0;t<26;t++)IS[String.fromCharCode(65+t)]=String(10+t);const $k=15;function k1e(t){t=t.toUpperCase(),t=t.substring(4)+t.substring(0,2)+"00";let e=t.split("").map(n=>IS[n]).join("");for(;e.length>=$k;){let n=e.substring(0,$k);e=parseInt(n,10)%97+e.substring(n.length)}let r=String(98-parseInt(e,10)%97);for(;r.length<2;)r="0"+r;return r}const R1e=function(){const t={};for(let e=0;e<36;e++){const r="0123456789abcdefghijklmnopqrstuvwxyz"[e];t[r]=BigInt(e)}return t}();function B1e(t){t=t.toLowerCase();let e=I1e;for(let r=0;re.format()).join(",")})`:this.type}defaultValue(){return 0}minValue(){return 0}maxValue(){return 0}isBigInt(){return!!this.type.match(/^u?int[0-9]+$/)}isData(){return this.type.startsWith("bytes")}isString(){return this.type==="string"}get tupleName(){if(this.type!=="tuple")throw TypeError("not a tuple");return X(this,_u)}get arrayLength(){if(this.type!=="array")throw TypeError("not an array");return X(this,_u)===!0?-1:X(this,_u)===!1?this.value.length:null}static from(e,r){return new ef(Ya,e,r)}static uint8(e){return Xe(e,8)}static uint16(e){return Xe(e,16)}static uint24(e){return Xe(e,24)}static uint32(e){return Xe(e,32)}static uint40(e){return Xe(e,40)}static uint48(e){return Xe(e,48)}static uint56(e){return Xe(e,56)}static uint64(e){return Xe(e,64)}static uint72(e){return Xe(e,72)}static uint80(e){return Xe(e,80)}static uint88(e){return Xe(e,88)}static uint96(e){return Xe(e,96)}static uint104(e){return Xe(e,104)}static uint112(e){return Xe(e,112)}static uint120(e){return Xe(e,120)}static uint128(e){return Xe(e,128)}static uint136(e){return Xe(e,136)}static uint144(e){return Xe(e,144)}static uint152(e){return Xe(e,152)}static uint160(e){return Xe(e,160)}static uint168(e){return Xe(e,168)}static uint176(e){return Xe(e,176)}static uint184(e){return Xe(e,184)}static uint192(e){return Xe(e,192)}static uint200(e){return Xe(e,200)}static uint208(e){return Xe(e,208)}static uint216(e){return Xe(e,216)}static uint224(e){return Xe(e,224)}static uint232(e){return Xe(e,232)}static uint240(e){return Xe(e,240)}static uint248(e){return Xe(e,248)}static uint256(e){return Xe(e,256)}static uint(e){return Xe(e,256)}static int8(e){return Xe(e,-8)}static int16(e){return Xe(e,-16)}static int24(e){return Xe(e,-24)}static int32(e){return Xe(e,-32)}static int40(e){return Xe(e,-40)}static int48(e){return Xe(e,-48)}static int56(e){return Xe(e,-56)}static int64(e){return Xe(e,-64)}static int72(e){return Xe(e,-72)}static int80(e){return Xe(e,-80)}static int88(e){return Xe(e,-88)}static int96(e){return Xe(e,-96)}static int104(e){return Xe(e,-104)}static int112(e){return Xe(e,-112)}static int120(e){return Xe(e,-120)}static int128(e){return Xe(e,-128)}static int136(e){return Xe(e,-136)}static int144(e){return Xe(e,-144)}static int152(e){return Xe(e,-152)}static int160(e){return Xe(e,-160)}static int168(e){return Xe(e,-168)}static int176(e){return Xe(e,-176)}static int184(e){return Xe(e,-184)}static int192(e){return Xe(e,-192)}static int200(e){return Xe(e,-200)}static int208(e){return Xe(e,-208)}static int216(e){return Xe(e,-216)}static int224(e){return Xe(e,-224)}static int232(e){return Xe(e,-232)}static int240(e){return Xe(e,-240)}static int248(e){return Xe(e,-248)}static int256(e){return Xe(e,-256)}static int(e){return Xe(e,-256)}static bytes1(e){return Kt(e,1)}static bytes2(e){return Kt(e,2)}static bytes3(e){return Kt(e,3)}static bytes4(e){return Kt(e,4)}static bytes5(e){return Kt(e,5)}static bytes6(e){return Kt(e,6)}static bytes7(e){return Kt(e,7)}static bytes8(e){return Kt(e,8)}static bytes9(e){return Kt(e,9)}static bytes10(e){return Kt(e,10)}static bytes11(e){return Kt(e,11)}static bytes12(e){return Kt(e,12)}static bytes13(e){return Kt(e,13)}static bytes14(e){return Kt(e,14)}static bytes15(e){return Kt(e,15)}static bytes16(e){return Kt(e,16)}static bytes17(e){return Kt(e,17)}static bytes18(e){return Kt(e,18)}static bytes19(e){return Kt(e,19)}static bytes20(e){return Kt(e,20)}static bytes21(e){return Kt(e,21)}static bytes22(e){return Kt(e,22)}static bytes23(e){return Kt(e,23)}static bytes24(e){return Kt(e,24)}static bytes25(e){return Kt(e,25)}static bytes26(e){return Kt(e,26)}static bytes27(e){return Kt(e,27)}static bytes28(e){return Kt(e,28)}static bytes29(e){return Kt(e,29)}static bytes30(e){return Kt(e,30)}static bytes31(e){return Kt(e,31)}static bytes32(e){return Kt(e,32)}static address(e){return new ef(Ya,"address",e)}static bool(e){return new ef(Ya,"bool",!!e)}static bytes(e){return new ef(Ya,"bytes",e)}static string(e){return new ef(Ya,"string",e)}static array(e,r){throw new Error("not implemented yet")}static tuple(e,r){throw new Error("not implemented yet")}static overrides(e){return new ef(Ya,"overrides",Object.assign({},e))}static isTyped(e){return e&&typeof e=="object"&&"_typedSymbol"in e&&e._typedSymbol===Fk}static dereference(e,r){if(ef.isTyped(e)){if(e.type!==r)throw new Error(`invalid type: expecetd ${r}, got ${e.type}`);return e.value}return e}};_u=new WeakMap;let Xn=ef;class N1e extends r0{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,r){let n=Xn.dereference(r,"string");try{n=Zt(n)}catch(s){return this._throwError(s.message,r)}return e.writeValue(n)}decode(e){return Zt(vc(e.readValue(),20))}}class L1e extends r0{constructor(r){super(r.name,r.type,"_",r.dynamic);Ie(this,"coder");this.coder=r}defaultValue(){return this.coder.defaultValue()}encode(r,n){return this.coder.encode(r,n)}decode(r){return this.coder.decode(r)}}function sj(t,e,r){let n=[];if(Array.isArray(r))n=r;else if(r&&typeof r=="object"){let h={};n=e.map(p=>{const b=p.localName;return He(b,"cannot encode object for signature with missing names","INVALID_ARGUMENT",{argument:"values",info:{coder:p},value:r}),He(!h[b],"cannot encode object for signature with duplicate names","INVALID_ARGUMENT",{argument:"values",info:{coder:p},value:r}),h[b]=!0,r[b]})}else me(!1,"invalid tuple value","tuple",r);me(e.length===n.length,"types/value length mismatch","tuple",r);let s=new U9,i=new U9,o=[];e.forEach((h,p)=>{let b=n[p];if(h.dynamic){let v=i.length;h.encode(i,b);let E=s.writeUpdatableValue();o.push(_=>{E(_+v)})}else h.encode(s,b)}),o.forEach(h=>{h(s.length)});let f=t.appendWriter(s);return f+=t.appendWriter(i),f}function oj(t,e){let r=[],n=[],s=t.subReader(0);return e.forEach(i=>{let o=null;if(i.dynamic){let f=t.readIndex(),h=s.subReader(f);try{o=i.decode(h)}catch(p){if(Ns(p,"BUFFER_OVERRUN"))throw p;o=p,o.baseType=i.name,o.name=i.localName,o.type=i.type}}else try{o=i.decode(t)}catch(f){if(Ns(f,"BUFFER_OVERRUN"))throw f;o=f,o.baseType=i.name,o.name=i.localName,o.type=i.type}if(o==null)throw new Error("investigate");r.push(o),n.push(i.localName||null)}),Y2.fromItems(r,n)}class D1e extends r0{constructor(r,n,s){const i=r.type+"["+(n>=0?n:"")+"]",o=n===-1||r.dynamic;super("array",i,s,o);Ie(this,"coder");Ie(this,"length");lt(this,{coder:r,length:n})}defaultValue(){const r=this.coder.defaultValue(),n=[];for(let s=0;so||s<-(o+q1e))&&this._throwError("value out-of-bounds",n),s=O$(s,8*fi)}else(slu(i,this.size*8))&&this._throwError("value out-of-bounds",n);return r.writeValue(s)}decode(r){let n=lu(r.readValue(),this.size*8);return this.signed&&(n=Z2(n,this.size*8)),n}}class K1e extends aj{constructor(e){super("string",e)}defaultValue(){return""}encode(e,r){return super.encode(e,Rf(Xn.dereference(r,"string")))}decode(e){return _M(super.decode(e))}}class Zb extends r0{constructor(r,n){let s=!1;const i=[];r.forEach(f=>{f.dynamic&&(s=!0),i.push(f.type)});const o="tuple("+i.join(",")+")";super("tuple",o,n,s);Ie(this,"coders");lt(this,{coders:Object.freeze(r.slice())})}defaultValue(){const r=[];this.coders.forEach(s=>{r.push(s.defaultValue())});const n=this.coders.reduce((s,i)=>{const o=i.localName;return o&&(s[o]||(s[o]=0),s[o]++),s},{});return this.coders.forEach((s,i)=>{let o=s.localName;!o||n[o]!==1||(o==="length"&&(o="_length"),r[o]==null&&(r[o]=r[i]))}),Object.freeze(r)}encode(r,n){const s=Xn.dereference(n,"tuple");return sj(r,this.coders,s)}decode(r){return oj(r,this.coders)}}function ll(t){return kr(Rf(t))}function W1e(t){let e=0;function r(){return t[e++]<<8|t[e++]}let n=r(),s=1,i=[0,1];for(let $=1;$>--h&1}const v=31,E=2**v,_=E>>>1,S=_>>1,P=E-1;let I=0;for(let $=0;$1;){let se=H+J>>>1;$>>1|b(),Q=Q<<1^_,K=(K^_)<<1|_|1;T=Q,B=1+K-Q}let N=n-4;return C.map($=>{switch($-N){case 3:return N+65792+(t[f++]<<16|t[f++]<<8|t[f++]);case 2:return N+256+(t[f++]<<8|t[f++]);case 1:return N+t[f++];default:return $-1}})}function J1e(t){let e=0;return()=>t[e++]}function fj(t){return J1e(W1e(Z1e(t)))}function Z1e(t){let e=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach((s,i)=>e[s.charCodeAt(0)]=i);let r=t.length,n=new Uint8Array(6*r>>3);for(let s=0,i=0,o=0,f=0;s=8&&(n[i++]=f>>(o-=8));return n}function Q1e(t){return t&1?~t>>1:t>>1}function Y1e(t,e){let r=Array(t);for(let n=0,s=0;n{let e=wc(t);if(e.length)return e})}function uj(t){let e=[];for(;;){let r=t();if(r==0)break;e.push(X1e(r,t))}for(;;){let r=t()-1;if(r<0)break;e.push(eme(r,t))}return e.flat()}function Ag(t){let e=[];for(;;){let r=t(e.length);if(!r)break;e.push(r)}return e}function lj(t,e,r){let n=Array(t).fill().map(()=>[]);for(let s=0;sn[o].push(i));return n}function X1e(t,e){let r=1+e(),n=e(),s=Ag(e);return lj(s.length,1+t,e).flatMap((o,f)=>{let[h,...p]=o;return Array(s[f]).fill().map((b,v)=>{let E=v*n;return[h+v*r,p.map(_=>_+E)]})})}function eme(t,e){let r=1+e();return lj(r,1+t,e).map(s=>[s[0],s.slice(1)])}var fs=fj("AEgSbwjEDVYByQKaAQsBOQDpATQAngDUAHsAoABoANQAagCNAEQAhABMAHIAOwA9ACsANgAmAGIAHgAvACgAJwAXAC0AGgAjAB8ALwAUACkAEgAeAAkAGwARABkAFgA5ACgALQArADcAFQApABAAHgAiABAAGAAeABMAFwAXAA0ADgAWAA8AFAAVBFsF1QEXE0o3xAXUALIArkABaACmAgPGAK6AMDAwMAE/qAYK7P4HQAblMgVYBVkAPSw5Afa3EgfJwgAPA8meNALGCjACjqIChtk/j2+KAsXMAoPzASDgCgDyrgFCAi6OCkCQAOQA4woWABjVuskNDD6eBBx4AP4COhi+D+wKBirqBgSCaA0cBy4ArABqku+mnIAAXAaUJAbqABwAPAyUFvyp/Mo8INAIvCoDshQ8APcubKQAon4ZABgEJtgXAR4AuhnOBPsKIE04CZgJiR8cVlpM5INDABQADQAWAA9sVQAiAA8ASO8W2T30OVnKluYvChEeX05ZPe0AFAANABYAD2wgXUCYAMPsABwAOgzGFryp/AHauQVcBeMC0KACxLEKTR2kZhR0Gm5M9gC8DmgC4gAMLjSKF8qSAoF8ARMcAL4OaALiAAwuAUlQJpJMCwMt/AUpCthqGK4B2EQAciwSeAIyFiIDKCi6OGwAOuIB9iYAyA7MtgEcZIIAsgYABgCK1EoFHNZsGACoKNIBogAAAAAAKy4DnABoAQoaPu43dQQZGACrAcgCIgDgLBJ0OvRQsTOiKDVJBfsoBVoFWbC5BWo7XkITO1hCmHuUZmCh+QwUA8YIJvJ4JASkTAJUVAJ2HKwoAZCkpjZcA0YYBIRiCgDSBqxAMCQHKgI6XgBsAWIgcgCEHhoAlgFKuAAoahgBsMYDOC4iRFQBcFoGZgJmAPJKGAMqAgYASkIArABeAHQALLYGCPTwGo6AAAAKIgAqALQcSAHSAdwIDDKXeYHpAAsAEgA1AD4AOTR3etTBEGAQXQJNCkxtOxUMAq0PpwvmERYM0irM09kANKoH7ANUB+wDVANUB+wH7ANUB+wDVANUA1QDVBwL8BvUwRBgD0kEbgWPBYwE1wiEJkoRggcpCNNUDnQfHEgDRgD9IyZJHTuUMwwlQ0wNTQQH/TZDbKh9OQNIMaxU9pCjA8wyUDltAh5yEqEAKw90HTW2Tn96SHGhCkxPr7WASWNOaAK/Oqk/+QoiCZRvvHdPBj4QGCeiEPQMMAGyATgN6kvVBO4GOATGH3oZFg/KlZkIoi3aDOom4C6egFcj8iqABepL8TzaC0pRZQ9WC2IJ4DpggUsDHgEKIogK2g02CGoQ8ArGaA3iEUIHNgPSSZcAogb+Cw4dMhWyJg1iqQsGOXQG+BrzC4wmrBMmevkF0BoeBkoBJhr8AMwu5IWtWi5cGU9cBgALIiPEFKVQHQ0iQLR4RRoYBxIlpgKOQ21KhFEzHpAh8zw6DWMuEFF5B/I8AhlMC348m0aoRQsRzz6KPUUiRkwpBDJ8LCwniAnMD4IMtnxvAVYJHgmuDG4TLhEUN8IINgcWKpchJxIIHkaSYJcE9JwD8BPOAwgFPAk+BxADshwqEysVJgUKgSHUAvA20i6wAoxWfQEUBcgPIh/cEE1H3Q7mCJgCYgOAJegAKhUeABQimAhAYABcj9VTAi7ICMRqaSNxA2QU5F4RcAeODlQHpBwwFbwc3nDFXgiGBSigrAlYAXIJlgFcBOAIBjVYjJ0gPmdQi1UYmCBeQTxd+QIuDGIVnES6h3UCiA9oEhgBMgFwBzYM/gJ0EeoRaBCSCOiGATWyM/U6IgRMIYAgDgokA0xsywskJvYM9WYBoBJfAwk0OnfrZ6hgsyEX+gcWMsJBXSHuC49PygyZGr4YP1QrGeEHvAPwGvAn50FUBfwDoAAQOkoz6wS6C2YIiAk8AEYOoBQH1BhnCm6MzQEuiAG0lgNUjoACbIwGNAcIAGQIhAV24gAaAqQIoAACAMwDVAA2AqoHmgAWAII+AToDJCwBHuICjAOQCC7IAZIsAfAmBBjADBIA9DRuRwLDrgKAZ2afBdpVAosCRjIBSiIEAktETgOsbt4A2ABIBhDcRAESqEfIF+BAAdxsKADEAPgAAjIHAj4BygHwagC0AVwLLgmfsLIBSuYmAIAAEmgB1AKGANoAMgB87gFQAEoFVvYF0AJMRgEOLhUoVF4BuAMcATABCgB2BsiKosYEHARqB9ACEBgV3gLvKweyAyLcE8pCwgK921IAMhMKNQqkCqNgWF0wAy5vPU0ACx+lPsQ/SwVOO1A7VTtQO1U7UDtVO1A7VTtQO1UDlLzfvN8KaV9CYegMow3RRMU6RhPYYE5gLxPFLbQUvhXLJVMZOhq5JwIl4VUGDwEt0GYtCCk0che5ADwpZYM+Y4MeLQpIHORTjlT1LRgArkufM6wNqRsSRD0FRHXqYicWCwofAmR+AmI/WEqsWDcdAqH0AmiVAmYGAp+BOBgIAmY4AmYjBGsEfAN/EAN+jzkDOXQUOX86ICACbBoCMjM4BwJtxAJtq+yHMGRCKAFkANsA3gBHAgeVDIoA+wi/AAqyAncsAnafPAJ5SEACeLcaWdhFq0bwAnw8AnrFAn0GAnztR/1IemAhACgSSVVKWBIUSskC0P4C0MlLJAOITAOH40TCkS8C8p5dAAMDq0vLTCoiAMxNSU2sAos8AorVvhgEGkBkArQCjjQCjlk9lH4CjtYCjll1UbFTMgdS0VSCApP4ApMJAOYAGVUbVaxVzQMsGCmSgzLeeGNFODYCl5wC769YHqUAViIClowClnmZAKZZqVoGfkoAOAKWsgKWS1xBXM4CmcgCmWFcx10EFgKcmDm/OpoCnBMCn5gCnrWHABoMLicMAp3uAp6PALI6YTFh7AKe0AKgawGmAp6cHAKeS6JjxWQkIigCJ6wCJnsCoPgCoEnUAqYsAqXLAqf8AHoCp+9oeWiuAABGahlqzgKs4AKsqwKtZAKs/wJXGgJV2QKx3tQDH0tslAKyugoCsuUUbN1tYG1FXAMlygK2WTg8bo0DKUICuFsCuUQSArkndHAzcN4CvRYDLa8DMg4CvoVx/wMzbgK+F3Mfc0wCw8gCwwFzf3RIMkJ03QM8pAM8lwM9vALFeQLGRALGDYYCyGZOAshBAslMAskrAmSaAt3PeHZeeKt5IkvNAxigZv8CYfEZ8JUhewhej164DgLPaALPaSxIUM/wEJwAw6oCz3ABJucDTg9+SAIC3CQC24cC0kwDUlkDU1wA/gNViYCGPMgT6l1CcoLLg4oC2sQC2duEDYRGpzkDhqIALANkC4ZuVvYAUgLfYgLetXB0AuIs7REB8y0kAfSYAfLPhALr8ALpbXYC6vYC6uEA9kQBtgLuhgLrmZanlwAC7jwDhd2YdnDdcZ4C8wAAZgOOE5mQAvcQA5FrA5KEAveVAvnWAvhjmhmaqLg0mxsDnYAC/vcBGAA2nxmfsAMFigOmZwOm1gDOwgMGZ6GFogIGAwxGAQwBHAdqBl62ZAIAuARovA6IHrAKABRyNgAgAzASSgOGfAFgJB4AjOwAHgDmoAScjgi0BhygwgCoBRK86h4+PxZ5BWk4P0EsQiJCtV9yEl+9AJbGBTMAkE0am7o7J2AzErrQDjAYxxiKyfcFWAVZBVgFWQVkBVkFWAVZBVgFWQVYBVkFWAVZRxYI2IZoAwMDCmVe6iwEygOyBjC8vAC8BKi8AOhBKhazBUc+aj5xQkBCt192OF/pAFgSM6wAjP/MbMv9puhGez4nJAUsFyg3Nn5u32vB8hnDLGoBbNdvMRgFYAVrycLJuQjQSlwBAQEKfV5+jL8AND+CAAQW0gbmriQGAIzEDAMCDgDlZh4+JSBLQrJCvUI5JF8oYDcoOSQJwj4KRT9EPnk+gj5xPnICikK9SkM8X8xPUGtOCy1sVTBrDG8gX+E0OxwJaJwKYyQsPR4nQqxCvSzMAsv9X8oPIC8KCQoAACN+nt9rOy5LGMmsya0JZsLMzQphQWAP5hCkEgCTjh5GQiYbqm06zjkKND9EPnFCQBwICx5NSG1cLS5a4rwTCn7uHixCQBxeCUsKDzRVREM4BTtEnC0KghwuQkAb9glUIyQZMTIBBo9i8F8KcmTKYAxgLiRvAERgGjoDHB9gtAcDbBFmT2BOEgIAZOhgFmCWYH5gtGBMYJJpFhgGtg/cVqq8WwtDF6wBvCzOwgMgFgEdBB8BegJtMDGWU4EBiwq5SBsA5SR0jwvLDqdN6wGcAoidUAVBYAD4AD4LATUXWHsMpg0lILuwSABQDTUAFhO4NVUC0wxLZhEcANlPBnYECx9bADIAtwKbKAsWcKwzOaAaAVwBhwn9A9ruEAarBksGugAey1aqWwq7YhOKCy1ADrwBvAEjA0hbKSkpIR8gIi0TJwciDY4AVQJvWJFKlgJvIA9ySAHUdRDPUiEaqrFN6wcSBU1gAPgAPgsBewAHJW0LiAymOTEuyLBXDgwAYL0MAGRKaFAiIhzAADIAtwKbKC08D88CkRh8ULxYyXRzjtilnA72mhU+G+0S2hIHDxwByAk7EJQGESwNNwwAPAC0zwEDAKUA4gCbizAAFQBcG8cvbXcrDsIRAzwlRNTiHR8MG34CfATCC6vxbQA4Oi4Opzkuz6IdB7wKABA7Ls8SGgB9rNsdD7wbSBzOoncfAT4qYB0C7KAJBE3z5R9mDL0M+wg9Cj8ABcELPgJMDbwIvQ09CT0KvS7PoisOvAaYAhwPjBriBBwLvBY8AKELPBC8BRihe90AO2wMPQACpwm9BRzR9QYFB2/LBnwAB7wSXBISvQECAOsCAAB1FVwHFswV/HAXvBg8AC68AuyovAAevAJWISuAAAG8AALkFT0VvCvso7zJqDwEAp8nTAACXADn3hm8CaVcD7/FAPUafAiiBQv/cQDfvKe8GNwavKOMeXMG/KmchAASvAcbDAADlABtvAcAC7ynPAIaPLsIopzLDvwHwak8AOF8L7dtvwNJAAPsABW8AAb8AAm8AGmMABq8AA68Axi8jmoV/AABXAAObAAuTB8ABrwAF7wIIgANSwC6vCcAA7wADpwq7ACyWwAcHAAbvAAB7AqiAAXHCxYV3AAHnABCvAEDAGm8AAt8AB28AAi8CaIABcsAbqAZ1gCSCCIABcsAATwAB9wAHZwIIgAGmwAJfAAbLABtHADmvIEACFwACDwAFLwAaPwJIgAGywDjjAAJPAuiDsX7YAAHPABunUBJAEgACrwFAAM8AAmuAzgABxwAGXwAAgym/AAKHAAKPAAJ/KfsBrwACRwAAwwAEDwBABQ8ABFsAA+MAA3sAA28ABkMBxYcABU8AG6cFrQBvAC7ABM8BABpLAsA4UwAAjwABFMAF3wFHAAG0QAYvB8BfClTADpGALAJBw4McwApK3EBpQYIXwJtJA0ACghwTG1gK4oggRVjLjcDogq1AALZABcC/ARvAXdzSFMVIgNQAhY/AS0GBHRHvnxTe0EAKgAyAvwAVAvcAHyRLQEsAHfmDhIzRwJLAFgGAAJRAQiLzQB5PAQhpgBbANcWAJZpOCCMAM5ssgDQ1RcJw3Z0HBlXHgrSAYmRrCNUVE5JEz3DivoAgB04QSos4RKYUABzASosMSlDGhADMVYE+MbvAExm3QBrAnICQBF7Osh4LzXWBhETIAUVCK6v/xPNACYAAQIbAIYAiQCONgDjALQA1QCdPQC7AKsApgChAOcAnwDTAJwA4AEBAPwAwAB6AFsAywDNAPwA1wDrAIkAogEqAOMA2ADVBAIIKzTT09PTtb/bzM/NQjEWAUsBVS5GAVMBYgFhAVQBRUpCRGcMAUwUBgkEMzcMBwAgDSQmKCs3OTk8PDw9Pg0/HVBQUFBSUlFSKFNUVlVVHFxgYF9hYCNlZ29ucXFxcXFxc3Nzc3Nzc3Nzc3N1dXZ1dFsAPesAQgCTAHEAKwBf8QCHAFAAUAAwAm/oAIT+8fEAXQCM6wCYAEgAWwBd+PipAH4AfgBiAE8AqgAdAK8AfAI5AjwA9QDgAPcA9wDhAPgA4gDiAOEA3wAoAnQBSgE5ATcBTQE3ATcBNwEyATEBMQExARUBURAAKgkBAEwYCxcEFhcPAIcAjwCfAEoAYxkCKgBvAGgAkAMOAyArAxpCP0gqAIoCSADAAlACnQC5Ao8CjwKPAo8CjwKPAoQCjwKPAo8CjwKPAo8CjgKOApECmQKQAo8CjwKNAo0CjQKNAosCjgJuAc0CkAKYAo8CjwKOF3oMAPcGA5gCWgIzGAFNETYC2xILLBQBRzgUTpIBdKU9AWJaAP4DOkgA/wCSKh4ZkGsAKmEAagAvAIoDlcyM8K+FWwa7LA/DEgKe1nUrCwQkWwGzAN5/gYB/gX+Cg4N/hIeFf4aJh4GIg4mDin+Lf4x/jYuOf49/kIORf5J/k3+Uf5WElomXg5h/AIMloQCEBDwEOQQ7BD4EPARCBD8EOgRABEIEQQQ9BD8EQgCkA4gAylIA0AINAPdbAPcBGgD3APUA9QD2APXVhSRmvwD3APUA9QD2APUdAIpbAPcAigEaAPcAigLtAPcAitWFJGa/HQD4WwEaAPcA9wD1APUA9gD1APgA9QD1APYA9dWFJGa/HQCKWwEaAPcAigD3AIoC7QD3AIrVhSRmvx0CRAE3AksBOgJMwgOfAu0Dn9WFJGa/HQCKWwEaA58AigOfAIoC7QOfAIrVhSRmvx0EMQCKBDIAigeOMm4hLQCKAT9vBCQA/gDHWwMAVVv/FDMDAIoDPtkASgMAigMAl2dBtv/TrfLzakaPh3aztmIuZQrR3ER2n5Yo+qNR2jK/aP/V04UK1njIJXLgkab9PjOxyJDVbIN3R/FZLoZVl2kYFQIZ7V6LpRqGDt9OdDohnJKp5yX/HLj0voPpLrneDaN11t5W3sSM4ALscgSw8fyWLVkKa/cNcQmjYOgTLZUgOLi2F05g4TR0RfgZ4PBdntxdV3qvdxQt8DeaMMgjJMgwUxYN3tUNpUNx21AvwADDAIa0+raTWaoBXmShAl5AThpMi282o+WzOKMlxjHj7a+DI6AM6VI9w+xyh3Eyg/1XvPmbqjeg2MGXugHt8wW03DQMRTd5iqqOhjLvyOCcKtViGwAHVLyl86KqvxVX7MxSW8HLq6KCrLpB8SspAOHO9IuOwCh9poLoMEha9CHCxlRAXJNDobducWjqhFHqCkzjTM2V9CHslwq4iU19IxqhIFZMve15lDTiMVZIPdADXGxTqzSTv0dDWyk1ht430yvaYCy9qY0MQ3cC5c1uw4mHcTGkMHTAGC99TkNXFAiLQgw9ZWhwKJjGCe+J5FIaMpYhhyUnEgfrF3zEtzn40DdgCIJUJfZ0mo3eXsDwneJ8AYCr7Vx2eHFnt2H6ZEyAHs9JoQ4Lzh5zBoGOGwAz37NOPuqSNmZf51hBEovtpm2T1wI79OBWDyvCFYkONqAKGVYgIL0F+uxTcMLSPtFbiNDbBPFgip8MGDmLLHbSyGXdCMO6f7teiW9EEmorZ+75KzanZwvUySgjoUQBTfHlOIerJs6Y9wLlgDw18AB1ne0tZRNgGjcrqHbtubSUooEpy4hWpDzTSrmvqw0H9AoXQLolMt9eOM+l9RitBB1OBnrdC1XL4yLFyXqZSgZhv7FnnDEXLUeffb4nVDqYTLY6X7gHVaK4ZZlepja2Oe6OhLDI/Ve5SQTCmJdH3HJeb14cw99XsBQAlDy5s5kil2sGezZA3tFok2IsNja7QuFgM30Hff3NGSsSVFYZLOcTBOvlPx8vLhjJrSI7xrNMA/BOzpBIJrdR1+v+zw4RZ7ry6aq4/tFfvPQxQCPDsXlcRvIZYl+E5g3kJ+zLMZon0yElBvEOQTh6SaAdIO6BwdqJqfvgU+e8Y65FQhdiHkZMVt9/39N2jGd26J6cNjq8cQIyp6RonRPgVn2fl89uRDcQ27GacaN0MPrcNyRlbUWelKfDfyrNVVGBG5sjd3jXzTx06ywyzuWn5jbvEfPPCTbpClkgEu9oPLKICxU5HuDe3jA1XnvU85IYYhaEtOU1YVWYhEFsa4/TQj3rHdsU2da2eVbF8YjSI0m619/8bLMZu3xildwqM7zf1cjn4Whx0PSYXcY5bR7wEQfGC7CTOXwZdmsdTO8q3uGm7Rh/RfCWwpzBHCAaVfjxgibL5vUeL0pH6bzDmI9yCXKC/okkmbc28OJvI87L/bjFzpq0DHepw4kT1Od+fL7cyuFaRgfaUWB2++TCFvz11J0leEtrGkpccfX9z2LY39sph4PBHCjNOOkd0ybUm+ZzS8GkFbqMpq8uiX2yHpa0jllTLfGTDBMYR6FT5FWLLDPMkYxt1Q0eyMvxJWztDjy0m6VvZPvamrFXjHmPpU6WxrZqH6WW//I37RwvqPQhPz8I3RPuXAk1C94ZprQWm9iGM/KgiGDO6SV9sjp+Jmk4TBajMNJ5zzWZ1k1jrteQQBp9C2dOvmbIeeEME8y573Q8TgGe+ZCzutM45gYLBzYm2LNvgq2kebAbMpHRDSyh6dQ27GbsAAdCqQVVXWC1C+zpwBM2Lr4eqtobmmu1vJEDlIQR1iN8CUWpztq50z7FFQBn3SKViX6wSqzVQCoYvAjByjeSa+h1PRnYWvBinTDB9cHt4eqDsPS4jcD3FwXJKT0RQsl8EvslI2SFaz2OtmYLFV8FwgvWroZ3fKmh7btewX9tfL2upXsrsqpLJzpzNGyNlnuZyetg7DIOxQTMBR7dqlrTlZ6FWi1g4j1NSjA2j1Yd7fzTH6k9LxCyUCneAKYCU581bnvKih6KJTeTeCX4Zhme/QIz7w2o+AdSgtLAkdrLS9nfweYEqrMLsrGGSWXtgWamAWp6+x6GM/Z8jNw3BqPNQ39hrzYLECn3tPvh/LqKbRSCiDGauDKBBj/kGbpnM1Bb/my8hv4NWStclkwjfl57y4oNDgw1JAG9VOti3QVVoSziMEsSdfEjaCPIDb7SgpLXykQsM+nbqbt97I0mIlzWv0uqFobLMAq8Rd9pszUBKxFhBPwOjf//gVOz2r7URJ2OnpviCXv9iz3a4X/YLBYbXoYwxBv/Kq0a5s4utQHzoTerJ7PmFW/no/ZAsid/hRIV82tD+Qabh5F1ssIM8Ri3chu0PuPD3sSJRMjDoxLAbwUbroiPAz/V52e8s3DIixxlO7OrvhMj3qfzA0kKxzwicr5wJmZwJxTXgrwYsqhRvpgC2Nfdyd+TYYxJSZgk+gk2g9KyHSlwQVAyPtWWgvVGyVBqsU2LpDlLNosSAtolC1uBKt5pQZLhAxTjeGCWIC/HVpagc5rRwkgpCHKEsjA8d+scp8aiMewwQBhp5dYTV5t/Nvl+HbDMu8F3S0psPyZb1bSnqlHPFUnMQeQqSqwDBT23fJO9gO3aVaa1icrXU0PKwlMM5K+iL3ATcVq2fFWKk0irCTF4LDVDG4gUpkyplq6efcZS+WDR1woApjD18x+2JQR9oOXzuA7uy4b+/91WsJd/tSd1QcAH8PVPXApieA37B7YXPhDPH1azP3PKR+HfHmOoDYLeuKsIi/ssSsdYs62qJo14Hw1P2N/6zpr8F3FTWmJ4ysAVcl84Iv/tl///Z8FaAWbBQbyMNDZjrZ2JwdRjtd1jOeNumSodFtr4/Zf45iRJf/8HSW+KIB/+GlKu8Rv1BPLr/4duoL+kFPRqrstEr41gfJupoJRf4hcYDWX93FOcfEBiIivxtjtV8g7mvOReiamYWKE7vfPbv3v2L9Kwq3cIDFGLyhyfOGuf/9vA5muH6Pjg7B4SUj2ydDXra9fSBI+DrsNHA6l51wfHssJb+11TfNk7B8OleUe3Y+ZmHboMFHdv7FFP2cfISFyeAQR0sk/Xv62HBTdW4HmnGSLFk/cqyWVVFJkdIIa+4hos3JRHcqLoRKM5h2Qtk1RZtzISMtlXTfTqIc77YsCCgQD0r61jtxskCctwJOtjE/pL8wC4LBD4AZFjh2wzzFCrT/PNqW0/DeBbkfMfzVm9yy06WiF+1mTdNNEAytVtohBKg3brWd2VQa+aF+cQ0mW5CvbwOlWCT07liX226PjiVLwFCRs/Ax2/u+ZNPjrNFIWIPf5GjHyUKp60OeXe9F01f7IaPf/SDTvyDAf7LSWWejtiZcsqtWZjrdn6A2MqBwnSeKhrZOlUMmgMionmiCIvXqKZfmhGZ1MwD3uMF4n9KJcfWLA3cL5pq48tm5NDYNh3SS/TKUtmFSlQR89MR4+kxcqJgpGbhm9gXneDELkyqAN5nitmIzTscKeJRXqd64RiaOALR2d295NWwbjHRNG2AU5oR9OS2oJg/5CY6BFPc1JvD2Mxdhp2/MZdI8dLePxiP4KRIp8VXmqfg+jqd/RNG7GNuq1U2SiI4735Bdc0MVFx6mH5UOWEa5HuhYykd6t4M1gYLVS8m1B+9bUqi5DziQq7qT8d94cxB6AB4WqMCOF/zPPtRSZUUaMSsvHOWxGASufywTX8ogy6HgUf9p+Z30wUEosl8qgmwm6o2AV6nO9HKQjRHpN6SUegI5pvR61RLnUJ1lqCtmfcsRQutEizVpAaPXN7xMp5UQ5OSZK6tniCK9CpyMd7LjR6+MxfoMEDPpWdf2p2m5N3KO4QMxf+V7vGdYjemQczQ+m2MGIkFNYDMf0Yop2eSx81sP36WHUczqEhKysp2iJSYAvfgJjinKwToPvRKb+HBi+7cJ96S5ngfLOXaHAFRLkulo4TnXTFO51gX0TCCo4ZUHdbpdgkMEwUZAPjh6M+hA8DzycbtxAgH3uD6i0nN1aTiIuQ4BYCE9dEHHwAmINU+4YEWx4EC3OZwFGfYZMPLScVlb+BAAJeARUh+gdWA3/gRqCrf1jecgqeFf1MdzrrP4SVlGm5mMihSP+zYYksAB7O+SBPwNQqSNMiLnkviY/klwgcRmvqtCqeWeA0gjuir4CMZqmw/ntP6M+l0pdN8/P9xI53aP7x/zavJbbKOz8VzO/nXxIr1tjparMnqd6iWdByHKw4lF4p/u57Yv07WeZPDnRl7wgmDVZZ44fQsjdYO/gmXQ+940PRGst8UMQApFC4OOV22e4N+lVOPyFLAOj4t8R3PFw/FjbSWy0ELuAFReNkee8ORcBOT2NPDcs7OfpUmzvn/F9Czk9o9naMyVYy/j8I5qVFmQDFcptBp65J/+sJA3w/j6y/eqUkKxTsf0CZjtNdRSBEmJ2tmfgmJbqpcsSagk+Ul9qdyV+NnqFBIJZFCB1XwPvWGDBOjVUmpWGHsWA5uDuMgLUNKZ4vlq5qfzY1LnRhCc/mh5/EX+hzuGdDy5aYYx4BAdwTTeZHcZpl3X0YyuxZFWNE6wFNppYs3LcFJePOyfKZ8KYb7dmRyvDOcORLPH0sytC6mH1US3JVj6paYM1GEr+CUmyHRnabHPqLlh6Kl0/BWd3ebziDfvpRQpPoR7N+LkUeYWtQ6Rn5v5+NtNeBPs2+DKDlzEVR5aYbTVPrZekJsZ9UC9qtVcP99thVIt1GREnN8zXP8mBfzS+wKYym8fcW6KqrE702Zco+hFQAEIR7qimo7dd7wO8B7R+QZPTuCWm1UAwblDTyURSbd85P4Pz+wBpQyGPeEpsEvxxIZkKsyfSOUcfE3UqzMFwZKYijb7sOkzpou+tC4bPXey5GI1GUAg9c3vLwIwAhcdPHRsYvpAfzkZHWY20vWxxJO0lvKfj6sG2g/pJ1vd/X2EBZkyEjLN4nUZOpOO7MewyHCrxQK8d5aF7rCeQlFX+XksK6l6z971BPuJqwdjj68ULOj9ZTDdOLopMdOLL0PFSS792SXE/EC9EDnIXZGYhr52aQb+9b2zEdBSnpkxAdBUkwJDqGCpZk/HkRidjdp0zKv/Cm52EenmfeKX6HkLUJgMbTTxxIZkIeL/6xuAaAAHbA7mONVduTHNX/UJj1nJEaI7f3HlUyiqKn7VfBE+bdb4HWln1HPJx001Ulq1tOxFf8WZEARvq5Da1+pE7fPVxLntGACz3nkoLsKcPdUqdCwwiyWkmXTd5+bv3j7HaReRt3ESn783Ew3SWsvkEjKtbocNksbrLmV+GVZn1+Uneo35MT1/4r8fngQX5/ptORfgmWfF6KSB/ssJmUSijXxQqUpzkANEkSkYgYj560OOjJr6uqckFuO15TRNgABEwNDjus1V3q2huLPYERMCLXUNmJJpbMrUQsSO7Qnxta55TvPWL6gWmMOvFknqETzqzFVO8SVkovEdYatypLGmDy9VWfgAc0KyIChiOhbd7UlbAeVLPZyEDp4POXKBwN/KP5pT6Cyqs6yaI00vXMn1ubk9OWT9Q/O2t/C25qlnO/zO0xcBzpMBCAB8vsdsh3U8fnPX1XlPEWfaYJxKVaTUgfCESWl4CCkIyjE6iQ5JFcwU6S4/IH0/Agacp8d5Gzq2+GzPnJ7+sqk40mfFQpKrDbAKwLlr3ONEati2k/ycLMSUu7V/7BBkDlNyXoN9tvqXCbbMc4SSQXgC/DBUY9QjtrCtQ+susEomCq8xcNJNNMWCH31GtlTw2BdCXkJBjT+/QNWlBWwQ5SWCh1LdQ99QVii/DyTxjSR6rmdap3l3L3aiplQpPYlrzNm9er88fXd2+ao+YdUNjtqmxiVxmyYPzJxl67OokDcTezEGqldkGgPbRdXA+fGcuZVkembZByo7J1dMnkGNjwwCny+FNcVcWvWYL9mg8oF7jACVWI3bA64EXpdM8bSIEVIAs5JJH+LHXgnCsgcMGPZyAAVBncvbLiexzg9YozcytjPXVlAbQAC7Tc4S0C8QN4LlAGjj4pQAVWrwkaDoUYGxxvkCWKRRHkdzJB5zpREleBDL1oDKEvAqmkDibVC4kTqF89YO6laUjgtJPebBfzr16tg4t10GmN1sJ5vezk2sUOq8blCn5mPZyT3ltaDcddKupQjqusNM9wtFVD0ABzv17fZDn7GPT1nkCtdcgYejcK1qOcTGtPxnCX1rErEjVWCnEJv5HaOAUjgpiKQjUKkQi64D5g2COgwas8FcgIl0Pw95H9dWxE3QG0VbMNffh6BPlAojLDf4es2/5Xfq7hw5NGcON2g8Qsy2UQm94KddKyy3kdJxWgpNaEc15xcylbLC3vnT26u8qS90qc2MU8LdOJc5VPF5KnSpXIhnj1eJJ/jszjZ01oR6JDFJRoeTPO/wh4IPFbdG9KljuSzeuI92p8JF/bpgDE8wG86/W2EBKgPrmzdLijxssQn8mM44ky/KLGOJcrSwXIpZa/Z3v7W6HCRk7ewds99LTsUW1LbeJytw8Q/BFZVZyfO9BUHOCe2suuEkO8DU4fLX0IQSQ2TdOkKXDtPf3sNV9tYhYFueuPRhfQlEEy+aYM/MCz7diDNmFSswYYlZZPmKr2Q5AxLsSVEqqBtn6hVl1BCFOFExnqnIsmyY/NA8jXnDaNzr7Zv3hu+I1Mf/PJjk0gALN2G8ABzdf9FNvWHvZHhv6xIoDCXf964MxG92vGZtx/LYU5PeZqgly8tT5tGeQGeJzMMsJc5p+a5Rn2PtEhiRzo/5Owjy1n0Lzx3ev8GHQmeWb8vagG6O5Qk5nrZuQTiKODI4UqL0LLAusS2Ve7j1Ivdxquu1BR9Rc4QkOiUPwQXJv6du2E8i5pDhVoQpUhyMWGUT2O2YODIhjAfI71gxep5r5zAY7GBUZpy51hAw0pcCCrhOmU8Wp6ujQTdZQsCjtq6SHX8QAMNiPCIIkoxhHEZPgsBcOlP4aErJZPhF7qvx6gHrn8hEwPwYbx8YmT/n7lbcmTip1v8kgsrIjFTAlvLY4Nuil0KDmgz3svYs0ZJ3O3Is/vSx4xpxF1e2VAtZE8dJxGYEIhCSuPvCjP54l/NSNDnwlKvAW8mG+AQkgp7a87Igh26uKMFGD0PoPHTSvoWxiHuk+su8XkQiHIjeYKl/RdcOHpxhQH3zHCNE3aARm83Bl6zGxU/vMltlVPQhubcqhW4RYkl6uXk5JdP/QpzaKFpw2M8zvysv2qj7xaQECuu2akM0Cssj/uB9+wDR7uA6XOnLNaoczalHoMj33eiiu+DRaFsUmlmUZuh9bjDY4INMNSSAivSh03uJvny4Gj+D+neudoa7iJi7c4VFlZ/J5gUR82308zSNAt/ZroBXDWw0fV3eVPAn3aX0mtJabF6RsUZmL+Ehn+wn51/4QipMjD+6y64t7bjL6bjENan2prQ4h7++hBJ9NXvX8CUocJqMC937IasLzm5K0qwXeFMAimMHkEIQIQI2LrQ9sLBfXuyp66zWvlsh74GPv7Xpabj993pRNNDuFud5oIcn/92isbADXdpRPbjmbCNOrwRbxGZx2XmYNGMiV5kjF4IKyxCBvKier9U4uVoheCdmk83rp5G0PihAm2fAtczI4b9BWqX+nrZTrJX5kSwQddi93NQrXG+Cl3eBGNkM77VBsMpEolhXex1MVvMkZN9fG59GGbciH11FEXaY1MxrArovaSjE/lUUqBg2cZBNmiWbvzCHCPJ4RVGFK2dTbObM1m+gJyEX53fa7u3+TZpm74mNEzWbkVL4vjNwfL9uzRCu1cgbrNx5Yv5dDruNrIOgwIk+UZWwJfdbu/WHul6PMmRflVCIzd7B37Pgm/Up/NuCiQW7RXyafevN3AL6ycciCc4ZPlTRzEu+aURGlUBOJbUEsheX7PPyrrhdUt5JAG12EEEZpY/N3Vhbl5uLAfT0CbC2XmpnryFkxZmBTs5prvEeuf0bn73i3O82WTiQtJWEPLsBXnQmdnKhB06NbbhLtlTZYJMxDMJpFeajSNRDB2v61BMUHqXggUwRJ19m6p5zl51v11q34T74lTXdJURuV6+bg2D6qpfGnLy7KGLuLZngobM4pIouz4+n0/UzFKxDgLM4h+fUwKZozQ9UGrHjcif51Ruonz7oIVZ56xWtZS8z7u5zay6J2LD4gCYh2RXoBRLDKsUlZ80R8kmoxlJiL8aZCy2wCAonnucFxCLT1HKoMhbPKt34D97EXPPh0joO93iJVF1Uruew61Qoy3ZUVNX9uIJDt9AQWKLLo+mSzmTibyLHq0D6hhzpvgUgI6ekyVEL3FD+Fi5R3A8MRHPXspN1VyKkfRlC+OGiNgPC4NREZpFETgVmdXrQ2TxChuS3aY+Ndc7CiYv5+CmzfiqeZrWIQJW/C4RvjbGUoJFf1K6ZdR2xL/bG4kVq1+I4jQWX+26YUijpp+lpN7o5c6ZodXJCF56UkFGsqz44sIg8jrdWvbjRCxi2Bk0iyM3a7ecAV93zB6h1Ei38c0s6+8nrbkopArccGP8vntQe1bFeEh2nJIFOHX/k3/UHb5PtKGpnzbkmnRETMX+9X/QduLZWw/feklW/kH/JnzToJe9Kgu9Hct1UGbH5BPCLo4OOtQnZonW0xnyCcdtKyPQ/sbLiSTYJdSx4sJqWLMnfn6fIqPB3WAgk00J+fCOkomPHqtS67pf0mFmKoItYZUlJu6BihSZ8qve8+/X+LX1MhQXF95AshfUleCtmdn6l6QFXzLg2sgLn1oyVFuZecv7fzsIHzoRlAGp0gwYDOn1S4qabWvB5xUaE+Svw4KmjWtxdnuQbI32dw87D4N95u8qQRJTSQg0wLxOLkxSrPMLEn1UIhNKjAa9VLs3WLaXGrtCIt8bKY2AQP/ZdyRU6zT/E8qP2ltyBE2CCZPgWgEYDoJJO4n92y61ylNaSFXKohJhLjkfvYWm592539sIpmBNLlDo1bExFBfmHJJ0lFEiC/fj8v42OoMC9Mo3whIoWvyHfq6Uacqq55mzFf/EGC+NP/gHjhd6urc6R0hES27VXux7UY8CGKPohplWIZtTrFSaPWslCWy78E22Pw8fvReSUZx/txqLtHrFqg1DY/Eus6Iq1heZdrdcqE0/c971Bz1HW/XNXHsXpUIbI4kHdOfCc6T5zHZzvzQJB0ggMFL6IGPAilU9bj/ASdPk6fNvNtZqPuwEDhMBtBnhCexo6D6VAGIOPvJPPV523Y8R8a9vCqZbswSZKzOT1291BsUbmUWehtbb1fdRX9hiJKXvwr1QX6GjnZMgyMvnwOo2Dr24amr7FqEAbVeJAjRNOceM2EQ1Mna9fInqPJ5mh5X8CzT1aDOv08An0blz0fF5Gq4mS2cwq5glwIOlY5nznE8X4j/UdZ3FJsVIXte1JH0A7iibuPfazStM5O/Vo3KXIpXBeGORV0M9XDXFvsYZUHGvFCUubWzTw248EHE0cpQM2zNg6rjavreq3NHCAWsoZ7wvVy7l5gvtKRmIj1MnvfWEm0yFnGcuOq192350a5WefpfKCcX3Sn+AgHU+qnpstNtddbdVebagJU390lq9ko4aI9rqdaWXYG8tv5O/ZQHSqDRYHC6zfH10l5z++opso7aOSaIczlQ13iAzXvLdEu0V7kwNUZ1c8Y8aq7SeIEe5p902FlNkW8DnwHyueHchbK8vVFJfmr9mz7P8nUSccl1ULaoWMRSI1ls32kvlK0h46h3J25Yd9AzfcJbp9qYF/SEt3H5j69mMdcsNxZcAzT/A89ov3tglTX54y/EwjMfuoDoxPwLJDm5I7q6F9Kp469yNy1zSxz0N4HbRRBj9xFFuogvBspv7DXUNIsGxTINEQfmctb42XImWAODgARNo7dfcTqFKq6aTfivmvunLmzP9f8yLsJvXD3JbcPcDGNriMAcjzeDTNr65t8YB5tsnFDFLa0Uwmd2OvUdkLMX9TsAUYUfooSv47sw5J88j7CpahRjjO3/UhOXjTS39W5YZAel2KTbQd1h7INOw9P23GW7GDAe4agIUFHP48MZr7ubq0efFmmtwYMyk7D0r1oeG/CGOODgb9Ur+JMHxkwzPbtCX2ZnENQuI0RN5SyTIZuoY4XS9Rd/tPe3vNAZGSHM/YYwqs9xkkENx0O+eC2YVW1cwOJ3ckE890nbQeHLKlW15L0P0W2VliyYrfNr0nrIYddoRyGaCtj4OYd2MT7ebApqZOAQIaSHJM4mphhfjNjtnjg6YRyx9qM2FT3xOiYIMqXPFWdzhSgFF8ItocqVV09CmIoO8k6U/oJB7++wSX/YksxfPXHyjSgAGZOj1aKEq9fSvXBqtp2wu8/FxEf5AxapAD06pPGuLVUYLdgEzHR8wqRGYEwiUO9MyYbgswstuLYhwYFpSVKOdzAihZ9LuHtD598EGhINU9xc9xhL+QgTLAstmPIvvm2xyRw/WTUPXkP3ZHu6GyPmj5xFH9/QGpkglKXRVUBgVmLOJx8uZO2AstxQYocZH2JhORlxawj66BAXUEs7K/gPxINIRAFyK3WLuyq9oBTF9wEbnmCot82WjIg7CPNwYK3KrZMrKAz5yFszg4wCVLJVnIL8+OYA0xRDH8cHQjQUiQ2i1mr/be32k/3Xej9sdf3iuGvZHyLFSJvPSqz/wltnxumTJYKZsrWXtx/Rmu39jjV9lFaJttfFn57/No2h/unsJmMHbrnZ8csxkp5HQ4xR1s0HH+t3Iz82a3iQWTUDGq/+l2W3TUYLE8zNdL8Y+5oXaIH/Y2UUcX67cXeN4WvENZjz4+8q7vjhowOI3rSjFhGZ6KzwmU7+5nFV+kGWAZ5z2UWvzq0TK0pk1hPwAN4jbw//1CApRvIaIjhSGhioY6TUmsToek9cF9XjJdHvLPcyyCV3lbR5Jiz/ts46ay2F820VjTXvllElwrGzKcNSyvQlWDXdwrUINXmHorAM3fE19ngLZmgeUaCJLsSITf2VcfAOuWwX7mTPdP8Zb/04KqRniufCpwnDUk7sP0RX6cud/sanFMagnzKInSRVey0YzlVSOtA/AjrofmSH6RYbJQ8b4NDeTkIGc6247+Mnbez/qhJ9GAv9fGNFercPnnrf285Qgs+UqThLRgflcAKFuqWhLzZaR4QqvSwa3xe0LPkqj9xJWub195r7NrrR0e78FR+0mRBNMPsraqZctAUVAJfYKehTDV1MGGQSeDsOK9J3sbUuKRIS/WilX/64CBms9jCZocBlsBSZaIAjWm/SUZ8daWL2a/cJFyUOFqE3Epc2RWbtjNyPwOGpWtzu32kUooUqsJud7IV4E8rstUBXM7tGEtBx99x60g1duhyvxeKJSl8s5E34HTMmADT0836aEdg5Dv9rVyCz8i2REOmiz6wtIVFN0HsjAoN37SrY0bV1Ms8CRUILhvZvvRaDzoVCaSI0u8EPuTe4b7OPowgRGODl22UBBmHSTUY8e4DyL+Bc7bngo+2T8HtNvzyATSL5iJZgFPKpmUyZv54vVL90+/RQGATUmNKnrIvcJMYON9fl83naW5sf6hRkbbTC9RUEE6XADwjgA46wWfUQ+QWZl0J4PVTWAln/YfAz/SV3q3J9+yCYDleruoN5uoc/wT2f4YONGTb6zTGq3V+3JqzmCOjwebKln+fExVLN7sqtqfMnsKVXWbb2Ai5m3D/fCTgX7oKYzTZvj+m28XnDqPbXuP4MyWdmPezcesdrh7rCzA7BWdObiuyDEKjjzBbQ0qnuwjliz+b+j7aPMKlkXyIznV3tGzAfYwIbzGGt098oh4eq3ruDjdgHtjxfFCjHrjjRbHajoz/YOY4raojPFQ910GIlBV7hq47UDgpyajBxQUmD8NctiLV1rTSLAEsQDLTeRKcmPBMVMFF0SPBBhZ5oXoxtD3lMhuAQXmA+57OcciczVW9e9zwSIAHS+FJmvfXMJGF1dMBsIUMaPjvgaVqUc3p32qVCMQYFEiRLzlVSOGMCmv/HJIxAHe3mL/XnoZ1IkWLeRZfgyByjnDbbeRK5KL7bYHSVJZ9UFq+yCiNKeRUaYjgbC3hVUvfJAhy/QNl/JqLKVvGMk9ZcfyGidNeo/VTxK9vUpodzfQI9Z2eAre4nmrkzgxKSnT5IJ1D69oHuUS5hp7pK9IAWuNrAOtOH0mAuwCrY8mXAtVXUeaNK3OXr6PRvmWg4VQqFSy+a1GZfFYgdsJELG8N0kvqmzvwZ02Plf5fH9QTy6br0oY/IDsEA+GBf9pEVWCIuBCjsup3LDSDqI+5+0IKSUFr7A96A2f0FbcU9fqljdqvsd8sG55KcKloHIFZem2Wb6pCLXybnVSB0sjCXzdS8IKvE");const Uk=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]),zk=4;function tme(t){return t.toString(16).toUpperCase().padStart(2,"0")}function hj(t){return`{${tme(t)}}`}function rme(t){let e=[];for(let r=0,n=t.length;r>24&255}function dj(t){return t&16777215}const nme=new Map(cj(TS).flatMap((t,e)=>t.map(r=>[r,e+1<<24]))),ime=new Set(wc(TS)),pj=new Map,g7=new Map;for(let[t,e]of uj(TS)){if(!ime.has(t)&&e.length==2){let[r,n]=e,s=g7.get(r);s||(s=new Map,g7.set(r,s)),s.set(n,t)}pj.set(t,e.reverse())}const Mg=44032,m6=4352,g6=4449,y6=4519,mj=19,gj=21,_p=28,b6=gj*_p,sme=mj*b6,ome=Mg+sme,ame=m6+mj,fme=g6+gj,cme=y6+_p;function yj(t){return t>=Mg&&t=m6&&t=g6&&ey6&&e0&&s(y6+p)}else{let o=pj.get(i);o?r.push(...o):s(i)}if(!r.length)break;i=r.pop()}if(n&&e.length>1){let i=vm(e[0]);for(let o=1;o0&&s>=o)o==0?(e.push(n,...r),r.length=0,n=f):r.push(f),s=o;else{let h=ume(n,f);h>=0?n=h:s==0&&o==0?(e.push(n),n=f):(r.push(f),s=o)}}return n>=0&&e.push(n,...r),e}function vj(t){return bj(t).map(dj)}function hme(t){return lme(bj(t))}const y7=65039,xj=".",wj=1,jk=45;function y1(){return new Set(wc(fs))}const dme=new Map(uj(fs)),pme=y1(),v6=y1(),Hk=new Set(wc(fs).map(function(t){return this[t]},[...v6])),mme=y1();y1();const gme=cj(fs);function qk(){return new Set([wc(fs).map(t=>gme[t]),wc(fs)].flat(2))}const yme=fs(),Sg=Ag(t=>{let e=Ag(fs).map(r=>r+96);if(e.length){let r=t>=yme;e[0]-=32,e=Eg(e),r&&(e=`Restricted[${e}]`);let n=qk(),s=qk(),i=[...n,...s].sort((f,h)=>f-h),o=!fs();return{N:e,P:n,M:o,R:r,V:new Set(i)}}}),Gk=y1(),_g=new Map;[...Gk,...y1()].sort((t,e)=>t-e).map((t,e,r)=>{let n=fs(),s=r[e]=n?r[e-n]:{V:[],M:new Map};s.V.push(t),Gk.has(t)||_g.set(t,s)});for(let{V:t,M:e}of new Set(_g.values())){let r=[];for(let s of t){let i=Sg.filter(f=>f.V.has(s)),o=r.find(({G:f})=>i.some(h=>f.has(h)));o||(o={G:new Set,V:[]},r.push(o)),o.V.push(s),i.forEach(f=>o.G.add(f))}let n=r.flatMap(({G:s})=>[...s]);for(let{G:s,V:i}of r){let o=new Set(n.filter(f=>!s.has(f)));for(let f of i)e.set(f,o)}}let Pg=new Set,Aj=new Set;for(let t of Sg)for(let e of t.V)(Pg.has(e)?Aj:Pg).add(e);for(let t of Pg)!_g.has(t)&&!Aj.has(t)&&_g.set(t,wj);const bme=new Set([...Pg,...vj(Pg)]),vme=wc(fs),xme=Ej([]);function Ej(t){let e=Ag(()=>{let f=wc(fs).map(h=>vme[h]);if(f.length)return Ej(f)}).sort((f,h)=>h.Q.size-f.Q.size),r=fs(),n=r%3;r=r/3|0;let s=r&1;r>>=1;let i=r&1,o=r&2;return{B:e,V:n,F:s,S:i,C:o,Q:new Set(t)}}class wme extends Array{get is_emoji(){return!0}}function Gx(t,e=hj){let r=[];Mme(t[0])&&r.push("◌");let n=0,s=t.length;for(let i=0;i=4&&t[2]==jk&&t[3]==jk)throw new Error("invalid label extension")}function Vk(t){for(let r=t.lastIndexOf(95);r>0;)if(t[--r]!==95)throw new Error("underscore allowed only at start")}function Eme(t){let e=t[0],r=Uk.get(e);if(r)throw Fm(`leading ${r}`);let n=t.length,s=-1;for(let i=1;i{let s=rme(n),i={input:s,offset:r};r+=s.length+1;let o;try{let f=i.tokens=kme(s,hme),h=f.length,p;if(h){let b=f[0],v=h>1||b.is_emoji;if(!v&&b.every(E=>E<128))o=b,Vk(o),Ame(o),p="ASCII";else if(v&&(i.emoji=!0,b=f.flatMap(E=>E.is_emoji?[]:E)),o=f.flatMap(E=>!e&&E.is_emoji?Rme(E):E),Vk(o),!b.length)p="Emoji";else{if(v6.has(o[0]))throw Fm("leading combining mark");for(let S=1;So.has(f)):[...o],!r.length)return}else n.push(s)}if(r){for(let s of r)if(n.every(i=>s.V.has(i)))throw new Error(`whole-script confusable: ${t.N}/${s.N}`)}}function Cme(t){let e=Sg;for(let r of t){let n=e.filter(s=>s.V.has(r));if(!n.length)throw e===Sg?Sj(r):_j(e[0],r);if(e=n,n.length==1)break}return e}function Ime(t){return t.map(({input:e,error:r,output:n})=>{if(r){let s=r.message;throw new Error(t.length==1?s:`Invalid label ${RS(Gx(e))}: ${s}`)}return Eg(n)}).join(xj)}function Sj(t){return new Error(`disallowed character: ${kS(t)}`)}function _j(t,e){let r=kS(e),n=Sg.find(s=>s.P.has(e));return n&&(r=`${n.N} ${r}`),new Error(`illegal mixture: ${t.N} + ${r}`)}function Fm(t){return new Error(`illegal placement: ${t}`)}function Tme(t,e){let{V:r,M:n}=t;for(let s of e)if(!r.has(s))throw _j(t,s);if(n){let s=vj(e);for(let i=1,o=s.length;izk)throw new Error(`non-spacing marks: too many ${RS(Gx(s.slice(i-1,f)))} (${f-i}/${zk})`);i=f}}}function kme(t,e){let r=[],n=[];for(t=t.slice().reverse();t.length;){let s=Bme(t);if(s)n.length&&(r.push(e(n)),n=[]),r.push(s);else{let i=t.pop();if(bme.has(i))n.push(i);else{let o=dme.get(i);if(o)n.push(...o);else if(!pme.has(i))throw Sj(i)}}}return n.length&&r.push(e(n)),r}function Rme(t){return t.filter(e=>e!=y7)}function Bme(t,e){let r=xme,n,s,i=[],o=t.length;for(e&&(e.length=0);o;){let f=t[--o];if(r=r.B.find(h=>h.Q.has(f)),!r)break;if(r.S)s=f;else if(r.C&&f===s)break;i.push(f),r.F&&(i.push(y7),o>0&&t[o-1]==y7&&o--),r.V&&(n=Ome(i,r),e&&e.push(...t.slice(o).reverse()),t.length=o)}return n}function Ome(t,e){let r=wme.from(t);return e.V==2&&r.splice(1,1),r}const Pj=new Uint8Array(32);Pj.fill(0);function Kk(t){return me(t.length!==0,"invalid ENS name; empty component","comp",t),t}function Cj(t){const e=Rf(Nme(t)),r=[];if(t.length===0)return r;let n=0;for(let s=0;s{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const r=new Uint8Array(e.length+1);return r.set(e,1),r[0]=r.length-1,r})))+"00"}function O8(t,e){return{address:Zt(t),storageKeys:e.map((r,n)=>(me(Rr(r,32),"invalid slot",`storageKeys[${n}]`,r),r.toLowerCase()))}}function Bl(t){if(Array.isArray(t))return t.map((r,n)=>Array.isArray(r)?(me(r.length===2,"invalid slot set",`value[${n}]`,r),O8(r[0],r[1])):(me(r!=null&&typeof r=="object","invalid address-slot set","value",t),O8(r.address,r.storageKeys)));me(t!=null&&typeof t=="object","invalid access list","value",t);const e=Object.keys(t).map(r=>{const n=t[r].reduce((s,i)=>(s[i]=!0,s),{});return O8(r,Object.keys(n).sort())});return e.sort((r,n)=>r.address.localeCompare(n.address)),e}function Dme(t){let e;return typeof t=="string"?e=CS.computePublicKey(t,!1):e=t.publicKey,Zt(kr("0x"+e.substring(4)).substring(26))}function $me(t,e){return Dme(CS.recoverPublicKey(t,e))}const Pi=BigInt(0),Fme=BigInt(2),Ume=BigInt(27),zme=BigInt(28),jme=BigInt(35),Hme=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function BS(t){return t==="0x"?null:Zt(t)}function Ij(t,e){try{return Bl(t)}catch(r){me(!1,r.message,e,t)}}function Vx(t,e){return t==="0x"?0:Ct(t,e)}function ai(t,e){if(t==="0x")return Pi;const r=ft(t,e);return me(r<=Hme,"value exceeds uint size",e,r),r}function In(t,e){const r=ft(t,"value"),n=rs(r);return me(n.length<=32,"value too large",`tx.${e}`,r),n}function Tj(t){return Bl(t).map(e=>[e.address,e.storageKeys])}function qme(t){const e=PM(t);me(Array.isArray(e)&&(e.length===9||e.length===6),"invalid field count for legacy transaction","data",t);const r={type:0,nonce:Vx(e[0],"nonce"),gasPrice:ai(e[1],"gasPrice"),gasLimit:ai(e[2],"gasLimit"),to:BS(e[3]),value:ai(e[4],"value"),data:nt(e[5]),chainId:Pi};if(e.length===6)return r;const n=ai(e[6],"v"),s=ai(e[7],"r"),i=ai(e[8],"s");if(s===Pi&&i===Pi)r.chainId=n;else{let o=(n-jme)/Fme;o=this.maxPriorityFeePerGas,"priorityFee cannot be more than maxFee","BAD_DATA",{value:this}),He(!r||this.type!==0&&this.type!==1,"transaction type cannot have maxFeePerGas or maxPriorityFeePerGas","BAD_DATA",{value:this}),He(this.type!==0||!n,"legacy transaction cannot have accessList","BAD_DATA",{value:this});const s=[];return this.type!=null?s.push(this.type):r?s.push(2):e?(s.push(1),n||s.push(0)):n?(s.push(1),s.push(2)):(s.push(0),s.push(1),s.push(2)),s.sort(),s}isLegacy(){return this.type===0}isBerlin(){return this.type===1}isLondon(){return this.type===2}clone(){return P0.from(this)}toJSON(){const e=r=>r==null?null:r.toString();return{type:this.type,to:this.to,data:this.data,nonce:this.nonce,gasLimit:e(this.gasLimit),gasPrice:e(this.gasPrice),maxPriorityFeePerGas:e(this.maxPriorityFeePerGas),maxFeePerGas:e(this.maxFeePerGas),value:e(this.value),chainId:e(this.chainId),sig:this.signature?this.signature.toJSON():null,accessList:this.accessList}}static from(e){if(e==null)return new P0;if(typeof e=="string"){const n=$t(e);if(n[0]>=127)return P0.from(qme(n));switch(n[0]){case 1:return P0.from(Vme(n));case 2:return P0.from(Gme(n))}He(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:"from"})}const r=new P0;return e.type!=null&&(r.type=e.type),e.to!=null&&(r.to=e.to),e.nonce!=null&&(r.nonce=e.nonce),e.gasLimit!=null&&(r.gasLimit=e.gasLimit),e.gasPrice!=null&&(r.gasPrice=e.gasPrice),e.maxPriorityFeePerGas!=null&&(r.maxPriorityFeePerGas=e.maxPriorityFeePerGas),e.maxFeePerGas!=null&&(r.maxFeePerGas=e.maxFeePerGas),e.data!=null&&(r.data=e.data),e.value!=null&&(r.value=e.value),e.chainId!=null&&(r.chainId=e.chainId),e.signature!=null&&(r.signature=Jf.from(e.signature)),e.accessList!=null&&(r.accessList=e.accessList),e.hash!=null&&(me(r.isSigned(),"unsigned transaction cannot define hash","tx",e),me(r.hash===e.hash,"hash mismatch","tx",e)),e.from!=null&&(me(r.isSigned(),"unsigned transaction cannot define from","tx",e),me(r.from.toLowerCase()===(e.from||"").toLowerCase(),"from mismatch","tx",e)),r}};lf=new WeakMap,wd=new WeakMap,Ad=new WeakMap,Ed=new WeakMap,Md=new WeakMap,Sd=new WeakMap,_d=new WeakMap,Pd=new WeakMap,Cd=new WeakMap,Id=new WeakMap,Td=new WeakMap,kd=new WeakMap;let x6=P0;const Rj=new Uint8Array(32);Rj.fill(0);const Kme=BigInt(-1),Bj=BigInt(0),Oj=BigInt(1),Wme=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function Jme(t){const e=$t(t),r=e.length%32;return r?tn([e,Rj.slice(r)]):nt(e)}const Zme=vc(Oj,32),Qme=vc(Bj,32),Qk={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},N8=["name","version","chainId","verifyingContract","salt"];function Yk(t){return function(e){return me(typeof e=="string",`invalid domain value for ${JSON.stringify(t)}`,`domain.${t}`,e),e}}const Yme={name:Yk("name"),version:Yk("version"),chainId:function(t){const e=ft(t,"domain.chainId");return me(e>=0,"invalid chain ID","domain.chainId",t),Number.isSafeInteger(e)?Number(e):Th(e)},verifyingContract:function(t){try{return Zt(t).toLowerCase()}catch{}me(!1,'invalid domain value "verifyingContract"',"domain.verifyingContract",t)},salt:function(t){const e=$t(t,"domain.salt");return me(e.length===32,'invalid domain value "salt"',"domain.salt",t),nt(e)}};function L8(t){{const e=t.match(/^(u?)int(\d*)$/);if(e){const r=e[1]==="",n=parseInt(e[2]||"256");me(n%8===0&&n!==0&&n<=256&&(e[2]==null||e[2]===String(n)),"invalid numeric width","type",t);const s=lu(Wme,r?n-1:n),i=r?(s+Oj)*Kme:Bj;return function(o){const f=ft(o,"value");return me(f>=i&&f<=s,`value out-of-bounds for ${t}`,"value",f),vc(r?O$(f,256):f,32)}}}{const e=t.match(/^bytes(\d+)$/);if(e){const r=parseInt(e[1]);return me(r!==0&&r<=32&&e[1]===String(r),"invalid bytes width","type",t),function(n){const s=$t(n);return me(s.length===r,`invalid length for ${t}`,"value",n),Jme(n)}}}switch(t){case"address":return function(e){return sl(Zt(e),32)};case"bool":return function(e){return e?Zme:Qme};case"bytes":return function(e){return kr(e)};case"string":return function(e){return ll(e)}}return null}function Xk(t,e){return`${t}(${e.map(({name:r,type:n})=>n+" "+r).join(",")})`}var Wg,hf,Rd,o5,Nj,Mi;let eR=(Mi=class{constructor(e){Te(this,o5);Ie(this,"primaryType");Te(this,Wg,void 0);Te(this,hf,void 0);Te(this,Rd,void 0);fe(this,Wg,JSON.stringify(e)),fe(this,hf,new Map),fe(this,Rd,new Map);const r=new Map,n=new Map,s=new Map;Object.keys(e).forEach(f=>{r.set(f,new Set),n.set(f,[]),s.set(f,new Set)});for(const f in e){const h=new Set;for(const p of e[f]){me(!h.has(p.name),`duplicate variable name ${JSON.stringify(p.name)} in ${JSON.stringify(f)}`,"types",e),h.add(p.name);const b=p.type.match(/^([^\x5b]*)(\x5b|$)/)[1]||null;me(b!==f,`circular type reference to ${JSON.stringify(b)}`,"types",e),!L8(b)&&(me(n.has(b),`unknown type ${JSON.stringify(b)}`,"types",e),n.get(b).push(f),r.get(f).add(b))}}const i=Array.from(n.keys()).filter(f=>n.get(f).length===0);me(i.length!==0,"missing primary type","types",e),me(i.length===1,`ambiguous primary types or unused types: ${i.map(f=>JSON.stringify(f)).join(", ")}`,"types",e),lt(this,{primaryType:i[0]});function o(f,h){me(!h.has(f),`circular type reference to ${JSON.stringify(f)}`,"types",e),h.add(f);for(const p of r.get(f))if(n.has(p)){o(p,h);for(const b of h)s.get(b).add(p)}h.delete(f)}o(this.primaryType,new Set);for(const[f,h]of s){const p=Array.from(h);p.sort(),X(this,hf).set(f,Xk(f,e[f])+p.map(b=>Xk(b,e[b])).join(""))}}get types(){return JSON.parse(X(this,Wg))}getEncoder(e){let r=X(this,Rd).get(e);return r||(r=Ge(this,o5,Nj).call(this,e),X(this,Rd).set(e,r)),r}encodeType(e){const r=X(this,hf).get(e);return me(r,`unknown type: ${JSON.stringify(e)}`,"name",e),r}encodeData(e,r){return this.getEncoder(e)(r)}hashStruct(e,r){return kr(this.encodeData(e,r))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,r,n){if(L8(e))return n(e,r);const s=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(s)return me(!s[3]||parseInt(s[3])===r.length,`array length mismatch; expected length ${parseInt(s[3])}`,"value",r),r.map(o=>this._visit(s[1],o,n));const i=this.types[e];if(i)return i.reduce((o,{name:f,type:h})=>(o[f]=this._visit(h,r[f],n),o),{});me(!1,`unknown type: ${e}`,"type",e)}visit(e,r){return this._visit(this.primaryType,e,r)}static from(e){return new Mi(e)}static getPrimaryType(e){return Mi.from(e).primaryType}static hashStruct(e,r,n){return Mi.from(r).hashStruct(e,n)}static hashDomain(e){const r=[];for(const n in e){if(e[n]==null)continue;const s=Qk[n];me(s,`invalid typed-data domain key: ${JSON.stringify(n)}`,"domain",e),r.push({name:n,type:s})}return r.sort((n,s)=>N8.indexOf(n.name)-N8.indexOf(s.name)),Mi.hashStruct("EIP712Domain",{EIP712Domain:r},e)}static encode(e,r,n){return tn(["0x1901",Mi.hashDomain(e),Mi.from(r).hash(n)])}static hash(e,r,n){return kr(Mi.encode(e,r,n))}static async resolveNames(e,r,n,s){e=Object.assign({},e);for(const f in e)e[f]==null&&delete e[f];const i={};e.verifyingContract&&!Rr(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const o=Mi.from(r);o.visit(n,(f,h)=>(f==="address"&&!Rr(h,20)&&(i[h]="0x"),h));for(const f in i)i[f]=await s(f);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),n=o.visit(n,(f,h)=>f==="address"&&i[h]?i[h]:h),{domain:e,value:n}}static getPayload(e,r,n){Mi.hashDomain(e);const s={},i=[];N8.forEach(h=>{const p=e[h];p!=null&&(s[h]=Yme[h](p),i.push({name:h,type:Qk[h]}))});const o=Mi.from(r),f=Object.assign({},r);return me(f.EIP712Domain==null,"types must not contain EIP712Domain type","types.EIP712Domain",r),f.EIP712Domain=i,o.encode(n),{types:f,domain:s,primaryType:o.primaryType,message:o.visit(n,(h,p)=>{if(h.match(/^bytes(\d*)/))return nt($t(p));if(h.match(/^u?int/))return ft(p).toString();switch(h){case"address":return p.toLowerCase();case"bool":return!!p;case"string":return me(typeof p=="string","invalid string","value",p),p}me(!1,"unsupported type","type",h)})}}},Wg=new WeakMap,hf=new WeakMap,Rd=new WeakMap,o5=new WeakSet,Nj=function(e){{const s=L8(e);if(s)return s}const r=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(r){const s=r[1],i=this.getEncoder(s);return o=>{me(!r[3]||parseInt(r[3])===o.length,`array length mismatch; expected length ${parseInt(r[3])}`,"value",o);let f=o.map(i);return X(this,hf).has(s)&&(f=f.map(kr)),kr(tn(f))}}const n=this.types[e];if(n){const s=ll(X(this,hf).get(e));return i=>{const o=n.map(({name:f,type:h})=>{const p=this.getEncoder(h)(i[f]);return X(this,hf).has(h)?kr(p):p});return o.unshift(s),tn(o)}}me(!1,`unknown type: ${e}`,"type",e)},Mi);function ci(t){const e=new Set;return t.forEach(r=>e.add(r)),Object.freeze(e)}const Xme="external public payable",ege=ci(Xme.split(" ")),Lj="constant external internal payable private public pure view",tge=ci(Lj.split(" ")),Dj="constructor error event fallback function receive struct",$j=ci(Dj.split(" ")),Fj="calldata memory storage payable indexed",rge=ci(Fj.split(" ")),nge="tuple returns",ige=[Dj,Fj,nge,Lj].join(" "),sge=ci(ige.split(" ")),oge={"(":"OPEN_PAREN",")":"CLOSE_PAREN","[":"OPEN_BRACKET","]":"CLOSE_BRACKET",",":"COMMA","@":"AT"},age=new RegExp("^(\\s*)"),fge=new RegExp("^([0-9]+)"),cge=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)"),Uj=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)$"),zj=new RegExp("^(address|bool|bytes([0-9]*)|string|u?int([0-9]*))$");var Pn,Mo,Jg,v7;const a5=class a5{constructor(e){Te(this,Jg);Te(this,Pn,void 0);Te(this,Mo,void 0);fe(this,Pn,0),fe(this,Mo,e.slice())}get offset(){return X(this,Pn)}get length(){return X(this,Mo).length-X(this,Pn)}clone(){return new a5(X(this,Mo))}reset(){fe(this,Pn,0)}popKeyword(e){const r=this.peek();if(r.type!=="KEYWORD"||!e.has(r.text))throw new Error(`expected keyword ${r.text}`);return this.pop().text}popType(e){if(this.peek().type!==e)throw new Error(`expected ${e}; got ${JSON.stringify(this.peek())}`);return this.pop().text}popParen(){const e=this.peek();if(e.type!=="OPEN_PAREN")throw new Error("bad start");const r=Ge(this,Jg,v7).call(this,X(this,Pn)+1,e.match+1);return fe(this,Pn,e.match+1),r}popParams(){const e=this.peek();if(e.type!=="OPEN_PAREN")throw new Error("bad start");const r=[];for(;X(this,Pn)=X(this,Mo).length)throw new Error("out-of-bounds");return X(this,Mo)[X(this,Pn)]}peekKeyword(e){const r=this.peekType("KEYWORD");return r!=null&&e.has(r)?r:null}peekType(e){if(this.length===0)return null;const r=this.peek();return r.type===e?r.text:null}pop(){const e=this.peek();return R1(this,Pn)._++,e}toString(){const e=[];for(let r=X(this,Pn);r`}};Pn=new WeakMap,Mo=new WeakMap,Jg=new WeakSet,v7=function(e=0,r=0){return new a5(X(this,Mo).slice(e,r).map(n=>Object.freeze(Object.assign({},n,{match:n.match-e,linkBack:n.linkBack-e,linkNext:n.linkNext-e}))))};let Zo=a5;function Hc(t){const e=[],r=o=>{const f=i0&&e[e.length-1].type==="NUMBER"){const v=e.pop().text;b=v+b,e[e.length-1].value=Ct(v)}if(e.length===0||e[e.length-1].type!=="BRACKET")throw new Error("missing opening bracket");e[e.length-1].text+=b}continue}if(f=o.match(cge),f){if(h.text=f[1],i+=h.text.length,sge.has(h.text)){h.type="KEYWORD";continue}if(h.text.match(zj)){h.type="TYPE";continue}h.type="ID";continue}if(f=o.match(fge),f){h.text=f[1],h.type="NUMBER",i+=h.text.length;continue}throw new Error(`unexpected token ${JSON.stringify(o[0])} at position ${i}`)}return new Zo(e.map(o=>Object.freeze(o)))}function tR(t,e){let r=[];for(const n in e.keys())t.has(n)&&r.push(n);if(r.length>1)throw new Error(`conflicting types: ${r.join(", ")}`)}function Kx(t,e){if(e.peekKeyword($j)){const r=e.pop().text;if(r!==t)throw new Error(`expected ${t}, got ${r}`)}return e.popType("ID")}function Zf(t,e){const r=new Set;for(;;){const n=t.peekType("KEYWORD");if(n==null||e&&!e.has(n))break;if(t.pop(),r.has(n))throw new Error(`duplicate keywords: ${JSON.stringify(n)}`);r.add(n)}return Object.freeze(r)}function jj(t){let e=Zf(t,tge);return tR(e,ci("constant payable nonpayable".split(" "))),tR(e,ci("pure view payable nonpayable".split(" "))),e.has("view")?"view":e.has("pure")?"pure":e.has("payable")?"payable":e.has("nonpayable")?"nonpayable":e.has("constant")?"view":"nonpayable"}function Of(t,e){return t.popParams().map(r=>On.from(r,e))}function Hj(t){if(t.peekType("AT")){if(t.pop(),t.peekType("NUMBER"))return ft(t.pop().text);throw new Error("invalid gas")}return null}function hl(t){if(t.length)throw new Error(`unexpected tokens: ${t.toString()}`)}const uge=new RegExp(/^(.*)\[([0-9]*)\]$/);function rR(t){const e=t.match(zj);if(me(e,"invalid type","type",t),t==="uint")return"uint256";if(t==="int")return"int256";if(e[2]){const r=parseInt(e[2]);me(r!==0&&r<=32,"invalid bytes length","type",t)}else if(e[3]){const r=parseInt(e[3]);me(r!==0&&r<=256&&r%8===0,"invalid numeric width","type",t)}return t}const Ir={},$i=Symbol.for("_ethers_internal"),nR="_ParamTypeInternal",iR="_ErrorInternal",sR="_EventInternal",oR="_ConstructorInternal",aR="_FallbackInternal",fR="_FunctionInternal",cR="_StructInternal";var Bd,Jv;const ws=class ws{constructor(e,r,n,s,i,o,f,h){Te(this,Bd);Ie(this,"name");Ie(this,"type");Ie(this,"baseType");Ie(this,"indexed");Ie(this,"components");Ie(this,"arrayLength");Ie(this,"arrayChildren");if(Ey(e,Ir,"ParamType"),Object.defineProperty(this,$i,{value:nR}),o&&(o=Object.freeze(o.slice())),s==="array"){if(f==null||h==null)throw new Error("")}else if(f!=null||h!=null)throw new Error("");if(s==="tuple"){if(o==null)throw new Error("")}else if(o!=null)throw new Error("");lt(this,{name:r,type:n,baseType:s,indexed:i,components:o,arrayLength:f,arrayChildren:h})}format(e){if(e==null&&(e="sighash"),e==="json"){const n=this.name||"";if(this.isArray()){const i=JSON.parse(this.arrayChildren.format("json"));return i.name=n,i.type+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`,JSON.stringify(i)}const s={type:this.baseType==="tuple"?"tuple":this.type,name:n};return typeof this.indexed=="boolean"&&(s.indexed=this.indexed),this.isTuple()&&(s.components=this.components.map(i=>JSON.parse(i.format(e)))),JSON.stringify(s)}let r="";return this.isArray()?(r+=this.arrayChildren.format(e),r+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`):this.isTuple()?(e!=="sighash"&&(r+=this.type),r+="("+this.components.map(n=>n.format(e)).join(e==="full"?", ":",")+")"):r+=this.type,e!=="sighash"&&(this.indexed===!0&&(r+=" indexed"),e==="full"&&this.name&&(r+=" "+this.name)),r}isArray(){return this.baseType==="array"}isTuple(){return this.baseType==="tuple"}isIndexable(){return this.indexed!=null}walk(e,r){if(this.isArray()){if(!Array.isArray(e))throw new Error("invalid array value");if(this.arrayLength!==-1&&e.length!==this.arrayLength)throw new Error("array is wrong length");const n=this;return e.map(s=>n.arrayChildren.walk(s,r))}if(this.isTuple()){if(!Array.isArray(e))throw new Error("invalid tuple value");if(e.length!==this.components.length)throw new Error("array is wrong length");const n=this;return e.map((s,i)=>n.components[i].walk(s,r))}return r(this.type,e)}async walkAsync(e,r){const n=[],s=[e];return Ge(this,Bd,Jv).call(this,n,e,r,i=>{s[0]=i}),n.length&&await Promise.all(n),s[0]}static from(e,r){if(ws.isParamType(e))return e;if(typeof e=="string")try{return ws.from(Hc(e),r)}catch{me(!1,"invalid param type","obj",e)}else if(e instanceof Zo){let f="",h="",p=null;Zf(e,ci(["tuple"])).has("tuple")||e.peekType("OPEN_PAREN")?(h="tuple",p=e.popParams().map(P=>ws.from(P)),f=`tuple(${p.map(P=>P.format()).join(",")})`):(f=rR(e.popType("TYPE")),h=f);let b=null,v=null;for(;e.length&&e.peekType("BRACKET");){const P=e.pop();b=new ws(Ir,"",f,h,null,p,v,b),v=P.value,f+=P.text,h="array",p=null}let E=null;if(Zf(e,rge).has("indexed")){if(!r)throw new Error("");E=!0}const S=e.peekType("ID")?e.pop().text:"";if(e.length)throw new Error("leftover tokens");return new ws(Ir,S,f,h,E,p,v,b)}const n=e.name;me(!n||typeof n=="string"&&n.match(Uj),"invalid name","obj.name",n);let s=e.indexed;s!=null&&(me(r,"parameter cannot be indexed","obj.indexed",e.indexed),s=!!s);let i=e.type,o=i.match(uge);if(o){const f=parseInt(o[2]||"-1"),h=ws.from({type:o[1],components:e.components});return new ws(Ir,n||"",i,"array",s,null,f,h)}if(i==="tuple"||i.startsWith("tuple(")||i.startsWith("(")){const f=e.components!=null?e.components.map(p=>ws.from(p)):null;return new ws(Ir,n||"",i,"tuple",s,f,null,null)}return i=rR(e.type),new ws(Ir,n||"",i,i,s,null,null,null)}static isParamType(e){return e&&e[$i]===nR}};Bd=new WeakSet,Jv=function(e,r,n,s){if(this.isArray()){if(!Array.isArray(r))throw new Error("invalid array value");if(this.arrayLength!==-1&&r.length!==this.arrayLength)throw new Error("array is wrong length");const o=this.arrayChildren,f=r.slice();f.forEach((h,p)=>{var b;Ge(b=o,Bd,Jv).call(b,e,h,n,v=>{f[p]=v})}),s(f);return}if(this.isTuple()){const o=this.components;let f;if(Array.isArray(r))f=r.slice();else{if(r==null||typeof r!="object")throw new Error("invalid tuple value");f=o.map(h=>{if(!h.name)throw new Error("cannot use object value with unnamed components");if(!(h.name in r))throw new Error(`missing value for component ${h.name}`);return r[h.name]})}if(f.length!==this.components.length)throw new Error("array is wrong length");f.forEach((h,p)=>{var b;Ge(b=o[p],Bd,Jv).call(b,e,h,n,v=>{f[p]=v})}),s(f);return}const i=n(this.type,r);i.then?e.push(async function(){s(await i)}()):s(i)};let On=ws;class dl{constructor(e,r,n){Ie(this,"type");Ie(this,"inputs");Ey(e,Ir,"Fragment"),n=Object.freeze(n.slice()),lt(this,{type:r,inputs:n})}static from(e){if(typeof e=="string"){try{dl.from(JSON.parse(e))}catch{}return dl.from(Hc(e))}if(e instanceof Zo)switch(e.peekKeyword($j)){case"constructor":return Sf.from(e);case"error":return Ci.from(e);case"event":return Aa.from(e);case"fallback":case"receive":return rf.from(e);case"function":return Ea.from(e);case"struct":return Wu.from(e)}else if(typeof e=="object"){switch(e.type){case"constructor":return Sf.from(e);case"error":return Ci.from(e);case"event":return Aa.from(e);case"fallback":case"receive":return rf.from(e);case"function":return Ea.from(e);case"struct":return Wu.from(e)}He(!1,`unsupported type: ${e.type}`,"UNSUPPORTED_OPERATION",{operation:"Fragment.from"})}me(!1,"unsupported frgament object","obj",e)}static isConstructor(e){return Sf.isFragment(e)}static isError(e){return Ci.isFragment(e)}static isEvent(e){return Aa.isFragment(e)}static isFunction(e){return Ea.isFragment(e)}static isStruct(e){return Wu.isFragment(e)}}class Wx extends dl{constructor(r,n,s,i){super(r,n,i);Ie(this,"name");me(typeof s=="string"&&s.match(Uj),"invalid identifier","name",s),i=Object.freeze(i.slice()),lt(this,{name:s})}}function Cg(t,e){return"("+e.map(r=>r.format(t)).join(t==="full"?", ":",")+")"}class Ci extends Wx{constructor(e,r,n){super(e,"error",r,n),Object.defineProperty(this,$i,{value:iR})}get selector(){return ll(this.format("sighash")).substring(0,10)}format(e){if(e==null&&(e="sighash"),e==="json")return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map(n=>JSON.parse(n.format(e)))});const r=[];return e!=="sighash"&&r.push("error"),r.push(this.name+Cg(e,this.inputs)),r.join(" ")}static from(e){if(Ci.isFragment(e))return e;if(typeof e=="string")return Ci.from(Hc(e));if(e instanceof Zo){const r=Kx("error",e),n=Of(e);return hl(e),new Ci(Ir,r,n)}return new Ci(Ir,e.name,e.inputs?e.inputs.map(On.from):[])}static isFragment(e){return e&&e[$i]===iR}}class Aa extends Wx{constructor(r,n,s,i){super(r,"event",n,s);Ie(this,"anonymous");Object.defineProperty(this,$i,{value:sR}),lt(this,{anonymous:i})}get topicHash(){return ll(this.format("sighash"))}format(r){if(r==null&&(r="sighash"),r==="json")return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map(s=>JSON.parse(s.format(r)))});const n=[];return r!=="sighash"&&n.push("event"),n.push(this.name+Cg(r,this.inputs)),r!=="sighash"&&this.anonymous&&n.push("anonymous"),n.join(" ")}static getTopicHash(r,n){return n=(n||[]).map(i=>On.from(i)),new Aa(Ir,r,n,!1).topicHash}static from(r){if(Aa.isFragment(r))return r;if(typeof r=="string")try{return Aa.from(Hc(r))}catch{me(!1,"invalid event fragment","obj",r)}else if(r instanceof Zo){const n=Kx("event",r),s=Of(r,!0),i=!!Zf(r,ci(["anonymous"])).has("anonymous");return hl(r),new Aa(Ir,n,s,i)}return new Aa(Ir,r.name,r.inputs?r.inputs.map(n=>On.from(n,!0)):[],!!r.anonymous)}static isFragment(r){return r&&r[$i]===sR}}class Sf extends dl{constructor(r,n,s,i,o){super(r,n,s);Ie(this,"payable");Ie(this,"gas");Object.defineProperty(this,$i,{value:oR}),lt(this,{payable:i,gas:o})}format(r){if(He(r!=null&&r!=="sighash","cannot format a constructor for sighash","UNSUPPORTED_OPERATION",{operation:"format(sighash)"}),r==="json")return JSON.stringify({type:"constructor",stateMutability:this.payable?"payable":"undefined",payable:this.payable,gas:this.gas!=null?this.gas:void 0,inputs:this.inputs.map(s=>JSON.parse(s.format(r)))});const n=[`constructor${Cg(r,this.inputs)}`];return n.push(this.payable?"payable":"nonpayable"),this.gas!=null&&n.push(`@${this.gas.toString()}`),n.join(" ")}static from(r){if(Sf.isFragment(r))return r;if(typeof r=="string")try{return Sf.from(Hc(r))}catch{me(!1,"invalid constuctor fragment","obj",r)}else if(r instanceof Zo){Zf(r,ci(["constructor"]));const n=Of(r),s=!!Zf(r,ege).has("payable"),i=Hj(r);return hl(r),new Sf(Ir,"constructor",n,s,i)}return new Sf(Ir,"constructor",r.inputs?r.inputs.map(On.from):[],!!r.payable,r.gas!=null?r.gas:null)}static isFragment(r){return r&&r[$i]===oR}}class rf extends dl{constructor(r,n,s){super(r,"fallback",n);Ie(this,"payable");Object.defineProperty(this,$i,{value:aR}),lt(this,{payable:s})}format(r){const n=this.inputs.length===0?"receive":"fallback";if(r==="json"){const s=this.payable?"payable":"nonpayable";return JSON.stringify({type:n,stateMutability:s})}return`${n}()${this.payable?" payable":""}`}static from(r){if(rf.isFragment(r))return r;if(typeof r=="string")try{return rf.from(Hc(r))}catch{me(!1,"invalid fallback fragment","obj",r)}else if(r instanceof Zo){const n=r.toString(),s=r.peekKeyword(ci(["fallback","receive"]));if(me(s,"type must be fallback or receive","obj",n),r.popKeyword(ci(["fallback","receive"]))==="receive"){const h=Of(r);return me(h.length===0,"receive cannot have arguments","obj.inputs",h),Zf(r,ci(["payable"])),hl(r),new rf(Ir,[],!0)}let o=Of(r);o.length?me(o.length===1&&o[0].type==="bytes","invalid fallback inputs","obj.inputs",o.map(h=>h.format("minimal")).join(", ")):o=[On.from("bytes")];const f=jj(r);if(me(f==="nonpayable"||f==="payable","fallback cannot be constants","obj.stateMutability",f),Zf(r,ci(["returns"])).has("returns")){const h=Of(r);me(h.length===1&&h[0].type==="bytes","invalid fallback outputs","obj.outputs",h.map(p=>p.format("minimal")).join(", "))}return hl(r),new rf(Ir,o,f==="payable")}if(r.type==="receive")return new rf(Ir,[],!0);if(r.type==="fallback"){const n=[On.from("bytes")],s=r.stateMutability==="payable";return new rf(Ir,n,s)}me(!1,"invalid fallback description","obj",r)}static isFragment(r){return r&&r[$i]===aR}}class Ea extends Wx{constructor(r,n,s,i,o,f){super(r,"function",n,i);Ie(this,"constant");Ie(this,"outputs");Ie(this,"stateMutability");Ie(this,"payable");Ie(this,"gas");Object.defineProperty(this,$i,{value:fR}),o=Object.freeze(o.slice()),lt(this,{constant:s==="view"||s==="pure",gas:f,outputs:o,payable:s==="payable",stateMutability:s})}get selector(){return ll(this.format("sighash")).substring(0,10)}format(r){if(r==null&&(r="sighash"),r==="json")return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas!=null?this.gas:void 0,inputs:this.inputs.map(s=>JSON.parse(s.format(r))),outputs:this.outputs.map(s=>JSON.parse(s.format(r)))});const n=[];return r!=="sighash"&&n.push("function"),n.push(this.name+Cg(r,this.inputs)),r!=="sighash"&&(this.stateMutability!=="nonpayable"&&n.push(this.stateMutability),this.outputs&&this.outputs.length&&(n.push("returns"),n.push(Cg(r,this.outputs))),this.gas!=null&&n.push(`@${this.gas.toString()}`)),n.join(" ")}static getSelector(r,n){return n=(n||[]).map(i=>On.from(i)),new Ea(Ir,r,"view",n,[],null).selector}static from(r){if(Ea.isFragment(r))return r;if(typeof r=="string")try{return Ea.from(Hc(r))}catch{me(!1,"invalid function fragment","obj",r)}else if(r instanceof Zo){const s=Kx("function",r),i=Of(r),o=jj(r);let f=[];Zf(r,ci(["returns"])).has("returns")&&(f=Of(r));const h=Hj(r);return hl(r),new Ea(Ir,s,o,i,f,h)}let n=r.stateMutability;return n==null&&(n="payable",typeof r.constant=="boolean"?(n="view",r.constant||(n="payable",typeof r.payable=="boolean"&&!r.payable&&(n="nonpayable"))):typeof r.payable=="boolean"&&!r.payable&&(n="nonpayable")),new Ea(Ir,r.name,n,r.inputs?r.inputs.map(On.from):[],r.outputs?r.outputs.map(On.from):[],r.gas!=null?r.gas:null)}static isFragment(r){return r&&r[$i]===fR}}class Wu extends Wx{constructor(e,r,n){super(e,"struct",r,n),Object.defineProperty(this,$i,{value:cR})}format(){throw new Error("@TODO")}static from(e){if(typeof e=="string")try{return Wu.from(Hc(e))}catch{me(!1,"invalid struct fragment","obj",e)}else if(e instanceof Zo){const r=Kx("struct",e),n=Of(e);return hl(e),new Wu(Ir,r,n)}return new Wu(Ir,e.name,e.inputs?e.inputs.map(On.from):[])}static isFragment(e){return e&&e[$i]===cR}}const sa=new Map;sa.set(0,"GENERIC_PANIC");sa.set(1,"ASSERT_FALSE");sa.set(17,"OVERFLOW");sa.set(18,"DIVIDE_BY_ZERO");sa.set(33,"ENUM_RANGE_ERROR");sa.set(34,"BAD_STORAGE_DATA");sa.set(49,"STACK_UNDERFLOW");sa.set(50,"ARRAY_RANGE_ERROR");sa.set(65,"OUT_OF_MEMORY");sa.set(81,"UNINITIALIZED_FUNCTION_CALL");const lge=new RegExp(/^bytes([0-9]*)$/),hge=new RegExp(/^(u?int)([0-9]*)$/);let D8=null;function dge(t,e,r,n){let s="missing revert data",i=null;const o=null;let f=null;if(r){s="execution reverted";const p=$t(r);if(r=nt(r),p.length===0)s+=" (no data present; likely require(false) occurred",i="require(false)";else if(p.length%32!==4)s+=" (could not decode reason; invalid data length)";else if(nt(p.slice(0,4))==="0x08c379a0")try{i=n.decode(["string"],p.slice(4))[0],f={signature:"Error(string)",name:"Error",args:[i]},s+=`: ${JSON.stringify(i)}`}catch{s+=" (could not decode reason; invalid string data)"}else if(nt(p.slice(0,4))==="0x4e487b71")try{const b=Number(n.decode(["uint256"],p.slice(4))[0]);f={signature:"Panic(uint256)",name:"Panic",args:[b]},i=`Panic due to ${sa.get(b)||"UNKNOWN"}(${b})`,s+=`: ${i}`}catch{s+=" (could not decode panic code)"}else s+=" (unknown custom error)"}const h={to:e.to?Zt(e.to):null,data:e.data||"0x"};return e.from&&(h.from=Zt(e.from)),nn(s,"CALL_EXCEPTION",{action:t,data:r,reason:i,transaction:h,invocation:o,revert:f})}var O0,uh;const f5=class f5{constructor(){Te(this,O0)}getDefaultValue(e){const r=e.map(s=>Ge(this,O0,uh).call(this,On.from(s)));return new Zb(r,"_").defaultValue()}encode(e,r){k$(r.length,e.length,"types/values length mismatch");const n=e.map(o=>Ge(this,O0,uh).call(this,On.from(o))),s=new Zb(n,"_"),i=new U9;return s.encode(i,r),i.data}decode(e,r,n){const s=e.map(o=>Ge(this,O0,uh).call(this,On.from(o)));return new Zb(s,"_").decode(new z9(r,n))}static defaultAbiCoder(){return D8==null&&(D8=new f5),D8}static getBuiltinCallException(e,r,n){return dge(e,r,n,f5.defaultAbiCoder())}};O0=new WeakSet,uh=function(e){if(e.isArray())return new D1e(Ge(this,O0,uh).call(this,e.arrayChildren),e.arrayLength,e.name);if(e.isTuple())return new Zb(e.components.map(n=>Ge(this,O0,uh).call(this,n)),e.name);switch(e.baseType){case"address":return new N1e(e.name);case"bool":return new $1e(e.name);case"string":return new K1e(e.name);case"bytes":return new F1e(e.name);case"":return new j1e(e.name)}let r=e.type.match(hge);if(r){let n=parseInt(r[2]||"256");return me(n!==0&&n<=256&&n%8===0,"invalid "+r[1]+" bit length","param",e),new V1e(n/8,r[1]==="int",e.name)}if(r=e.type.match(lge),r){let n=parseInt(r[1]);return me(n!==0&&n<=32,"invalid bytes length","param",e),new U1e(n,e.name)}me(!1,"invalid type","type",e.type)};let Ig=f5;class pge{constructor(e,r,n){Ie(this,"fragment");Ie(this,"name");Ie(this,"signature");Ie(this,"topic");Ie(this,"args");const s=e.name,i=e.format();lt(this,{fragment:e,name:s,signature:i,topic:r,args:n})}}class mge{constructor(e,r,n,s){Ie(this,"fragment");Ie(this,"name");Ie(this,"args");Ie(this,"signature");Ie(this,"selector");Ie(this,"value");const i=e.name,o=e.format();lt(this,{fragment:e,name:i,args:n,signature:o,selector:r,value:s})}}class gge{constructor(e,r,n){Ie(this,"fragment");Ie(this,"name");Ie(this,"args");Ie(this,"signature");Ie(this,"selector");const s=e.name,i=e.format();lt(this,{fragment:e,name:s,args:n,signature:i,selector:r})}}class uR{constructor(e){Ie(this,"hash");Ie(this,"_isIndexed");lt(this,{hash:e,_isIndexed:!0})}static isIndexed(e){return!!(e&&e._isIndexed)}}const lR={0:"generic panic",1:"assert(false)",17:"arithmetic overflow",18:"division or modulo by zero",33:"enum overflow",34:"invalid encoded storage byte array accessed",49:"out-of-bounds array access; popping on an empty array",50:"out-of-bounds access of an array or bytesN",65:"out of memory",81:"uninitialized function"},hR={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:t=>`reverted with reason string ${JSON.stringify(t)}`},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"],reason:t=>{let e="unknown panic code";return t>=0&&t<=255&&lR[t.toString()]&&(e=lR[t.toString()]),`reverted with panic code 0x${t.toString(16)} (${e})`}}};var da,pa,ma,Gn,Od,Zv,Nd,Qv;const Lh=class Lh{constructor(e){Te(this,Od);Te(this,Nd);Ie(this,"fragments");Ie(this,"deploy");Ie(this,"fallback");Ie(this,"receive");Te(this,da,void 0);Te(this,pa,void 0);Te(this,ma,void 0);Te(this,Gn,void 0);let r=[];typeof e=="string"?r=JSON.parse(e):r=e,fe(this,ma,new Map),fe(this,da,new Map),fe(this,pa,new Map);const n=[];for(const o of r)try{n.push(dl.from(o))}catch(f){console.log("EE",f)}lt(this,{fragments:Object.freeze(n)});let s=null,i=!1;fe(this,Gn,this.getAbiCoder()),this.fragments.forEach((o,f)=>{let h;switch(o.type){case"constructor":if(this.deploy){console.log("duplicate definition - constructor");return}lt(this,{deploy:o});return;case"fallback":o.inputs.length===0?i=!0:(me(!s||o.payable!==s.payable,"conflicting fallback fragments",`fragments[${f}]`,o),s=o,i=s.payable);return;case"function":h=X(this,ma);break;case"event":h=X(this,pa);break;case"error":h=X(this,da);break;default:return}const p=o.format();h.has(p)||h.set(p,o)}),this.deploy||lt(this,{deploy:Sf.from("constructor()")}),lt(this,{fallback:s,receive:i})}format(e){const r=e?"minimal":"full";return this.fragments.map(s=>s.format(r))}formatJson(){const e=this.fragments.map(r=>r.format("json"));return JSON.stringify(e.map(r=>JSON.parse(r)))}getAbiCoder(){return Ig.defaultAbiCoder()}getFunctionName(e){const r=Ge(this,Od,Zv).call(this,e,null,!1);return me(r,"no matching function","key",e),r.name}hasFunction(e){return!!Ge(this,Od,Zv).call(this,e,null,!1)}getFunction(e,r){return Ge(this,Od,Zv).call(this,e,r||null,!0)}forEachFunction(e){const r=Array.from(X(this,ma).keys());r.sort((n,s)=>n.localeCompare(s));for(let n=0;nn.localeCompare(s));for(let n=0;n1){const i=s.map(o=>JSON.stringify(o.format())).join(", ");me(!1,`ambiguous error description (i.e. ${i})`,"name",e)}return s[0]}if(e=Ci.from(e).format(),e==="Error(string)")return Ci.from("error Error(string)");if(e==="Panic(uint256)")return Ci.from("error Panic(uint256)");const n=X(this,da).get(e);return n||null}forEachError(e){const r=Array.from(X(this,da).keys());r.sort((n,s)=>n.localeCompare(s));for(let n=0;ni.type==="string"?ll(o):i.type==="bytes"?kr(nt(o)):(i.type==="bool"&&typeof o=="boolean"?o=o?"0x01":"0x00":i.type.match(/^u?int/)?o=vc(o):i.type.match(/^bytes/)?o=Mse(o,32):i.type==="address"&&X(this,Gn).encode(["address"],[o]),sl(nt(o),32));for(r.forEach((i,o)=>{const f=e.inputs[o];if(!f.indexed){me(i==null,"cannot filter non-indexed parameters; must be null","contract."+f.name,i);return}i==null?n.push(null):f.baseType==="array"||f.baseType==="tuple"?me(!1,"filtering with tuples or arrays not supported","contract."+f.name,i):Array.isArray(i)?n.push(i.map(h=>s(f,h))):n.push(s(f,i))});n.length&&n[n.length-1]===null;)n.pop();return n}encodeEventLog(e,r){if(typeof e=="string"){const o=this.getEvent(e);me(o,"unknown event","eventFragment",e),e=o}const n=[],s=[],i=[];return e.anonymous||n.push(e.topicHash),me(r.length===e.inputs.length,"event arguments/values mismatch","values",r),e.inputs.forEach((o,f)=>{const h=r[f];if(o.indexed)if(o.type==="string")n.push(ll(h));else if(o.type==="bytes")n.push(kr(h));else{if(o.baseType==="tuple"||o.baseType==="array")throw new Error("not implemented");n.push(X(this,Gn).encode([o.type],[h]))}else s.push(o),i.push(h)}),{data:X(this,Gn).encode(s,i),topics:n}}decodeEventLog(e,r,n){if(typeof e=="string"){const _=this.getEvent(e);me(_,"unknown event","eventFragment",e),e=_}if(n!=null&&!e.anonymous){const _=e.topicHash;me(Rr(n[0],32)&&n[0].toLowerCase()===_,"fragment/topic mismatch","topics[0]",n[0]),n=n.slice(1)}const s=[],i=[],o=[];e.inputs.forEach((_,S)=>{_.indexed?_.type==="string"||_.type==="bytes"||_.baseType==="tuple"||_.baseType==="array"?(s.push(On.from({type:"bytes32",name:_.name})),o.push(!0)):(s.push(_),o.push(!1)):(i.push(_),o.push(!1))});const f=n!=null?X(this,Gn).decode(s,tn(n)):null,h=X(this,Gn).decode(i,r,!0),p=[],b=[];let v=0,E=0;return e.inputs.forEach((_,S)=>{let P=null;if(_.indexed)if(f==null)P=new uR(null);else if(o[S])P=new uR(f[E++]);else try{P=f[E++]}catch(I){P=I}else try{P=h[v++]}catch(I){P=I}p.push(P),b.push(_.name||null)}),Y2.fromItems(p,b)}parseTransaction(e){const r=$t(e.data,"tx.data"),n=ft(e.value!=null?e.value:0,"tx.value"),s=this.getFunction(nt(r.slice(0,4)));if(!s)return null;const i=X(this,Gn).decode(s.inputs,r.slice(4));return new mge(s,s.selector,i,n)}parseCallResult(e){throw new Error("@TODO")}parseLog(e){const r=this.getEvent(e.topics[0]);return!r||r.anonymous?null:new pge(r,r.topicHash,this.decodeEventLog(r,e.data,e.topics))}parseError(e){const r=nt(e),n=this.getError(Nr(r,0,4));if(!n)return null;const s=X(this,Gn).decode(n.inputs,Nr(r,4));return new gge(n,n.selector,s)}static from(e){return e instanceof Lh?e:typeof e=="string"?new Lh(JSON.parse(e)):typeof e.format=="function"?new Lh(e.format("json")):new Lh(e)}};da=new WeakMap,pa=new WeakMap,ma=new WeakMap,Gn=new WeakMap,Od=new WeakSet,Zv=function(e,r,n){if(Rr(e)){const i=e.toLowerCase();for(const o of X(this,ma).values())if(i===o.selector)return o;return null}if(e.indexOf("(")===-1){const i=[];for(const[o,f]of X(this,ma))o.split("(")[0]===e&&i.push(f);if(r){const o=r.length>0?r[r.length-1]:null;let f=r.length,h=!0;Xn.isTyped(o)&&o.type==="overrides"&&(h=!1,f--);for(let p=i.length-1;p>=0;p--){const b=i[p].inputs.length;b!==f&&(!h||b!==f-1)&&i.splice(p,1)}for(let p=i.length-1;p>=0;p--){const b=i[p].inputs;for(let v=0;v=b.length){if(r[v].type==="overrides")continue;i.splice(p,1);break}if(r[v].type!==b[v].baseType){i.splice(p,1);break}}}}if(i.length===1&&r&&r.length!==i[0].inputs.length){const o=r[r.length-1];(o==null||Array.isArray(o)||typeof o!="object")&&i.splice(0,1)}if(i.length===0)return null;if(i.length>1&&n){const o=i.map(f=>JSON.stringify(f.format())).join(", ");me(!1,`ambiguous function description (i.e. matches ${o})`,"key",e)}return i[0]}const s=X(this,ma).get(Ea.from(e).format());return s||null},Nd=new WeakSet,Qv=function(e,r,n){if(Rr(e)){const i=e.toLowerCase();for(const o of X(this,pa).values())if(i===o.topicHash)return o;return null}if(e.indexOf("(")===-1){const i=[];for(const[o,f]of X(this,pa))o.split("(")[0]===e&&i.push(f);if(r){for(let o=i.length-1;o>=0;o--)i[o].inputs.length=0;o--){const f=i[o].inputs;for(let h=0;h1&&n){const o=i.map(f=>JSON.stringify(f.format())).join(", ");me(!1,`ambiguous event description (i.e. matches ${o})`,"key",e)}return i[0]}const s=X(this,pa).get(Aa.from(e).format());return s||null};let x7=Lh;const qj=BigInt(0);function Um(t){return t??null}function Qn(t){return t==null?null:t.toString()}class dR{constructor(e,r,n){Ie(this,"gasPrice");Ie(this,"maxFeePerGas");Ie(this,"maxPriorityFeePerGas");lt(this,{gasPrice:Um(e),maxFeePerGas:Um(r),maxPriorityFeePerGas:Um(n)})}toJSON(){const{gasPrice:e,maxFeePerGas:r,maxPriorityFeePerGas:n}=this;return{_type:"FeeData",gasPrice:Qn(e),maxFeePerGas:Qn(r),maxPriorityFeePerGas:Qn(n)}}}function w6(t){const e={};t.to&&(e.to=t.to),t.from&&(e.from=t.from),t.data&&(e.data=nt(t.data));const r="chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);for(const s of r)!(s in t)||t[s]==null||(e[s]=ft(t[s],`request.${s}`));const n="type,nonce".split(/,/);for(const s of n)!(s in t)||t[s]==null||(e[s]=Ct(t[s],`request.${s}`));return t.accessList&&(e.accessList=Bl(t.accessList)),"blockTag"in t&&(e.blockTag=t.blockTag),"enableCcipRead"in t&&(e.enableCcipRead=!!t.enableCcipRead),"customData"in t&&(e.customData=t.customData),e}var df;class yge{constructor(e,r){Ie(this,"provider");Ie(this,"number");Ie(this,"hash");Ie(this,"timestamp");Ie(this,"parentHash");Ie(this,"nonce");Ie(this,"difficulty");Ie(this,"gasLimit");Ie(this,"gasUsed");Ie(this,"miner");Ie(this,"extraData");Ie(this,"baseFeePerGas");Te(this,df,void 0);fe(this,df,e.transactions.map(n=>typeof n!="string"?new Tg(n,r):n)),lt(this,{provider:r,hash:Um(e.hash),number:e.number,timestamp:e.timestamp,parentHash:e.parentHash,nonce:e.nonce,difficulty:e.difficulty,gasLimit:e.gasLimit,gasUsed:e.gasUsed,miner:e.miner,extraData:e.extraData,baseFeePerGas:Um(e.baseFeePerGas)})}get transactions(){return X(this,df).map(e=>typeof e=="string"?e:e.hash)}get prefetchedTransactions(){const e=X(this,df).slice();return e.length===0?[]:(He(typeof e[0]=="object","transactions were not prefetched with block request","UNSUPPORTED_OPERATION",{operation:"transactionResponses()"}),e)}toJSON(){const{baseFeePerGas:e,difficulty:r,extraData:n,gasLimit:s,gasUsed:i,hash:o,miner:f,nonce:h,number:p,parentHash:b,timestamp:v,transactions:E}=this;return{_type:"Block",baseFeePerGas:Qn(e),difficulty:Qn(r),extraData:n,gasLimit:Qn(s),gasUsed:Qn(i),hash:o,miner:f,nonce:h,number:p,parentHash:b,timestamp:v,transactions:E}}[Symbol.iterator](){let e=0;const r=this.transactions;return{next:()=>enew Hy(s,r))));let n=qj;e.effectiveGasPrice!=null?n=e.effectiveGasPrice:e.gasPrice!=null&&(n=e.gasPrice),lt(this,{provider:r,to:e.to,from:e.from,contractAddress:e.contractAddress,hash:e.hash,index:e.index,blockHash:e.blockHash,blockNumber:e.blockNumber,logsBloom:e.logsBloom,gasUsed:e.gasUsed,cumulativeGasUsed:e.cumulativeGasUsed,gasPrice:n,type:e.type,status:e.status,root:e.root})}get logs(){return X(this,Zg)}toJSON(){const{to:e,from:r,contractAddress:n,hash:s,index:i,blockHash:o,blockNumber:f,logsBloom:h,logs:p,status:b,root:v}=this;return{_type:"TransactionReceipt",blockHash:o,blockNumber:f,contractAddress:n,cumulativeGasUsed:Qn(this.cumulativeGasUsed),from:r,gasPrice:Qn(this.gasPrice),gasUsed:Qn(this.gasUsed),hash:s,index:i,logs:p,logsBloom:h,root:v,status:b,to:e}}get length(){return this.logs.length}[Symbol.iterator](){let e=0;return{next:()=>e{if(f)return null;const{blockNumber:E,nonce:_}=await si({blockNumber:this.provider.getBlockNumber(),nonce:this.provider.getTransactionCount(this.from)});if(_{if(E==null||E.status!==0)return E;He(!1,"transaction execution reverted","CALL_EXCEPTION",{action:"sendTransaction",data:null,reason:null,invocation:null,revert:null,transaction:{to:E.to,from:E.from,data:""},receipt:E})},b=await this.provider.getTransactionReceipt(this.hash);if(n===0)return p(b);if(b){if(await b.confirmations()>=n)return p(b)}else if(await h(),n===0)return null;return await new Promise((E,_)=>{const S=[],P=()=>{S.forEach(C=>C())};if(S.push(()=>{f=!0}),s>0){const C=setTimeout(()=>{P(),_(nn("wait for transaction timeout","TIMEOUT"))},s);S.push(()=>{clearTimeout(C)})}const I=async C=>{if(await C.confirmations()>=n){P();try{E(p(C))}catch(T){_(T)}}};if(S.push(()=>{this.provider.off(this.hash,I)}),this.provider.on(this.hash,I),i>=0){const C=async()=>{try{await h()}catch(T){if(Ns(T,"TRANSACTION_REPLACED")){P(),_(T);return}}f||this.provider.once("block",C)};S.push(()=>{this.provider.off("block",C)}),this.provider.once("block",C)}})}isMined(){return this.blockHash!=null}isLegacy(){return this.type===0}isBerlin(){return this.type===1}isLondon(){return this.type===2}removedEvent(){return He(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),Kj(this)}reorderedEvent(e){return He(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),He(!e||e.isMined(),"unmined 'other' transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),Vj(this,e)}replaceableTransaction(e){me(Number.isInteger(e)&&e>=0,"invalid startBlock","startBlock",e);const r=new _P(this,this.provider);return fe(r,N0,e),r}};N0=new WeakMap;let Tg=_P;function bge(t){return{orphan:"drop-block",hash:t.hash,number:t.number}}function Vj(t,e){return{orphan:"reorder-transaction",tx:t,other:e}}function Kj(t){return{orphan:"drop-transaction",tx:t}}function vge(t){return{orphan:"drop-log",log:{transactionHash:t.transactionHash,blockHash:t.blockHash,blockNumber:t.blockNumber,address:t.address,data:t.data,topics:Object.freeze(t.topics.slice()),index:t.index}}}class OS extends Hy{constructor(r,n,s){super(r,r.provider);Ie(this,"interface");Ie(this,"fragment");Ie(this,"args");const i=n.decodeEventLog(s,r.data,r.topics);lt(this,{args:i,fragment:s,interface:n})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}class Wj extends Hy{constructor(r,n){super(r,r.provider);Ie(this,"error");lt(this,{error:n})}}var Ld;class xge extends Gj{constructor(r,n,s){super(s,n);Te(this,Ld,void 0);fe(this,Ld,r)}get logs(){return super.logs.map(r=>{const n=r.topics.length?X(this,Ld).getEvent(r.topics[0]):null;if(n)try{return new OS(r,X(this,Ld),n)}catch(s){return new Wj(r,s)}return r})}}Ld=new WeakMap;var Qg;class NS extends Tg{constructor(r,n,s){super(s,n);Te(this,Qg,void 0);fe(this,Qg,r)}async wait(r){const n=await super.wait(r);return n==null?null:new xge(X(this,Qg),this.provider,n)}}Qg=new WeakMap;class Jj extends N${constructor(r,n,s,i){super(r,n,s);Ie(this,"log");lt(this,{log:i})}async getBlock(){return await this.log.getBlock()}async getTransaction(){return await this.log.getTransaction()}async getTransactionReceipt(){return await this.log.getTransactionReceipt()}}class wge extends Jj{constructor(e,r,n,s,i){super(e,r,n,new OS(i,e.interface,s));const o=e.interface.decodeEventLog(s,this.log.data,this.log.topics);lt(this,{args:o,fragment:s})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}const pR=BigInt(0);function Zj(t){return t&&typeof t.call=="function"}function Qj(t){return t&&typeof t.estimateGas=="function"}function LS(t){return t&&typeof t.resolveName=="function"}function Yj(t){return t&&typeof t.sendTransaction=="function"}var Yg;class Age{constructor(e,r,n){Te(this,Yg,void 0);Ie(this,"fragment");if(lt(this,{fragment:r}),r.inputs.lengthn[h]==null?null:f.walkAsync(n[h],(b,v)=>b==="address"?Array.isArray(v)?Promise.all(v.map(E=>Ri(E,i))):Ri(v,i):v)));return e.interface.encodeFilterTopics(r,o)}())}getTopicFilter(){return X(this,Yg)}}Yg=new WeakMap;function pl(t,e){return t==null?null:typeof t[e]=="function"?t:t.provider&&typeof t.provider[e]=="function"?t.provider:null}function pu(t){return t==null?null:t.provider||null}async function Xj(t,e){const r=Xn.dereference(t,"overrides");me(typeof r=="object","invalid overrides parameter","overrides",t);const n=w6(r);return me(n.to==null||(e||[]).indexOf("to")>=0,"cannot override to","overrides.to",n.to),me(n.data==null||(e||[]).indexOf("data")>=0,"cannot override data","overrides.data",n.data),n.from&&(n.from=await Ri(n.from)),n}async function Ege(t,e,r){const n=pl(t,"resolveName"),s=LS(n)?n:null;return await Promise.all(e.map((i,o)=>i.walkAsync(r[o],(f,h)=>(h=Xn.dereference(h,f),f==="address"?Ri(h,s):h))))}function Mge(t){const e=async function(o){const f=await Xj(o,["data"]);f.to=await t.getAddress();const h=t.interface,p=ft(f.value||pR,"overrides.value")===pR,b=(f.data||"0x")==="0x";h.fallback&&!h.fallback.payable&&h.receive&&!b&&!p&&me(!1,"cannot send data to receive or send value to non-payable fallback","overrides",o),me(h.fallback||b,"cannot send data to receive-only contract","overrides.data",f.data);const v=h.receive||h.fallback&&h.fallback.payable;return me(v||p,"cannot send value to non-payable fallback","overrides.value",f.value),me(h.fallback||b,"cannot send data to receive-only contract","overrides.data",f.data),f},r=async function(o){const f=pl(t.runner,"call");He(Zj(f),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const h=await e(o);try{return await f.call(h)}catch(p){throw SM(p)&&p.data?t.interface.makeError(p.data,h):p}},n=async function(o){const f=t.runner;He(Yj(f),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const h=await f.sendTransaction(await e(o)),p=pu(t.runner);return new NS(t.interface,p,h)},s=async function(o){const f=pl(t.runner,"estimateGas");return He(Qj(f),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await f.estimateGas(await e(o))},i=async o=>await n(o);return lt(i,{_contract:t,estimateGas:s,populateTransaction:e,send:n,staticCall:r}),i}function Sge(t,e){const r=function(...p){const b=t.interface.getFunction(e,p);return He(b,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:e,args:p}}),b},n=async function(...p){const b=r(...p);let v={};if(b.inputs.length+1===p.length&&(v=await Xj(p.pop())),b.inputs.length!==p.length)throw new Error("internal error: fragment inputs doesn't match arguments; should not happen");const E=await Ege(t.runner,b.inputs,p);return Object.assign({},v,await si({to:t.getAddress(),data:t.interface.encodeFunctionData(b,E)}))},s=async function(...p){const b=await f(...p);return b.length===1?b[0]:b},i=async function(...p){const b=t.runner;He(Yj(b),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const v=await b.sendTransaction(await n(...p)),E=pu(t.runner);return new NS(t.interface,E,v)},o=async function(...p){const b=pl(t.runner,"estimateGas");return He(Qj(b),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await b.estimateGas(await n(...p))},f=async function(...p){const b=pl(t.runner,"call");He(Zj(b),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const v=await n(...p);let E="0x";try{E=await b.call(v)}catch(S){throw SM(S)&&S.data?t.interface.makeError(S.data,v):S}const _=r(...p);return t.interface.decodeFunctionResult(_,E)},h=async(...p)=>r(...p).constant?await s(...p):await i(...p);return lt(h,{name:t.interface.getFunctionName(e),_contract:t,_key:e,getFragment:r,estimateGas:o,populateTransaction:n,send:i,staticCall:s,staticCallResult:f}),Object.defineProperty(h,"fragment",{configurable:!1,enumerable:!0,get:()=>{const p=t.interface.getFunction(e);return He(p,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:e}}),p}}),h}function _ge(t,e){const r=function(...s){const i=t.interface.getEvent(e,s);return He(i,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:e,args:s}}),i},n=function(...s){return new Age(t,r(...s),s)};return lt(n,{name:t.interface.getEventName(e),_contract:t,_key:e,getFragment:r}),Object.defineProperty(n,"fragment",{configurable:!1,enumerable:!0,get:()=>{const s=t.interface.getEvent(e);return He(s,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:e}}),s}}),n}const A6=Symbol.for("_ethersInternal_contract"),eH=new WeakMap;function Pge(t,e){eH.set(t[A6],e)}function Hi(t){return eH.get(t[A6])}function Cge(t){return t&&typeof t=="object"&&"getTopicFilter"in t&&typeof t.getTopicFilter=="function"&&t.fragment}async function DS(t,e){let r,n=null;if(Array.isArray(e)){const i=function(o){if(Rr(o,32))return o;const f=t.interface.getEvent(o);return me(f,"unknown fragment","name",o),f.topicHash};r=e.map(o=>o==null?null:Array.isArray(o)?o.map(i):i(o))}else e==="*"?r=[null]:typeof e=="string"?Rr(e,32)?r=[e]:(n=t.interface.getEvent(e),me(n,"unknown fragment","event",e),r=[n.topicHash]):Cge(e)?r=await e.getTopicFilter():"fragment"in e?(n=e.fragment,r=[n.topicHash]):me(!1,"unknown event name","event",e);r=r.map(i=>{if(i==null)return null;if(Array.isArray(i)){const o=Array.from(new Set(i.map(f=>f.toLowerCase())).values());return o.length===1?o[0]:(o.sort(),o)}return i.toLowerCase()});const s=r.map(i=>i==null?"null":Array.isArray(i)?i.join("|"):i).join("&");return{fragment:n,tag:s,topics:r}}async function xm(t,e){const{subs:r}=Hi(t);return r.get((await DS(t,e)).tag)||null}async function mR(t,e,r){const n=pu(t.runner);He(n,"contract runner does not support subscribing","UNSUPPORTED_OPERATION",{operation:e});const{fragment:s,tag:i,topics:o}=await DS(t,r),{addr:f,subs:h}=Hi(t);let p=h.get(i);if(!p){const v={address:f||t,topics:o},E=I=>{let C=s;if(C==null)try{C=t.interface.getEvent(I.topics[0])}catch{}if(C){const T=C,B=s?t.interface.decodeEventLog(s,I.data,I.topics):[];A7(t,r,B,N=>new wge(t,N,r,T,I))}else A7(t,r,[],T=>new Jj(t,T,r,I))};let _=[];p={tag:i,listeners:[],start:()=>{_.length||_.push(n.on(v,E))},stop:async()=>{if(_.length==0)return;let I=_;_=[],await Promise.all(I),n.off(v,E)}},h.set(i,p)}return p}let w7=Promise.resolve();async function Ige(t,e,r,n){await w7;const s=await xm(t,e);if(!s)return!1;const i=s.listeners.length;return s.listeners=s.listeners.filter(({listener:o,once:f})=>{const h=Array.from(r);n&&h.push(n(f?null:o));try{o.call(t,...h)}catch{}return!f}),s.listeners.length===0&&(s.stop(),Hi(t).subs.delete(s.tag)),i>0}async function A7(t,e,r,n){try{await w7}catch{}const s=Ige(t,e,r,n);return w7=s,await s}const Qb=["then"];var zMe;const Gm=class Gm{constructor(e,r,n,s){Ie(this,"target");Ie(this,"interface");Ie(this,"runner");Ie(this,"filters");Ie(this,zMe);Ie(this,"fallback");me(typeof e=="string"||ij(e),"invalid value for Contract target","target",e),n==null&&(n=null);const i=x7.from(r);lt(this,{target:e,runner:n,interface:i}),Object.defineProperty(this,A6,{value:{}});let o,f=null,h=null;if(s){const v=pu(n);h=new NS(this.interface,v,s)}let p=new Map;if(typeof e=="string")if(Rr(e))f=e,o=Promise.resolve(e);else{const v=pl(n,"resolveName");if(!LS(v))throw nn("contract runner does not support name resolution","UNSUPPORTED_OPERATION",{operation:"resolveName"});o=v.resolveName(e).then(E=>{if(E==null)throw nn("an ENS name used for a contract target must be correctly configured","UNCONFIGURED_NAME",{value:e});return Hi(this).addr=E,E})}else o=e.getAddress().then(v=>{if(v==null)throw new Error("TODO");return Hi(this).addr=v,v});Pge(this,{addrPromise:o,addr:f,deployTx:h,subs:p});const b=new Proxy({},{get:(v,E,_)=>{if(typeof E=="symbol"||Qb.indexOf(E)>=0)return Reflect.get(v,E,_);try{return this.getEvent(E)}catch(S){if(!Ns(S,"INVALID_ARGUMENT")||S.argument!=="key")throw S}},has:(v,E)=>Qb.indexOf(E)>=0?Reflect.has(v,E):Reflect.has(v,E)||this.interface.hasEvent(String(E))});return lt(this,{filters:b}),lt(this,{fallback:i.receive||i.fallback?Mge(this):null}),new Proxy(this,{get:(v,E,_)=>{if(typeof E=="symbol"||E in v||Qb.indexOf(E)>=0)return Reflect.get(v,E,_);try{return v.getFunction(E)}catch(S){if(!Ns(S,"INVALID_ARGUMENT")||S.argument!=="key")throw S}},has:(v,E)=>typeof E=="symbol"||E in v||Qb.indexOf(E)>=0?Reflect.has(v,E):v.interface.hasFunction(E)})}connect(e){return new Gm(this.target,this.interface,e)}attach(e){return new Gm(e,this.interface,this.runner)}async getAddress(){return await Hi(this).addrPromise}async getDeployedCode(){const e=pu(this.runner);He(e,"runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"getDeployedCode"});const r=await e.getCode(await this.getAddress());return r==="0x"?null:r}async waitForDeployment(){const e=this.deploymentTransaction();if(e)return await e.wait(),this;if(await this.getDeployedCode()!=null)return this;const n=pu(this.runner);return He(n!=null,"contract runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"waitForDeployment"}),new Promise((s,i)=>{const o=async()=>{try{if(await this.getDeployedCode()!=null)return s(this);n.once("block",o)}catch(f){i(f)}};o()})}deploymentTransaction(){return Hi(this).deployTx}getFunction(e){return typeof e!="string"&&(e=e.format()),Sge(this,e)}getEvent(e){return typeof e!="string"&&(e=e.format()),_ge(this,e)}async queryTransaction(e){throw new Error("@TODO")}async queryFilter(e,r,n){r==null&&(r=0),n==null&&(n="latest");const{addr:s,addrPromise:i}=Hi(this),o=s||await i,{fragment:f,topics:h}=await DS(this,e),p={address:o,topics:h,fromBlock:r,toBlock:n},b=pu(this.runner);return He(b,"contract runner does not have a provider","UNSUPPORTED_OPERATION",{operation:"queryFilter"}),(await b.getLogs(p)).map(v=>{let E=f;if(E==null)try{E=this.interface.getEvent(v.topics[0])}catch{}if(E)try{return new OS(v,this.interface,E)}catch(_){return new Wj(v,_)}return new Hy(v,b)})}async on(e,r){const n=await mR(this,"on",e);return n.listeners.push({listener:r,once:!1}),n.start(),this}async once(e,r){const n=await mR(this,"once",e);return n.listeners.push({listener:r,once:!0}),n.start(),this}async emit(e,...r){return await A7(this,e,r,null)}async listenerCount(e){if(e){const s=await xm(this,e);return s?s.listeners.length:0}const{subs:r}=Hi(this);let n=0;for(const{listeners:s}of r.values())n+=s.length;return n}async listeners(e){if(e){const s=await xm(this,e);return s?s.listeners.map(({listener:i})=>i):[]}const{subs:r}=Hi(this);let n=[];for(const{listeners:s}of r.values())n=n.concat(s.map(({listener:i})=>i));return n}async off(e,r){const n=await xm(this,e);if(!n)return this;if(r){const s=n.listeners.map(({listener:i})=>i).indexOf(r);s>=0&&n.listeners.splice(s,1)}return(r==null||n.listeners.length===0)&&(n.stop(),Hi(this).subs.delete(n.tag)),this}async removeAllListeners(e){if(e){const r=await xm(this,e);if(!r)return this;r.stop(),Hi(this).subs.delete(r.tag)}else{const{subs:r}=Hi(this);for(const{tag:n,stop:s}of r.values())s(),r.delete(n)}return this}async addListener(e,r){return await this.on(e,r)}async removeListener(e,r){return await this.off(e,r)}static buildClass(e){class r extends Gm{constructor(s,i=null){super(s,e,i)}}return r}static from(e,r,n){return n==null&&(n=null),new this(e,r,n)}};zMe=A6;let E7=Gm;function Tge(){return E7}class ss extends Tge(){}function $8(t){return t.match(/^ipfs:\/\/ipfs\//i)?t=t.substring(12):t.match(/^ipfs:\/\//i)?t=t.substring(7):me(!1,"unsupported IPFS format","link",t),`https://gateway.ipfs.io/ipfs/${t}`}class kge{constructor(e){Ie(this,"name");lt(this,{name:e})}connect(e){return this}supportsCoinType(e){return!1}async encodeAddress(e,r){throw new Error("unsupported coin")}async decodeAddress(e,r){throw new Error("unsupported coin")}}const tH=new RegExp("^(ipfs)://(.*)$","i"),gR=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),tH,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];var L0,Pu,D0,lh,c5,rH;const Dh=class Dh{constructor(e,r,n){Te(this,D0);Ie(this,"provider");Ie(this,"address");Ie(this,"name");Te(this,L0,void 0);Te(this,Pu,void 0);lt(this,{provider:e,address:r,name:n}),fe(this,L0,null),fe(this,Pu,new ss(r,["function supportsInterface(bytes4) view returns (bool)","function resolve(bytes, bytes) view returns (bytes)","function addr(bytes32) view returns (address)","function addr(bytes32, uint) view returns (bytes)","function text(bytes32, string) view returns (string)","function contenthash(bytes32) view returns (bytes)"],e))}async supportsWildcard(){return X(this,L0)==null&&fe(this,L0,(async()=>{try{return await X(this,Pu).supportsInterface("0x9061b923")}catch(e){if(Ns(e,"CALL_EXCEPTION"))return!1;throw fe(this,L0,null),e}})()),await X(this,L0)}async getAddress(e){if(e==null&&(e=60),e===60)try{const i=await Ge(this,D0,lh).call(this,"addr(bytes32)");return i==null||i===To?null:i}catch(i){if(Ns(i,"CALL_EXCEPTION"))return null;throw i}if(e>=0&&e<2147483648){let i=e+2147483648;const o=await Ge(this,D0,lh).call(this,"addr(bytes32,uint)",[i]);if(Rr(o,20))return Zt(o)}let r=null;for(const i of this.provider.plugins)if(i instanceof kge&&i.supportsCoinType(e)){r=i;break}if(r==null)return null;const n=await Ge(this,D0,lh).call(this,"addr(bytes32,uint)",[e]);if(n==null||n==="0x")return null;const s=await r.decodeAddress(e,n);if(s!=null)return s;He(!1,"invalid coin data","UNSUPPORTED_OPERATION",{operation:`getAddress(${e})`,info:{coinType:e,data:n}})}async getText(e){const r=await Ge(this,D0,lh).call(this,"text(bytes32,string)",[e]);return r==null||r==="0x"?null:r}async getContentHash(){const e=await Ge(this,D0,lh).call(this,"contenthash(bytes32)");if(e==null||e==="0x")return null;const r=e.match(/^0x(e3010170|e5010172)(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(r){const s=r[1]==="e3010170"?"ipfs":"ipns",i=parseInt(r[4],16);if(r[5].length===i*2)return`${s}://${Pse("0x"+r[2])}`}const n=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(n&&n[1].length===64)return`bzz://${n[1]}`;He(!1,"invalid or unsupported content hash data","UNSUPPORTED_OPERATION",{operation:"getContentHash()",info:{data:e}})}async getAvatar(){return(await this._getAvatar()).url}async _getAvatar(){const e=[{type:"name",value:this.name}];try{const r=await this.getText("avatar");if(r==null)return e.push({type:"!avatar",value:""}),{url:null,linkage:e};e.push({type:"avatar",value:r});for(let n=0;n{if(!Array.isArray(e))throw new Error("not an array");return e.map(r=>t(r))}}function qy(t,e){return r=>{const n={};for(const s in t){let i=s;if(e&&s in e&&!(i in r)){for(const o of e[s])if(o in r){i=o;break}}try{const o=t[s](r[i]);o!==void 0&&(n[s]=o)}catch(o){const f=o instanceof Error?o.message:"not-an-error";He(!1,`invalid value for value.${s} (${f})`,"BAD_DATA",{value:r})}}return n}}function Rge(t){switch(t){case!0:case"true":return!0;case!1:case"false":return!1}me(!1,`invalid boolean; ${JSON.stringify(t)}`,"value",t)}function Pp(t){return me(Rr(t,!0),"invalid data","value",t),t}function Ls(t){return me(Rr(t,32),"invalid hash","value",t),t}const Bge=qy({address:Zt,blockHash:Ls,blockNumber:Ct,data:Pp,index:Ct,removed:Pr(Rge,!1),topics:$S(Ls),transactionHash:Ls,transactionIndex:Ct},{index:["logIndex"]});function Oge(t){return Bge(t)}const Nge=qy({hash:Pr(Ls),parentHash:Ls,number:Ct,timestamp:Ct,nonce:Pr(Pp),difficulty:ft,gasLimit:ft,gasUsed:ft,miner:Pr(Zt),extraData:Pp,baseFeePerGas:Pr(ft)});function Lge(t){const e=Nge(t);return e.transactions=t.transactions.map(r=>typeof r=="string"?r:nH(r)),e}const Dge=qy({transactionIndex:Ct,blockNumber:Ct,transactionHash:Ls,address:Zt,topics:$S(Ls),data:Pp,index:Ct,blockHash:Ls},{index:["logIndex"]});function $ge(t){return Dge(t)}const Fge=qy({to:Pr(Zt,null),from:Pr(Zt,null),contractAddress:Pr(Zt,null),index:Ct,root:Pr(nt),gasUsed:ft,logsBloom:Pr(Pp),blockHash:Ls,hash:Ls,logs:$S($ge),blockNumber:Ct,cumulativeGasUsed:ft,effectiveGasPrice:Pr(ft),status:Pr(Ct),type:Pr(Ct,0)},{effectiveGasPrice:["gasPrice"],hash:["transactionHash"],index:["transactionIndex"]});function Uge(t){return Fge(t)}function nH(t){t.to&&ft(t.to)===yR&&(t.to="0x0000000000000000000000000000000000000000");const e=qy({hash:Ls,type:r=>r==="0x"||r==null?0:Ct(r),accessList:Pr(Bl,null),blockHash:Pr(Ls,null),blockNumber:Pr(Ct,null),transactionIndex:Pr(Ct,null),from:Zt,gasPrice:Pr(ft),maxPriorityFeePerGas:Pr(ft),maxFeePerGas:Pr(ft),gasLimit:ft,to:Pr(Zt,null),value:ft,nonce:Ct,data:Pp,creates:Pr(Zt,null),chainId:Pr(ft,null)},{data:["input"],gasLimit:["gas"]})(t);if(e.to==null&&e.creates==null&&(e.creates=O1e(e)),(t.type===1||t.type===2)&&t.accessList==null&&(e.accessList=[]),t.signature?e.signature=Jf.from(t.signature):e.signature=Jf.from(t),e.chainId==null){const r=e.signature.legacyChainId;r!=null&&(e.chainId=r)}return e.blockHash&&ft(e.blockHash)===yR&&(e.blockHash=null),e}const zge="0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e";class Gy{constructor(e){Ie(this,"name");lt(this,{name:e})}clone(){return new Gy(this.name)}}class Jx extends Gy{constructor(r,n){r==null&&(r=0);super(`org.ethers.network.plugins.GasCost#${r||0}`);Ie(this,"effectiveBlock");Ie(this,"txBase");Ie(this,"txCreate");Ie(this,"txDataZero");Ie(this,"txDataNonzero");Ie(this,"txAccessListStorageKey");Ie(this,"txAccessListAddress");const s={effectiveBlock:r};function i(o,f){let h=(n||{})[o];h==null&&(h=f),me(typeof h=="number",`invalud value for ${o}`,"costs",n),s[o]=h}i("txBase",21e3),i("txCreate",32e3),i("txDataZero",4),i("txDataNonzero",16),i("txAccessListStorageKey",1900),i("txAccessListAddress",2400),lt(this,s)}clone(){return new Jx(this.effectiveBlock,this)}}class Zx extends Gy{constructor(r,n){super("org.ethers.plugins.network.Ens");Ie(this,"address");Ie(this,"targetNetwork");lt(this,{address:r||zge,targetNetwork:n??1})}clone(){return new Zx(this.address,this.targetNetwork)}}var Xg,ey;class iH extends Gy{constructor(r,n){super("org.ethers.plugins.network.FetchUrlFeeDataPlugin");Te(this,Xg,void 0);Te(this,ey,void 0);fe(this,Xg,r),fe(this,ey,n)}get url(){return X(this,Xg)}get processFunc(){return X(this,ey)}clone(){return this}}Xg=new WeakMap,ey=new WeakMap;const F8=new Map;var Dd,$d,$0;const $h=class $h{constructor(e,r){Te(this,Dd,void 0);Te(this,$d,void 0);Te(this,$0,void 0);fe(this,Dd,e),fe(this,$d,ft(r)),fe(this,$0,new Map)}toJSON(){return{name:this.name,chainId:String(this.chainId)}}get name(){return X(this,Dd)}set name(e){fe(this,Dd,e)}get chainId(){return X(this,$d)}set chainId(e){fe(this,$d,ft(e,"chainId"))}matches(e){if(e==null)return!1;if(typeof e=="string"){try{return this.chainId===ft(e)}catch{}return this.name===e}if(typeof e=="number"||typeof e=="bigint"){try{return this.chainId===ft(e)}catch{}return!1}if(typeof e=="object"){if(e.chainId!=null){try{return this.chainId===ft(e.chainId)}catch{}return!1}return e.name!=null?this.name===e.name:!1}return!1}get plugins(){return Array.from(X(this,$0).values())}attachPlugin(e){if(X(this,$0).get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return X(this,$0).set(e.name,e.clone()),this}getPlugin(e){return X(this,$0).get(e)||null}getPlugins(e){return this.plugins.filter(r=>r.name.split("#")[0]===e)}clone(){const e=new $h(this.name,this.chainId);return this.plugins.forEach(r=>{e.attachPlugin(r.clone())}),e}computeIntrinsicGas(e){const r=this.getPlugin("org.ethers.plugins.network.GasCost")||new Jx;let n=r.txBase;if(e.to==null&&(n+=r.txCreate),e.data)for(let s=2;s9){let s=BigInt(n[1].substring(0,9));n[1].substring(9).match(/^0+$/)||s++,n[1]=s.toString()}return BigInt(n[0]+n[1])}function vR(t){return new iH(t,async(e,r,n)=>{n.setHeader("User-Agent","ethers");let s;try{const[i,o]=await Promise.all([n.send(),e()]);s=i;const f=s.bodyJson.standard;return{gasPrice:o.gasPrice,maxFeePerGas:bR(f.maxFee,9),maxPriorityFeePerGas:bR(f.maxPriorityFee,9)}}catch(i){He(!1,`error encountered with polygon gas station (${JSON.stringify(n.url)})`,"SERVER_ERROR",{request:n,response:s,error:i})}})}function jge(t){return new iH("data:",async(e,r,n)=>{const s=await e();if(s.maxFeePerGas==null||s.maxPriorityFeePerGas==null)return s;const i=s.maxFeePerGas-s.maxPriorityFeePerGas;return{gasPrice:s.gasPrice,maxFeePerGas:i+t,maxPriorityFeePerGas:t}})}let xR=!1;function Hge(){if(xR)return;xR=!0;function t(e,r,n){const s=function(){const i=new _f(e,r);return n.ensNetwork!=null&&i.attachPlugin(new Zx(null,n.ensNetwork)),i.attachPlugin(new Jx),(n.plugins||[]).forEach(o=>{i.attachPlugin(o)}),i};_f.register(e,s),_f.register(r,s),n.altNames&&n.altNames.forEach(i=>{_f.register(i,s)})}t("mainnet",1,{ensNetwork:1,altNames:["homestead"]}),t("ropsten",3,{ensNetwork:3}),t("rinkeby",4,{ensNetwork:4}),t("goerli",5,{ensNetwork:5}),t("kovan",42,{ensNetwork:42}),t("sepolia",11155111,{}),t("classic",61,{}),t("classicKotti",6,{}),t("arbitrum",42161,{ensNetwork:1}),t("arbitrum-goerli",421613,{}),t("bnb",56,{ensNetwork:1}),t("bnbt",97,{}),t("linea",59144,{ensNetwork:1}),t("linea-goerli",59140,{}),t("matic",137,{ensNetwork:1,plugins:[vR("https://gasstation.polygon.technology/v2")]}),t("matic-mumbai",80001,{altNames:["maticMumbai","maticmum"],plugins:[vR("https://gasstation-testnet.polygon.technology/v2")]}),t("optimism",10,{ensNetwork:1,plugins:[jge(BigInt("1000000"))]}),t("optimism-goerli",420,{}),t("xdai",100,{ensNetwork:1})}function M7(t){return JSON.parse(JSON.stringify(t))}var pf,Ms,F0,ga,Fd,Yv;class qge{constructor(e){Te(this,Fd);Te(this,pf,void 0);Te(this,Ms,void 0);Te(this,F0,void 0);Te(this,ga,void 0);fe(this,pf,e),fe(this,Ms,null),fe(this,F0,4e3),fe(this,ga,-2)}get pollingInterval(){return X(this,F0)}set pollingInterval(e){fe(this,F0,e)}start(){X(this,Ms)||(fe(this,Ms,X(this,pf)._setTimeout(Ge(this,Fd,Yv).bind(this),X(this,F0))),Ge(this,Fd,Yv).call(this))}stop(){X(this,Ms)&&(X(this,pf)._clearTimeout(X(this,Ms)),fe(this,Ms,null))}pause(e){this.stop(),e&&fe(this,ga,-2)}resume(){this.start()}}pf=new WeakMap,Ms=new WeakMap,F0=new WeakMap,ga=new WeakMap,Fd=new WeakSet,Yv=async function(){try{const e=await X(this,pf).getBlockNumber();if(X(this,ga)===-2){fe(this,ga,e);return}if(e!==X(this,ga)){for(let r=X(this,ga)+1;r<=e;r++){if(X(this,Ms)==null)return;await X(this,pf).emit("block",r)}fe(this,ga,e)}}catch{}X(this,Ms)!=null&&fe(this,Ms,X(this,pf)._setTimeout(Ge(this,Fd,Yv).bind(this),X(this,F0)))};var Cu,Iu,U0;class sH{constructor(e){Te(this,Cu,void 0);Te(this,Iu,void 0);Te(this,U0,void 0);fe(this,Cu,e),fe(this,U0,!1),fe(this,Iu,r=>{this._poll(r,X(this,Cu))})}async _poll(e,r){throw new Error("sub-classes must override this")}start(){X(this,U0)||(fe(this,U0,!0),X(this,Iu).call(this,-2),X(this,Cu).on("block",X(this,Iu)))}stop(){X(this,U0)&&(fe(this,U0,!1),X(this,Cu).off("block",X(this,Iu)))}pause(e){this.stop()}resume(){this.start()}}Cu=new WeakMap,Iu=new WeakMap,U0=new WeakMap;var u5;class Gge extends sH{constructor(r,n){super(r);Te(this,u5,void 0);fe(this,u5,M7(n))}async _poll(r,n){throw new Error("@TODO")}}u5=new WeakMap;var Ud;class Vge extends sH{constructor(r,n){super(r);Te(this,Ud,void 0);fe(this,Ud,n)}async _poll(r,n){const s=await n.getTransactionReceipt(X(this,Ud));s&&n.emit(X(this,Ud),s)}}Ud=new WeakMap;var mf,zd,jd,z0,Ss,l5,oH;class FS{constructor(e,r){Te(this,l5);Te(this,mf,void 0);Te(this,zd,void 0);Te(this,jd,void 0);Te(this,z0,void 0);Te(this,Ss,void 0);fe(this,mf,e),fe(this,zd,M7(r)),fe(this,jd,Ge(this,l5,oH).bind(this)),fe(this,z0,!1),fe(this,Ss,-2)}start(){X(this,z0)||(fe(this,z0,!0),X(this,Ss)===-2&&X(this,mf).getBlockNumber().then(e=>{fe(this,Ss,e)}),X(this,mf).on("block",X(this,jd)))}stop(){X(this,z0)&&(fe(this,z0,!1),X(this,mf).off("block",X(this,jd)))}pause(e){this.stop(),e&&fe(this,Ss,-2)}resume(){this.start()}}mf=new WeakMap,zd=new WeakMap,jd=new WeakMap,z0=new WeakMap,Ss=new WeakMap,l5=new WeakSet,oH=async function(e){if(X(this,Ss)===-2)return;const r=M7(X(this,zd));r.fromBlock=X(this,Ss)+1,r.toBlock=e;const n=await X(this,mf).getLogs(r);if(n.length===0){X(this,Ss){if(n==null)return"null";if(typeof n=="bigint")return`bigint:${n.toString()}`;if(typeof n=="string")return n.toLowerCase();if(typeof n=="object"&&!Array.isArray(n)){const s=Object.keys(n);return s.sort(),s.reduce((i,o)=>(i[o]=n[o],i),{})}return n})}class aH{constructor(e){Ie(this,"name");lt(this,{name:e})}start(){}stop(){}pause(e){}resume(){}}function Jge(t){return JSON.parse(JSON.stringify(t))}function S7(t){return t=Array.from(new Set(t).values()),t.sort(),t}async function U8(t,e){if(t==null)throw new Error("invalid event");if(Array.isArray(t)&&(t={topics:t}),typeof t=="string")switch(t){case"block":case"pending":case"debug":case"error":case"network":return{type:t,tag:t}}if(Rr(t,32)){const r=t.toLowerCase();return{type:"transaction",tag:Xv("tx",{hash:r}),hash:r}}if(t.orphan){const r=t;return{type:"orphan",tag:Xv("orphan",r),filter:Jge(r)}}if(t.address||t.topics){const r=t,n={topics:(r.topics||[]).map(s=>s==null?null:Array.isArray(s)?S7(s.map(i=>i.toLowerCase())):s.toLowerCase())};if(r.address){const s=[],i=[],o=f=>{Rr(f)?s.push(f):i.push((async()=>{s.push(await Ri(f,e))})())};Array.isArray(r.address)?r.address.forEach(o):o(r.address),i.length&&await Promise.all(i),n.address=S7(s.map(f=>f.toLowerCase()))}return{filter:n,tag:Xv("event",n),type:"event"}}me(!1,"unknown ProviderEvent","event",t)}function z8(){return new Date().getTime()}const Zge={cacheTimeout:250,pollingInterval:4e3};var Vn,j0,Kn,Hd,Ki,Tu,H0,gf,ty,_s,qd,Gd,Ai,xs,ry,_7,ny,P7,ku,wm,iy,C7,Ru,Am,Vd,e2;class Qge{constructor(e,r){Te(this,Ai);Te(this,ry);Te(this,ny);Te(this,ku);Te(this,iy);Te(this,Ru);Te(this,Vd);Te(this,Vn,void 0);Te(this,j0,void 0);Te(this,Kn,void 0);Te(this,Hd,void 0);Te(this,Ki,void 0);Te(this,Tu,void 0);Te(this,H0,void 0);Te(this,gf,void 0);Te(this,ty,void 0);Te(this,_s,void 0);Te(this,qd,void 0);Te(this,Gd,void 0);if(fe(this,Gd,Object.assign({},Zge,r||{})),e==="any")fe(this,Tu,!0),fe(this,Ki,null);else if(e){const n=_f.from(e);fe(this,Tu,!1),fe(this,Ki,Promise.resolve(n)),setTimeout(()=>{this.emit("network",n,null)},0)}else fe(this,Tu,!1),fe(this,Ki,null);fe(this,gf,-1),fe(this,H0,new Map),fe(this,Vn,new Map),fe(this,j0,new Map),fe(this,Kn,null),fe(this,Hd,!1),fe(this,ty,1),fe(this,_s,new Map),fe(this,qd,!1)}get pollingInterval(){return X(this,Gd).pollingInterval}get provider(){return this}get plugins(){return Array.from(X(this,j0).values())}attachPlugin(e){if(X(this,j0).get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return X(this,j0).set(e.name,e.connect(this)),this}getPlugin(e){return X(this,j0).get(e)||null}get disableCcipRead(){return X(this,qd)}set disableCcipRead(e){fe(this,qd,!!e)}async ccipReadFetch(e,r,n){if(this.disableCcipRead||n.length===0||e.to==null)return null;const s=e.to.toLowerCase(),i=r.toLowerCase(),o=[];for(let f=0;f=500,`response not found during CCIP fetch: ${v}`,"OFFCHAIN_FAULT",{reason:"404_MISSING_RESOURCE",transaction:e,info:{url:h,errorMessage:v}}),o.push(v)}He(!1,`error encountered during CCIP fetch: ${o.map(f=>JSON.stringify(f)).join(", ")}`,"OFFCHAIN_FAULT",{reason:"500_SERVER_ERROR",transaction:e,info:{urls:n,errorMessages:o}})}_wrapBlock(e,r){return new yge(Lge(e),this)}_wrapLog(e,r){return new Hy(Oge(e),this)}_wrapTransactionReceipt(e,r){return new Gj(Uge(e),this)}_wrapTransactionResponse(e,r){return new Tg(nH(e),this)}_detectNetwork(){He(!1,"sub-classes must implement this","UNSUPPORTED_OPERATION",{operation:"_detectNetwork"})}async _perform(e){He(!1,`unsupported method: ${e.method}`,"UNSUPPORTED_OPERATION",{operation:e.method,info:e})}async getBlockNumber(){const e=Ct(await Ge(this,Ai,xs).call(this,{method:"getBlockNumber"}),"%response");return X(this,gf)>=0&&fe(this,gf,e),e}_getAddress(e){return Ri(e,this)}_getBlockTag(e){if(e==null)return"latest";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(Rr(e))return Rr(e,32)?e:Th(e);if(typeof e=="bigint"&&(e=Ct(e,"blockTag")),typeof e=="number")return e>=0?Th(e):X(this,gf)>=0?Th(X(this,gf)+e):this.getBlockNumber().then(r=>Th(r+e));me(!1,"invalid blockTag","blockTag",e)}_getFilter(e){const r=(e.topics||[]).map(h=>h==null?null:Array.isArray(h)?S7(h.map(p=>p.toLowerCase())):h.toLowerCase()),n="blockHash"in e?e.blockHash:void 0,s=(h,p,b)=>{let v;switch(h.length){case 0:break;case 1:v=h[0];break;default:h.sort(),v=h}if(n&&(p!=null||b!=null))throw new Error("invalid filter");const E={};return v&&(E.address=v),r.length&&(E.topics=r),p&&(E.fromBlock=p),b&&(E.toBlock=b),n&&(E.blockHash=n),E};let i=[];if(e.address)if(Array.isArray(e.address))for(const h of e.address)i.push(this._getAddress(h));else i.push(this._getAddress(e.address));let o;"fromBlock"in e&&(o=this._getBlockTag(e.fromBlock));let f;return"toBlock"in e&&(f=this._getBlockTag(e.toBlock)),i.filter(h=>typeof h!="string").length||o!=null&&typeof o!="string"||f!=null&&typeof f!="string"?Promise.all([Promise.all(i),o,f]).then(h=>s(h[0],h[1],h[2])):s(i,o,f)}_getTransactionRequest(e){const r=w6(e),n=[];if(["to","from"].forEach(s=>{if(r[s]==null)return;const i=Ri(r[s]);Yb(i)?n.push(async function(){r[s]=await i}()):r[s]=i}),r.blockTag!=null){const s=this._getBlockTag(r.blockTag);Yb(s)?n.push(async function(){r.blockTag=await s}()):r.blockTag=s}return n.length?async function(){return await Promise.all(n),r}():r}async getNetwork(){if(X(this,Ki)==null){const s=this._detectNetwork().then(i=>(this.emit("network",i,null),i),i=>{throw X(this,Ki)===s&&fe(this,Ki,null),i});return fe(this,Ki,s),(await s).clone()}const e=X(this,Ki),[r,n]=await Promise.all([e,this._detectNetwork()]);return r.chainId!==n.chainId&&(X(this,Tu)?(this.emit("network",n,r),X(this,Ki)===e&&fe(this,Ki,Promise.resolve(n))):He(!1,`network changed: ${r.chainId} => ${n.chainId} `,"NETWORK_ERROR",{event:"changed"})),r.clone()}async getFeeData(){const e=await this.getNetwork(),r=async()=>{const{_block:s,gasPrice:i}=await si({_block:Ge(this,iy,C7).call(this,"latest",!1),gasPrice:(async()=>{try{const p=await Ge(this,Ai,xs).call(this,{method:"getGasPrice"});return ft(p,"%response")}catch{}return null})()});let o=null,f=null;const h=this._wrapBlock(s,e);return h&&h.baseFeePerGas&&(f=BigInt("1000000000"),o=h.baseFeePerGas*Kge+f),new dR(i,o,f)},n=e.getPlugin("org.ethers.plugins.network.FetchUrlFeeDataPlugin");if(n){const s=new qf(n.url),i=await n.processFunc(r,this,s);return new dR(i.gasPrice,i.maxFeePerGas,i.maxPriorityFeePerGas)}return await r()}async estimateGas(e){let r=this._getTransactionRequest(e);return Yb(r)&&(r=await r),ft(await Ge(this,Ai,xs).call(this,{method:"estimateGas",transaction:r}),"%response")}async call(e){const{tx:r,blockTag:n}=await si({tx:this._getTransactionRequest(e),blockTag:this._getBlockTag(e.blockTag)});return await Ge(this,ny,P7).call(this,Ge(this,ry,_7).call(this,r,n,e.enableCcipRead?0:-1))}async getBalance(e,r){return ft(await Ge(this,ku,wm).call(this,{method:"getBalance"},e,r),"%response")}async getTransactionCount(e,r){return Ct(await Ge(this,ku,wm).call(this,{method:"getTransactionCount"},e,r),"%response")}async getCode(e,r){return nt(await Ge(this,ku,wm).call(this,{method:"getCode"},e,r))}async getStorage(e,r,n){const s=ft(r,"position");return nt(await Ge(this,ku,wm).call(this,{method:"getStorage",position:s},e,n))}async broadcastTransaction(e){const{blockNumber:r,hash:n,network:s}=await si({blockNumber:this.getBlockNumber(),hash:this._perform({method:"broadcastTransaction",signedTransaction:e}),network:this.getNetwork()}),i=x6.from(e);if(i.hash!==n)throw new Error("@TODO: the returned hash did not match");return this._wrapTransactionResponse(i,s).replaceableTransaction(r)}async getBlock(e,r){const{network:n,params:s}=await si({network:this.getNetwork(),params:Ge(this,iy,C7).call(this,e,!!r)});return s==null?null:this._wrapBlock(s,n)}async getTransaction(e){const{network:r,params:n}=await si({network:this.getNetwork(),params:Ge(this,Ai,xs).call(this,{method:"getTransaction",hash:e})});return n==null?null:this._wrapTransactionResponse(n,r)}async getTransactionReceipt(e){const{network:r,params:n}=await si({network:this.getNetwork(),params:Ge(this,Ai,xs).call(this,{method:"getTransactionReceipt",hash:e})});if(n==null)return null;if(n.gasPrice==null&&n.effectiveGasPrice==null){const s=await Ge(this,Ai,xs).call(this,{method:"getTransaction",hash:e});if(s==null)throw new Error("report this; could not find tx or effectiveGasPrice");n.effectiveGasPrice=s.gasPrice}return this._wrapTransactionReceipt(n,r)}async getTransactionResult(e){const{result:r}=await si({network:this.getNetwork(),result:Ge(this,Ai,xs).call(this,{method:"getTransactionResult",hash:e})});return r==null?null:nt(r)}async getLogs(e){let r=this._getFilter(e);Yb(r)&&(r=await r);const{network:n,params:s}=await si({network:this.getNetwork(),params:Ge(this,Ai,xs).call(this,{method:"getLogs",filter:r})});return s.map(i=>this._wrapLog(i,n))}_getProvider(e){He(!1,"provider cannot connect to target network","UNSUPPORTED_OPERATION",{operation:"_getProvider()"})}async getResolver(e){return await E6.fromName(this,e)}async getAvatar(e){const r=await this.getResolver(e);return r?await r.getAvatar():null}async resolveName(e){const r=await this.getResolver(e);return r?await r.getAddress():null}async lookupAddress(e){e=Zt(e);const r=b7(e.substring(2).toLowerCase()+".addr.reverse");try{const n=await E6.getEnsAddress(this),i=await new ss(n,["function resolver(bytes32) view returns (address)"],this).resolver(r);if(i==null||i===To)return null;const f=await new ss(i,["function name(bytes32) view returns (string)"],this).name(r);return await this.resolveName(f)!==e?null:f}catch(n){if(Ns(n,"BAD_DATA")&&n.value==="0x"||Ns(n,"CALL_EXCEPTION"))return null;throw n}return null}async waitForTransaction(e,r,n){const s=r??1;return s===0?this.getTransactionReceipt(e):new Promise(async(i,o)=>{let f=null;const h=async p=>{try{const b=await this.getTransactionReceipt(e);if(b!=null&&p-b.blockNumber+1>=s){i(b),f&&(clearTimeout(f),f=null);return}}catch(b){console.log("EEE",b)}this.once("block",h)};n!=null&&(f=setTimeout(()=>{f!=null&&(f=null,this.off("block",h),o(nn("timeout","TIMEOUT",{reason:"timeout"})))},n)),h(await this.getBlockNumber())})}async waitForBlock(e){He(!1,"not implemented yet","NOT_IMPLEMENTED",{operation:"waitForBlock"})}_clearTimeout(e){const r=X(this,_s).get(e);r&&(r.timer&&clearTimeout(r.timer),X(this,_s).delete(e))}_setTimeout(e,r){r==null&&(r=0);const n=R1(this,ty)._++,s=()=>{X(this,_s).delete(n),e()};if(this.paused)X(this,_s).set(n,{timer:null,func:s,time:r});else{const i=setTimeout(s,r);X(this,_s).set(n,{timer:i,func:s,time:z8()})}return n}_forEachSubscriber(e){for(const r of X(this,Vn).values())e(r.subscriber)}_getSubscriber(e){switch(e.type){case"debug":case"error":case"network":return new aH(e.type);case"block":{const r=new qge(this);return r.pollingInterval=this.pollingInterval,r}case"event":return new FS(this,e.filter);case"transaction":return new Vge(this,e.hash);case"orphan":return new Gge(this,e.filter)}throw new Error(`unsupported event: ${e.type}`)}_recoverSubscriber(e,r){for(const n of X(this,Vn).values())if(n.subscriber===e){n.started&&n.subscriber.stop(),n.subscriber=r,n.started&&r.start(),X(this,Kn)!=null&&r.pause(X(this,Kn));break}}async on(e,r){const n=await Ge(this,Vd,e2).call(this,e);return n.listeners.push({listener:r,once:!1}),n.started||(n.subscriber.start(),n.started=!0,X(this,Kn)!=null&&n.subscriber.pause(X(this,Kn))),this}async once(e,r){const n=await Ge(this,Vd,e2).call(this,e);return n.listeners.push({listener:r,once:!0}),n.started||(n.subscriber.start(),n.started=!0,X(this,Kn)!=null&&n.subscriber.pause(X(this,Kn))),this}async emit(e,...r){const n=await Ge(this,Ru,Am).call(this,e,r);if(!n||n.listeners.length===0)return!1;const s=n.listeners.length;return n.listeners=n.listeners.filter(({listener:i,once:o})=>{const f=new N$(this,o?null:i,e);try{i.call(this,...r,f)}catch{}return!o}),n.listeners.length===0&&(n.started&&n.subscriber.stop(),X(this,Vn).delete(n.tag)),s>0}async listenerCount(e){if(e){const n=await Ge(this,Ru,Am).call(this,e);return n?n.listeners.length:0}let r=0;for(const{listeners:n}of X(this,Vn).values())r+=n.length;return r}async listeners(e){if(e){const n=await Ge(this,Ru,Am).call(this,e);return n?n.listeners.map(({listener:s})=>s):[]}let r=[];for(const{listeners:n}of X(this,Vn).values())r=r.concat(n.map(({listener:s})=>s));return r}async off(e,r){const n=await Ge(this,Ru,Am).call(this,e);if(!n)return this;if(r){const s=n.listeners.map(({listener:i})=>i).indexOf(r);s>=0&&n.listeners.splice(s,1)}return(!r||n.listeners.length===0)&&(n.started&&n.subscriber.stop(),X(this,Vn).delete(n.tag)),this}async removeAllListeners(e){if(e){const{tag:r,started:n,subscriber:s}=await Ge(this,Vd,e2).call(this,e);n&&s.stop(),X(this,Vn).delete(r)}else for(const[r,{started:n,subscriber:s}]of X(this,Vn))n&&s.stop(),X(this,Vn).delete(r);return this}async addListener(e,r){return await this.on(e,r)}async removeListener(e,r){return this.off(e,r)}get destroyed(){return X(this,Hd)}destroy(){this.removeAllListeners();for(const e of X(this,_s).keys())this._clearTimeout(e);fe(this,Hd,!0)}get paused(){return X(this,Kn)!=null}set paused(e){!!e!==this.paused&&(this.paused?this.resume():this.pause(!1))}pause(e){if(fe(this,gf,-1),X(this,Kn)!=null){if(X(this,Kn)==!!e)return;He(!1,"cannot change pause type; resume first","UNSUPPORTED_OPERATION",{operation:"pause"})}this._forEachSubscriber(r=>r.pause(e)),fe(this,Kn,!!e);for(const r of X(this,_s).values())r.timer&&clearTimeout(r.timer),r.time=z8()-r.time}resume(){if(X(this,Kn)!=null){this._forEachSubscriber(e=>e.resume()),fe(this,Kn,null);for(const e of X(this,_s).values()){let r=e.time;r<0&&(r=0),e.time=z8(),setTimeout(e.func,r)}}}}Vn=new WeakMap,j0=new WeakMap,Kn=new WeakMap,Hd=new WeakMap,Ki=new WeakMap,Tu=new WeakMap,H0=new WeakMap,gf=new WeakMap,ty=new WeakMap,_s=new WeakMap,qd=new WeakMap,Gd=new WeakMap,Ai=new WeakSet,xs=async function(e){const r=X(this,Gd).cacheTimeout;if(r<0)return await this._perform(e);const n=Xv(e.method,e);let s=X(this,H0).get(n);return s||(s=this._perform(e),X(this,H0).set(n,s),setTimeout(()=>{X(this,H0).get(n)===s&&X(this,H0).delete(n)},r)),await s},ry=new WeakSet,_7=async function(e,r,n){He(n=0&&r==="latest"&&s.to!=null&&Nr(i.data,0,4)==="0x556f1830"){const o=i.data,f=await Ri(s.to,this);let h;try{h=rye(Nr(i.data,4))}catch(v){He(!1,v.message,"OFFCHAIN_FAULT",{reason:"BAD_DATA",transaction:s,info:{data:o}})}He(h.sender.toLowerCase()===f.toLowerCase(),"CCIP Read sender mismatch","CALL_EXCEPTION",{action:"call",data:o,reason:"OffchainLookup",transaction:s,invocation:null,revert:{signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",name:"OffchainLookup",args:h.errorArgs}});const p=await this.ccipReadFetch(s,h.calldata,h.urls);He(p!=null,"CCIP Read failed to fetch data","OFFCHAIN_FAULT",{reason:"FETCH_FAILED",transaction:s,info:{data:i.data,errorArgs:h.errorArgs}});const b={to:f,data:tn([h.selector,tye([p,h.extraData])])};this.emit("debug",{action:"sendCcipReadCall",transaction:b});try{const v=await Ge(this,ry,_7).call(this,b,r,n+1);return this.emit("debug",{action:"receiveCcipReadCallResult",transaction:Object.assign({},b),result:v}),v}catch(v){throw this.emit("debug",{action:"receiveCcipReadCallError",transaction:Object.assign({},b),error:v}),v}}throw i}},ny=new WeakSet,P7=async function(e){const{value:r}=await si({network:this.getNetwork(),value:e});return r},ku=new WeakSet,wm=async function(e,r,n){let s=this._getAddress(r),i=this._getBlockTag(n);return(typeof s!="string"||typeof i!="string")&&([s,i]=await Promise.all([s,i])),await Ge(this,ny,P7).call(this,Ge(this,Ai,xs).call(this,Object.assign(e,{address:s,blockTag:i})))},iy=new WeakSet,C7=async function(e,r){if(Rr(e,32))return await Ge(this,Ai,xs).call(this,{method:"getBlock",blockHash:e,includeTransactions:r});let n=this._getBlockTag(e);return typeof n!="string"&&(n=await n),await Ge(this,Ai,xs).call(this,{method:"getBlock",blockTag:n,includeTransactions:r})},Ru=new WeakSet,Am=async function(e,r){let n=await U8(e,this);return n.type==="event"&&r&&r.length>0&&r[0].removed===!0&&(n=await U8({orphan:"drop-log",log:r[0]},this)),X(this,Vn).get(n.tag)||null},Vd=new WeakSet,e2=async function(e){const r=await U8(e,this),n=r.tag;let s=X(this,Vn).get(n);return s||(s={subscriber:this._getSubscriber(r),tag:n,addressableMap:new WeakMap,nameMap:new Map,started:!1,listeners:[]},X(this,Vn).set(n,s)),s};function Yge(t,e){try{const r=I7(t,e);if(r)return _M(r)}catch{}return null}function I7(t,e){if(t==="0x")return null;try{const r=Ct(Nr(t,e,e+32)),n=Ct(Nr(t,r,r+32));return Nr(t,r+32,r+32+n)}catch{}return null}function wR(t){const e=rs(t);if(e.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(e,32-e.length),r}function Xge(t){if(t.length%32===0)return t;const e=new Uint8Array(Math.ceil(t.length/32)*32);return e.set(t),e}const eye=new Uint8Array([]);function tye(t){const e=[];let r=0;for(let n=0;n=5*32,"insufficient OffchainLookup data","OFFCHAIN_FAULT",{reason:"insufficient OffchainLookup data"});const r=Nr(t,0,32);He(Nr(r,0,12)===Nr(AR,0,12),"corrupt OffchainLookup sender","OFFCHAIN_FAULT",{reason:"corrupt OffchainLookup sender"}),e.sender=Nr(r,12);try{const n=[],s=Ct(Nr(t,32,64)),i=Ct(Nr(t,s,s+32)),o=Nr(t,s+32);for(let f=0;fe[n]),e}function nh(t,e){if(t.provider)return t.provider;He(!1,"missing provider","UNSUPPORTED_OPERATION",{operation:e})}async function ER(t,e){let r=w6(e);if(r.to!=null&&(r.to=Ri(r.to,t)),r.from!=null){const n=r.from;r.from=Promise.all([t.getAddress(),Ri(n,t)]).then(([s,i])=>(me(s.toLowerCase()===i.toLowerCase(),"transaction from mismatch","tx.from",i),s))}else r.from=t.getAddress();return await si(r)}class nye{constructor(e){Ie(this,"provider");lt(this,{provider:e||null})}async getNonce(e){return nh(this,"getTransactionCount").getTransactionCount(await this.getAddress(),e)}async populateCall(e){return await ER(this,e)}async populateTransaction(e){const r=nh(this,"populateTransaction"),n=await ER(this,e);n.nonce==null&&(n.nonce=await this.getNonce("pending")),n.gasLimit==null&&(n.gasLimit=await this.estimateGas(n));const s=await this.provider.getNetwork();if(n.chainId!=null){const o=ft(n.chainId);me(o===s.chainId,"transaction chainId mismatch","tx.chainId",e.chainId)}else n.chainId=s.chainId;const i=n.maxFeePerGas!=null||n.maxPriorityFeePerGas!=null;if(n.gasPrice!=null&&(n.type===2||i)?me(!1,"eip-1559 transaction do not support gasPrice","tx",e):(n.type===0||n.type===1)&&i&&me(!1,"pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","tx",e),(n.type===2||n.type==null)&&n.maxFeePerGas!=null&&n.maxPriorityFeePerGas!=null)n.type=2;else if(n.type===0||n.type===1){const o=await r.getFeeData();He(o.gasPrice!=null,"network does not support gasPrice","UNSUPPORTED_OPERATION",{operation:"getGasPrice"}),n.gasPrice==null&&(n.gasPrice=o.gasPrice)}else{const o=await r.getFeeData();if(n.type==null)if(o.maxFeePerGas!=null&&o.maxPriorityFeePerGas!=null)if(n.type=2,n.gasPrice!=null){const f=n.gasPrice;delete n.gasPrice,n.maxFeePerGas=f,n.maxPriorityFeePerGas=f}else n.maxFeePerGas==null&&(n.maxFeePerGas=o.maxFeePerGas),n.maxPriorityFeePerGas==null&&(n.maxPriorityFeePerGas=o.maxPriorityFeePerGas);else o.gasPrice!=null?(He(!i,"network does not support EIP-1559","UNSUPPORTED_OPERATION",{operation:"populateTransaction"}),n.gasPrice==null&&(n.gasPrice=o.gasPrice),n.type=0):He(!1,"failed to get consistent fee data","UNSUPPORTED_OPERATION",{operation:"signer.getFeeData"});else n.type===2&&(n.maxFeePerGas==null&&(n.maxFeePerGas=o.maxFeePerGas),n.maxPriorityFeePerGas==null&&(n.maxPriorityFeePerGas=o.maxPriorityFeePerGas))}return await si(n)}async estimateGas(e){return nh(this,"estimateGas").estimateGas(await this.populateCall(e))}async call(e){return nh(this,"call").call(await this.populateCall(e))}async resolveName(e){return await nh(this,"resolveName").resolveName(e)}async sendTransaction(e){const r=nh(this,"sendTransaction"),n=await this.populateTransaction(e);delete n.from;const s=x6.from(n);return await r.broadcastTransaction(await this.signTransaction(s))}}function iye(t){return JSON.parse(JSON.stringify(t))}var Ei,ya,Bu,q0,Ou,Kd,sy,T7,oy,k7;class fH{constructor(e){Te(this,sy);Te(this,oy);Te(this,Ei,void 0);Te(this,ya,void 0);Te(this,Bu,void 0);Te(this,q0,void 0);Te(this,Ou,void 0);Te(this,Kd,void 0);fe(this,Ei,e),fe(this,ya,null),fe(this,Bu,Ge(this,sy,T7).bind(this)),fe(this,q0,!1),fe(this,Ou,null),fe(this,Kd,!1)}_subscribe(e){throw new Error("subclasses must override this")}_emitResults(e,r){throw new Error("subclasses must override this")}_recover(e){throw new Error("subclasses must override this")}start(){X(this,q0)||(fe(this,q0,!0),Ge(this,sy,T7).call(this,-2))}stop(){X(this,q0)&&(fe(this,q0,!1),fe(this,Kd,!0),Ge(this,oy,k7).call(this),X(this,Ei).off("block",X(this,Bu)))}pause(e){e&&Ge(this,oy,k7).call(this),X(this,Ei).off("block",X(this,Bu))}resume(){this.start()}}Ei=new WeakMap,ya=new WeakMap,Bu=new WeakMap,q0=new WeakMap,Ou=new WeakMap,Kd=new WeakMap,sy=new WeakSet,T7=async function(e){try{X(this,ya)==null&&fe(this,ya,this._subscribe(X(this,Ei)));let r=null;try{r=await X(this,ya)}catch(i){if(!Ns(i,"UNSUPPORTED_OPERATION")||i.operation!=="eth_newFilter")throw i}if(r==null){fe(this,ya,null),X(this,Ei)._recoverSubscriber(this,this._recover(X(this,Ei)));return}const n=await X(this,Ei).getNetwork();if(X(this,Ou)||fe(this,Ou,n),X(this,Ou).chainId!==n.chainId)throw new Error("chaid changed");if(X(this,Kd))return;const s=await X(this,Ei).send("eth_getFilterChanges",[r]);await this._emitResults(X(this,Ei),s)}catch(r){console.log("@TODO",r)}X(this,Ei).once("block",X(this,Bu))},oy=new WeakSet,k7=function(){const e=X(this,ya);e&&(fe(this,ya,null),e.then(r=>{X(this,Ei).send("eth_uninstallFilter",[r])}))};var Nu;class sye extends fH{constructor(r,n){super(r);Te(this,Nu,void 0);fe(this,Nu,iye(n))}_recover(r){return new FS(r,X(this,Nu))}async _subscribe(r){return await r.send("eth_newFilter",[X(this,Nu)])}async _emitResults(r,n){for(const s of n)r.emit(X(this,Nu),r._wrapLog(s,r._network))}}Nu=new WeakMap;class oye extends fH{async _subscribe(e){return await e.send("eth_newPendingTransactionFilter",[])}async _emitResults(e,r){for(const n of r)e.emit("pending",n)}}const aye="bigint,boolean,function,number,string,symbol".split(/,/g);function t2(t){if(t==null||aye.indexOf(typeof t)>=0||typeof t.getAddress=="function")return t;if(Array.isArray(t))return t.map(t2);if(typeof t=="object")return Object.keys(t).reduce((e,r)=>(e[r]=t[r],e),{});throw new Error(`should not happen: ${t} (${typeof t})`)}function fye(t){return new Promise(e=>{setTimeout(e,t)})}function ih(t){return t&&t.toLowerCase()}function MR(t){return t&&typeof t.pollingInterval=="number"}const cye={polling:!1,staticNetwork:null,batchStallTime:10,batchMaxSize:1<<20,batchMaxCount:100,cacheTimeout:250,pollingInterval:4e3};class j8 extends nye{constructor(r,n){super(r);Ie(this,"address");n=Zt(n),lt(this,{address:n})}connect(r){He(!1,"cannot reconnect JsonRpcSigner","UNSUPPORTED_OPERATION",{operation:"signer.connect"})}async getAddress(){return this.address}async populateTransaction(r){return await this.populateCall(r)}async sendUncheckedTransaction(r){const n=t2(r),s=[];if(n.from){const o=n.from;s.push((async()=>{const f=await Ri(o,this.provider);me(f!=null&&f.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",r),n.from=f})())}else n.from=this.address;if(n.gasLimit==null&&s.push((async()=>{n.gasLimit=await this.provider.estimateGas({...n,from:this.address})})()),n.to!=null){const o=n.to;s.push((async()=>{n.to=await Ri(o,this.provider)})())}s.length&&await Promise.all(s);const i=this.provider.getRpcTransaction(n);return this.provider.send("eth_sendTransaction",[i])}async sendTransaction(r){const n=await this.provider.getBlockNumber(),s=await this.sendUncheckedTransaction(r);return await new Promise((i,o)=>{const f=[1e3,100],h=async()=>{const p=await this.provider.getTransaction(s);if(p!=null){i(p.replaceableTransaction(n));return}this.provider._setTimeout(()=>{h()},f.pop()||4e3)};h()})}async signTransaction(r){const n=t2(r);if(n.from){const i=await Ri(n.from,this.provider);me(i!=null&&i.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",r),n.from=i}else n.from=this.address;const s=this.provider.getRpcTransaction(n);return await this.provider.send("eth_signTransaction",[s])}async signMessage(r){const n=typeof r=="string"?Rf(r):r;return await this.provider.send("personal_sign",[nt(n),this.address.toLowerCase()])}async signTypedData(r,n,s){const i=t2(s),o=await eR.resolveNames(r,n,i,async f=>{const h=await Ri(f);return me(h!=null,"TypedData does not support null address","value",f),h});return await this.provider.send("eth_signTypedData_v4",[this.address.toLowerCase(),JSON.stringify(eR.getPayload(o.domain,n,o.value))])}async unlock(r){return this.provider.send("personal_unlockAccount",[this.address.toLowerCase(),r,null])}async _legacySignMessage(r){const n=typeof r=="string"?Rf(r):r;return await this.provider.send("eth_sign",[this.address.toLowerCase(),nt(n)])}}var Lu,Wd,yf,ba,So,bf,ay,R7;class uye extends Qge{constructor(r,n){super(r,n);Te(this,ay);Te(this,Lu,void 0);Te(this,Wd,void 0);Te(this,yf,void 0);Te(this,ba,void 0);Te(this,So,void 0);Te(this,bf,void 0);fe(this,Wd,1),fe(this,Lu,Object.assign({},cye,n||{})),fe(this,yf,[]),fe(this,ba,null),fe(this,bf,null);{let i=null;const o=new Promise(f=>{i=f});fe(this,So,{promise:o,resolve:i})}const s=this._getOption("staticNetwork");s&&(me(r==null||s.matches(r),"staticNetwork MUST match network object","options",n),fe(this,bf,s))}_getOption(r){return X(this,Lu)[r]}get _network(){return He(X(this,bf),"network is not available yet","NETWORK_ERROR"),X(this,bf)}async _perform(r){if(r.method==="call"||r.method==="estimateGas"){let s=r.transaction;if(s&&s.type!=null&&ft(s.type)&&s.maxFeePerGas==null&&s.maxPriorityFeePerGas==null){const i=await this.getFeeData();i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null&&(r=Object.assign({},r,{transaction:Object.assign({},s,{type:void 0})}))}}const n=this.getRpcRequest(r);return n!=null?await this.send(n.method,n.args):super._perform(r)}async _detectNetwork(){const r=this._getOption("staticNetwork");if(r)return r;if(this.ready)return _f.from(ft(await this.send("eth_chainId",[])));const n={id:R1(this,Wd)._++,method:"eth_chainId",params:[],jsonrpc:"2.0"};this.emit("debug",{action:"sendRpcPayload",payload:n});let s;try{s=(await this._send(n))[0]}catch(i){throw this.emit("debug",{action:"receiveRpcError",error:i}),i}if(this.emit("debug",{action:"receiveRpcResult",result:s}),"result"in s)return _f.from(ft(s.result));throw this.getRpcError(n,s)}_start(){X(this,So)==null||X(this,So).resolve==null||(X(this,So).resolve(),fe(this,So,null),(async()=>{for(;X(this,bf)==null&&!this.destroyed;)try{fe(this,bf,await this._detectNetwork())}catch(r){if(this.destroyed)break;console.log("JsonRpcProvider failed to detect network and cannot start up; retry in 1s (perhaps the URL is wrong or the node is not started)"),this.emit("error",nn("failed to bootstrap network detection","NETWORK_ERROR",{event:"initial-network-discovery",info:{error:r}})),await fye(1e3)}Ge(this,ay,R7).call(this)})())}async _waitUntilReady(){if(X(this,So)!=null)return await X(this,So).promise}_getSubscriber(r){return r.type==="pending"?new oye(this):r.type==="event"?this._getOption("polling")?new FS(this,r.filter):new sye(this,r.filter):r.type==="orphan"&&r.filter.orphan==="drop-log"?new aH("orphan"):super._getSubscriber(r)}get ready(){return X(this,So)==null}getRpcTransaction(r){const n={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(s=>{if(r[s]==null)return;let i=s;s==="gasLimit"&&(i="gas"),n[i]=Th(ft(r[s],`tx.${s}`))}),["from","to","data"].forEach(s=>{r[s]!=null&&(n[s]=nt(r[s]))}),r.accessList&&(n.accessList=Bl(r.accessList)),n}getRpcRequest(r){switch(r.method){case"chainId":return{method:"eth_chainId",args:[]};case"getBlockNumber":return{method:"eth_blockNumber",args:[]};case"getGasPrice":return{method:"eth_gasPrice",args:[]};case"getBalance":return{method:"eth_getBalance",args:[ih(r.address),r.blockTag]};case"getTransactionCount":return{method:"eth_getTransactionCount",args:[ih(r.address),r.blockTag]};case"getCode":return{method:"eth_getCode",args:[ih(r.address),r.blockTag]};case"getStorage":return{method:"eth_getStorageAt",args:[ih(r.address),"0x"+r.position.toString(16),r.blockTag]};case"broadcastTransaction":return{method:"eth_sendRawTransaction",args:[r.signedTransaction]};case"getBlock":if("blockTag"in r)return{method:"eth_getBlockByNumber",args:[r.blockTag,!!r.includeTransactions]};if("blockHash"in r)return{method:"eth_getBlockByHash",args:[r.blockHash,!!r.includeTransactions]};break;case"getTransaction":return{method:"eth_getTransactionByHash",args:[r.hash]};case"getTransactionReceipt":return{method:"eth_getTransactionReceipt",args:[r.hash]};case"call":return{method:"eth_call",args:[this.getRpcTransaction(r.transaction),r.blockTag]};case"estimateGas":return{method:"eth_estimateGas",args:[this.getRpcTransaction(r.transaction)]};case"getLogs":return r.filter&&r.filter.address!=null&&(Array.isArray(r.filter.address)?r.filter.address=r.filter.address.map(ih):r.filter.address=ih(r.filter.address)),{method:"eth_getLogs",args:[r.filter]}}return null}getRpcError(r,n){const{method:s}=r,{error:i}=n;if(s==="eth_estimateGas"&&i.message){const h=i.message;if(!h.match(/revert/i)&&h.match(/insufficient funds/i))return nn("insufficient funds","INSUFFICIENT_FUNDS",{transaction:r.params[0],info:{payload:r,error:i}})}if(s==="eth_call"||s==="eth_estimateGas"){const h=B7(i),p=Ig.getBuiltinCallException(s==="eth_call"?"call":"estimateGas",r.params[0],h?h.data:null);return p.info={error:i,payload:r},p}const o=JSON.stringify(lye(i));if(typeof i.message=="string"&&i.message.match(/user denied|ethers-user-denied/i))return nn("user rejected action","ACTION_REJECTED",{action:{eth_sign:"signMessage",personal_sign:"signMessage",eth_signTypedData_v4:"signTypedData",eth_signTransaction:"signTransaction",eth_sendTransaction:"sendTransaction",eth_requestAccounts:"requestAccess",wallet_requestAccounts:"requestAccess"}[s]||"unknown",reason:"rejected",info:{payload:r,error:i}});if(s==="eth_sendRawTransaction"||s==="eth_sendTransaction"){const h=r.params[0];if(o.match(/insufficient funds|base fee exceeds gas limit/i))return nn("insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:h,info:{error:i}});if(o.match(/nonce/i)&&o.match(/too low/i))return nn("nonce has already been used","NONCE_EXPIRED",{transaction:h,info:{error:i}});if(o.match(/replacement transaction/i)&&o.match(/underpriced/i))return nn("replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:h,info:{error:i}});if(o.match(/only replay-protected/i))return nn("legacy pre-eip-155 transactions not supported","UNSUPPORTED_OPERATION",{operation:s,info:{transaction:h,info:{error:i}}})}let f=!!o.match(/the method .* does not exist/i);return f||i&&i.details&&i.details.startsWith("Unauthorized method:")&&(f=!0),f?nn("unsupported operation","UNSUPPORTED_OPERATION",{operation:r.method,info:{error:i,payload:r}}):nn("could not coalesce error","UNKNOWN_ERROR",{error:i,payload:r})}send(r,n){if(this.destroyed)return Promise.reject(nn("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:r}));const s=R1(this,Wd)._++,i=new Promise((o,f)=>{X(this,yf).push({resolve:o,reject:f,payload:{method:r,params:n,id:s,jsonrpc:"2.0"}})});return Ge(this,ay,R7).call(this),i}async getSigner(r){r==null&&(r=0);const n=this.send("eth_accounts",[]);if(typeof r=="number"){const i=await n;if(r>=i.length)throw new Error("no such account");return new j8(this,i[r])}const{accounts:s}=await si({network:this.getNetwork(),accounts:n});r=Zt(r);for(const i of s)if(Zt(i)===r)return new j8(this,r);throw new Error("invalid account")}async listAccounts(){return(await this.send("eth_accounts",[])).map(n=>new j8(this,n))}destroy(){X(this,ba)&&(clearTimeout(X(this,ba)),fe(this,ba,null));for(const{payload:r,reject:n}of X(this,yf))n(nn("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:r.method}));fe(this,yf,[]),super.destroy()}}Lu=new WeakMap,Wd=new WeakMap,yf=new WeakMap,ba=new WeakMap,So=new WeakMap,bf=new WeakMap,ay=new WeakSet,R7=function(){if(X(this,ba))return;const r=this._getOption("batchMaxCount")===1?0:this._getOption("batchStallTime");fe(this,ba,setTimeout(()=>{fe(this,ba,null);const n=X(this,yf);for(fe(this,yf,[]);n.length;){const s=[n.shift()];for(;n.length&&s.length!==X(this,Lu).batchMaxCount;)if(s.push(n.shift()),JSON.stringify(s.map(o=>o.payload)).length>X(this,Lu).batchMaxSize){n.unshift(s.pop());break}(async()=>{const i=s.length===1?s[0].payload:s.map(o=>o.payload);this.emit("debug",{action:"sendRpcPayload",payload:i});try{const o=await this._send(i);this.emit("debug",{action:"receiveRpcResult",result:o});for(const{resolve:f,reject:h,payload:p}of s){if(this.destroyed){h(nn("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:p.method}));continue}const b=o.filter(v=>v.id===p.id)[0];if(b==null){const v=nn("missing response for request","BAD_DATA",{value:o,info:{payload:p}});this.emit("error",v),h(v);continue}if("error"in b){h(this.getRpcError(p,b));continue}f(b.result)}}catch(o){this.emit("debug",{action:"receiveRpcError",error:o});for(const{reject:f}of s)f(o)}})()}},r))};var G0;class cH extends uye{constructor(r,n){super(r,n);Te(this,G0,void 0);fe(this,G0,4e3)}_getSubscriber(r){const n=super._getSubscriber(r);return MR(n)&&(n.pollingInterval=X(this,G0)),n}get pollingInterval(){return X(this,G0)}set pollingInterval(r){if(!Number.isInteger(r)||r<0)throw new Error("invalid interval");fe(this,G0,r),this._forEachSubscriber(n=>{MR(n)&&(n.pollingInterval=X(this,G0))})}}G0=new WeakMap;var Jd;class uH extends cH{constructor(r,n,s){r==null&&(r="http://localhost:8545");super(n,s);Te(this,Jd,void 0);typeof r=="string"?fe(this,Jd,new qf(r)):fe(this,Jd,r.clone())}_getConnection(){return X(this,Jd).clone()}async send(r,n){return await this._start(),await super.send(r,n)}async _send(r){const n=this._getConnection();n.body=JSON.stringify(r),n.setHeader("content-type","application/json");const s=await n.send();s.assertOk();let i=s.bodyJson;return Array.isArray(i)||(i=[i]),i}}Jd=new WeakMap;function B7(t){if(t==null)return null;if(typeof t.message=="string"&&t.message.match(/revert/i)&&Rr(t.data))return{message:t.message,data:t.data};if(typeof t=="object"){for(const e in t){const r=B7(t[e]);if(r)return r}return null}if(typeof t=="string")try{return B7(JSON.parse(t))}catch{}return null}function O7(t,e){if(t!=null){if(typeof t.message=="string"&&e.push(t.message),typeof t=="object")for(const r in t)O7(t[r],e);if(typeof t=="string")try{return O7(JSON.parse(t),e)}catch{}}}function lye(t){const e=[];return O7(t,e),e}var Zd;class hye extends cH{constructor(r,n){super(n,{batchMaxCount:1});Te(this,Zd,void 0);fe(this,Zd,async(s,i)=>{const o={method:s,params:i};this.emit("debug",{action:"sendEip1193Request",payload:o});try{const f=await r.request(o);return this.emit("debug",{action:"receiveEip1193Result",result:f}),f}catch(f){const h=new Error(f.message);throw h.code=f.code,h.data=f.data,h.payload=o,this.emit("debug",{action:"receiveEip1193Error",error:h}),h}})}async send(r,n){return await this._start(),await super.send(r,n)}async _send(r){me(!Array.isArray(r),"EIP-1193 does not support batch request","payload",r);try{const n=await X(this,Zd).call(this,r.method,r.params||[]);return[{id:r.id,result:n}]}catch(n){return[{id:r.id,error:{code:n.code,data:n.data,message:n.message}}]}}getRpcError(r,n){switch(n=JSON.parse(JSON.stringify(n)),n.error.code||-1){case 4001:n.error.message=`ethers-user-denied: ${n.error.message}`;break;case 4200:n.error.message=`ethers-unsupported: ${n.error.message}`;break}return super.getRpcError(r,n)}async hasSigner(r){r==null&&(r=0);const n=await this.send("eth_accounts",[]);return typeof r=="number"?n.length>r:(r=r.toLowerCase(),n.filter(s=>s.toLowerCase()===r).length!==0)}async getSigner(r){if(r==null&&(r=0),!await this.hasSigner(r))try{await X(this,Zd).call(this,"eth_requestAccounts",[])}catch(n){const s=n.payload;throw this.getRpcError(s,{id:s.id,error:n})}return await super.getSigner(r)}}Zd=new WeakMap;var lH={},M6={},hH={},Vy={},Ky={};const dye="@safe-global/safe-apps-sdk",pye="8.0.0",mye="SDK developed to integrate third-party apps with Safe app.",gye="dist/src/index.js",yye="dist/src/index.d.ts",bye=["dist/**/*","src/**/*","CHANGELOG.md","README.md"],vye=["Safe","sdk","apps"],xye={test:"jest","format-dist":`sed -i 's/"files":/"_files":/' dist/package.json`,build:"yarn rimraf dist && tsc && yarn format-dist"},wye="Safe (https://safe.global)",Aye="MIT",Eye={"@safe-global/safe-gateway-typescript-sdk":"^3.5.3",viem:"^1.0.0"},Mye={rimraf:"^3.0.2"},Sye={type:"git",url:"git+https://github.com/safe-global/safe-apps-sdk.git"},_ye={url:"https://github.com/safe-global/safe-apps-sdk/issues"},Pye="https://github.com/safe-global/safe-apps-sdk#readme",Cye={access:"public"},Iye={name:dye,version:pye,description:mye,main:gye,typings:yye,_files:bye,keywords:vye,scripts:xye,author:wye,license:Aye,dependencies:Eye,devDependencies:Mye,repository:Sye,bugs:_ye,homepage:Pye,publishConfig:Cye};var Tye=Ke&&Ke.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Ky,"__esModule",{value:!0});Ky.getSDKVersion=void 0;const kye=Tye(Iye),Rye=()=>kye.default.version.split("-")[0];Ky.getSDKVersion=Rye;var Qx={};Object.defineProperty(Qx,"__esModule",{value:!0});Qx.generateRequestId=void 0;const Bye=t=>t.toString(16).padStart(2,"0"),Oye=t=>{const e=new Uint8Array((t||40)/2);return window.crypto.getRandomValues(e),Array.from(e,Bye).join("")},Nye=()=>typeof window<"u"?Oye(10):new Date().getTime().toString(36);Qx.generateRequestId=Nye;Object.defineProperty(Vy,"__esModule",{value:!0});Vy.MessageFormatter=void 0;const Lye=Ky,Dye=Qx;class Yx{}Vy.MessageFormatter=Yx;Yx.makeRequest=(t,e)=>({id:(0,Dye.generateRequestId)(),method:t,params:e,env:{sdkVersion:(0,Lye.getSDKVersion)()}});Yx.makeResponse=(t,e,r)=>({id:t,success:!0,version:r,data:e});Yx.makeErrorResponse=(t,e,r)=>({id:t,success:!1,error:e,version:r});var Ol={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.RestrictedMethods=t.Methods=void 0,function(e){e.sendTransactions="sendTransactions",e.rpcCall="rpcCall",e.getChainInfo="getChainInfo",e.getSafeInfo="getSafeInfo",e.getTxBySafeTxHash="getTxBySafeTxHash",e.getSafeBalances="getSafeBalances",e.signMessage="signMessage",e.signTypedMessage="signTypedMessage",e.getEnvironmentInfo="getEnvironmentInfo",e.getOffChainSignature="getOffChainSignature",e.requestAddressBook="requestAddressBook",e.wallet_getPermissions="wallet_getPermissions",e.wallet_requestPermissions="wallet_requestPermissions"}(t.Methods||(t.Methods={})),function(e){e.requestAddressBook="requestAddressBook"}(t.RestrictedMethods||(t.RestrictedMethods={}))})(Ol);(function(t){var e=Ke&&Ke.__createBinding||(Object.create?function(i,o,f,h){h===void 0&&(h=f);var p=Object.getOwnPropertyDescriptor(o,f);(!p||("get"in p?!o.__esModule:p.writable||p.configurable))&&(p={enumerable:!0,get:function(){return o[f]}}),Object.defineProperty(i,h,p)}:function(i,o,f,h){h===void 0&&(h=f),i[h]=o[f]}),r=Ke&&Ke.__exportStar||function(i,o){for(var f in i)f!=="default"&&!Object.prototype.hasOwnProperty.call(o,f)&&e(o,i,f)};Object.defineProperty(t,"__esModule",{value:!0});const n=Vy;class s{constructor(o=null,f=!1){this.allowedOrigins=null,this.callbacks=new Map,this.debugMode=!1,this.isServer=typeof window>"u",this.isValidMessage=({origin:h,data:p,source:b})=>{const v=!p,E=!this.isServer&&b===window.parent,S=(typeof p.version<"u"&&parseInt(p.version.split(".")[0]))>=1;let P=!0;return Array.isArray(this.allowedOrigins)&&(P=this.allowedOrigins.find(I=>I.test(h))!==void 0),!v&&E&&S&&P},this.logIncomingMessage=h=>{console.info(`Safe Apps SDK v1: A message was received from origin ${h.origin}. `,h.data)},this.onParentMessage=h=>{this.isValidMessage(h)&&(this.debugMode&&this.logIncomingMessage(h),this.handleIncomingMessage(h.data))},this.handleIncomingMessage=h=>{const{id:p}=h,b=this.callbacks.get(p);b&&(b(h),this.callbacks.delete(p))},this.send=(h,p)=>{const b=n.MessageFormatter.makeRequest(h,p);if(this.isServer)throw new Error("Window doesn't exist");return window.parent.postMessage(b,"*"),new Promise((v,E)=>{this.callbacks.set(b.id,_=>{if(!_.success){E(new Error(_.error));return}v(_)})})},this.allowedOrigins=o,this.debugMode=f,this.isServer||window.addEventListener("message",this.onParentMessage)}}t.default=s,r(Ol,t)})(hH);var Xx={},ew={},tw={};Object.defineProperty(tw,"__esModule",{value:!0});tw.isObjectEIP712TypedData=void 0;const $ye=t=>typeof t=="object"&&t!=null&&"domain"in t&&"types"in t&&"message"in t;tw.isObjectEIP712TypedData=$ye;var dH={};Object.defineProperty(dH,"__esModule",{value:!0});var pH={},mH={},Cp={},hc={},N7={exports:{}};(function(t,e){var r=typeof self<"u"?self:Ke,n=function(){function i(){this.fetch=!1,this.DOMException=r.DOMException}return i.prototype=r,new i}();(function(i){(function(o){var f={searchParams:"URLSearchParams"in i,iterable:"Symbol"in i&&"iterator"in Symbol,blob:"FileReader"in i&&"Blob"in i&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in i,arrayBuffer:"ArrayBuffer"in i};function h(l){return l&&DataView.prototype.isPrototypeOf(l)}if(f.arrayBuffer)var p=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],b=ArrayBuffer.isView||function(l){return l&&p.indexOf(Object.prototype.toString.call(l))>-1};function v(l){if(typeof l!="string"&&(l=String(l)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(l))throw new TypeError("Invalid character in header field name");return l.toLowerCase()}function E(l){return typeof l!="string"&&(l=String(l)),l}function _(l){var d={next:function(){var m=l.shift();return{done:m===void 0,value:m}}};return f.iterable&&(d[Symbol.iterator]=function(){return d}),d}function S(l){this.map={},l instanceof S?l.forEach(function(d,m){this.append(m,d)},this):Array.isArray(l)?l.forEach(function(d){this.append(d[0],d[1])},this):l&&Object.getOwnPropertyNames(l).forEach(function(d){this.append(d,l[d])},this)}S.prototype.append=function(l,d){l=v(l),d=E(d);var m=this.map[l];this.map[l]=m?m+", "+d:d},S.prototype.delete=function(l){delete this.map[v(l)]},S.prototype.get=function(l){return l=v(l),this.has(l)?this.map[l]:null},S.prototype.has=function(l){return this.map.hasOwnProperty(v(l))},S.prototype.set=function(l,d){this.map[v(l)]=E(d)},S.prototype.forEach=function(l,d){for(var m in this.map)this.map.hasOwnProperty(m)&&l.call(d,this.map[m],m,this)},S.prototype.keys=function(){var l=[];return this.forEach(function(d,m){l.push(m)}),_(l)},S.prototype.values=function(){var l=[];return this.forEach(function(d){l.push(d)}),_(l)},S.prototype.entries=function(){var l=[];return this.forEach(function(d,m){l.push([m,d])}),_(l)},f.iterable&&(S.prototype[Symbol.iterator]=S.prototype.entries);function P(l){if(l.bodyUsed)return Promise.reject(new TypeError("Already read"));l.bodyUsed=!0}function I(l){return new Promise(function(d,m){l.onload=function(){d(l.result)},l.onerror=function(){m(l.error)}})}function C(l){var d=new FileReader,m=I(d);return d.readAsArrayBuffer(l),m}function T(l){var d=new FileReader,m=I(d);return d.readAsText(l),m}function B(l){for(var d=new Uint8Array(l),m=new Array(d.length),x=0;x-1?d:l}function Q(l,d){d=d||{};var m=d.body;if(l instanceof Q){if(l.bodyUsed)throw new TypeError("Already read");this.url=l.url,this.credentials=l.credentials,d.headers||(this.headers=new S(l.headers)),this.method=l.method,this.mode=l.mode,this.signal=l.signal,!m&&l._bodyInit!=null&&(m=l._bodyInit,l.bodyUsed=!0)}else this.url=String(l);if(this.credentials=d.credentials||this.credentials||"same-origin",(d.headers||!this.headers)&&(this.headers=new S(d.headers)),this.method=J(d.method||this.method||"GET"),this.mode=d.mode||this.mode||null,this.signal=d.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&m)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(m)}Q.prototype.clone=function(){return new Q(this,{body:this._bodyInit})};function K(l){var d=new FormData;return l.trim().split("&").forEach(function(m){if(m){var x=m.split("="),A=x.shift().replace(/\+/g," "),y=x.join("=").replace(/\+/g," ");d.append(decodeURIComponent(A),decodeURIComponent(y))}}),d}function se(l){var d=new S,m=l.replace(/\r?\n[\t ]+/g," ");return m.split(/\r?\n/).forEach(function(x){var A=x.split(":"),y=A.shift().trim();if(y){var c=A.join(":").trim();d.append(y,c)}}),d}$.call(Q.prototype);function w(l,d){d||(d={}),this.type="default",this.status=d.status===void 0?200:d.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in d?d.statusText:"OK",this.headers=new S(d.headers),this.url=d.url||"",this._initBody(l)}$.call(w.prototype),w.prototype.clone=function(){return new w(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new S(this.headers),url:this.url})},w.error=function(){var l=new w(null,{status:0,statusText:""});return l.type="error",l};var a=[301,302,303,307,308];w.redirect=function(l,d){if(a.indexOf(d)===-1)throw new RangeError("Invalid status code");return new w(null,{status:d,headers:{location:l}})},o.DOMException=i.DOMException;try{new o.DOMException}catch{o.DOMException=function(d,m){this.message=d,this.name=m;var x=Error(d);this.stack=x.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function u(l,d){return new Promise(function(m,x){var A=new Q(l,d);if(A.signal&&A.signal.aborted)return x(new o.DOMException("Aborted","AbortError"));var y=new XMLHttpRequest;function c(){y.abort()}y.onload=function(){var g={status:y.status,statusText:y.statusText,headers:se(y.getAllResponseHeaders()||"")};g.url="responseURL"in y?y.responseURL:g.headers.get("X-Request-URL");var M="response"in y?y.response:y.responseText;m(new w(M,g))},y.onerror=function(){x(new TypeError("Network request failed"))},y.ontimeout=function(){x(new TypeError("Network request failed"))},y.onabort=function(){x(new o.DOMException("Aborted","AbortError"))},y.open(A.method,A.url,!0),A.credentials==="include"?y.withCredentials=!0:A.credentials==="omit"&&(y.withCredentials=!1),"responseType"in y&&f.blob&&(y.responseType="blob"),A.headers.forEach(function(g,M){y.setRequestHeader(M,g)}),A.signal&&(A.signal.addEventListener("abort",c),y.onreadystatechange=function(){y.readyState===4&&A.signal.removeEventListener("abort",c)}),y.send(typeof A._bodyInit>"u"?null:A._bodyInit)})}return u.polyfill=!0,i.fetch||(i.fetch=u,i.Headers=S,i.Request=Q,i.Response=w),o.Headers=S,o.Request=Q,o.Response=w,o.fetch=u,Object.defineProperty(o,"__esModule",{value:!0}),o})({})})(n),n.fetch.ponyfill=!0,delete n.fetch.polyfill;var s=n;e=s.fetch,e.default=s.fetch,e.fetch=s.fetch,e.Headers=s.Headers,e.Request=s.Request,e.Response=s.Response,t.exports=e})(N7,N7.exports);var Fye=N7.exports,Uye=Ke&&Ke.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})},zye=Ke&&Ke.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(hc,"__esModule",{value:!0});hc.fetchData=hc.stringifyQuery=hc.insertParams=void 0;const jye=zye(Fye),Hye=t=>typeof t=="object"&&t!==null&&"code"in t&&"message"in t;function qye(t,e,r){return t.replace(new RegExp(`\\{${e}\\}`,"g"),r)}function Gye(t,e){return e?Object.keys(e).reduce((r,n)=>qye(r,n,String(e[n])),t):t}hc.insertParams=Gye;function Vye(t){if(!t)return"";const e=new URLSearchParams;Object.keys(t).forEach(n=>{t[n]!=null&&e.append(n,String(t[n]))});const r=e.toString();return r?`?${r}`:""}hc.stringifyQuery=Vye;function Kye(t,e){return Uye(this,void 0,void 0,function*(){let r;e!=null&&(r={method:"POST",body:typeof e=="string"?e:JSON.stringify(e),headers:{"Content-Type":"application/json"}});const n=yield(0,jye.default)(t,r);let s;try{s=yield n.json()}catch{if(n.headers&&n.headers.get("content-length")!=="0")throw new Error(`Invalid response content: ${n.statusText}`)}if(!n.ok){const i=Hye(s)?`${s.code}: ${s.message}`:n.statusText;throw new Error(i)}return s})}hc.fetchData=Kye;Object.defineProperty(Cp,"__esModule",{value:!0});Cp.getEndpoint=Cp.postEndpoint=void 0;const kg=hc;function gH(t,e,r,n){const s=(0,kg.insertParams)(e,r),i=(0,kg.stringifyQuery)(n);return`${t}${s}${i}`}function Wye(t,e,r){const n=gH(t,e,r==null?void 0:r.path,r==null?void 0:r.query);return(0,kg.fetchData)(n,r==null?void 0:r.body)}Cp.postEndpoint=Wye;function Jye(t,e,r,n){if(n)return(0,kg.fetchData)(n);const s=gH(t,e,r==null?void 0:r.path,r==null?void 0:r.query);return(0,kg.fetchData)(s)}Cp.getEndpoint=Jye;var rw={};Object.defineProperty(rw,"__esModule",{value:!0});rw.DEFAULT_BASE_URL=void 0;rw.DEFAULT_BASE_URL="https://safe-client.safe.global";var yH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationVersionState=void 0,function(e){e.UP_TO_DATE="UP_TO_DATE",e.OUTDATED="OUTDATED",e.UNKNOWN="UNKNOWN"}(t.ImplementationVersionState||(t.ImplementationVersionState={}))})(yH);var bH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SafeAppSocialPlatforms=t.SafeAppFeatures=t.SafeAppAccessPolicyTypes=void 0,function(e){e.NoRestrictions="NO_RESTRICTIONS",e.DomainAllowlist="DOMAIN_ALLOWLIST"}(t.SafeAppAccessPolicyTypes||(t.SafeAppAccessPolicyTypes={})),function(e){e.BATCHED_TRANSACTIONS="BATCHED_TRANSACTIONS"}(t.SafeAppFeatures||(t.SafeAppFeatures={})),function(e){e.TWITTER="TWITTER",e.GITHUB="GITHUB",e.DISCORD="DISCORD"}(t.SafeAppSocialPlatforms||(t.SafeAppSocialPlatforms={}))})(bH);var vH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.LabelValue=t.DetailedExecutionInfoType=t.TransactionListItemType=t.ConflictType=t.TransactionInfoType=t.SettingsInfoType=t.TransactionTokenType=t.TransferDirection=t.TransactionStatus=t.Operation=void 0,function(e){e[e.CALL=0]="CALL",e[e.DELEGATE=1]="DELEGATE"}(t.Operation||(t.Operation={})),function(e){e.AWAITING_CONFIRMATIONS="AWAITING_CONFIRMATIONS",e.AWAITING_EXECUTION="AWAITING_EXECUTION",e.CANCELLED="CANCELLED",e.FAILED="FAILED",e.SUCCESS="SUCCESS"}(t.TransactionStatus||(t.TransactionStatus={})),function(e){e.INCOMING="INCOMING",e.OUTGOING="OUTGOING",e.UNKNOWN="UNKNOWN"}(t.TransferDirection||(t.TransferDirection={})),function(e){e.ERC20="ERC20",e.ERC721="ERC721",e.NATIVE_COIN="NATIVE_COIN"}(t.TransactionTokenType||(t.TransactionTokenType={})),function(e){e.SET_FALLBACK_HANDLER="SET_FALLBACK_HANDLER",e.ADD_OWNER="ADD_OWNER",e.REMOVE_OWNER="REMOVE_OWNER",e.SWAP_OWNER="SWAP_OWNER",e.CHANGE_THRESHOLD="CHANGE_THRESHOLD",e.CHANGE_IMPLEMENTATION="CHANGE_IMPLEMENTATION",e.ENABLE_MODULE="ENABLE_MODULE",e.DISABLE_MODULE="DISABLE_MODULE",e.SET_GUARD="SET_GUARD",e.DELETE_GUARD="DELETE_GUARD"}(t.SettingsInfoType||(t.SettingsInfoType={})),function(e){e.TRANSFER="Transfer",e.SETTINGS_CHANGE="SettingsChange",e.CUSTOM="Custom",e.CREATION="Creation"}(t.TransactionInfoType||(t.TransactionInfoType={})),function(e){e.NONE="None",e.HAS_NEXT="HasNext",e.END="End"}(t.ConflictType||(t.ConflictType={})),function(e){e.TRANSACTION="TRANSACTION",e.LABEL="LABEL",e.CONFLICT_HEADER="CONFLICT_HEADER",e.DATE_LABEL="DATE_LABEL"}(t.TransactionListItemType||(t.TransactionListItemType={})),function(e){e.MULTISIG="MULTISIG",e.MODULE="MODULE"}(t.DetailedExecutionInfoType||(t.DetailedExecutionInfoType={})),function(e){e.Queued="Queued",e.Next="Next"}(t.LabelValue||(t.LabelValue={}))})(vH);var xH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.FEATURES=t.GAS_PRICE_TYPE=t.RPC_AUTHENTICATION=void 0,function(e){e.API_KEY_PATH="API_KEY_PATH",e.NO_AUTHENTICATION="NO_AUTHENTICATION",e.UNKNOWN="UNKNOWN"}(t.RPC_AUTHENTICATION||(t.RPC_AUTHENTICATION={})),function(e){e.ORACLE="ORACLE",e.FIXED="FIXED",e.UNKNOWN="UNKNOWN"}(t.GAS_PRICE_TYPE||(t.GAS_PRICE_TYPE={})),function(e){e.ERC721="ERC721",e.SAFE_APPS="SAFE_APPS",e.CONTRACT_INTERACTION="CONTRACT_INTERACTION",e.DOMAIN_LOOKUP="DOMAIN_LOOKUP",e.SPENDING_LIMIT="SPENDING_LIMIT",e.EIP1559="EIP1559",e.SAFE_TX_GAS_OPTIONAL="SAFE_TX_GAS_OPTIONAL",e.TX_SIMULATION="TX_SIMULATION",e.EIP1271="EIP1271"}(t.FEATURES||(t.FEATURES={}))})(xH);var wH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TokenType=void 0,function(e){e.ERC20="ERC20",e.ERC721="ERC721",e.NATIVE_TOKEN="NATIVE_TOKEN"}(t.TokenType||(t.TokenType={}))})(wH);var AH={};Object.defineProperty(AH,"__esModule",{value:!0});var EH={};Object.defineProperty(EH,"__esModule",{value:!0});var MH={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SafeMessageStatus=t.SafeMessageListItemType=void 0,function(e){e.DATE_LABEL="DATE_LABEL",e.MESSAGE="MESSAGE"}(t.SafeMessageListItemType||(t.SafeMessageListItemType={})),function(e){e.NEEDS_CONFIRMATION="NEEDS_CONFIRMATION",e.CONFIRMED="CONFIRMED"}(t.SafeMessageStatus||(t.SafeMessageStatus={}))})(MH);(function(t){var e=Ke&&Ke.__createBinding||(Object.create?function(l,d,m,x){x===void 0&&(x=m);var A=Object.getOwnPropertyDescriptor(d,m);(!A||("get"in A?!d.__esModule:A.writable||A.configurable))&&(A={enumerable:!0,get:function(){return d[m]}}),Object.defineProperty(l,x,A)}:function(l,d,m,x){x===void 0&&(x=m),l[x]=d[m]}),r=Ke&&Ke.__exportStar||function(l,d){for(var m in l)m!=="default"&&!Object.prototype.hasOwnProperty.call(d,m)&&e(d,l,m)};Object.defineProperty(t,"__esModule",{value:!0}),t.confirmSafeMessage=t.proposeSafeMessage=t.getSafeMessage=t.getSafeMessages=t.getDecodedData=t.getMasterCopies=t.getSafeApps=t.getChainConfig=t.getChainsConfig=t.proposeTransaction=t.postSafeGasEstimation=t.getTransactionDetails=t.getTransactionQueue=t.getTransactionHistory=t.getCollectiblesPage=t.getCollectibles=t.getOwnedSafes=t.getFiatCurrencies=t.getBalances=t.getMultisigTransactions=t.getModuleTransactions=t.getIncomingTransfers=t.getSafeInfo=t.setBaseUrl=void 0;const n=Cp,s=rw;r(yH,t),r(bH,t),r(vH,t),r(xH,t),r(wH,t),r(AH,t),r(EH,t),r(MH,t);let i=s.DEFAULT_BASE_URL;const o=l=>{i=l};t.setBaseUrl=o;function f(l,d){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}",{path:{chainId:l,address:d}})}t.getSafeInfo=f;function h(l,d,m,x){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}/incoming-transfers/",{path:{chainId:l,address:d},query:m},x)}t.getIncomingTransfers=h;function p(l,d,m,x){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}/module-transactions/",{path:{chainId:l,address:d},query:m},x)}t.getModuleTransactions=p;function b(l,d,m,x){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}/multisig-transactions/",{path:{chainId:l,address:d},query:m},x)}t.getMultisigTransactions=b;function v(l,d,m="usd",x={}){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}/balances/{currency}",{path:{chainId:l,address:d,currency:m},query:x})}t.getBalances=v;function E(){return(0,n.getEndpoint)(i,"/v1/balances/supported-fiat-codes")}t.getFiatCurrencies=E;function _(l,d){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/owners/{address}/safes",{path:{chainId:l,address:d}})}t.getOwnedSafes=_;function S(l,d,m={}){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:l,address:d},query:m})}t.getCollectibles=S;function P(l,d,m={},x){return(0,n.getEndpoint)(i,"/v2/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:l,address:d},query:m},x)}t.getCollectiblesPage=P;function I(l,d,m){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{safe_address}/transactions/history",{path:{chainId:l,safe_address:d},query:{}},m)}t.getTransactionHistory=I;function C(l,d,m,x){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{safe_address}/transactions/queued",{path:{chainId:l,safe_address:d},query:{trusted:x}},m)}t.getTransactionQueue=C;function T(l,d){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/transactions/{transactionId}",{path:{chainId:l,transactionId:d}})}t.getTransactionDetails=T;function B(l,d,m){return(0,n.postEndpoint)(i,"/v2/chains/{chainId}/safes/{safe_address}/multisig-transactions/estimations",{path:{chainId:l,safe_address:d},body:m})}t.postSafeGasEstimation=B;function N(l,d,m){return(0,n.postEndpoint)(i,"/v1/chains/{chainId}/transactions/{safe_address}/propose",{path:{chainId:l,safe_address:d},body:m})}t.proposeTransaction=N;function $(l){return(0,n.getEndpoint)(i,"/v1/chains",{query:l})}t.getChainsConfig=$;function H(l){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}",{path:{chainId:l}})}t.getChainConfig=H;function J(l,d={}){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safe-apps",{path:{chainId:l},query:d})}t.getSafeApps=J;function Q(l){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/about/master-copies",{path:{chainId:l}})}t.getMasterCopies=Q;function K(l,d){return(0,n.postEndpoint)(i,"/v1/chains/{chainId}/data-decoder",{path:{chainId:l},body:{data:d}})}t.getDecodedData=K;function se(l,d,m){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:l,safe_address:d},query:{}},m)}t.getSafeMessages=se;function w(l,d){return(0,n.getEndpoint)(i,"/v1/chains/{chainId}/messages/{message_hash}",{path:{chainId:l,message_hash:d}})}t.getSafeMessage=w;function a(l,d,m){return(0,n.postEndpoint)(i,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:l,safe_address:d},body:m})}t.proposeSafeMessage=a;function u(l,d,m){return(0,n.postEndpoint)(i,"/v1/chains/{chainId}/messages/{message_hash}/signatures",{path:{chainId:l,message_hash:d},body:m})}t.confirmSafeMessage=u})(mH);(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TransferDirection=t.TransactionStatus=t.TokenType=t.Operation=void 0;var e=mH;Object.defineProperty(t,"Operation",{enumerable:!0,get:function(){return e.Operation}}),Object.defineProperty(t,"TokenType",{enumerable:!0,get:function(){return e.TokenType}}),Object.defineProperty(t,"TransactionStatus",{enumerable:!0,get:function(){return e.TransactionStatus}}),Object.defineProperty(t,"TransferDirection",{enumerable:!0,get:function(){return e.TransferDirection}})})(pH);var SH={};Object.defineProperty(SH,"__esModule",{value:!0});(function(t){var e=Ke&&Ke.__createBinding||(Object.create?function(n,s,i,o){o===void 0&&(o=i);var f=Object.getOwnPropertyDescriptor(s,i);(!f||("get"in f?!s.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return s[i]}}),Object.defineProperty(n,o,f)}:function(n,s,i,o){o===void 0&&(o=i),n[o]=s[i]}),r=Ke&&Ke.__exportStar||function(n,s){for(var i in n)i!=="default"&&!Object.prototype.hasOwnProperty.call(s,i)&&e(s,n,i)};Object.defineProperty(t,"__esModule",{value:!0}),r(tw,t),r(dH,t),r(pH,t),r(SH,t)})(ew);Object.defineProperty(Xx,"__esModule",{value:!0});Xx.TXs=void 0;const Xb=Ol,Zye=ew;class Qye{constructor(e){this.communicator=e}async getBySafeTxHash(e){if(!e)throw new Error("Invalid safeTxHash");return(await this.communicator.send(Xb.Methods.getTxBySafeTxHash,{safeTxHash:e})).data}async signMessage(e){const r={message:e};return(await this.communicator.send(Xb.Methods.signMessage,r)).data}async signTypedMessage(e){if(!(0,Zye.isObjectEIP712TypedData)(e))throw new Error("Invalid typed data");return(await this.communicator.send(Xb.Methods.signTypedMessage,{typedData:e})).data}async send({txs:e,params:r}){if(!e||!e.length)throw new Error("No transactions were passed");const n={txs:e,params:r};return(await this.communicator.send(Xb.Methods.sendTransactions,n)).data}}Xx.TXs=Qye;var nw={},Wy={};Object.defineProperty(Wy,"__esModule",{value:!0});Wy.RPC_CALLS=void 0;Wy.RPC_CALLS={eth_call:"eth_call",eth_gasPrice:"eth_gasPrice",eth_getLogs:"eth_getLogs",eth_getBalance:"eth_getBalance",eth_getCode:"eth_getCode",eth_getBlockByHash:"eth_getBlockByHash",eth_getBlockByNumber:"eth_getBlockByNumber",eth_getStorageAt:"eth_getStorageAt",eth_getTransactionByHash:"eth_getTransactionByHash",eth_getTransactionReceipt:"eth_getTransactionReceipt",eth_getTransactionCount:"eth_getTransactionCount",eth_estimateGas:"eth_estimateGas",safe_setSettings:"safe_setSettings"};Object.defineProperty(nw,"__esModule",{value:!0});nw.Eth=void 0;const ji=Wy,Yye=Ol,Ka={defaultBlockParam:(t="latest")=>t,returnFullTxObjectParam:(t=!1)=>t,blockNumberToHex:t=>Number.isInteger(t)?`0x${t.toString(16)}`:t};class Xye{constructor(e){this.communicator=e,this.call=this.buildRequest({call:ji.RPC_CALLS.eth_call,formatters:[null,Ka.defaultBlockParam]}),this.getBalance=this.buildRequest({call:ji.RPC_CALLS.eth_getBalance,formatters:[null,Ka.defaultBlockParam]}),this.getCode=this.buildRequest({call:ji.RPC_CALLS.eth_getCode,formatters:[null,Ka.defaultBlockParam]}),this.getStorageAt=this.buildRequest({call:ji.RPC_CALLS.eth_getStorageAt,formatters:[null,Ka.blockNumberToHex,Ka.defaultBlockParam]}),this.getPastLogs=this.buildRequest({call:ji.RPC_CALLS.eth_getLogs}),this.getBlockByHash=this.buildRequest({call:ji.RPC_CALLS.eth_getBlockByHash,formatters:[null,Ka.returnFullTxObjectParam]}),this.getBlockByNumber=this.buildRequest({call:ji.RPC_CALLS.eth_getBlockByNumber,formatters:[Ka.blockNumberToHex,Ka.returnFullTxObjectParam]}),this.getTransactionByHash=this.buildRequest({call:ji.RPC_CALLS.eth_getTransactionByHash}),this.getTransactionReceipt=this.buildRequest({call:ji.RPC_CALLS.eth_getTransactionReceipt}),this.getTransactionCount=this.buildRequest({call:ji.RPC_CALLS.eth_getTransactionCount,formatters:[null,Ka.defaultBlockParam]}),this.getGasPrice=this.buildRequest({call:ji.RPC_CALLS.eth_gasPrice}),this.getEstimateGas=r=>this.buildRequest({call:ji.RPC_CALLS.eth_estimateGas})([r]),this.setSafeSettings=this.buildRequest({call:ji.RPC_CALLS.safe_setSettings})}buildRequest(e){const{call:r,formatters:n}=e;return async s=>{n&&Array.isArray(s)&&n.forEach((f,h)=>{f&&(s[h]=f(s[h]))});const i={call:r,params:s||[]};return(await this.communicator.send(Yye.Methods.rpcCall,i)).data}}}nw.Eth=Xye;var iw={};const ebe="0.9.8";let bi=class L7 extends Error{constructor(e,r={}){var o;const n=r.cause instanceof L7?r.cause.details:(o=r.cause)!=null&&o.message?r.cause.message:r.details,s=r.cause instanceof L7&&r.cause.docsPath||r.docsPath,i=[e||"An error occurred.","",...r.metaMessages?[...r.metaMessages,""]:[],...s?[`Docs: https://abitype.dev${s}`]:[],...n?[`Details: ${n}`]:[],`Version: abitype@${ebe}`].join(` -`);super(i),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiTypeError"}),r.cause&&(this.cause=r.cause),this.details=n,this.docsPath=s,this.metaMessages=r.metaMessages,this.shortMessage=e}};function qc(t,e){const r=t.exec(e);return r==null?void 0:r.groups}const _H=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,PH=/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/,CH=/^\(.+?\).*?$/,SR=/^tuple(?(\[(\d*)\])*)$/;function D7(t){let e=t.type;if(SR.test(t.type)&&"components"in t){e="(";const r=t.components.length;for(let s=0;s[a-zA-Z$_][a-zA-Z0-9$_]*)\((?.*?)\)$/;function rbe(t){return IH.test(t)}function nbe(t){return qc(IH,t)}const TH=/^event (?[a-zA-Z$_][a-zA-Z0-9$_]*)\((?.*?)\)$/;function ibe(t){return TH.test(t)}function sbe(t){return qc(TH,t)}const kH=/^function (?[a-zA-Z$_][a-zA-Z0-9$_]*)\((?.*?)\)(?: (?external|public{1}))?(?: (?pure|view|nonpayable|payable{1}))?(?: returns\s?\((?.*?)\))?$/;function obe(t){return kH.test(t)}function abe(t){return qc(kH,t)}const RH=/^struct (?[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?.*?)\}$/;function Jy(t){return RH.test(t)}function fbe(t){return qc(RH,t)}const BH=/^constructor\((?.*?)\)(?:\s(?payable{1}))?$/;function cbe(t){return BH.test(t)}function ube(t){return qc(BH,t)}const lbe=/^fallback\(\)$/;function hbe(t){return lbe.test(t)}const dbe=/^receive\(\) external payable$/;function pbe(t){return dbe.test(t)}const S6=new Set(["memory","indexed","storage","calldata"]),mbe=new Set(["indexed"]),$7=new Set(["calldata","memory","storage"]);class OH extends bi{constructor({signature:e}){super("Failed to parse ABI item.",{details:`parseAbiItem(${JSON.stringify(e,null,2)})`,docsPath:"/api/human.html#parseabiitem-1"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiItemError"})}}class NH extends bi{constructor({type:e}){super("Unknown type.",{metaMessages:[`Type "${e}" is not a valid ABI type. Perhaps you forgot to include a struct signature?`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownTypeError"})}}class gbe extends bi{constructor({type:e}){super("Unknown type.",{metaMessages:[`Type "${e}" is not a valid ABI type.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSolidityTypeError"})}}class LH extends bi{constructor({param:e}){super("Failed to parse ABI parameter.",{details:`parseAbiParameter(${JSON.stringify(e,null,2)})`,docsPath:"/api/human.html#parseabiparameter-1"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiParameterError"})}}class DH extends bi{constructor({params:e}){super("Failed to parse ABI parameters.",{details:`parseAbiParameters(${JSON.stringify(e,null,2)})`,docsPath:"/api/human.html#parseabiparameters-1"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiParametersError"})}}class $H extends bi{constructor({param:e}){super("Invalid ABI parameter.",{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParameterError"})}}class FH extends bi{constructor({param:e,name:r}){super("Invalid ABI parameter.",{details:e,metaMessages:[`"${r}" is a protected Solidity keyword. More info: https://docs.soliditylang.org/en/latest/cheatsheet.html`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SolidityProtectedKeywordError"})}}class UH extends bi{constructor({param:e,type:r,modifier:n}){super("Invalid ABI parameter.",{details:e,metaMessages:[`Modifier "${n}" not allowed${r?` in "${r}" type`:""}.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidModifierError"})}}class zH extends bi{constructor({param:e,type:r,modifier:n}){super("Invalid ABI parameter.",{details:e,metaMessages:[`Modifier "${n}" not allowed${r?` in "${r}" type`:""}.`,`Data location can only be specified for array, struct, or mapping types, but "${n}" was given.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidFunctionModifierError"})}}class jH extends bi{constructor({abiParameter:e}){super("Invalid ABI parameter.",{details:JSON.stringify(e,null,2),metaMessages:["ABI parameter type is invalid."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiTypeParameterError"})}}class Oh extends bi{constructor({signature:e,type:r}){super(`Invalid ${r} signature.`,{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSignatureError"})}}class HH extends bi{constructor({signature:e}){super("Unknown signature.",{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSignatureError"})}}class qH extends bi{constructor({signature:e}){super("Invalid struct signature.",{details:e,metaMessages:["No properties exist."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidStructSignatureError"})}}class GH extends bi{constructor({type:e}){super("Circular reference detected.",{metaMessages:[`Struct "${e}" is a circular reference.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"CircularReferenceError"})}}class VH extends bi{constructor({current:e,depth:r}){super("Unbalanced parentheses.",{metaMessages:[`"${e.trim()}" has too many ${r>0?"opening":"closing"} parentheses.`],details:`Depth "${r}"`}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParenthesisError"})}}function ybe(t,e){return e?`${e}:${t}`:t}const H8=new Map([["address",{type:"address"}],["bool",{type:"bool"}],["bytes",{type:"bytes"}],["bytes32",{type:"bytes32"}],["int",{type:"int256"}],["int256",{type:"int256"}],["string",{type:"string"}],["uint",{type:"uint256"}],["uint8",{type:"uint8"}],["uint16",{type:"uint16"}],["uint24",{type:"uint24"}],["uint32",{type:"uint32"}],["uint64",{type:"uint64"}],["uint96",{type:"uint96"}],["uint112",{type:"uint112"}],["uint160",{type:"uint160"}],["uint192",{type:"uint192"}],["uint256",{type:"uint256"}],["address owner",{type:"address",name:"owner"}],["address to",{type:"address",name:"to"}],["bool approved",{type:"bool",name:"approved"}],["bytes _data",{type:"bytes",name:"_data"}],["bytes data",{type:"bytes",name:"data"}],["bytes signature",{type:"bytes",name:"signature"}],["bytes32 hash",{type:"bytes32",name:"hash"}],["bytes32 r",{type:"bytes32",name:"r"}],["bytes32 root",{type:"bytes32",name:"root"}],["bytes32 s",{type:"bytes32",name:"s"}],["string name",{type:"string",name:"name"}],["string symbol",{type:"string",name:"symbol"}],["string tokenURI",{type:"string",name:"tokenURI"}],["uint tokenId",{type:"uint256",name:"tokenId"}],["uint8 v",{type:"uint8",name:"v"}],["uint256 balance",{type:"uint256",name:"balance"}],["uint256 tokenId",{type:"uint256",name:"tokenId"}],["uint256 value",{type:"uint256",name:"value"}],["event:address indexed from",{type:"address",name:"from",indexed:!0}],["event:address indexed to",{type:"address",name:"to",indexed:!0}],["event:uint indexed tokenId",{type:"uint256",name:"tokenId",indexed:!0}],["event:uint256 indexed tokenId",{type:"uint256",name:"tokenId",indexed:!0}]]);function F7(t,e={}){if(obe(t)){const r=abe(t);if(!r)throw new Oh({signature:t,type:"function"});const n=es(r.parameters),s=[],i=n.length;for(let f=0;f[a-zA-Z$_][a-zA-Z0-9$_]*)(?(?:\[\d*?\])+?)?(?:\s(?calldata|indexed|memory|storage{1}))?(?:\s(?[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,vbe=/^\((?.+?)\)(?(?:\[\d*?\])+?)?(?:\s(?calldata|indexed|memory|storage{1}))?(?:\s(?[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,xbe=/^u?int$/;function ko(t,e){var v,E;const r=ybe(t,e==null?void 0:e.type);if(H8.has(r))return H8.get(r);const n=CH.test(t),s=qc(n?vbe:bbe,t);if(!s)throw new $H({param:t});if(s.name&&Abe(s.name))throw new FH({param:t,name:s.name});const i=s.name?{name:s.name}:{},o=s.modifier==="indexed"?{indexed:!0}:{},f=(e==null?void 0:e.structs)??{};let h,p={};if(n){h="tuple";const _=es(s.type),S=[],P=_.length;for(let I=0;I[a-zA-Z$_][a-zA-Z0-9$_]*)(?(?:\[\d*?\])+?)?$/;function WH(t,e,r=new Set){const n=[],s=t.length;for(let i=0;i{var s;return((s=t[e.name||r])==null?void 0:s.call(t,n))??e(t,n)}}function Qo(t,{includeName:e=!1}={}){if(t.type!=="function"&&t.type!=="event"&&t.type!=="error")throw new sq(t.type);return`${t.name}(${ow(t.inputs,{includeName:e})})`}function ow(t,{includeName:e=!1}={}){return t?t.map(r=>Ibe(r,{includeName:e})).join(e?", ":","):""}function Ibe(t,{includeName:e}){return t.type.startsWith("tuple")?`(${ow(t.components,{includeName:e})})${t.type.slice(5)}`:t.type+(e&&t.name?` ${t.name}`:"")}function Rt(t,{strict:e=!0}={}){return!t||typeof t!="string"?!1:e?/^0x[0-9a-fA-F]*$/.test(t):t.startsWith("0x")}function Wr(t){return Rt(t,{strict:!1})?Math.ceil((t.length-2)/2):t.length}const Tbe="1.20.0",kbe=t=>t,b1=t=>t,Rbe=()=>`viem@${Tbe}`;class Ue extends Error{constructor(e,r={}){var i;super(),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ViemError"}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:Rbe()});const n=r.cause instanceof Ue?r.cause.details:(i=r.cause)!=null&&i.message?r.cause.message:r.details,s=r.cause instanceof Ue&&r.cause.docsPath||r.docsPath;this.message=[e||"An error occurred.","",...r.metaMessages?[...r.metaMessages,""]:[],...s?[`Docs: https://viem.sh${s}.html${r.docsSlug?`#${r.docsSlug}`:""}`]:[],...n?[`Details: ${n}`]:[],`Version: ${this.version}`].join(` -`),r.cause&&(this.cause=r.cause),this.details=n,this.docsPath=s,this.metaMessages=r.metaMessages,this.shortMessage=e}walk(e){return JH(this,e)}}function JH(t,e){return e!=null&&e(t)?t:t&&typeof t=="object"&&"cause"in t?JH(t.cause,e):e?null:t}class US extends Ue{constructor({docsPath:e}){super(["A constructor was not found on the ABI.","Make sure you are using the correct ABI and that the constructor exists on it."].join(` -`),{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorNotFoundError"})}}class Rg extends Ue{constructor({docsPath:e}){super(["Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.","Make sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists."].join(` -`),{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorParamsNotFoundError"})}}class Bbe extends Ue{constructor({data:e,size:r}){super([`Data size of ${r} bytes is invalid.`,"Size must be in increments of 32 bytes (size % 32 === 0)."].join(` -`),{metaMessages:[`Data: ${e} (${r} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingDataSizeInvalidError"})}}class aw extends Ue{constructor({data:e,params:r,size:n}){super([`Data size of ${n} bytes is too small for given parameters.`].join(` -`),{metaMessages:[`Params: (${ow(r,{includeName:!0})})`,`Data: ${e} (${n} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingDataSizeTooSmallError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=e,this.params=r,this.size=n}}class Zy extends Ue{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingZeroDataError"})}}class ZH extends Ue{constructor({expectedLength:e,givenLength:r,type:n}){super([`ABI encoding array length mismatch for type ${n}.`,`Expected length: ${e}`,`Given length: ${r}`].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}}class QH extends Ue{constructor({expectedSize:e,value:r}){super(`Size of bytes "${r}" (bytes${Wr(r)}) does not match expected size (bytes${e}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}}class zS extends Ue{constructor({expectedLength:e,givenLength:r}){super(["ABI encoding params/values length mismatch.",`Expected length (params): ${e}`,`Given length (values): ${r}`].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}}class YH extends Ue{constructor(e,{docsPath:r}){super([`Arguments (\`args\`) were provided to "${e}", but "${e}" on the ABI does not contain any parameters (\`inputs\`).`,"Cannot encode error result without knowing what the parameter types are.","Make sure you are using the correct ABI and that the inputs exist on it."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorInputsNotFoundError"})}}class U7 extends Ue{constructor(e,{docsPath:r}={}){super([`Error ${e?`"${e}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the error exists on it."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorNotFoundError"})}}class jS extends Ue{constructor(e,{docsPath:r}){super([`Encoded error signature "${e}" not found on ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://openchain.xyz/signatures?query=${e}.`].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorSignatureNotFoundError"}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=e}}class XH extends Ue{constructor({docsPath:e}){super("Cannot extract event signature from empty topics.",{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureEmptyTopicsError"})}}class eq extends Ue{constructor(e,{docsPath:r}){super([`Encoded event signature "${e}" not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it.",`You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureNotFoundError"})}}class z7 extends Ue{constructor(e,{docsPath:r}={}){super([`Event ${e?`"${e}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventNotFoundError"})}}class ml extends Ue{constructor(e,{docsPath:r}={}){super([`Function ${e?`"${e}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}}class HS extends Ue{constructor(e,{docsPath:r}){super([`Function "${e}" does not contain any \`outputs\` on ABI.`,"Cannot decode function result without knowing what the parameter types are.","Make sure you are using the correct ABI and that the function exists on it."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionOutputsNotFoundError"})}}class tq extends Ue{constructor(e,{docsPath:r}){super([`Encoded function signature "${e}" not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it.",`You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionSignatureNotFoundError"})}}class Obe extends Ue{constructor(e,r){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${e.type}\` in \`${Qo(e.abiItem)}\`, and`,`\`${r.type}\` in \`${Qo(r.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItemAmbiguityError"})}}class qS extends Ue{constructor({expectedSize:e,givenSize:r}){super(`Expected bytes${e}, got bytes${r}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}}class Ac extends Ue{constructor({abiItem:e,data:r,params:n,size:s}){super([`Data size of ${s} bytes is too small for non-indexed event parameters.`].join(` -`),{metaMessages:[`Params: (${ow(n,{includeName:!0})})`,`Data: ${r} (${s} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogDataMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=e,this.data=r,this.params=n,this.size=s}}class Nl extends Ue{constructor({abiItem:e,param:r}){super([`Expected a topic for indexed event parameter${r.name?` "${r.name}"`:""} on event "${Qo(e,{includeName:!0})}".`].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=e}}class rq extends Ue{constructor(e,{docsPath:r}){super([`Type "${e}" is not a valid encoding type.`,"Please provide a valid ABI type."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}}class nq extends Ue{constructor(e,{docsPath:r}){super([`Type "${e}" is not a valid decoding type.`,"Please provide a valid ABI type."].join(` -`),{docsPath:r}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiDecodingType"})}}class iq extends Ue{constructor(e){super([`Value "${e}" is not a valid array.`].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}}class sq extends Ue{constructor(e){super([`"${e}" is not a valid definition type.`,'Valid types: "function", "event", "error"'].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}}class oq extends Ue{constructor(e){super(`Type "${e}" is not supported for packed encoding.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedPackedAbiType"})}}class aq extends Ue{constructor(e){super(`Filter type "${e}" is not supported.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FilterTypeNotSupportedError"})}}class GS extends Ue{constructor({offset:e,position:r,size:n}){super(`Slice ${r==="start"?"starting":"ending"} at offset "${e}" is out-of-bounds (size: ${n}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}}class VS extends Ue{constructor({size:e,targetSize:r,type:n}){super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} size (${e}) exceeds padding size (${r}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}}function Uo(t,{dir:e,size:r=32}={}){return typeof t=="string"?zo(t,{dir:e,size:r}):fq(t,{dir:e,size:r})}function zo(t,{dir:e,size:r=32}={}){if(r===null)return t;const n=t.replace("0x","");if(n.length>r*2)throw new VS({size:Math.ceil(n.length/2),targetSize:r,type:"hex"});return`0x${n[e==="right"?"padEnd":"padStart"](r*2,"0")}`}function fq(t,{dir:e,size:r=32}={}){if(r===null)return t;if(t.length>r)throw new VS({size:t.length,targetSize:r,type:"bytes"});const n=new Uint8Array(r);for(let s=0;se)throw new dq({givenSize:Wr(t),maxSize:e})}function $be(t,e){const r=typeof e=="string"?{to:e}:e,n=r.to;return n==="number"?er(t,r):n==="bigint"?Wt(t,r):n==="string"?WS(t,r):n==="boolean"?KS(t,r):i0(t,r)}function Wt(t,e={}){const{signed:r}=e;e.size&&ao(t,{size:e.size});const n=BigInt(t);if(!r)return n;const s=(t.length-2)/2,i=(1n<e.toString(16).padStart(2,"0"));function ut(t,e={}){return typeof t=="number"||typeof t=="bigint"?it(t,e):typeof t=="string"?Qy(t,e):typeof t=="boolean"?fw(t,e):Fi(t,e)}function fw(t,e={}){const r=`0x${Number(t)}`;return typeof e.size=="number"?(ao(r,{size:e.size}),Uo(r,{size:e.size})):r}function Fi(t,e={}){let r="";for(let s=0;si||s=Wa.zero&&t<=Wa.nine)return t-Wa.zero;if(t>=Wa.A&&t<=Wa.F)return t-(Wa.A-10);if(t>=Wa.a&&t<=Wa.f)return t-(Wa.a-10)}function i0(t,e={}){let r=t;e.size&&(ao(r,{size:e.size}),r=Uo(r,{dir:"right",size:e.size}));let n=r.slice(2);n.length%2&&(n=`0${n}`);const s=n.length/2,i=new Uint8Array(s);for(let o=0,f=0;o{const e=(()=>typeof t=="string"?t:tbe(t))();return jbe(e)},gq=t=>JS(t);function _6(t){if(!Number.isSafeInteger(t)||t<0)throw new Error(`Wrong positive integer: ${t}`)}function ZS(t,...e){if(!(t instanceof Uint8Array))throw new Error("Expected Uint8Array");if(e.length>0&&!e.includes(t.length))throw new Error(`Expected Uint8Array of length ${e}, not of length=${t.length}`)}function Hbe(t){if(typeof t!="function"||typeof t.create!="function")throw new Error("Hash should be wrapped by utils.wrapConstructor");_6(t.outputLen),_6(t.blockLen)}function Ip(t,e=!0){if(t.destroyed)throw new Error("Hash instance has been destroyed");if(e&&t.finished)throw new Error("Hash#digest() has already been called")}function yq(t,e){ZS(t);const r=e.outputLen;if(t.length>PR&ev)}:{h:Number(t>>PR&ev)|0,l:Number(t&ev)|0}}function Gbe(t,e=!1){let r=new Uint32Array(t.length),n=new Uint32Array(t.length);for(let s=0;st<>>32-r,Kbe=(t,e,r)=>e<>>32-r,Wbe=(t,e,r)=>e<>>64-r,Jbe=(t,e,r)=>t<>>64-r,q8=typeof globalThis=="object"&&"crypto"in globalThis?globalThis.crypto:void 0;/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */const bq=t=>t instanceof Uint8Array,Zbe=t=>new Uint32Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/4)),G8=t=>new DataView(t.buffer,t.byteOffset,t.byteLength),fa=(t,e)=>t<<32-e|t>>>e,Qbe=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;if(!Qbe)throw new Error("Non little-endian hardware is not supported");function Ybe(t){if(typeof t!="string")throw new Error(`utf8ToBytes expected string, got ${typeof t}`);return new Uint8Array(new TextEncoder().encode(t))}function cw(t){if(typeof t=="string"&&(t=Ybe(t)),!bq(t))throw new Error(`expected Uint8Array, got ${typeof t}`);return t}function Xbe(...t){const e=new Uint8Array(t.reduce((n,s)=>n+s.length,0));let r=0;return t.forEach(n=>{if(!bq(n))throw new Error("Uint8Array expected");e.set(n,r),r+=n.length}),e}class QS{clone(){return this._cloneInto()}}function YS(t){const e=n=>t().update(cw(n)).digest(),r=t();return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=()=>t(),e}function vq(t=32){if(q8&&typeof q8.getRandomValues=="function")return q8.getRandomValues(new Uint8Array(t));throw new Error("crypto.getRandomValues must be defined")}const[xq,wq,Aq]=[[],[],[]],eve=BigInt(0),nm=BigInt(1),tve=BigInt(2),rve=BigInt(7),nve=BigInt(256),ive=BigInt(113);for(let t=0,e=nm,r=1,n=0;t<24;t++){[r,n]=[n,(2*r+3*n)%5],xq.push(2*(5*n+r)),wq.push((t+1)*(t+2)/2%64);let s=eve;for(let i=0;i<7;i++)e=(e<>rve)*ive)%nve,e&tve&&(s^=nm<<(nm<r>32?Wbe(t,e,r):Vbe(t,e,r),IR=(t,e,r)=>r>32?Jbe(t,e,r):Kbe(t,e,r);function ave(t,e=24){const r=new Uint32Array(10);for(let n=24-e;n<24;n++){for(let o=0;o<10;o++)r[o]=t[o]^t[o+10]^t[o+20]^t[o+30]^t[o+40];for(let o=0;o<10;o+=2){const f=(o+8)%10,h=(o+2)%10,p=r[h],b=r[h+1],v=CR(p,b,1)^r[f],E=IR(p,b,1)^r[f+1];for(let _=0;_<50;_+=10)t[o+_]^=v,t[o+_+1]^=E}let s=t[2],i=t[3];for(let o=0;o<24;o++){const f=wq[o],h=CR(s,i,f),p=IR(s,i,f),b=xq[o];s=t[b],i=t[b+1],t[b]=h,t[b+1]=p}for(let o=0;o<50;o+=10){for(let f=0;f<10;f++)r[f]=t[o+f];for(let f=0;f<10;f++)t[o+f]^=~r[(f+2)%10]&r[(f+4)%10]}t[0]^=sve[n],t[1]^=ove[n]}r.fill(0)}class XS extends QS{constructor(e,r,n,s=!1,i=24){if(super(),this.blockLen=e,this.suffix=r,this.outputLen=n,this.enableXOF=s,this.rounds=i,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,_6(n),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=Zbe(this.state)}keccak(){ave(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){Ip(this);const{blockLen:r,state:n}=this;e=cw(e);const s=e.length;for(let i=0;i=n&&this.keccak();const o=Math.min(n-this.posOut,i-s);e.set(r.subarray(this.posOut,this.posOut+o),s),this.posOut+=o,s+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return _6(e),this.xofInto(new Uint8Array(e))}digestInto(e){if(yq(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(e){const{blockLen:r,suffix:n,outputLen:s,rounds:i,enableXOF:o}=this;return e||(e=new XS(r,n,s,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=n,e.outputLen=s,e.enableXOF=o,e.destroyed=this.destroyed,e}}const fve=(t,e,r)=>YS(()=>new XS(e,t,r)),cve=fve(1,136,256/8);function zr(t,e){const r=e||"hex",n=cve(Rt(t,{strict:!1})?vn(t):t);return r==="bytes"?n:ut(n)}const uve=t=>zr(vn(t)),uw=t=>uve(gq(t));class un extends Ue{constructor({address:e}){super(`Address "${e}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}}const lve=/^0x[a-fA-F0-9]{40}$/;function wr(t){return lve.test(t)}function cs(t){return typeof t[0]=="string"?fo(t):Eq(t)}function Eq(t){let e=0;for(const s of t)e+=s.length;const r=new Uint8Array(e);let n=0;for(const s of t)r.set(s,n),n+=s.length;return r}function fo(t){return`0x${t.reduce((e,r)=>e+r.replace("0x",""),"")}`}function Sr(t,e,r,{strict:n}={}){return Rt(t,{strict:!1})?e_(t,e,r,{strict:n}):_q(t,e,r,{strict:n})}function Mq(t,e){if(typeof e=="number"&&e>0&&e>Wr(t)-1)throw new GS({offset:e,position:"start",size:Wr(t)})}function Sq(t,e,r){if(typeof e=="number"&&typeof r=="number"&&Wr(t)!==r-e)throw new GS({offset:r,position:"end",size:Wr(t)})}function _q(t,e,r,{strict:n}={}){Mq(t,e);const s=t.slice(e,r);return n&&Sq(s,e,r),s}function e_(t,e,r,{strict:n}={}){Mq(t,e);const s=`0x${t.replace("0x","").slice((e??0)*2,(r??t.length)*2)}`;return n&&Sq(s,e,r),s}function s0(t,e){if(t.length!==e.length)throw new zS({expectedLength:t.length,givenLength:e.length});const r=hve({params:t,values:e}),n=r_(r);return n.length===0?"0x":n}function hve({params:t,values:e}){const r=[];for(let n=0;n0?cs([f,o]):f}}if(s)return{dynamic:!0,encoded:o}}return{dynamic:!1,encoded:cs(i.map(({encoded:o})=>o))}}function mve(t,{param:e}){const[,r]=e.type.split("bytes"),n=Wr(t);if(!r){let s=t;return n%32!==0&&(s=zo(s,{dir:"right",size:Math.ceil((t.length-2)/2/32)*32})),{dynamic:!0,encoded:cs([zo(it(n,{size:32})),s])}}if(n!==parseInt(r))throw new QH({expectedSize:parseInt(r),value:t});return{dynamic:!1,encoded:zo(t,{dir:"right"})}}function gve(t){return{dynamic:!1,encoded:zo(fw(t))}}function yve(t,{signed:e}){return{dynamic:!1,encoded:it(t,{size:32,signed:e})}}function bve(t){const e=Qy(t),r=Math.ceil(Wr(e)/32),n=[];for(let s=0;ss))}}function lw(t){const e=t.match(/^(.*)\[(\d+)?\]$/);return e?[e[2]?Number(e[2]):null,e[1]]:void 0}const xve=t=>zr(vn(t)),v1=t=>Sr(xve(JS(t)),0,4);function Gc({abi:t,args:e=[],name:r}){const n=Rt(r,{strict:!1}),s=t.filter(o=>n?o.type==="function"?v1(o)===r:o.type==="event"?uw(o)===r:!1:"name"in o&&o.name===r);if(s.length===0)return;if(s.length===1)return s[0];let i;for(const o of s){if(!("inputs"in o))continue;if(!e||e.length===0){if(!o.inputs||o.inputs.length===0)return o;continue}if(!o.inputs||o.inputs.length===0||o.inputs.length!==e.length)continue;if(e.every((h,p)=>{const b="inputs"in o&&o.inputs[p];return b?j7(h,b):!1})){if(i&&"inputs"in i&&i.inputs){const h=Pq(o.inputs,i.inputs,e);if(h)throw new Obe({abiItem:o,type:h[0]},{abiItem:i,type:h[1]})}i=o}}return i||s[0]}function j7(t,e){const r=typeof t,n=e.type;switch(n){case"address":return wr(t);case"bool":return r==="boolean";case"function":return r==="string";case"string":return r==="string";default:return n==="tuple"&&"components"in e?Object.values(e.components).every((s,i)=>j7(Object.values(t)[i],s)):/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/.test(n)?r==="number"||r==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(n)?r==="string"||t instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(n)?Array.isArray(t)&&t.every(s=>j7(s,{...e,type:n.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function Pq(t,e,r){for(const n in t){const s=t[n],i=e[n];if(s.type==="tuple"&&i.type==="tuple"&&"components"in s&&"components"in i)return Pq(s.components,i.components,r[n]);const o=[s.type,i.type];if((()=>o.includes("address")&&o.includes("bytes20")?!0:o.includes("address")&&o.includes("string")||o.includes("address")&&o.includes("bytes")?wr(r[n]):!1)())return o}}function x1({abi:t,eventName:e,args:r}){var f;let n=t[0];if(e&&(n=Gc({abi:t,args:r,name:e}),!n))throw new z7(e,{docsPath:"/docs/contract/encodeEventTopics"});if(n.type!=="event")throw new z7(void 0,{docsPath:"/docs/contract/encodeEventTopics"});const s=Qo(n),i=uw(s);let o=[];if(r&&"inputs"in n){const h=(f=n.inputs)==null?void 0:f.filter(b=>"indexed"in b&&b.indexed),p=Array.isArray(r)?r:Object.values(r).length>0?(h==null?void 0:h.map(b=>r[b.name]))??[]:[];p.length>0&&(o=(h==null?void 0:h.map((b,v)=>Array.isArray(p[v])?p[v].map((E,_)=>TR({param:b,value:p[v][_]})):p[v]?TR({param:b,value:p[v]}):null))??[])}return[i,...o]}function TR({param:t,value:e}){if(t.type==="string"||t.type==="bytes")return zr(vn(e));if(t.type==="tuple"||t.type.match(/^(.*)\[(\d+)?\]$/))throw new aq(t.type);return s0([t],[e])}function hw(t,{method:e}){var n,s;const r={};return t.transport.type==="fallback"&&((s=(n=t.transport).onResponse)==null||s.call(n,({method:i,response:o,status:f,transport:h})=>{f==="success"&&e===i&&(r[o]=h.request)})),i=>r[i]||t.request}async function n_(t,{address:e,abi:r,args:n,eventName:s,fromBlock:i,strict:o,toBlock:f}){const h=hw(t,{method:"eth_newFilter"}),p=s?x1({abi:r,args:n,eventName:s}):void 0,b=await t.request({method:"eth_newFilter",params:[{address:e,fromBlock:typeof i=="bigint"?it(i):i,toBlock:typeof f=="bigint"?it(f):f,topics:p}]});return{abi:r,args:n,eventName:s,id:b,request:h(b),strict:o,type:"event"}}function co(t){return typeof t=="string"?{address:t,type:"json-rpc"}:t}function mi({abi:t,args:e,functionName:r}){let n=t[0];if(r&&(n=Gc({abi:t,args:e,name:r}),!n))throw new ml(r,{docsPath:"/docs/contract/encodeFunctionData"});if(n.type!=="function")throw new ml(void 0,{docsPath:"/docs/contract/encodeFunctionData"});const s=Qo(n),i=v1(s),o="inputs"in n&&n.inputs?s0(n.inputs,e??[]):void 0;return fo([i,o??"0x"])}const Cq={1:"An `assert` condition failed.",17:"Arithmic operation resulted in underflow or overflow.",18:"Division or modulo by zero (e.g. `5 / 0` or `23 % 0`).",33:"Attempted to convert to an invalid type.",34:"Attempted to access a storage byte array that is incorrectly encoded.",49:"Performed `.pop()` on an empty array",50:"Array index is out of bounds.",65:"Allocated too much memory or created an array which is too large.",81:"Attempted to call a zero-initialized variable of internal function type."},wve={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},Ave={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"};function Yy(t,e){const r=e?`${e}${t.toLowerCase()}`:t.substring(2).toLowerCase(),n=zr(Ra(r),"bytes"),s=(e?r.substring(`${e}0x`.length):r).split("");for(let i=0;i<40;i+=2)n[i>>1]>>4>=8&&s[i]&&(s[i]=s[i].toUpperCase()),(n[i>>1]&15)>=8&&s[i+1]&&(s[i+1]=s[i+1].toUpperCase());return`0x${s.join("")}`}function Ec(t,e){if(!wr(t))throw new un({address:t});return Yy(t,e)}function Ll(t,e){if(e==="0x"&&t.length>0)throw new Zy;if(Wr(e)&&Wr(e)<32)throw new aw({data:e,params:t,size:Wr(e)});return Eve({data:e,params:t})}function Eve({data:t,params:e}){const r=[];let n=0;for(let s=0;s=Wr(t))throw new aw({data:t,params:e,size:Wr(t)});const i=e[s],{consumed:o,value:f}=nd({data:t,param:i,position:n});r.push(f),n+=o}return r}function nd({data:t,param:e,position:r}){const n=lw(e.type);if(n){const[i,o]=n;return Sve(t,{length:i,param:{...e,type:o},position:r})}if(e.type==="tuple")return Tve(t,{param:e,position:r});if(e.type==="string")return Ive(t,{position:r});if(e.type.startsWith("bytes"))return Pve(t,{param:e,position:r});const s=Sr(t,r,r+32,{strict:!0});if(e.type.startsWith("uint")||e.type.startsWith("int"))return Cve(s,{param:e});if(e.type==="address")return Mve(s);if(e.type==="bool")return _ve(s);throw new nq(e.type,{docsPath:"/docs/contract/decodeAbiParameters"})}function Mve(t){return{consumed:32,value:Yy(Sr(t,-20))}}function Sve(t,{param:e,length:r,position:n}){if(!r){const o=er(Sr(t,n,n+32,{strict:!0})),f=er(Sr(t,o,o+32,{strict:!0}));let h=0;const p=[];for(let b=0;b48?Wt(t,{signed:r}):er(t,{signed:r})}}function Ive(t,{position:e}){const r=er(Sr(t,e,e+32,{strict:!0})),n=er(Sr(t,r,r+32,{strict:!0}));return n===0?{consumed:32,value:""}:{consumed:32,value:WS(rn(Sr(t,r+32,r+32+n,{strict:!0})))}}function Tve(t,{param:e,position:r}){const n=e.components.length===0||e.components.some(({name:o})=>!o),s=n?[]:{};let i=0;if(P6(e)){const o=er(Sr(t,r,r+32,{strict:!0}));for(let f=0;fi.type==="error"&&r===v1(Qo(i)));if(!s)throw new jS(r,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:s,args:"inputs"in s&&s.inputs&&s.inputs.length>0?Ll(s.inputs,Sr(e,4)):void 0,errorName:s.name}}const cn=(t,e,r)=>JSON.stringify(t,(n,s)=>{const i=typeof s=="bigint"?s.toString():s;return typeof e=="function"?e(n,i):i},r);function Iq({abiItem:t,args:e,includeFunctionName:r=!0,includeName:n=!1}){if("name"in t&&"inputs"in t&&t.inputs)return`${r?t.name:""}(${t.inputs.map((s,i)=>`${n&&s.name?`${s.name}: `:""}${typeof e[i]=="object"?cn(e[i]):e[i]}`).join(", ")})`}const s_={gwei:9,wei:18},o_={ether:-9,wei:9},kve={ether:-18,gwei:-9};function a_(t,e){let r=t.toString();const n=r.startsWith("-");n&&(r=r.slice(1)),r=r.padStart(e,"0");let[s,i]=[r.slice(0,r.length-e),r.slice(r.length-e)];return i=i.replace(/(0+)$/,""),`${n?"-":""}${s||"0"}${i?`.${i}`:""}`}function Dl(t,e="wei"){return a_(t,s_[e])}function li(t,e="wei"){return a_(t,o_[e])}function Xy(t){const e=Object.entries(t).map(([n,s])=>s===void 0||s===!1?null:[n,s]).filter(Boolean),r=e.reduce((n,[s])=>Math.max(n,s.length),0);return e.map(([n,s])=>` ${`${n}:`.padEnd(r+1)} ${s}`).join(` -`)}class Tq extends Ue{constructor(){super(["Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.","Use `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeConflictError"})}}class f_ extends Ue{constructor({v:e}){super(`Invalid \`v\` value "${e}". Expected 27 or 28.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidLegacyVError"})}}class kq extends Ue{constructor({transaction:e}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",Xy(e),"}","","To infer the type, either provide:","- a `type` to the Transaction, or","- an EIP-1559 Transaction with `maxFeePerGas`, or","- an EIP-2930 Transaction with `gasPrice` & `accessList`, or","- a Legacy Transaction with `gasPrice`"]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSerializableTransactionError"})}}class Rq extends Ue{constructor({serializedType:e}){super(`Serialized transaction type "${e}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSerializedTransactionType"}),Object.defineProperty(this,"serializedType",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.serializedType=e}}class dw extends Ue{constructor({attributes:e,serializedTransaction:r,type:n}){const s=Object.entries(e).map(([i,o])=>typeof o>"u"?i:void 0).filter(Boolean);super(`Invalid serialized transaction of type "${n}" was provided.`,{metaMessages:[`Serialized Transaction: "${r}"`,s.length>0?`Missing Attributes: ${s.join(", ")}`:""].filter(Boolean)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSerializedTransactionError"}),Object.defineProperty(this,"serializedTransaction",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"type",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.serializedTransaction=r,this.type=n}}class Bq extends Ue{constructor({storageKey:e}){super(`Size for storage key "${e}" is invalid. Expected 32 bytes. Got ${Math.floor((e.length-2)/2)} bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidStorageKeySizeError"})}}class Oq extends Ue{constructor(e,{account:r,docsPath:n,chain:s,data:i,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E}){var S;const _=Xy({chain:s&&`${s==null?void 0:s.name} (id: ${s==null?void 0:s.id})`,from:r==null?void 0:r.address,to:v,value:typeof E<"u"&&`${Dl(E)} ${((S=s==null?void 0:s.nativeCurrency)==null?void 0:S.symbol)||"ETH"}`,data:i,gas:o,gasPrice:typeof f<"u"&&`${li(f)} gwei`,maxFeePerGas:typeof h<"u"&&`${li(h)} gwei`,maxPriorityFeePerGas:typeof p<"u"&&`${li(p)} gwei`,nonce:b});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Request Arguments:",_].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionExecutionError"}),this.cause=e}}class c_ extends Ue{constructor({blockHash:e,blockNumber:r,blockTag:n,hash:s,index:i}){let o="Transaction";n&&i!==void 0&&(o=`Transaction at block time "${n}" at index "${i}"`),e&&i!==void 0&&(o=`Transaction at block hash "${e}" at index "${i}"`),r&&i!==void 0&&(o=`Transaction at block number "${r}" at index "${i}"`),s&&(o=`Transaction with hash "${s}"`),super(`${o} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionNotFoundError"})}}class u_ extends Ue{constructor({hash:e}){super(`Transaction receipt with hash "${e}" could not be found. The Transaction may not be processed on a block yet.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionReceiptNotFoundError"})}}class Nq extends Ue{constructor({hash:e}){super(`Timed out while waiting for transaction with hash "${e}" to be confirmed.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WaitForTransactionReceiptTimeoutError"})}}class l_ extends Ue{constructor(e,{account:r,docsPath:n,chain:s,data:i,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E}){var P;const _=r?co(r):void 0,S=Xy({from:_==null?void 0:_.address,to:v,value:typeof E<"u"&&`${Dl(E)} ${((P=s==null?void 0:s.nativeCurrency)==null?void 0:P.symbol)||"ETH"}`,data:i,gas:o,gasPrice:typeof f<"u"&&`${li(f)} gwei`,maxFeePerGas:typeof h<"u"&&`${li(h)} gwei`,maxPriorityFeePerGas:typeof p<"u"&&`${li(p)} gwei`,nonce:b});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Raw Call Arguments:",S].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"CallExecutionError"}),this.cause=e}}class Lq extends Ue{constructor(e,{abi:r,args:n,contractAddress:s,docsPath:i,functionName:o,sender:f}){const h=Gc({abi:r,args:n,name:o}),p=h?Iq({abiItem:h,args:n,includeFunctionName:!1,includeName:!1}):void 0,b=h?Qo(h,{includeName:!0}):void 0,v=Xy({address:s&&kbe(s),function:b,args:p&&p!=="()"&&`${[...Array((o==null?void 0:o.length)??0).keys()].map(()=>" ").join("")}${p}`,sender:f});super(e.shortMessage||`An unknown error occurred while executing the contract function "${o}".`,{cause:e,docsPath:i,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Contract Call:",v].filter(Boolean)}),Object.defineProperty(this,"abi",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"args",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"contractAddress",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"formattedArgs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"functionName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sender",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionExecutionError"}),this.abi=r,this.args=n,this.cause=e,this.contractAddress=s,this.functionName=o,this.sender=f}}class C6 extends Ue{constructor({abi:e,data:r,functionName:n,message:s}){let i,o,f,h;if(r&&r!=="0x")try{o=i_({abi:e,data:r});const{abiItem:b,errorName:v,args:E}=o;if(v==="Error")h=E[0];else if(v==="Panic"){const[_]=E;h=Cq[_]}else{const _=b?Qo(b,{includeName:!0}):void 0,S=b&&E?Iq({abiItem:b,args:E,includeFunctionName:!1,includeName:!1}):void 0;f=[_?`Error: ${_}`:"",S&&S!=="()"?` ${[...Array((v==null?void 0:v.length)??0).keys()].map(()=>" ").join("")}${S}`:""]}}catch(b){i=b}else s&&(h=s);let p;i instanceof jS&&(p=i.signature,f=[`Unable to decode signature "${p}" as it was not found on the provided ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://openchain.xyz/signatures?query=${p}.`]),super(h&&h!=="execution reverted"||p?[`The contract function "${n}" reverted with the following ${p?"signature":"reason"}:`,h||p].join(` -`):`The contract function "${n}" reverted.`,{cause:i,metaMessages:f}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"reason",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=o,this.reason=h,this.signature=p}}class Dq extends Ue{constructor({functionName:e}){super(`The contract function "${e}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",` - The contract does not have the function "${e}",`," - The parameters passed to the contract function may be invalid, or"," - The address is not a contract."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionZeroDataError"})}}class pw extends Ue{constructor({data:e,message:r}){super(r||""),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RawContractError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=e}}class dc extends Ue{constructor({body:e,details:r,headers:n,status:s,url:i}){super("HTTP request failed.",{details:r,metaMessages:[s&&`Status: ${s}`,`URL: ${b1(i)}`,e&&`Request body: ${cn(e)}`].filter(Boolean)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"HttpRequestError"}),Object.defineProperty(this,"body",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"headers",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"status",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.body=e,this.headers=n,this.status=s,this.url=i}}class $q extends Ue{constructor({body:e,details:r,url:n}){super("WebSocket request failed.",{details:r,metaMessages:[`URL: ${b1(n)}`,`Request body: ${cn(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WebSocketRequestError"})}}class mw extends Ue{constructor({body:e,error:r,url:n}){super("RPC Request failed.",{cause:r,details:r.message,metaMessages:[`URL: ${b1(n)}`,`Request body: ${cn(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=r.code}}class I6 extends Ue{constructor({body:e,url:r}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${b1(r)}`,`Request body: ${cn(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TimeoutError"})}}const Rve=-1;class vi extends Ue{constructor(e,{code:r,docsPath:n,metaMessages:s,shortMessage:i}){super(i,{cause:e,docsPath:n,metaMessages:s||(e==null?void 0:e.metaMessages)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=e.name,this.code=e instanceof mw?e.code:r??Rve}}class $l extends vi{constructor(e,r){super(e,r),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderRpcError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=r.data}}class Tp extends vi{constructor(e){super(e,{code:Tp.code,shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ParseRpcError"})}}Object.defineProperty(Tp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});class kp extends vi{constructor(e){super(e,{code:kp.code,shortMessage:"JSON is not a valid request object."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidRequestRpcError"})}}Object.defineProperty(kp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});class Rp extends vi{constructor(e){super(e,{code:Rp.code,shortMessage:"The method does not exist / is not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotFoundRpcError"})}}Object.defineProperty(Rp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});class Bp extends vi{constructor(e){super(e,{code:Bp.code,shortMessage:["Invalid parameters were provided to the RPC method.","Double check you have provided the correct parameters."].join(` -`)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParamsRpcError"})}}Object.defineProperty(Bp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});class gl extends vi{constructor(e){super(e,{code:gl.code,shortMessage:"An internal error was received."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InternalRpcError"})}}Object.defineProperty(gl,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});class Mc extends vi{constructor(e){super(e,{code:Mc.code,shortMessage:["Missing or invalid parameters.","Double check you have provided the correct parameters."].join(` -`)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidInputRpcError"})}}Object.defineProperty(Mc,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});class Op extends vi{constructor(e){super(e,{code:Op.code,shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}}Object.defineProperty(Op,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});class Np extends vi{constructor(e){super(e,{code:Np.code,shortMessage:"Requested resource not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceUnavailableRpcError"})}}Object.defineProperty(Np,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});class Lp extends vi{constructor(e){super(e,{code:Lp.code,shortMessage:"Transaction creation failed."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionRejectedRpcError"})}}Object.defineProperty(Lp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});class Dp extends vi{constructor(e){super(e,{code:Dp.code,shortMessage:"Method is not implemented."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotSupportedRpcError"})}}Object.defineProperty(Dp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});class $p extends vi{constructor(e){super(e,{code:$p.code,shortMessage:"Request exceeds defined limit."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"LimitExceededRpcError"})}}Object.defineProperty($p,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});class Fp extends vi{constructor(e){super(e,{code:Fp.code,shortMessage:"Version of JSON-RPC protocol is not supported."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"JsonRpcVersionUnsupportedError"})}}Object.defineProperty(Fp,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});class Ju extends $l{constructor(e){super(e,{code:Ju.code,shortMessage:"User rejected the request."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UserRejectedRequestError"})}}Object.defineProperty(Ju,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});class Up extends $l{constructor(e){super(e,{code:Up.code,shortMessage:"The requested method and/or account has not been authorized by the user."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnauthorizedProviderError"})}}Object.defineProperty(Up,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});class zp extends $l{constructor(e){super(e,{code:zp.code,shortMessage:"The Provider does not support the requested method."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedProviderMethodError"})}}Object.defineProperty(zp,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});class jp extends $l{constructor(e){super(e,{code:jp.code,shortMessage:"The Provider is disconnected from all chains."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderDisconnectedError"})}}Object.defineProperty(jp,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});class Hp extends $l{constructor(e){super(e,{code:Hp.code,shortMessage:"The Provider is not connected to the requested chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDisconnectedError"})}}Object.defineProperty(Hp,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});class qp extends $l{constructor(e){super(e,{code:qp.code,shortMessage:"An error occurred when attempting to switch chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SwitchChainError"})}}Object.defineProperty(qp,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});class Fq extends vi{constructor(e){super(e,{shortMessage:"An unknown RPC error occurred."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownRpcError"})}}const Bve=3;function Gp(t,{abi:e,address:r,args:n,docsPath:s,functionName:i,sender:o}){const{code:f,data:h,message:p,shortMessage:b}=t instanceof pw?t:t instanceof Ue?t.walk(E=>"data"in E)||t.walk():{},v=(()=>t instanceof Zy?new Dq({functionName:i}):[Bve,gl.code].includes(f)&&(h||p||b)?new C6({abi:e,data:typeof h=="object"?h.data:h,functionName:i,message:b??p}):t)();return new Lq(v,{abi:e,args:n,contractAddress:r,docsPath:s,functionName:i,sender:o})}class w1 extends Ue{constructor({docsPath:e}={}){super(["Could not find an Account to execute with this Action.","Please provide an Account with the `account` argument on the Action, or by supplying an `account` to the WalletClient."].join(` -`),{docsPath:e,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountNotFoundError"})}}class Uq extends Ue{constructor(e,{account:r,docsPath:n,chain:s,data:i,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E}){var S;const _=Xy({from:r==null?void 0:r.address,to:v,value:typeof E<"u"&&`${Dl(E)} ${((S=s==null?void 0:s.nativeCurrency)==null?void 0:S.symbol)||"ETH"}`,data:i,gas:o,gasPrice:typeof f<"u"&&`${li(f)} gwei`,maxFeePerGas:typeof h<"u"&&`${li(h)} gwei`,maxPriorityFeePerGas:typeof p<"u"&&`${li(p)} gwei`,nonce:b});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Estimate Gas Arguments:",_].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EstimateGasExecutionError"}),this.cause=e}}class mu extends Ue{constructor({cause:e,message:r}={}){var s;const n=(s=r==null?void 0:r.replace("execution reverted: ",""))==null?void 0:s.replace("execution reverted","");super(`Execution reverted ${n?`with reason: ${n}`:"for an unknown reason"}.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ExecutionRevertedError"})}}Object.defineProperty(mu,"code",{enumerable:!0,configurable:!0,writable:!0,value:3});Object.defineProperty(mu,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/});class $a extends Ue{constructor({cause:e,maxFeePerGas:r}={}){super(`The fee cap (\`maxFeePerGas\`${r?` = ${li(r)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooHigh"})}}Object.defineProperty($a,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});class T6 extends Ue{constructor({cause:e,maxFeePerGas:r}={}){super(`The fee cap (\`maxFeePerGas\`${r?` = ${li(r)}`:""} gwei) cannot be lower than the block base fee.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooLow"})}}Object.defineProperty(T6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/});class k6 extends Ue{constructor({cause:e,nonce:r}={}){super(`Nonce provided for the transaction ${r?`(${r}) `:""}is higher than the next one expected.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooHighError"})}}Object.defineProperty(k6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});class R6 extends Ue{constructor({cause:e,nonce:r}={}){super([`Nonce provided for the transaction ${r?`(${r}) `:""}is lower than the current nonce of the account.`,"Try increasing the nonce or find the latest nonce with `getTransactionCount`."].join(` -`),{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooLowError"})}}Object.defineProperty(R6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});class B6 extends Ue{constructor({cause:e,nonce:r}={}){super(`Nonce provided for the transaction ${r?`(${r}) `:""}exceeds the maximum allowed nonce.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceMaxValueError"})}}Object.defineProperty(B6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});class O6 extends Ue{constructor({cause:e}={}){super(["The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."].join(` -`),{cause:e,metaMessages:["This error could arise when the account does not have enough funds to:"," - pay for the total gas fee,"," - pay for the value to send."," ","The cost of the transaction is calculated as `gas * gas fee + value`, where:"," - `gas` is the amount of gas needed for transaction to execute,"," - `gas fee` is the gas fee,"," - `value` is the amount of ether to send to the recipient."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InsufficientFundsError"})}}Object.defineProperty(O6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds/});class N6 extends Ue{constructor({cause:e,gas:r}={}){super(`The amount of gas ${r?`(${r}) `:""}provided for the transaction exceeds the limit allowed for the block.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooHighError"})}}Object.defineProperty(N6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});class L6 extends Ue{constructor({cause:e,gas:r}={}){super(`The amount of gas ${r?`(${r}) `:""}provided for the transaction is too low.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooLowError"})}}Object.defineProperty(L6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});class D6 extends Ue{constructor({cause:e}){super("The transaction type is not supported for this chain.",{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionTypeNotSupportedError"})}}Object.defineProperty(D6,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});class Sc extends Ue{constructor({cause:e,maxPriorityFeePerGas:r,maxFeePerGas:n}={}){super([`The provided tip (\`maxPriorityFeePerGas\`${r?` = ${li(r)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${n?` = ${li(n)} gwei`:""}).`].join(` -`),{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TipAboveFeeCapError"})}}Object.defineProperty(Sc,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});class eb extends Ue{constructor({cause:e}){super(`An error occurred while executing: ${e==null?void 0:e.shortMessage}`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownNodeError"})}}function h_(t,e){const r=(t.details||"").toLowerCase(),n=t.walk(s=>s.code===mu.code);return n instanceof Ue?new mu({cause:t,message:n.details}):mu.nodeMessage.test(r)?new mu({cause:t,message:t.details}):$a.nodeMessage.test(r)?new $a({cause:t,maxFeePerGas:e==null?void 0:e.maxFeePerGas}):T6.nodeMessage.test(r)?new T6({cause:t,maxFeePerGas:e==null?void 0:e.maxFeePerGas}):k6.nodeMessage.test(r)?new k6({cause:t,nonce:e==null?void 0:e.nonce}):R6.nodeMessage.test(r)?new R6({cause:t,nonce:e==null?void 0:e.nonce}):B6.nodeMessage.test(r)?new B6({cause:t,nonce:e==null?void 0:e.nonce}):O6.nodeMessage.test(r)?new O6({cause:t}):N6.nodeMessage.test(r)?new N6({cause:t,gas:e==null?void 0:e.gas}):L6.nodeMessage.test(r)?new L6({cause:t,gas:e==null?void 0:e.gas}):D6.nodeMessage.test(r)?new D6({cause:t}):Sc.nodeMessage.test(r)?new Sc({cause:t,maxFeePerGas:e==null?void 0:e.maxFeePerGas,maxPriorityFeePerGas:e==null?void 0:e.maxPriorityFeePerGas}):new eb({cause:t})}function Ove(t,{docsPath:e,...r}){const n=(()=>{const s=h_(t,r);return s instanceof eb?t:s})();return new Uq(n,{docsPath:e,...r})}function gw(t,{format:e}){if(!e)return{};const r={};function n(i){const o=Object.keys(i);for(const f of o)f in t&&(r[f]=t[f]),i[f]&&typeof i[f]=="object"&&!Array.isArray(i[f])&&n(i[f])}const s=e(t||{});return n(s),r}function yw(t,e){return({exclude:r,format:n})=>({exclude:r,format:s=>{const i=e(s);if(r)for(const o of r)delete i[o];return{...i,...n(s)}},type:t})}const zq={legacy:"0x0",eip2930:"0x1",eip1559:"0x2"};function Fl(t){return{...t,gas:typeof t.gas<"u"?it(t.gas):void 0,gasPrice:typeof t.gasPrice<"u"?it(t.gasPrice):void 0,maxFeePerGas:typeof t.maxFeePerGas<"u"?it(t.maxFeePerGas):void 0,maxPriorityFeePerGas:typeof t.maxPriorityFeePerGas<"u"?it(t.maxPriorityFeePerGas):void 0,nonce:typeof t.nonce<"u"?it(t.nonce):void 0,type:typeof t.type<"u"?zq[t.type]:void 0,value:typeof t.value<"u"?it(t.value):void 0}}const jq=yw("transactionRequest",Fl);function A1(t){const{account:e,gasPrice:r,maxFeePerGas:n,maxPriorityFeePerGas:s,to:i}=t,o=e?co(e):void 0;if(o&&!wr(o.address))throw new un({address:o.address});if(i&&!wr(i))throw new un({address:i});if(typeof r<"u"&&(typeof n<"u"||typeof s<"u"))throw new Tq;if(n&&n>2n**256n-1n)throw new $a({maxFeePerGas:n});if(s&&n&&s>n)throw new Sc({maxFeePerGas:n,maxPriorityFeePerGas:s})}class Hq extends Ue{constructor(){super("`baseFeeMultiplier` must be greater than 1."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseFeeScalarError"})}}class bw extends Ue{constructor(){super("Chain does not support EIP-1559 fees."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Eip1559FeesNotSupportedError"})}}class qq extends Ue{constructor({maxPriorityFeePerGas:e}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${li(e)} gwei).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MaxFeePerGasTooLowError"})}}class d_ extends Ue{constructor({blockHash:e,blockNumber:r}){let n="Block";e&&(n=`Block at hash "${e}"`),r&&(n=`Block at number "${r}"`),super(`${n} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlockNotFoundError"})}}const p_={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559"};function E1(t){const e={...t,blockHash:t.blockHash?t.blockHash:null,blockNumber:t.blockNumber?BigInt(t.blockNumber):null,chainId:t.chainId?er(t.chainId):void 0,gas:t.gas?BigInt(t.gas):void 0,gasPrice:t.gasPrice?BigInt(t.gasPrice):void 0,maxFeePerGas:t.maxFeePerGas?BigInt(t.maxFeePerGas):void 0,maxPriorityFeePerGas:t.maxPriorityFeePerGas?BigInt(t.maxPriorityFeePerGas):void 0,nonce:t.nonce?er(t.nonce):void 0,to:t.to?t.to:null,transactionIndex:t.transactionIndex?Number(t.transactionIndex):null,type:t.type?p_[t.type]:void 0,typeHex:t.type?t.type:void 0,value:t.value?BigInt(t.value):void 0,v:t.v?BigInt(t.v):void 0};return e.yParity=(()=>{if(t.yParity)return Number(t.yParity);if(typeof e.v=="bigint"){if(e.v===0n||e.v===27n)return 0;if(e.v===1n||e.v===28n)return 1;if(e.v>=35n)return e.v%2n===0n?1:0}})(),e.type==="legacy"&&(delete e.accessList,delete e.maxFeePerGas,delete e.maxPriorityFeePerGas,delete e.yParity),e.type==="eip2930"&&(delete e.maxFeePerGas,delete e.maxPriorityFeePerGas),e}const m_=yw("transaction",E1);function vw(t){var r;const e=(r=t.transactions)==null?void 0:r.map(n=>typeof n=="string"?n:E1(n));return{...t,baseFeePerGas:t.baseFeePerGas?BigInt(t.baseFeePerGas):null,difficulty:t.difficulty?BigInt(t.difficulty):void 0,gasLimit:t.gasLimit?BigInt(t.gasLimit):void 0,gasUsed:t.gasUsed?BigInt(t.gasUsed):void 0,hash:t.hash?t.hash:null,logsBloom:t.logsBloom?t.logsBloom:null,nonce:t.nonce?t.nonce:null,number:t.number?BigInt(t.number):null,size:t.size?BigInt(t.size):void 0,timestamp:t.timestamp?BigInt(t.timestamp):void 0,transactions:e,totalDifficulty:t.totalDifficulty?BigInt(t.totalDifficulty):null}}const g_=yw("block",vw);async function _c(t,{blockHash:e,blockNumber:r,blockTag:n,includeTransactions:s}={}){var b,v,E;const i=n??"latest",o=s??!1,f=r!==void 0?it(r):void 0;let h=null;if(e?h=await t.request({method:"eth_getBlockByHash",params:[e,o]}):h=await t.request({method:"eth_getBlockByNumber",params:[f||i,o]}),!h)throw new d_({blockHash:e,blockNumber:r});return(((E=(v=(b=t.chain)==null?void 0:b.formatters)==null?void 0:v.block)==null?void 0:E.format)||vw)(h)}async function y_(t){const e=await t.request({method:"eth_gasPrice"});return BigInt(e)}async function Nve(t,e){return Gq(t,e)}async function Gq(t,e){var i,o,f;const{block:r,chain:n=t.chain,request:s}=e||{};if(typeof((i=n==null?void 0:n.fees)==null?void 0:i.defaultPriorityFee)=="function"){const h=r||await ct(t,_c,"getBlock")({});return n.fees.defaultPriorityFee({block:h,client:t,request:s})}if(typeof((o=n==null?void 0:n.fees)==null?void 0:o.defaultPriorityFee)<"u")return(f=n==null?void 0:n.fees)==null?void 0:f.defaultPriorityFee;try{const h=await t.request({method:"eth_maxPriorityFeePerGas"});return Wt(h)}catch{const[h,p]=await Promise.all([r?Promise.resolve(r):ct(t,_c,"getBlock")({}),ct(t,y_,"getGasPrice")({})]);if(typeof h.baseFeePerGas!="bigint")throw new bw;const b=p-h.baseFeePerGas;return b<0n?0n:b}}async function Vq(t,e){return H7(t,e)}async function H7(t,e){var E,_;const{block:r,chain:n=t.chain,request:s,type:i="eip1559"}=e||{},o=await(async()=>{var S,P;return typeof((S=n==null?void 0:n.fees)==null?void 0:S.baseFeeMultiplier)=="function"?n.fees.baseFeeMultiplier({block:r,client:t,request:s}):((P=n==null?void 0:n.fees)==null?void 0:P.baseFeeMultiplier)??1.2})();if(o<1)throw new Hq;const h=10**(((E=o.toString().split(".")[1])==null?void 0:E.length)??0),p=S=>S*BigInt(Math.ceil(o*h))/BigInt(h),b=r||await ct(t,_c,"getBlock")({});if(typeof((_=n==null?void 0:n.fees)==null?void 0:_.estimateFeesPerGas)=="function")return n.fees.estimateFeesPerGas({block:r,client:t,multiply:p,request:s,type:i});if(i==="eip1559"){if(typeof b.baseFeePerGas!="bigint")throw new bw;const S=s!=null&&s.maxPriorityFeePerGas?s.maxPriorityFeePerGas:await Gq(t,{block:b,chain:n,request:s}),P=p(b.baseFeePerGas);return{maxFeePerGas:(s==null?void 0:s.maxFeePerGas)??P+S,maxPriorityFeePerGas:S}}return{gasPrice:(s==null?void 0:s.gasPrice)??p(await ct(t,y_,"getGasPrice")({}))}}async function Kq(t,{address:e,blockTag:r="latest",blockNumber:n}){const s=await t.request({method:"eth_getTransactionCount",params:[e,n?it(n):r]});return er(s)}function b_(t){if(t.type)return t.type;if(typeof t.maxFeePerGas<"u"||typeof t.maxPriorityFeePerGas<"u")return"eip1559";if(typeof t.gasPrice<"u")return typeof t.accessList<"u"?"eip2930":"legacy";throw new kq({transaction:t})}async function xw(t,e){const{account:r=t.account,chain:n,gas:s,nonce:i,type:o}=e;if(!r)throw new w1;const f=co(r),h=await ct(t,_c,"getBlock")({blockTag:"latest"}),p={...e,from:f.address};if(typeof i>"u"&&(p.nonce=await ct(t,Kq,"getTransactionCount")({address:f.address,blockTag:"pending"})),typeof o>"u")try{p.type=b_(p)}catch{p.type=typeof h.baseFeePerGas=="bigint"?"eip1559":"legacy"}if(p.type==="eip1559"){const{maxFeePerGas:b,maxPriorityFeePerGas:v}=await H7(t,{block:h,chain:n,request:p});if(typeof e.maxPriorityFeePerGas>"u"&&e.maxFeePerGas&&e.maxFeePerGas"u"&&(p.gas=await ct(t,v_,"estimateGas")({...p,account:{address:f.address,type:"json-rpc"}})),A1(p),p}async function v_(t,e){var s,i,o;const r=e.account??t.account;if(!r)throw new w1({docsPath:"/docs/actions/public/estimateGas"});const n=co(r);try{const{accessList:f,blockNumber:h,blockTag:p,data:b,gas:v,gasPrice:E,maxFeePerGas:_,maxPriorityFeePerGas:S,nonce:P,to:I,value:C,...T}=n.type==="local"?await xw(t,e):e,N=(h?it(h):void 0)||p;A1(e);const $=(o=(i=(s=t.chain)==null?void 0:s.formatters)==null?void 0:i.transactionRequest)==null?void 0:o.format,J=($||Fl)({...gw(T,{format:$}),from:n.address,accessList:f,data:b,gas:v,gasPrice:E,maxFeePerGas:_,maxPriorityFeePerGas:S,nonce:P,to:I,value:C}),Q=await t.request({method:"eth_estimateGas",params:N?[J,N]:[J]});return BigInt(Q)}catch(f){throw Ove(f,{...e,account:n,chain:t.chain})}}async function Wq(t,{abi:e,address:r,args:n,functionName:s,...i}){const o=mi({abi:e,args:n,functionName:s});try{return await ct(t,v_,"estimateGas")({data:o,to:r,...i})}catch(f){const h=i.account?co(i.account):void 0;throw Gp(f,{abi:e,address:r,args:n,docsPath:"/docs/contract/estimateContractGas",functionName:s,sender:h==null?void 0:h.address})}}const kR="/docs/contract/decodeEventLog";function M1({abi:t,data:e,strict:r,topics:n}){const s=r??!0,[i,...o]=n;if(!i)throw new XH({docsPath:kR});const f=t.find(S=>S.type==="event"&&i===uw(Qo(S)));if(!(f&&"name"in f)||f.type!=="event")throw new eq(i,{docsPath:kR});const{name:h,inputs:p}=f,b=p==null?void 0:p.some(S=>!("name"in S&&S.name));let v=b?[]:{};const E=p.filter(S=>"indexed"in S&&S.indexed);for(let S=0;S!("indexed"in S&&S.indexed));if(_.length>0){if(e&&e!=="0x")try{const S=Ll(_,e);if(S)if(b)v=[...v,...S];else for(let P=0;P<_.length;P++)v[_[P].name]=S[P]}catch(S){if(s)throw S instanceof aw?new Ac({abiItem:f,data:S.data,params:S.params,size:S.size}):S}else if(s)throw new Ac({abiItem:f,data:"0x",params:_,size:0})}return{eventName:h,args:Object.values(v).length>0?v:void 0}}function Lve({param:t,value:e}){return t.type==="string"||t.type==="bytes"||t.type==="tuple"||t.type.match(/^(.*)\[(\d+)?\]$/)?e:(Ll([t],e)||[])[0]}function Ws(t,{args:e,eventName:r}={}){return{...t,blockHash:t.blockHash?t.blockHash:null,blockNumber:t.blockNumber?BigInt(t.blockNumber):null,logIndex:t.logIndex?Number(t.logIndex):null,transactionHash:t.transactionHash?t.transactionHash:null,transactionIndex:t.transactionIndex?Number(t.transactionIndex):null,...r?{args:e,eventName:r}:{}}}async function x_(t,{address:e,blockHash:r,fromBlock:n,toBlock:s,event:i,events:o,args:f,strict:h}={}){const p=h??!1,b=o??(i?[i]:void 0);let v=[];b&&(v=[b.flatMap(_=>x1({abi:[_],eventName:_.name,args:f}))],i&&(v=v[0]));let E;return r?E=await t.request({method:"eth_getLogs",params:[{address:e,topics:v,blockHash:r}]}):E=await t.request({method:"eth_getLogs",params:[{address:e,topics:v,fromBlock:typeof n=="bigint"?it(n):n,toBlock:typeof s=="bigint"?it(s):s}]}),E.map(_=>{var S;try{const{eventName:P,args:I}=b?M1({abi:b,data:_.data,topics:_.topics,strict:p}):{eventName:void 0,args:void 0};return Ws(_,{args:I,eventName:P})}catch(P){let I,C;if(P instanceof Ac||P instanceof Nl){if(p)return;I=P.abiItem.name,C=(S=P.abiItem.inputs)==null?void 0:S.some(T=>!("name"in T&&T.name))}return Ws(_,{args:C?[]:{},eventName:I})}}).filter(Boolean)}async function w_(t,{abi:e,address:r,args:n,blockHash:s,eventName:i,fromBlock:o,toBlock:f,strict:h}){const p=i?Gc({abi:e,name:i}):void 0,b=p?void 0:e.filter(v=>v.type==="event");return ct(t,x_,"getLogs")({address:r,args:n,blockHash:s,event:p,events:b,fromBlock:o,toBlock:f,strict:h})}const V8="/docs/contract/decodeFunctionResult";function Ul({abi:t,args:e,functionName:r,data:n}){let s=t[0];if(r&&(s=Gc({abi:t,args:e,name:r}),!s))throw new ml(r,{docsPath:V8});if(s.type!=="function")throw new ml(void 0,{docsPath:V8});if(!s.outputs)throw new HS(s.name,{docsPath:V8});const i=Ll(s.outputs,n);if(i&&i.length>1)return i;if(i&&i.length===1)return i[0]}const Dve="modulepreload",$ve=function(t){return"/"+t},RR={},$6=function(e,r,n){if(!r||r.length===0)return e();const s=document.getElementsByTagName("link");return Promise.all(r.map(i=>{if(i=$ve(i),i in RR)return;RR[i]=!0;const o=i.endsWith(".css"),f=o?'[rel="stylesheet"]':"";if(!!n)for(let b=s.length-1;b>=0;b--){const v=s[b];if(v.href===i&&(!o||v.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${i}"]${f}`))return;const p=document.createElement("link");if(p.rel=o?"stylesheet":Dve,o||(p.as="script",p.crossOrigin=""),p.href=i,document.head.appendChild(p),o)return new Promise((b,v)=>{p.addEventListener("load",b),p.addEventListener("error",()=>v(new Error(`Unable to preload CSS for ${i}`)))})})).then(()=>e()).catch(i=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=i,window.dispatchEvent(o),!o.defaultPrevented)throw i})},F6=[{inputs:[{components:[{name:"target",type:"address"},{name:"allowFailure",type:"bool"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate3",outputs:[{components:[{name:"success",type:"bool"},{name:"returnData",type:"bytes"}],name:"returnData",type:"tuple[]"}],stateMutability:"view",type:"function"}],Jq=[{inputs:[],name:"ResolverNotFound",type:"error"},{inputs:[],name:"ResolverWildcardNotSupported",type:"error"}],Zq=[...Jq,{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],Fve=[...Jq,{name:"reverse",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolvedAddress"},{type:"address",name:"reverseResolver"},{type:"address",name:"resolver"}]}],BR=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],OR=[{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"}],outputs:[{name:"",type:"address"}]},{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"coinType",type:"uint256"}],outputs:[{name:"",type:"bytes"}]}],Uve=[{inputs:[{internalType:"address",name:"_signer",type:"address"},{internalType:"bytes32",name:"_hash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"}],zve="0x82ad56cb";class U6 extends Ue{constructor({blockNumber:e,chain:r,contract:n}){super(`Chain "${r.name}" does not support contract "${n.name}".`,{metaMessages:["This could be due to any of the following:",...e&&n.blockCreated&&n.blockCreated>e?[`- The contract "${n.name}" was not deployed until block ${n.blockCreated} (current block ${e}).`]:[`- The chain does not have the contract "${n.name}" configured.`]]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDoesNotSupportContract"})}}class Qq extends Ue{constructor({chain:e,currentChainId:r}){super(`The current chain of the wallet (id: ${r}) does not match the target chain for the transaction (id: ${e.id} – ${e.name}).`,{metaMessages:[`Current Chain ID: ${r}`,`Expected Chain ID: ${e.id} – ${e.name}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainMismatchError"})}}class Yq extends Ue{constructor(){super(["No chain was provided to the request.","Please provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."].join(` -`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotFoundError"})}}class A_ extends Ue{constructor(){super("No chain was provided to the Client."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ClientChainNotConfiguredError"})}}class S1 extends Ue{constructor({chainId:e}){super(`Chain ID "${e}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidChainIdError"})}}function zl({blockNumber:t,chain:e,contract:r}){var s;const n=(s=e==null?void 0:e.contracts)==null?void 0:s[r];if(!n)throw new U6({chain:e,contract:{name:r}});if(t&&n.blockCreated&&n.blockCreated>t)throw new U6({blockNumber:t,chain:e,contract:{name:r,blockCreated:n.blockCreated}});return n.address}function jve(t,{docsPath:e,...r}){const n=(()=>{const s=h_(t,r);return s instanceof eb?t:s})();return new l_(n,{docsPath:e,...r})}const K8=new Map;function E_({fn:t,id:e,shouldSplitBatch:r,wait:n=0,sort:s}){const i=async()=>{const b=h();o();const v=b.map(({args:E})=>E);v.length!==0&&t(v).then(E=>{var _;s&&Array.isArray(E)&&E.sort(s);for(let S=0;S{var _;for(let S=0;SK8.delete(e),f=()=>h().map(({args:b})=>b),h=()=>K8.get(e)||[],p=b=>K8.set(e,[...h(),b]);return{flush:o,async schedule(b){const v={},E=new Promise((P,I)=>{v.resolve=P,v.reject=I});return(r==null?void 0:r([...f(),b]))&&i(),h().length>0?(p({args:b,pendingPromise:v}),E):(p({args:b,pendingPromise:v}),setTimeout(i,n),E)}}}async function tb(t,e){var C,T,B,N;const{account:r=t.account,batch:n=!!((C=t.batch)!=null&&C.multicall),blockNumber:s,blockTag:i="latest",accessList:o,data:f,gas:h,gasPrice:p,maxFeePerGas:b,maxPriorityFeePerGas:v,nonce:E,to:_,value:S,...P}=e,I=r?co(r):void 0;try{A1(e);const H=(s?it(s):void 0)||i,J=(N=(B=(T=t.chain)==null?void 0:T.formatters)==null?void 0:B.transactionRequest)==null?void 0:N.format,K=(J||Fl)({...gw(P,{format:J}),from:I==null?void 0:I.address,accessList:o,data:f,gas:h,gasPrice:p,maxFeePerGas:b,maxPriorityFeePerGas:v,nonce:E,to:_,value:S});if(n&&Hve({request:K}))try{return await qve(t,{...K,blockNumber:s,blockTag:i})}catch(w){if(!(w instanceof A_)&&!(w instanceof U6))throw w}const se=await t.request({method:"eth_call",params:H?[K,H]:[K]});return se==="0x"?{data:void 0}:{data:se}}catch($){const H=Gve($),{offchainLookup:J,offchainLookupSignature:Q}=await $6(()=>Promise.resolve().then(()=>L2e),void 0);if((H==null?void 0:H.slice(0,10))===Q&&_)return{data:await J(t,{data:H,to:_})};throw jve($,{...e,account:I,chain:t.chain})}}function Hve({request:t}){const{data:e,to:r,...n}=t;return!(!e||e.startsWith(zve)||!r||Object.values(n).filter(s=>typeof s<"u").length>0)}async function qve(t,e){var P;const{batchSize:r=1024,wait:n=0}=typeof((P=t.batch)==null?void 0:P.multicall)=="object"?t.batch.multicall:{},{blockNumber:s,blockTag:i="latest",data:o,multicallAddress:f,to:h}=e;let p=f;if(!p){if(!t.chain)throw new A_;p=zl({blockNumber:s,chain:t.chain,contract:"multicall3"})}const v=(s?it(s):void 0)||i,{schedule:E}=E_({id:`${t.uid}.${v}`,wait:n,shouldSplitBatch(I){return I.reduce((T,{data:B})=>T+(B.length-2),0)>r*2},fn:async I=>{const C=I.map(N=>({allowFailure:!0,callData:N.data,target:N.to})),T=mi({abi:F6,args:[C],functionName:"aggregate3"}),B=await t.request({method:"eth_call",params:[{data:T,to:p},v]});return Ul({abi:F6,args:[C],functionName:"aggregate3",data:B||"0x"})}}),[{returnData:_,success:S}]=await E({data:o,to:h});if(!S)throw new pw({data:_});return _==="0x"?{data:void 0}:{data:_}}function Gve(t){if(!(t instanceof Ue))return;const e=t.walk();return typeof e.data=="object"?e.data.data:e.data}async function Yo(t,{abi:e,address:r,args:n,functionName:s,...i}){const o=mi({abi:e,args:n,functionName:s});try{const{data:f}=await ct(t,tb,"call")({data:o,to:r,...i});return Ul({abi:e,args:n,functionName:s,data:f||"0x"})}catch(f){throw Gp(f,{abi:e,address:r,args:n,docsPath:"/docs/contract/readContract",functionName:s})}}async function Xq(t,{abi:e,address:r,args:n,dataSuffix:s,functionName:i,...o}){const f=o.account?co(o.account):void 0,h=mi({abi:e,args:n,functionName:i});try{const{data:p}=await ct(t,tb,"call")({batch:!1,data:`${h}${s?s.replace("0x",""):""}`,to:r,...o});return{result:Ul({abi:e,args:n,functionName:i,data:p||"0x"}),request:{abi:e,address:r,args:n,dataSuffix:s,functionName:i,...o}}}catch(p){throw Gp(p,{abi:e,address:r,args:n,docsPath:"/docs/contract/simulateContract",functionName:i,sender:f==null?void 0:f.address})}}const W8=new Map,NR=new Map;let Vve=0;function _1(t,e,r){const n=++Vve,s=()=>W8.get(t)||[],i=()=>{const b=s();W8.set(t,b.filter(v=>v.id!==n))},o=()=>{const b=NR.get(t);s().length===1&&b&&b(),i()},f=s();if(W8.set(t,[...f,{id:n,fns:e}]),f&&f.length>0)return o;const h={};for(const b in e)h[b]=(...v)=>{var _,S;const E=s();if(E.length!==0)for(const P of E)(S=(_=P.fns)[b])==null||S.call(_,...v)};const p=r(h);return typeof p=="function"&&NR.set(t,p),o}async function z6(t){return new Promise(e=>setTimeout(e,t))}function rb(t,{emitOnBegin:e,initialWaitTime:r,interval:n}){let s=!0;const i=()=>s=!1;return(async()=>{let f;e&&(f=await t({unpoll:i}));const h=await(r==null?void 0:r(f))??n;await z6(h);const p=async()=>{s&&(await t({unpoll:i}),await z6(n),p())};p()})(),i}const Kve=new Map,Wve=new Map;function Jve(t){const e=(s,i)=>({clear:()=>i.delete(s),get:()=>i.get(s),set:o=>i.set(s,o)}),r=e(t,Kve),n=e(t,Wve);return{clear:()=>{r.clear(),n.clear()},promise:r,response:n}}async function Zve(t,{cacheKey:e,cacheTime:r=1/0}){const n=Jve(e),s=n.response.get();if(s&&r>0&&new Date().getTime()-s.created.getTime()`blockNumber.${t}`;async function nb(t,{cacheTime:e=t.cacheTime,maxAge:r}={}){const n=await Zve(()=>t.request({method:"eth_blockNumber"}),{cacheKey:Qve(t.uid),cacheTime:r??e});return BigInt(n)}async function ww(t,{filter:e}){const r="strict"in e&&e.strict;return(await e.request({method:"eth_getFilterChanges",params:[e.id]})).map(s=>{var i;if(typeof s=="string")return s;try{const{eventName:o,args:f}="abi"in e&&e.abi?M1({abi:e.abi,data:s.data,topics:s.topics,strict:r}):{eventName:void 0,args:void 0};return Ws(s,{args:f,eventName:o})}catch(o){let f,h;if(o instanceof Ac||o instanceof Nl){if("strict"in e&&e.strict)return;f=o.abiItem.name,h=(i=o.abiItem.inputs)==null?void 0:i.some(p=>!("name"in p&&p.name))}return Ws(s,{args:h?[]:{},eventName:f})}}).filter(Boolean)}async function Aw(t,{filter:e}){return e.request({method:"eth_uninstallFilter",params:[e.id]})}function eG(t,{abi:e,address:r,args:n,batch:s=!0,eventName:i,onError:o,onLogs:f,poll:h,pollingInterval:p=t.pollingInterval,strict:b}){return(typeof h<"u"?h:t.transport.type!=="webSocket")?(()=>{const S=cn(["watchContractEvent",r,n,s,t.uid,i,p]),P=b??!1;return _1(S,{onLogs:f,onError:o},I=>{let C,T,B=!1;const N=rb(async()=>{var $;if(!B){try{T=await ct(t,n_,"createContractEventFilter")({abi:e,address:r,args:n,eventName:i,strict:P})}catch{}B=!0;return}try{let H;if(T)H=await ct(t,ww,"getFilterChanges")({filter:T});else{const J=await ct(t,nb,"getBlockNumber")({});C&&C!==J?H=await ct(t,w_,"getContractEvents")({abi:e,address:r,args:n,eventName:i,fromBlock:C+1n,toBlock:J,strict:P}):H=[],C=J}if(H.length===0)return;if(s)I.onLogs(H);else for(const J of H)I.onLogs([J])}catch(H){T&&H instanceof Mc&&(B=!1),($=I.onError)==null||$.call(I,H)}},{emitOnBegin:!0,interval:p});return async()=>{T&&await ct(t,Aw,"uninstallFilter")({filter:T}),N()}})})():(()=>{let S=!0,P=()=>S=!1;return(async()=>{try{const I=i?x1({abi:e,eventName:i,args:n}):[],{unsubscribe:C}=await t.transport.subscribe({params:["logs",{address:r,topics:I}],onData(T){var N;if(!S)return;const B=T.result;try{const{eventName:$,args:H}=M1({abi:e,data:B.data,topics:B.topics,strict:b}),J=Ws(B,{args:H,eventName:$});f([J])}catch($){let H,J;if($ instanceof Ac||$ instanceof Nl){if(b)return;H=$.abiItem.name,J=(N=$.abiItem.inputs)==null?void 0:N.some(K=>!("name"in K&&K.name))}const Q=Ws(B,{args:J?[]:{},eventName:H});f([Q])}},onError(T){o==null||o(T)}});P=C,S||P()}catch(I){o==null||o(I)}})(),P})()}function M_({chain:t,currentChainId:e}){if(!t)throw new Yq;if(e!==t.id)throw new Qq({chain:t,currentChainId:e})}function Yve(t,{docsPath:e,...r}){const n=(()=>{const s=h_(t,r);return s instanceof eb?t:s})();return new Oq(n,{docsPath:e,...r})}async function Vp(t){const e=await t.request({method:"eth_chainId"});return er(e)}async function S_(t,{serializedTransaction:e}){return t.request({method:"eth_sendRawTransaction",params:[e]})}async function __(t,e){var P,I,C,T;const{account:r=t.account,chain:n=t.chain,accessList:s,data:i,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E,..._}=e;if(!r)throw new w1({docsPath:"/docs/actions/wallet/sendTransaction"});const S=co(r);try{A1(e);let B;if(n!==null&&(B=await ct(t,Vp,"getChainId")({}),M_({currentChainId:B,chain:n})),S.type==="local"){const J=await ct(t,xw,"prepareTransactionRequest")({account:S,accessList:s,chain:n,data:i,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E,..._});B||(B=await ct(t,Vp,"getChainId")({}));const Q=(P=n==null?void 0:n.serializers)==null?void 0:P.transaction,K=await S.signTransaction({...J,chainId:B},{serializer:Q});return await ct(t,S_,"sendRawTransaction")({serializedTransaction:K})}const N=(T=(C=(I=t.chain)==null?void 0:I.formatters)==null?void 0:C.transactionRequest)==null?void 0:T.format,H=(N||Fl)({...gw(_,{format:N}),accessList:s,data:i,from:S.address,gas:o,gasPrice:f,maxFeePerGas:h,maxPriorityFeePerGas:p,nonce:b,to:v,value:E});return await t.request({method:"eth_sendTransaction",params:[H]})}catch(B){throw Yve(B,{...e,account:S,chain:e.chain||void 0})}}async function tG(t,{abi:e,address:r,args:n,dataSuffix:s,functionName:i,...o}){const f=mi({abi:e,args:n,functionName:i});return await ct(t,__,"sendTransaction")({data:`${f}${s?s.replace("0x",""):""}`,to:r,...o})}function Xve({abi:t,address:e,publicClient:r,walletClient:n}){const s=r!=null,i=n!=null,o={};let f=!1,h=!1,p=!1;for(const b of t)if(b.type==="function"?b.stateMutability==="view"||b.stateMutability==="pure"?f=!0:h=!0:b.type==="event"&&(p=!0),f&&h&&p)break;return s&&(f&&(o.read=new Proxy({},{get(b,v){return(...E)=>{const{args:_,options:S}=tv(E);return ct(r,Yo,"readContract")({abi:t,address:e,functionName:v,args:_,...S})}}})),h&&(o.simulate=new Proxy({},{get(b,v){return(...E)=>{const{args:_,options:S}=tv(E);return ct(r,Xq,"simulateContract")({abi:t,address:e,functionName:v,args:_,...S})}}})),p&&(o.createEventFilter=new Proxy({},{get(b,v){return(...E)=>{const _=t.find(I=>I.type==="event"&&I.name===v),{args:S,options:P}=J8(E,_);return ct(r,n_,"createContractEventFilter")({abi:t,address:e,eventName:v,args:S,...P})}}}),o.getEvents=new Proxy({},{get(b,v){return(...E)=>{const _=t.find(I=>I.type==="event"&&I.name===v),{args:S,options:P}=J8(E,_);return ct(r,w_,"getContractEvents")({abi:t,address:e,eventName:v,args:S,...P})}}}),o.watchEvent=new Proxy({},{get(b,v){return(...E)=>{const _=t.find(I=>I.type==="event"&&I.name===v),{args:S,options:P}=J8(E,_);return ct(r,eG,"watchContractEvent")({abi:t,address:e,eventName:v,args:S,...P})}}}))),i&&h&&(o.write=new Proxy({},{get(b,v){return(...E)=>{const{args:_,options:S}=tv(E);return ct(n,tG,"writeContract")({abi:t,address:e,functionName:v,args:_,...S})}}})),(s||i)&&h&&(o.estimateGas=new Proxy({},{get(b,v){return(...E)=>{const{args:_,options:S}=tv(E);return ct(r??n,Wq,"estimateContractGas")({abi:t,address:e,functionName:v,args:_,...S,account:S.account??n.account})}}})),o.address=e,o.abi=t,o}function tv(t){const e=t.length&&Array.isArray(t[0]),r=e?t[0]:[],n=(e?t[1]:t[0])??{};return{args:r,options:n}}function J8(t,e){let r=!1;Array.isArray(t[0])?r=!0:t.length===1?r=e.inputs.some(i=>i.indexed):t.length===2&&(r=!0);const n=r?t[0]:void 0,s=(r?t[1]:t[0])??{};return{args:n,options:s}}async function e2e(t,{chain:e}){const{id:r,name:n,nativeCurrency:s,rpcUrls:i,blockExplorers:o}=e;await t.request({method:"wallet_addEthereumChain",params:[{chainId:it(r),chainName:n,nativeCurrency:s,rpcUrls:i.default.http,blockExplorerUrls:o?Object.values(o).map(({url:f})=>f):void 0}]})}function t2e(t){const e=zr(`0x${t.substring(4)}`).substring(26);return Yy(`0x${e}`)}const q7=256;let rv=q7,nv;function r2e(t=11){if(!nv||rv+t>q7*2){nv="",rv=0;for(let e=0;e{const C=I(P);for(const B in _)delete C[B];const T={...P,...C};return Object.assign(T,{extend:S(T)})}}return Object.assign(_,{extend:S(_)})}function G7(t,{delay:e=100,retryCount:r=2,shouldRetry:n=()=>!0}={}){return new Promise((s,i)=>{const o=async({count:f=0}={})=>{const h=async({error:p})=>{const b=typeof e=="function"?e({count:f,error:p}):e;b&&await z6(b),o({count:f+1})};try{const p=await t();s(p)}catch(p){if(f"code"in t?t.code!==-1&&t.code!==-32004&&t.code!==-32005&&t.code!==-32042&&t.code!==-32603:t instanceof dc&&t.status?t.status!==403&&t.status!==408&&t.status!==413&&t.status!==429&&t.status!==500&&t.status!==502&&t.status!==503&&t.status!==504:!1;function n2e(t,{retryDelay:e=150,retryCount:r=3}={}){return async n=>G7(async()=>{try{return await t(n)}catch(s){const i=s;switch(i.code){case Tp.code:throw new Tp(i);case kp.code:throw new kp(i);case Rp.code:throw new Rp(i);case Bp.code:throw new Bp(i);case gl.code:throw new gl(i);case Mc.code:throw new Mc(i);case Op.code:throw new Op(i);case Np.code:throw new Np(i);case Lp.code:throw new Lp(i);case Dp.code:throw new Dp(i);case $p.code:throw new $p(i);case Fp.code:throw new Fp(i);case Ju.code:throw new Ju(i);case Up.code:throw new Up(i);case zp.code:throw new zp(i);case jp.code:throw new jp(i);case Hp.code:throw new Hp(i);case qp.code:throw new qp(i);case 5e3:throw new Ju(i);default:throw s instanceof Ue?s:new Fq(i)}}},{delay:({count:s,error:i})=>{var o;if(i&&i instanceof dc){const f=(o=i==null?void 0:i.headers)==null?void 0:o.get("Retry-After");if(f!=null&&f.match(/\d/))return parseInt(f)*1e3}return~~(1<!rG(s)})}function ib({key:t,name:e,request:r,retryCount:n=3,retryDelay:s=150,timeout:i,type:o},f){return{config:{key:t,name:e,request:r,retryCount:n,retryDelay:s,timeout:i,type:o},request:n2e(r,{retryCount:n,retryDelay:s}),value:f}}function i2e(t,e={}){const{key:r="custom",name:n="Custom Provider",retryDelay:s}=e;return({retryCount:i})=>ib({key:r,name:n,request:t.request.bind(t),retryCount:e.retryCount??i,retryDelay:s,type:"custom"})}function s2e(t,e={}){const{key:r="fallback",name:n="Fallback",rank:s=!1,retryCount:i,retryDelay:o}=e;return({chain:f,pollingInterval:h=4e3,timeout:p})=>{let b=t,v=()=>{};const E=ib({key:r,name:n,async request({method:_,params:S}){const P=async(I=0)=>{const C=b[I]({chain:f,retryCount:0,timeout:p});try{const T=await C.request({method:_,params:S});return v({method:_,params:S,response:T,transport:C,status:"success"}),T}catch(T){if(v({error:T,method:_,params:S,transport:C,status:"error"}),rG(T)||I===b.length-1)throw T;return P(I+1)}};return P()},retryCount:i,retryDelay:o,type:"fallback"},{onResponse:_=>v=_,transports:b.map(_=>_({chain:f,retryCount:0}))});if(s){const _=typeof s=="object"?s:{};o2e({chain:f,interval:_.interval??h,onTransports:S=>b=S,sampleCount:_.sampleCount,timeout:_.timeout,transports:b,weights:_.weights})}return E}}function o2e({chain:t,interval:e=4e3,onTransports:r,sampleCount:n=10,timeout:s=1e3,transports:i,weights:o={}}){const{stability:f=.7,latency:h=.3}=o,p=[],b=async()=>{const v=await Promise.all(i.map(async S=>{const P=S({chain:t,retryCount:0,timeout:s}),I=Date.now();let C,T;try{await P.request({method:"net_listening"}),T=1}catch{T=0}finally{C=Date.now()}return{latency:C-I,success:T}}));p.push(v),p.length>n&&p.shift();const E=Math.max(...p.map(S=>Math.max(...S.map(({latency:P})=>P)))),_=i.map((S,P)=>{const I=p.map($=>$[P].latency),T=1-I.reduce(($,H)=>$+H,0)/I.length/E,B=p.map($=>$[P].success),N=B.reduce(($,H)=>$+H,0)/B.length;return N===0?[0,P]:[h*T+f*N,P]}).sort((S,P)=>P[0]-S[0]);r(_.map(([,S])=>i[S])),await z6(e),b()};b()}class P_ extends Ue{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro"})}}function a2e(){if(typeof WebSocket<"u")return WebSocket;if(typeof Ve.global.WebSocket<"u")return Ve.global.WebSocket;if(typeof window.WebSocket<"u")return window.WebSocket;if(typeof self.WebSocket<"u")return self.WebSocket;throw new Error("`WebSocket` is not supported in this environment")}const LR=a2e();function nG(t,{errorInstance:e=new Error("timed out"),timeout:r,signal:n}){return new Promise((s,i)=>{(async()=>{let o;try{const f=new AbortController;r>0&&(o=setTimeout(()=>{n?f.abort():i(e)},r)),s(await t({signal:f==null?void 0:f.signal}))}catch(f){f.name==="AbortError"&&i(e),i(f)}finally{clearTimeout(o)}})()})}let V7=0;async function f2e(t,{body:e,fetchOptions:r={},timeout:n=1e4}){var f;const{headers:s,method:i,signal:o}=r;try{const h=await nG(async({signal:b})=>await fetch(t,{...r,body:Array.isArray(e)?cn(e.map(E=>({jsonrpc:"2.0",id:E.id??V7++,...E}))):cn({jsonrpc:"2.0",id:e.id??V7++,...e}),headers:{...s,"Content-Type":"application/json"},method:i||"POST",signal:o||(n>0?b:void 0)}),{errorInstance:new I6({body:e,url:t}),timeout:n,signal:!0});let p;if((f=h.headers.get("Content-Type"))!=null&&f.startsWith("application/json")?p=await h.json():p=await h.text(),!h.ok)throw new dc({body:e,details:cn(p.error)||h.statusText,headers:h.headers,status:h.status,url:t});return p}catch(h){throw h instanceof dc||h instanceof I6?h:new dc({body:e,details:h.message,url:t})}}const Z8=new Map;async function Q8(t){let e=Z8.get(t);if(e)return e;const{schedule:r}=E_({id:t,fn:async()=>{const i=new LR(t),o=new Map,f=new Map,h=({data:b})=>{const v=JSON.parse(b),E=v.method==="eth_subscription",_=E?v.params.subscription:v.id,S=E?f:o,P=S.get(_);P&&P({data:b}),E||S.delete(_)},p=()=>{Z8.delete(t),i.removeEventListener("close",p),i.removeEventListener("message",h)};return i.addEventListener("close",p),i.addEventListener("message",h),i.readyState===LR.CONNECTING&&await new Promise((b,v)=>{i&&(i.onopen=b,i.onerror=v)}),e=Object.assign(i,{requests:o,subscriptions:f}),Z8.set(t,e),[e]}}),[n,[s]]=await r();return s}function c2e(t,{body:e,onResponse:r}){if(t.readyState===t.CLOSED||t.readyState===t.CLOSING)throw new $q({body:e,url:t.url,details:"Socket is closed."});const n=V7++,s=({data:i})=>{var f;const o=JSON.parse(i);typeof o.id=="number"&&n!==o.id||(r==null||r(o),e.method==="eth_subscribe"&&typeof o.result=="string"&&t.subscriptions.set(o.result,s),e.method==="eth_unsubscribe"&&t.subscriptions.delete((f=e.params)==null?void 0:f[0]))};return t.requests.set(n,s),t.send(JSON.stringify({jsonrpc:"2.0",...e,id:n})),t}async function u2e(t,{body:e,timeout:r=1e4}){return nG(()=>new Promise(n=>id.webSocket(t,{body:e,onResponse:n})),{errorInstance:new I6({body:e,url:t.url}),timeout:r})}const id={http:f2e,webSocket:c2e,webSocketAsync:u2e};function sd(t,e={}){const{batch:r,fetchOptions:n,key:s="http",name:i="HTTP JSON-RPC",retryDelay:o}=e;return({chain:f,retryCount:h,timeout:p})=>{const{batchSize:b=1e3,wait:v=0}=typeof r=="object"?r:{},E=e.retryCount??h,_=p??e.timeout??1e4,S=t||(f==null?void 0:f.rpcUrls.default.http[0]);if(!S)throw new P_;return ib({key:s,name:i,async request({method:P,params:I}){const C={method:P,params:I},{schedule:T}=E_({id:`${t}`,wait:v,shouldSplitBatch(H){return H.length>b},fn:H=>id.http(S,{body:H,fetchOptions:n,timeout:_}),sort:(H,J)=>H.id-J.id}),B=async H=>r?T(H):[await id.http(S,{body:H,fetchOptions:n,timeout:_})],[{error:N,result:$}]=await B(C);if(N)throw new mw({body:C,error:N,url:S});return $},retryCount:E,retryDelay:o,timeout:_,type:"http"},{fetchOptions:n,url:t})}}function C_(t,e){var n,s,i;if(!(t instanceof Ue))return!1;const r=t.walk(o=>o instanceof C6);return r instanceof C6?!!(((n=r.data)==null?void 0:n.errorName)==="ResolverNotFound"||((s=r.data)==null?void 0:s.errorName)==="ResolverWildcardNotSupported"||(i=r.reason)!=null&&i.includes("Wildcard on non-extended resolvers is not supported")||e==="reverse"&&r.reason===Cq[50]):!1}function iG(t){if(t.length!==66||t.indexOf("[")!==0||t.indexOf("]")!==65)return null;const e=`0x${t.slice(1,65)}`;return Rt(e)?e:null}function zm(t){let e=new Uint8Array(32).fill(0);if(!t)return Fi(e);const r=t.split(".");for(let n=r.length-1;n>=0;n-=1){const s=iG(r[n]),i=s?vn(s):zr(Ra(r[n]),"bytes");e=zr(cs([e,i]),"bytes")}return Fi(e)}function l2e(t){return`[${t.slice(2)}]`}function sG(t){const e=new Uint8Array(32).fill(0);return t?iG(t)||zr(Ra(t)):Fi(e)}function Ew(t){const e=t.replace(/^\.|\.$/gm,"");if(e.length===0)return new Uint8Array(1);const r=new Uint8Array(Ra(e).byteLength+2);let n=0;const s=e.split(".");for(let i=0;i255&&(o=Ra(l2e(sG(s[i])))),r[n]=o.length,r.set(o,n+1),n+=o.length+1}return r.byteLength!==n+1?r.slice(0,n+1):r}async function h2e(t,{blockNumber:e,blockTag:r,coinType:n,name:s,universalResolverAddress:i}){let o=i;if(!o){if(!t.chain)throw new Error("client chain not configured. universalResolverAddress is required.");o=zl({blockNumber:e,chain:t.chain,contract:"ensUniversalResolver"})}try{const f=mi({abi:OR,functionName:"addr",...n!=null?{args:[zm(s),BigInt(n)]}:{args:[zm(s)]}}),h=await ct(t,Yo,"readContract")({address:o,abi:Zq,functionName:"resolve",args:[ut(Ew(s)),f],blockNumber:e,blockTag:r});if(h[0]==="0x")return null;const p=Ul({abi:OR,args:n!=null?[zm(s),BigInt(n)]:void 0,functionName:"addr",data:h[0]});return p==="0x"||rn(p)==="0x00"?null:p}catch(f){if(C_(f,"resolve"))return null;throw f}}class d2e extends Ue{constructor({data:e}){super("Unable to extract image from metadata. The metadata may be malformed or invalid.",{metaMessages:["- Metadata must be a JSON object with at least an `image`, `image_url` or `image_data` property.","",`Provided data: ${JSON.stringify(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidMetadataError"})}}class hh extends Ue{constructor({reason:e}){super(`ENS NFT avatar URI is invalid. ${e}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidNftUriError"})}}class Mw extends Ue{constructor({uri:e}){super(`Unable to resolve ENS avatar URI "${e}". The URI may be malformed, invalid, or does not respond with a valid image.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUriResolutionError"})}}class oG extends Ue{constructor({namespace:e}){super(`ENS NFT avatar namespace "${e}" is not supported. Must be "erc721" or "erc1155".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUnsupportedNamespaceError"})}}const p2e=/(?https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?\/)?(?ipfs\/|ipns\/)?(?[\w\-.]+)(?\/.*)?/,m2e=/^(Qm[1-9A-HJ-NP-Za-km-z]{44,}|b[A-Za-z2-7]{58,}|B[A-Z2-7]{58,}|z[1-9A-HJ-NP-Za-km-z]{48,}|F[0-9A-F]{50,})(\/(?[\w\-.]+))?(?\/.*)?$/,g2e=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,y2e=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function b2e(t){try{const e=await fetch(t,{method:"HEAD"});if(e.status===200){const r=e.headers.get("content-type");return r==null?void 0:r.startsWith("image/")}return!1}catch(e){return typeof e=="object"&&typeof e.response<"u"||!globalThis.hasOwnProperty("Image")?!1:new Promise(r=>{const n=new Image;n.onload=()=>{r(!0)},n.onerror=()=>{r(!1)},n.src=t})}}function DR(t,e){return t?t.endsWith("/")?t.slice(0,-1):t:e}function aG({uri:t,gatewayUrls:e}){const r=g2e.test(t);if(r)return{uri:t,isOnChain:!0,isEncoded:r};const n=DR(e==null?void 0:e.ipfs,"https://ipfs.io"),s=DR(e==null?void 0:e.arweave,"https://arweave.net"),i=t.match(p2e),{protocol:o,subpath:f,target:h,subtarget:p=""}=(i==null?void 0:i.groups)||{},b=o==="ipns:/"||f==="ipns/",v=o==="ipfs:/"||f==="ipfs/"||m2e.test(t);if(t.startsWith("http")&&!b&&!v){let _=t;return e!=null&&e.arweave&&(_=t.replace(/https:\/\/arweave.net/g,e==null?void 0:e.arweave)),{uri:_,isOnChain:!1,isEncoded:!1}}if((b||v)&&h)return{uri:`${n}/${b?"ipns":"ipfs"}/${h}${p}`,isOnChain:!1,isEncoded:!1};if(o==="ar:/"&&h)return{uri:`${s}/${h}${p||""}`,isOnChain:!1,isEncoded:!1};let E=t.replace(y2e,"");if(E.startsWith("s.json());return await I_({gatewayUrls:t,uri:fG(r)})}catch{throw new Mw({uri:e})}}async function I_({gatewayUrls:t,uri:e}){const{uri:r,isOnChain:n}=aG({uri:e,gatewayUrls:t});if(n||await b2e(r))return r;throw new Mw({uri:e})}function x2e(t){let e=t;e.startsWith("did:nft:")&&(e=e.replace("did:nft:","").replace(/_/g,"/"));const[r,n,s]=e.split("/"),[i,o]=r.split(":"),[f,h]=n.split(":");if(!i||i.toLowerCase()!=="eip155")throw new hh({reason:"Only EIP-155 supported"});if(!o)throw new hh({reason:"Chain ID not found"});if(!h)throw new hh({reason:"Contract address not found"});if(!s)throw new hh({reason:"Token ID not found"});if(!f)throw new hh({reason:"ERC namespace not found"});return{chainID:parseInt(o),namespace:f.toLowerCase(),contractAddress:h,tokenID:s}}async function w2e(t,{nft:e}){if(e.namespace==="erc721")return Yo(t,{address:e.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(e.tokenID)]});if(e.namespace==="erc1155")return Yo(t,{address:e.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(e.tokenID)]});throw new oG({namespace:e.namespace})}async function A2e(t,{gatewayUrls:e,record:r}){return/eip155:/i.test(r)?E2e(t,{gatewayUrls:e,record:r}):I_({uri:r,gatewayUrls:e})}async function E2e(t,{gatewayUrls:e,record:r}){const n=x2e(r),s=await w2e(t,{nft:n}),{uri:i,isOnChain:o,isEncoded:f}=aG({uri:s,gatewayUrls:e});if(o&&(i.includes("data:application/json;base64,")||i.startsWith("{"))){const p=f?atob(i.replace("data:application/json;base64,","")):i,b=JSON.parse(p);return I_({uri:fG(b),gatewayUrls:e})}let h=n.tokenID;return n.namespace==="erc1155"&&(h=h.replace("0x","").padStart(64,"0")),v2e({gatewayUrls:e,uri:i.replace(/(?:0x)?{id}/,h)})}async function cG(t,{blockNumber:e,blockTag:r,name:n,key:s,universalResolverAddress:i}){let o=i;if(!o){if(!t.chain)throw new Error("client chain not configured. universalResolverAddress is required.");o=zl({blockNumber:e,chain:t.chain,contract:"ensUniversalResolver"})}try{const f=await ct(t,Yo,"readContract")({address:o,abi:Zq,functionName:"resolve",args:[ut(Ew(n)),mi({abi:BR,functionName:"text",args:[zm(n),s]})],blockNumber:e,blockTag:r});if(f[0]==="0x")return null;const h=Ul({abi:BR,functionName:"text",data:f[0]});return h===""?null:h}catch(f){if(C_(f,"resolve"))return null;throw f}}async function M2e(t,{blockNumber:e,blockTag:r,gatewayUrls:n,name:s,universalResolverAddress:i}){const o=await ct(t,cG,"getEnsText")({blockNumber:e,blockTag:r,key:"avatar",name:s,universalResolverAddress:i});if(!o)return null;try{return await A2e(t,{record:o,gatewayUrls:n})}catch{return null}}async function S2e(t,{address:e,blockNumber:r,blockTag:n,universalResolverAddress:s}){let i=s;if(!i){if(!t.chain)throw new Error("client chain not configured. universalResolverAddress is required.");i=zl({blockNumber:r,chain:t.chain,contract:"ensUniversalResolver"})}const o=`${e.toLowerCase().substring(2)}.addr.reverse`;try{const[f,h]=await ct(t,Yo,"readContract")({address:i,abi:Fve,functionName:"reverse",args:[ut(Ew(o))],blockNumber:r,blockTag:n});return e.toLowerCase()!==h.toLowerCase()?null:f}catch(f){if(C_(f,"reverse"))return null;throw f}}async function _2e(t,{blockNumber:e,blockTag:r,name:n,universalResolverAddress:s}){let i=s;if(!i){if(!t.chain)throw new Error("client chain not configured. universalResolverAddress is required.");i=zl({blockNumber:e,chain:t.chain,contract:"ensUniversalResolver"})}const[o]=await ct(t,Yo,"readContract")({address:i,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[ut(Ew(n))],blockNumber:e,blockTag:r});return o}async function P2e(t){const e=hw(t,{method:"eth_newBlockFilter"}),r=await t.request({method:"eth_newBlockFilter"});return{id:r,request:e(r),type:"block"}}async function uG(t,{address:e,args:r,event:n,events:s,fromBlock:i,strict:o,toBlock:f}={}){const h=s??(n?[n]:void 0),p=hw(t,{method:"eth_newFilter"});let b=[];h&&(b=[h.flatMap(E=>x1({abi:[E],eventName:E.name,args:r}))],n&&(b=b[0]));const v=await t.request({method:"eth_newFilter",params:[{address:e,fromBlock:typeof i=="bigint"?it(i):i,toBlock:typeof f=="bigint"?it(f):f,...b.length?{topics:b}:{}}]});return{abi:h,args:r,eventName:n?n.name:void 0,fromBlock:i,id:v,request:p(v),strict:o,toBlock:f,type:"event"}}async function lG(t){const e=hw(t,{method:"eth_newPendingTransactionFilter"}),r=await t.request({method:"eth_newPendingTransactionFilter"});return{id:r,request:e(r),type:"transaction"}}async function C2e(t,{address:e,blockNumber:r,blockTag:n="latest"}){const s=r?it(r):void 0,i=await t.request({method:"eth_getBalance",params:[e,s||n]});return BigInt(i)}async function I2e(t,{blockHash:e,blockNumber:r,blockTag:n="latest"}={}){const s=r!==void 0?it(r):void 0;let i;return e?i=await t.request({method:"eth_getBlockTransactionCountByHash",params:[e]}):i=await t.request({method:"eth_getBlockTransactionCountByNumber",params:[s||n]}),er(i)}async function hG(t,{address:e,blockNumber:r,blockTag:n="latest"}){const s=r!==void 0?it(r):void 0,i=await t.request({method:"eth_getCode",params:[e,s||n]});if(i!=="0x")return i}function T2e(t){var e;return{baseFeePerGas:t.baseFeePerGas.map(r=>BigInt(r)),gasUsedRatio:t.gasUsedRatio,oldestBlock:BigInt(t.oldestBlock),reward:(e=t.reward)==null?void 0:e.map(r=>r.map(n=>BigInt(n)))}}async function k2e(t,{blockCount:e,blockNumber:r,blockTag:n="latest",rewardPercentiles:s}){const i=r?it(r):void 0,o=await t.request({method:"eth_feeHistory",params:[it(e),i||n,s]});return T2e(o)}async function R2e(t,{filter:e}){const r=e.strict??!1;return(await e.request({method:"eth_getFilterLogs",params:[e.id]})).map(s=>{var i;try{const{eventName:o,args:f}="abi"in e&&e.abi?M1({abi:e.abi,data:s.data,topics:s.topics,strict:r}):{eventName:void 0,args:void 0};return Ws(s,{args:f,eventName:o})}catch(o){let f,h;if(o instanceof Ac||o instanceof Nl){if("strict"in e&&e.strict)return;f=o.abiItem.name,h=(i=o.abiItem.inputs)==null?void 0:i.some(p=>!("name"in p&&p.name))}return Ws(s,{args:h?[]:{},eventName:f})}}).filter(Boolean)}class B2e extends Ue{constructor({callbackSelector:e,cause:r,data:n,extraData:s,sender:i,urls:o}){var f;super(r.shortMessage||"An error occurred while fetching for an offchain result.",{cause:r,metaMessages:[...r.metaMessages||[],(f=r.metaMessages)!=null&&f.length?"":[],"Offchain Gateway Call:",o&&[" Gateway URL(s):",...o.map(h=>` ${b1(h)}`)],` Sender: ${i}`,` Data: ${n}`,` Callback selector: ${e}`,` Extra data: ${s}`].flat()}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupError"})}}class O2e extends Ue{constructor({result:e,url:r}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${b1(r)}`,`Response: ${cn(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupResponseMalformedError"})}}class N2e extends Ue{constructor({sender:e,to:r}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${r}`,`OffchainLookup sender address: ${e}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupSenderMismatchError"})}}function Sw(t,e){if(!wr(t))throw new un({address:t});if(!wr(e))throw new un({address:e});return t.toLowerCase()===e.toLowerCase()}const dG="0x556f1830",T_={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]};async function pG(t,{blockNumber:e,blockTag:r,data:n,to:s}){const{args:i}=i_({data:n,abi:[T_]}),[o,f,h,p,b]=i;try{if(!Sw(s,o))throw new N2e({sender:o,to:s});const v=await k_({data:h,sender:o,urls:f}),{data:E}=await tb(t,{blockNumber:e,blockTag:r,data:cs([p,s0([{type:"bytes"},{type:"bytes"}],[v,b])]),to:s});return E}catch(v){throw new B2e({callbackSelector:p,cause:v,data:n,extraData:b,sender:o,urls:f})}}async function k_({data:t,sender:e,urls:r}){var s;let n=new Error("An unknown error occurred.");for(let i=0;ir.id===e)}const $2e=/^(.*)\[([0-9]*)\]$/,mG=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,gG=/^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;function P1({domain:t,message:e,primaryType:r,types:n}){const s=typeof t>"u"?{}:t,i={EIP712Domain:sb({domain:s}),...n};_w({domain:s,message:e,primaryType:r,types:i});const o=["0x1901"];return s&&o.push(R_({domain:s,types:i})),r!=="EIP712Domain"&&o.push(yG({data:e,primaryType:r,types:i})),zr(cs(o))}function R_({domain:t,types:e}){return yG({data:t,primaryType:"EIP712Domain",types:e})}function yG({data:t,primaryType:e,types:r}){const n=bG({data:t,primaryType:e,types:r});return zr(n)}function bG({data:t,primaryType:e,types:r}){const n=[{type:"bytes32"}],s=[F2e({primaryType:e,types:r})];for(const i of r[e]){const[o,f]=xG({types:r,name:i.name,type:i.type,value:t[i.name]});n.push(o),s.push(f)}return s0(n,s)}function F2e({primaryType:t,types:e}){const r=ut(U2e({primaryType:t,types:e}));return zr(r)}function U2e({primaryType:t,types:e}){let r="";const n=vG({primaryType:t,types:e});n.delete(t);const s=[t,...Array.from(n).sort()];for(const i of s)r+=`${i}(${e[i].map(({name:o,type:f})=>`${f} ${o}`).join(",")})`;return r}function vG({primaryType:t,types:e},r=new Set){const n=t.match(/^\w*/u),s=n==null?void 0:n[0];if(r.has(s)||e[s]===void 0)return r;r.add(s);for(const i of e[s])vG({primaryType:i.type,types:e},r);return r}function xG({types:t,name:e,type:r,value:n}){if(t[r]!==void 0)return[{type:"bytes32"},zr(bG({data:n,primaryType:r,types:t}))];if(r==="bytes")return n=`0x${(n.length%2?"0":"")+n.slice(2)}`,[{type:"bytes32"},zr(n)];if(r==="string")return[{type:"bytes32"},zr(ut(n))];if(r.lastIndexOf("]")===r.length-1){const s=r.slice(0,r.lastIndexOf("[")),i=n.map(o=>xG({name:e,type:s,types:t,value:o}));return[{type:"bytes32"},zr(s0(i.map(([o])=>o),i.map(([,o])=>o)))]}return[{type:r},n]}function _w({domain:t,message:e,primaryType:r,types:n}){const s=n,i=(o,f)=>{for(const h of o){const{name:p,type:b}=h,v=b,E=f[p],_=v.match(gG);if(_&&(typeof E=="number"||typeof E=="bigint")){const[I,C,T]=_;it(E,{signed:C==="int",size:parseInt(T)/8})}if(v==="address"&&typeof E=="string"&&!wr(E))throw new un({address:E});const S=v.match(mG);if(S){const[I,C]=S;if(C&&Wr(E)!==parseInt(C))throw new qS({expectedSize:parseInt(C),givenSize:Wr(E)})}const P=s[v];P&&i(P,E)}};if(s.EIP712Domain&&t&&i(s.EIP712Domain,t),r!=="EIP712Domain"){const o=s[r];i(o,e)}}function sb({domain:t}){return[typeof(t==null?void 0:t.name)=="string"&&{name:"name",type:"string"},(t==null?void 0:t.version)&&{name:"version",type:"string"},typeof(t==null?void 0:t.chainId)=="number"&&{name:"chainId",type:"uint256"},(t==null?void 0:t.verifyingContract)&&{name:"verifyingContract",type:"address"},(t==null?void 0:t.salt)&&{name:"salt",type:"bytes32"}].filter(Boolean)}function z2e({domain:t}){return R_({domain:t,types:{EIP712Domain:sb({domain:t})}})}function j2e({abi:t,data:e}){const r=Sr(e,0,4),n=t.find(s=>s.type==="function"&&r===v1(Qo(s)));if(!n)throw new tq(r,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:n.name,args:"inputs"in n&&n.inputs&&n.inputs.length>0?Ll(n.inputs,Sr(e,4)):void 0}}const Y8="/docs/contract/encodeDeployData";function B_({abi:t,args:e,bytecode:r}){if(!e||e.length===0)return r;const n=t.find(i=>"type"in i&&i.type==="constructor");if(!n)throw new US({docsPath:Y8});if(!("inputs"in n))throw new Rg({docsPath:Y8});if(!n.inputs||n.inputs.length===0)throw new Rg({docsPath:Y8});const s=s0(n.inputs,e);return fo([r,s])}const X8="/docs/contract/encodeErrorResult";function H2e({abi:t,errorName:e,args:r}){let n=t[0];if(e&&(n=Gc({abi:t,args:r,name:e}),!n))throw new U7(e,{docsPath:X8});if(n.type!=="error")throw new U7(void 0,{docsPath:X8});const s=Qo(n),i=v1(s);let o="0x";if(r&&r.length>0){if(!n.inputs)throw new YH(n.name,{docsPath:X8});o=s0(n.inputs,r)}return fo([i,o])}const q2e="/docs/contract/encodeFunctionResult";function G2e({abi:t,functionName:e,result:r}){let n=t[0];if(e&&(n=Gc({abi:t,name:e}),!n))throw new ml(e,{docsPath:"/docs/contract/encodeFunctionResult"});if(n.type!=="function")throw new ml(void 0,{docsPath:"/docs/contract/encodeFunctionResult"});if(!n.outputs)throw new HS(n.name,{docsPath:q2e});let s=Array.isArray(r)?r:[r];return n.outputs.length===0&&!s[0]&&(s=[]),s0(n.outputs,s)}function od(t,e){if(t.length!==e.length)throw new zS({expectedLength:t.length,givenLength:e.length});const r=[];for(let n=0;nthis.bytes.length-1)throw new V2e({length:this.bytes.length,position:t})},decrementPosition(t){if(t<0)throw new $R({offset:t});const e=this.position-t;this.assertPosition(e),this.position=e},incrementPosition(t){if(t<0)throw new $R({offset:t});const e=this.position+t;this.assertPosition(e),this.position=e},inspectByte(t){const e=t??this.position;return this.assertPosition(e),this.bytes[e]},inspectBytes(t,e){const r=e??this.position;return this.assertPosition(r+t-1),this.bytes.subarray(r,r+t)},inspectUint8(t){const e=t??this.position;return this.assertPosition(e),this.bytes[e]},inspectUint16(t){const e=t??this.position;return this.assertPosition(e+1),this.dataView.getUint16(e)},inspectUint24(t){const e=t??this.position;return this.assertPosition(e+2),(this.dataView.getUint16(e)<<8)+this.dataView.getUint8(e+2)},inspectUint32(t){const e=t??this.position;return this.assertPosition(e+3),this.dataView.getUint32(e)},pushByte(t){this.assertPosition(this.position),this.bytes[this.position]=t,this.position++},pushBytes(t){this.assertPosition(this.position+t.length-1),this.bytes.set(t,this.position),this.position+=t.length},pushUint8(t){this.assertPosition(this.position),this.bytes[this.position]=t,this.position++},pushUint16(t){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,t),this.position+=2},pushUint24(t){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,t>>8),this.dataView.setUint8(this.position+2,t&255),this.position+=3},pushUint32(t){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,t),this.position+=4},readByte(){const t=this.inspectByte();return this.position++,t},readBytes(t){const e=this.inspectBytes(t);return this.position+=t,e},readUint8(){const t=this.inspectUint8();return this.position+=1,t},readUint16(){const t=this.inspectUint16();return this.position+=2,t},readUint24(){const t=this.inspectUint24();return this.position+=3,t},readUint32(){const t=this.inspectUint32();return this.position+=4,t},setPosition(t){this.assertPosition(t),this.position=t}};function AG(t){const e=Object.create(K2e);return e.bytes=t,e.dataView=new DataView(t.buffer,t.byteOffset,t.byteLength),e}function o0(t,e="hex"){const r=EG(t),n=AG(new Uint8Array(r.length));return r.encode(n),e==="hex"?Fi(n.bytes):n.bytes}function W2e(t,e="bytes"){return o0(t,e)}function J2e(t,e="hex"){return o0(t,e)}function EG(t){return Array.isArray(t)?Z2e(t.map(e=>EG(e))):Q2e(t)}function Z2e(t){const e=t.reduce((s,i)=>s+i.length,0),r=MG(e);return{length:(()=>e<=55?1+e:1+r+e)(),encode(s){e<=55?s.pushByte(192+e):(s.pushByte(192+55+r),r===1?s.pushUint8(e):r===2?s.pushUint16(e):r===3?s.pushUint24(e):s.pushUint32(e));for(const{encode:i}of t)i(s)}}}function Q2e(t){const e=typeof t=="string"?i0(t):t,r=MG(e.length);return{length:(()=>e.length===1&&e[0]<128?1:e.length<=55?1+e.length:1+r+e.length)(),encode(s){e.length===1&&e[0]<128?s.pushBytes(e):e.length<=55?(s.pushByte(128+e.length),s.pushBytes(e)):(s.pushByte(128+55+r),r===1?s.pushUint8(e.length):r===2?s.pushUint16(e.length):r===3?s.pushUint24(e.length):s.pushUint32(e.length),s.pushBytes(e))}}}function MG(t){if(t<2**8)return 1;if(t<2**16)return 2;if(t<2**24)return 3;if(t<2**32)return 4;throw new Ue("Length is too large.")}function SG(t){return t.opcode==="CREATE2"?PG(t):_G(t)}function _G(t){const e=vn(Ec(t.from));let r=vn(t.nonce);return r[0]===0&&(r=new Uint8Array([])),Ec(`0x${zr(o0([e,r],"bytes")).slice(26)}`)}function PG(t){const e=vn(Ec(t.from)),r=Uo(K7(t.salt)?t.salt:vn(t.salt),{size:32}),n=(()=>"bytecodeHash"in t?K7(t.bytecodeHash)?t.bytecodeHash:vn(t.bytecodeHash):zr(t.bytecode,"bytes"))();return Ec(Sr(zr(cs([vn("0xff"),e,r,n])),12))}const Y2e={"0x0":"reverted","0x1":"success"};function O_(t){return{...t,blockNumber:t.blockNumber?BigInt(t.blockNumber):null,contractAddress:t.contractAddress?t.contractAddress:null,cumulativeGasUsed:t.cumulativeGasUsed?BigInt(t.cumulativeGasUsed):null,effectiveGasPrice:t.effectiveGasPrice?BigInt(t.effectiveGasPrice):null,gasUsed:t.gasUsed?BigInt(t.gasUsed):null,logs:t.logs?t.logs.map(e=>Ws(e)):null,to:t.to?t.to:null,transactionIndex:t.transactionIndex?er(t.transactionIndex):null,status:t.status?Y2e[t.status]:null,type:t.type?p_[t.type]||t.type:null}}const N_=yw("transactionReceipt",O_);function X2e(t,e){const r=typeof e=="string"?{to:e}:e,n=r.to;return n==="number"?IG(t,r):n==="bigint"?W7(t,r):n==="boolean"?CG(t,r):n==="string"?TG(t,r):Fi(t,r)}function W7(t,e={}){typeof e.size<"u"&&ao(t,{size:e.size});const r=Fi(t,e);return Wt(r)}function CG(t,e={}){let r=t;if(typeof e.size<"u"&&(ao(r,{size:e.size}),r=rn(r)),r.length>1||r[0]>1)throw new uq(r);return!!r[0]}function IG(t,e={}){typeof e.size<"u"&&ao(t,{size:e.size});const r=Fi(t,e);return er(r)}function TG(t,e={}){let r=t;return typeof e.size<"u"&&(ao(r,{size:e.size}),r=rn(r,{dir:"right"})),new TextDecoder().decode(r)}function L_(t,e="hex"){const r=(()=>{if(typeof t=="string"){if(t.length>3&&t.length%2!==0)throw new hq(t);return i0(t)}return t})(),n=AG(r);return kG(n,e)}function kG(t,e="hex"){if(t.bytes.length===0)return e==="hex"?Fi(t.bytes):t.bytes;const r=t.readByte();if(r<128&&t.decrementPosition(1),r<192){const s=FR(t,r,128),i=t.readBytes(s);return e==="hex"?Fi(i):i}const n=FR(t,r,192);return e6e(t,n,e)}function FR(t,e,r){if(r===128&&e<128)return 1;if(e<=r+55)return e-r;if(e===r+55+1)return t.readUint8();if(e===r+55+2)return t.readUint16();if(e===r+55+3)return t.readUint24();if(e===r+55+4)return t.readUint32();throw new Ue("Invalid RLP prefix")}function e6e(t,e,r){const n=t.position,s=[];for(;t.position-n>s&i),f=Number(r&i),h=n?4:0,p=n?0:4;t.setUint32(e+h,o,n),t.setUint32(e+p,f,n)}class BG extends QS{constructor(e,r,n,s){super(),this.blockLen=e,this.outputLen=r,this.padOffset=n,this.isLE=s,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=G8(this.buffer)}update(e){Ip(this);const{view:r,buffer:n,blockLen:s}=this;e=cw(e);const i=e.length;for(let o=0;os-o&&(this.process(n,0),o=0);for(let v=o;vb.length)throw new Error("_sha2: outputLen bigger than state");for(let v=0;vt&e^~t&r,n6e=(t,e,r)=>t&e^t&r^e&r,i6e=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),p0=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),m0=new Uint32Array(64);class s6e extends BG{constructor(){super(64,32,8,!1),this.A=p0[0]|0,this.B=p0[1]|0,this.C=p0[2]|0,this.D=p0[3]|0,this.E=p0[4]|0,this.F=p0[5]|0,this.G=p0[6]|0,this.H=p0[7]|0}get(){const{A:e,B:r,C:n,D:s,E:i,F:o,G:f,H:h}=this;return[e,r,n,s,i,o,f,h]}set(e,r,n,s,i,o,f,h){this.A=e|0,this.B=r|0,this.C=n|0,this.D=s|0,this.E=i|0,this.F=o|0,this.G=f|0,this.H=h|0}process(e,r){for(let v=0;v<16;v++,r+=4)m0[v]=e.getUint32(r,!1);for(let v=16;v<64;v++){const E=m0[v-15],_=m0[v-2],S=fa(E,7)^fa(E,18)^E>>>3,P=fa(_,17)^fa(_,19)^_>>>10;m0[v]=P+m0[v-7]+S+m0[v-16]|0}let{A:n,B:s,C:i,D:o,E:f,F:h,G:p,H:b}=this;for(let v=0;v<64;v++){const E=fa(f,6)^fa(f,11)^fa(f,25),_=b+E+r6e(f,h,p)+i6e[v]+m0[v]|0,P=(fa(n,2)^fa(n,13)^fa(n,22))+n6e(n,s,i)|0;b=p,p=h,h=f,f=o+_|0,o=i,i=s,s=n,n=_+P|0}n=n+this.A|0,s=s+this.B|0,i=i+this.C|0,o=o+this.D|0,f=f+this.E|0,h=h+this.F|0,p=p+this.G|0,b=b+this.H|0,this.set(n,s,i,o,f,h,p,b)}roundClean(){m0.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const Kp=YS(()=>new s6e);function o6e(t,e){const r=e||"hex",n=Kp(Rt(t,{strict:!1})?vn(t):t);return r==="bytes"?n:ut(n)}const a6e=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),OG=Uint8Array.from({length:16},(t,e)=>e),f6e=OG.map(t=>(9*t+5)%16);let D_=[OG],$_=[f6e];for(let t=0;t<4;t++)for(let e of[D_,$_])e.push(e[t].map(r=>a6e[r]));const NG=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map(t=>new Uint8Array(t)),c6e=D_.map((t,e)=>t.map(r=>NG[e][r])),u6e=$_.map((t,e)=>t.map(r=>NG[e][r])),l6e=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),h6e=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),iv=(t,e)=>t<>>32-e;function UR(t,e,r,n){return t===0?e^r^n:t===1?e&r|~e&n:t===2?(e|~r)^n:t===3?e&n|r&~n:e^(r|~n)}const sv=new Uint32Array(16);class d6e extends BG{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:e,h1:r,h2:n,h3:s,h4:i}=this;return[e,r,n,s,i]}set(e,r,n,s,i){this.h0=e|0,this.h1=r|0,this.h2=n|0,this.h3=s|0,this.h4=i|0}process(e,r){for(let _=0;_<16;_++,r+=4)sv[_]=e.getUint32(r,!0);let n=this.h0|0,s=n,i=this.h1|0,o=i,f=this.h2|0,h=f,p=this.h3|0,b=p,v=this.h4|0,E=v;for(let _=0;_<5;_++){const S=4-_,P=l6e[_],I=h6e[_],C=D_[_],T=$_[_],B=c6e[_],N=u6e[_];for(let $=0;$<16;$++){const H=iv(n+UR(_,i,f,p)+sv[C[$]]+P,B[$])+v|0;n=v,v=p,p=iv(f,10)|0,f=i,i=H}for(let $=0;$<16;$++){const H=iv(s+UR(S,o,h,b)+sv[T[$]]+I,N[$])+E|0;s=E,E=b,b=iv(h,10)|0,h=o,o=H}}this.set(this.h1+f+b|0,this.h2+p+E|0,this.h3+v+s|0,this.h4+n+o|0,this.h0+i+h|0)}roundClean(){sv.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}const p6e=YS(()=>new d6e);function m6e(t,e){const r=e||"hex",n=p6e(Rt(t,{strict:!1})?vn(t):t);return r==="bytes"?n:ut(n)}async function LG({hash:t,signature:e}){const r=Rt(e)?e:ut(e),n=Rt(t)?t:ut(t);let s=er(`0x${r.slice(130)}`);(s===0||s===1)&&(s+=27);const{secp256k1:i}=await $6(()=>Promise.resolve().then(()=>c3e),void 0);return`0x${i.Signature.fromCompact(r.substring(2,130)).addRecoveryBit(s-27).recoverPublicKey(n.substring(2)).toHex(!1)}`}async function F_({hash:t,signature:e}){return t2e(await LG({hash:t,signature:e}))}const DG=`Ethereum Signed Message: -`;function ob(t,e){const r=(()=>typeof t=="string"?Ra(t):t.raw instanceof Uint8Array?t.raw:vn(t.raw))(),n=Ra(`${DG}${r.length}`);return zr(cs([n,r]),e)}async function $G({message:t,signature:e}){return F_({hash:ob(t),signature:e})}async function FG({domain:t,message:e,primaryType:r,signature:n,types:s}){return F_({hash:P1({domain:t,message:e,primaryType:r,types:s}),signature:n})}async function g6e({address:t,message:e,signature:r}){return Sw(Ec(t),await $G({message:e,signature:r}))}async function y6e({address:t,domain:e,message:r,primaryType:n,signature:s,types:i}){return Sw(Ec(t),await FG({domain:e,message:r,primaryType:n,signature:s,types:i}))}function UG(t){const e=e_(t,0,1);if(e==="0x02")return"eip1559";if(e==="0x01")return"eip2930";if(e!=="0x"&&er(e)>=192)return"legacy";throw new Rq({serializedType:e})}function U_(t){const{chainId:e,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:i}=t;if(e<=0)throw new S1({chainId:e});if(i&&!wr(i))throw new un({address:i});if(n)throw new Ue("`gasPrice` is not a valid EIP-1559 Transaction attribute.");if(s&&s>2n**256n-1n)throw new $a({maxFeePerGas:s});if(r&&s&&r>s)throw new Sc({maxFeePerGas:s,maxPriorityFeePerGas:r})}function z_(t){const{chainId:e,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:i}=t;if(e<=0)throw new S1({chainId:e});if(i&&!wr(i))throw new un({address:i});if(r||s)throw new Ue("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(n&&n>2n**256n-1n)throw new $a({maxFeePerGas:n})}function j_(t){const{chainId:e,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:i,accessList:o}=t;if(i&&!wr(i))throw new un({address:i});if(typeof e<"u"&&e<=0)throw new S1({chainId:e});if(r||s)throw new Ue("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(n&&n>2n**256n-1n)throw new $a({maxFeePerGas:n});if(o)throw new Ue("`accessList` is not a valid Legacy Transaction attribute.")}function b6e(t){const e=UG(t);return e==="eip1559"?v6e(t):e==="eip2930"?x6e(t):w6e(t)}function v6e(t){const e=zG(t),[r,n,s,i,o,f,h,p,b,v,E,_]=e;if(!(e.length===9||e.length===12))throw new dw({attributes:{chainId:r,nonce:n,maxPriorityFeePerGas:s,maxFeePerGas:i,gas:o,to:f,value:h,data:p,accessList:b,...e.length>9?{v,r:E,s:_}:{}},serializedTransaction:t,type:"eip1559"});const S={chainId:er(r),type:"eip1559"};return Rt(f)&&f!=="0x"&&(S.to=f),Rt(o)&&o!=="0x"&&(S.gas=Wt(o)),Rt(p)&&p!=="0x"&&(S.data=p),Rt(n)&&n!=="0x"&&(S.nonce=er(n)),Rt(h)&&h!=="0x"&&(S.value=Wt(h)),Rt(i)&&i!=="0x"&&(S.maxFeePerGas=Wt(i)),Rt(s)&&s!=="0x"&&(S.maxPriorityFeePerGas=Wt(s)),b.length!==0&&b!=="0x"&&(S.accessList=jG(b)),U_(S),{...e.length===12?HG(e):void 0,...S}}function x6e(t){const e=zG(t),[r,n,s,i,o,f,h,p,b,v,E]=e;if(!(e.length===8||e.length===11))throw new dw({attributes:{chainId:r,nonce:n,gasPrice:s,gas:i,to:o,value:f,data:h,accessList:p,...e.length>8?{v:b,r:v,s:E}:{}},serializedTransaction:t,type:"eip2930"});const _={chainId:er(r),type:"eip2930"};return Rt(o)&&o!=="0x"&&(_.to=o),Rt(i)&&i!=="0x"&&(_.gas=Wt(i)),Rt(h)&&h!=="0x"&&(_.data=h),Rt(n)&&n!=="0x"&&(_.nonce=er(n)),Rt(f)&&f!=="0x"&&(_.value=Wt(f)),Rt(s)&&s!=="0x"&&(_.gasPrice=Wt(s)),p.length!==0&&p!=="0x"&&(_.accessList=jG(p)),z_(_),{...e.length===11?HG(e):void 0,..._}}function w6e(t){const e=L_(t,"hex"),[r,n,s,i,o,f,h,p,b]=e;if(!(e.length===6||e.length===9))throw new dw({attributes:{nonce:r,gasPrice:n,gas:s,to:i,value:o,data:f,...e.length>6?{v:h,r:p,s:b}:{}},serializedTransaction:t,type:"legacy"});const v={type:"legacy"};if(Rt(i)&&i!=="0x"&&(v.to=i),Rt(s)&&s!=="0x"&&(v.gas=Wt(s)),Rt(f)&&f!=="0x"&&(v.data=f),Rt(r)&&r!=="0x"&&(v.nonce=er(r)),Rt(o)&&o!=="0x"&&(v.value=Wt(o)),Rt(n)&&n!=="0x"&&(v.gasPrice=Wt(n)),j_(v),e.length===6)return v;const E=Rt(h)&&h!=="0x"?Wt(h):0n;if(b==="0x"&&p==="0x")return E>0&&(v.chainId=Number(E)),v;const _=E,S=Number((_-35n)/2n);if(S>0)v.chainId=S;else if(_!==27n&&_!==28n)throw new f_({v:_});return v.v=_,v.s=b,v.r=p,v}function zG(t){return L_(`0x${t.slice(4)}`,"hex")}function jG(t){const e=[];for(let r=0;rRG(i)?i:rn(i))})}return e}function HG(t){const e=t.slice(-3),r=e[0]==="0x"||Wt(e[0])===0n?27n:28n;return{r:zo(e[1],{size:32}),s:zo(e[2],{size:32}),v:r,yParity:r===27n?0:1}}function ab(t){if(!t||t.length===0)return[];const e=[];for(let r=0;re.v===0n?"0x":e.v===1n?ut(1):e.v===27n?"0x":ut(1))();E.push(_,rn(e.r),rn(e.s))}return fo(["0x02",o0(E)])}function E6e(t,e){const{chainId:r,gas:n,data:s,nonce:i,to:o,value:f,accessList:h,gasPrice:p}=t;z_(t);const b=ab(h),v=[ut(r),i?ut(i):"0x",p?ut(p):"0x",n?ut(n):"0x",o??"0x",f?ut(f):"0x",s??"0x",b];if(e){const E=(()=>e.v===0n?"0x":e.v===1n?ut(1):e.v===27n?"0x":ut(1))();v.push(E,rn(e.r),rn(e.s))}return fo(["0x01",o0(v)])}function M6e(t,e){const{chainId:r=0,gas:n,data:s,nonce:i,to:o,value:f,gasPrice:h}=t;j_(t);let p=[i?ut(i):"0x",h?ut(h):"0x",n?ut(n):"0x",o??"0x",f?ut(f):"0x",s??"0x"];if(e){const b=(()=>{if(r>0)return BigInt(r*2)+BigInt(35n+e.v-27n);if(e.v>=35n)return(e.v-35n)/2n>0?e.v:27n+(e.v===35n?0n:1n);const v=27n+(e.v===27n?0n:1n);if(e.v!==v)throw new f_({v:e.v});return v})();p=[...p,ut(b),e.r,e.s]}else r>0&&(p=[...p,ut(r),"0x","0x"]);return o0(p)}function q_(t,e){let[r,n="0"]=t.split(".");const s=r.startsWith("-");if(s&&(r=r.slice(1)),n=n.replace(/(0+)$/,""),e===0)Math.round(+`.${n}`)===1&&(r=`${BigInt(r)+1n}`),n="";else if(n.length>e){const[i,o,f]=[n.slice(0,e-1),n.slice(e-1,e),n.slice(e)],h=Math.round(+`${o}.${f}`);h>9?n=`${BigInt(i)+BigInt(1)}0`.padStart(i.length+1,"0"):n=`${i}${h}`,n.length>e&&(n=n.slice(1),r=`${BigInt(r)+1n}`),n=n.slice(0,e)}else n=n.padEnd(e,"0");return BigInt(`${s?"-":""}${r}${n}`)}function S6e(t,e="wei"){return q_(t,s_[e])}function _6e(t,e="wei"){return q_(t,o_[e])}function P6e(t){return t.map(e=>({...e,value:BigInt(e.value)}))}function C6e(t){return{...t,balance:t.balance?BigInt(t.balance):void 0,nonce:t.nonce?er(t.nonce):void 0,storageProof:t.storageProof?P6e(t.storageProof):void 0}}async function I6e(t,{address:e,blockNumber:r,blockTag:n,storageKeys:s}){const i=n??"latest",o=r!==void 0?it(r):void 0,f=await t.request({method:"eth_getProof",params:[e,s,o||i]});return C6e(f)}async function T6e(t,{address:e,blockNumber:r,blockTag:n="latest",slot:s}){const i=r!==void 0?it(r):void 0;return await t.request({method:"eth_getStorageAt",params:[e,s,i||n]})}async function G_(t,{blockHash:e,blockNumber:r,blockTag:n,hash:s,index:i}){var b,v,E;const o=n||"latest",f=r!==void 0?it(r):void 0;let h=null;if(s?h=await t.request({method:"eth_getTransactionByHash",params:[s]}):e?h=await t.request({method:"eth_getTransactionByBlockHashAndIndex",params:[e,it(i)]}):(f||o)&&(h=await t.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[f||o,it(i)]})),!h)throw new c_({blockHash:e,blockNumber:r,blockTag:o,hash:s,index:i});return(((E=(v=(b=t.chain)==null?void 0:b.formatters)==null?void 0:v.transaction)==null?void 0:E.format)||E1)(h)}async function k6e(t,{hash:e,transactionReceipt:r}){const[n,s]=await Promise.all([ct(t,nb,"getBlockNumber")({}),e?ct(t,G_,"getBlockNumber")({hash:e}):void 0]),i=(r==null?void 0:r.blockNumber)||(s==null?void 0:s.blockNumber);return i?n-i+1n:0n}async function J7(t,{hash:e}){var s,i,o;const r=await t.request({method:"eth_getTransactionReceipt",params:[e]});if(!r)throw new u_({hash:e});return(((o=(i=(s=t.chain)==null?void 0:s.formatters)==null?void 0:i.transactionReceipt)==null?void 0:o.format)||O_)(r)}async function R6e(t,e){var P;const{allowFailure:r=!0,batchSize:n,blockNumber:s,blockTag:i,contracts:o,multicallAddress:f}=e,h=n??(typeof((P=t.batch)==null?void 0:P.multicall)=="object"&&t.batch.multicall.batchSize||1024);let p=f;if(!p){if(!t.chain)throw new Error("client chain not configured. multicallAddress is required.");p=zl({blockNumber:s,chain:t.chain,contract:"multicall3"})}const b=[[]];let v=0,E=0;for(let I=0;I0&&E>h&&b[v].length>0&&(v++,E=($.length-2)/2,b[v]=[]),b[v]=[...b[v],{allowFailure:!0,callData:$,target:T}]}catch($){const H=Gp($,{abi:C,address:T,args:B,docsPath:"/docs/contract/multicall",functionName:N});if(!r)throw H;b[v]=[...b[v],{allowFailure:!0,callData:"0x",target:T}]}}const _=await Promise.allSettled(b.map(I=>ct(t,Yo,"readContract")({abi:F6,address:p,args:[I],blockNumber:s,blockTag:i,functionName:"aggregate3"}))),S=[];for(let I=0;I<_.length;I++){const C=_[I];if(C.status==="rejected"){if(!r)throw C.reason;for(let B=0;Bt instanceof Uint8Array,N6e=Array.from({length:256},(t,e)=>e.toString(16).padStart(2,"0"));function Wp(t){if(!Cw(t))throw new Error("Uint8Array expected");let e="";for(let r=0;rn+s.length,0));let r=0;return t.forEach(n=>{if(!Cw(n))throw new Error("Uint8Array expected");e.set(n,r),r+=n.length}),e}function VG(t,e){if(t.length!==e.length)return!1;for(let r=0;rqG;t>>=Pw,e+=1);return e}function $6e(t,e){return t>>BigInt(e)&Pw}const F6e=(t,e,r)=>t|(r?Pw:qG)<(O6e<new Uint8Array(t),zR=t=>Uint8Array.from(t);function KG(t,e,r){if(typeof t!="number"||t<2)throw new Error("hashLen must be a number");if(typeof e!="number"||e<2)throw new Error("qByteLen must be a number");if(typeof r!="function")throw new Error("hmacFn must be a function");let n=e4(t),s=e4(t),i=0;const o=()=>{n.fill(1),s.fill(0),i=0},f=(...v)=>r(s,n,...v),h=(v=e4())=>{s=f(zR([0]),v),n=f(),v.length!==0&&(s=f(zR([1]),v),n=f())},p=()=>{if(i++>=1e3)throw new Error("drbg: tried 1000 values");let v=0;const E=[];for(;v{o(),h(v);let _;for(;!(_=E(p()));)h();return o(),_}}const U6e={bigint:t=>typeof t=="bigint",function:t=>typeof t=="function",boolean:t=>typeof t=="boolean",string:t=>typeof t=="string",stringOrUint8Array:t=>typeof t=="string"||t instanceof Uint8Array,isSafeInteger:t=>Number.isSafeInteger(t),array:t=>Array.isArray(t),field:(t,e)=>e.Fp.isValid(t),hash:t=>typeof t=="function"&&Number.isSafeInteger(t.outputLen)};function C1(t,e,r={}){const n=(s,i,o)=>{const f=U6e[i];if(typeof f!="function")throw new Error(`Invalid validator "${i}", expected function`);const h=t[s];if(!(o&&h===void 0)&&!f(h,t))throw new Error(`Invalid param ${String(s)}=${h} (${typeof h}), expected ${i}`)};for(const[s,i]of Object.entries(e))n(s,i,!1);for(const[s,i]of Object.entries(r))n(s,i,!0);return t}const z6e=Object.freeze(Object.defineProperty({__proto__:null,bitGet:$6e,bitLen:D6e,bitMask:J_,bitSet:F6e,bytesToHex:Wp,bytesToNumberBE:hi,bytesToNumberLE:K_,concatBytes:Xi,createHmacDrbg:KG,ensureBytes:Wn,equalBytes:VG,hexToBytes:Jp,hexToNumber:V_,numberToBytesBE:Pc,numberToBytesLE:W_,numberToHexUnpadded:GG,numberToVarBytesBE:L6e,utf8ToBytes:Iw,validateObject:C1},Symbol.toStringTag,{value:"Module"}));function j6e(t,e){const r=Rt(t)?vn(t):t,n=Rt(e)?vn(e):e;return VG(r,n)}async function WG(t,{address:e,hash:r,signature:n,...s}){const i=Rt(n)?n:ut(n);try{const{data:o}=await ct(t,tb,"call")({data:B_({abi:Uve,args:[e,r,i],bytecode:B6e}),...s});return j6e(o??"0x0","0x1")}catch(o){if(o instanceof l_)return!1;throw o}}async function H6e(t,{address:e,message:r,signature:n,...s}){const i=ob(r);return WG(t,{address:e,hash:i,signature:n,...s})}async function q6e(t,{address:e,signature:r,message:n,primaryType:s,types:i,domain:o,...f}){const h=P1({message:n,primaryType:s,types:i,domain:o});return WG(t,{address:e,hash:h,signature:r,...f})}function JG(t,{emitOnBegin:e=!1,emitMissed:r=!1,onBlockNumber:n,onError:s,poll:i,pollingInterval:o=t.pollingInterval}){const f=typeof i<"u"?i:t.transport.type!=="webSocket";let h;return f?(()=>{const v=cn(["watchBlockNumber",t.uid,e,r,o]);return _1(v,{onBlockNumber:n,onError:s},E=>rb(async()=>{var _;try{const S=await ct(t,nb,"getBlockNumber")({cacheTime:0});if(h){if(S===h)return;if(S-h>1&&r)for(let P=h+1n;Ph)&&(E.onBlockNumber(S,h),h=S)}catch(S){(_=E.onError)==null||_.call(E,S)}},{emitOnBegin:e,interval:o}))})():(()=>{let v=!0,E=()=>v=!1;return(async()=>{try{const{unsubscribe:_}=await t.transport.subscribe({params:["newHeads"],onData(S){var I;if(!v)return;const P=Wt((I=S.result)==null?void 0:I.number);n(P,h),h=P},onError(S){s==null||s(S)}});E=_,v||E()}catch(_){s==null||s(_)}})(),E})()}async function G6e(t,{confirmations:e=1,hash:r,onReplaced:n,pollingInterval:s=t.pollingInterval,timeout:i}){const o=cn(["waitForTransactionReceipt",t.uid,r]);let f,h,p,b=!1;return new Promise((v,E)=>{i&&setTimeout(()=>E(new Nq({hash:r})),i);const _=_1(o,{onReplaced:n,resolve:v,reject:E},S=>{const P=ct(t,JG,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:s,async onBlockNumber(I){if(b)return;let C=I;const T=B=>{P(),B(),_()};try{if(p){if(e>1&&(!p.blockNumber||C-p.blockNumber+1nS.resolve(p));return}if(f||(b=!0,await G7(async()=>{f=await ct(t,G_,"getTransaction")({hash:r}),f.blockNumber&&(C=f.blockNumber)},{delay:({count:B})=>~~(1<1&&(!p.blockNumber||C-p.blockNumber+1nS.resolve(p))}catch(B){if(f&&(B instanceof c_||B instanceof u_))try{h=f,b=!0;const N=await G7(()=>ct(t,_c,"getBlock")({blockNumber:C,includeTransactions:!0}),{delay:({count:J})=>~~(1<J instanceof d_});b=!1;const $=N.transactions.find(({from:J,nonce:Q})=>J===h.from&&Q===h.nonce);if(!$||(p=await ct(t,J7,"getTransactionReceipt")({hash:$.hash}),e>1&&(!p.blockNumber||C-p.blockNumber+1n{var J;(J=S.onReplaced)==null||J.call(S,{reason:H,replacedTransaction:h,transaction:$,transactionReceipt:p}),S.resolve(p)})}catch(N){T(()=>S.reject(N))}else T(()=>S.reject(B))}}})})})}function V6e(t,{blockTag:e="latest",emitMissed:r=!1,emitOnBegin:n=!1,onBlock:s,onError:i,includeTransactions:o,poll:f,pollingInterval:h=t.pollingInterval}){const p=typeof f<"u"?f:t.transport.type!=="webSocket",b=o??!1;let v;return p?(()=>{const S=cn(["watchBlocks",t.uid,r,n,b,h]);return _1(S,{onBlock:s,onError:i},P=>rb(async()=>{var I;try{const C=await ct(t,_c,"getBlock")({blockTag:e,includeTransactions:b});if(C.number&&(v!=null&&v.number)){if(C.number===v.number)return;if(C.number-v.number>1&&r)for(let T=(v==null?void 0:v.number)+1n;Tv.number)&&(P.onBlock(C,v),v=C)}catch(C){(I=P.onError)==null||I.call(P,C)}},{emitOnBegin:n,interval:h}))})():(()=>{let S=!0,P=()=>S=!1;return(async()=>{try{const{unsubscribe:I}=await t.transport.subscribe({params:["newHeads"],onData(C){var N,$,H;if(!S)return;const B=(((H=($=(N=t.chain)==null?void 0:N.formatters)==null?void 0:$.block)==null?void 0:H.format)||vw)(C.result);s(B,v),v=B},onError(C){i==null||i(C)}});P=I,S||P()}catch(I){i==null||i(I)}})(),P})()}function K6e(t,{address:e,args:r,batch:n=!0,event:s,events:i,onError:o,onLogs:f,poll:h,pollingInterval:p=t.pollingInterval,strict:b}){const v=typeof h<"u"?h:t.transport.type!=="webSocket",E=b??!1;return v?(()=>{const P=cn(["watchEvent",e,r,n,t.uid,s,p]);return _1(P,{onLogs:f,onError:o},I=>{let C,T,B=!1;const N=rb(async()=>{var $;if(!B){try{T=await ct(t,uG,"createEventFilter")({address:e,args:r,event:s,events:i,strict:E})}catch{}B=!0;return}try{let H;if(T)H=await ct(t,ww,"getFilterChanges")({filter:T});else{const J=await ct(t,nb,"getBlockNumber")({});C&&C!==J?H=await ct(t,x_,"getLogs")({address:e,args:r,event:s,events:i,fromBlock:C+1n,toBlock:J}):H=[],C=J}if(H.length===0)return;if(n)I.onLogs(H);else for(const J of H)I.onLogs([J])}catch(H){T&&H instanceof Mc&&(B=!1),($=I.onError)==null||$.call(I,H)}},{emitOnBegin:!0,interval:p});return async()=>{T&&await ct(t,Aw,"uninstallFilter")({filter:T}),N()}})})():(()=>{let P=!0,I=()=>P=!1;return(async()=>{try{const C=i??(s?[s]:void 0);let T=[];C&&(T=[C.flatMap(N=>x1({abi:[N],eventName:N.name,args:r}))],s&&(T=T[0]));const{unsubscribe:B}=await t.transport.subscribe({params:["logs",{address:e,topics:T}],onData(N){var H;if(!P)return;const $=N.result;try{const{eventName:J,args:Q}=M1({abi:C,data:$.data,topics:$.topics,strict:E}),K=Ws($,{args:Q,eventName:J});f([K])}catch(J){let Q,K;if(J instanceof Ac||J instanceof Nl){if(b)return;Q=J.abiItem.name,K=(H=J.abiItem.inputs)==null?void 0:H.some(w=>!("name"in w&&w.name))}const se=Ws($,{args:K?[]:{},eventName:Q});f([se])}},onError(N){o==null||o(N)}});I=B,P||I()}catch(C){o==null||o(C)}})(),I})()}function W6e(t,{batch:e=!0,onError:r,onTransactions:n,poll:s,pollingInterval:i=t.pollingInterval}){return(typeof s<"u"?s:t.transport.type!=="webSocket")?(()=>{const p=cn(["watchPendingTransactions",t.uid,e,i]);return _1(p,{onTransactions:n,onError:r},b=>{let v;const E=rb(async()=>{var _;try{if(!v)try{v=await ct(t,lG,"createPendingTransactionFilter")({});return}catch(P){throw E(),P}const S=await ct(t,ww,"getFilterChanges")({filter:v});if(S.length===0)return;if(e)b.onTransactions(S);else for(const P of S)b.onTransactions([P])}catch(S){(_=b.onError)==null||_.call(b,S)}},{emitOnBegin:!0,interval:i});return async()=>{v&&await ct(t,Aw,"uninstallFilter")({filter:v}),E()}})})():(()=>{let p=!0,b=()=>p=!1;return(async()=>{try{const{unsubscribe:v}=await t.transport.subscribe({params:["newPendingTransactions"],onData(E){if(!p)return;const _=E.result;n([_])},onError(E){r==null||r(E)}});b=v,p||b()}catch(v){r==null||r(v)}})(),b})()}function ZG(t){return{call:e=>tb(t,e),createBlockFilter:()=>P2e(t),createContractEventFilter:e=>n_(t,e),createEventFilter:e=>uG(t,e),createPendingTransactionFilter:()=>lG(t),estimateContractGas:e=>Wq(t,e),estimateGas:e=>v_(t,e),getBalance:e=>C2e(t,e),getBlock:e=>_c(t,e),getBlockNumber:e=>nb(t,e),getBlockTransactionCount:e=>I2e(t,e),getBytecode:e=>hG(t,e),getChainId:()=>Vp(t),getContractEvents:e=>w_(t,e),getEnsAddress:e=>h2e(t,e),getEnsAvatar:e=>M2e(t,e),getEnsName:e=>S2e(t,e),getEnsResolver:e=>_2e(t,e),getEnsText:e=>cG(t,e),getFeeHistory:e=>k2e(t,e),estimateFeesPerGas:e=>Vq(t,e),getFilterChanges:e=>ww(t,e),getFilterLogs:e=>R2e(t,e),getGasPrice:()=>y_(t),getLogs:e=>x_(t,e),getProof:e=>I6e(t,e),estimateMaxPriorityFeePerGas:e=>Nve(t,e),getStorageAt:e=>T6e(t,e),getTransaction:e=>G_(t,e),getTransactionConfirmations:e=>k6e(t,e),getTransactionCount:e=>Kq(t,e),getTransactionReceipt:e=>J7(t,e),multicall:e=>R6e(t,e),prepareTransactionRequest:e=>xw(t,e),readContract:e=>Yo(t,e),sendRawTransaction:e=>S_(t,e),simulateContract:e=>Xq(t,e),verifyMessage:e=>H6e(t,e),verifyTypedData:e=>q6e(t,e),uninstallFilter:e=>Aw(t,e),waitForTransactionReceipt:e=>G6e(t,e),watchBlocks:e=>V6e(t,e),watchBlockNumber:e=>JG(t,e),watchContractEvent:e=>eG(t,e),watchEvent:e=>K6e(t,e),watchPendingTransactions:e=>W6e(t,e)}}function QG(t){const{key:e="public",name:r="Public Client"}=t;return jl({...t,key:e,name:r,type:"publicClient"}).extend(ZG)}async function J6e(t,{hash:e}){await t.request({method:`${t.mode}_dropTransaction`,params:[e]})}async function Z6e(t){return t.request({method:`${t.mode}_dumpState`})}async function Q6e(t){return t.mode==="ganache"?await t.request({method:"eth_mining"}):await t.request({method:`${t.mode}_getAutomine`})}async function Y6e(t){return await t.request({method:"txpool_content"})}async function X6e(t){const{pending:e,queued:r}=await t.request({method:"txpool_status"});return{pending:er(e),queued:er(r)}}async function e5e(t,{address:e}){await t.request({method:`${t.mode}_impersonateAccount`,params:[e]})}async function t5e(t,{seconds:e}){return await t.request({method:"evm_increaseTime",params:[it(e)]})}async function r5e(t){return await t.request({method:"txpool_inspect"})}async function n5e(t,{state:e}){await t.request({method:`${t.mode}_loadState`,params:[e]})}async function i5e(t,{blocks:e,interval:r}){t.mode==="ganache"?await t.request({method:"evm_mine",params:[{blocks:it(e)}]}):await t.request({method:`${t.mode}_mine`,params:[it(e),it(r||0)]})}async function s5e(t){await t.request({method:`${t.mode}_removeBlockTimestampInterval`})}async function o5e(t,{blockNumber:e,jsonRpcUrl:r}={}){await t.request({method:`${t.mode}_reset`,params:[{forking:{blockNumber:Number(e),jsonRpcUrl:r}}]})}async function a5e(t,{id:e}){await t.request({method:"evm_revert",params:[e]})}async function f5e(t,e){var C,T,B;const{accessList:r,data:n,from:s,gas:i,gasPrice:o,maxFeePerGas:f,maxPriorityFeePerGas:h,nonce:p,to:b,value:v,...E}=e,_=(B=(T=(C=t.chain)==null?void 0:C.formatters)==null?void 0:T.transactionRequest)==null?void 0:B.format,P=(_||Fl)({...gw(E,{format:_}),accessList:r,data:n,from:s,gas:i,gasPrice:o,maxFeePerGas:f,maxPriorityFeePerGas:h,nonce:p,to:b,value:v});return await t.request({method:"eth_sendUnsignedTransaction",params:[P]})}async function c5e(t,e){t.mode==="ganache"?e?await t.request({method:"miner_start"}):await t.request({method:"miner_stop"}):await t.request({method:"evm_setAutomine",params:[e]})}async function u5e(t,{address:e,value:r}){t.mode==="ganache"?await t.request({method:"evm_setAccountBalance",params:[e,it(r)]}):await t.request({method:`${t.mode}_setBalance`,params:[e,it(r)]})}async function l5e(t,{gasLimit:e}){await t.request({method:"evm_setBlockGasLimit",params:[it(e)]})}async function h5e(t,{interval:e}){const r=(()=>t.mode==="hardhat"?e*1e3:e)();await t.request({method:`${t.mode}_setBlockTimestampInterval`,params:[r]})}async function d5e(t,{address:e,bytecode:r}){await t.request({method:`${t.mode}_setCode`,params:[e,r]})}async function p5e(t,{address:e}){await t.request({method:`${t.mode}_setCoinbase`,params:[e]})}async function m5e(t,{interval:e}){const r=(()=>t.mode==="hardhat"?e*1e3:e)();await t.request({method:"evm_setIntervalMining",params:[r]})}async function g5e(t,e){await t.request({method:`${t.mode}_setLoggingEnabled`,params:[e]})}async function y5e(t,{gasPrice:e}){await t.request({method:`${t.mode}_setMinGasPrice`,params:[it(e)]})}async function b5e(t,{baseFeePerGas:e}){await t.request({method:`${t.mode}_setNextBlockBaseFeePerGas`,params:[it(e)]})}async function v5e(t,{timestamp:e}){await t.request({method:"evm_setNextBlockTimestamp",params:[it(e)]})}async function x5e(t,{address:e,nonce:r}){await t.request({method:`${t.mode}_setNonce`,params:[e,it(r)]})}async function w5e(t,e){await t.request({method:`${t.mode}_setRpcUrl`,params:[e]})}async function A5e(t,{address:e,index:r,value:n}){await t.request({method:`${t.mode}_setStorageAt`,params:[e,typeof r=="number"?it(r):r,n]})}async function E5e(t){return await t.request({method:"evm_snapshot"})}async function M5e(t,{address:e}){await t.request({method:`${t.mode}_stopImpersonatingAccount`,params:[e]})}function YG({mode:t}){return e=>{const r=e.extend(()=>({mode:t}));return{dropTransaction:n=>J6e(r,n),dumpState:()=>Z6e(r),getAutomine:()=>Q6e(r),getTxpoolContent:()=>Y6e(r),getTxpoolStatus:()=>X6e(r),impersonateAccount:n=>e5e(r,n),increaseTime:n=>t5e(r,n),inspectTxpool:()=>r5e(r),loadState:n=>n5e(r,n),mine:n=>i5e(r,n),removeBlockTimestampInterval:()=>s5e(r),reset:n=>o5e(r,n),revert:n=>a5e(r,n),sendUnsignedTransaction:n=>f5e(r,n),setAutomine:n=>c5e(r,n),setBalance:n=>u5e(r,n),setBlockGasLimit:n=>l5e(r,n),setBlockTimestampInterval:n=>h5e(r,n),setCode:n=>d5e(r,n),setCoinbase:n=>p5e(r,n),setIntervalMining:n=>m5e(r,n),setLoggingEnabled:n=>g5e(r,n),setMinGasPrice:n=>y5e(r,n),setNextBlockBaseFeePerGas:n=>b5e(r,n),setNextBlockTimestamp:n=>v5e(r,n),setNonce:n=>x5e(r,n),setRpcUrl:n=>w5e(r,n),setStorageAt:n=>A5e(r,n),snapshot:()=>E5e(r),stopImpersonatingAccount:n=>M5e(r,n)}}}function S5e(t){const{key:e="test",name:r="Test Client",mode:n}=t;return jl({...t,key:e,name:r,type:"testClient"}).extend(i=>({mode:n,...YG({mode:n})(i)}))}function _5e(t,{abi:e,args:r,bytecode:n,...s}){const i=B_({abi:e,args:r,bytecode:n});return __(t,{...s,data:i})}async function P5e(t){var r;return((r=t.account)==null?void 0:r.type)==="local"?[t.account.address]:(await t.request({method:"eth_accounts"})).map(n=>Yy(n))}async function C5e(t){return await t.request({method:"wallet_getPermissions"})}async function I5e(t){return(await t.request({method:"eth_requestAccounts"})).map(r=>Ec(r))}async function T5e(t,e){return t.request({method:"wallet_requestPermissions",params:[e]})}async function XG(t,{account:e=t.account,message:r}){if(!e)throw new w1({docsPath:"/docs/actions/wallet/signMessage"});const n=co(e);if(n.type==="local")return n.signMessage({message:r});const s=(()=>typeof r=="string"?Qy(r):r.raw instanceof Uint8Array?ut(r.raw):r.raw)();return t.request({method:"personal_sign",params:[s,n.address]})}async function k5e(t,e){var p,b,v,E;const{account:r=t.account,chain:n=t.chain,...s}=e;if(!r)throw new w1({docsPath:"/docs/actions/wallet/signTransaction"});const i=co(r);A1({account:i,...e});const o=await ct(t,Vp,"getChainId")({});n!==null&&M_({currentChainId:o,chain:n});const f=(n==null?void 0:n.formatters)||((p=t.chain)==null?void 0:p.formatters),h=((b=f==null?void 0:f.transactionRequest)==null?void 0:b.format)||Fl;return i.type==="local"?i.signTransaction({...s,chainId:o},{serializer:(E=(v=t.chain)==null?void 0:v.serializers)==null?void 0:E.transaction}):await t.request({method:"eth_signTransaction",params:[{...h(s),chainId:it(o),from:i.address}]})}async function Z7(t,{account:e=t.account,domain:r,message:n,primaryType:s,types:i}){if(!e)throw new w1({docsPath:"/docs/actions/wallet/signTypedData"});const o=co(e),f={EIP712Domain:sb({domain:r}),...i};if(_w({domain:r,message:n,primaryType:s,types:f}),o.type==="local")return o.signTypedData({domain:r,primaryType:s,types:f,message:n});const h=cn({domain:r??{},primaryType:s,types:f,message:n},(p,b)=>Rt(b)?b.toLowerCase():b);return t.request({method:"eth_signTypedData_v4",params:[o.address,h]})}async function R5e(t,{id:e}){await t.request({method:"wallet_switchEthereumChain",params:[{chainId:it(e)}]})}async function B5e(t,e){return await t.request({method:"wallet_watchAsset",params:e})}function eV(t){return{addChain:e=>e2e(t,e),deployContract:e=>_5e(t,e),getAddresses:()=>P5e(t),getChainId:()=>Vp(t),getPermissions:()=>C5e(t),prepareTransactionRequest:e=>xw(t,e),requestAddresses:()=>I5e(t),requestPermissions:e=>T5e(t,e),sendRawTransaction:e=>S_(t,e),sendTransaction:e=>__(t,e),signMessage:e=>XG(t,e),signTransaction:e=>k5e(t,e),signTypedData:e=>Z7(t,e),switchChain:e=>R5e(t,e),watchAsset:e=>B5e(t,e),writeContract:e=>tG(t,e)}}function tV(t){const{key:e="wallet",name:r="Wallet Client",transport:n}=t;return jl({...t,key:e,name:r,transport:i=>n({...i,retryCount:0}),type:"walletClient"}).extend(eV)}function O5e(t,e={}){const{key:r="webSocket",name:n="WebSocket JSON-RPC",retryDelay:s}=e;return({chain:i,retryCount:o,timeout:f})=>{var v;const h=e.retryCount??o,p=f??e.timeout??1e4,b=t||((v=i==null?void 0:i.rpcUrls.default.webSocket)==null?void 0:v[0]);if(!b)throw new P_;return ib({key:r,name:n,async request({method:E,params:_}){const S={method:E,params:_},P=await Q8(b),{error:I,result:C}=await id.webSocketAsync(P,{body:S,timeout:p});if(I)throw new mw({body:S,error:I,url:b});return C},retryCount:h,retryDelay:s,timeout:p,type:"webSocket"},{getSocket(){return Q8(b)},async subscribe({params:E,onData:_,onError:S}){const P=await Q8(b),{result:I}=await new Promise((C,T)=>id.webSocket(P,{body:{method:"eth_subscribe",params:E},onResponse(B){if(B.error){T(B.error),S==null||S(B.error);return}if(typeof B.id=="number"){C(B);return}B.method==="eth_subscription"&&_(B.params)}}));return{subscriptionId:I,async unsubscribe(){return new Promise(C=>id.webSocket(P,{body:{method:"eth_unsubscribe",params:[I]},onResponse:C}))}}}})}}const Q7="0x0000000000000000000000000000000000000000",N5e=2n**(8n-1n)-1n,L5e=2n**(16n-1n)-1n,D5e=2n**(24n-1n)-1n,$5e=2n**(32n-1n)-1n,F5e=2n**(40n-1n)-1n,U5e=2n**(48n-1n)-1n,z5e=2n**(56n-1n)-1n,j5e=2n**(64n-1n)-1n,H5e=2n**(72n-1n)-1n,q5e=2n**(80n-1n)-1n,G5e=2n**(88n-1n)-1n,V5e=2n**(96n-1n)-1n,K5e=2n**(104n-1n)-1n,W5e=2n**(112n-1n)-1n,J5e=2n**(120n-1n)-1n,Z5e=2n**(128n-1n)-1n,Q5e=2n**(136n-1n)-1n,Y5e=2n**(144n-1n)-1n,X5e=2n**(152n-1n)-1n,exe=2n**(160n-1n)-1n,txe=2n**(168n-1n)-1n,rxe=2n**(176n-1n)-1n,nxe=2n**(184n-1n)-1n,ixe=2n**(192n-1n)-1n,sxe=2n**(200n-1n)-1n,oxe=2n**(208n-1n)-1n,axe=2n**(216n-1n)-1n,fxe=2n**(224n-1n)-1n,cxe=2n**(232n-1n)-1n,uxe=2n**(240n-1n)-1n,lxe=2n**(248n-1n)-1n,hxe=2n**(256n-1n)-1n,dxe=-(2n**(8n-1n)),pxe=-(2n**(16n-1n)),mxe=-(2n**(24n-1n)),gxe=-(2n**(32n-1n)),yxe=-(2n**(40n-1n)),bxe=-(2n**(48n-1n)),vxe=-(2n**(56n-1n)),xxe=-(2n**(64n-1n)),wxe=-(2n**(72n-1n)),Axe=-(2n**(80n-1n)),Exe=-(2n**(88n-1n)),Mxe=-(2n**(96n-1n)),Sxe=-(2n**(104n-1n)),_xe=-(2n**(112n-1n)),Pxe=-(2n**(120n-1n)),Cxe=-(2n**(128n-1n)),Ixe=-(2n**(136n-1n)),Txe=-(2n**(144n-1n)),kxe=-(2n**(152n-1n)),Rxe=-(2n**(160n-1n)),Bxe=-(2n**(168n-1n)),Oxe=-(2n**(176n-1n)),Nxe=-(2n**(184n-1n)),Lxe=-(2n**(192n-1n)),Dxe=-(2n**(200n-1n)),$xe=-(2n**(208n-1n)),Fxe=-(2n**(216n-1n)),Uxe=-(2n**(224n-1n)),zxe=-(2n**(232n-1n)),jxe=-(2n**(240n-1n)),Hxe=-(2n**(248n-1n)),qxe=-(2n**(256n-1n)),Gxe=2n**8n-1n,Vxe=2n**16n-1n,Kxe=2n**24n-1n,Wxe=2n**32n-1n,Jxe=2n**40n-1n,Zxe=2n**48n-1n,Qxe=2n**56n-1n,Yxe=2n**64n-1n,Xxe=2n**72n-1n,ewe=2n**80n-1n,twe=2n**88n-1n,rwe=2n**96n-1n,nwe=2n**104n-1n,iwe=2n**112n-1n,swe=2n**120n-1n,owe=2n**128n-1n,awe=2n**136n-1n,fwe=2n**144n-1n,cwe=2n**152n-1n,uwe=2n**160n-1n,lwe=2n**168n-1n,hwe=2n**176n-1n,dwe=2n**184n-1n,pwe=2n**192n-1n,mwe=2n**200n-1n,gwe=2n**208n-1n,ywe=2n**216n-1n,bwe=2n**224n-1n,vwe=2n**232n-1n,xwe=2n**240n-1n,wwe=2n**248n-1n,Awe=2n**256n-1n,Ewe="0x0000000000000000000000000000000000000000000000000000000000000000",t4="/docs/contract/decodeDeployData";function Mwe({abi:t,bytecode:e,data:r}){if(r===e)return{bytecode:e};const n=t.find(i=>"type"in i&&i.type==="constructor");if(!n)throw new US({docsPath:t4});if(!("inputs"in n))throw new Rg({docsPath:t4});if(!n.inputs||n.inputs.length===0)throw new Rg({docsPath:t4});return{args:Ll(n.inputs,`0x${r.replace(e,"")}`),bytecode:e}}function Swe({r:t,yParityAndS:e}){const r=i0(e),n=r[0]&128?28n:27n,s=r;return n===28n&&(s[0]&=127),{r:t,s:Fi(s),v:n}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const xn=BigInt(0),Kr=BigInt(1),su=BigInt(2),_we=BigInt(3),Y7=BigInt(4),jR=BigInt(5),HR=BigInt(8);BigInt(9);BigInt(16);function bn(t,e){const r=t%e;return r>=xn?r:e+r}function Pwe(t,e,r){if(r<=xn||e 0");if(r===Kr)return xn;let n=Kr;for(;e>xn;)e&Kr&&(n=n*t%r),t=t*t%r,e>>=Kr;return n}function bs(t,e,r){let n=t;for(;e-- >xn;)n*=n,n%=r;return n}function X7(t,e){if(t===xn||e<=xn)throw new Error(`invert: expected positive integers, got n=${t} mod=${e}`);let r=bn(t,e),n=e,s=xn,i=Kr;for(;r!==xn;){const f=n/r,h=n%r,p=s-i*f;n=r,r=h,s=i,i=p}if(n!==Kr)throw new Error("invert: does not exist");return bn(s,e)}function Cwe(t){const e=(t-Kr)/su;let r,n,s;for(r=t-Kr,n=0;r%su===xn;r/=su,n++);for(s=su;s(n[s]="function",n),e);return C1(t,r)}function kwe(t,e,r){if(r 0");if(r===xn)return t.ONE;if(r===Kr)return e;let n=t.ONE,s=e;for(;r>xn;)r&Kr&&(n=t.mul(n,s)),s=t.sqr(s),r>>=Kr;return n}function Rwe(t,e){const r=new Array(e.length),n=e.reduce((i,o,f)=>t.is0(o)?i:(r[f]=i,t.mul(i,o)),t.ONE),s=t.inv(n);return e.reduceRight((i,o,f)=>t.is0(o)?i:(r[f]=t.mul(i,r[f]),t.mul(i,o)),s),r}function nV(t,e){const r=e!==void 0?e:t.toString(2).length,n=Math.ceil(r/8);return{nBitLength:r,nByteLength:n}}function Bwe(t,e,r=!1,n={}){if(t<=xn)throw new Error(`Expected Field ORDER > 0, got ${t}`);const{nBitLength:s,nByteLength:i}=nV(t,e);if(i>2048)throw new Error("Field lengths over 2048 bytes are not supported");const o=Iwe(t),f=Object.freeze({ORDER:t,BITS:s,BYTES:i,MASK:J_(s),ZERO:xn,ONE:Kr,create:h=>bn(h,t),isValid:h=>{if(typeof h!="bigint")throw new Error(`Invalid field element: expected bigint, got ${typeof h}`);return xn<=h&&hh===xn,isOdd:h=>(h&Kr)===Kr,neg:h=>bn(-h,t),eql:(h,p)=>h===p,sqr:h=>bn(h*h,t),add:(h,p)=>bn(h+p,t),sub:(h,p)=>bn(h-p,t),mul:(h,p)=>bn(h*p,t),pow:(h,p)=>kwe(f,h,p),div:(h,p)=>bn(h*X7(p,t),t),sqrN:h=>h*h,addN:(h,p)=>h+p,subN:(h,p)=>h-p,mulN:(h,p)=>h*p,inv:h=>X7(h,t),sqrt:n.sqrt||(h=>o(f,h)),invertBatch:h=>Rwe(f,h),cmov:(h,p,b)=>b?p:h,toBytes:h=>r?W_(h,i):Pc(h,i),fromBytes:h=>{if(h.length!==i)throw new Error(`Fp.fromBytes: expected ${i}, got ${h.length}`);return r?K_(h):hi(h)}});return Object.freeze(f)}function iV(t){if(typeof t!="bigint")throw new Error("field order must be bigint");const e=t.toString(2).length;return Math.ceil(e/8)}function sV(t){const e=iV(t);return e+Math.ceil(e/2)}function Owe(t,e,r=!1){const n=t.length,s=iV(e),i=sV(e);if(n<16||n1024)throw new Error(`expected ${i}-1024 bytes of input, got ${n}`);const o=r?hi(t):K_(t),f=bn(o,e-Kr)+Kr;return r?W_(f,s):Pc(f,s)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const Nwe=BigInt(0),r4=BigInt(1);function Lwe(t,e){const r=(s,i)=>{const o=i.negate();return s?o:i},n=s=>{const i=Math.ceil(e/s)+1,o=2**(s-1);return{windows:i,windowSize:o}};return{constTimeNegate:r,unsafeLadder(s,i){let o=t.ZERO,f=s;for(;i>Nwe;)i&r4&&(o=o.add(f)),f=f.double(),i>>=r4;return o},precomputeWindow(s,i){const{windows:o,windowSize:f}=n(i),h=[];let p=s,b=p;for(let v=0;v>=_,I>h&&(I-=E,o+=r4);const C=P,T=P+Math.abs(I)-1,B=S%2!==0,N=I<0;I===0?b=b.add(r(B,i[C])):p=p.add(r(N,i[T]))}return{p,f:b}},wNAFCached(s,i,o,f){const h=s._WINDOW_SIZE||1;let p=i.get(s);return p||(p=this.precomputeWindow(s,h),h!==1&&i.set(s,f(p))),this.wNAF(h,p,o)}}}function oV(t){return rV(t.Fp),C1(t,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...nV(t.n,t.nBitLength),...t,p:t.Fp.ORDER})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function Dwe(t){const e=oV(t);C1(e,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:r,Fp:n,a:s}=e;if(r){if(!n.eql(s,n.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if(typeof r!="object"||typeof r.beta!="bigint"||typeof r.splitScalar!="function")throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...e})}const{bytesToNumberBE:$we,hexToBytes:Fwe}=z6e,gu={Err:class extends Error{constructor(e=""){super(e)}},_parseInt(t){const{Err:e}=gu;if(t.length<2||t[0]!==2)throw new e("Invalid signature integer tag");const r=t[1],n=t.subarray(2,r+2);if(!r||n.length!==r)throw new e("Invalid signature integer: wrong length");if(n[0]&128)throw new e("Invalid signature integer: negative");if(n[0]===0&&!(n[1]&128))throw new e("Invalid signature integer: unnecessary leading zero");return{d:$we(n),l:t.subarray(r+2)}},toSig(t){const{Err:e}=gu,r=typeof t=="string"?Fwe(t):t;if(!(r instanceof Uint8Array))throw new Error("ui8a expected");let n=r.length;if(n<2||r[0]!=48)throw new e("Invalid signature tag");if(r[1]!==n-2)throw new e("Invalid signature: incorrect length");const{d:s,l:i}=gu._parseInt(r.subarray(2)),{d:o,l:f}=gu._parseInt(i);if(f.length)throw new e("Invalid signature: left bytes after parsing");return{r:s,s:o}},hexFromSig(t){const e=p=>Number.parseInt(p[0],16)&8?"00"+p:p,r=p=>{const b=p.toString(16);return b.length&1?`0${b}`:b},n=e(r(t.s)),s=e(r(t.r)),i=n.length/2,o=s.length/2,f=r(i),h=r(o);return`30${r(o+i+4)}02${h}${s}02${f}${n}`}},Ro=BigInt(0),Lr=BigInt(1),g0=BigInt(2),j6=BigInt(3),qR=BigInt(4);function Uwe(t){const e=Dwe(t),{Fp:r}=e,n=e.toBytes||((S,P,I)=>{const C=P.toAffine();return Xi(Uint8Array.from([4]),r.toBytes(C.x),r.toBytes(C.y))}),s=e.fromBytes||(S=>{const P=S.subarray(1),I=r.fromBytes(P.subarray(0,r.BYTES)),C=r.fromBytes(P.subarray(r.BYTES,2*r.BYTES));return{x:I,y:C}});function i(S){const{a:P,b:I}=e,C=r.sqr(S),T=r.mul(C,S);return r.add(r.add(T,r.mul(S,P)),I)}if(!r.eql(r.sqr(e.Gy),i(e.Gx)))throw new Error("bad generator point: equation left != right");function o(S){return typeof S=="bigint"&&Ror.eql(B,r.ZERO);return T(I)&&T(C)?v.ZERO:new v(I,C,r.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(P){const I=r.invertBatch(P.map(C=>C.pz));return P.map((C,T)=>C.toAffine(I[T])).map(v.fromAffine)}static fromHex(P){const I=v.fromAffine(s(Wn("pointHex",P)));return I.assertValidity(),I}static fromPrivateKey(P){return v.BASE.multiply(h(P))}_setWindowSize(P){this._WINDOW_SIZE=P,p.delete(this)}assertValidity(){if(this.is0()){if(e.allowInfinityPoint&&!r.is0(this.py))return;throw new Error("bad point: ZERO")}const{x:P,y:I}=this.toAffine();if(!r.isValid(P)||!r.isValid(I))throw new Error("bad point: x or y not FE");const C=r.sqr(I),T=i(P);if(!r.eql(C,T))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:P}=this.toAffine();if(r.isOdd)return!r.isOdd(P);throw new Error("Field doesn't support isOdd")}equals(P){b(P);const{px:I,py:C,pz:T}=this,{px:B,py:N,pz:$}=P,H=r.eql(r.mul(I,$),r.mul(B,T)),J=r.eql(r.mul(C,$),r.mul(N,T));return H&&J}negate(){return new v(this.px,r.neg(this.py),this.pz)}double(){const{a:P,b:I}=e,C=r.mul(I,j6),{px:T,py:B,pz:N}=this;let $=r.ZERO,H=r.ZERO,J=r.ZERO,Q=r.mul(T,T),K=r.mul(B,B),se=r.mul(N,N),w=r.mul(T,B);return w=r.add(w,w),J=r.mul(T,N),J=r.add(J,J),$=r.mul(P,J),H=r.mul(C,se),H=r.add($,H),$=r.sub(K,H),H=r.add(K,H),H=r.mul($,H),$=r.mul(w,$),J=r.mul(C,J),se=r.mul(P,se),w=r.sub(Q,se),w=r.mul(P,w),w=r.add(w,J),J=r.add(Q,Q),Q=r.add(J,Q),Q=r.add(Q,se),Q=r.mul(Q,w),H=r.add(H,Q),se=r.mul(B,N),se=r.add(se,se),Q=r.mul(se,w),$=r.sub($,Q),J=r.mul(se,K),J=r.add(J,J),J=r.add(J,J),new v($,H,J)}add(P){b(P);const{px:I,py:C,pz:T}=this,{px:B,py:N,pz:$}=P;let H=r.ZERO,J=r.ZERO,Q=r.ZERO;const K=e.a,se=r.mul(e.b,j6);let w=r.mul(I,B),a=r.mul(C,N),u=r.mul(T,$),l=r.add(I,C),d=r.add(B,N);l=r.mul(l,d),d=r.add(w,a),l=r.sub(l,d),d=r.add(I,T);let m=r.add(B,$);return d=r.mul(d,m),m=r.add(w,u),d=r.sub(d,m),m=r.add(C,T),H=r.add(N,$),m=r.mul(m,H),H=r.add(a,u),m=r.sub(m,H),Q=r.mul(K,d),H=r.mul(se,u),Q=r.add(H,Q),H=r.sub(a,Q),Q=r.add(a,Q),J=r.mul(H,Q),a=r.add(w,w),a=r.add(a,w),u=r.mul(K,u),d=r.mul(se,d),a=r.add(a,u),u=r.sub(w,u),u=r.mul(K,u),d=r.add(d,u),w=r.mul(a,d),J=r.add(J,w),w=r.mul(m,d),H=r.mul(l,H),H=r.sub(H,w),w=r.mul(l,a),Q=r.mul(m,Q),Q=r.add(Q,w),new v(H,J,Q)}subtract(P){return this.add(P.negate())}is0(){return this.equals(v.ZERO)}wNAF(P){return _.wNAFCached(this,p,P,I=>{const C=r.invertBatch(I.map(T=>T.pz));return I.map((T,B)=>T.toAffine(C[B])).map(v.fromAffine)})}multiplyUnsafe(P){const I=v.ZERO;if(P===Ro)return I;if(f(P),P===Lr)return this;const{endo:C}=e;if(!C)return _.unsafeLadder(this,P);let{k1neg:T,k1:B,k2neg:N,k2:$}=C.splitScalar(P),H=I,J=I,Q=this;for(;B>Ro||$>Ro;)B&Lr&&(H=H.add(Q)),$&Lr&&(J=J.add(Q)),Q=Q.double(),B>>=Lr,$>>=Lr;return T&&(H=H.negate()),N&&(J=J.negate()),J=new v(r.mul(J.px,C.beta),J.py,J.pz),H.add(J)}multiply(P){f(P);let I=P,C,T;const{endo:B}=e;if(B){const{k1neg:N,k1:$,k2neg:H,k2:J}=B.splitScalar(I);let{p:Q,f:K}=this.wNAF($),{p:se,f:w}=this.wNAF(J);Q=_.constTimeNegate(N,Q),se=_.constTimeNegate(H,se),se=new v(r.mul(se.px,B.beta),se.py,se.pz),C=Q.add(se),T=K.add(w)}else{const{p:N,f:$}=this.wNAF(I);C=N,T=$}return v.normalizeZ([C,T])[0]}multiplyAndAddUnsafe(P,I,C){const T=v.BASE,B=($,H)=>H===Ro||H===Lr||!$.equals(T)?$.multiplyUnsafe(H):$.multiply(H),N=B(this,I).add(B(P,C));return N.is0()?void 0:N}toAffine(P){const{px:I,py:C,pz:T}=this,B=this.is0();P==null&&(P=B?r.ONE:r.inv(T));const N=r.mul(I,P),$=r.mul(C,P),H=r.mul(T,P);if(B)return{x:r.ZERO,y:r.ZERO};if(!r.eql(H,r.ONE))throw new Error("invZ was invalid");return{x:N,y:$}}isTorsionFree(){const{h:P,isTorsionFree:I}=e;if(P===Lr)return!0;if(I)return I(v,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:P,clearCofactor:I}=e;return P===Lr?this:I?I(v,this):this.multiplyUnsafe(e.h)}toRawBytes(P=!0){return this.assertValidity(),n(v,this,P)}toHex(P=!0){return Wp(this.toRawBytes(P))}}v.BASE=new v(e.Gx,e.Gy,r.ONE),v.ZERO=new v(r.ZERO,r.ONE,r.ZERO);const E=e.nBitLength,_=Lwe(v,e.endo?Math.ceil(E/2):E);return{CURVE:e,ProjectivePoint:v,normPrivateKeyToScalar:h,weierstrassEquation:i,isWithinCurveOrder:o}}function zwe(t){const e=oV(t);return C1(e,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...e})}function jwe(t){const e=zwe(t),{Fp:r,n}=e,s=r.BYTES+1,i=2*r.BYTES+1;function o(d){return RoWp(Pc(d,e.nByteLength));function S(d){const m=n>>Lr;return d>m}function P(d){return S(d)?f(-d):d}const I=(d,m,x)=>hi(d.slice(m,x));class C{constructor(m,x,A){this.r=m,this.s=x,this.recovery=A,this.assertValidity()}static fromCompact(m){const x=e.nByteLength;return m=Wn("compactSignature",m,x*2),new C(I(m,0,x),I(m,x,2*x))}static fromDER(m){const{r:x,s:A}=gu.toSig(Wn("DER",m));return new C(x,A)}assertValidity(){if(!E(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!E(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(m){return new C(this.r,this.s,m)}recoverPublicKey(m){const{r:x,s:A,recovery:y}=this,c=J(Wn("msgHash",m));if(y==null||![0,1,2,3].includes(y))throw new Error("recovery id invalid");const g=y===2||y===3?x+e.n:x;if(g>=r.ORDER)throw new Error("recovery id 2 or 3 invalid");const M=y&1?"03":"02",R=p.fromHex(M+_(g)),L=h(g),k=f(-c*L),D=f(A*L),U=p.BASE.multiplyAndAddUnsafe(R,k,D);if(!U)throw new Error("point at infinify");return U.assertValidity(),U}hasHighS(){return S(this.s)}normalizeS(){return this.hasHighS()?new C(this.r,f(-this.s),this.recovery):this}toDERRawBytes(){return Jp(this.toDERHex())}toDERHex(){return gu.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Jp(this.toCompactHex())}toCompactHex(){return _(this.r)+_(this.s)}}const T={isValidPrivateKey(d){try{return b(d),!0}catch{return!1}},normPrivateKeyToScalar:b,randomPrivateKey:()=>{const d=sV(e.n);return Owe(e.randomBytes(d),e.n)},precompute(d=8,m=p.BASE){return m._setWindowSize(d),m.multiply(BigInt(3)),m}};function B(d,m=!0){return p.fromPrivateKey(d).toRawBytes(m)}function N(d){const m=d instanceof Uint8Array,x=typeof d=="string",A=(m||x)&&d.length;return m?A===s||A===i:x?A===2*s||A===2*i:d instanceof p}function $(d,m,x=!0){if(N(d))throw new Error("first arg must be private key");if(!N(m))throw new Error("second arg must be public key");return p.fromHex(m).multiply(b(d)).toRawBytes(x)}const H=e.bits2int||function(d){const m=hi(d),x=d.length*8-e.nBitLength;return x>0?m>>BigInt(x):m},J=e.bits2int_modN||function(d){return f(H(d))},Q=J_(e.nBitLength);function K(d){if(typeof d!="bigint")throw new Error("bigint expected");if(!(Ro<=d&&dG in x))throw new Error("sign() legacy options not supported");const{hash:A,randomBytes:y}=e;let{lowS:c,prehash:g,extraEntropy:M}=x;c==null&&(c=!0),d=Wn("msgHash",d),g&&(d=Wn("prehashed msgHash",A(d)));const R=J(d),L=b(m),k=[K(L),K(R)];if(M!=null){const G=M===!0?y(r.BYTES):M;k.push(Wn("extraEntropy",G))}const D=Xi(...k),U=R;function V(G){const Y=H(G);if(!E(Y))return;const q=h(Y),z=p.BASE.multiply(Y).toAffine(),ee=f(z.x);if(ee===Ro)return;const re=f(q*f(U+ee*L));if(re===Ro)return;let ie=(z.x===ee?0:2)|Number(z.y&Lr),ae=re;return c&&S(re)&&(ae=P(re),ie^=1),new C(ee,ae,ie)}return{seed:D,k2sig:V}}const w={lowS:e.lowS,prehash:!1},a={lowS:e.lowS,prehash:!1};function u(d,m,x=w){const{seed:A,k2sig:y}=se(d,m,x),c=e;return KG(c.hash.outputLen,c.nByteLength,c.hmac)(A,y)}p.BASE._setWindowSize(8);function l(d,m,x,A=a){var z;const y=d;if(m=Wn("msgHash",m),x=Wn("publicKey",x),"strict"in A)throw new Error("options.strict was renamed to lowS");const{lowS:c,prehash:g}=A;let M,R;try{if(typeof y=="string"||y instanceof Uint8Array)try{M=C.fromDER(y)}catch(ee){if(!(ee instanceof gu.Err))throw ee;M=C.fromCompact(y)}else if(typeof y=="object"&&typeof y.r=="bigint"&&typeof y.s=="bigint"){const{r:ee,s:re}=y;M=new C(ee,re)}else throw new Error("PARSE");R=p.fromHex(x)}catch(ee){if(ee.message==="PARSE")throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(c&&M.hasHighS())return!1;g&&(m=e.hash(m));const{r:L,s:k}=M,D=J(m),U=h(k),V=f(D*U),G=f(L*U),Y=(z=p.BASE.multiplyAndAddUnsafe(R,V,G))==null?void 0:z.toAffine();return Y?f(Y.x)===L:!1}return{CURVE:e,getPublicKey:B,getSharedSecret:$,sign:u,verify:l,ProjectivePoint:p,Signature:C,utils:T}}function Hwe(t,e){const r=t.ORDER;let n=Ro;for(let S=r-Lr;S%g0===Ro;S/=g0)n+=Lr;const s=n,i=g0<{let I=v,C=t.pow(P,p),T=t.sqr(C);T=t.mul(T,P);let B=t.mul(S,T);B=t.pow(B,h),B=t.mul(B,C),C=t.mul(B,P),T=t.mul(B,S);let N=t.mul(T,C);B=t.pow(N,b);let $=t.eql(B,t.ONE);C=t.mul(T,E),B=t.mul(N,I),T=t.cmov(C,T,$),N=t.cmov(B,N,$);for(let H=s;H>Lr;H--){let J=H-g0;J=g0<{let T=t.sqr(C);const B=t.mul(I,C);T=t.mul(T,B);let N=t.pow(T,S);N=t.mul(N,B);const $=t.mul(N,P),H=t.mul(t.sqr(N),C),J=t.eql(H,I);let Q=t.cmov($,N,J);return{isValid:J,value:Q}}}return _}function qwe(t,e){if(rV(t),!t.isValid(e.A)||!t.isValid(e.B)||!t.isValid(e.Z))throw new Error("mapToCurveSimpleSWU: invalid opts");const r=Hwe(t,e.Z);if(!t.isOdd)throw new Error("Fp.isOdd is not implemented!");return n=>{let s,i,o,f,h,p,b,v;s=t.sqr(n),s=t.mul(s,e.Z),i=t.sqr(s),i=t.add(i,s),o=t.add(i,t.ONE),o=t.mul(o,e.B),f=t.cmov(e.Z,t.neg(i),!t.eql(i,t.ZERO)),f=t.mul(f,e.A),i=t.sqr(o),p=t.sqr(f),h=t.mul(p,e.A),i=t.add(i,h),i=t.mul(i,o),p=t.mul(p,f),h=t.mul(p,e.B),i=t.add(i,h),b=t.mul(s,o);const{isValid:E,value:_}=r(i,p);v=t.mul(s,n),v=t.mul(v,_),b=t.cmov(b,o,E),v=t.cmov(v,_,E);const S=t.isOdd(n)===t.isOdd(v);return v=t.cmov(t.neg(v),v,S),b=t.div(b,f),{x:b,y:v}}}function Gwe(t){if(t instanceof Uint8Array)return t;if(typeof t=="string")return Iw(t);throw new Error("DST must be Uint8Array or string")}const Vwe=hi;function S0(t,e){if(t<0||t>=1<<8*e)throw new Error(`bad I2OSP call: value=${t} length=${e}`);const r=Array.from({length:e}).fill(0);for(let n=e-1;n>=0;n--)r[n]=t&255,t>>>=8;return new Uint8Array(r)}function Kwe(t,e){const r=new Uint8Array(t.length);for(let n=0;n255&&(e=n(Xi(Iw("H2C-OVERSIZE-DST-"),e)));const{outputLen:s,blockLen:i}=n,o=Math.ceil(r/s);if(o>255)throw new Error("Invalid xmd length");const f=Xi(e,S0(e.length,1)),h=S0(0,i),p=S0(r,2),b=new Array(o),v=n(Xi(h,t,p,S0(0,1),f));b[0]=n(Xi(v,S0(1,1),f));for(let _=1;_<=o;_++){const S=[Kwe(v,b[_-1]),S0(_+1,1),f];b[_]=n(Xi(...S))}return Xi(...b).slice(0,r)}function Jwe(t,e,r,n,s){if(Bg(t),Bg(e),Z_(r),e.length>255){const i=Math.ceil(2*n/8);e=s.create({dkLen:i}).update(Iw("H2C-OVERSIZE-DST-")).update(e).digest()}if(r>65535||e.length>255)throw new Error("expand_message_xof: invalid lenInBytes");return s.create({dkLen:r}).update(t).update(S0(r,2)).update(e).update(S0(e.length,1)).digest()}function GR(t,e,r){C1(r,{DST:"stringOrUint8Array",p:"bigint",m:"isSafeInteger",k:"isSafeInteger",hash:"hash"});const{p:n,k:s,m:i,hash:o,expand:f,DST:h}=r;Bg(t),Z_(e);const p=Gwe(h),b=n.toString(2).length,v=Math.ceil((b+s)/8),E=e*i*v;let _;if(f==="xmd")_=Wwe(t,p,E,o);else if(f==="xof")_=Jwe(t,p,E,s,o);else if(f==="_internal_pass")_=t;else throw new Error('expand must be "xmd" or "xof"');const S=new Array(e);for(let P=0;PArray.from(n).reverse());return(n,s)=>{const[i,o,f,h]=r.map(p=>p.reduce((b,v)=>t.add(t.mul(b,n),v)));return n=t.div(i,o),s=t.mul(s,t.div(f,h)),{x:n,y:s}}}function Qwe(t,e,r){if(typeof e!="function")throw new Error("mapToCurve() must be defined");return{hashToCurve(n,s){const i=GR(n,2,{...r,DST:r.DST,...s}),o=t.fromAffine(e(i[0])),f=t.fromAffine(e(i[1])),h=o.add(f).clearCofactor();return h.assertValidity(),h},encodeToCurve(n,s){const i=GR(n,1,{...r,DST:r.encodeDST,...s}),o=t.fromAffine(e(i[0])).clearCofactor();return o.assertValidity(),o}}}class aV extends QS{constructor(e,r){super(),this.finished=!1,this.destroyed=!1,Hbe(e);const n=cw(r);if(this.iHash=e.create(),typeof this.iHash.update!="function")throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const s=this.blockLen,i=new Uint8Array(s);i.set(n.length>s?e.create().update(n).digest():n);for(let o=0;onew aV(t,e).update(r).digest();fV.create=(t,e)=>new aV(t,e);/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function Ywe(t){return{hash:t,hmac:(e,...r)=>fV(t,e,Xbe(...r)),randomBytes:vq}}function Xwe(t,e){const r=n=>jwe({...t,...Ywe(n)});return Object.freeze({...r(e),create:r})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const Tw=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),H6=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),cV=BigInt(1),q6=BigInt(2),VR=(t,e)=>(t+e/q6)/e;function uV(t){const e=Tw,r=BigInt(3),n=BigInt(6),s=BigInt(11),i=BigInt(22),o=BigInt(23),f=BigInt(44),h=BigInt(88),p=t*t*t%e,b=p*p*t%e,v=bs(b,r,e)*b%e,E=bs(v,r,e)*b%e,_=bs(E,q6,e)*p%e,S=bs(_,s,e)*_%e,P=bs(S,i,e)*S%e,I=bs(P,f,e)*P%e,C=bs(I,h,e)*I%e,T=bs(C,f,e)*P%e,B=bs(T,r,e)*b%e,N=bs(B,o,e)*S%e,$=bs(N,n,e)*p%e,H=bs($,q6,e);if(!Cc.eql(Cc.sqr(H),t))throw new Error("Cannot find square root");return H}const Cc=Bwe(Tw,void 0,void 0,{sqrt:uV}),a0=Xwe({a:BigInt(0),b:BigInt(7),Fp:Cc,n:H6,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:t=>{const e=H6,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),n=-cV*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),s=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),i=r,o=BigInt("0x100000000000000000000000000000000"),f=VR(i*t,e),h=VR(-n*t,e);let p=bn(t-f*r-h*s,e),b=bn(-f*n-h*i,e);const v=p>o,E=b>o;if(v&&(p=e-p),E&&(b=e-b),p>o||b>o)throw new Error("splitScalar: Endomorphism failed, k="+t);return{k1neg:v,k1:p,k2neg:E,k2:b}}}},Kp),kw=BigInt(0),lV=t=>typeof t=="bigint"&&kwtypeof t=="bigint"&&kws.charCodeAt(0)));r=Xi(n,n),KR[t]=r}return Kp(Xi(r,...e))}const Q_=t=>t.toRawBytes(!0).slice(1),eA=t=>Pc(t,32),n4=t=>bn(t,Tw),Og=t=>bn(t,H6),Y_=a0.ProjectivePoint,t3e=(t,e,r)=>Y_.BASE.multiplyAndAddUnsafe(t,e,r);function tA(t){let e=a0.utils.normPrivateKeyToScalar(t),r=Y_.fromPrivateKey(e);return{scalar:r.hasEvenY()?e:Og(-e),bytes:Q_(r)}}function hV(t){if(!lV(t))throw new Error("bad x: need 0 < x < p");const e=n4(t*t),r=n4(e*t+BigInt(7));let n=uV(r);n%q6!==kw&&(n=n4(-n));const s=new Y_(t,n,cV);return s.assertValidity(),s}function dV(...t){return Og(hi(G6("BIP0340/challenge",...t)))}function r3e(t){return tA(t).bytes}function n3e(t,e,r=vq(32)){const n=Wn("message",t),{bytes:s,scalar:i}=tA(e),o=Wn("auxRand",r,32),f=eA(i^hi(G6("BIP0340/aux",o))),h=G6("BIP0340/nonce",f,s,n),p=Og(hi(h));if(p===kw)throw new Error("sign failed: k is zero");const{bytes:b,scalar:v}=tA(p),E=dV(b,s,n),_=new Uint8Array(64);if(_.set(b,0),_.set(eA(Og(v+E*i)),32),!pV(_,n,s))throw new Error("sign: Invalid signature produced");return _}function pV(t,e,r){const n=Wn("signature",t,64),s=Wn("message",e),i=Wn("publicKey",r,32);try{const o=hV(hi(i)),f=hi(n.subarray(0,32));if(!lV(f))return!1;const h=hi(n.subarray(32,64));if(!e3e(h))return!1;const p=dV(eA(f),Q_(o),s),b=t3e(o,h,Og(-p));return!(!b||!b.hasEvenY()||b.toAffine().x!==f)}catch{return!1}}const i3e=(()=>({getPublicKey:r3e,sign:n3e,verify:pV,utils:{randomPrivateKey:a0.utils.randomPrivateKey,lift_x:hV,pointToBytes:Q_,numberToBytesBE:Pc,bytesToNumberBE:hi,taggedHash:G6,mod:bn}}))(),s3e=(()=>Zwe(Cc,[["0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa8c7","0x7d3d4c80bc321d5b9f315cea7fd44c5d595d2fc0bf63b92dfff1044f17c6581","0x534c328d23f234e6e2a413deca25caece4506144037c40314ecbd0b53d9dd262","0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa88c"],["0xd35771193d94918a9ca34ccbb7b640dd86cd409542f8487d9fe6b745781eb49b","0xedadc6f64383dc1df7c4b2d51b54225406d36b641f5e41bbc52a56612a8c6d14","0x0000000000000000000000000000000000000000000000000000000000000001"],["0x4bda12f684bda12f684bda12f684bda12f684bda12f684bda12f684b8e38e23c","0xc75e0c32d5cb7c0fa9d0a54b12a0a6d5647ab046d686da6fdffc90fc201d71a3","0x29a6194691f91a73715209ef6512e576722830a201be2018a765e85a9ecee931","0x2f684bda12f684bda12f684bda12f684bda12f684bda12f684bda12f38e38d84"],["0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffff93b","0x7a06534bb8bdb49fd5e9e6632722c2989467c1bfc8e8d978dfb425d2685c2573","0x6484aa716545ca2cf3a70c3fa8fe337e0a3d21162f0d6299a7bf8192bfd2a76f","0x0000000000000000000000000000000000000000000000000000000000000001"]].map(t=>t.map(e=>BigInt(e)))))(),o3e=(()=>qwe(Cc,{A:BigInt("0x3f8731abdd661adca08a5558f0f5d272e953d363cb6f0e5d405447c01a444533"),B:BigInt("1771"),Z:Cc.create(BigInt("-11"))}))(),mV=(()=>Qwe(a0.ProjectivePoint,t=>{const{x:e,y:r}=o3e(Cc.create(t[0]));return s3e(e,r)},{DST:"secp256k1_XMD:SHA-256_SSWU_RO_",encodeDST:"secp256k1_XMD:SHA-256_SSWU_NU_",p:Cc.ORDER,m:1,k:128,expand:"xmd",hash:Kp}))(),a3e=(()=>mV.hashToCurve)(),f3e=(()=>mV.encodeToCurve)(),c3e=Object.freeze(Object.defineProperty({__proto__:null,encodeToCurve:f3e,hashToCurve:a3e,schnorr:i3e,secp256k1:a0},Symbol.toStringTag,{value:"Module"}));function u3e(t){const{r:e,s:r}=a0.Signature.fromCompact(t.slice(2,130));return{r:it(e,{size:32}),yParityAndS:it(r,{size:32})}}function l3e(t){const{r:e,s:r}=a0.Signature.fromCompact(t.slice(2,130)),n=BigInt(`0x${t.slice(130)}`);return{r:it(e,{size:32}),s:it(r,{size:32}),v:n}}function h3e(t){const{r:e,s:r,v:n}=t,s=n-27n;let i=r;if(s===1n){const o=i0(r);o[0]|=128,i=Fi(o)}return{r:e,yParityAndS:i}}function d3e({r:t,yParityAndS:e}){return`0x${new a0.Signature(Wt(t),Wt(e)).toCompactHex()}`}function gV({r:t,s:e,v:r}){return`0x${new a0.Signature(Wt(t),Wt(e)).toCompactHex()}${ut(r).slice(2)}`}const p3e=Object.freeze(Object.defineProperty({__proto__:null,AbiConstructorNotFoundError:US,AbiConstructorParamsNotFoundError:Rg,AbiDecodingDataSizeInvalidError:Bbe,AbiDecodingDataSizeTooSmallError:aw,AbiDecodingZeroDataError:Zy,AbiEncodingArrayLengthMismatchError:ZH,AbiEncodingBytesSizeMismatchError:QH,AbiEncodingLengthMismatchError:zS,AbiErrorInputsNotFoundError:YH,AbiErrorNotFoundError:U7,AbiErrorSignatureNotFoundError:jS,AbiEventNotFoundError:z7,AbiEventSignatureEmptyTopicsError:XH,AbiEventSignatureNotFoundError:eq,AbiFunctionNotFoundError:ml,AbiFunctionOutputsNotFoundError:HS,AbiFunctionSignatureNotFoundError:tq,BaseError:Ue,BaseFeeScalarError:Hq,BlockNotFoundError:d_,BytesSizeMismatchError:qS,CallExecutionError:l_,ChainDisconnectedError:Hp,ChainDoesNotSupportContract:U6,ChainMismatchError:Qq,ChainNotFoundError:Yq,CircularReferenceError:GH,ClientChainNotConfiguredError:A_,ContractFunctionExecutionError:Lq,ContractFunctionRevertedError:C6,ContractFunctionZeroDataError:Dq,DataLengthTooLongError:Nbe,DataLengthTooShortError:Lbe,DecodeLogDataMismatch:Ac,DecodeLogTopicsMismatch:Nl,Eip1559FeesNotSupportedError:bw,EnsAvatarInvalidNftUriError:hh,EnsAvatarUnsupportedNamespaceError:oG,EnsAvatarUriResolutionError:Mw,EstimateGasExecutionError:Uq,ExecutionRevertedError:mu,FeeCapTooHighError:$a,FeeCapTooLowError:T6,FeeConflictError:Tq,FilterTypeNotSupportedError:aq,HttpRequestError:dc,InsufficientFundsError:O6,IntegerOutOfRangeError:cq,InternalRpcError:gl,IntrinsicGasTooHighError:N6,IntrinsicGasTooLowError:L6,InvalidAbiDecodingTypeError:nq,InvalidAbiEncodingTypeError:rq,InvalidAbiItemError:OH,InvalidAbiParameterError:LH,InvalidAbiParametersError:DH,InvalidAbiTypeParameterError:jH,InvalidAddressError:un,InvalidArrayError:iq,InvalidBytesBooleanError:uq,InvalidChainIdError:S1,InvalidDefinitionTypeError:sq,InvalidFunctionModifierError:zH,InvalidHexBooleanError:lq,InvalidHexValueError:hq,InvalidInputRpcError:Mc,InvalidLegacyVError:f_,InvalidModifierError:UH,InvalidParameterError:$H,InvalidParamsRpcError:Bp,InvalidParenthesisError:VH,InvalidRequestRpcError:kp,InvalidSerializableTransactionError:kq,InvalidSerializedTransactionError:dw,InvalidSerializedTransactionTypeError:Rq,InvalidSignatureError:Oh,InvalidStorageKeySizeError:Bq,InvalidStructSignatureError:qH,JsonRpcVersionUnsupportedError:Fp,LimitExceededRpcError:$p,MaxFeePerGasTooLowError:qq,MethodNotFoundRpcError:Rp,MethodNotSupportedRpcError:Dp,NonceMaxValueError:B6,NonceTooHighError:k6,NonceTooLowError:R6,OffsetOutOfBoundsError:Dbe,ParseRpcError:Tp,ProviderDisconnectedError:jp,ProviderRpcError:$l,RawContractError:pw,ResourceNotFoundRpcError:Op,ResourceUnavailableRpcError:Np,RpcError:vi,RpcRequestError:mw,SizeExceedsPaddingSizeError:VS,SizeOverflowError:dq,SliceOffsetOutOfBoundsError:GS,SolidityProtectedKeywordError:FH,SwitchChainError:qp,TimeoutError:I6,TipAboveFeeCapError:Sc,TransactionExecutionError:Oq,TransactionNotFoundError:c_,TransactionReceiptNotFoundError:u_,TransactionRejectedRpcError:Lp,TransactionTypeNotSupportedError:D6,UnauthorizedProviderError:Up,UnknownNodeError:eb,UnknownRpcError:Fq,UnknownSignatureError:HH,UnknownTypeError:NH,UnsupportedPackedAbiType:oq,UnsupportedProviderMethodError:zp,UrlRequiredError:P_,UserRejectedRequestError:Ju,WaitForTransactionReceiptTimeoutError:Nq,WebSocketRequestError:$q,assertCurrentChain:M_,assertRequest:A1,assertTransactionEIP1559:U_,assertTransactionEIP2930:z_,assertTransactionLegacy:j_,boolToBytes:pq,boolToHex:fw,bytesToBigInt:W7,bytesToBigint:W7,bytesToBool:CG,bytesToHex:Fi,bytesToNumber:IG,bytesToRlp:W2e,bytesToString:TG,ccipFetch:k_,checksumAddress:Yy,compactSignatureToHex:d3e,compactSignatureToSignature:Swe,concat:cs,concatBytes:Eq,concatHex:fo,createClient:jl,createPublicClient:QG,createTestClient:S5e,createTransport:ib,createWalletClient:tV,custom:i2e,decodeAbiParameters:Ll,decodeDeployData:Mwe,decodeErrorResult:i_,decodeEventLog:M1,decodeFunctionData:j2e,decodeFunctionResult:Ul,defineBlock:g_,defineChain:Vc,defineTransaction:m_,defineTransactionReceipt:N_,defineTransactionRequest:jq,domainSeparator:z2e,encodeAbiParameters:s0,encodeDeployData:B_,encodeErrorResult:H2e,encodeEventTopics:x1,encodeFunctionData:mi,encodeFunctionResult:G2e,encodePacked:od,etherUnits:s_,extractChain:D2e,fallback:s2e,formatBlock:vw,formatEther:Dl,formatGwei:li,formatLog:Ws,formatTransaction:E1,formatTransactionReceipt:O_,formatTransactionRequest:Fl,formatUnits:a_,fromBytes:X2e,fromHex:$be,fromRlp:L_,getAbiItem:Gc,getAddress:Ec,getChainContractAddress:zl,getContract:Xve,getContractAddress:SG,getContractError:Gp,getCreate2Address:PG,getCreateAddress:_G,getEventSelector:uw,getEventSignature:gq,getFunctionSelector:v1,getFunctionSignature:JS,getSerializedTransactionType:UG,getTransactionType:b_,getTypesForEIP712Domain:sb,gweiUnits:o_,hashDomain:R_,hashMessage:ob,hashTypedData:P1,hexToBigInt:Wt,hexToBool:KS,hexToBytes:i0,hexToCompactSignature:u3e,hexToNumber:er,hexToRlp:J2e,hexToSignature:l3e,hexToString:WS,http:sd,isAddress:wr,isAddressEqual:Sw,isBytes:K7,isHash:RG,isHex:Rt,keccak256:zr,labelhash:sG,maxInt104:K5e,maxInt112:W5e,maxInt120:J5e,maxInt128:Z5e,maxInt136:Q5e,maxInt144:Y5e,maxInt152:X5e,maxInt16:L5e,maxInt160:exe,maxInt168:txe,maxInt176:rxe,maxInt184:nxe,maxInt192:ixe,maxInt200:sxe,maxInt208:oxe,maxInt216:axe,maxInt224:fxe,maxInt232:cxe,maxInt24:D5e,maxInt240:uxe,maxInt248:lxe,maxInt256:hxe,maxInt32:$5e,maxInt40:F5e,maxInt48:U5e,maxInt56:z5e,maxInt64:j5e,maxInt72:H5e,maxInt8:N5e,maxInt80:q5e,maxInt88:G5e,maxInt96:V5e,maxUint104:nwe,maxUint112:iwe,maxUint120:swe,maxUint128:owe,maxUint136:awe,maxUint144:fwe,maxUint152:cwe,maxUint16:Vxe,maxUint160:uwe,maxUint168:lwe,maxUint176:hwe,maxUint184:dwe,maxUint192:pwe,maxUint200:mwe,maxUint208:gwe,maxUint216:ywe,maxUint224:bwe,maxUint232:vwe,maxUint24:Kxe,maxUint240:xwe,maxUint248:wwe,maxUint256:Awe,maxUint32:Wxe,maxUint40:Jxe,maxUint48:Zxe,maxUint56:Qxe,maxUint64:Yxe,maxUint72:Xxe,maxUint8:Gxe,maxUint80:ewe,maxUint88:twe,maxUint96:rwe,minInt104:Sxe,minInt112:_xe,minInt120:Pxe,minInt128:Cxe,minInt136:Ixe,minInt144:Txe,minInt152:kxe,minInt16:pxe,minInt160:Rxe,minInt168:Bxe,minInt176:Oxe,minInt184:Nxe,minInt192:Lxe,minInt200:Dxe,minInt208:$xe,minInt216:Fxe,minInt224:Uxe,minInt232:zxe,minInt24:mxe,minInt240:jxe,minInt248:Hxe,minInt256:qxe,minInt32:gxe,minInt40:yxe,minInt48:bxe,minInt56:vxe,minInt64:xxe,minInt72:wxe,minInt8:dxe,minInt80:Axe,minInt88:Exe,minInt96:Mxe,multicall3Abi:F6,namehash:zm,numberToBytes:mq,numberToHex:it,offchainLookup:pG,offchainLookupAbiItem:T_,offchainLookupSignature:dG,pad:Uo,padBytes:fq,padHex:zo,parseAbi:Sbe,parseAbiItem:_be,parseAbiParameter:Pbe,parseAbiParameters:Cbe,parseEther:S6e,parseGwei:_6e,parseTransaction:b6e,parseUnits:q_,presignMessagePrefix:DG,publicActions:ZG,recoverAddress:F_,recoverMessageAddress:$G,recoverPublicKey:LG,recoverTypedDataAddress:FG,ripemd160:m6e,rpcTransactionType:zq,serializeAccessList:ab,serializeTransaction:H_,sha256:o6e,signatureToCompactSignature:h3e,signatureToHex:gV,size:Wr,slice:Sr,sliceBytes:_q,sliceHex:e_,stringToBytes:Ra,stringToHex:Qy,stringify:cn,testActions:YG,toBytes:vn,toHex:ut,toRlp:o0,transactionType:p_,trim:rn,validateTypedData:_w,verifyMessage:g6e,verifyTypedData:y6e,walletActions:eV,webSocket:O5e,weiUnits:kve,zeroAddress:Q7,zeroHash:Ewe},Symbol.toStringTag,{value:"Module"})),m3e=iW(p3e);var Zp={};Object.defineProperty(Zp,"__esModule",{value:!0});Zp.MAGIC_VALUE_BYTES=Zp.MAGIC_VALUE=void 0;const g3e="0x1626ba7e";Zp.MAGIC_VALUE=g3e;const y3e="0x20c13b0b";Zp.MAGIC_VALUE_BYTES=y3e;var X_={},fb={},yl={};Object.defineProperty(yl,"__esModule",{value:!0});yl.PermissionsError=yl.PERMISSIONS_REQUEST_REJECTED=void 0;yl.PERMISSIONS_REQUEST_REJECTED=4001;class eP extends Error{constructor(e,r,n){super(e),this.code=r,this.data=n,Object.setPrototypeOf(this,eP.prototype)}}yl.PermissionsError=eP;Object.defineProperty(fb,"__esModule",{value:!0});fb.Wallet=void 0;const i4=Ol,ov=yl;let b3e=class{constructor(e){this.communicator=e}async getPermissions(){return(await this.communicator.send(i4.Methods.wallet_getPermissions,void 0)).data}async requestPermissions(e){if(!this.isPermissionRequestValid(e))throw new ov.PermissionsError("Permissions request is invalid",ov.PERMISSIONS_REQUEST_REJECTED);try{return(await this.communicator.send(i4.Methods.wallet_requestPermissions,e)).data}catch{throw new ov.PermissionsError("Permissions rejected",ov.PERMISSIONS_REQUEST_REJECTED)}}isPermissionRequestValid(e){return e.every(r=>typeof r=="object"?Object.keys(r).every(n=>!!Object.values(i4.RestrictedMethods).includes(n)):!1)}};fb.Wallet=b3e;Object.defineProperty(X_,"__esModule",{value:!0});const v3e=fb,WR=yl,JR=(t,e)=>e.some(r=>r.parentCapability===t),x3e=()=>(t,e,r)=>{const n=r.value;return r.value=async function(){const s=new v3e.Wallet(this.communicator);let i=await s.getPermissions();if(JR(e,i)||(i=await s.requestPermissions([{[e]:{}}])),!JR(e,i))throw new WR.PermissionsError("Permissions rejected",WR.PERMISSIONS_REQUEST_REJECTED);return n.apply(this)},r};X_.default=x3e;var w3e=Ke&&Ke.__decorate||function(t,e,r,n){var s=arguments.length,i=s<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,r,n);else for(var f=t.length-1;f>=0;f--)(o=t[f])&&(i=(s<3?o(i):s>3?o(e,r,i):o(e,r))||i);return s>3&&i&&Object.defineProperty(e,r,i),i},A3e=Ke&&Ke.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(iw,"__esModule",{value:!0});iw.Safe=void 0;const av=m3e,ZR=Zp,y0=Ol,QR=Wy,E3e=ew,M3e=A3e(X_);let yV=class{constructor(e){this.communicator=e}async getChainInfo(){return(await this.communicator.send(y0.Methods.getChainInfo,void 0)).data}async getInfo(){return(await this.communicator.send(y0.Methods.getSafeInfo,void 0)).data}async experimental_getBalances({currency:e="usd"}={}){return(await this.communicator.send(y0.Methods.getSafeBalances,{currency:e})).data}async check1271Signature(e,r="0x"){const n=await this.getInfo(),s=(0,av.encodeFunctionData)({abi:[{constant:!1,inputs:[{name:"_dataHash",type:"bytes32"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[e,r]}),i={call:QR.RPC_CALLS.eth_call,params:[{to:n.safeAddress,data:s},"latest"]};try{return(await this.communicator.send(y0.Methods.rpcCall,i)).data.slice(0,10).toLowerCase()===ZR.MAGIC_VALUE}catch{return!1}}async check1271SignatureBytes(e,r="0x"){const n=await this.getInfo(),s=(0,av.encodeFunctionData)({abi:[{constant:!1,inputs:[{name:"_data",type:"bytes"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[e,r]}),i={call:QR.RPC_CALLS.eth_call,params:[{to:n.safeAddress,data:s},"latest"]};try{return(await this.communicator.send(y0.Methods.rpcCall,i)).data.slice(0,10).toLowerCase()===ZR.MAGIC_VALUE_BYTES}catch{return!1}}calculateMessageHash(e){return(0,av.hashMessage)(e)}calculateTypedMessageHash(e){const r=typeof e.domain.chainId=="object"?e.domain.chainId.toNumber():Number(e.domain.chainId);let n=e.primaryType;if(!n){const s=Object.values(e.types),i=Object.keys(e.types).filter(o=>s.every(f=>f.every(({type:h})=>h.replace("[","").replace("]","")!==o)));if(i.length===0||i.length>1)throw new Error("Please specify primaryType");n=i[0]}return(0,av.hashTypedData)({message:e.message,domain:Object.assign(Object.assign({},e.domain),{chainId:r,verifyingContract:e.domain.verifyingContract,salt:e.domain.salt}),types:e.types,primaryType:n})}async getOffChainSignature(e){return(await this.communicator.send(y0.Methods.getOffChainSignature,e)).data}async isMessageSigned(e,r="0x"){let n;if(typeof e=="string"&&(n=async()=>{const s=this.calculateMessageHash(e);return await this.isMessageHashSigned(s,r)}),(0,E3e.isObjectEIP712TypedData)(e)&&(n=async()=>{const s=this.calculateTypedMessageHash(e);return await this.isMessageHashSigned(s,r)}),n)return await n();throw new Error("Invalid message type")}async isMessageHashSigned(e,r="0x"){const n=[this.check1271Signature.bind(this),this.check1271SignatureBytes.bind(this)];for(const s of n)if(await s(e,r))return!0;return!1}async getEnvironmentInfo(){return(await this.communicator.send(y0.Methods.getEnvironmentInfo,void 0)).data}async requestAddressBook(){return(await this.communicator.send(y0.Methods.requestAddressBook,void 0)).data}};w3e([(0,M3e.default)()],yV.prototype,"requestAddressBook",null);iw.Safe=yV;var S3e=Ke&&Ke.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(M6,"__esModule",{value:!0});const _3e=S3e(hH),P3e=Xx,C3e=nw,I3e=iw,T3e=fb;let k3e=class{constructor(e={}){const{allowedDomains:r=null,debug:n=!1}=e;this.communicator=new _3e.default(r,n),this.eth=new C3e.Eth(this.communicator),this.txs=new P3e.TXs(this.communicator),this.safe=new I3e.Safe(this.communicator),this.wallet=new T3e.Wallet(this.communicator)}};M6.default=k3e;(function(t){var e=Ke&&Ke.__createBinding||(Object.create?function(o,f,h,p){p===void 0&&(p=h);var b=Object.getOwnPropertyDescriptor(f,h);(!b||("get"in b?!f.__esModule:b.writable||b.configurable))&&(b={enumerable:!0,get:function(){return f[h]}}),Object.defineProperty(o,p,b)}:function(o,f,h,p){p===void 0&&(p=h),o[p]=f[h]}),r=Ke&&Ke.__exportStar||function(o,f){for(var h in o)h!=="default"&&!Object.prototype.hasOwnProperty.call(f,h)&&e(f,o,h)},n=Ke&&Ke.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(t,"__esModule",{value:!0}),t.getSDKVersion=void 0;const s=n(M6);t.default=s.default,r(M6,t),r(ew,t),r(Ol,t),r(Vy,t);var i=Ky;Object.defineProperty(t,"getSDKVersion",{enumerable:!0,get:function(){return i.getSDKVersion}})})(lH);const R3e=Qs(lH);var bV={},Rw={},Bw={};Object.defineProperty(Bw,"__esModule",{value:!0});Bw.getLowerCase=void 0;function B3e(t){return t&&t.toLowerCase()}Bw.getLowerCase=B3e;Object.defineProperty(Rw,"__esModule",{value:!0});Rw.SafeAppProvider=void 0;const O3e=dx,fv=Bw;class N3e extends O3e.EventEmitter{constructor(e,r){super(),this.submittedTxs=new Map,this.safe=e,this.sdk=r}async connect(){this.emit("connect",{chainId:this.chainId})}async disconnect(){}get chainId(){return this.safe.chainId}async request(e){const{method:r,params:n=[]}=e;switch(r){case"eth_accounts":return[this.safe.safeAddress];case"net_version":case"eth_chainId":return`0x${this.chainId.toString(16)}`;case"personal_sign":{const[h,p]=n;if(this.safe.safeAddress.toLowerCase()!==p.toLowerCase())throw new Error("The address or message hash is invalid");const b=await this.sdk.txs.signMessage(h);return("signature"in b?b.signature:void 0)||"0x"}case"eth_sign":{const[h,p]=n;if(this.safe.safeAddress.toLowerCase()!==h.toLowerCase()||!p.startsWith("0x"))throw new Error("The address or message hash is invalid");const b=await this.sdk.txs.signMessage(p);return("signature"in b?b.signature:void 0)||"0x"}case"eth_signTypedData":case"eth_signTypedData_v4":{const[h,p]=n,b=typeof p=="string"?JSON.parse(p):p;if(this.safe.safeAddress.toLowerCase()!==h.toLowerCase())throw new Error("The address is invalid");const v=await this.sdk.txs.signTypedMessage(b);return("signature"in v?v.signature:void 0)||"0x"}case"eth_sendTransaction":const s=Object.assign({value:"0",data:"0x"},n[0]);typeof s.gas=="string"&&s.gas.startsWith("0x")&&(s.gas=parseInt(s.gas,16));const i=await this.sdk.txs.send({txs:[s],params:{safeTxGas:s.gas}});return this.submittedTxs.set(i.safeTxHash,{from:this.safe.safeAddress,hash:i.safeTxHash,gas:0,gasPrice:"0x00",nonce:0,input:s.data,value:s.value,to:s.to,blockHash:null,blockNumber:null,transactionIndex:null}),i.safeTxHash;case"eth_blockNumber":return(await this.sdk.eth.getBlockByNumber(["latest"])).number;case"eth_getBalance":return this.sdk.eth.getBalance([(0,fv.getLowerCase)(n[0]),n[1]]);case"eth_getCode":return this.sdk.eth.getCode([(0,fv.getLowerCase)(n[0]),n[1]]);case"eth_getTransactionCount":return this.sdk.eth.getTransactionCount([(0,fv.getLowerCase)(n[0]),n[1]]);case"eth_getStorageAt":return this.sdk.eth.getStorageAt([(0,fv.getLowerCase)(n[0]),n[1],n[2]]);case"eth_getBlockByNumber":return this.sdk.eth.getBlockByNumber([n[0],n[1]]);case"eth_getBlockByHash":return this.sdk.eth.getBlockByHash([n[0],n[1]]);case"eth_getTransactionByHash":let f=n[0];try{f=(await this.sdk.txs.getBySafeTxHash(f)).txHash||f}catch{}return this.submittedTxs.has(f)?this.submittedTxs.get(f):this.sdk.eth.getTransactionByHash([f]).then(h=>(h&&(h.hash=n[0]),h));case"eth_getTransactionReceipt":{let h=n[0];try{h=(await this.sdk.txs.getBySafeTxHash(h)).txHash||h}catch{}return this.sdk.eth.getTransactionReceipt([h]).then(p=>(p&&(p.transactionHash=n[0]),p))}case"eth_estimateGas":return this.sdk.eth.getEstimateGas(n[0]);case"eth_call":return this.sdk.eth.call([n[0],n[1]]);case"eth_getLogs":return this.sdk.eth.getPastLogs([n[0]]);case"eth_gasPrice":return this.sdk.eth.getGasPrice();case"wallet_getPermissions":return this.sdk.wallet.getPermissions();case"wallet_requestPermissions":return this.sdk.wallet.requestPermissions(n[0]);case"safe_setSettings":return this.sdk.eth.setSafeSettings([n[0]]);default:throw Error(`"${e.method}" not implemented`)}}send(e,r){e||r("Undefined request"),this.request(e).then(n=>r(null,{jsonrpc:"2.0",id:e.id,result:n})).catch(n=>r(n,null))}}Rw.SafeAppProvider=N3e;(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SafeAppProvider=void 0;var e=Rw;Object.defineProperty(t,"SafeAppProvider",{enumerable:!0,get:function(){return e.SafeAppProvider}})})(bV);const tP=new R3e,L3e=t=>new Promise((e,r)=>setTimeout(r,t));let im;const Ow=async()=>(im!=null||(im=await tP.safe.getInfo(),console.log(im)),im),vV=async()=>{try{const t=await Promise.race([L3e(300),Ow()]);return console.log(t),t!=null}catch{return!1}},D3e=async()=>{const t=await Ow();if(!t.chainId)throw Error("Unsupported chain");return new hye(new bV.SafeAppProvider(t,tP))},$3e=async t=>(await tP.txs.send({txs:t})).safeTxHash,F3e=84531,I1=async()=>{var t;return await vV()?(console.log("Use SafeAppsProvider"),await D3e()):(console.log("Use JsonRpcProvider"),new uH((t=Yr.getNetworkById(F3e))==null?void 0:t.url))},bl=async t=>{var e,r;return console.log("Use JsonRpcProvider"),console.log((e=Yr.getNetworkById(parseInt(t)))==null?void 0:e.url),new uH((r=Yr.getNetworkById(parseInt(t)))==null?void 0:r.url)},U3e="_nav_mbz2l_1",z3e="_wrapper_mbz2l_20",j3e="_maincontainer_mbz2l_31",H3e="_network_mbz2l_42",q3e="_buttonContainer_mbz2l_49",G3e="_container_mbz2l_59",V3e="_mode_mbz2l_68",K3e="_root_mbz2l_78",W3e="_icon_mbz2l_85",J3e="_iconLight_mbz2l_92",Z3e="_iconDark_mbz2l_97",sm={nav:U3e,wrapper:z3e,maincontainer:j3e,network:H3e,buttonContainer:q3e,container:G3e,mode:V3e,root:K3e,icon:W3e,iconLight:J3e,iconDark:Z3e},Q3e=t=>{const{colorScheme:e,toggleColorScheme:r}=TE(),[n,s]=Z.useState(""),[i,o]=Z.useState(84531),f=e==="dark",h=C$();return Z.useEffect(()=>{(async()=>{var v,E;const p=await I1(),{chainId:b}=await p.getNetwork();o(b),s(`${(v=Yr.getNetworkById(parseInt(b)))==null?void 0:v.name} ${(E=Yr.getNetworkById(parseInt(b)))==null?void 0:E.type}`)})()},[]),ce.jsx(Ko.Header,{children:ce.jsx("div",{className:sm.wrapper,children:ce.jsxs(Tf,{position:"apart",className:sm.maincontainer,children:[ce.jsx(Tf,{className:sm.container,children:ce.jsx(mM,{onClick:()=>{h(fc.home)},style:{cursor:"pointer",width:"170px"},src:f?mse:pse,alt:"Logo"})}),ce.jsxs(Tf,{className:sm.mode,children:[ce.jsx(dse,{size:30,stroke:1.5,onClick:()=>h(fc.account),style:{cursor:"pointer"}}),ce.jsx("div",{className:sm.container,children:f?ce.jsx(lse,{size:24,stroke:1.5,onClick:()=>r(),style:{cursor:"pointer"}}):ce.jsx(cse,{size:24,stroke:1.5,style:{cursor:"pointer"},onClick:()=>r()})})]})]})})})},Y3e=t=>{const{children:e}=t,[r,n]=Z.useState(!1),{colorScheme:s,toggleColorScheme:i}=TE(),o=s=="dark";return ce.jsxs(Ko,{header:{height:60},padding:"md",styles:{main:{backgroundColor:o?"var(--mantine-color-dark-9)":"var(--mantine-color-gray-0)"},header:{backgroundColor:o?"var(--mantine-color-dark-7)":"var(--mantine-color-white)"}},children:[ce.jsx(Q3e,{setOpened:n,opened:r}),ce.jsxs(Ko.Main,{children:[" ",ce.jsx(nie,{children:e})]})]})},X3e="_homeContainer_c8z77_47",e8e="_avatar_c8z77_55",t8e="_avatarContainer_c8z77_62",r8e="_safe_c8z77_70",n8e="_safeContainer_c8z77_77",i8e="_formContainer_c8z77_85",s8e="_heading_c8z77_92",o8e="_actions_c8z77_6",a8e="_links_c8z77_115",f8e="_subHeading_c8z77_123",c8e="_inputContainer_c8z77_129",u8e="_selectGroup_c8z77_140",l8e="_btn_c8z77_146",h8e="_helperText_c8z77_164",d8e="_mode_c8z77_168",p8e="_successContainer_c8z77_178",m8e="_network_c8z77_188",g8e="_copyContainer_c8z77_197",y8e="_goBack_c8z77_203",b8e="_input_c8z77_129",Hr={homeContainer:X3e,avatar:e8e,avatarContainer:t8e,safe:r8e,safeContainer:n8e,formContainer:i8e,heading:s8e,actions:o8e,links:a8e,subHeading:f8e,inputContainer:c8e,selectGroup:u8e,btn:l8e,helperText:h8e,mode:d8e,successContainer:p8e,network:m8e,copyContainer:g8e,goBack:y8e,input:b8e},v8e="/assets/ethindia-fbdac2de.svg",x8e="/assets/safe-a3da9967.svg",w8e="logger/5.7.0";let YR=!1,XR=!1;const r2={debug:1,default:2,info:2,warning:3,error:4,off:5};let eB=r2.default,s4=null;function A8e(){try{const t=[];if(["NFD","NFC","NFKD","NFKC"].forEach(e=>{try{if("test".normalize(e)!=="test")throw new Error("bad normalize")}catch{t.push(e)}}),t.length)throw new Error("missing "+t.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}const tB=A8e();var rA;(function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARNING="WARNING",t.ERROR="ERROR",t.OFF="OFF"})(rA||(rA={}));var vo;(function(t){t.UNKNOWN_ERROR="UNKNOWN_ERROR",t.NOT_IMPLEMENTED="NOT_IMPLEMENTED",t.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",t.NETWORK_ERROR="NETWORK_ERROR",t.SERVER_ERROR="SERVER_ERROR",t.TIMEOUT="TIMEOUT",t.BUFFER_OVERRUN="BUFFER_OVERRUN",t.NUMERIC_FAULT="NUMERIC_FAULT",t.MISSING_NEW="MISSING_NEW",t.INVALID_ARGUMENT="INVALID_ARGUMENT",t.MISSING_ARGUMENT="MISSING_ARGUMENT",t.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",t.CALL_EXCEPTION="CALL_EXCEPTION",t.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",t.NONCE_EXPIRED="NONCE_EXPIRED",t.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",t.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",t.TRANSACTION_REPLACED="TRANSACTION_REPLACED",t.ACTION_REJECTED="ACTION_REJECTED"})(vo||(vo={}));const rB="0123456789abcdef";class rt{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,r){const n=e.toLowerCase();r2[n]==null&&this.throwArgumentError("invalid log level name","logLevel",e),!(eB>r2[n])&&console.log.apply(console,r)}debug(...e){this._log(rt.levels.DEBUG,e)}info(...e){this._log(rt.levels.INFO,e)}warn(...e){this._log(rt.levels.WARNING,e)}makeError(e,r,n){if(XR)return this.makeError("censored error",r,{});r||(r=rt.errors.UNKNOWN_ERROR),n||(n={});const s=[];Object.keys(n).forEach(h=>{const p=n[h];try{if(p instanceof Uint8Array){let b="";for(let v=0;v>4],b+=rB[p[v]&15];s.push(h+"=Uint8Array(0x"+b+")")}else s.push(h+"="+JSON.stringify(p))}catch{s.push(h+"="+JSON.stringify(n[h].toString()))}}),s.push(`code=${r}`),s.push(`version=${this.version}`);const i=e;let o="";switch(r){case vo.NUMERIC_FAULT:{o="NUMERIC_FAULT";const h=e;switch(h){case"overflow":case"underflow":case"division-by-zero":o+="-"+h;break;case"negative-power":case"negative-width":o+="-unsupported";break;case"unbound-bitwise-result":o+="-unbound-result";break}break}case vo.CALL_EXCEPTION:case vo.INSUFFICIENT_FUNDS:case vo.MISSING_NEW:case vo.NONCE_EXPIRED:case vo.REPLACEMENT_UNDERPRICED:case vo.TRANSACTION_REPLACED:case vo.UNPREDICTABLE_GAS_LIMIT:o=r;break}o&&(e+=" [ See: https://links.ethers.org/v5-errors-"+o+" ]"),s.length&&(e+=" ("+s.join(", ")+")");const f=new Error(e);return f.reason=i,f.code=r,Object.keys(n).forEach(function(h){f[h]=n[h]}),f}throwError(e,r,n){throw this.makeError(e,r,n)}throwArgumentError(e,r,n){return this.throwError(e,rt.errors.INVALID_ARGUMENT,{argument:r,value:n})}assert(e,r,n,s){e||this.throwError(r,n,s)}assertArgument(e,r,n,s){e||this.throwArgumentError(r,n,s)}checkNormalize(e){tB&&this.throwError("platform missing String.prototype.normalize",rt.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:tB})}checkSafeUint53(e,r){typeof e=="number"&&(r==null&&(r="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(r,rt.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(r,rt.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,r,n){n?n=": "+n:n="",er&&this.throwError("too many arguments"+n,rt.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:r})}checkNew(e,r){(e===Object||e==null)&&this.throwError("missing new",rt.errors.MISSING_NEW,{name:r.name})}checkAbstract(e,r){e===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",rt.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):(e===Object||e==null)&&this.throwError("missing new",rt.errors.MISSING_NEW,{name:r.name})}static globalLogger(){return s4||(s4=new rt(w8e)),s4}static setCensorship(e,r){if(!e&&r&&this.globalLogger().throwError("cannot permanently disable censorship",rt.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),YR){if(!e)return;this.globalLogger().throwError("error censorship permanent",rt.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}XR=!!e,YR=!!r}static setLogLevel(e){const r=r2[e.toLowerCase()];if(r==null){rt.globalLogger().warn("invalid log level - "+e);return}eB=r}static from(e){return new rt(e)}}rt.errors=vo;rt.levels=rA;const E8e="bytes/5.7.0",qr=new rt(E8e);function xV(t){return!!t.toHexString}function ad(t){return t.slice||(t.slice=function(){const e=Array.prototype.slice.call(arguments);return ad(new Uint8Array(Array.prototype.slice.apply(t,e)))}),t}function rP(t){return di(t)&&!(t.length%2)||Nw(t)}function nB(t){return typeof t=="number"&&t==t&&t%1===0}function Nw(t){if(t==null)return!1;if(t.constructor===Uint8Array)return!0;if(typeof t=="string"||!nB(t.length)||t.length<0)return!1;for(let e=0;e=256)return!1}return!0}function Ze(t,e){if(e||(e={}),typeof t=="number"){qr.checkSafeUint53(t,"invalid arrayify value");const r=[];for(;t;)r.unshift(t&255),t=parseInt(String(t/256));return r.length===0&&r.push(0),ad(new Uint8Array(r))}if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),xV(t)&&(t=t.toHexString()),di(t)){let r=t.substring(2);r.length%2&&(e.hexPad==="left"?r="0"+r:e.hexPad==="right"?r+="0":qr.throwArgumentError("hex data is odd-length","value",t));const n=[];for(let s=0;sZe(s)),r=e.reduce((s,i)=>s+i.length,0),n=new Uint8Array(r);return e.reduce((s,i)=>(n.set(i,s),s+i.length),0),ad(n)}function pc(t){let e=Ze(t);if(e.length===0)return e;let r=0;for(;re&&qr.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(e);return r.set(t,e-t.length),ad(r)}function di(t,e){return!(typeof t!="string"||!t.match(/^0x[0-9A-Fa-f]*$/)||e&&t.length!==2+2*e)}const o4="0123456789abcdef";function pt(t,e){if(e||(e={}),typeof t=="number"){qr.checkSafeUint53(t,"invalid hexlify value");let r="";for(;t;)r=o4[t&15]+r,t=Math.floor(t/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if(typeof t=="bigint")return t=t.toString(16),t.length%2?"0x0"+t:"0x"+t;if(e.allowMissingPrefix&&typeof t=="string"&&t.substring(0,2)!=="0x"&&(t="0x"+t),xV(t))return t.toHexString();if(di(t))return t.length%2&&(e.hexPad==="left"?t="0x0"+t.substring(2):e.hexPad==="right"?t+="0":qr.throwArgumentError("hex data is odd-length","value",t)),t.toLowerCase();if(Nw(t)){let r="0x";for(let n=0;n>4]+o4[s&15]}return r}return qr.throwArgumentError("invalid hexlify value","value",t)}function wV(t){if(typeof t!="string")t=pt(t);else if(!di(t)||t.length%2)return null;return(t.length-2)/2}function Ng(t,e,r){return typeof t!="string"?t=pt(t):(!di(t)||t.length%2)&&qr.throwArgumentError("invalid hexData","value",t),e=2+2*e,r!=null?"0x"+t.substring(e,2+2*r):"0x"+t.substring(e)}function fd(t){let e="0x";return t.forEach(r=>{e+=pt(r).substring(2)}),e}function Ds(t,e){for(typeof t!="string"?t=pt(t):di(t)||qr.throwArgumentError("invalid hex string","value",t),t.length>2*e+2&&qr.throwArgumentError("value out of range","value",arguments[1]);t.length<2*e+2;)t="0x0"+t.substring(2);return t}function cb(t){const e={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(rP(t)){let r=Ze(t);r.length===64?(e.v=27+(r[32]>>7),r[32]&=127,e.r=pt(r.slice(0,32)),e.s=pt(r.slice(32,64))):r.length===65?(e.r=pt(r.slice(0,32)),e.s=pt(r.slice(32,64)),e.v=r[64]):qr.throwArgumentError("invalid signature string","signature",t),e.v<27&&(e.v===0||e.v===1?e.v+=27:qr.throwArgumentError("signature invalid v byte","signature",t)),e.recoveryParam=1-e.v%2,e.recoveryParam&&(r[32]|=128),e._vs=pt(r.slice(32,64))}else{if(e.r=t.r,e.s=t.s,e.v=t.v,e.recoveryParam=t.recoveryParam,e._vs=t._vs,e._vs!=null){const s=n2(Ze(e._vs),32);e._vs=pt(s);const i=s[0]>=128?1:0;e.recoveryParam==null?e.recoveryParam=i:e.recoveryParam!==i&&qr.throwArgumentError("signature recoveryParam mismatch _vs","signature",t),s[0]&=127;const o=pt(s);e.s==null?e.s=o:e.s!==o&&qr.throwArgumentError("signature v mismatch _vs","signature",t)}if(e.recoveryParam==null)e.v==null?qr.throwArgumentError("signature missing v and recoveryParam","signature",t):e.v===0||e.v===1?e.recoveryParam=e.v:e.recoveryParam=1-e.v%2;else if(e.v==null)e.v=27+e.recoveryParam;else{const s=e.v===0||e.v===1?e.v:1-e.v%2;e.recoveryParam!==s&&qr.throwArgumentError("signature recoveryParam mismatch v","signature",t)}e.r==null||!di(e.r)?qr.throwArgumentError("signature missing or invalid r","signature",t):e.r=Ds(e.r,32),e.s==null||!di(e.s)?qr.throwArgumentError("signature missing or invalid s","signature",t):e.s=Ds(e.s,32);const r=Ze(e.s);r[0]>=128&&qr.throwArgumentError("signature s out of range","signature",t),e.recoveryParam&&(r[0]|=128);const n=pt(r);e._vs&&(di(e._vs)||qr.throwArgumentError("signature invalid _vs","signature",t),e._vs=Ds(e._vs,32)),e._vs==null?e._vs=n:e._vs!==n&&qr.throwArgumentError("signature _vs mismatch v and s","signature",t)}return e.yParityAndS=e._vs,e.compact=e.r+e.yParityAndS.substring(2),e}function iB(t){return t=cb(t),pt(Fa([t.r,t.s,t.recoveryParam?"0x1c":"0x1b"]))}const M8e="bignumber/5.7.0";var V6=Mt.BN;const Xa=new rt(M8e),a4={},sB=9007199254740991;let oB=!1;class mr{constructor(e,r){e!==a4&&Xa.throwError("cannot call constructor directly; use BigNumber.from",rt.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}fromTwos(e){return xi(Bt(this).fromTwos(e))}toTwos(e){return xi(Bt(this).toTwos(e))}abs(){return this._hex[0]==="-"?mr.from(this._hex.substring(1)):this}add(e){return xi(Bt(this).add(Bt(e)))}sub(e){return xi(Bt(this).sub(Bt(e)))}div(e){return mr.from(e).isZero()&&vs("division-by-zero","div"),xi(Bt(this).div(Bt(e)))}mul(e){return xi(Bt(this).mul(Bt(e)))}mod(e){const r=Bt(e);return r.isNeg()&&vs("division-by-zero","mod"),xi(Bt(this).umod(r))}pow(e){const r=Bt(e);return r.isNeg()&&vs("negative-power","pow"),xi(Bt(this).pow(r))}and(e){const r=Bt(e);return(this.isNegative()||r.isNeg())&&vs("unbound-bitwise-result","and"),xi(Bt(this).and(r))}or(e){const r=Bt(e);return(this.isNegative()||r.isNeg())&&vs("unbound-bitwise-result","or"),xi(Bt(this).or(r))}xor(e){const r=Bt(e);return(this.isNegative()||r.isNeg())&&vs("unbound-bitwise-result","xor"),xi(Bt(this).xor(r))}mask(e){return(this.isNegative()||e<0)&&vs("negative-width","mask"),xi(Bt(this).maskn(e))}shl(e){return(this.isNegative()||e<0)&&vs("negative-width","shl"),xi(Bt(this).shln(e))}shr(e){return(this.isNegative()||e<0)&&vs("negative-width","shr"),xi(Bt(this).shrn(e))}eq(e){return Bt(this).eq(Bt(e))}lt(e){return Bt(this).lt(Bt(e))}lte(e){return Bt(this).lte(Bt(e))}gt(e){return Bt(this).gt(Bt(e))}gte(e){return Bt(this).gte(Bt(e))}isNegative(){return this._hex[0]==="-"}isZero(){return Bt(this).isZero()}toNumber(){try{return Bt(this).toNumber()}catch{vs("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch{}return Xa.throwError("this platform does not support BigInt",rt.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(arguments[0]===10?oB||(oB=!0,Xa.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):arguments[0]===16?Xa.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",rt.errors.UNEXPECTED_ARGUMENT,{}):Xa.throwError("BigNumber.toString does not accept parameters",rt.errors.UNEXPECTED_ARGUMENT,{})),Bt(this).toString(10)}toHexString(){return this._hex}toJSON(e){return{type:"BigNumber",hex:this.toHexString()}}static from(e){if(e instanceof mr)return e;if(typeof e=="string")return e.match(/^-?0x[0-9a-f]+$/i)?new mr(a4,Lg(e)):e.match(/^-?[0-9]+$/)?new mr(a4,Lg(new V6(e))):Xa.throwArgumentError("invalid BigNumber string","value",e);if(typeof e=="number")return e%1&&vs("underflow","BigNumber.from",e),(e>=sB||e<=-sB)&&vs("overflow","BigNumber.from",e),mr.from(String(e));const r=e;if(typeof r=="bigint")return mr.from(r.toString());if(Nw(r))return mr.from(pt(r));if(r)if(r.toHexString){const n=r.toHexString();if(typeof n=="string")return mr.from(n)}else{let n=r._hex;if(n==null&&r.type==="BigNumber"&&(n=r.hex),typeof n=="string"&&(di(n)||n[0]==="-"&&di(n.substring(1))))return mr.from(n)}return Xa.throwArgumentError("invalid BigNumber value","value",e)}static isBigNumber(e){return!!(e&&e._isBigNumber)}}function Lg(t){if(typeof t!="string")return Lg(t.toString(16));if(t[0]==="-")return t=t.substring(1),t[0]==="-"&&Xa.throwArgumentError("invalid hex","value",t),t=Lg(t),t==="0x00"?t:"-"+t;if(t.substring(0,2)!=="0x"&&(t="0x"+t),t==="0x")return"0x00";for(t.length%2&&(t="0x0"+t.substring(2));t.length>4&&t.substring(0,4)==="0x00";)t="0x"+t.substring(4);return t}function xi(t){return mr.from(Lg(t))}function Bt(t){const e=mr.from(t).toHexString();return e[0]==="-"?new V6("-"+e.substring(3),16):new V6(e.substring(2),16)}function vs(t,e,r){const n={fault:t,operation:e};return r!=null&&(n.value=r),Xa.throwError(t,rt.errors.NUMERIC_FAULT,n)}function S8e(t){return new V6(t,36).toString(16)}const _8e="properties/5.7.0";var P8e=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const K6=new rt(_8e);function St(t,e,r){Object.defineProperty(t,e,{enumerable:!0,value:r,writable:!1})}function Nh(t){return P8e(this,void 0,void 0,function*(){const e=Object.keys(t).map(n=>{const s=t[n];return Promise.resolve(s).then(i=>({key:n,value:i}))});return(yield Promise.all(e)).reduce((n,s)=>(n[s.key]=s.value,n),{})})}function C8e(t,e){(!t||typeof t!="object")&&K6.throwArgumentError("invalid object","object",t),Object.keys(t).forEach(r=>{e[r]||K6.throwArgumentError("invalid object key - "+r,"transaction:"+r,t)})}function nA(t){const e={};for(const r in t)e[r]=t[r];return e}const I8e={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function AV(t){if(t==null||I8e[typeof t])return!0;if(Array.isArray(t)||typeof t=="object"){if(!Object.isFrozen(t))return!1;const e=Object.keys(t);for(let r=0;rW6(e)));if(typeof t=="object"){const e={};for(const r in t){const n=t[r];n!==void 0&&St(e,r,W6(n))}return e}return K6.throwArgumentError(`Cannot deepCopy ${typeof t}`,"object",t)}function W6(t){return T8e(t)}class EV{constructor(e){for(const r in e)this[r]=W6(e[r])}}var MV={exports:{}};(function(t){(function(){var e="input is invalid type",r="finalize already called",n=typeof window=="object",s=n?window:{};s.JS_SHA3_NO_WINDOW&&(n=!1);var i=!n&&typeof self=="object",o=!s.JS_SHA3_NO_NODE_JS&&typeof Ve.process=="object"&&Ve.process.versions&&Ve.process.versions.node;o?s=Ke:i&&(s=self);var f=!s.JS_SHA3_NO_COMMON_JS&&!0&&t.exports,h=!s.JS_SHA3_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",p="0123456789abcdef".split(""),b=[31,7936,2031616,520093696],v=[4,1024,262144,67108864],E=[1,256,65536,16777216],_=[6,1536,393216,100663296],S=[0,8,16,24],P=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],I=[224,256,384,512],C=[128,256],T=["hex","buffer","arrayBuffer","array","digest"],B={128:168,256:136};(s.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(k){return Object.prototype.toString.call(k)==="[object Array]"}),h&&(s.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(k){return typeof k=="object"&&k.buffer&&k.buffer.constructor===ArrayBuffer});for(var N=function(k,D,U){return function(V){return new M(k,D,k).update(V)[U]()}},$=function(k,D,U){return function(V,G){return new M(k,D,G).update(V)[U]()}},H=function(k,D,U){return function(V,G,Y,q){return l["cshake"+k].update(V,G,Y,q)[U]()}},J=function(k,D,U){return function(V,G,Y,q){return l["kmac"+k].update(V,G,Y,q)[U]()}},Q=function(k,D,U,V){for(var G=0;G>5,this.byteCount=this.blockCount<<2,this.outputBlocks=U>>5,this.extraBytes=(U&31)>>3;for(var V=0;V<50;++V)this.s[V]=0}M.prototype.update=function(k){if(this.finalized)throw new Error(r);var D,U=typeof k;if(U!=="string"){if(U==="object"){if(k===null)throw new Error(e);if(h&&k.constructor===ArrayBuffer)k=new Uint8Array(k);else if(!Array.isArray(k)&&(!h||!ArrayBuffer.isView(k)))throw new Error(e)}else throw new Error(e);D=!0}for(var V=this.blocks,G=this.byteCount,Y=k.length,q=this.blockCount,z=0,ee=this.s,re,ie;z>2]|=k[z]<>2]|=ie<>2]|=(192|ie>>6)<>2]|=(128|ie&63)<=57344?(V[re>>2]|=(224|ie>>12)<>2]|=(128|ie>>6&63)<>2]|=(128|ie&63)<>2]|=(240|ie>>18)<>2]|=(128|ie>>12&63)<>2]|=(128|ie>>6&63)<>2]|=(128|ie&63)<=G){for(this.start=re-G,this.block=V[q],re=0;re>8,U=k&255;U>0;)G.unshift(U),k=k>>8,U=k&255,++V;return D?G.push(V):G.unshift(V),this.update(G),G.length},M.prototype.encodeString=function(k){var D,U=typeof k;if(U!=="string"){if(U==="object"){if(k===null)throw new Error(e);if(h&&k.constructor===ArrayBuffer)k=new Uint8Array(k);else if(!Array.isArray(k)&&(!h||!ArrayBuffer.isView(k)))throw new Error(e)}else throw new Error(e);D=!0}var V=0,G=k.length;if(D)V=G;else for(var Y=0;Y=57344?V+=3:(q=65536+((q&1023)<<10|k.charCodeAt(++Y)&1023),V+=4)}return V+=this.encode(V*8),this.update(k),V},M.prototype.bytepad=function(k,D){for(var U=this.encode(D),V=0;V>2]|=this.padding[D&3],this.lastByteIndex===this.byteCount)for(k[0]=k[U],D=1;D>4&15]+p[z&15]+p[z>>12&15]+p[z>>8&15]+p[z>>20&15]+p[z>>16&15]+p[z>>28&15]+p[z>>24&15];Y%k===0&&(L(D),G=0)}return V&&(z=D[G],q+=p[z>>4&15]+p[z&15],V>1&&(q+=p[z>>12&15]+p[z>>8&15]),V>2&&(q+=p[z>>20&15]+p[z>>16&15])),q},M.prototype.arrayBuffer=function(){this.finalize();var k=this.blockCount,D=this.s,U=this.outputBlocks,V=this.extraBytes,G=0,Y=0,q=this.outputBits>>3,z;V?z=new ArrayBuffer(U+1<<2):z=new ArrayBuffer(q);for(var ee=new Uint32Array(z);Y>8&255,q[z+2]=ee>>16&255,q[z+3]=ee>>24&255;Y%k===0&&L(D)}return V&&(z=Y<<2,ee=D[G],q[z]=ee&255,V>1&&(q[z+1]=ee>>8&255),V>2&&(q[z+2]=ee>>16&255)),q};function R(k,D,U){M.call(this,k,D,U)}R.prototype=new M,R.prototype.finalize=function(){return this.encode(this.outputBits,!0),M.prototype.finalize.call(this)};var L=function(k){var D,U,V,G,Y,q,z,ee,re,ie,ae,je,he,oe,Qe,ge,be,ot,ye,xe,at,j,O,F,W,te,le,ne,pe,Ye,de,ve,Je,we,Re,yt,Ae,Be,bt,Ee,Oe,vt,Me,Ne,xt,Se,Le,wt,_e,De,At,Pe,$e,Et,Ce,Fe,ht,dt,jt,Ht,qt,Gt,Vt;for(V=0;V<48;V+=2)G=k[0]^k[10]^k[20]^k[30]^k[40],Y=k[1]^k[11]^k[21]^k[31]^k[41],q=k[2]^k[12]^k[22]^k[32]^k[42],z=k[3]^k[13]^k[23]^k[33]^k[43],ee=k[4]^k[14]^k[24]^k[34]^k[44],re=k[5]^k[15]^k[25]^k[35]^k[45],ie=k[6]^k[16]^k[26]^k[36]^k[46],ae=k[7]^k[17]^k[27]^k[37]^k[47],je=k[8]^k[18]^k[28]^k[38]^k[48],he=k[9]^k[19]^k[29]^k[39]^k[49],D=je^(q<<1|z>>>31),U=he^(z<<1|q>>>31),k[0]^=D,k[1]^=U,k[10]^=D,k[11]^=U,k[20]^=D,k[21]^=U,k[30]^=D,k[31]^=U,k[40]^=D,k[41]^=U,D=G^(ee<<1|re>>>31),U=Y^(re<<1|ee>>>31),k[2]^=D,k[3]^=U,k[12]^=D,k[13]^=U,k[22]^=D,k[23]^=U,k[32]^=D,k[33]^=U,k[42]^=D,k[43]^=U,D=q^(ie<<1|ae>>>31),U=z^(ae<<1|ie>>>31),k[4]^=D,k[5]^=U,k[14]^=D,k[15]^=U,k[24]^=D,k[25]^=U,k[34]^=D,k[35]^=U,k[44]^=D,k[45]^=U,D=ee^(je<<1|he>>>31),U=re^(he<<1|je>>>31),k[6]^=D,k[7]^=U,k[16]^=D,k[17]^=U,k[26]^=D,k[27]^=U,k[36]^=D,k[37]^=U,k[46]^=D,k[47]^=U,D=ie^(G<<1|Y>>>31),U=ae^(Y<<1|G>>>31),k[8]^=D,k[9]^=U,k[18]^=D,k[19]^=U,k[28]^=D,k[29]^=U,k[38]^=D,k[39]^=U,k[48]^=D,k[49]^=U,oe=k[0],Qe=k[1],Se=k[11]<<4|k[10]>>>28,Le=k[10]<<4|k[11]>>>28,ne=k[20]<<3|k[21]>>>29,pe=k[21]<<3|k[20]>>>29,Ht=k[31]<<9|k[30]>>>23,qt=k[30]<<9|k[31]>>>23,vt=k[40]<<18|k[41]>>>14,Me=k[41]<<18|k[40]>>>14,we=k[2]<<1|k[3]>>>31,Re=k[3]<<1|k[2]>>>31,ge=k[13]<<12|k[12]>>>20,be=k[12]<<12|k[13]>>>20,wt=k[22]<<10|k[23]>>>22,_e=k[23]<<10|k[22]>>>22,Ye=k[33]<<13|k[32]>>>19,de=k[32]<<13|k[33]>>>19,Gt=k[42]<<2|k[43]>>>30,Vt=k[43]<<2|k[42]>>>30,Et=k[5]<<30|k[4]>>>2,Ce=k[4]<<30|k[5]>>>2,yt=k[14]<<6|k[15]>>>26,Ae=k[15]<<6|k[14]>>>26,ot=k[25]<<11|k[24]>>>21,ye=k[24]<<11|k[25]>>>21,De=k[34]<<15|k[35]>>>17,At=k[35]<<15|k[34]>>>17,ve=k[45]<<29|k[44]>>>3,Je=k[44]<<29|k[45]>>>3,F=k[6]<<28|k[7]>>>4,W=k[7]<<28|k[6]>>>4,Fe=k[17]<<23|k[16]>>>9,ht=k[16]<<23|k[17]>>>9,Be=k[26]<<25|k[27]>>>7,bt=k[27]<<25|k[26]>>>7,xe=k[36]<<21|k[37]>>>11,at=k[37]<<21|k[36]>>>11,Pe=k[47]<<24|k[46]>>>8,$e=k[46]<<24|k[47]>>>8,Ne=k[8]<<27|k[9]>>>5,xt=k[9]<<27|k[8]>>>5,te=k[18]<<20|k[19]>>>12,le=k[19]<<20|k[18]>>>12,dt=k[29]<<7|k[28]>>>25,jt=k[28]<<7|k[29]>>>25,Ee=k[38]<<8|k[39]>>>24,Oe=k[39]<<8|k[38]>>>24,j=k[48]<<14|k[49]>>>18,O=k[49]<<14|k[48]>>>18,k[0]=oe^~ge&ot,k[1]=Qe^~be&ye,k[10]=F^~te&ne,k[11]=W^~le&pe,k[20]=we^~yt&Be,k[21]=Re^~Ae&bt,k[30]=Ne^~Se&wt,k[31]=xt^~Le&_e,k[40]=Et^~Fe&dt,k[41]=Ce^~ht&jt,k[2]=ge^~ot&xe,k[3]=be^~ye&at,k[12]=te^~ne&Ye,k[13]=le^~pe&de,k[22]=yt^~Be&Ee,k[23]=Ae^~bt&Oe,k[32]=Se^~wt&De,k[33]=Le^~_e&At,k[42]=Fe^~dt&Ht,k[43]=ht^~jt&qt,k[4]=ot^~xe&j,k[5]=ye^~at&O,k[14]=ne^~Ye&ve,k[15]=pe^~de&Je,k[24]=Be^~Ee&vt,k[25]=bt^~Oe&Me,k[34]=wt^~De&Pe,k[35]=_e^~At&$e,k[44]=dt^~Ht&Gt,k[45]=jt^~qt&Vt,k[6]=xe^~j&oe,k[7]=at^~O&Qe,k[16]=Ye^~ve&F,k[17]=de^~Je&W,k[26]=Ee^~vt&we,k[27]=Oe^~Me&Re,k[36]=De^~Pe&Ne,k[37]=At^~$e&xt,k[46]=Ht^~Gt&Et,k[47]=qt^~Vt&Ce,k[8]=j^~oe&ge,k[9]=O^~Qe&be,k[18]=ve^~F&te,k[19]=Je^~W&le,k[28]=vt^~we&yt,k[29]=Me^~Re&Ae,k[38]=Pe^~Ne&Se,k[39]=$e^~xt&Le,k[48]=Gt^~Et&Fe,k[49]=Vt^~Ce&ht,k[0]^=P[V],k[1]^=P[V+1]};if(f)t.exports=l;else for(m=0;m>=8;return e}function SV(t){if(Array.isArray(t)){let n=[];if(t.forEach(function(i){n=n.concat(SV(i))}),n.length<=55)return n.unshift(192+n.length),n;const s=aB(n.length);return s.unshift(247+s.length),s.concat(n)}rP(t)||O8e.throwArgumentError("RLP object must be BytesLike","object",t);const e=Array.prototype.slice.call(Ze(t));if(e.length===1&&e[0]<=127)return e;if(e.length<=55)return e.unshift(128+e.length),e;const r=aB(e.length);return r.unshift(183+r.length),r.concat(e)}function J6(t){return pt(SV(t))}const N8e="address/5.7.0",Em=new rt(N8e);function fB(t){di(t,20)||Em.throwArgumentError("invalid address","address",t),t=t.toLowerCase();const e=t.substring(2).split(""),r=new Uint8Array(40);for(let s=0;s<40;s++)r[s]=e[s].charCodeAt(0);const n=Ze(kn(r));for(let s=0;s<40;s+=2)n[s>>1]>>4>=8&&(e[s]=e[s].toUpperCase()),(n[s>>1]&15)>=8&&(e[s+1]=e[s+1].toUpperCase());return"0x"+e.join("")}const L8e=9007199254740991;function D8e(t){return Math.log10?Math.log10(t):Math.log(t)/Math.LN10}const nP={};for(let t=0;t<10;t++)nP[String(t)]=String(t);for(let t=0;t<26;t++)nP[String.fromCharCode(65+t)]=String(10+t);const cB=Math.floor(D8e(L8e));function $8e(t){t=t.toUpperCase(),t=t.substring(4)+t.substring(0,2)+"00";let e=t.split("").map(n=>nP[n]).join("");for(;e.length>=cB;){let n=e.substring(0,cB);e=parseInt(n,10)%97+e.substring(n.length)}let r=String(98-parseInt(e,10)%97);for(;r.length<2;)r="0"+r;return r}function Xo(t){let e=null;if(typeof t!="string"&&Em.throwArgumentError("invalid address","address",t),t.match(/^(0x)?[0-9a-fA-F]{40}$/))t.substring(0,2)!=="0x"&&(t="0x"+t),e=fB(t),t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&e!==t&&Em.throwArgumentError("bad address checksum","address",t);else if(t.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(t.substring(2,4)!==$8e(t)&&Em.throwArgumentError("bad icap checksum","address",t),e=S8e(t.substring(4));e.length<40;)e="0"+e;e=fB("0x"+e)}else Em.throwArgumentError("invalid address","address",t);return e}const F8e="strings/5.7.0",U8e=new rt(F8e);var vl;(function(t){t.current="",t.NFC="NFC",t.NFD="NFD",t.NFKC="NFKC",t.NFKD="NFKD"})(vl||(vl={}));var uB;(function(t){t.UNEXPECTED_CONTINUE="unexpected continuation byte",t.BAD_PREFIX="bad codepoint prefix",t.OVERRUN="string overrun",t.MISSING_CONTINUE="missing continuation byte",t.OUT_OF_RANGE="out of UTF-8 range",t.UTF16_SURROGATE="UTF-16 surrogate",t.OVERLONG="overlong representation"})(uB||(uB={}));function jo(t,e=vl.current){e!=vl.current&&(U8e.checkNormalize(),t=t.normalize(e));let r=[];for(let n=0;n>6|192),r.push(s&63|128);else if((s&64512)==55296){n++;const i=t.charCodeAt(n);if(n>=t.length||(i&64512)!==56320)throw new Error("invalid utf-8 string");const o=65536+((s&1023)<<10)+(i&1023);r.push(o>>18|240),r.push(o>>12&63|128),r.push(o>>6&63|128),r.push(o&63|128)}else r.push(s>>12|224),r.push(s>>6&63|128),r.push(s&63|128)}return Ze(r)}function iP(t){return kn(jo(t))}const z8e="hash/5.7.0",j8e=`Ethereum Signed Message: -`;function _V(t){return typeof t=="string"&&(t=jo(t)),kn(Fa([jo(j8e),jo(String(t.length)),t]))}var H8e=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const _r=new rt(z8e),PV=new Uint8Array(32);PV.fill(0);const q8e=mr.from(-1),CV=mr.from(0),IV=mr.from(1),G8e=mr.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function V8e(t){const e=Ze(t),r=e.length%32;return r?fd([e,PV.slice(r)]):pt(e)}const K8e=Ds(IV.toHexString(),32),W8e=Ds(CV.toHexString(),32),lB={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},f4=["name","version","chainId","verifyingContract","salt"];function hB(t){return function(e){return typeof e!="string"&&_r.throwArgumentError(`invalid domain value for ${JSON.stringify(t)}`,`domain.${t}`,e),e}}const J8e={name:hB("name"),version:hB("version"),chainId:function(t){try{return mr.from(t).toString()}catch{}return _r.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",t)},verifyingContract:function(t){try{return Xo(t).toLowerCase()}catch{}return _r.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",t)},salt:function(t){try{const e=Ze(t);if(e.length!==32)throw new Error("bad length");return pt(e)}catch{}return _r.throwArgumentError('invalid domain value "salt"',"domain.salt",t)}};function c4(t){{const e=t.match(/^(u?)int(\d*)$/);if(e){const r=e[1]==="",n=parseInt(e[2]||"256");(n%8!==0||n>256||e[2]&&e[2]!==String(n))&&_r.throwArgumentError("invalid numeric width","type",t);const s=G8e.mask(r?n-1:n),i=r?s.add(IV).mul(q8e):CV;return function(o){const f=mr.from(o);return(f.lt(i)||f.gt(s))&&_r.throwArgumentError(`value out-of-bounds for ${t}`,"value",o),Ds(f.toTwos(256).toHexString(),32)}}}{const e=t.match(/^bytes(\d+)$/);if(e){const r=parseInt(e[1]);return(r===0||r>32||e[1]!==String(r))&&_r.throwArgumentError("invalid bytes width","type",t),function(n){return Ze(n).length!==r&&_r.throwArgumentError(`invalid length for ${t}`,"value",n),V8e(n)}}}switch(t){case"address":return function(e){return Ds(Xo(e),32)};case"bool":return function(e){return e?K8e:W8e};case"bytes":return function(e){return kn(e)};case"string":return function(e){return iP(e)}}return null}function dB(t,e){return`${t}(${e.map(({name:r,type:n})=>n+" "+r).join(",")})`}class qi{constructor(e){St(this,"types",Object.freeze(W6(e))),St(this,"_encoderCache",{}),St(this,"_types",{});const r={},n={},s={};Object.keys(e).forEach(f=>{r[f]={},n[f]=[],s[f]={}});for(const f in e){const h={};e[f].forEach(p=>{h[p.name]&&_r.throwArgumentError(`duplicate variable name ${JSON.stringify(p.name)} in ${JSON.stringify(f)}`,"types",e),h[p.name]=!0;const b=p.type.match(/^([^\x5b]*)(\x5b|$)/)[1];b===f&&_r.throwArgumentError(`circular type reference to ${JSON.stringify(b)}`,"types",e),!c4(b)&&(n[b]||_r.throwArgumentError(`unknown type ${JSON.stringify(b)}`,"types",e),n[b].push(f),r[f][b]=!0)})}const i=Object.keys(n).filter(f=>n[f].length===0);i.length===0?_r.throwArgumentError("missing primary type","types",e):i.length>1&&_r.throwArgumentError(`ambiguous primary types or unused types: ${i.map(f=>JSON.stringify(f)).join(", ")}`,"types",e),St(this,"primaryType",i[0]);function o(f,h){h[f]&&_r.throwArgumentError(`circular type reference to ${JSON.stringify(f)}`,"types",e),h[f]=!0,Object.keys(r[f]).forEach(p=>{n[p]&&(o(p,h),Object.keys(h).forEach(b=>{s[b][p]=!0}))}),delete h[f]}o(this.primaryType,{});for(const f in s){const h=Object.keys(s[f]);h.sort(),this._types[f]=dB(f,e[f])+h.map(p=>dB(p,e[p])).join("")}}getEncoder(e){let r=this._encoderCache[e];return r||(r=this._encoderCache[e]=this._getEncoder(e)),r}_getEncoder(e){{const s=c4(e);if(s)return s}const r=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(r){const s=r[1],i=this.getEncoder(s),o=parseInt(r[3]);return f=>{o>=0&&f.length!==o&&_r.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",f);let h=f.map(i);return this._types[s]&&(h=h.map(kn)),kn(fd(h))}}const n=this.types[e];if(n){const s=iP(this._types[e]);return i=>{const o=n.map(({name:f,type:h})=>{const p=this.getEncoder(h)(i[f]);return this._types[h]?kn(p):p});return o.unshift(s),fd(o)}}return _r.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){const r=this._types[e];return r||_r.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),r}encodeData(e,r){return this.getEncoder(e)(r)}hashStruct(e,r){return kn(this.encodeData(e,r))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,r,n){if(c4(e))return n(e,r);const s=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(s){const o=s[1],f=parseInt(s[3]);return f>=0&&r.length!==f&&_r.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",r),r.map(h=>this._visit(o,h,n))}const i=this.types[e];return i?i.reduce((o,{name:f,type:h})=>(o[f]=this._visit(h,r[f],n),o),{}):_r.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,r){return this._visit(this.primaryType,e,r)}static from(e){return new qi(e)}static getPrimaryType(e){return qi.from(e).primaryType}static hashStruct(e,r,n){return qi.from(r).hashStruct(e,n)}static hashDomain(e){const r=[];for(const n in e){const s=lB[n];s||_r.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(n)}`,"domain",e),r.push({name:n,type:s})}return r.sort((n,s)=>f4.indexOf(n.name)-f4.indexOf(s.name)),qi.hashStruct("EIP712Domain",{EIP712Domain:r},e)}static encode(e,r,n){return fd(["0x1901",qi.hashDomain(e),qi.from(r).hash(n)])}static hash(e,r,n){return kn(qi.encode(e,r,n))}static resolveNames(e,r,n,s){return H8e(this,void 0,void 0,function*(){e=nA(e);const i={};e.verifyingContract&&!di(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const o=qi.from(r);o.visit(n,(f,h)=>(f==="address"&&!di(h,20)&&(i[h]="0x"),h));for(const f in i)i[f]=yield s(f);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),n=o.visit(n,(f,h)=>f==="address"&&i[h]?i[h]:h),{domain:e,value:n}})}static getPayload(e,r,n){qi.hashDomain(e);const s={},i=[];f4.forEach(h=>{const p=e[h];p!=null&&(s[h]=J8e[h](p),i.push({name:h,type:lB[h]}))});const o=qi.from(r),f=nA(r);return f.EIP712Domain?_r.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):f.EIP712Domain=i,o.encode(n),{types:f,domain:s,primaryType:o.primaryType,message:o.visit(n,(h,p)=>{if(h.match(/^bytes(\d*)/))return pt(Ze(p));if(h.match(/^u?int/))return mr.from(p).toString();switch(h){case"address":return p.toLowerCase();case"bool":return!!p;case"string":return typeof p!="string"&&_r.throwArgumentError("invalid string","value",p),p}return _r.throwArgumentError("unsupported type","type",h)})}}}const Z8e="abstract-provider/5.7.0";var Q8e=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const Y8e=new rt(Z8e);class sP{constructor(){Y8e.checkAbstract(new.target,sP),St(this,"_isProvider",!0)}getFeeData(){return Q8e(this,void 0,void 0,function*(){const{block:e,gasPrice:r}=yield Nh({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch(o=>null)});let n=null,s=null,i=null;return e&&e.baseFeePerGas&&(n=e.baseFeePerGas,i=mr.from("1500000000"),s=e.baseFeePerGas.mul(2).add(i)),{lastBaseFeePerGas:n,maxFeePerGas:s,maxPriorityFeePerGas:i,gasPrice:r}})}addListener(e,r){return this.on(e,r)}removeListener(e,r){return this.off(e,r)}static isProvider(e){return!!(e&&e._isProvider)}}const X8e="abstract-signer/5.7.0";var mo=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const go=new rt(X8e),e4e=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],t4e=[rt.errors.INSUFFICIENT_FUNDS,rt.errors.NONCE_EXPIRED,rt.errors.REPLACEMENT_UNDERPRICED];class oP{constructor(){go.checkAbstract(new.target,oP),St(this,"_isSigner",!0)}getBalance(e){return mo(this,void 0,void 0,function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)})}getTransactionCount(e){return mo(this,void 0,void 0,function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)})}estimateGas(e){return mo(this,void 0,void 0,function*(){this._checkProvider("estimateGas");const r=yield Nh(this.checkTransaction(e));return yield this.provider.estimateGas(r)})}call(e,r){return mo(this,void 0,void 0,function*(){this._checkProvider("call");const n=yield Nh(this.checkTransaction(e));return yield this.provider.call(n,r)})}sendTransaction(e){return mo(this,void 0,void 0,function*(){this._checkProvider("sendTransaction");const r=yield this.populateTransaction(e),n=yield this.signTransaction(r);return yield this.provider.sendTransaction(n)})}getChainId(){return mo(this,void 0,void 0,function*(){return this._checkProvider("getChainId"),(yield this.provider.getNetwork()).chainId})}getGasPrice(){return mo(this,void 0,void 0,function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()})}getFeeData(){return mo(this,void 0,void 0,function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()})}resolveName(e){return mo(this,void 0,void 0,function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)})}checkTransaction(e){for(const n in e)e4e.indexOf(n)===-1&&go.throwArgumentError("invalid transaction key: "+n,"transaction",e);const r=nA(e);return r.from==null?r.from=this.getAddress():r.from=Promise.all([Promise.resolve(r.from),this.getAddress()]).then(n=>(n[0].toLowerCase()!==n[1].toLowerCase()&&go.throwArgumentError("from address mismatch","transaction",e),n[0])),r}populateTransaction(e){return mo(this,void 0,void 0,function*(){const r=yield Nh(this.checkTransaction(e));r.to!=null&&(r.to=Promise.resolve(r.to).then(s=>mo(this,void 0,void 0,function*(){if(s==null)return null;const i=yield this.resolveName(s);return i==null&&go.throwArgumentError("provided ENS name resolves to null","tx.to",s),i})),r.to.catch(s=>{}));const n=r.maxFeePerGas!=null||r.maxPriorityFeePerGas!=null;if(r.gasPrice!=null&&(r.type===2||n)?go.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e):(r.type===0||r.type===1)&&n&&go.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e),(r.type===2||r.type==null)&&r.maxFeePerGas!=null&&r.maxPriorityFeePerGas!=null)r.type=2;else if(r.type===0||r.type===1)r.gasPrice==null&&(r.gasPrice=this.getGasPrice());else{const s=yield this.getFeeData();if(r.type==null)if(s.maxFeePerGas!=null&&s.maxPriorityFeePerGas!=null)if(r.type=2,r.gasPrice!=null){const i=r.gasPrice;delete r.gasPrice,r.maxFeePerGas=i,r.maxPriorityFeePerGas=i}else r.maxFeePerGas==null&&(r.maxFeePerGas=s.maxFeePerGas),r.maxPriorityFeePerGas==null&&(r.maxPriorityFeePerGas=s.maxPriorityFeePerGas);else s.gasPrice!=null?(n&&go.throwError("network does not support EIP-1559",rt.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),r.gasPrice==null&&(r.gasPrice=s.gasPrice),r.type=0):go.throwError("failed to get consistent fee data",rt.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else r.type===2&&(r.maxFeePerGas==null&&(r.maxFeePerGas=s.maxFeePerGas),r.maxPriorityFeePerGas==null&&(r.maxPriorityFeePerGas=s.maxPriorityFeePerGas))}return r.nonce==null&&(r.nonce=this.getTransactionCount("pending")),r.gasLimit==null&&(r.gasLimit=this.estimateGas(r).catch(s=>{if(t4e.indexOf(s.code)>=0)throw s;return go.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",rt.errors.UNPREDICTABLE_GAS_LIMIT,{error:s,tx:r})})),r.chainId==null?r.chainId=this.getChainId():r.chainId=Promise.all([Promise.resolve(r.chainId),this.getChainId()]).then(s=>(s[1]!==0&&s[0]!==s[1]&&go.throwArgumentError("chainId address mismatch","transaction",e),s[0])),yield Nh(r)})}_checkProvider(e){this.provider||go.throwError("missing provider",rt.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!!(e&&e._isSigner)}}function T1(t,e,r){return r={path:e,exports:{},require:function(n,s){return r4e(n,s??r.path)}},t(r,r.exports),r.exports}function r4e(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var aP=TV;function TV(t,e){if(!t)throw new Error(e||"Assertion failed")}TV.equal=function(e,r,n){if(e!=r)throw new Error(n||"Assertion failed: "+e+" != "+r)};var Lo=T1(function(t,e){var r=e;function n(o,f){if(Array.isArray(o))return o.slice();if(!o)return[];var h=[];if(typeof o!="string"){for(var p=0;p>8,E=b&255;v?h.push(v,E):h.push(E)}return h}r.toArray=n;function s(o){return o.length===1?"0"+o:o}r.zero2=s;function i(o){for(var f="",h=0;h(E>>1)-1?P=(E>>1)-I:P=I,_.isubn(P)):P=0,v[S]=P,_.iushrn(1)}return v}r.getNAF=n;function s(h,p){var b=[[],[]];h=h.clone(),p=p.clone();for(var v=0,E=0,_;h.cmpn(-v)>0||p.cmpn(-E)>0;){var S=h.andln(3)+v&3,P=p.andln(3)+E&3;S===3&&(S=-1),P===3&&(P=-1);var I;S&1?(_=h.andln(7)+v&7,(_===3||_===5)&&P===2?I=-S:I=S):I=0,b[0].push(I);var C;P&1?(_=p.andln(7)+E&7,(_===3||_===5)&&S===2?C=-P:C=P):C=0,b[1].push(C),2*v===I+1&&(v=1-v),2*E===C+1&&(E=1-E),h.iushrn(1),p.iushrn(1)}return b}r.getJSF=s;function i(h,p,b){var v="_"+p;h.prototype[p]=function(){return this[v]!==void 0?this[v]:this[v]=b.call(this)}}r.cachedProperty=i;function o(h){return typeof h=="string"?r.toArray(h,"hex"):h}r.parseBytes=o;function f(h){return new Mt(h,"hex","le")}r.intFromLE=f}),Z6=ms.getNAF,n4e=ms.getJSF,Q6=ms.assert;function Kc(t,e){this.type=t,this.p=new Mt(e.p,16),this.red=e.prime?Mt.red(e.prime):Mt.mont(this.p),this.zero=new Mt(0).toRed(this.red),this.one=new Mt(1).toRed(this.red),this.two=new Mt(2).toRed(this.red),this.n=e.n&&new Mt(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var Hl=Kc;Kc.prototype.point=function(){throw new Error("Not implemented")};Kc.prototype.validate=function(){throw new Error("Not implemented")};Kc.prototype._fixedNafMul=function(e,r){Q6(e.precomputed);var n=e._getDoubles(),s=Z6(r,1,this._bitLength),i=(1<=f;p--)h=(h<<1)+s[p];o.push(h)}for(var b=this.jpoint(null,null,null),v=this.jpoint(null,null,null),E=i;E>0;E--){for(f=0;f=0;h--){for(var p=0;h>=0&&o[h]===0;h--)p++;if(h>=0&&p++,f=f.dblp(p),h<0)break;var b=o[h];Q6(b!==0),e.type==="affine"?b>0?f=f.mixedAdd(i[b-1>>1]):f=f.mixedAdd(i[-b-1>>1].neg()):b>0?f=f.add(i[b-1>>1]):f=f.add(i[-b-1>>1].neg())}return e.type==="affine"?f.toP():f};Kc.prototype._wnafMulAdd=function(e,r,n,s,i){var o=this._wnafT1,f=this._wnafT2,h=this._wnafT3,p=0,b,v,E;for(b=0;b=1;b-=2){var S=b-1,P=b;if(o[S]!==1||o[P]!==1){h[S]=Z6(n[S],o[S],this._bitLength),h[P]=Z6(n[P],o[P],this._bitLength),p=Math.max(h[S].length,p),p=Math.max(h[P].length,p);continue}var I=[r[S],null,null,r[P]];r[S].y.cmp(r[P].y)===0?(I[1]=r[S].add(r[P]),I[2]=r[S].toJ().mixedAdd(r[P].neg())):r[S].y.cmp(r[P].y.redNeg())===0?(I[1]=r[S].toJ().mixedAdd(r[P]),I[2]=r[S].add(r[P].neg())):(I[1]=r[S].toJ().mixedAdd(r[P]),I[2]=r[S].toJ().mixedAdd(r[P].neg()));var C=[-3,-1,-5,-7,0,7,5,1,3],T=n4e(n[S],n[P]);for(p=Math.max(T[0].length,p),h[S]=new Array(p),h[P]=new Array(p),v=0;v=0;b--){for(var J=0;b>=0;){var Q=!0;for(v=0;v=0&&J++,$=$.dblp(J),b<0)break;for(v=0;v0?E=f[v][K-1>>1]:K<0&&(E=f[v][-K-1>>1].neg()),E.type==="affine"?$=$.mixedAdd(E):$=$.add(E))}}for(b=0;b=Math.ceil((e.bitLength()+1)/r.step):!1};uo.prototype._getDoubles=function(e,r){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var n=[this],s=this,i=0;i=0&&(_=p,S=b),v.negative&&(v=v.neg(),E=E.neg()),_.negative&&(_=_.neg(),S=S.neg()),[{a:v,b:E},{a:_,b:S}]};lo.prototype._endoSplit=function(e){var r=this.endo.basis,n=r[0],s=r[1],i=s.b.mul(e).divRound(this.n),o=n.b.neg().mul(e).divRound(this.n),f=i.mul(n.a),h=o.mul(s.a),p=i.mul(n.b),b=o.mul(s.b),v=e.sub(f).sub(h),E=p.add(b).neg();return{k1:v,k2:E}};lo.prototype.pointFromX=function(e,r){e=new Mt(e,16),e.red||(e=e.toRed(this.red));var n=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),s=n.redSqrt();if(s.redSqr().redSub(n).cmp(this.zero)!==0)throw new Error("invalid point");var i=s.fromRed().isOdd();return(r&&!i||!r&&i)&&(s=s.redNeg()),this.point(e,s)};lo.prototype.validate=function(e){if(e.inf)return!0;var r=e.x,n=e.y,s=this.a.redMul(r),i=r.redSqr().redMul(r).redIAdd(s).redIAdd(this.b);return n.redSqr().redISub(i).cmpn(0)===0};lo.prototype._endoWnafMulAdd=function(e,r,n){for(var s=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""};_n.prototype.isInfinity=function(){return this.inf};_n.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(this.x.cmp(e.x)===0)return this.curve.point(null,null);var r=this.y.redSub(e.y);r.cmpn(0)!==0&&(r=r.redMul(this.x.redSub(e.x).redInvm()));var n=r.redSqr().redISub(this.x).redISub(e.x),s=r.redMul(this.x.redSub(n)).redISub(this.y);return this.curve.point(n,s)};_n.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(e.cmpn(0)===0)return this.curve.point(null,null);var r=this.curve.a,n=this.x.redSqr(),s=e.redInvm(),i=n.redAdd(n).redIAdd(n).redIAdd(r).redMul(s),o=i.redSqr().redISub(this.x.redAdd(this.x)),f=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,f)};_n.prototype.getX=function(){return this.x.fromRed()};_n.prototype.getY=function(){return this.y.fromRed()};_n.prototype.mul=function(e){return e=new Mt(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)};_n.prototype.mulAdd=function(e,r,n){var s=[this,r],i=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(s,i):this.curve._wnafMulAdd(1,s,i,2)};_n.prototype.jmulAdd=function(e,r,n){var s=[this,r],i=[e,n];return this.curve.endo?this.curve._endoWnafMulAdd(s,i,!0):this.curve._wnafMulAdd(1,s,i,2,!0)};_n.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||this.x.cmp(e.x)===0&&this.y.cmp(e.y)===0)};_n.prototype.neg=function(e){if(this.inf)return this;var r=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var n=this.precomputed,s=function(i){return i.neg()};r.precomputed={naf:n.naf&&{wnd:n.naf.wnd,points:n.naf.points.map(s)},doubles:n.doubles&&{step:n.doubles.step,points:n.doubles.points.map(s)}}}return r};_n.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var e=this.curve.jpoint(this.x,this.y,this.curve.one);return e};function $n(t,e,r,n){Hl.BasePoint.call(this,t,"jacobian"),e===null&&r===null&&n===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new Mt(0)):(this.x=new Mt(e,16),this.y=new Mt(r,16),this.z=new Mt(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}fP($n,Hl.BasePoint);lo.prototype.jpoint=function(e,r,n){return new $n(this,e,r,n)};$n.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),r=e.redSqr(),n=this.x.redMul(r),s=this.y.redMul(r).redMul(e);return this.curve.point(n,s)};$n.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};$n.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var r=e.z.redSqr(),n=this.z.redSqr(),s=this.x.redMul(r),i=e.x.redMul(n),o=this.y.redMul(r.redMul(e.z)),f=e.y.redMul(n.redMul(this.z)),h=s.redSub(i),p=o.redSub(f);if(h.cmpn(0)===0)return p.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var b=h.redSqr(),v=b.redMul(h),E=s.redMul(b),_=p.redSqr().redIAdd(v).redISub(E).redISub(E),S=p.redMul(E.redISub(_)).redISub(o.redMul(v)),P=this.z.redMul(e.z).redMul(h);return this.curve.jpoint(_,S,P)};$n.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var r=this.z.redSqr(),n=this.x,s=e.x.redMul(r),i=this.y,o=e.y.redMul(r).redMul(this.z),f=n.redSub(s),h=i.redSub(o);if(f.cmpn(0)===0)return h.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var p=f.redSqr(),b=p.redMul(f),v=n.redMul(p),E=h.redSqr().redIAdd(b).redISub(v).redISub(v),_=h.redMul(v.redISub(E)).redISub(i.redMul(b)),S=this.z.redMul(f);return this.curve.jpoint(E,_,S)};$n.prototype.dblp=function(e){if(e===0)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var r;if(this.curve.zeroA||this.curve.threeA){var n=this;for(r=0;r=0)return!1;if(n.redIAdd(i),this.x.cmp(n)===0)return!0}};$n.prototype.inspect=function(){return this.isInfinity()?"":""};$n.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var i2=T1(function(t,e){var r=e;r.base=Hl,r.short=s4e,r.mont=null,r.edwards=null}),s2=T1(function(t,e){var r=e,n=ms.assert;function s(f){f.type==="short"?this.curve=new i2.short(f):f.type==="edwards"?this.curve=new i2.edwards(f):this.curve=new i2.mont(f),this.g=this.curve.g,this.n=this.curve.n,this.hash=f.hash,n(this.g.validate(),"Invalid curve"),n(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}r.PresetCurve=s;function i(f,h){Object.defineProperty(r,f,{configurable:!0,enumerable:!0,get:function(){var p=new s(h);return Object.defineProperty(r,f,{configurable:!0,enumerable:!0,value:p}),p}})}i("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:Zi.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),i("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:Zi.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),i("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:Zi.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),i("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:Zi.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),i("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:Zi.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),i("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Zi.sha256,gRed:!1,g:["9"]}),i("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Zi.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var o;try{o=null.crash()}catch{o=void 0}i("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:Zi.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",o]})});function Ic(t){if(!(this instanceof Ic))return new Ic(t);this.hash=t.hash,this.predResist=!!t.predResist,this.outLen=this.hash.outSize,this.minEntropy=t.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var e=Lo.toArray(t.entropy,t.entropyEnc||"hex"),r=Lo.toArray(t.nonce,t.nonceEnc||"hex"),n=Lo.toArray(t.pers,t.persEnc||"hex");aP(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,n)}var kV=Ic;Ic.prototype._init=function(e,r,n){var s=e.concat(r).concat(n);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(n||[])),this._reseed=1};Ic.prototype.generate=function(e,r,n,s){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof r!="string"&&(s=n,n=r,r=null),n&&(n=Lo.toArray(n,s||"hex"),this._update(n));for(var i=[];i.length"};var o4e=ms.assert;function Lw(t,e){if(t instanceof Lw)return t;this._importDER(t,e)||(o4e(t.r&&t.s,"Signature without r or s"),this.r=new Mt(t.r,16),this.s=new Mt(t.s,16),t.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}var Dw=Lw;function a4e(){this.place=0}function u4(t,e){var r=t[e.place++];if(!(r&128))return r;var n=r&15;if(n===0||n>4)return!1;for(var s=0,i=0,o=e.place;i>>=0;return s<=127?!1:(e.place=o,s)}function pB(t){for(var e=0,r=t.length-1;!t[e]&&!(t[e+1]&128)&&e>>3);for(t.push(r|128);--r;)t.push(e>>>(r<<3)&255);t.push(e)}Lw.prototype.toDER=function(e){var r=this.r.toArray(),n=this.s.toArray();for(r[0]&128&&(r=[0].concat(r)),n[0]&128&&(n=[0].concat(n)),r=pB(r),n=pB(n);!n[0]&&!(n[1]&128);)n=n.slice(1);var s=[2];l4(s,r.length),s=s.concat(r),s.push(2),l4(s,n.length);var i=s.concat(n),o=[48];return l4(o,i.length),o=o.concat(i),ms.encode(o,e)};var f4e=function(){throw new Error("unsupported")},RV=ms.assert;function Js(t){if(!(this instanceof Js))return new Js(t);typeof t=="string"&&(RV(Object.prototype.hasOwnProperty.call(s2,t),"Unknown curve "+t),t=s2[t]),t instanceof s2.PresetCurve&&(t={curve:t}),this.curve=t.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=t.curve.g,this.g.precompute(t.curve.n.bitLength()+1),this.hash=t.hash||t.curve.hash}var c4e=Js;Js.prototype.keyPair=function(e){return new cP(this,e)};Js.prototype.keyFromPrivate=function(e,r){return cP.fromPrivate(this,e,r)};Js.prototype.keyFromPublic=function(e,r){return cP.fromPublic(this,e,r)};Js.prototype.genKeyPair=function(e){e||(e={});for(var r=new kV({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||f4e(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),n=this.n.byteLength(),s=this.n.sub(new Mt(2));;){var i=new Mt(r.generate(n));if(!(i.cmp(s)>0))return i.iaddn(1),this.keyFromPrivate(i)}};Js.prototype._truncateToN=function(e,r){var n=e.byteLength()*8-this.n.bitLength();return n>0&&(e=e.ushrn(n)),!r&&e.cmp(this.n)>=0?e.sub(this.n):e};Js.prototype.sign=function(e,r,n,s){typeof n=="object"&&(s=n,n=null),s||(s={}),r=this.keyFromPrivate(r,n),e=this._truncateToN(new Mt(e,16));for(var i=this.n.byteLength(),o=r.getPrivate().toArray("be",i),f=e.toArray("be",i),h=new kV({hash:this.hash,entropy:o,nonce:f,pers:s.pers,persEnc:s.persEnc||"utf8"}),p=this.n.sub(new Mt(1)),b=0;;b++){var v=s.k?s.k(b):new Mt(h.generate(this.n.byteLength()));if(v=this._truncateToN(v,!0),!(v.cmpn(1)<=0||v.cmp(p)>=0)){var E=this.g.mul(v);if(!E.isInfinity()){var _=E.getX(),S=_.umod(this.n);if(S.cmpn(0)!==0){var P=v.invm(this.n).mul(S.mul(r.getPrivate()).iadd(e));if(P=P.umod(this.n),P.cmpn(0)!==0){var I=(E.getY().isOdd()?1:0)|(_.cmp(S)!==0?2:0);return s.canonical&&P.cmp(this.nh)>0&&(P=this.n.sub(P),I^=1),new Dw({r:S,s:P,recoveryParam:I})}}}}}};Js.prototype.verify=function(e,r,n,s){e=this._truncateToN(new Mt(e,16)),n=this.keyFromPublic(n,s),r=new Dw(r,"hex");var i=r.r,o=r.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0||o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var f=o.invm(this.n),h=f.mul(e).umod(this.n),p=f.mul(i).umod(this.n),b;return this.curve._maxwellTrick?(b=this.g.jmulAdd(h,n.getPublic(),p),b.isInfinity()?!1:b.eqXToP(i)):(b=this.g.mulAdd(h,n.getPublic(),p),b.isInfinity()?!1:b.getX().umod(this.n).cmp(i)===0)};Js.prototype.recoverPubKey=function(t,e,r,n){RV((3&r)===r,"The recovery param is more than two bits"),e=new Dw(e,n);var s=this.n,i=new Mt(t),o=e.r,f=e.s,h=r&1,p=r>>1;if(o.cmp(this.curve.p.umod(this.curve.n))>=0&&p)throw new Error("Unable to find sencond key candinate");p?o=this.curve.pointFromX(o.add(this.curve.n),h):o=this.curve.pointFromX(o,h);var b=e.r.invm(s),v=s.sub(i).mul(b).umod(s),E=f.mul(b).umod(s);return this.g.mulAdd(v,o,E)};Js.prototype.getKeyRecoveryParam=function(t,e,r,n){if(e=new Dw(e,n),e.recoveryParam!==null)return e.recoveryParam;for(var s=0;s<4;s++){var i;try{i=this.recoverPubKey(t,e,s)}catch{continue}if(i.eq(r))return s}throw new Error("Unable to find valid recovery factor")};var u4e=T1(function(t,e){var r=e;r.version="6.5.4",r.utils=ms,r.rand=function(){throw new Error("unsupported")},r.curve=i2,r.curves=s2,r.ec=c4e,r.eddsa=null}),l4e=u4e.ec;const h4e="signing-key/5.7.0",sA=new rt(h4e);let h4=null;function nf(){return h4||(h4=new l4e("secp256k1")),h4}class cd{constructor(e){St(this,"curve","secp256k1"),St(this,"privateKey",pt(e)),wV(this.privateKey)!==32&&sA.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const r=nf().keyFromPrivate(Ze(this.privateKey));St(this,"publicKey","0x"+r.getPublic(!1,"hex")),St(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),St(this,"_isSigningKey",!0)}_addPoint(e){const r=nf().keyFromPublic(Ze(this.publicKey)),n=nf().keyFromPublic(Ze(e));return"0x"+r.pub.add(n.pub).encodeCompressed("hex")}signDigest(e){const r=nf().keyFromPrivate(Ze(this.privateKey)),n=Ze(e);n.length!==32&&sA.throwArgumentError("bad digest length","digest",e);const s=r.sign(n,{canonical:!0});return cb({recoveryParam:s.recoveryParam,r:Ds("0x"+s.r.toString(16),32),s:Ds("0x"+s.s.toString(16),32)})}computeSharedSecret(e){const r=nf().keyFromPrivate(Ze(this.privateKey)),n=nf().keyFromPublic(Ze(BV(e)));return Ds("0x"+r.derive(n.getPublic()).toString(16),32)}static isSigningKey(e){return!!(e&&e._isSigningKey)}}function BV(t,e){const r=Ze(t);if(r.length===32){const n=new cd(r);return e?"0x"+nf().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}else{if(r.length===33)return e?pt(r):"0x"+nf().keyFromPublic(r).getPublic(!1,"hex");if(r.length===65)return e?"0x"+nf().keyFromPublic(r).getPublic(!0,"hex"):pt(r)}return sA.throwArgumentError("invalid public or private key","key","[REDACTED]")}const d4e="transactions/5.7.0",Bo=new rt(d4e);var mB;(function(t){t[t.legacy=0]="legacy",t[t.eip2930=1]="eip2930",t[t.eip1559=2]="eip1559"})(mB||(mB={}));const p4e=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],m4e={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function ud(t){const e=BV(t);return Xo(Ng(kn(Ng(e,1)),12))}function Qi(t,e){const r=pc(mr.from(t).toHexString());return r.length>32&&Bo.throwArgumentError("invalid length for "+e,"transaction:"+e,t),r}function d4(t,e){return{address:Xo(t),storageKeys:(e||[]).map((r,n)=>(wV(r)!==32&&Bo.throwArgumentError("invalid access list storageKey",`accessList[${t}:${n}]`,r),r.toLowerCase()))}}function g4e(t){if(Array.isArray(t))return t.map((r,n)=>Array.isArray(r)?(r.length>2&&Bo.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${n}]`,r),d4(r[0],r[1])):d4(r.address,r.storageKeys));const e=Object.keys(t).map(r=>{const n=t[r].reduce((s,i)=>(s[i]=!0,s),{});return d4(r,Object.keys(n).sort())});return e.sort((r,n)=>r.address.localeCompare(n.address)),e}function OV(t){return g4e(t).map(e=>[e.address,e.storageKeys])}function y4e(t,e){if(t.gasPrice!=null){const n=mr.from(t.gasPrice),s=mr.from(t.maxFeePerGas||0);n.eq(s)||Bo.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:n,maxFeePerGas:s})}const r=[Qi(t.chainId||0,"chainId"),Qi(t.nonce||0,"nonce"),Qi(t.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),Qi(t.maxFeePerGas||0,"maxFeePerGas"),Qi(t.gasLimit||0,"gasLimit"),t.to!=null?Xo(t.to):"0x",Qi(t.value||0,"value"),t.data||"0x",OV(t.accessList||[])];if(e){const n=cb(e);r.push(Qi(n.recoveryParam,"recoveryParam")),r.push(pc(n.r)),r.push(pc(n.s))}return fd(["0x02",J6(r)])}function b4e(t,e){const r=[Qi(t.chainId||0,"chainId"),Qi(t.nonce||0,"nonce"),Qi(t.gasPrice||0,"gasPrice"),Qi(t.gasLimit||0,"gasLimit"),t.to!=null?Xo(t.to):"0x",Qi(t.value||0,"value"),t.data||"0x",OV(t.accessList||[])];if(e){const n=cb(e);r.push(Qi(n.recoveryParam,"recoveryParam")),r.push(pc(n.r)),r.push(pc(n.s))}return fd(["0x01",J6(r)])}function v4e(t,e){C8e(t,m4e);const r=[];p4e.forEach(function(o){let f=t[o.name]||[];const h={};o.numeric&&(h.hexPad="left"),f=Ze(pt(f,h)),o.length&&f.length!==o.length&&f.length>0&&Bo.throwArgumentError("invalid length for "+o.name,"transaction:"+o.name,f),o.maxLength&&(f=pc(f),f.length>o.maxLength&&Bo.throwArgumentError("invalid length for "+o.name,"transaction:"+o.name,f)),r.push(pt(f))});let n=0;if(t.chainId!=null?(n=t.chainId,typeof n!="number"&&Bo.throwArgumentError("invalid transaction.chainId","transaction",t)):e&&!rP(e)&&e.v>28&&(n=Math.floor((e.v-35)/2)),n!==0&&(r.push(pt(n)),r.push("0x"),r.push("0x")),!e)return J6(r);const s=cb(e);let i=27+s.recoveryParam;return n!==0?(r.pop(),r.pop(),r.pop(),i+=n*2+8,s.v>28&&s.v!==i&&Bo.throwArgumentError("transaction.chainId/signature.v mismatch","signature",e)):s.v!==i&&Bo.throwArgumentError("transaction.chainId/signature.v mismatch","signature",e),r.push(pt(i)),r.push(pc(Ze(s.r))),r.push(pc(Ze(s.s))),J6(r)}function gB(t,e){if(t.type==null||t.type===0)return t.accessList!=null&&Bo.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",t),v4e(t,e);switch(t.type){case 1:return b4e(t,e);case 2:return y4e(t,e)}return Bo.throwError(`unsupported transaction type: ${t.type}`,rt.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:t.type})}class NV{constructor(e){St(this,"alphabet",e),St(this,"base",e.length),St(this,"_alphabetMap",{}),St(this,"_leader",e.charAt(0));for(let r=0;r0;)n.push(o%this.base),o=o/this.base|0}let s="";for(let i=0;r[i]===0&&i=0;--i)s+=this.alphabet[n[i]];return s}decode(e){if(typeof e!="string")throw new TypeError("Expected String");let r=[];if(e.length===0)return new Uint8Array(r);r.push(0);for(let n=0;n>=8;for(;i>0;)r.push(i&255),i>>=8}for(let n=0;e[n]===this._leader&&n>24&255,h[e.length+1]=v>>16&255,h[e.length+2]=v>>8&255,h[e.length+3]=v&255;let E=Ze(Y6(s,t,h));i||(i=E.length,b=new Uint8Array(i),o=Math.ceil(n/i),p=n-(o-1)*i),b.set(E);for(let P=1;P=256)throw new Error("Depth too large!");return vB(Fa([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",pt(this.depth),this.parentFingerprint,Ds(pt(this.index),4),this.chainCode,this.privateKey!=null?Fa(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new Ps(sh,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let r=this.path;r&&(r+="/"+(e&~om));const n=new Uint8Array(37);if(e&om){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(Ze(this.privateKey),1),r&&(r+="'")}else n.set(Ze(this.publicKey));for(let v=24;v>=0;v-=8)n[33+(v>>3)]=e>>24-v&255;const s=Ze(Y6(Dg.sha512,this.chainCode,n)),i=s.slice(0,32),o=s.slice(32);let f=null,h=null;this.privateKey?f=cv(mr.from(i).add(this.privateKey).mod(C4e)):h=new cd(pt(i))._addPoint(this.publicKey);let p=r;const b=this.mnemonic;return b&&(p=Object.freeze({phrase:b.phrase,path:r,locale:b.locale||"en"})),new Ps(sh,f,h,this.fingerprint,cv(o),e,this.depth+1,p)}derivePath(e){const r=e.split("/");if(r.length===0||r[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);r[0]==="m"&&r.shift();let n=this;for(let s=0;s=om)throw new Error("invalid path index - "+i);n=n._derive(om+o)}else if(i.match(/^[0-9]+$/)){const o=parseInt(i);if(o>=om)throw new Error("invalid path index - "+i);n=n._derive(o)}else throw new Error("invalid path component - "+i)}return n}static _fromSeed(e,r){const n=Ze(e);if(n.length<16||n.length>64)throw new Error("invalid seed");const s=Ze(Y6(Dg.sha512,I4e,n));return new Ps(sh,cv(s.slice(0,32)),null,"0x00000000",cv(s.slice(32)),0,0,r)}static fromMnemonic(e,r,n){return n=lP(n),e=hP(FV(e,n),n),Ps._fromSeed(k4e(e,r),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return Ps._fromSeed(e,null)}static fromExtendedKey(e){const r=LV.decode(e);(r.length!==82||vB(r.slice(0,78))!==e)&&X6.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");const n=r[4],s=pt(r.slice(5,9)),i=parseInt(pt(r.slice(9,13)).substring(2),16),o=pt(r.slice(13,45)),f=r.slice(45,78);switch(pt(r.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new Ps(sh,null,pt(f),s,o,i,n,null);case"0x0488ade4":case"0x04358394 ":if(f[0]!==0)break;return new Ps(sh,pt(f.slice(1)),null,s,o,i,n,null)}return X6.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}function k4e(t,e){e||(e="");const r=jo("mnemonic"+e,vl.NFKD);return uP(jo(t,vl.NFKD),r,2048,64,"sha512")}function FV(t,e){e=lP(e),X6.checkNormalize();const r=e.split(t);if(r.length%3!==0)throw new Error("invalid mnemonic");const n=Ze(new Uint8Array(Math.ceil(11*r.length/8)));let s=0;for(let p=0;p>3]|=1<<7-s%8),s++}const i=32*r.length/3,o=r.length/3,f=$V(o);if((Ze($g(n.slice(0,i/8)))[0]&f)!==(n[n.length-1]&f))throw new Error("invalid checksum");return pt(n.slice(0,i/8))}function hP(t,e){if(e=lP(e),t=Ze(t),t.length%4!==0||t.length<16||t.length>32)throw new Error("invalid entropy");const r=[0];let n=11;for(let o=0;o8?(r[r.length-1]<<=8,r[r.length-1]|=t[o],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=t[o]>>8-n,r.push(t[o]&T4e(8-n)),n+=3);const s=t.length/4,i=Ze($g(t))[0]&$V(s);return r[r.length-1]<<=s,r[r.length-1]|=i>>8-s,e.join(r.map(o=>e.getWord(o)))}const R4e="random/5.7.0",oA=new rt(R4e);function B4e(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof Ve.global<"u")return Ve.global;throw new Error("unable to locate global object")}const xB=B4e();let o2=xB.crypto||xB.msCrypto;(!o2||!o2.getRandomValues)&&(oA.warn("WARNING: Missing strong random number source"),o2={getRandomValues:function(t){return oA.throwError("no secure random source avaialble",rt.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Mm(t){(t<=0||t>1024||t%1||t!=t)&&oA.throwArgumentError("invalid length","length",t);const e=new Uint8Array(t);return o2.getRandomValues(e),Ze(e)}var UV={exports:{}};(function(t,e){(function(r){function n(g){return parseInt(g)===g}function s(g){if(!n(g.length))return!1;for(var M=0;M255)return!1;return!0}function i(g,M){if(g.buffer&&ArrayBuffer.isView(g)&&g.name==="Uint8Array")return M&&(g.slice?g=g.slice():g=Array.prototype.slice.call(g)),g;if(Array.isArray(g)){if(!s(g))throw new Error("Array contains invalid value: "+g);return new Uint8Array(g)}if(n(g.length)&&s(g))return new Uint8Array(g);throw new Error("unsupported array-like object")}function o(g){return new Uint8Array(g)}function f(g,M,R,L,k){(L!=null||k!=null)&&(g.slice?g=g.slice(L,k):g=Array.prototype.slice.call(g,L,k)),M.set(g,R)}var h=function(){function g(R){var L=[],k=0;for(R=encodeURI(R);k191&&D<224?(L.push(String.fromCharCode((D&31)<<6|R[k+1]&63)),k+=2):(L.push(String.fromCharCode((D&15)<<12|(R[k+1]&63)<<6|R[k+2]&63)),k+=3)}return L.join("")}return{toBytes:g,fromBytes:M}}(),p=function(){function g(L){for(var k=[],D=0;D>4]+M[U&15])}return k.join("")}return{toBytes:g,fromBytes:R}}(),b={16:10,24:12,32:14},v=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],E=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],_=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],S=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],P=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],I=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],C=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],T=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],B=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],N=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],$=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],H=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],J=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],Q=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],K=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function se(g){for(var M=[],R=0;R>2,this._Ke[D][M%4]=k[M],this._Kd[g-D][M%4]=k[M];for(var U=0,V=L,G;V>16&255]<<24^E[G>>8&255]<<16^E[G&255]<<8^E[G>>24&255]^v[U]<<24,U+=1,L!=8)for(var M=1;M>8&255]<<8^E[G>>16&255]<<16^E[G>>24&255]<<24;for(var M=L/2+1;M>2,q=V%4,this._Ke[Y][q]=k[M],this._Kd[g-Y][q]=k[M++],V++}for(var Y=1;Y>24&255]^J[G>>16&255]^Q[G>>8&255]^K[G&255]},w.prototype.encrypt=function(g){if(g.length!=16)throw new Error("invalid plaintext size (must be 16 bytes)");for(var M=this._Ke.length-1,R=[0,0,0,0],L=se(g),k=0;k<4;k++)L[k]^=this._Ke[0][k];for(var D=1;D>24&255]^P[L[(k+1)%4]>>16&255]^I[L[(k+2)%4]>>8&255]^C[L[(k+3)%4]&255]^this._Ke[D][k];L=R.slice()}for(var U=o(16),V,k=0;k<4;k++)V=this._Ke[M][k],U[4*k]=(E[L[k]>>24&255]^V>>24)&255,U[4*k+1]=(E[L[(k+1)%4]>>16&255]^V>>16)&255,U[4*k+2]=(E[L[(k+2)%4]>>8&255]^V>>8)&255,U[4*k+3]=(E[L[(k+3)%4]&255]^V)&255;return U},w.prototype.decrypt=function(g){if(g.length!=16)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var M=this._Kd.length-1,R=[0,0,0,0],L=se(g),k=0;k<4;k++)L[k]^=this._Kd[0][k];for(var D=1;D>24&255]^B[L[(k+3)%4]>>16&255]^N[L[(k+2)%4]>>8&255]^$[L[(k+1)%4]&255]^this._Kd[D][k];L=R.slice()}for(var U=o(16),V,k=0;k<4;k++)V=this._Kd[M][k],U[4*k]=(_[L[k]>>24&255]^V>>24)&255,U[4*k+1]=(_[L[(k+3)%4]>>16&255]^V>>16)&255,U[4*k+2]=(_[L[(k+2)%4]>>8&255]^V>>8)&255,U[4*k+3]=(_[L[(k+1)%4]&255]^V)&255;return U};var a=function(g){if(!(this instanceof a))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new w(g)};a.prototype.encrypt=function(g){if(g=i(g),g.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var M=o(g.length),R=o(16),L=0;L=0;--M)this._counter[M]=g%256,g=g>>8},m.prototype.setBytes=function(g){if(g=i(g,!0),g.length!=16)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=g},m.prototype.increment=function(){for(var g=15;g>=0;g--)if(this._counter[g]===255)this._counter[g]=0;else{this._counter[g]++;break}};var x=function(g,M){if(!(this instanceof x))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",M instanceof m||(M=new m(M)),this._counter=M,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new w(g)};x.prototype.encrypt=function(g){for(var M=i(g,!0),R=0;R16)throw new Error("PKCS#7 padding byte out of range");for(var R=g.length-M,L=0;L=64;){let c=C,g=T,M=B,R=N,L=$,k=H,D=J,U=Q,V,G,Y,q,z;for(G=0;G<16;G++)Y=A+G*4,K[G]=(x[Y]&255)<<24|(x[Y+1]&255)<<16|(x[Y+2]&255)<<8|x[Y+3]&255;for(G=16;G<64;G++)V=K[G-2],q=(V>>>17|V<<32-17)^(V>>>19|V<<32-19)^V>>>10,V=K[G-15],z=(V>>>7|V<<32-7)^(V>>>18|V<<32-18)^V>>>3,K[G]=(q+K[G-7]|0)+(z+K[G-16]|0)|0;for(G=0;G<64;G++)q=(((L>>>6|L<<32-6)^(L>>>11|L<<32-11)^(L>>>25|L<<32-25))+(L&k^~L&D)|0)+(U+(I[G]+K[G]|0)|0)|0,z=((c>>>2|c<<32-2)^(c>>>13|c<<32-13)^(c>>>22|c<<32-22))+(c&g^c&M^g&M)|0,U=D,D=k,k=L,L=R+q|0,R=M,M=g,g=c,c=q+z|0;C=C+c|0,T=T+g|0,B=B+M|0,N=N+R|0,$=$+L|0,H=H+k|0,J=J+D|0,Q=Q+U|0,A+=64,y-=64}}se(P);let w,a=P.length%64,u=P.length/536870912|0,l=P.length<<3,d=a<56?56:120,m=P.slice(P.length-a,P.length);for(m.push(128),w=a+1;w>>24&255),m.push(u>>>16&255),m.push(u>>>8&255),m.push(u>>>0&255),m.push(l>>>24&255),m.push(l>>>16&255),m.push(l>>>8&255),m.push(l>>>0&255),se(m),[C>>>24&255,C>>>16&255,C>>>8&255,C>>>0&255,T>>>24&255,T>>>16&255,T>>>8&255,T>>>0&255,B>>>24&255,B>>>16&255,B>>>8&255,B>>>0&255,N>>>24&255,N>>>16&255,N>>>8&255,N>>>0&255,$>>>24&255,$>>>16&255,$>>>8&255,$>>>0&255,H>>>24&255,H>>>16&255,H>>>8&255,H>>>0&255,J>>>24&255,J>>>16&255,J>>>8&255,J>>>0&255,Q>>>24&255,Q>>>16&255,Q>>>8&255,Q>>>0&255]}function i(P,I,C){P=P.length<=64?P:s(P);const T=64+I.length+4,B=new Array(T),N=new Array(64);let $,H=[];for($=0;$<64;$++)B[$]=54;for($=0;$=T-4;Q--){if(B[Q]++,B[Q]<=255)return;B[Q]=0}}for(;C>=32;)J(),H=H.concat(s(N.concat(s(B)))),C-=32;return C>0&&(J(),H=H.concat(s(N.concat(s(B))).slice(0,C))),H}function o(P,I,C,T,B){let N;for(b(P,(2*C-1)*16,B,0,16),N=0;N<2*C;N++)p(P,N*16,B,16),h(B,T),b(B,0,P,I+N*16,16);for(N=0;N>>32-I}function h(P,I){b(P,0,I,0,16);for(let C=8;C>0;C-=2)I[4]^=f(I[0]+I[12],7),I[8]^=f(I[4]+I[0],9),I[12]^=f(I[8]+I[4],13),I[0]^=f(I[12]+I[8],18),I[9]^=f(I[5]+I[1],7),I[13]^=f(I[9]+I[5],9),I[1]^=f(I[13]+I[9],13),I[5]^=f(I[1]+I[13],18),I[14]^=f(I[10]+I[6],7),I[2]^=f(I[14]+I[10],9),I[6]^=f(I[2]+I[14],13),I[10]^=f(I[6]+I[2],18),I[3]^=f(I[15]+I[11],7),I[7]^=f(I[3]+I[15],9),I[11]^=f(I[7]+I[3],13),I[15]^=f(I[11]+I[7],18),I[1]^=f(I[0]+I[3],7),I[2]^=f(I[1]+I[0],9),I[3]^=f(I[2]+I[1],13),I[0]^=f(I[3]+I[2],18),I[6]^=f(I[5]+I[4],7),I[7]^=f(I[6]+I[5],9),I[4]^=f(I[7]+I[6],13),I[5]^=f(I[4]+I[7],18),I[11]^=f(I[10]+I[9],7),I[8]^=f(I[11]+I[10],9),I[9]^=f(I[8]+I[11],13),I[10]^=f(I[9]+I[8],18),I[12]^=f(I[15]+I[14],7),I[13]^=f(I[12]+I[15],9),I[14]^=f(I[13]+I[12],13),I[15]^=f(I[14]+I[13],18);for(let C=0;C<16;++C)P[C]+=I[C]}function p(P,I,C,T){for(let B=0;B=256)return!1}return!0}function E(P,I){if(typeof P!="number"||P%1)throw new Error("invalid "+I);return P}function _(P,I,C,T,B,N,$){if(C=E(C,"N"),T=E(T,"r"),B=E(B,"p"),N=E(N,"dkLen"),C===0||C&C-1)throw new Error("N must be power of 2");if(C>2147483647/128/T)throw new Error("N too large");if(T>2147483647/128/B)throw new Error("r too large");if(!v(P))throw new Error("password must be an array or buffer");if(P=Array.prototype.slice.call(P),!v(I))throw new Error("salt must be an array or buffer");I=Array.prototype.slice.call(I);let H=i(P,I,B*128*T);const J=new Uint32Array(B*32*T);for(let L=0;Lg&&(L=g);for(let D=0;Dg&&(L=g);for(let D=0;D>0&255),H.push(J[D]>>8&255),H.push(J[D]>>16&255),H.push(J[D]>>24&255);const k=i(P,H,N);return $&&$(null,1,k),k}$&&M(R)};if(!$)for(;;){const L=R();if(L!=null)return L}R()}const S={scrypt:function(P,I,C,T,B,N,$){return new Promise(function(H,J){let Q=0;$&&$(0),_(P,I,C,T,B,N,function(K,se,w){if(K)J(K);else if(w)$&&Q!==1&&$(1),H(new Uint8Array(w));else if($&&se!==Q)return Q=se,$(se)})})},syncScrypt:function(P,I,C,T,B,N){return new Uint8Array(_(P,I,C,T,B,N))}};t.exports=S})()})(GV);var $4e=GV.exports;const pP=Qs($4e);var F4e=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const aA=new rt(zV);function wB(t){return t!=null&&t.mnemonic&&t.mnemonic.phrase}class U4e extends EV{isKeystoreAccount(e){return!!(e&&e._isKeystoreAccount)}}function z4e(t,e,r){if(Gr(t,"crypto/cipher")==="aes-128-ctr"){const s=Zu(Gr(t,"crypto/cipherparams/iv")),i=new Sa.Counter(s),o=new Sa.ModeOfOperation.ctr(e,i);return Ze(o.decrypt(r))}return null}function VV(t,e){const r=Zu(Gr(t,"crypto/ciphertext"));if(pt(kn(Fa([e.slice(16,32),r]))).substring(2)!==Gr(t,"crypto/mac").toLowerCase())throw new Error("invalid password");const s=z4e(t,e.slice(0,16),r);s||aA.throwError("unsupported cipher",rt.errors.UNSUPPORTED_OPERATION,{operation:"decrypt"});const i=e.slice(32,64),o=ud(s);if(t.address){let h=t.address.toLowerCase();if(h.substring(0,2)!=="0x"&&(h="0x"+h),Xo(h)!==o)throw new Error("address mismatch")}const f={_isKeystoreAccount:!0,address:o,privateKey:pt(s)};if(Gr(t,"x-ethers/version")==="0.1"){const h=Zu(Gr(t,"x-ethers/mnemonicCiphertext")),p=Zu(Gr(t,"x-ethers/mnemonicCounter")),b=new Sa.Counter(p),v=new Sa.ModeOfOperation.ctr(i,b),E=Gr(t,"x-ethers/path")||Fg,_=Gr(t,"x-ethers/locale")||"en",S=Ze(v.decrypt(h));try{const P=hP(S,_),I=Ps.fromMnemonic(P,null,_).derivePath(E);if(I.privateKey!=f.privateKey)throw new Error("mnemonic mismatch");f.mnemonic=I.mnemonic}catch(P){if(P.code!==rt.errors.INVALID_ARGUMENT||P.argument!=="wordlist")throw P}}return new U4e(f)}function KV(t,e,r,n,s){return Ze(uP(t,e,r,n,s))}function j4e(t,e,r,n,s){return Promise.resolve(KV(t,e,r,n,s))}function WV(t,e,r,n,s){const i=dP(e),o=Gr(t,"crypto/kdf");if(o&&typeof o=="string"){const f=function(h,p){return aA.throwArgumentError("invalid key-derivation function parameters",h,p)};if(o.toLowerCase()==="scrypt"){const h=Zu(Gr(t,"crypto/kdfparams/salt")),p=parseInt(Gr(t,"crypto/kdfparams/n")),b=parseInt(Gr(t,"crypto/kdfparams/r")),v=parseInt(Gr(t,"crypto/kdfparams/p"));(!p||!b||!v)&&f("kdf",o),p&p-1&&f("N",p);const E=parseInt(Gr(t,"crypto/kdfparams/dklen"));return E!==32&&f("dklen",E),n(i,h,p,b,v,64,s)}else if(o.toLowerCase()==="pbkdf2"){const h=Zu(Gr(t,"crypto/kdfparams/salt"));let p=null;const b=Gr(t,"crypto/kdfparams/prf");b==="hmac-sha256"?p="sha256":b==="hmac-sha512"?p="sha512":f("prf",b);const v=parseInt(Gr(t,"crypto/kdfparams/c")),E=parseInt(Gr(t,"crypto/kdfparams/dklen"));return E!==32&&f("dklen",E),r(i,h,v,E,p)}}return aA.throwArgumentError("unsupported key-derivation function","kdf",o)}function H4e(t,e){const r=JSON.parse(t),n=WV(r,e,KV,pP.syncScrypt);return VV(r,n)}function q4e(t,e,r){return F4e(this,void 0,void 0,function*(){const n=JSON.parse(t),s=yield WV(n,e,j4e,pP.scrypt,r);return VV(n,s)})}function G4e(t,e,r,n){try{if(Xo(t.address)!==ud(t.privateKey))throw new Error("address/privateKey mismatch");if(wB(t)){const I=t.mnemonic;if(Ps.fromMnemonic(I.phrase,null,I.locale).derivePath(I.path||Fg).privateKey!=t.privateKey)throw new Error("mnemonic mismatch")}}catch(I){return Promise.reject(I)}typeof r=="function"&&!n&&(n=r,r={}),r||(r={});const s=Ze(t.privateKey),i=dP(e);let o=null,f=null,h=null;if(wB(t)){const I=t.mnemonic;o=Ze(FV(I.phrase,I.locale||"en")),f=I.path||Fg,h=I.locale||"en"}let p=r.client;p||(p="ethers.js");let b=null;r.salt?b=Ze(r.salt):b=Mm(32);let v=null;if(r.iv){if(v=Ze(r.iv),v.length!==16)throw new Error("invalid iv")}else v=Mm(16);let E=null;if(r.uuid){if(E=Ze(r.uuid),E.length!==16)throw new Error("invalid uuid")}else E=Mm(16);let _=1<<17,S=8,P=1;return r.scrypt&&(r.scrypt.N&&(_=r.scrypt.N),r.scrypt.r&&(S=r.scrypt.r),r.scrypt.p&&(P=r.scrypt.p)),pP.scrypt(i,b,_,S,P,64,n).then(I=>{I=Ze(I);const C=I.slice(0,16),T=I.slice(16,32),B=I.slice(32,64),N=new Sa.Counter(v),$=new Sa.ModeOfOperation.ctr(C,N),H=Ze($.encrypt(s)),J=kn(Fa([T,H])),Q={address:t.address.substring(2).toLowerCase(),id:N4e(E),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:pt(v).substring(2)},ciphertext:pt(H).substring(2),kdf:"scrypt",kdfparams:{salt:pt(b).substring(2),n:_,dklen:32,p:P,r:S},mac:J.substring(2)}};if(o){const K=Mm(16),se=new Sa.Counter(K),w=new Sa.ModeOfOperation.ctr(B,se),a=Ze(w.encrypt(o)),u=new Date,l=u.getUTCFullYear()+"-"+am(u.getUTCMonth()+1,2)+"-"+am(u.getUTCDate(),2)+"T"+am(u.getUTCHours(),2)+"-"+am(u.getUTCMinutes(),2)+"-"+am(u.getUTCSeconds(),2)+".0Z";Q["x-ethers"]={client:p,gethFilename:"UTC--"+l+"--"+Q.address,mnemonicCounter:pt(K).substring(2),mnemonicCiphertext:pt(a).substring(2),path:f,locale:h,version:"0.1"}}return JSON.stringify(Q)})}function V4e(t,e,r){if(HV(t)){r&&r(0);const n=jV(t,e);return r&&r(1),Promise.resolve(n)}return qV(t)?q4e(t,e,r):Promise.reject(new Error("invalid JSON wallet"))}function K4e(t,e){if(HV(t))return jV(t,e);if(qV(t))return H4e(t,e);throw new Error("invalid JSON wallet")}const W4e="wallet/5.7.0";var AB=globalThis&&globalThis.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function f(b){try{p(n.next(b))}catch(v){o(v)}}function h(b){try{p(n.throw(b))}catch(v){o(v)}}function p(b){b.done?i(b.value):s(b.value).then(f,h)}p((n=n.apply(t,e||[])).next())})};const oh=new rt(W4e);function J4e(t){return t!=null&&di(t.privateKey,32)&&t.address!=null}function Z4e(t){const e=t.mnemonic;return e&&e.phrase}class k0 extends oP{constructor(e,r){if(super(),J4e(e)){const n=new cd(e.privateKey);if(St(this,"_signingKey",()=>n),St(this,"address",ud(this.publicKey)),this.address!==Xo(e.address)&&oh.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),Z4e(e)){const s=e.mnemonic;St(this,"_mnemonic",()=>({phrase:s.phrase,path:s.path||Fg,locale:s.locale||"en"}));const i=this.mnemonic,o=Ps.fromMnemonic(i.phrase,null,i.locale).derivePath(i.path);ud(o.privateKey)!==this.address&&oh.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else St(this,"_mnemonic",()=>null)}else{if(cd.isSigningKey(e))e.curve!=="secp256k1"&&oh.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),St(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);const n=new cd(e);St(this,"_signingKey",()=>n)}St(this,"_mnemonic",()=>null),St(this,"address",ud(this.publicKey))}r&&!sP.isProvider(r)&&oh.throwArgumentError("invalid provider","provider",r),St(this,"provider",r||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new k0(this,e)}signTransaction(e){return Nh(e).then(r=>{r.from!=null&&(Xo(r.from)!==this.address&&oh.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete r.from);const n=this._signingKey().signDigest(kn(gB(r)));return gB(r,n)})}signMessage(e){return AB(this,void 0,void 0,function*(){return iB(this._signingKey().signDigest(_V(e)))})}_signTypedData(e,r,n){return AB(this,void 0,void 0,function*(){const s=yield qi.resolveNames(e,r,n,i=>(this.provider==null&&oh.throwError("cannot resolve ENS names without a provider",rt.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:i}),this.provider.resolveName(i)));return iB(this._signingKey().signDigest(qi.hash(s.domain,r,s.value)))})}encrypt(e,r,n){if(typeof r=="function"&&!n&&(n=r,r={}),n&&typeof n!="function")throw new Error("invalid callback");return r||(r={}),G4e(this,e,r,n)}static createRandom(e){let r=Mm(16);e||(e={}),e.extraEntropy&&(r=Ze(Ng(kn(Fa([r,e.extraEntropy])),0,16)));const n=hP(r,e.locale);return k0.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,r,n){return V4e(e,r,n).then(s=>new k0(s))}static fromEncryptedJsonSync(e,r){return new k0(K4e(e,r))}static fromMnemonic(e,r,n){return r||(r=Fg),new k0(Ps.fromMnemonic(e,null,n).derivePath(r))}}const Q4e="solidity/5.7.0",Y4e=new RegExp("^bytes([0-9]+)$"),X4e=new RegExp("^(u?int)([0-9]*)$"),e9e=new RegExp("^(.*)\\[([0-9]*)\\]$"),t9e="0000000000000000000000000000000000000000000000000000000000000000",dh=new rt(Q4e);function JV(t,e,r){switch(t){case"address":return r?n2(e,32):Ze(e);case"string":return jo(e);case"bytes":return Ze(e);case"bool":return e=e?"0x01":"0x00",r?n2(e,32):Ze(e)}let n=t.match(X4e);if(n){let s=parseInt(n[2]||"256");return(n[2]&&String(s)!==n[2]||s%8!==0||s===0||s>256)&&dh.throwArgumentError("invalid number type","type",t),r&&(s=256),e=mr.from(e).toTwos(s),n2(e,s/8)}if(n=t.match(Y4e),n){const s=parseInt(n[1]);return(String(s)!==n[1]||s===0||s>32)&&dh.throwArgumentError("invalid bytes type","type",t),Ze(e).byteLength!==s&&dh.throwArgumentError(`invalid value for ${t}`,"value",e),r?Ze((e+t9e).substring(0,66)):e}if(n=t.match(e9e),n&&Array.isArray(e)){const s=n[1];parseInt(n[2]||String(e.length))!=e.length&&dh.throwArgumentError(`invalid array length for ${t}`,"value",e);const o=[];return e.forEach(function(f){o.push(JV(s,f,!0))}),Fa(o)}return dh.throwArgumentError("invalid type","type",t)}function r9e(t,e){t.length!=e.length&&dh.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);const r=[];return t.forEach(function(n,s){r.push(JV(n,e[s]))}),pt(Fa(r))}function ZV(t,e){return kn(r9e(t,e))}const n9e=["function isModuleEnabled(address module) public view returns (bool)","function nonce() public view returns (uint256)","function enableModule(address module) public","function setGuard(address module) public","function execTransaction(address to,uint256 value,bytes calldata data,uint8 operation,uint256 safeTxGas,uint256 baseGas,uint256 gasPrice,address gasToken,address payable refundReceiver,bytes memory signatures) public payable returns (bool success)"],QV=async t=>{const e=await I1();return new ss(t,n9e,e)},i9e=async(t,e)=>await(await QV(t)).isModuleEnabled(e),s9e=async(t,e)=>{const r=await QV(t);return{to:t,value:"0",data:(await r.enableModule.populateTransaction(e)).data}},o9e="hh-sol-artifact-1",a9e="Safe2LinkModule",f9e="contracts/Safe2LinkModule.sol",c9e=[{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"_index",type:"uint256"},{indexed:!1,internalType:"uint256",name:"_amount",type:"uint256"},{indexed:!0,internalType:"address",name:"_senderAddress",type:"address"}],name:"LinkEvent",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"string",name:"message",type:"string"}],name:"MessageEvent",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"_index",type:"uint256"},{indexed:!1,internalType:"uint256",name:"_amount",type:"uint256"},{indexed:!0,internalType:"address",name:"_recipientAddress",type:"address"}],name:"WithdrawEvent",type:"event"},{inputs:[],name:"NAME",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"VERSION",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_index",type:"uint256"},{internalType:"address",name:"_recipientAddress",type:"address"},{internalType:"bytes32",name:"_recipientAddressHash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],name:"claimLink",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_pubKey20",type:"address"}],name:"createLink",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getAllLinks",outputs:[{components:[{internalType:"address",name:"pubKey20",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"bool",name:"claimed",type:"bool"},{internalType:"uint40",name:"timestamp",type:"uint40"},{internalType:"address",name:"account",type:"address"}],internalType:"struct Safe2LinkModule.Link[]",name:"",type:"tuple[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_index",type:"uint256"}],name:"getLink",outputs:[{components:[{internalType:"address",name:"pubKey20",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"bool",name:"claimed",type:"bool"},{internalType:"uint40",name:"timestamp",type:"uint40"},{internalType:"address",name:"account",type:"address"}],internalType:"struct Safe2LinkModule.Link",name:"",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getLinkCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"messageHash",type:"bytes32"},{internalType:"bytes",name:"signature",type:"bytes"}],name:"getSigner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"links",outputs:[{internalType:"address",name:"pubKey20",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"bool",name:"claimed",type:"bool"},{internalType:"uint40",name:"timestamp",type:"uint40"},{internalType:"address",name:"account",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"address",name:"",type:"address"},{internalType:"uint256",name:"",type:"uint256"}],name:"tokens",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],u9e="0x608060405234801561001057600080fd5b506122fd806100206000396000f3fe608060405234801561001057600080fd5b506004361061009e5760003560e01c8063a3f4df7e11610066578063a3f4df7e14610186578063ef51b79d146101a4578063f56e81fa146101c2578063f7b2ec0d146101f2578063ffa1ad74146102225761009e565b806326091678146100a3578063393b6df3146100d357806348d9cb941461010357806355c3d97a14610121578063881d8a4014610151575b600080fd5b6100bd60048036038101906100b8919061152f565b610240565b6040516100ca91906115cd565b60405180910390f35b6100ed60048036038101906100e891906115e8565b6105fb565b6040516100fa91906116dd565b60405180910390f35b61010b610787565b6040516101189190611822565b60405180910390f35b61013b60048036038101906101369190611844565b610936565b60405161014891906118a6565b60405180910390f35b61016b600480360381019061016691906115e8565b610b7f565b60405161017d969594939291906118df565b60405180910390f35b61018e610c49565b60405161019b91906119bf565b60405180910390f35b6101ac610c82565b6040516101b991906118a6565b60405180910390f35b6101dc60048036038101906101d791906119e1565b610c8f565b6040516101e99190611a34565b60405180910390f35b61020c60048036038101906102079190611a4f565b610cea565b6040516102199190611a34565b60405180910390f35b61022a610d03565b60405161023791906119bf565b60405180910390f35b60006001805490508510610289576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028090611af7565b60405180910390fd5b60006001868154811061029f5761029e611b17565b5b90600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815250509050600015158160600151151514610455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044c90611b92565b60405180910390fd5b610484856040516020016104699190611bfa565b60405160208183030381529060405280519060200120610d3c565b84146104c5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104bc90611c61565b60405180910390fd5b60006104d18585610cea565b9050816000015173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610545576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161053c90611ccd565b60405180910390fd5b8573ffffffffffffffffffffffffffffffffffffffff16877fa62bf33e3860a18b08244c1b59b8aa4920be374252eb534e0ab47d5f7a18ca18846020015160405161059091906118a6565b60405180910390a360018088815481106105ad576105ac611b17565b5b906000526020600020906004020160020160146101000a81548160ff0219169083151502179055506105ed8260a001518360400151888560200151610d72565b600192505050949350505050565b61060361128a565b6001828154811061061757610616611b17565b5b90600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815250509050919050565b60606001805480602002602001604051908101604052809291908181526020016000905b8282101561092d57838290600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681525050815260200190600101906107ab565b50505050905090565b600060016040518060c001604052808473ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018673ffffffffffffffffffffffffffffffffffffffff1681526020016000151581526020014264ffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff16815250908060018154018082558091505060019003906000526020600020906004020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151816001015560408201518160020160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160020160146101000a81548160ff02191690831515021790555060808201518160020160156101000a81548164ffffffffff021916908364ffffffffff16021790555060a08201518160030160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050503373ffffffffffffffffffffffffffffffffffffffff1660018080549050610b2e9190611d1c565b7fd0b52dbf7f8c29477b6ae9116c857532274475062b33c1f29e0c92f745c1ffbf85604051610b5d91906118a6565b60405180910390a360018080549050610b769190611d1c565b90509392505050565b60018181548110610b8f57600080fd5b90600052602060002090600402016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154908060020160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060020160149054906101000a900460ff16908060020160159054906101000a900464ffffffffff16908060030160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905086565b6040518060400160405280601081526020017f53616665324c696e6b204d6f64756c650000000000000000000000000000000081525081565b6000600180549050905090565b60006020528260005260406000206020528160005260406000208181548110610cb757600080fd5b90600052602060002001600092509250509054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080610cf78484610fca565b90508091505092915050565b6040518060400160405280600581526020017f302e312e3000000000000000000000000000000000000000000000000000000081525081565b60007f19457468657265756d205369676e6564204d6573736167653a0a33320000000060005281601c52603c6000209050919050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610e6b578373ffffffffffffffffffffffffffffffffffffffff1663468721a7838360006040518463ffffffff1660e01b8152600401610de493929190611e5d565b6020604051808303816000875af1158015610e03573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e279190611ed3565b610e66576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e5d90611f4c565b60405180910390fd5b610fc4565b60008282604051602401610e80929190611f8d565b6040516020818303038152906040527fa9059cbb000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505090508473ffffffffffffffffffffffffffffffffffffffff1663468721a78560008460006040518563ffffffff1660e01b8152600401610f409493929190612035565b6020604051808303816000875af1158015610f5f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f839190611ed3565b610fc2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fb9906120cd565b60405180910390fd5b505b50505050565b6000806000610fd98585610ff1565b91509150610fe681611042565b819250505092915050565b60008060418351036110325760008060006020860151925060408601519150606086015160001a9050611026878285856111a8565b9450945050505061103b565b60006002915091505b9250929050565b6000600481111561105657611055611de6565b5b81600481111561106957611068611de6565b5b03156111a5576001600481111561108357611082611de6565b5b81600481111561109657611095611de6565b5b036110d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110cd90612139565b60405180910390fd5b600260048111156110ea576110e9611de6565b5b8160048111156110fd576110fc611de6565b5b0361113d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611134906121a5565b60405180910390fd5b6003600481111561115157611150611de6565b5b81600481111561116457611163611de6565b5b036111a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161119b90612237565b60405180910390fd5b5b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08360001c11156111e3576000600391509150611281565b6000600187878787604051600081526020016040526040516112089493929190612282565b6020604051602081039080840390855afa15801561122a573d6000803e3d6000fd5b505050602060405103519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361127857600060019250925050611281565b80600092509250505b94509492505050565b6040518060c00160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600015158152602001600064ffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681525090565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6113328161131f565b811461133d57600080fd5b50565b60008135905061134f81611329565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061138082611355565b9050919050565b61139081611375565b811461139b57600080fd5b50565b6000813590506113ad81611387565b92915050565b6000819050919050565b6113c6816113b3565b81146113d157600080fd5b50565b6000813590506113e3816113bd565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61143c826113f3565b810181811067ffffffffffffffff8211171561145b5761145a611404565b5b80604052505050565b600061146e61130b565b905061147a8282611433565b919050565b600067ffffffffffffffff82111561149a57611499611404565b5b6114a3826113f3565b9050602081019050919050565b82818337600083830152505050565b60006114d26114cd8461147f565b611464565b9050828152602081018484840111156114ee576114ed6113ee565b5b6114f98482856114b0565b509392505050565b600082601f830112611516576115156113e9565b5b81356115268482602086016114bf565b91505092915050565b6000806000806080858703121561154957611548611315565b5b600061155787828801611340565b94505060206115688782880161139e565b9350506040611579878288016113d4565b925050606085013567ffffffffffffffff81111561159a5761159961131a565b5b6115a687828801611501565b91505092959194509250565b60008115159050919050565b6115c7816115b2565b82525050565b60006020820190506115e260008301846115be565b92915050565b6000602082840312156115fe576115fd611315565b5b600061160c84828501611340565b91505092915050565b61161e81611375565b82525050565b61162d8161131f565b82525050565b61163c816115b2565b82525050565b600064ffffffffff82169050919050565b61165c81611642565b82525050565b60c0820160008201516116786000850182611615565b50602082015161168b6020850182611624565b50604082015161169e6040850182611615565b5060608201516116b16060850182611633565b5060808201516116c46080850182611653565b5060a08201516116d760a0850182611615565b50505050565b600060c0820190506116f26000830184611662565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60c08201600082015161173a6000850182611615565b50602082015161174d6020850182611624565b5060408201516117606040850182611615565b5060608201516117736060850182611633565b5060808201516117866080850182611653565b5060a082015161179960a0850182611615565b50505050565b60006117ab8383611724565b60c08301905092915050565b6000602082019050919050565b60006117cf826116f8565b6117d98185611703565b93506117e483611714565b8060005b838110156118155781516117fc888261179f565b9750611807836117b7565b9250506001810190506117e8565b5085935050505092915050565b6000602082019050818103600083015261183c81846117c4565b905092915050565b60008060006060848603121561185d5761185c611315565b5b600061186b8682870161139e565b935050602061187c86828701611340565b925050604061188d8682870161139e565b9150509250925092565b6118a08161131f565b82525050565b60006020820190506118bb6000830184611897565b92915050565b6118ca81611375565b82525050565b6118d981611642565b82525050565b600060c0820190506118f460008301896118c1565b6119016020830188611897565b61190e60408301876118c1565b61191b60608301866115be565b61192860808301856118d0565b61193560a08301846118c1565b979650505050505050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561197a57808201518184015260208101905061195f565b60008484015250505050565b600061199182611940565b61199b818561194b565b93506119ab81856020860161195c565b6119b4816113f3565b840191505092915050565b600060208201905081810360008301526119d98184611986565b905092915050565b6000806000606084860312156119fa576119f9611315565b5b6000611a088682870161139e565b9350506020611a198682870161139e565b9250506040611a2a86828701611340565b9150509250925092565b6000602082019050611a4960008301846118c1565b92915050565b60008060408385031215611a6657611a65611315565b5b6000611a74858286016113d4565b925050602083013567ffffffffffffffff811115611a9557611a9461131a565b5b611aa185828601611501565b9150509250929050565b7f4c494e4b20494e44455820444f4553204e4f5420455849535400000000000000600082015250565b6000611ae160198361194b565b9150611aec82611aab565b602082019050919050565b60006020820190508181036000830152611b1081611ad4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4c494e4b20414c52454144592057495448445241574e00000000000000000000600082015250565b6000611b7c60168361194b565b9150611b8782611b46565b602082019050919050565b60006020820190508181036000830152611bab81611b6f565b9050919050565b60008160601b9050919050565b6000611bca82611bb2565b9050919050565b6000611bdc82611bbf565b9050919050565b611bf4611bef82611375565b611bd1565b82525050565b6000611c068284611be3565b60148201915081905092915050565b7f48415348455320444f204e4f54204d4154434800000000000000000000000000600082015250565b6000611c4b60138361194b565b9150611c5682611c15565b602082019050919050565b60006020820190508181036000830152611c7a81611c3e565b9050919050565b7f57524f4e47205349474e41545552450000000000000000000000000000000000600082015250565b6000611cb7600f8361194b565b9150611cc282611c81565b602082019050919050565b60006020820190508181036000830152611ce681611caa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000611d278261131f565b9150611d328361131f565b9250828203905081811115611d4a57611d49611ced565b5b92915050565b6000819050919050565b6000611d75611d70611d6b84611355565b611d50565b611355565b9050919050565b6000611d8782611d5a565b9050919050565b6000611d9982611d7c565b9050919050565b611da981611d8e565b82525050565b600082825260208201905092915050565b50565b6000611dd0600083611daf565b9150611ddb82611dc0565b600082019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60028110611e2657611e25611de6565b5b50565b6000819050611e3782611e15565b919050565b6000611e4782611e29565b9050919050565b611e5781611e3c565b82525050565b6000608082019050611e726000830186611da0565b611e7f6020830185611897565b8181036040830152611e9081611dc3565b9050611e9f6060830184611e4e565b949350505050565b611eb0816115b2565b8114611ebb57600080fd5b50565b600081519050611ecd81611ea7565b92915050565b600060208284031215611ee957611ee8611315565b5b6000611ef784828501611ebe565b91505092915050565b7f436f756c64206e6f742065786563757465206574686572207472616e73666572600082015250565b6000611f3660208361194b565b9150611f4182611f00565b602082019050919050565b60006020820190508181036000830152611f6581611f29565b9050919050565b6000611f7782611355565b9050919050565b611f8781611f6c565b82525050565b6000604082019050611fa26000830185611f7e565b611faf6020830184611897565b9392505050565b6000819050919050565b6000611fdb611fd6611fd184611fb6565b611d50565b61131f565b9050919050565b611feb81611fc0565b82525050565b600081519050919050565b600061200782611ff1565b6120118185611daf565b935061202181856020860161195c565b61202a816113f3565b840191505092915050565b600060808201905061204a60008301876118c1565b6120576020830186611fe2565b81810360408301526120698185611ffc565b90506120786060830184611e4e565b95945050505050565b7f436f756c64206e6f74206578656375746520746f6b656e207472616e73666572600082015250565b60006120b760208361194b565b91506120c282612081565b602082019050919050565b600060208201905081810360008301526120e6816120aa565b9050919050565b7f45434453413a20696e76616c6964207369676e61747572650000000000000000600082015250565b600061212360188361194b565b915061212e826120ed565b602082019050919050565b6000602082019050818103600083015261215281612116565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265206c656e67746800600082015250565b600061218f601f8361194b565b915061219a82612159565b602082019050919050565b600060208201905081810360008301526121be81612182565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202773272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b600061222160228361194b565b915061222c826121c5565b604082019050919050565b6000602082019050818103600083015261225081612214565b9050919050565b612260816113b3565b82525050565b600060ff82169050919050565b61227c81612266565b82525050565b60006080820190506122976000830187612257565b6122a46020830186612273565b6122b16040830185612257565b6122be6060830184612257565b9594505050505056fea2646970667358221220d4cfcae48dcd9cb39e8e8efbdf1eeec788e79274901739cdd0ee4771a47cfb8064736f6c63430008130033",l9e="0x608060405234801561001057600080fd5b506004361061009e5760003560e01c8063a3f4df7e11610066578063a3f4df7e14610186578063ef51b79d146101a4578063f56e81fa146101c2578063f7b2ec0d146101f2578063ffa1ad74146102225761009e565b806326091678146100a3578063393b6df3146100d357806348d9cb941461010357806355c3d97a14610121578063881d8a4014610151575b600080fd5b6100bd60048036038101906100b8919061152f565b610240565b6040516100ca91906115cd565b60405180910390f35b6100ed60048036038101906100e891906115e8565b6105fb565b6040516100fa91906116dd565b60405180910390f35b61010b610787565b6040516101189190611822565b60405180910390f35b61013b60048036038101906101369190611844565b610936565b60405161014891906118a6565b60405180910390f35b61016b600480360381019061016691906115e8565b610b7f565b60405161017d969594939291906118df565b60405180910390f35b61018e610c49565b60405161019b91906119bf565b60405180910390f35b6101ac610c82565b6040516101b991906118a6565b60405180910390f35b6101dc60048036038101906101d791906119e1565b610c8f565b6040516101e99190611a34565b60405180910390f35b61020c60048036038101906102079190611a4f565b610cea565b6040516102199190611a34565b60405180910390f35b61022a610d03565b60405161023791906119bf565b60405180910390f35b60006001805490508510610289576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028090611af7565b60405180910390fd5b60006001868154811061029f5761029e611b17565b5b90600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815250509050600015158160600151151514610455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044c90611b92565b60405180910390fd5b610484856040516020016104699190611bfa565b60405160208183030381529060405280519060200120610d3c565b84146104c5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104bc90611c61565b60405180910390fd5b60006104d18585610cea565b9050816000015173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610545576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161053c90611ccd565b60405180910390fd5b8573ffffffffffffffffffffffffffffffffffffffff16877fa62bf33e3860a18b08244c1b59b8aa4920be374252eb534e0ab47d5f7a18ca18846020015160405161059091906118a6565b60405180910390a360018088815481106105ad576105ac611b17565b5b906000526020600020906004020160020160146101000a81548160ff0219169083151502179055506105ed8260a001518360400151888560200151610d72565b600192505050949350505050565b61060361128a565b6001828154811061061757610616611b17565b5b90600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815250509050919050565b60606001805480602002602001604051908101604052809291908181526020016000905b8282101561092d57838290600052602060002090600402016040518060c00160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015481526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016002820160149054906101000a900460ff161515151581526020016002820160159054906101000a900464ffffffffff1664ffffffffff1664ffffffffff1681526020016003820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681525050815260200190600101906107ab565b50505050905090565b600060016040518060c001604052808473ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018673ffffffffffffffffffffffffffffffffffffffff1681526020016000151581526020014264ffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff16815250908060018154018082558091505060019003906000526020600020906004020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151816001015560408201518160020160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160020160146101000a81548160ff02191690831515021790555060808201518160020160156101000a81548164ffffffffff021916908364ffffffffff16021790555060a08201518160030160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050503373ffffffffffffffffffffffffffffffffffffffff1660018080549050610b2e9190611d1c565b7fd0b52dbf7f8c29477b6ae9116c857532274475062b33c1f29e0c92f745c1ffbf85604051610b5d91906118a6565b60405180910390a360018080549050610b769190611d1c565b90509392505050565b60018181548110610b8f57600080fd5b90600052602060002090600402016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154908060020160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060020160149054906101000a900460ff16908060020160159054906101000a900464ffffffffff16908060030160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905086565b6040518060400160405280601081526020017f53616665324c696e6b204d6f64756c650000000000000000000000000000000081525081565b6000600180549050905090565b60006020528260005260406000206020528160005260406000208181548110610cb757600080fd5b90600052602060002001600092509250509054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080610cf78484610fca565b90508091505092915050565b6040518060400160405280600581526020017f302e312e3000000000000000000000000000000000000000000000000000000081525081565b60007f19457468657265756d205369676e6564204d6573736167653a0a33320000000060005281601c52603c6000209050919050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610e6b578373ffffffffffffffffffffffffffffffffffffffff1663468721a7838360006040518463ffffffff1660e01b8152600401610de493929190611e5d565b6020604051808303816000875af1158015610e03573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e279190611ed3565b610e66576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e5d90611f4c565b60405180910390fd5b610fc4565b60008282604051602401610e80929190611f8d565b6040516020818303038152906040527fa9059cbb000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505090508473ffffffffffffffffffffffffffffffffffffffff1663468721a78560008460006040518563ffffffff1660e01b8152600401610f409493929190612035565b6020604051808303816000875af1158015610f5f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f839190611ed3565b610fc2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fb9906120cd565b60405180910390fd5b505b50505050565b6000806000610fd98585610ff1565b91509150610fe681611042565b819250505092915050565b60008060418351036110325760008060006020860151925060408601519150606086015160001a9050611026878285856111a8565b9450945050505061103b565b60006002915091505b9250929050565b6000600481111561105657611055611de6565b5b81600481111561106957611068611de6565b5b03156111a5576001600481111561108357611082611de6565b5b81600481111561109657611095611de6565b5b036110d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110cd90612139565b60405180910390fd5b600260048111156110ea576110e9611de6565b5b8160048111156110fd576110fc611de6565b5b0361113d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611134906121a5565b60405180910390fd5b6003600481111561115157611150611de6565b5b81600481111561116457611163611de6565b5b036111a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161119b90612237565b60405180910390fd5b5b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08360001c11156111e3576000600391509150611281565b6000600187878787604051600081526020016040526040516112089493929190612282565b6020604051602081039080840390855afa15801561122a573d6000803e3d6000fd5b505050602060405103519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361127857600060019250925050611281565b80600092509250505b94509492505050565b6040518060c00160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600015158152602001600064ffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681525090565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6113328161131f565b811461133d57600080fd5b50565b60008135905061134f81611329565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061138082611355565b9050919050565b61139081611375565b811461139b57600080fd5b50565b6000813590506113ad81611387565b92915050565b6000819050919050565b6113c6816113b3565b81146113d157600080fd5b50565b6000813590506113e3816113bd565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61143c826113f3565b810181811067ffffffffffffffff8211171561145b5761145a611404565b5b80604052505050565b600061146e61130b565b905061147a8282611433565b919050565b600067ffffffffffffffff82111561149a57611499611404565b5b6114a3826113f3565b9050602081019050919050565b82818337600083830152505050565b60006114d26114cd8461147f565b611464565b9050828152602081018484840111156114ee576114ed6113ee565b5b6114f98482856114b0565b509392505050565b600082601f830112611516576115156113e9565b5b81356115268482602086016114bf565b91505092915050565b6000806000806080858703121561154957611548611315565b5b600061155787828801611340565b94505060206115688782880161139e565b9350506040611579878288016113d4565b925050606085013567ffffffffffffffff81111561159a5761159961131a565b5b6115a687828801611501565b91505092959194509250565b60008115159050919050565b6115c7816115b2565b82525050565b60006020820190506115e260008301846115be565b92915050565b6000602082840312156115fe576115fd611315565b5b600061160c84828501611340565b91505092915050565b61161e81611375565b82525050565b61162d8161131f565b82525050565b61163c816115b2565b82525050565b600064ffffffffff82169050919050565b61165c81611642565b82525050565b60c0820160008201516116786000850182611615565b50602082015161168b6020850182611624565b50604082015161169e6040850182611615565b5060608201516116b16060850182611633565b5060808201516116c46080850182611653565b5060a08201516116d760a0850182611615565b50505050565b600060c0820190506116f26000830184611662565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60c08201600082015161173a6000850182611615565b50602082015161174d6020850182611624565b5060408201516117606040850182611615565b5060608201516117736060850182611633565b5060808201516117866080850182611653565b5060a082015161179960a0850182611615565b50505050565b60006117ab8383611724565b60c08301905092915050565b6000602082019050919050565b60006117cf826116f8565b6117d98185611703565b93506117e483611714565b8060005b838110156118155781516117fc888261179f565b9750611807836117b7565b9250506001810190506117e8565b5085935050505092915050565b6000602082019050818103600083015261183c81846117c4565b905092915050565b60008060006060848603121561185d5761185c611315565b5b600061186b8682870161139e565b935050602061187c86828701611340565b925050604061188d8682870161139e565b9150509250925092565b6118a08161131f565b82525050565b60006020820190506118bb6000830184611897565b92915050565b6118ca81611375565b82525050565b6118d981611642565b82525050565b600060c0820190506118f460008301896118c1565b6119016020830188611897565b61190e60408301876118c1565b61191b60608301866115be565b61192860808301856118d0565b61193560a08301846118c1565b979650505050505050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561197a57808201518184015260208101905061195f565b60008484015250505050565b600061199182611940565b61199b818561194b565b93506119ab81856020860161195c565b6119b4816113f3565b840191505092915050565b600060208201905081810360008301526119d98184611986565b905092915050565b6000806000606084860312156119fa576119f9611315565b5b6000611a088682870161139e565b9350506020611a198682870161139e565b9250506040611a2a86828701611340565b9150509250925092565b6000602082019050611a4960008301846118c1565b92915050565b60008060408385031215611a6657611a65611315565b5b6000611a74858286016113d4565b925050602083013567ffffffffffffffff811115611a9557611a9461131a565b5b611aa185828601611501565b9150509250929050565b7f4c494e4b20494e44455820444f4553204e4f5420455849535400000000000000600082015250565b6000611ae160198361194b565b9150611aec82611aab565b602082019050919050565b60006020820190508181036000830152611b1081611ad4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4c494e4b20414c52454144592057495448445241574e00000000000000000000600082015250565b6000611b7c60168361194b565b9150611b8782611b46565b602082019050919050565b60006020820190508181036000830152611bab81611b6f565b9050919050565b60008160601b9050919050565b6000611bca82611bb2565b9050919050565b6000611bdc82611bbf565b9050919050565b611bf4611bef82611375565b611bd1565b82525050565b6000611c068284611be3565b60148201915081905092915050565b7f48415348455320444f204e4f54204d4154434800000000000000000000000000600082015250565b6000611c4b60138361194b565b9150611c5682611c15565b602082019050919050565b60006020820190508181036000830152611c7a81611c3e565b9050919050565b7f57524f4e47205349474e41545552450000000000000000000000000000000000600082015250565b6000611cb7600f8361194b565b9150611cc282611c81565b602082019050919050565b60006020820190508181036000830152611ce681611caa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000611d278261131f565b9150611d328361131f565b9250828203905081811115611d4a57611d49611ced565b5b92915050565b6000819050919050565b6000611d75611d70611d6b84611355565b611d50565b611355565b9050919050565b6000611d8782611d5a565b9050919050565b6000611d9982611d7c565b9050919050565b611da981611d8e565b82525050565b600082825260208201905092915050565b50565b6000611dd0600083611daf565b9150611ddb82611dc0565b600082019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60028110611e2657611e25611de6565b5b50565b6000819050611e3782611e15565b919050565b6000611e4782611e29565b9050919050565b611e5781611e3c565b82525050565b6000608082019050611e726000830186611da0565b611e7f6020830185611897565b8181036040830152611e9081611dc3565b9050611e9f6060830184611e4e565b949350505050565b611eb0816115b2565b8114611ebb57600080fd5b50565b600081519050611ecd81611ea7565b92915050565b600060208284031215611ee957611ee8611315565b5b6000611ef784828501611ebe565b91505092915050565b7f436f756c64206e6f742065786563757465206574686572207472616e73666572600082015250565b6000611f3660208361194b565b9150611f4182611f00565b602082019050919050565b60006020820190508181036000830152611f6581611f29565b9050919050565b6000611f7782611355565b9050919050565b611f8781611f6c565b82525050565b6000604082019050611fa26000830185611f7e565b611faf6020830184611897565b9392505050565b6000819050919050565b6000611fdb611fd6611fd184611fb6565b611d50565b61131f565b9050919050565b611feb81611fc0565b82525050565b600081519050919050565b600061200782611ff1565b6120118185611daf565b935061202181856020860161195c565b61202a816113f3565b840191505092915050565b600060808201905061204a60008301876118c1565b6120576020830186611fe2565b81810360408301526120698185611ffc565b90506120786060830184611e4e565b95945050505050565b7f436f756c64206e6f74206578656375746520746f6b656e207472616e73666572600082015250565b60006120b760208361194b565b91506120c282612081565b602082019050919050565b600060208201905081810360008301526120e6816120aa565b9050919050565b7f45434453413a20696e76616c6964207369676e61747572650000000000000000600082015250565b600061212360188361194b565b915061212e826120ed565b602082019050919050565b6000602082019050818103600083015261215281612116565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265206c656e67746800600082015250565b600061218f601f8361194b565b915061219a82612159565b602082019050919050565b600060208201905081810360008301526121be81612182565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202773272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b600061222160228361194b565b915061222c826121c5565b604082019050919050565b6000602082019050818103600083015261225081612214565b9050919050565b612260816113b3565b82525050565b600060ff82169050919050565b61227c81612266565b82525050565b60006080820190506122976000830187612257565b6122a46020830186612273565b6122b16040830185612257565b6122be6060830184612257565b9594505050505056fea2646970667358221220d4cfcae48dcd9cb39e8e8efbdf1eeec788e79274901739cdd0ee4771a47cfb8064736f6c63430008130033",h9e={},d9e={},$w={_format:o9e,contractName:a9e,sourceName:f9e,abi:c9e,bytecode:u9e,deployedBytecode:l9e,linkReferences:h9e,deployedLinkReferences:d9e},YV={block:g_({format(t){var r;return{transactions:(r=t.transactions)==null?void 0:r.map(n=>{if(typeof n=="string")return n;const s=E1(n);return s.typeHex==="0x7e"&&(s.isSystemTx=n.isSystemTx,s.mint=n.mint?Wt(n.mint):void 0,s.sourceHash=n.sourceHash,s.type="deposit"),s}),stateRoot:t.stateRoot}}}),transaction:m_({format(t){const e={};return t.type==="0x7e"&&(e.isSystemTx=t.isSystemTx,e.mint=t.mint?Wt(t.mint):void 0,e.sourceHash=t.sourceHash,e.type="deposit"),e}}),transactionReceipt:N_({format(t){return{l1GasPrice:t.l1GasPrice?Wt(t.l1GasPrice):null,l1GasUsed:t.l1GasUsed?Wt(t.l1GasUsed):null,l1Fee:t.l1Fee?Wt(t.l1Fee):null,l1FeeScalar:t.l1FeeScalar?Number(t.l1FeeScalar):null}}})},p9e=Vc({id:8453,network:"base",name:"Base",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://base-mainnet.g.alchemy.com/v2"],webSocket:["wss://base-mainnet.g.alchemy.com/v2"]},infura:{http:["https://base-mainnet.infura.io/v3"],webSocket:["wss://base-mainnet.infura.io/ws/v3"]},default:{http:["https://mainnet.base.org"]},public:{http:["https://mainnet.base.org"]}},blockExplorers:{blockscout:{name:"Basescout",url:"https://base.blockscout.com"},default:{name:"Basescan",url:"https://basescan.org"},etherscan:{name:"Basescan",url:"https://basescan.org"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:5022}}},{formatters:YV}),m9e=Vc({id:84531,network:"base-goerli",name:"Base Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://base-goerli.g.alchemy.com/v2"],webSocket:["wss://base-goerli.g.alchemy.com/v2"]},default:{http:["https://goerli.base.org"]},public:{http:["https://goerli.base.org"]}},blockExplorers:{etherscan:{name:"Basescan",url:"https://goerli.basescan.org"},default:{name:"Basescan",url:"https://goerli.basescan.org"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:1376988}},testnet:!0,sourceId:5},{formatters:YV});function Y0(t){return t===0||t===0n||t===void 0||t===null||t==="0"||t===""||typeof t=="string"&&(rn(t).toLowerCase()==="0x"||rn(t).toLowerCase()==="0x00")}function Tn(t){return!Y0(t)}function XV(t){return Tn(t.maxFeePerGas)&&Tn(t.maxPriorityFeePerGas)}function eK(t){return t.type==="cip42"?!0:XV(t)&&(Tn(t.feeCurrency)||Tn(t.gatewayFeeRecipient)||Tn(t.gatewayFee))}function tK(t){return t.type==="cip64"?!0:XV(t)&&Tn(t.feeCurrency)&&Y0(t.gatewayFee)&&Y0(t.gatewayFeeRecipient)}const g9e={block:g_({exclude:["difficulty","gasLimit","mixHash","nonce","uncles"],format(t){var r;const e=(r=t.transactions)==null?void 0:r.map(n=>typeof n=="string"?n:{...E1(n),feeCurrency:n.feeCurrency,...n.type!=="0x7b"?{gatewayFee:n.gatewayFee?Wt(n.gatewayFee):null,gatewayFeeRecipient:n.gatewayFeeRecipient||null}:{}});return{randomness:t.randomness,transactions:e}}}),transaction:m_({format(t){const e={feeCurrency:t.feeCurrency};return t.type==="0x7b"?e.type="cip64":(t.type==="0x7c"&&(e.type="cip42"),e.gatewayFee=t.gatewayFee?Wt(t.gatewayFee):null,e.gatewayFeeRecipient=t.gatewayFeeRecipient),e}}),transactionReceipt:N_({format(t){return{feeCurrency:t.feeCurrency,gatewayFee:t.gatewayFee?Wt(t.gatewayFee):null,gatewayFeeRecipient:t.gatewayFeeRecipient}}}),transactionRequest:jq({format(t){const e={feeCurrency:t.feeCurrency};return tK(t)?e.type="0x7b":(eK(t)&&(e.type="0x7c"),e.gatewayFee=typeof t.gatewayFee<"u"?it(t.gatewayFee):void 0,e.gatewayFeeRecipient=t.gatewayFeeRecipient),e}})},y9e=(t,e)=>tK(t)?x9e(t,e):eK(t)?v9e(t,e):H_(t,e),b9e={transaction:y9e};function v9e(t,e){w9e(t);const{chainId:r,gas:n,nonce:s,to:i,value:o,maxFeePerGas:f,maxPriorityFeePerGas:h,accessList:p,feeCurrency:b,gatewayFeeRecipient:v,gatewayFee:E,data:_}=t,S=[ut(r),s?ut(s):"0x",h?ut(h):"0x",f?ut(f):"0x",n?ut(n):"0x",b??"0x",v??"0x",E?ut(E):"0x",i??"0x",o?ut(o):"0x",_??"0x",ab(p)];return e&&S.push(e.v===27n?"0x":ut(1),rn(e.r),rn(e.s)),fo(["0x7c",o0(S)])}function x9e(t,e){A9e(t);const{chainId:r,gas:n,nonce:s,to:i,value:o,maxFeePerGas:f,maxPriorityFeePerGas:h,accessList:p,feeCurrency:b,data:v}=t,E=[ut(r),s?ut(s):"0x",h?ut(h):"0x",f?ut(f):"0x",n?ut(n):"0x",i??"0x",o?ut(o):"0x",v??"0x",ab(p),b];return e&&E.push(e.v===27n?"0x":ut(1),rn(e.r),rn(e.s)),fo(["0x7b",o0(E)])}const rK=2n**256n-1n;function w9e(t){const{chainId:e,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:i,feeCurrency:o,gatewayFee:f,gatewayFeeRecipient:h}=t;if(e<=0)throw new S1({chainId:e});if(i&&!wr(i))throw new un({address:i});if(n)throw new Ue("`gasPrice` is not a valid CIP-42 Transaction attribute.");if(Tn(s)&&s>rK)throw new $a({maxFeePerGas:s});if(Tn(r)&&Tn(s)&&r>s)throw new Sc({maxFeePerGas:s,maxPriorityFeePerGas:r});if(Tn(f)&&Y0(h)||Tn(h)&&Y0(f))throw new Ue("`gatewayFee` and `gatewayFeeRecipient` must be provided together.");if(Tn(o)&&!wr(o))throw new Ue("`feeCurrency` MUST be a token address for CIP-42 transactions.");if(Tn(h)&&!wr(h))throw new un(h);if(Y0(o)&&Y0(h))throw new Ue("Either `feeCurrency` or `gatewayFeeRecipient` must be provided for CIP-42 transactions.")}function A9e(t){const{chainId:e,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:i,feeCurrency:o}=t;if(e<=0)throw new S1({chainId:e});if(i&&!wr(i))throw new un({address:i});if(n)throw new Ue("`gasPrice` is not a valid CIP-64 Transaction attribute.");if(Tn(s)&&s>rK)throw new $a({maxFeePerGas:s});if(Tn(r)&&Tn(s)&&r>s)throw new Sc({maxFeePerGas:s,maxPriorityFeePerGas:r});if(Tn(o)&&!wr(o))throw new Ue("`feeCurrency` MUST be a token address for CIP-64 transactions.");if(Y0(o))throw new Ue("`feeCurrency` must be provided for CIP-64 transactions.")}const E9e=Vc({id:42220,name:"Celo",network:"celo",nativeCurrency:{decimals:18,name:"CELO",symbol:"CELO"},rpcUrls:{default:{http:["https://forno.celo.org"]},infura:{http:["https://celo-mainnet.infura.io/v3"]},public:{http:["https://forno.celo.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/mainnet"},etherscan:{name:"CeloScan",url:"https://celoscan.io"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:13112599}},testnet:!1},{formatters:g9e,serializers:b9e}),M9e=Vc({id:5,network:"goerli",name:"Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-goerli.g.alchemy.com/v2"],webSocket:["wss://eth-goerli.g.alchemy.com/v2"]},infura:{http:["https://goerli.infura.io/v3"],webSocket:["wss://goerli.infura.io/ws/v3"]},default:{http:["https://rpc.ankr.com/eth_goerli"]},public:{http:["https://rpc.ankr.com/eth_goerli"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli.etherscan.io"},default:{name:"Etherscan",url:"https://goerli.etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0x56522D00C410a43BFfDF00a9A569489297385790",blockCreated:8765204},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:6507670}},testnet:!0}),S9e=Vc({id:100,name:"Gnosis",network:"gnosis",nativeCurrency:{decimals:18,name:"Gnosis",symbol:"xDAI"},rpcUrls:{default:{http:["https://rpc.gnosischain.com"],webSocket:["wss://rpc.gnosischain.com/wss"]},public:{http:["https://rpc.gnosischain.com"],webSocket:["wss://rpc.gnosischain.com/wss"]}},blockExplorers:{etherscan:{name:"Gnosisscan",url:"https://gnosisscan.io"},default:{name:"Gnosis Chain Explorer",url:"https://blockscout.com/xdai/mainnet"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:21022491}}}),_9e=Vc({id:137,name:"Polygon",network:"matic",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mainnet.g.alchemy.com/v2"],webSocket:["wss://polygon-mainnet.g.alchemy.com/v2"]},infura:{http:["https://polygon-mainnet.infura.io/v3"],webSocket:["wss://polygon-mainnet.infura.io/ws/v3"]},default:{http:["https://polygon-rpc.com"]},public:{http:["https://polygon-rpc.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://polygonscan.com"},default:{name:"PolygonScan",url:"https://polygonscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:25770160}}}),P9e=Vc({id:11155111,network:"sepolia",name:"Sepolia",nativeCurrency:{name:"Sepolia Ether",symbol:"SEP",decimals:18},rpcUrls:{alchemy:{http:["https://eth-sepolia.g.alchemy.com/v2"],webSocket:["wss://eth-sepolia.g.alchemy.com/v2"]},infura:{http:["https://sepolia.infura.io/v3"],webSocket:["wss://sepolia.infura.io/ws/v3"]},default:{http:["https://rpc.sepolia.org"]},public:{http:["https://rpc.sepolia.org"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://sepolia.etherscan.io"},default:{name:"Etherscan",url:"https://sepolia.etherscan.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:751532},ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0x21B000Fd62a880b2125A61e36a284BB757b76025",blockCreated:3914906}},testnet:!0});function Zs(t,e,r=e.name){return n=>{var s;return((s=t[r])==null?void 0:s.call(t,n))??e(t,n)}}const C9e=async t=>Number(await t.request({method:"eth_chainId",params:[]})),I9e={"0x0":"reverted","0x1":"success"};function xl(t){if(typeof t!="function")return t==null||typeof t=="string"||typeof t=="boolean"?t:typeof t=="bigint"?ut(t):t._isBigNumber!=null||typeof t!="object"?ut(t).replace(/^0x0/,"0x"):Array.isArray(t)?t.map(e=>xl(e)):Object.keys(t).reduce((e,r)=>(e[r]=xl(t[r]),e),{})}const nK=async(t,e)=>{const{userOperation:r,entryPoint:n}=e,s=await t.request({method:"eth_estimateUserOperationGas",params:[xl(r),n]});return{preVerificationGas:BigInt(s.preVerificationGas||0),verificationGasLimit:BigInt(s.verificationGasLimit||0),callGasLimit:BigInt(s.callGasLimit||0)}},T9e=async(t,{hash:e})=>{const r=[e],n=await t.request({method:"eth_getUserOperationByHash",params:r});if(!n)return null;const{userOperation:s,entryPoint:i,transactionHash:o,blockHash:f,blockNumber:h}=n;return{userOperation:{...s,nonce:BigInt(s.nonce),callGasLimit:BigInt(s.callGasLimit),verificationGasLimit:BigInt(s.verificationGasLimit),preVerificationGas:BigInt(s.preVerificationGas),maxFeePerGas:BigInt(s.maxFeePerGas),maxPriorityFeePerGas:BigInt(s.maxPriorityFeePerGas)},entryPoint:i,transactionHash:o,blockHash:f,blockNumber:BigInt(h)}},iK=async(t,{hash:e})=>{const r=[e],n=await t.request({method:"eth_getUserOperationReceipt",params:r});return n?{userOpHash:n.userOpHash,sender:n.sender,nonce:BigInt(n.nonce),actualGasUsed:BigInt(n.actualGasUsed),actualGasCost:BigInt(n.actualGasCost),success:n.success,receipt:{transactionHash:n.receipt.transactionHash,transactionIndex:BigInt(n.receipt.transactionIndex),blockHash:n.receipt.blockHash,blockNumber:BigInt(n.receipt.blockNumber),from:n.receipt.from,to:n.receipt.to,cumulativeGasUsed:BigInt(n.receipt.cumulativeGasUsed),status:I9e[n.receipt.status],gasUsed:BigInt(n.receipt.gasUsed),contractAddress:n.receipt.contractAddress,logsBloom:n.receipt.logsBloom,effectiveGasPrice:BigInt(n.receipt.effectiveGasPrice)},logs:n.logs.map(i=>({data:i.data,blockNumber:BigInt(i.blockNumber),blockHash:i.blockHash,transactionHash:i.transactionHash,logIndex:BigInt(i.logIndex),transactionIndex:BigInt(i.transactionIndex),address:i.address,topics:i.topics}))}:null},sK=async(t,e)=>{const{userOperation:r,entryPoint:n}=e;return t.request({method:"eth_sendUserOperation",params:[xl(r),n]})},k9e=async t=>t.request({method:"eth_supportedEntryPoints",params:[]}),p4=new Map,EB=new Map;let R9e=0;function B9e(t,e,r){const n=++R9e,s=()=>p4.get(t)||[],i=()=>{const b=s();p4.set(t,b.filter(v=>v.id!==n))},o=()=>{const b=EB.get(t);s().length===1&&b&&b(),i()},f=s();if(p4.set(t,[...f,{id:n,fns:e}]),f&&f.length>0)return o;const h={};for(const b in e)h[b]=(...v)=>{var _,S;const E=s();if(E.length!==0)for(const P of E)(S=(_=P.fns)[b])==null||S.call(_,...v)};const p=r(h);return typeof p=="function"&&EB.set(t,p),o}class O9e extends Ue{constructor({hash:e}){super(`Timed out while waiting for transaction with hash "${e}" to be confirmed.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WaitForUserOperationReceiptTimeoutError"})}}const Fw=(t,{hash:e,pollingInterval:r=t.pollingInterval,timeout:n})=>{const s=cn(["waitForUserOperationReceipt",t.uid,e]);let i;return new Promise((o,f)=>{n&&setTimeout(()=>f(new O9e({hash:e})),n);const h=B9e(s,{resolve:o,reject:f},async p=>{const b=setInterval(async()=>{const v=_=>{clearInterval(b),_(),h()},E=await Zs(t,iK)({hash:e});if(E!==null&&(i=E),i){v(()=>p.resolve(i));return}},r)})})},N9e=async(t,{sender:e,entryPoint:r,key:n=BigInt(0)})=>await Zs(t,Yo)({address:r,abi:[{inputs:[{name:"sender",type:"address"},{name:"key",type:"uint192"}],name:"getNonce",outputs:[{name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],functionName:"getNonce",args:[e,n]}),L9e=t=>({sendUserOperation:async e=>sK(t,e),estimateUserOperationGas:e=>nK(t,e),supportedEntryPoints:()=>k9e(t),chainId:()=>C9e(t),getUserOperationByHash:e=>T9e(t,e),getUserOperationReceipt:e=>iK(t,e),waitForUserOperationReceipt:e=>Fw(t,e)});class MB extends Ue{constructor({docsPath:e}={}){super(["A smart account cannot sign or send transaction, it can only sign message or userOperation.","Please send user operation instead."].join(` -`),{docsPath:e,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SignTransactionNotSupportedBySmartAccount"})}}class ql extends Ue{constructor({docsPath:e}={}){super(["Could not find an Account to execute with this Action.","Please provide an Account with the `account` argument on the Action, or by supplying an `account` to the WalletClient."].join(` -`),{docsPath:e,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountOrClientNotFoundError"})}}function Gl(t){return typeof t=="string"?{address:t,type:"json-rpc"}:t}async function oK(t,e){const{account:r=t.account,userOperation:n,sponsorUserOperation:s}=e;if(!r)throw new ql;const i=Gl(r),[o,f,h,p,b,v]=await Promise.all([n.sender||i.address,n.nonce||i.getNonce(),n.initCode||i.getInitCode(),n.signature||i.getDummySignature(),n.callData,!n.maxFeePerGas||!n.maxPriorityFeePerGas?Vq(i.client):void 0]),E={sender:o,nonce:f,initCode:h,signature:p,callData:b,paymasterAndData:"0x",maxFeePerGas:n.maxFeePerGas||(v==null?void 0:v.maxFeePerGas)||0n,maxPriorityFeePerGas:n.maxPriorityFeePerGas||(v==null?void 0:v.maxPriorityFeePerGas)||0n,callGasLimit:n.callGasLimit||0n,verificationGasLimit:n.verificationGasLimit||0n,preVerificationGas:n.preVerificationGas||0n};if(s){const{callGasLimit:_,verificationGasLimit:S,preVerificationGas:P,paymasterAndData:I}=await s({userOperation:E,entryPoint:i.entryPoint});E.paymasterAndData=I,E.callGasLimit=E.callGasLimit||_,E.verificationGasLimit=E.verificationGasLimit||S,E.preVerificationGas=E.preVerificationGas||P}else if(!E.callGasLimit||!E.verificationGasLimit||!E.preVerificationGas){const _=await Zs(t,nK)({userOperation:{...E},entryPoint:i.entryPoint});E.callGasLimit=E.callGasLimit||_.callGasLimit,E.verificationGasLimit=E.verificationGasLimit||_.verificationGasLimit,E.preVerificationGas=E.preVerificationGas||_.preVerificationGas}return E}async function mP(t,e){const{account:r=t.account}=e;if(!r)throw new ql;const n=Gl(r),s=await Zs(t,oK)(e);return s.signature=await n.signUserOperation(s),await Zs(t,sK,"sendUserOperation")({userOperation:s,entryPoint:n.entryPoint})}async function D9e(t,{abi:e,args:r,bytecode:n,sponsorUserOperation:s,...i}){const{account:o=t.account}=i;if(!o)throw new ql({docsPath:"/docs/actions/wallet/sendTransaction"});const f=Gl(o),h=await Zs(t,mP)({userOperation:{sender:f.address,paymasterAndData:"0x",maxFeePerGas:i.maxFeePerGas||0n,maxPriorityFeePerGas:i.maxPriorityFeePerGas||0n,callData:await f.encodeDeployCallData({abi:e,args:r,bytecode:n})},account:f,sponsorUserOperation:s}),p=await Zs(t,Fw)({hash:h});return p==null?void 0:p.receipt.transactionHash}async function aK(t,e){const{account:r=t.account,data:n,maxFeePerGas:s,maxPriorityFeePerGas:i,to:o,value:f,nonce:h,sponsorUserOperation:p}=e;if(!r)throw new ql({docsPath:"/docs/actions/wallet/sendTransaction"});const b=Gl(r);if(!o)throw new Error("Missing to address");if(b.type!=="local")throw new Error("RPC account type not supported");const v=await b.encodeCallData({to:o,value:f||0n,data:n||"0x"}),E=await Zs(t,mP)({userOperation:{sender:b.address,paymasterAndData:"0x",maxFeePerGas:s||0n,maxPriorityFeePerGas:i||0n,callData:v,nonce:h?BigInt(h):void 0},account:b,sponsorUserOperation:p}),_=await Zs(t,Fw)({hash:E});return _==null?void 0:_.receipt.transactionHash}async function $9e(t,{account:e=t.account,message:r}){if(!e)throw new ql({docsPath:"/docs/actions/wallet/signMessage"});const n=Gl(e);if(n.type==="local")return n.signMessage({message:r});throw new Error("Sign message is not supported by this account")}async function F9e(t,{account:e=t.account,domain:r,message:n,primaryType:s,types:i}){if(!e)throw new ql({docsPath:"/docs/actions/wallet/signMessage"});const o=Gl(e),f={EIP712Domain:sb({domain:r}),...i};if(_w({domain:r,message:n,primaryType:s,types:f}),o.type==="local")return o.signTypedData({domain:r,primaryType:s,types:f,message:n});throw new Error("Sign type message is not supported by this account")}async function U9e(t,e){const{account:r=t.account,transactions:n,sponsorUserOperation:s,maxFeePerGas:i,maxPriorityFeePerGas:o,nonce:f}=e;if(!r)throw new ql({docsPath:"/docs/actions/wallet/sendTransaction"});const h=Gl(r);if(h.type!=="local")throw new Error("RPC account type not supported");const p=await h.encodeCallData(n.map(({to:E,value:_,data:S})=>{if(!E)throw new Error("Missing to address");return{to:E,value:_||0n,data:S||"0x"}})),b=await Zs(t,mP)({userOperation:{sender:h.address,paymasterAndData:"0x",maxFeePerGas:i||0n,maxPriorityFeePerGas:o||0n,callData:p,nonce:f},account:h,sponsorUserOperation:s}),v=await Zs(t,Fw)({hash:b});return v==null?void 0:v.receipt.transactionHash}async function z9e(t,{abi:e,address:r,args:n,dataSuffix:s,functionName:i,...o}){const f=mi({abi:e,args:n,functionName:i});return await Zs(t,aK)({data:`${f}${s?s.replace("0x",""):""}`,to:r,...o})}const j9e=({sponsorUserOperation:t})=>e=>({prepareUserOperationRequest:r=>oK(e,r),deployContract:r=>D9e(e,{...r,sponsorUserOperation:t}),sendTransaction:r=>aK(e,{...r,sponsorUserOperation:t}),sendTransactions:r=>U9e(e,{...r,sponsorUserOperation:t}),signMessage:r=>$9e(e,r),signTypedData:r=>F9e(e,r),writeContract:r=>z9e(e,{...r,sponsorUserOperation:t})}),H9e=t=>{const{key:e="Account",name:r="Smart Account Client",transport:n}=t;return jl({...t,key:e,name:r,transport:i=>n({...i,retryCount:0}),type:"smartAccountClient"}).extend(j9e({sponsorUserOperation:t.sponsorUserOperation}))},q9e=async t=>{const e=await t.request({method:"pimlico_getUserOperationGasPrice",params:[]});return{slow:{maxFeePerGas:BigInt(e.slow.maxFeePerGas),maxPriorityFeePerGas:BigInt(e.slow.maxPriorityFeePerGas)},standard:{maxFeePerGas:BigInt(e.standard.maxFeePerGas),maxPriorityFeePerGas:BigInt(e.standard.maxPriorityFeePerGas)},fast:{maxFeePerGas:BigInt(e.fast.maxFeePerGas),maxPriorityFeePerGas:BigInt(e.fast.maxPriorityFeePerGas)}}},G9e=async(t,{hash:e})=>t.request({method:"pimlico_getUserOperationStatus",params:[e]}),V9e=async(t,e)=>{const r=await t.request({method:"pm_sponsorUserOperation",params:e.sponsorshipPolicyId?[xl(e.userOperation),e.entryPoint,{sponsorshipPolicyId:e.sponsorshipPolicyId}]:[xl(e.userOperation),e.entryPoint]});return{paymasterAndData:r.paymasterAndData,preVerificationGas:BigInt(r.preVerificationGas),verificationGasLimit:BigInt(r.verificationGasLimit),callGasLimit:BigInt(r.callGasLimit)}},K9e=async(t,e)=>await t.request({method:"pm_validateSponsorshipPolicies",params:[xl(e.userOperation),e.entryPoint,e.sponsorshipPolicyIds]}),W9e=t=>({getUserOperationGasPrice:async()=>q9e(t),getUserOperationStatus:async e=>G9e(t,e)}),J9e=t=>({sponsorUserOperation:async e=>V9e(t,e),validateSponsorshipPolicies:async e=>K9e(t,e)}),Z9e=t=>{const{key:e="public",name:r="Pimlico Bundler Client"}=t;return jl({...t,key:e,name:r,type:"pimlicoBundlerClient"}).extend(L9e).extend(W9e)},Q9e=t=>{const{key:e="public",name:r="Pimlico Paymaster Client"}=t;return jl({...t,key:e,name:r,type:"pimlicoPaymasterClient"}).extend(J9e)};function fK(t){if(typeof t=="string"){if(!wr(t))throw new un({address:t});return{address:t,type:"json-rpc"}}if(!wr(t.address))throw new un({address:t.address});return{address:t.address,signMessage:t.signMessage,signTransaction:t.signTransaction,signTypedData:t.signTypedData,source:"custom",type:"local"}}const Y9e={SafeOp:[{type:"address",name:"safe"},{type:"uint256",name:"nonce"},{type:"bytes",name:"initCode"},{type:"bytes",name:"callData"},{type:"uint256",name:"callGasLimit"},{type:"uint256",name:"verificationGasLimit"},{type:"uint256",name:"preVerificationGas"},{type:"uint256",name:"maxFeePerGas"},{type:"uint256",name:"maxPriorityFeePerGas"},{type:"bytes",name:"paymasterAndData"},{type:"uint48",name:"validAfter"},{type:"uint48",name:"validUntil"},{type:"address",name:"entryPoint"}]},ah={"1.4.1":{ADD_MODULES_LIB_ADDRESS:"0x8EcD4ec46D4D2a6B64fE960B3D64e8B94B2234eb",SAFE_4337_MODULE_ADDRESS:"0xa581c4A4DB7175302464fF3C06380BC3270b4037",SAFE_PROXY_FACTORY_ADDRESS:"0x4e1DCf7AD4e460CfD30791CCC4F9c8a4f820ec67",SAFE_SINGLETON_ADDRESS:"0x41675C099F32341bf84BFc5382aF534df5C7461a",MULTI_SEND_ADDRESS:"0x38869bf66a61cF6bDB996A6aE40D5853Fd43B526",MULTI_SEND_CALL_ONLY_ADDRESS:"0x9641d764fc13c8B624c04430C7356C1C7C8102e2"}},SB=(t,e)=>{const r=[0,1,27,28],n=27;let s=parseInt(e.slice(-2),16);if(!r.includes(s))throw new Error("Invalid signature");return t==="eth_sign"&&(s{const e=t;return typeof e=="string"||e.raw?ob(e):P1(t)},X9e=t=>od(["uint8","address","uint256","uint256","bytes"],[t.operation,t.to,t.value,BigInt(t.data.slice(2).length/2),t.data]).slice(2),cK=t=>{const e=`0x${t.map(r=>X9e(r)).join("")}`;return mi({abi:[{inputs:[{internalType:"bytes",name:"transactions",type:"bytes"}],name:"multiSend",outputs:[],stateMutability:"payable",type:"function"}],functionName:"multiSend",args:[e]})},uK=async({owner:t,addModuleLibAddress:e,safe4337ModuleAddress:r,multiSendAddress:n,setupTransactions:s=[],safeModules:i=[]})=>{const o=cK([{to:e,data:mi({abi:[{inputs:[{internalType:"address[]",name:"modules",type:"address[]"}],name:"enableModules",outputs:[],stateMutability:"nonpayable",type:"function"}],functionName:"enableModules",args:[[r,...i]]}),value:0n,operation:1},...s.map(f=>({...f,operation:0}))]);return mi({abi:[{inputs:[{internalType:"address[]",name:"_owners",type:"address[]"},{internalType:"uint256",name:"_threshold",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bytes",name:"data",type:"bytes"},{internalType:"address",name:"fallbackHandler",type:"address"},{internalType:"address",name:"paymentToken",type:"address"},{internalType:"uint256",name:"payment",type:"uint256"},{internalType:"address payable",name:"paymentReceiver",type:"address"}],name:"setup",outputs:[],stateMutability:"nonpayable",type:"function"}],functionName:"setup",args:[[t],1n,n,o,r,Q7,0n,Q7]})},e7e=async({owner:t,addModuleLibAddress:e,safe4337ModuleAddress:r,safeProxyFactoryAddress:n,safeSingletonAddress:s,multiSendAddress:i,saltNonce:o=0n,setupTransactions:f=[],safeModules:h=[]})=>{if(!t)throw new Error("Owner account not found");const p=await uK({owner:t,addModuleLibAddress:e,safe4337ModuleAddress:r,multiSendAddress:i,setupTransactions:f,safeModules:h}),b=mi({abi:[{inputs:[{internalType:"address",name:"_singleton",type:"address"},{internalType:"bytes",name:"initializer",type:"bytes"},{internalType:"uint256",name:"saltNonce",type:"uint256"}],name:"createProxyWithNonce",outputs:[{internalType:"contract SafeProxy",name:"proxy",type:"address"}],stateMutability:"nonpayable",type:"function"}],functionName:"createProxyWithNonce",args:[s,p,o]});return fo([n,b])},t7e=async({client:t,owner:e,addModuleLibAddress:r,safe4337ModuleAddress:n,safeProxyFactoryAddress:s,safeSingletonAddress:i,multiSendAddress:o,setupTransactions:f=[],safeModules:h=[],saltNonce:p=0n})=>{const b=await Yo(t,{abi:[{inputs:[],name:"proxyCreationCode",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"pure",type:"function"}],address:s,functionName:"proxyCreationCode"}),v=od(["bytes","uint256"],[b,Wt(i)]),E=await uK({owner:e,addModuleLibAddress:r,safe4337ModuleAddress:n,multiSendAddress:o,setupTransactions:f,safeModules:h}),_=zr(od(["bytes32","uint256"],[zr(od(["bytes"],[E])),p]));return SG({from:s,salt:_,bytecode:v,opcode:"CREATE2"})},r7e=(t,{addModuleLibAddress:e,safe4337ModuleAddress:r,safeProxyFactoryAddress:n,safeSingletonAddress:s,multiSendAddress:i,multiSendCallOnlyAddress:o})=>{const f=e??ah[t].ADD_MODULES_LIB_ADDRESS,h=r??ah[t].SAFE_4337_MODULE_ADDRESS,p=n??ah[t].SAFE_PROXY_FACTORY_ADDRESS,b=s??ah[t].SAFE_SINGLETON_ADDRESS,v=i??ah[t].MULTI_SEND_ADDRESS,E=o??ah[t].MULTI_SEND_CALL_ONLY_ADDRESS;return{addModuleLibAddress:f,safe4337ModuleAddress:h,safeProxyFactoryAddress:p,safeSingletonAddress:b,multiSendAddress:v,multiSendCallOnlyAddress:E}};async function n7e(t,{signer:e,safeVersion:r,entryPoint:n,addModuleLibAddress:s,safe4337ModuleAddress:i,safeProxyFactoryAddress:o,safeSingletonAddress:f,multiSendAddress:h,multiSendCallOnlyAddress:p,saltNonce:b=0n,validUntil:v=0,validAfter:E=0,safeModules:_=[],setupTransactions:S=[]}){const P=await Vp(t),I={...e,signTransaction:(K,se)=>{throw new MB}},{addModuleLibAddress:C,safe4337ModuleAddress:T,safeProxyFactoryAddress:B,safeSingletonAddress:N,multiSendAddress:$,multiSendCallOnlyAddress:H}=r7e(r,{addModuleLibAddress:s,safe4337ModuleAddress:i,safeProxyFactoryAddress:o,safeSingletonAddress:f,multiSendAddress:h,multiSendCallOnlyAddress:p}),J=await t7e({client:t,owner:I.address,addModuleLibAddress:C,safe4337ModuleAddress:T,safeProxyFactoryAddress:B,safeSingletonAddress:N,multiSendAddress:$,saltNonce:b,setupTransactions:S,safeModules:_});if(!J)throw new Error("Account address not found");return{...fK({address:J,async signMessage({message:K}){const se=P1({domain:{chainId:P,verifyingContract:J},types:{SafeMessage:[{name:"message",type:"bytes"}]},primaryType:"SafeMessage",message:{message:_B(K)}});return SB("eth_sign",await XG(t,{account:I,message:{raw:vn(se)}}))},async signTransaction(K,se){throw new MB},async signTypedData(K){return SB("eth_signTypedData",await Z7(t,{account:I,domain:{chainId:P,verifyingContract:J},types:{SafeMessage:[{name:"message",type:"bytes"}]},primaryType:"SafeMessage",message:{message:_B(K)}}))}}),client:t,publicKey:J,entryPoint:n,source:"SafeSmartAccount",async getNonce(){return N9e(t,{sender:J,entryPoint:n})},async signUserOperation(K){const se=[{signer:I.address,data:await Z7(t,{account:I,domain:{chainId:P,verifyingContract:T},types:Y9e,primaryType:"SafeOp",message:{safe:J,callData:K.callData,entryPoint:n,nonce:K.nonce,initCode:K.initCode,maxFeePerGas:K.maxFeePerGas,maxPriorityFeePerGas:K.maxPriorityFeePerGas,preVerificationGas:K.preVerificationGas,verificationGasLimit:K.verificationGasLimit,callGasLimit:K.callGasLimit,paymasterAndData:K.paymasterAndData,validAfter:E,validUntil:v}})}];se.sort((a,u)=>a.signer.toLowerCase().localeCompare(u.signer.toLowerCase()));const w=cs(se.map(a=>a.data));return od(["uint48","uint48","bytes"],[E,v,w])},async getInitCode(){const K=await hG(t,{address:J});return((K==null?void 0:K.length)??0)>2?"0x":e7e({owner:I.address,addModuleLibAddress:C,safe4337ModuleAddress:T,safeProxyFactoryAddress:B,safeSingletonAddress:N,multiSendAddress:$,saltNonce:b,setupTransactions:S,safeModules:_})},async encodeDeployCallData(K){throw new Error("Safe account doesn't support account deployment")},async encodeCallData(K){let se,w,a;if(Array.isArray(K)){const u=K;se=H,w=0n,a=cK(u.map(l=>({...l,operation:0})))}else{const u=K;se=u.to,a=u.data,w=u.value}return mi({abi:[{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"},{internalType:"uint8",name:"operation",type:"uint8"}],name:"executeUserOp",outputs:[],stateMutability:"nonpayable",type:"function"}],functionName:"executeUserOp",args:[se,w,a,0]})},async getDummySignature(){return"0x000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"}}}/** - * Code modified from https://github.com/google/tink/blob/6f74b99a2bfe6677e3670799116a57268fd067fa/javascript/subtle/bytes.ts - * - * @license - * Copyright 2020 Google LLC - * SPDX-License-Identifier: Apache-2.0 - */function i7e(t){if(t.length%2!=0)throw new Error("Hex string length must be multiple of 2");const e=new Uint8Array(t.length/2);for(let r=0;r1?n:"0"+n}return e}function PB(t,e){const r=btoa(o7e(t)).replace(/=/g,"");return e?r.replace(/\+/g,"-").replace(/\//g,"_"):r}function o7e(t){let e="";for(let r=0;r>BigInt(2),s=c7e(r,n,e);if(s*s%e!==r)throw new Error("could not find a modular square root");return s}throw new Error("unsupported modulus value")}function l7e(t,e){const r=lK(),n=r-BigInt(3),s=a7e(),i=((t*t+n)*t+s)%r;let o=u7e(i,r);return e!==fA(o,0)&&(o=(r-o)%r),o}function h7e(t){const e=d7e();if(t.length!==1+e)throw new Error("compressed point has wrong length");if(t[0]!==2&&t[0]!==3)throw new Error("invalid format");const r=t[0]===3,n=f7e(t.subarray(1,t.length)),s=lK();if(n=s)throw new Error("x is out of range");const i=l7e(n,r);return{kty:"EC",crv:"P-256",x:PB(CB(n),!0),y:PB(CB(i),!0),ext:!0}}function d7e(){return 32}function hK(t){const e=btoa(t);return p7e(e)}function p7e(t){return t.replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function eSe(t){return t.reduce((e,r)=>e+r.toString(16).padStart(2,"0"),"")}function tSe(t){const{uncompressedPrivateKeyHex:e,compressedPublicKeyHex:r}=t,n=h7e(dK(r));return n.d=m7e(e),n}function dK(t){if(t.length===0||t.length%2!==0||/[^a-fA-F0-9]/u.test(t))throw new Error(`Invalid hex string: ${JSON.stringify(t)}`);return Uint8Array.from(t.match(/.{2}/g).map(e=>parseInt(e,16)))}function m7e(t){const e=dK(t);return hK(e.reduce((r,n)=>r+String.fromCharCode(n),""))}const g7e="X-Stamp",y7e=async t=>{var e;return typeof((e=globalThis==null?void 0:globalThis.crypto)==null?void 0:e.subtle)<"u"?(await $6(()=>import("./webcrypto-31cddabe.js"),[]).then(n=>n.signWithApiKey))(t):(await $6(()=>import("./nodecrypto-7fa9a5ea.js"),[]).then(n=>n.signWithApiKey))(t)};class pK{constructor(e){this.apiPublicKey=e.apiPublicKey,this.apiPrivateKey=e.apiPrivateKey}async stamp(e){const r=await y7e({publicKey:this.apiPublicKey,privateKey:this.apiPrivateKey,content:e}),n={publicKey:this.apiPublicKey,scheme:"SIGNATURE_SCHEME_TK_API_P256",signature:r};return{stampHeaderName:g7e,stampHeaderValue:hK(JSON.stringify(n))}}}var cA={exports:{}};(function(t,e){var r=typeof self<"u"?self:Ke,n=function(){function i(){this.fetch=!1,this.DOMException=r.DOMException}return i.prototype=r,new i}();(function(i){(function(o){var f={searchParams:"URLSearchParams"in i,iterable:"Symbol"in i&&"iterator"in Symbol,blob:"FileReader"in i&&"Blob"in i&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in i,arrayBuffer:"ArrayBuffer"in i};function h(l){return l&&DataView.prototype.isPrototypeOf(l)}if(f.arrayBuffer)var p=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],b=ArrayBuffer.isView||function(l){return l&&p.indexOf(Object.prototype.toString.call(l))>-1};function v(l){if(typeof l!="string"&&(l=String(l)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(l))throw new TypeError("Invalid character in header field name");return l.toLowerCase()}function E(l){return typeof l!="string"&&(l=String(l)),l}function _(l){var d={next:function(){var m=l.shift();return{done:m===void 0,value:m}}};return f.iterable&&(d[Symbol.iterator]=function(){return d}),d}function S(l){this.map={},l instanceof S?l.forEach(function(d,m){this.append(m,d)},this):Array.isArray(l)?l.forEach(function(d){this.append(d[0],d[1])},this):l&&Object.getOwnPropertyNames(l).forEach(function(d){this.append(d,l[d])},this)}S.prototype.append=function(l,d){l=v(l),d=E(d);var m=this.map[l];this.map[l]=m?m+", "+d:d},S.prototype.delete=function(l){delete this.map[v(l)]},S.prototype.get=function(l){return l=v(l),this.has(l)?this.map[l]:null},S.prototype.has=function(l){return this.map.hasOwnProperty(v(l))},S.prototype.set=function(l,d){this.map[v(l)]=E(d)},S.prototype.forEach=function(l,d){for(var m in this.map)this.map.hasOwnProperty(m)&&l.call(d,this.map[m],m,this)},S.prototype.keys=function(){var l=[];return this.forEach(function(d,m){l.push(m)}),_(l)},S.prototype.values=function(){var l=[];return this.forEach(function(d){l.push(d)}),_(l)},S.prototype.entries=function(){var l=[];return this.forEach(function(d,m){l.push([m,d])}),_(l)},f.iterable&&(S.prototype[Symbol.iterator]=S.prototype.entries);function P(l){if(l.bodyUsed)return Promise.reject(new TypeError("Already read"));l.bodyUsed=!0}function I(l){return new Promise(function(d,m){l.onload=function(){d(l.result)},l.onerror=function(){m(l.error)}})}function C(l){var d=new FileReader,m=I(d);return d.readAsArrayBuffer(l),m}function T(l){var d=new FileReader,m=I(d);return d.readAsText(l),m}function B(l){for(var d=new Uint8Array(l),m=new Array(d.length),x=0;x-1?d:l}function Q(l,d){d=d||{};var m=d.body;if(l instanceof Q){if(l.bodyUsed)throw new TypeError("Already read");this.url=l.url,this.credentials=l.credentials,d.headers||(this.headers=new S(l.headers)),this.method=l.method,this.mode=l.mode,this.signal=l.signal,!m&&l._bodyInit!=null&&(m=l._bodyInit,l.bodyUsed=!0)}else this.url=String(l);if(this.credentials=d.credentials||this.credentials||"same-origin",(d.headers||!this.headers)&&(this.headers=new S(d.headers)),this.method=J(d.method||this.method||"GET"),this.mode=d.mode||this.mode||null,this.signal=d.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&m)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(m)}Q.prototype.clone=function(){return new Q(this,{body:this._bodyInit})};function K(l){var d=new FormData;return l.trim().split("&").forEach(function(m){if(m){var x=m.split("="),A=x.shift().replace(/\+/g," "),y=x.join("=").replace(/\+/g," ");d.append(decodeURIComponent(A),decodeURIComponent(y))}}),d}function se(l){var d=new S,m=l.replace(/\r?\n[\t ]+/g," ");return m.split(/\r?\n/).forEach(function(x){var A=x.split(":"),y=A.shift().trim();if(y){var c=A.join(":").trim();d.append(y,c)}}),d}$.call(Q.prototype);function w(l,d){d||(d={}),this.type="default",this.status=d.status===void 0?200:d.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in d?d.statusText:"OK",this.headers=new S(d.headers),this.url=d.url||"",this._initBody(l)}$.call(w.prototype),w.prototype.clone=function(){return new w(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new S(this.headers),url:this.url})},w.error=function(){var l=new w(null,{status:0,statusText:""});return l.type="error",l};var a=[301,302,303,307,308];w.redirect=function(l,d){if(a.indexOf(d)===-1)throw new RangeError("Invalid status code");return new w(null,{status:d,headers:{location:l}})},o.DOMException=i.DOMException;try{new o.DOMException}catch{o.DOMException=function(d,m){this.message=d,this.name=m;var x=Error(d);this.stack=x.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function u(l,d){return new Promise(function(m,x){var A=new Q(l,d);if(A.signal&&A.signal.aborted)return x(new o.DOMException("Aborted","AbortError"));var y=new XMLHttpRequest;function c(){y.abort()}y.onload=function(){var g={status:y.status,statusText:y.statusText,headers:se(y.getAllResponseHeaders()||"")};g.url="responseURL"in y?y.responseURL:g.headers.get("X-Request-URL");var M="response"in y?y.response:y.responseText;m(new w(M,g))},y.onerror=function(){x(new TypeError("Network request failed"))},y.ontimeout=function(){x(new TypeError("Network request failed"))},y.onabort=function(){x(new o.DOMException("Aborted","AbortError"))},y.open(A.method,A.url,!0),A.credentials==="include"?y.withCredentials=!0:A.credentials==="omit"&&(y.withCredentials=!1),"responseType"in y&&f.blob&&(y.responseType="blob"),A.headers.forEach(function(g,M){y.setRequestHeader(M,g)}),A.signal&&(A.signal.addEventListener("abort",c),y.onreadystatechange=function(){y.readyState===4&&A.signal.removeEventListener("abort",c)}),y.send(typeof A._bodyInit>"u"?null:A._bodyInit)})}return u.polyfill=!0,i.fetch||(i.fetch=u,i.Headers=S,i.Request=Q,i.Response=w),o.Headers=S,o.Request=Q,o.Response=w,o.fetch=u,Object.defineProperty(o,"__esModule",{value:!0}),o})({})})(n),n.fetch.ponyfill=!0,delete n.fetch.polyfill;var s=n;e=s.fetch,e.default=s.fetch,e.fetch=s.fetch,e.Headers=s.Headers,e.Request=s.Request,e.Response=s.Response,t.exports=e})(cA,cA.exports);var b7e=cA.exports;const v7e=b7e.fetch;function x7e(t){const e=new Uint8Array(t);let r="";for(const i of e)r+=String.fromCharCode(i);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}const X0="copy",a2="convert";function uA(t,e,r){if(e===X0)return r;if(e===a2)return t(r);if(e instanceof Array)return r.map(n=>uA(t,e[0],n));if(e instanceof Object){const n={};for(const[s,i]of Object.entries(e)){if(i.derive){const o=i.derive(r);o!==void 0&&(r[s]=o)}if(!(s in r)){if(i.required)throw new Error(`Missing key: ${s}`);continue}if(r[s]==null){n[s]=null;continue}n[s]=uA(t,i.schema,r[s])}return n}}function IB(t,e){return{required:!0,schema:t,derive:e}}function fh(t){return{required:!0,schema:t}}function f2(t){return{required:!1,schema:t}}const w7e={appid:f2(X0),appidExclude:f2(X0),credProps:f2(X0)},A7e={type:fh(X0),id:fh(X0),rawId:fh(a2),authenticatorAttachment:f2(X0),response:fh({clientDataJSON:fh(a2),attestationObject:fh(a2),transports:IB(X0,t=>{var e;return((e=t.getTransports)==null?void 0:e.call(t))||[]})}),clientExtensionResults:IB(w7e,t=>t.getClientExtensionResults())};function E7e(t){return uA(x7e,A7e,t)}async function M7e(t){const e=await navigator.credentials.create(t);return e.toJSON=()=>E7e(e),e}function S7e(t){switch(t){case"internal":return"AUTHENTICATOR_TRANSPORT_INTERNAL";case"usb":return"AUTHENTICATOR_TRANSPORT_USB";case"nfc":return"AUTHENTICATOR_TRANSPORT_NFC";case"ble":return"AUTHENTICATOR_TRANSPORT_BLE";case"hybrid":return"AUTHENTICATOR_TRANSPORT_HYBRID";default:throw new Error("unsupported transport format")}}function _7e(t){return{credentialId:t.rawId,attestationObject:t.response.attestationObject,clientDataJson:t.response.clientDataJSON,transports:t.response.transports.map(S7e)}}async function P7e(t){if(!C7e())throw new Error("webauthn is not supported by this browser");const r=await M7e(t);return _7e(r.toJSON())}function C7e(){return!!window.PublicKeyCredential}class I7e extends Error{constructor(e){let r=`Turnkey error ${e.code}: ${e.message}`;e.details!=null&&(r+=` (Details: ${JSON.stringify(e.details)})`),super(r),this.name="TurnkeyRequestError",this.details=e.details??null,this.code=e.code}}class Uw{constructor(e,r){if(this.getActivity=async n=>this.request("/public/v1/query/get_activity",n),this.stampGetActivity=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_activity",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getAuthenticator=async n=>this.request("/public/v1/query/get_authenticator",n),this.stampGetAuthenticator=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_authenticator",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getAuthenticators=async n=>this.request("/public/v1/query/get_authenticators",n),this.stampGetAuthenticators=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_authenticators",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getOrganization=async n=>this.request("/public/v1/query/get_organization",n),this.stampGetOrganization=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_organization",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getPolicy=async n=>this.request("/public/v1/query/get_policy",n),this.stampGetPolicy=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_policy",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getPrivateKey=async n=>this.request("/public/v1/query/get_private_key",n),this.stampGetPrivateKey=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_private_key",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getUser=async n=>this.request("/public/v1/query/get_user",n),this.stampGetUser=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_user",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getWallet=async n=>this.request("/public/v1/query/get_wallet",n),this.stampGetWallet=async n=>{const s=this.config.baseUrl+"/public/v1/query/get_wallet",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getActivities=async n=>this.request("/public/v1/query/list_activities",n),this.stampGetActivities=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_activities",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getPolicies=async n=>this.request("/public/v1/query/list_policies",n),this.stampGetPolicies=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_policies",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.listPrivateKeyTags=async n=>this.request("/public/v1/query/list_private_key_tags",n),this.stampListPrivateKeyTags=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_private_key_tags",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getPrivateKeys=async n=>this.request("/public/v1/query/list_private_keys",n),this.stampGetPrivateKeys=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_private_keys",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.listUserTags=async n=>this.request("/public/v1/query/list_user_tags",n),this.stampListUserTags=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_user_tags",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getUsers=async n=>this.request("/public/v1/query/list_users",n),this.stampGetUsers=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_users",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getWalletAccounts=async n=>this.request("/public/v1/query/list_wallet_accounts",n),this.stampGetWalletAccounts=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_wallet_accounts",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getWallets=async n=>this.request("/public/v1/query/list_wallets",n),this.stampGetWallets=async n=>{const s=this.config.baseUrl+"/public/v1/query/list_wallets",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.getWhoami=async n=>this.request("/public/v1/query/whoami",n),this.stampGetWhoami=async n=>{const s=this.config.baseUrl+"/public/v1/query/whoami",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.approveActivity=async n=>this.request("/public/v1/submit/approve_activity",n),this.stampApproveActivity=async n=>{const s=this.config.baseUrl+"/public/v1/submit/approve_activity",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createApiKeys=async n=>this.request("/public/v1/submit/create_api_keys",n),this.stampCreateApiKeys=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_api_keys",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createApiOnlyUsers=async n=>this.request("/public/v1/submit/create_api_only_users",n),this.stampCreateApiOnlyUsers=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_api_only_users",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createAuthenticators=async n=>this.request("/public/v1/submit/create_authenticators",n),this.stampCreateAuthenticators=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_authenticators",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createInvitations=async n=>this.request("/public/v1/submit/create_invitations",n),this.stampCreateInvitations=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_invitations",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createPolicy=async n=>this.request("/public/v1/submit/create_policy",n),this.stampCreatePolicy=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_policy",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createPrivateKeyTag=async n=>this.request("/public/v1/submit/create_private_key_tag",n),this.stampCreatePrivateKeyTag=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_private_key_tag",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createPrivateKeys=async n=>this.request("/public/v1/submit/create_private_keys",n),this.stampCreatePrivateKeys=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_private_keys",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createSubOrganization=async n=>this.request("/public/v1/submit/create_sub_organization",n),this.stampCreateSubOrganization=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_sub_organization",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createUserTag=async n=>this.request("/public/v1/submit/create_user_tag",n),this.stampCreateUserTag=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_user_tag",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createUsers=async n=>this.request("/public/v1/submit/create_users",n),this.stampCreateUsers=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_users",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createWallet=async n=>this.request("/public/v1/submit/create_wallet",n),this.stampCreateWallet=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_wallet",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.createWalletAccounts=async n=>this.request("/public/v1/submit/create_wallet_accounts",n),this.stampCreateWalletAccounts=async n=>{const s=this.config.baseUrl+"/public/v1/submit/create_wallet_accounts",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.deleteApiKeys=async n=>this.request("/public/v1/submit/delete_api_keys",n),this.stampDeleteApiKeys=async n=>{const s=this.config.baseUrl+"/public/v1/submit/delete_api_keys",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.deleteAuthenticators=async n=>this.request("/public/v1/submit/delete_authenticators",n),this.stampDeleteAuthenticators=async n=>{const s=this.config.baseUrl+"/public/v1/submit/delete_authenticators",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.deleteInvitation=async n=>this.request("/public/v1/submit/delete_invitation",n),this.stampDeleteInvitation=async n=>{const s=this.config.baseUrl+"/public/v1/submit/delete_invitation",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.deletePolicy=async n=>this.request("/public/v1/submit/delete_policy",n),this.stampDeletePolicy=async n=>{const s=this.config.baseUrl+"/public/v1/submit/delete_policy",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.emailAuth=async n=>this.request("/public/v1/submit/email_auth",n),this.stampEmailAuth=async n=>{const s=this.config.baseUrl+"/public/v1/submit/email_auth",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.exportPrivateKey=async n=>this.request("/public/v1/submit/export_private_key",n),this.stampExportPrivateKey=async n=>{const s=this.config.baseUrl+"/public/v1/submit/export_private_key",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.exportWallet=async n=>this.request("/public/v1/submit/export_wallet",n),this.stampExportWallet=async n=>{const s=this.config.baseUrl+"/public/v1/submit/export_wallet",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.initUserEmailRecovery=async n=>this.request("/public/v1/submit/init_user_email_recovery",n),this.stampInitUserEmailRecovery=async n=>{const s=this.config.baseUrl+"/public/v1/submit/init_user_email_recovery",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.recoverUser=async n=>this.request("/public/v1/submit/recover_user",n),this.stampRecoverUser=async n=>{const s=this.config.baseUrl+"/public/v1/submit/recover_user",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.rejectActivity=async n=>this.request("/public/v1/submit/reject_activity",n),this.stampRejectActivity=async n=>{const s=this.config.baseUrl+"/public/v1/submit/reject_activity",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.removeOrganizationFeature=async n=>this.request("/public/v1/submit/remove_organization_feature",n),this.stampRemoveOrganizationFeature=async n=>{const s=this.config.baseUrl+"/public/v1/submit/remove_organization_feature",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.setOrganizationFeature=async n=>this.request("/public/v1/submit/set_organization_feature",n),this.stampSetOrganizationFeature=async n=>{const s=this.config.baseUrl+"/public/v1/submit/set_organization_feature",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.signRawPayload=async n=>this.request("/public/v1/submit/sign_raw_payload",n),this.stampSignRawPayload=async n=>{const s=this.config.baseUrl+"/public/v1/submit/sign_raw_payload",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.signTransaction=async n=>this.request("/public/v1/submit/sign_transaction",n),this.stampSignTransaction=async n=>{const s=this.config.baseUrl+"/public/v1/submit/sign_transaction",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.updatePolicy=async n=>this.request("/public/v1/submit/update_policy",n),this.stampUpdatePolicy=async n=>{const s=this.config.baseUrl+"/public/v1/submit/update_policy",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.updatePrivateKeyTag=async n=>this.request("/public/v1/submit/update_private_key_tag",n),this.stampUpdatePrivateKeyTag=async n=>{const s=this.config.baseUrl+"/public/v1/submit/update_private_key_tag",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.updateRootQuorum=async n=>this.request("/public/v1/submit/update_root_quorum",n),this.stampUpdateRootQuorum=async n=>{const s=this.config.baseUrl+"/public/v1/submit/update_root_quorum",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.updateUser=async n=>this.request("/public/v1/submit/update_user",n),this.stampUpdateUser=async n=>{const s=this.config.baseUrl+"/public/v1/submit/update_user",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},this.updateUserTag=async n=>this.request("/public/v1/submit/update_user_tag",n),this.stampUpdateUserTag=async n=>{const s=this.config.baseUrl+"/public/v1/submit/update_user_tag",i=JSON.stringify(n),o=await this.stamper.stamp(i);return{body:i,stamp:o,url:s}},!e.baseUrl)throw new Error("Missing base URL. Please verify env vars.");this.config=e,this.stamper=r}async request(e,r){const n=this.config.baseUrl+e,s=JSON.stringify(r),i=await this.stamper.stamp(s),o=await v7e(n,{method:"POST",headers:{[i.stampHeaderName]:i.stampHeaderValue},body:s,redirect:"follow"});if(!o.ok){let h;try{h=await o.json()}catch{throw new Error(`${o.status} ${o.statusText}`)}throw new I7e(h)}return await o.json()}}class Ho extends Error{constructor(e){const{message:r,cause:n,activityId:s,activityStatus:i,activityType:o}=e;super(r),this.name="TurnkeyActivityError",this.activityId=s??null,this.activityStatus=i??null,this.activityType=o??null,this.cause=n??null}}const T7e=500;function k7e(t){const{client:e,requestFn:r,refreshIntervalMs:n=T7e}=t;return async s=>{let o=(await r(s)).activity;for(;;){switch(o.status){case"ACTIVITY_STATUS_COMPLETED":return o;case"ACTIVITY_STATUS_CREATED":break;case"ACTIVITY_STATUS_PENDING":break;case"ACTIVITY_STATUS_CONSENSUS_NEEDED":throw new Ho({message:`Consensus needed for activity ${o.id}`,activityId:o.id,activityStatus:o.status,activityType:o.type});case"ACTIVITY_STATUS_FAILED":throw new Ho({message:`Activity ${o.id} failed`,activityId:o.id,activityStatus:o.status,activityType:o.type});case"ACTIVITY_STATUS_REJECTED":throw new Ho({message:`Activity ${o.id} was rejected`,activityId:o.id,activityStatus:o.status,activityType:o.type});default:B7e(o.status)}await R7e(n),o=(await e.getActivity({activityId:o.id,organizationId:o.organizationId})).activity}}}function R7e(t){return new Promise(e=>{setTimeout(()=>{e()},t)})}function B7e(t,e){throw new Error(e??`Unexpected case: ${JSON.stringify(t)}`)}async function O7e(t){var i;const{client:e,organizationId:r,signWith:n}=t;let{ethereumAddress:s}=t;if(!n)throw new Ho({message:"Missing signWith parameter"});if(wr(n))s=n;else if(!s&&(s=(i=(await e.getPrivateKey({privateKeyId:n,organizationId:r})).privateKey.addresses.find(f=>f.format==="ADDRESS_FORMAT_ETHEREUM"))==null?void 0:i.address,typeof s!="string"||!s))throw new Ho({message:`Unable to find Ethereum address for key ${n} under organization ${r}`});return fK({address:s,signMessage:function({message:o}){return N7e(e,o,r,n)},signTransaction:function(o,f){const h=f!=null&&f.serializer?f.serializer:H_;return L7e(e,o,h,r,n)},signTypedData:function(o){return D7e(e,o,r,n)}})}async function N7e(t,e,r,n){const s=ob(e);return`${await mK(t,s,r,n)}`}async function L7e(t,e,r,n,s){const o=r(e).replace(/^0x/,"");return await $7e(t,o,n,s)}async function D7e(t,e,r,n){const s=P1(e);return await mK(t,s,r,n)}async function $7e(t,e,r,n){let s;try{s=await F7e(t,e,r,n)}catch(i){throw i instanceof Ho?i:new Ho({message:`Failed to sign transaction: ${i.message}`,cause:i})}return`0x${s}`}async function F7e(t,e,r,n){var h,p;const{activity:s}=await t.signTransaction({type:"ACTIVITY_TYPE_SIGN_TRANSACTION_V2",organizationId:r,parameters:{signWith:n,type:"TRANSACTION_TYPE_ETHEREUM",unsignedTransaction:e},timestampMs:String(Date.now())}),{id:i,status:o,type:f}=s;if(s.status==="ACTIVITY_STATUS_COMPLETED")return lA((p=(h=s==null?void 0:s.result)==null?void 0:h.signTransactionResult)==null?void 0:p.signedTransaction);throw new Ho({message:`Invalid activity status: ${s.status}`,activityId:i,activityStatus:o,activityType:f})}async function mK(t,e,r,n){let s;try{s=await U7e(t,e,r,n)}catch(i){throw i instanceof Ho?i:new Ho({message:`Failed to sign: ${i.message}`,cause:i})}return s}async function U7e(t,e,r,n){var h;const{activity:s}=await t.signRawPayload({type:"ACTIVITY_TYPE_SIGN_RAW_PAYLOAD_V2",organizationId:r,parameters:{signWith:n,payload:e,encoding:"PAYLOAD_ENCODING_HEXADECIMAL",hashFunction:"HASH_FUNCTION_NO_OP"},timestampMs:String(Date.now())}),{id:i,status:o,type:f}=s;if(s.status==="ACTIVITY_STATUS_COMPLETED"){let p=lA((h=s==null?void 0:s.result)==null?void 0:h.signRawPayloadResult),b=gV({r:`0x${p.r}`,s:`0x${p.s}`,v:p.v==="00"?27n:28n});return lA(b)}throw new Ho({message:`Invalid activity status: ${s.status}`,activityId:i,activityStatus:o,activityType:f})}function lA(t){if(t==null)throw new Error(`Got unexpected ${JSON.stringify(t)}`);return t}function z7e(t){const e=new Uint8Array(t);let r="";for(const i of e)r+=String.fromCharCode(i);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}const Qu="copy",ph="convert";function hA(t,e,r){if(e===Qu)return r;if(e===ph)return t(r);if(e instanceof Array)return r.map(n=>hA(t,e[0],n));if(e instanceof Object){const n={};for(const[s,i]of Object.entries(e)){if(i.derive){const o=i.derive(r);o!==void 0&&(r[s]=o)}if(!(s in r)){if(i.required)throw new Error(`Missing key: ${s}`);continue}if(r[s]==null){n[s]=null;continue}n[s]=hA(t,i.schema,r[s])}return n}}function j7e(t,e){return{required:!0,schema:t,derive:e}}function b0(t){return{required:!0,schema:t}}function c2(t){return{required:!1,schema:t}}const H7e={appid:c2(Qu),appidExclude:c2(Qu),credProps:c2(Qu)},q7e={type:b0(Qu),id:b0(Qu),rawId:b0(ph),authenticatorAttachment:c2(Qu),response:b0({clientDataJSON:b0(ph),authenticatorData:b0(ph),signature:b0(ph),userHandle:b0(ph)}),clientExtensionResults:j7e(H7e,t=>t.getClientExtensionResults())};function G7e(t){return hA(z7e,q7e,t)}async function V7e(t){const e=await navigator.credentials.get(t);return e.toJSON=()=>G7e(e),e}let e5;typeof(globalThis==null?void 0:globalThis.Buffer)<"u"?e5=globalThis.Buffer:e5=Ln.Buffer;const K7e="X-Stamp-Webauthn",W7e=5*60*1e3,J7e="preferred";class gK{constructor(e){this.rpId=e.rpId,this.timeout=e.timeout||W7e,this.userVerification=e.userVerification||J7e,this.allowCredentials=e.allowCredentials||[]}async stamp(e){const r=Z7e(e),n={publicKey:{rpId:this.rpId,challenge:r,allowCredentials:this.allowCredentials,timeout:this.timeout,userVerification:this.userVerification}},i=(await V7e(n)).toJSON(),o={authenticatorData:i.response.authenticatorData,clientDataJson:i.response.clientDataJSON,credentialId:i.id,signature:i.response.signature};return{stampHeaderName:K7e,stampHeaderValue:JSON.stringify(o)}}}function Z7e(t){const e=new TextEncoder().encode(t),r=Kp(e),n=e5.from(r).toString("hex"),s=e5.from(n,"utf8");return new Uint8Array(s)}const gP=["function name() view returns (string)","function symbol() view returns (string)","function decimals() view returns (uint8)","function totalSupply() view returns (uint256)","function balanceOf(address owner) view returns (uint256)","function transfer(address to, uint256 value) returns (bool)","function allowance(address owner, address spender) view returns (uint256)","function approve(address spender, uint256 value) returns (bool)","function transferFrom(address from, address to, uint256 value) returns (bool)"];function TB(t,e){if(t==null)throw new Error(e??`Unexpected ${JSON.stringify(t)}`);return t}const Q7e=new gK({rpId:{}.NEXT_PUBLIC_RPID}),yK=new Uw({baseUrl:"https://api.turnkey.com"},Q7e),bK=t=>{var e,r;return console.log(t),console.log((e=Yr.getNetworkById(t))==null?void 0:e.url),QG({transport:sd((r=Yr.getNetworkById(t))==null?void 0:r.url)})},kB=()=>{const t=new Uint8Array(32);return crypto.getRandomValues(t),t.buffer},Y7e=t=>Ve.Buffer.from(t).toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"");async function vK(t,e,r){const n=new ss(t,gP,r),s=await n.balanceOf(e);console.log(s);const i=await n.decimals();return CM(s,i)}async function yP(t,e){return await new ss(t,gP,e).decimals()}async function X7e(t,e,r,n){return(await new ss(t,gP,n).transfer.populateTransaction(e,r)).data}const xK=t=>[p9e,E9e,S9e,P9e,m9e,M9e,_9e].find(e=>e.id==t),wK=async(t,e,r,n,s=0n)=>{const i=xK(t),o=Z9e({transport:sd(`https://api.pimlico.io/v1/${i.name.toLowerCase().replace(/\s+/g,"-")}/rpc?apikey=2a09b339-49f0-446f-ab3e-9e963144e0a6`)}),f=Q9e({transport:sd(`https://api.pimlico.io/v2/${i.name.toLowerCase().replace(/\s+/g,"-")}/rpc?apikey=2a09b339-49f0-446f-ab3e-9e963144e0a6`)}),h=H9e({account:n,chain:i,transport:sd(`https://api.pimlico.io/v1/${i.name.toLowerCase().replace(/\s+/g,"-")}/rpc?apikey=2a09b339-49f0-446f-ab3e-9e963144e0a6`),sponsorUserOperation:f.sponsorUserOperation});console.log(h);const p=await o.getUserOperationGasPrice();try{const b=await h.sendTransaction({to:e,data:r,value:s,maxFeePerGas:p.fast.maxFeePerGas,maxPriorityFeePerGas:p.fast.maxPriorityFeePerGas});return console.log(b),b}catch(b){return console.log(b),!1}},Hm=async(t,e)=>{const r=xK(t.toString()),n=await O7e({client:yK,organizationId:e.subOrgId,signWith:e.address,ethereumAddress:e.address}),s=tV({account:n,chain:r,transport:sd()});try{const i=await n7e(bK(t),{signer:s.account,entryPoint:"0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789",safeVersion:"1.4.1",safe4337ModuleAddress:"0xa581c4A4DB7175302464fF3C06380BC3270b4037",addModuleLibAddress:"0x8EcD4ec46D4D2a6B64fE960B3D64e8B94B2234eb"});return console.log(i),i}catch(i){console.log(i)}},Tc="0xaB83F7041C82D5a915E608D887073B6C52a28459",eAe=async()=>{const e=(await(await I1()).getNetwork()).chainId.toString(),r=await bl(e);return await new ss(Tc,$w.abi,r).getLinkCount()},tAe=async(t,e)=>{const r=await bl(t);return await new ss(Tc,$w.abi,r).getLink(e)};function rAe(t){const e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";let r="";for(let n=0;n{const n=await I1(),s=(await n.getNetwork()).chainId.toString(),i=await bl(s),o=new ss(Tc,$w.abi,i);let f;return e==To?f=q$(r):f=IM(r,await yP(e,n)),{to:Tc,value:"0",data:(await o.createLink.populateTransaction(e,f,t)).data}},RB=async(t,e,r,n)=>{const s=await bl(t),{address:i,privateKey:o}=AK(r),f=nAe(n.address),h=Ze(f),p=iAe(h),b=sAe(n.address,o),E=await new ss(Tc,$w.abi,s).claimLink.populateTransaction(e,n.address,p,b);return await wK(t,Tc,E.data,n)},aAe=async(t,e)=>{if(!await vV())throw Error("Not connected to a Safe");const r=await Ow(),n=[],s=rAe(18),{address:i,privateKey:o}=AK(s);await i9e(r.safeAddress,Tc)||n.push(await s9e(r.safeAddress,Tc)),n.push(await oAe(i,t,e));const h=(await(await I1()).getNetwork()).chainId.toString(),p=await eAe();if(n.length!=0)return await $3e(n),{i:Number(p),p:s,c:h}};var EK={exports:{}};(function(t,e){(function(r,n){t.exports=n(Z)})(typeof self<"u"?self:Ke,function(r){return function(n){var s={};function i(o){if(s[o])return s[o].exports;var f=s[o]={i:o,l:!1,exports:{}};return n[o].call(f.exports,f,f.exports,i),f.l=!0,f.exports}return i.m=n,i.c=s,i.d=function(o,f,h){i.o(o,f)||Object.defineProperty(o,f,{enumerable:!0,get:h})},i.r=function(o){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})},i.t=function(o,f){if(1&f&&(o=i(o)),8&f||4&f&&typeof o=="object"&&o&&o.__esModule)return o;var h=Object.create(null);if(i.r(h),Object.defineProperty(h,"default",{enumerable:!0,value:o}),2&f&&typeof o!="string")for(var p in o)i.d(h,p,(function(b){return o[b]}).bind(null,p));return h},i.n=function(o){var f=o&&o.__esModule?function(){return o.default}:function(){return o};return i.d(f,"a",f),f},i.o=function(o,f){return Object.prototype.hasOwnProperty.call(o,f)},i.p="",i(i.s=2)}([function(n,s){n.exports=r},function(n,s,i){var o={linear:function(f,h,p,b){return(p-h)*f/b+h},easeInQuad:function(f,h,p,b){return(p-h)*(f/=b)*f+h},easeOutQuad:function(f,h,p,b){return-(p-h)*(f/=b)*(f-2)+h},easeInOutQuad:function(f,h,p,b){var v=p-h;return(f/=b/2)<1?v/2*f*f+h:-v/2*(--f*(f-2)-1)+h},easeInCubic:function(f,h,p,b){return(p-h)*(f/=b)*f*f+h},easeOutCubic:function(f,h,p,b){return(p-h)*((f=f/b-1)*f*f+1)+h},easeInOutCubic:function(f,h,p,b){var v=p-h;return(f/=b/2)<1?v/2*f*f*f+h:v/2*((f-=2)*f*f+2)+h},easeInQuart:function(f,h,p,b){return(p-h)*(f/=b)*f*f*f+h},easeOutQuart:function(f,h,p,b){return-(p-h)*((f=f/b-1)*f*f*f-1)+h},easeInOutQuart:function(f,h,p,b){var v=p-h;return(f/=b/2)<1?v/2*f*f*f*f+h:-v/2*((f-=2)*f*f*f-2)+h},easeInQuint:function(f,h,p,b){return(p-h)*(f/=b)*f*f*f*f+h},easeOutQuint:function(f,h,p,b){return(p-h)*((f=f/b-1)*f*f*f*f+1)+h},easeInOutQuint:function(f,h,p,b){var v=p-h;return(f/=b/2)<1?v/2*f*f*f*f*f+h:v/2*((f-=2)*f*f*f*f+2)+h},easeInSine:function(f,h,p,b){var v=p-h;return-v*Math.cos(f/b*(Math.PI/2))+v+h},easeOutSine:function(f,h,p,b){return(p-h)*Math.sin(f/b*(Math.PI/2))+h},easeInOutSine:function(f,h,p,b){return-(p-h)/2*(Math.cos(Math.PI*f/b)-1)+h},easeInExpo:function(f,h,p,b){return f==0?h:(p-h)*Math.pow(2,10*(f/b-1))+h},easeOutExpo:function(f,h,p,b){var v=p-h;return f==b?h+v:v*(1-Math.pow(2,-10*f/b))+h},easeInOutExpo:function(f,h,p,b){var v=p-h;return f===0?h:f===b?h+v:(f/=b/2)<1?v/2*Math.pow(2,10*(f-1))+h:v/2*(2-Math.pow(2,-10*--f))+h},easeInCirc:function(f,h,p,b){return-(p-h)*(Math.sqrt(1-(f/=b)*f)-1)+h},easeOutCirc:function(f,h,p,b){return(p-h)*Math.sqrt(1-(f=f/b-1)*f)+h},easeInOutCirc:function(f,h,p,b){var v=p-h;return(f/=b/2)<1?-v/2*(Math.sqrt(1-f*f)-1)+h:v/2*(Math.sqrt(1-(f-=2)*f)+1)+h},easeInElastic:function(f,h,p,b){var v,E,_,S=p-h;return _=1.70158,f===0?h:(f/=b)==1?h+S:((E=0)||(E=.3*b),(v=S)=1&&this.rotationDirection===f.Positive?this.rotationDirection=f.Negative:this.rotateY<=-1&&this.rotationDirection===f.Negative&&(this.rotationDirection=f.Positive);var je=.1*this.rotationDirection;if(this.rotateY+=je,this.angle+=this.angularSpin,this.context.save(),this.context.translate(this.x,this.y),this.context.rotate(this.angle),this.context.scale(1,this.rotateY),this.context.rotate(this.angle),this.context.beginPath(),this.context.fillStyle=this.color,this.context.strokeStyle=this.color,this.context.globalAlpha=ie,this.context.lineCap="round",this.context.lineWidth=2,ae&&typeof ae=="function")ae.call(this,this.context);else switch(this.shape){case o.Circle:this.context.beginPath(),this.context.arc(0,0,this.radius,0,2*Math.PI),this.context.fill();break;case o.Square:this.context.fillRect(-this.w/2,-this.h/2,this.w,this.h);break;case o.Strip:this.context.fillRect(-this.w/6,-this.h/2,this.w/3,this.h)}this.context.closePath(),this.context.restore()}}])&&_(G.prototype,Y),V}();function I(V,G,Y){return G in V?Object.defineProperty(V,G,{value:Y,enumerable:!0,configurable:!0,writable:!0}):V[G]=Y,V}var C=function V(G,Y){var q=this;(function(ee,re){if(!(ee instanceof re))throw new TypeError("Cannot call a class as a function")})(this,V),I(this,"canvas",void 0),I(this,"context",void 0),I(this,"getOptions",void 0),I(this,"x",0),I(this,"y",0),I(this,"w",0),I(this,"h",0),I(this,"lastNumberOfPieces",0),I(this,"tweenInitTime",Date.now()),I(this,"particles",[]),I(this,"particlesGenerated",0),I(this,"removeParticleAt",function(ee){q.particles.splice(ee,1)}),I(this,"getParticle",function(){var ee=E(q.x,q.w+q.x),re=E(q.y,q.h+q.y);return new P(q.context,q.getOptions,ee,re)}),I(this,"animate",function(){var ee=q.canvas,re=q.context,ie=q.particlesGenerated,ae=q.lastNumberOfPieces,je=q.getOptions(),he=je.run,oe=je.recycle,Qe=je.numberOfPieces,ge=je.debug,be=je.tweenFunction,ot=je.tweenDuration;if(!he)return!1;var ye=q.particles.length,xe=oe?ye:ie,at=Date.now();if(xeot?ot:Math.max(0,at-j),xe,Qe,ot),F=Math.round(O-xe),W=0;Wee.height||te.y<-100||te.x>ee.width+100||te.x<-100)&&(oe&&xe<=Qe?q.particles[le]=q.getParticle():q.removeParticleAt(le))}),ye>0||xe0&&je.call(ee,ee),ee._options.run=!1)}),$(this,"reset",function(){ee.generator&&ee.generator.particlesGenerated>0&&(ee.generator.particlesGenerated=0,ee.generator.particles=[],ee.generator.lastNumberOfPieces=0)}),$(this,"stop",function(){ee.options={run:!1},ee.rafId&&(cancelAnimationFrame(ee.rafId),ee.rafId=void 0)}),this.canvas=q;var re=this.canvas.getContext("2d");if(!re)throw new Error("Could not get canvas context");this.context=re,this.generator=new C(this.canvas,function(){return ee.options}),this.options=z,this.update()}var G,Y;return G=V,(Y=[{key:"options",get:function(){return this._options},set:function(q){var z=this._options&&this._options.run,ee=this._options&&this._options.recycle;this.setOptionsWithDefaults(q),this.generator&&(Object.assign(this.generator,this.options.confettiSource),typeof q.recycle=="boolean"&&q.recycle&&ee===!1&&(this.generator.lastNumberOfPieces=this.generator.particles.length)),typeof q.run=="boolean"&&q.run&&z===!1&&this.update()}}])&&N(G.prototype,Y),V}();function Q(V){return function(G){if(Array.isArray(G))return d(G)}(V)||function(G){if(typeof Symbol<"u"&&Symbol.iterator in Object(G))return Array.from(G)}(V)||l(V)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function K(V){return(K=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(G){return typeof G}:function(G){return G&&typeof Symbol=="function"&&G.constructor===Symbol&&G!==Symbol.prototype?"symbol":typeof G})(V)}function se(){return(se=Object.assign||function(V){for(var G=1;G"u"||!(Symbol.iterator in Object(Y)))){var z=[],ee=!0,re=!1,ie=void 0;try{for(var ae,je=Y[Symbol.iterator]();!(ee=(ae=je.next()).done)&&(z.push(ae.value),!q||z.length!==q);ee=!0);}catch(he){re=!0,ie=he}finally{try{ee||je.return==null||je.return()}finally{if(re)throw ie}}return z}}(V,G)||l(V,G)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function l(V,G){if(V){if(typeof V=="string")return d(V,G);var Y=Object.prototype.toString.call(V).slice(8,-1);return Y==="Object"&&V.constructor&&(Y=V.constructor.name),Y==="Map"||Y==="Set"?Array.from(V):Y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Y)?d(V,G):void 0}}function d(V,G){(G==null||G>V.length)&&(G=V.length);for(var Y=0,q=new Array(G);Y"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}();return function(){var Y,q=M(V);if(G){var z=M(this).constructor;Y=Reflect.construct(q,arguments,z)}else Y=q.apply(this,arguments);return c(this,Y)}}function c(V,G){return!G||K(G)!=="object"&&typeof G!="function"?g(V):G}function g(V){if(V===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return V}function M(V){return(M=Object.setPrototypeOf?Object.getPrototypeOf:function(G){return G.__proto__||Object.getPrototypeOf(G)})(V)}function R(V,G,Y){return G in V?Object.defineProperty(V,G,{value:Y,enumerable:!0,configurable:!0,writable:!0}):V[G]=Y,V}var L=p.a.createRef(),k=function(V){(function(ee,re){if(typeof re!="function"&&re!==null)throw new TypeError("Super expression must either be null or a function");ee.prototype=Object.create(re&&re.prototype,{constructor:{value:ee,writable:!0,configurable:!0}}),re&&A(ee,re)})(z,V);var G,Y,q=y(z);function z(ee){var re;m(this,z);for(var ie=arguments.length,ae=new Array(ie>1?ie-1:0),je=1;je{try{if(Object.keys(kc).includes(t.toString()))return kc[t].find(r=>r.value.toLowerCase()==(e==null?void 0:e.toLowerCase()))}catch{console.log("Error getting token info")}return{}},PK=t=>Object.keys(kc).includes(t.toString())?kc[t]:[];var zw={},lAe=function(){var t=document.getSelection();if(!t.rangeCount)return function(){};for(var e=document.activeElement,r=[],n=0;n"u"){r&&console.warn("unable to use e.clipboardData"),r&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var v=BB[e.format]||BB.default;window.clipboardData.setData(v,t)}else b.clipboardData.clearData(),b.clipboardData.setData(e.format,t);e.onCopy&&(b.preventDefault(),e.onCopy(b.clipboardData))}),document.body.appendChild(f),i.selectNodeContents(f),o.addRange(i);var p=document.execCommand("copy");if(!p)throw new Error("copy command was unsuccessful");h=!0}catch(b){r&&console.error("unable to copy using execCommand: ",b),r&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(e.format||"text",t),e.onCopy&&e.onCopy(window.clipboardData),h=!0}catch(v){r&&console.error("unable to copy using clipboardData: ",v),r&&console.error("falling back to prompt"),n=pAe("message"in e?e.message:dAe),window.prompt(n,t)}}finally{o&&(typeof o.removeRange=="function"?o.removeRange(i):o.removeAllRanges()),f&&document.body.removeChild(f),s()}return h}var gAe=mAe;function dA(t){"@babel/helpers - typeof";return dA=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},dA(t)}Object.defineProperty(zw,"__esModule",{value:!0});zw.CopyToClipboard=void 0;var uv=CK(Z),yAe=CK(gAe),bAe=["text","onCopy","options","children"];function CK(t){return t&&t.__esModule?t:{default:t}}function OB(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),r.push.apply(r,n)}return r}function NB(t){for(var e=1;e=0)&&Object.prototype.propertyIsEnumerable.call(t,n)&&(r[n]=t[n])}return r}function xAe(t,e){if(t==null)return{};var r={},n=Object.keys(t),s,i;for(i=0;i=0)&&(r[s]=t[s]);return r}function wAe(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function LB(t,e){for(var r=0;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function t5(t){return t5=Object.setPrototypeOf?Object.getPrototypeOf:function(r){return r.__proto__||Object.getPrototypeOf(r)},t5(t)}function bP(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var TK=function(t){EAe(r,t);var e=MAe(r);function r(){var n;wAe(this,r);for(var s=arguments.length,i=new Array(s),o=0;oe in t?NAe(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,$B=(t,e)=>{for(var r in e||(e={}))OK.call(e,r)&&DB(t,r,e[r]);if(r5)for(var r of r5(e))NK.call(e,r)&&DB(t,r,e[r]);return t},$Ae=(t,e)=>LAe(t,DAe(e)),FAe=(t,e)=>{var r={};for(var n in t)OK.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&r5)for(var n of r5(t))e.indexOf(n)<0&&NK.call(t,n)&&(r[n]=t[n]);return r},UAe=(t,e,r)=>{const n=Z.forwardRef((s,i)=>{var o=s,{color:f="currentColor",size:h=24,stroke:p=2,children:b}=o,v=FAe(o,["color","size","stroke","children"]);return Z.createElement("svg",$B($Ae($B({ref:i},OAe),{width:h,height:h,stroke:f,strokeWidth:p,className:`tabler-icon tabler-icon-${t}`}),v),[...r.map(([E,_])=>Z.createElement(E,_)),...b||[]])});return n.propTypes={color:eu.string,size:eu.oneOfType([eu.string,eu.number]),stroke:eu.oneOfType([eu.string,eu.number])},n.displayName=`${e}`,n},zAe=UAe("brand-x","IconBrandX",[["path",{d:"M4 4l11.733 16h4.267l-11.733 -16z",key:"svg-0"}],["path",{d:"M4 20l6.768 -6.768m2.46 -2.46l6.772 -6.772",key:"svg-1"}]]);function jAe(){ME(!1);const{colorScheme:t}=TE(),e=t==="dark",[r,n]=Z.useState("0");Z.useState(""),Z.useState("");const[s,i]=Z.useState(""),[o,f]=Z.useState(5),[h,p]=Z.useState(!1),[b,v]=Z.useState(!1),[E,_]=Z.useState(""),[S,P]=Z.useState(!1),[I,C]=Z.useState(!1),T=H2({onDropdownClose:()=>T.resetSelectedOption()}),[B,N]=Z.useState("0x0000000000000000000000000000000000000000"),[$,H]=Z.useState(0),J=yu(o,B),Q=PK(o).map(w=>ce.jsx(kt.Option,{value:w.value,children:ce.jsx(K,{...w})},w.value));function K({image:w,label:a}){return ce.jsxs(Tf,{style:{width:"100%"},children:[ce.jsx(kf,{src:w,children:ce.jsx(O9,{size:"1.5rem"})}),ce.jsx("div",{children:ce.jsx(Fu,{fz:"sm",fw:500,children:a})})]})}const se=async()=>{var w;P(!0);try{const a=await aAe(B,r),u=(w=new URLSearchParams(a))==null?void 0:w.toString(),l=`${window.location.href}#/claim?${u}`;console.log("url",l),_(l),p(!1),P(!1),_(l)}catch{P(!1),C(!0)}p(!0)};return Z.useEffect(()=>{(async()=>{var u;const w=await I1(),a=(await w.getNetwork()).chainId;f(Number(a)),i(`${(u=Yr.getNetworkById(Number(a)))==null?void 0:u.name}`);try{const l=await Ow();B==To?H(Dl(await w.getBalance(l==null?void 0:l.safeAddress))):H(await vK(B,l==null?void 0:l.safeAddress,w))}catch{console.log("No safe found")}})()},[B]),ce.jsx(ce.Fragment,{children:E.length>0?ce.jsxs(ce.Fragment,{children:[ce.jsx(MK,{width:2e3,height:1200}),ce.jsx("div",{className:Hr.successContainer,children:ce.jsxs(zf,{className:Hr.formContainer,shadow:"md",withBorder:!0,radius:"md",children:[ce.jsx("h1",{className:Hr.heading,children:"Link is Ready!"}),ce.jsx("p",{className:Hr.subheading,style:{textAlign:"center"},children:"Safeguard this link and share it with those you trust to spread the crypto love ❤️ ❤️"}),ce.jsx("div",{className:Hr.copyContainer,children:ce.jsx(Tr,{className:Hr.input,value:E,placeholder:E})}),ce.jsxs("div",{className:Hr.actions,children:[ce.jsx(Ii,{size:"lg",radius:"md",onClick:()=>_(""),style:{width:"180px"},color:e?"#49494f":"#c3c3c3",variant:"filled",children:"Create New"}),ce.jsx(CAe.CopyToClipboard,{text:E,onCopy:()=>v(!0),children:ce.jsx(Ii,{size:"lg",radius:"md",style:{width:"180px"},color:"teal",children:b?"Link Copied":"Copy Link"})})]})]})})]}):ce.jsxs(ce.Fragment,{children:[ce.jsxs("div",{children:[ce.jsxs("h1",{className:Hr.heading,children:["Share crypto from your",ce.jsx("div",{className:Hr.safeContainer,children:ce.jsx("img",{className:Hr.safe,src:x8e,alt:"avatar"})})]}),ce.jsx("h1",{className:Hr.links,children:"via links 🔗"})]}),ce.jsx("div",{className:Hr.homeContainer,children:ce.jsxs(zf,{className:Hr.formContainer,shadow:"md",withBorder:!0,radius:"md",p:"xl",children:[!Object.keys(kc).includes(o.toString())&&ce.jsxs(ap,{variant:"light",color:"yellow",radius:"lg",title:"Unsupported Network",children:["Safe2Link is supports only these networks as of now ",ce.jsxs("b",{children:[" : ",ce.jsx("br",{})," ",Object.keys(kc).map(w=>{var a,u;return`${(a=Yr.getNetworkById(Number(w)))==null?void 0:a.name} ${(u=Yr.getNetworkById(Number(w)))==null?void 0:u.type}, `})," "]})]}),I&&ce.jsxs(ap,{variant:"light",color:"yellow",radius:"lg",title:"Open as Safe App",children:["Try this application as a ",ce.jsx("span",{}),ce.jsx(lg,{href:"https://app.safe.global/share/safe-app?appUrl=https://safe2link.xyz&chain=sep",children:"Safe App"})," ",ce.jsx("span",{}),"on Safe Wallet."]}),ce.jsxs("div",{className:Hr.inputContainer,children:[ce.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",marginBottom:"20px",alignItems:"center"},children:[ce.jsxs(kt,{store:T,withinPortal:!1,onOptionSubmit:w=>{N(w),T.closeDropdown()},children:[ce.jsx(kt.Target,{children:ce.jsx(U5,{style:{width:"50%"},component:"button",type:"button",pointer:!0,rightSection:ce.jsx(kt.Chevron,{}),onClick:()=>T.toggleDropdown(),rightSectionPointerEvents:"none",multiline:!0,children:J?ce.jsx(K,{...J}):ce.jsx(Tr.Placeholder,{children:"Pick value"})})}),ce.jsx(kt.Dropdown,{children:ce.jsx(kt.Options,{children:Q})})]}),ce.jsx(j5,{pl:0,color:"gray",variant:"light",leftSection:ce.jsx(kf,{alt:"Avatar for badge",size:24,mr:5,src:u2(o)}),size:"lg",className:Hr.network,children:s})]}),ce.jsx(Tr.Wrapper,{label:`Enter Value (Balance: ${$})`,children:ce.jsx(Tr,{type:"number",size:"lg",value:r,onChange:w=>{var a;return n((a=w==null?void 0:w.target)==null?void 0:a.value)},placeholder:"enter the value",className:Hr.input})})]}),ce.jsx(Ii,{size:"lg",radius:"md",fullWidth:!0,color:"green",className:Hr.btn,onClick:se,loaderProps:{color:"white",type:"dots",size:"md"},loading:S,children:S?"Creating Link ...":"Create Link"}),ce.jsx("p",{className:Hr.subHeading,children:"Just select the amount and asset to create a payment link 🔗 . The funds won't leave your account untill claimed ✨"})]})}),ce.jsxs("div",{className:Hr.avatarContainer,children:[ce.jsx(lg,{href:"https://x.com/rajkoshik/status/1734166408794394693?s=20",target:"_blank",children:ce.jsx("img",{className:Hr.avatar,src:v8e,alt:"avatar",height:100,width:100})}),ce.jsxs(Tf,{className:Hr.mode,children:[ce.jsx(zAe,{size:30,stroke:1.5,onClick:()=>window.open("https://x.com/safe2link"),style:{cursor:"pointer"}}),ce.jsx(Zie,{size:30,stroke:1.5,onClick:()=>window.open("https://github.com/koshikraj/safe2link"),style:{cursor:"pointer"}})]})]})]})})}const HAe="_homeContainer_yxegy_3",qAe="_formContainer_yxegy_15",GAe="_claimContainer_yxegy_23",VAe="_links_yxegy_35",KAe="_claimHeading_yxegy_43",WAe="_claimInner_yxegy_56",JAe="_heading_yxegy_73",ZAe="_subHeading_yxegy_84",QAe="_footerHeading_yxegy_90",YAe="_loader_yxegy_95",XAe="_btn_yxegy_101",eEe="_input_yxegy_115",tEe="_inputContainer_yxegy_120",rEe="_accountInputContainer_yxegy_130",dn={homeContainer:HAe,formContainer:qAe,claimContainer:GAe,links:VAe,claimHeading:KAe,claimInner:WAe,heading:JAe,subHeading:ZAe,footerHeading:QAe,loader:YAe,btn:XAe,input:eEe,inputContainer:tEe,accountInputContainer:rEe};function LK(t,e){return function(){return t.apply(e,arguments)}}const{toString:nEe}=Object.prototype,{getPrototypeOf:vP}=Object,jw=(t=>e=>{const r=nEe.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Ga=t=>(t=t.toLowerCase(),e=>jw(e)===t),Hw=t=>e=>typeof e===t,{isArray:k1}=Array,Ug=Hw("undefined");function iEe(t){return t!==null&&!Ug(t)&&t.constructor!==null&&!Ug(t.constructor)&&$s(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const DK=Ga("ArrayBuffer");function sEe(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&DK(t.buffer),e}const oEe=Hw("string"),$s=Hw("function"),$K=Hw("number"),qw=t=>t!==null&&typeof t=="object",aEe=t=>t===!0||t===!1,l2=t=>{if(jw(t)!=="object")return!1;const e=vP(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},fEe=Ga("Date"),cEe=Ga("File"),uEe=Ga("Blob"),lEe=Ga("FileList"),hEe=t=>qw(t)&&$s(t.pipe),dEe=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||$s(t.append)&&((e=jw(t))==="formdata"||e==="object"&&$s(t.toString)&&t.toString()==="[object FormData]"))},pEe=Ga("URLSearchParams"),mEe=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function lb(t,e,{allOwnKeys:r=!1}={}){if(t===null||typeof t>"u")return;let n,s;if(typeof t!="object"&&(t=[t]),k1(t))for(n=0,s=t.length;n0;)if(s=r[n],e===s.toLowerCase())return s;return null}const UK=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:Ve.global)(),zK=t=>!Ug(t)&&t!==UK;function gA(){const{caseless:t}=zK(this)&&this||{},e={},r=(n,s)=>{const i=t&&FK(e,s)||s;l2(e[i])&&l2(n)?e[i]=gA(e[i],n):l2(n)?e[i]=gA({},n):k1(n)?e[i]=n.slice():e[i]=n};for(let n=0,s=arguments.length;n(lb(e,(s,i)=>{r&&$s(s)?t[i]=LK(s,r):t[i]=s},{allOwnKeys:n}),t),yEe=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),bEe=(t,e,r,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),r&&Object.assign(t.prototype,r)},vEe=(t,e,r,n)=>{let s,i,o;const f={};if(e=e||{},t==null)return e;do{for(s=Object.getOwnPropertyNames(t),i=s.length;i-- >0;)o=s[i],(!n||n(o,t,e))&&!f[o]&&(e[o]=t[o],f[o]=!0);t=r!==!1&&vP(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},xEe=(t,e,r)=>{t=String(t),(r===void 0||r>t.length)&&(r=t.length),r-=e.length;const n=t.indexOf(e,r);return n!==-1&&n===r},wEe=t=>{if(!t)return null;if(k1(t))return t;let e=t.length;if(!$K(e))return null;const r=new Array(e);for(;e-- >0;)r[e]=t[e];return r},AEe=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&vP(Uint8Array)),EEe=(t,e)=>{const n=(t&&t[Symbol.iterator]).call(t);let s;for(;(s=n.next())&&!s.done;){const i=s.value;e.call(t,i[0],i[1])}},MEe=(t,e)=>{let r;const n=[];for(;(r=t.exec(e))!==null;)n.push(r);return n},SEe=Ga("HTMLFormElement"),_Ee=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,s){return n.toUpperCase()+s}),FB=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),PEe=Ga("RegExp"),jK=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};lb(r,(s,i)=>{e(s,i,t)!==!1&&(n[i]=s)}),Object.defineProperties(t,n)},CEe=t=>{jK(t,(e,r)=>{if($s(t)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=t[r];if($s(n)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},IEe=(t,e)=>{const r={},n=s=>{s.forEach(i=>{r[i]=!0})};return k1(t)?n(t):n(String(t).split(e)),r},TEe=()=>{},kEe=(t,e)=>(t=+t,Number.isFinite(t)?t:e),m4="abcdefghijklmnopqrstuvwxyz",UB="0123456789",HK={DIGIT:UB,ALPHA:m4,ALPHA_DIGIT:m4+m4.toUpperCase()+UB},REe=(t=16,e=HK.ALPHA_DIGIT)=>{let r="";const{length:n}=e;for(;t--;)r+=e[Math.random()*n|0];return r};function BEe(t){return!!(t&&$s(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const OEe=t=>{const e=new Array(10),r=(n,s)=>{if(qw(n)){if(e.indexOf(n)>=0)return;if(!("toJSON"in n)){e[s]=n;const i=k1(n)?[]:{};return lb(n,(o,f)=>{const h=r(o,s+1);!Ug(h)&&(i[f]=h)}),e[s]=void 0,i}}return n};return r(t,0)},NEe=Ga("AsyncFunction"),LEe=t=>t&&(qw(t)||$s(t))&&$s(t.then)&&$s(t.catch),ze={isArray:k1,isArrayBuffer:DK,isBuffer:iEe,isFormData:dEe,isArrayBufferView:sEe,isString:oEe,isNumber:$K,isBoolean:aEe,isObject:qw,isPlainObject:l2,isUndefined:Ug,isDate:fEe,isFile:cEe,isBlob:uEe,isRegExp:PEe,isFunction:$s,isStream:hEe,isURLSearchParams:pEe,isTypedArray:AEe,isFileList:lEe,forEach:lb,merge:gA,extend:gEe,trim:mEe,stripBOM:yEe,inherits:bEe,toFlatObject:vEe,kindOf:jw,kindOfTest:Ga,endsWith:xEe,toArray:wEe,forEachEntry:EEe,matchAll:MEe,isHTMLForm:SEe,hasOwnProperty:FB,hasOwnProp:FB,reduceDescriptors:jK,freezeMethods:CEe,toObjectSet:IEe,toCamelCase:_Ee,noop:TEe,toFiniteNumber:kEe,findKey:FK,global:UK,isContextDefined:zK,ALPHABET:HK,generateString:REe,isSpecCompliantForm:BEe,toJSONObject:OEe,isAsyncFn:NEe,isThenable:LEe};function Ut(t,e,r,n,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),r&&(this.config=r),n&&(this.request=n),s&&(this.response=s)}ze.inherits(Ut,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ze.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const qK=Ut.prototype,GK={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{GK[t]={value:t}});Object.defineProperties(Ut,GK);Object.defineProperty(qK,"isAxiosError",{value:!0});Ut.from=(t,e,r,n,s,i)=>{const o=Object.create(qK);return ze.toFlatObject(t,o,function(h){return h!==Error.prototype},f=>f!=="isAxiosError"),Ut.call(o,t.message,e,r,n,s),o.cause=t,o.name=t.name,i&&Object.assign(o,i),o};const DEe=null;function yA(t){return ze.isPlainObject(t)||ze.isArray(t)}function VK(t){return ze.endsWith(t,"[]")?t.slice(0,-2):t}function zB(t,e,r){return t?t.concat(e).map(function(s,i){return s=VK(s),!r&&i?"["+s+"]":s}).join(r?".":""):e}function $Ee(t){return ze.isArray(t)&&!t.some(yA)}const FEe=ze.toFlatObject(ze,{},null,function(e){return/^is[A-Z]/.test(e)});function Gw(t,e,r){if(!ze.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,r=ze.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(P,I){return!ze.isUndefined(I[P])});const n=r.metaTokens,s=r.visitor||b,i=r.dots,o=r.indexes,h=(r.Blob||typeof Blob<"u"&&Blob)&&ze.isSpecCompliantForm(e);if(!ze.isFunction(s))throw new TypeError("visitor must be a function");function p(S){if(S===null)return"";if(ze.isDate(S))return S.toISOString();if(!h&&ze.isBlob(S))throw new Ut("Blob is not supported. Use a Buffer instead.");return ze.isArrayBuffer(S)||ze.isTypedArray(S)?h&&typeof Blob=="function"?new Blob([S]):Ve.Buffer.from(S):S}function b(S,P,I){let C=S;if(S&&!I&&typeof S=="object"){if(ze.endsWith(P,"{}"))P=n?P:P.slice(0,-2),S=JSON.stringify(S);else if(ze.isArray(S)&&$Ee(S)||(ze.isFileList(S)||ze.endsWith(P,"[]"))&&(C=ze.toArray(S)))return P=VK(P),C.forEach(function(B,N){!(ze.isUndefined(B)||B===null)&&e.append(o===!0?zB([P],N,i):o===null?P:P+"[]",p(B))}),!1}return yA(S)?!0:(e.append(zB(I,P,i),p(S)),!1)}const v=[],E=Object.assign(FEe,{defaultVisitor:b,convertValue:p,isVisitable:yA});function _(S,P){if(!ze.isUndefined(S)){if(v.indexOf(S)!==-1)throw Error("Circular reference detected in "+P.join("."));v.push(S),ze.forEach(S,function(C,T){(!(ze.isUndefined(C)||C===null)&&s.call(e,C,ze.isString(T)?T.trim():T,P,E))===!0&&_(C,P?P.concat(T):[T])}),v.pop()}}if(!ze.isObject(t))throw new TypeError("data must be an object");return _(t),e}function jB(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function xP(t,e){this._pairs=[],t&&Gw(t,this,e)}const KK=xP.prototype;KK.append=function(e,r){this._pairs.push([e,r])};KK.toString=function(e){const r=e?function(n){return e.call(this,n,jB)}:jB;return this._pairs.map(function(s){return r(s[0])+"="+r(s[1])},"").join("&")};function UEe(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function WK(t,e,r){if(!e)return t;const n=r&&r.encode||UEe,s=r&&r.serialize;let i;if(s?i=s(e,r):i=ze.isURLSearchParams(e)?e.toString():new xP(e,r).toString(n),i){const o=t.indexOf("#");o!==-1&&(t=t.slice(0,o)),t+=(t.indexOf("?")===-1?"?":"&")+i}return t}class zEe{constructor(){this.handlers=[]}use(e,r,n){return this.handlers.push({fulfilled:e,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){ze.forEach(this.handlers,function(n){n!==null&&e(n)})}}const HB=zEe,JK={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},jEe=typeof URLSearchParams<"u"?URLSearchParams:xP,HEe=typeof FormData<"u"?FormData:null,qEe=typeof Blob<"u"?Blob:null,GEe=(()=>{let t;return typeof navigator<"u"&&((t=navigator.product)==="ReactNative"||t==="NativeScript"||t==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),VEe=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),_a={isBrowser:!0,classes:{URLSearchParams:jEe,FormData:HEe,Blob:qEe},isStandardBrowserEnv:GEe,isStandardBrowserWebWorkerEnv:VEe,protocols:["http","https","file","blob","url","data"]};function KEe(t,e){return Gw(t,new _a.classes.URLSearchParams,Object.assign({visitor:function(r,n,s,i){return _a.isNode&&ze.isBuffer(r)?(this.append(n,r.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},e))}function WEe(t){return ze.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function JEe(t){const e={},r=Object.keys(t);let n;const s=r.length;let i;for(n=0;n=r.length;return o=!o&&ze.isArray(s)?s.length:o,h?(ze.hasOwnProp(s,o)?s[o]=[s[o],n]:s[o]=n,!f):((!s[o]||!ze.isObject(s[o]))&&(s[o]=[]),e(r,n,s[o],i)&&ze.isArray(s[o])&&(s[o]=JEe(s[o])),!f)}if(ze.isFormData(t)&&ze.isFunction(t.entries)){const r={};return ze.forEachEntry(t,(n,s)=>{e(WEe(n),s,r,0)}),r}return null}const ZEe={"Content-Type":void 0};function QEe(t,e,r){if(ze.isString(t))try{return(e||JSON.parse)(t),ze.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}const Vw={transitional:JK,adapter:["xhr","http"],transformRequest:[function(e,r){const n=r.getContentType()||"",s=n.indexOf("application/json")>-1,i=ze.isObject(e);if(i&&ze.isHTMLForm(e)&&(e=new FormData(e)),ze.isFormData(e))return s&&s?JSON.stringify(ZK(e)):e;if(ze.isArrayBuffer(e)||ze.isBuffer(e)||ze.isStream(e)||ze.isFile(e)||ze.isBlob(e))return e;if(ze.isArrayBufferView(e))return e.buffer;if(ze.isURLSearchParams(e))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let f;if(i){if(n.indexOf("application/x-www-form-urlencoded")>-1)return KEe(e,this.formSerializer).toString();if((f=ze.isFileList(e))||n.indexOf("multipart/form-data")>-1){const h=this.env&&this.env.FormData;return Gw(f?{"files[]":e}:e,h&&new h,this.formSerializer)}}return i||s?(r.setContentType("application/json",!1),QEe(e)):e}],transformResponse:[function(e){const r=this.transitional||Vw.transitional,n=r&&r.forcedJSONParsing,s=this.responseType==="json";if(e&&ze.isString(e)&&(n&&!this.responseType||s)){const o=!(r&&r.silentJSONParsing)&&s;try{return JSON.parse(e)}catch(f){if(o)throw f.name==="SyntaxError"?Ut.from(f,Ut.ERR_BAD_RESPONSE,this,null,this.response):f}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:_a.classes.FormData,Blob:_a.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};ze.forEach(["delete","get","head"],function(e){Vw.headers[e]={}});ze.forEach(["post","put","patch"],function(e){Vw.headers[e]=ze.merge(ZEe)});const wP=Vw,YEe=ze.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),XEe=t=>{const e={};let r,n,s;return t&&t.split(` -`).forEach(function(o){s=o.indexOf(":"),r=o.substring(0,s).trim().toLowerCase(),n=o.substring(s+1).trim(),!(!r||e[r]&&YEe[r])&&(r==="set-cookie"?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)}),e},qB=Symbol("internals");function fm(t){return t&&String(t).trim().toLowerCase()}function h2(t){return t===!1||t==null?t:ze.isArray(t)?t.map(h2):String(t)}function eMe(t){const e=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(t);)e[n[1]]=n[2];return e}const tMe=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function g4(t,e,r,n,s){if(ze.isFunction(n))return n.call(this,e,r);if(s&&(e=r),!!ze.isString(e)){if(ze.isString(n))return e.indexOf(n)!==-1;if(ze.isRegExp(n))return n.test(e)}}function rMe(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,r,n)=>r.toUpperCase()+n)}function nMe(t,e){const r=ze.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(s,i,o){return this[n].call(this,e,s,i,o)},configurable:!0})})}class Kw{constructor(e){e&&this.set(e)}set(e,r,n){const s=this;function i(f,h,p){const b=fm(h);if(!b)throw new Error("header name must be a non-empty string");const v=ze.findKey(s,b);(!v||s[v]===void 0||p===!0||p===void 0&&s[v]!==!1)&&(s[v||h]=h2(f))}const o=(f,h)=>ze.forEach(f,(p,b)=>i(p,b,h));return ze.isPlainObject(e)||e instanceof this.constructor?o(e,r):ze.isString(e)&&(e=e.trim())&&!tMe(e)?o(XEe(e),r):e!=null&&i(r,e,n),this}get(e,r){if(e=fm(e),e){const n=ze.findKey(this,e);if(n){const s=this[n];if(!r)return s;if(r===!0)return eMe(s);if(ze.isFunction(r))return r.call(this,s,n);if(ze.isRegExp(r))return r.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,r){if(e=fm(e),e){const n=ze.findKey(this,e);return!!(n&&this[n]!==void 0&&(!r||g4(this,this[n],n,r)))}return!1}delete(e,r){const n=this;let s=!1;function i(o){if(o=fm(o),o){const f=ze.findKey(n,o);f&&(!r||g4(n,n[f],f,r))&&(delete n[f],s=!0)}}return ze.isArray(e)?e.forEach(i):i(e),s}clear(e){const r=Object.keys(this);let n=r.length,s=!1;for(;n--;){const i=r[n];(!e||g4(this,this[i],i,e,!0))&&(delete this[i],s=!0)}return s}normalize(e){const r=this,n={};return ze.forEach(this,(s,i)=>{const o=ze.findKey(n,i);if(o){r[o]=h2(s),delete r[i];return}const f=e?rMe(i):String(i).trim();f!==i&&delete r[i],r[f]=h2(s),n[f]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const r=Object.create(null);return ze.forEach(this,(n,s)=>{n!=null&&n!==!1&&(r[s]=e&&ze.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,r])=>e+": "+r).join(` -`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...r){const n=new this(e);return r.forEach(s=>n.set(s)),n}static accessor(e){const n=(this[qB]=this[qB]={accessors:{}}).accessors,s=this.prototype;function i(o){const f=fm(o);n[f]||(nMe(s,o),n[f]=!0)}return ze.isArray(e)?e.forEach(i):i(e),this}}Kw.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ze.freezeMethods(Kw.prototype);ze.freezeMethods(Kw);const Nf=Kw;function y4(t,e){const r=this||wP,n=e||r,s=Nf.from(n.headers);let i=n.data;return ze.forEach(t,function(f){i=f.call(r,i,s.normalize(),e?e.status:void 0)}),s.normalize(),i}function QK(t){return!!(t&&t.__CANCEL__)}function hb(t,e,r){Ut.call(this,t??"canceled",Ut.ERR_CANCELED,e,r),this.name="CanceledError"}ze.inherits(hb,Ut,{__CANCEL__:!0});function iMe(t,e,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?t(r):e(new Ut("Request failed with status code "+r.status,[Ut.ERR_BAD_REQUEST,Ut.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}const sMe=_a.isStandardBrowserEnv?function(){return{write:function(r,n,s,i,o,f){const h=[];h.push(r+"="+encodeURIComponent(n)),ze.isNumber(s)&&h.push("expires="+new Date(s).toGMTString()),ze.isString(i)&&h.push("path="+i),ze.isString(o)&&h.push("domain="+o),f===!0&&h.push("secure"),document.cookie=h.join("; ")},read:function(r){const n=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function oMe(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function aMe(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}function YK(t,e){return t&&!oMe(e)?aMe(t,e):e}const fMe=_a.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");let n;function s(i){let o=i;return e&&(r.setAttribute("href",o),o=r.href),r.setAttribute("href",o),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=s(window.location.href),function(o){const f=ze.isString(o)?s(o):o;return f.protocol===n.protocol&&f.host===n.host}}():function(){return function(){return!0}}();function cMe(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function uMe(t,e){t=t||10;const r=new Array(t),n=new Array(t);let s=0,i=0,o;return e=e!==void 0?e:1e3,function(h){const p=Date.now(),b=n[i];o||(o=p),r[s]=h,n[s]=p;let v=i,E=0;for(;v!==s;)E+=r[v++],v=v%t;if(s=(s+1)%t,s===i&&(i=(i+1)%t),p-o{const i=s.loaded,o=s.lengthComputable?s.total:void 0,f=i-r,h=n(f),p=i<=o;r=i;const b={loaded:i,total:o,progress:o?i/o:void 0,bytes:f,rate:h||void 0,estimated:h&&o&&p?(o-i)/h:void 0,event:s};b[e?"download":"upload"]=!0,t(b)}}const lMe=typeof XMLHttpRequest<"u",hMe=lMe&&function(t){return new Promise(function(r,n){let s=t.data;const i=Nf.from(t.headers).normalize(),o=t.responseType;let f;function h(){t.cancelToken&&t.cancelToken.unsubscribe(f),t.signal&&t.signal.removeEventListener("abort",f)}ze.isFormData(s)&&(_a.isStandardBrowserEnv||_a.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.setContentType("multipart/form-data;",!1));let p=new XMLHttpRequest;if(t.auth){const _=t.auth.username||"",S=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";i.set("Authorization","Basic "+btoa(_+":"+S))}const b=YK(t.baseURL,t.url);p.open(t.method.toUpperCase(),WK(b,t.params,t.paramsSerializer),!0),p.timeout=t.timeout;function v(){if(!p)return;const _=Nf.from("getAllResponseHeaders"in p&&p.getAllResponseHeaders()),P={data:!o||o==="text"||o==="json"?p.responseText:p.response,status:p.status,statusText:p.statusText,headers:_,config:t,request:p};iMe(function(C){r(C),h()},function(C){n(C),h()},P),p=null}if("onloadend"in p?p.onloadend=v:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(v)},p.onabort=function(){p&&(n(new Ut("Request aborted",Ut.ECONNABORTED,t,p)),p=null)},p.onerror=function(){n(new Ut("Network Error",Ut.ERR_NETWORK,t,p)),p=null},p.ontimeout=function(){let S=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";const P=t.transitional||JK;t.timeoutErrorMessage&&(S=t.timeoutErrorMessage),n(new Ut(S,P.clarifyTimeoutError?Ut.ETIMEDOUT:Ut.ECONNABORTED,t,p)),p=null},_a.isStandardBrowserEnv){const _=(t.withCredentials||fMe(b))&&t.xsrfCookieName&&sMe.read(t.xsrfCookieName);_&&i.set(t.xsrfHeaderName,_)}s===void 0&&i.setContentType(null),"setRequestHeader"in p&&ze.forEach(i.toJSON(),function(S,P){p.setRequestHeader(P,S)}),ze.isUndefined(t.withCredentials)||(p.withCredentials=!!t.withCredentials),o&&o!=="json"&&(p.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&p.addEventListener("progress",GB(t.onDownloadProgress,!0)),typeof t.onUploadProgress=="function"&&p.upload&&p.upload.addEventListener("progress",GB(t.onUploadProgress)),(t.cancelToken||t.signal)&&(f=_=>{p&&(n(!_||_.type?new hb(null,t,p):_),p.abort(),p=null)},t.cancelToken&&t.cancelToken.subscribe(f),t.signal&&(t.signal.aborted?f():t.signal.addEventListener("abort",f)));const E=cMe(b);if(E&&_a.protocols.indexOf(E)===-1){n(new Ut("Unsupported protocol "+E+":",Ut.ERR_BAD_REQUEST,t));return}p.send(s||null)})},d2={http:DEe,xhr:hMe};ze.forEach(d2,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const dMe={getAdapter:t=>{t=ze.isArray(t)?t:[t];const{length:e}=t;let r,n;for(let s=0;st instanceof Nf?t.toJSON():t;function Qp(t,e){e=e||{};const r={};function n(p,b,v){return ze.isPlainObject(p)&&ze.isPlainObject(b)?ze.merge.call({caseless:v},p,b):ze.isPlainObject(b)?ze.merge({},b):ze.isArray(b)?b.slice():b}function s(p,b,v){if(ze.isUndefined(b)){if(!ze.isUndefined(p))return n(void 0,p,v)}else return n(p,b,v)}function i(p,b){if(!ze.isUndefined(b))return n(void 0,b)}function o(p,b){if(ze.isUndefined(b)){if(!ze.isUndefined(p))return n(void 0,p)}else return n(void 0,b)}function f(p,b,v){if(v in e)return n(p,b);if(v in t)return n(void 0,p)}const h={url:i,method:i,data:i,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:f,headers:(p,b)=>s(KB(p),KB(b),!0)};return ze.forEach(Object.keys(Object.assign({},t,e)),function(b){const v=h[b]||s,E=v(t[b],e[b],b);ze.isUndefined(E)&&v!==f||(r[b]=E)}),r}const XK="1.4.0",AP={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{AP[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const WB={};AP.transitional=function(e,r,n){function s(i,o){return"[Axios v"+XK+"] Transitional option '"+i+"'"+o+(n?". "+n:"")}return(i,o,f)=>{if(e===!1)throw new Ut(s(o," has been removed"+(r?" in "+r:"")),Ut.ERR_DEPRECATED);return r&&!WB[o]&&(WB[o]=!0,console.warn(s(o," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(i,o,f):!0}};function pMe(t,e,r){if(typeof t!="object")throw new Ut("options must be an object",Ut.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let s=n.length;for(;s-- >0;){const i=n[s],o=e[i];if(o){const f=t[i],h=f===void 0||o(f,i,t);if(h!==!0)throw new Ut("option "+i+" must be "+h,Ut.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Ut("Unknown option "+i,Ut.ERR_BAD_OPTION)}}const bA={assertOptions:pMe,validators:AP},v0=bA.validators;class n5{constructor(e){this.defaults=e,this.interceptors={request:new HB,response:new HB}}request(e,r){typeof e=="string"?(r=r||{},r.url=e):r=e||{},r=Qp(this.defaults,r);const{transitional:n,paramsSerializer:s,headers:i}=r;n!==void 0&&bA.assertOptions(n,{silentJSONParsing:v0.transitional(v0.boolean),forcedJSONParsing:v0.transitional(v0.boolean),clarifyTimeoutError:v0.transitional(v0.boolean)},!1),s!=null&&(ze.isFunction(s)?r.paramsSerializer={serialize:s}:bA.assertOptions(s,{encode:v0.function,serialize:v0.function},!0)),r.method=(r.method||this.defaults.method||"get").toLowerCase();let o;o=i&&ze.merge(i.common,i[r.method]),o&&ze.forEach(["delete","get","head","post","put","patch","common"],S=>{delete i[S]}),r.headers=Nf.concat(o,i);const f=[];let h=!0;this.interceptors.request.forEach(function(P){typeof P.runWhen=="function"&&P.runWhen(r)===!1||(h=h&&P.synchronous,f.unshift(P.fulfilled,P.rejected))});const p=[];this.interceptors.response.forEach(function(P){p.push(P.fulfilled,P.rejected)});let b,v=0,E;if(!h){const S=[VB.bind(this),void 0];for(S.unshift.apply(S,f),S.push.apply(S,p),E=S.length,b=Promise.resolve(r);v{if(!n._listeners)return;let i=n._listeners.length;for(;i-- >0;)n._listeners[i](s);n._listeners=null}),this.promise.then=s=>{let i;const o=new Promise(f=>{n.subscribe(f),i=f}).then(s);return o.cancel=function(){n.unsubscribe(i)},o},e(function(i,o,f){n.reason||(n.reason=new hb(i,o,f),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const r=this._listeners.indexOf(e);r!==-1&&this._listeners.splice(r,1)}static source(){let e;return{token:new EP(function(s){e=s}),cancel:e}}}const mMe=EP;function gMe(t){return function(r){return t.apply(null,r)}}function yMe(t){return ze.isObject(t)&&t.isAxiosError===!0}const vA={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(vA).forEach(([t,e])=>{vA[e]=t});const bMe=vA;function eW(t){const e=new p2(t),r=LK(p2.prototype.request,e);return ze.extend(r,p2.prototype,e,{allOwnKeys:!0}),ze.extend(r,e,null,{allOwnKeys:!0}),r.create=function(s){return eW(Qp(t,s))},r}const ln=eW(wP);ln.Axios=p2;ln.CanceledError=hb;ln.CancelToken=mMe;ln.isCancel=QK;ln.VERSION=XK;ln.toFormData=Gw;ln.AxiosError=Ut;ln.Cancel=ln.CanceledError;ln.all=function(e){return Promise.all(e)};ln.spread=gMe;ln.isAxiosError=yMe;ln.mergeConfig=Qp;ln.AxiosHeaders=Nf;ln.formToJSON=t=>ZK(ze.isHTMLForm(t)?new FormData(t):t);ln.HttpStatusCode=bMe;ln.default=ln;const vMe=ln,xMe="m/44'/60'/0'/0/0";async function xA(){try{const t=await yK.stampGetWhoami({organizationId:"be67a3da-0512-40f8-a025-cb518d83c655"}),r=(await vMe.post(t.url,t.body,{headers:{[t.stamp.stampHeaderName]:t.stamp.stampHeaderValue}})).data.organizationId,n=new pK({apiPublicKey:"0301cb31eadda1532da75c9dbfee121a2f91ea6e3e4f7f7470fa5ae44e8ce3d468",apiPrivateKey:"779dab5bd0e62af43716e370d31f9a5c1b4284bd8068f9239ab28c80fdb74d42"}),s=new Uw({baseUrl:"https://api.turnkey.com"},n),i=await s.getWallets({organizationId:r}),o=await s.getWalletAccounts({organizationId:r,walletId:i.wallets[0].walletId}),f=o.accounts[0].walletId,h=o.accounts[0].address;return{id:f,address:h,subOrgId:r,balance:Dl(0n)}}catch(t){console.error(t)}}async function tW(t){var r,n;const e=t;try{const s=kB(),i=kB(),o=await P7e({publicKey:{rp:{id:{}.NEXT_PUBLIC_RPID,name:"Turnkey Viem Passkey Demo"},challenge:s,pubKeyCredParams:[{type:"public-key",alg:-7},{type:"public-key",alg:-257}],user:{id:i,name:e.split(" ").join("-"),displayName:e},authenticatorSelection:{requireResidentKey:!0}}}),f=new Uw({baseUrl:"https://api.turnkey.com"},new pK({apiPublicKey:"0301cb31eadda1532da75c9dbfee121a2f91ea6e3e4f7f7470fa5ae44e8ce3d468",apiPrivateKey:"779dab5bd0e62af43716e370d31f9a5c1b4284bd8068f9239ab28c80fdb74d42"})),h=k7e({client:f,requestFn:f.createSubOrganization}),p="Default ETH Wallet",b=await h({type:"ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V4",timestampMs:String(Date.now()),organizationId:"be67a3da-0512-40f8-a025-cb518d83c655",parameters:{subOrganizationName:e,rootQuorumThreshold:1,rootUsers:[{userName:"New user",apiKeys:[],authenticators:[{authenticatorName:"Passkey",challenge:Y7e(s),attestation:o}]}],wallet:{walletName:p,accounts:[{curve:"CURVE_SECP256K1",pathFormat:"PATH_FORMAT_BIP32",path:xMe,addressFormat:"ADDRESS_FORMAT_ETHEREUM"}]}}}),v=TB((r=b.result.createSubOrganizationResultV4)==null?void 0:r.subOrganizationId),E=TB((n=b.result.createSubOrganizationResultV4)==null?void 0:n.wallet),_=E.walletId,S=E.addresses[0],P=bK(5);return{id:_,address:S,subOrgId:v,balance:Dl(0n)}}catch(s){console.error(s)}}const wMe=new gK({rpId:{}.NEXT_PUBLIC_RPID});new Uw({baseUrl:"https://api.turnkey.com"},wMe);function AMe(){var H,J;const[t,{open:e,close:r}]=ME(!1),n=C$(),[s,i]=Z.useState(),[o,f]=Z.useState({}),[h,p]=Z.useState(!0),[b,v]=Z.useState(""),[E,_]=Z.useState(""),[S,P]=Z.useState(""),{confirming:I,setConfirming:C,setConfirmed:T,setClaimDetails:B,claimDetails:N}=bM(Q=>Q);console.log(o);function $(Q){const K=Q.split("?")[1];if(!K)return null;const se=new URLSearchParams(K),w={};for(const[a,u]of se.entries())w[a]=u;return w}return Z.useEffect(()=>{(async()=>{var K,se;const Q=$(window.location.href);i(Q);try{let{claimed:w,amount:a,tokenAddress:u}=await tAe(Q.c,Q.i);const l=await bl(Q.c);u==To?a=H$(a):a=CM(a,await yP(u,l)),f({claimed:w,amount:a,token:u,chainId:Q.c}),_(`${(K=Yr.getNetworkById(Number(Q.c)))==null?void 0:K.name} ${(se=Yr.getNetworkById(Number(Q.c)))==null?void 0:se.type}`)}catch{p(!1)}p(!1)})()},[]),ce.jsxs(ce.Fragment,{children:[ce.jsxs(js,{opened:t,onClose:r,title:"Claim via Safe Account",centered:!0,children:[ce.jsx(gM,{visible:I,zIndex:1e3,overlayProps:{radius:"sm",blur:2},loaderProps:{color:"green",children:ce.jsxs(zf,{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",backgroundColor:"inherit",padding:"20px"},children:[ce.jsxs("p",{className:dn.loader,children:[S,"."]}),ce.jsx("p",{className:dn.subHeading,children:" Buckle up! Our digital hamsters are on their morning jog—this'll be quicker than a cat video. 🏃‍♂️💨"}),ce.jsx(_l,{color:"green",type:"dots",size:"xl"})," "]})}}),ce.jsxs("div",{className:dn.formContainer,children:[ce.jsx("div",{children:ce.jsx("h1",{className:dn.heading,children:"Claim in one click with PassKey"})}),ce.jsx("p",{className:dn.subHeading,children:"First time at Safe2Link?"}),ce.jsxs("div",{className:dn.accountInputContainer,children:[ce.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",marginBottom:"20px",alignItems:"center"},children:[ce.jsx(Tr.Wrapper,{children:ce.jsx(Tr,{type:"text",size:"lg",value:b,onChange:Q=>v(Q.currentTarget.value),placeholder:"Wallet Name",className:dn.input})}),ce.jsx(Ii,{type:"button",size:"lg",radius:"md",fullWidth:!0,variant:"outline",color:"green",style:{marginLeft:"20px"},onClick:async()=>{try{C(!0),P("Authenticating you ...");const Q=await tW(b),K=await Hm(parseInt(s.c),Q);P("Confirming the claim transaction");const se=await RB(s.c,s.i,s.p,K);B({account:K,amount:o.amount,chainId:parseInt(s.c),token:o.token}),C(!1),n(fc.account)}catch{C(!1)}},loading:!1,children:"Create & Claim"})]}),ce.jsx("p",{className:dn.footerHeading,children:"This will claim the funds to a new Safe Account (with 4337 module) created via passkey."}),ce.jsx(q5,{my:"xs",label:"OR",labelPosition:"center"}),ce.jsx("p",{className:dn.subHeading,children:"Already have an account?"}),ce.jsx("div",{style:{display:"flex",marginTop:"20px",marginBottom:"20px",alignItems:"center",justifyContent:"center"},children:ce.jsx(Ii,{type:"button",size:"lg",radius:"md",fullWidth:!0,color:"green",className:dn.btn,onClick:async()=>{try{C(!0),P("Authenticating you ...");const Q=await xA();P("Confirming the claim transaction");const K=await Hm(parseInt(s.c),Q);C(!0);const se=await RB(s.c,s.i,s.p,K);B({account:K,amount:o.amount,chainId:parseInt(s.c),token:o.token}),C(!1),n(fc.account)}catch{C(!1)}},loading:!1,children:"Login & Claim"})})]})]})]}),ce.jsx("div",{className:dn.homeContainer,children:ce.jsx(zf,{className:dn.claimContainer,shadow:"md",radius:"md",children:h?ce.jsxs(ce.Fragment,{children:[ce.jsx(Uu,{style:{marginBottom:"10px"},height:20,width:200,mt:6,radius:"xl"}),ce.jsx(Uu,{style:{marginBottom:"20px"},height:20,width:200,mt:6,radius:"xl"}),ce.jsx(Uu,{style:{marginBottom:"20px"},height:40,width:150,mt:6,radius:"md"})]}):ce.jsxs(ce.Fragment,{children:[o.amount&&!o.claimed?ce.jsxs("div",{children:[ce.jsxs("h1",{className:dn.claimHeading,children:["You have",ce.jsxs("h1",{className:dn.claimInner,children:[o.amount?o.amount:0," ",(H=yu(o.chainId,o.token))==null?void 0:H.label," ",ce.jsx(kf,{src:(J=yu(o.chainId,o.token))==null?void 0:J.image})]})]}),ce.jsx("h1",{className:dn.links,children:" to claim 🎉 😍"})]}):ce.jsxs("div",{children:[ce.jsx("h1",{className:dn.claimHeading,children:"Looks like there is nothing to claim"}),ce.jsx("h1",{className:dn.links,children:" 👀 😢"})]}),o.amount&&!o.claimed&&ce.jsx(Ii,{size:"lg",radius:"md",style:{width:"50%",marginTop:"20px"},fullWidth:!0,color:"teal",type:"button",className:dn.btn,onClick:async()=>{e()},children:"Claim Now"})]})})})]})}const EMe="_accountContainer_1tcas_3",MMe="_formContainer_1tcas_15",SMe="_avatarContainer_1tcas_24",_Me="_balance_1tcas_32",PMe="_avatar_1tcas_24",CMe="_heading_1tcas_45",IMe="_btn_1tcas_56",TMe="_actionsContainer_1tcas_71",kMe="_subHeading_1tcas_79",RMe="_footerHeading_1tcas_86",BMe="_balanceContainer_1tcas_91",OMe="_actions_1tcas_71",NMe="_inputContainer_1tcas_109",LMe="_accountInputContainer_1tcas_119",Ar={accountContainer:EMe,formContainer:MMe,avatarContainer:SMe,balance:_Me,avatar:PMe,heading:CMe,btn:IMe,actionsContainer:TMe,subHeading:kMe,footerHeading:RMe,balanceContainer:BMe,actions:OMe,inputContainer:NMe,accountInputContainer:LMe},DMe=()=>{var D,U,V,G,Y,q,z,ee;const{claimDetails:t,setClaimDetails:e}=bM(re=>re),[r,n]=Z.useState(0),[s,{open:i,close:o}]=ME(!1),[f,h]=Z.useState(!1),[p,b]=Z.useState(0),[v,E]=Z.useState(""),[_,S]=Z.useState(!1),[P,I]=Z.useState(!1),[C,T]=Z.useState(!1),[B,N]=Z.useState(""),[$,H]=Z.useState(!1),[J,Q]=Z.useState({width:window.innerWidth,height:window.innerHeight}),[K,se]=Z.useState(t.chainId),[w,a]=Z.useState("0x0000000000000000000000000000000000000000"),u=Object.keys(kc).filter(re=>{var ie;return((ie=Yr.getNetworkById(Number(re)))==null?void 0:ie.type)=="testnet"}).map(re=>{var ie,ae;return{label:`${(ie=Yr.getNetworkById(Number(re)))==null?void 0:ie.name}`,type:`${(ae=Yr.getNetworkById(Number(re)))==null?void 0:ae.type}`,image:u2(re),value:re}}),d=Object.keys(kc).filter(re=>{var ie;return((ie=Yr.getNetworkById(Number(re)))==null?void 0:ie.type)=="mainnet"}).map(re=>{var ie,ae;return{label:`${(ie=Yr.getNetworkById(Number(re)))==null?void 0:ie.name}`,type:`${(ae=Yr.getNetworkById(Number(re)))==null?void 0:ae.type}`,image:u2(re),value:re}}).map(re=>ce.jsx(kt.Option,{value:re.value,children:ce.jsx(c,{...re})},re.value)),m=u.map(re=>ce.jsx(kt.Option,{value:re.value,children:ce.jsx(c,{...re})},re.value)),x=ce.jsxs(kt.Options,{children:[ce.jsx(kt.Group,{children:d}),ce.jsx(kt.Group,{label:"TESTNETS",children:m})]}),A=H2({onDropdownClose:()=>A.resetSelectedOption()}),y=H2({onDropdownClose:()=>y.resetSelectedOption()});function c({image:re,label:ie}){return ce.jsxs(Tf,{style:{width:"100%"},children:[ce.jsx(kf,{src:re,children:ce.jsx(O9,{size:"1.5rem"})}),ce.jsx("div",{children:ce.jsx(Fu,{fz:"sm",fw:500,children:ie})})]})}const g=yu(K,w),M=PK(K).map(re=>ce.jsx(kt.Option,{value:re.value,children:ce.jsx(R,{...re})},re.value));function R({image:re,label:ie}){return ce.jsxs(Tf,{style:{width:"100%"},children:[ce.jsx(kf,{src:re,children:ce.jsx(O9,{size:"1.5rem"})}),ce.jsx("div",{children:ce.jsx(Fu,{fz:"sm",fw:500,children:ie})})]})}async function L(){let re=t.account;T(!0);try{await t.account.client.getChainId()!=K&&(re=await Hm(K,await xA()),e({account:re,amount:0,chainId:K}));let ie,ae="0x",je=v;if(w==To)ie=q$(p.toString());else{const oe=await bl(K.toString());ie=IM(p.toString(),await yP(w,oe)),ae=await X7e(w,je,ie,oe),ie=0n,je=w}const he=await wK(K.toString(),je,ae,re,ie);S(!!he)}catch{console.log("error"),T(!1)}T(!1)}Z.useEffect(()=>{(async()=>{var ie,ae;t.account||i(),I(!0);const re=await bl(K.toString());w==To?n(H$(await re.getBalance((ie=t==null?void 0:t.account)==null?void 0:ie.address))):n(await vK(w,(ae=t==null?void 0:t.account)==null?void 0:ae.address,re)),I(!1),window.addEventListener("resize",()=>Q({width:window.innerWidth,height:window.innerHeight}))})()},[t.account,K,_,w]),console.log(r);function k(re){const ie=re.slice(0,7),ae=re.slice(-5);return`${ie}...${ae}`}return ce.jsxs(ce.Fragment,{children:[ce.jsx(js,{opened:s,onClose:o,title:"Authenticate your Account",centered:!0,children:ce.jsxs("div",{className:Ar.formContainer,children:[ce.jsx("div",{children:ce.jsx("h1",{className:Ar.heading,children:"Authenticate in one click with PassKey"})}),ce.jsx("p",{className:Ar.subHeading,children:"First time at Safe2Link?"}),ce.jsxs("div",{className:Ar.accountInputContainer,children:[ce.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",marginBottom:"20px",alignItems:"center"},children:[ce.jsx(Tr.Wrapper,{children:ce.jsx(Tr,{type:"text",size:"lg",value:B,onChange:re=>N(re.currentTarget.value),placeholder:"Wallet Name",className:Ar.input})}),ce.jsx(Ii,{type:"button",variant:"outline",size:"lg",radius:"md",fullWidth:!0,color:"green",style:{marginLeft:"20px"},onClick:async()=>{const re=await Hm(K,await tW(B));e({account:re,amount:0,chainId:K}),o()},children:"Create Account"})]}),ce.jsx("p",{className:Ar.footerHeading,children:"This will create a new Safe Account (with 4337 module) created via passkey."}),ce.jsx(q5,{my:"xs",label:"OR",labelPosition:"center"}),ce.jsx("p",{className:Ar.subHeading,children:"Already have an account?"}),ce.jsx("div",{style:{display:"flex",marginTop:"20px",marginBottom:"20px",alignItems:"center",justifyContent:"center"},children:ce.jsx(Ii,{size:"lg",radius:"md",type:"button",fullWidth:!0,color:"green",className:Ar.btn,loaderProps:{color:"white",type:"dots",size:"md"},onClick:async()=>{H(!0);try{const re=await Hm(K,await xA());e({account:re,amount:0,chainId:K}),o()}catch{H(!1)}},loading:$,children:"Login"})})]})]})}),ce.jsx(js,{opened:f,onClose:()=>{h(!1),S(!1),a(To)},title:"Transfer your crypto",centered:!0,children:ce.jsxs("div",{className:Ar.formContainer,children:[ce.jsx("div",{children:ce.jsx("h1",{className:Ar.heading,children:"Send crypto anywhere"})}),ce.jsx("p",{className:Ar.subHeading,children:"Send your crypto gas free."}),ce.jsxs("div",{className:Ar.inputContainer,children:[ce.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",alignItems:"center"},children:[ce.jsxs(kt,{store:y,withinPortal:!1,onOptionSubmit:re=>{a(re),y.closeDropdown()},children:[ce.jsx(kt.Target,{children:ce.jsx(U5,{style:{width:"50%"},component:"button",type:"button",pointer:!0,rightSection:ce.jsx(kt.Chevron,{}),onClick:()=>y.toggleDropdown(),rightSectionPointerEvents:"none",multiline:!0,children:g?ce.jsx(R,{...g}):ce.jsx(Tr.Placeholder,{children:"Pick Token"})})}),ce.jsx(kt.Dropdown,{children:ce.jsx(kt.Options,{children:M})})]}),ce.jsx(Tr,{style:{width:"40%"},type:"number",size:"lg",value:p,onChange:re=>{var ie;return b((ie=re==null?void 0:re.target)==null?void 0:ie.value)},placeholder:"Value",className:Ar.input})]}),ce.jsx(Fu,{size:"sm",style:{cursor:"pointer"},onClick:()=>{b(r)},children:P?ce.jsx(Uu,{height:15,width:90,mt:6,radius:"xl"}):`Balance: ${r} ${(D=yu(K,w))==null?void 0:D.label}`}),ce.jsx(Tr,{type:"string",style:{marginTop:"20px"},size:"lg",value:v,onChange:re=>{var ie;return E((ie=re==null?void 0:re.target)==null?void 0:ie.value)},placeholder:"Recipient Address",className:Ar.input})]}),ce.jsx(Ii,{size:"lg",radius:"md",style:{marginBottom:"20px"},fullWidth:!0,color:"green",className:Ar.btn,onClick:()=>L(),loaderProps:{color:"white",type:"dots",size:"md"},loading:C,children:"Send Now"}),_&&ce.jsx(ap,{variant:"light",color:"lime",radius:"md",title:"Transfer Successful",icon:ce.jsx(nse,{}),children:"Your crypto assets have safely landed in the Success Galaxy. Buckle up for a stellar financial journey! 🚀💰"})]})}),ce.jsx(zf,{className:Ar.accountContainer,shadow:"md",withBorder:!0,radius:"md",p:"xl",children:ce.jsxs("div",{className:Ar.formContainer,children:[!!t.amount&&ce.jsx(ap,{variant:"light",color:"green",radius:"md",title:"",icon:ce.jsx(ase,{}),children:ce.jsx("b",{children:`Successfully claimed ${t.amount?t.amount:0} ${(U=yu(t.chainId,t.token))==null?void 0:U.label} from the link 🎉`})}),ce.jsxs("div",{className:Ar.avatarContainer,children:[ce.jsx("img",{className:Ar.avatar,src:"https://pbs.twimg.com/profile_images/1643941027898613760/gyhYEOCE_400x400.jpg",alt:"avatar",height:100,width:100}),ce.jsxs("div",{className:Ar.balanceContainer,children:[ce.jsxs(lg,{href:`${(V=Yr.getNetworkById(K))==null?void 0:V.blockExplorer}/address/${(G=t.account)==null?void 0:G.address}`,target:"_blank",underline:"hover",children:[" ",ce.jsxs("p",{children:[" ",k((Y=t.account)!=null&&Y.address?(q=t.account)==null?void 0:q.address:To)]})]}),ce.jsx(UD,{value:(z=t.account)==null?void 0:z.address,timeout:1e3,children:({copied:re,copy:ie})=>ce.jsx(wy,{label:re?"Copied":"Copy",withArrow:!0,position:"right",children:ce.jsx(N5,{color:re?"teal":"gray",variant:"subtle",onClick:ie,children:re?ce.jsx(Yie,{style:{width:ke(16)}}):ce.jsx(sse,{style:{width:ke(16)}})})})})]}),ce.jsxs(kt,{store:A,withinPortal:!1,onOptionSubmit:re=>{se(Number(re)),A.closeDropdown()},children:[ce.jsx(kt.Target,{children:ce.jsx(j5,{pl:0,style:{cursor:"pointer",width:"200px",height:"40px",padding:"10px"},color:"gray",variant:"light",leftSection:ce.jsx(kf,{alt:"Avatar for badge",size:24,mr:5,src:u2(K)}),rightSection:ce.jsx(ese,{size:20}),size:"lg",onClick:()=>A.toggleDropdown(),children:`${(ee=Yr.getNetworkById(Number(K)))==null?void 0:ee.name}`})}),ce.jsx(kt.Dropdown,{children:ce.jsx(kt.Options,{children:x})})]}),ce.jsxs("p",{className:Ar.balance,children:[" ",P?ce.jsx(Uu,{height:20,width:110,mt:6,radius:"xl"}):`${r} ${yu(K,To).label}`," "]})]}),ce.jsx("div",{className:Ar.actionsContainer,children:ce.jsxs("div",{className:Ar.actions,children:[ce.jsx(Ii,{size:"lg",radius:"md",style:{width:"110px"},className:Ar.btn,color:"teal",onClick:()=>h(!0),children:"Send"}),ce.jsx(Ii,{size:"lg",radius:"md",color:"#49494f",disabled:!0,variant:"filled",style:{},children:"Swap"})]})})]})}),!!t.amount&&ce.jsx(MK,{width:J.width,height:J.height})]})},$Me=()=>ce.jsxs(Vie,{children:[ce.jsx(Nv,{path:fc.home,element:ce.jsx(jAe,{})}),ce.jsx(Nv,{path:fc.claim,element:ce.jsx(AMe,{})}),ce.jsx(Nv,{path:fc.account,element:ce.jsx(DMe,{})})]}),FMe={fontFamily:"Inter, sans-serif"};function UMe(){return ce.jsx(UL,{theme:FMe,defaultColorScheme:"dark",children:ce.jsx(Wie,{children:ce.jsx(Y3e,{children:ce.jsx($Me,{})})})})}w4.createRoot(document.getElementById("root")).render(ce.jsx(UMe,{}));export{Xz as a,tSe as c,Ve as d,eSe as u}; diff --git a/assets/index-964a48cc.css b/assets/index-964a48cc.css deleted file mode 100644 index 899b3209..00000000 --- a/assets/index-964a48cc.css +++ /dev/null @@ -1 +0,0 @@ -body,html{height:100%}*,:after,:before{box-sizing:border-box}button,input,select,textarea{font:inherit}button,select{text-transform:none}body{-webkit-font-smoothing:var(--mantine-webkit-font-smoothing);-moz-osx-font-smoothing:var(--mantine-moz-font-smoothing);background-color:var(--mantine-color-body);color:var(--mantine-color-text);font-family:var(--mantine-font-family);font-size:var(--mantine-font-size-md);line-height:var(--mantine-line-height);margin:0}@media screen and (max-device-width:500px){body{-webkit-text-size-adjust:100%}}@media (prefers-reduced-motion:reduce){[data-respect-reduced-motion] [data-reduce-motion]{animation:none;transition:none}}[data-mantine-color-scheme=dark] .mantine-dark-hidden,[data-mantine-color-scheme=light] .mantine-light-hidden{display:none}.mantine-focus-auto:focus-visible{outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem*var(--mantine-scale))}.mantine-focus-always:focus{outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem*var(--mantine-scale))}.mantine-focus-never:focus{outline:none}.mantine-active:active{transform:translateY(calc(.0625rem*var(--mantine-scale)))}[dir=rtl] .mantine-rotate-rtl{transform:rotate(180deg)}:root{--mantine-z-index-app:100;--mantine-z-index-modal:200;--mantine-z-index-popover:300;--mantine-z-index-overlay:400;--mantine-z-index-max:9999;--mantine-scale:1;--mantine-cursor-type:default;--mantine-webkit-font-smoothing:antialiased;--mantine-color-scheme:light dark;--mantine-moz-font-smoothing:grayscale;--mantine-color-white:#fff;--mantine-color-black:#000;--mantine-line-height:1.55;--mantine-font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;--mantine-font-family-monospace:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;--mantine-font-family-headings:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;--mantine-heading-font-weight:700;--mantine-radius-default:calc(.25rem*var(--mantine-scale));--mantine-primary-color-filled:var(--mantine-color-blue-filled);--mantine-primary-color-filled-hover:var(--mantine-color-blue-filled-hover);--mantine-primary-color-light:var(--mantine-color-blue-light);--mantine-primary-color-light-hover:var(--mantine-color-blue-light-hover);--mantine-primary-color-light-color:var(--mantine-color-blue-light-color);--mantine-breakpoint-xs:36em;--mantine-breakpoint-sm:48em;--mantine-breakpoint-md:62em;--mantine-breakpoint-lg:75em;--mantine-breakpoint-xl:88em;--mantine-spacing-xs:calc(.625rem*var(--mantine-scale));--mantine-spacing-sm:calc(.75rem*var(--mantine-scale));--mantine-spacing-md:calc(1rem*var(--mantine-scale));--mantine-spacing-lg:calc(1.25rem*var(--mantine-scale));--mantine-spacing-xl:calc(2rem*var(--mantine-scale));--mantine-font-size-xs:calc(.75rem*var(--mantine-scale));--mantine-font-size-sm:calc(.875rem*var(--mantine-scale));--mantine-font-size-md:calc(1rem*var(--mantine-scale));--mantine-font-size-lg:calc(1.125rem*var(--mantine-scale));--mantine-font-size-xl:calc(1.25rem*var(--mantine-scale));--mantine-line-height-xs:1.4;--mantine-line-height-sm:1.45;--mantine-line-height-md:1.55;--mantine-line-height-lg:1.6;--mantine-line-height-xl:1.65;--mantine-shadow-xs:0 calc(.0625rem*var(--mantine-scale)) calc(.1875rem*var(--mantine-scale)) rgba(0,0,0,.05),0 calc(.0625rem*var(--mantine-scale)) calc(.125rem*var(--mantine-scale)) rgba(0,0,0,.1);--mantine-shadow-sm:0 calc(.0625rem*var(--mantine-scale)) calc(.1875rem*var(--mantine-scale)) rgba(0,0,0,.05),rgba(0,0,0,.05) 0 calc(.625rem*var(--mantine-scale)) calc(.9375rem*var(--mantine-scale)) calc(-.3125rem*var(--mantine-scale)),rgba(0,0,0,.04) 0 calc(.4375rem*var(--mantine-scale)) calc(.4375rem*var(--mantine-scale)) calc(-.3125rem*var(--mantine-scale));--mantine-shadow-md:0 calc(.0625rem*var(--mantine-scale)) calc(.1875rem*var(--mantine-scale)) rgba(0,0,0,.05),rgba(0,0,0,.05) 0 calc(1.25rem*var(--mantine-scale)) calc(1.5625rem*var(--mantine-scale)) calc(-.3125rem*var(--mantine-scale)),rgba(0,0,0,.04) 0 calc(.625rem*var(--mantine-scale)) calc(.625rem*var(--mantine-scale)) calc(-.3125rem*var(--mantine-scale));--mantine-shadow-lg:0 calc(.0625rem*var(--mantine-scale)) calc(.1875rem*var(--mantine-scale)) rgba(0,0,0,.05),rgba(0,0,0,.05) 0 calc(1.75rem*var(--mantine-scale)) calc(1.4375rem*var(--mantine-scale)) calc(-.4375rem*var(--mantine-scale)),rgba(0,0,0,.04) 0 calc(.75rem*var(--mantine-scale)) calc(.75rem*var(--mantine-scale)) calc(-.4375rem*var(--mantine-scale));--mantine-shadow-xl:0 calc(.0625rem*var(--mantine-scale)) calc(.1875rem*var(--mantine-scale)) rgba(0,0,0,.05),rgba(0,0,0,.05) 0 calc(2.25rem*var(--mantine-scale)) calc(1.75rem*var(--mantine-scale)) calc(-.4375rem*var(--mantine-scale)),rgba(0,0,0,.04) 0 calc(1.0625rem*var(--mantine-scale)) calc(1.0625rem*var(--mantine-scale)) calc(-.4375rem*var(--mantine-scale));--mantine-radius-xs:calc(.125rem*var(--mantine-scale));--mantine-radius-sm:calc(.25rem*var(--mantine-scale));--mantine-radius-md:calc(.5rem*var(--mantine-scale));--mantine-radius-lg:calc(1rem*var(--mantine-scale));--mantine-radius-xl:calc(2rem*var(--mantine-scale));--mantine-color-dark-0:#c9c9c9;--mantine-color-dark-1:#b8b8b8;--mantine-color-dark-2:#828282;--mantine-color-dark-3:#696969;--mantine-color-dark-4:#4a4a4a;--mantine-color-dark-5:#404040;--mantine-color-dark-6:#383838;--mantine-color-dark-7:#2e2e2e;--mantine-color-dark-8:#242424;--mantine-color-dark-9:#212121;--mantine-color-gray-0:#f8f9fa;--mantine-color-gray-1:#f1f3f5;--mantine-color-gray-2:#e9ecef;--mantine-color-gray-3:#dee2e6;--mantine-color-gray-4:#ced4da;--mantine-color-gray-5:#adb5bd;--mantine-color-gray-6:#868e96;--mantine-color-gray-7:#495057;--mantine-color-gray-8:#343a40;--mantine-color-gray-9:#212529;--mantine-color-red-0:#fff5f5;--mantine-color-red-1:#ffe3e3;--mantine-color-red-2:#ffc9c9;--mantine-color-red-3:#ffa8a8;--mantine-color-red-4:#ff8787;--mantine-color-red-5:#ff6b6b;--mantine-color-red-6:#fa5252;--mantine-color-red-7:#f03e3e;--mantine-color-red-8:#e03131;--mantine-color-red-9:#c92a2a;--mantine-color-pink-0:#fff0f6;--mantine-color-pink-1:#ffdeeb;--mantine-color-pink-2:#fcc2d7;--mantine-color-pink-3:#faa2c1;--mantine-color-pink-4:#f783ac;--mantine-color-pink-5:#f06595;--mantine-color-pink-6:#e64980;--mantine-color-pink-7:#d6336c;--mantine-color-pink-8:#c2255c;--mantine-color-pink-9:#a61e4d;--mantine-color-grape-0:#f8f0fc;--mantine-color-grape-1:#f3d9fa;--mantine-color-grape-2:#eebefa;--mantine-color-grape-3:#e599f7;--mantine-color-grape-4:#da77f2;--mantine-color-grape-5:#cc5de8;--mantine-color-grape-6:#be4bdb;--mantine-color-grape-7:#ae3ec9;--mantine-color-grape-8:#9c36b5;--mantine-color-grape-9:#862e9c;--mantine-color-violet-0:#f3f0ff;--mantine-color-violet-1:#e5dbff;--mantine-color-violet-2:#d0bfff;--mantine-color-violet-3:#b197fc;--mantine-color-violet-4:#9775fa;--mantine-color-violet-5:#845ef7;--mantine-color-violet-6:#7950f2;--mantine-color-violet-7:#7048e8;--mantine-color-violet-8:#6741d9;--mantine-color-violet-9:#5f3dc4;--mantine-color-indigo-0:#edf2ff;--mantine-color-indigo-1:#dbe4ff;--mantine-color-indigo-2:#bac8ff;--mantine-color-indigo-3:#91a7ff;--mantine-color-indigo-4:#748ffc;--mantine-color-indigo-5:#5c7cfa;--mantine-color-indigo-6:#4c6ef5;--mantine-color-indigo-7:#4263eb;--mantine-color-indigo-8:#3b5bdb;--mantine-color-indigo-9:#364fc7;--mantine-color-blue-0:#e7f5ff;--mantine-color-blue-1:#d0ebff;--mantine-color-blue-2:#a5d8ff;--mantine-color-blue-3:#74c0fc;--mantine-color-blue-4:#4dabf7;--mantine-color-blue-5:#339af0;--mantine-color-blue-6:#228be6;--mantine-color-blue-7:#1c7ed6;--mantine-color-blue-8:#1971c2;--mantine-color-blue-9:#1864ab;--mantine-color-cyan-0:#e3fafc;--mantine-color-cyan-1:#c5f6fa;--mantine-color-cyan-2:#99e9f2;--mantine-color-cyan-3:#66d9e8;--mantine-color-cyan-4:#3bc9db;--mantine-color-cyan-5:#22b8cf;--mantine-color-cyan-6:#15aabf;--mantine-color-cyan-7:#1098ad;--mantine-color-cyan-8:#0c8599;--mantine-color-cyan-9:#0b7285;--mantine-color-teal-0:#e6fcf5;--mantine-color-teal-1:#c3fae8;--mantine-color-teal-2:#96f2d7;--mantine-color-teal-3:#63e6be;--mantine-color-teal-4:#38d9a9;--mantine-color-teal-5:#20c997;--mantine-color-teal-6:#12b886;--mantine-color-teal-7:#0ca678;--mantine-color-teal-8:#099268;--mantine-color-teal-9:#087f5b;--mantine-color-green-0:#ebfbee;--mantine-color-green-1:#d3f9d8;--mantine-color-green-2:#b2f2bb;--mantine-color-green-3:#8ce99a;--mantine-color-green-4:#69db7c;--mantine-color-green-5:#51cf66;--mantine-color-green-6:#40c057;--mantine-color-green-7:#37b24d;--mantine-color-green-8:#2f9e44;--mantine-color-green-9:#2b8a3e;--mantine-color-lime-0:#f4fce3;--mantine-color-lime-1:#e9fac8;--mantine-color-lime-2:#d8f5a2;--mantine-color-lime-3:#c0eb75;--mantine-color-lime-4:#a9e34b;--mantine-color-lime-5:#94d82d;--mantine-color-lime-6:#82c91e;--mantine-color-lime-7:#74b816;--mantine-color-lime-8:#66a80f;--mantine-color-lime-9:#5c940d;--mantine-color-yellow-0:#fff9db;--mantine-color-yellow-1:#fff3bf;--mantine-color-yellow-2:#ffec99;--mantine-color-yellow-3:#ffe066;--mantine-color-yellow-4:#ffd43b;--mantine-color-yellow-5:#fcc419;--mantine-color-yellow-6:#fab005;--mantine-color-yellow-7:#f59f00;--mantine-color-yellow-8:#f08c00;--mantine-color-yellow-9:#e67700;--mantine-color-orange-0:#fff4e6;--mantine-color-orange-1:#ffe8cc;--mantine-color-orange-2:#ffd8a8;--mantine-color-orange-3:#ffc078;--mantine-color-orange-4:#ffa94d;--mantine-color-orange-5:#ff922b;--mantine-color-orange-6:#fd7e14;--mantine-color-orange-7:#f76707;--mantine-color-orange-8:#e8590c;--mantine-color-orange-9:#d9480f;--mantine-h1-font-size:calc(2.125rem*var(--mantine-scale));--mantine-h1-line-height:1.3;--mantine-h1-font-weight:700;--mantine-h2-font-size:calc(1.625rem*var(--mantine-scale));--mantine-h2-line-height:1.35;--mantine-h2-font-weight:700;--mantine-h3-font-size:calc(1.375rem*var(--mantine-scale));--mantine-h3-line-height:1.4;--mantine-h3-font-weight:700;--mantine-h4-font-size:calc(1.125rem*var(--mantine-scale));--mantine-h4-line-height:1.45;--mantine-h4-font-weight:700;--mantine-h5-font-size:calc(1rem*var(--mantine-scale));--mantine-h5-line-height:1.5;--mantine-h5-font-weight:700;--mantine-h6-font-size:calc(.875rem*var(--mantine-scale));--mantine-h6-line-height:1.5;--mantine-h6-font-weight:700;color-scheme:var(--mantine-color-scheme)}:root[data-mantine-color-scheme=dark]{--mantine-color-scheme:dark;--mantine-color-bright:var(--mantine-color-white);--mantine-color-text:var(--mantine-color-dark-0);--mantine-color-body:var(--mantine-color-dark-7);--mantine-color-error:var(--mantine-color-red-8);--mantine-color-placeholder:var(--mantine-color-dark-3);--mantine-color-anchor:var(--mantine-color-blue-4);--mantine-color-default:var(--mantine-color-dark-6);--mantine-color-default-hover:var(--mantine-color-dark-5);--mantine-color-default-color:var(--mantine-color-white);--mantine-color-default-border:var(--mantine-color-dark-4);--mantine-color-dimmed:var(--mantine-color-dark-2);--mantine-color-dark-text:var(--mantine-color-dark-4);--mantine-color-dark-filled:var(--mantine-color-dark-8);--mantine-color-dark-filled-hover:var(--mantine-color-dark-7);--mantine-color-dark-light:rgba(36,36,36,.15);--mantine-color-dark-light-hover:rgba(36,36,36,.2);--mantine-color-dark-light-color:#656b73;--mantine-color-dark-outline:var(--mantine-color-dark-4);--mantine-color-dark-outline-hover:rgba(36,36,36,.05);--mantine-color-gray-text:var(--mantine-color-gray-4);--mantine-color-gray-filled:#343a40;--mantine-color-gray-filled-hover:#212529;--mantine-color-gray-light:hsla(210,7%,56%,.15);--mantine-color-gray-light-hover:hsla(210,7%,56%,.2);--mantine-color-gray-light-color:#dee2e6;--mantine-color-gray-outline:#ced4da;--mantine-color-gray-outline-hover:rgba(206,212,218,.05);--mantine-color-red-text:var(--mantine-color-red-4);--mantine-color-red-filled:#e03131;--mantine-color-red-filled-hover:#c92a2a;--mantine-color-red-light:rgba(250,82,82,.15);--mantine-color-red-light-hover:rgba(250,82,82,.2);--mantine-color-red-light-color:#ffa8a8;--mantine-color-red-outline:#ff8787;--mantine-color-red-outline-hover:hsla(0,100%,76%,.05);--mantine-color-pink-text:var(--mantine-color-pink-4);--mantine-color-pink-filled:#c2255c;--mantine-color-pink-filled-hover:#a61e4d;--mantine-color-pink-light:rgba(230,73,128,.15);--mantine-color-pink-light-hover:rgba(230,73,128,.2);--mantine-color-pink-light-color:#faa2c1;--mantine-color-pink-outline:#f783ac;--mantine-color-pink-outline-hover:rgba(247,131,172,.05);--mantine-color-grape-text:var(--mantine-color-grape-4);--mantine-color-grape-filled:#9c36b5;--mantine-color-grape-filled-hover:#862e9c;--mantine-color-grape-light:rgba(190,75,219,.15);--mantine-color-grape-light-hover:rgba(190,75,219,.2);--mantine-color-grape-light-color:#e599f7;--mantine-color-grape-outline:#da77f2;--mantine-color-grape-outline-hover:rgba(218,119,242,.05);--mantine-color-violet-text:var(--mantine-color-violet-4);--mantine-color-violet-filled:#6741d9;--mantine-color-violet-filled-hover:#5f3dc4;--mantine-color-violet-light:rgba(121,80,242,.15);--mantine-color-violet-light-hover:rgba(121,80,242,.2);--mantine-color-violet-light-color:#b197fc;--mantine-color-violet-outline:#9775fa;--mantine-color-violet-outline-hover:rgba(151,117,250,.05);--mantine-color-indigo-text:var(--mantine-color-indigo-4);--mantine-color-indigo-filled:#3b5bdb;--mantine-color-indigo-filled-hover:#364fc7;--mantine-color-indigo-light:rgba(76,110,245,.15);--mantine-color-indigo-light-hover:rgba(76,110,245,.2);--mantine-color-indigo-light-color:#91a7ff;--mantine-color-indigo-outline:#748ffc;--mantine-color-indigo-outline-hover:rgba(116,143,252,.05);--mantine-color-blue-text:var(--mantine-color-blue-4);--mantine-color-blue-filled:#1971c2;--mantine-color-blue-filled-hover:#1864ab;--mantine-color-blue-light:rgba(34,139,230,.15);--mantine-color-blue-light-hover:rgba(34,139,230,.2);--mantine-color-blue-light-color:#74c0fc;--mantine-color-blue-outline:#4dabf7;--mantine-color-blue-outline-hover:rgba(77,171,247,.05);--mantine-color-cyan-text:var(--mantine-color-cyan-4);--mantine-color-cyan-filled:#0c8599;--mantine-color-cyan-filled-hover:#0b7285;--mantine-color-cyan-light:rgba(21,170,191,.15);--mantine-color-cyan-light-hover:rgba(21,170,191,.2);--mantine-color-cyan-light-color:#66d9e8;--mantine-color-cyan-outline:#3bc9db;--mantine-color-cyan-outline-hover:rgba(59,201,219,.05);--mantine-color-teal-text:var(--mantine-color-teal-4);--mantine-color-teal-filled:#099268;--mantine-color-teal-filled-hover:#087f5b;--mantine-color-teal-light:rgba(18,184,134,.15);--mantine-color-teal-light-hover:rgba(18,184,134,.2);--mantine-color-teal-light-color:#63e6be;--mantine-color-teal-outline:#38d9a9;--mantine-color-teal-outline-hover:rgba(56,217,169,.05);--mantine-color-green-text:var(--mantine-color-green-4);--mantine-color-green-filled:#2f9e44;--mantine-color-green-filled-hover:#2b8a3e;--mantine-color-green-light:rgba(64,192,87,.15);--mantine-color-green-light-hover:rgba(64,192,87,.2);--mantine-color-green-light-color:#8ce99a;--mantine-color-green-outline:#69db7c;--mantine-color-green-outline-hover:rgba(105,219,124,.05);--mantine-color-lime-text:var(--mantine-color-lime-4);--mantine-color-lime-filled:#66a80f;--mantine-color-lime-filled-hover:#5c940d;--mantine-color-lime-light:rgba(130,201,30,.15);--mantine-color-lime-light-hover:rgba(130,201,30,.2);--mantine-color-lime-light-color:#c0eb75;--mantine-color-lime-outline:#a9e34b;--mantine-color-lime-outline-hover:rgba(169,227,75,.05);--mantine-color-yellow-text:var(--mantine-color-yellow-4);--mantine-color-yellow-filled:#f08c00;--mantine-color-yellow-filled-hover:#e67700;--mantine-color-yellow-light:rgba(250,176,5,.15);--mantine-color-yellow-light-hover:rgba(250,176,5,.2);--mantine-color-yellow-light-color:#ffe066;--mantine-color-yellow-outline:#ffd43b;--mantine-color-yellow-outline-hover:rgba(255,212,59,.05);--mantine-color-orange-text:var(--mantine-color-orange-4);--mantine-color-orange-filled:#e8590c;--mantine-color-orange-filled-hover:#d9480f;--mantine-color-orange-light:rgba(253,126,20,.15);--mantine-color-orange-light-hover:rgba(253,126,20,.2);--mantine-color-orange-light-color:#ffc078;--mantine-color-orange-outline:#ffa94d;--mantine-color-orange-outline-hover:rgba(255,169,77,.05)}:root[data-mantine-color-scheme=light]{--mantine-color-scheme:light;--mantine-color-bright:var(--mantine-color-black);--mantine-color-text:#000;--mantine-color-body:#fff;--mantine-color-error:var(--mantine-color-red-6);--mantine-color-placeholder:var(--mantine-color-gray-5);--mantine-color-anchor:var(--mantine-primary-color-filled);--mantine-color-default:var(--mantine-color-white);--mantine-color-default-hover:var(--mantine-color-gray-0);--mantine-color-default-color:var(--mantine-color-gray-9);--mantine-color-default-border:var(--mantine-color-gray-4);--mantine-color-dimmed:var(--mantine-color-gray-6);--mantine-color-dark-text:var(--mantine-color-dark-filled);--mantine-color-dark-filled:var(--mantine-color-dark-6);--mantine-color-dark-filled-hover:var(--mantine-color-dark-7);--mantine-color-dark-light:rgba(56,56,56,.1);--mantine-color-dark-light-hover:rgba(56,56,56,.12);--mantine-color-dark-light-color:var(--mantine-color-dark-6);--mantine-color-dark-outline:var(--mantine-color-dark-6);--mantine-color-dark-outline-hover:rgba(56,56,56,.05);--mantine-color-gray-text:var(--mantine-color-gray-filled);--mantine-color-gray-filled:#868e96;--mantine-color-gray-filled-hover:#495057;--mantine-color-gray-light:hsla(210,7%,56%,.1);--mantine-color-gray-light-hover:hsla(210,7%,56%,.12);--mantine-color-gray-light-color:#868e96;--mantine-color-gray-outline:#868e96;--mantine-color-gray-outline-hover:hsla(210,7%,56%,.05);--mantine-color-red-text:var(--mantine-color-red-filled);--mantine-color-red-filled:#fa5252;--mantine-color-red-filled-hover:#f03e3e;--mantine-color-red-light:rgba(250,82,82,.1);--mantine-color-red-light-hover:rgba(250,82,82,.12);--mantine-color-red-light-color:#fa5252;--mantine-color-red-outline:#fa5252;--mantine-color-red-outline-hover:rgba(250,82,82,.05);--mantine-color-pink-text:var(--mantine-color-pink-filled);--mantine-color-pink-filled:#e64980;--mantine-color-pink-filled-hover:#d6336c;--mantine-color-pink-light:rgba(230,73,128,.1);--mantine-color-pink-light-hover:rgba(230,73,128,.12);--mantine-color-pink-light-color:#e64980;--mantine-color-pink-outline:#e64980;--mantine-color-pink-outline-hover:rgba(230,73,128,.05);--mantine-color-grape-text:var(--mantine-color-grape-filled);--mantine-color-grape-filled:#be4bdb;--mantine-color-grape-filled-hover:#ae3ec9;--mantine-color-grape-light:rgba(190,75,219,.1);--mantine-color-grape-light-hover:rgba(190,75,219,.12);--mantine-color-grape-light-color:#be4bdb;--mantine-color-grape-outline:#be4bdb;--mantine-color-grape-outline-hover:rgba(190,75,219,.05);--mantine-color-violet-text:var(--mantine-color-violet-filled);--mantine-color-violet-filled:#7950f2;--mantine-color-violet-filled-hover:#7048e8;--mantine-color-violet-light:rgba(121,80,242,.1);--mantine-color-violet-light-hover:rgba(121,80,242,.12);--mantine-color-violet-light-color:#7950f2;--mantine-color-violet-outline:#7950f2;--mantine-color-violet-outline-hover:rgba(121,80,242,.05);--mantine-color-indigo-text:var(--mantine-color-indigo-filled);--mantine-color-indigo-filled:#4c6ef5;--mantine-color-indigo-filled-hover:#4263eb;--mantine-color-indigo-light:rgba(76,110,245,.1);--mantine-color-indigo-light-hover:rgba(76,110,245,.12);--mantine-color-indigo-light-color:#4c6ef5;--mantine-color-indigo-outline:#4c6ef5;--mantine-color-indigo-outline-hover:rgba(76,110,245,.05);--mantine-color-blue-text:var(--mantine-color-blue-filled);--mantine-color-blue-filled:#228be6;--mantine-color-blue-filled-hover:#1c7ed6;--mantine-color-blue-light:rgba(34,139,230,.1);--mantine-color-blue-light-hover:rgba(34,139,230,.12);--mantine-color-blue-light-color:#228be6;--mantine-color-blue-outline:#228be6;--mantine-color-blue-outline-hover:rgba(34,139,230,.05);--mantine-color-cyan-text:var(--mantine-color-cyan-filled);--mantine-color-cyan-filled:#15aabf;--mantine-color-cyan-filled-hover:#1098ad;--mantine-color-cyan-light:rgba(21,170,191,.1);--mantine-color-cyan-light-hover:rgba(21,170,191,.12);--mantine-color-cyan-light-color:#15aabf;--mantine-color-cyan-outline:#15aabf;--mantine-color-cyan-outline-hover:rgba(21,170,191,.05);--mantine-color-teal-text:var(--mantine-color-teal-filled);--mantine-color-teal-filled:#12b886;--mantine-color-teal-filled-hover:#0ca678;--mantine-color-teal-light:rgba(18,184,134,.1);--mantine-color-teal-light-hover:rgba(18,184,134,.12);--mantine-color-teal-light-color:#12b886;--mantine-color-teal-outline:#12b886;--mantine-color-teal-outline-hover:rgba(18,184,134,.05);--mantine-color-green-text:var(--mantine-color-green-filled);--mantine-color-green-filled:#40c057;--mantine-color-green-filled-hover:#37b24d;--mantine-color-green-light:rgba(64,192,87,.1);--mantine-color-green-light-hover:rgba(64,192,87,.12);--mantine-color-green-light-color:#40c057;--mantine-color-green-outline:#40c057;--mantine-color-green-outline-hover:rgba(64,192,87,.05);--mantine-color-lime-text:var(--mantine-color-lime-filled);--mantine-color-lime-filled:#82c91e;--mantine-color-lime-filled-hover:#74b816;--mantine-color-lime-light:rgba(130,201,30,.1);--mantine-color-lime-light-hover:rgba(130,201,30,.12);--mantine-color-lime-light-color:#82c91e;--mantine-color-lime-outline:#82c91e;--mantine-color-lime-outline-hover:rgba(130,201,30,.05);--mantine-color-yellow-text:var(--mantine-color-yellow-filled);--mantine-color-yellow-filled:#fab005;--mantine-color-yellow-filled-hover:#f59f00;--mantine-color-yellow-light:rgba(250,176,5,.1);--mantine-color-yellow-light-hover:rgba(250,176,5,.12);--mantine-color-yellow-light-color:#fab005;--mantine-color-yellow-outline:#fab005;--mantine-color-yellow-outline-hover:rgba(250,176,5,.05);--mantine-color-orange-text:var(--mantine-color-orange-filled);--mantine-color-orange-filled:#fd7e14;--mantine-color-orange-filled-hover:#f76707;--mantine-color-orange-light:rgba(253,126,20,.1);--mantine-color-orange-light-hover:rgba(253,126,20,.12);--mantine-color-orange-light-color:#fd7e14;--mantine-color-orange-outline:#fd7e14;--mantine-color-orange-outline-hover:rgba(253,126,20,.05)}.m-d57069b5{--scrollarea-scrollbar-size:calc(.75rem*var(--mantine-scale));overflow:hidden;position:relative}.m-c0783ff9{-ms-overflow-style:none;-webkit-overflow-scrolling:touch;height:100%;padding-bottom:var(--_viewport-padding-bottom,0);padding-left:var(--_viewport-padding-left,0);padding-right:var(--_viewport-padding-right,0);scrollbar-width:none;width:100%}.m-c0783ff9::-webkit-scrollbar{display:none}.m-c0783ff9[data-offset-scrollbars=xy],.m-c0783ff9[data-offset-scrollbars=y]{--_viewport-padding-right:var(--scrollarea-scrollbar-size);--_viewport-padding-left:unset}[dir=rtl] .m-c0783ff9[data-offset-scrollbars=xy],[dir=rtl] .m-c0783ff9[data-offset-scrollbars=y]{--_viewport-padding-right:unset;--_viewport-padding-left:var(--scrollarea-scrollbar-size)}.m-c0783ff9[data-offset-scrollbars=x],.m-c0783ff9[data-offset-scrollbars=xy]{--_viewport-padding-bottom:var(--scrollarea-scrollbar-size)}.m-f8f631dd{display:table;min-width:100%}.m-c44ba933{background-color:var(--_scrollbar-bg,transparent);box-sizing:border-box;display:var(--_scrollbar-display,flex);flex-direction:var(--_scrollbar-direction,row);height:var(--_scrollbar-height);padding:calc(var(--scrollarea-scrollbar-size)/5);touch-action:none;transition:background-color .15s ease,opacity .15s ease;-webkit-user-select:none;user-select:none;width:var(--_scrollbar-width)}.m-c44ba933>.m-d8b5e363{background-color:var(--_thumb-bg)}@media (hover:hover){[data-mantine-color-scheme=light] .m-c44ba933:hover{--_scrollbar-bg:var(--mantine-color-gray-0);--_thumb-bg:rgba(0,0,0,.5)}[data-mantine-color-scheme=dark] .m-c44ba933:hover{--_scrollbar-bg:var(--mantine-color-dark-8);--_thumb-bg:hsla(0,0%,100%,.5)}}@media (hover:none){[data-mantine-color-scheme=light] .m-c44ba933:active{--_scrollbar-bg:var(--mantine-color-gray-0);--_thumb-bg:rgba(0,0,0,.5)}[data-mantine-color-scheme=dark] .m-c44ba933:active{--_scrollbar-bg:var(--mantine-color-dark-8);--_thumb-bg:hsla(0,0%,100%,.5)}}.m-c44ba933[data-hidden],.m-c44ba933[data-state=hidden]{--_scrollbar-display:none}.m-c44ba933[data-orientation=vertical]{--_scrollbar-width:var(--scrollarea-scrollbar-size);bottom:var(--sa-corner-width);right:0;top:0}[dir=rtl] .m-c44ba933[data-orientation=vertical]{left:0;right:unset}.m-c44ba933[data-orientation=horizontal]{--_scrollbar-height:var(--scrollarea-scrollbar-size);--_scrollbar-direction:column;bottom:0;left:0;right:var(--sa-corner-height)}[dir=rtl] .m-c44ba933[data-orientation=horizontal]{left:var(--sa-corner-height);right:0}.m-d8b5e363{background-color:var(--_thumb-bg);border-radius:var(--scrollarea-scrollbar-size);flex:1;overflow:hidden;position:relative;transition:background-color .15s ease}.m-d8b5e363:before{content:'""';height:100%;left:50%;min-height:calc(2.75rem*var(--mantine-scale));min-width:calc(2.75rem*var(--mantine-scale));position:absolute;top:50%;transform:translate(-50%,-50%);width:100%}[data-mantine-color-scheme=light] .m-d8b5e363{--_thumb-bg:rgba(0,0,0,.4)}[data-mantine-color-scheme=dark] .m-d8b5e363{--_thumb-bg:hsla(0,0%,100%,.4)}.m-21657268{background-color:var(--_corner-bg);bottom:0;display:var(--_corner-display,block);opacity:var(--_corner-opacity,0);position:absolute;right:0;transition:opacity .15s ease}[dir=rtl] .m-21657268{bottom:0;left:0;right:unset}[data-mantine-color-scheme=light] .m-21657268{--_corner-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-21657268{--_corner-bg:var(--mantine-color-dark-8)}.m-21657268[data-hovered]{--_corner-opacity:1}.m-21657268[data-hidden]{--_corner-display:none}.m-87cf2631{-webkit-tap-highlight-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:0;color:inherit;cursor:pointer;font-size:var(--mantine-font-size-md);padding:0;text-align:left;text-decoration:none;touch-action:manipulation}[dir=rtl] .m-87cf2631{text-align:right}.m-515a97f8{clip:rect(0 0 0 0);border:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.m-1b7284a3{-webkit-tap-highlight-color:transparent;background-color:var(--mantine-color-body);border:var(--_paper-border,none);border-radius:var(--paper-radius,var(--mantine-radius-default));box-shadow:var(--paper-shadow,none);display:block;outline:0;text-decoration:none;touch-action:manipulation}[data-mantine-color-scheme=light] .m-1b7284a3[data-with-border]{--_paper-border:calc(.0625rem*var(--mantine-scale)) solid var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-1b7284a3[data-with-border]{--_paper-border:calc(.0625rem*var(--mantine-scale)) solid var(--mantine-color-dark-4)}.m-1b7284a3:not([data-with-border]){--_paper-border:none!important}.m-38a85659{background-color:var(--_popover-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_popover-bd);border-radius:var(--popover-radius,var(--mantine-radius-default));box-shadow:var(--popover-shadow,none);padding:var(--mantine-spacing-sm) var(--mantine-spacing-md);position:absolute}.m-38a85659:focus{outline:none}[data-mantine-color-scheme=light] .m-38a85659{--_popover-bg:var(--mantine-color-white);--_popover-bd:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-38a85659{--_popover-bg:var(--mantine-color-dark-6);--_popover-bd:var(--mantine-color-dark-4)}.m-a31dc6c1{background-color:inherit;border:calc(.0625rem*var(--mantine-scale)) solid var(--_popover-bd);z-index:1}.m-5ae2e3c{--loader-size-xs:calc(1.125rem*var(--mantine-scale));--loader-size-sm:calc(1.375rem*var(--mantine-scale));--loader-size-md:calc(2.25rem*var(--mantine-scale));--loader-size-lg:calc(2.75rem*var(--mantine-scale));--loader-size-xl:calc(3.625rem*var(--mantine-scale));--loader-size:var(--loader-size-md);--loader-color:var(--mantine-primary-color-filled)}@keyframes m-5d2b3b9d{0%{opacity:0;transform:scale(.6)}50%,to{transform:scale(1)}}.m-7a2bd4cd{display:flex;gap:calc(var(--loader-size)/5);height:var(--loader-size);position:relative;width:var(--loader-size)}.m-870bb79{animation:m-5d2b3b9d 1.2s cubic-bezier(0,.5,.5,1) infinite;background:var(--loader-color);border-radius:calc(.125rem*var(--mantine-scale));flex:1}.m-870bb79:first-of-type{animation-delay:-.24s}.m-870bb79:nth-of-type(2){animation-delay:-.12s}.m-870bb79:nth-of-type(3){animation-delay:0}@keyframes m-aac34a1{0%,to{opacity:1;transform:scale(1)}50%{opacity:.5;transform:scale(.6)}}.m-4e3f22d7{align-items:center;display:flex;gap:calc(var(--loader-size)/10);height:var(--loader-size);justify-content:center;position:relative;width:var(--loader-size)}.m-870c4af{animation:m-aac34a1 .8s linear infinite;background:var(--loader-color);border-radius:50%;height:calc(var(--loader-size)/3 - var(--loader-size)/15);width:calc(var(--loader-size)/3 - var(--loader-size)/15)}.m-870c4af:nth-child(2){animation-delay:.4s}@keyframes m-f8e89c4b{0%{transform:rotate(0)}to{transform:rotate(1turn)}}.m-b34414df{display:inline-block}.m-b34414df,.m-b34414df:after{height:var(--loader-size);width:var(--loader-size)}.m-b34414df:after{animation:m-f8e89c4b 1.2s linear infinite;border-color:var(--loader-color) var(--loader-color) var(--loader-color) transparent;border-radius:calc(625rem*var(--mantine-scale));border-style:solid;border-width:calc(var(--loader-size)/8);content:"";display:block}.m-8d3f4000{--ai-size-xs:calc(1.125rem*var(--mantine-scale));--ai-size-sm:calc(1.375rem*var(--mantine-scale));--ai-size-md:calc(1.75rem*var(--mantine-scale));--ai-size-lg:calc(2.125rem*var(--mantine-scale));--ai-size-xl:calc(2.75rem*var(--mantine-scale));--ai-size-input-xs:calc(1.875rem*var(--mantine-scale));--ai-size-input-sm:calc(2.25rem*var(--mantine-scale));--ai-size-input-md:calc(2.625rem*var(--mantine-scale));--ai-size-input-lg:calc(3.125rem*var(--mantine-scale));--ai-size-input-xl:calc(3.75rem*var(--mantine-scale));--ai-size:var(--ai-size-md);--ai-color:var(--mantine-color-white);align-items:center;background:var(--_ai-bg,var(--ai-bg,var(--mantine-primary-color-filled)));border:var(--ai-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--ai-radius,var(--mantine-radius-default));color:var(--_ai-color,var(--ai-color,var(--mantine-color-white)));cursor:var(--_ai-cursor,pointer);display:inline-flex;height:var(--ai-size);justify-content:center;line-height:1;min-height:var(--ai-size);min-width:var(--ai-size);position:relative;-webkit-user-select:none;user-select:none;width:var(--ai-size)}@media (hover:hover){.m-8d3f4000:hover:not([data-loading]):not(:disabled):not([data-disabled]){--_ai-bg:var(--ai-hover,var(--mantine-primary-color-filled-hover));--_ai-color:var(--ai-hover-color)}}@media (hover:none){.m-8d3f4000:active:not([data-loading]):not(:disabled):not([data-disabled]){--_ai-bg:var(--ai-hover,var(--mantine-primary-color-filled-hover));--_ai-color:var(--ai-hover-color)}}[data-mantine-color-scheme=light] .m-8d3f4000{--_ai-loading-overlay-bg:hsla(0,0%,100%,.35);--_ai-disabled-bg:var(--mantine-color-gray-1);--_ai-disabled-color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m-8d3f4000{--_ai-loading-overlay-bg:rgba(0,0,0,.35);--_ai-disabled-bg:var(--mantine-color-dark-6);--_ai-disabled-color:var(--mantine-color-dark-3)}.m-8d3f4000[data-loading]{--_ai-cursor:not-allowed}.m-8d3f4000[data-loading]:before{background-color:var(--_ai-loading-overlay-bg);border-radius:var(--ai-radius,var(--mantine-radius-default));content:"";inset:calc(-.0625rem*var(--mantine-scale));position:absolute}.m-8d3f4000:disabled:not([data-loading]),.m-8d3f4000[data-disabled]:not([data-loading]){--_ai-cursor:not-allowed;--_ai-bg:var(--_ai-disabled-bg);--_ai-color:var(--_ai-disabled-color);--ai-bd:calc(.0625rem*var(--mantine-scale)) solid transparent!important}.m-8d3f4000:disabled:not([data-loading]):active,.m-8d3f4000[data-disabled]:not([data-loading]):active{transform:none}.m-302b9fb1{z-index:1}.m-1a0f1b21{--ai-border-width:calc(.0625rem*var(--mantine-scale));display:flex}.m-1a0f1b21[data-orientation=horizontal]{flex-direction:row}.m-1a0f1b21[data-orientation=horizontal] .m-8d3f4000:not(:only-child):first-child{border-bottom-right-radius:0;border-right-width:calc(var(--ai-border-width)/2);border-top-right-radius:0}.m-1a0f1b21[data-orientation=horizontal] .m-8d3f4000:not(:only-child):last-child{border-bottom-left-radius:0;border-left-width:calc(var(--ai-border-width)/2);border-top-left-radius:0}.m-1a0f1b21[data-orientation=horizontal] .m-8d3f4000:not(:only-child):not(:first-child):not(:last-child){border-left-width:calc(var(--ai-border-width)/2);border-radius:0;border-right-width:calc(var(--ai-border-width)/2)}[dir=rtl] .m-1a0f1b21[data-orientation=horizontal] .m-8d3f4000:not(:only-child):first-child{border:var(--ai-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--ai-radius,var(--mantine-radius-default));border-bottom-left-radius:0;border-left-width:calc(var(--ai-border-width)/2);border-top-left-radius:0}[dir=rtl] .m-1a0f1b21[data-orientation=horizontal] .m-8d3f4000:not(:only-child):last-child{border:var(--ai-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--ai-radius,var(--mantine-radius-default));border-bottom-right-radius:0;border-right-width:calc(var(--ai-border-width)/2);border-top-right-radius:0}.m-1a0f1b21[data-orientation=vertical]{flex-direction:column}.m-1a0f1b21[data-orientation=vertical] .m-8d3f4000:not(:only-child):first-child{border-bottom-left-radius:0;border-bottom-right-radius:0;border-bottom-width:calc(var(--ai-border-width)/2)}.m-1a0f1b21[data-orientation=vertical] .m-8d3f4000:not(:only-child):last-child{border-top-left-radius:0;border-top-right-radius:0;border-top-width:calc(var(--ai-border-width)/2)}.m-1a0f1b21[data-orientation=vertical] .m-8d3f4000:not(:only-child):not(:first-child):not(:last-child){border-bottom-width:calc(var(--ai-border-width)/2);border-radius:0;border-top-width:calc(var(--ai-border-width)/2)}.m-86a44da5{--cb-size-xs:calc(1.125rem*var(--mantine-scale));--cb-size-sm:calc(1.375rem*var(--mantine-scale));--cb-size-md:calc(1.75rem*var(--mantine-scale));--cb-size-lg:calc(2.125rem*var(--mantine-scale));--cb-size-xl:calc(2.75rem*var(--mantine-scale));--cb-size:var(--cb-size-md);--cb-icon-size:70%;align-items:center;border-radius:var(--cb-radius,var(--mantine-radius-default));color:var(--_cb-color);display:inline-flex;height:var(--cb-size);justify-content:center;line-height:1;min-height:var(--cb-size);min-width:var(--cb-size);position:relative;-webkit-user-select:none;user-select:none;width:var(--cb-size)}[data-mantine-color-scheme=light] .m-86a44da5{--_cb-color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] .m-86a44da5{--_cb-color:var(--mantine-color-dark-1)}.m-220c80f2{background-color:var(--_cb-bg)}@media (hover:hover){[data-mantine-color-scheme=light] .m-220c80f2:hover{--_cb-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-220c80f2:hover{--_cb-bg:var(--mantine-color-dark-6)}}@media (hover:none){[data-mantine-color-scheme=light] .m-220c80f2:active{--_cb-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-220c80f2:active{--_cb-bg:var(--mantine-color-dark-6)}}.m-4081bf90{align-items:var(--group-align,center);display:flex;flex-direction:row;flex-wrap:var(--group-wrap,wrap);gap:var(--group-gap,var(--mantine-spacing-md));justify-content:var(--group-justify,flex-start)}.m-4081bf90[data-grow]>*{flex-grow:1;max-width:var(--group-child-width)}.m-9814e45f{backdrop-filter:var(--overlay-filter);-webkit-backdrop-filter:var(--overlay-filter);background:var(--overlay-bg,rgba(0,0,0,.6));border-radius:var(--overlay-radius,0);top:0;right:0;bottom:0;left:0;position:var(--_overlay-position,absolute);z-index:var(--overlay-z-index)}.m-9814e45f[data-fixed]{--_overlay-position:fixed}.m-9814e45f[data-center]{align-items:center;display:flex;justify-content:center}.m-615af6c9{font-size:var(--mantine-font-size-md);font-weight:400;line-height:1;margin:0;padding:0}.m-b5489c3c{align-items:center;background-color:var(--mantine-color-body);display:flex;justify-content:space-between;padding:var(--mb-padding,var(--mantine-spacing-md));padding-left:var(--_pl,var(--mb-padding,var(--mantine-spacing-md)));padding-right:var(--_pr,calc(var(--mb-padding, var(--mantine-spacing-md)) - .3125rem*var(--mantine-scale)));position:sticky;top:0;z-index:1000}[dir=rtl] .m-b5489c3c{--_pr:var(--mb-padding,var(--mantine-spacing-md));--_pl:calc(var(--mb-padding, var(--mantine-spacing-md)) - .3125rem*var(--mantine-scale))}.m-60c222c7{bottom:0;pointer-events:none;position:fixed;top:0;width:100%;z-index:var(--mb-z-index)}.m-fd1ab0aa{box-shadow:var(--mb-shadow,var(--mantine-shadow-xl));pointer-events:all}.m-606cb269{margin-left:var(--_close-ml,auto);margin-right:var(--_close-mr,0)}[dir=rtl] .m-606cb269{--_close-ml:0;--_close-mr:auto}.m-5df29311{padding:var(--mb-padding,var(--mantine-spacing-md));padding-top:var(--_pt,var(--mb-padding,var(--mantine-spacing-md)))}.m-5df29311:not(:only-child){--_pt:0}.m-6c018570{--input-height-xs:calc(1.875rem*var(--mantine-scale));--input-height-sm:calc(2.25rem*var(--mantine-scale));--input-height-md:calc(2.625rem*var(--mantine-scale));--input-height-lg:calc(3.125rem*var(--mantine-scale));--input-height-xl:calc(3.75rem*var(--mantine-scale));--input-padding-y-xs:calc(.3125rem*var(--mantine-scale));--input-padding-y-sm:calc(.375rem*var(--mantine-scale));--input-padding-y-md:calc(.5rem*var(--mantine-scale));--input-padding-y-lg:calc(.625rem*var(--mantine-scale));--input-padding-y-xl:calc(.8125rem*var(--mantine-scale));--_input-height:var(--input-height,var(--input-height-sm));--_input-radius:var(--input-radius,var(--mantine-radius-default));--_input-cursor:text;--_input-text-align:left;--_input-line-height:calc(var(--_input-height) - .125rem*var(--mantine-scale));--_input-padding:calc(var(--_input-height)/3);--_input-padding-left:var(--_input-padding);--_input-padding-right:var(--_input-padding);--_input-placeholder-color:var(--mantine-color-placeholder);--_input-color:var(--mantine-color-text);--_input-left-section-size:var( --input-left-section-width,calc(var(--_input-height) - .125rem*var(--mantine-scale)) );--_input-right-section-size:var( --input-right-section-width,calc(var(--_input-height) - .125rem*var(--mantine-scale)) );--_input-size:var(--_input-height);--_section-y:calc(.0625rem*var(--mantine-scale));--_left-section-left:calc(.0625rem*var(--mantine-scale));--_left-section-right:unset;--_left-section-border-radius:var(--_input-radius) 0 0 var(--_input-radius);--_right-section-left:unset;--_right-section-right:calc(.0625rem*var(--mantine-scale));--_right-section-border-radius:0 var(--_input-radius) var(--_input-radius) 0;margin-bottom:var(--input-margin-bottom,0);margin-top:var(--input-margin-top,0);position:relative}.m-6c018570[data-variant=unstyled]{--input-padding:0;--input-padding-y:0;--_input-padding-left:0;--_input-padding-right:0}.m-6c018570[data-pointer]{--_input-cursor:pointer}.m-6c018570[data-multiline]{--input-padding-y-xs:calc(.28125rem*var(--mantine-scale));--input-padding-y-sm:calc(.34375rem*var(--mantine-scale));--input-padding-y-md:calc(.4375rem*var(--mantine-scale));--input-padding-y-lg:calc(.59375rem*var(--mantine-scale));--input-padding-y-xl:calc(.8125rem*var(--mantine-scale));--_input-size:auto;--_input-line-height:var(--mantine-line-height);--input-padding-y:var(--input-padding-y-sm)}.m-6c018570[data-with-left-section]{--_input-padding-left:var(--_input-left-section-size)}[dir=rtl] .m-6c018570[data-with-left-section]{--_input-padding-right:var(--_input-left-section-size)}[dir=rtl] .m-6c018570[data-with-left-section]:not([data-with-right-section]){--_input-padding-left:var(--_input-padding)}.m-6c018570[data-with-right-section]{--_input-padding-right:var(--_input-right-section-size)}[dir=rtl] .m-6c018570[data-with-right-section]{--_input-padding-left:var(--_input-right-section-size)}[dir=rtl] .m-6c018570[data-with-right-section]:not([data-with-left-section]){--_input-padding-right:var(--_input-padding)}[data-mantine-color-scheme=light] .m-6c018570{--_input-disabled-bg:var(--mantine-color-gray-1);--_input-disabled-color:var(--mantine-color-gray-6)}[data-mantine-color-scheme=light] .m-6c018570[data-variant=default]{--_input-bd:var(--mantine-color-gray-4);--_input-bg:var(--mantine-color-white);--_input-bd-focus:var(--mantine-primary-color-filled)}[data-mantine-color-scheme=light] .m-6c018570[data-variant=filled]{--_input-bd:transparent;--_input-bg:var(--mantine-color-gray-1);--_input-bd-focus:var(--mantine-primary-color-filled)}[data-mantine-color-scheme=light] .m-6c018570[data-variant=unstyled]{--_input-bd:transparent;--_input-bg:transparent;--_input-bd-focus:transparent}[data-mantine-color-scheme=dark] .m-6c018570{--_input-disabled-bg:var(--mantine-color-dark-6);--_input-disabled-color:var(--mantine-color-dark-2)}[data-mantine-color-scheme=dark] .m-6c018570[data-variant=default]{--_input-bd:var(--mantine-color-dark-4);--_input-bg:var(--mantine-color-dark-6);--_input-bd-focus:var(--mantine-primary-color-filled)}[data-mantine-color-scheme=dark] .m-6c018570[data-variant=filled]{--_input-bd:transparent;--_input-bg:var(--mantine-color-dark-5);--_input-bd-focus:var(--mantine-primary-color-filled)}[data-mantine-color-scheme=dark] .m-6c018570[data-variant=unstyled]{--_input-bd:transparent;--_input-bg:transparent;--_input-bd-focus:transparent}[data-mantine-color-scheme] .m-6c018570[data-error]:not([data-variant=unstyled]){--_input-bd:var(--mantine-color-error)}[data-mantine-color-scheme] .m-6c018570[data-error]{--_input-color:var(--mantine-color-error);--_input-placeholder-color:var(--mantine-color-error);--_input-section-color:var(--mantine-color-error)}[dir=rtl] .m-6c018570{--_input-text-align:right;--_left-section-left:unset;--_left-section-right:calc(.0625rem*var(--mantine-scale));--_left-section-border-radius:0 var(--_input-radius) var(--_input-radius) 0;--_right-section-left:calc(.0625rem*var(--mantine-scale));--_right-section-right:unset;--_right-section-border-radius:var(--_input-radius) 0 0 var(--_input-radius)}.m-8fb7ebe7{-webkit-tap-highlight-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--_input-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_input-bd);border-radius:var(--_input-radius);color:var(--_input-color);cursor:var(--_input-cursor);display:block;font-family:var(--_input-font-family,var(--mantine-font-family));font-size:var(--_input-fz,var(--input-fz,var(--mantine-font-size-sm)));height:var(--_input-size);line-height:var(--_input-line-height);min-height:var(--_input-height);overflow:var(--_input-overflow);padding:var(--input-padding-y,0) var(--_input-padding-right) var(--input-padding-y,0) var(--_input-padding-left);resize:none;text-align:var(--_input-text-align);transition:border-color .1s ease;width:100%}.m-8fb7ebe7[data-no-overflow]{--_input-overflow:hidden}.m-8fb7ebe7[data-monospace]{--_input-font-family:var(--mantine-font-family-monospace);--_input-fz:calc(var(--input-fz, var(--mantine-font-size-sm)) - .125rem*var(--mantine-scale))}.m-8fb7ebe7:focus,.m-8fb7ebe7:focus-within{--_input-bd:var(--_input-bd-focus);outline:none}[data-error] .m-8fb7ebe7:focus,[data-error] .m-8fb7ebe7:focus-within{--_input-bd:var(--mantine-color-error)}.m-8fb7ebe7::placeholder{color:var(--_input-placeholder-color);opacity:1}.m-8fb7ebe7::-webkit-inner-spin-button,.m-8fb7ebe7::-webkit-outer-spin-button,.m-8fb7ebe7::-webkit-search-cancel-button,.m-8fb7ebe7::-webkit-search-decoration,.m-8fb7ebe7::-webkit-search-results-button,.m-8fb7ebe7::-webkit-search-results-decoration{-webkit-appearance:none;-moz-appearance:none;appearance:none}.m-8fb7ebe7[type=number]{-moz-appearance:textfield}.m-8fb7ebe7:disabled,.m-8fb7ebe7[data-disabled]{background-color:var(--_input-disabled-bg);color:var(--_input-disabled-color);cursor:not-allowed;opacity:.6}.m-8fb7ebe7:has(input:disabled){background-color:var(--_input-disabled-bg);color:var(--_input-disabled-color);cursor:not-allowed;opacity:.6}.m-82577fc2{align-items:center;border-radius:var(--_section-border-radius);bottom:var(--_section-y);color:var(--mantine-color-dimmed);display:flex;justify-content:center;left:var(--_section-left);pointer-events:var(--_section-pointer-events);position:absolute;right:var(--_section-right);top:var(--_section-y);width:var(--_section-size);z-index:1}.m-82577fc2[data-position=right]{--_section-pointer-events:var(--input-right-section-pointer-events);--_section-left:var(--_right-section-left);--_section-right:var(--_right-section-right);--_section-size:var(--_input-right-section-size);--_section-border-radius:var(--_right-section-border-radius)}.m-82577fc2[data-position=left]{--_section-pointer-events:var(--input-left-section-pointer-events);--_section-left:var(--_left-section-left);--_section-right:var(--_left-section-right);--_section-size:var(--_input-left-section-size);--_section-border-radius:var(--_left-section-border-radius)}.m-88bacfd0{color:var(--_input-placeholder-color,var(--mantine-color-placeholder))}[data-error] .m-88bacfd0{--_input-placeholder-color:var(--_input-color,var(--mantine-color-placeholder))}.m-46b77525{line-height:var(--mantine-line-height)}.m-8fdc1311{-webkit-tap-highlight-color:transparent;cursor:default;display:inline-block;font-size:var(--input-label-size,var(--mantine-font-size-sm));font-weight:500;word-break:break-word}.m-78a94662{color:var(--input-asterisk-color,var(--mantine-color-error))}.m-8f816625,.m-fe47ce59{word-wrap:break-word;display:block;line-height:1.2;margin:0;padding:0}.m-8f816625{color:var(--mantine-color-error);font-size:var(--input-error-size,calc(var(--mantine-font-size-sm) - .125rem*var(--mantine-scale)))}.m-fe47ce59{color:var(--mantine-color-dimmed);font-size:var(--input-description-size,calc(var(--mantine-font-size-sm) - .125rem*var(--mantine-scale)))}.m-8bffd616{display:flex}.m-9bdbb667{--_accordion-radius:var(--accordion-radius,var(--mantine-radius-default))}.m-df78851f{word-break:break-word}.m-4ba554d4{padding:var(--mantine-spacing-md);padding-top:calc(var(--mantine-spacing-xs)/2)}.m-8fa820a0{margin:0;padding:0}.m-4ba585b8{align-items:center;background-color:var(--_control-background-color,transparent);color:var(--_control-color);cursor:var(--_control-cursor,pointer);display:flex;flex-direction:var(--_control-flex-direction,row-reverse);opacity:var(--_control-opacity,1);padding-left:var(--_control-padding-left,var(--mantine-spacing-md));padding-right:var(--_control-padding-right,var(--mantine-spacing-md));text-align:left;width:100%}.m-4ba585b8[data-chevron-position=left]{--_control-flex-direction:row;--_control-padding-left:0}[dir=rtl] .m-4ba585b8[data-chevron-position=left]{--_control-padding-left:var(--mantine-spacing-md)}[data-mantine-color-scheme=light] .m-4ba585b8{--_control-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-4ba585b8{--_control-color:var(--mantine-color-dark-0)}.m-4ba585b8:disabled,.m-4ba585b8[data-disabled]{--_control-opacity:.4;--_control-cursor:not-allowed}@media (hover:hover){[data-mantine-color-scheme=light] .m-4271d21b:not(:disabled,[data-disabled]):hover,[data-mantine-color-scheme=light] .m-6939a5e9:not(:disabled,[data-disabled]):hover{--_control-background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-4271d21b:not(:disabled,[data-disabled]):hover,[data-mantine-color-scheme=dark] .m-6939a5e9:not(:disabled,[data-disabled]):hover{--_control-background-color:var(--mantine-color-dark-6)}}@media (hover:none){[data-mantine-color-scheme=light] .m-4271d21b:not(:disabled,[data-disabled]):active,[data-mantine-color-scheme=light] .m-6939a5e9:not(:disabled,[data-disabled]):active{--_control-background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-4271d21b:not(:disabled,[data-disabled]):active,[data-mantine-color-scheme=dark] .m-6939a5e9:not(:disabled,[data-disabled]):active{--_control-background-color:var(--mantine-color-dark-6)}}.m-df3ffa0f{color:inherit;flex:1;font-weight:400;overflow:hidden;padding-bottom:var(--mantine-spacing-sm);padding-top:var(--mantine-spacing-sm);text-overflow:ellipsis}[dir=rtl] .m-df3ffa0f{text-align:right}.m-3f35ae96{align-items:center;display:flex;justify-content:flex-start;margin-left:var(--_chevron-margin-left);margin-right:var(--_chevron-margin-right);min-width:var(--accordion-chevron-size,calc(.9375rem*var(--mantine-scale)));transform:var(--_chevron-transform,rotate(0deg));transition:transform var(--accordion-transition-duration,.2s) ease;width:var(--accordion-chevron-size,calc(.9375rem*var(--mantine-scale)))}.m-3f35ae96[data-rotate]{--_chevron-transform:rotate(180deg)}.m-3f35ae96[data-position=left]{--_chevron-margin-right:var(--mantine-spacing-md);--_chevron-margin-left:var(--mantine-spacing-md)}.m-3f35ae96[data-position=right]{--_chevron-margin-left:0}[dir=rtl] .m-3f35ae96[data-position=left]{--_chevron-margin-right:0;--_chevron-margin-left:var(--mantine-spacing-md)}[dir=rtl] .m-3f35ae96[data-position=right]{--_chevron-margin-right:var(--mantine-spacing-md);--_chevron-margin-left:0}.m-9bd771fe{align-items:center;display:flex;justify-content:center;margin-left:var(--_icon-margin-left,0);margin-right:var(--_icon-margin-right,var(--mantine-spacing-sm))}.m-9bd771fe[data-chevron-position=left]{--_icon-margin-right:0;--_icon-margin-left:var(--mantine-spacing-lg)}[dir=rtl] .m-9bd771fe[data-chevron-position=left]{--_icon-margin-right:var(--mantine-spacing-lg);--_icon-margin-left:0}[dir=rtl] .m-9bd771fe[data-chevron-position=right]{--_icon-margin-right:0;--_icon-margin-left:var(--mantine-spacing-sm)}.m-9bd7b098{background-color:var(--_item-bg)}[data-mantine-color-scheme=light] .m-9bd7b098{--_item-border-color:var(--mantine-color-gray-3);--_item-filled-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-9bd7b098{--_item-border-color:var(--mantine-color-dark-4);--_item-filled-color:var(--mantine-color-dark-6)}.m-fe19b709{border-bottom:calc(.0625rem*var(--mantine-scale)) solid var(--_item-border-color)}.m-1f921b3b{border:calc(.0625rem*var(--mantine-scale)) solid var(--_item-border-color);transition:background-color .15s ease}.m-1f921b3b[data-active]{--_item-bg:var(--_item-filled-color)}.m-1f921b3b:first-of-type,.m-1f921b3b:first-of-type>[data-accordion-control]{border-top-left-radius:var(--_accordion-radius);border-top-right-radius:var(--_accordion-radius)}.m-1f921b3b:last-of-type,.m-1f921b3b:last-of-type>[data-accordion-control]{border-bottom-left-radius:var(--_accordion-radius);border-bottom-right-radius:var(--_accordion-radius)}.m-1f921b3b+.m-1f921b3b{border-top:0}.m-2cdf939a{border-radius:var(--_accordion-radius)}.m-2cdf939a[data-active],.m-9f59b069{--_item-bg:var(--_item-filled-color)}.m-9f59b069{border:calc(.0625rem*var(--mantine-scale)) solid var(--__item-border-color,transparent);border-radius:var(--_accordion-radius);transition:background-color .15s ease}.m-9f59b069[data-active]{--__item-border-color:var(--_item-border-color)}[data-mantine-color-scheme=light] .m-9f59b069[data-active]{--_item-bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-9f59b069[data-active]{--_item-bg:var(--mantine-color-dark-7)}.m-9f59b069+.m-9f59b069{margin-top:var(--mantine-spacing-md)}.m-7f854edf{bottom:var(--affix-bottom);left:var(--affix-left);position:fixed;right:var(--affix-right);top:var(--affix-top);z-index:var(--affix-z-index)}.m-66836ed3{background-color:var(--alert-bg,var(--mantine-primary-color-light));border:var(--alert-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--alert-radius,var(--mantine-radius-default));color:var(--alert-color,var(--mantine-primary-color-light-color));overflow:hidden;padding:var(--mantine-spacing-md) var(--mantine-spacing-md);position:relative}.m-12b2e6d5{--_message-color:var(--alert-color,var(--mantine-primary-color-light-color))}.m-cffd1856{--_message-color:var(--mantine-color-black)}.m-667c2793,.m-a5d60502{display:flex}.m-667c2793{flex:1;flex-direction:column;gap:var(--mantine-spacing-xs)}.m-6a03f287{align-items:center;display:flex;font-size:var(--mantine-font-size-sm);font-weight:700;justify-content:space-between}.m-6a03f287[data-with-close-button]{padding-right:var(--mantine-spacing-md)}[dir=rtl] .m-6a03f287[data-with-close-button]{padding-left:var(--mantine-spacing-md);padding-right:0}.m-698f4f23{display:block;overflow:hidden;text-overflow:ellipsis}.m-667f2a6a{align-items:center;display:flex;height:calc(1.25rem*var(--mantine-scale));justify-content:flex-start;line-height:1;margin-right:var(--mantine-spacing-md);margin-top:calc(.0625rem*var(--mantine-scale));width:calc(1.25rem*var(--mantine-scale))}[dir=rtl] .m-667f2a6a{margin-left:var(--mantine-spacing-md);margin-right:0}.m-7fa78076{color:var(--_message-color,var(--__message-color));font-size:var(--mantine-font-size-sm);overflow:hidden;text-overflow:ellipsis}[data-mantine-color-scheme=light] .m-7fa78076{--__message-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-7fa78076{--__message-color:var(--mantine-color-white)}.m-87f54839{color:var(--alert-color,var(--mantine-primary-color-light-color));height:calc(1.25rem*var(--mantine-scale));margin-top:calc(var(--mantine-spacing-sm)*-.5);width:calc(1.25rem*var(--mantine-scale))}.m-b6d8b162{-webkit-tap-highlight-color:transparent;color:var(--text-color);font-size:var(--text-fz,var(--mantine-font-size-md));font-weight:400;line-height:var(--_text-line-height,var(--text-lh,var(--mantine-line-height-md)));margin:0;padding:0;text-decoration:none}.m-b6d8b162[data-truncate]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.m-b6d8b162[data-truncate=start]{direction:rtl;text-align:right}[dir=rtl] .m-b6d8b162[data-truncate=start]{direction:ltr;text-align:left}.m-b6d8b162[data-variant=gradient]{-webkit-text-fill-color:transparent;background-clip:text;-webkit-background-clip:text;background-image:var(--text-gradient)}.m-b6d8b162[data-line-clamp]{-webkit-line-clamp:var(--text-line-clamp);-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden;text-overflow:ellipsis}.m-b6d8b162[data-inherit]{font-size:inherit;font-weight:inherit;line-height:inherit}.m-b6d8b162[data-inline]{--_text-line-height:1}.m-849cf0da{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:none;color:var(--mantine-color-anchor);cursor:pointer;display:inline;margin:0;padding:0;text-decoration:var(--_text-decoration,none)}@media (hover:hover){.m-849cf0da[data-underline=hover]:hover{--_text-decoration:underline}}@media (hover:none){.m-849cf0da[data-underline=hover]:active{--_text-decoration:underline}}.m-849cf0da[data-underline=always]{--_text-decoration:underline}.m-89ab340[data-resizing]{--app-shell-transition-duration:0ms!important}.m-89ab340[data-disabled]{--app-shell-header-offset:0px!important;--app-shell-navbar-offset:0px!important}[data-mantine-color-scheme=light] .m-89ab340{--_app-shell-border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-89ab340{--_app-shell-border-color:var(--mantine-color-dark-4)}.m-3840c879,.m-3b16f56b,.m-45252eee,.m-8983817,.m-9cdde9a{transition-duration:var(--app-shell-transition-duration);transition-timing-function:var(--app-shell-transition-timing-function)}.m-45252eee,.m-9cdde9a{background-color:var(--mantine-color-body);display:flex;flex-direction:column;height:var( --_section-height,calc(100dvh - var(--app-shell-header-offset, 0px) - var(--app-shell-footer-offset, 0px)) );position:fixed;top:var(--_section-top,var(--app-shell-header-offset,0));transition-property:transform,top,height}[data-layout=alt] .m-45252eee,[data-layout=alt] .m-9cdde9a{--_section-top:0px;--_section-height:100dvh}.m-45252eee{border-left:var(--_navbar-border-left);border-right:var(--_navbar-border-right);left:var(--_navbar-left,0);right:var(--_navbar-right);transform:var(--_navbar-transform,var(--app-shell-navbar-transform));transition-property:transform,top,height;width:var(--app-shell-navbar-width);z-index:var(--app-shell-navbar-z-index)}.m-45252eee[data-with-border]{--_navbar-border-right:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}[dir=rtl] .m-45252eee[data-with-border]{--_navbar-border-right:none;--_navbar-border-left:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}[dir=rtl] .m-45252eee{--_navbar-left:auto;--_navbar-right:0px;--_navbar-transform:var(--app-shell-navbar-transform-rtl)}.m-9cdde9a{border-left:var(--_aside-border-left);border-right:var(--_aside-border-right);left:var(--_aside-left);right:var(--_aside-right,0);transform:var(--_aside-transform,var(--app-shell-aside-transform));width:var(--app-shell-aside-width);z-index:var(--app-shell-aside-z-index)}.m-9cdde9a[data-with-border]{--_aside-border-left:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}[dir=rtl] .m-9cdde9a[data-with-border]{--_aside-border-left:none;--_aside-border-right:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}[dir=rtl] .m-9cdde9a{--_aside-left:0px;--_aside-right:auto;--_aside-transform:var(--app-shell-aside-transform-rtl)}.m-8983817{min-height:100dvh;padding:calc(var(--app-shell-header-offset, 0px) + var(--app-shell-padding)) var( --_main-padding-right,calc(var(--app-shell-aside-offset, 0px) + var(--app-shell-padding)) ) calc(var(--app-shell-footer-offset, 0px) + var(--app-shell-padding)) var( --_main-padding-left,calc(var(--app-shell-navbar-offset, 0px) + var(--app-shell-padding)) );transition-property:padding}[dir=rtl] .m-8983817{--_main-padding-left:calc(var(--app-shell-aside-offset, 0px) + var(--app-shell-padding));--_main-padding-right:calc(var(--app-shell-navbar-offset, 0px) + var(--app-shell-padding))}.m-3840c879,.m-3b16f56b{background-color:var(--mantine-color-body);left:var(--_section-left,0);position:fixed;right:var(--_section-right,0);transition-property:transform,left,right}[data-layout=alt] .m-3840c879,[data-layout=alt] .m-3b16f56b{--_section-left:var(--app-shell-navbar-offset,0px)}[dir=rtl] [data-layout=alt] .m-3840c879,[dir=rtl] [data-layout=alt] .m-3b16f56b{--_section-right:var(--app-shell-navbar-offset,0px);--_section-left:0px}.m-3b16f56b{background-color:var(--mantine-color-body);border-bottom:var(--_header-border-bottom);height:var(--app-shell-header-height);top:0;transform:var(--app-shell-header-transform);z-index:var(--app-shell-header-z-index)}.m-3b16f56b[data-with-border]{--_header-border-bottom:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}.m-3840c879{border-top:var(--_footer-border-top);bottom:0;height:var(--app-shell-footer-height);transform:var(--app-shell-footer-transform);z-index:var(--app-shell-footer-z-index)}.m-3840c879[data-with-border]{--_footer-border-top:calc(.0625rem*var(--mantine-scale)) solid var(--_app-shell-border-color)}.m-6dcfc7c7{flex-grow:var(--_section-grow,0)}.m-6dcfc7c7[data-grow]{--_section-grow:1}.m-71ac47fc{max-width:100%;position:relative}.m-71ac47fc:before{content:"";display:block;height:0;padding-bottom:calc((1/var(--ar-ratio, 1))*100%)}.m-71ac47fc:after{clear:both;content:"";display:table}.m-71ac47fc>:not(style){align-items:center;display:flex;height:100%;top:0;right:0;bottom:0;left:0;justify-content:center;position:absolute;width:100%}.m-71ac47fc>img,.m-71ac47fc>video{object-fit:cover}.m-88b62a41{--_combobox-padding:var(--combobox-padding,calc(.25rem*var(--mantine-scale)));padding:var(--_combobox-padding)}.m-88b62a41[data-hidden]{display:none}.m-88b62a41,.m-b2821a6e{--combobox-option-padding-xs:calc(.25rem*var(--mantine-scale)) calc(.5rem*var(--mantine-scale));--combobox-option-padding-sm:calc(.375rem*var(--mantine-scale)) calc(.625rem*var(--mantine-scale));--combobox-option-padding-md:calc(.5rem*var(--mantine-scale)) calc(.75rem*var(--mantine-scale));--combobox-option-padding-lg:calc(.625rem*var(--mantine-scale)) calc(1rem*var(--mantine-scale));--combobox-option-padding-xl:calc(.875rem*var(--mantine-scale)) calc(1.25rem*var(--mantine-scale));--_combobox-option-padding:var(--combobox-option-padding,var(--combobox-option-padding-sm))}.m-92253aa5{background-color:var(--_option-bg,transparent);border-radius:var(--mantine-radius-default);color:var(--_option-color,inherit);cursor:var(--_option-cursor,pointer);font-size:var(--combobox-option-fz,var(--mantine-font-size-sm));opacity:var(--_option-opacity,1);padding:var(--_combobox-option-padding);word-break:break-word}.m-92253aa5[data-combobox-selected]{--_option-bg:var(--mantine-primary-color-filled);--_option-color:var(--mantine-color-white)}.m-92253aa5[data-combobox-disabled]{--_option-cursor:not-allowed;--_option-opacity:.35}@media (hover:hover){[data-mantine-color-scheme=light] .m-92253aa5:hover:not([data-combobox-selected],[data-combobox-disabled]){--_option-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-92253aa5:hover:not([data-combobox-selected],[data-combobox-disabled]){--_option-bg:var(--mantine-color-dark-7)}}@media (hover:none){[data-mantine-color-scheme=light] .m-92253aa5:active:not([data-combobox-selected],[data-combobox-disabled]){--_option-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-92253aa5:active:not([data-combobox-selected],[data-combobox-disabled]){--_option-bg:var(--mantine-color-dark-7)}}.m-985517d8{background-color:var(--_search_background);border-bottom-left-radius:0;border-bottom-right-radius:0;border-left-width:0;border-right-width:0;border-top-width:0;margin:calc(var(--_combobox-padding)*-1) calc(var(--_combobox-padding)*-1) var(--_combobox-padding);position:relative;width:calc(100% + var(--_combobox-padding)*2);z-index:1000}.m-985517d8,.m-985517d8:focus{border-color:var(--_search-border-color)}[data-mantine-color-scheme=light] .m-985517d8{--_search-border-color:var(--mantine-color-gray-2);--_search_background:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-985517d8{--_search-border-color:var(--mantine-color-dark-4);--_search_background:var(--mantine-color-dark-7)}.m-2530cd1d{color:var(--mantine-color-dimmed);text-align:center}.m-2530cd1d,.m-82b967cb,.m-858f94bd{font-size:var(--combobox-option-fz,var(--mantine-font-size-sm));padding:var(--_combobox-option-padding)}.m-82b967cb,.m-858f94bd{border:0 solid var(--_footer-border-color);margin-left:calc(var(--_combobox-padding)*-1);margin-right:calc(var(--_combobox-padding)*-1)}[data-mantine-color-scheme=light] .m-82b967cb,[data-mantine-color-scheme=light] .m-858f94bd{--_footer-border-color:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-82b967cb,[data-mantine-color-scheme=dark] .m-858f94bd{--_footer-border-color:var(--mantine-color-dark-4)}.m-82b967cb{border-top-width:calc(.0625rem*var(--mantine-scale));margin-bottom:calc(var(--_combobox-padding)*-1);margin-top:var(--_combobox-padding)}.m-858f94bd{border-bottom-width:calc(.0625rem*var(--mantine-scale));margin-bottom:var(--_combobox-padding);margin-top:calc(var(--_combobox-padding)*-1)}.m-254f3e4f:has(.m-2bb2e9e5:only-child){display:none}.m-2bb2e9e5{align-items:center;color:var(--mantine-color-dimmed);display:flex;font-size:calc(var(--combobox-option-fz, var(--mantine-font-size-sm))*.85);font-weight:500;padding:var(--_combobox-option-padding);position:relative}.m-2bb2e9e5:after{background-color:var(--_divider-bg);content:"";flex:1;height:calc(.0625rem*var(--mantine-scale));left:0;margin-left:var(--mantine-spacing-xs);right:0}[data-mantine-color-scheme=light] .m-2bb2e9e5:after{--_divider-bg:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-2bb2e9e5:after{--_divider-bg:var(--mantine-color-dark-4)}[dir=rtl] .m-2bb2e9e5:after{margin-left:unset;margin-right:var(--mantine-spacing-xs)}.m-2bb2e9e5:only-child{display:none}.m-2943220b{--combobox-chevron-size-xs:calc(.875rem*var(--mantine-scale));--combobox-chevron-size-sm:calc(1.125rem*var(--mantine-scale));--combobox-chevron-size-md:calc(1.25rem*var(--mantine-scale));--combobox-chevron-size-lg:calc(1.5rem*var(--mantine-scale));--combobox-chevron-size-xl:calc(1.75rem*var(--mantine-scale));--combobox-chevron-size:var(--combobox-chevron-size-sm);color:var(--_color);height:var(--combobox-chevron-size);width:var(--combobox-chevron-size)}[data-mantine-color-scheme=light] .m-2943220b{--_color:var(--mantine-color-gray-6)}[data-mantine-color-scheme=dark] .m-2943220b{--_color:var(--mantine-color-dark-3)}.m-2943220b[data-error]{--_color:var(--mantine-color-error)}.m-71d052f9{margin-right:calc(var(--_combobox-padding)*-1)}[dir=rtl] .m-71d052f9{margin-left:calc(var(--_combobox-padding)*-1);margin-right:0}.m-390b5f4{align-items:center;display:flex;flex-direction:var(--_flex-direction,row);gap:calc(.5rem*var(--mantine-scale))}.m-390b5f4[data-reverse]{justify-content:space-between}.m-8ee53fc2{height:.8em;min-width:.8em;opacity:.4;width:.8em}[data-combobox-selected] .m-8ee53fc2{opacity:1}.m-5f75b09e{--label-lh-xs:calc(1rem*var(--mantine-scale));--label-lh-sm:calc(1.25rem*var(--mantine-scale));--label-lh-md:calc(1.5rem*var(--mantine-scale));--label-lh-lg:calc(1.875rem*var(--mantine-scale));--label-lh-xl:calc(2.25rem*var(--mantine-scale));--label-lh:var(--label-lh-sm)}.m-5f75b09e[data-label-position=left]{--_label-order:1;--_offset-right:var(--mantine-spacing-sm);--_offset-left:0}[dir=rtl] .m-5f75b09e[data-label-position=left]{--_offset-right:0;--_offset-left:var(--mantine-spacing-sm)}.m-5f75b09e[data-label-position=right]{--_label-order:2;--_offset-right:0;--_offset-left:var(--mantine-spacing-sm)}[dir=rtl] .m-5f75b09e[data-label-position=right]{--_offset-right:var(--mantine-spacing-sm);--_offset-left:0}.m-5f6e695e{display:flex}.m-d3ea56bb{-webkit-tap-highlight-color:transparent;display:inline-flex;flex-direction:column;font-size:var(--label-fz,var(--mantine-font-size-sm));line-height:var(--label-lh);order:var(--_label-order)}.m-8ee546b8,.m-d3ea56bb{cursor:var(--mantine-cursor-type)}.m-8ee546b8{color:var(--_label-color,inherit);padding-left:var(--_offset-left);padding-right:var(--_offset-right)}[data-mantine-color-scheme=light] .m-8ee546b8[data-disabled],[data-mantine-color-scheme=light] fieldset:disabled .m-8ee546b8{--_label-color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m-8ee546b8[data-disabled],[data-mantine-color-scheme=dark] fieldset:disabled .m-8ee546b8{--_label-color:var(--mantine-color-dark-3)}.m-328f68c0,.m-8e8a99cc{margin-top:calc(var(--mantine-spacing-xs)/2);padding-left:var(--_offset-left);padding-right:var(--_offset-right)}.m-bf2d988c{--checkbox-size-xs:calc(1rem*var(--mantine-scale));--checkbox-size-sm:calc(1.25rem*var(--mantine-scale));--checkbox-size-md:calc(1.5rem*var(--mantine-scale));--checkbox-size-lg:calc(1.875rem*var(--mantine-scale));--checkbox-size-xl:calc(2.25rem*var(--mantine-scale));--checkbox-size:var(--checkbox-size-sm);--checkbox-color:var(--mantine-primary-color-filled);--checkbox-icon-color:var(--mantine-color-white)}.m-26062bec{height:var(--checkbox-size);order:var(--_checkbox-inner-order,1);position:relative;width:var(--checkbox-size)}.m-26062bec[data-label-position=left]{--_checkbox-inner-order:2}.m-26063560{-webkit-tap-highlight-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--_checkbox-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_checkbox-bd-color);border-radius:var(--checkbox-radius,var(--mantine-radius-default));cursor:var(--_checkbox-cursor,var(--mantine-cursor-type));display:block;height:var(--checkbox-size);margin:0;padding:0;transition:border-color .1s ease,background-color .1s ease;width:var(--checkbox-size)}[data-mantine-color-scheme=light] .m-26063560{--_checkbox-bg:var(--mantine-color-white);--_checkbox-bd-color:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-26063560{--_checkbox-bg:var(--mantine-color-dark-6);--_checkbox-bd-color:var(--mantine-color-dark-4)}.m-26063560[data-error]{--_checkbox-bd-color:var(--mantine-color-error)}[data-mantine-color-scheme] .m-26063560:checked,[data-mantine-color-scheme] .m-26063560[data-indeterminate]{--_checkbox-bg:var(--checkbox-color);--_checkbox-bd-color:var(--checkbox-color)}[data-mantine-color-scheme] .m-26063560:checked+.m-bf295423,[data-mantine-color-scheme] .m-26063560[data-indeterminate]+.m-bf295423{--_checkbox-icon-opacity:1;--_checkbox-icon-transform:none}.m-26063560:disabled{--_checkbox-cursor:not-allowed}[data-mantine-color-scheme=light] .m-26063560:disabled{--_checkbox-bg:var(--mantine-color-gray-2);--_checkbox-bd-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-26063560:disabled{--_checkbox-bg:var(--mantine-color-dark-6);--_checkbox-bd-color:var(--mantine-color-dark-6)}[data-mantine-color-scheme=light] .m-26063560:disabled+.m-bf295423{--_checkbox-icon-color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m-26063560:disabled+.m-bf295423{--_checkbox-icon-color:var(--mantine-color-dark-3)}.m-215c4542+.m-bf295423{--_checkbox-icon-color:var(--checkbox-color)}[data-mantine-color-scheme] .m-215c4542:checked:not(:disabled),[data-mantine-color-scheme] .m-215c4542[data-indeterminate]{--_checkbox-bg:transparent;--_checkbox-bd-color:var(--checkbox-color)}[data-mantine-color-scheme] .m-215c4542:checked:not(:disabled)+.m-bf295423,[data-mantine-color-scheme] .m-215c4542[data-indeterminate]+.m-bf295423{--_checkbox-icon-color:var(--checkbox-color);--_checkbox-icon-opacity:1;--_checkbox-icon-transform:none}.m-bf295423{bottom:0;color:var(--_checkbox-icon-color,var(--checkbox-icon-color));left:0;margin:auto;opacity:var(--_checkbox-icon-opacity,0);pointer-events:none;position:absolute;right:0;top:0;transform:var(--_checkbox-icon-transform,translateY(calc(.3125rem*var(--mantine-scale))) scale(.5));transition:transform .1s ease,opacity .1s ease;width:60%}.m-f85678b6{--avatar-size-xs:calc(1rem*var(--mantine-scale));--avatar-size-sm:calc(1.625rem*var(--mantine-scale));--avatar-size-md:calc(2.375rem*var(--mantine-scale));--avatar-size-lg:calc(3.5rem*var(--mantine-scale));--avatar-size-xl:calc(5.25rem*var(--mantine-scale));--_avatar-size:var(--avatar-size,var(--avatar-size-md));-webkit-tap-highlight-color:transparent;background-color:var(--_avatar-bg);border:var(--_avatar-border,none);border-radius:var(--avatar-radius,calc(62.5rem*var(--mantine-scale)));display:block;height:var(--_avatar-size);margin-left:var(--_avatar-ml,unset);margin-right:var(--_avatar-mr,unset);min-width:var(--_avatar-size);overflow:hidden;padding:0;position:relative;text-decoration:none;-webkit-user-select:none;user-select:none;width:var(--_avatar-size)}.m-f85678b6[data-within-group]{--_avatar-ml:calc(var(--ag-spacing, var(--mantine-spacing-sm))*-1);--_avatar-border:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-body);--_avatar-bg:var(--mantine-color-body)}[dir=rtl] .m-f85678b6[data-within-group]{--_avatar-mr:calc(var(--ag-spacing, var(--mantine-spacing-sm))*-1);--_avatar-ml:unset}.m-11f8ac07{display:block;height:100%;object-fit:cover;width:100%}.m-104cd71f{align-items:center;background:var(--avatar-bg,var(--mantine-color-gray-light));border:var(--avatar-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--avatar-radius);color:var(--avatar-color,var(--mantine-color-gray-light-color));display:flex;font-size:calc(var(--_avatar-size)/2.5);font-weight:700;height:100%;justify-content:center;-webkit-user-select:none;user-select:none;width:100%}.m-104cd71f>[data-avatar-placeholder-icon]{height:70%;width:70%}.m-11def92b{display:flex;padding-left:var(--ag-spacing,var(--mantine-spacing-sm))}[dir=rtl] .m-11def92b{padding-left:0;padding-right:var(--ag-spacing,var(--mantine-spacing-sm))}.m-2ce0de02{background-position:50%;background-size:cover;border:0;border-radius:var(--bi-radius,0);display:block;text-decoration:none;width:100%}.m-347db0ec{--badge-height-xs:calc(1rem*var(--mantine-scale));--badge-height-sm:calc(1.125rem*var(--mantine-scale));--badge-height-md:calc(1.25rem*var(--mantine-scale));--badge-height-lg:calc(1.625rem*var(--mantine-scale));--badge-height-xl:calc(2rem*var(--mantine-scale));--badge-fz-xs:calc(.5625rem*var(--mantine-scale));--badge-fz-sm:calc(.625rem*var(--mantine-scale));--badge-fz-md:calc(.6875rem*var(--mantine-scale));--badge-fz-lg:calc(.8125rem*var(--mantine-scale));--badge-fz-xl:calc(1rem*var(--mantine-scale));--badge-padding-x-xs:calc(.375rem*var(--mantine-scale));--badge-padding-x-sm:calc(.5rem*var(--mantine-scale));--badge-padding-x-md:calc(.625rem*var(--mantine-scale));--badge-padding-x-lg:calc(.75rem*var(--mantine-scale));--badge-padding-x-xl:calc(1rem*var(--mantine-scale));--badge-height:var(--badge-height-md);--badge-fz:var(--badge-fz-md);--badge-padding-x:var(--badge-padding-x-md);-webkit-tap-highlight-color:transparent;align-items:center;background:var(--badge-bg,var(--mantine-primary-color-filled));border:var(--badge-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--badge-radius,calc(625rem*var(--mantine-scale)));color:var(--badge-color,var(--mantine-color-white));cursor:inherit;display:var(--_badge-display,inline-flex);font-size:var(--badge-fz);font-weight:700;height:var(--badge-height);justify-content:center;letter-spacing:calc(.01563rem*var(--mantine-scale));line-height:calc(var(--badge-height) - .125rem*var(--mantine-scale));overflow:hidden;padding:0 var(--badge-padding-x);text-decoration:none;text-overflow:ellipsis;text-transform:uppercase;width:var(--_badge-width,fit-content)}.m-347db0ec[data-block]{--_badge-display:flex;--_badge-width:100%}.m-fbd81e3d{--badge-dot-size:calc(var(--badge-height)/3.4);background-color:var(--_badge-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_badge-border-color);color:var(--_badge-color)}[data-mantine-color-scheme=light] .m-fbd81e3d{--_badge-bg:var(--mantine-color-white);--_badge-border-color:var(--mantine-color-gray-4);--_badge-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-fbd81e3d{--_badge-bg:var(--mantine-color-dark-5);--_badge-border-color:var(--mantine-color-dark-5);--_badge-color:var(--mantine-color-white)}.m-fbd81e3d:before{background-color:var(--badge-dot-color);border-radius:var(--badge-dot-size);content:"";display:block;height:var(--badge-dot-size);margin-right:var(--badge-dot-size);width:var(--badge-dot-size)}[dir=rtl] .m-fbd81e3d:before{margin-left:var(--badge-dot-size);margin-right:0}.m-5add502a{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.m-91fdda9b{--_section-margin:calc(var(--mantine-spacing-xs)/2);align-items:center;display:inline-flex;justify-content:center}.m-91fdda9b[data-position=left]{margin-left:var(--_left-section-ml,0);margin-right:var(--_left-section-mr,var(--_section-margin))}[dir=rtl] .m-91fdda9b[data-position=left]{--_left-section-ml:var(--_section-margin);--_left-section-mr:0}.m-91fdda9b[data-position=right]{margin-left:var(--_right-section-ml,var(--_section-margin));margin-right:var(--_right-section-mr,0)}[dir=rtl] .m-91fdda9b[data-position=right]{--_right-section-mr:var(--_section-margin);--_right-section-ml:0}.m-ddec01c0{--_bq-border:calc(.1875rem*var(--mantine-scale)) solid var(--bq-bd);background-color:var(--_bq-bg);border-bottom-left-radius:var(--_bq-radius-left,0);border-bottom-right-radius:var(--_bq-radius-right,var(--bq-radius));border-left:var(--_bq-border-left,var(--_bq-border));border-right:var(--_bq-border-right,0);border-top-left-radius:var(--_bq-radius-left,0);border-top-right-radius:var(--_bq-radius-right,var(--bq-radius));margin:0;padding:var(--mantine-spacing-xl) calc(2.375rem*var(--mantine-scale));position:relative}[dir=rtl] .m-ddec01c0{--_bq-radius-left:var(--bq-radius);--_bq-radius-right:0;--_bq-border-left:0;--_bq-border-right:var(--_bq-border)}[data-mantine-color-scheme=light] .m-ddec01c0{--_bq-bg:var(--bq-bg-light)}[data-mantine-color-scheme=dark] .m-ddec01c0{--_bq-bg:var(--bq-bg-dark)}.m-dde7bd57{align-items:center;background-color:var(--mantine-color-body);border-radius:var(--bq-icon-size);color:var(--bq-bd);display:flex;height:var(--bq-icon-size);justify-content:center;left:var(--_bq-icon-left,calc(var(--bq-icon-size)/-2));position:absolute;right:var(--_bq-icon-right,0);top:calc(var(--bq-icon-size)/-2);width:var(--bq-icon-size)}[dir=rtl] .m-dde7bd57{--_bq-icon-left:0;--_bq-icon-right:calc(var(--bq-icon-size)/-2)}.m-dde51a35{display:block;font-size:85%;margin-top:var(--mantine-spacing-md);opacity:.6}.m-8b3717df{align-items:center;display:flex}.m-f678d540{-webkit-tap-highlight-color:transparent;line-height:1;white-space:nowrap}.m-3b8f2208{align-items:center;color:var(--_separator-color);display:flex;justify-content:center;line-height:1;margin-left:var(--bc-separator-margin,var(--mantine-spacing-xs));margin-right:var(--bc-separator-margin,var(--mantine-spacing-xs))}[data-mantine-color-scheme=light] .m-3b8f2208{--_separator-color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] .m-3b8f2208{--_separator-color:var(--mantine-color-dark-2)}.m-fea6bf1a{--burger-size-xs:calc(.75rem*var(--mantine-scale));--burger-size-sm:calc(1.125rem*var(--mantine-scale));--burger-size-md:calc(1.5rem*var(--mantine-scale));--burger-size-lg:calc(2.125rem*var(--mantine-scale));--burger-size-xl:calc(2.625rem*var(--mantine-scale));--burger-size:var(--burger-size-md);--_burger-color:var(--burger-color,var(--__burger-color));cursor:pointer;height:calc(var(--burger-size) + var(--mantine-spacing-xs));padding:calc(var(--mantine-spacing-xs)/2);width:calc(var(--burger-size) + var(--mantine-spacing-xs))}[data-mantine-color-scheme=light] .m-fea6bf1a{--__burger-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-fea6bf1a{--__burger-color:var(--mantine-color-white)}.m-d4fb9cad{position:relative;-webkit-user-select:none;user-select:none}.m-d4fb9cad,.m-d4fb9cad:after,.m-d4fb9cad:before{background-color:var(--_burger-color);display:block;height:calc(var(--burger-size)/12);outline:calc(.0625rem*var(--mantine-scale)) solid transparent;transition-duration:var(--burger-transition-duration,.3s);transition-property:background-color,transform;transition-timing-function:var(--burger-transition-timing-function,ease);width:var(--burger-size)}.m-d4fb9cad:after,.m-d4fb9cad:before{content:"";left:0;position:absolute}.m-d4fb9cad:before{top:calc(var(--burger-size)/-3)}.m-d4fb9cad:after{top:calc(var(--burger-size)/3)}.m-d4fb9cad[data-opened]{background-color:transparent}.m-d4fb9cad[data-opened]:before{transform:translateY(calc(var(--burger-size)/3)) rotate(45deg)}.m-d4fb9cad[data-opened]:after{transform:translateY(calc(var(--burger-size)/-3)) rotate(-45deg)}.m-77c9d27d{--button-height-xs:calc(1.875rem*var(--mantine-scale));--button-height-sm:calc(2.25rem*var(--mantine-scale));--button-height-md:calc(2.625rem*var(--mantine-scale));--button-height-lg:calc(3.125rem*var(--mantine-scale));--button-height-xl:calc(3.75rem*var(--mantine-scale));--button-height-compact-xs:calc(1.375rem*var(--mantine-scale));--button-height-compact-sm:calc(1.625rem*var(--mantine-scale));--button-height-compact-md:calc(1.875rem*var(--mantine-scale));--button-height-compact-lg:calc(2.125rem*var(--mantine-scale));--button-height-compact-xl:calc(2.5rem*var(--mantine-scale));--button-padding-x-xs:calc(.875rem*var(--mantine-scale));--button-padding-x-sm:calc(1.125rem*var(--mantine-scale));--button-padding-x-md:calc(1.375rem*var(--mantine-scale));--button-padding-x-lg:calc(1.625rem*var(--mantine-scale));--button-padding-x-xl:calc(2rem*var(--mantine-scale));--button-padding-x-compact-xs:calc(.4375rem*var(--mantine-scale));--button-padding-x-compact-sm:calc(.5rem*var(--mantine-scale));--button-padding-x-compact-md:calc(.625rem*var(--mantine-scale));--button-padding-x-compact-lg:calc(.75rem*var(--mantine-scale));--button-padding-x-compact-xl:calc(.875rem*var(--mantine-scale));--button-height:var(--button-height-sm);--button-padding-x:var(--button-padding-x-sm);--button-color:var(--mantine-color-white);background:var(--_button-bg,var(--button-bg,var(--mantine-primary-color-filled)));border:var(--_button-bd,var(--button-bd,calc(.0625rem*var(--mantine-scale)) solid transparent));border-radius:var(--button-radius,var(--mantine-radius-default));color:var(--_button-color,var(--button-color,var(--mantine-color-white)));cursor:var(--_button-cursor,pointer);display:var(--_button-display,inline-block);font-size:var(--button-fz,var(--mantine-font-size-sm));font-weight:600;height:var(--button-height,var(--button-height-sm));line-height:1;overflow:hidden;padding-left:var(--_button-padding-left,var(--button-padding-x,var(--button-padding-x-sm)));padding-right:var(--_button-padding-right,var(--button-padding-x,var(--button-padding-x-sm)));position:relative;text-align:center;-webkit-user-select:none;user-select:none;width:var(--_button-width,auto)}.m-77c9d27d[data-block]{--_button-display:block;--_button-width:100%}.m-77c9d27d[data-with-left-section]{--_button-padding-left:calc(var(--button-padding-x)/1.5)}[dir=rtl] .m-77c9d27d[data-with-left-section]{--_button-padding-left:var(--button-padding-x)}.m-77c9d27d[data-with-right-section],[dir=rtl] .m-77c9d27d[data-with-left-section]{--_button-padding-right:calc(var(--button-padding-x)/1.5)}[dir=rtl] .m-77c9d27d[data-with-right-section]{--_button-padding-right:var(--button-padding-x);--_button-padding-left:calc(var(--button-padding-x)/1.5)}.m-77c9d27d:disabled:not([data-loading]),.m-77c9d27d[data-disabled]:not([data-loading]){--_button-cursor:not-allowed;--_button-bg:var(--_disabled-bg);--_button-color:var(--_disabled-color);--_button-bd:calc(.0625rem*var(--mantine-scale)) solid transparent;transform:none}.m-77c9d27d:before{background-color:var(--_button-loading-overlay-bg);border-radius:var(--button-radius,var(--mantine-radius-default));content:"";filter:blur(12px);inset:calc(-.0625rem*var(--mantine-scale));opacity:0;pointer-events:none;position:absolute;transform:translateY(-100%);transition:transform .15s ease,opacity .1s ease}.m-77c9d27d[data-loading]{--_button-cursor:not-allowed;transform:none}.m-77c9d27d[data-loading]:before{opacity:1;transform:translateY(0)}.m-77c9d27d[data-loading] .m-80f1301b{opacity:0;transform:translateY(100%)}.m-77c9d27d[data-loading] .m-a25b86ee{opacity:1;transform:translate(-50%,-50%)}@media (hover:hover){.m-77c9d27d:hover:not([data-loading]):not(:disabled):not([data-disabled]){--_button-bg:var(--button-hover,var(--mantine-primary-color-filled-hover));--_button-color:var(--button-hover-color)}}@media (hover:none){.m-77c9d27d:active:not([data-loading]):not(:disabled):not([data-disabled]){--_button-bg:var(--button-hover,var(--mantine-primary-color-filled-hover));--_button-color:var(--button-hover-color)}}[data-mantine-color-scheme=light] .m-77c9d27d{--_disabled-color:var(--mantine-color-gray-5);--_disabled-bg:var(--mantine-color-gray-1);--_button-loading-overlay-bg:hsla(0,0%,100%,.15)}[data-mantine-color-scheme=dark] .m-77c9d27d{--_disabled-color:var(--mantine-color-dark-3);--_disabled-bg:var(--mantine-color-dark-6);--_button-loading-overlay-bg:rgba(0,0,0,.15)}.m-80f1301b{justify-content:var(--button-justify,center);overflow:visible;transition:transform .15s ease,opacity .1s ease}.m-80f1301b,.m-811560b9{align-items:center;display:flex;height:100%}.m-811560b9{opacity:var(--_button-label-opacity,1);overflow:hidden;white-space:nowrap}.m-811560b9[data-loading]{--_button-label-opacity:.2}.m-a74036a{align-items:center;display:flex;margin-left:var(--_button-section-margin-left);margin-right:var(--_button-section-margin-right)}.m-a74036a[data-position=left]{--_button-section-margin-right:var(--mantine-spacing-xs)}[dir=rtl] .m-a74036a[data-position=left]{--_button-section-margin-right:0}.m-a74036a[data-position=right],[dir=rtl] .m-a74036a[data-position=left]{--_button-section-margin-left:var(--mantine-spacing-xs)}[dir=rtl] .m-a74036a[data-position=right]{--_button-section-margin-left:0;--_button-section-margin-right:var(--mantine-spacing-xs)}.m-a25b86ee{left:50%;opacity:0;position:absolute;top:50%;transform:translate(-50%,-200%);transition:transform .15s ease,opacity .1s ease}.m-80d6d844{--button-border-width:calc(.0625rem*var(--mantine-scale));display:flex}.m-80d6d844[data-orientation=horizontal]{flex-direction:row}.m-80d6d844[data-orientation=horizontal] .m-77c9d27d:not(:only-child):first-child{border-bottom-right-radius:0;border-right-width:calc(var(--button-border-width)/2);border-top-right-radius:0}.m-80d6d844[data-orientation=horizontal] .m-77c9d27d:not(:only-child):last-child{border-bottom-left-radius:0;border-left-width:calc(var(--button-border-width)/2);border-top-left-radius:0}.m-80d6d844[data-orientation=horizontal] .m-77c9d27d:not(:only-child):not(:first-child):not(:last-child){border-left-width:calc(var(--button-border-width)/2);border-radius:0;border-right-width:calc(var(--button-border-width)/2)}[dir=rtl] .m-80d6d844[data-orientation=horizontal] .m-77c9d27d:not(:only-child):first-child{border:var(--_button-bd,var(--button-bd,calc(.0625rem*var(--mantine-scale)) solid transparent));border-radius:var(--button-radius,var(--mantine-radius-default));border-bottom-left-radius:0;border-left-width:calc(var(--button-border-width)/2);border-top-left-radius:0}[dir=rtl] .m-80d6d844[data-orientation=horizontal] .m-77c9d27d:not(:only-child):last-child{border:var(--_button-bd,var(--button-bd,calc(.0625rem*var(--mantine-scale)) solid transparent));border-radius:var(--button-radius,var(--mantine-radius-default));border-bottom-right-radius:0;border-right-width:calc(var(--button-border-width)/2);border-top-right-radius:0}.m-80d6d844[data-orientation=vertical]{flex-direction:column}.m-80d6d844[data-orientation=vertical] .m-77c9d27d:not(:only-child):first-child{border-bottom-left-radius:0;border-bottom-right-radius:0;border-bottom-width:calc(var(--button-border-width)/2)}.m-80d6d844[data-orientation=vertical] .m-77c9d27d:not(:only-child):last-child{border-top-left-radius:0;border-top-right-radius:0;border-top-width:calc(var(--button-border-width)/2)}.m-80d6d844[data-orientation=vertical] .m-77c9d27d:not(:only-child):not(:first-child):not(:last-child){border-bottom-width:calc(var(--button-border-width)/2);border-radius:0;border-top-width:calc(var(--button-border-width)/2)}.m-e615b15f{--card-padding:var(--mantine-spacing-md);background-color:var(--_card-bg);color:var(--mantine-color-text);display:flex;flex-direction:column;overflow:hidden;padding:var(--card-padding);position:relative}[data-mantine-color-scheme=light] .m-e615b15f{--_card-bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-e615b15f{--_card-bg:var(--mantine-color-dark-6)}.m-599a2148{border-bottom:var(--_card-section-border-bottom,unset);border-top:var(--_card-section-border-top,unset);display:block;margin:var(--_card-section-mt,0) calc(var(--card-padding)*-1) var(--_card-section-mb,0);padding-left:var(--_card-section-padding,0);padding-right:var(--_card-section-padding,0)}.m-599a2148[data-first-section]{--_card-section-mt:calc(var(--card-padding)*-1);--_card-section-border-top:none!important}.m-599a2148[data-last-section]{--_card-section-mb:calc(var(--card-padding)*-1);--_card-section-border-bottom:none!important}.m-599a2148[data-inherit-padding]{--_card-section-padding:var(--card-padding)}.m-599a2148[data-with-border]{--_card-section-border-top:calc(.0625rem*var(--mantine-scale)) solid var(--_card-section-border-color);--_card-section-border-bottom:calc(.0625rem*var(--mantine-scale)) solid var(--_card-section-border-color)}.m-599a2148+.m-599a2148{--_card-section-border-top:none!important}[data-mantine-color-scheme=light] .m-599a2148{--_card-section-border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-599a2148{--_card-section-border-color:var(--mantine-color-dark-4)}.m-4451eb3a{align-items:center;display:var(--_center-display,flex);justify-content:center}.m-4451eb3a[data-inline]{--_center-display:inline-flex}.m-f59ffda3{--chip-size-xs:calc(1.4375rem*var(--mantine-scale));--chip-size-sm:calc(1.75rem*var(--mantine-scale));--chip-size-md:calc(2rem*var(--mantine-scale));--chip-size-lg:calc(2.25rem*var(--mantine-scale));--chip-size-xl:calc(2.5rem*var(--mantine-scale));--chip-icon-size-xs:calc(.625rem*var(--mantine-scale));--chip-icon-size-sm:calc(.75rem*var(--mantine-scale));--chip-icon-size-md:calc(.875rem*var(--mantine-scale));--chip-icon-size-lg:calc(1rem*var(--mantine-scale));--chip-icon-size-xl:calc(1.125rem*var(--mantine-scale));--chip-padding-xs:calc(1rem*var(--mantine-scale));--chip-padding-sm:calc(1.25rem*var(--mantine-scale));--chip-padding-md:calc(1.5rem*var(--mantine-scale));--chip-padding-lg:calc(1.75rem*var(--mantine-scale));--chip-padding-xl:calc(2rem*var(--mantine-scale));--chip-checked-padding-xs:calc(.46875rem*var(--mantine-scale));--chip-checked-padding-sm:calc(.625rem*var(--mantine-scale));--chip-checked-padding-md:calc(.73125rem*var(--mantine-scale));--chip-checked-padding-lg:calc(.84375rem*var(--mantine-scale));--chip-checked-padding-xl:calc(.78125rem*var(--mantine-scale));--chip-spacing-xs:calc(.625rem*var(--mantine-scale));--chip-spacing-sm:calc(.75rem*var(--mantine-scale));--chip-spacing-md:calc(1rem*var(--mantine-scale));--chip-spacing-lg:calc(1.25rem*var(--mantine-scale));--chip-spacing-xl:calc(1.375rem*var(--mantine-scale));--chip-size:var(--chip-size-sm);--chip-icon-size:var(--chip-icon-size-sm);--chip-padding:var(--chip-padding-sm);--chip-spacing:var(--chip-spacing-sm);--chip-checked-padding:var(--chip-checked-padding-sm);--chip-bg:var(--mantine-primary-color-filled);--chip-hover:var(--mantine-primary-color-filled-hover);--chip-color:var(--mantine-color-white);--chip-bd:calc(.0625rem*var(--mantine-scale)) solid transparent}.m-be049a53{-webkit-tap-highlight-color:transparent;align-items:center;background-color:var(--_chip-bg);border:calc(.0625rem*var(--mantine-scale)) solid transparent;border-radius:var(--chip-radius,calc(62.5rem*var(--mantine-scale)));color:var(--_chip-color,var(--mantine-color-text));cursor:var(--_chip-cursor,pointer);display:inline-flex;font-size:var(--chip-fz,var(--mantine-font-size-sm));height:var(--chip-size);line-height:calc(var(--chip-size) - .125rem*var(--mantine-scale));padding-left:var(--_chip-padding,var(--chip-padding));padding-right:var(--_chip-padding,var(--chip-padding));-webkit-user-select:none;user-select:none;white-space:nowrap}.m-be049a53[data-checked]{--_chip-padding:var(--chip-checked-padding)}[data-mantine-color-scheme=light] .m-be049a53[data-disabled]{--_chip-bg:var(--mantine-color-gray-2);--_chip-color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m-be049a53[data-disabled]{--_chip-bg:var(--mantine-color-dark-6);--_chip-color:var(--mantine-color-dark-3)}.m-be049a53[data-disabled]{--_chip-cursor:not-allowed}.m-3904c1af:not([data-disabled]){background-color:var(--_chip-bg);border:var(--_chip-bd)}@media (hover:hover){[data-mantine-color-scheme=light] .m-3904c1af:not([data-disabled]):hover{--_chip-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-3904c1af:not([data-disabled]):hover{--_chip-bg:var(--mantine-color-dark-5)}}@media (hover:none){[data-mantine-color-scheme=light] .m-3904c1af:not([data-disabled]):active{--_chip-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-3904c1af:not([data-disabled]):active{--_chip-bg:var(--mantine-color-dark-5)}}[data-mantine-color-scheme=light] .m-3904c1af:not([data-disabled]){--_chip-bg:var(--mantine-color-white);--_chip-bd:calc(.0625rem*var(--mantine-scale)) solid var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-3904c1af:not([data-disabled]){--_chip-bg:var(--mantine-color-dark-6);--_chip-bd:calc(.0625rem*var(--mantine-scale)) solid var(--mantine-color-dark-4)}[data-mantine-color-scheme] .m-3904c1af:not([data-disabled])[data-checked]{--_chip-bd:var(--chip-bd);--_chip-icon-color:var(--chip-color)}@media (hover:hover){[data-mantine-color-scheme] .m-3904c1af:not([data-disabled])[data-checked]:hover{--_chip-bg:var(--chip-hover)}}@media (hover:none){[data-mantine-color-scheme] .m-3904c1af:not([data-disabled])[data-checked]:active{--_chip-bg:var(--chip-hover)}}.m-f7e165c3:not([data-disabled]),.m-fa109255:not([data-disabled]){background-color:var(--_chip-bg);border:calc(.0625rem*var(--mantine-scale)) solid transparent;color:var(--_chip-color,var(--mantine-color-text))}@media (hover:hover){[data-mantine-color-scheme=light] .m-f7e165c3:not([data-disabled]):hover,[data-mantine-color-scheme=light] .m-fa109255:not([data-disabled]):hover{--_chip-bg:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-f7e165c3:not([data-disabled]):hover,[data-mantine-color-scheme=dark] .m-fa109255:not([data-disabled]):hover{--_chip-bg:var(--mantine-color-dark-4)}}@media (hover:none){[data-mantine-color-scheme=light] .m-f7e165c3:not([data-disabled]):active,[data-mantine-color-scheme=light] .m-fa109255:not([data-disabled]):active{--_chip-bg:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-f7e165c3:not([data-disabled]):active,[data-mantine-color-scheme=dark] .m-fa109255:not([data-disabled]):active{--_chip-bg:var(--mantine-color-dark-4)}}[data-mantine-color-scheme=light] .m-f7e165c3:not([data-disabled]),[data-mantine-color-scheme=light] .m-fa109255:not([data-disabled]){--_chip-bg:var(--mantine-color-gray-1)}[data-mantine-color-scheme=dark] .m-f7e165c3:not([data-disabled]),[data-mantine-color-scheme=dark] .m-fa109255:not([data-disabled]){--_chip-bg:var(--mantine-color-dark-5)}[data-mantine-color-scheme] .m-f7e165c3:not([data-disabled])[data-checked],[data-mantine-color-scheme] .m-fa109255:not([data-disabled])[data-checked]{--_chip-icon-color:var(--chip-color);--_chip-color:var(--chip-color);--_chip-bg:var(--chip-bg)}@media (hover:hover){[data-mantine-color-scheme] .m-f7e165c3:not([data-disabled])[data-checked]:hover,[data-mantine-color-scheme] .m-fa109255:not([data-disabled])[data-checked]:hover{--_chip-bg:var(--chip-hover)}}@media (hover:none){[data-mantine-color-scheme] .m-f7e165c3:not([data-disabled])[data-checked]:active,[data-mantine-color-scheme] .m-fa109255:not([data-disabled])[data-checked]:active{--_chip-bg:var(--chip-hover)}}.m-9ac86df9{align-items:center;display:flex;max-width:calc(var(--chip-icon-size) + var(--chip-spacing)/1.5);overflow:hidden;width:calc(var(--chip-icon-size) + var(--chip-spacing)/1.5)}.m-9ac86df9,.m-d6d72580{height:var(--chip-icon-size)}.m-d6d72580{color:var(--_chip-icon-color,inherit);display:block;width:var(--chip-icon-size)}.m-bde07329{height:0;margin:0;opacity:0;padding:0;width:0}.m-bde07329:focus-visible+.m-be049a53{outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem*var(--mantine-scale))}.m-b183c0a2{background-color:var(--_code-bg);border-radius:var(--mantine-radius-sm);color:var(--_code-color);font-family:var(--mantine-font-family-monospace);font-size:var(--mantine-font-size-xs);line-height:var(--mantine-line-height);margin:0;overflow:auto;padding:var(--_code-padding,calc(.125rem*var(--mantine-scale)) calc(var(--mantine-spacing-xs)/2))}[data-mantine-color-scheme=light] .m-b183c0a2{--_code-bg:var(--code-bg,var(--mantine-color-gray-1));--_code-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-b183c0a2{--_code-bg:var(--code-bg,var(--mantine-color-dark-5));--_code-color:var(--mantine-color-white)}.m-b183c0a2[data-block]{--_code-padding:var(--mantine-spacing-xs)}.m-fee9c77{--cp-width-xs:calc(11.25rem*var(--mantine-scale));--cp-width-sm:calc(12.5rem*var(--mantine-scale));--cp-width-md:calc(15rem*var(--mantine-scale));--cp-width-lg:calc(17.5rem*var(--mantine-scale));--cp-width-xl:calc(20rem*var(--mantine-scale));--cp-preview-size-xs:calc(1.625rem*var(--mantine-scale));--cp-preview-size-sm:calc(2.125rem*var(--mantine-scale));--cp-preview-size-md:calc(2.625rem*var(--mantine-scale));--cp-preview-size-lg:calc(3.125rem*var(--mantine-scale));--cp-preview-size-xl:calc(3.375rem*var(--mantine-scale));--cp-thumb-size-xs:calc(.5rem*var(--mantine-scale));--cp-thumb-size-sm:calc(.75rem*var(--mantine-scale));--cp-thumb-size-md:calc(1rem*var(--mantine-scale));--cp-thumb-size-lg:calc(1.25rem*var(--mantine-scale));--cp-thumb-size-xl:calc(1.375rem*var(--mantine-scale));--cp-saturation-height-xs:calc(6.25rem*var(--mantine-scale));--cp-saturation-height-sm:calc(6.875rem*var(--mantine-scale));--cp-saturation-height-md:calc(7.5rem*var(--mantine-scale));--cp-saturation-height-lg:calc(8.75rem*var(--mantine-scale));--cp-saturation-height-xl:calc(10rem*var(--mantine-scale));--cp-preview-size:var(--cp-preview-size-sm);--cp-thumb-size:var(--cp-thumb-size-sm);--cp-saturation-height:var(--cp-saturation-height-sm);--cp-width:var(--cp-width-sm);--cp-body-spacing:var(--mantine-spacing-sm);padding:calc(.0625rem*var(--mantine-scale));width:var(--_cp-width,var(--cp-width))}.m-fee9c77[data-full-width]{--_cp-width:100%}.m-9dddfbac{height:var(--cp-preview-size);width:var(--cp-preview-size)}.m-bffecc3e{display:flex;padding-top:calc(var(--cp-body-spacing)/2)}.m-3283bb96{flex:1}.m-3283bb96:not(:only-child){margin-right:var(--mantine-spacing-xs)}.m-40d572ba{border:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-white);border-radius:var(--_cp-thumb-size);box-shadow:0 0 calc(.0625rem*var(--mantine-scale)) #0009;height:var(--_cp-thumb-size);left:calc(var(--_thumb-x-offset) - var(--_cp-thumb-size)/2);outline:var(--_outline);overflow:hidden;position:absolute;top:calc(var(--_thumb-y-offset) - var(--_cp-thumb-size)/2);width:var(--_cp-thumb-size)}.m-d8ee6fd8{cursor:pointer;flex:0 0 calc(var(--cp-swatch-size) - .25rem*var(--mantine-scale));height:unset!important;margin:calc(.125rem*var(--mantine-scale));min-height:0!important;min-width:0!important;padding-bottom:calc(var(--cp-swatch-size) - .25rem*var(--mantine-scale));width:unset!important}.m-5711e686{display:flex;flex-wrap:wrap;margin-left:calc(-.125rem*var(--mantine-scale));margin-right:calc(-.125rem*var(--mantine-scale));margin-top:calc(.3125rem*var(--mantine-scale))}.m-202a296e{--cp-thumb-size-xs:calc(.5rem*var(--mantine-scale));--cp-thumb-size-sm:calc(.75rem*var(--mantine-scale));--cp-thumb-size-md:calc(1rem*var(--mantine-scale));--cp-thumb-size-lg:calc(1.25rem*var(--mantine-scale));--cp-thumb-size-xl:calc(1.375rem*var(--mantine-scale));--_cp-thumb-size:var(--cp-thumb-size,calc(.75rem*var(--mantine-scale)));-webkit-tap-highlight-color:transparent;border-radius:var(--mantine-radius-sm);height:var(--cp-saturation-height);margin:calc(var(--cp-thumb-size)/2);position:relative}.m-202a296e[data-focus-ring=auto]:focus:focus-visible .m-40d572ba{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}.m-202a296e[data-focus-ring=always]:focus .m-40d572ba{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}.m-11b3db02{border-radius:var(--mantine-radius-sm);inset:calc(var(--cp-thumb-size)*-1/2 - .0625rem*var(--mantine-scale));position:absolute}.m-d856d47d{--cp-thumb-size-xs:calc(.5rem*var(--mantine-scale));--cp-thumb-size-sm:calc(.75rem*var(--mantine-scale));--cp-thumb-size-md:calc(1rem*var(--mantine-scale));--cp-thumb-size-lg:calc(1.25rem*var(--mantine-scale));--cp-thumb-size-xl:calc(1.375rem*var(--mantine-scale));--_cp-thumb-size:var(--cp-thumb-size,calc(.75rem*var(--mantine-scale)));height:calc(var(--_cp-thumb-size) + .125rem*var(--mantine-scale));margin-left:calc(var(--_cp-thumb-size)/2);margin-right:calc(var(--_cp-thumb-size)/2);outline:none;position:relative}.m-d856d47d+.m-d856d47d{margin-top:calc(.375rem*var(--mantine-scale))}.m-d856d47d[data-focus-ring=auto]:focus:focus-visible .m-40d572ba{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}.m-d856d47d[data-focus-ring=always]:focus .m-40d572ba{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}[data-mantine-color-scheme=light] .m-d856d47d{--_slider-checkers:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-d856d47d{--_slider-checkers:var(--mantine-color-dark-4)}.m-8f327113{border-radius:10000rem;bottom:0;left:calc(var(--_cp-thumb-size)*-1/2 - .0625rem*var(--mantine-scale));position:absolute;right:calc(var(--_cp-thumb-size)*-1/2 - .0625rem*var(--mantine-scale));top:0}.m-de3d2490{--cs-size:calc(1.75rem*var(--mantine-scale));--cs-radius:calc(62.5rem*var(--mantine-scale));-webkit-tap-highlight-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;border-radius:var(--cs-radius);color:inherit;display:block;height:var(--cs-size);line-height:1;min-height:var(--cs-size);min-width:var(--cs-size);position:relative;text-decoration:none;width:var(--cs-size)}[data-mantine-color-scheme=light] .m-de3d2490{--_alpha-overlay-color:var(--mantine-color-gray-3);--_alpha-overlay-bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-de3d2490{--_alpha-overlay-color:var(--mantine-color-dark-4);--_alpha-overlay-bg:var(--mantine-color-dark-7)}.m-862f3d1b,.m-98ae7f22{border-radius:var(--cs-radius);top:0;right:0;bottom:0;left:0;position:absolute}.m-98ae7f22{box-shadow:#0000001a 0 0 0 calc(.0625rem*var(--mantine-scale)) inset,#00000026 0 0 calc(.25rem*var(--mantine-scale)) inset;z-index:1}.m-95709ac0{background-image:linear-gradient(45deg,var(--_alpha-overlay-color) 25%,transparent 25%),linear-gradient(-45deg,var(--_alpha-overlay-color) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--_alpha-overlay-color) 75%),linear-gradient(-45deg,var(--_alpha-overlay-bg) 75%,var(--_alpha-overlay-color) 75%);background-position:0 0,0 calc(.25rem*var(--mantine-scale)),calc(.25rem*var(--mantine-scale)) calc(-.25rem*var(--mantine-scale)),calc(-.25rem*var(--mantine-scale)) 0;background-size:calc(.5rem*var(--mantine-scale)) calc(.5rem*var(--mantine-scale))}.m-93e74e3,.m-95709ac0{border-radius:var(--cs-radius);top:0;right:0;bottom:0;left:0;position:absolute}.m-93e74e3{align-items:center;display:flex;justify-content:center;z-index:2}.m-b077c2bc{--ci-eye-dropper-icon-size-xs:calc(.875rem*var(--mantine-scale));--ci-eye-dropper-icon-size-sm:calc(1rem*var(--mantine-scale));--ci-eye-dropper-icon-size-md:calc(1.125rem*var(--mantine-scale));--ci-eye-dropper-icon-size-lg:calc(1.25rem*var(--mantine-scale));--ci-eye-dropper-icon-size-xl:calc(1.375rem*var(--mantine-scale));--ci-eye-dropper-icon-size:var(--ci-eye-dropper-icon-size-sm)}.m-c5ccdcab{--ci-preview-size-xs:calc(1rem*var(--mantine-scale));--ci-preview-size-sm:calc(1.125rem*var(--mantine-scale));--ci-preview-size-md:calc(1.375rem*var(--mantine-scale));--ci-preview-size-lg:calc(1.75rem*var(--mantine-scale));--ci-preview-size-xl:calc(2.25rem*var(--mantine-scale));--ci-preview-size:var(--ci-preview-size-sm)}.m-5ece2cd7{padding:calc(.5rem*var(--mantine-scale))}.m-7485cace{--container-size-xs:calc(33.75rem*var(--mantine-scale));--container-size-sm:calc(45rem*var(--mantine-scale));--container-size-md:calc(60rem*var(--mantine-scale));--container-size-lg:calc(71.25rem*var(--mantine-scale));--container-size-xl:calc(82.5rem*var(--mantine-scale));--container-size:var(--container-size-md);margin-left:auto;margin-right:auto;max-width:var(--container-size);padding-left:var(--mantine-spacing-md);padding-right:var(--mantine-spacing-md)}.m-7485cace[data-fluid]{--container-size:100%}.m-e2125a27{--dialog-size-xs:calc(10rem*var(--mantine-scale));--dialog-size-sm:calc(12.5rem*var(--mantine-scale));--dialog-size-md:calc(21.25rem*var(--mantine-scale));--dialog-size-lg:calc(25rem*var(--mantine-scale));--dialog-size-xl:calc(31.25rem*var(--mantine-scale));--dialog-size:var(--dialog-size-md);max-width:calc(100vw - var(--mantine-spacing-xl)*2);min-height:calc(3.125rem*var(--mantine-scale));position:relative;width:var(--dialog-size)}.m-5abab665{left:var(--_close-button-left,auto);position:absolute;right:var(--_close-button-right,calc(var(--mantine-spacing-md)/2));top:calc(var(--mantine-spacing-md)/2)}[dir=rtl] .m-5abab665{--_close-button-right:auto;--_close-button-left:calc(var(--mantine-spacing-md)/2)}.m-3eebeb36{--divider-size-xs:calc(.0625rem*var(--mantine-scale));--divider-size-sm:calc(.125rem*var(--mantine-scale));--divider-size-md:calc(.1875rem*var(--mantine-scale));--divider-size-lg:calc(.25rem*var(--mantine-scale));--divider-size-xl:calc(.3125rem*var(--mantine-scale));--divider-size:var(--divider-size-xs)}[data-mantine-color-scheme=light] .m-3eebeb36{--_divider-color:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-3eebeb36{--_divider-color:var(--mantine-color-dark-3)}.m-3eebeb36[data-orientation=horizontal]{border-top:var(--divider-size) var(--divider-border-style,solid) var(--divider-color,var(--_divider-color))}.m-3eebeb36[data-orientation=vertical]{align-self:stretch;border-left:var(--divider-size) var(--divider-border-style,solid) var(--divider-color,var(--_divider-color));height:auto}.m-3eebeb36[data-with-label]{border:0}.m-9e365f20{align-items:center;color:var(--divider-color,var(--mantine-color-dimmed));display:flex;font-size:var(--mantine-font-size-xs);white-space:nowrap}.m-9e365f20[data-position=left]:before,.m-9e365f20[data-position=right]:after{display:none}.m-9e365f20:before{border-top:var(--divider-size) var(--divider-border-style,solid) var(--divider-color,var(--_divider-color));content:"";flex:1;height:calc(.0625rem*var(--mantine-scale));margin-right:var(--mantine-spacing-xs)}[dir=rtl] .m-9e365f20:before{margin-left:var(--mantine-spacing-xs);margin-right:0}.m-9e365f20:after{border-top:var(--divider-size) var(--divider-border-style,solid) var(--divider-color,var(--_divider-color));content:"";flex:1;height:calc(.0625rem*var(--mantine-scale));margin-left:var(--mantine-spacing-xs)}[dir=rtl] .m-9e365f20:after{margin-left:0;margin-right:var(--mantine-spacing-xs)}.m-f11b401e{--drawer-size-xs:calc(20rem*var(--mantine-scale));--drawer-size-sm:calc(23.75rem*var(--mantine-scale));--drawer-size-md:calc(27.5rem*var(--mantine-scale));--drawer-size-lg:calc(38.75rem*var(--mantine-scale));--drawer-size-xl:calc(48.75rem*var(--mantine-scale));--drawer-size:var(--drawer-size-md);--drawer-offset:0rem}.m-5a7c2c9{z-index:1000}.m-b8a05bbd{flex:var(--drawer-flex,0 0 var(--drawer-size));height:var(--drawer-height,calc(100% - var(--drawer-offset)*2));margin:var(--drawer-offset);max-height:100%;max-width:100%;overflow-y:auto}.m-31cd769a{align-items:var(--drawer-align,flex-start);display:flex;justify-content:var(--drawer-justify,flex-start)}.m-e9408a47{border-radius:var(--fieldset-radius,var(--mantine-radius-default));min-inline-size:auto;padding:var(--mantine-spacing-lg);padding-top:var(--mantine-spacing-xs)}.m-84c9523a{background-color:var(--_bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_bd)}[data-mantine-color-scheme=light] .m-84c9523a{--_bd:var(--mantine-color-gray-3);--_bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-84c9523a{--_bd:var(--mantine-color-dark-4);--_bg:var(--mantine-color-dark-7)}.m-ef274e49{background-color:var(--_bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_bd)}[data-mantine-color-scheme=light] .m-ef274e49{--_bd:var(--mantine-color-gray-3);--_bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-ef274e49{--_bd:var(--mantine-color-dark-4);--_bg:var(--mantine-color-dark-6)}.m-eda993d3{border:0;border-radius:0;padding:0}.m-90794832{font-size:var(--mantine-font-size-sm)}.m-74ca27fe{margin-bottom:var(--mantine-spacing-sm);padding:0}.m-410352e9{overflow:var(--grid-overflow,hidden)}.m-dee7bd2f{align-items:var(--grid-align);display:flex;flex-wrap:wrap;justify-content:var(--grid-justify);margin:calc(var(--grid-gutter)/-2);width:calc(100% + var(--grid-gutter))}.m-96bdd299{flex-basis:var(--col-flex-basis);flex-grow:var(--col-flex-grow,0);flex-shrink:0;margin-left:var(--_col-ml,var(--col-offset,0));margin-right:var(--_col-mr,0);max-width:var(--col-max-width);order:var(--col-order);padding:calc(var(--grid-gutter)/2);width:var(--col-width)}[dir=rtl] .m-96bdd299{--_col-ml:0;--_col-mr:var(--col-offset,0)}.m-bcb3f3c2{background-color:var(--_mark-bg);color:var(--mantine-color-black)}[data-mantine-color-scheme=light] .m-bcb3f3c2{--_mark-bg:var(--mark-bg-light)}[data-mantine-color-scheme=dark] .m-bcb3f3c2{--_mark-bg:var(--mark-bg-dark)}.m-9e117634{border-radius:var(--image-radius,0);display:block;flex:0;object-fit:var(--image-object-fit,cover);width:100%}@keyframes m-885901b1{0%{box-shadow:0 0 calc(.03125rem*var(--mantine-scale)) 0 var(--indicator-color);opacity:.6}to{box-shadow:0 0 calc(.03125rem*var(--mantine-scale)) calc(.275rem*var(--mantine-scale)) var(--indicator-color);opacity:0}}.m-e5262200{--indicator-size:calc(.625rem*var(--mantine-scale));--indicator-color:var(--mantine-primary-color-filled);display:var(--_indicator-display,block);position:relative}.m-e5262200[data-inline]{--_indicator-display:inline-block}.m-760d1fb1{align-items:center;border:var(--_indicator-border);border-radius:var(--indicator-radius,calc(62.5rem*var(--mantine-scale)));bottom:var(--indicator-bottom);color:var(--mantine-color-white);display:flex;font-size:var(--mantine-font-size-xs);height:var(--indicator-size);justify-content:center;left:var(--indicator-left);min-width:var(--indicator-size);padding-left:var(--_indicator-padding,0);padding-right:var(--_indicator-padding,0);right:var(--indicator-right);top:var(--indicator-top);transform:translate(var(--indicator-translate-x),var(--indicator-translate-y));white-space:nowrap;z-index:var(--indicator-z-index,200)}.m-760d1fb1,.m-760d1fb1:before{background-color:var(--indicator-color);position:absolute}.m-760d1fb1:before{border-radius:var(--indicator-radius,calc(62.5rem*var(--mantine-scale)));content:"";top:0;right:0;bottom:0;left:0;z-index:-1}.m-760d1fb1[data-with-label]{--_indicator-padding:calc(var(--mantine-spacing-xs)/2)}.m-760d1fb1[data-with-border]{--_indicator-border:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-body)}.m-760d1fb1[data-processing]:before{animation:m-885901b1 1s linear infinite}.m-dc6f14e2{--kbd-fz-xs:calc(.625rem*var(--mantine-scale));--kbd-fz-sm:calc(.75rem*var(--mantine-scale));--kbd-fz-md:calc(.875rem*var(--mantine-scale));--kbd-fz-lg:calc(1rem*var(--mantine-scale));--kbd-fz-xl:calc(1.25rem*var(--mantine-scale));--kbd-fz:var(--kbd-fz-sm);--kbd-padding-xs:calc(.125rem*var(--mantine-scale)) calc(.25rem*var(--mantine-scale));--kbd-padding-sm:calc(.1875rem*var(--mantine-scale)) calc(.3125rem*var(--mantine-scale));--kbd-padding-md:calc(.25rem*var(--mantine-scale)) calc(.4375rem*var(--mantine-scale));--kbd-padding-lg:calc(.3125rem*var(--mantine-scale)) calc(.5625rem*var(--mantine-scale));--kbd-padding-xl:calc(.5rem*var(--mantine-scale)) calc(.875rem*var(--mantine-scale));--kbd-padding:var(--kbd-padding-sm);background-color:var(--_kbd-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_kbd-border-color);border-bottom-width:calc(.1875rem*var(--mantine-scale));border-radius:var(--mantine-radius-sm);color:var(--_kbd-color);font-family:var(--mantine-font-family-monospace);font-size:var(--kbd-fz);font-weight:700;line-height:var(--mantine-line-height);padding:var(--kbd-padding);unicode-bidi:embed}[data-mantine-color-scheme=light] .m-dc6f14e2{--_kbd-border-color:var(--mantine-color-gray-3);--_kbd-color:var(--mantine-color-gray-7);--_kbd-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-dc6f14e2{--_kbd-border-color:var(--mantine-color-dark-3);--_kbd-color:var(--mantine-color-dark-0);--_kbd-bg:var(--mantine-color-dark-5)}.m-abbac491{font-size:var(--list-fz,var(--mantine-fz-md));line-height:var(--list-lh,var(--mantine-line-height-md));list-style-position:inside;margin:0;padding:0;padding-left:var(--_list-pl,0);padding-right:var(--_list-pr,0)}.m-abbac491[data-with-padding]{--_list-pl:var(--mantine-spacing-md)}[dir=rtl] .m-abbac491[data-with-padding]{--_list-pl:0;--_list-pr:var(--mantine-spacing-md)}.m-abb6bec2{line-height:var(--_item-lh,var(--list-lh));list-style:var(--_item-list-style);margin-top:var(--_item-mt,0);white-space:nowrap}.m-abb6bec2[data-with-icon]{--_item-list-style:none}.m-abb6bec2[data-with-icon] .m-75cd9f71{--_item-wrapper-direction:row;--_item-wrapper-align:center}.m-abb6bec2:not(:first-of-type){--_item-mt:var(--list-spacing,0)}.m-abb6bec2[data-centered]{--_item-lh:1}.m-75cd9f71{align-items:var(--_item-wrapper-align,flex-start);display:inline-flex;flex-direction:var(--_item-wrapper-direction,column);white-space:normal}.m-60f83e5b{display:inline-block;margin-left:var(--_item-icon-ml,0);margin-right:var(--_item-icon-mr,var(--mantine-spacing-sm));vertical-align:middle}[dir=rtl] .m-60f83e5b{--_item-icon-mr:0;--_item-icon-ml:var(--mantine-spacing-sm)}.m-6e45937b{align-items:center;display:flex;top:0;right:0;bottom:0;left:0;justify-content:center;overflow:hidden;position:absolute;z-index:var(--lo-z-index)}.m-e8eb006c{position:relative;z-index:calc(var(--lo-z-index) + 1)}.m-df587f17{z-index:var(--lo-z-index)}[data-mantine-color-scheme=dark] .m-df587f17[data-light],[data-mantine-color-scheme=light] .m-df587f17[data-dark]{display:none}.m-dc9b7c9f{padding:calc(.25rem*var(--mantine-scale))}.m-9bfac126{color:var(--mantine-color-dimmed);cursor:default;font-size:var(--mantine-font-size-xs);font-weight:500;padding:calc(var(--mantine-spacing-xs)/2) var(--mantine-spacing-sm)}.m-efdf90cb{border-top:calc(.0625rem*var(--mantine-scale)) solid var(--_divider-color);margin-bottom:calc(.25rem*var(--mantine-scale));margin-top:calc(.25rem*var(--mantine-scale))}[data-mantine-color-scheme=light] .m-efdf90cb{--_divider-color:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-efdf90cb{--_divider-color:var(--mantine-color-dark-4)}.m-99ac2aa1{align-items:center;background-color:var(--_item-bg,transparent);border-radius:var(--popover-radius,var(--mantine-radius-default));color:var(--menu-item-color,var(--mantine-color-text));display:flex;font-size:var(--mantine-font-size-sm);opacity:var(--_item-opacity,1);padding:calc(var(--mantine-spacing-xs)/1.5) var(--mantine-spacing-sm);pointer-events:var(--_item-pointer-events,auto);-webkit-user-select:none;user-select:none;width:100%}.m-99ac2aa1:disabled,.m-99ac2aa1[data-disabled]{--menu-item-color:var(--mantine-color-dimmed)!important;--_item-opacity:.6;--_item-pointer-events:none}.m-99ac2aa1[data-hovered]{--_item-bg:var(--menu-item-hover,var(--_item-bg-hover))}[data-mantine-color-scheme=light] .m-99ac2aa1[data-hovered]{--_item-bg-hover:var(--mantine-color-gray-1)}[data-mantine-color-scheme=dark] .m-99ac2aa1[data-hovered]{--_item-bg-hover:var(--mantine-color-dark-4)}.m-5476e0d3{flex:1}[dir=rtl] .m-5476e0d3{text-align:right}.m-8b75e504{align-items:center;display:flex;justify-content:center;margin-left:var(--_section-ml);margin-right:var(--_section-mr)}.m-8b75e504[data-position=left]{--_section-ml:0;--_section-mr:var(--mantine-spacing-xs)}.m-8b75e504[data-position=right],[dir=rtl] .m-8b75e504[data-position=left]{--_section-ml:var(--mantine-spacing-xs);--_section-mr:0}[dir=rtl] .m-8b75e504[data-position=right]{--_section-ml:0;--_section-mr:var(--mantine-spacing-xs)}.m-9df02822{--modal-size-xs:calc(20rem*var(--mantine-scale));--modal-size-sm:calc(23.75rem*var(--mantine-scale));--modal-size-md:calc(27.5rem*var(--mantine-scale));--modal-size-lg:calc(38.75rem*var(--mantine-scale));--modal-size-xl:calc(48.75rem*var(--mantine-scale));--modal-size:var(--modal-size-md);--modal-y-offset:5dvh;--modal-x-offset:5vw}.m-9df02822[data-full-screen]{--modal-border-radius:0!important}.m-9df02822[data-full-screen] .m-54c44539{--_content-flex:0 0 100%;--_content-max-height:auto;--_content-height:100dvh}.m-9df02822[data-full-screen] .m-1f958f16{--_inner-y-offset:0;--_inner-x-offset:0}.m-9df02822[data-centered] .m-1f958f16{--_inner-align:center}.m-d0e2b9cd{border-top-left-radius:var(--modal-radius,var(--mantine-radius-default));border-top-right-radius:var(--modal-radius,var(--mantine-radius-default))}.m-54c44539{flex:var(--_content-flex,0 0 var(--modal-size));height:var(--_content-height,auto);max-height:var(--_content-max-height,calc(100dvh - var(--modal-y-offset)*2));max-width:100%;overflow-y:auto}.m-1f958f16{align-items:var(--_inner-align,flex-start);display:flex;justify-content:center;padding:var(--_inner-y-offset,var(--modal-y-offset)) var(--_inner-x-offset,var(--modal-x-offset))}.m-45c4369d{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;border:0;color:inherit;flex:1;font-size:inherit;height:1.6em;min-width:calc(6.25rem*var(--mantine-scale));padding:0}.m-45c4369d::placeholder{color:var(--_input-placeholder-color);opacity:1}.m-45c4369d[data-type=auto],.m-45c4369d[data-type=hidden]{height:calc(.0625rem*var(--mantine-scale));left:0;opacity:0;pointer-events:none;position:absolute;top:0;width:calc(.0625rem*var(--mantine-scale))}.m-45c4369d:focus{outline:none}.m-45c4369d[data-type=auto]:focus{height:1.6em;opacity:1;position:static;visibility:visible}.m-45c4369d[data-pointer]:not([data-disabled],:disabled){cursor:pointer}.m-45c4369d:disabled,.m-45c4369d[data-disabled]{cursor:not-allowed}.m-7cda1cd6{--pill-fz-xs:calc(.625rem*var(--mantine-scale));--pill-fz-sm:calc(.75rem*var(--mantine-scale));--pill-fz-md:calc(.875rem*var(--mantine-scale));--pill-fz-lg:calc(1rem*var(--mantine-scale));--pill-fz-xl:calc(1.125rem*var(--mantine-scale));--pill-height-xs:calc(1.125rem*var(--mantine-scale));--pill-height-sm:calc(1.375rem*var(--mantine-scale));--pill-height-md:calc(1.5625rem*var(--mantine-scale));--pill-height-lg:calc(1.75rem*var(--mantine-scale));--pill-height-xl:calc(2rem*var(--mantine-scale));--pill-fz:var(--pill-fz-sm);--pill-height:var(--pill-height-sm);align-items:center;background-color:var(--_pill-bg);border-radius:var(--pill-radius,calc(62.5rem*var(--mantine-scale)));color:var(--_pill-color);display:inline-flex;flex:0;font-size:var(--pill-fz);height:var(--pill-height);line-height:1;max-width:100%;padding-left:.8em;padding-right:var(--_pill-padding-right,.8em);user-select:none;-webkit-user-select:none;white-space:nowrap}[data-mantine-color-scheme=dark] .m-7cda1cd6{--_pill-bg:var(--mantine-color-dark-7);--_pill-color:var(--mantine-color-dark-0)}[data-mantine-color-scheme=light] .m-7cda1cd6{--_pill-color:var(--mantine-color-black)}[dir=rtl] .m-7cda1cd6{padding-left:var(--_pill-padding-right,.8em);padding-right:.8em}.m-7cda1cd6[data-with-remove]{--_pill-padding-right:0}.m-7cda1cd6:has(button:disabled),.m-7cda1cd6[data-disabled]{--_pill-cursor:not-allowed}[data-mantine-color-scheme=light] .m-44da308b{--_pill-bg:var(--mantine-color-gray-1)}[data-mantine-color-scheme=light] .m-44da308b:has(button:disabled),[data-mantine-color-scheme=light] .m-44da308b[data-disabled]{--_pill-bg:var(--mantine-color-gray-3)}[data-mantine-color-scheme=light] .m-e3a01f8{--_pill-bg:var(--mantine-color-white)}[data-mantine-color-scheme=light] .m-e3a01f8:has(button:disabled),[data-mantine-color-scheme=light] .m-e3a01f8[data-disabled]{--_pill-bg:var(--mantine-color-gray-3)}.m-1e0e6180{cursor:var(--_pill-cursor,default);height:100%;line-height:var(--pill-height);overflow:hidden;text-overflow:ellipsis}.m-ae386778{border-radius:0;color:inherit;flex:0;font-size:inherit;height:100%;min-height:unset;min-width:2em;padding-left:.1em;padding-right:.3em;width:unset}.m-7cda1cd6[data-disabled]>.m-ae386778,.m-ae386778:disabled{background-color:transparent;cursor:not-allowed;min-width:.8em;padding:0;width:.8em}.m-7cda1cd6[data-disabled]>.m-ae386778>svg,.m-ae386778:disabled>svg{display:none}.m-ae386778>svg{pointer-events:none}.m-1dcfd90b{--pg-gap-xs:calc(.375rem*var(--mantine-scale));--pg-gap-sm:calc(.5rem*var(--mantine-scale));--pg-gap-md:calc(.625rem*var(--mantine-scale));--pg-gap-lg:calc(.75rem*var(--mantine-scale));--pg-gap-xl:calc(.75rem*var(--mantine-scale));--pg-gap:var(--pg-gap-sm);flex-wrap:wrap;gap:var(--pg-gap)}.m-1dcfd90b,.m-f0824112{align-items:center;display:flex}.m-f0824112{--nl-bg:var(--mantine-primary-color-light);--nl-hover:var(--mantine-primary-color-light-hover);--nl-color:var(--mantine-primary-color-light-color);background:var(--_nav-link-bg);color:var(--_nav-link-color);opacity:var(--_nav-link-opacity,1);padding:calc(.5rem*var(--mantine-scale)) var(--mantine-spacing-sm);pointer-events:var(--_nav-link-pointer-events,auto);-webkit-user-select:none;user-select:none;width:100%}@media (hover:hover){[data-mantine-color-scheme=light] .m-f0824112:hover{--_nav-link-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-f0824112:hover{--_nav-link-bg:var(--mantine-color-dark-6)}}@media (hover:none){[data-mantine-color-scheme=light] .m-f0824112:active{--_nav-link-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-f0824112:active{--_nav-link-bg:var(--mantine-color-dark-6)}}.m-f0824112[data-disabled]{--_nav-link-opacity:.4;--_nav-link-pointer-events:none}.m-f0824112[data-active]{--_nav-link-bg:var(--nl-bg);--_nav-link-color:var(--nl-color)}@media (hover:hover){.m-f0824112[data-active]:hover{--_nav-link-bg:var(--nl-hover)}}@media (hover:none){.m-f0824112[data-active]:active{--_nav-link-bg:var(--nl-hover)}}.m-f0824112[data-active] .m-57492dcc{--_description-opacity:.9;--_description-color:var(--nl-color)}.m-690090b5{align-items:center;display:flex;justify-content:center;margin-left:var(--_section-ml);margin-right:var(--_section-mr);transform:var(--_section-transform,none);transition:transform .15s ease}.m-690090b5>svg{display:block}.m-690090b5[data-position=left]{--_section-ml:0;--_section-mr:var(--mantine-spacing-sm)}.m-690090b5[data-position=right],[dir=rtl] .m-690090b5[data-position=left]{--_section-ml:var(--mantine-spacing-sm);--_section-mr:0}[dir=rtl] .m-690090b5[data-position=right]{--_section-ml:0;--_section-mr:var(--mantine-spacing-sm)}.m-690090b5[data-rotate]{--_section-transform:rotate(90deg)}.m-1f6ac4c4{font-size:var(--mantine-font-size-sm)}.m-f07af9d2{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:var(--_body-white-space,auto)}.m-f07af9d2[data-no-wrap]{--_body-white-space:nowrap}.m-57492dcc{color:var(--_description-color,var(--mantine-color-dimmed));display:block;font-size:var(--mantine-font-size-xs);opacity:var(--_description-opacity,1);overflow:hidden;text-overflow:ellipsis;white-space:var(--_body-white-space,auto)}.m-e17b862f{padding-left:var(--_children-pl,var(--nl-offset,var(--mantine-spacing-lg)));padding-right:var(--_children-pr,0)}[dir=rtl] .m-e17b862f{--_children-pl:0;--_children-pr:var(--nl-offset,var(--mantine-spacing-lg))}.m-1fd8a00b{transform:rotate(-90deg)}.m-a513464{align-items:center;background-color:var(--_bg);border:var(--_border,none);box-shadow:var(--mantine-shadow-lg);box-sizing:border-box;display:flex;overflow:hidden;padding:var(--mantine-spacing-xs) var(--_root-padding-right,var(--mantine-spacing-xs)) var(--mantine-spacing-xs) var(--_root-padding-left,calc(1.375rem*var(--mantine-scale)));position:relative}.m-a513464,.m-a513464:before{border-radius:var(--notification-radius,var(--mantine-radius-default))}.m-a513464:before{background-color:var(--notification-color,var(--mantine-primary-color-filled));bottom:var(--notification-radius,var(--mantine-radius-default));content:"";display:block;left:calc(.25rem*var(--mantine-scale));position:absolute;top:var(--notification-radius,var(--mantine-radius-default));width:calc(.375rem*var(--mantine-scale))}[dir=rtl] .m-a513464:before{left:auto;right:calc(.25rem*var(--mantine-scale))}.m-a513464[data-with-icon]{--_root-padding-left:var(--mantine-spacing-xs)}.m-a513464[data-with-icon]:before{display:none}[dir=rtl] .m-a513464[data-with-icon]{--_root-padding-right:var(--mantine-spacing-xs)}.m-a513464[data-with-border]{--_border:calc(.0625rem*var(--mantine-scale)) solid var(--_border-color)}[dir=rtl] .m-a513464{--_root-padding-right:calc(1.375rem*var(--mantine-scale));--_root-padding-left:var(--mantine-spacing-xs)}[data-mantine-color-scheme=light] .m-a513464{--_border-color:var(--mantine-color-gray-3);--_bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-a513464{--_border-color:var(--mantine-color-dark-4);--_bg:var(--mantine-color-dark-6)}.m-a4ceffb{align-items:center;background-color:var(--notification-color,var(--mantine-primary-color-filled));border-radius:calc(1.75rem*var(--mantine-scale));box-sizing:border-box;color:var(--mantine-color-white);display:flex;height:calc(1.75rem*var(--mantine-scale));justify-content:center;margin-left:var(--_icon-margin-left,0);margin-right:var(--_icon-margin-right,var(--mantine-spacing-md));width:calc(1.75rem*var(--mantine-scale))}[dir=rtl] .m-a4ceffb{--_icon-margin-right:0;--_icon-margin-left:var(--mantine-spacing-md)}.m-b0920b15{margin-left:var(--_icon-margin-left,0);margin-right:var(--_icon-margin-right,var(--mantine-spacing-md))}[dir=rtl] .m-b0920b15{--_icon-margin-right:0;--_icon-margin-left:var(--mantine-spacing-md)}.m-a49ed24{flex:1;margin-left:var(--_body-margin-left,0);margin-right:var(--_body-margin-right,var(--mantine-spacing-xs));overflow:hidden}[dir=rtl] .m-a49ed24{--_body-margin-right:0;--_body-margin-left:var(--mantine-spacing-xs)}.m-3feedf16{color:var(--_title-color);font-size:var(--mantine-font-size-sm);font-weight:500;line-height:var(--mantine-line-height-sm);margin-bottom:calc(.125rem*var(--mantine-scale));overflow:hidden;text-overflow:ellipsis}[data-mantine-color-scheme=light] .m-3feedf16{--_title-color:var(--mantine-color-gray-9)}[data-mantine-color-scheme=dark] .m-3feedf16{--_title-color:var(--mantine-color-white)}.m-3d733a3a{color:var(--_description-color);font-size:var(--mantine-font-size-sm);line-height:var(--mantine-line-height-sm);overflow:hidden;text-overflow:ellipsis}[data-mantine-color-scheme=light] .m-3d733a3a[data-with-title]{--_description-color:var(--mantine-color-gray-6)}[data-mantine-color-scheme=dark] .m-3d733a3a[data-with-title]{--_description-color:var(--mantine-color-dark-2)}[data-mantine-color-scheme=light] .m-3d733a3a{--_description-color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-3d733a3a{--_description-color:var(--mantine-color-dark-0)}.m-919a4d88:hover{background-color:var(--_close-button-hover-bg)}[data-mantine-color-scheme=light] .m-919a4d88:hover{--_close-button-hover-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-919a4d88:hover{--_close-button-hover-bg:var(--mantine-color-dark-8)}.m-e2f5cd4e{--ni-right-section-width-xs:calc(1.0625rem*var(--mantine-scale));--ni-right-section-width-sm:calc(1.5rem*var(--mantine-scale));--ni-right-section-width-md:calc(1.6875rem*var(--mantine-scale));--ni-right-section-width-lg:calc(1.9375rem*var(--mantine-scale));--ni-right-section-width-xl:calc(2.125rem*var(--mantine-scale))}.m-95e17d22{--ni-chevron-size-xs:calc(.625rem*var(--mantine-scale));--ni-chevron-size-sm:calc(.875rem*var(--mantine-scale));--ni-chevron-size-md:calc(1rem*var(--mantine-scale));--ni-chevron-size-lg:calc(1.125rem*var(--mantine-scale));--ni-chevron-size-xl:calc(1.25rem*var(--mantine-scale));--ni-chevron-size:var(--ni-chevron-size-sm);display:flex;flex-direction:column;height:calc(var(--_input-height) - .125rem*var(--mantine-scale));margin-left:var(--_controls-ml,auto);margin-right:var(--_controls-mr,0);max-width:calc(var(--ni-chevron-size)*1.7);width:100%}[dir=rtl] .m-95e17d22{--_controls-ml:0;--_controls-mr:auto}.m-80b4b171{--_control-bd:calc(.0625rem*var(--mantine-scale)) solid var(--_input-bd);--_control-radius:calc(var(--_input-radius) - .0625rem*var(--mantine-scale));align-items:center;background-color:var(--_control-bg,transparent);border-left:var(--_control-bdl,var(--_control-bd));border-right:var(--_control-bdr,none);color:var(--mantine-color-text);display:flex;flex:0 0 50%;height:calc(var(--_input-height)/2 - .0625rem*var(--mantine-scale));justify-content:center;opacity:var(--_control-opacity,1);padding:0;pointer-events:var(--_control-pointer-events,auto);width:100%}.m-80b4b171:disabled{--_control-pointer-events:none;--_control-opacity:.4}[dir=rtl] .m-80b4b171{--_control-bdl:none;--_control-bdr:var(--_control-bd)}@media (hover:hover){[data-mantine-color-scheme=light] .m-80b4b171:hover{--_control-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-80b4b171:hover{--_control-bg:var(--mantine-color-dark-4)}}@media (hover:none){[data-mantine-color-scheme=light] .m-80b4b171:active{--_control-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-80b4b171:active{--_control-bg:var(--mantine-color-dark-4)}}.m-80b4b171:first-of-type{border-bottom:calc(.03125rem*var(--mantine-scale)) solid var(--_input-bd);border-radius:0 var(--_control-radius) 0 0}[dir=rtl] .m-80b4b171:first-of-type{border-radius:var(--_control-radius) 0 0 0}.m-80b4b171:last-of-type{border-radius:0 0 var(--_control-radius) 0;border-top:calc(.03125rem*var(--mantine-scale)) solid var(--_input-bd)}[dir=rtl] .m-80b4b171:last-of-type{border-radius:0 0 0 var(--_control-radius)}.m-4addd315{--pagination-control-size-xs:calc(1.375rem*var(--mantine-scale));--pagination-control-size-sm:calc(1.625rem*var(--mantine-scale));--pagination-control-size-md:calc(2rem*var(--mantine-scale));--pagination-control-size-lg:calc(2.375rem*var(--mantine-scale));--pagination-control-size-xl:calc(2.75rem*var(--mantine-scale));--pagination-control-size:var(--pagination-control-size-md);--pagination-control-fz:var(--mantine-font-size-md);--pagination-active-bg:var(--mantine-primary-color-filled)}.m-326d024a{align-items:center;background-color:var(--_control-bg-color);border:calc(.0625rem*var(--mantine-scale)) solid var(--_control-border-color);border-radius:var(--pagination-control-radius,var(--mantine-radius-default));color:var(--_control-color,var(--mantine-color-text));cursor:var(--_control-cursor,pointer);display:flex;font-size:var(--pagination-control-fz);height:var(--pagination-control-size);justify-content:center;line-height:1;min-width:var(--pagination-control-size);opacity:var(--_control-opacity,1);padding:var(--_control-padding,0)}.m-326d024a[data-with-padding]{--_control-padding:calc(var(--pagination-control-size)/4)}.m-326d024a:disabled,.m-326d024a[data-disabled]{--_control-cursor:not-allowed;--_control-opacity:.4}.m-326d024a[data-active]{--_control-bg-color:var(--pagination-active-bg)!important;--_control-border-color:var(--pagination-active-bg)!important;--_control-color:var(--mantine-color-white)}[data-mantine-color-scheme=light] .m-326d024a{--_control-border-color:var(--mantine-color-gray-4);--_control-bg-color:var(--mantine-color-white);--_control-bg-hover:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-326d024a{--_control-border-color:var(--mantine-color-dark-4);--_control-bg-color:var(--mantine-color-dark-6);--_control-bg-hover:var(--mantine-color-dark-5)}@media (hover:hover){.m-326d024a:hover:not(:disabled,[data-disabled]){--_control-bg-color:var(--_control-bg-hover)}}@media (hover:none){.m-326d024a:active:not(:disabled,[data-disabled]){--_control-bg-color:var(--_control-bg-hover)}}[dir=rtl] .m-326d024a>svg{transform:rotate(180deg)}.m-4ad7767d{align-items:center;display:flex;height:var(--pagination-control-size);justify-content:center;min-width:var(--pagination-control-size);pointer-events:none}.m-f61ca620{--psi-button-size-xs:calc(1.375rem*var(--mantine-scale));--psi-button-size-sm:calc(1.625rem*var(--mantine-scale));--psi-button-size-md:calc(1.75rem*var(--mantine-scale));--psi-button-size-lg:calc(2rem*var(--mantine-scale));--psi-button-size-xl:calc(2.5rem*var(--mantine-scale));--psi-icon-size-xs:calc(.75rem*var(--mantine-scale));--psi-icon-size-sm:calc(.9375rem*var(--mantine-scale));--psi-icon-size-md:calc(1.0625rem*var(--mantine-scale));--psi-icon-size-lg:calc(1.1875rem*var(--mantine-scale));--psi-icon-size-xl:calc(1.3125rem*var(--mantine-scale));--psi-button-size:var(--psi-button-size-sm);--psi-icon-size:var(--psi-icon-size-sm)}.m-ccf8da4c{overflow:hidden;position:relative}.m-f2d85dd2{background-color:transparent;border:0;color:inherit;font-family:var(--mantine-font-family);font-size:inherit;height:100%;top:0;right:0;bottom:0;left:0;line-height:var(--mantine-line-height);outline:0;padding-left:var(--_input-padding-left);padding-right:var(--_input-padding-right);position:absolute;width:100%}.m-ccf8da4c[data-disabled] .m-f2d85dd2,.m-f2d85dd2:disabled{cursor:not-allowed}.m-f2d85dd2::placeholder{color:var(--_input-placeholder-color);opacity:1}.m-b1072d44{height:var(--psi-button-size);min-height:var(--psi-button-size);min-width:var(--psi-button-size);width:var(--psi-button-size)}.m-b1072d44:disabled{display:none}.m-f1cb205a{--pin-input-size-xs:calc(1.875rem*var(--mantine-scale));--pin-input-size-sm:calc(2.25rem*var(--mantine-scale));--pin-input-size-md:calc(2.625rem*var(--mantine-scale));--pin-input-size-lg:calc(3.125rem*var(--mantine-scale));--pin-input-size-xl:calc(3.75rem*var(--mantine-scale));--pin-input-size:var(--pin-input-size-sm)}.m-cb288ead{height:var(--pin-input-size);width:var(--pin-input-size)}@keyframes m-81a374bd{0%{background-position:0 0}to{background-position:calc(2.5rem*var(--mantine-scale)) 0}}.m-db6d6462{--progress-radius:var(--mantine-radius-default);--progress-size-xs:calc(.1875rem*var(--mantine-scale));--progress-size-sm:calc(.3125rem*var(--mantine-scale));--progress-size-md:calc(.5rem*var(--mantine-scale));--progress-size-lg:calc(.75rem*var(--mantine-scale));--progress-size-xl:calc(1rem*var(--mantine-scale));--progress-size:var(--progress-size-md);background-color:var(--_track-bg);border-radius:var(--progress-radius);display:flex;height:var(--progress-size);overflow:hidden;position:relative}[data-mantine-color-scheme=light] .m-db6d6462{--_track-bg:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-db6d6462{--_track-bg:var(--mantine-color-dark-4)}.m-2242eb65{align-items:center;animation:var(--_section-animation);background-color:var(--progress-section-color);background-image:var(--_section-gradient);background-size:calc(1.25rem*var(--mantine-scale)) calc(1.25rem*var(--mantine-scale));border-radius:var(--_section-radius);display:flex;height:100%;justify-content:center;overflow:hidden;width:var(--progress-section-width)}.m-2242eb65[data-striped]{--_section-gradient:linear-gradient(45deg,hsla(0,0%,100%,.15) 25%,transparent 0,transparent 50%,hsla(0,0%,100%,.15) 0,hsla(0,0%,100%,.15) 75%,transparent 0,transparent)}.m-2242eb65[data-animated]{--_section-animation:m-81a374bd 1s linear infinite}.m-2242eb65:last-of-type{--_section-radius:0 var(--progress-radius) var(--progress-radius) 0}.m-2242eb65:first-of-type,[dir=rtl] .m-2242eb65:last-of-type{--_section-radius:var(--progress-radius) 0 0 var(--progress-radius)}[dir=rtl] .m-2242eb65:first-of-type{--_section-radius:0 var(--progress-radius) var(--progress-radius) 0}.m-91e40b74{color:var(--mantine-color-white);font-size:min(calc(var(--progress-size)*.65),calc(1.125rem*var(--mantine-scale)));font-weight:700;line-height:1;overflow:hidden;padding-left:calc(.25rem*var(--mantine-scale));padding-right:calc(.25rem*var(--mantine-scale));text-overflow:ellipsis;-webkit-user-select:none;user-select:none;white-space:nowrap}.m-f3f1af94{--radio-size-xs:calc(1rem*var(--mantine-scale));--radio-size-sm:calc(1.25rem*var(--mantine-scale));--radio-size-md:calc(1.5rem*var(--mantine-scale));--radio-size-lg:calc(1.875rem*var(--mantine-scale));--radio-size-xl:calc(2.25rem*var(--mantine-scale));--radio-size:var(--radio-size-sm);--radio-icon-size-xs:calc(.375rem*var(--mantine-scale));--radio-icon-size-sm:calc(.5rem*var(--mantine-scale));--radio-icon-size-md:calc(.625rem*var(--mantine-scale));--radio-icon-size-lg:calc(.875rem*var(--mantine-scale));--radio-icon-size-xl:calc(1rem*var(--mantine-scale));--radio-icon-size:var(--radio-icon-size-sm);--radio-icon-color:var(--mantine-color-white)}.m-89c4f5e4{height:var(--radio-size);order:var(--_radio-order,1);position:relative;width:var(--radio-size)}.m-89c4f5e4[data-label-position=left]{--_radio-order:2}.m-f3ed6b2b{color:var(--_radio-icon-color,var(--radio-icon-color));height:var(--radio-icon-size);left:calc(50% - var(--radio-icon-size)/2);opacity:var(--_radio-icon-opacity,0);pointer-events:none;position:absolute;top:calc(50% - var(--radio-icon-size)/2);transform:var(--_radio-icon-transform,scale(.2) translateY(calc(.625rem*var(--mantine-scale))));transition:opacity .1s ease,transform .2s ease;width:var(--radio-icon-size)}.m-8a3dbb89{-webkit-tap-highlight-color:transparent;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--_radio-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_radio-bd-color);border-radius:var(--radio-radius,var(--radio-size));cursor:var(--_cursor,var(--mantine-cursor-type));display:flex;height:var(--radio-size);justify-content:center;margin:0;position:relative;transition-duration:.1s;transition-property:background-color,border-color;transition-timing-function:ease;width:var(--radio-size)}[data-mantine-color-scheme=light] .m-8a3dbb89{--_radio-bg:var(--mantine-color-white);--_radio-bd-color:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-8a3dbb89{--_radio-bg:var(--mantine-color-dark-6);--_radio-bd-color:var(--mantine-color-dark-4)}.m-8a3dbb89:checked{--_radio-bg:var(--radio-color,var(--mantine-primary-color-filled));--_radio-bd-color:var(--radio-color,var(--mantine-primary-color-filled))}.m-8a3dbb89:checked+.m-f3ed6b2b{--_radio-icon-opacity:1;--_radio-icon-transform:scale(1)}.m-8a3dbb89:disabled{--_cursor:not-allowed}[data-mantine-color-scheme=light] .m-8a3dbb89:disabled{--_radio-bg:var(--mantine-color-gray-1);--_radio-bd-color:var(--mantine-color-gray-2)}[data-mantine-color-scheme=light] .m-8a3dbb89:disabled+.m-f3ed6b2b{--_radio-icon-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-8a3dbb89:disabled{--_radio-bg:var(--mantine-color-dark-5);--_radio-bd-color:var(--mantine-color-dark-4)}[data-mantine-color-scheme=dark] .m-8a3dbb89:disabled+.m-f3ed6b2b{--_radio-icon-color:var(--mantine-color-dark-7)}.m-8a3dbb89[data-error]{--_radio-bd-color:var(--mantine-color-error)}.m-1bfe9d39+.m-f3ed6b2b{--_radio-icon-color:var(--radio-color)}[data-mantine-color-scheme] .m-1bfe9d39:checked:not(:disabled){--_radio-bg:transparent;--_radio-bd-color:var(--radio-color)}[data-mantine-color-scheme] .m-1bfe9d39:checked:not(:disabled)+.m-f3ed6b2b{--_radio-icon-color:var(--radio-color);--_radio-icon-opacity:1;--_radio-icon-transform:none}.m-f8d312f2{--rating-size-xs:calc(.875rem*var(--mantine-scale));--rating-size-sm:calc(1.125rem*var(--mantine-scale));--rating-size-md:calc(1.25rem*var(--mantine-scale));--rating-size-lg:calc(1.75rem*var(--mantine-scale));--rating-size-xl:calc(2rem*var(--mantine-scale));display:flex;pointer-events:var(--_pointer-events);width:max-content}.m-f8d312f2:has(input:disabled){--_pointer-events:none}.m-61734bb7{position:relative;transform:var(--_transform);transition:transform .1s ease;z-index:var(--_z-index)}.m-61734bb7[data-active]{--_z-index:1;--_transform:scale(1.1)}.m-5662a89a{stroke:var(--_star-color);fill:var(--_star-color);display:block;height:var(--rating-size);width:var(--rating-size)}[data-mantine-color-scheme=light] .m-5662a89a{--_star-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-5662a89a{--_star-color:var(--mantine-color-dark-3)}[data-mantine-color-scheme] .m-5662a89a[data-filled]{--_star-color:var(--rating-color)}.m-211007ba{-webkit-tap-highlight-color:transparent;height:0;opacity:0;overflow:hidden;position:absolute;white-space:nowrap;width:0}.m-211007ba:focus-visible+label{outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem*var(--mantine-scale))}.m-21342ee4{-webkit-tap-highlight-color:transparent;cursor:pointer;display:block;left:0;position:absolute;top:0;z-index:var(--rating-item-z-index,0)}.m-21342ee4[data-read-only]{cursor:default}.m-21342ee4:last-of-type{position:relative}.m-fae05d6a{clip-path:var(--rating-symbol-clip-path)}.m-b32e4812{position:relative}.m-b32e4812,.m-d43b5134{height:var(--rp-size);min-height:var(--rp-size);min-width:var(--rp-size);width:var(--rp-size)}.m-d43b5134{transform:rotate(-90deg)}.m-b1ca1fbf{stroke:var(--curve-color,var(--_curve-root-color))}[data-mantine-color-scheme=light] .m-b1ca1fbf{--_curve-root-color:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-b1ca1fbf{--_curve-root-color:var(--mantine-color-dark-4)}.m-b23f9dc4{left:var(--rp-label-offset);position:absolute;right:var(--rp-label-offset);top:50%;transform:translateY(-50%)}.m-1b3c8819{background-color:var(--_tooltip-bg);border-radius:var(--tooltip-radius,var(--mantine-radius-default));color:var(--tooltip-color,var(--_tooltip-color));font-size:var(--mantine-font-size-sm);padding:calc(var(--mantine-spacing-xs)/2) var(--mantine-spacing-xs);pointer-events:none;position:absolute;white-space:var(--_tooltip-white-space,nowrap)}[data-mantine-color-scheme=light] .m-1b3c8819{--_tooltip-bg:var(--tooltip-bg,var(--mantine-color-gray-9));--_tooltip-color:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-1b3c8819{--_tooltip-bg:var(--tooltip-bg,var(--mantine-color-gray-2));--_tooltip-color:var(--mantine-color-black)}.m-1b3c8819[data-multiline]{--_tooltip-white-space:normal}.m-f898399f{background-color:inherit;border:0;z-index:1}.m-cf365364{--sc-padding-xs:calc(.1875rem*var(--mantine-scale)) calc(.375rem*var(--mantine-scale));--sc-padding-sm:calc(.3125rem*var(--mantine-scale)) calc(.625rem*var(--mantine-scale));--sc-padding-md:calc(.4375rem*var(--mantine-scale)) calc(.875rem*var(--mantine-scale));--sc-padding-lg:calc(.5625rem*var(--mantine-scale)) calc(1rem*var(--mantine-scale));--sc-padding-xl:calc(.75rem*var(--mantine-scale)) calc(1.25rem*var(--mantine-scale));--sc-transition-duration:.2s;--sc-padding:var(--sc-padding-sm);--sc-transition-timing-function:ease;--sc-font-size:var(--mantine-font-size-sm);background-color:var(--_bg);border-radius:var(--sc-radius,var(--mantine-radius-default));display:var(--_display,inline-flex);flex-direction:var(--_flex-direction,row);overflow:hidden;padding:4px;position:relative;width:var(--_width,auto)}.m-cf365364[data-full-width]{--_display:flex}.m-cf365364[data-orientation=vertical]{--_display:flex;--_flex-direction:column;--_width:max-content}.m-cf365364[data-orientation=vertical][data-full-width]{--_width:auto}[data-mantine-color-scheme=light] .m-cf365364{--_bg:var(--mantine-color-gray-1)}[data-mantine-color-scheme=dark] .m-cf365364{--_bg:var(--mantine-color-dark-8)}.m-9e182ccd{background-color:var(--_bg);border-radius:var(--sc-radius,var(--mantine-radius-default));box-shadow:var(--_box-shadow);display:block;height:var(--sc-indicator-height);position:absolute;transform:var(--sc-indicator-transform);transition:transform var(--sc-transition-duration) var(--sc-transition-timing-function),width var(--sc-transition-duration) var(--sc-transition-timing-function);width:var(--sc-indicator-width);z-index:1}[data-mantine-color-scheme=light] .m-9e182ccd{--_box-shadow:var(--sc-shadow,none);--_bg:var(--sc-color,var(--mantine-color-white))}[data-mantine-color-scheme=dark] .m-9e182ccd{--_box-shadow:none;--_bg:var(--sc-color,var(--mantine-color-dark-5))}.m-1738fcb2{-webkit-tap-highlight-color:transparent;border-radius:var(--sc-radius,var(--mantine-radius-default));color:var(--_color);cursor:var(--_cursor,pointer);display:block;font-size:var(--sc-font-size);font-weight:500;outline:var(--_outline,none);overflow:hidden;padding:var(--sc-padding);text-align:center;text-overflow:ellipsis;transition:color var(--sc-transition-duration) var(--sc-transition-timing-function);-webkit-user-select:none;user-select:none;white-space:nowrap}.m-1738fcb2[data-disabled],fieldset:disabled .m-1738fcb2{--_cursor:not-allowed}[data-mantine-color-scheme=light] .m-1738fcb2[data-disabled],[data-mantine-color-scheme=light] fieldset:disabled .m-1738fcb2{--_color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m-1738fcb2[data-disabled],[data-mantine-color-scheme=dark] fieldset:disabled .m-1738fcb2{--_color:var(--mantine-color-dark-3)}[data-mantine-color-scheme=light] .m-1738fcb2[data-active]{--_color:var(--sc-label-color,var(--mantine-color-black))}[data-mantine-color-scheme=dark] .m-1738fcb2[data-active]{--_color:var(--sc-label-color,var(--mantine-color-white))}@media (hover:hover){[data-mantine-color-scheme=light] .m-1738fcb2:not([data-disabled]):not([data-active]):hover{--_color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-1738fcb2:not([data-disabled]):not([data-active]):hover{--_color:var(--mantine-color-white)}}@media (hover:none){[data-mantine-color-scheme=light] .m-1738fcb2:not([data-disabled]):not([data-active]):active{--_color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-1738fcb2:not([data-disabled]):not([data-active]):active{--_color:var(--mantine-color-white)}}@media (hover:hover){[data-mantine-color-scheme=light] fieldset:disabled .m-1738fcb2:hover{--_color:var(--mantine-color-gray-5)!important}[data-mantine-color-scheme=dark] fieldset:disabled .m-1738fcb2:hover{--_color:var(--mantine-color-dark-3)!important}}@media (hover:none){[data-mantine-color-scheme=light] fieldset:disabled .m-1738fcb2:active{--_color:var(--mantine-color-gray-5)!important}[data-mantine-color-scheme=dark] fieldset:disabled .m-1738fcb2:active{--_color:var(--mantine-color-dark-3)!important}}[data-mantine-color-scheme=light] .m-1738fcb2{--_color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] .m-1738fcb2{--_color:var(--mantine-color-dark-1)}.m-1714d588{height:0;opacity:0;overflow:hidden;position:absolute;white-space:nowrap;width:0}.m-1714d588[data-focus-ring=auto]:focus:focus-visible+.m-1738fcb2{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}.m-1714d588[data-focus-ring=always]:focus+.m-1738fcb2{--_outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-color-blue-filled)}.m-69686b9b{flex:1;position:relative;transition:border-color var(--sc-transition-duration) var(--sc-transition-timing-function);z-index:2}.m-69686b9b:before{background-color:var(--_separator-color);bottom:0;content:"";left:0;position:absolute;top:0;transition:background-color var(--sc-transition-duration) var(--sc-transition-timing-function);width:calc(.0625rem*var(--mantine-scale))}[dir=rtl] .m-69686b9b:before{left:auto;right:0}.m-69686b9b[data-orientation=vertical]:before{bottom:auto;height:calc(.0625rem*var(--mantine-scale));left:0;right:0;top:0;width:auto}[data-mantine-color-scheme=light] .m-69686b9b{--_separator-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-69686b9b{--_separator-color:var(--mantine-color-dark-4)}.m-69686b9b:first-of-type:before,[data-mantine-color-scheme] .m-69686b9b[data-active]+.m-69686b9b:before,[data-mantine-color-scheme] .m-69686b9b[data-active]:before{--_separator-color:transparent}.m-2415a157{display:grid;gap:var(--sg-spacing-y) var(--sg-spacing-x);grid-template-columns:repeat(var(--sg-cols),minmax(0,1fr))}@keyframes m-299c329c{0%,to{opacity:.4}50%{opacity:1}}.m-18320242{border-radius:var(--skeleton-radius,var(--mantine-radius-default));height:var(--skeleton-height,auto);position:relative;transform:translateZ(0);-webkit-transform:translateZ(0);width:var(--skeleton-width,100%)}.m-18320242[data-animate]:after{animation:m-299c329c 1.5s linear infinite}.m-18320242[data-visible]{overflow:hidden}.m-18320242[data-visible]:before{background-color:var(--mantine-color-body);content:"";top:0;right:0;bottom:0;left:0;position:absolute;z-index:10}.m-18320242[data-visible]:after{content:"";top:0;right:0;bottom:0;left:0;position:absolute;z-index:11}[data-mantine-color-scheme=light] .m-18320242[data-visible]:after{background-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-18320242[data-visible]:after{background-color:var(--mantine-color-dark-4)}.m-dd36362e{--slider-size-xs:calc(.25rem*var(--mantine-scale));--slider-size-sm:calc(.375rem*var(--mantine-scale));--slider-size-md:calc(.5rem*var(--mantine-scale));--slider-size-lg:calc(.625rem*var(--mantine-scale));--slider-size-xl:calc(.75rem*var(--mantine-scale));--slider-size:var(--slider-size-md);--slider-radius:calc(62.5rem*var(--mantine-scale));--slider-color:var(--mantine-primary-color-filled);-webkit-tap-highlight-color:transparent;align-items:center;display:flex;flex-direction:column;height:calc(var(--slider-size)*2);outline:none;padding-left:var(--slider-size);padding-right:var(--slider-size);position:relative;touch-action:none}[data-mantine-color-scheme=light] .m-dd36362e{--slider-track-bg:var(--mantine-color-gray-2);--slider-track-disabled-bg:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-dd36362e{--slider-track-bg:var(--mantine-color-dark-4);--slider-track-disabled-bg:var(--mantine-color-dark-3)}.m-c9357328{background-color:var(--_label-bg);border-radius:var(--mantine-radius-sm);color:var(--mantine-color-white);font-size:var(--mantine-font-size-xs);padding:calc(var(--mantine-spacing-xs)/2);pointer-events:none;position:absolute;top:calc(-2.25rem*var(--mantine-scale));touch-action:none;-webkit-user-select:none;user-select:none;white-space:nowrap}[data-mantine-color-scheme=light] .m-c9357328{--_label-bg:var(--mantine-color-gray-9)}[data-mantine-color-scheme=dark] .m-c9357328{--_label-bg:var(--mantine-color-dark-4)}.m-c9a9a60a{align-items:center;background-color:var(--_thumb-bg);border:calc(.25rem*var(--mantine-scale)) solid var(--_thumb-bd);border-radius:var(--slider-radius);box-shadow:var(--_thumb-box-shadow,none);color:var(--_thumb-bd);cursor:pointer;display:var(--_thumb-display,flex);height:var(--slider-thumb-size);justify-content:center;left:var(--slider-thumb-offset);outline-offset:calc(.125rem*var(--mantine-scale));position:absolute;top:50%;touch-action:none;transform:var(--_thumb-transform,translate(-50%,-50%));transition:box-shadow .1s ease,transform .1s ease;-webkit-user-select:none;user-select:none;width:var(--slider-thumb-size);z-index:3}[dir=rtl] .m-c9a9a60a{left:auto;right:calc(var(--slider-thumb-offset) - var(--slider-thumb-size))}.m-c9a9a60a[data-disabled],fieldset:disabled .m-c9a9a60a{--_thumb-display:none}.m-c9a9a60a[data-dragging]{--_thumb-transform:translate(-50%,-50%) scale(1.05);--_thumb-box-shadow:var(--mantine-shadow-sm)}[data-mantine-color-scheme=light] .m-c9a9a60a{--_thumb-bd:var(--slider-color);--_thumb-bg:var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m-c9a9a60a{--_thumb-bd:var(--mantine-color-white);--_thumb-bg:var(--slider-color)}.m-a8645c2{align-items:center;cursor:var(--_track-cursor,pointer);display:flex;height:calc(var(--slider-size)*2);width:100%}.m-a8645c2[data-disabled],fieldset:disabled .m-a8645c2{--_track-cursor:not-allowed}.m-c9ade57f{height:var(--slider-size);position:relative;width:100%}.m-c9ade57f[data-inverted]:not([data-disabled]){--_track-bg:var(--slider-color)}.m-c9ade57f[data-inverted][data-disabled],fieldset:disabled .m-c9ade57f[data-inverted]{--_track-bg:var(--slider-track-disabled-bg)}.m-c9ade57f:before{background-color:var(--_track-bg,var(--slider-track-bg));content:"";left:calc(var(--slider-size)*-1);right:calc(var(--slider-size)*-1);z-index:0}.m-38aeed47,.m-c9ade57f:before{border-radius:var(--slider-radius);bottom:0;position:absolute;top:0}.m-38aeed47{background-color:var(--_bar-bg,var(--slider-color));left:var(--slider-bar-offset);width:var(--slider-bar-width);z-index:1}[dir=rtl] .m-38aeed47{left:auto;right:var(--slider-bar-offset)}.m-38aeed47[data-inverted]{--_bar-bg:var(--slider-track-bg)}.m-38aeed47[data-disabled]:not([data-inverted]),fieldset:disabled .m-38aeed47:not([data-inverted]){--_bar-bg:var(--_bar-disabled-bg)}[data-mantine-color-scheme=light] .m-38aeed47{--_bar-disabled-bg:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-38aeed47{--_bar-disabled-bg:var(--mantine-color-dark-3)}.m-b7b0423a{height:0;left:calc(var(--mark-offset) - var(--slider-size)/2);pointer-events:none;position:absolute;top:0;z-index:2}[dir=rtl] .m-b7b0423a{left:unset;right:calc(var(--mark-offset) - var(--slider-size)/2)}.m-dd33bc19{background-color:var(--_mark-bg,var(--mantine-color-white));border:calc(.125rem*var(--mantine-scale)) solid var(--_mark-bd);border-radius:calc(62.5rem*var(--mantine-scale));height:var(--slider-size);pointer-events:none;transform:translate((calc(var(--slider-size)/-2)));width:var(--slider-size)}[data-mantine-color-scheme] .m-dd33bc19[data-filled]{--_mark-bd:var(--slider-color)}[data-mantine-color-scheme=light] .m-dd33bc19[data-filled][data-disabled]{--_mark-bd:var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m-dd33bc19[data-filled][data-disabled]{--_mark-bd:var(--mantine-color-dark-3)}[data-mantine-color-scheme=light] .m-dd33bc19{--_mark-bd:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-dd33bc19{--_mark-bd:var(--mantine-color-dark-4)}.m-68c77a5b{color:var(--_mark-label-color);cursor:pointer;font-size:var(--mantine-font-size-sm);transform:translate(calc(-50% + var(--slider-size)/2),calc(var(--mantine-spacing-xs)/2));-webkit-user-select:none;user-select:none;white-space:nowrap}[data-mantine-color-scheme=light] .m-68c77a5b{--_mark-label-color:var(--mantine-color-gray-6)}[data-mantine-color-scheme=dark] .m-68c77a5b{--_mark-label-color:var(--mantine-color-dark-2)}.m-559cce2d{margin-bottom:var(--_spoiler-margin-bottom);position:relative}.m-559cce2d[data-has-spoiler]{--_spoiler-margin-bottom:calc(1.5rem*var(--mantine-scale))}.m-b912df4e{display:flex;flex-direction:column;overflow:hidden;transition:max-height var(--spoiler-transition-duration,.2s) ease}.m-b9131032{height:calc(1.5rem*var(--mantine-scale));left:0;position:absolute;top:100%}.m-6d731127{align-items:var(--stack-align,stretch);display:flex;flex-direction:column;gap:var(--stack-gap,var(--mantine-spacing-md));justify-content:var(--stack-justify,flex-start)}.m-cbb4ea7e{--stepper-icon-size-xs:calc(2.125rem*var(--mantine-scale));--stepper-icon-size-sm:calc(2.25rem*var(--mantine-scale));--stepper-icon-size-md:calc(2.625rem*var(--mantine-scale));--stepper-icon-size-lg:calc(3rem*var(--mantine-scale));--stepper-icon-size-xl:calc(3.25rem*var(--mantine-scale));--stepper-icon-size:var(--stepper-icon-size-md);--stepper-color:var(--mantine-primary-color-filled);--stepper-content-padding:var(--mantine-spacing-md);--stepper-spacing:var(--mantine-spacing-md);--stepper-radius:calc(62.5rem*var(--mantine-scale));--stepper-fz:var(--mantine-font-size-md)}.m-aaf89d0b{align-items:var(--_steps-align-items,center);display:flex;flex-direction:var(--_steps-direction);flex-wrap:var(--_steps-wrap,nowrap);gap:var(--_steps-gap)}.m-aaf89d0b[data-wrap]{--_steps-wrap:wrap;--_steps-gap:var(--mantine-spacing-md) 0}.m-aaf89d0b[data-orientation=vertical]{--_steps-direction:column}.m-aaf89d0b[data-orientation=vertical][data-icon-position=left]{--_steps-align-items:flex-start}.m-aaf89d0b[data-orientation=vertical][data-icon-position=right]{--_steps-align-items:flex-end}.m-aaf89d0b[data-orientation=horizontal]{--_steps-direction:row}.m-2a371ac9{--_separator-offset:calc(var(--stepper-icon-size)/2 - .0625rem*var(--mantine-scale));background-color:var(--_separator-bg);flex:1;height:var(--_separator-height);margin:var(--_separator-mt) var(--_separator-mr) var(--_separator-mb) var(--_separator-ml);transition:background-color .15s ease;width:var(--_separator-width)}[data-mantine-color-scheme=light] .m-2a371ac9{--_separator-bg:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-2a371ac9{--_separator-bg:var(--mantine-color-dark-2)}.m-2a371ac9[data-active]{--_separator-bg:var(--stepper-color)}.m-2a371ac9[data-orientation=horizontal]{--_separator-height:calc(.125rem*var(--mantine-scale));--_separator-ml:var(--mantine-spacing-md);--_separator-mr:var(--mantine-spacing-md);--_separator-mt:0;--_separator-mb:0}.m-2a371ac9[data-orientation=vertical]{--_separator-width:calc(.125rem*var(--mantine-scale));--_separator-mt:calc(var(--mantine-spacing-xs)/2);--_separator-mb:calc(var(--mantine-spacing-xs) - .125rem*var(--mantine-scale))}.m-2a371ac9[data-orientation=vertical][data-icon-position=left]{--_separator-ml:var(--_separator-offset);--_separator-mr:0}.m-2a371ac9[data-orientation=vertical][data-icon-position=right],[dir=rtl] .m-2a371ac9[data-orientation=vertical][data-icon-position=left]{--_separator-ml:0;--_separator-mr:var(--_separator-offset)}[dir=rtl] .m-2a371ac9[data-orientation=vertical][data-icon-position=right]{--_separator-ml:var(--_separator-offset);--_separator-mr:0}.m-78da155d{padding-top:var(--stepper-content-padding)}.m-cbb57068{--_step-color:var(--step-color,var(--stepper-color));cursor:var(--_step-cursor,default);display:flex;flex-direction:var(--_step-direction)}.m-cbb57068[data-allow-click]{--_step-cursor:pointer}.m-cbb57068[data-icon-position=left]{--_step-direction:row}.m-cbb57068[data-icon-position=right]{--_step-direction:row-reverse}.m-f56b1e2c{align-items:center;flex-direction:var(--_step-direction)}.m-833edb7e{--_separator-spacing:calc(var(--mantine-spacing-xs)/2);justify-content:flex-start;margin-top:var(--_step-mt,var(--_separator-spacing));min-height:calc(var(--stepper-icon-size) + var(--mantine-spacing-xl) + var(--_separator-spacing));overflow:hidden}.m-833edb7e:first-of-type{--_step-mt:0}.m-833edb7e:last-of-type .m-6496b3f3{display:none}.m-818e70b{position:relative}.m-6496b3f3{border-left:calc(.125rem*var(--mantine-scale)) solid var(--_separator-border-color);height:100vh;left:calc(var(--stepper-icon-size)/2);position:absolute;top:calc(var(--stepper-icon-size) + var(--_separator-spacing))}[data-mantine-color-scheme=light] .m-6496b3f3{--_separator-border-color:var(--mantine-color-gray-1)}[data-mantine-color-scheme=dark] .m-6496b3f3{--_separator-border-color:var(--mantine-color-dark-5)}[data-mantine-color-scheme] .m-6496b3f3[data-active]{--_separator-border-color:var(--stepper-color)}.m-1959ad01{align-items:center;background-color:var(--_step-icon-bg);border:calc(.125rem*var(--mantine-scale)) solid var(--_step-icon-border-color);border-radius:var(--stepper-radius);color:var(--_step-icon-color);display:flex;font-size:var(--stepper-fz);font-weight:700;height:var(--stepper-icon-size);justify-content:center;min-height:var(--stepper-icon-size);min-width:var(--stepper-icon-size);position:relative;transition:background-color .15s ease,border-color .15s ease;width:var(--stepper-icon-size)}[data-mantine-color-scheme=light] .m-1959ad01{--_step-icon-bg:var(--mantine-color-gray-1);--_step-icon-border-color:var(--mantine-color-gray-1);--_step-icon-color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] .m-1959ad01{--_step-icon-bg:var(--mantine-color-dark-5);--_step-icon-border-color:var(--mantine-color-dark-5);--_step-icon-color:var(--mantine-color-dark-1)}[data-mantine-color-scheme] .m-1959ad01[data-progress]{--_step-icon-border-color:var(--_step-color)}[data-mantine-color-scheme] .m-1959ad01[data-completed]{--_step-icon-color:var(--mantine-color-white);--_step-icon-bg:var(--_step-color);--_step-icon-border-color:var(--_step-color)}.m-a79331dc{align-items:center;color:var(--mantine-color-white);display:flex;top:0;right:0;bottom:0;left:0;justify-content:center;position:absolute}.m-1956aa2a{display:flex;flex-direction:column;margin-left:var(--_step-body-ml);margin-right:var(--_step-body-mr);margin-top:var(--_step-body-mt);text-align:var(--_step-body-ta)}.m-1956aa2a[data-icon-position=left]{--_step-body-ta:left;--_step-body-ml:var(--mantine-spacing-sm)}[dir=rtl] .m-1956aa2a[data-icon-position=left]{--_step-body-ta:right;--_step-body-ml:0;--_step-body-mr:var(--mantine-spacing-sm)}.m-1956aa2a[data-icon-position=right]{--_step-body-ta:right;--_step-body-mr:var(--mantine-spacing-sm)}[dir=rtl] .m-1956aa2a[data-icon-position=right]{--_step-body-ta:left;--_step-body-ml:var(--mantine-spacing-sm);--_step-body-mr:0}.m-12051f6c{font-size:var(--stepper-fz);font-weight:500;line-height:1}.m-164eea74{color:var(--mantine-color-dimmed);font-size:calc(var(--stepper-fz) - .125rem*var(--mantine-scale));line-height:1;margin-bottom:calc(var(--stepper-spacing)/3);margin-top:calc(var(--stepper-spacing)/3)}.m-5f93f3bb{--switch-height-xs:calc(1rem*var(--mantine-scale));--switch-height-sm:calc(1.25rem*var(--mantine-scale));--switch-height-md:calc(1.5rem*var(--mantine-scale));--switch-height-lg:calc(1.875rem*var(--mantine-scale));--switch-height-xl:calc(2.25rem*var(--mantine-scale));--switch-width-xs:calc(2rem*var(--mantine-scale));--switch-width-sm:calc(2.375rem*var(--mantine-scale));--switch-width-md:calc(2.875rem*var(--mantine-scale));--switch-width-lg:calc(3.5rem*var(--mantine-scale));--switch-width-xl:calc(4.5rem*var(--mantine-scale));--switch-thumb-size-xs:calc(.75rem*var(--mantine-scale));--switch-thumb-size-sm:calc(.875rem*var(--mantine-scale));--switch-thumb-size-md:calc(1.125rem*var(--mantine-scale));--switch-thumb-size-lg:calc(1.375rem*var(--mantine-scale));--switch-thumb-size-xl:calc(1.75rem*var(--mantine-scale));--switch-label-font-size-xs:calc(.3125rem*var(--mantine-scale));--switch-label-font-size-sm:calc(.375rem*var(--mantine-scale));--switch-label-font-size-md:calc(.4375rem*var(--mantine-scale));--switch-label-font-size-lg:calc(.5625rem*var(--mantine-scale));--switch-label-font-size-xl:calc(.6875rem*var(--mantine-scale));--switch-track-label-padding-xs:calc(.0625rem*var(--mantine-scale));--switch-track-label-padding-sm:calc(.125rem*var(--mantine-scale));--switch-track-label-padding-md:calc(.125rem*var(--mantine-scale));--switch-track-label-padding-lg:calc(.1875rem*var(--mantine-scale));--switch-track-label-padding-xl:calc(.1875rem*var(--mantine-scale));--switch-height:var(--switch-height-sm);--switch-width:var(--switch-width-sm);--switch-thumb-size:var(--switch-thumb-size-sm);--switch-label-font-size:var(--switch-label-font-size-sm);--switch-track-label-padding:var(--switch-track-label-padding-sm);--switch-radius:calc(62.5rem*var(--mantine-scale));--switch-color:var(--mantine-primary-color-filled);position:relative}.m-926b4011{height:0;opacity:0;padding:0;position:absolute;white-space:nowrap;width:0}.m-926b4011,.m-9307d992{margin:0;overflow:hidden}.m-9307d992{-webkit-tap-highlight-color:transparent;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--_switch-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_switch-bd);border-radius:var(--switch-radius);color:var(--_switch-color);cursor:var(--_switch-cursor,var(--mantine-cursor-type));display:flex;font-size:var(--switch-label-font-size);font-weight:600;height:var(--switch-height);line-height:0;min-width:var(--switch-width);order:var(--_switch-order,1);position:relative;transition:background-color .15s ease,border-color .15s ease;-webkit-user-select:none;user-select:none;z-index:0}.m-926b4011:focus-visible+.m-9307d992{outline:calc(.125rem*var(--mantine-scale)) solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem*var(--mantine-scale))}.m-926b4011:checked+.m-9307d992{--_switch-bg:var(--switch-color);--_switch-bd:var(--switch-color);--_switch-color:var(--mantine-color-white)}.m-926b4011:disabled+.m-9307d992,.m-926b4011[data-disabled]+.m-9307d992{--_switch-bg:var(--_switch-disabled-color);--_switch-bd:var(--_switch-disabled-color);--_switch-cursor:not-allowed}[data-mantine-color-scheme=light] .m-9307d992{--_switch-bg:var(--mantine-color-gray-2);--_switch-bd:var(--mantine-color-gray-3);--_switch-color:var(--mantine-color-gray-6);--_switch-disabled-color:var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m-9307d992{--_switch-bg:var(--mantine-color-dark-6);--_switch-bd:var(--mantine-color-dark-4);--_switch-color:var(--mantine-color-dark-1);--_switch-disabled-color:var(--mantine-color-dark-4)}.m-9307d992[data-error]{--_switch-bd:var(--mantine-color-error)}.m-9307d992[data-label-position=left]{--_switch-order:2}.m-93039a1d{background-color:var(--_switch-thumb-bg,var(--mantine-color-white));border:calc(.0625rem*var(--mantine-scale)) solid var(--_switch-thumb-bd);border-radius:var(--switch-radius);display:flex;height:var(--switch-thumb-size);left:var(--_switch-thumb-left,var(--switch-track-label-padding));position:absolute;transition:left .15s ease;width:var(--switch-thumb-size);z-index:1}[dir=rtl] .m-93039a1d{left:unset;right:var(--_switch-thumb-left,var(--switch-track-label-padding));transition:right .15s ease}.m-93039a1d>*{margin:auto}.m-926b4011:checked+*>.m-93039a1d{--_switch-thumb-left:calc(100% - var(--switch-thumb-size) - var(--switch-track-label-padding));--_switch-thumb-bd:var(--mantine-color-white)}.m-926b4011:disabled+*>.m-93039a1d,.m-926b4011[data-disabled]+*>.m-93039a1d{--_switch-thumb-bd:var(--_switch-thumb-bg-disabled);--_switch-thumb-bg:var(--_switch-thumb-bg-disabled)}[data-mantine-color-scheme=light] .m-93039a1d{--_switch-thumb-bd:var(--mantine-color-gray-3);--_switch-thumb-bg-disabled:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-93039a1d{--_switch-thumb-bd:var(--mantine-color-white);--_switch-thumb-bg-disabled:var(--mantine-color-dark-3)}.m-8277e082{display:grid;height:100%;margin:0 0 0 calc(var(--switch-thumb-size) + var(--switch-track-label-padding));min-width:calc(var(--switch-width) - var(--switch-thumb-size));padding-inline:var(--switch-track-label-padding);place-content:center;transition:margin .15s ease}.m-926b4011:checked+*>.m-8277e082,[dir=rtl] .m-8277e082{margin:0 calc(var(--switch-thumb-size) + var(--switch-track-label-padding)) 0 0}[dir=rtl] .m-926b4011:checked+*>.m-8277e082{margin:0 0 0 calc(var(--switch-thumb-size) + var(--switch-track-label-padding))}.m-b23fa0ef{border:var(--_table-border,none);border-collapse:collapse;caption-side:var(--table-caption-side,bottom);font-size:var(--mantine-font-size-sm);line-height:var(--mantine-line-height);table-layout:var(--table-layout,auto);width:100%}[data-mantine-color-scheme=light] .m-b23fa0ef{--_table-hover-color:var(--table-highlight-on-hover-color,var(--mantine-color-gray-1));--_table-striped-color:var(--table-striped-color,var(--mantine-color-gray-0));--_table-border-color:var(--table-border-color,var(--mantine-color-gray-3))}[data-mantine-color-scheme=dark] .m-b23fa0ef{--_table-hover-color:var(--table-highlight-on-hover-color,var(--mantine-color-dark-5));--_table-striped-color:var(--table-striped-color,var(--mantine-color-dark-6));--_table-border-color:var(--table-border-color,var(--mantine-color-dark-4))}.m-b23fa0ef[data-with-table-border]{--_table-border:calc(.0625rem*var(--mantine-scale)) solid var(--_table-border-color)}.m-4e7aa4f3{text-align:var(--_th-text-align,left)}[dir=rtl] .m-4e7aa4f3{--_th-text-align:right}.m-4e7aa4fd{background-color:var(--_tr-bg,transparent);border-bottom:var(--_tr-border-bottom,none)}@media (hover:hover){[data-mantine-color-scheme] .m-4e7aa4fd:hover[data-hover]{--_tr-bg:var(--_tr-hover-bg)!important}}@media (hover:none){[data-mantine-color-scheme] .m-4e7aa4fd:active[data-hover]{--_tr-bg:var(--_tr-hover-bg)!important}}.m-4e7aa4fd[data-with-row-border]{--_tr-border-bottom:calc(.0625rem*var(--mantine-scale)) solid var(--_table-border-color)}.m-4e7aa4ef,.m-4e7aa4f3{--_border-right:none;--_border-left:none;border-left:var(--_border-left);border-right:var(--_border-right);padding:var(--table-vertical-spacing) var(--table-horizontal-spacing,var(--mantine-spacing-xs))}.m-4e7aa4ef[data-with-column-border]:not(:last-child),.m-4e7aa4f3[data-with-column-border]:not(:last-child){--_border-right:calc(.0625rem*var(--mantine-scale)) solid var(--_table-border-color)}[dir=rtl] .m-4e7aa4ef[data-with-column-border]:not(:last-child),[dir=rtl] .m-4e7aa4f3[data-with-column-border]:not(:last-child){--_border-left:calc(.0625rem*var(--mantine-scale)) solid var(--_table-border-color);--_border-right:none}.m-b2404537>.m-4e7aa4fd:last-of-type[data-with-row-border]{--_tr-border-bottom:none}.m-b2404537>.m-4e7aa4fd[data-striped=even]:nth-of-type(2n),.m-b2404537>.m-4e7aa4fd[data-striped=odd]:nth-of-type(odd){--_tr-bg:var(--_table-striped-color)}.m-b2404537>.m-4e7aa4fd[data-hover]{--_tr-hover-bg:var(--_table-hover-color)}.m-b242d975{background-color:var(--_thead-bg,transparent);position:var(--_thead-position,static);top:var(--table-sticky-header-offset,0)}.m-b242d975[data-sticky]{--_thead-position:sticky;--_thead-bg:var(--mantine-color-body)}.m-9e5a3ac7{color:var(--mantine-color-dimmed);margin-bottom:var(--_margin-bottom,0);margin-top:var(--_margin-top,0)}.m-9e5a3ac7[data-side=top]{--_margin-bottom:var(--mantine-spacing-xs)}.m-9e5a3ac7[data-side=bottom]{--_margin-top:var(--mantine-spacing-xs)}.m-a100c15{overflow-x:var(--table-overflow)}.m-62259741{min-width:var(--table-min-width)}.m-89d60db1{--_tab-justify:flex-start;--_list-direction:row;--_panel-grow:unset;--_tabs-display:block;--_tabs-flex-direction:row;--_list-border-width:0;--_list-border-size:0 0 var(--_list-border-width) 0;--_list-gap:unset;--_list-line-bottom:0;--_list-line-top:unset;--_list-line-left:0;--_list-line-right:0;--_tab-radius:var(--tabs-radius) var(--tabs-radius) 0 0;--_tab-border-width:0 0 var(--_list-border-width) 0;display:var(--_tabs-display);flex-direction:var(--_tabs-flex-direction)}.m-89d60db1[data-inverted]{--_list-line-bottom:unset;--_list-line-top:0;--_tab-radius:0 0 var(--tabs-radius) var(--tabs-radius);--_tab-border-width:var(--_list-border-width) 0 0 0}.m-89d60db1[data-inverted] .m-576c9d4:before{bottom:unset;top:0}.m-89d60db1[data-orientation=vertical]{--_list-line-left:unset;--_list-line-right:0;--_list-line-top:0;--_list-line-bottom:0;--_list-border-size:0 var(--_list-border-width) 0 0;--_tab-border-width:0 var(--_list-border-width) 0 0;--_tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius);--_list-direction:column;--_panel-grow:1;--_tabs-display:flex}[dir=rtl] .m-89d60db1[data-orientation=vertical]{--_list-line-left:0;--_list-line-right:unset;--_list-border-size:0 0 0 var(--_list-border-width);--_tab-border-width:0 0 0 var(--_list-border-width);--_tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0}.m-89d60db1[data-orientation=vertical][data-placement=right]{--_tabs-flex-direction:row-reverse;--_list-line-left:0;--_list-line-right:unset;--_list-border-size:0 0 0 var(--_list-border-width);--_tab-border-width:0 0 0 var(--_list-border-width);--_tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0}[dir=rtl] .m-89d60db1[data-orientation=vertical][data-placement=right]{--_list-line-left:unset;--_list-line-right:0;--_list-border-size:0 var(--_list-border-width) 0 0;--_tab-border-width:0 var(--_list-border-width) 0 0;--_tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius)}[data-mantine-color-scheme=light] .m-89d60db1{--_tab-border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-89d60db1{--_tab-border-color:var(--mantine-color-dark-4)}.m-89d60db1[data-orientation=horizontal]{--_tab-justify:center}.m-89d60db1[data-variant=default]{--_list-border-width:calc(.125rem*var(--mantine-scale))}[data-mantine-color-scheme=light] .m-89d60db1[data-variant=default]{--_tab-hover-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-89d60db1[data-variant=default]{--_tab-hover-color:var(--mantine-color-dark-6)}.m-89d60db1[data-variant=outline]{--_list-border-width:calc(.0625rem*var(--mantine-scale))}.m-89d60db1[data-variant=pills]{--_list-gap:calc(var(--mantine-spacing-sm)/2)}[data-mantine-color-scheme=light] .m-89d60db1[data-variant=pills]{--_tab-hover-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-89d60db1[data-variant=pills]{--_tab-hover-color:var(--mantine-color-dark-6)}.m-89d33d6d{--_tab-grow:unset;display:flex;flex-direction:var(--_list-direction);flex-wrap:wrap;gap:var(--_list-gap);justify-content:var(--tabs-justify,flex-start)}.m-89d33d6d[data-grow]{--_tab-grow:1}.m-b0c91715{flex-grow:var(--_panel-grow)}.m-4ec4dce6{align-items:center;display:flex;flex-grow:var(--_tab-grow);font-size:var(--mantine-font-size-sm);justify-content:var(--_tab-justify);line-height:1;padding:var(--mantine-spacing-xs) var(--mantine-spacing-md);position:relative;-webkit-user-select:none;user-select:none;white-space:nowrap;z-index:0}.m-4ec4dce6:disabled,.m-4ec4dce6[data-disabled]{cursor:not-allowed;opacity:.5}.m-4ec4dce6:focus{z-index:1}.m-fc420b1f{align-items:center;display:flex;justify-content:center;margin-left:var(--_tab-section-margin-left,0);margin-right:var(--_tab-section-margin-right,0)}.m-fc420b1f[data-position=left]:not(:only-child){--_tab-section-margin-right:var(--mantine-spacing-xs)}[dir=rtl] .m-fc420b1f[data-position=left]:not(:only-child){--_tab-section-margin-right:0rem;--_tab-section-margin-left:var(--mantine-spacing-xs)}.m-fc420b1f[data-position=right]:not(:only-child){--_tab-section-margin-left:var(--mantine-spacing-xs)}[dir=rtl] .m-fc420b1f[data-position=right]:not(:only-child){--_tab-section-margin-left:0rem;--_tab-section-margin-right:var(--mantine-spacing-xs)}.m-576c9d4{position:relative}.m-576c9d4:before{border-color:var(--_tab-border-color);border-style:solid;border-width:var(--_list-border-size);bottom:var(--_list-line-bottom);content:"";left:var(--_list-line-left);position:absolute;right:var(--_list-line-right);top:var(--_list-line-top)}.m-539e827b{--__tab-border-color:transparent;--_tab-bg:transparent;background-color:var(--_tab-bg);border-color:var(--__tab-border-color);border-radius:var(--_tab-radius);border-style:solid;border-width:var(--_tab-border-width)}.m-539e827b[data-active]{--__tab-border-color:var(--tabs-color)}@media (hover:hover){.m-539e827b:hover{--_tab-bg:var(--_tab-hover-color)}.m-539e827b:hover:not([data-active]){--__tab-border-color:var(--_tab-border-color)}}@media (hover:none){.m-539e827b:active{--_tab-bg:var(--_tab-hover-color)}.m-539e827b:active:not([data-active]){--__tab-border-color:var(--_tab-border-color)}}@media (hover:hover){.m-539e827b:disabled:hover,.m-539e827b[data-disabled]:hover{--_tab-bg:transparent}}@media (hover:none){.m-539e827b:disabled:active,.m-539e827b[data-disabled]:active{--_tab-bg:transparent}}.m-6772fbd5{position:relative}.m-6772fbd5:before{border-color:var(--_tab-border-color);border-style:solid;border-width:var(--_list-border-size);bottom:var(--_list-line-bottom);content:"";left:var(--_list-line-left);position:absolute;right:var(--_list-line-right);top:var(--_list-line-top)}.m-b59ab47c{--_tab-border-bottom-color:transparent;--_tab-border-top-color:transparent;--_tab-border-right-color:transparent;--_tab-border-left-color:transparent;border-color:transparent;border-bottom:calc(.0625rem*var(--mantine-scale)) solid var(--_tab-border-bottom-color);border-left:calc(.0625rem*var(--mantine-scale)) solid var(--_tab-border-left-color);border-radius:var(--_tab-radius);border-right:calc(.0625rem*var(--mantine-scale)) solid var(--_tab-border-right-color);border-top:calc(.0625rem*var(--mantine-scale)) solid var(--_tab-border-top-color)}.m-b59ab47c[data-active]{--_tab-border-top-color:var(--_tab-border-color);--_tab-border-left-color:var(--_tab-border-color);--_tab-border-right-color:var(--_tab-border-color);--_tab-border-bottom-color:var(--mantine-color-body)}.m-b59ab47c[data-active][data-inverted]{--_tab-border-bottom-color:var(--_tab-border-color);--_tab-border-top-color:var(--mantine-color-body)}.m-b59ab47c[data-active][data-orientation=vertical][data-placement=left]{--_tab-border-right-color:var(--mantine-color-body);--_tab-border-left-color:var(--_tab-border-color);--_tab-border-bottom-color:var(--_tab-border-color)}[dir=rtl] .m-b59ab47c[data-active][data-orientation=vertical][data-placement=left]{--_tab-border-right-color:var(--_tab-border-color);--_tab-border-left-color:var(--mantine-color-body)}.m-b59ab47c[data-active][data-orientation=vertical][data-placement=right]{--_tab-border-left-color:var(--mantine-color-body);--_tab-border-right-color:var(--_tab-border-color);--_tab-border-bottom-color:var(--_tab-border-color)}[dir=rtl] .m-b59ab47c[data-active][data-orientation=vertical][data-placement=right]{--_tab-border-left-color:var(--_tab-border-color);--_tab-border-right-color:var(--mantine-color-body)}.m-c3381914{--_tab-bg:transparent;--_tab-color:inherit;background-color:var(--_tab-bg);border-radius:var(--tabs-radius);color:var(--_tab-color)}@media (hover:hover){.m-c3381914:not([data-disabled]):hover{--_tab-bg:var(--_tab-hover-color)}}@media (hover:none){.m-c3381914:not([data-disabled]):active{--_tab-bg:var(--_tab-hover-color)}}.m-c3381914[data-active][data-active]{--_tab-bg:var(--tabs-color);--_tab-color:var(--mantine-color-white)}@media (hover:hover){.m-c3381914[data-active][data-active]:hover{--_tab-bg:var(--tabs-color)}}@media (hover:none){.m-c3381914[data-active][data-active]:active{--_tab-bg:var(--tabs-color)}}.m-7341320d{--ti-size-xs:calc(1.125rem*var(--mantine-scale));--ti-size-sm:calc(1.375rem*var(--mantine-scale));--ti-size-md:calc(1.75rem*var(--mantine-scale));--ti-size-lg:calc(2.125rem*var(--mantine-scale));--ti-size-xl:calc(2.75rem*var(--mantine-scale));--ti-size:var(--ti-size-md);align-items:center;background:var(--ti-bg,var(--mantine-primary-color-filled));border:var(--ti-bd,calc(.0625rem*var(--mantine-scale)) solid transparent);border-radius:var(--ti-radius,var(--mantine-radius-default));color:var(--ti-color,var(--mantine-color-white));display:inline-flex;height:var(--ti-size);justify-content:center;line-height:1;min-height:var(--ti-size);min-width:var(--ti-size);position:relative;-webkit-user-select:none;user-select:none;width:var(--ti-size)}.m-43657ece{--offset:calc(var(--tl-bullet-size)/2 + var(--tl-line-width)/2);--tl-bullet-size:calc(1.25rem*var(--mantine-scale));--tl-line-width:calc(.25rem*var(--mantine-scale));--tl-radius:calc(62.5rem*var(--mantine-scale));--tl-color:var(--mantine-primary-color-filled);padding-left:var(--_tl-pl,0);padding-right:var(--_tl-pr,0)}.m-43657ece[data-align=left]{--_tl-pl:var(--offset)}[dir=rtl] .m-43657ece[data-align=left]{--_tl-pl:0;--_tl-pr:var(--offset)}.m-43657ece[data-align=right]{--_tl-pr:var(--offset)}[dir=rtl] .m-43657ece[data-align=right]{--_tl-pl:var(--offset);--_tl-pr:0}.m-2ebe8099{font-weight:500;line-height:1;margin-bottom:calc(var(--mantine-spacing-xs)/2)}.m-436178ff{--item-border:var(--tl-line-width) var(--tli-border-style,solid) var(--_item-border-color);color:var(--mantine-color-text);margin-top:var(--_item-mt);padding-left:var(--_item-pl,0);padding-right:var(--_item-pr,0);position:relative;text-align:var(--_item-ta)}.m-436178ff:before{border-left:var(--_line-border-left,var(--item-border));border-right:var(--_line-border-right,0);bottom:calc(var(--mantine-spacing-xl)*-1);content:"";display:var(--_line-display,none);left:var(--_line-left,0);pointer-events:none;position:absolute;right:var(--_line-right,0);top:0}[dir=rtl] .m-436178ff:before{--_line-border-left:0;--_line-border-right:var(--item-border)}.m-43657ece[data-align=left] .m-436178ff:before{--_line-left:calc(var(--tl-line-width)*-1);--_line-right:auto}.m-43657ece[data-align=right] .m-436178ff:before,[dir=rtl] .m-43657ece[data-align=left] .m-436178ff:before{--_line-left:auto;--_line-right:calc(var(--tl-line-width)*-1)}[dir=rtl] .m-43657ece[data-align=right] .m-436178ff:before{--_line-left:calc(var(--tl-line-width)*-1);--_line-right:auto}.m-43657ece[data-align=left] .m-436178ff{--_item-pl:var(--offset);--_item-ta:left}[dir=rtl] .m-43657ece[data-align=left] .m-436178ff{--_item-pl:0;--_item-pr:var(--offset)}.m-43657ece[data-align=right] .m-436178ff{--_item-pr:var(--offset);--_item-ta:right}[dir=rtl] .m-43657ece[data-align=right] .m-436178ff{--_item-pl:var(--offset);--_item-pr:0}[data-mantine-color-scheme=light] .m-436178ff{--_item-border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-436178ff{--_item-border-color:var(--mantine-color-dark-4)}[data-mantine-color-scheme] .m-436178ff[data-line-active]:before{border-color:var(--tli-color,var(--tl-color))}.m-436178ff:not(:last-of-type){--_line-display:block}.m-436178ff:not(:first-of-type){--_item-mt:var(--mantine-spacing-xl)}.m-8affcee1{align-items:center;background-color:var(--_bullet-bg-color,var(--mantine-color-body));border:var(--_bullet-border-width,var(--tl-line-width)) solid var(--_bullet-border-color);border-radius:var(--tli-radius,var(--tl-radius));color:var(--_bullet-color,var(--mantine-color-text));display:flex;height:var(--tl-bullet-size);justify-content:center;left:var(--_bullet-left,0);position:absolute;right:var(--_bullet-right,0);top:0;width:var(--tl-bullet-size)}[data-mantine-color-scheme=light] .m-8affcee1{--_bullet-border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-8affcee1{--_bullet-border-color:var(--mantine-color-dark-4)}.m-43657ece[data-align=left] .m-8affcee1{--_bullet-left:calc(var(--tl-bullet-size)/2*-1 + var(--tl-line-width)/2*-1);--_bullet-right:auto}.m-43657ece[data-align=right] .m-8affcee1,[dir=rtl] .m-43657ece[data-align=left] .m-8affcee1{--_bullet-left:auto;--_bullet-right:calc(var(--tl-bullet-size)/2*-1 + var(--tl-line-width)/2*-1)}[dir=rtl] .m-43657ece[data-align=right] .m-8affcee1{--_bullet-left:calc(var(--tl-bullet-size)/2*-1 + var(--tl-line-width)/2*-1);--_bullet-right:auto}.m-8affcee1[data-with-child]{--_bullet-border-width:var(--tl-line-width)}[data-mantine-color-scheme=light] .m-8affcee1[data-with-child]{--_bullet-bg-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-8affcee1[data-with-child]{--_bullet-bg-color:var(--mantine-color-dark-4)}.m-8affcee1[data-active]{--_bullet-border-color:var(--tli-color,var(--tl-color));--_bullet-bg-color:var(--mantine-color-white);--_bullet-color:var(--mantine-color-white)}.m-8affcee1[data-active][data-with-child]{--_bullet-bg-color:var(--tli-color,var(--tl-color));--_bullet-color:var(--mantine-color-white)}.m-540e8f41{padding-left:var(--_body-pl,0);padding-right:var(--_body-pr,0);text-align:var(--_body-ta)}.m-43657ece[data-align=left] .m-540e8f41{--_body-pl:var(--offset);--_body-ta:left}[dir=rtl] .m-43657ece[data-align=left] .m-540e8f41{--_body-pl:0;--_body-pr:var(--offset);--_body-ta:right}.m-43657ece[data-align=right] .m-540e8f41{--_body-pr:var(--offset);--_body-ta:right}[dir=rtl] .m-43657ece[data-align=right] .m-540e8f41{--_body-pl:var(--offset);--_body-pr:0;--_body-ta:left}.m-8a5d1357{font-family:var(--mantine-font-family-headings);font-size:var(--title-fz);font-weight:var(--title-fw);line-height:var(--title-lh);margin:0}.m-d6493fad h1,.m-d6493fad h2,.m-d6493fad h3,.m-d6493fad h4,.m-d6493fad h5,.m-d6493fad h6{margin-bottom:var(--mantine-spacing-xs);margin-top:calc(var(--mantine-spacing-xl)*1.55)}.m-d6493fad h1{font-size:var(--mantine-h1-font-size);font-weight:var(--mantine-h1-font-weight);line-height:var(--mantine-h1-line-height)}.m-d6493fad h2{font-size:var(--mantine-h2-font-size);font-weight:var(--mantine-h2-font-weight);line-height:var(--mantine-h2-line-height)}.m-d6493fad h3{font-size:var(--mantine-h3-font-size);font-weight:var(--mantine-h3-font-weight);line-height:var(--mantine-h3-line-height)}.m-d6493fad h4{font-size:var(--mantine-h4-font-size);font-weight:var(--mantine-h4-font-weight);line-height:var(--mantine-h4-line-height)}.m-d6493fad h5{font-size:var(--mantine-h5-font-size);font-weight:var(--mantine-h5-font-weight);line-height:var(--mantine-h5-line-height)}.m-d6493fad h6{font-size:var(--mantine-h6-font-size);font-weight:var(--mantine-h6-font-weight);line-height:var(--mantine-h6-line-height)}.m-d6493fad img{margin-bottom:var(--mantine-spacing-xs);max-width:100%}.m-d6493fad p{margin-bottom:var(--mantine-spacing-lg);margin-top:0}[data-mantine-color-scheme=light] .m-d6493fad mark{background-color:var(--mantine-color-yellow-2);color:inherit}[data-mantine-color-scheme=dark] .m-d6493fad mark{background-color:var(--mantine-color-yellow-5);color:var(--mantine-color-black)}.m-d6493fad a{color:var(--mantine-color-anchor);text-decoration:none}@media (hover:hover){.m-d6493fad a:hover{text-decoration:underline}}@media (hover:none){.m-d6493fad a:active{text-decoration:underline}}.m-d6493fad hr{border:0;border-top:calc(.0625rem*var(--mantine-scale)) solid;margin-bottom:var(--mantine-spacing-md);margin-top:var(--mantine-spacing-md)}[data-mantine-color-scheme=light] .m-d6493fad hr{border-color:var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m-d6493fad hr{border-color:var(--mantine-color-dark-3)}.m-d6493fad pre{border-radius:var(--mantine-radius-sm);font-family:var(--mantine-font-family-monospace);font-size:var(--mantine-font-size-xs);line-height:var(--mantine-line-height);margin:0;margin-bottom:var(--mantine-spacing-md);margin-top:var(--mantine-spacing-md);overflow-x:auto;padding:var(--mantine-spacing-xs)}[data-mantine-color-scheme=light] .m-d6493fad pre{background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-d6493fad pre{background-color:var(--mantine-color-dark-8)}.m-d6493fad pre code{background-color:transparent;border:0;border-radius:0;color:inherit;padding:0}.m-d6493fad kbd{--kbd-fz:calc(.75rem*var(--mantine-scale));--kbd-padding:calc(.1875rem*var(--mantine-scale)) calc(.3125rem*var(--mantine-scale));background-color:var(--_kbd-bg);border:calc(.0625rem*var(--mantine-scale)) solid var(--_kbd-border-color);border-bottom-width:calc(.1875rem*var(--mantine-scale));border-radius:var(--mantine-radius-sm);color:var(--_kbd-color);font-family:var(--mantine-font-family-monospace);font-size:var(--kbd-fz);font-weight:700;line-height:var(--mantine-line-height);padding:var(--kbd-padding)}[data-mantine-color-scheme=light] .m-d6493fad kbd{--_kbd-border-color:var(--mantine-color-gray-3);--_kbd-color:var(--mantine-color-gray-7);--_kbd-bg:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-d6493fad kbd{--_kbd-border-color:var(--mantine-color-dark-3);--_kbd-color:var(--mantine-color-dark-0);--_kbd-bg:var(--mantine-color-dark-5)}.m-d6493fad code{border-radius:var(--mantine-radius-sm);font-family:var(--mantine-font-family-monospace);font-size:var(--mantine-font-size-xs);line-height:var(--mantine-line-height);padding:calc(.0625rem*var(--mantine-scale)) calc(.3125rem*var(--mantine-scale))}[data-mantine-color-scheme=light] .m-d6493fad code{background-color:var(--mantine-color-gray-0);color:var(--mantine-color-black)}[data-mantine-color-scheme=dark] .m-d6493fad code{background-color:var(--mantine-color-dark-5);color:var(--mantine-color-white)}.m-d6493fad,.m-d6493fad ol,.m-d6493fad ul{margin-bottom:var(--mantine-spacing-md);padding-left:calc(2.375rem*var(--mantine-scale))}.m-d6493fad li,.m-d6493fad ol li,.m-d6493fad ul li{margin-bottom:var(--mantine-spacing-xs)}.m-d6493fad table{border-collapse:collapse;caption-side:bottom;margin-bottom:var(--mantine-spacing-md);width:100%}.m-d6493fad table caption{color:var(--mantine-color-gray-6);font-size:var(--mantine-font-size-sm);margin-top:var(--mantine-spacing-xs)}.m-d6493fad table th{color:var(--mantine-color-gray-7);font-size:var(--mantine-font-size-sm);font-weight:700;padding:var(--mantine-spacing-xs) var(--mantine-spacing-sm);text-align:left}.m-d6493fad table thead th{border-bottom:calc(.0625rem*var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3)}.m-d6493fad table tfoot th{border-top:calc(.0625rem*var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3)}.m-d6493fad table td{border-bottom:calc(.0625rem*var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3);font-size:var(--mantine-font-size-sm);padding:var(--mantine-spacing-xs) var(--mantine-spacing-sm)}.m-d6493fad table tr:last-of-type td{border-bottom:0}.m-d6493fad blockquote{border-radius:var(--mantine-radius-sm);font-size:var(--mantine-font-size-lg);line-height:var(--mantine-line-height);margin:var(--mantine-spacing-md) 0;padding:var(--mantine-spacing-md) var(--mantine-spacing-lg)}[data-mantine-color-scheme=light] .m-d6493fad blockquote{background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m-d6493fad blockquote{background-color:var(--mantine-color-dark-8)}._nav_mbz2l_1{height:64px;margin-top:20px}@media (max-width: 900px):{._nav_mbz2l_1{max-width:100%;min-width:100%;width:100%}}._nav_mbz2l_1{gap:2rem;align-items:"center"}._wrapper_mbz2l_20{max-width:900px;border-radius:8px;margin:10px auto 0}._maincontainer_mbz2l_31{display:flex;align-items:center;justify-content:space-between;flex-direction:row}@media (max-width: 500px){._network_mbz2l_42{visibility:hidden}}._buttonContainer_mbz2l_49{width:30px;height:30px;padding:2px;border-radius:4px,}._container_mbz2l_59{padding-left:20px;padding-right:20px;display:flex;align-items:center;justify-content:center;flex-direction:row}._mode_mbz2l_68{display:"flex";align-items:"center";justify-content:"center";flex-direction:"row"}._root_mbz2l_78{position:"relative"}._icon_mbz2l_85{pointer-events:"none";position:"absolute";z-index:1;top:3}._iconLight_mbz2l_92{left:4}._iconDark_mbz2l_97{right:4}._homeContainer_c8z77_47{max-width:500px;margin:0 auto}._avatar_c8z77_55{height:200px;width:200px}._avatarContainer_c8z77_62{display:flex;align-items:center;justify-content:center;flex-direction:row}._safe_c8z77_70{width:130px;margin:20px}._safeContainer_c8z77_77{display:flex;align-items:center;justify-content:center;flex-direction:column}._formContainer_c8z77_85{border-radius:12px;border:0px solid #4a4a4a;padding:80px}._heading_c8z77_92{font-size:43px;background:#00ff00;background:-webkit-linear-gradient(to left,#6fa56f 0%,#00ffff 100%);background:-moz-linear-gradient(to left,#6b9c6b 0%,#00ffff 100%);background:linear-gradient(to left,#00ff00 0%,#00ffff 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent;text-align:center;font-weight:700;margin-bottom:0}._actions_c8z77_6{margin-top:20px;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:20px;margin-bottom:20px}._links_c8z77_115{margin-top:0;font-size:35px;text-align:center;font-weight:700;color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] ._links_c8z77_115{color:var(--mantine-color-white-2)}._subHeading_c8z77_123{padding-top:15px;font-size:16px;text-align:center}._inputContainer_c8z77_129{display:flex;flex-direction:column;gap:10px;margin-bottom:20px}._selectGroup_c8z77_140{display:flex;align-items:center;justify-content:center}._btn_c8z77_146{background-image:linear-gradient(to right,#1d976c 0%,#93f9b9 51%,#1d976c 100%);transition:.5s;background-size:200% auto;color:#fff}._btn_c8z77_146:hover{background-position:right center;color:#fff;text-decoration:none}._helperText_c8z77_164{font-size:16px}._mode_c8z77_168{padding-left:20px;display:"flex";align-items:"center";justify-content:"center";flex-direction:"row"}._successContainer_c8z77_178{width:600px;margin:80px auto 0;border-radius:12px;border:0px solid #4a4a4a;background-color:#fff;box-shadow:0 1px 2px #1018280d}._network_c8z77_188{width:40%;height:50px;margin-left:5px}._copyContainer_c8z77_197{display:flex;align-items:center;gap:20px}._goBack_c8z77_203{margin-top:20px}._input_c8z77_129{width:100%;cursor:pointer}@media screen and (max-width: 600px){._successContainer_c8z77_178{width:100%}._copyContainer_c8z77_197{flex-direction:column}._input_c8z77_129{width:100%;cursor:pointer}._btn_c8z77_146{width:100%}}._homeContainer_yxegy_3{max-width:550px;margin:80px auto 0;border-radius:4px;border:1px solid #4a4a4a;background-color:#fff d;border:0px solid #4a4a4a}._formContainer_yxegy_15{padding:20px;display:flex;align-items:center;justify-content:center;flex-direction:column}._claimContainer_yxegy_23{padding-block:60px;border-radius:12px;display:flex;align-items:center;justify-content:center;flex-direction:column;padding-left:20px;padding-right:20px}._links_yxegy_35{margin-top:0;font-size:35px;text-align:center;font-weight:700;color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] ._links_yxegy_35{color:var(--mantine-color-white-2)}._claimHeading_yxegy_43{margin-bottom:0;text-align:center;background:#00FF00;font-size:35px;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._claimInner_yxegy_56{display:flex;align-items:center;margin-top:0;margin-bottom:0;text-align:center;justify-content:center;background:#00FF00;column-gap:20px;font-size:45px;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._heading_yxegy_73{text-align:center;background:#00FF00;font-size:25px;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._subHeading_yxegy_84{font-size:16px;font-weight:600;text-align:center}._footerHeading_yxegy_90{font-size:14px;text-align:center}._loader_yxegy_95{font-size:16px;text-align:center;font-weight:600}._btn_yxegy_101{background-image:linear-gradient(to right,#1d976c 0%,#93f9b9 51%,#1d976c 100%);transition:.5s;background-size:200% auto;color:#fff}._btn_yxegy_101:hover{background-position:right center;color:#fff;text-decoration:none}._input_yxegy_115{width:100%;cursor:pointer}._inputContainer_yxegy_120{justify-content:center;gap:20px;display:flex;flex-direction:column;margin-bottom:20px}._accountInputContainer_yxegy_130{display:flex;flex-direction:column}._accountContainer_1tcas_3{max-width:500px;margin:80px auto 0;border-radius:12px;border:0px solid #4a4a4a;background-color:#fff d}._formContainer_1tcas_15{padding:20px;display:flex;align-items:center;justify-content:center;flex-direction:column}._avatarContainer_1tcas_24{display:flex;align-items:center;justify-content:center;flex-direction:column}._balance_1tcas_32{font-size:30px;font-weight:700}._avatar_1tcas_24{height:60px;width:60px;margin-top:20px;margin-bottom:20px;border-radius:50%}._heading_1tcas_45{text-align:center;background:#00FF00;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._btn_1tcas_56{background-image:linear-gradient(to right,#1d976c 0%,#93f9b9 51%,#1d976c 100%);transition:.5s;background-size:200% auto;color:#fff}._btn_1tcas_56:hover{background-position:right center;color:#fff;text-decoration:none}._actionsContainer_1tcas_71{display:flex;align-items:center;justify-content:center;flex-direction:column}._subHeading_1tcas_79{padding-top:15px;font-size:16px;font-weight:600;text-align:center}._footerHeading_1tcas_86{font-size:14px;text-align:center}._balanceContainer_1tcas_91{display:flex;flex-direction:row;align-items:center;justify-content:center;gap:5px}._actions_1tcas_71{margin-top:20px;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:20px;margin-bottom:20px}._inputContainer_1tcas_109{justify-content:center;gap:20px;display:flex;flex-direction:column;margin-bottom:20px}._accountInputContainer_1tcas_119{display:flex;flex-direction:column} diff --git a/assets/index-c08d793e.css b/assets/index-c08d793e.css new file mode 100644 index 00000000..00f997ef --- /dev/null +++ b/assets/index-c08d793e.css @@ -0,0 +1 @@ +*,*:before,*:after{box-sizing:border-box}input,button,textarea,select{font:inherit}button,select{text-transform:none}body{margin:0;font-family:var(--mantine-font-family);font-size:var(--mantine-font-size-md);line-height:var(--mantine-line-height);background-color:var(--mantine-color-body);color:var(--mantine-color-text);-webkit-font-smoothing:var(--mantine-webkit-font-smoothing);-moz-osx-font-smoothing:var(--mantine-moz-font-smoothing)}@media screen and (max-device-width: 31.25em){body{-webkit-text-size-adjust:100%}}@media (prefers-reduced-motion: reduce){[data-respect-reduced-motion] [data-reduce-motion]{transition:none;animation:none}}[data-mantine-color-scheme=light] .mantine-light-hidden,[data-mantine-color-scheme=dark] .mantine-dark-hidden{display:none}.mantine-focus-auto:focus-visible{outline:2px solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem * var(--mantine-scale))}.mantine-focus-always:focus{outline:2px solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem * var(--mantine-scale))}.mantine-focus-never:focus{outline:none}.mantine-active:active{transform:translateY(calc(.0625rem * var(--mantine-scale)))}:where([dir=rtl]) .mantine-rotate-rtl{transform:rotate(180deg)}:root{color-scheme:var(--mantine-color-scheme);--mantine-z-index-app: 100;--mantine-z-index-modal: 200;--mantine-z-index-popover: 300;--mantine-z-index-overlay: 400;--mantine-z-index-max: 9999;--mantine-scale: 1;--mantine-cursor-type: default;--mantine-webkit-font-smoothing: antialiased;--mantine-color-scheme: light dark;--mantine-moz-font-smoothing: grayscale;--mantine-color-white: #fff;--mantine-color-black: #000;--mantine-line-height: 1.55;--mantine-font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji;--mantine-font-family-monospace: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;--mantine-font-family-headings: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji;--mantine-heading-font-weight: 700;--mantine-radius-default: calc(.25rem * var(--mantine-scale));--mantine-primary-color-0: var(--mantine-color-blue-0);--mantine-primary-color-1: var(--mantine-color-blue-1);--mantine-primary-color-2: var(--mantine-color-blue-2);--mantine-primary-color-3: var(--mantine-color-blue-3);--mantine-primary-color-4: var(--mantine-color-blue-4);--mantine-primary-color-5: var(--mantine-color-blue-5);--mantine-primary-color-6: var(--mantine-color-blue-6);--mantine-primary-color-7: var(--mantine-color-blue-7);--mantine-primary-color-8: var(--mantine-color-blue-8);--mantine-primary-color-9: var(--mantine-color-blue-9);--mantine-primary-color-filled: var(--mantine-color-blue-filled);--mantine-primary-color-filled-hover: var(--mantine-color-blue-filled-hover);--mantine-primary-color-light: var(--mantine-color-blue-light);--mantine-primary-color-light-hover: var(--mantine-color-blue-light-hover);--mantine-primary-color-light-color: var(--mantine-color-blue-light-color);--mantine-breakpoint-xs: 36em;--mantine-breakpoint-sm: 48em;--mantine-breakpoint-md: 62em;--mantine-breakpoint-lg: 75em;--mantine-breakpoint-xl: 88em;--mantine-spacing-xs: calc(.625rem * var(--mantine-scale));--mantine-spacing-sm: calc(.75rem * var(--mantine-scale));--mantine-spacing-md: calc(1rem * var(--mantine-scale));--mantine-spacing-lg: calc(1.25rem * var(--mantine-scale));--mantine-spacing-xl: calc(2rem * var(--mantine-scale));--mantine-font-size-xs: calc(.75rem * var(--mantine-scale));--mantine-font-size-sm: calc(.875rem * var(--mantine-scale));--mantine-font-size-md: calc(1rem * var(--mantine-scale));--mantine-font-size-lg: calc(1.125rem * var(--mantine-scale));--mantine-font-size-xl: calc(1.25rem * var(--mantine-scale));--mantine-line-height-xs: 1.4;--mantine-line-height-sm: 1.45;--mantine-line-height-md: 1.55;--mantine-line-height-lg: 1.6;--mantine-line-height-xl: 1.65;--mantine-shadow-xs: 0 calc(.0625rem * var(--mantine-scale)) calc(.1875rem * var(--mantine-scale)) rgba(0, 0, 0, .05), 0 calc(.0625rem * var(--mantine-scale)) calc(.125rem * var(--mantine-scale)) rgba(0, 0, 0, .1);--mantine-shadow-sm: 0 calc(.0625rem * var(--mantine-scale)) calc(.1875rem * var(--mantine-scale)) rgba(0, 0, 0, .05), rgba(0, 0, 0, .05) 0 calc(.625rem * var(--mantine-scale)) calc(.9375rem * var(--mantine-scale)) calc(-.3125rem * var(--mantine-scale)), rgba(0, 0, 0, .04) 0 calc(.4375rem * var(--mantine-scale)) calc(.4375rem * var(--mantine-scale)) calc(-.3125rem * var(--mantine-scale));--mantine-shadow-md: 0 calc(.0625rem * var(--mantine-scale)) calc(.1875rem * var(--mantine-scale)) rgba(0, 0, 0, .05), rgba(0, 0, 0, .05) 0 calc(1.25rem * var(--mantine-scale)) calc(1.5625rem * var(--mantine-scale)) calc(-.3125rem * var(--mantine-scale)), rgba(0, 0, 0, .04) 0 calc(.625rem * var(--mantine-scale)) calc(.625rem * var(--mantine-scale)) calc(-.3125rem * var(--mantine-scale));--mantine-shadow-lg: 0 calc(.0625rem * var(--mantine-scale)) calc(.1875rem * var(--mantine-scale)) rgba(0, 0, 0, .05), rgba(0, 0, 0, .05) 0 calc(1.75rem * var(--mantine-scale)) calc(1.4375rem * var(--mantine-scale)) calc(-.4375rem * var(--mantine-scale)), rgba(0, 0, 0, .04) 0 calc(.75rem * var(--mantine-scale)) calc(.75rem * var(--mantine-scale)) calc(-.4375rem * var(--mantine-scale));--mantine-shadow-xl: 0 calc(.0625rem * var(--mantine-scale)) calc(.1875rem * var(--mantine-scale)) rgba(0, 0, 0, .05), rgba(0, 0, 0, .05) 0 calc(2.25rem * var(--mantine-scale)) calc(1.75rem * var(--mantine-scale)) calc(-.4375rem * var(--mantine-scale)), rgba(0, 0, 0, .04) 0 calc(1.0625rem * var(--mantine-scale)) calc(1.0625rem * var(--mantine-scale)) calc(-.4375rem * var(--mantine-scale));--mantine-radius-xs: calc(.125rem * var(--mantine-scale));--mantine-radius-sm: calc(.25rem * var(--mantine-scale));--mantine-radius-md: calc(.5rem * var(--mantine-scale));--mantine-radius-lg: calc(1rem * var(--mantine-scale));--mantine-radius-xl: calc(2rem * var(--mantine-scale));--mantine-color-dark-0: #c9c9c9;--mantine-color-dark-1: #b8b8b8;--mantine-color-dark-2: #828282;--mantine-color-dark-3: #696969;--mantine-color-dark-4: #424242;--mantine-color-dark-5: #3b3b3b;--mantine-color-dark-6: #2e2e2e;--mantine-color-dark-7: #242424;--mantine-color-dark-8: #1f1f1f;--mantine-color-dark-9: #141414;--mantine-color-gray-0: #f8f9fa;--mantine-color-gray-1: #f1f3f5;--mantine-color-gray-2: #e9ecef;--mantine-color-gray-3: #dee2e6;--mantine-color-gray-4: #ced4da;--mantine-color-gray-5: #adb5bd;--mantine-color-gray-6: #868e96;--mantine-color-gray-7: #495057;--mantine-color-gray-8: #343a40;--mantine-color-gray-9: #212529;--mantine-color-red-0: #fff5f5;--mantine-color-red-1: #ffe3e3;--mantine-color-red-2: #ffc9c9;--mantine-color-red-3: #ffa8a8;--mantine-color-red-4: #ff8787;--mantine-color-red-5: #ff6b6b;--mantine-color-red-6: #fa5252;--mantine-color-red-7: #f03e3e;--mantine-color-red-8: #e03131;--mantine-color-red-9: #c92a2a;--mantine-color-pink-0: #fff0f6;--mantine-color-pink-1: #ffdeeb;--mantine-color-pink-2: #fcc2d7;--mantine-color-pink-3: #faa2c1;--mantine-color-pink-4: #f783ac;--mantine-color-pink-5: #f06595;--mantine-color-pink-6: #e64980;--mantine-color-pink-7: #d6336c;--mantine-color-pink-8: #c2255c;--mantine-color-pink-9: #a61e4d;--mantine-color-grape-0: #f8f0fc;--mantine-color-grape-1: #f3d9fa;--mantine-color-grape-2: #eebefa;--mantine-color-grape-3: #e599f7;--mantine-color-grape-4: #da77f2;--mantine-color-grape-5: #cc5de8;--mantine-color-grape-6: #be4bdb;--mantine-color-grape-7: #ae3ec9;--mantine-color-grape-8: #9c36b5;--mantine-color-grape-9: #862e9c;--mantine-color-violet-0: #f3f0ff;--mantine-color-violet-1: #e5dbff;--mantine-color-violet-2: #d0bfff;--mantine-color-violet-3: #b197fc;--mantine-color-violet-4: #9775fa;--mantine-color-violet-5: #845ef7;--mantine-color-violet-6: #7950f2;--mantine-color-violet-7: #7048e8;--mantine-color-violet-8: #6741d9;--mantine-color-violet-9: #5f3dc4;--mantine-color-indigo-0: #edf2ff;--mantine-color-indigo-1: #dbe4ff;--mantine-color-indigo-2: #bac8ff;--mantine-color-indigo-3: #91a7ff;--mantine-color-indigo-4: #748ffc;--mantine-color-indigo-5: #5c7cfa;--mantine-color-indigo-6: #4c6ef5;--mantine-color-indigo-7: #4263eb;--mantine-color-indigo-8: #3b5bdb;--mantine-color-indigo-9: #364fc7;--mantine-color-blue-0: #e7f5ff;--mantine-color-blue-1: #d0ebff;--mantine-color-blue-2: #a5d8ff;--mantine-color-blue-3: #74c0fc;--mantine-color-blue-4: #4dabf7;--mantine-color-blue-5: #339af0;--mantine-color-blue-6: #228be6;--mantine-color-blue-7: #1c7ed6;--mantine-color-blue-8: #1971c2;--mantine-color-blue-9: #1864ab;--mantine-color-cyan-0: #e3fafc;--mantine-color-cyan-1: #c5f6fa;--mantine-color-cyan-2: #99e9f2;--mantine-color-cyan-3: #66d9e8;--mantine-color-cyan-4: #3bc9db;--mantine-color-cyan-5: #22b8cf;--mantine-color-cyan-6: #15aabf;--mantine-color-cyan-7: #1098ad;--mantine-color-cyan-8: #0c8599;--mantine-color-cyan-9: #0b7285;--mantine-color-teal-0: #e6fcf5;--mantine-color-teal-1: #c3fae8;--mantine-color-teal-2: #96f2d7;--mantine-color-teal-3: #63e6be;--mantine-color-teal-4: #38d9a9;--mantine-color-teal-5: #20c997;--mantine-color-teal-6: #12b886;--mantine-color-teal-7: #0ca678;--mantine-color-teal-8: #099268;--mantine-color-teal-9: #087f5b;--mantine-color-green-0: #ebfbee;--mantine-color-green-1: #d3f9d8;--mantine-color-green-2: #b2f2bb;--mantine-color-green-3: #8ce99a;--mantine-color-green-4: #69db7c;--mantine-color-green-5: #51cf66;--mantine-color-green-6: #40c057;--mantine-color-green-7: #37b24d;--mantine-color-green-8: #2f9e44;--mantine-color-green-9: #2b8a3e;--mantine-color-lime-0: #f4fce3;--mantine-color-lime-1: #e9fac8;--mantine-color-lime-2: #d8f5a2;--mantine-color-lime-3: #c0eb75;--mantine-color-lime-4: #a9e34b;--mantine-color-lime-5: #94d82d;--mantine-color-lime-6: #82c91e;--mantine-color-lime-7: #74b816;--mantine-color-lime-8: #66a80f;--mantine-color-lime-9: #5c940d;--mantine-color-yellow-0: #fff9db;--mantine-color-yellow-1: #fff3bf;--mantine-color-yellow-2: #ffec99;--mantine-color-yellow-3: #ffe066;--mantine-color-yellow-4: #ffd43b;--mantine-color-yellow-5: #fcc419;--mantine-color-yellow-6: #fab005;--mantine-color-yellow-7: #f59f00;--mantine-color-yellow-8: #f08c00;--mantine-color-yellow-9: #e67700;--mantine-color-orange-0: #fff4e6;--mantine-color-orange-1: #ffe8cc;--mantine-color-orange-2: #ffd8a8;--mantine-color-orange-3: #ffc078;--mantine-color-orange-4: #ffa94d;--mantine-color-orange-5: #ff922b;--mantine-color-orange-6: #fd7e14;--mantine-color-orange-7: #f76707;--mantine-color-orange-8: #e8590c;--mantine-color-orange-9: #d9480f;--mantine-h1-font-size: calc(2.125rem * var(--mantine-scale));--mantine-h1-line-height: 1.3;--mantine-h1-font-weight: 700;--mantine-h2-font-size: calc(1.625rem * var(--mantine-scale));--mantine-h2-line-height: 1.35;--mantine-h2-font-weight: 700;--mantine-h3-font-size: calc(1.375rem * var(--mantine-scale));--mantine-h3-line-height: 1.4;--mantine-h3-font-weight: 700;--mantine-h4-font-size: calc(1.125rem * var(--mantine-scale));--mantine-h4-line-height: 1.45;--mantine-h4-font-weight: 700;--mantine-h5-font-size: calc(1rem * var(--mantine-scale));--mantine-h5-line-height: 1.5;--mantine-h5-font-weight: 700;--mantine-h6-font-size: calc(.875rem * var(--mantine-scale));--mantine-h6-line-height: 1.5;--mantine-h6-font-weight: 700}:root[data-mantine-color-scheme=dark]{--mantine-color-scheme: dark;--mantine-primary-color-contrast: var(--mantine-color-white);--mantine-color-bright: var(--mantine-color-white);--mantine-color-text: var(--mantine-color-dark-0);--mantine-color-body: var(--mantine-color-dark-7);--mantine-color-error: var(--mantine-color-red-8);--mantine-color-placeholder: var(--mantine-color-dark-3);--mantine-color-anchor: var(--mantine-color-blue-4);--mantine-color-default: var(--mantine-color-dark-6);--mantine-color-default-hover: var(--mantine-color-dark-5);--mantine-color-default-color: var(--mantine-color-white);--mantine-color-default-border: var(--mantine-color-dark-4);--mantine-color-dimmed: var(--mantine-color-dark-2);--mantine-color-dark-text: var(--mantine-color-dark-4);--mantine-color-dark-filled: var(--mantine-color-dark-8);--mantine-color-dark-filled-hover: var(--mantine-color-dark-7);--mantine-color-dark-light: rgba(36, 36, 36, .15);--mantine-color-dark-light-hover: rgba(36, 36, 36, .2);--mantine-color-dark-light-color: var(--mantine-color-dark-3);--mantine-color-dark-outline: var(--mantine-color-dark-4);--mantine-color-dark-outline-hover: rgba(36, 36, 36, .05);--mantine-color-gray-text: var(--mantine-color-gray-4);--mantine-color-gray-filled: var(--mantine-color-gray-8);--mantine-color-gray-filled-hover: var(--mantine-color-gray-9);--mantine-color-gray-light: rgba(134, 142, 150, .15);--mantine-color-gray-light-hover: rgba(134, 142, 150, .2);--mantine-color-gray-light-color: var(--mantine-color-gray-3);--mantine-color-gray-outline: var(--mantine-color-gray-4);--mantine-color-gray-outline-hover: rgba(206, 212, 218, .05);--mantine-color-red-text: var(--mantine-color-red-4);--mantine-color-red-filled: var(--mantine-color-red-8);--mantine-color-red-filled-hover: var(--mantine-color-red-9);--mantine-color-red-light: rgba(250, 82, 82, .15);--mantine-color-red-light-hover: rgba(250, 82, 82, .2);--mantine-color-red-light-color: var(--mantine-color-red-3);--mantine-color-red-outline: var(--mantine-color-red-4);--mantine-color-red-outline-hover: rgba(255, 135, 135, .05);--mantine-color-pink-text: var(--mantine-color-pink-4);--mantine-color-pink-filled: var(--mantine-color-pink-8);--mantine-color-pink-filled-hover: var(--mantine-color-pink-9);--mantine-color-pink-light: rgba(230, 73, 128, .15);--mantine-color-pink-light-hover: rgba(230, 73, 128, .2);--mantine-color-pink-light-color: var(--mantine-color-pink-3);--mantine-color-pink-outline: var(--mantine-color-pink-4);--mantine-color-pink-outline-hover: rgba(247, 131, 172, .05);--mantine-color-grape-text: var(--mantine-color-grape-4);--mantine-color-grape-filled: var(--mantine-color-grape-8);--mantine-color-grape-filled-hover: var(--mantine-color-grape-9);--mantine-color-grape-light: rgba(190, 75, 219, .15);--mantine-color-grape-light-hover: rgba(190, 75, 219, .2);--mantine-color-grape-light-color: var(--mantine-color-grape-3);--mantine-color-grape-outline: var(--mantine-color-grape-4);--mantine-color-grape-outline-hover: rgba(218, 119, 242, .05);--mantine-color-violet-text: var(--mantine-color-violet-4);--mantine-color-violet-filled: var(--mantine-color-violet-8);--mantine-color-violet-filled-hover: var(--mantine-color-violet-9);--mantine-color-violet-light: rgba(121, 80, 242, .15);--mantine-color-violet-light-hover: rgba(121, 80, 242, .2);--mantine-color-violet-light-color: var(--mantine-color-violet-3);--mantine-color-violet-outline: var(--mantine-color-violet-4);--mantine-color-violet-outline-hover: rgba(151, 117, 250, .05);--mantine-color-indigo-text: var(--mantine-color-indigo-4);--mantine-color-indigo-filled: var(--mantine-color-indigo-8);--mantine-color-indigo-filled-hover: var(--mantine-color-indigo-9);--mantine-color-indigo-light: rgba(76, 110, 245, .15);--mantine-color-indigo-light-hover: rgba(76, 110, 245, .2);--mantine-color-indigo-light-color: var(--mantine-color-indigo-3);--mantine-color-indigo-outline: var(--mantine-color-indigo-4);--mantine-color-indigo-outline-hover: rgba(116, 143, 252, .05);--mantine-color-blue-text: var(--mantine-color-blue-4);--mantine-color-blue-filled: var(--mantine-color-blue-8);--mantine-color-blue-filled-hover: var(--mantine-color-blue-9);--mantine-color-blue-light: rgba(34, 139, 230, .15);--mantine-color-blue-light-hover: rgba(34, 139, 230, .2);--mantine-color-blue-light-color: var(--mantine-color-blue-3);--mantine-color-blue-outline: var(--mantine-color-blue-4);--mantine-color-blue-outline-hover: rgba(77, 171, 247, .05);--mantine-color-cyan-text: var(--mantine-color-cyan-4);--mantine-color-cyan-filled: var(--mantine-color-cyan-8);--mantine-color-cyan-filled-hover: var(--mantine-color-cyan-9);--mantine-color-cyan-light: rgba(21, 170, 191, .15);--mantine-color-cyan-light-hover: rgba(21, 170, 191, .2);--mantine-color-cyan-light-color: var(--mantine-color-cyan-3);--mantine-color-cyan-outline: var(--mantine-color-cyan-4);--mantine-color-cyan-outline-hover: rgba(59, 201, 219, .05);--mantine-color-teal-text: var(--mantine-color-teal-4);--mantine-color-teal-filled: var(--mantine-color-teal-8);--mantine-color-teal-filled-hover: var(--mantine-color-teal-9);--mantine-color-teal-light: rgba(18, 184, 134, .15);--mantine-color-teal-light-hover: rgba(18, 184, 134, .2);--mantine-color-teal-light-color: var(--mantine-color-teal-3);--mantine-color-teal-outline: var(--mantine-color-teal-4);--mantine-color-teal-outline-hover: rgba(56, 217, 169, .05);--mantine-color-green-text: var(--mantine-color-green-4);--mantine-color-green-filled: var(--mantine-color-green-8);--mantine-color-green-filled-hover: var(--mantine-color-green-9);--mantine-color-green-light: rgba(64, 192, 87, .15);--mantine-color-green-light-hover: rgba(64, 192, 87, .2);--mantine-color-green-light-color: var(--mantine-color-green-3);--mantine-color-green-outline: var(--mantine-color-green-4);--mantine-color-green-outline-hover: rgba(105, 219, 124, .05);--mantine-color-lime-text: var(--mantine-color-lime-4);--mantine-color-lime-filled: var(--mantine-color-lime-8);--mantine-color-lime-filled-hover: var(--mantine-color-lime-9);--mantine-color-lime-light: rgba(130, 201, 30, .15);--mantine-color-lime-light-hover: rgba(130, 201, 30, .2);--mantine-color-lime-light-color: var(--mantine-color-lime-3);--mantine-color-lime-outline: var(--mantine-color-lime-4);--mantine-color-lime-outline-hover: rgba(169, 227, 75, .05);--mantine-color-yellow-text: var(--mantine-color-yellow-4);--mantine-color-yellow-filled: var(--mantine-color-yellow-8);--mantine-color-yellow-filled-hover: var(--mantine-color-yellow-9);--mantine-color-yellow-light: rgba(250, 176, 5, .15);--mantine-color-yellow-light-hover: rgba(250, 176, 5, .2);--mantine-color-yellow-light-color: var(--mantine-color-yellow-3);--mantine-color-yellow-outline: var(--mantine-color-yellow-4);--mantine-color-yellow-outline-hover: rgba(255, 212, 59, .05);--mantine-color-orange-text: var(--mantine-color-orange-4);--mantine-color-orange-filled: var(--mantine-color-orange-8);--mantine-color-orange-filled-hover: var(--mantine-color-orange-9);--mantine-color-orange-light: rgba(253, 126, 20, .15);--mantine-color-orange-light-hover: rgba(253, 126, 20, .2);--mantine-color-orange-light-color: var(--mantine-color-orange-3);--mantine-color-orange-outline: var(--mantine-color-orange-4);--mantine-color-orange-outline-hover: rgba(255, 169, 77, .05)}:root[data-mantine-color-scheme=light]{--mantine-color-scheme: light;--mantine-color-bright: var(--mantine-color-black);--mantine-color-text: var(--mantine-color-black);--mantine-color-body: var(--mantine-color-white);--mantine-primary-color-contrast: var(--mantine-color-white);--mantine-color-error: var(--mantine-color-red-6);--mantine-color-placeholder: var(--mantine-color-gray-5);--mantine-color-anchor: var(--mantine-primary-color-filled);--mantine-color-default: var(--mantine-color-white);--mantine-color-default-hover: var(--mantine-color-gray-0);--mantine-color-default-color: var(--mantine-color-gray-9);--mantine-color-default-border: var(--mantine-color-gray-4);--mantine-color-dimmed: var(--mantine-color-gray-6);--mantine-color-dark-text: var(--mantine-color-dark-filled);--mantine-color-dark-filled: var(--mantine-color-dark-6);--mantine-color-dark-filled-hover: var(--mantine-color-dark-7);--mantine-color-dark-light: rgba(56, 56, 56, .1);--mantine-color-dark-light-hover: rgba(56, 56, 56, .12);--mantine-color-dark-light-color: var(--mantine-color-dark-6);--mantine-color-dark-outline: var(--mantine-color-dark-6);--mantine-color-dark-outline-hover: rgba(56, 56, 56, .05);--mantine-color-gray-text: var(--mantine-color-gray-filled);--mantine-color-gray-filled: var(--mantine-color-gray-6);--mantine-color-gray-filled-hover: var(--mantine-color-gray-7);--mantine-color-gray-light: rgba(134, 142, 150, .1);--mantine-color-gray-light-hover: rgba(134, 142, 150, .12);--mantine-color-gray-light-color: var(--mantine-color-gray-6);--mantine-color-gray-outline: var(--mantine-color-gray-6);--mantine-color-gray-outline-hover: rgba(134, 142, 150, .05);--mantine-color-red-text: var(--mantine-color-red-filled);--mantine-color-red-filled: var(--mantine-color-red-6);--mantine-color-red-filled-hover: var(--mantine-color-red-7);--mantine-color-red-light: rgba(250, 82, 82, .1);--mantine-color-red-light-hover: rgba(250, 82, 82, .12);--mantine-color-red-light-color: var(--mantine-color-red-6);--mantine-color-red-outline: var(--mantine-color-red-6);--mantine-color-red-outline-hover: rgba(250, 82, 82, .05);--mantine-color-pink-text: var(--mantine-color-pink-filled);--mantine-color-pink-filled: var(--mantine-color-pink-6);--mantine-color-pink-filled-hover: var(--mantine-color-pink-7);--mantine-color-pink-light: rgba(230, 73, 128, .1);--mantine-color-pink-light-hover: rgba(230, 73, 128, .12);--mantine-color-pink-light-color: var(--mantine-color-pink-6);--mantine-color-pink-outline: var(--mantine-color-pink-6);--mantine-color-pink-outline-hover: rgba(230, 73, 128, .05);--mantine-color-grape-text: var(--mantine-color-grape-filled);--mantine-color-grape-filled: var(--mantine-color-grape-6);--mantine-color-grape-filled-hover: var(--mantine-color-grape-7);--mantine-color-grape-light: rgba(190, 75, 219, .1);--mantine-color-grape-light-hover: rgba(190, 75, 219, .12);--mantine-color-grape-light-color: var(--mantine-color-grape-6);--mantine-color-grape-outline: var(--mantine-color-grape-6);--mantine-color-grape-outline-hover: rgba(190, 75, 219, .05);--mantine-color-violet-text: var(--mantine-color-violet-filled);--mantine-color-violet-filled: var(--mantine-color-violet-6);--mantine-color-violet-filled-hover: var(--mantine-color-violet-7);--mantine-color-violet-light: rgba(121, 80, 242, .1);--mantine-color-violet-light-hover: rgba(121, 80, 242, .12);--mantine-color-violet-light-color: var(--mantine-color-violet-6);--mantine-color-violet-outline: var(--mantine-color-violet-6);--mantine-color-violet-outline-hover: rgba(121, 80, 242, .05);--mantine-color-indigo-text: var(--mantine-color-indigo-filled);--mantine-color-indigo-filled: var(--mantine-color-indigo-6);--mantine-color-indigo-filled-hover: var(--mantine-color-indigo-7);--mantine-color-indigo-light: rgba(76, 110, 245, .1);--mantine-color-indigo-light-hover: rgba(76, 110, 245, .12);--mantine-color-indigo-light-color: var(--mantine-color-indigo-6);--mantine-color-indigo-outline: var(--mantine-color-indigo-6);--mantine-color-indigo-outline-hover: rgba(76, 110, 245, .05);--mantine-color-blue-text: var(--mantine-color-blue-filled);--mantine-color-blue-filled: var(--mantine-color-blue-6);--mantine-color-blue-filled-hover: var(--mantine-color-blue-7);--mantine-color-blue-light: rgba(34, 139, 230, .1);--mantine-color-blue-light-hover: rgba(34, 139, 230, .12);--mantine-color-blue-light-color: var(--mantine-color-blue-6);--mantine-color-blue-outline: var(--mantine-color-blue-6);--mantine-color-blue-outline-hover: rgba(34, 139, 230, .05);--mantine-color-cyan-text: var(--mantine-color-cyan-filled);--mantine-color-cyan-filled: var(--mantine-color-cyan-6);--mantine-color-cyan-filled-hover: var(--mantine-color-cyan-7);--mantine-color-cyan-light: rgba(21, 170, 191, .1);--mantine-color-cyan-light-hover: rgba(21, 170, 191, .12);--mantine-color-cyan-light-color: var(--mantine-color-cyan-6);--mantine-color-cyan-outline: var(--mantine-color-cyan-6);--mantine-color-cyan-outline-hover: rgba(21, 170, 191, .05);--mantine-color-teal-text: var(--mantine-color-teal-filled);--mantine-color-teal-filled: var(--mantine-color-teal-6);--mantine-color-teal-filled-hover: var(--mantine-color-teal-7);--mantine-color-teal-light: rgba(18, 184, 134, .1);--mantine-color-teal-light-hover: rgba(18, 184, 134, .12);--mantine-color-teal-light-color: var(--mantine-color-teal-6);--mantine-color-teal-outline: var(--mantine-color-teal-6);--mantine-color-teal-outline-hover: rgba(18, 184, 134, .05);--mantine-color-green-text: var(--mantine-color-green-filled);--mantine-color-green-filled: var(--mantine-color-green-6);--mantine-color-green-filled-hover: var(--mantine-color-green-7);--mantine-color-green-light: rgba(64, 192, 87, .1);--mantine-color-green-light-hover: rgba(64, 192, 87, .12);--mantine-color-green-light-color: var(--mantine-color-green-6);--mantine-color-green-outline: var(--mantine-color-green-6);--mantine-color-green-outline-hover: rgba(64, 192, 87, .05);--mantine-color-lime-text: var(--mantine-color-lime-filled);--mantine-color-lime-filled: var(--mantine-color-lime-6);--mantine-color-lime-filled-hover: var(--mantine-color-lime-7);--mantine-color-lime-light: rgba(130, 201, 30, .1);--mantine-color-lime-light-hover: rgba(130, 201, 30, .12);--mantine-color-lime-light-color: var(--mantine-color-lime-6);--mantine-color-lime-outline: var(--mantine-color-lime-6);--mantine-color-lime-outline-hover: rgba(130, 201, 30, .05);--mantine-color-yellow-text: var(--mantine-color-yellow-filled);--mantine-color-yellow-filled: var(--mantine-color-yellow-6);--mantine-color-yellow-filled-hover: var(--mantine-color-yellow-7);--mantine-color-yellow-light: rgba(250, 176, 5, .1);--mantine-color-yellow-light-hover: rgba(250, 176, 5, .12);--mantine-color-yellow-light-color: var(--mantine-color-yellow-6);--mantine-color-yellow-outline: var(--mantine-color-yellow-6);--mantine-color-yellow-outline-hover: rgba(250, 176, 5, .05);--mantine-color-orange-text: var(--mantine-color-orange-filled);--mantine-color-orange-filled: var(--mantine-color-orange-6);--mantine-color-orange-filled-hover: var(--mantine-color-orange-7);--mantine-color-orange-light: rgba(253, 126, 20, .1);--mantine-color-orange-light-hover: rgba(253, 126, 20, .12);--mantine-color-orange-light-color: var(--mantine-color-orange-6);--mantine-color-orange-outline: var(--mantine-color-orange-6);--mantine-color-orange-outline-hover: rgba(253, 126, 20, .05)}.m_d57069b5{--scrollarea-scrollbar-size: calc(.75rem * var(--mantine-scale));position:relative;overflow:hidden}.m_c0783ff9{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;width:100%;height:100%}.m_c0783ff9::-webkit-scrollbar{display:none}.m_c0783ff9:where([data-scrollbars=xy],[data-scrollbars=y]):where([data-offset-scrollbars=xy],[data-offset-scrollbars=y]){padding-inline-end:var(--scrollarea-scrollbar-size);padding-inline-start:unset}.m_c0783ff9:where([data-scrollbars=xy],[data-scrollbars=x]):where([data-offset-scrollbars=xy],[data-offset-scrollbars=x]){padding-bottom:var(--scrollarea-scrollbar-size)}.m_f8f631dd{min-width:100%;display:table}.m_c44ba933{-webkit-user-select:none;user-select:none;touch-action:none;box-sizing:border-box;transition:background-color .15s ease,opacity .15s ease;padding:calc(var(--scrollarea-scrollbar-size) / 5);display:flex;background-color:transparent;flex-direction:row}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_c44ba933:hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=light]) .m_c44ba933:hover>.m_d8b5e363{background-color:#00000080}:where([data-mantine-color-scheme=dark]) .m_c44ba933:hover{background-color:var(--mantine-color-dark-8)}:where([data-mantine-color-scheme=dark]) .m_c44ba933:hover>.m_d8b5e363{background-color:#ffffff80}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_c44ba933:active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=light]) .m_c44ba933:active>.m_d8b5e363{background-color:#00000080}:where([data-mantine-color-scheme=dark]) .m_c44ba933:active{background-color:var(--mantine-color-dark-8)}:where([data-mantine-color-scheme=dark]) .m_c44ba933:active>.m_d8b5e363{background-color:#ffffff80}}.m_c44ba933:where([data-hidden],[data-state=hidden]){display:none}.m_c44ba933:where([data-orientation=vertical]){width:var(--scrollarea-scrollbar-size);top:0;bottom:var(--sa-corner-width);inset-inline-end:0}.m_c44ba933:where([data-orientation=horizontal]){height:var(--scrollarea-scrollbar-size);flex-direction:column;bottom:0;inset-inline-start:0;inset-inline-end:var(--sa-corner-width)}.m_d8b5e363{flex:1;border-radius:var(--scrollarea-scrollbar-size);position:relative;transition:background-color .15s ease;overflow:hidden}.m_d8b5e363:before{content:'""';position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:100%;height:100%;min-width:calc(2.75rem * var(--mantine-scale));min-height:calc(2.75rem * var(--mantine-scale))}:where([data-mantine-color-scheme=light]) .m_d8b5e363{background-color:#0006}:where([data-mantine-color-scheme=dark]) .m_d8b5e363{background-color:#fff6}.m_21657268{position:absolute;opacity:0;transition:opacity .15s ease;display:block;inset-inline-end:0;bottom:0}:where([data-mantine-color-scheme=light]) .m_21657268{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_21657268{background-color:var(--mantine-color-dark-8)}.m_21657268:where([data-hovered]){opacity:1}.m_21657268:where([data-hidden]){display:none}.m_87cf2631{background-color:transparent;cursor:pointer;border:0;padding:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;font-size:var(--mantine-font-size-md);text-align:left;text-decoration:none;color:inherit;touch-action:manipulation;-webkit-tap-highlight-color:transparent}:where([dir=rtl]) .m_87cf2631{text-align:right}.m_515a97f8{border:0;clip:rect(0 0 0 0);height:calc(.0625rem * var(--mantine-scale));width:calc(.0625rem * var(--mantine-scale));margin:calc(-.0625rem * var(--mantine-scale));overflow:hidden;padding:0;position:absolute;white-space:nowrap}.m_1b7284a3{--paper-radius: var(--mantine-radius-default);outline:0;-webkit-tap-highlight-color:transparent;display:block;touch-action:manipulation;text-decoration:none;border-radius:var(--paper-radius);box-shadow:var(--paper-shadow);background-color:var(--mantine-color-body)}:where([data-mantine-color-scheme=light]) .m_1b7284a3:where([data-with-border]){border:1px solid var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_1b7284a3:where([data-with-border]){border:1px solid var(--mantine-color-dark-4)}.m_38a85659{position:absolute;border:1px solid var(--popover-border-color);padding:var(--mantine-spacing-sm) var(--mantine-spacing-md);box-shadow:var(--popover-shadow, none);border-radius:var(--popover-radius, var(--mantine-radius-default))}.m_38a85659:focus{outline:none}:where([data-mantine-color-scheme=light]) .m_38a85659{--popover-border-color: var(--mantine-color-gray-2);background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_38a85659{--popover-border-color: var(--mantine-color-dark-4);background-color:var(--mantine-color-dark-6)}.m_a31dc6c1{background-color:inherit;border:1px solid var(--popover-border-color);z-index:1}.m_5ae2e3c{--loader-size-xs: calc(1.125rem * var(--mantine-scale));--loader-size-sm: calc(1.375rem * var(--mantine-scale));--loader-size-md: calc(2.25rem * var(--mantine-scale));--loader-size-lg: calc(2.75rem * var(--mantine-scale));--loader-size-xl: calc(3.625rem * var(--mantine-scale));--loader-size: var(--loader-size-md);--loader-color: var(--mantine-primary-color-filled)}@keyframes m_5d2b3b9d{0%{transform:scale(.6);opacity:0}50%,to{transform:scale(1)}}.m_7a2bd4cd{position:relative;width:var(--loader-size);height:var(--loader-size);display:flex;gap:calc(var(--loader-size) / 5)}.m_870bb79{flex:1;background:var(--loader-color);animation:m_5d2b3b9d 1.2s cubic-bezier(0,.5,.5,1) infinite;border-radius:calc(.125rem * var(--mantine-scale))}.m_870bb79:nth-of-type(1){animation-delay:-.24s}.m_870bb79:nth-of-type(2){animation-delay:-.12s}.m_870bb79:nth-of-type(3){animation-delay:0}@keyframes m_aac34a1{0%,to{transform:scale(1);opacity:1}50%{transform:scale(.6);opacity:.5}}.m_4e3f22d7{display:flex;justify-content:center;align-items:center;gap:calc(var(--loader-size) / 10);position:relative;width:var(--loader-size);height:var(--loader-size)}.m_870c4af{width:calc(var(--loader-size) / 3 - var(--loader-size) / 15);height:calc(var(--loader-size) / 3 - var(--loader-size) / 15);border-radius:50%;background:var(--loader-color);animation:m_aac34a1 .8s infinite linear}.m_870c4af:nth-child(2){animation-delay:.4s}@keyframes m_f8e89c4b{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.m_b34414df{display:inline-block;width:var(--loader-size);height:var(--loader-size)}.m_b34414df:after{content:"";display:block;width:var(--loader-size);height:var(--loader-size);border-radius:calc(625rem * var(--mantine-scale));border-width:calc(var(--loader-size) / 8);border-style:solid;border-color:var(--loader-color) var(--loader-color) var(--loader-color) transparent;animation:m_f8e89c4b 1.2s linear infinite}.m_8d3f4000{--ai-size-xs: calc(1.125rem * var(--mantine-scale));--ai-size-sm: calc(1.375rem * var(--mantine-scale));--ai-size-md: calc(1.75rem * var(--mantine-scale));--ai-size-lg: calc(2.125rem * var(--mantine-scale));--ai-size-xl: calc(2.75rem * var(--mantine-scale));--ai-size-input-xs: calc(1.875rem * var(--mantine-scale));--ai-size-input-sm: calc(2.25rem * var(--mantine-scale));--ai-size-input-md: calc(2.625rem * var(--mantine-scale));--ai-size-input-lg: calc(3.125rem * var(--mantine-scale));--ai-size-input-xl: calc(3.75rem * var(--mantine-scale));--ai-size: var(--ai-size-md);--ai-color: var(--mantine-color-white);line-height:1;display:inline-flex;align-items:center;justify-content:center;position:relative;-webkit-user-select:none;user-select:none;overflow:hidden;width:var(--ai-size);height:var(--ai-size);min-width:var(--ai-size);min-height:var(--ai-size);border-radius:var(--ai-radius, var(--mantine-radius-default));background:var(--ai-bg, var(--mantine-primary-color-filled));color:var(--ai-color, var(--mantine-color-white));border:var(--ai-bd, calc(.0625rem * var(--mantine-scale)) solid transparent);cursor:pointer}@media (hover: hover){.m_8d3f4000:hover:where(:not([data-loading],:disabled,[data-disabled])){background-color:var(--ai-hover, var(--mantine-primary-color-filled-hover));color:var(--ai-hover-color, var(--ai-color))}}@media (hover: none){.m_8d3f4000:active:where(:not([data-loading],:disabled,[data-disabled])){background-color:var(--ai-hover, var(--mantine-primary-color-filled-hover));color:var(--ai-hover-color, var(--ai-color))}}.m_8d3f4000[data-loading]{cursor:not-allowed}.m_8d3f4000[data-loading] .m_8d3afb97{opacity:0;transform:translateY(100%)}.m_8d3f4000:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){cursor:not-allowed;border:calc(.0625rem * var(--mantine-scale)) solid transparent}:where([data-mantine-color-scheme=light]) .m_8d3f4000:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){background-color:var(--mantine-color-gray-1);color:var(--mantine-color-gray-5)}:where([data-mantine-color-scheme=dark]) .m_8d3f4000:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){background-color:var(--mantine-color-dark-6);color:var(--mantine-color-dark-3)}.m_8d3f4000:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])):active{transform:none}.m_302b9fb1{inset:calc(-.0625rem * var(--mantine-scale));position:absolute;border-radius:var(--ai-radius, var(--mantine-radius-default));display:flex;align-items:center;justify-content:center}:where([data-mantine-color-scheme=light]) .m_302b9fb1{background-color:#ffffff59}:where([data-mantine-color-scheme=dark]) .m_302b9fb1{background-color:#00000059}.m_1a0f1b21{--ai-border-width: calc(.0625rem * var(--mantine-scale));display:flex}.m_1a0f1b21 :where(*):focus{position:relative;z-index:1}.m_1a0f1b21[data-orientation=horizontal]{flex-direction:row}.m_1a0f1b21[data-orientation=horizontal] .m_8d3f4000:not(:only-child):first-child{border-end-end-radius:0;border-start-end-radius:0;border-inline-end-width:calc(var(--ai-border-width) / 2)}.m_1a0f1b21[data-orientation=horizontal] .m_8d3f4000:not(:only-child):last-child{border-end-start-radius:0;border-start-start-radius:0;border-inline-start-width:calc(var(--ai-border-width) / 2)}.m_1a0f1b21[data-orientation=horizontal] .m_8d3f4000:not(:only-child):not(:first-child):not(:last-child){border-radius:0;border-inline-width:calc(var(--ai-border-width) / 2)}.m_1a0f1b21[data-orientation=vertical]{flex-direction:column}.m_1a0f1b21[data-orientation=vertical] .m_8d3f4000:not(:only-child):first-child{border-end-start-radius:0;border-end-end-radius:0;border-bottom-width:calc(var(--ai-border-width) / 2)}.m_1a0f1b21[data-orientation=vertical] .m_8d3f4000:not(:only-child):last-child{border-start-start-radius:0;border-start-end-radius:0;border-top-width:calc(var(--ai-border-width) / 2)}.m_1a0f1b21[data-orientation=vertical] .m_8d3f4000:not(:only-child):not(:first-child):not(:last-child){border-radius:0;border-bottom-width:calc(var(--ai-border-width) / 2);border-top-width:calc(var(--ai-border-width) / 2)}.m_8d3afb97{display:flex;align-items:center;justify-content:center;transition:transform .15s ease,opacity .1s ease;width:100%;height:100%}.m_86a44da5{--cb-size-xs: calc(1.125rem * var(--mantine-scale));--cb-size-sm: calc(1.375rem * var(--mantine-scale));--cb-size-md: calc(1.75rem * var(--mantine-scale));--cb-size-lg: calc(2.125rem * var(--mantine-scale));--cb-size-xl: calc(2.75rem * var(--mantine-scale));--cb-size: var(--cb-size-md);--cb-icon-size: 70%;--cb-radius: var(--mantine-radius-default);line-height:1;display:inline-flex;align-items:center;justify-content:center;position:relative;-webkit-user-select:none;user-select:none;width:var(--cb-size);height:var(--cb-size);min-width:var(--cb-size);min-height:var(--cb-size);border-radius:var(--cb-radius)}:where([data-mantine-color-scheme=light]) .m_86a44da5{color:var(--mantine-color-gray-7)}:where([data-mantine-color-scheme=dark]) .m_86a44da5{color:var(--mantine-color-dark-1)}.m_86a44da5[data-disabled],.m_86a44da5:disabled{cursor:not-allowed;opacity:.6}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_220c80f2:not([data-disabled],:disabled):hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_220c80f2:not([data-disabled],:disabled):hover{background-color:var(--mantine-color-dark-6)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_220c80f2:not([data-disabled],:disabled):active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_220c80f2:not([data-disabled],:disabled):active{background-color:var(--mantine-color-dark-6)}}.m_4081bf90{display:flex;flex-direction:row;flex-wrap:var(--group-wrap, wrap);justify-content:var(--group-justify, flex-start);align-items:var(--group-align, center);gap:var(--group-gap, var(--mantine-spacing-md))}.m_4081bf90:where([data-grow])>*{flex-grow:1;max-width:var(--group-child-width)}.m_9814e45f{top:0;right:0;bottom:0;left:0;position:absolute;background:var(--overlay-bg, rgba(0, 0, 0, .6));backdrop-filter:var(--overlay-filter);-webkit-backdrop-filter:var(--overlay-filter);border-radius:var(--overlay-radius, 0);z-index:var(--overlay-z-index)}.m_9814e45f:where([data-fixed]){position:fixed}.m_9814e45f:where([data-center]){display:flex;align-items:center;justify-content:center}.m_615af6c9{line-height:1;padding:0;margin:0;font-weight:400;font-size:var(--mantine-font-size-md)}.m_b5489c3c{display:flex;justify-content:space-between;align-items:center;padding:var(--mb-padding, var(--mantine-spacing-md));padding-inline-end:calc(var(--mb-padding, var(--mantine-spacing-md)) - calc(.3125rem * var(--mantine-scale)));position:sticky;top:0;background-color:var(--mantine-color-body);z-index:1000;min-height:calc(3.75rem * var(--mantine-scale))}.m_60c222c7{position:fixed;width:100%;top:0;bottom:0;z-index:var(--mb-z-index);pointer-events:none}.m_fd1ab0aa{pointer-events:all;box-shadow:var(--mb-shadow, var(--mantine-shadow-xl))}.m_606cb269{margin-inline-start:auto}.m_5df29311{padding:var(--mb-padding, var(--mantine-spacing-md));padding-top:var(--mb-padding, var(--mantine-spacing-md))}.m_5df29311:where(:not(:only-child)){padding-top:0}.m_6c018570{position:relative;margin-top:var(--input-margin-top, 0rem);margin-bottom:var(--input-margin-bottom, 0rem);--input-height-xs: calc(1.875rem * var(--mantine-scale));--input-height-sm: calc(2.25rem * var(--mantine-scale));--input-height-md: calc(2.625rem * var(--mantine-scale));--input-height-lg: calc(3.125rem * var(--mantine-scale));--input-height-xl: calc(3.75rem * var(--mantine-scale));--input-padding-y-xs: calc(.3125rem * var(--mantine-scale));--input-padding-y-sm: calc(.375rem * var(--mantine-scale));--input-padding-y-md: calc(.5rem * var(--mantine-scale));--input-padding-y-lg: calc(.625rem * var(--mantine-scale));--input-padding-y-xl: calc(.8125rem * var(--mantine-scale));--input-height: var(--input-height-sm);--input-radius: var(--mantine-radius-default);--input-cursor: text;--input-text-align: left;--input-line-height: calc(var(--input-height) - calc(.125rem * var(--mantine-scale)));--input-padding: calc(var(--input-height) / 3);--input-padding-inline-start: var(--input-padding);--input-padding-inline-end: var(--input-padding);--input-placeholder-color: var(--mantine-color-placeholder);--input-color: var(--mantine-color-text);--input-left-section-size: var(--input-left-section-width, calc(var(--input-height) - calc(.125rem * var(--mantine-scale))));--input-right-section-size: var( --input-right-section-width, calc(var(--input-height) - calc(.125rem * var(--mantine-scale))) );--input-size: var(--input-height);--section-y: calc(.0625rem * var(--mantine-scale));--left-section-start: calc(.0625rem * var(--mantine-scale));--left-section-border-radius: var(--input-radius) 0 0 var(--input-radius);--right-section-end: calc(.0625rem * var(--mantine-scale));--right-section-border-radius: 0 var(--input-radius) var(--input-radius) 0}.m_6c018570[data-variant=unstyled]{--input-padding: 0;--input-padding-y: 0;--input-padding-inline-start: 0;--input-padding-inline-end: 0}.m_6c018570[data-pointer]{--input-cursor: pointer}.m_6c018570[data-multiline]{--input-padding-y-xs: calc(.28125rem * var(--mantine-scale));--input-padding-y-sm: calc(.34375rem * var(--mantine-scale));--input-padding-y-md: calc(.4375rem * var(--mantine-scale));--input-padding-y-lg: calc(.59375rem * var(--mantine-scale));--input-padding-y-xl: calc(.8125rem * var(--mantine-scale));--input-size: auto;--input-line-height: var(--mantine-line-height);--input-padding-y: var(--input-padding-y-sm)}.m_6c018570[data-with-left-section]{--input-padding-inline-start: var(--input-left-section-size)}.m_6c018570[data-with-right-section]{--input-padding-inline-end: var(--input-right-section-size)}[data-mantine-color-scheme=light] .m_6c018570{--input-disabled-bg: var(--mantine-color-gray-1);--input-disabled-color: var(--mantine-color-gray-6)}[data-mantine-color-scheme=light] .m_6c018570[data-variant=default]{--input-bd: var(--mantine-color-gray-4);--input-bg: var(--mantine-color-white);--input-bd-focus: var(--mantine-primary-color-filled)}[data-mantine-color-scheme=light] .m_6c018570[data-variant=filled]{--input-bd: transparent;--input-bg: var(--mantine-color-gray-1);--input-bd-focus: var(--mantine-primary-color-filled)}[data-mantine-color-scheme=light] .m_6c018570[data-variant=unstyled]{--input-bd: transparent;--input-bg: transparent;--input-bd-focus: transparent}[data-mantine-color-scheme=dark] .m_6c018570{--input-disabled-bg: var(--mantine-color-dark-6);--input-disabled-color: var(--mantine-color-dark-2)}[data-mantine-color-scheme=dark] .m_6c018570[data-variant=default]{--input-bd: var(--mantine-color-dark-4);--input-bg: var(--mantine-color-dark-6);--input-bd-focus: var(--mantine-primary-color-filled)}[data-mantine-color-scheme=dark] .m_6c018570[data-variant=filled]{--input-bd: transparent;--input-bg: var(--mantine-color-dark-5);--input-bd-focus: var(--mantine-primary-color-filled)}[data-mantine-color-scheme=dark] .m_6c018570[data-variant=unstyled]{--input-bd: transparent;--input-bg: transparent;--input-bd-focus: transparent}[data-mantine-color-scheme] .m_6c018570[data-error]:not([data-variant=unstyled]){--input-bd: var(--mantine-color-error)}[data-mantine-color-scheme] .m_6c018570[data-error]{--input-color: var(--mantine-color-error);--input-placeholder-color: var(--mantine-color-error);--input-section-color: var(--mantine-color-error)}:where([dir=rtl]) .m_6c018570{--input-text-align: right;--left-section-border-radius: 0 var(--input-radius) var(--input-radius) 0;--right-section-border-radius: var(--input-radius) 0 0 var(--input-radius)}.m_8fb7ebe7{-webkit-tap-highlight-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;resize:var(--input-resize, none);display:block;width:100%;transition:border-color .1s ease;text-align:var(--input-text-align);color:var(--input-color);border:1px solid var(--input-bd);background-color:var(--input-bg);font-family:var(--input-font-family, var(--mantine-font-family));height:var(--input-size);min-height:var(--input-height);line-height:var(--input-line-height);font-size:var(--input-fz, var(--input-fz, var(--mantine-font-size-sm)));border-radius:var(--input-radius);padding-inline-start:var(--input-padding-inline-start);padding-inline-end:var(--input-padding-inline-end);padding-top:var(--input-padding-y, 0rem);padding-bottom:var(--input-padding-y, 0rem);cursor:var(--input-cursor);overflow:var(--input-overflow)}.m_8fb7ebe7[data-no-overflow]{--input-overflow: hidden}.m_8fb7ebe7[data-monospace]{--input-font-family: var(--mantine-font-family-monospace);--input-fz: calc(var(--input-fz, var(--mantine-font-size-sm)) - calc(.125rem * var(--mantine-scale)))}.m_8fb7ebe7:focus,.m_8fb7ebe7:focus-within{outline:none;--input-bd: var(--input-bd-focus)}[data-error] .m_8fb7ebe7:focus,[data-error] .m_8fb7ebe7:focus-within{--input-bd: var(--mantine-color-error)}.m_8fb7ebe7::placeholder{color:var(--input-placeholder-color);opacity:1}.m_8fb7ebe7::-webkit-inner-spin-button,.m_8fb7ebe7::-webkit-outer-spin-button,.m_8fb7ebe7::-webkit-search-decoration,.m_8fb7ebe7::-webkit-search-cancel-button,.m_8fb7ebe7::-webkit-search-results-button,.m_8fb7ebe7::-webkit-search-results-decoration{-webkit-appearance:none;-moz-appearance:none;appearance:none}.m_8fb7ebe7[type=number]{-moz-appearance:textfield}.m_8fb7ebe7:disabled,.m_8fb7ebe7[data-disabled]{cursor:not-allowed;opacity:.6;background-color:var(--input-disabled-bg);color:var(--input-disabled-color)}.m_8fb7ebe7:has(input:disabled){cursor:not-allowed;opacity:.6;background-color:var(--input-disabled-bg);color:var(--input-disabled-color)}.m_82577fc2{pointer-events:var(--section-pointer-events);position:absolute;z-index:1;inset-inline-start:var(--section-start);inset-inline-end:var(--section-end);bottom:var(--section-y);top:var(--section-y);display:flex;align-items:center;justify-content:center;width:var(--section-size);border-radius:var(--section-border-radius);color:var(--input-section-color, var(--mantine-color-dimmed))}.m_82577fc2[data-position=right]{--section-pointer-events: var(--input-right-section-pointer-events);--section-end: var(--right-section-end);--section-size: var(--input-right-section-size);--section-border-radius: var(--right-section-border-radius)}.m_82577fc2[data-position=left]{--section-pointer-events: var(--input-left-section-pointer-events);--section-start: var(--left-section-start);--section-size: var(--input-left-section-size);--section-border-radius: var(--left-section-border-radius)}.m_88bacfd0{color:var(--input-placeholder-color, var(--mantine-color-placeholder))}[data-error] .m_88bacfd0{--input-placeholder-color: var(--input-color, var(--mantine-color-placeholder))}.m_46b77525{line-height:var(--mantine-line-height)}.m_8fdc1311{display:inline-block;font-weight:500;word-break:break-word;cursor:default;-webkit-tap-highlight-color:transparent;font-size:var(--input-label-size, var(--mantine-font-size-sm))}.m_78a94662{color:var(--input-asterisk-color, var(--mantine-color-error))}.m_8f816625,.m_fe47ce59{word-wrap:break-word;line-height:1.2;display:block;margin:0;padding:0}.m_8f816625{color:var(--mantine-color-error);font-size:var(--input-error-size, calc(var(--mantine-font-size-sm) - calc(.125rem * var(--mantine-scale))))}.m_fe47ce59{color:var(--mantine-color-dimmed);font-size:var(--input-description-size, calc(var(--mantine-font-size-sm) - calc(.125rem * var(--mantine-scale))))}.m_8bffd616{display:flex}.m_96b553a6{--transition-duration: .15s;top:0;left:0;position:absolute;z-index:0;transition-property:transform,width,height;transition-timing-function:ease;transition-duration:0ms}.m_96b553a6:where([data-initialized]){transition-duration:var(--transition-duration)}.m_96b553a6:where([data-hidden]){background-color:red;display:none}.m_9bdbb667{--accordion-radius: var(--mantine-radius-default)}.m_df78851f{word-break:break-word}.m_4ba554d4{padding:var(--mantine-spacing-md);padding-top:calc(var(--mantine-spacing-xs) / 2)}.m_8fa820a0{margin:0;padding:0}.m_4ba585b8{width:100%;display:flex;align-items:center;flex-direction:row-reverse;padding-inline:var(--mantine-spacing-md);opacity:1;cursor:pointer;background-color:transparent}.m_4ba585b8:where([data-chevron-position=left]){flex-direction:row;padding-inline-start:0}:where([data-mantine-color-scheme=light]) .m_4ba585b8{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_4ba585b8{color:var(--mantine-color-dark-0)}.m_4ba585b8:where(:disabled,[data-disabled]){opacity:.4;cursor:not-allowed}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_6939a5e9:where(:not(:disabled,[data-disabled])):hover,:where([data-mantine-color-scheme=light]) .m_4271d21b:where(:not(:disabled,[data-disabled])):hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_6939a5e9:where(:not(:disabled,[data-disabled])):hover,:where([data-mantine-color-scheme=dark]) .m_4271d21b:where(:not(:disabled,[data-disabled])):hover{background-color:var(--mantine-color-dark-6)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_6939a5e9:where(:not(:disabled,[data-disabled])):active,:where([data-mantine-color-scheme=light]) .m_4271d21b:where(:not(:disabled,[data-disabled])):active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_6939a5e9:where(:not(:disabled,[data-disabled])):active,:where([data-mantine-color-scheme=dark]) .m_4271d21b:where(:not(:disabled,[data-disabled])):active{background-color:var(--mantine-color-dark-6)}}.m_df3ffa0f{color:inherit;font-weight:400;flex:1;overflow:hidden;text-overflow:ellipsis;padding-top:var(--mantine-spacing-sm);padding-bottom:var(--mantine-spacing-sm)}.m_3f35ae96{display:flex;align-items:center;justify-content:flex-start;transition:transform var(--accordion-transition-duration, .2s) ease;width:var(--accordion-chevron-size, calc(.9375rem * var(--mantine-scale)));min-width:var(--accordion-chevron-size, calc(.9375rem * var(--mantine-scale)));transform:rotate(0)}.m_3f35ae96:where([data-rotate]){transform:rotate(180deg)}.m_3f35ae96:where([data-position=left]){margin-inline-end:var(--mantine-spacing-md);margin-inline-start:var(--mantine-spacing-md)}.m_9bd771fe{display:flex;align-items:center;justify-content:center;margin-inline-end:var(--mantine-spacing-sm)}.m_9bd771fe:where([data-chevron-position=left]){margin-inline-end:0;margin-inline-start:var(--mantine-spacing-lg)}:where([data-mantine-color-scheme=light]) .m_9bd7b098{--item-border-color: var(--mantine-color-gray-3);--item-filled-color: var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_9bd7b098{--item-border-color: var(--mantine-color-dark-4);--item-filled-color: var(--mantine-color-dark-6)}.m_fe19b709{border-bottom:1px solid var(--item-border-color)}.m_1f921b3b{border:1px solid var(--item-border-color);transition:background-color .15s ease}.m_1f921b3b:where([data-active]){background-color:var(--item-filled-color)}.m_1f921b3b:first-of-type{border-start-start-radius:var(--accordion-radius);border-start-end-radius:var(--accordion-radius)}.m_1f921b3b:first-of-type>[data-accordion-control]{border-start-start-radius:var(--accordion-radius);border-start-end-radius:var(--accordion-radius)}.m_1f921b3b:last-of-type{border-end-start-radius:var(--accordion-radius);border-end-end-radius:var(--accordion-radius)}.m_1f921b3b:last-of-type>[data-accordion-control]{border-end-start-radius:var(--accordion-radius);border-end-end-radius:var(--accordion-radius)}.m_1f921b3b+.m_1f921b3b{border-top:0}.m_2cdf939a{border-radius:var(--accordion-radius)}.m_2cdf939a:where([data-active]){background-color:var(--item-filled-color)}.m_9f59b069{background-color:var(--item-filled-color);border-radius:var(--accordion-radius);border:calc(.0625rem * var(--mantine-scale)) solid transparent;transition:background-color .15s ease}.m_9f59b069[data-active]{border-color:var(--item-border-color)}:where([data-mantine-color-scheme=light]) .m_9f59b069[data-active]{background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_9f59b069[data-active]{background-color:var(--mantine-color-dark-7)}.m_9f59b069+.m_9f59b069{margin-top:var(--mantine-spacing-md)}.m_7f854edf{position:fixed;z-index:var(--affix-z-index);inset-inline-start:var(--affix-left);inset-inline-end:var(--affix-right);top:var(--affix-top);bottom:var(--affix-bottom)}.m_66836ed3{--alert-radius: var(--mantine-radius-default);--alert-bg: var(--mantine-primary-color-light);--alert-bd: calc(.0625rem * var(--mantine-scale)) solid transparent;--alert-color: var(--mantine-primary-color-light-color);padding:var(--mantine-spacing-md) var(--mantine-spacing-md);border-radius:var(--alert-radius);position:relative;overflow:hidden;background-color:var(--alert-bg);border:var(--alert-bd);color:var(--alert-color)}.m_a5d60502{display:flex}.m_667c2793{flex:1;display:flex;flex-direction:column;gap:var(--mantine-spacing-xs)}.m_6a03f287{display:flex;align-items:center;justify-content:space-between;font-size:var(--mantine-font-size-sm);font-weight:700}.m_6a03f287:where([data-with-close-button]){padding-inline-end:var(--mantine-spacing-md)}.m_698f4f23{display:block;overflow:hidden;text-overflow:ellipsis}.m_667f2a6a{line-height:1;width:calc(1.25rem * var(--mantine-scale));height:calc(1.25rem * var(--mantine-scale));display:flex;align-items:center;justify-content:flex-start;margin-inline-end:var(--mantine-spacing-md);margin-top:calc(.0625rem * var(--mantine-scale))}.m_7fa78076{text-overflow:ellipsis;overflow:hidden;font-size:var(--mantine-font-size-sm)}:where([data-mantine-color-scheme=light]) .m_7fa78076{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_7fa78076{color:var(--mantine-color-white)}.m_7fa78076:where([data-variant=filled]){color:var(--alert-color)}.m_7fa78076:where([data-variant=white]){color:var(--mantine-color-black)}.m_87f54839{width:calc(1.25rem * var(--mantine-scale));height:calc(1.25rem * var(--mantine-scale));color:var(--alert-color)}.m_b6d8b162{-webkit-tap-highlight-color:transparent;text-decoration:none;font-size:var(--text-fz, var(--mantine-font-size-md));line-height:var(--text-lh, var(--mantine-line-height-md));font-weight:400;margin:0;padding:0;color:var(--text-color)}.m_b6d8b162:where([data-truncate]){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.m_b6d8b162:where([data-truncate=start]){direction:rtl;text-align:right}:where([dir=rtl]) .m_b6d8b162:where([data-truncate=start]){direction:ltr;text-align:left}.m_b6d8b162:where([data-variant=gradient]){background-image:var(--text-gradient);background-clip:text;-webkit-background-clip:text;-webkit-text-fill-color:transparent}.m_b6d8b162:where([data-line-clamp]){overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:var(--text-line-clamp);-webkit-box-orient:vertical}.m_b6d8b162:where([data-inherit]){line-height:inherit;font-weight:inherit;font-size:inherit}.m_b6d8b162:where([data-inline]){line-height:1}.m_849cf0da{color:var(--mantine-color-anchor);text-decoration:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;display:inline;padding:0;margin:0;background-color:transparent;cursor:pointer}@media (hover: hover){.m_849cf0da:where([data-underline=hover]):hover{text-decoration:underline}}@media (hover: none){.m_849cf0da:where([data-underline=hover]):active{text-decoration:underline}}.m_849cf0da:where([data-underline=always]){text-decoration:underline}.m_89ab340[data-resizing]{--app-shell-transition-duration: 0ms !important}.m_89ab340[data-disabled]{--app-shell-header-offset: 0rem !important;--app-shell-navbar-offset: 0rem !important}[data-mantine-color-scheme=light] .m_89ab340{--app-shell-border-color: var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m_89ab340{--app-shell-border-color: var(--mantine-color-dark-4)}.m_45252eee,.m_9cdde9a,.m_3b16f56b,.m_8983817,.m_3840c879{transition-duration:var(--app-shell-transition-duration);transition-timing-function:var(--app-shell-transition-timing-function)}.m_45252eee,.m_9cdde9a{position:fixed;display:flex;flex-direction:column;top:var(--app-shell-header-offset, 0rem);height:calc(100dvh - var(--app-shell-header-offset, 0rem) - var(--app-shell-footer-offset, 0rem));background-color:var(--mantine-color-body);transition-property:transform,top,height}:where([data-layout=alt]) .m_45252eee,:where([data-layout=alt]) .m_9cdde9a{top:0rem;height:100dvh}.m_45252eee{inset-inline-start:0;width:var(--app-shell-navbar-width);transition-property:transform,top,height;transform:var(--app-shell-navbar-transform);z-index:var(--app-shell-navbar-z-index)}:where([dir=rtl]) .m_45252eee{transform:var(--app-shell-navbar-transform-rtl)}.m_45252eee:where([data-with-border]){border-inline-end:1px solid var(--app-shell-border-color)}.m_9cdde9a{inset-inline-end:0;width:var(--app-shell-aside-width);transform:var(--app-shell-aside-transform);z-index:var(--app-shell-aside-z-index)}:where([dir=rtl]) .m_9cdde9a{transform:var(--app-shell-aside-transform-rtl)}.m_9cdde9a:where([data-with-border]){border-inline-start:1px solid var(--app-shell-border-color)}.m_8983817{padding-inline-start:calc(var(--app-shell-navbar-offset, 0rem) + var(--app-shell-padding));padding-inline-end:calc(var(--app-shell-aside-offset, 0rem) + var(--app-shell-padding));padding-top:calc(var(--app-shell-header-offset, 0rem) + var(--app-shell-padding));padding-bottom:calc(var(--app-shell-footer-offset, 0rem) + var(--app-shell-padding));min-height:100dvh;transition-property:padding}.m_3b16f56b,.m_3840c879{position:fixed;inset-inline:0;transition-property:transform,left,right;background-color:var(--mantine-color-body)}:where([data-layout=alt]) .m_3b16f56b,:where([data-layout=alt]) .m_3840c879{inset-inline-start:var(--app-shell-navbar-offset, 0rem);inset-inline-end:var(--app-shell-aside-offset, 0rem)}.m_3b16f56b{top:0;height:var(--app-shell-header-height);background-color:var(--mantine-color-body);transform:var(--app-shell-header-transform);z-index:var(--app-shell-header-z-index)}.m_3b16f56b:where([data-with-border]){border-bottom:1px solid var(--app-shell-border-color)}.m_3840c879{bottom:0;height:calc(var(--app-shell-footer-height) + env(safe-area-inset-bottom));padding-bottom:env(safe-area-inset-bottom);transform:var(--app-shell-footer-transform);z-index:var(--app-shell-footer-z-index)}.m_3840c879:where([data-with-border]){border-top:1px solid var(--app-shell-border-color)}.m_6dcfc7c7{flex-grow:0}.m_6dcfc7c7:where([data-grow]){flex-grow:1}.m_71ac47fc{--ar-ratio: 1;position:relative;max-width:100%}.m_71ac47fc:before{content:"";height:0;display:block;padding-bottom:calc((1 / var(--ar-ratio)) * 100%)}.m_71ac47fc:after{content:"";display:table;clear:both}.m_71ac47fc>:where(*:not(style)){position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center}.m_71ac47fc>:where(img,video){object-fit:cover}.m_88b62a41{--combobox-padding: calc(.25rem * var(--mantine-scale));padding:var(--combobox-padding)}.m_88b62a41[data-hidden]{display:none}.m_88b62a41,.m_b2821a6e{--combobox-option-padding-xs: calc(.25rem * var(--mantine-scale)) calc(.5rem * var(--mantine-scale));--combobox-option-padding-sm: calc(.375rem * var(--mantine-scale)) calc(.625rem * var(--mantine-scale));--combobox-option-padding-md: calc(.5rem * var(--mantine-scale)) calc(.75rem * var(--mantine-scale));--combobox-option-padding-lg: calc(.625rem * var(--mantine-scale)) calc(1rem * var(--mantine-scale));--combobox-option-padding-xl: calc(.875rem * var(--mantine-scale)) calc(1.25rem * var(--mantine-scale));--combobox-option-padding: var(--combobox-option-padding-sm)}.m_92253aa5{padding:var(--combobox-option-padding);font-size:var(--combobox-option-fz, var(--mantine-font-size-sm));border-radius:var(--mantine-radius-default);background-color:transparent;color:inherit;cursor:pointer;word-break:break-word}.m_92253aa5:where([data-combobox-selected]){background-color:var(--mantine-primary-color-filled);color:var(--mantine-color-white)}.m_92253aa5:where([data-combobox-disabled]){cursor:not-allowed;opacity:.35}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_92253aa5:hover:where(:not([data-combobox-selected],[data-combobox-disabled])){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_92253aa5:hover:where(:not([data-combobox-selected],[data-combobox-disabled])){background-color:var(--mantine-color-dark-7)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_92253aa5:active:where(:not([data-combobox-selected],[data-combobox-disabled])){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_92253aa5:active:where(:not([data-combobox-selected],[data-combobox-disabled])){background-color:var(--mantine-color-dark-7)}}.m_985517d8{margin-inline:calc(var(--combobox-padding) * -1);margin-top:calc(var(--combobox-padding) * -1);width:calc(100% + var(--combobox-padding) * 2);border-top-width:0;border-inline-width:0;border-end-start-radius:0;border-end-end-radius:0;margin-bottom:var(--combobox-padding);position:relative}:where([data-mantine-color-scheme=light]) .m_985517d8,:where([data-mantine-color-scheme=light]) .m_985517d8:focus{border-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_985517d8,:where([data-mantine-color-scheme=dark]) .m_985517d8:focus{border-color:var(--mantine-color-dark-4)}:where([data-mantine-color-scheme=light]) .m_985517d8{background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_985517d8{background-color:var(--mantine-color-dark-7)}.m_2530cd1d{font-size:var(--combobox-option-fz, var(--mantine-font-size-sm));text-align:center;padding:var(--combobox-option-padding);color:var(--mantine-color-dimmed)}.m_858f94bd,.m_82b967cb{font-size:var(--combobox-option-fz, var(--mantine-font-size-sm));border:0 solid transparent;margin-inline:calc(var(--combobox-padding) * -1);padding:var(--combobox-option-padding)}:where([data-mantine-color-scheme=light]) .m_858f94bd,:where([data-mantine-color-scheme=light]) .m_82b967cb{border-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_858f94bd,:where([data-mantine-color-scheme=dark]) .m_82b967cb{border-color:var(--mantine-color-dark-4)}.m_82b967cb{border-top-width:calc(.0625rem * var(--mantine-scale));margin-top:var(--combobox-padding);margin-bottom:calc(var(--combobox-padding) * -1)}.m_858f94bd{border-bottom-width:calc(.0625rem * var(--mantine-scale));margin-bottom:var(--combobox-padding);margin-top:calc(var(--combobox-padding) * -1)}.m_254f3e4f:has(.m_2bb2e9e5:only-child){display:none}.m_2bb2e9e5{color:var(--mantine-color-dimmed);font-size:calc(var(--combobox-option-fz, var(--mantine-font-size-sm)) * .85);padding:var(--combobox-option-padding);font-weight:500;position:relative;display:flex;align-items:center}.m_2bb2e9e5:after{content:"";flex:1;inset-inline:0;height:calc(.0625rem * var(--mantine-scale));margin-inline-start:var(--mantine-spacing-xs)}:where([data-mantine-color-scheme=light]) .m_2bb2e9e5:after{background-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_2bb2e9e5:after{background-color:var(--mantine-color-dark-4)}.m_2bb2e9e5:only-child{display:none}.m_2943220b{--combobox-chevron-size-xs: calc(.875rem * var(--mantine-scale));--combobox-chevron-size-sm: calc(1.125rem * var(--mantine-scale));--combobox-chevron-size-md: calc(1.25rem * var(--mantine-scale));--combobox-chevron-size-lg: calc(1.5rem * var(--mantine-scale));--combobox-chevron-size-xl: calc(1.75rem * var(--mantine-scale));--combobox-chevron-size: var(--combobox-chevron-size-sm);width:var(--combobox-chevron-size);height:var(--combobox-chevron-size)}:where([data-mantine-color-scheme=light]) .m_2943220b{color:var(--mantine-color-gray-6)}:where([data-mantine-color-scheme=dark]) .m_2943220b{color:var(--mantine-color-dark-3)}.m_2943220b:where([data-error]){color:var(--mantine-color-error)}.m_390b5f4{display:flex;align-items:center;gap:calc(.5rem * var(--mantine-scale))}.m_390b5f4:where([data-reverse]){justify-content:space-between}.m_8ee53fc2{opacity:.4;width:.8em;min-width:.8em;height:.8em}:where([data-combobox-selected]) .m_8ee53fc2{opacity:1}.m_5f75b09e{--label-lh-xs: calc(1rem * var(--mantine-scale));--label-lh-sm: calc(1.25rem * var(--mantine-scale));--label-lh-md: calc(1.5rem * var(--mantine-scale));--label-lh-lg: calc(1.875rem * var(--mantine-scale));--label-lh-xl: calc(2.25rem * var(--mantine-scale));--label-lh: var(--label-lh-sm)}.m_5f75b09e[data-label-position=left]{--label-order: 1;--label-offset-end: var(--mantine-spacing-sm);--label-offset-start: 0}.m_5f75b09e[data-label-position=right]{--label-order: 2;--label-offset-end: 0;--label-offset-start: var(--mantine-spacing-sm)}.m_5f6e695e{display:flex}.m_d3ea56bb{--label-cursor: var(--mantine-cursor-type);-webkit-tap-highlight-color:transparent;display:inline-flex;flex-direction:column;font-size:var(--label-fz, var(--mantine-font-size-sm));line-height:var(--label-lh);cursor:var(--label-cursor);order:var(--label-order)}fieldset:disabled .m_d3ea56bb,.m_d3ea56bb[data-disabled]{--label-cursor: not-allowed}.m_8ee546b8{cursor:var(--label-cursor);color:inherit;padding-inline-start:var(--label-offset-start);padding-inline-end:var(--label-offset-end)}:where([data-mantine-color-scheme=light]) fieldset:disabled .m_8ee546b8,:where([data-mantine-color-scheme=light]) .m_8ee546b8:where([data-disabled]){color:var(--mantine-color-gray-5)}:where([data-mantine-color-scheme=dark]) fieldset:disabled .m_8ee546b8,:where([data-mantine-color-scheme=dark]) .m_8ee546b8:where([data-disabled]){color:var(--mantine-color-dark-3)}.m_328f68c0,.m_8e8a99cc{margin-top:calc(var(--mantine-spacing-xs) / 2);padding-inline-start:var(--label-offset-start);padding-inline-end:var(--label-offset-end)}.m_bf2d988c{--checkbox-size-xs: calc(1rem * var(--mantine-scale));--checkbox-size-sm: calc(1.25rem * var(--mantine-scale));--checkbox-size-md: calc(1.5rem * var(--mantine-scale));--checkbox-size-lg: calc(1.875rem * var(--mantine-scale));--checkbox-size-xl: calc(2.25rem * var(--mantine-scale));--checkbox-size: var(--checkbox-size-sm);--checkbox-color: var(--mantine-primary-color-filled);--checkbox-icon-color: var(--mantine-color-white)}.m_26062bec{position:relative;width:var(--checkbox-size);height:var(--checkbox-size);order:1}.m_26062bec:where([data-label-position=left]){order:2}.m_26063560{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:calc(.0625rem * var(--mantine-scale)) solid transparent;width:var(--checkbox-size);height:var(--checkbox-size);border-radius:var(--checkbox-radius, var(--mantine-radius-default));padding:0;display:block;margin:0;transition:border-color .1s ease,background-color .1s ease;cursor:var(--mantine-cursor-type);-webkit-tap-highlight-color:transparent}:where([data-mantine-color-scheme=light]) .m_26063560{background-color:var(--mantine-color-white);border-color:var(--mantine-color-gray-4)}:where([data-mantine-color-scheme=dark]) .m_26063560{background-color:var(--mantine-color-dark-6);border-color:var(--mantine-color-dark-4)}.m_26063560:where([data-error]){border-color:var(--mantine-color-error)}.m_26063560[data-indeterminate],.m_26063560:checked{background-color:var(--checkbox-color);border-color:var(--checkbox-color)}.m_26063560[data-indeterminate]+.m_bf295423,.m_26063560:checked+.m_bf295423{opacity:1;transform:none}.m_26063560:disabled{cursor:not-allowed}:where([data-mantine-color-scheme=light]) .m_26063560:disabled{background-color:var(--mantine-color-gray-2);border-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_26063560:disabled{background-color:var(--mantine-color-dark-6);border-color:var(--mantine-color-dark-6)}[data-mantine-color-scheme=light] .m_26063560:disabled+.m_bf295423{color:var(--mantine-color-gray-5)}[data-mantine-color-scheme=dark] .m_26063560:disabled+.m_bf295423{color:var(--mantine-color-dark-3)}.m_215c4542+.m_bf295423{color:var(--checkbox-color)}.m_215c4542[data-indeterminate]:not(:disabled),.m_215c4542:checked:not(:disabled){background-color:transparent;border-color:var(--checkbox-color)}.m_215c4542[data-indeterminate]:not(:disabled)+.m_bf295423,.m_215c4542:checked:not(:disabled)+.m_bf295423{color:var(--checkbox-color);opacity:1;transform:none}.m_bf295423{position:absolute;top:0;right:0;bottom:0;left:0;width:60%;margin:auto;color:var(--checkbox-icon-color);pointer-events:none;transform:translateY(calc(.3125rem * var(--mantine-scale))) scale(.5);opacity:0;transition:transform .1s ease,opacity .1s ease}.m_11def92b{--ag-spacing: var(--mantine-spacing-sm);--ag-offset: calc(var(--ag-spacing) * -1);display:flex;padding-inline-start:var(--ag-spacing)}.m_f85678b6{--avatar-size-xs: calc(1rem * var(--mantine-scale));--avatar-size-sm: calc(1.625rem * var(--mantine-scale));--avatar-size-md: calc(2.375rem * var(--mantine-scale));--avatar-size-lg: calc(3.5rem * var(--mantine-scale));--avatar-size-xl: calc(5.25rem * var(--mantine-scale));--avatar-size: var(--avatar-size-md);--avatar-radius: calc(62.5rem * var(--mantine-scale));--avatar-bg: var(--mantine-color-gray-light);--avatar-bd: calc(.0625rem * var(--mantine-scale)) solid transparent;--avatar-color: var(--mantine-color-gray-light-color);--avatar-placeholder-fz: calc(var(--avatar-size) / 2.5);-webkit-tap-highlight-color:transparent;position:relative;display:block;-webkit-user-select:none;user-select:none;overflow:hidden;border-radius:var(--avatar-radius);text-decoration:none;padding:0;width:var(--avatar-size);height:var(--avatar-size);min-width:var(--avatar-size)}.m_f85678b6:where([data-within-group]){margin-inline-start:var(--ag-offset);border:2px solid var(--mantine-color-body);background:var(--mantine-color-body)}.m_11f8ac07{object-fit:cover;width:100%;height:100%;display:block}.m_104cd71f{font-weight:700;display:flex;align-items:center;justify-content:center;width:100%;height:100%;-webkit-user-select:none;user-select:none;border-radius:var(--avatar-radius);font-size:var(--avatar-placeholder-fz);background:var(--avatar-bg);border:var(--avatar-bd);color:var(--avatar-color)}.m_104cd71f>[data-avatar-placeholder-icon]{width:70%;height:70%}.m_2ce0de02{background-size:cover;background-position:center;display:block;width:100%;border:0;text-decoration:none;border-radius:var(--bi-radius, 0)}.m_347db0ec{--badge-height-xs: calc(1rem * var(--mantine-scale));--badge-height-sm: calc(1.125rem * var(--mantine-scale));--badge-height-md: calc(1.25rem * var(--mantine-scale));--badge-height-lg: calc(1.625rem * var(--mantine-scale));--badge-height-xl: calc(2rem * var(--mantine-scale));--badge-fz-xs: calc(.5625rem * var(--mantine-scale));--badge-fz-sm: calc(.625rem * var(--mantine-scale));--badge-fz-md: calc(.6875rem * var(--mantine-scale));--badge-fz-lg: calc(.8125rem * var(--mantine-scale));--badge-fz-xl: calc(1rem * var(--mantine-scale));--badge-padding-x-xs: calc(.375rem * var(--mantine-scale));--badge-padding-x-sm: calc(.5rem * var(--mantine-scale));--badge-padding-x-md: calc(.625rem * var(--mantine-scale));--badge-padding-x-lg: calc(.75rem * var(--mantine-scale));--badge-padding-x-xl: calc(1rem * var(--mantine-scale));--badge-height: var(--badge-height-md);--badge-fz: var(--badge-fz-md);--badge-padding-x: var(--badge-padding-x-md);--badge-radius: calc(62.5rem * var(--mantine-scale));--badge-lh: calc(var(--badge-height) - calc(.125rem * var(--mantine-scale)));--badge-color: var(--mantine-color-white);--badge-bg: var(--mantine-primary-color-filled);--badge-bd: calc(.0625rem * var(--mantine-scale)) solid transparent;-webkit-tap-highlight-color:transparent;font-size:var(--badge-fz);border-radius:var(--badge-radius);height:var(--badge-height);line-height:var(--badge-lh);text-decoration:none;padding:0 var(--badge-padding-x);display:inline-flex;align-items:center;justify-content:center;width:fit-content;text-transform:uppercase;font-weight:700;letter-spacing:calc(.015625rem * var(--mantine-scale));cursor:inherit;text-overflow:ellipsis;overflow:hidden;color:var(--badge-color);background:var(--badge-bg);border:var(--badge-bd)}.m_347db0ec:where([data-block]){display:flex;width:100%}.m_347db0ec:where([data-circle]){padding-inline:calc(.125rem * var(--mantine-scale));width:var(--badge-height)}.m_fbd81e3d{--badge-dot-size: calc(var(--badge-height) / 3.4)}:where([data-mantine-color-scheme=light]) .m_fbd81e3d{background-color:var(--mantine-color-white);border-color:var(--mantine-color-gray-4);color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_fbd81e3d{background-color:var(--mantine-color-dark-5);border-color:var(--mantine-color-dark-5);color:var(--mantine-color-white)}.m_fbd81e3d:before{content:"";display:block;width:var(--badge-dot-size);height:var(--badge-dot-size);border-radius:var(--badge-dot-size);background-color:var(--badge-dot-color);margin-inline-end:var(--badge-dot-size)}.m_5add502a{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.m_91fdda9b{--badge-section-margin: calc(var(--mantine-spacing-xs) / 2);display:inline-flex;justify-content:center;align-items:center}.m_91fdda9b:where([data-position=left]){margin-inline-end:var(--badge-section-margin)}.m_91fdda9b:where([data-position=right]){margin-inline-start:var(--badge-section-margin)}.m_ddec01c0{--blockquote-border: 3px solid var(--bq-bd);position:relative;margin:0;border-inline-start:var(--blockquote-border);border-start-end-radius:var(--bq-radius);border-end-end-radius:var(--bq-radius);padding:var(--mantine-spacing-xl) calc(2.375rem * var(--mantine-scale))}:where([data-mantine-color-scheme=light]) .m_ddec01c0{background-color:var(--bq-bg-light)}:where([data-mantine-color-scheme=dark]) .m_ddec01c0{background-color:var(--bq-bg-dark)}.m_dde7bd57{--blockquote-icon-offset: calc(var(--bq-icon-size) / -2);position:absolute;color:var(--bq-bd);background-color:var(--mantine-color-body);display:flex;align-items:center;justify-content:center;top:var(--blockquote-icon-offset);inset-inline-start:var(--blockquote-icon-offset);width:var(--bq-icon-size);height:var(--bq-icon-size);border-radius:var(--bq-icon-size)}.m_dde51a35{display:block;margin-top:var(--mantine-spacing-md);opacity:.6;font-size:85%}.m_8b3717df{display:flex;align-items:center}.m_f678d540{line-height:1;white-space:nowrap;-webkit-tap-highlight-color:transparent}.m_3b8f2208{margin-inline:var(--bc-separator-margin, var(--mantine-spacing-xs));line-height:1;display:flex;align-items:center;justify-content:center}:where([data-mantine-color-scheme=light]) .m_3b8f2208{color:var(--mantine-color-gray-7)}:where([data-mantine-color-scheme=dark]) .m_3b8f2208{color:var(--mantine-color-dark-2)}.m_fea6bf1a{--burger-size-xs: calc(.75rem * var(--mantine-scale));--burger-size-sm: calc(1.125rem * var(--mantine-scale));--burger-size-md: calc(1.5rem * var(--mantine-scale));--burger-size-lg: calc(2.125rem * var(--mantine-scale));--burger-size-xl: calc(2.625rem * var(--mantine-scale));--burger-size: var(--burger-size-md);width:calc(var(--burger-size) + var(--mantine-spacing-xs));height:calc(var(--burger-size) + var(--mantine-spacing-xs));padding:calc(var(--mantine-spacing-xs) / 2);cursor:pointer}:where([data-mantine-color-scheme=light]) .m_fea6bf1a{--burger-color: var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_fea6bf1a{--burger-color: var(--mantine-color-white)}.m_d4fb9cad{position:relative;-webkit-user-select:none;user-select:none}.m_d4fb9cad,.m_d4fb9cad:before,.m_d4fb9cad:after{display:block;width:var(--burger-size);height:calc(var(--burger-size) / 12);background-color:var(--burger-color);outline:calc(.0625rem * var(--mantine-scale)) solid transparent;transition-property:background-color,transform;transition-duration:var(--burger-transition-duration, .3s);transition-timing-function:var(--burger-transition-timing-function, ease)}.m_d4fb9cad:before,.m_d4fb9cad:after{position:absolute;content:"";inset-inline-start:0}.m_d4fb9cad:before{top:calc(var(--burger-size) / -3)}.m_d4fb9cad:after{top:calc(var(--burger-size) / 3)}.m_d4fb9cad[data-opened]{background-color:transparent}.m_d4fb9cad[data-opened]:before{transform:translateY(calc(var(--burger-size) / 3)) rotate(45deg)}.m_d4fb9cad[data-opened]:after{transform:translateY(calc(var(--burger-size) / -3)) rotate(-45deg)}.m_77c9d27d{--button-height-xs: calc(1.875rem * var(--mantine-scale));--button-height-sm: calc(2.25rem * var(--mantine-scale));--button-height-md: calc(2.625rem * var(--mantine-scale));--button-height-lg: calc(3.125rem * var(--mantine-scale));--button-height-xl: calc(3.75rem * var(--mantine-scale));--button-height-compact-xs: calc(1.375rem * var(--mantine-scale));--button-height-compact-sm: calc(1.625rem * var(--mantine-scale));--button-height-compact-md: calc(1.875rem * var(--mantine-scale));--button-height-compact-lg: calc(2.125rem * var(--mantine-scale));--button-height-compact-xl: calc(2.5rem * var(--mantine-scale));--button-padding-x-xs: calc(.875rem * var(--mantine-scale));--button-padding-x-sm: calc(1.125rem * var(--mantine-scale));--button-padding-x-md: calc(1.375rem * var(--mantine-scale));--button-padding-x-lg: calc(1.625rem * var(--mantine-scale));--button-padding-x-xl: calc(2rem * var(--mantine-scale));--button-padding-x-compact-xs: calc(.4375rem * var(--mantine-scale));--button-padding-x-compact-sm: calc(.5rem * var(--mantine-scale));--button-padding-x-compact-md: calc(.625rem * var(--mantine-scale));--button-padding-x-compact-lg: calc(.75rem * var(--mantine-scale));--button-padding-x-compact-xl: calc(.875rem * var(--mantine-scale));--button-height: var(--button-height-sm);--button-padding-x: var(--button-padding-x-sm);--button-color: var(--mantine-color-white);-webkit-user-select:none;user-select:none;font-weight:600;position:relative;line-height:1;text-align:center;overflow:hidden;width:auto;cursor:pointer;display:inline-block;border-radius:var(--button-radius, var(--mantine-radius-default));font-size:var(--button-fz, var(--mantine-font-size-sm));background:var(--button-bg, var(--mantine-primary-color-filled));border:var(--button-bd, calc(.0625rem * var(--mantine-scale)) solid transparent);color:var(--button-color, var(--mantine-color-white));height:var(--button-height, var(--button-height-sm));padding-inline:var(--button-padding-x, var(--button-padding-x-sm));vertical-align:middle}.m_77c9d27d:where([data-block]){display:block;width:100%}.m_77c9d27d:where([data-with-left-section]){padding-inline-start:calc(var(--button-padding-x) / 1.5)}.m_77c9d27d:where([data-with-right-section]){padding-inline-end:calc(var(--button-padding-x) / 1.5)}.m_77c9d27d:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){cursor:not-allowed;border:calc(.0625rem * var(--mantine-scale)) solid transparent;transform:none}:where([data-mantine-color-scheme=light]) .m_77c9d27d:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){color:var(--mantine-color-gray-5);background:var(--mantine-color-gray-1)}:where([data-mantine-color-scheme=dark]) .m_77c9d27d:where(:disabled:not([data-loading]),[data-disabled]:not([data-loading])){color:var(--mantine-color-dark-3);background:var(--mantine-color-dark-6)}.m_77c9d27d:before{content:"";pointer-events:none;position:absolute;inset:calc(-.0625rem * var(--mantine-scale));border-radius:var(--button-radius, var(--mantine-radius-default));transform:translateY(-100%);opacity:0;filter:blur(12px);transition:transform .15s ease,opacity .1s ease}:where([data-mantine-color-scheme=light]) .m_77c9d27d:before{background-color:#ffffff26}:where([data-mantine-color-scheme=dark]) .m_77c9d27d:before{background-color:#00000026}.m_77c9d27d:where([data-loading]){cursor:not-allowed;transform:none}.m_77c9d27d:where([data-loading]):before{transform:translateY(0);opacity:1}.m_77c9d27d:where([data-loading]) .m_80f1301b{opacity:0;transform:translateY(100%)}@media (hover: hover){.m_77c9d27d:hover:where(:not([data-loading],:disabled,[data-disabled])){background-color:var(--button-hover, var(--mantine-primary-color-filled-hover));color:var(--button-hover-color, var(--button-color))}}@media (hover: none){.m_77c9d27d:active:where(:not([data-loading],:disabled,[data-disabled])){background-color:var(--button-hover, var(--mantine-primary-color-filled-hover));color:var(--button-hover-color, var(--button-color))}}.m_80f1301b{display:flex;align-items:center;justify-content:var(--button-justify, center);height:100%;overflow:visible;transition:transform .15s ease,opacity .1s ease}.m_811560b9{white-space:nowrap;height:100%;overflow:hidden;display:flex;align-items:center;opacity:1}.m_811560b9:where([data-loading]){opacity:.2}.m_a74036a{display:flex;align-items:center}.m_a74036a:where([data-position=left]){margin-inline-end:var(--mantine-spacing-xs)}.m_a74036a:where([data-position=right]){margin-inline-start:var(--mantine-spacing-xs)}.m_a25b86ee{position:absolute;left:50%;top:50%}.m_80d6d844{--button-border-width: calc(.0625rem * var(--mantine-scale));display:flex}.m_80d6d844 :where(*):focus{position:relative;z-index:1}.m_80d6d844[data-orientation=horizontal]{flex-direction:row}.m_80d6d844[data-orientation=horizontal] .m_77c9d27d:not(:only-child):first-child{border-end-end-radius:0;border-start-end-radius:0;border-inline-end-width:calc(var(--button-border-width) / 2)}.m_80d6d844[data-orientation=horizontal] .m_77c9d27d:not(:only-child):last-child{border-end-start-radius:0;border-start-start-radius:0;border-inline-start-width:calc(var(--button-border-width) / 2)}.m_80d6d844[data-orientation=horizontal] .m_77c9d27d:not(:only-child):not(:first-child):not(:last-child){border-radius:0;border-inline-width:calc(var(--button-border-width) / 2)}.m_80d6d844[data-orientation=vertical]{flex-direction:column}.m_80d6d844[data-orientation=vertical] .m_77c9d27d:not(:only-child):first-child{border-end-start-radius:0;border-end-end-radius:0;border-bottom-width:calc(var(--button-border-width) / 2)}.m_80d6d844[data-orientation=vertical] .m_77c9d27d:not(:only-child):last-child{border-start-start-radius:0;border-start-end-radius:0;border-top-width:calc(var(--button-border-width) / 2)}.m_80d6d844[data-orientation=vertical] .m_77c9d27d:not(:only-child):not(:first-child):not(:last-child){border-radius:0;border-bottom-width:calc(var(--button-border-width) / 2);border-top-width:calc(var(--button-border-width) / 2)}.m_e615b15f{--card-padding: var(--mantine-spacing-md);position:relative;overflow:hidden;display:flex;flex-direction:column;padding:var(--card-padding);color:var(--mantine-color-text)}:where([data-mantine-color-scheme=light]) .m_e615b15f{background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_e615b15f{background-color:var(--mantine-color-dark-6)}.m_599a2148{display:block;margin-inline:calc(var(--card-padding) * -1)}.m_599a2148:where(:first-child){margin-top:calc(var(--card-padding) * -1);border-top:none!important}.m_599a2148:where(:last-child){margin-bottom:calc(var(--card-padding) * -1);border-bottom:none!important}.m_599a2148:where([data-inherit-padding]){padding-inline:var(--card-padding)}.m_599a2148:where([data-with-border]){border-top:calc(.0625rem * var(--mantine-scale)) solid;border-bottom:calc(.0625rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_599a2148{border-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_599a2148{border-color:var(--mantine-color-dark-4)}.m_599a2148+.m_599a2148{border-top:none!important}.m_4451eb3a{display:flex;align-items:center;justify-content:center}.m_4451eb3a:where([data-inline]){display:inline-flex}.m_f59ffda3{--chip-size-xs: calc(1.4375rem * var(--mantine-scale));--chip-size-sm: calc(1.75rem * var(--mantine-scale));--chip-size-md: calc(2rem * var(--mantine-scale));--chip-size-lg: calc(2.25rem * var(--mantine-scale));--chip-size-xl: calc(2.5rem * var(--mantine-scale));--chip-icon-size-xs: calc(.625rem * var(--mantine-scale));--chip-icon-size-sm: calc(.75rem * var(--mantine-scale));--chip-icon-size-md: calc(.875rem * var(--mantine-scale));--chip-icon-size-lg: calc(1rem * var(--mantine-scale));--chip-icon-size-xl: calc(1.125rem * var(--mantine-scale));--chip-padding-xs: calc(1rem * var(--mantine-scale));--chip-padding-sm: calc(1.25rem * var(--mantine-scale));--chip-padding-md: calc(1.5rem * var(--mantine-scale));--chip-padding-lg: calc(1.75rem * var(--mantine-scale));--chip-padding-xl: calc(2rem * var(--mantine-scale));--chip-checked-padding-xs: calc(.46875rem * var(--mantine-scale));--chip-checked-padding-sm: calc(.625rem * var(--mantine-scale));--chip-checked-padding-md: calc(.73125rem * var(--mantine-scale));--chip-checked-padding-lg: calc(.84375rem * var(--mantine-scale));--chip-checked-padding-xl: calc(.78125rem * var(--mantine-scale));--chip-spacing-xs: calc(.625rem * var(--mantine-scale));--chip-spacing-sm: calc(.75rem * var(--mantine-scale));--chip-spacing-md: calc(1rem * var(--mantine-scale));--chip-spacing-lg: calc(1.25rem * var(--mantine-scale));--chip-spacing-xl: calc(1.375rem * var(--mantine-scale));--chip-size: var(--chip-size-sm);--chip-icon-size: var(--chip-icon-size-sm);--chip-padding: var(--chip-padding-sm);--chip-spacing: var(--chip-spacing-sm);--chip-checked-padding: var(--chip-checked-padding-sm);--chip-bg: var(--mantine-primary-color-filled);--chip-hover: var(--mantine-primary-color-filled-hover);--chip-color: var(--mantine-color-white);--chip-bd: calc(.0625rem * var(--mantine-scale)) solid transparent}.m_be049a53{display:inline-flex;align-items:center;-webkit-user-select:none;user-select:none;border-radius:var(--chip-radius, 1000rem);height:var(--chip-size);font-size:var(--chip-fz, var(--mantine-font-size-sm));line-height:calc(var(--chip-size) - calc(.125rem * var(--mantine-scale)));padding-inline:var(--chip-padding);cursor:pointer;white-space:nowrap;-webkit-tap-highlight-color:transparent;border:calc(.0625rem * var(--mantine-scale)) solid transparent;color:var(--mantine-color-text)}.m_be049a53:where([data-checked]){padding:var(--chip-checked-padding)}.m_be049a53:where([data-disabled]){cursor:not-allowed}:where([data-mantine-color-scheme=light]) .m_be049a53:where([data-disabled]){background-color:var(--mantine-color-gray-2);color:var(--mantine-color-gray-5)}:where([data-mantine-color-scheme=dark]) .m_be049a53:where([data-disabled]){background-color:var(--mantine-color-dark-6);color:var(--mantine-color-dark-3)}:where([data-mantine-color-scheme=light]) .m_3904c1af:not([data-disabled]){background-color:var(--mantine-color-white);border:1px solid var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_3904c1af:not([data-disabled]){background-color:var(--mantine-color-dark-6);border:1px solid var(--mantine-color-dark-4)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_3904c1af:not([data-disabled]):hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_3904c1af:not([data-disabled]):hover{background-color:var(--mantine-color-dark-5)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_3904c1af:not([data-disabled]):active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_3904c1af:not([data-disabled]):active{background-color:var(--mantine-color-dark-5)}}.m_3904c1af:not([data-disabled]):where([data-checked]){--chip-icon-color: var(--chip-color);border:var(--chip-bd)}@media (hover: hover){.m_3904c1af:not([data-disabled]):where([data-checked]):hover{background-color:var(--chip-hover)}}@media (hover: none){.m_3904c1af:not([data-disabled]):where([data-checked]):active{background-color:var(--chip-hover)}}.m_fa109255:not([data-disabled]),.m_f7e165c3:not([data-disabled]){border:calc(.0625rem * var(--mantine-scale)) solid transparent;color:var(--mantine-color-text)}:where([data-mantine-color-scheme=light]) .m_fa109255:not([data-disabled]),:where([data-mantine-color-scheme=light]) .m_f7e165c3:not([data-disabled]){background-color:var(--mantine-color-gray-1)}:where([data-mantine-color-scheme=dark]) .m_fa109255:not([data-disabled]),:where([data-mantine-color-scheme=dark]) .m_f7e165c3:not([data-disabled]){background-color:var(--mantine-color-dark-5)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_fa109255:not([data-disabled]):hover,:where([data-mantine-color-scheme=light]) .m_f7e165c3:not([data-disabled]):hover{background-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_fa109255:not([data-disabled]):hover,:where([data-mantine-color-scheme=dark]) .m_f7e165c3:not([data-disabled]):hover{background-color:var(--mantine-color-dark-4)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_fa109255:not([data-disabled]):active,:where([data-mantine-color-scheme=light]) .m_f7e165c3:not([data-disabled]):active{background-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_fa109255:not([data-disabled]):active,:where([data-mantine-color-scheme=dark]) .m_f7e165c3:not([data-disabled]):active{background-color:var(--mantine-color-dark-4)}}.m_fa109255:not([data-disabled]):where([data-checked]),.m_f7e165c3:not([data-disabled]):where([data-checked]){--chip-icon-color: var(--chip-color);color:var(--chip-color);background-color:var(--chip-bg)}@media (hover: hover){.m_fa109255:not([data-disabled]):where([data-checked]):hover,.m_f7e165c3:not([data-disabled]):where([data-checked]):hover{background-color:var(--chip-hover)}}@media (hover: none){.m_fa109255:not([data-disabled]):where([data-checked]):active,.m_f7e165c3:not([data-disabled]):where([data-checked]):active{background-color:var(--chip-hover)}}.m_9ac86df9{width:calc(var(--chip-icon-size) + (var(--chip-spacing) / 1.5));max-width:calc(var(--chip-icon-size) + (var(--chip-spacing) / 1.5));height:var(--chip-icon-size);display:flex;align-items:center;overflow:hidden}.m_d6d72580{width:var(--chip-icon-size);height:var(--chip-icon-size);display:block;color:var(--chip-icon-color, inherit)}.m_bde07329{width:0;height:0;padding:0;opacity:0;margin:0}.m_bde07329:focus-visible+.m_be049a53{outline:2px solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem * var(--mantine-scale))}.m_b183c0a2{font-family:var(--mantine-font-family-monospace);line-height:var(--mantine-line-height);padding:2px calc(var(--mantine-spacing-xs) / 2);border-radius:var(--mantine-radius-sm);font-size:var(--mantine-font-size-xs);margin:0;overflow:auto}:where([data-mantine-color-scheme=light]) .m_b183c0a2{background-color:var(--code-bg, var(--mantine-color-gray-1));color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_b183c0a2{background-color:var(--code-bg, var(--mantine-color-dark-5));color:var(--mantine-color-white)}.m_b183c0a2[data-block]{padding:var(--mantine-spacing-xs)}.m_de3d2490{--cs-size: calc(1.75rem * var(--mantine-scale));--cs-radius: calc(62.5rem * var(--mantine-scale));-webkit-tap-highlight-color:transparent;border:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;display:block;line-height:1;position:relative;width:var(--cs-size);height:var(--cs-size);min-width:var(--cs-size);min-height:var(--cs-size);border-radius:var(--cs-radius);color:inherit;text-decoration:none}[data-mantine-color-scheme=light] .m_de3d2490{--alpha-overlay-color: var(--mantine-color-gray-3);--alpha-overlay-bg: var(--mantine-color-white)}[data-mantine-color-scheme=dark] .m_de3d2490{--alpha-overlay-color: var(--mantine-color-dark-4);--alpha-overlay-bg: var(--mantine-color-dark-7)}.m_862f3d1b{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:var(--cs-radius)}.m_98ae7f22{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:var(--cs-radius);z-index:1;box-shadow:#0000001a 0 0 0 calc(.0625rem * var(--mantine-scale)) inset,#00000026 0 0 calc(.25rem * var(--mantine-scale)) inset}.m_95709ac0{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:var(--cs-radius);background-size:calc(.5rem * var(--mantine-scale)) calc(.5rem * var(--mantine-scale));background-position:0 0,0 calc(.25rem * var(--mantine-scale)),calc(.25rem * var(--mantine-scale)) calc(-.25rem * var(--mantine-scale)),calc(-.25rem * var(--mantine-scale)) 0;background-image:linear-gradient(45deg,var(--alpha-overlay-color) 25%,transparent 25%),linear-gradient(-45deg,var(--alpha-overlay-color) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--alpha-overlay-color) 75%),linear-gradient(-45deg,var(--alpha-overlay-bg) 75%,var(--alpha-overlay-color) 75%)}.m_93e74e3{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:var(--cs-radius);z-index:2;display:flex;align-items:center;justify-content:center}.m_fee9c77{--cp-width-xs: calc(11.25rem * var(--mantine-scale));--cp-width-sm: calc(12.5rem * var(--mantine-scale));--cp-width-md: calc(15rem * var(--mantine-scale));--cp-width-lg: calc(17.5rem * var(--mantine-scale));--cp-width-xl: calc(20rem * var(--mantine-scale));--cp-preview-size-xs: calc(1.625rem * var(--mantine-scale));--cp-preview-size-sm: calc(2.125rem * var(--mantine-scale));--cp-preview-size-md: calc(2.625rem * var(--mantine-scale));--cp-preview-size-lg: calc(3.125rem * var(--mantine-scale));--cp-preview-size-xl: calc(3.375rem * var(--mantine-scale));--cp-thumb-size-xs: calc(.5rem * var(--mantine-scale));--cp-thumb-size-sm: calc(.75rem * var(--mantine-scale));--cp-thumb-size-md: calc(1rem * var(--mantine-scale));--cp-thumb-size-lg: calc(1.25rem * var(--mantine-scale));--cp-thumb-size-xl: calc(1.375rem * var(--mantine-scale));--cp-saturation-height-xs: calc(6.25rem * var(--mantine-scale));--cp-saturation-height-sm: calc(6.875rem * var(--mantine-scale));--cp-saturation-height-md: calc(7.5rem * var(--mantine-scale));--cp-saturation-height-lg: calc(8.75rem * var(--mantine-scale));--cp-saturation-height-xl: calc(10rem * var(--mantine-scale));--cp-preview-size: var(--cp-preview-size-sm);--cp-thumb-size: var(--cp-thumb-size-sm);--cp-saturation-height: var(--cp-saturation-height-sm);--cp-width: var(--cp-width-sm);--cp-body-spacing: var(--mantine-spacing-sm);width:var(--cp-width);padding:calc(.0625rem * var(--mantine-scale))}.m_fee9c77:where([data-full-width]){width:100%}.m_9dddfbac{width:var(--cp-preview-size);height:var(--cp-preview-size)}.m_bffecc3e{display:flex;padding-top:calc(var(--cp-body-spacing) / 2)}.m_3283bb96{flex:1}.m_3283bb96:not(:only-child){margin-inline-end:var(--mantine-spacing-xs)}.m_40d572ba{overflow:hidden;position:absolute;box-shadow:0 0 1px #0009;border:2px solid var(--mantine-color-white);width:var(--cp-thumb-size);height:var(--cp-thumb-size);border-radius:var(--cp-thumb-size);left:calc(var(--thumb-x-offset) - var(--cp-thumb-size) / 2);top:calc(var(--thumb-y-offset) - var(--cp-thumb-size) / 2)}.m_d8ee6fd8{height:unset!important;width:unset!important;min-width:0!important;min-height:0!important;margin:calc(.125rem * var(--mantine-scale));cursor:pointer;padding-bottom:calc(var(--cp-swatch-size) - calc(.25rem * var(--mantine-scale)));flex:0 0 calc(var(--cp-swatch-size) - calc(.25rem * var(--mantine-scale)))}.m_5711e686{margin-top:calc(.3125rem * var(--mantine-scale));margin-inline:calc(-.125rem * var(--mantine-scale));display:flex;flex-wrap:wrap}.m_202a296e{--cp-thumb-size-xs: calc(.5rem * var(--mantine-scale));--cp-thumb-size-sm: calc(.75rem * var(--mantine-scale));--cp-thumb-size-md: calc(1rem * var(--mantine-scale));--cp-thumb-size-lg: calc(1.25rem * var(--mantine-scale));--cp-thumb-size-xl: calc(1.375rem * var(--mantine-scale));-webkit-tap-highlight-color:transparent;position:relative;height:var(--cp-saturation-height);border-radius:var(--mantine-radius-sm);margin:calc(var(--cp-thumb-size) / 2)}.m_202a296e:where([data-focus-ring=auto]):focus:focus-visible .m_40d572ba{outline:2px solid var(--mantine-color-blue-filled)}.m_202a296e:where([data-focus-ring=always]):focus .m_40d572ba{outline:2px solid var(--mantine-color-blue-filled)}.m_11b3db02{position:absolute;border-radius:var(--mantine-radius-sm);inset:calc(var(--cp-thumb-size) * -1 / 2 - calc(.0625rem * var(--mantine-scale)))}.m_d856d47d{--cp-thumb-size-xs: calc(.5rem * var(--mantine-scale));--cp-thumb-size-sm: calc(.75rem * var(--mantine-scale));--cp-thumb-size-md: calc(1rem * var(--mantine-scale));--cp-thumb-size-lg: calc(1.25rem * var(--mantine-scale));--cp-thumb-size-xl: calc(1.375rem * var(--mantine-scale));--cp-thumb-size: var(--cp-thumb-size, calc(.75rem * var(--mantine-scale)));position:relative;height:calc(var(--cp-thumb-size) + calc(.125rem * var(--mantine-scale)));margin-inline:calc(var(--cp-thumb-size) / 2);outline:none}.m_d856d47d+.m_d856d47d{margin-top:calc(.375rem * var(--mantine-scale))}.m_d856d47d:where([data-focus-ring=auto]):focus:focus-visible .m_40d572ba{outline:2px solid var(--mantine-color-blue-filled)}.m_d856d47d:where([data-focus-ring=always]):focus .m_40d572ba{outline:2px solid var(--mantine-color-blue-filled)}:where([data-mantine-color-scheme=light]) .m_d856d47d{--slider-checkers: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_d856d47d{--slider-checkers: var(--mantine-color-dark-4)}.m_8f327113{position:absolute;top:0;bottom:0;inset-inline:calc(var(--cp-thumb-size) * -1 / 2 - calc(.0625rem * var(--mantine-scale)));border-radius:10000rem}.m_b077c2bc{--ci-eye-dropper-icon-size-xs: calc(.875rem * var(--mantine-scale));--ci-eye-dropper-icon-size-sm: calc(1rem * var(--mantine-scale));--ci-eye-dropper-icon-size-md: calc(1.125rem * var(--mantine-scale));--ci-eye-dropper-icon-size-lg: calc(1.25rem * var(--mantine-scale));--ci-eye-dropper-icon-size-xl: calc(1.375rem * var(--mantine-scale));--ci-eye-dropper-icon-size: var(--ci-eye-dropper-icon-size-sm)}.m_c5ccdcab{--ci-preview-size-xs: calc(1rem * var(--mantine-scale));--ci-preview-size-sm: calc(1.125rem * var(--mantine-scale));--ci-preview-size-md: calc(1.375rem * var(--mantine-scale));--ci-preview-size-lg: calc(1.75rem * var(--mantine-scale));--ci-preview-size-xl: calc(2.25rem * var(--mantine-scale));--ci-preview-size: var(--ci-preview-size-sm)}.m_5ece2cd7{padding:calc(.5rem * var(--mantine-scale))}.m_7485cace{--container-size-xs: calc(33.75rem * var(--mantine-scale));--container-size-sm: calc(45rem * var(--mantine-scale));--container-size-md: calc(60rem * var(--mantine-scale));--container-size-lg: calc(71.25rem * var(--mantine-scale));--container-size-xl: calc(82.5rem * var(--mantine-scale));--container-size: var(--container-size-md);max-width:var(--container-size);padding-inline:var(--mantine-spacing-md);margin-inline:auto}.m_7485cace:where([data-fluid]){max-width:100%}.m_e2125a27{--dialog-size-xs: calc(10rem * var(--mantine-scale));--dialog-size-sm: calc(12.5rem * var(--mantine-scale));--dialog-size-md: calc(21.25rem * var(--mantine-scale));--dialog-size-lg: calc(25rem * var(--mantine-scale));--dialog-size-xl: calc(31.25rem * var(--mantine-scale));--dialog-size: var(--dialog-size-md);position:relative;width:var(--dialog-size);max-width:calc(100vw - var(--mantine-spacing-xl) * 2);min-height:calc(3.125rem * var(--mantine-scale))}.m_5abab665{position:absolute;top:calc(var(--mantine-spacing-md) / 2);inset-inline-end:calc(var(--mantine-spacing-md) / 2)}.m_3eebeb36{--divider-size-xs: calc(.0625rem * var(--mantine-scale));--divider-size-sm: calc(.125rem * var(--mantine-scale));--divider-size-md: calc(.1875rem * var(--mantine-scale));--divider-size-lg: calc(.25rem * var(--mantine-scale));--divider-size-xl: calc(.3125rem * var(--mantine-scale));--divider-size: var(--divider-size-xs)}:where([data-mantine-color-scheme=light]) .m_3eebeb36{--divider-color: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_3eebeb36{--divider-color: var(--mantine-color-dark-4)}.m_3eebeb36:where([data-orientation=horizontal]){border-top:var(--divider-size) var(--divider-border-style, solid) var(--divider-color)}.m_3eebeb36:where([data-orientation=vertical]){border-inline-start:var(--divider-size) var(--divider-border-style, solid) var(--divider-color);height:auto;align-self:stretch}.m_3eebeb36:where([data-with-label]){border:0}.m_9e365f20{display:flex;align-items:center;font-size:var(--mantine-font-size-xs);color:var(--mantine-color-dimmed);white-space:nowrap}.m_9e365f20:where([data-position=left]):before{display:none}.m_9e365f20:where([data-position=right]):after{display:none}.m_9e365f20:before{content:"";flex:1;height:calc(.0625rem * var(--mantine-scale));border-top:var(--divider-size) var(--divider-border-style, solid) var(--divider-color);margin-inline-end:var(--mantine-spacing-xs)}.m_9e365f20:after{content:"";flex:1;height:calc(.0625rem * var(--mantine-scale));border-top:var(--divider-size) var(--divider-border-style, solid) var(--divider-color);margin-inline-start:var(--mantine-spacing-xs)}.m_f11b401e{--drawer-size-xs: calc(20rem * var(--mantine-scale));--drawer-size-sm: calc(23.75rem * var(--mantine-scale));--drawer-size-md: calc(27.5rem * var(--mantine-scale));--drawer-size-lg: calc(38.75rem * var(--mantine-scale));--drawer-size-xl: calc(48.75rem * var(--mantine-scale));--drawer-size: var(--drawer-size-md);--drawer-offset: 0rem}.m_5a7c2c9{z-index:1000}.m_b8a05bbd{flex:var(--drawer-flex, 0 0 var(--drawer-size));height:var(--drawer-height, calc(100% - var(--drawer-offset) * 2));margin:var(--drawer-offset);max-width:100%;max-height:100%;overflow-y:auto}.m_31cd769a{display:flex;justify-content:var(--drawer-justify, flex-start);align-items:var(--drawer-align, flex-start)}.m_e9408a47{padding:var(--mantine-spacing-lg);padding-top:var(--mantine-spacing-xs);border-radius:var(--fieldset-radius, var(--mantine-radius-default));min-inline-size:auto}.m_84c9523a{border:calc(.0625rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_84c9523a{border-color:var(--mantine-color-gray-3);background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_84c9523a{border-color:var(--mantine-color-dark-4);background-color:var(--mantine-color-dark-7)}.m_ef274e49{border:calc(.0625rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_ef274e49{border-color:var(--mantine-color-gray-3);background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_ef274e49{border-color:var(--mantine-color-dark-4);background-color:var(--mantine-color-dark-6)}.m_eda993d3{padding:0;border:0;border-radius:0}.m_90794832{font-size:var(--mantine-font-size-sm)}.m_74ca27fe{padding:0;margin-bottom:var(--mantine-spacing-sm)}.m_410352e9{--grid-overflow: visible;--grid-margin: calc(var(--grid-gutter) / -2);--grid-col-padding: calc(var(--grid-gutter) / 2);overflow:var(--grid-overflow)}.m_dee7bd2f{width:calc(100% + var(--grid-gutter));display:flex;flex-wrap:wrap;justify-content:var(--grid-justify);align-items:var(--grid-align);margin:var(--grid-margin)}.m_96bdd299{--col-flex-grow: 0;--col-offset: 0rem;flex-shrink:0;order:var(--col-order);flex-basis:var(--col-flex-basis);width:var(--col-width);max-width:var(--col-max-width);flex-grow:var(--col-flex-grow);margin-inline-start:var(--col-offset);padding:var(--grid-col-padding)}.m_bcb3f3c2{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=light]) .m_bcb3f3c2{background-color:var(--mark-bg-light)}:where([data-mantine-color-scheme=dark]) .m_bcb3f3c2{background-color:var(--mark-bg-dark)}.m_9e117634{display:block;flex:0;object-fit:var(--image-object-fit, cover);width:100%;border-radius:var(--image-radius, 0)}@keyframes m_885901b1{0%{opacity:.6;transform:scale(0)}to{opacity:0;transform:scale(2.8)}}.m_e5262200{--indicator-size: calc(.625rem * var(--mantine-scale));--indicator-color: var(--mantine-primary-color-filled);position:relative;display:block}.m_e5262200:where([data-inline]){display:inline-block}.m_760d1fb1{position:absolute;top:var(--indicator-top);left:var(--indicator-left);right:var(--indicator-right);bottom:var(--indicator-bottom);transform:translate(var(--indicator-translate-x),var(--indicator-translate-y));min-width:var(--indicator-size);height:var(--indicator-size);border-radius:var(--indicator-radius, 1000rem);z-index:var(--indicator-z-index, 200);display:flex;align-items:center;justify-content:center;font-size:var(--mantine-font-size-xs);background-color:var(--indicator-color);color:var(--indicator-text-color, var(--mantine-color-white));white-space:nowrap}.m_760d1fb1:before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;background-color:var(--indicator-color);border-radius:var(--indicator-radius, 1000rem);z-index:-1}.m_760d1fb1:where([data-with-label]){padding-inline:calc(var(--mantine-spacing-xs) / 2)}.m_760d1fb1:where([data-with-border]){border:2px solid var(--mantine-color-body)}.m_760d1fb1[data-processing]:before{animation:m_885901b1 1s linear infinite}.m_dc6f14e2{--kbd-fz-xs: calc(.625rem * var(--mantine-scale));--kbd-fz-sm: calc(.75rem * var(--mantine-scale));--kbd-fz-md: calc(.875rem * var(--mantine-scale));--kbd-fz-lg: calc(1rem * var(--mantine-scale));--kbd-fz-xl: calc(1.25rem * var(--mantine-scale));--kbd-fz: var(--kbd-fz-sm);--kbd-padding-xs: calc(.125rem * var(--mantine-scale)) calc(.25rem * var(--mantine-scale));--kbd-padding-sm: calc(.1875rem * var(--mantine-scale)) calc(.3125rem * var(--mantine-scale));--kbd-padding-md: calc(.25rem * var(--mantine-scale)) calc(.4375rem * var(--mantine-scale));--kbd-padding-lg: calc(.3125rem * var(--mantine-scale)) calc(.5625rem * var(--mantine-scale));--kbd-padding-xl: calc(.5rem * var(--mantine-scale)) calc(.875rem * var(--mantine-scale));--kbd-padding: var(--kbd-padding-sm);font-family:var(--mantine-font-family-monospace);line-height:var(--mantine-line-height);font-weight:700;padding:var(--kbd-padding);font-size:var(--kbd-fz);border-radius:var(--mantine-radius-sm);border:calc(.0625rem * var(--mantine-scale)) solid;border-bottom-width:calc(.1875rem * var(--mantine-scale));unicode-bidi:embed}:where([data-mantine-color-scheme=light]) .m_dc6f14e2{border-color:var(--mantine-color-gray-3);color:var(--mantine-color-gray-7);background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_dc6f14e2{border-color:var(--mantine-color-dark-4);color:var(--mantine-color-dark-0);background-color:var(--mantine-color-dark-6)}.m_abbac491{--list-fz: var(--mantine-font-size-md);--list-lh: var(--mantine-line-height-md);list-style-position:inside;font-size:var(--list-fz);line-height:var(--list-lh);margin:0;padding:0}.m_abbac491:where([data-with-padding]){padding-inline-start:var(--mantine-spacing-md)}.m_abb6bec2{white-space:nowrap;line-height:var(--list-lh)}.m_abb6bec2:where([data-with-icon]){list-style:none}.m_abb6bec2:where([data-with-icon]) .m_75cd9f71{--li-direction: row;--li-align: center}.m_abb6bec2:where(:not(:first-of-type)){margin-top:var(--list-spacing, 0)}.m_abb6bec2:where([data-centered]){line-height:1}.m_75cd9f71{display:inline-flex;flex-direction:var(--li-direction, column);align-items:var(--li-align, flex-start);white-space:normal}.m_60f83e5b{display:inline-block;vertical-align:middle;margin-inline-end:var(--mantine-spacing-sm)}.m_6e45937b{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;overflow:hidden;z-index:var(--lo-z-index)}.m_e8eb006c{position:relative;z-index:calc(var(--lo-z-index) + 1)}.m_df587f17{z-index:var(--lo-z-index)}.m_dc9b7c9f{padding:calc(.25rem * var(--mantine-scale))}.m_9bfac126{color:var(--mantine-color-dimmed);font-weight:500;font-size:var(--mantine-font-size-xs);padding:calc(var(--mantine-spacing-xs) / 2) var(--mantine-spacing-sm);cursor:default}.m_efdf90cb{margin-top:calc(.25rem * var(--mantine-scale));margin-bottom:calc(.25rem * var(--mantine-scale));border-top:calc(.0625rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_efdf90cb{border-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_efdf90cb{border-color:var(--mantine-color-dark-4)}.m_99ac2aa1{font-size:var(--mantine-font-size-sm);width:100%;padding:calc(var(--mantine-spacing-xs) / 1.5) var(--mantine-spacing-sm);border-radius:var(--popover-radius, var(--mantine-radius-default));color:var(--menu-item-color, var(--mantine-color-text));display:flex;align-items:center;-webkit-user-select:none;user-select:none}.m_99ac2aa1:where([data-disabled],:disabled){color:var(--mantine-color-dimmed);opacity:.6;pointer-events:none}:where([data-mantine-color-scheme=light]) .m_99ac2aa1:where([data-hovered]){background-color:var(--menu-item-hover, var(--mantine-color-gray-1))}:where([data-mantine-color-scheme=dark]) .m_99ac2aa1:where([data-hovered]){background-color:var(--menu-item-hover, var(--mantine-color-dark-4))}.m_5476e0d3{flex:1}.m_8b75e504{display:flex;justify-content:center;align-items:center}.m_8b75e504:where([data-position=left]){margin-inline-end:var(--mantine-spacing-xs)}.m_8b75e504:where([data-position=right]){margin-inline-start:var(--mantine-spacing-xs)}.m_9df02822{--modal-size-xs: calc(20rem * var(--mantine-scale));--modal-size-sm: calc(23.75rem * var(--mantine-scale));--modal-size-md: calc(27.5rem * var(--mantine-scale));--modal-size-lg: calc(38.75rem * var(--mantine-scale));--modal-size-xl: calc(48.75rem * var(--mantine-scale));--modal-size: var(--modal-size-md);--modal-y-offset: 5dvh;--modal-x-offset: 5vw}.m_9df02822[data-full-screen]{--modal-border-radius: 0 !important}.m_9df02822[data-full-screen] .m_54c44539{--modal-content-flex: 0 0 100%;--modal-content-max-height: auto;--modal-content-height: 100dvh}.m_9df02822[data-full-screen] .m_1f958f16{--modal-inner-y-offset: 0;--modal-inner-x-offset: 0}.m_9df02822[data-centered] .m_1f958f16{--modal-inner-align: center}.m_d0e2b9cd{border-start-start-radius:var(--modal-radius, var(--mantine-radius-default));border-start-end-radius:var(--modal-radius, var(--mantine-radius-default))}.m_54c44539{flex:var(--modal-content-flex, 0 0 var(--modal-size));max-width:100%;max-height:var(--modal-content-max-height, calc(100dvh - var(--modal-y-offset) * 2));height:var(--modal-content-height, auto);overflow-y:auto}.m_54c44539[data-full-screen]{border-radius:0}.m_1f958f16{display:flex;justify-content:center;align-items:var(--modal-inner-align, flex-start);padding-top:var(--modal-inner-y-offset, var(--modal-y-offset));padding-bottom:var(--modal-inner-y-offset, var(--modal-y-offset));padding-inline:var(--modal-inner-x-offset, var(--modal-x-offset))}.m_7cda1cd6{--pill-fz-xs: calc(.625rem * var(--mantine-scale));--pill-fz-sm: calc(.75rem * var(--mantine-scale));--pill-fz-md: calc(.875rem * var(--mantine-scale));--pill-fz-lg: calc(1rem * var(--mantine-scale));--pill-fz-xl: calc(1.125rem * var(--mantine-scale));--pill-height-xs: calc(1.125rem * var(--mantine-scale));--pill-height-sm: calc(1.375rem * var(--mantine-scale));--pill-height-md: calc(1.5625rem * var(--mantine-scale));--pill-height-lg: calc(1.75rem * var(--mantine-scale));--pill-height-xl: calc(2rem * var(--mantine-scale));--pill-fz: var(--pill-fz-sm);--pill-height: var(--pill-height-sm);font-size:var(--pill-fz);flex:0;height:var(--pill-height);padding-inline:.8em;display:inline-flex;align-items:center;border-radius:var(--pill-radius, 1000rem);line-height:1;white-space:nowrap;user-select:none;-webkit-user-select:none;max-width:100%}:where([data-mantine-color-scheme=dark]) .m_7cda1cd6{background-color:var(--mantine-color-dark-7);color:var(--mantine-color-dark-0)}:where([data-mantine-color-scheme=light]) .m_7cda1cd6{color:var(--mantine-color-black)}.m_7cda1cd6:where([data-with-remove]:not(:has(button:disabled))){padding-inline-end:0}.m_7cda1cd6:where([data-disabled],:has(button:disabled)){cursor:not-allowed}:where([data-mantine-color-scheme=light]) .m_44da308b{background-color:var(--mantine-color-gray-1)}:where([data-mantine-color-scheme=light]) .m_44da308b:where([data-disabled],:has(button:disabled)){background-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=light]) .m_e3a01f8{background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=light]) .m_e3a01f8:where([data-disabled],:has(button:disabled)){background-color:var(--mantine-color-gray-3)}.m_1e0e6180{cursor:inherit;overflow:hidden;height:100%;line-height:var(--pill-height);text-overflow:ellipsis}.m_ae386778{color:inherit;font-size:inherit;height:100%;min-height:unset;min-width:2em;width:unset;border-radius:0;padding-inline-start:.1em;padding-inline-end:.3em;flex:0}.m_7cda1cd6[data-disabled]>.m_ae386778,.m_ae386778:disabled{display:none;background-color:transparent;width:.8em;min-width:.8em;padding:0;cursor:not-allowed}.m_7cda1cd6[data-disabled]>.m_ae386778>svg,.m_ae386778:disabled>svg{display:none}.m_ae386778>svg{pointer-events:none}.m_1dcfd90b{--pg-gap-xs: calc(.375rem * var(--mantine-scale));--pg-gap-sm: calc(.5rem * var(--mantine-scale));--pg-gap-md: calc(.625rem * var(--mantine-scale));--pg-gap-lg: calc(.75rem * var(--mantine-scale));--pg-gap-xl: calc(.75rem * var(--mantine-scale));--pg-gap: var(--pg-gap-sm);display:flex;align-items:center;gap:var(--pg-gap);flex-wrap:wrap}.m_45c4369d{background-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none;min-width:calc(6.25rem * var(--mantine-scale));flex:1;border:0;font-size:inherit;height:1.6em;color:inherit;padding:0}.m_45c4369d::placeholder{color:var(--input-placeholder-color);opacity:1}.m_45c4369d:where([data-type=hidden],[data-type=auto]){height:calc(.0625rem * var(--mantine-scale));width:calc(.0625rem * var(--mantine-scale));top:0;left:0;pointer-events:none;position:absolute;opacity:0}.m_45c4369d:focus{outline:none}.m_45c4369d:where([data-type=auto]:focus){height:1.6em;visibility:visible;opacity:1;position:static}.m_45c4369d:where([data-pointer]:not([data-disabled],:disabled)){cursor:pointer}.m_45c4369d:where([data-disabled],:disabled){cursor:not-allowed}.m_f0824112{--nl-bg: var(--mantine-primary-color-light);--nl-hover: var(--mantine-primary-color-light-hover);--nl-color: var(--mantine-primary-color-light-color);display:flex;align-items:center;width:100%;padding:8px var(--mantine-spacing-sm);-webkit-user-select:none;user-select:none}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_f0824112:hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_f0824112:hover{background-color:var(--mantine-color-dark-6)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_f0824112:active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_f0824112:active{background-color:var(--mantine-color-dark-6)}}.m_f0824112:where([data-disabled]){opacity:.4;pointer-events:none}.m_f0824112:where([data-active]){background-color:var(--nl-bg);color:var(--nl-color)}@media (hover: hover){.m_f0824112:where([data-active]):hover{background-color:var(--nl-hover)}}@media (hover: none){.m_f0824112:where([data-active]):active{background-color:var(--nl-hover)}}.m_f0824112:where([data-active]) .m_57492dcc{--description-opacity: .9;--description-color: var(--nl-color)}.m_690090b5{display:flex;align-items:center;justify-content:center;transition:transform .15s ease}.m_690090b5>svg{display:block}.m_690090b5:where([data-position=left]){margin-inline-end:var(--mantine-spacing-sm)}.m_690090b5:where([data-position=right]){margin-inline-start:var(--mantine-spacing-sm)}.m_690090b5:where([data-rotate]){transform:rotate(90deg)}.m_1f6ac4c4{font-size:var(--mantine-font-size-sm)}.m_f07af9d2{flex:1;overflow:hidden;text-overflow:ellipsis}.m_f07af9d2:where([data-no-wrap]){white-space:nowrap}.m_57492dcc{display:block;font-size:var(--mantine-font-size-xs);opacity:var(--description-opacity, 1);color:var(--description-color, var(--mantine-color-dimmed));overflow:hidden;text-overflow:ellipsis}:where([data-no-wrap]) .m_57492dcc{white-space:nowrap}.m_e17b862f{padding-inline-start:var(--nl-offset, var(--mantine-spacing-lg))}.m_1fd8a00b{transform:rotate(-90deg)}.m_a513464{--notification-radius: var(--mantine-radius-default);--notification-color: var(--mantine-primary-color-filled);overflow:hidden;box-sizing:border-box;position:relative;display:flex;align-items:center;padding-inline-start:calc(1.375rem * var(--mantine-scale));padding-inline-end:var(--mantine-spacing-xs);padding-top:var(--mantine-spacing-xs);padding-bottom:var(--mantine-spacing-xs);border-radius:var(--notification-radius);box-shadow:var(--mantine-shadow-lg)}.m_a513464:before{content:"";display:block;position:absolute;width:calc(.375rem * var(--mantine-scale));top:var(--notification-radius);bottom:var(--notification-radius);inset-inline-start:calc(.25rem * var(--mantine-scale));border-radius:var(--notification-radius);background-color:var(--notification-color)}:where([data-mantine-color-scheme=light]) .m_a513464{background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_a513464{background-color:var(--mantine-color-dark-6)}.m_a513464:where([data-with-icon]){padding-inline-start:var(--mantine-spacing-xs)}.m_a513464:where([data-with-icon]):before{display:none}:where([data-mantine-color-scheme=light]) .m_a513464:where([data-with-border]){border:1px solid var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_a513464:where([data-with-border]){border:1px solid var(--mantine-color-dark-4)}.m_a4ceffb{box-sizing:border-box;margin-inline-end:var(--mantine-spacing-md);width:calc(1.75rem * var(--mantine-scale));height:calc(1.75rem * var(--mantine-scale));border-radius:calc(1.75rem * var(--mantine-scale));display:flex;align-items:center;justify-content:center;background-color:var(--notification-color);color:var(--mantine-color-white)}.m_b0920b15{margin-inline-end:var(--mantine-spacing-md)}.m_a49ed24{flex:1;overflow:hidden;margin-inline-end:var(--mantine-spacing-xs)}.m_3feedf16{margin-bottom:calc(.125rem * var(--mantine-scale));overflow:hidden;text-overflow:ellipsis;font-size:var(--mantine-font-size-sm);line-height:var(--mantine-line-height-sm);font-weight:500}:where([data-mantine-color-scheme=light]) .m_3feedf16{color:var(--mantine-color-gray-9)}:where([data-mantine-color-scheme=dark]) .m_3feedf16{color:var(--mantine-color-white)}.m_3d733a3a{font-size:var(--mantine-font-size-sm);line-height:var(--mantine-line-height-sm);overflow:hidden;text-overflow:ellipsis}:where([data-mantine-color-scheme=light]) .m_3d733a3a{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_3d733a3a{color:var(--mantine-color-dark-0)}:where([data-mantine-color-scheme=light]) .m_3d733a3a:where([data-with-title]){color:var(--mantine-color-gray-6)}:where([data-mantine-color-scheme=dark]) .m_3d733a3a:where([data-with-title]){color:var(--mantine-color-dark-2)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_919a4d88:hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_919a4d88:hover{background-color:var(--mantine-color-dark-8)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_919a4d88:active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_919a4d88:active{background-color:var(--mantine-color-dark-8)}}.m_e2f5cd4e{--ni-right-section-width-xs: calc(1.0625rem * var(--mantine-scale));--ni-right-section-width-sm: calc(1.5rem * var(--mantine-scale));--ni-right-section-width-md: calc(1.6875rem * var(--mantine-scale));--ni-right-section-width-lg: calc(1.9375rem * var(--mantine-scale));--ni-right-section-width-xl: calc(2.125rem * var(--mantine-scale))}.m_95e17d22{--ni-chevron-size-xs: calc(.625rem * var(--mantine-scale));--ni-chevron-size-sm: calc(.875rem * var(--mantine-scale));--ni-chevron-size-md: calc(1rem * var(--mantine-scale));--ni-chevron-size-lg: calc(1.125rem * var(--mantine-scale));--ni-chevron-size-xl: calc(1.25rem * var(--mantine-scale));--ni-chevron-size: var(--ni-chevron-size-sm);display:flex;flex-direction:column;width:100%;height:calc(var(--input-height) - calc(.125rem * var(--mantine-scale)));max-width:calc(var(--ni-chevron-size) * 1.7);margin-inline-start:auto}.m_80b4b171{--control-border: 1px solid var(--input-bd);--control-radius: calc(var(--input-radius) - calc(.0625rem * var(--mantine-scale)));flex:0 0 50%;width:100%;padding:0;height:calc(var(--input-height) / 2 - calc(.0625rem * var(--mantine-scale)));border-inline-start:var(--control-border);display:flex;align-items:center;justify-content:center;color:var(--mantine-color-text);background-color:transparent;cursor:pointer}.m_80b4b171:where(:disabled){background-color:transparent;cursor:not-allowed;opacity:.6}:where([data-mantine-color-scheme=light]) .m_80b4b171:where(:disabled){color:var(--mantine-color-gray-4)}:where([data-mantine-color-scheme=dark]) .m_80b4b171:where(:disabled){color:var(--mantine-color-dark-3)}.m_e2f5cd4e[data-error] :where(.m_80b4b171){color:var(--mantine-color-error)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_80b4b171:hover{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_80b4b171:hover{background-color:var(--mantine-color-dark-4)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_80b4b171:active{background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_80b4b171:active{background-color:var(--mantine-color-dark-4)}}.m_80b4b171:where(:first-of-type){border-radius:0;border-start-end-radius:var(--control-radius)}.m_80b4b171:last-of-type{border-top:1 solid var(--input-bd);border-radius:0;border-end-end-radius:var(--control-radius)}.m_4addd315{--pagination-control-size-xs: calc(1.375rem * var(--mantine-scale));--pagination-control-size-sm: calc(1.625rem * var(--mantine-scale));--pagination-control-size-md: calc(2rem * var(--mantine-scale));--pagination-control-size-lg: calc(2.375rem * var(--mantine-scale));--pagination-control-size-xl: calc(2.75rem * var(--mantine-scale));--pagination-control-size: var(--pagination-control-size-md);--pagination-control-fz: var(--mantine-font-size-md);--pagination-active-bg: var(--mantine-primary-color-filled)}.m_326d024a{display:flex;align-items:center;justify-content:center;border:calc(.0625rem * var(--mantine-scale)) solid;cursor:pointer;color:var(--mantine-color-text);height:var(--pagination-control-size);min-width:var(--pagination-control-size);font-size:var(--pagination-control-fz);line-height:1;border-radius:var(--pagination-control-radius, var(--mantine-radius-default))}.m_326d024a:where([data-with-padding]){padding:calc(var(--pagination-control-size) / 4)}.m_326d024a:where(:disabled,[data-disabled]){cursor:not-allowed;opacity:.4}:where([data-mantine-color-scheme=light]) .m_326d024a{border-color:var(--mantine-color-gray-4);background-color:var(--mantine-color-white)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_326d024a:hover:where(:not(:disabled,[data-disabled])){background-color:var(--mantine-color-gray-0)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_326d024a:active:where(:not(:disabled,[data-disabled])){background-color:var(--mantine-color-gray-0)}}:where([data-mantine-color-scheme=dark]) .m_326d024a{border-color:var(--mantine-color-dark-4);background-color:var(--mantine-color-dark-6)}@media (hover: hover){:where([data-mantine-color-scheme=dark]) .m_326d024a:hover:where(:not(:disabled,[data-disabled])){background-color:var(--mantine-color-dark-5)}}@media (hover: none){:where([data-mantine-color-scheme=dark]) .m_326d024a:active:where(:not(:disabled,[data-disabled])){background-color:var(--mantine-color-dark-5)}}.m_326d024a:where([data-active]){background-color:var(--pagination-active-bg);border-color:var(--pagination-active-bg);color:var(--pagination-active-color, var(--mantine-color-white))}@media (hover: hover){.m_326d024a:where([data-active]):hover{background-color:var(--pagination-active-bg)}}@media (hover: none){.m_326d024a:where([data-active]):active{background-color:var(--pagination-active-bg)}}.m_4ad7767d{height:var(--pagination-control-size);min-width:var(--pagination-control-size);display:flex;align-items:center;justify-content:center;pointer-events:none}.m_f61ca620{--psi-button-size-xs: calc(1.375rem * var(--mantine-scale));--psi-button-size-sm: calc(1.625rem * var(--mantine-scale));--psi-button-size-md: calc(1.75rem * var(--mantine-scale));--psi-button-size-lg: calc(2rem * var(--mantine-scale));--psi-button-size-xl: calc(2.5rem * var(--mantine-scale));--psi-icon-size-xs: calc(.75rem * var(--mantine-scale));--psi-icon-size-sm: calc(.9375rem * var(--mantine-scale));--psi-icon-size-md: calc(1.0625rem * var(--mantine-scale));--psi-icon-size-lg: calc(1.1875rem * var(--mantine-scale));--psi-icon-size-xl: calc(1.3125rem * var(--mantine-scale));--psi-button-size: var(--psi-button-size-sm);--psi-icon-size: var(--psi-icon-size-sm)}.m_ccf8da4c{position:relative;overflow:hidden}.m_f2d85dd2{font-family:var(--mantine-font-family);background-color:transparent;border:0;padding-inline-end:var(--input-padding-inline-end);padding-inline-start:var(--input-padding-inline-start);position:absolute;top:0;right:0;bottom:0;left:0;outline:0;font-size:inherit;line-height:var(--mantine-line-height);height:100%;width:100%;color:inherit}.m_ccf8da4c[data-disabled] .m_f2d85dd2,.m_f2d85dd2:disabled{cursor:not-allowed}.m_f2d85dd2::placeholder{color:var(--input-placeholder-color);opacity:1}.m_b1072d44{width:var(--psi-button-size);height:var(--psi-button-size);min-width:var(--psi-button-size);min-height:var(--psi-button-size)}.m_b1072d44:disabled{display:none}.m_f1cb205a{--pin-input-size-xs: calc(1.875rem * var(--mantine-scale));--pin-input-size-sm: calc(2.25rem * var(--mantine-scale));--pin-input-size-md: calc(2.625rem * var(--mantine-scale));--pin-input-size-lg: calc(3.125rem * var(--mantine-scale));--pin-input-size-xl: calc(3.75rem * var(--mantine-scale));--pin-input-size: var(--pin-input-size-sm)}.m_cb288ead{width:var(--pin-input-size);height:var(--pin-input-size)}@keyframes m_81a374bd{0%{background-position:0 0}to{background-position:calc(2.5rem * var(--mantine-scale)) 0}}.m_db6d6462{--progress-radius: var(--mantine-radius-default);--progress-size: var(--progress-size-md);--progress-size-xs: calc(.1875rem * var(--mantine-scale));--progress-size-sm: calc(.3125rem * var(--mantine-scale));--progress-size-md: calc(.5rem * var(--mantine-scale));--progress-size-lg: calc(.75rem * var(--mantine-scale));--progress-size-xl: calc(1rem * var(--mantine-scale));position:relative;height:var(--progress-size);border-radius:var(--progress-radius);overflow:hidden;display:flex}:where([data-mantine-color-scheme=light]) .m_db6d6462{background-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_db6d6462{background-color:var(--mantine-color-dark-4)}.m_2242eb65{background-color:var(--progress-section-color);height:100%;width:var(--progress-section-width);display:flex;align-items:center;justify-content:center;overflow:hidden;background-size:calc(1.25rem * var(--mantine-scale)) calc(1.25rem * var(--mantine-scale));transition:width var(--progress-transition-duration, .1s) ease}.m_2242eb65:where([data-striped]){background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.m_2242eb65:where([data-animated]){animation:m_81a374bd 1s linear infinite}.m_2242eb65:where(:last-of-type){border-radius:0;border-start-end-radius:var(--progress-radius);border-end-end-radius:var(--progress-radius)}.m_2242eb65:where(:first-of-type){border-radius:0;border-start-start-radius:var(--progress-radius);border-end-start-radius:var(--progress-radius)}.m_91e40b74{color:var(--progress-label-color, var(--mantine-color-white));font-weight:700;-webkit-user-select:none;user-select:none;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:min(calc(var(--progress-size) * .65),calc(1.125rem * var(--mantine-scale)));line-height:1;padding-inline:calc(.25rem * var(--mantine-scale))}.m_f3f1af94{--radio-size-xs: calc(1rem * var(--mantine-scale));--radio-size-sm: calc(1.25rem * var(--mantine-scale));--radio-size-md: calc(1.5rem * var(--mantine-scale));--radio-size-lg: calc(1.875rem * var(--mantine-scale));--radio-size-xl: calc(2.25rem * var(--mantine-scale));--radio-size: var(--radio-size-sm);--radio-icon-size-xs: calc(.375rem * var(--mantine-scale));--radio-icon-size-sm: calc(.5rem * var(--mantine-scale));--radio-icon-size-md: calc(.625rem * var(--mantine-scale));--radio-icon-size-lg: calc(.875rem * var(--mantine-scale));--radio-icon-size-xl: calc(1rem * var(--mantine-scale));--radio-icon-size: var(--radio-icon-size-sm);--radio-icon-color: var(--mantine-color-white)}.m_89c4f5e4{position:relative;width:var(--radio-size);height:var(--radio-size);order:1}.m_89c4f5e4:where([data-label-position=left]){order:2}.m_f3ed6b2b{color:var(--radio-icon-color);opacity:var(--radio-icon-opacity, 0);transform:var(--radio-icon-transform, scale(.2) translateY(calc(.625rem * var(--mantine-scale))));transition:opacity .1s ease,transform .2s ease;pointer-events:none;width:var(--radio-icon-size);height:var(--radio-icon-size);position:absolute;top:calc(50% - var(--radio-icon-size) / 2);left:calc(50% - var(--radio-icon-size) / 2)}.m_8a3dbb89{border:calc(.0625rem * var(--mantine-scale)) solid;position:relative;-webkit-appearance:none;-moz-appearance:none;appearance:none;width:var(--radio-size);height:var(--radio-size);border-radius:var(--radio-radius, var(--radio-size));margin:0;display:flex;align-items:center;justify-content:center;transition-property:background-color,border-color;transition-timing-function:ease;transition-duration:.1s;cursor:var(--mantine-cursor-type);-webkit-tap-highlight-color:transparent}:where([data-mantine-color-scheme=light]) .m_8a3dbb89{background-color:var(--mantine-color-white);border-color:var(--mantine-color-gray-4)}:where([data-mantine-color-scheme=dark]) .m_8a3dbb89{background-color:var(--mantine-color-dark-6);border-color:var(--mantine-color-dark-4)}.m_8a3dbb89:checked{background-color:var(--radio-color, var(--mantine-primary-color-filled));border-color:var(--radio-color, var(--mantine-primary-color-filled))}.m_8a3dbb89:checked+.m_f3ed6b2b{--radio-icon-opacity: 1;--radio-icon-transform: scale(1)}.m_8a3dbb89:disabled{cursor:not-allowed}:where([data-mantine-color-scheme=light]) .m_8a3dbb89:disabled{background-color:var(--mantine-color-gray-1);border-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=light]) .m_8a3dbb89:disabled+.m_f3ed6b2b{--radio-icon-color: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_8a3dbb89:disabled{background-color:var(--mantine-color-dark-5);border-color:var(--mantine-color-dark-4)}:where([data-mantine-color-scheme=dark]) .m_8a3dbb89:disabled+.m_f3ed6b2b{--radio-icon-color: var(--mantine-color-dark-7)}.m_8a3dbb89:where([data-error]){border-color:var(--mantine-color-error)}.m_1bfe9d39+.m_f3ed6b2b{--radio-icon-color: var(--radio-color)}.m_1bfe9d39:checked:not(:disabled){background-color:transparent;border-color:var(--radio-color)}.m_1bfe9d39:checked:not(:disabled)+.m_f3ed6b2b{--radio-icon-color: var(--radio-color);--radio-icon-opacity: 1;--radio-icon-transform: none}.m_f8d312f2{--rating-size-xs: calc(.875rem * var(--mantine-scale));--rating-size-sm: calc(1.125rem * var(--mantine-scale));--rating-size-md: calc(1.25rem * var(--mantine-scale));--rating-size-lg: calc(1.75rem * var(--mantine-scale));--rating-size-xl: calc(2rem * var(--mantine-scale));display:flex;width:max-content}.m_f8d312f2:where(:has(input:disabled)){pointer-events:none}.m_61734bb7{position:relative;transition:transform .1s ease}.m_61734bb7:where([data-active]){z-index:1;transform:scale(1.1)}.m_5662a89a{width:var(--rating-size);height:var(--rating-size);display:block}:where([data-mantine-color-scheme=light]) .m_5662a89a{fill:var(--mantine-color-gray-3);stroke:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_5662a89a{fill:var(--mantine-color-dark-3);stroke:var(--mantine-color-dark-3)}.m_5662a89a:where([data-filled]){fill:var(--rating-color);stroke:var(--rating-color)}.m_211007ba{height:0;width:0;position:absolute;overflow:hidden;white-space:nowrap;opacity:0;-webkit-tap-highlight-color:transparent}.m_211007ba:focus-visible+label{outline:2px solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem * var(--mantine-scale))}.m_21342ee4{display:block;cursor:pointer;position:absolute;top:0;left:0;z-index:var(--rating-item-z-index, 0);-webkit-tap-highlight-color:transparent}.m_21342ee4:where([data-read-only]){cursor:default}.m_21342ee4:where(:last-of-type){position:relative}.m_fae05d6a{clip-path:var(--rating-symbol-clip-path)}.m_1b3c8819{--tooltip-radius: var(--mantine-radius-default);position:absolute;padding:calc(var(--mantine-spacing-xs) / 2) var(--mantine-spacing-xs);pointer-events:none;font-size:var(--mantine-font-size-sm);white-space:nowrap;border-radius:var(--tooltip-radius)}:where([data-mantine-color-scheme=light]) .m_1b3c8819{background-color:var(--tooltip-bg, var(--mantine-color-gray-9));color:var(--tooltip-color, var(--mantine-color-white))}:where([data-mantine-color-scheme=dark]) .m_1b3c8819{background-color:var(--tooltip-bg, var(--mantine-color-gray-2));color:var(--tooltip-color, var(--mantine-color-black))}.m_1b3c8819:where([data-multiline]){white-space:normal}.m_f898399f{background-color:inherit;border:0;z-index:1}.m_b32e4812{position:relative;width:var(--rp-size);height:var(--rp-size);min-width:var(--rp-size);min-height:var(--rp-size)}.m_d43b5134{width:var(--rp-size);height:var(--rp-size);min-width:var(--rp-size);min-height:var(--rp-size);transform:rotate(-90deg)}.m_b1ca1fbf{stroke:var(--curve-color, var(--rp-curve-root-color))}[data-mantine-color-scheme=light] .m_b1ca1fbf{--rp-curve-root-color: var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m_b1ca1fbf{--rp-curve-root-color: var(--mantine-color-dark-4)}.m_b23f9dc4{position:absolute;top:50%;transform:translateY(-50%);inset-inline:var(--rp-label-offset)}.m_cf365364{--sc-padding-xs: calc(.1875rem * var(--mantine-scale)) calc(.375rem * var(--mantine-scale));--sc-padding-sm: calc(.3125rem * var(--mantine-scale)) calc(.625rem * var(--mantine-scale));--sc-padding-md: calc(.4375rem * var(--mantine-scale)) calc(.875rem * var(--mantine-scale));--sc-padding-lg: calc(.5625rem * var(--mantine-scale)) calc(1rem * var(--mantine-scale));--sc-padding-xl: calc(.75rem * var(--mantine-scale)) calc(1.25rem * var(--mantine-scale));--sc-transition-duration: .2s;--sc-padding: var(--sc-padding-sm);--sc-transition-timing-function: ease;--sc-font-size: var(--mantine-font-size-sm);position:relative;display:inline-flex;flex-direction:row;width:auto;border-radius:var(--sc-radius, var(--mantine-radius-default));overflow:hidden;padding:calc(.25rem * var(--mantine-scale))}.m_cf365364:where([data-full-width]){display:flex}.m_cf365364:where([data-orientation=vertical]){display:flex;flex-direction:column;width:max-content}.m_cf365364:where([data-orientation=vertical]):where([data-full-width]){width:auto}:where([data-mantine-color-scheme=light]) .m_cf365364{background-color:var(--mantine-color-gray-1)}:where([data-mantine-color-scheme=dark]) .m_cf365364{background-color:var(--mantine-color-dark-8)}.m_9e182ccd{position:absolute;display:block;z-index:1;border-radius:var(--sc-radius, var(--mantine-radius-default))}:where([data-mantine-color-scheme=light]) .m_9e182ccd{box-shadow:var(--sc-shadow, none);background-color:var(--sc-color, var(--mantine-color-white))}:where([data-mantine-color-scheme=dark]) .m_9e182ccd{box-shadow:none;background-color:var(--sc-color, var(--mantine-color-dark-5))}.m_1738fcb2{-webkit-tap-highlight-color:transparent;font-weight:500;display:block;text-align:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;-webkit-user-select:none;user-select:none;border-radius:var(--sc-radius, var(--mantine-radius-default));font-size:var(--sc-font-size);padding:var(--sc-padding);transition:color var(--sc-transition-duration) var(--sc-transition-timing-function);cursor:pointer;outline:var(--segmented-control-outline, none)}:where([data-mantine-color-scheme=light]) .m_1738fcb2{color:var(--mantine-color-gray-7)}:where([data-mantine-color-scheme=dark]) .m_1738fcb2{color:var(--mantine-color-dark-1)}.m_1738fcb2:where([data-read-only]){cursor:default}fieldset:disabled .m_1738fcb2,.m_1738fcb2:where([data-disabled]){cursor:not-allowed}:where([data-mantine-color-scheme=light]) fieldset:disabled .m_1738fcb2,:where([data-mantine-color-scheme=light]) .m_1738fcb2:where([data-disabled]){color:var(--mantine-color-gray-5)}:where([data-mantine-color-scheme=dark]) fieldset:disabled .m_1738fcb2,:where([data-mantine-color-scheme=dark]) .m_1738fcb2:where([data-disabled]){color:var(--mantine-color-dark-3)}:where([data-mantine-color-scheme=light]) .m_1738fcb2:where([data-active]){color:var(--sc-label-color, var(--mantine-color-black))}:where([data-mantine-color-scheme=dark]) .m_1738fcb2:where([data-active]){color:var(--sc-label-color, var(--mantine-color-white))}.m_cf365364:where([data-initialized]) .m_1738fcb2:where([data-active]):before{display:none}.m_1738fcb2:where([data-active]):before{content:"";top:0;right:0;bottom:0;left:0;z-index:0;position:absolute;border-radius:var(--sc-radius, var(--mantine-radius-default))}:where([data-mantine-color-scheme=light]) .m_1738fcb2:where([data-active]):before{box-shadow:var(--sc-shadow, none);background-color:var(--sc-color, var(--mantine-color-white))}:where([data-mantine-color-scheme=dark]) .m_1738fcb2:where([data-active]):before{box-shadow:none;background-color:var(--sc-color, var(--mantine-color-dark-5))}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_1738fcb2:where(:not([data-disabled],[data-active],[data-read-only])):hover{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_1738fcb2:where(:not([data-disabled],[data-active],[data-read-only])):hover{color:var(--mantine-color-white)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_1738fcb2:where(:not([data-disabled],[data-active],[data-read-only])):active{color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_1738fcb2:where(:not([data-disabled],[data-active],[data-read-only])):active{color:var(--mantine-color-white)}}@media (hover: hover){:where([data-mantine-color-scheme=light]) fieldset:disabled .m_1738fcb2:hover{color:var(--mantine-color-gray-5)!important}:where([data-mantine-color-scheme=dark]) fieldset:disabled .m_1738fcb2:hover{color:var(--mantine-color-dark-3)!important}}@media (hover: none){:where([data-mantine-color-scheme=light]) fieldset:disabled .m_1738fcb2:active{color:var(--mantine-color-gray-5)!important}:where([data-mantine-color-scheme=dark]) fieldset:disabled .m_1738fcb2:active{color:var(--mantine-color-dark-3)!important}}.m_1714d588{height:0;width:0;position:absolute;overflow:hidden;white-space:nowrap;opacity:0}.m_1714d588[data-focus-ring=auto]:focus:focus-visible+.m_1738fcb2{--segmented-control-outline: 2px solid var(--mantine-color-blue-filled)}.m_1714d588[data-focus-ring=always]:focus+.m_1738fcb2{--segmented-control-outline: 2px solid var(--mantine-color-blue-filled)}.m_69686b9b{position:relative;flex:1;z-index:2;transition:border-color var(--sc-transition-duration) var(--sc-transition-timing-function)}.m_cf365364[data-with-items-borders] :where(.m_69686b9b):before{content:"";position:absolute;top:0;bottom:0;inset-inline-start:0;background-color:var(--separator-color);width:calc(.0625rem * var(--mantine-scale));transition:background-color var(--sc-transition-duration) var(--sc-transition-timing-function)}.m_69686b9b[data-orientation=vertical]:before{top:0;inset-inline:0;bottom:auto;height:calc(.0625rem * var(--mantine-scale));width:auto}:where([data-mantine-color-scheme=light]) .m_69686b9b{--separator-color: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_69686b9b{--separator-color: var(--mantine-color-dark-4)}.m_69686b9b:first-of-type:before{--separator-color: transparent}[data-mantine-color-scheme] .m_69686b9b[data-active]:before,[data-mantine-color-scheme] .m_69686b9b[data-active]+.m_69686b9b:before{--separator-color: transparent}.m_78882f40{position:relative;z-index:2}.m_2415a157{display:grid;grid-template-columns:repeat(var(--sg-cols),minmax(0,1fr));gap:var(--sg-spacing-y) var(--sg-spacing-x)}@keyframes m_299c329c{0%,to{opacity:.4}50%{opacity:1}}.m_18320242{height:var(--skeleton-height, auto);width:var(--skeleton-width, 100%);border-radius:var(--skeleton-radius, var(--mantine-radius-default));position:relative;transform:translateZ(0);-webkit-transform:translateZ(0)}.m_18320242:where([data-animate]):after{animation:m_299c329c 1.5s linear infinite}.m_18320242:where([data-visible]){overflow:hidden}.m_18320242:where([data-visible]):before{position:absolute;content:"";top:0;right:0;bottom:0;left:0;z-index:10;background-color:var(--mantine-color-body)}.m_18320242:where([data-visible]):after{position:absolute;content:"";top:0;right:0;bottom:0;left:0;z-index:11}:where([data-mantine-color-scheme=light]) .m_18320242:where([data-visible]):after{background-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_18320242:where([data-visible]):after{background-color:var(--mantine-color-dark-4)}.m_dd36362e{--slider-size-xs: calc(.25rem * var(--mantine-scale));--slider-size-sm: calc(.375rem * var(--mantine-scale));--slider-size-md: calc(.5rem * var(--mantine-scale));--slider-size-lg: calc(.625rem * var(--mantine-scale));--slider-size-xl: calc(.75rem * var(--mantine-scale));--slider-size: var(--slider-size-md);--slider-radius: calc(62.5rem * var(--mantine-scale));--slider-color: var(--mantine-primary-color-filled);-webkit-tap-highlight-color:transparent;outline:none;height:calc(var(--slider-size) * 2);padding-inline:var(--slider-size);display:flex;flex-direction:column;align-items:center;touch-action:none;position:relative}[data-mantine-color-scheme=light] .m_dd36362e{--slider-track-bg: var(--mantine-color-gray-2);--slider-track-disabled-bg: var(--mantine-color-gray-4)}[data-mantine-color-scheme=dark] .m_dd36362e{--slider-track-bg: var(--mantine-color-dark-4);--slider-track-disabled-bg: var(--mantine-color-dark-3)}.m_c9357328{position:absolute;top:calc(-2.25rem * var(--mantine-scale));font-size:var(--mantine-font-size-xs);color:var(--mantine-color-white);padding:calc(var(--mantine-spacing-xs) / 2);border-radius:var(--mantine-radius-sm);white-space:nowrap;pointer-events:none;-webkit-user-select:none;user-select:none;touch-action:none}:where([data-mantine-color-scheme=light]) .m_c9357328{background-color:var(--mantine-color-gray-9)}:where([data-mantine-color-scheme=dark]) .m_c9357328{background-color:var(--mantine-color-dark-4)}.m_c9a9a60a{position:absolute;display:flex;height:var(--slider-thumb-size);width:var(--slider-thumb-size);border:calc(.25rem * var(--mantine-scale)) solid;transform:translate(-50%,-50%);color:var(--slider-color);top:50%;cursor:pointer;border-radius:var(--slider-radius);align-items:center;justify-content:center;transition:box-shadow .1s ease,transform .1s ease;z-index:3;-webkit-user-select:none;user-select:none;touch-action:none;outline-offset:calc(.125rem * var(--mantine-scale));left:var(--slider-thumb-offset)}:where([dir=rtl]) .m_c9a9a60a{left:auto;right:calc(var(--slider-thumb-offset) - var(--slider-thumb-size))}fieldset:disabled .m_c9a9a60a,.m_c9a9a60a:where([data-disabled]){display:none}.m_c9a9a60a:where([data-dragging]){transform:translate(-50%,-50%) scale(1.05);box-shadow:var(--mantine-shadow-sm)}:where([data-mantine-color-scheme=light]) .m_c9a9a60a{border-color:var(--slider-color);background-color:var(--mantine-color-white)}:where([data-mantine-color-scheme=dark]) .m_c9a9a60a{border-color:var(--mantine-color-white);background-color:var(--slider-color)}.m_a8645c2{display:flex;align-items:center;width:100%;height:calc(var(--slider-size) * 2);cursor:pointer}fieldset:disabled .m_a8645c2,.m_a8645c2:where([data-disabled]){cursor:not-allowed}.m_c9ade57f{position:relative;width:100%;height:var(--slider-size)}.m_c9ade57f:where([data-inverted]:not([data-disabled])){--track-bg: var(--slider-color)}fieldset:disabled .m_c9ade57f:where([data-inverted]),.m_c9ade57f:where([data-inverted][data-disabled]){--track-bg: var(--slider-track-disabled-bg)}.m_c9ade57f:before{content:"";position:absolute;top:0;bottom:0;border-radius:var(--slider-radius);inset-inline:calc(var(--slider-size) * -1);background-color:var(--track-bg, var(--slider-track-bg));z-index:0}.m_38aeed47{position:absolute;z-index:1;top:0;bottom:0;background-color:var(--slider-color);border-radius:var(--slider-radius);width:var(--slider-bar-width);inset-inline-start:var(--slider-bar-offset)}.m_38aeed47:where([data-inverted]){background-color:var(--slider-track-bg)}:where([data-mantine-color-scheme=light]) fieldset:disabled .m_38aeed47:where(:not([data-inverted])),:where([data-mantine-color-scheme=light]) .m_38aeed47:where([data-disabled]:not([data-inverted])){background-color:var(--mantine-color-gray-4)}:where([data-mantine-color-scheme=dark]) fieldset:disabled .m_38aeed47:where(:not([data-inverted])),:where([data-mantine-color-scheme=dark]) .m_38aeed47:where([data-disabled]:not([data-inverted])){background-color:var(--mantine-color-dark-3)}.m_b7b0423a{position:absolute;inset-inline-start:calc(var(--mark-offset) - var(--slider-size) / 2);top:0;z-index:2;height:0;pointer-events:none}.m_dd33bc19{border:calc(.125rem * var(--mantine-scale)) solid;height:var(--slider-size);width:var(--slider-size);border-radius:calc(62.5rem * var(--mantine-scale));transform:translate((calc(var(--slider-size) / -2)));background-color:var(--mantine-color-white);pointer-events:none}:where([data-mantine-color-scheme=light]) .m_dd33bc19{border-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_dd33bc19{border-color:var(--mantine-color-dark-4)}.m_dd33bc19:where([data-filled]){border-color:var(--slider-color)}:where([data-mantine-color-scheme=light]) .m_dd33bc19:where([data-filled]):where([data-disabled]){border-color:var(--mantine-color-gray-4)}:where([data-mantine-color-scheme=dark]) .m_dd33bc19:where([data-filled]):where([data-disabled]){border-color:var(--mantine-color-dark-3)}.m_68c77a5b{transform:translate(calc(-50% + var(--slider-size) / 2),calc(var(--mantine-spacing-xs) / 2));font-size:var(--mantine-font-size-sm);white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none}:where([data-mantine-color-scheme=light]) .m_68c77a5b{color:var(--mantine-color-gray-6)}:where([data-mantine-color-scheme=dark]) .m_68c77a5b{color:var(--mantine-color-dark-2)}.m_559cce2d{position:relative}.m_559cce2d:where([data-has-spoiler]){margin-bottom:calc(1.5rem * var(--mantine-scale))}.m_b912df4e{display:flex;flex-direction:column;overflow:hidden;transition:max-height var(--spoiler-transition-duration, .2s) ease}.m_b9131032{position:absolute;inset-inline-start:0;top:100%;height:calc(1.5rem * var(--mantine-scale))}.m_6d731127{display:flex;flex-direction:column;align-items:var(--stack-align, stretch);justify-content:var(--stack-justify, flex-start);gap:var(--stack-gap, var(--mantine-spacing-md))}.m_cbb4ea7e{--stepper-icon-size-xs: calc(2.125rem * var(--mantine-scale));--stepper-icon-size-sm: calc(2.25rem * var(--mantine-scale));--stepper-icon-size-md: calc(2.625rem * var(--mantine-scale));--stepper-icon-size-lg: calc(3rem * var(--mantine-scale));--stepper-icon-size-xl: calc(3.25rem * var(--mantine-scale));--stepper-icon-size: var(--stepper-icon-size-md);--stepper-color: var(--mantine-primary-color-filled);--stepper-content-padding: var(--mantine-spacing-md);--stepper-spacing: var(--mantine-spacing-md);--stepper-radius: calc(62.5rem * var(--mantine-scale));--stepper-fz: var(--mantine-font-size-md)}.m_aaf89d0b{display:flex;flex-wrap:nowrap;align-items:center}.m_aaf89d0b:where([data-wrap]){flex-wrap:wrap;gap:var(--mantine-spacing-md) 0}.m_aaf89d0b:where([data-orientation=vertical]){flex-direction:column}.m_aaf89d0b:where([data-orientation=vertical]):where([data-icon-position=left]){align-items:flex-start}.m_aaf89d0b:where([data-orientation=vertical]):where([data-icon-position=right]){align-items:flex-end}.m_aaf89d0b:where([data-orientation=horizontal]){flex-direction:row}.m_2a371ac9{--separator-offset: calc(var(--stepper-icon-size) / 2 - calc(.0625rem * var(--mantine-scale)));transition:background-color .15s ease;flex:1}:where([data-mantine-color-scheme=light]) .m_2a371ac9{background-color:var(--mantine-color-gray-2)}:where([data-mantine-color-scheme=dark]) .m_2a371ac9{background-color:var(--mantine-color-dark-2)}.m_2a371ac9:where([data-active]){background-color:var(--stepper-color)}.m_2a371ac9:where([data-orientation=horizontal]){height:calc(.125rem * var(--mantine-scale));margin-inline:var(--mantine-spacing-md)}.m_2a371ac9:where([data-orientation=vertical]){width:calc(.125rem * var(--mantine-scale));margin-top:calc(var(--mantine-spacing-xs) / 2);margin-bottom:calc(var(--mantine-spacing-xs) - calc(.125rem * var(--mantine-scale)))}.m_2a371ac9:where([data-orientation=vertical]):where([data-icon-position=left]){margin-inline-start:var(--separator-offset)}.m_2a371ac9:where([data-orientation=vertical]):where([data-icon-position=right]){margin-inline-end:var(--separator-offset)}.m_78da155d{padding-top:var(--stepper-content-padding)}.m_cbb57068{--step-color: var(--stepper-color);display:flex;cursor:default}.m_cbb57068:where([data-allow-click]){cursor:pointer}.m_cbb57068:where([data-icon-position=left]){flex-direction:row}.m_cbb57068:where([data-icon-position=right]){flex-direction:row-reverse}.m_f56b1e2c{align-items:center}.m_833edb7e{--separator-spacing: calc(var(--mantine-spacing-xs) / 2);justify-content:flex-start;min-height:calc(var(--stepper-icon-size) + var(--mantine-spacing-xl) + var(--separator-spacing));margin-top:var(--separator-spacing);overflow:hidden}.m_833edb7e:where(:first-of-type){margin-top:0}.m_833edb7e:where(:last-of-type) .m_6496b3f3{display:none}.m_818e70b{position:relative}.m_6496b3f3{top:calc(var(--stepper-icon-size) + var(--separator-spacing));inset-inline-start:calc(var(--stepper-icon-size) / 2);height:100vh;position:absolute;border-inline-start:calc(.125rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_6496b3f3{border-color:var(--mantine-color-gray-1)}:where([data-mantine-color-scheme=dark]) .m_6496b3f3{border-color:var(--mantine-color-dark-5)}.m_6496b3f3:where([data-active]){border-color:var(--stepper-color)}.m_1959ad01{height:var(--stepper-icon-size);width:var(--stepper-icon-size);min-height:var(--stepper-icon-size);min-width:var(--stepper-icon-size);border-radius:var(--stepper-radius);font-size:var(--stepper-fz);display:flex;align-items:center;justify-content:center;position:relative;font-weight:700;transition:background-color .15s ease,border-color .15s ease;border:calc(.125rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_1959ad01{background-color:var(--mantine-color-gray-1);border-color:var(--mantine-color-gray-1);color:var(--mantine-color-gray-7)}:where([data-mantine-color-scheme=dark]) .m_1959ad01{background-color:var(--mantine-color-dark-5);border-color:var(--mantine-color-dark-5);color:var(--mantine-color-dark-1)}.m_1959ad01:where([data-progress]){border-color:var(--step-color)}.m_1959ad01:where([data-completed]){color:var(--stepper-icon-color, var(--mantine-color-white));background-color:var(--step-color);border-color:var(--step-color)}.m_a79331dc{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;color:var(--stepper-icon-color, var(--mantine-color-white))}.m_1956aa2a{display:flex;flex-direction:column}.m_1956aa2a:where([data-icon-position=left]){margin-inline-start:var(--mantine-spacing-sm)}.m_1956aa2a:where([data-icon-position=right]){text-align:right;margin-inline-end:var(--mantine-spacing-sm)}:where([dir=rtl]) .m_1956aa2a:where([data-icon-position=right]){text-align:left}.m_12051f6c{font-weight:500;font-size:var(--stepper-fz);line-height:1}.m_164eea74{margin-top:calc(var(--stepper-spacing) / 3);margin-bottom:calc(var(--stepper-spacing) / 3);font-size:calc(var(--stepper-fz) - calc(.125rem * var(--mantine-scale)));line-height:1;color:var(--mantine-color-dimmed)}.m_5f93f3bb{--switch-height-xs: calc(1rem * var(--mantine-scale));--switch-height-sm: calc(1.25rem * var(--mantine-scale));--switch-height-md: calc(1.5rem * var(--mantine-scale));--switch-height-lg: calc(1.875rem * var(--mantine-scale));--switch-height-xl: calc(2.25rem * var(--mantine-scale));--switch-width-xs: calc(2rem * var(--mantine-scale));--switch-width-sm: calc(2.375rem * var(--mantine-scale));--switch-width-md: calc(2.875rem * var(--mantine-scale));--switch-width-lg: calc(3.5rem * var(--mantine-scale));--switch-width-xl: calc(4.5rem * var(--mantine-scale));--switch-thumb-size-xs: calc(.75rem * var(--mantine-scale));--switch-thumb-size-sm: calc(.875rem * var(--mantine-scale));--switch-thumb-size-md: calc(1.125rem * var(--mantine-scale));--switch-thumb-size-lg: calc(1.375rem * var(--mantine-scale));--switch-thumb-size-xl: calc(1.75rem * var(--mantine-scale));--switch-label-font-size-xs: calc(.3125rem * var(--mantine-scale));--switch-label-font-size-sm: calc(.375rem * var(--mantine-scale));--switch-label-font-size-md: calc(.4375rem * var(--mantine-scale));--switch-label-font-size-lg: calc(.5625rem * var(--mantine-scale));--switch-label-font-size-xl: calc(.6875rem * var(--mantine-scale));--switch-track-label-padding-xs: calc(.0625rem * var(--mantine-scale));--switch-track-label-padding-sm: calc(.125rem * var(--mantine-scale));--switch-track-label-padding-md: calc(.125rem * var(--mantine-scale));--switch-track-label-padding-lg: calc(.1875rem * var(--mantine-scale));--switch-track-label-padding-xl: calc(.1875rem * var(--mantine-scale));--switch-height: var(--switch-height-sm);--switch-width: var(--switch-width-sm);--switch-thumb-size: var(--switch-thumb-size-sm);--switch-label-font-size: var(--switch-label-font-size-sm);--switch-track-label-padding: var(--switch-track-label-padding-sm);--switch-radius: calc(62.5rem * var(--mantine-scale));--switch-color: var(--mantine-primary-color-filled);position:relative}.m_926b4011{height:0;width:0;opacity:0;margin:0;padding:0;position:absolute;overflow:hidden;white-space:nowrap}.m_9307d992{-webkit-tap-highlight-color:transparent;cursor:var(--switch-cursor, var(--mantine-cursor-type));overflow:hidden;position:relative;border-radius:var(--switch-radius);background-color:var(--switch-bg);border:1px solid var(--switch-bd);height:var(--switch-height);min-width:var(--switch-width);margin:0;transition:background-color .15s ease,border-color .15s ease;-webkit-appearance:none;-moz-appearance:none;appearance:none;display:flex;align-items:center;font-size:var(--switch-label-font-size);font-weight:600;order:var(--switch-order, 1);-webkit-user-select:none;user-select:none;z-index:0;line-height:0;color:var(--switch-text-color)}.m_926b4011:focus-visible+.m_9307d992{outline:2px solid var(--mantine-primary-color-filled);outline-offset:calc(.125rem * var(--mantine-scale))}.m_926b4011:checked+.m_9307d992{--switch-bg: var(--switch-color);--switch-bd: var(--switch-color);--switch-text-color: var(--mantine-color-white)}.m_926b4011:disabled+.m_9307d992,.m_926b4011[data-disabled]+.m_9307d992{--switch-bg: var(--switch-disabled-color);--switch-bd: var(--switch-disabled-color);--switch-cursor: not-allowed}[data-mantine-color-scheme=light] .m_9307d992{--switch-bg: var(--mantine-color-gray-2);--switch-bd: var(--mantine-color-gray-3);--switch-text-color: var(--mantine-color-gray-6);--switch-disabled-color: var(--mantine-color-gray-2)}[data-mantine-color-scheme=dark] .m_9307d992{--switch-bg: var(--mantine-color-dark-6);--switch-bd: var(--mantine-color-dark-4);--switch-text-color: var(--mantine-color-dark-1);--switch-disabled-color: var(--mantine-color-dark-4)}.m_9307d992[data-error]{--switch-bd: var(--mantine-color-error)}.m_9307d992[data-label-position=left]{--switch-order: 2}.m_93039a1d{position:absolute;z-index:1;border-radius:var(--switch-radius);display:flex;background-color:var(--switch-thumb-bg, var(--mantine-color-white));height:var(--switch-thumb-size);width:var(--switch-thumb-size);border:1px solid var(--switch-thumb-bd);inset-inline-start:var(--switch-thumb-start, var(--switch-track-label-padding));transition:inset-inline-start .15s ease}.m_93039a1d>*{margin:auto}.m_926b4011:checked+*>.m_93039a1d{--switch-thumb-start: calc(100% - var(--switch-thumb-size) - var(--switch-track-label-padding));--switch-thumb-bd: var(--mantine-color-white)}.m_926b4011:disabled+*>.m_93039a1d,.m_926b4011[data-disabled]+*>.m_93039a1d{--switch-thumb-bd: var(--switch-thumb-bg-disabled);--switch-thumb-bg: var(--switch-thumb-bg-disabled)}[data-mantine-color-scheme=light] .m_93039a1d{--switch-thumb-bd: var(--mantine-color-gray-3);--switch-thumb-bg-disabled: var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_93039a1d{--switch-thumb-bd: var(--mantine-color-white);--switch-thumb-bg-disabled: var(--mantine-color-dark-3)}.m_8277e082{height:100%;display:grid;place-content:center;min-width:calc(var(--switch-width) - var(--switch-thumb-size));padding-inline:var(--switch-track-label-padding);margin-inline-start:calc(var(--switch-thumb-size) + var(--switch-track-label-padding));transition:margin .15s ease}.m_926b4011:checked+*>.m_8277e082{margin-inline-end:calc(var(--switch-thumb-size) + var(--switch-track-label-padding));margin-inline-start:0}.m_b23fa0ef{width:100%;border-collapse:collapse;line-height:var(--mantine-line-height);font-size:var(--mantine-font-size-sm);table-layout:var(--table-layout, auto);caption-side:var(--table-caption-side, bottom);border:none}:where([data-mantine-color-scheme=light]) .m_b23fa0ef{--table-hover-color: var(--mantine-color-gray-1);--table-striped-color: var(--mantine-color-gray-0);--table-border-color: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_b23fa0ef{--table-hover-color: var(--mantine-color-dark-5);--table-striped-color: var(--mantine-color-dark-6);--table-border-color: var(--mantine-color-dark-4)}.m_b23fa0ef:where([data-with-table-border]){border:1px solid var(--table-border-color)}.m_4e7aa4f3{text-align:left}:where([dir=rtl]) .m_4e7aa4f3{text-align:right}.m_4e7aa4fd{border-bottom:none;background-color:transparent}@media (hover: hover){.m_4e7aa4fd:hover:where([data-hover]){background-color:var(--tr-hover-bg)}}@media (hover: none){.m_4e7aa4fd:active:where([data-hover]){background-color:var(--tr-hover-bg)}}.m_4e7aa4fd:where([data-with-row-border]){border-bottom:1px solid var(--table-border-color)}.m_4e7aa4ef,.m_4e7aa4f3{padding:var(--table-vertical-spacing) var(--table-horizontal-spacing, var(--mantine-spacing-xs))}.m_4e7aa4ef:where([data-with-column-border]:not(:last-child)),.m_4e7aa4f3:where([data-with-column-border]:not(:last-child)){border-inline-end:1px solid var(--table-border-color)}.m_b2404537 :where(tr):where([data-with-row-border]:last-of-type){border-bottom:none}.m_b2404537 :where(tr):where([data-striped=odd]:nth-of-type(odd)){background-color:var(--table-striped-color)}.m_b2404537 :where(tr):where([data-striped=even]:nth-of-type(2n)){background-color:var(--table-striped-color)}.m_b2404537 :where(tr)[data-hover]{--tr-hover-bg: var(--table-highlight-on-hover-color, var(--table-hover-color))}.m_b242d975{top:var(--table-sticky-header-offset, 0);z-index:1}.m_b242d975:where([data-sticky]){position:sticky;background-color:var(--mantine-color-body)}.m_9e5a3ac7{color:var(--mantine-color-dimmed)}.m_9e5a3ac7:where([data-side=top]){margin-bottom:var(--mantine-spacing-xs)}.m_9e5a3ac7:where([data-side=bottom]){margin-top:var(--mantine-spacing-xs)}.m_a100c15{overflow-x:var(--table-overflow)}.m_62259741{min-width:var(--table-min-width)}.m_89d60db1{display:var(--tabs-display);flex-direction:var(--tabs-flex-direction);--tab-justify: flex-start;--tabs-list-direction: row;--tabs-panel-grow: unset;--tabs-display: block;--tabs-flex-direction: row;--tabs-list-border-width: 0;--tabs-list-border-size: 0 0 var(--tabs-list-border-width) 0;--tabs-list-gap: unset;--tabs-list-line-bottom: 0;--tabs-list-line-top: unset;--tabs-list-line-start: 0;--tabs-list-line-end: 0;--tab-radius: var(--tabs-radius) var(--tabs-radius) 0 0;--tab-border-width: 0 0 var(--tabs-list-border-width) 0}.m_89d60db1[data-inverted]{--tabs-list-line-bottom: unset;--tabs-list-line-top: 0;--tab-radius: 0 0 var(--tabs-radius) var(--tabs-radius);--tab-border-width: var(--tabs-list-border-width) 0 0 0}.m_89d60db1[data-inverted] .m_576c9d4:before{top:0;bottom:unset}.m_89d60db1[data-orientation=vertical]{--tabs-list-line-start: unset;--tabs-list-line-end: 0;--tabs-list-line-top: 0;--tabs-list-line-bottom: 0;--tabs-list-border-size: 0 var(--tabs-list-border-width) 0 0;--tab-border-width: 0 var(--tabs-list-border-width) 0 0;--tab-radius: var(--tabs-radius) 0 0 var(--tabs-radius);--tabs-list-direction: column;--tabs-panel-grow: 1;--tabs-display: flex}[dir=rtl] .m_89d60db1[data-orientation=vertical]{--tabs-list-border-size: 0 0 0 var(--tabs-list-border-width);--tab-border-width: 0 0 0 var(--tabs-list-border-width);--tab-radius: 0 var(--tabs-radius) var(--tabs-radius) 0}.m_89d60db1[data-orientation=vertical][data-placement=right]{--tabs-flex-direction: row-reverse;--tabs-list-line-start: 0;--tabs-list-line-end: unset;--tabs-list-border-size: 0 0 0 var(--tabs-list-border-width);--tab-border-width: 0 0 0 var(--tabs-list-border-width);--tab-radius: 0 var(--tabs-radius) var(--tabs-radius) 0}[dir=rtl] .m_89d60db1[data-orientation=vertical][data-placement=right]{--tabs-list-border-size: 0 var(--tabs-list-border-width) 0 0;--tab-border-width: 0 var(--tabs-list-border-width) 0 0;--tab-radius: var(--tabs-radius) 0 0 var(--tabs-radius)}[data-mantine-color-scheme=light] .m_89d60db1{--tab-border-color: var(--mantine-color-gray-3)}[data-mantine-color-scheme=dark] .m_89d60db1{--tab-border-color: var(--mantine-color-dark-4)}.m_89d60db1[data-orientation=horizontal]{--tab-justify: center}.m_89d60db1[data-variant=default]{--tabs-list-border-width: calc(.125rem * var(--mantine-scale))}[data-mantine-color-scheme=light] .m_89d60db1[data-variant=default]{--tab-hover-color: var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_89d60db1[data-variant=default]{--tab-hover-color: var(--mantine-color-dark-6)}.m_89d60db1[data-variant=outline]{--tabs-list-border-width: calc(.0625rem * var(--mantine-scale))}.m_89d60db1[data-variant=pills]{--tabs-list-gap: calc(var(--mantine-spacing-sm) / 2)}[data-mantine-color-scheme=light] .m_89d60db1[data-variant=pills]{--tab-hover-color: var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_89d60db1[data-variant=pills]{--tab-hover-color: var(--mantine-color-dark-6)}.m_89d33d6d{display:flex;flex-wrap:wrap;justify-content:var(--tabs-justify, flex-start);flex-direction:var(--tabs-list-direction);gap:var(--tabs-list-gap);--tab-grow: unset}.m_89d33d6d[data-grow]{--tab-grow: 1}.m_b0c91715{flex-grow:var(--tabs-panel-grow)}.m_4ec4dce6{position:relative;padding:var(--mantine-spacing-xs) var(--mantine-spacing-md);font-size:var(--mantine-font-size-sm);white-space:nowrap;z-index:0;display:flex;align-items:center;line-height:1;-webkit-user-select:none;user-select:none;flex-grow:var(--tab-grow);justify-content:var(--tab-justify)}.m_4ec4dce6:disabled,.m_4ec4dce6[data-disabled]{opacity:.5;cursor:not-allowed}.m_4ec4dce6:focus{z-index:1}.m_fc420b1f{display:flex;align-items:center;justify-content:center;margin-left:var(--tab-section-margin-left, 0);margin-right:var(--tab-section-margin-right, 0)}.m_fc420b1f[data-position=left]:not(:only-child){--tab-section-margin-right: var(--mantine-spacing-xs)}[dir=rtl] .m_fc420b1f[data-position=left]:not(:only-child){--tab-section-margin-right: 0rem;--tab-section-margin-left: var(--mantine-spacing-xs)}.m_fc420b1f[data-position=right]:not(:only-child){--tab-section-margin-left: var(--mantine-spacing-xs)}[dir=rtl] .m_fc420b1f[data-position=right]:not(:only-child){--tab-section-margin-left: 0rem;--tab-section-margin-right: var(--mantine-spacing-xs)}.m_576c9d4{position:relative}.m_576c9d4:before{content:"";position:absolute;border-color:var(--tab-border-color);border-width:var(--tabs-list-border-size);border-style:solid;bottom:var(--tabs-list-line-bottom);inset-inline-start:var(--tabs-list-line-start);inset-inline-end:var(--tabs-list-line-end);top:var(--tabs-list-line-top)}.m_539e827b{border-radius:var(--tab-radius);border-width:var(--tab-border-width);border-style:solid;border-color:transparent;background-color:var(--tab-bg);--tab-bg: transparent}.m_539e827b:where([data-active]){border-color:var(--tabs-color)}@media (hover: hover){.m_539e827b:hover{--tab-bg: var(--tab-hover-color)}.m_539e827b:hover:where(:not([data-active])){border-color:var(--tab-border-color)}}@media (hover: none){.m_539e827b:active{--tab-bg: var(--tab-hover-color)}.m_539e827b:active:where(:not([data-active])){border-color:var(--tab-border-color)}}@media (hover: hover){.m_539e827b:disabled:hover,.m_539e827b[data-disabled]:hover{--tab-bg: transparent}}@media (hover: none){.m_539e827b:disabled:active,.m_539e827b[data-disabled]:active{--tab-bg: transparent}}.m_6772fbd5{position:relative}.m_6772fbd5:before{content:"";position:absolute;border-color:var(--tab-border-color);border-width:var(--tabs-list-border-size);border-style:solid;bottom:var(--tabs-list-line-bottom);inset-inline-start:var(--tabs-list-line-start);inset-inline-end:var(--tabs-list-line-end);top:var(--tabs-list-line-top)}.m_b59ab47c{border-top:calc(.0625rem * var(--mantine-scale)) solid transparent;border-bottom:calc(.0625rem * var(--mantine-scale)) solid transparent;border-right:calc(.0625rem * var(--mantine-scale)) solid transparent;border-left:calc(.0625rem * var(--mantine-scale)) solid transparent;border-top-color:var(--tab-border-top-color);border-bottom-color:var(--tab-border-bottom-color);border-radius:var(--tab-radius);position:relative;--tab-border-bottom-color: transparent;--tab-border-top-color: transparent;--tab-border-inline-end-color: transparent;--tab-border-inline-start-color: transparent}.m_b59ab47c:where([data-active]):before{content:"";position:absolute;background-color:var(--tab-border-color);bottom:var(--tab-before-bottom, calc(-.0625rem * var(--mantine-scale)));left:var(--tab-before-left, calc(-.0625rem * var(--mantine-scale)));right:var(--tab-before-right, auto);top:var(--tab-before-top, auto);width:calc(.0625rem * var(--mantine-scale));height:calc(.0625rem * var(--mantine-scale))}.m_b59ab47c:where([data-active]):after{content:"";position:absolute;background-color:var(--tab-border-color);bottom:var(--tab-after-bottom, calc(-.0625rem * var(--mantine-scale)));right:var(--tab-after-right, calc(-.0625rem * var(--mantine-scale)));left:var(--tab-after-left, auto);top:var(--tab-after-top, auto);width:calc(.0625rem * var(--mantine-scale));height:calc(.0625rem * var(--mantine-scale))}.m_b59ab47c:where([data-active]){border-top-color:var(--tab-border-top-color);border-bottom-color:var(--tab-border-bottom-color);border-inline-start-color:var(--tab-border-inline-start-color);border-inline-end-color:var(--tab-border-inline-end-color);--tab-border-top-color: var(--tab-border-color);--tab-border-inline-start-color: var(--tab-border-color);--tab-border-inline-end-color: var(--tab-border-color);--tab-border-bottom-color: var(--mantine-color-body)}.m_b59ab47c:where([data-active])[data-inverted]{--tab-border-bottom-color: var(--tab-border-color);--tab-border-top-color: var(--mantine-color-body);--tab-before-bottom: auto;--tab-before-top: calc(-.0625rem * var(--mantine-scale));--tab-after-bottom: auto;--tab-after-top: calc(-.0625rem * var(--mantine-scale))}.m_b59ab47c:where([data-active])[data-orientation=vertical][data-placement=left]{--tab-border-inline-end-color: var(--mantine-color-body);--tab-border-inline-start-color: var(--tab-border-color);--tab-border-bottom-color: var(--tab-border-color);--tab-before-right: calc(-.0625rem * var(--mantine-scale));--tab-before-left: auto;--tab-before-bottom: auto;--tab-before-top: calc(-.0625rem * var(--mantine-scale));--tab-after-left: auto;--tab-after-right: calc(-.0625rem * var(--mantine-scale))}[dir=rtl] .m_b59ab47c:where([data-active])[data-orientation=vertical][data-placement=left]{--tab-before-right: auto;--tab-before-left: calc(-.0625rem * var(--mantine-scale));--tab-after-left: calc(-.0625rem * var(--mantine-scale));--tab-after-right: auto}.m_b59ab47c:where([data-active])[data-orientation=vertical][data-placement=right]{--tab-border-inline-start-color: var(--mantine-color-body);--tab-border-inline-end-color: var(--tab-border-color);--tab-border-bottom-color: var(--tab-border-color);--tab-before-left: calc(-.0625rem * var(--mantine-scale));--tab-before-right: auto;--tab-before-bottom: auto;--tab-before-top: calc(-.0625rem * var(--mantine-scale));--tab-after-right: auto;--tab-after-left: calc(-.0625rem * var(--mantine-scale))}[dir=rtl] .m_b59ab47c:where([data-active])[data-orientation=vertical][data-placement=right]{--tab-before-left: auto;--tab-before-right: calc(-.0625rem * var(--mantine-scale));--tab-after-right: calc(-.0625rem * var(--mantine-scale));--tab-after-left: auto}.m_c3381914{border-radius:var(--tabs-radius);background-color:var(--tab-bg);color:var(--tab-color);--tab-bg: transparent;--tab-color: inherit}@media (hover: hover){.m_c3381914:not([data-disabled]):hover{--tab-bg: var(--tab-hover-color)}}@media (hover: none){.m_c3381914:not([data-disabled]):active{--tab-bg: var(--tab-hover-color)}}.m_c3381914[data-active][data-active]{--tab-bg: var(--tabs-color);--tab-color: var(--tabs-text-color, var(--mantine-color-white))}@media (hover: hover){.m_c3381914[data-active][data-active]:hover{--tab-bg: var(--tabs-color)}}@media (hover: none){.m_c3381914[data-active][data-active]:active{--tab-bg: var(--tabs-color)}}.m_7341320d{--ti-size-xs: calc(1.125rem * var(--mantine-scale));--ti-size-sm: calc(1.375rem * var(--mantine-scale));--ti-size-md: calc(1.75rem * var(--mantine-scale));--ti-size-lg: calc(2.125rem * var(--mantine-scale));--ti-size-xl: calc(2.75rem * var(--mantine-scale));--ti-size: var(--ti-size-md);line-height:1;display:inline-flex;align-items:center;justify-content:center;position:relative;-webkit-user-select:none;user-select:none;width:var(--ti-size);height:var(--ti-size);min-width:var(--ti-size);min-height:var(--ti-size);border-radius:var(--ti-radius, var(--mantine-radius-default));background:var(--ti-bg, var(--mantine-primary-color-filled));color:var(--ti-color, var(--mantine-color-white));border:var(--ti-bd, 1px solid transparent)}.m_43657ece{--offset: calc(var(--tl-bullet-size) / 2 + var(--tl-line-width) / 2);--tl-bullet-size: calc(1.25rem * var(--mantine-scale));--tl-line-width: calc(.25rem * var(--mantine-scale));--tl-radius: calc(62.5rem * var(--mantine-scale));--tl-color: var(--mantine-primary-color-filled)}.m_43657ece:where([data-align=left]){padding-inline-start:var(--offset)}.m_43657ece:where([data-align=right]){padding-inline-end:var(--offset)}.m_2ebe8099{font-weight:500;line-height:1;margin-bottom:calc(var(--mantine-spacing-xs) / 2)}.m_436178ff{--item-border: var(--tl-line-width) var(--tli-border-style, solid) var(--item-border-color);position:relative;color:var(--mantine-color-text)}.m_436178ff:before{content:"";pointer-events:none;position:absolute;top:0;left:var(--timeline-line-left, 0);right:var(--timeline-line-right, 0);bottom:calc(var(--mantine-spacing-xl) * -1);border-inline-start:var(--item-border);display:var(--timeline-line-display, none)}.m_43657ece[data-align=left] .m_436178ff:before{--timeline-line-left: calc(var(--tl-line-width) * -1);--timeline-line-right: auto}[dir=rtl] .m_43657ece[data-align=left] .m_436178ff:before{--timeline-line-left: auto;--timeline-line-right: calc(var(--tl-line-width) * -1)}.m_43657ece[data-align=right] .m_436178ff:before{--timeline-line-left: auto;--timeline-line-right: calc(var(--tl-line-width) * -1)}[dir=rtl] .m_43657ece[data-align=right] .m_436178ff:before{--timeline-line-left: calc(var(--tl-line-width) * -1);--timeline-line-right: auto}.m_43657ece:where([data-align=left]) .m_436178ff{padding-inline-start:var(--offset);text-align:left}.m_43657ece:where([data-align=right]) .m_436178ff{padding-inline-end:var(--offset);text-align:right}:where([data-mantine-color-scheme=light]) .m_436178ff{--item-border-color: var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_436178ff{--item-border-color: var(--mantine-color-dark-4)}.m_436178ff:where([data-line-active]):before{border-color:var(--tli-color, var(--tl-color))}.m_436178ff:where(:not(:last-of-type)){--timeline-line-display: block}.m_436178ff:where(:not(:first-of-type)){margin-top:var(--mantine-spacing-xl)}.m_8affcee1{width:var(--tl-bullet-size);height:var(--tl-bullet-size);border-radius:var(--tli-radius, var(--tl-radius));border:var(--tl-line-width) solid;background-color:var(--mantine-color-body);position:absolute;top:0;display:flex;align-items:center;justify-content:center;color:var(--mantine-color-text)}:where([data-mantine-color-scheme=light]) .m_8affcee1{border-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_8affcee1{border-color:var(--mantine-color-dark-4)}.m_43657ece:where([data-align=left]) .m_8affcee1{left:calc((var(--tl-bullet-size) / 2 + var(--tl-line-width) / 2) * -1);right:auto}:where([dir=rtl]) .m_43657ece:where([data-align=left]) .m_8affcee1{left:auto;right:calc((var(--tl-bullet-size) / 2 + var(--tl-line-width) / 2) * -1)}.m_43657ece:where([data-align=right]) .m_8affcee1{left:auto;right:calc((var(--tl-bullet-size) / 2 + var(--tl-line-width) / 2) * -1)}:where([dir=rtl]) .m_43657ece:where([data-align=right]) .m_8affcee1{left:calc((var(--tl-bullet-size) / 2 + var(--tl-line-width) / 2) * -1);right:auto}.m_8affcee1:where([data-with-child]){border-width:var(--tl-line-width)}:where([data-mantine-color-scheme=light]) .m_8affcee1:where([data-with-child]){background-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_8affcee1:where([data-with-child]){background-color:var(--mantine-color-dark-4)}.m_8affcee1:where([data-active]){border-color:var(--tli-color, var(--tl-color));background-color:var(--mantine-color-white);color:var(--tl-icon-color, var(--mantine-color-white))}.m_8affcee1:where([data-active]):where([data-with-child]){background-color:var(--tli-color, var(--tl-color));color:var(--tl-icon-color, var(--mantine-color-white))}.m_43657ece:where([data-align=left]) .m_540e8f41{padding-inline-start:var(--offset);text-align:left}:where([dir=rtl]) .m_43657ece:where([data-align=left]) .m_540e8f41{text-align:right}.m_43657ece:where([data-align=right]) .m_540e8f41{padding-inline-end:var(--offset);text-align:right}:where([dir=rtl]) .m_43657ece:where([data-align=right]) .m_540e8f41{text-align:left}.m_8a5d1357{margin:0;font-weight:var(--title-fw);font-size:var(--title-fz);line-height:var(--title-lh);font-family:var(--mantine-font-family-headings);text-wrap:var(--title-text-wrap, var(--mantine-heading-text-wrap))}.m_8a5d1357:where([data-line-clamp]){overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:var(--title-line-clamp);-webkit-box-orient:vertical}.m_d6493fad :first-child{margin-top:0}.m_d6493fad :last-child{margin-bottom:0}.m_d6493fad :where(h1,h2,h3,h4,h5,h6){margin-bottom:var(--mantine-spacing-xs);text-wrap:var(--mantine-heading-text-wrap)}.m_d6493fad :where(h1){margin-top:calc(1.5 * var(--mantine-spacing-xl));font-size:var(--mantine-h1-font-size);line-height:var(--mantine-h1-line-height);font-weight:var(--mantine-h1-font-weight)}.m_d6493fad :where(h2){margin-top:var(--mantine-spacing-xl);font-size:var(--mantine-h2-font-size);line-height:var(--mantine-h2-line-height);font-weight:var(--mantine-h2-font-weight)}.m_d6493fad :where(h3){margin-top:calc(.8 * var(--mantine-spacing-xl));font-size:var(--mantine-h3-font-size);line-height:var(--mantine-h3-line-height);font-weight:var(--mantine-h3-font-weight)}.m_d6493fad :where(h4){margin-top:calc(.8 * var(--mantine-spacing-xl));font-size:var(--mantine-h4-font-size);line-height:var(--mantine-h4-line-height);font-weight:var(--mantine-h4-font-weight)}.m_d6493fad :where(h5){margin-top:calc(.5 * var(--mantine-spacing-xl));font-size:var(--mantine-h5-font-size);line-height:var(--mantine-h5-line-height);font-weight:var(--mantine-h5-font-weight)}.m_d6493fad :where(h6){margin-top:calc(.5 * var(--mantine-spacing-xl));font-size:var(--mantine-h6-font-size);line-height:var(--mantine-h6-line-height);font-weight:var(--mantine-h6-font-weight)}.m_d6493fad :where(img){max-width:100%;margin-bottom:var(--mantine-spacing-xs)}.m_d6493fad :where(p){margin-top:0;margin-bottom:var(--mantine-spacing-lg)}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(mark){background-color:var(--mantine-color-yellow-2);color:inherit}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(mark){background-color:var(--mantine-color-yellow-5);color:var(--mantine-color-black)}.m_d6493fad :where(a){color:var(--mantine-color-anchor);text-decoration:none}@media (hover: hover){.m_d6493fad :where(a):hover{text-decoration:underline}}@media (hover: none){.m_d6493fad :where(a):active{text-decoration:underline}}.m_d6493fad :where(hr){margin-top:var(--mantine-spacing-md);margin-bottom:var(--mantine-spacing-md);border:0;border-top:calc(.0625rem * var(--mantine-scale)) solid}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(hr){border-color:var(--mantine-color-gray-3)}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(hr){border-color:var(--mantine-color-dark-3)}.m_d6493fad :where(pre){padding:var(--mantine-spacing-xs);line-height:var(--mantine-line-height);margin:0;margin-top:var(--mantine-spacing-md);margin-bottom:var(--mantine-spacing-md);overflow-x:auto;font-family:var(--mantine-font-family-monospace);font-size:var(--mantine-font-size-xs);border-radius:var(--mantine-radius-sm)}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(pre){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(pre){background-color:var(--mantine-color-dark-8)}.m_d6493fad :where(pre) :where(code){background-color:transparent;padding:0;border-radius:0;color:inherit;border:0}.m_d6493fad :where(kbd){--kbd-fz: calc(.75rem * var(--mantine-scale));--kbd-padding: calc(.1875rem * var(--mantine-scale)) calc(.3125rem * var(--mantine-scale));font-family:var(--mantine-font-family-monospace);line-height:var(--mantine-line-height);font-weight:700;padding:var(--kbd-padding);font-size:var(--kbd-fz);border-radius:var(--mantine-radius-sm);border:calc(.0625rem * var(--mantine-scale)) solid;border-bottom-width:calc(.1875rem * var(--mantine-scale))}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(kbd){border-color:var(--mantine-color-gray-3);color:var(--mantine-color-gray-7);background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(kbd){border-color:var(--mantine-color-dark-3);color:var(--mantine-color-dark-0);background-color:var(--mantine-color-dark-5)}.m_d6493fad :where(code){line-height:var(--mantine-line-height);padding:calc(.0625rem * var(--mantine-scale)) calc(.3125rem * var(--mantine-scale));border-radius:var(--mantine-radius-sm);font-family:var(--mantine-font-family-monospace);font-size:var(--mantine-font-size-xs)}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(code){background-color:var(--mantine-color-gray-0);color:var(--mantine-color-black)}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(code){background-color:var(--mantine-color-dark-5);color:var(--mantine-color-white)}.m_d6493fad :where(ul,ol):not([data-type=taskList]){margin-bottom:var(--mantine-spacing-md);padding-inline-start:calc(2.375rem * var(--mantine-scale))}.m_d6493fad :where(ul,ol):not([data-type=taskList]) :where(li){margin-bottom:var(--mantine-spacing-xs)}.m_d6493fad :where(table){width:100%;border-collapse:collapse;caption-side:bottom;margin-bottom:var(--mantine-spacing-md)}.m_d6493fad :where(table) :where(caption){margin-top:var(--mantine-spacing-xs);font-size:var(--mantine-font-size-sm);color:var(--mantine-color-gray-6)}.m_d6493fad :where(table) :where(th){text-align:left;font-weight:700;color:var(--mantine-color-gray-7);font-size:var(--mantine-font-size-sm);padding:var(--mantine-spacing-xs) var(--mantine-spacing-sm)}.m_d6493fad :where(table) :where(thead th){border-bottom:calc(.0625rem * var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3)}.m_d6493fad :where(table) :where(tfoot th){border-top:calc(.0625rem * var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3)}.m_d6493fad :where(table) :where(td){padding:var(--mantine-spacing-xs) var(--mantine-spacing-sm);border-bottom:calc(.0625rem * var(--mantine-scale)) solid;border-color:var(--mantine-color-gray-3);font-size:var(--mantine-font-size-sm)}.m_d6493fad :where(table) :where(tr:last-of-type td){border-bottom:0}.m_d6493fad :where(blockquote){font-size:var(--mantine-font-size-lg);line-height:var(--mantine-line-height);margin:var(--mantine-spacing-md) 0;border-radius:var(--mantine-radius-sm);padding:var(--mantine-spacing-md) var(--mantine-spacing-lg)}:where([data-mantine-color-scheme=light]) .m_d6493fad :where(blockquote){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_d6493fad :where(blockquote){background-color:var(--mantine-color-dark-8)}.m_468e7eda{padding-top:0;padding-bottom:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.m_468e7eda::-webkit-calendar-picker-indicator{display:none}.m_468e7eda::-webkit-clear-button{display:none}.m_468e7eda::-webkit-datetime-edit-hour-field,.m_468e7eda::-webkit-datetime-edit-minute-field,.m_468e7eda::-webkit-datetime-edit-second-field{padding-top:0;max-height:calc(1.875rem * var(--mantine-scale));display:inline}.m_468e7eda::-webkit-datetime-edit-hour-field:focus,.m_468e7eda::-webkit-datetime-edit-minute-field:focus,.m_468e7eda::-webkit-datetime-edit-second-field:focus{background-color:var(--mantine-primary-color-filled);color:var(--mantine-color-white)}.m_396ce5cb{--day-size-xs: calc(1.875rem * var(--mantine-scale));--day-size-sm: calc(2.25rem * var(--mantine-scale));--day-size-md: calc(2.625rem * var(--mantine-scale));--day-size-lg: calc(3rem * var(--mantine-scale));--day-size-xl: calc(3.375rem * var(--mantine-scale));--day-size: var(--day-size-sm);width:var(--day-size, var(--day-size-sm));height:var(--day-size, var(--day-size-sm));font-size:calc(var(--day-size) / 2.8);display:inline-flex;justify-content:center;align-items:center;-webkit-user-select:none;user-select:none;cursor:pointer;background-color:transparent;border-radius:var(--mantine-radius-default);color:var(--mantine-color-text);opacity:1}@media (hover: hover){[data-mantine-color-scheme=light] .m_396ce5cb:hover:where(:not([data-static],[data-disabled],[data-selected],[data-in-range])){background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_396ce5cb:hover:where(:not([data-static],[data-disabled],[data-selected],[data-in-range])){background-color:var(--mantine-color-dark-5)}}@media (hover: none){[data-mantine-color-scheme=light] .m_396ce5cb:active:where(:not([data-static],[data-disabled],[data-selected],[data-in-range])){background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_396ce5cb:active:where(:not([data-static],[data-disabled],[data-selected],[data-in-range])){background-color:var(--mantine-color-dark-5)}}.m_396ce5cb:where([data-static]){-webkit-user-select:auto;user-select:auto;cursor:default}.m_396ce5cb:where([data-weekend]){color:var(--mantine-color-red-6)}.m_396ce5cb:where([data-outside]){color:var(--mantine-color-dimmed);opacity:.5}.m_396ce5cb:where(:disabled,[data-disabled]){color:var(--mantine-color-dimmed);cursor:not-allowed;opacity:.5}.m_396ce5cb:where([data-hidden]){display:none}.m_396ce5cb:where([data-in-range]){background-color:var(--mantine-primary-color-light-hover);border-radius:0}@media (hover: hover){.m_396ce5cb:where([data-in-range]):hover:where(:not([data-disabled],[data-static])){background-color:var(--mantine-primary-color-light)}}@media (hover: none){.m_396ce5cb:where([data-in-range]):active:where(:not([data-disabled],[data-static])){background-color:var(--mantine-primary-color-light)}}.m_396ce5cb:where([data-first-in-range]){border-radius:0;border-start-start-radius:var(--mantine-radius-default);border-end-start-radius:var(--mantine-radius-default)}.m_396ce5cb:where([data-last-in-range]){border-radius:0;border-end-end-radius:var(--mantine-radius-default);border-start-end-radius:var(--mantine-radius-default)}.m_396ce5cb:where([data-last-in-range][data-first-in-range]){border-radius:var(--mantine-radius-default)}.m_396ce5cb:where([data-selected]){background-color:var(--mantine-primary-color-filled);color:var(--mantine-primary-color-contrast)}@media (hover: hover){.m_396ce5cb:where([data-selected]):hover:where(:not([data-disabled],[data-static])){background-color:var(--mantine-primary-color-filled-hover)}}@media (hover: none){.m_396ce5cb:where([data-selected]):active:where(:not([data-disabled],[data-static])){background-color:var(--mantine-primary-color-filled-hover)}}.m_18a3eca{color:var(--mantine-color-dimmed);font-weight:400;font-size:var(--wr-fz, var(--mantine-font-size-sm));text-transform:capitalize;padding-bottom:calc(var(--wr-spacing, var(--mantine-spacing-sm)) / 2)}.m_cc9820d3{border-collapse:collapse;table-layout:fixed}.m_8f457cd5{padding:0}.m_8f457cd5:where([data-with-spacing]){padding:calc(.03125rem * var(--mantine-scale))}.m_dc6a3c71{--dpc-size-xs: calc(1.875rem * var(--mantine-scale));--dpc-size-sm: calc(2.25rem * var(--mantine-scale));--dpc-size-md: calc(2.625rem * var(--mantine-scale));--dpc-size-lg: calc(3rem * var(--mantine-scale));--dpc-size-xl: calc(3.375rem * var(--mantine-scale));--dpc-size: var(--dpc-size-sm);font-size:var(--dpc-fz, var(--mantine-font-size-sm));height:var(--dpc-size);width:calc((var(--dpc-size) * 7) / 3 + calc(.09375rem * var(--mantine-scale)));display:flex;justify-content:center;align-items:center;-webkit-user-select:none;user-select:none;cursor:pointer;background-color:transparent;color:var(--mantine-color-text);opacity:1;border-radius:var(--mantine-radius-default)}@media (hover: hover){:where([data-mantine-color-scheme=light]) .m_dc6a3c71:hover:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_dc6a3c71:hover:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-dark-5)}}@media (hover: none){:where([data-mantine-color-scheme=light]) .m_dc6a3c71:active:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-gray-0)}:where([data-mantine-color-scheme=dark]) .m_dc6a3c71:active:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-dark-5)}}.m_dc6a3c71:where(:disabled,[data-disabled]){color:var(--mantine-color-dimmed);cursor:not-allowed;opacity:.5}.m_dc6a3c71:where([data-selected]){background-color:var(--mantine-primary-color-filled);color:var(--mantine-primary-color-contrast, var(--mantine-color-white))}@media (hover: hover){.m_dc6a3c71:where([data-selected]):hover{background-color:var(--mantine-primary-color-filled-hover)}}@media (hover: none){.m_dc6a3c71:where([data-selected]):active{background-color:var(--mantine-primary-color-filled-hover)}}.m_dc6a3c71:where([data-in-range]){background-color:var(--mantine-primary-color-light-hover);border-radius:0}@media (hover: hover){.m_dc6a3c71:where([data-in-range]):hover{background-color:var(--mantine-primary-color-light)}}@media (hover: none){.m_dc6a3c71:where([data-in-range]):active{background-color:var(--mantine-primary-color-light)}}.m_dc6a3c71:where([data-first-in-range]){border-radius:0;border-start-start-radius:var(--mantine-radius-default);border-end-start-radius:var(--mantine-radius-default)}.m_dc6a3c71:where([data-last-in-range]){border-radius:0;border-end-end-radius:var(--mantine-radius-default);border-start-end-radius:var(--mantine-radius-default)}.m_dc6a3c71:where([data-first-in-range][data-last-in-range]){border-radius:var(--mantine-radius-default)}.m_9206547b{border-collapse:collapse;border-width:0}.m_c5a19c7d{padding:0}.m_c5a19c7d:where([data-with-spacing]){padding:calc(.03125rem * var(--mantine-scale))}.m_2a6c32d{border-collapse:collapse;border-width:0;cursor:pointer}.m_fe27622f{padding:0}.m_fe27622f:where([data-with-spacing]){padding:calc(.03125rem * var(--mantine-scale))}.m_730a79ed{--dch-control-size-xs: calc(1.875rem * var(--mantine-scale));--dch-control-size-sm: calc(2.25rem * var(--mantine-scale));--dch-control-size-md: calc(2.625rem * var(--mantine-scale));--dch-control-size-lg: calc(3rem * var(--mantine-scale));--dch-control-size-xl: calc(3.375rem * var(--mantine-scale));--dch-control-size: var(--dch-control-size-sm);display:flex;max-width:calc(var(--dch-control-size) * 7 + calc(.4375rem * var(--mantine-scale)));margin-bottom:var(--mantine-spacing-xs)}.m_f6645d97,.m_2351eeb0{height:var(--dch-control-size);border-radius:var(--mantine-radius-default);display:flex;justify-content:center;align-items:center;-webkit-user-select:none;user-select:none;opacity:1;cursor:pointer}@media (hover: hover){[data-mantine-color-scheme=light] .m_f6645d97:hover:where(:not([data-disabled],:disabled)),[data-mantine-color-scheme=light] .m_2351eeb0:hover:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_f6645d97:hover:where(:not([data-disabled],:disabled)),[data-mantine-color-scheme=dark] .m_2351eeb0:hover:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-dark-5)}}@media (hover: none){[data-mantine-color-scheme=light] .m_f6645d97:active:where(:not([data-disabled],:disabled)),[data-mantine-color-scheme=light] .m_2351eeb0:active:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-gray-0)}[data-mantine-color-scheme=dark] .m_f6645d97:active:where(:not([data-disabled],:disabled)),[data-mantine-color-scheme=dark] .m_2351eeb0:active:where(:not([data-disabled],:disabled)){background-color:var(--mantine-color-dark-5)}}.m_f6645d97:where(:disabled,[data-disabled]),.m_2351eeb0:where(:disabled,[data-disabled]){opacity:.2;cursor:not-allowed}.m_2351eeb0{width:var(--dch-control-size)}.m_f6645d97{flex:1;font-size:var(--dch-fz, var(--mantine-font-size-sm));font-weight:500;text-transform:capitalize}.m_367dc749{width:60%;height:60%}.m_367dc749:where([data-direction=next]){transform:rotate(270deg)}:where([dir=rtl]) .m_367dc749:where([data-direction=next]){transform:rotate(90deg)}.m_367dc749:where([data-direction=previous]){transform:rotate(90deg)}:where([dir=rtl]) .m_367dc749:where([data-direction=previous]){transform:rotate(270deg)}.m_30b26e33{display:flex;gap:var(--mantine-spacing-md)}.m_6fa5e2aa{cursor:pointer;line-height:unset}.m_6fa5e2aa:where([data-read-only]){cursor:default}.m_208d2562{display:flex;align-items:stretch;margin-top:var(--mantine-spacing-md)}.m_62ee059{flex:1;margin-inline-end:var(--mantine-spacing-md)}._nav_mbz2l_1{height:64px;margin-top:20px}@media (max-width: 900px):{._nav_mbz2l_1{max-width:100%;min-width:100%;width:100%}}._nav_mbz2l_1{gap:2rem;align-items:"center"}._wrapper_mbz2l_20{max-width:900px;border-radius:8px;margin:10px auto 0}._maincontainer_mbz2l_31{display:flex;align-items:center;justify-content:space-between;flex-direction:row}@media (max-width: 500px){._network_mbz2l_42{visibility:hidden}}._buttonContainer_mbz2l_49{width:30px;height:30px;padding:2px;border-radius:4px,}._container_mbz2l_59{padding-left:20px;padding-right:20px;display:flex;align-items:center;justify-content:center;flex-direction:row}._mode_mbz2l_68{display:"flex";align-items:"center";justify-content:"center";flex-direction:"row"}._root_mbz2l_78{position:"relative"}._icon_mbz2l_85{pointer-events:"none";position:"absolute";z-index:1;top:3}._iconLight_mbz2l_92{left:4}._iconDark_mbz2l_97{right:4}._homeContainer_it9to_47{max-width:600px;margin:0 auto}._avatar_it9to_55{height:200px;width:200px}._avatarContainer_it9to_62{display:flex;align-items:center;margin:20px;justify-content:center;flex-direction:row}._safe_it9to_71{width:130px;margin:20px}._safeContainer_it9to_78{display:flex;align-items:center;justify-content:center;flex-direction:column}._formContainer_it9to_86{border-radius:12px;border:0px solid #4a4a4a;padding:80px}._heading_it9to_93{font-size:43px;background:#00ff00;background:-webkit-linear-gradient(to left,#6fa56f 0%,#00ffff 100%);background:-moz-linear-gradient(to left,#6b9c6b 0%,#00ffff 100%);background:linear-gradient(to left,#00ff00 0%,#00ffff 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent;text-align:center;font-weight:700;margin-bottom:0}._actions_it9to_6{margin-top:20px;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:20px;margin-bottom:20px}._links_it9to_117{margin-top:0;font-size:35px;text-align:center;font-weight:700;color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] ._links_it9to_117{color:var(--mantine-color-white-2)}._subHeading_it9to_125{padding-top:15px;font-size:16px;text-align:center}._topHeading_it9to_131{padding-top:15px;font-size:16px;color:#868e96}._inputContainer_it9to_140{display:flex;flex-direction:column;gap:10px;margin-bottom:20px;margin-top:20px}._selectGroup_it9to_152{display:flex;align-items:center;justify-content:center}._btn_it9to_158{background-image:linear-gradient(to right,#1d976c 0%,#93f9b9 51%,#1d976c 100%);transition:.5s;background-size:200% auto;color:#fff}._card_it9to_170{position:relative;overflow:visible;padding:var(--mantine-spacing-xl)}._btn_it9to_158:hover{background-position:right center;color:#fff;text-decoration:none}._helperText_it9to_183{font-size:16px}._mode_it9to_187{padding-left:20px;display:"flex";align-items:"center";justify-content:"center";flex-direction:"row"}._successContainer_it9to_197{width:600px;margin:80px auto 0;border-radius:12px;border:0px solid #4a4a4a;background-color:#fff;box-shadow:0 1px 2px #1018280d}._network_it9to_207{padding:10px;margin-left:5px}._copyContainer_it9to_215{display:flex;align-items:center;gap:20px}._goBack_it9to_221{margin-top:20px}._input_it9to_140{width:100%;cursor:pointer}@media screen and (max-width: 600px){._successContainer_it9to_197{width:100%}._copyContainer_it9to_215{flex-direction:column}._input_it9to_140{width:100%;cursor:pointer}._btn_it9to_158{width:100%}}._accountContainer_1ox68_3{max-width:500px;margin:80px auto 0;border-radius:12px;border:0px solid #4a4a4a;background-color:#fff d}._formContainer_1ox68_15{padding:20px;display:flex;align-items:center;justify-content:center;flex-direction:column}._avatarContainer_1ox68_24{display:flex;align-items:center;justify-content:center;flex-direction:column}._balance_1ox68_32{font-size:30px;font-weight:700}._avatar_1ox68_24{height:60px;width:60px;margin-top:20px;margin-bottom:20px;border-radius:50%}._heading_1ox68_45{text-align:center;background:#00FF00;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._btn_1ox68_56{background-image:linear-gradient(to right,#1d976c 0%,#93f9b9 51%,#1d976c 100%);transition:.5s;background-size:200% auto;color:#fff}._btn_1ox68_56:hover{background-position:right center;color:#fff;text-decoration:none}._actionsContainer_1ox68_71{display:flex;align-items:center;justify-content:center;flex-direction:column}._subHeading_1ox68_79{padding-top:15px;font-size:16px;font-weight:600;text-align:center}._footerHeading_1ox68_86{font-size:14px;text-align:center}._balanceContainer_1ox68_91{display:flex;flex-direction:row;align-items:center;justify-content:center;gap:5px}._actions_1ox68_71{margin-top:20px;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:20px;margin-bottom:20px}._inputContainer_1ox68_109{justify-content:center;gap:20px;display:flex;flex-direction:column;margin-bottom:20px}._accountInputContainer_1ox68_119{display:flex;flex-direction:column}._card_1ox68_128{position:relative;overflow:visible;padding:var(--mantine-spacing-xl)}._icon_1ox68_135{position:absolute;top:calc(-1.25rem * var(--mantine-scale));left:calc(50% - calc(1.875rem * var(--mantine-scale)))}._title_1ox68_141{font-family:Greycliff CF,var(--mantine-font-family);line-height:1}._claimHeading_1ox68_148{margin-bottom:0;text-align:center;background:#00FF00;font-size:35px;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._claimInner_1ox68_161{display:flex;align-items:center;margin-top:0;margin-bottom:0;text-align:center;justify-content:center;background:#00FF00;column-gap:20px;font-size:45px;background:-webkit-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:-moz-linear-gradient(to left,#00FF00 0%,#00FFFF 100%);background:linear-gradient(to left,#00FF00 0%,#00FFFF 100%);-webkit-background-clip:text;-webkit-text-fill-color:transparent}._links_1ox68_178{margin-top:0;font-size:35px;text-align:center;font-weight:700;color:var(--mantine-color-gray-7)}[data-mantine-color-scheme=dark] ._links_1ox68_178{color:var(--mantine-color-white-2)} diff --git a/assets/index-fb499c6a.js b/assets/index-fb499c6a.js new file mode 100644 index 00000000..1a89fb53 --- /dev/null +++ b/assets/index-fb499c6a.js @@ -0,0 +1,216 @@ +var s1=Object.defineProperty;var o1=(c,a,d)=>a in c?s1(c,a,{enumerable:!0,configurable:!0,writable:!0,value:d}):c[a]=d;var G0=(c,a,d)=>(o1(c,typeof a!="symbol"?a+"":a,d),d),Fo=(c,a,d)=>{if(!a.has(c))throw TypeError("Cannot "+d)};var s0=(c,a,d)=>(Fo(c,a,"read from private field"),d?d.call(c):a.get(c)),q0=(c,a,d)=>{if(a.has(c))throw TypeError("Cannot add the same private member more than once");a instanceof WeakSet?a.add(c):a.set(c,d)},m0=(c,a,d,et)=>(Fo(c,a,"write to private field"),et?et.call(c,d):a.set(c,d),d);var Ws=(c,a,d,et)=>({set _(nt){m0(c,a,nt,d)},get _(){return s0(c,a,et)}}),W0=(c,a,d)=>(Fo(c,a,"access private method"),d);function _mergeNamespaces(c,a){for(var d=0;det[nt]})}}}return Object.freeze(Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}))}(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const nt of document.querySelectorAll('link[rel="modulepreload"]'))et(nt);new MutationObserver(nt=>{for(const tt of nt)if(tt.type==="childList")for(const bt of tt.addedNodes)bt.tagName==="LINK"&&bt.rel==="modulepreload"&&et(bt)}).observe(document,{childList:!0,subtree:!0});function d(nt){const tt={};return nt.integrity&&(tt.integrity=nt.integrity),nt.referrerPolicy&&(tt.referrerPolicy=nt.referrerPolicy),nt.crossOrigin==="use-credentials"?tt.credentials="include":nt.crossOrigin==="anonymous"?tt.credentials="omit":tt.credentials="same-origin",tt}function et(nt){if(nt.ep)return;nt.ep=!0;const tt=d(nt);fetch(nt.href,tt)}})();var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}var bufferPolyfill={},base64Js={};base64Js.byteLength=byteLength;base64Js.toByteArray=toByteArray;base64Js.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var i=0,len=code.length;i0)throw new Error("Invalid string. Length must be a multiple of 4");var d=c.indexOf("=");d===-1&&(d=a);var et=d===a?0:4-d%4;return[d,et]}function byteLength(c){var a=getLens(c),d=a[0],et=a[1];return(d+et)*3/4-et}function _byteLength(c,a,d){return(a+d)*3/4-d}function toByteArray(c){var a,d=getLens(c),et=d[0],nt=d[1],tt=new Arr(_byteLength(c,et,nt)),bt=0,mt=nt>0?et-4:et,vt;for(vt=0;vt>16&255,tt[bt++]=a>>8&255,tt[bt++]=a&255;return nt===2&&(a=revLookup[c.charCodeAt(vt)]<<2|revLookup[c.charCodeAt(vt+1)]>>4,tt[bt++]=a&255),nt===1&&(a=revLookup[c.charCodeAt(vt)]<<10|revLookup[c.charCodeAt(vt+1)]<<4|revLookup[c.charCodeAt(vt+2)]>>2,tt[bt++]=a>>8&255,tt[bt++]=a&255),tt}function tripletToBase64(c){return lookup[c>>18&63]+lookup[c>>12&63]+lookup[c>>6&63]+lookup[c&63]}function encodeChunk(c,a,d){for(var et,nt=[],tt=a;ttmt?mt:bt+tt));return et===1?(a=c[d-1],nt.push(lookup[a>>2]+lookup[a<<4&63]+"==")):et===2&&(a=(c[d-2]<<8)+c[d-1],nt.push(lookup[a>>10]+lookup[a>>4&63]+lookup[a<<2&63]+"=")),nt.join("")}var ieee754={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */ieee754.read=function(c,a,d,et,nt){var tt,bt,mt=nt*8-et-1,vt=(1<>1,At=-7,Mt=d?nt-1:0,Tt=d?-1:1,Rt=c[a+Mt];for(Mt+=Tt,tt=Rt&(1<<-At)-1,Rt>>=-At,At+=mt;At>0;tt=tt*256+c[a+Mt],Mt+=Tt,At-=8);for(bt=tt&(1<<-At)-1,tt>>=-At,At+=et;At>0;bt=bt*256+c[a+Mt],Mt+=Tt,At-=8);if(tt===0)tt=1-$t;else{if(tt===vt)return bt?NaN:(Rt?-1:1)*(1/0);bt=bt+Math.pow(2,et),tt=tt-$t}return(Rt?-1:1)*bt*Math.pow(2,tt-et)};ieee754.write=function(c,a,d,et,nt,tt){var bt,mt,vt,$t=tt*8-nt-1,At=(1<<$t)-1,Mt=At>>1,Tt=nt===23?Math.pow(2,-24)-Math.pow(2,-77):0,Rt=et?0:tt-1,kt=et?1:-1,It=a<0||a===0&&1/a<0?1:0;for(a=Math.abs(a),isNaN(a)||a===1/0?(mt=isNaN(a)?1:0,bt=At):(bt=Math.floor(Math.log(a)/Math.LN2),a*(vt=Math.pow(2,-bt))<1&&(bt--,vt*=2),bt+Mt>=1?a+=Tt/vt:a+=Tt*Math.pow(2,1-Mt),a*vt>=2&&(bt++,vt/=2),bt+Mt>=At?(mt=0,bt=At):bt+Mt>=1?(mt=(a*vt-1)*Math.pow(2,nt),bt=bt+Mt):(mt=a*Math.pow(2,Mt-1)*Math.pow(2,nt),bt=0));nt>=8;c[d+Rt]=mt&255,Rt+=kt,mt/=256,nt-=8);for(bt=bt<0;c[d+Rt]=bt&255,Rt+=kt,bt/=256,$t-=8);c[d+Rt-kt]|=It*128};/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */(function(c){const a=base64Js,d=ieee754,et=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;c.Buffer=mt,c.SlowBuffer=Ot,c.INSPECT_MAX_BYTES=50;const nt=2147483647;c.kMaxLength=nt,mt.TYPED_ARRAY_SUPPORT=tt(),!mt.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function tt(){try{const Qt=new Uint8Array(1),Ht={foo:function(){return 42}};return Object.setPrototypeOf(Ht,Uint8Array.prototype),Object.setPrototypeOf(Qt,Ht),Qt.foo()===42}catch{return!1}}Object.defineProperty(mt.prototype,"parent",{enumerable:!0,get:function(){if(mt.isBuffer(this))return this.buffer}}),Object.defineProperty(mt.prototype,"offset",{enumerable:!0,get:function(){if(mt.isBuffer(this))return this.byteOffset}});function bt(Qt){if(Qt>nt)throw new RangeError('The value "'+Qt+'" is invalid for option "size"');const Ht=new Uint8Array(Qt);return Object.setPrototypeOf(Ht,mt.prototype),Ht}function mt(Qt,Ht,Yt){if(typeof Qt=="number"){if(typeof Ht=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return Mt(Qt)}return vt(Qt,Ht,Yt)}mt.poolSize=8192;function vt(Qt,Ht,Yt){if(typeof Qt=="string")return Tt(Qt,Ht);if(ArrayBuffer.isView(Qt))return kt(Qt);if(Qt==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Qt);if(E0(Qt,ArrayBuffer)||Qt&&E0(Qt.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(E0(Qt,SharedArrayBuffer)||Qt&&E0(Qt.buffer,SharedArrayBuffer)))return It(Qt,Ht,Yt);if(typeof Qt=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const r0=Qt.valueOf&&Qt.valueOf();if(r0!=null&&r0!==Qt)return mt.from(r0,Ht,Yt);const f0=Dt(Qt);if(f0)return f0;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof Qt[Symbol.toPrimitive]=="function")return mt.from(Qt[Symbol.toPrimitive]("string"),Ht,Yt);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Qt)}mt.from=function(Qt,Ht,Yt){return vt(Qt,Ht,Yt)},Object.setPrototypeOf(mt.prototype,Uint8Array.prototype),Object.setPrototypeOf(mt,Uint8Array);function $t(Qt){if(typeof Qt!="number")throw new TypeError('"size" argument must be of type number');if(Qt<0)throw new RangeError('The value "'+Qt+'" is invalid for option "size"')}function At(Qt,Ht,Yt){return $t(Qt),Qt<=0?bt(Qt):Ht!==void 0?typeof Yt=="string"?bt(Qt).fill(Ht,Yt):bt(Qt).fill(Ht):bt(Qt)}mt.alloc=function(Qt,Ht,Yt){return At(Qt,Ht,Yt)};function Mt(Qt){return $t(Qt),bt(Qt<0?0:Nt(Qt)|0)}mt.allocUnsafe=function(Qt){return Mt(Qt)},mt.allocUnsafeSlow=function(Qt){return Mt(Qt)};function Tt(Qt,Ht){if((typeof Ht!="string"||Ht==="")&&(Ht="utf8"),!mt.isEncoding(Ht))throw new TypeError("Unknown encoding: "+Ht);const Yt=Ut(Qt,Ht)|0;let r0=bt(Yt);const f0=r0.write(Qt,Ht);return f0!==Yt&&(r0=r0.slice(0,f0)),r0}function Rt(Qt){const Ht=Qt.length<0?0:Nt(Qt.length)|0,Yt=bt(Ht);for(let r0=0;r0=nt)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+nt.toString(16)+" bytes");return Qt|0}function Ot(Qt){return+Qt!=Qt&&(Qt=0),mt.alloc(+Qt)}mt.isBuffer=function(Ht){return Ht!=null&&Ht._isBuffer===!0&&Ht!==mt.prototype},mt.compare=function(Ht,Yt){if(E0(Ht,Uint8Array)&&(Ht=mt.from(Ht,Ht.offset,Ht.byteLength)),E0(Yt,Uint8Array)&&(Yt=mt.from(Yt,Yt.offset,Yt.byteLength)),!mt.isBuffer(Ht)||!mt.isBuffer(Yt))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(Ht===Yt)return 0;let r0=Ht.length,f0=Yt.length;for(let x0=0,d0=Math.min(r0,f0);x0f0.length?(mt.isBuffer(d0)||(d0=mt.from(d0)),d0.copy(f0,x0)):Uint8Array.prototype.set.call(f0,d0,x0);else if(mt.isBuffer(d0))d0.copy(f0,x0);else throw new TypeError('"list" argument must be an Array of Buffers');x0+=d0.length}return f0};function Ut(Qt,Ht){if(mt.isBuffer(Qt))return Qt.length;if(ArrayBuffer.isView(Qt)||E0(Qt,ArrayBuffer))return Qt.byteLength;if(typeof Qt!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof Qt);const Yt=Qt.length,r0=arguments.length>2&&arguments[2]===!0;if(!r0&&Yt===0)return 0;let f0=!1;for(;;)switch(Ht){case"ascii":case"latin1":case"binary":return Yt;case"utf8":case"utf-8":return $0(Qt).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Yt*2;case"hex":return Yt>>>1;case"base64":return J0(Qt).length;default:if(f0)return r0?-1:$0(Qt).length;Ht=(""+Ht).toLowerCase(),f0=!0}}mt.byteLength=Ut;function Gt(Qt,Ht,Yt){let r0=!1;if((Ht===void 0||Ht<0)&&(Ht=0),Ht>this.length||((Yt===void 0||Yt>this.length)&&(Yt=this.length),Yt<=0)||(Yt>>>=0,Ht>>>=0,Yt<=Ht))return"";for(Qt||(Qt="utf8");;)switch(Qt){case"hex":return Et(this,Ht,Yt);case"utf8":case"utf-8":return gt(this,Ht,Yt);case"ascii":return _t(this,Ht,Yt);case"latin1":case"binary":return Pt(this,Ht,Yt);case"base64":return yt(this,Ht,Yt);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ht(this,Ht,Yt);default:if(r0)throw new TypeError("Unknown encoding: "+Qt);Qt=(Qt+"").toLowerCase(),r0=!0}}mt.prototype._isBuffer=!0;function Wt(Qt,Ht,Yt){const r0=Qt[Ht];Qt[Ht]=Qt[Yt],Qt[Yt]=r0}mt.prototype.swap16=function(){const Ht=this.length;if(Ht%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let Yt=0;YtYt&&(Ht+=" ... "),""},et&&(mt.prototype[et]=mt.prototype.inspect),mt.prototype.compare=function(Ht,Yt,r0,f0,x0){if(E0(Ht,Uint8Array)&&(Ht=mt.from(Ht,Ht.offset,Ht.byteLength)),!mt.isBuffer(Ht))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof Ht);if(Yt===void 0&&(Yt=0),r0===void 0&&(r0=Ht?Ht.length:0),f0===void 0&&(f0=0),x0===void 0&&(x0=this.length),Yt<0||r0>Ht.length||f0<0||x0>this.length)throw new RangeError("out of range index");if(f0>=x0&&Yt>=r0)return 0;if(f0>=x0)return-1;if(Yt>=r0)return 1;if(Yt>>>=0,r0>>>=0,f0>>>=0,x0>>>=0,this===Ht)return 0;let d0=x0-f0,y0=r0-Yt;const Q0=Math.min(d0,y0),g0=this.slice(f0,x0),A0=Ht.slice(Yt,r0);for(let Y0=0;Y02147483647?Yt=2147483647:Yt<-2147483648&&(Yt=-2147483648),Yt=+Yt,Z0(Yt)&&(Yt=f0?0:Qt.length-1),Yt<0&&(Yt=Qt.length+Yt),Yt>=Qt.length){if(f0)return-1;Yt=Qt.length-1}else if(Yt<0)if(f0)Yt=0;else return-1;if(typeof Ht=="string"&&(Ht=mt.from(Ht,r0)),mt.isBuffer(Ht))return Ht.length===0?-1:a0(Qt,Ht,Yt,r0,f0);if(typeof Ht=="number")return Ht=Ht&255,typeof Uint8Array.prototype.indexOf=="function"?f0?Uint8Array.prototype.indexOf.call(Qt,Ht,Yt):Uint8Array.prototype.lastIndexOf.call(Qt,Ht,Yt):a0(Qt,[Ht],Yt,r0,f0);throw new TypeError("val must be string, number or Buffer")}function a0(Qt,Ht,Yt,r0,f0){let x0=1,d0=Qt.length,y0=Ht.length;if(r0!==void 0&&(r0=String(r0).toLowerCase(),r0==="ucs2"||r0==="ucs-2"||r0==="utf16le"||r0==="utf-16le")){if(Qt.length<2||Ht.length<2)return-1;x0=2,d0/=2,y0/=2,Yt/=2}function Q0(A0,Y0){return x0===1?A0[Y0]:A0.readUInt16BE(Y0*x0)}let g0;if(f0){let A0=-1;for(g0=Yt;g0d0&&(Yt=d0-y0),g0=Yt;g0>=0;g0--){let A0=!0;for(let Y0=0;Y0f0&&(r0=f0)):r0=f0;const x0=Ht.length;r0>x0/2&&(r0=x0/2);let d0;for(d0=0;d0>>0,isFinite(r0)?(r0=r0>>>0,f0===void 0&&(f0="utf8")):(f0=r0,r0=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const x0=this.length-Yt;if((r0===void 0||r0>x0)&&(r0=x0),Ht.length>0&&(r0<0||Yt<0)||Yt>this.length)throw new RangeError("Attempt to write outside buffer bounds");f0||(f0="utf8");let d0=!1;for(;;)switch(f0){case"hex":return n0(this,Ht,Yt,r0);case"utf8":case"utf-8":return t0(this,Ht,Yt,r0);case"ascii":case"latin1":case"binary":return c0(this,Ht,Yt,r0);case"base64":return Ct(this,Ht,Yt,r0);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return dt(this,Ht,Yt,r0);default:if(d0)throw new TypeError("Unknown encoding: "+f0);f0=(""+f0).toLowerCase(),d0=!0}},mt.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function yt(Qt,Ht,Yt){return Ht===0&&Yt===Qt.length?a.fromByteArray(Qt):a.fromByteArray(Qt.slice(Ht,Yt))}function gt(Qt,Ht,Yt){Yt=Math.min(Qt.length,Yt);const r0=[];let f0=Ht;for(;f0239?4:x0>223?3:x0>191?2:1;if(f0+y0<=Yt){let Q0,g0,A0,Y0;switch(y0){case 1:x0<128&&(d0=x0);break;case 2:Q0=Qt[f0+1],(Q0&192)===128&&(Y0=(x0&31)<<6|Q0&63,Y0>127&&(d0=Y0));break;case 3:Q0=Qt[f0+1],g0=Qt[f0+2],(Q0&192)===128&&(g0&192)===128&&(Y0=(x0&15)<<12|(Q0&63)<<6|g0&63,Y0>2047&&(Y0<55296||Y0>57343)&&(d0=Y0));break;case 4:Q0=Qt[f0+1],g0=Qt[f0+2],A0=Qt[f0+3],(Q0&192)===128&&(g0&192)===128&&(A0&192)===128&&(Y0=(x0&15)<<18|(Q0&63)<<12|(g0&63)<<6|A0&63,Y0>65535&&Y0<1114112&&(d0=Y0))}}d0===null?(d0=65533,y0=1):d0>65535&&(d0-=65536,r0.push(d0>>>10&1023|55296),d0=56320|d0&1023),r0.push(d0),f0+=y0}return St(r0)}const xt=4096;function St(Qt){const Ht=Qt.length;if(Ht<=xt)return String.fromCharCode.apply(String,Qt);let Yt="",r0=0;for(;r0r0)&&(Yt=r0);let f0="";for(let x0=Ht;x0r0&&(Ht=r0),Yt<0?(Yt+=r0,Yt<0&&(Yt=0)):Yt>r0&&(Yt=r0),YtYt)throw new RangeError("Trying to access beyond buffer length")}mt.prototype.readUintLE=mt.prototype.readUIntLE=function(Ht,Yt,r0){Ht=Ht>>>0,Yt=Yt>>>0,r0||wt(Ht,Yt,this.length);let f0=this[Ht],x0=1,d0=0;for(;++d0>>0,Yt=Yt>>>0,r0||wt(Ht,Yt,this.length);let f0=this[Ht+--Yt],x0=1;for(;Yt>0&&(x0*=256);)f0+=this[Ht+--Yt]*x0;return f0},mt.prototype.readUint8=mt.prototype.readUInt8=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,1,this.length),this[Ht]},mt.prototype.readUint16LE=mt.prototype.readUInt16LE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,2,this.length),this[Ht]|this[Ht+1]<<8},mt.prototype.readUint16BE=mt.prototype.readUInt16BE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,2,this.length),this[Ht]<<8|this[Ht+1]},mt.prototype.readUint32LE=mt.prototype.readUInt32LE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,4,this.length),(this[Ht]|this[Ht+1]<<8|this[Ht+2]<<16)+this[Ht+3]*16777216},mt.prototype.readUint32BE=mt.prototype.readUInt32BE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,4,this.length),this[Ht]*16777216+(this[Ht+1]<<16|this[Ht+2]<<8|this[Ht+3])},mt.prototype.readBigUInt64LE=b0(function(Ht){Ht=Ht>>>0,i0(Ht,"offset");const Yt=this[Ht],r0=this[Ht+7];(Yt===void 0||r0===void 0)&&h0(Ht,this.length-8);const f0=Yt+this[++Ht]*2**8+this[++Ht]*2**16+this[++Ht]*2**24,x0=this[++Ht]+this[++Ht]*2**8+this[++Ht]*2**16+r0*2**24;return BigInt(f0)+(BigInt(x0)<>>0,i0(Ht,"offset");const Yt=this[Ht],r0=this[Ht+7];(Yt===void 0||r0===void 0)&&h0(Ht,this.length-8);const f0=Yt*2**24+this[++Ht]*2**16+this[++Ht]*2**8+this[++Ht],x0=this[++Ht]*2**24+this[++Ht]*2**16+this[++Ht]*2**8+r0;return(BigInt(f0)<>>0,Yt=Yt>>>0,r0||wt(Ht,Yt,this.length);let f0=this[Ht],x0=1,d0=0;for(;++d0=x0&&(f0-=Math.pow(2,8*Yt)),f0},mt.prototype.readIntBE=function(Ht,Yt,r0){Ht=Ht>>>0,Yt=Yt>>>0,r0||wt(Ht,Yt,this.length);let f0=Yt,x0=1,d0=this[Ht+--f0];for(;f0>0&&(x0*=256);)d0+=this[Ht+--f0]*x0;return x0*=128,d0>=x0&&(d0-=Math.pow(2,8*Yt)),d0},mt.prototype.readInt8=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,1,this.length),this[Ht]&128?(255-this[Ht]+1)*-1:this[Ht]},mt.prototype.readInt16LE=function(Ht,Yt){Ht=Ht>>>0,Yt||wt(Ht,2,this.length);const r0=this[Ht]|this[Ht+1]<<8;return r0&32768?r0|4294901760:r0},mt.prototype.readInt16BE=function(Ht,Yt){Ht=Ht>>>0,Yt||wt(Ht,2,this.length);const r0=this[Ht+1]|this[Ht]<<8;return r0&32768?r0|4294901760:r0},mt.prototype.readInt32LE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,4,this.length),this[Ht]|this[Ht+1]<<8|this[Ht+2]<<16|this[Ht+3]<<24},mt.prototype.readInt32BE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,4,this.length),this[Ht]<<24|this[Ht+1]<<16|this[Ht+2]<<8|this[Ht+3]},mt.prototype.readBigInt64LE=b0(function(Ht){Ht=Ht>>>0,i0(Ht,"offset");const Yt=this[Ht],r0=this[Ht+7];(Yt===void 0||r0===void 0)&&h0(Ht,this.length-8);const f0=this[Ht+4]+this[Ht+5]*2**8+this[Ht+6]*2**16+(r0<<24);return(BigInt(f0)<>>0,i0(Ht,"offset");const Yt=this[Ht],r0=this[Ht+7];(Yt===void 0||r0===void 0)&&h0(Ht,this.length-8);const f0=(Yt<<24)+this[++Ht]*2**16+this[++Ht]*2**8+this[++Ht];return(BigInt(f0)<>>0,Yt||wt(Ht,4,this.length),d.read(this,Ht,!0,23,4)},mt.prototype.readFloatBE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,4,this.length),d.read(this,Ht,!1,23,4)},mt.prototype.readDoubleLE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,8,this.length),d.read(this,Ht,!0,52,8)},mt.prototype.readDoubleBE=function(Ht,Yt){return Ht=Ht>>>0,Yt||wt(Ht,8,this.length),d.read(this,Ht,!1,52,8)};function Bt(Qt,Ht,Yt,r0,f0,x0){if(!mt.isBuffer(Qt))throw new TypeError('"buffer" argument must be a Buffer instance');if(Ht>f0||HtQt.length)throw new RangeError("Index out of range")}mt.prototype.writeUintLE=mt.prototype.writeUIntLE=function(Ht,Yt,r0,f0){if(Ht=+Ht,Yt=Yt>>>0,r0=r0>>>0,!f0){const y0=Math.pow(2,8*r0)-1;Bt(this,Ht,Yt,r0,y0,0)}let x0=1,d0=0;for(this[Yt]=Ht&255;++d0>>0,r0=r0>>>0,!f0){const y0=Math.pow(2,8*r0)-1;Bt(this,Ht,Yt,r0,y0,0)}let x0=r0-1,d0=1;for(this[Yt+x0]=Ht&255;--x0>=0&&(d0*=256);)this[Yt+x0]=Ht/d0&255;return Yt+r0},mt.prototype.writeUint8=mt.prototype.writeUInt8=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,1,255,0),this[Yt]=Ht&255,Yt+1},mt.prototype.writeUint16LE=mt.prototype.writeUInt16LE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,2,65535,0),this[Yt]=Ht&255,this[Yt+1]=Ht>>>8,Yt+2},mt.prototype.writeUint16BE=mt.prototype.writeUInt16BE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,2,65535,0),this[Yt]=Ht>>>8,this[Yt+1]=Ht&255,Yt+2},mt.prototype.writeUint32LE=mt.prototype.writeUInt32LE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,4,4294967295,0),this[Yt+3]=Ht>>>24,this[Yt+2]=Ht>>>16,this[Yt+1]=Ht>>>8,this[Yt]=Ht&255,Yt+4},mt.prototype.writeUint32BE=mt.prototype.writeUInt32BE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,4,4294967295,0),this[Yt]=Ht>>>24,this[Yt+1]=Ht>>>16,this[Yt+2]=Ht>>>8,this[Yt+3]=Ht&255,Yt+4};function Lt(Qt,Ht,Yt,r0,f0){Jt(Ht,r0,f0,Qt,Yt,7);let x0=Number(Ht&BigInt(4294967295));Qt[Yt++]=x0,x0=x0>>8,Qt[Yt++]=x0,x0=x0>>8,Qt[Yt++]=x0,x0=x0>>8,Qt[Yt++]=x0;let d0=Number(Ht>>BigInt(32)&BigInt(4294967295));return Qt[Yt++]=d0,d0=d0>>8,Qt[Yt++]=d0,d0=d0>>8,Qt[Yt++]=d0,d0=d0>>8,Qt[Yt++]=d0,Yt}function jt(Qt,Ht,Yt,r0,f0){Jt(Ht,r0,f0,Qt,Yt,7);let x0=Number(Ht&BigInt(4294967295));Qt[Yt+7]=x0,x0=x0>>8,Qt[Yt+6]=x0,x0=x0>>8,Qt[Yt+5]=x0,x0=x0>>8,Qt[Yt+4]=x0;let d0=Number(Ht>>BigInt(32)&BigInt(4294967295));return Qt[Yt+3]=d0,d0=d0>>8,Qt[Yt+2]=d0,d0=d0>>8,Qt[Yt+1]=d0,d0=d0>>8,Qt[Yt]=d0,Yt+8}mt.prototype.writeBigUInt64LE=b0(function(Ht,Yt=0){return Lt(this,Ht,Yt,BigInt(0),BigInt("0xffffffffffffffff"))}),mt.prototype.writeBigUInt64BE=b0(function(Ht,Yt=0){return jt(this,Ht,Yt,BigInt(0),BigInt("0xffffffffffffffff"))}),mt.prototype.writeIntLE=function(Ht,Yt,r0,f0){if(Ht=+Ht,Yt=Yt>>>0,!f0){const Q0=Math.pow(2,8*r0-1);Bt(this,Ht,Yt,r0,Q0-1,-Q0)}let x0=0,d0=1,y0=0;for(this[Yt]=Ht&255;++x0>0)-y0&255;return Yt+r0},mt.prototype.writeIntBE=function(Ht,Yt,r0,f0){if(Ht=+Ht,Yt=Yt>>>0,!f0){const Q0=Math.pow(2,8*r0-1);Bt(this,Ht,Yt,r0,Q0-1,-Q0)}let x0=r0-1,d0=1,y0=0;for(this[Yt+x0]=Ht&255;--x0>=0&&(d0*=256);)Ht<0&&y0===0&&this[Yt+x0+1]!==0&&(y0=1),this[Yt+x0]=(Ht/d0>>0)-y0&255;return Yt+r0},mt.prototype.writeInt8=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,1,127,-128),Ht<0&&(Ht=255+Ht+1),this[Yt]=Ht&255,Yt+1},mt.prototype.writeInt16LE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,2,32767,-32768),this[Yt]=Ht&255,this[Yt+1]=Ht>>>8,Yt+2},mt.prototype.writeInt16BE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,2,32767,-32768),this[Yt]=Ht>>>8,this[Yt+1]=Ht&255,Yt+2},mt.prototype.writeInt32LE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,4,2147483647,-2147483648),this[Yt]=Ht&255,this[Yt+1]=Ht>>>8,this[Yt+2]=Ht>>>16,this[Yt+3]=Ht>>>24,Yt+4},mt.prototype.writeInt32BE=function(Ht,Yt,r0){return Ht=+Ht,Yt=Yt>>>0,r0||Bt(this,Ht,Yt,4,2147483647,-2147483648),Ht<0&&(Ht=4294967295+Ht+1),this[Yt]=Ht>>>24,this[Yt+1]=Ht>>>16,this[Yt+2]=Ht>>>8,this[Yt+3]=Ht&255,Yt+4},mt.prototype.writeBigInt64LE=b0(function(Ht,Yt=0){return Lt(this,Ht,Yt,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),mt.prototype.writeBigInt64BE=b0(function(Ht,Yt=0){return jt(this,Ht,Yt,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Ft(Qt,Ht,Yt,r0,f0,x0){if(Yt+r0>Qt.length)throw new RangeError("Index out of range");if(Yt<0)throw new RangeError("Index out of range")}function Vt(Qt,Ht,Yt,r0,f0){return Ht=+Ht,Yt=Yt>>>0,f0||Ft(Qt,Ht,Yt,4),d.write(Qt,Ht,Yt,r0,23,4),Yt+4}mt.prototype.writeFloatLE=function(Ht,Yt,r0){return Vt(this,Ht,Yt,!0,r0)},mt.prototype.writeFloatBE=function(Ht,Yt,r0){return Vt(this,Ht,Yt,!1,r0)};function zt(Qt,Ht,Yt,r0,f0){return Ht=+Ht,Yt=Yt>>>0,f0||Ft(Qt,Ht,Yt,8),d.write(Qt,Ht,Yt,r0,52,8),Yt+8}mt.prototype.writeDoubleLE=function(Ht,Yt,r0){return zt(this,Ht,Yt,!0,r0)},mt.prototype.writeDoubleBE=function(Ht,Yt,r0){return zt(this,Ht,Yt,!1,r0)},mt.prototype.copy=function(Ht,Yt,r0,f0){if(!mt.isBuffer(Ht))throw new TypeError("argument should be a Buffer");if(r0||(r0=0),!f0&&f0!==0&&(f0=this.length),Yt>=Ht.length&&(Yt=Ht.length),Yt||(Yt=0),f0>0&&f0=this.length)throw new RangeError("Index out of range");if(f0<0)throw new RangeError("sourceEnd out of bounds");f0>this.length&&(f0=this.length),Ht.length-Yt>>0,r0=r0===void 0?this.length:r0>>>0,Ht||(Ht=0);let x0;if(typeof Ht=="number")for(x0=Yt;x02**32?f0=e0(String(Yt)):typeof Yt=="bigint"&&(f0=String(Yt),(Yt>BigInt(2)**BigInt(32)||Yt<-(BigInt(2)**BigInt(32)))&&(f0=e0(f0)),f0+="n"),r0+=` It must be ${Ht}. Received ${f0}`,r0},RangeError);function e0(Qt){let Ht="",Yt=Qt.length;const r0=Qt[0]==="-"?1:0;for(;Yt>=r0+4;Yt-=3)Ht=`_${Qt.slice(Yt-3,Yt)}${Ht}`;return`${Qt.slice(0,Yt)}${Ht}`}function Zt(Qt,Ht,Yt){i0(Ht,"offset"),(Qt[Ht]===void 0||Qt[Ht+Yt]===void 0)&&h0(Ht,Qt.length-(Yt+1))}function Jt(Qt,Ht,Yt,r0,f0,x0){if(Qt>Yt||Qt3?Ht===0||Ht===BigInt(0)?y0=`>= 0${d0} and < 2${d0} ** ${(x0+1)*8}${d0}`:y0=`>= -(2${d0} ** ${(x0+1)*8-1}${d0}) and < 2 ** ${(x0+1)*8-1}${d0}`:y0=`>= ${Ht}${d0} and <= ${Yt}${d0}`,new qt.ERR_OUT_OF_RANGE("value",y0,Qt)}Zt(r0,f0,x0)}function i0(Qt,Ht){if(typeof Qt!="number")throw new qt.ERR_INVALID_ARG_TYPE(Ht,"number",Qt)}function h0(Qt,Ht,Yt){throw Math.floor(Qt)!==Qt?(i0(Qt,Yt),new qt.ERR_OUT_OF_RANGE(Yt||"offset","an integer",Qt)):Ht<0?new qt.ERR_BUFFER_OUT_OF_BOUNDS:new qt.ERR_OUT_OF_RANGE(Yt||"offset",`>= ${Yt?1:0} and <= ${Ht}`,Qt)}const o0=/[^+/0-9A-Za-z-_]/g;function l0(Qt){if(Qt=Qt.split("=")[0],Qt=Qt.trim().replace(o0,""),Qt.length<2)return"";for(;Qt.length%4!==0;)Qt=Qt+"=";return Qt}function $0(Qt,Ht){Ht=Ht||1/0;let Yt;const r0=Qt.length;let f0=null;const x0=[];for(let d0=0;d055295&&Yt<57344){if(!f0){if(Yt>56319){(Ht-=3)>-1&&x0.push(239,191,189);continue}else if(d0+1===r0){(Ht-=3)>-1&&x0.push(239,191,189);continue}f0=Yt;continue}if(Yt<56320){(Ht-=3)>-1&&x0.push(239,191,189),f0=Yt;continue}Yt=(f0-55296<<10|Yt-56320)+65536}else f0&&(Ht-=3)>-1&&x0.push(239,191,189);if(f0=null,Yt<128){if((Ht-=1)<0)break;x0.push(Yt)}else if(Yt<2048){if((Ht-=2)<0)break;x0.push(Yt>>6|192,Yt&63|128)}else if(Yt<65536){if((Ht-=3)<0)break;x0.push(Yt>>12|224,Yt>>6&63|128,Yt&63|128)}else if(Yt<1114112){if((Ht-=4)<0)break;x0.push(Yt>>18|240,Yt>>12&63|128,Yt>>6&63|128,Yt&63|128)}else throw new Error("Invalid code point")}return x0}function p0(Qt){const Ht=[];for(let Yt=0;Yt>8,f0=Yt%256,x0.push(f0),x0.push(r0);return x0}function J0(Qt){return a.toByteArray(l0(Qt))}function v0(Qt,Ht,Yt,r0){let f0;for(f0=0;f0=Ht.length||f0>=Qt.length);++f0)Ht[f0+Yt]=Qt[f0];return f0}function E0(Qt,Ht){return Qt instanceof Ht||Qt!=null&&Qt.constructor!=null&&Qt.constructor.name!=null&&Qt.constructor.name===Ht.name}function Z0(Qt){return Qt!==Qt}const w0=function(){const Qt="0123456789abcdef",Ht=new Array(256);for(let Yt=0;Yt<16;++Yt){const r0=Yt*16;for(let f0=0;f0<16;++f0)Ht[r0+f0]=Qt[Yt]+Qt[f0]}return Ht}();function b0(Qt){return typeof BigInt>"u"?K0:Qt}function K0(){throw new Error("BigInt not supported")}})(bufferPolyfill);var browser$c={exports:{}},process$1=browser$c.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(c){if(cachedSetTimeout===setTimeout)return setTimeout(c,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(c,0);try{return cachedSetTimeout(c,0)}catch{try{return cachedSetTimeout.call(null,c,0)}catch{return cachedSetTimeout.call(this,c,0)}}}function runClearTimeout(c){if(cachedClearTimeout===clearTimeout)return clearTimeout(c);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(c);try{return cachedClearTimeout(c)}catch{try{return cachedClearTimeout.call(null,c)}catch{return cachedClearTimeout.call(this,c)}}}var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var c=runTimeout(cleanUpNextTick);draining=!0;for(var a=queue.length;a;){for(currentQueue=queue,queue=[];++queueIndex1)for(var d=1;d>>1,Bt=Pt[wt];if(0>>1;wtnt(Ft,ht))Vtnt(zt,Ft)?(Pt[wt]=zt,Pt[Vt]=ht,wt=Vt):(Pt[wt]=Ft,Pt[jt]=ht,wt=jt);else if(Vtnt(zt,ht))Pt[wt]=zt,Pt[Vt]=ht,wt=Vt;else break e}}return Et}function nt(Pt,Et){var ht=Pt.sortIndex-Et.sortIndex;return ht!==0?ht:Pt.id-Et.id}if(typeof performance=="object"&&typeof performance.now=="function"){var tt=performance;c.unstable_now=function(){return tt.now()}}else{var bt=Date,mt=bt.now();c.unstable_now=function(){return bt.now()-mt}}var vt=[],$t=[],At=1,Mt=null,Tt=3,Rt=!1,kt=!1,It=!1,Dt=typeof setTimeout=="function"?setTimeout:null,Nt=typeof clearTimeout=="function"?clearTimeout:null,Ot=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function Ut(Pt){for(var Et=d($t);Et!==null;){if(Et.callback===null)et($t);else if(Et.startTime<=Pt)et($t),Et.sortIndex=Et.expirationTime,a(vt,Et);else break;Et=d($t)}}function Gt(Pt){if(It=!1,Ut(Pt),!kt)if(d(vt)!==null)kt=!0,St(Wt);else{var Et=d($t);Et!==null&&_t(Gt,Et.startTime-Pt)}}function Wt(Pt,Et){kt=!1,It&&(It=!1,Nt(n0),n0=-1),Rt=!0;var ht=Tt;try{for(Ut(Et),Mt=d(vt);Mt!==null&&(!(Mt.expirationTime>Et)||Pt&&!Ct());){var wt=Mt.callback;if(typeof wt=="function"){Mt.callback=null,Tt=Mt.priorityLevel;var Bt=wt(Mt.expirationTime<=Et);Et=c.unstable_now(),typeof Bt=="function"?Mt.callback=Bt:Mt===d(vt)&&et(vt),Ut(Et)}else et(vt);Mt=d(vt)}if(Mt!==null)var Lt=!0;else{var jt=d($t);jt!==null&&_t(Gt,jt.startTime-Et),Lt=!1}return Lt}finally{Mt=null,Tt=ht,Rt=!1}}var Xt=!1,a0=null,n0=-1,t0=5,c0=-1;function Ct(){return!(c.unstable_now()-c0Pt||125wt?(Pt.sortIndex=ht,a($t,Pt),d(vt)===null&&Pt===d($t)&&(It?(Nt(n0),n0=-1):It=!0,_t(Gt,ht-wt))):(Pt.sortIndex=Bt,a(vt,Pt),kt||Rt||(kt=!0,St(Wt))),Pt},c.unstable_shouldYield=Ct,c.unstable_wrapCallback=function(Pt){var Et=Tt;return function(){var ht=Tt;Tt=Et;try{return Pt.apply(this,arguments)}finally{Tt=ht}}}})(scheduler_production_min);scheduler.exports=scheduler_production_min;var schedulerExports=scheduler.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var aa=reactExports,ca=schedulerExports;function p$2(c){for(var a="https://reactjs.org/docs/error-decoder.html?invariant="+c,d=1;d"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ja=Object.prototype.hasOwnProperty,ka=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,la={},ma={};function oa(c){return ja.call(ma,c)?!0:ja.call(la,c)?!1:ka.test(c)?ma[c]=!0:(la[c]=!0,!1)}function pa(c,a,d,et){if(d!==null&&d.type===0)return!1;switch(typeof a){case"function":case"symbol":return!0;case"boolean":return et?!1:d!==null?!d.acceptsBooleans:(c=c.toLowerCase().slice(0,5),c!=="data-"&&c!=="aria-");default:return!1}}function qa(c,a,d,et){if(a===null||typeof a>"u"||pa(c,a,d,et))return!0;if(et)return!1;if(d!==null)switch(d.type){case 3:return!a;case 4:return a===!1;case 5:return isNaN(a);case 6:return isNaN(a)||1>a}return!1}function v$2(c,a,d,et,nt,tt,bt){this.acceptsBooleans=a===2||a===3||a===4,this.attributeName=et,this.attributeNamespace=nt,this.mustUseProperty=d,this.propertyName=c,this.type=a,this.sanitizeURL=tt,this.removeEmptyString=bt}var z$1={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(c){z$1[c]=new v$2(c,0,!1,c,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(c){var a=c[0];z$1[a]=new v$2(a,1,!1,c[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(c){z$1[c]=new v$2(c,2,!1,c.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(c){z$1[c]=new v$2(c,2,!1,c,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(c){z$1[c]=new v$2(c,3,!1,c.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(c){z$1[c]=new v$2(c,3,!0,c,null,!1,!1)});["capture","download"].forEach(function(c){z$1[c]=new v$2(c,4,!1,c,null,!1,!1)});["cols","rows","size","span"].forEach(function(c){z$1[c]=new v$2(c,6,!1,c,null,!1,!1)});["rowSpan","start"].forEach(function(c){z$1[c]=new v$2(c,5,!1,c.toLowerCase(),null,!1,!1)});var ra=/[\-:]([a-z])/g;function sa(c){return c[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(c){var a=c.replace(ra,sa);z$1[a]=new v$2(a,1,!1,c,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(c){var a=c.replace(ra,sa);z$1[a]=new v$2(a,1,!1,c,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(c){var a=c.replace(ra,sa);z$1[a]=new v$2(a,1,!1,c,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(c){z$1[c]=new v$2(c,1,!1,c.toLowerCase(),null,!1,!1)});z$1.xlinkHref=new v$2("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(c){z$1[c]=new v$2(c,1,!1,c.toLowerCase(),null,!0,!0)});function ta(c,a,d,et){var nt=z$1.hasOwnProperty(a)?z$1[a]:null;(nt!==null?nt.type!==0:et||!(2mt||nt[bt]!==tt[mt]){var vt=` +`+nt[bt].replace(" at new "," at ");return c.displayName&&vt.includes("")&&(vt=vt.replace("",c.displayName)),vt}while(1<=bt&&0<=mt);break}}}finally{Na=!1,Error.prepareStackTrace=d}return(c=c?c.displayName||c.name:"")?Ma(c):""}function Pa(c){switch(c.tag){case 5:return Ma(c.type);case 16:return Ma("Lazy");case 13:return Ma("Suspense");case 19:return Ma("SuspenseList");case 0:case 2:case 15:return c=Oa(c.type,!1),c;case 11:return c=Oa(c.type.render,!1),c;case 1:return c=Oa(c.type,!0),c;default:return""}}function Qa(c){if(c==null)return null;if(typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case ya:return"Fragment";case wa:return"Portal";case Aa:return"Profiler";case za:return"StrictMode";case Ea:return"Suspense";case Fa:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case Ca:return(c.displayName||"Context")+".Consumer";case Ba:return(c._context.displayName||"Context")+".Provider";case Da:var a=c.render;return c=c.displayName,c||(c=a.displayName||a.name||"",c=c!==""?"ForwardRef("+c+")":"ForwardRef"),c;case Ga:return a=c.displayName||null,a!==null?a:Qa(c.type)||"Memo";case Ha:a=c._payload,c=c._init;try{return Qa(c(a))}catch{}}return null}function Ra(c){var a=c.type;switch(c.tag){case 24:return"Cache";case 9:return(a.displayName||"Context")+".Consumer";case 10:return(a._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return c=a.render,c=c.displayName||c.name||"",a.displayName||(c!==""?"ForwardRef("+c+")":"ForwardRef");case 7:return"Fragment";case 5:return a;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Qa(a);case 8:return a===za?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof a=="function")return a.displayName||a.name||null;if(typeof a=="string")return a}return null}function Sa(c){switch(typeof c){case"boolean":case"number":case"string":case"undefined":return c;case"object":return c;default:return""}}function Ta(c){var a=c.type;return(c=c.nodeName)&&c.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function Ua(c){var a=Ta(c)?"checked":"value",d=Object.getOwnPropertyDescriptor(c.constructor.prototype,a),et=""+c[a];if(!c.hasOwnProperty(a)&&typeof d<"u"&&typeof d.get=="function"&&typeof d.set=="function"){var nt=d.get,tt=d.set;return Object.defineProperty(c,a,{configurable:!0,get:function(){return nt.call(this)},set:function(bt){et=""+bt,tt.call(this,bt)}}),Object.defineProperty(c,a,{enumerable:d.enumerable}),{getValue:function(){return et},setValue:function(bt){et=""+bt},stopTracking:function(){c._valueTracker=null,delete c[a]}}}}function Va(c){c._valueTracker||(c._valueTracker=Ua(c))}function Wa(c){if(!c)return!1;var a=c._valueTracker;if(!a)return!0;var d=a.getValue(),et="";return c&&(et=Ta(c)?c.checked?"true":"false":c.value),c=et,c!==d?(a.setValue(c),!0):!1}function Xa(c){if(c=c||(typeof document<"u"?document:void 0),typeof c>"u")return null;try{return c.activeElement||c.body}catch{return c.body}}function Ya(c,a){var d=a.checked;return A$1({},a,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:d??c._wrapperState.initialChecked})}function Za(c,a){var d=a.defaultValue==null?"":a.defaultValue,et=a.checked!=null?a.checked:a.defaultChecked;d=Sa(a.value!=null?a.value:d),c._wrapperState={initialChecked:et,initialValue:d,controlled:a.type==="checkbox"||a.type==="radio"?a.checked!=null:a.value!=null}}function ab(c,a){a=a.checked,a!=null&&ta(c,"checked",a,!1)}function bb(c,a){ab(c,a);var d=Sa(a.value),et=a.type;if(d!=null)et==="number"?(d===0&&c.value===""||c.value!=d)&&(c.value=""+d):c.value!==""+d&&(c.value=""+d);else if(et==="submit"||et==="reset"){c.removeAttribute("value");return}a.hasOwnProperty("value")?cb(c,a.type,d):a.hasOwnProperty("defaultValue")&&cb(c,a.type,Sa(a.defaultValue)),a.checked==null&&a.defaultChecked!=null&&(c.defaultChecked=!!a.defaultChecked)}function db(c,a,d){if(a.hasOwnProperty("value")||a.hasOwnProperty("defaultValue")){var et=a.type;if(!(et!=="submit"&&et!=="reset"||a.value!==void 0&&a.value!==null))return;a=""+c._wrapperState.initialValue,d||a===c.value||(c.value=a),c.defaultValue=a}d=c.name,d!==""&&(c.name=""),c.defaultChecked=!!c._wrapperState.initialChecked,d!==""&&(c.name=d)}function cb(c,a,d){(a!=="number"||Xa(c.ownerDocument)!==c)&&(d==null?c.defaultValue=""+c._wrapperState.initialValue:c.defaultValue!==""+d&&(c.defaultValue=""+d))}var eb=Array.isArray;function fb(c,a,d,et){if(c=c.options,a){a={};for(var nt=0;nt"+a.valueOf().toString()+"",a=mb.firstChild;c.firstChild;)c.removeChild(c.firstChild);for(;a.firstChild;)c.appendChild(a.firstChild)}});function ob(c,a){if(a){var d=c.firstChild;if(d&&d===c.lastChild&&d.nodeType===3){d.nodeValue=a;return}}c.textContent=a}var pb={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},qb=["Webkit","ms","Moz","O"];Object.keys(pb).forEach(function(c){qb.forEach(function(a){a=a+c.charAt(0).toUpperCase()+c.substring(1),pb[a]=pb[c]})});function rb(c,a,d){return a==null||typeof a=="boolean"||a===""?"":d||typeof a!="number"||a===0||pb.hasOwnProperty(c)&&pb[c]?(""+a).trim():a+"px"}function sb(c,a){c=c.style;for(var d in a)if(a.hasOwnProperty(d)){var et=d.indexOf("--")===0,nt=rb(d,a[d],et);d==="float"&&(d="cssFloat"),et?c.setProperty(d,nt):c[d]=nt}}var tb=A$1({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ub(c,a){if(a){if(tb[c]&&(a.children!=null||a.dangerouslySetInnerHTML!=null))throw Error(p$2(137,c));if(a.dangerouslySetInnerHTML!=null){if(a.children!=null)throw Error(p$2(60));if(typeof a.dangerouslySetInnerHTML!="object"||!("__html"in a.dangerouslySetInnerHTML))throw Error(p$2(61))}if(a.style!=null&&typeof a.style!="object")throw Error(p$2(62))}}function vb(c,a){if(c.indexOf("-")===-1)return typeof a.is=="string";switch(c){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var wb=null;function xb(c){return c=c.target||c.srcElement||window,c.correspondingUseElement&&(c=c.correspondingUseElement),c.nodeType===3?c.parentNode:c}var yb=null,zb=null,Ab=null;function Bb(c){if(c=Cb(c)){if(typeof yb!="function")throw Error(p$2(280));var a=c.stateNode;a&&(a=Db(a),yb(c.stateNode,c.type,a))}}function Eb(c){zb?Ab?Ab.push(c):Ab=[c]:zb=c}function Fb(){if(zb){var c=zb,a=Ab;if(Ab=zb=null,Bb(c),a)for(c=0;c>>=0,c===0?32:31-(pc(c)/qc|0)|0}var rc=64,sc=4194304;function tc(c){switch(c&-c){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return c&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return c&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return c}}function uc(c,a){var d=c.pendingLanes;if(d===0)return 0;var et=0,nt=c.suspendedLanes,tt=c.pingedLanes,bt=d&268435455;if(bt!==0){var mt=bt&~nt;mt!==0?et=tc(mt):(tt&=bt,tt!==0&&(et=tc(tt)))}else bt=d&~nt,bt!==0?et=tc(bt):tt!==0&&(et=tc(tt));if(et===0)return 0;if(a!==0&&a!==et&&!(a&nt)&&(nt=et&-et,tt=a&-a,nt>=tt||nt===16&&(tt&4194240)!==0))return a;if(et&4&&(et|=d&16),a=c.entangledLanes,a!==0)for(c=c.entanglements,a&=et;0d;d++)a.push(c);return a}function Ac(c,a,d){c.pendingLanes|=a,a!==536870912&&(c.suspendedLanes=0,c.pingedLanes=0),c=c.eventTimes,a=31-oc(a),c[a]=d}function Bc(c,a){var d=c.pendingLanes&~a;c.pendingLanes=a,c.suspendedLanes=0,c.pingedLanes=0,c.expiredLanes&=a,c.mutableReadLanes&=a,c.entangledLanes&=a,a=c.entanglements;var et=c.eventTimes;for(c=c.expirationTimes;0=be$1),ee$1=String.fromCharCode(32),fe$1=!1;function ge$1(c,a){switch(c){case"keyup":return $d.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function he$1(c){return c=c.detail,typeof c=="object"&&"data"in c?c.data:null}var ie$1=!1;function je$1(c,a){switch(c){case"compositionend":return he$1(a);case"keypress":return a.which!==32?null:(fe$1=!0,ee$1);case"textInput":return c=a.data,c===ee$1&&fe$1?null:c;default:return null}}function ke$1(c,a){if(ie$1)return c==="compositionend"||!ae$1&&ge$1(c,a)?(c=nd(),md=ld=kd=null,ie$1=!1,c):null;switch(c){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1=a)return{node:d,offset:a-c};c=et}e:{for(;d;){if(d.nextSibling){d=d.nextSibling;break e}d=d.parentNode}d=void 0}d=Je$1(d)}}function Le$1(c,a){return c&&a?c===a?!0:c&&c.nodeType===3?!1:a&&a.nodeType===3?Le$1(c,a.parentNode):"contains"in c?c.contains(a):c.compareDocumentPosition?!!(c.compareDocumentPosition(a)&16):!1:!1}function Me$1(){for(var c=window,a=Xa();a instanceof c.HTMLIFrameElement;){try{var d=typeof a.contentWindow.location.href=="string"}catch{d=!1}if(d)c=a.contentWindow;else break;a=Xa(c.document)}return a}function Ne$1(c){var a=c&&c.nodeName&&c.nodeName.toLowerCase();return a&&(a==="input"&&(c.type==="text"||c.type==="search"||c.type==="tel"||c.type==="url"||c.type==="password")||a==="textarea"||c.contentEditable==="true")}function Oe$1(c){var a=Me$1(),d=c.focusedElem,et=c.selectionRange;if(a!==d&&d&&d.ownerDocument&&Le$1(d.ownerDocument.documentElement,d)){if(et!==null&&Ne$1(d)){if(a=et.start,c=et.end,c===void 0&&(c=a),"selectionStart"in d)d.selectionStart=a,d.selectionEnd=Math.min(c,d.value.length);else if(c=(a=d.ownerDocument||document)&&a.defaultView||window,c.getSelection){c=c.getSelection();var nt=d.textContent.length,tt=Math.min(et.start,nt);et=et.end===void 0?tt:Math.min(et.end,nt),!c.extend&&tt>et&&(nt=et,et=tt,tt=nt),nt=Ke$1(d,tt);var bt=Ke$1(d,et);nt&&bt&&(c.rangeCount!==1||c.anchorNode!==nt.node||c.anchorOffset!==nt.offset||c.focusNode!==bt.node||c.focusOffset!==bt.offset)&&(a=a.createRange(),a.setStart(nt.node,nt.offset),c.removeAllRanges(),tt>et?(c.addRange(a),c.extend(bt.node,bt.offset)):(a.setEnd(bt.node,bt.offset),c.addRange(a)))}}for(a=[],c=d;c=c.parentNode;)c.nodeType===1&&a.push({element:c,left:c.scrollLeft,top:c.scrollTop});for(typeof d.focus=="function"&&d.focus(),d=0;d=document.documentMode,Qe$1=null,Re$1=null,Se$1=null,Te$1=!1;function Ue$1(c,a,d){var et=d.window===d?d.document:d.nodeType===9?d:d.ownerDocument;Te$1||Qe$1==null||Qe$1!==Xa(et)||(et=Qe$1,"selectionStart"in et&&Ne$1(et)?et={start:et.selectionStart,end:et.selectionEnd}:(et=(et.ownerDocument&&et.ownerDocument.defaultView||window).getSelection(),et={anchorNode:et.anchorNode,anchorOffset:et.anchorOffset,focusNode:et.focusNode,focusOffset:et.focusOffset}),Se$1&&Ie$1(Se$1,et)||(Se$1=et,et=oe$1(Re$1,"onSelect"),0Tf||(c.current=Sf[Tf],Sf[Tf]=null,Tf--)}function G$2(c,a){Tf++,Sf[Tf]=c.current,c.current=a}var Vf={},H$1=Uf(Vf),Wf=Uf(!1),Xf=Vf;function Yf(c,a){var d=c.type.contextTypes;if(!d)return Vf;var et=c.stateNode;if(et&&et.__reactInternalMemoizedUnmaskedChildContext===a)return et.__reactInternalMemoizedMaskedChildContext;var nt={},tt;for(tt in d)nt[tt]=a[tt];return et&&(c=c.stateNode,c.__reactInternalMemoizedUnmaskedChildContext=a,c.__reactInternalMemoizedMaskedChildContext=nt),nt}function Zf(c){return c=c.childContextTypes,c!=null}function $f(){E(Wf),E(H$1)}function ag(c,a,d){if(H$1.current!==Vf)throw Error(p$2(168));G$2(H$1,a),G$2(Wf,d)}function bg(c,a,d){var et=c.stateNode;if(a=a.childContextTypes,typeof et.getChildContext!="function")return d;et=et.getChildContext();for(var nt in et)if(!(nt in a))throw Error(p$2(108,Ra(c)||"Unknown",nt));return A$1({},d,et)}function cg(c){return c=(c=c.stateNode)&&c.__reactInternalMemoizedMergedChildContext||Vf,Xf=H$1.current,G$2(H$1,c),G$2(Wf,Wf.current),!0}function dg(c,a,d){var et=c.stateNode;if(!et)throw Error(p$2(169));d?(c=bg(c,a,Xf),et.__reactInternalMemoizedMergedChildContext=c,E(Wf),E(H$1),G$2(H$1,c)):E(Wf),G$2(Wf,d)}var eg=null,fg=!1,gg=!1;function hg(c){eg===null?eg=[c]:eg.push(c)}function ig(c){fg=!0,hg(c)}function jg(){if(!gg&&eg!==null){gg=!0;var c=0,a=C$1;try{var d=eg;for(C$1=1;c>=bt,nt-=bt,rg=1<<32-oc(a)+nt|d<n0?(t0=a0,a0=null):t0=a0.sibling;var c0=Tt(Nt,a0,Ut[n0],Gt);if(c0===null){a0===null&&(a0=t0);break}c&&a0&&c0.alternate===null&&a(Nt,a0),Ot=tt(c0,Ot,n0),Xt===null?Wt=c0:Xt.sibling=c0,Xt=c0,a0=t0}if(n0===Ut.length)return d(Nt,a0),I$1&&tg(Nt,n0),Wt;if(a0===null){for(;n0n0?(t0=a0,a0=null):t0=a0.sibling;var Ct=Tt(Nt,a0,c0.value,Gt);if(Ct===null){a0===null&&(a0=t0);break}c&&a0&&Ct.alternate===null&&a(Nt,a0),Ot=tt(Ct,Ot,n0),Xt===null?Wt=Ct:Xt.sibling=Ct,Xt=Ct,a0=t0}if(c0.done)return d(Nt,a0),I$1&&tg(Nt,n0),Wt;if(a0===null){for(;!c0.done;n0++,c0=Ut.next())c0=Mt(Nt,c0.value,Gt),c0!==null&&(Ot=tt(c0,Ot,n0),Xt===null?Wt=c0:Xt.sibling=c0,Xt=c0);return I$1&&tg(Nt,n0),Wt}for(a0=et(Nt,a0);!c0.done;n0++,c0=Ut.next())c0=Rt(a0,Nt,n0,c0.value,Gt),c0!==null&&(c&&c0.alternate!==null&&a0.delete(c0.key===null?n0:c0.key),Ot=tt(c0,Ot,n0),Xt===null?Wt=c0:Xt.sibling=c0,Xt=c0);return c&&a0.forEach(function(dt){return a(Nt,dt)}),I$1&&tg(Nt,n0),Wt}function Dt(Nt,Ot,Ut,Gt){if(typeof Ut=="object"&&Ut!==null&&Ut.type===ya&&Ut.key===null&&(Ut=Ut.props.children),typeof Ut=="object"&&Ut!==null){switch(Ut.$$typeof){case va:e:{for(var Wt=Ut.key,Xt=Ot;Xt!==null;){if(Xt.key===Wt){if(Wt=Ut.type,Wt===ya){if(Xt.tag===7){d(Nt,Xt.sibling),Ot=nt(Xt,Ut.props.children),Ot.return=Nt,Nt=Ot;break e}}else if(Xt.elementType===Wt||typeof Wt=="object"&&Wt!==null&&Wt.$$typeof===Ha&&Ng(Wt)===Xt.type){d(Nt,Xt.sibling),Ot=nt(Xt,Ut.props),Ot.ref=Lg(Nt,Xt,Ut),Ot.return=Nt,Nt=Ot;break e}d(Nt,Xt);break}else a(Nt,Xt);Xt=Xt.sibling}Ut.type===ya?(Ot=Tg(Ut.props.children,Nt.mode,Gt,Ut.key),Ot.return=Nt,Nt=Ot):(Gt=Rg(Ut.type,Ut.key,Ut.props,null,Nt.mode,Gt),Gt.ref=Lg(Nt,Ot,Ut),Gt.return=Nt,Nt=Gt)}return bt(Nt);case wa:e:{for(Xt=Ut.key;Ot!==null;){if(Ot.key===Xt)if(Ot.tag===4&&Ot.stateNode.containerInfo===Ut.containerInfo&&Ot.stateNode.implementation===Ut.implementation){d(Nt,Ot.sibling),Ot=nt(Ot,Ut.children||[]),Ot.return=Nt,Nt=Ot;break e}else{d(Nt,Ot);break}else a(Nt,Ot);Ot=Ot.sibling}Ot=Sg(Ut,Nt.mode,Gt),Ot.return=Nt,Nt=Ot}return bt(Nt);case Ha:return Xt=Ut._init,Dt(Nt,Ot,Xt(Ut._payload),Gt)}if(eb(Ut))return kt(Nt,Ot,Ut,Gt);if(Ka(Ut))return It(Nt,Ot,Ut,Gt);Mg(Nt,Ut)}return typeof Ut=="string"&&Ut!==""||typeof Ut=="number"?(Ut=""+Ut,Ot!==null&&Ot.tag===6?(d(Nt,Ot.sibling),Ot=nt(Ot,Ut),Ot.return=Nt,Nt=Ot):(d(Nt,Ot),Ot=Qg(Ut,Nt.mode,Gt),Ot.return=Nt,Nt=Ot),bt(Nt)):d(Nt,Ot)}return Dt}var Ug=Og(!0),Vg=Og(!1),Wg=Uf(null),Xg=null,Yg=null,Zg=null;function $g(){Zg=Yg=Xg=null}function ah(c){var a=Wg.current;E(Wg),c._currentValue=a}function bh(c,a,d){for(;c!==null;){var et=c.alternate;if((c.childLanes&a)!==a?(c.childLanes|=a,et!==null&&(et.childLanes|=a)):et!==null&&(et.childLanes&a)!==a&&(et.childLanes|=a),c===d)break;c=c.return}}function ch$1(c,a){Xg=c,Zg=Yg=null,c=c.dependencies,c!==null&&c.firstContext!==null&&(c.lanes&a&&(dh$1=!0),c.firstContext=null)}function eh(c){var a=c._currentValue;if(Zg!==c)if(c={context:c,memoizedValue:a,next:null},Yg===null){if(Xg===null)throw Error(p$2(308));Yg=c,Xg.dependencies={lanes:0,firstContext:c}}else Yg=Yg.next=c;return a}var fh=null;function gh(c){fh===null?fh=[c]:fh.push(c)}function hh(c,a,d,et){var nt=a.interleaved;return nt===null?(d.next=d,gh(a)):(d.next=nt.next,nt.next=d),a.interleaved=d,ih(c,et)}function ih(c,a){c.lanes|=a;var d=c.alternate;for(d!==null&&(d.lanes|=a),d=c,c=c.return;c!==null;)c.childLanes|=a,d=c.alternate,d!==null&&(d.childLanes|=a),d=c,c=c.return;return d.tag===3?d.stateNode:null}var jh=!1;function kh(c){c.updateQueue={baseState:c.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function lh(c,a){c=c.updateQueue,a.updateQueue===c&&(a.updateQueue={baseState:c.baseState,firstBaseUpdate:c.firstBaseUpdate,lastBaseUpdate:c.lastBaseUpdate,shared:c.shared,effects:c.effects})}function mh(c,a){return{eventTime:c,lane:a,tag:0,payload:null,callback:null,next:null}}function nh(c,a,d){var et=c.updateQueue;if(et===null)return null;if(et=et.shared,K$6&2){var nt=et.pending;return nt===null?a.next=a:(a.next=nt.next,nt.next=a),et.pending=a,ih(c,d)}return nt=et.interleaved,nt===null?(a.next=a,gh(et)):(a.next=nt.next,nt.next=a),et.interleaved=a,ih(c,d)}function oh(c,a,d){if(a=a.updateQueue,a!==null&&(a=a.shared,(d&4194240)!==0)){var et=a.lanes;et&=c.pendingLanes,d|=et,a.lanes=d,Cc(c,d)}}function ph(c,a){var d=c.updateQueue,et=c.alternate;if(et!==null&&(et=et.updateQueue,d===et)){var nt=null,tt=null;if(d=d.firstBaseUpdate,d!==null){do{var bt={eventTime:d.eventTime,lane:d.lane,tag:d.tag,payload:d.payload,callback:d.callback,next:null};tt===null?nt=tt=bt:tt=tt.next=bt,d=d.next}while(d!==null);tt===null?nt=tt=a:tt=tt.next=a}else nt=tt=a;d={baseState:et.baseState,firstBaseUpdate:nt,lastBaseUpdate:tt,shared:et.shared,effects:et.effects},c.updateQueue=d;return}c=d.lastBaseUpdate,c===null?d.firstBaseUpdate=a:c.next=a,d.lastBaseUpdate=a}function qh(c,a,d,et){var nt=c.updateQueue;jh=!1;var tt=nt.firstBaseUpdate,bt=nt.lastBaseUpdate,mt=nt.shared.pending;if(mt!==null){nt.shared.pending=null;var vt=mt,$t=vt.next;vt.next=null,bt===null?tt=$t:bt.next=$t,bt=vt;var At=c.alternate;At!==null&&(At=At.updateQueue,mt=At.lastBaseUpdate,mt!==bt&&(mt===null?At.firstBaseUpdate=$t:mt.next=$t,At.lastBaseUpdate=vt))}if(tt!==null){var Mt=nt.baseState;bt=0,At=$t=vt=null,mt=tt;do{var Tt=mt.lane,Rt=mt.eventTime;if((et&Tt)===Tt){At!==null&&(At=At.next={eventTime:Rt,lane:0,tag:mt.tag,payload:mt.payload,callback:mt.callback,next:null});e:{var kt=c,It=mt;switch(Tt=a,Rt=d,It.tag){case 1:if(kt=It.payload,typeof kt=="function"){Mt=kt.call(Rt,Mt,Tt);break e}Mt=kt;break e;case 3:kt.flags=kt.flags&-65537|128;case 0:if(kt=It.payload,Tt=typeof kt=="function"?kt.call(Rt,Mt,Tt):kt,Tt==null)break e;Mt=A$1({},Mt,Tt);break e;case 2:jh=!0}}mt.callback!==null&&mt.lane!==0&&(c.flags|=64,Tt=nt.effects,Tt===null?nt.effects=[mt]:Tt.push(mt))}else Rt={eventTime:Rt,lane:Tt,tag:mt.tag,payload:mt.payload,callback:mt.callback,next:null},At===null?($t=At=Rt,vt=Mt):At=At.next=Rt,bt|=Tt;if(mt=mt.next,mt===null){if(mt=nt.shared.pending,mt===null)break;Tt=mt,mt=Tt.next,Tt.next=null,nt.lastBaseUpdate=Tt,nt.shared.pending=null}}while(1);if(At===null&&(vt=Mt),nt.baseState=vt,nt.firstBaseUpdate=$t,nt.lastBaseUpdate=At,a=nt.shared.interleaved,a!==null){nt=a;do bt|=nt.lane,nt=nt.next;while(nt!==a)}else tt===null&&(nt.shared.lanes=0);rh$1|=bt,c.lanes=bt,c.memoizedState=Mt}}function sh$1(c,a,d){if(c=a.effects,a.effects=null,c!==null)for(a=0;ad?d:4,c(!0);var et=Gh.transition;Gh.transition={};try{c(!1),a()}finally{C$1=d,Gh.transition=et}}function wi(){return Uh().memoizedState}function xi(c,a,d){var et=yi(c);if(d={lane:et,action:d,hasEagerState:!1,eagerState:null,next:null},zi(c))Ai(a,d);else if(d=hh(c,a,d,et),d!==null){var nt=R$2();gi(d,c,et,nt),Bi(d,a,et)}}function ii(c,a,d){var et=yi(c),nt={lane:et,action:d,hasEagerState:!1,eagerState:null,next:null};if(zi(c))Ai(a,nt);else{var tt=c.alternate;if(c.lanes===0&&(tt===null||tt.lanes===0)&&(tt=a.lastRenderedReducer,tt!==null))try{var bt=a.lastRenderedState,mt=tt(bt,d);if(nt.hasEagerState=!0,nt.eagerState=mt,He$1(mt,bt)){var vt=a.interleaved;vt===null?(nt.next=nt,gh(a)):(nt.next=vt.next,vt.next=nt),a.interleaved=nt;return}}catch{}finally{}d=hh(c,a,nt,et),d!==null&&(nt=R$2(),gi(d,c,et,nt),Bi(d,a,et))}}function zi(c){var a=c.alternate;return c===M$1||a!==null&&a===M$1}function Ai(c,a){Jh=Ih=!0;var d=c.pending;d===null?a.next=a:(a.next=d.next,d.next=a),c.pending=a}function Bi(c,a,d){if(d&4194240){var et=a.lanes;et&=c.pendingLanes,d|=et,a.lanes=d,Cc(c,d)}}var Rh={readContext:eh,useCallback:P,useContext:P,useEffect:P,useImperativeHandle:P,useInsertionEffect:P,useLayoutEffect:P,useMemo:P,useReducer:P,useRef:P,useState:P,useDebugValue:P,useDeferredValue:P,useTransition:P,useMutableSource:P,useSyncExternalStore:P,useId:P,unstable_isNewReconciler:!1},Oh={readContext:eh,useCallback:function(c,a){return Th().memoizedState=[c,a===void 0?null:a],c},useContext:eh,useEffect:mi,useImperativeHandle:function(c,a,d){return d=d!=null?d.concat([c]):null,ki(4194308,4,pi.bind(null,a,c),d)},useLayoutEffect:function(c,a){return ki(4194308,4,c,a)},useInsertionEffect:function(c,a){return ki(4,2,c,a)},useMemo:function(c,a){var d=Th();return a=a===void 0?null:a,c=c(),d.memoizedState=[c,a],c},useReducer:function(c,a,d){var et=Th();return a=d!==void 0?d(a):a,et.memoizedState=et.baseState=a,c={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:c,lastRenderedState:a},et.queue=c,c=c.dispatch=xi.bind(null,M$1,c),[et.memoizedState,c]},useRef:function(c){var a=Th();return c={current:c},a.memoizedState=c},useState:hi,useDebugValue:ri,useDeferredValue:function(c){return Th().memoizedState=c},useTransition:function(){var c=hi(!1),a=c[0];return c=vi.bind(null,c[1]),Th().memoizedState=c,[a,c]},useMutableSource:function(){},useSyncExternalStore:function(c,a,d){var et=M$1,nt=Th();if(I$1){if(d===void 0)throw Error(p$2(407));d=d()}else{if(d=a(),Q$1===null)throw Error(p$2(349));Hh&30||di(et,a,d)}nt.memoizedState=d;var tt={value:d,getSnapshot:a};return nt.queue=tt,mi(ai.bind(null,et,tt,c),[c]),et.flags|=2048,bi(9,ci.bind(null,et,tt,d,a),void 0,null),d},useId:function(){var c=Th(),a=Q$1.identifierPrefix;if(I$1){var d=sg,et=rg;d=(et&~(1<<32-oc(et)-1)).toString(32)+d,a=":"+a+"R"+d,d=Kh$1++,0<\/script>",c=c.removeChild(c.firstChild)):typeof et.is=="string"?c=bt.createElement(d,{is:et.is}):(c=bt.createElement(d),d==="select"&&(bt=c,et.multiple?bt.multiple=!0:et.size&&(bt.size=et.size))):c=bt.createElementNS(c,d),c[Of]=a,c[Pf]=et,zj(c,a,!1,!1),a.stateNode=c;e:{switch(bt=vb(d,et),d){case"dialog":D$1("cancel",c),D$1("close",c),nt=et;break;case"iframe":case"object":case"embed":D$1("load",c),nt=et;break;case"video":case"audio":for(nt=0;ntGj&&(a.flags|=128,et=!0,Dj(tt,!1),a.lanes=4194304)}else{if(!et)if(c=Ch$1(bt),c!==null){if(a.flags|=128,et=!0,d=c.updateQueue,d!==null&&(a.updateQueue=d,a.flags|=4),Dj(tt,!0),tt.tail===null&&tt.tailMode==="hidden"&&!bt.alternate&&!I$1)return S$1(a),null}else 2*B$1()-tt.renderingStartTime>Gj&&d!==1073741824&&(a.flags|=128,et=!0,Dj(tt,!1),a.lanes=4194304);tt.isBackwards?(bt.sibling=a.child,a.child=bt):(d=tt.last,d!==null?d.sibling=bt:a.child=bt,tt.last=bt)}return tt.tail!==null?(a=tt.tail,tt.rendering=a,tt.tail=a.sibling,tt.renderingStartTime=B$1(),a.sibling=null,d=L$1.current,G$2(L$1,et?d&1|2:d&1),a):(S$1(a),null);case 22:case 23:return Hj(),et=a.memoizedState!==null,c!==null&&c.memoizedState!==null!==et&&(a.flags|=8192),et&&a.mode&1?fj&1073741824&&(S$1(a),a.subtreeFlags&6&&(a.flags|=8192)):S$1(a),null;case 24:return null;case 25:return null}throw Error(p$2(156,a.tag))}function Ij(c,a){switch(wg(a),a.tag){case 1:return Zf(a.type)&&$f(),c=a.flags,c&65536?(a.flags=c&-65537|128,a):null;case 3:return zh(),E(Wf),E(H$1),Eh(),c=a.flags,c&65536&&!(c&128)?(a.flags=c&-65537|128,a):null;case 5:return Bh(a),null;case 13:if(E(L$1),c=a.memoizedState,c!==null&&c.dehydrated!==null){if(a.alternate===null)throw Error(p$2(340));Ig$1()}return c=a.flags,c&65536?(a.flags=c&-65537|128,a):null;case 19:return E(L$1),null;case 4:return zh(),null;case 10:return ah(a.type._context),null;case 22:case 23:return Hj(),null;case 24:return null;default:return null}}var Jj=!1,U$1=!1,Kj=typeof WeakSet=="function"?WeakSet:Set,V$1=null;function Lj(c,a){var d=c.ref;if(d!==null)if(typeof d=="function")try{d(null)}catch(et){W$7(c,a,et)}else d.current=null}function Mj(c,a,d){try{d()}catch(et){W$7(c,a,et)}}var Nj=!1;function Oj(c,a){if(Cf=dd,c=Me$1(),Ne$1(c)){if("selectionStart"in c)var d={start:c.selectionStart,end:c.selectionEnd};else e:{d=(d=c.ownerDocument)&&d.defaultView||window;var et=d.getSelection&&d.getSelection();if(et&&et.rangeCount!==0){d=et.anchorNode;var nt=et.anchorOffset,tt=et.focusNode;et=et.focusOffset;try{d.nodeType,tt.nodeType}catch{d=null;break e}var bt=0,mt=-1,vt=-1,$t=0,At=0,Mt=c,Tt=null;t:for(;;){for(var Rt;Mt!==d||nt!==0&&Mt.nodeType!==3||(mt=bt+nt),Mt!==tt||et!==0&&Mt.nodeType!==3||(vt=bt+et),Mt.nodeType===3&&(bt+=Mt.nodeValue.length),(Rt=Mt.firstChild)!==null;)Tt=Mt,Mt=Rt;for(;;){if(Mt===c)break t;if(Tt===d&&++$t===nt&&(mt=bt),Tt===tt&&++At===et&&(vt=bt),(Rt=Mt.nextSibling)!==null)break;Mt=Tt,Tt=Mt.parentNode}Mt=Rt}d=mt===-1||vt===-1?null:{start:mt,end:vt}}else d=null}d=d||{start:0,end:0}}else d=null;for(Df={focusedElem:c,selectionRange:d},dd=!1,V$1=a;V$1!==null;)if(a=V$1,c=a.child,(a.subtreeFlags&1028)!==0&&c!==null)c.return=a,V$1=c;else for(;V$1!==null;){a=V$1;try{var kt=a.alternate;if(a.flags&1024)switch(a.tag){case 0:case 11:case 15:break;case 1:if(kt!==null){var It=kt.memoizedProps,Dt=kt.memoizedState,Nt=a.stateNode,Ot=Nt.getSnapshotBeforeUpdate(a.elementType===a.type?It:Ci(a.type,It),Dt);Nt.__reactInternalSnapshotBeforeUpdate=Ot}break;case 3:var Ut=a.stateNode.containerInfo;Ut.nodeType===1?Ut.textContent="":Ut.nodeType===9&&Ut.documentElement&&Ut.removeChild(Ut.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(p$2(163))}}catch(Gt){W$7(a,a.return,Gt)}if(c=a.sibling,c!==null){c.return=a.return,V$1=c;break}V$1=a.return}return kt=Nj,Nj=!1,kt}function Pj(c,a,d){var et=a.updateQueue;if(et=et!==null?et.lastEffect:null,et!==null){var nt=et=et.next;do{if((nt.tag&c)===c){var tt=nt.destroy;nt.destroy=void 0,tt!==void 0&&Mj(a,d,tt)}nt=nt.next}while(nt!==et)}}function Qj(c,a){if(a=a.updateQueue,a=a!==null?a.lastEffect:null,a!==null){var d=a=a.next;do{if((d.tag&c)===c){var et=d.create;d.destroy=et()}d=d.next}while(d!==a)}}function Rj(c){var a=c.ref;if(a!==null){var d=c.stateNode;switch(c.tag){case 5:c=d;break;default:c=d}typeof a=="function"?a(c):a.current=c}}function Sj(c){var a=c.alternate;a!==null&&(c.alternate=null,Sj(a)),c.child=null,c.deletions=null,c.sibling=null,c.tag===5&&(a=c.stateNode,a!==null&&(delete a[Of],delete a[Pf],delete a[of],delete a[Qf],delete a[Rf])),c.stateNode=null,c.return=null,c.dependencies=null,c.memoizedProps=null,c.memoizedState=null,c.pendingProps=null,c.stateNode=null,c.updateQueue=null}function Tj(c){return c.tag===5||c.tag===3||c.tag===4}function Uj(c){e:for(;;){for(;c.sibling===null;){if(c.return===null||Tj(c.return))return null;c=c.return}for(c.sibling.return=c.return,c=c.sibling;c.tag!==5&&c.tag!==6&&c.tag!==18;){if(c.flags&2||c.child===null||c.tag===4)continue e;c.child.return=c,c=c.child}if(!(c.flags&2))return c.stateNode}}function Vj(c,a,d){var et=c.tag;if(et===5||et===6)c=c.stateNode,a?d.nodeType===8?d.parentNode.insertBefore(c,a):d.insertBefore(c,a):(d.nodeType===8?(a=d.parentNode,a.insertBefore(c,d)):(a=d,a.appendChild(c)),d=d._reactRootContainer,d!=null||a.onclick!==null||(a.onclick=Bf));else if(et!==4&&(c=c.child,c!==null))for(Vj(c,a,d),c=c.sibling;c!==null;)Vj(c,a,d),c=c.sibling}function Wj(c,a,d){var et=c.tag;if(et===5||et===6)c=c.stateNode,a?d.insertBefore(c,a):d.appendChild(c);else if(et!==4&&(c=c.child,c!==null))for(Wj(c,a,d),c=c.sibling;c!==null;)Wj(c,a,d),c=c.sibling}var X$1=null,Xj=!1;function Yj(c,a,d){for(d=d.child;d!==null;)Zj(c,a,d),d=d.sibling}function Zj(c,a,d){if(lc&&typeof lc.onCommitFiberUnmount=="function")try{lc.onCommitFiberUnmount(kc,d)}catch{}switch(d.tag){case 5:U$1||Lj(d,a);case 6:var et=X$1,nt=Xj;X$1=null,Yj(c,a,d),X$1=et,Xj=nt,X$1!==null&&(Xj?(c=X$1,d=d.stateNode,c.nodeType===8?c.parentNode.removeChild(d):c.removeChild(d)):X$1.removeChild(d.stateNode));break;case 18:X$1!==null&&(Xj?(c=X$1,d=d.stateNode,c.nodeType===8?Kf(c.parentNode,d):c.nodeType===1&&Kf(c,d),bd(c)):Kf(X$1,d.stateNode));break;case 4:et=X$1,nt=Xj,X$1=d.stateNode.containerInfo,Xj=!0,Yj(c,a,d),X$1=et,Xj=nt;break;case 0:case 11:case 14:case 15:if(!U$1&&(et=d.updateQueue,et!==null&&(et=et.lastEffect,et!==null))){nt=et=et.next;do{var tt=nt,bt=tt.destroy;tt=tt.tag,bt!==void 0&&(tt&2||tt&4)&&Mj(d,a,bt),nt=nt.next}while(nt!==et)}Yj(c,a,d);break;case 1:if(!U$1&&(Lj(d,a),et=d.stateNode,typeof et.componentWillUnmount=="function"))try{et.props=d.memoizedProps,et.state=d.memoizedState,et.componentWillUnmount()}catch(mt){W$7(d,a,mt)}Yj(c,a,d);break;case 21:Yj(c,a,d);break;case 22:d.mode&1?(U$1=(et=U$1)||d.memoizedState!==null,Yj(c,a,d),U$1=et):Yj(c,a,d);break;default:Yj(c,a,d)}}function ak(c){var a=c.updateQueue;if(a!==null){c.updateQueue=null;var d=c.stateNode;d===null&&(d=c.stateNode=new Kj),a.forEach(function(et){var nt=bk.bind(null,c,et);d.has(et)||(d.add(et),et.then(nt,nt))})}}function ck(c,a){var d=a.deletions;if(d!==null)for(var et=0;etnt&&(nt=bt),et&=~tt}if(et=nt,et=B$1()-et,et=(120>et?120:480>et?480:1080>et?1080:1920>et?1920:3e3>et?3e3:4320>et?4320:1960*lk(et/1960))-et,10c?16:c,wk===null)var et=!1;else{if(c=wk,wk=null,xk=0,K$6&6)throw Error(p$2(331));var nt=K$6;for(K$6|=4,V$1=c.current;V$1!==null;){var tt=V$1,bt=tt.child;if(V$1.flags&16){var mt=tt.deletions;if(mt!==null){for(var vt=0;vtB$1()-fk?Kk(c,0):rk|=d),Dk(c,a)}function Yk(c,a){a===0&&(c.mode&1?(a=sc,sc<<=1,!(sc&130023424)&&(sc=4194304)):a=1);var d=R$2();c=ih(c,a),c!==null&&(Ac(c,a,d),Dk(c,d))}function uj(c){var a=c.memoizedState,d=0;a!==null&&(d=a.retryLane),Yk(c,d)}function bk(c,a){var d=0;switch(c.tag){case 13:var et=c.stateNode,nt=c.memoizedState;nt!==null&&(d=nt.retryLane);break;case 19:et=c.stateNode;break;default:throw Error(p$2(314))}et!==null&&et.delete(a),Yk(c,d)}var Vk;Vk=function(c,a,d){if(c!==null)if(c.memoizedProps!==a.pendingProps||Wf.current)dh$1=!0;else{if(!(c.lanes&d)&&!(a.flags&128))return dh$1=!1,yj(c,a,d);dh$1=!!(c.flags&131072)}else dh$1=!1,I$1&&a.flags&1048576&&ug(a,ng,a.index);switch(a.lanes=0,a.tag){case 2:var et=a.type;ij(c,a),c=a.pendingProps;var nt=Yf(a,H$1.current);ch$1(a,d),nt=Nh(null,a,et,c,nt,d);var tt=Sh();return a.flags|=1,typeof nt=="object"&&nt!==null&&typeof nt.render=="function"&&nt.$$typeof===void 0?(a.tag=1,a.memoizedState=null,a.updateQueue=null,Zf(et)?(tt=!0,cg(a)):tt=!1,a.memoizedState=nt.state!==null&&nt.state!==void 0?nt.state:null,kh(a),nt.updater=Ei,a.stateNode=nt,nt._reactInternals=a,Ii(a,et,c,d),a=jj(null,a,et,!0,tt,d)):(a.tag=0,I$1&&tt&&vg(a),Xi(null,a,nt,d),a=a.child),a;case 16:et=a.elementType;e:{switch(ij(c,a),c=a.pendingProps,nt=et._init,et=nt(et._payload),a.type=et,nt=a.tag=Zk(et),c=Ci(et,c),nt){case 0:a=cj(null,a,et,c,d);break e;case 1:a=hj(null,a,et,c,d);break e;case 11:a=Yi(null,a,et,c,d);break e;case 14:a=$i(null,a,et,Ci(et.type,c),d);break e}throw Error(p$2(306,et,""))}return a;case 0:return et=a.type,nt=a.pendingProps,nt=a.elementType===et?nt:Ci(et,nt),cj(c,a,et,nt,d);case 1:return et=a.type,nt=a.pendingProps,nt=a.elementType===et?nt:Ci(et,nt),hj(c,a,et,nt,d);case 3:e:{if(kj(a),c===null)throw Error(p$2(387));et=a.pendingProps,tt=a.memoizedState,nt=tt.element,lh(c,a),qh(a,et,null,d);var bt=a.memoizedState;if(et=bt.element,tt.isDehydrated)if(tt={element:et,isDehydrated:!1,cache:bt.cache,pendingSuspenseBoundaries:bt.pendingSuspenseBoundaries,transitions:bt.transitions},a.updateQueue.baseState=tt,a.memoizedState=tt,a.flags&256){nt=Ji(Error(p$2(423)),a),a=lj(c,a,et,d,nt);break e}else if(et!==nt){nt=Ji(Error(p$2(424)),a),a=lj(c,a,et,d,nt);break e}else for(yg=Lf(a.stateNode.containerInfo.firstChild),xg=a,I$1=!0,zg=null,d=Vg(a,null,et,d),a.child=d;d;)d.flags=d.flags&-3|4096,d=d.sibling;else{if(Ig$1(),et===nt){a=Zi(c,a,d);break e}Xi(c,a,et,d)}a=a.child}return a;case 5:return Ah(a),c===null&&Eg(a),et=a.type,nt=a.pendingProps,tt=c!==null?c.memoizedProps:null,bt=nt.children,Ef(et,nt)?bt=null:tt!==null&&Ef(et,tt)&&(a.flags|=32),gj(c,a),Xi(c,a,bt,d),a.child;case 6:return c===null&&Eg(a),null;case 13:return oj(c,a,d);case 4:return yh(a,a.stateNode.containerInfo),et=a.pendingProps,c===null?a.child=Ug(a,null,et,d):Xi(c,a,et,d),a.child;case 11:return et=a.type,nt=a.pendingProps,nt=a.elementType===et?nt:Ci(et,nt),Yi(c,a,et,nt,d);case 7:return Xi(c,a,a.pendingProps,d),a.child;case 8:return Xi(c,a,a.pendingProps.children,d),a.child;case 12:return Xi(c,a,a.pendingProps.children,d),a.child;case 10:e:{if(et=a.type._context,nt=a.pendingProps,tt=a.memoizedProps,bt=nt.value,G$2(Wg,et._currentValue),et._currentValue=bt,tt!==null)if(He$1(tt.value,bt)){if(tt.children===nt.children&&!Wf.current){a=Zi(c,a,d);break e}}else for(tt=a.child,tt!==null&&(tt.return=a);tt!==null;){var mt=tt.dependencies;if(mt!==null){bt=tt.child;for(var vt=mt.firstContext;vt!==null;){if(vt.context===et){if(tt.tag===1){vt=mh(-1,d&-d),vt.tag=2;var $t=tt.updateQueue;if($t!==null){$t=$t.shared;var At=$t.pending;At===null?vt.next=vt:(vt.next=At.next,At.next=vt),$t.pending=vt}}tt.lanes|=d,vt=tt.alternate,vt!==null&&(vt.lanes|=d),bh(tt.return,d,a),mt.lanes|=d;break}vt=vt.next}}else if(tt.tag===10)bt=tt.type===a.type?null:tt.child;else if(tt.tag===18){if(bt=tt.return,bt===null)throw Error(p$2(341));bt.lanes|=d,mt=bt.alternate,mt!==null&&(mt.lanes|=d),bh(bt,d,a),bt=tt.sibling}else bt=tt.child;if(bt!==null)bt.return=tt;else for(bt=tt;bt!==null;){if(bt===a){bt=null;break}if(tt=bt.sibling,tt!==null){tt.return=bt.return,bt=tt;break}bt=bt.return}tt=bt}Xi(c,a,nt.children,d),a=a.child}return a;case 9:return nt=a.type,et=a.pendingProps.children,ch$1(a,d),nt=eh(nt),et=et(nt),a.flags|=1,Xi(c,a,et,d),a.child;case 14:return et=a.type,nt=Ci(et,a.pendingProps),nt=Ci(et.type,nt),$i(c,a,et,nt,d);case 15:return bj(c,a,a.type,a.pendingProps,d);case 17:return et=a.type,nt=a.pendingProps,nt=a.elementType===et?nt:Ci(et,nt),ij(c,a),a.tag=1,Zf(et)?(c=!0,cg(a)):c=!1,ch$1(a,d),Gi(a,et,nt),Ii(a,et,nt,d),jj(null,a,et,!0,c,d);case 19:return xj(c,a,d);case 22:return dj(c,a,d)}throw Error(p$2(156,a.tag))};function Fk(c,a){return ac(c,a)}function $k(c,a,d,et){this.tag=c,this.key=d,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=et,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bg(c,a,d,et){return new $k(c,a,d,et)}function aj(c){return c=c.prototype,!(!c||!c.isReactComponent)}function Zk(c){if(typeof c=="function")return aj(c)?1:0;if(c!=null){if(c=c.$$typeof,c===Da)return 11;if(c===Ga)return 14}return 2}function Pg(c,a){var d=c.alternate;return d===null?(d=Bg(c.tag,a,c.key,c.mode),d.elementType=c.elementType,d.type=c.type,d.stateNode=c.stateNode,d.alternate=c,c.alternate=d):(d.pendingProps=a,d.type=c.type,d.flags=0,d.subtreeFlags=0,d.deletions=null),d.flags=c.flags&14680064,d.childLanes=c.childLanes,d.lanes=c.lanes,d.child=c.child,d.memoizedProps=c.memoizedProps,d.memoizedState=c.memoizedState,d.updateQueue=c.updateQueue,a=c.dependencies,d.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},d.sibling=c.sibling,d.index=c.index,d.ref=c.ref,d}function Rg(c,a,d,et,nt,tt){var bt=2;if(et=c,typeof c=="function")aj(c)&&(bt=1);else if(typeof c=="string")bt=5;else e:switch(c){case ya:return Tg(d.children,nt,tt,a);case za:bt=8,nt|=8;break;case Aa:return c=Bg(12,d,a,nt|2),c.elementType=Aa,c.lanes=tt,c;case Ea:return c=Bg(13,d,a,nt),c.elementType=Ea,c.lanes=tt,c;case Fa:return c=Bg(19,d,a,nt),c.elementType=Fa,c.lanes=tt,c;case Ia:return pj(d,nt,tt,a);default:if(typeof c=="object"&&c!==null)switch(c.$$typeof){case Ba:bt=10;break e;case Ca:bt=9;break e;case Da:bt=11;break e;case Ga:bt=14;break e;case Ha:bt=16,et=null;break e}throw Error(p$2(130,c==null?c:typeof c,""))}return a=Bg(bt,d,a,nt),a.elementType=c,a.type=et,a.lanes=tt,a}function Tg(c,a,d,et){return c=Bg(7,c,et,a),c.lanes=d,c}function pj(c,a,d,et){return c=Bg(22,c,et,a),c.elementType=Ia,c.lanes=d,c.stateNode={isHidden:!1},c}function Qg(c,a,d){return c=Bg(6,c,null,a),c.lanes=d,c}function Sg(c,a,d){return a=Bg(4,c.children!==null?c.children:[],c.key,a),a.lanes=d,a.stateNode={containerInfo:c.containerInfo,pendingChildren:null,implementation:c.implementation},a}function al(c,a,d,et,nt){this.tag=a,this.containerInfo=c,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=zc(0),this.expirationTimes=zc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=zc(0),this.identifierPrefix=et,this.onRecoverableError=nt,this.mutableSourceEagerHydrationData=null}function bl(c,a,d,et,nt,tt,bt,mt,vt){return c=new al(c,a,d,mt,vt),a===1?(a=1,tt===!0&&(a|=8)):a=0,tt=Bg(3,null,null,a),c.current=tt,tt.stateNode=c,tt.memoizedState={element:et,isDehydrated:d,cache:null,transitions:null,pendingSuspenseBoundaries:null},kh(tt),c}function cl(c,a,d){var et=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE)}catch(c){console.error(c)}}checkDCE(),reactDom.exports=reactDom_production_min;var reactDomExports=reactDom.exports;const ReactDOM=getDefaultExportFromCjs(reactDomExports);var m$2=reactDomExports;client.createRoot=m$2.createRoot,client.hydrateRoot=m$2.hydrateRoot;const styles$1="",styles="";var __assign=function(){return __assign=Object.assign||function(a){for(var d,et=1,nt=arguments.length;et"u")return zeroGap;var a=getOffset(c),d=document.documentElement.clientWidth,et=window.innerWidth;return{left:a[0],top:a[1],right:a[2],gap:Math.max(0,et-d+a[2]-a[0])}},Style=styleSingleton(),lockAttribute="data-scroll-locked",getStyles=function(c,a,d,et){var nt=c.left,tt=c.top,bt=c.right,mt=c.gap;return d===void 0&&(d="margin"),` + .`.concat(noScrollbarsClassName,` { + overflow: hidden `).concat(et,`; + padding-right: `).concat(mt,"px ").concat(et,`; + } + body[`).concat(lockAttribute,`] { + overflow: hidden `).concat(et,`; + overscroll-behavior: contain; + `).concat([a&&"position: relative ".concat(et,";"),d==="margin"&&` + padding-left: `.concat(nt,`px; + padding-top: `).concat(tt,`px; + padding-right: `).concat(bt,`px; + margin-left:0; + margin-top:0; + margin-right: `).concat(mt,"px ").concat(et,`; + `),d==="padding"&&"padding-right: ".concat(mt,"px ").concat(et,";")].filter(Boolean).join(""),` + } + + .`).concat(zeroRightClassName,` { + right: `).concat(mt,"px ").concat(et,`; + } + + .`).concat(fullWidthClassName,` { + margin-right: `).concat(mt,"px ").concat(et,`; + } + + .`).concat(zeroRightClassName," .").concat(zeroRightClassName,` { + right: 0 `).concat(et,`; + } + + .`).concat(fullWidthClassName," .").concat(fullWidthClassName,` { + margin-right: 0 `).concat(et,`; + } + + body[`).concat(lockAttribute,`] { + `).concat(removedBarSizeVariable,": ").concat(mt,`px; + } +`)},getCurrentUseCounter=function(){var c=parseInt(document.body.getAttribute(lockAttribute)||"0",10);return isFinite(c)?c:0},useLockAttribute=function(){reactExports.useEffect(function(){return document.body.setAttribute(lockAttribute,(getCurrentUseCounter()+1).toString()),function(){var c=getCurrentUseCounter()-1;c<=0?document.body.removeAttribute(lockAttribute):document.body.setAttribute(lockAttribute,c.toString())}},[])},RemoveScrollBar=function(c){var a=c.noRelative,d=c.noImportant,et=c.gapMode,nt=et===void 0?"margin":et;useLockAttribute();var tt=reactExports.useMemo(function(){return getGapWidth(nt)},[nt]);return reactExports.createElement(Style,{styles:getStyles(tt,!a,nt,d?"":"!important")})},passiveSupported=!1;if(typeof window<"u")try{var options=Object.defineProperty({},"passive",{get:function(){return passiveSupported=!0,!0}});window.addEventListener("test",options,options),window.removeEventListener("test",options,options)}catch{passiveSupported=!1}var nonPassive=passiveSupported?{passive:!1}:!1,alwaysContainsScroll=function(c){return c.tagName==="TEXTAREA"},elementCanBeScrolled=function(c,a){if(!(c instanceof Element))return!1;var d=window.getComputedStyle(c);return d[a]!=="hidden"&&!(d.overflowY===d.overflowX&&!alwaysContainsScroll(c)&&d[a]==="visible")},elementCouldBeVScrolled=function(c){return elementCanBeScrolled(c,"overflowY")},elementCouldBeHScrolled=function(c){return elementCanBeScrolled(c,"overflowX")},locationCouldBeScrolled=function(c,a){var d=a.ownerDocument,et=a;do{typeof ShadowRoot<"u"&&et instanceof ShadowRoot&&(et=et.host);var nt=elementCouldBeScrolled(c,et);if(nt){var tt=getScrollVariables(c,et),bt=tt[1],mt=tt[2];if(bt>mt)return!0}et=et.parentNode}while(et&&et!==d.body);return!1},getVScrollVariables=function(c){var a=c.scrollTop,d=c.scrollHeight,et=c.clientHeight;return[a,d,et]},getHScrollVariables=function(c){var a=c.scrollLeft,d=c.scrollWidth,et=c.clientWidth;return[a,d,et]},elementCouldBeScrolled=function(c,a){return c==="v"?elementCouldBeVScrolled(a):elementCouldBeHScrolled(a)},getScrollVariables=function(c,a){return c==="v"?getVScrollVariables(a):getHScrollVariables(a)},getDirectionFactor=function(c,a){return c==="h"&&a==="rtl"?-1:1},handleScroll=function(c,a,d,et,nt){var tt=getDirectionFactor(c,window.getComputedStyle(a).direction),bt=tt*et,mt=d.target,vt=a.contains(mt),$t=!1,At=bt>0,Mt=0,Tt=0;do{var Rt=getScrollVariables(c,mt),kt=Rt[0],It=Rt[1],Dt=Rt[2],Nt=It-Dt-tt*kt;(kt||Nt)&&elementCouldBeScrolled(c,mt)&&(Mt+=Nt,Tt+=kt),mt instanceof ShadowRoot?mt=mt.host:mt=mt.parentNode}while(!vt&&mt!==document.body||vt&&(a.contains(mt)||a===mt));return(At&&(nt&&Math.abs(Mt)<1||!nt&&bt>Mt)||!At&&(nt&&Math.abs(Tt)<1||!nt&&-bt>Tt))&&($t=!0),$t},getTouchXY=function(c){return"changedTouches"in c?[c.changedTouches[0].clientX,c.changedTouches[0].clientY]:[0,0]},getDeltaXY=function(c){return[c.deltaX,c.deltaY]},extractRef=function(c){return c&&"current"in c?c.current:c},deltaCompare=function(c,a){return c[0]===a[0]&&c[1]===a[1]},generateStyle=function(c){return` + .block-interactivity-`.concat(c,` {pointer-events: none;} + .allow-interactivity-`).concat(c,` {pointer-events: all;} +`)},idCounter=0,lockStack=[];function RemoveScrollSideCar(c){var a=reactExports.useRef([]),d=reactExports.useRef([0,0]),et=reactExports.useRef(),nt=reactExports.useState(idCounter++)[0],tt=reactExports.useState(styleSingleton)[0],bt=reactExports.useRef(c);reactExports.useEffect(function(){bt.current=c},[c]),reactExports.useEffect(function(){if(c.inert){document.body.classList.add("block-interactivity-".concat(nt));var It=__spreadArray([c.lockRef.current],(c.shards||[]).map(extractRef),!0).filter(Boolean);return It.forEach(function(Dt){return Dt.classList.add("allow-interactivity-".concat(nt))}),function(){document.body.classList.remove("block-interactivity-".concat(nt)),It.forEach(function(Dt){return Dt.classList.remove("allow-interactivity-".concat(nt))})}}},[c.inert,c.lockRef.current,c.shards]);var mt=reactExports.useCallback(function(It,Dt){if("touches"in It&&It.touches.length===2)return!bt.current.allowPinchZoom;var Nt=getTouchXY(It),Ot=d.current,Ut="deltaX"in It?It.deltaX:Ot[0]-Nt[0],Gt="deltaY"in It?It.deltaY:Ot[1]-Nt[1],Wt,Xt=It.target,a0=Math.abs(Ut)>Math.abs(Gt)?"h":"v";if("touches"in It&&a0==="h"&&Xt.type==="range")return!1;var n0=locationCouldBeScrolled(a0,Xt);if(!n0)return!0;if(n0?Wt=a0:(Wt=a0==="v"?"h":"v",n0=locationCouldBeScrolled(a0,Xt)),!n0)return!1;if(!et.current&&"changedTouches"in It&&(Ut||Gt)&&(et.current=Wt),!Wt)return!0;var t0=et.current||Wt;return handleScroll(t0,Dt,It,t0==="h"?Ut:Gt,!0)},[]),vt=reactExports.useCallback(function(It){var Dt=It;if(!(!lockStack.length||lockStack[lockStack.length-1]!==tt)){var Nt="deltaY"in Dt?getDeltaXY(Dt):getTouchXY(Dt),Ot=a.current.filter(function(Wt){return Wt.name===Dt.type&&(Wt.target===Dt.target||Dt.target===Wt.shadowParent)&&deltaCompare(Wt.delta,Nt)})[0];if(Ot&&Ot.should){Dt.cancelable&&Dt.preventDefault();return}if(!Ot){var Ut=(bt.current.shards||[]).map(extractRef).filter(Boolean).filter(function(Wt){return Wt.contains(Dt.target)}),Gt=Ut.length>0?mt(Dt,Ut[0]):!bt.current.noIsolation;Gt&&Dt.cancelable&&Dt.preventDefault()}}},[]),$t=reactExports.useCallback(function(It,Dt,Nt,Ot){var Ut={name:It,delta:Dt,target:Nt,should:Ot,shadowParent:getOutermostShadowParent(Nt)};a.current.push(Ut),setTimeout(function(){a.current=a.current.filter(function(Gt){return Gt!==Ut})},1)},[]),At=reactExports.useCallback(function(It){d.current=getTouchXY(It),et.current=void 0},[]),Mt=reactExports.useCallback(function(It){$t(It.type,getDeltaXY(It),It.target,mt(It,c.lockRef.current))},[]),Tt=reactExports.useCallback(function(It){$t(It.type,getTouchXY(It),It.target,mt(It,c.lockRef.current))},[]);reactExports.useEffect(function(){return lockStack.push(tt),c.setCallbacks({onScrollCapture:Mt,onWheelCapture:Mt,onTouchMoveCapture:Tt}),document.addEventListener("wheel",vt,nonPassive),document.addEventListener("touchmove",vt,nonPassive),document.addEventListener("touchstart",At,nonPassive),function(){lockStack=lockStack.filter(function(It){return It!==tt}),document.removeEventListener("wheel",vt,nonPassive),document.removeEventListener("touchmove",vt,nonPassive),document.removeEventListener("touchstart",At,nonPassive)}},[]);var Rt=c.removeScrollBar,kt=c.inert;return reactExports.createElement(reactExports.Fragment,null,kt?reactExports.createElement(tt,{styles:generateStyle(nt)}):null,Rt?reactExports.createElement(RemoveScrollBar,{gapMode:c.gapMode}):null)}function getOutermostShadowParent(c){for(var a=null;c!==null;)c instanceof ShadowRoot&&(a=c.host,c=c.host),c=c.parentNode;return a}const SideCar=exportSidecar(effectCar,RemoveScrollSideCar);var ReactRemoveScroll=reactExports.forwardRef(function(c,a){return reactExports.createElement(RemoveScroll$1,__assign({},c,{ref:a,sideCar:SideCar}))});ReactRemoveScroll.classNames=RemoveScroll$1.classNames;const RemoveScroll=ReactRemoveScroll;function keys(c){return Object.keys(c)}function isObject$1(c){return c&&typeof c=="object"&&!Array.isArray(c)}function deepMerge(c,a){const d={...c},et=a;return isObject$1(c)&&isObject$1(a)&&Object.keys(a).forEach(nt=>{isObject$1(et[nt])&&nt in c?d[nt]=deepMerge(d[nt],et[nt]):d[nt]=et[nt]}),d}function camelToKebabCase(c){return c.replace(/[A-Z]/g,a=>`-${a.toLowerCase()}`)}function getTransformedScaledValue(c){var a;return typeof c!="string"||!c.includes("var(--mantine-scale)")?c:(a=c.match(/^calc\((.*?)\)$/))==null?void 0:a[1].split("*")[0].trim()}function px(c){const a=getTransformedScaledValue(c);return typeof a=="number"?a:typeof a=="string"?a.includes("calc")||a.includes("var")?a:a.includes("px")?Number(a.replace("px","")):a.includes("rem")?Number(a.replace("rem",""))*16:a.includes("em")?Number(a.replace("em",""))*16:Number(a):NaN}function scaleRem(c){return c==="0rem"?"0rem":`calc(${c} * var(--mantine-scale))`}function createConverter(c,{shouldScale:a=!1}={}){function d(et){if(et===0||et==="0")return`0${c}`;if(typeof et=="number"){const nt=`${et/16}${c}`;return a?scaleRem(nt):nt}if(typeof et=="string"){if(et===""||et.startsWith("calc(")||et.startsWith("clamp(")||et.includes("rgba("))return et;if(et.includes(","))return et.split(",").map(tt=>d(tt)).join(",");if(et.includes(" "))return et.split(" ").map(tt=>d(tt)).join(" ");if(et.includes(c))return a?scaleRem(et):et;const nt=et.replace("px","");if(!Number.isNaN(Number(nt))){const tt=`${Number(nt)/16}${c}`;return a?scaleRem(tt):tt}}return et}return d}const rem=createConverter("rem",{shouldScale:!0}),em=createConverter("em");function filterProps(c){return Object.keys(c).reduce((a,d)=>(c[d]!==void 0&&(a[d]=c[d]),a),{})}function isNumberLike(c){return typeof c=="number"?!0:typeof c=="string"?c.startsWith("calc(")||c.startsWith("var(")||c.includes(" ")&&c.trim()!==""?!0:/[0-9]/.test(c.trim().replace("-","")[0]):!1}function isElement$1(c){return Array.isArray(c)||c===null?!1:typeof c=="object"?c.type!==React.Fragment:!1}function createSafeContext(c){const a=reactExports.createContext(null);return[({children:nt,value:tt})=>React.createElement(a.Provider,{value:tt},nt),()=>{const nt=reactExports.useContext(a);if(nt===null)throw new Error(c);return nt}]}function createOptionalContext(c=null){const a=reactExports.createContext(c);return[({children:nt,value:tt})=>React.createElement(a.Provider,{value:tt},nt),()=>reactExports.useContext(a)]}const elevations={app:100,modal:200,popover:300,overlay:400,max:9999};function getDefaultZIndex(c){return elevations[c]}const noop=()=>{};function closeOnEscape(c,a={active:!0}){return typeof c!="function"||!a.active?a.onKeyDown||noop:d=>{var et;d.key==="Escape"&&(c(d),(et=a.onTrigger)==null||et.call(a))}}function getSize(c,a="size",d=!0){if(c!==void 0)return isNumberLike(c)?d?rem(c):c:`var(--${a}-${c})`}function getSpacing(c){return getSize(c,"mantine-spacing")}function getRadius(c){return c===void 0?"var(--mantine-radius-default)":getSize(c,"mantine-radius")}function getFontSize(c){return getSize(c,"mantine-font-size")}function getLineHeight(c){return getSize(c,"mantine-line-height",!1)}function getShadow(c){if(c)return getSize(c,"mantine-shadow",!1)}function getBreakpointValue$1(c,a){return c in a.breakpoints?px(a.breakpoints[c]):px(c)}function getSortedBreakpoints(c,a){const d=c.map(et=>({value:et,px:getBreakpointValue$1(et,a)}));return d.sort((et,nt)=>et.px-nt.px),d}function clamp$1(c,a,d){return a===void 0&&d===void 0?c:a!==void 0&&d===void 0?Math.max(c,a):Math.min(a===void 0&&d!==void 0?c:Math.max(c,a),d)}function randomId(){return`mantine-${Math.random().toString(36).slice(2,11)}`}const DEFAULT_EVENTS=["mousedown","touchstart"];function useClickOutside(c,a,d){const et=reactExports.useRef();return reactExports.useEffect(()=>{const nt=tt=>{const{target:bt}=tt??{};if(Array.isArray(d)){const mt=(bt==null?void 0:bt.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(bt)&&bt.tagName!=="HTML";d.every($t=>!!$t&&!tt.composedPath().includes($t))&&!mt&&c()}else et.current&&!et.current.contains(bt)&&c()};return(a||DEFAULT_EVENTS).forEach(tt=>document.addEventListener(tt,nt)),()=>{(a||DEFAULT_EVENTS).forEach(tt=>document.removeEventListener(tt,nt))}},[et,c,d]),et}function attachMediaListener(c,a){try{return c.addEventListener("change",a),()=>c.removeEventListener("change",a)}catch{return c.addListener(a),()=>c.removeListener(a)}}function getInitialValue(c,a){return typeof a=="boolean"?a:typeof window<"u"&&"matchMedia"in window?window.matchMedia(c).matches:!1}function useMediaQuery(c,a,{getInitialValueInEffect:d}={getInitialValueInEffect:!0}){const[et,nt]=reactExports.useState(d?a:getInitialValue(c)),tt=reactExports.useRef();return reactExports.useEffect(()=>{if("matchMedia"in window)return tt.current=window.matchMedia(c),nt(tt.current.matches),attachMediaListener(tt.current,bt=>nt(bt.matches))},[c]),et}function useColorScheme(c,a){return useMediaQuery("(prefers-color-scheme: dark)",c==="dark",a)?"dark":"light"}const useIsomorphicEffect=typeof document<"u"?reactExports.useLayoutEffect:reactExports.useEffect;function useDidUpdate(c,a){const d=reactExports.useRef(!1);reactExports.useEffect(()=>()=>{d.current=!1},[]),reactExports.useEffect(()=>{if(d.current)return c();d.current=!0},a)}function useFocusReturn({opened:c,shouldReturnFocus:a=!0}){const d=reactExports.useRef(),et=()=>{var nt;d.current&&"focus"in d.current&&typeof d.current.focus=="function"&&((nt=d.current)==null||nt.focus({preventScroll:!0}))};return useDidUpdate(()=>{let nt=-1;const tt=bt=>{bt.key==="Tab"&&window.clearTimeout(nt)};return document.addEventListener("keydown",tt),c?d.current=document.activeElement:a&&(nt=window.setTimeout(et,10)),()=>{window.clearTimeout(nt),document.removeEventListener("keydown",tt)}},[c,a]),et}function createAriaHider(c,a="body > :not(script)"){const d=randomId(),et=Array.from(document.querySelectorAll(a)).map(nt=>{var vt;if((vt=nt==null?void 0:nt.shadowRoot)!=null&&vt.contains(c)||nt.contains(c))return;const tt=nt.getAttribute("aria-hidden"),bt=nt.getAttribute("data-hidden"),mt=nt.getAttribute("data-focus-id");return nt.setAttribute("data-focus-id",d),tt===null||tt==="false"?nt.setAttribute("aria-hidden","true"):!bt&&!mt&&nt.setAttribute("data-hidden",tt),{node:nt,ariaHidden:bt||null}});return()=>{et.forEach(nt=>{!nt||d!==nt.node.getAttribute("data-focus-id")||(nt.ariaHidden===null?nt.node.removeAttribute("aria-hidden"):nt.node.setAttribute("aria-hidden",nt.ariaHidden),nt.node.removeAttribute("data-focus-id"),nt.node.removeAttribute("data-hidden"))})}}const TABBABLE_NODES=/input|select|textarea|button|object/,FOCUS_SELECTOR="a, input, select, textarea, button, object, [tabindex]";function hidden(c){return c.style.display==="none"}function visible(c){if(c.getAttribute("aria-hidden")||c.getAttribute("hidden")||c.getAttribute("type")==="hidden")return!1;let d=c;for(;d&&!(d===document.body||d.nodeType===11);){if(hidden(d))return!1;d=d.parentNode}return!0}function getElementTabIndex(c){let a=c.getAttribute("tabindex");return a===null&&(a=void 0),parseInt(a,10)}function focusable(c){const a=c.nodeName.toLowerCase(),d=!Number.isNaN(getElementTabIndex(c));return(TABBABLE_NODES.test(a)&&!c.disabled||c instanceof HTMLAnchorElement&&c.href||d)&&visible(c)}function tabbable(c){const a=getElementTabIndex(c);return(Number.isNaN(a)||a>=0)&&focusable(c)}function findTabbableDescendants(c){return Array.from(c.querySelectorAll(FOCUS_SELECTOR)).filter(tabbable)}function scopeTab(c,a){const d=findTabbableDescendants(c);if(!d.length){a.preventDefault();return}const et=d[a.shiftKey?0:d.length-1],nt=c.getRootNode();let tt=et===nt.activeElement||c===nt.activeElement;const bt=nt.activeElement;if(bt.tagName==="INPUT"&&bt.getAttribute("type")==="radio"&&(tt=d.filter(At=>At.getAttribute("type")==="radio"&&At.getAttribute("name")===bt.getAttribute("name")).includes(et)),!tt)return;a.preventDefault();const vt=d[a.shiftKey?d.length-1:0];vt&&vt.focus()}function useFocusTrap(c=!0){const a=reactExports.useRef(),d=reactExports.useRef(null),et=tt=>{let bt=tt.querySelector("[data-autofocus]");if(!bt){const mt=Array.from(tt.querySelectorAll(FOCUS_SELECTOR));bt=mt.find(tabbable)||mt.find(focusable)||null,!bt&&focusable(tt)&&(bt=tt)}bt&&bt.focus({preventScroll:!0})},nt=reactExports.useCallback(tt=>{if(c){if(tt===null){d.current&&(d.current(),d.current=null);return}d.current=createAriaHider(tt),a.current!==tt&&(tt?(setTimeout(()=>{tt.getRootNode()&&et(tt)}),a.current=tt):a.current=null)}},[c]);return reactExports.useEffect(()=>{if(!c)return;a.current&&setTimeout(()=>et(a.current));const tt=bt=>{bt.key==="Tab"&&a.current&&scopeTab(a.current,bt)};return document.addEventListener("keydown",tt),()=>{document.removeEventListener("keydown",tt),d.current&&d.current()}},[c]),nt}const __useId=React["useId".toString()]||(()=>{});function useReactId$1(){const c=__useId();return c?`mantine-${c.replace(/:/g,"")}`:""}function useId$1(c){const a=useReactId$1(),[d,et]=reactExports.useState(a);return useIsomorphicEffect(()=>{et(randomId())},[]),typeof c=="string"?c:typeof window>"u"?a:d}function useWindowEvent(c,a,d){reactExports.useEffect(()=>(window.addEventListener(c,a,d),()=>window.removeEventListener(c,a,d)),[c,a])}function assignRef(c,a){typeof c=="function"?c(a):typeof c=="object"&&c!==null&&"current"in c&&(c.current=a)}function mergeRefs(...c){return a=>{c.forEach(d=>assignRef(d,a))}}function useMergedRef(...c){return reactExports.useCallback(mergeRefs(...c),c)}function useUncontrolled({value:c,defaultValue:a,finalValue:d,onChange:et=()=>{}}){const[nt,tt]=reactExports.useState(a!==void 0?a:d),bt=(mt,...vt)=>{tt(mt),et==null||et(mt,...vt)};return c!==void 0?[c,et,!0]:[nt,bt,!1]}function useReducedMotion(c,a){return useMediaQuery("(prefers-reduced-motion: reduce)",c,a)}function useDisclosure(c=!1,a){const{onOpen:d,onClose:et}=a||{},[nt,tt]=reactExports.useState(c),bt=reactExports.useCallback(()=>{tt($t=>$t||(d==null||d(),!0))},[d]),mt=reactExports.useCallback(()=>{tt($t=>$t&&(et==null||et(),!1))},[et]),vt=reactExports.useCallback(()=>{nt?mt():bt()},[mt,bt,nt]);return[nt,{open:bt,close:mt,toggle:vt}]}var dist$2={};(function(c){Object.defineProperty(c,Symbol.toStringTag,{value:"Module"});const a=bufferPolyfill,d=browserExports$1,et=bt=>bt&&bt.__esModule?bt:{default:bt},nt=et(d),tt=globalThis||void 0||self;Object.defineProperty(c,"Buffer",{enumerable:!0,get:()=>a.Buffer}),Object.defineProperty(c,"process",{enumerable:!0,get:()=>nt.default}),c.global=tt})(dist$2);function createVarsResolver(c){return c}function r$5(c){var a,d,et="";if(typeof c=="string"||typeof c=="number")et+=c;else if(typeof c=="object")if(Array.isArray(c)){var nt=c.length;for(a=0;a{Object.entries(d).forEach(([et,nt])=>{a[et]?a[et]=clsx(a[et],nt):a[et]=nt})}),a}function resolveClassNames({theme:c,classNames:a,props:d,stylesCtx:et}){const tt=(Array.isArray(a)?a:[a]).map(bt=>typeof bt=="function"?bt(c,d,et):bt||EMPTY_CLASS_NAMES);return mergeClassNames(tt)}function resolveStyles({theme:c,styles:a,props:d,stylesCtx:et}){return(Array.isArray(a)?a:[a]).reduce((tt,bt)=>typeof bt=="function"?{...tt,...bt(c,d,et)}:{...tt,...bt},{})}const MantineContext=reactExports.createContext(null);function useMantineContext(){const c=reactExports.useContext(MantineContext);if(!c)throw new Error("[@mantine/core] MantineProvider was not found in tree");return c}function useMantineCssVariablesResolver(){return useMantineContext().cssVariablesResolver}function useMantineClassNamesPrefix(){return useMantineContext().classNamesPrefix}function useMantineStyleNonce(){return useMantineContext().getStyleNonce}function useMantineWithStaticClasses(){return useMantineContext().withStaticClasses}function useMantineIsHeadless(){return useMantineContext().headless}function isHexColor(c){return/^#?([0-9A-F]{3}){1,2}([0-9A-F]{2})?$/i.test(c)}function hexToRgba(c){let a=c.replace("#","");if(a.length===3){const bt=a.split("");a=[bt[0],bt[0],bt[1],bt[1],bt[2],bt[2]].join("")}if(a.length===8){const bt=parseInt(a.slice(6,8),16)/255;return{r:parseInt(a.slice(0,2),16),g:parseInt(a.slice(2,4),16),b:parseInt(a.slice(4,6),16),a:bt}}const d=parseInt(a,16),et=d>>16&255,nt=d>>8&255,tt=d&255;return{r:et,g:nt,b:tt,a:1}}function rgbStringToRgba(c){const[a,d,et,nt]=c.replace(/[^0-9,./]/g,"").split(/[/,]/).map(Number);return{r:a,g:d,b:et,a:nt||1}}function hslStringToRgba(c){const a=/^hsla?\(\s*(\d+)\s*,\s*(\d+%)\s*,\s*(\d+%)\s*(,\s*(0?\.\d+|\d+(\.\d+)?))?\s*\)$/i,d=c.match(a);if(!d)return{r:0,g:0,b:0,a:1};const et=parseInt(d[1],10),nt=parseInt(d[2],10)/100,tt=parseInt(d[3],10)/100,bt=d[5]?parseFloat(d[5]):void 0,mt=(1-Math.abs(2*tt-1))*nt,vt=et/60,$t=mt*(1-Math.abs(vt%2-1)),At=tt-mt/2;let Mt,Tt,Rt;return vt>=0&&vt<1?(Mt=mt,Tt=$t,Rt=0):vt>=1&&vt<2?(Mt=$t,Tt=mt,Rt=0):vt>=2&&vt<3?(Mt=0,Tt=mt,Rt=$t):vt>=3&&vt<4?(Mt=0,Tt=$t,Rt=mt):vt>=4&&vt<5?(Mt=$t,Tt=0,Rt=mt):(Mt=mt,Tt=0,Rt=$t),{r:Math.round((Mt+At)*255),g:Math.round((Tt+At)*255),b:Math.round((Rt+At)*255),a:bt||1}}function toRgba(c){return isHexColor(c)?hexToRgba(c):c.startsWith("rgb")?rgbStringToRgba(c):c.startsWith("hsl")?hslStringToRgba(c):{r:0,g:0,b:0,a:1}}function darken(c,a){if(c.startsWith("var("))return`color-mix(in srgb, ${c}, black ${a*100}%)`;const{r:d,g:et,b:nt,a:tt}=toRgba(c),bt=1-a,mt=vt=>Math.round(vt*bt);return`rgba(${mt(d)}, ${mt(et)}, ${mt(nt)}, ${tt})`}function getPrimaryShade(c,a){return typeof c.primaryShade=="number"?c.primaryShade:a==="dark"?c.primaryShade.dark:c.primaryShade.light}function gammaCorrect(c){return c<=.03928?c/12.92:((c+.055)/1.055)**2.4}function getLightnessFromOklch(c){const a=c.match(/oklch\((.*?)%\s/);return a?parseFloat(a[1]):null}function luminance(c){if(c.startsWith("oklch("))return(getLightnessFromOklch(c)||0)/100;const{r:a,g:d,b:et}=toRgba(c),nt=a/255,tt=d/255,bt=et/255,mt=gammaCorrect(nt),vt=gammaCorrect(tt),$t=gammaCorrect(bt);return .2126*mt+.7152*vt+.0722*$t}function isLightColor(c,a=.179){return c.startsWith("var(")?!1:luminance(c)>a}function parseThemeColor({color:c,theme:a,colorScheme:d}){if(typeof c!="string")throw new Error(`[@mantine/core] Failed to parse color. Expected color to be a string, instead got ${typeof c}`);if(c==="bright")return{color:c,value:d==="dark"?a.white:a.black,shade:void 0,isThemeColor:!1,isLight:isLightColor(d==="dark"?a.white:a.black,a.luminanceThreshold),variable:"--mantine-color-bright"};if(c==="dimmed")return{color:c,value:d==="dark"?a.colors.dark[2]:a.colors.gray[7],shade:void 0,isThemeColor:!1,isLight:isLightColor(d==="dark"?a.colors.dark[2]:a.colors.gray[6],a.luminanceThreshold),variable:"--mantine-color-dimmed"};if(c==="white"||c==="black")return{color:c,value:c==="white"?a.white:a.black,shade:void 0,isThemeColor:!1,isLight:isLightColor(c==="white"?a.white:a.black,a.luminanceThreshold),variable:`--mantine-color-${c}`};const[et,nt]=c.split("."),tt=nt?Number(nt):void 0,bt=et in a.colors;if(bt){const mt=tt!==void 0?a.colors[et][tt]:a.colors[et][getPrimaryShade(a,d||"light")];return{color:et,value:mt,shade:tt,isThemeColor:bt,isLight:isLightColor(mt,a.luminanceThreshold),variable:nt?`--mantine-color-${et}-${tt}`:`--mantine-color-${et}-filled`}}return{color:c,value:c,isThemeColor:bt,isLight:isLightColor(c,a.luminanceThreshold),shade:tt,variable:void 0}}function getThemeColor(c,a){const d=parseThemeColor({color:c||a.primaryColor,theme:a});return d.variable?`var(${d.variable})`:c}function getGradient(c,a){const d={from:(c==null?void 0:c.from)||a.defaultGradient.from,to:(c==null?void 0:c.to)||a.defaultGradient.to,deg:(c==null?void 0:c.deg)||a.defaultGradient.deg||0},et=getThemeColor(d.from,a),nt=getThemeColor(d.to,a);return`linear-gradient(${d.deg}deg, ${et} 0%, ${nt} 100%)`}function rgba(c,a){if(typeof c!="string"||a>1||a<0)return"rgba(0, 0, 0, 1)";if(c.startsWith("var(")){const tt=(1-a)*100;return`color-mix(in srgb, ${c}, transparent ${tt}%)`}if(c.startsWith("oklch"))return c.includes("/")?c.replace(/\/\s*[\d.]+\s*\)/,`/ ${a})`):c.replace(")",` / ${a})`);const{r:d,g:et,b:nt}=toRgba(c);return`rgba(${d}, ${et}, ${nt}, ${a})`}const alpha=rgba,defaultVariantColorsResolver=({color:c,theme:a,variant:d,gradient:et,autoContrast:nt})=>{const tt=parseThemeColor({color:c,theme:a}),bt=typeof nt=="boolean"?nt:a.autoContrast;if(d==="filled"){const mt=bt&&tt.isLight?"var(--mantine-color-black)":"var(--mantine-color-white)";return tt.isThemeColor?tt.shade===void 0?{background:`var(--mantine-color-${c}-filled)`,hover:`var(--mantine-color-${c}-filled-hover)`,color:mt,border:`${rem(1)} solid transparent`}:{background:`var(--mantine-color-${tt.color}-${tt.shade})`,hover:`var(--mantine-color-${tt.color}-${tt.shade===9?8:tt.shade+1})`,color:mt,border:`${rem(1)} solid transparent`}:{background:c,hover:darken(c,.1),color:mt,border:`${rem(1)} solid transparent`}}if(d==="light"){if(tt.isThemeColor){if(tt.shade===void 0)return{background:`var(--mantine-color-${c}-light)`,hover:`var(--mantine-color-${c}-light-hover)`,color:`var(--mantine-color-${c}-light-color)`,border:`${rem(1)} solid transparent`};const mt=a.colors[tt.color][tt.shade];return{background:rgba(mt,.1),hover:rgba(mt,.12),color:`var(--mantine-color-${tt.color}-${Math.min(tt.shade,6)})`,border:`${rem(1)} solid transparent`}}return{background:rgba(c,.1),hover:rgba(c,.12),color:c,border:`${rem(1)} solid transparent`}}if(d==="outline")return tt.isThemeColor?tt.shade===void 0?{background:"transparent",hover:`var(--mantine-color-${c}-outline-hover)`,color:`var(--mantine-color-${c}-outline)`,border:`${rem(1)} solid var(--mantine-color-${c}-outline)`}:{background:"transparent",hover:rgba(a.colors[tt.color][tt.shade],.05),color:`var(--mantine-color-${tt.color}-${tt.shade})`,border:`${rem(1)} solid var(--mantine-color-${tt.color}-${tt.shade})`}:{background:"transparent",hover:rgba(c,.05),color:c,border:`${rem(1)} solid ${c}`};if(d==="subtle"){if(tt.isThemeColor){if(tt.shade===void 0)return{background:"transparent",hover:`var(--mantine-color-${c}-light-hover)`,color:`var(--mantine-color-${c}-light-color)`,border:`${rem(1)} solid transparent`};const mt=a.colors[tt.color][tt.shade];return{background:"transparent",hover:rgba(mt,.12),color:`var(--mantine-color-${tt.color}-${Math.min(tt.shade,6)})`,border:`${rem(1)} solid transparent`}}return{background:"transparent",hover:rgba(c,.12),color:c,border:`${rem(1)} solid transparent`}}return d==="transparent"?tt.isThemeColor?tt.shade===void 0?{background:"transparent",hover:"transparent",color:`var(--mantine-color-${c}-light-color)`,border:`${rem(1)} solid transparent`}:{background:"transparent",hover:"transparent",color:`var(--mantine-color-${tt.color}-${Math.min(tt.shade,6)})`,border:`${rem(1)} solid transparent`}:{background:"transparent",hover:"transparent",color:c,border:`${rem(1)} solid transparent`}:d==="white"?tt.isThemeColor?tt.shade===void 0?{background:"var(--mantine-color-white)",hover:darken(a.white,.01),color:`var(--mantine-color-${c}-filled)`,border:`${rem(1)} solid transparent`}:{background:"var(--mantine-color-white)",hover:darken(a.white,.01),color:`var(--mantine-color-${tt.color}-${tt.shade})`,border:`${rem(1)} solid transparent`}:{background:"var(--mantine-color-white)",hover:darken(a.white,.01),color:c,border:`${rem(1)} solid transparent`}:d==="gradient"?{background:getGradient(et,a),hover:getGradient(et,a),color:"var(--mantine-color-white)",border:"none"}:d==="default"?{background:"var(--mantine-color-default)",hover:"var(--mantine-color-default-hover)",color:"var(--mantine-color-default-color)",border:`${rem(1)} solid var(--mantine-color-default-border)`}:{}},DEFAULT_COLORS={dark:["#C9C9C9","#b8b8b8","#828282","#696969","#424242","#3b3b3b","#2e2e2e","#242424","#1f1f1f","#141414"],gray:["#f8f9fa","#f1f3f5","#e9ecef","#dee2e6","#ced4da","#adb5bd","#868e96","#495057","#343a40","#212529"],red:["#fff5f5","#ffe3e3","#ffc9c9","#ffa8a8","#ff8787","#ff6b6b","#fa5252","#f03e3e","#e03131","#c92a2a"],pink:["#fff0f6","#ffdeeb","#fcc2d7","#faa2c1","#f783ac","#f06595","#e64980","#d6336c","#c2255c","#a61e4d"],grape:["#f8f0fc","#f3d9fa","#eebefa","#e599f7","#da77f2","#cc5de8","#be4bdb","#ae3ec9","#9c36b5","#862e9c"],violet:["#f3f0ff","#e5dbff","#d0bfff","#b197fc","#9775fa","#845ef7","#7950f2","#7048e8","#6741d9","#5f3dc4"],indigo:["#edf2ff","#dbe4ff","#bac8ff","#91a7ff","#748ffc","#5c7cfa","#4c6ef5","#4263eb","#3b5bdb","#364fc7"],blue:["#e7f5ff","#d0ebff","#a5d8ff","#74c0fc","#4dabf7","#339af0","#228be6","#1c7ed6","#1971c2","#1864ab"],cyan:["#e3fafc","#c5f6fa","#99e9f2","#66d9e8","#3bc9db","#22b8cf","#15aabf","#1098ad","#0c8599","#0b7285"],teal:["#e6fcf5","#c3fae8","#96f2d7","#63e6be","#38d9a9","#20c997","#12b886","#0ca678","#099268","#087f5b"],green:["#ebfbee","#d3f9d8","#b2f2bb","#8ce99a","#69db7c","#51cf66","#40c057","#37b24d","#2f9e44","#2b8a3e"],lime:["#f4fce3","#e9fac8","#d8f5a2","#c0eb75","#a9e34b","#94d82d","#82c91e","#74b816","#66a80f","#5c940d"],yellow:["#fff9db","#fff3bf","#ffec99","#ffe066","#ffd43b","#fcc419","#fab005","#f59f00","#f08c00","#e67700"],orange:["#fff4e6","#ffe8cc","#ffd8a8","#ffc078","#ffa94d","#ff922b","#fd7e14","#f76707","#e8590c","#d9480f"]},DEFAULT_FONT_FAMILY="-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",DEFAULT_THEME={scale:1,fontSmoothing:!0,focusRing:"auto",white:"#fff",black:"#000",colors:DEFAULT_COLORS,primaryShade:{light:6,dark:8},primaryColor:"blue",variantColorResolver:defaultVariantColorsResolver,autoContrast:!1,luminanceThreshold:.3,fontFamily:DEFAULT_FONT_FAMILY,fontFamilyMonospace:"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace",respectReducedMotion:!1,cursorType:"default",defaultGradient:{from:"blue",to:"cyan",deg:45},defaultRadius:"sm",activeClassName:"mantine-active",focusClassName:"",headings:{fontFamily:DEFAULT_FONT_FAMILY,fontWeight:"700",textWrap:"wrap",sizes:{h1:{fontSize:rem(34),lineHeight:"1.3"},h2:{fontSize:rem(26),lineHeight:"1.35"},h3:{fontSize:rem(22),lineHeight:"1.4"},h4:{fontSize:rem(18),lineHeight:"1.45"},h5:{fontSize:rem(16),lineHeight:"1.5"},h6:{fontSize:rem(14),lineHeight:"1.5"}}},fontSizes:{xs:rem(12),sm:rem(14),md:rem(16),lg:rem(18),xl:rem(20)},lineHeights:{xs:"1.4",sm:"1.45",md:"1.55",lg:"1.6",xl:"1.65"},radius:{xs:rem(2),sm:rem(4),md:rem(8),lg:rem(16),xl:rem(32)},spacing:{xs:rem(10),sm:rem(12),md:rem(16),lg:rem(20),xl:rem(32)},breakpoints:{xs:"36em",sm:"48em",md:"62em",lg:"75em",xl:"88em"},shadows:{xs:`0 ${rem(1)} ${rem(3)} rgba(0, 0, 0, 0.05), 0 ${rem(1)} ${rem(2)} rgba(0, 0, 0, 0.1)`,sm:`0 ${rem(1)} ${rem(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${rem(10)} ${rem(15)} ${rem(-5)}, rgba(0, 0, 0, 0.04) 0 ${rem(7)} ${rem(7)} ${rem(-5)}`,md:`0 ${rem(1)} ${rem(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${rem(20)} ${rem(25)} ${rem(-5)}, rgba(0, 0, 0, 0.04) 0 ${rem(10)} ${rem(10)} ${rem(-5)}`,lg:`0 ${rem(1)} ${rem(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${rem(28)} ${rem(23)} ${rem(-7)}, rgba(0, 0, 0, 0.04) 0 ${rem(12)} ${rem(12)} ${rem(-7)}`,xl:`0 ${rem(1)} ${rem(3)} rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 ${rem(36)} ${rem(28)} ${rem(-7)}, rgba(0, 0, 0, 0.04) 0 ${rem(17)} ${rem(17)} ${rem(-7)}`},other:{},components:{}};function isMantineColorScheme(c){return c==="auto"||c==="dark"||c==="light"}function localStorageColorSchemeManager({key:c="mantine-color-scheme-value"}={}){let a;return{get:d=>{if(typeof window>"u")return d;try{const et=window.localStorage.getItem(c);return isMantineColorScheme(et)?et:d}catch{return d}},set:d=>{try{window.localStorage.setItem(c,d)}catch(et){console.warn("[@mantine/core] Local storage color scheme manager was unable to save color scheme.",et)}},subscribe:d=>{a=et=>{et.storageArea===window.localStorage&&et.key===c&&isMantineColorScheme(et.newValue)&&d(et.newValue)},window.addEventListener("storage",a)},unsubscribe:()=>{window.removeEventListener("storage",a)},clear:()=>{window.localStorage.removeItem(c)}}}const INVALID_PRIMARY_COLOR_ERROR="[@mantine/core] MantineProvider: Invalid theme.primaryColor, it accepts only key of theme.colors, learn more – https://mantine.dev/theming/colors/#primary-color",INVALID_PRIMARY_SHADE_ERROR="[@mantine/core] MantineProvider: Invalid theme.primaryShade, it accepts only 0-9 integers or an object { light: 0-9, dark: 0-9 }";function isValidPrimaryShade(c){return c<0||c>9?!1:parseInt(c.toString(),10)===c}function validateMantineTheme(c){if(!(c.primaryColor in c.colors))throw new Error(INVALID_PRIMARY_COLOR_ERROR);if(typeof c.primaryShade=="object"&&(!isValidPrimaryShade(c.primaryShade.dark)||!isValidPrimaryShade(c.primaryShade.light)))throw new Error(INVALID_PRIMARY_SHADE_ERROR);if(typeof c.primaryShade=="number"&&!isValidPrimaryShade(c.primaryShade))throw new Error(INVALID_PRIMARY_SHADE_ERROR)}function mergeMantineTheme(c,a){var et;if(!a)return validateMantineTheme(c),c;const d=deepMerge(c,a);return a.fontFamily&&!((et=a.headings)!=null&&et.fontFamily)&&(d.headings.fontFamily=a.fontFamily),validateMantineTheme(d),d}const MantineThemeContext=reactExports.createContext(null),useSafeMantineTheme=()=>reactExports.useContext(MantineThemeContext)||DEFAULT_THEME;function useMantineTheme(){const c=reactExports.useContext(MantineThemeContext);if(!c)throw new Error("@mantine/core: MantineProvider was not found in component tree, make sure you have it in your app");return c}function MantineThemeProvider({theme:c,children:a,inherit:d=!0}){const et=useSafeMantineTheme(),nt=reactExports.useMemo(()=>mergeMantineTheme(d?et:DEFAULT_THEME,c),[c,et,d]);return React.createElement(MantineThemeContext.Provider,{value:nt},a)}MantineThemeProvider.displayName="@mantine/core/MantineThemeProvider";function MantineClasses(){const c=useMantineTheme(),a=useMantineStyleNonce(),d=keys(c.breakpoints).reduce((et,nt)=>{const tt=c.breakpoints[nt].includes("px"),bt=px(c.breakpoints[nt]),mt=tt?`${bt-.1}px`:em(bt-.1),vt=tt?`${bt}px`:em(bt);return`${et}@media (max-width: ${mt}) {.mantine-visible-from-${nt} {display: none !important;}}@media (min-width: ${vt}) {.mantine-hidden-from-${nt} {display: none !important;}}`},"");return React.createElement("style",{"data-mantine-styles":"classes",nonce:a==null?void 0:a(),dangerouslySetInnerHTML:{__html:d}})}function cssVariablesObjectToString(c){return Object.entries(c).map(([a,d])=>`${a}: ${d};`).join("")}function wrapWithSelector(c,a){return(Array.isArray(c)?c:[c]).reduce((et,nt)=>`${nt}{${et}}`,a)}function convertCssVariables(c,a){const d=cssVariablesObjectToString(c.variables),et=d?wrapWithSelector(a,d):"",nt=cssVariablesObjectToString(c.dark),tt=nt?wrapWithSelector(`${a}[data-mantine-color-scheme="dark"]`,nt):"",bt=cssVariablesObjectToString(c.light),mt=bt?wrapWithSelector(`${a}[data-mantine-color-scheme="light"]`,bt):"";return`${et}${tt}${mt}`}function getContrastColor({color:c,theme:a,autoContrast:d}){return(typeof d=="boolean"?d:a.autoContrast)&&parseThemeColor({color:c||a.primaryColor,theme:a}).isLight?"var(--mantine-color-black)":"var(--mantine-color-white)"}function getPrimaryContrastColor(c,a){return getContrastColor({color:c.colors[c.primaryColor][getPrimaryShade(c,a)],theme:c,autoContrast:null})}function getCSSColorVariables({theme:c,color:a,colorScheme:d,name:et=a,withColorValues:nt=!0}){if(!c.colors[a])return{};if(d==="light"){const mt=getPrimaryShade(c,"light"),vt={[`--mantine-color-${et}-text`]:`var(--mantine-color-${et}-filled)`,[`--mantine-color-${et}-filled`]:`var(--mantine-color-${et}-${mt})`,[`--mantine-color-${et}-filled-hover`]:`var(--mantine-color-${et}-${mt===9?8:mt+1})`,[`--mantine-color-${et}-light`]:alpha(c.colors[a][mt],.1),[`--mantine-color-${et}-light-hover`]:alpha(c.colors[a][mt],.12),[`--mantine-color-${et}-light-color`]:`var(--mantine-color-${et}-${mt})`,[`--mantine-color-${et}-outline`]:`var(--mantine-color-${et}-${mt})`,[`--mantine-color-${et}-outline-hover`]:alpha(c.colors[a][mt],.05)};return nt?{[`--mantine-color-${et}-0`]:c.colors[a][0],[`--mantine-color-${et}-1`]:c.colors[a][1],[`--mantine-color-${et}-2`]:c.colors[a][2],[`--mantine-color-${et}-3`]:c.colors[a][3],[`--mantine-color-${et}-4`]:c.colors[a][4],[`--mantine-color-${et}-5`]:c.colors[a][5],[`--mantine-color-${et}-6`]:c.colors[a][6],[`--mantine-color-${et}-7`]:c.colors[a][7],[`--mantine-color-${et}-8`]:c.colors[a][8],[`--mantine-color-${et}-9`]:c.colors[a][9],...vt}:vt}const tt=getPrimaryShade(c,"dark"),bt={[`--mantine-color-${et}-text`]:`var(--mantine-color-${et}-4)`,[`--mantine-color-${et}-filled`]:`var(--mantine-color-${et}-${tt})`,[`--mantine-color-${et}-filled-hover`]:`var(--mantine-color-${et}-${tt===9?8:tt+1})`,[`--mantine-color-${et}-light`]:alpha(c.colors[a][Math.max(0,tt-2)],.15),[`--mantine-color-${et}-light-hover`]:alpha(c.colors[a][Math.max(0,tt-2)],.2),[`--mantine-color-${et}-light-color`]:`var(--mantine-color-${et}-${Math.max(tt-5,0)})`,[`--mantine-color-${et}-outline`]:`var(--mantine-color-${et}-${Math.max(tt-4,0)})`,[`--mantine-color-${et}-outline-hover`]:alpha(c.colors[a][Math.max(tt-4,0)],.05)};return nt?{[`--mantine-color-${et}-0`]:c.colors[a][0],[`--mantine-color-${et}-1`]:c.colors[a][1],[`--mantine-color-${et}-2`]:c.colors[a][2],[`--mantine-color-${et}-3`]:c.colors[a][3],[`--mantine-color-${et}-4`]:c.colors[a][4],[`--mantine-color-${et}-5`]:c.colors[a][5],[`--mantine-color-${et}-6`]:c.colors[a][6],[`--mantine-color-${et}-7`]:c.colors[a][7],[`--mantine-color-${et}-8`]:c.colors[a][8],[`--mantine-color-${et}-9`]:c.colors[a][9],...bt}:bt}function isVirtualColor(c){return!!c&&typeof c=="object"&&"mantine-virtual-color"in c}function assignSizeVariables(c,a,d){keys(a).forEach(et=>Object.assign(c,{[`--mantine-${d}-${et}`]:a[et]}))}const defaultCssVariablesResolver=c=>{const a=getPrimaryShade(c,"light"),d=c.defaultRadius in c.radius?c.radius[c.defaultRadius]:rem(c.defaultRadius),et={variables:{"--mantine-scale":c.scale.toString(),"--mantine-cursor-type":c.cursorType,"--mantine-color-scheme":"light dark","--mantine-webkit-font-smoothing":c.fontSmoothing?"antialiased":"unset","--mantine-moz-font-smoothing":c.fontSmoothing?"grayscale":"unset","--mantine-color-white":c.white,"--mantine-color-black":c.black,"--mantine-line-height":c.lineHeights.md,"--mantine-font-family":c.fontFamily,"--mantine-font-family-monospace":c.fontFamilyMonospace,"--mantine-font-family-headings":c.headings.fontFamily,"--mantine-heading-font-weight":c.headings.fontWeight,"--mantine-heading-text-wrap":c.headings.textWrap,"--mantine-radius-default":d,"--mantine-primary-color-filled":`var(--mantine-color-${c.primaryColor}-filled)`,"--mantine-primary-color-filled-hover":`var(--mantine-color-${c.primaryColor}-filled-hover)`,"--mantine-primary-color-light":`var(--mantine-color-${c.primaryColor}-light)`,"--mantine-primary-color-light-hover":`var(--mantine-color-${c.primaryColor}-light-hover)`,"--mantine-primary-color-light-color":`var(--mantine-color-${c.primaryColor}-light-color)`},light:{"--mantine-primary-color-contrast":getPrimaryContrastColor(c,"light"),"--mantine-color-bright":"var(--mantine-color-black)","--mantine-color-text":c.black,"--mantine-color-body":c.white,"--mantine-color-error":"var(--mantine-color-red-6)","--mantine-color-placeholder":"var(--mantine-color-gray-5)","--mantine-color-anchor":`var(--mantine-color-${c.primaryColor}-${a})`,"--mantine-color-default":"var(--mantine-color-white)","--mantine-color-default-hover":"var(--mantine-color-gray-0)","--mantine-color-default-color":"var(--mantine-color-black)","--mantine-color-default-border":"var(--mantine-color-gray-4)","--mantine-color-dimmed":"var(--mantine-color-gray-6)"},dark:{"--mantine-primary-color-contrast":getPrimaryContrastColor(c,"dark"),"--mantine-color-bright":"var(--mantine-color-white)","--mantine-color-text":"var(--mantine-color-dark-0)","--mantine-color-body":"var(--mantine-color-dark-7)","--mantine-color-error":"var(--mantine-color-red-8)","--mantine-color-placeholder":"var(--mantine-color-dark-3)","--mantine-color-anchor":`var(--mantine-color-${c.primaryColor}-4)`,"--mantine-color-default":"var(--mantine-color-dark-6)","--mantine-color-default-hover":"var(--mantine-color-dark-5)","--mantine-color-default-color":"var(--mantine-color-white)","--mantine-color-default-border":"var(--mantine-color-dark-4)","--mantine-color-dimmed":"var(--mantine-color-dark-2)"}};assignSizeVariables(et.variables,c.breakpoints,"breakpoint"),assignSizeVariables(et.variables,c.spacing,"spacing"),assignSizeVariables(et.variables,c.fontSizes,"font-size"),assignSizeVariables(et.variables,c.lineHeights,"line-height"),assignSizeVariables(et.variables,c.shadows,"shadow"),assignSizeVariables(et.variables,c.radius,"radius"),c.colors[c.primaryColor].forEach((tt,bt)=>{et.variables[`--mantine-primary-color-${bt}`]=`var(--mantine-color-${c.primaryColor}-${bt})`}),keys(c.colors).forEach(tt=>{const bt=c.colors[tt];if(isVirtualColor(bt)){Object.assign(et.light,getCSSColorVariables({theme:c,name:bt.name,color:bt.light,colorScheme:"light",withColorValues:!0})),Object.assign(et.dark,getCSSColorVariables({theme:c,name:bt.name,color:bt.dark,colorScheme:"dark",withColorValues:!0}));return}bt.forEach((mt,vt)=>{et.variables[`--mantine-color-${tt}-${vt}`]=mt}),Object.assign(et.light,getCSSColorVariables({theme:c,color:tt,colorScheme:"light",withColorValues:!1})),Object.assign(et.dark,getCSSColorVariables({theme:c,color:tt,colorScheme:"dark",withColorValues:!1}))});const nt=c.headings.sizes;return keys(nt).forEach(tt=>{et.variables[`--mantine-${tt}-font-size`]=nt[tt].fontSize,et.variables[`--mantine-${tt}-line-height`]=nt[tt].lineHeight,et.variables[`--mantine-${tt}-font-weight`]=nt[tt].fontWeight||c.headings.fontWeight}),et};function getMergedVariables({theme:c,generator:a}){const d=defaultCssVariablesResolver(c),et=a==null?void 0:a(c);return et?deepMerge(d,et):d}const defaultCssVariables=defaultCssVariablesResolver(DEFAULT_THEME);function removeDefaultVariables(c){const a={variables:{},light:{},dark:{}};return keys(c.variables).forEach(d=>{defaultCssVariables.variables[d]!==c.variables[d]&&(a.variables[d]=c.variables[d])}),keys(c.light).forEach(d=>{defaultCssVariables.light[d]!==c.light[d]&&(a.light[d]=c.light[d])}),keys(c.dark).forEach(d=>{defaultCssVariables.dark[d]!==c.dark[d]&&(a.dark[d]=c.dark[d])}),a}function getColorSchemeCssVariables(c){return` + ${c}[data-mantine-color-scheme="dark"] { --mantine-color-scheme: dark; } + ${c}[data-mantine-color-scheme="light"] { --mantine-color-scheme: light; } +`}function MantineCssVariables({cssVariablesSelector:c,deduplicateCssVariables:a}){const d=useMantineTheme(),et=useMantineStyleNonce(),nt=useMantineCssVariablesResolver(),tt=getMergedVariables({theme:d,generator:nt}),bt=c===":root"&&a,mt=bt?removeDefaultVariables(tt):tt,vt=convertCssVariables(mt,c);return vt?React.createElement("style",{"data-mantine-styles":!0,nonce:et==null?void 0:et(),dangerouslySetInnerHTML:{__html:`${vt}${bt?"":getColorSchemeCssVariables(c)}`}}):null}MantineCssVariables.displayName="@mantine/CssVariables";function suppressNextjsWarning(){const c=console.error;console.error=(...a)=>{a.length>1&&typeof a[0]=="string"&&a[0].toLowerCase().includes("extra attributes from the server")&&typeof a[1]=="string"&&a[1].toLowerCase().includes("data-mantine-color-scheme")||c(...a)}}function setColorSchemeAttribute(c,a){var et;const d=c!=="auto"?c:window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";(et=a())==null||et.setAttribute("data-mantine-color-scheme",d)}function useProviderColorScheme({manager:c,defaultColorScheme:a,getRootElement:d,forceColorScheme:et}){const nt=reactExports.useRef(),[tt,bt]=reactExports.useState(()=>c.get(a)),mt=et||tt,vt=reactExports.useCallback(At=>{et||(setColorSchemeAttribute(At,d),bt(At),c.set(At))},[c.set,mt,et]),$t=reactExports.useCallback(()=>{bt(a),setColorSchemeAttribute(a,d),c.clear()},[c.clear,a]);return reactExports.useEffect(()=>(c.subscribe(vt),c.unsubscribe),[c.subscribe,c.unsubscribe]),useIsomorphicEffect(()=>{setColorSchemeAttribute(c.get(a),d)},[]),reactExports.useEffect(()=>{var Mt;if(et)return setColorSchemeAttribute(et,d),()=>{};et===void 0&&setColorSchemeAttribute(tt,d),nt.current=window.matchMedia("(prefers-color-scheme: dark)");const At=Tt=>{tt==="auto"&&setColorSchemeAttribute(Tt.matches?"dark":"light",d)};return(Mt=nt.current)==null||Mt.addEventListener("change",At),()=>{var Tt;return(Tt=nt.current)==null?void 0:Tt.removeEventListener("change",At)}},[tt,et]),{colorScheme:mt,setColorScheme:vt,clearColorScheme:$t}}function useRespectReduceMotion({respectReducedMotion:c,getRootElement:a}){useIsomorphicEffect(()=>{var d;c&&((d=a())==null||d.setAttribute("data-respect-reduced-motion","true"))},[c])}suppressNextjsWarning();function MantineProvider({theme:c,children:a,getStyleNonce:d,withStaticClasses:et=!0,withGlobalClasses:nt=!0,deduplicateCssVariables:tt=!0,withCssVariables:bt=!0,cssVariablesSelector:mt=":root",classNamesPrefix:vt="mantine",colorSchemeManager:$t=localStorageColorSchemeManager(),defaultColorScheme:At="light",getRootElement:Mt=()=>document.documentElement,cssVariablesResolver:Tt,forceColorScheme:Rt}){const{colorScheme:kt,setColorScheme:It,clearColorScheme:Dt}=useProviderColorScheme({defaultColorScheme:At,forceColorScheme:Rt,manager:$t,getRootElement:Mt});return useRespectReduceMotion({respectReducedMotion:(c==null?void 0:c.respectReducedMotion)||!1,getRootElement:Mt}),React.createElement(MantineContext.Provider,{value:{colorScheme:kt,setColorScheme:It,clearColorScheme:Dt,getRootElement:Mt,classNamesPrefix:vt,getStyleNonce:d,cssVariablesResolver:Tt,cssVariablesSelector:mt,withStaticClasses:et}},React.createElement(MantineThemeProvider,{theme:c},bt&&React.createElement(MantineCssVariables,{cssVariablesSelector:mt,deduplicateCssVariables:tt}),nt&&React.createElement(MantineClasses,null),a))}MantineProvider.displayName="@mantine/core/MantineProvider";function useResolvedStylesApi({classNames:c,styles:a,props:d,stylesCtx:et}){const nt=useMantineTheme();return{resolvedClassNames:resolveClassNames({theme:nt,classNames:c,props:d,stylesCtx:et||void 0}),resolvedStyles:resolveStyles({theme:nt,styles:a,props:d,stylesCtx:et||void 0})}}const FOCUS_CLASS_NAMES={always:"mantine-focus-always",auto:"mantine-focus-auto",never:"mantine-focus-never"};function getGlobalClassNames({theme:c,options:a,unstyled:d}){return clsx((a==null?void 0:a.focusable)&&!d&&(c.focusClassName||FOCUS_CLASS_NAMES[c.focusRing]),(a==null?void 0:a.active)&&!d&&c.activeClassName)}function getOptionsClassNames({selector:c,stylesCtx:a,options:d,props:et,theme:nt}){return resolveClassNames({theme:nt,classNames:d==null?void 0:d.classNames,props:(d==null?void 0:d.props)||et,stylesCtx:a})[c]}function getResolvedClassNames({selector:c,stylesCtx:a,theme:d,classNames:et,props:nt}){return resolveClassNames({theme:d,classNames:et,props:nt,stylesCtx:a})[c]}function getRootClassName({rootSelector:c,selector:a,className:d}){return c===a?d:void 0}function getSelectorClassName({selector:c,classes:a,unstyled:d}){return d?void 0:a[c]}function getStaticClassNames({themeName:c,classNamesPrefix:a,selector:d,withStaticClass:et}){return et===!1?[]:c.map(nt=>`${a}-${nt}-${d}`)}function getThemeClassNames({themeName:c,theme:a,selector:d,props:et,stylesCtx:nt}){return c.map(tt=>{var bt,mt;return(mt=resolveClassNames({theme:a,classNames:(bt=a.components[tt])==null?void 0:bt.classNames,props:et,stylesCtx:nt}))==null?void 0:mt[d]})}function getVariantClassName({options:c,classes:a,selector:d,unstyled:et}){return c!=null&&c.variant&&!et?a[`${d}--${c.variant}`]:void 0}function getClassName({theme:c,options:a,themeName:d,selector:et,classNamesPrefix:nt,classNames:tt,classes:bt,unstyled:mt,className:vt,rootSelector:$t,props:At,stylesCtx:Mt,withStaticClasses:Tt,headless:Rt}){return clsx(getGlobalClassNames({theme:c,options:a,unstyled:mt||Rt}),getThemeClassNames({theme:c,themeName:d,selector:et,props:At,stylesCtx:Mt}),getVariantClassName({options:a,classes:bt,selector:et,unstyled:mt}),getResolvedClassNames({selector:et,stylesCtx:Mt,theme:c,classNames:tt,props:At}),getOptionsClassNames({selector:et,stylesCtx:Mt,options:a,props:At,theme:c}),getRootClassName({rootSelector:$t,selector:et,className:vt}),getSelectorClassName({selector:et,classes:bt,unstyled:mt||Rt}),Tt&&!Rt&&getStaticClassNames({themeName:d,classNamesPrefix:nt,selector:et,withStaticClass:a==null?void 0:a.withStaticClass}),a==null?void 0:a.className)}function getThemeStyles({theme:c,themeName:a,props:d,stylesCtx:et,selector:nt}){return a.map(tt=>{var bt;return resolveStyles({theme:c,styles:(bt=c.components[tt])==null?void 0:bt.styles,props:d,stylesCtx:et})[nt]}).reduce((tt,bt)=>({...tt,...bt}),{})}function resolveStyle({style:c,theme:a}){return Array.isArray(c)?[...c].reduce((d,et)=>({...d,...resolveStyle({style:et,theme:a})}),{}):typeof c=="function"?c(a):c??{}}function mergeVars(c){return c.reduce((a,d)=>(d&&Object.keys(d).forEach(et=>{a[et]={...a[et],...filterProps(d[et])}}),a),{})}function resolveVars({vars:c,varsResolver:a,theme:d,props:et,stylesCtx:nt,selector:tt,themeName:bt,headless:mt}){var vt;return(vt=mergeVars([mt?{}:a==null?void 0:a(d,et,nt),...bt.map($t=>{var At,Mt,Tt;return(Tt=(Mt=(At=d.components)==null?void 0:At[$t])==null?void 0:Mt.vars)==null?void 0:Tt.call(Mt,d,et,nt)}),c==null?void 0:c(d,et,nt)]))==null?void 0:vt[tt]}function getStyle({theme:c,themeName:a,selector:d,options:et,props:nt,stylesCtx:tt,rootSelector:bt,styles:mt,style:vt,vars:$t,varsResolver:At,headless:Mt}){return{...getThemeStyles({theme:c,themeName:a,props:nt,stylesCtx:tt,selector:d}),...resolveStyles({theme:c,styles:mt,props:nt,stylesCtx:tt})[d],...resolveStyles({theme:c,styles:et==null?void 0:et.styles,props:(et==null?void 0:et.props)||nt,stylesCtx:tt})[d],...resolveVars({theme:c,props:nt,stylesCtx:tt,vars:$t,varsResolver:At,selector:d,themeName:a,headless:Mt}),...bt===d?resolveStyle({style:vt,theme:c}):null,...resolveStyle({style:et==null?void 0:et.style,theme:c})}}function useStyles({name:c,classes:a,props:d,stylesCtx:et,className:nt,style:tt,rootSelector:bt="root",unstyled:mt,classNames:vt,styles:$t,vars:At,varsResolver:Mt}){const Tt=useMantineTheme(),Rt=useMantineClassNamesPrefix(),kt=useMantineWithStaticClasses(),It=useMantineIsHeadless(),Dt=(Array.isArray(c)?c:[c]).filter(Nt=>Nt);return(Nt,Ot)=>({className:getClassName({theme:Tt,options:Ot,themeName:Dt,selector:Nt,classNamesPrefix:Rt,classNames:vt,classes:a,unstyled:mt,className:nt,rootSelector:bt,props:d,stylesCtx:et,withStaticClasses:kt,headless:It}),style:getStyle({theme:Tt,themeName:Dt,selector:Nt,options:Ot,props:d,stylesCtx:et,rootSelector:bt,styles:$t,style:tt,vars:At,varsResolver:Mt,headless:It})})}function getAutoContrastValue(c,a){return typeof c=="boolean"?c:a.autoContrast}function disableTransition(){const c=document.createElement("style");return c.innerHTML="*, *::before, *::after {transition: none !important;}",c.setAttribute("data-mantine-disable-transition","true"),document.head.appendChild(c),()=>document.querySelectorAll("[data-mantine-disable-transition]").forEach(d=>d.remove())}function useMantineColorScheme({keepTransitions:c}={}){const a=reactExports.useRef(),d=reactExports.useRef(),et=reactExports.useContext(MantineContext);if(!et)throw new Error("[@mantine/core] MantineProvider was not found in tree");const nt=$t=>{et.setColorScheme($t),a.current=c?()=>{}:disableTransition(),window.clearTimeout(d.current),d.current=window.setTimeout(()=>{var At;(At=a.current)==null||At.call(a)},10)},tt=()=>{et.clearColorScheme(),a.current=c?()=>{}:disableTransition(),window.clearTimeout(d.current),d.current=window.setTimeout(()=>{var $t;($t=a.current)==null||$t.call(a)},10)},bt=useColorScheme("light",{getInitialValueInEffect:!1}),mt=et.colorScheme==="auto"?bt:et.colorScheme,vt=reactExports.useCallback(()=>nt(mt==="light"?"dark":"light"),[nt,mt]);return reactExports.useEffect(()=>()=>{var $t;($t=a.current)==null||$t.call(a),window.clearTimeout(d.current)},[]),{colorScheme:et.colorScheme,setColorScheme:nt,clearColorScheme:tt,toggleColorScheme:vt}}function useProps(c,a,d){var bt;const et=useMantineTheme(),nt=(bt=et.components[c])==null?void 0:bt.defaultProps,tt=typeof nt=="function"?nt(et):nt;return{...a,...tt,...filterProps(d)}}function createTheme(c){return c}function cssObjectToString(c){return keys(c).reduce((a,d)=>c[d]!==void 0?`${a}${camelToKebabCase(d)}:${c[d]};`:a,"").trim()}function stylesToString({selector:c,styles:a,media:d}){const et=a?cssObjectToString(a):"",nt=Array.isArray(d)?d.map(tt=>`@media${tt.query}{${c}{${cssObjectToString(tt.styles)}}}`):[];return`${et?`${c}{${et}}`:""}${nt.join("")}`.trim()}function InlineStyles({selector:c,styles:a,media:d}){const et=useMantineStyleNonce();return React.createElement("style",{"data-mantine-styles":"inline",nonce:et==null?void 0:et(),dangerouslySetInnerHTML:{__html:stylesToString({selector:c,styles:a,media:d})}})}function extractStyleProps(c){const{m:a,mx:d,my:et,mt:nt,mb:tt,ml:bt,mr:mt,me:vt,ms:$t,p:At,px:Mt,py:Tt,pt:Rt,pb:kt,pl:It,pr:Dt,pe:Nt,ps:Ot,bg:Ut,c:Gt,opacity:Wt,ff:Xt,fz:a0,fw:n0,lts:t0,ta:c0,lh:Ct,fs:dt,tt:yt,td:gt,w:xt,miw:St,maw:_t,h:Pt,mih:Et,mah:ht,bgsz:wt,bgp:Bt,bgr:Lt,bga:jt,pos:Ft,top:Vt,left:zt,bottom:qt,right:Kt,inset:e0,display:Zt,flex:Jt,hiddenFrom:i0,visibleFrom:h0,lightHidden:o0,darkHidden:l0,...$0}=c;return{styleProps:filterProps({m:a,mx:d,my:et,mt:nt,mb:tt,ml:bt,mr:mt,me:vt,ms:$t,p:At,px:Mt,py:Tt,pt:Rt,pb:kt,pl:It,pr:Dt,pe:Nt,ps:Ot,bg:Ut,c:Gt,opacity:Wt,ff:Xt,fz:a0,fw:n0,lts:t0,ta:c0,lh:Ct,fs:dt,tt:yt,td:gt,w:xt,miw:St,maw:_t,h:Pt,mih:Et,mah:ht,bgsz:wt,bgp:Bt,bgr:Lt,bga:jt,pos:Ft,top:Vt,left:zt,bottom:qt,right:Kt,inset:e0,display:Zt,flex:Jt,hiddenFrom:i0,visibleFrom:h0,lightHidden:o0,darkHidden:l0}),rest:$0}}const STYlE_PROPS_DATA={m:{type:"spacing",property:"margin"},mt:{type:"spacing",property:"marginTop"},mb:{type:"spacing",property:"marginBottom"},ml:{type:"spacing",property:"marginLeft"},mr:{type:"spacing",property:"marginRight"},ms:{type:"spacing",property:"marginInlineStart"},me:{type:"spacing",property:"marginInlineEnd"},mx:{type:"spacing",property:"marginInline"},my:{type:"spacing",property:"marginBlock"},p:{type:"spacing",property:"padding"},pt:{type:"spacing",property:"paddingTop"},pb:{type:"spacing",property:"paddingBottom"},pl:{type:"spacing",property:"paddingLeft"},pr:{type:"spacing",property:"paddingRight"},ps:{type:"spacing",property:"paddingInlineStart"},pe:{type:"spacing",property:"paddingInlineEnd"},px:{type:"spacing",property:"paddingInline"},py:{type:"spacing",property:"paddingBlock"},bg:{type:"color",property:"background"},c:{type:"textColor",property:"color"},opacity:{type:"identity",property:"opacity"},ff:{type:"fontFamily",property:"fontFamily"},fz:{type:"fontSize",property:"fontSize"},fw:{type:"identity",property:"fontWeight"},lts:{type:"size",property:"letterSpacing"},ta:{type:"identity",property:"textAlign"},lh:{type:"lineHeight",property:"lineHeight"},fs:{type:"identity",property:"fontStyle"},tt:{type:"identity",property:"textTransform"},td:{type:"identity",property:"textDecoration"},w:{type:"spacing",property:"width"},miw:{type:"spacing",property:"minWidth"},maw:{type:"spacing",property:"maxWidth"},h:{type:"spacing",property:"height"},mih:{type:"spacing",property:"minHeight"},mah:{type:"spacing",property:"maxHeight"},bgsz:{type:"size",property:"backgroundSize"},bgp:{type:"identity",property:"backgroundPosition"},bgr:{type:"identity",property:"backgroundRepeat"},bga:{type:"identity",property:"backgroundAttachment"},pos:{type:"identity",property:"position"},top:{type:"identity",property:"top"},left:{type:"size",property:"left"},bottom:{type:"size",property:"bottom"},right:{type:"size",property:"right"},inset:{type:"size",property:"inset"},display:{type:"identity",property:"display"},flex:{type:"identity",property:"flex"}};function colorResolver(c,a){const d=parseThemeColor({color:c,theme:a});return d.color==="dimmed"?"var(--mantine-color-dimmed)":d.color==="bright"?"var(--mantine-color-bright)":d.variable?`var(${d.variable})`:d.color}function textColorResolver(c,a){const d=parseThemeColor({color:c,theme:a});return d.isThemeColor&&d.shade===void 0?`var(--mantine-color-${d.color}-text)`:colorResolver(c,a)}const values={text:"var(--mantine-font-family)",mono:"var(--mantine-font-family-monospace)",monospace:"var(--mantine-font-family-monospace)",heading:"var(--mantine-font-family-headings)",headings:"var(--mantine-font-family-headings)"};function fontFamilyResolver(c){return typeof c=="string"&&c in values?values[c]:c}const headings$1=["h1","h2","h3","h4","h5","h6"];function fontSizeResolver(c,a){return typeof c=="string"&&c in a.fontSizes?`var(--mantine-font-size-${c})`:typeof c=="string"&&headings$1.includes(c)?`var(--mantine-${c}-font-size)`:typeof c=="number"||typeof c=="string"?rem(c):c}function identityResolver(c){return c}const headings=["h1","h2","h3","h4","h5","h6"];function lineHeightResolver(c,a){return typeof c=="string"&&c in a.lineHeights?`var(--mantine-line-height-${c})`:typeof c=="string"&&headings.includes(c)?`var(--mantine-${c}-line-height)`:c}function sizeResolver(c){return typeof c=="number"?rem(c):c}function spacingResolver(c,a){if(typeof c=="number")return rem(c);if(typeof c=="string"){const d=c.replace("-","");if(!(d in a.spacing))return rem(c);const et=`--mantine-spacing-${d}`;return c.startsWith("-")?`calc(var(${et}) * -1)`:`var(${et})`}return c}const resolvers={color:colorResolver,textColor:textColorResolver,fontSize:fontSizeResolver,spacing:spacingResolver,identity:identityResolver,size:sizeResolver,lineHeight:lineHeightResolver,fontFamily:fontFamilyResolver};function replaceMediaQuery(c){return c.replace("(min-width: ","").replace("em)","")}function sortMediaQueries({media:c,...a}){const et=Object.keys(c).sort((nt,tt)=>Number(replaceMediaQuery(nt))-Number(replaceMediaQuery(tt))).map(nt=>({query:nt,styles:c[nt]}));return{...a,media:et}}function hasResponsiveStyles(c){if(typeof c!="object"||c===null)return!1;const a=Object.keys(c);return!(a.length===1&&a[0]==="base")}function getBaseValue(c){return typeof c=="object"&&c!==null?"base"in c?c.base:void 0:c}function getBreakpointKeys(c){return typeof c=="object"&&c!==null?keys(c).filter(a=>a!=="base"):[]}function getBreakpointValue(c,a){return typeof c=="object"&&c!==null&&a in c?c[a]:c}function parseStyleProps({styleProps:c,data:a,theme:d}){return sortMediaQueries(keys(c).reduce((et,nt)=>{if(nt==="hiddenFrom"||nt==="visibleFrom")return et;const tt=a[nt],bt=Array.isArray(tt.property)?tt.property:[tt.property],mt=getBaseValue(c[nt]);if(!hasResponsiveStyles(c[nt]))return bt.forEach($t=>{et.inlineStyles[$t]=resolvers[tt.type](mt,d)}),et;et.hasResponsiveStyles=!0;const vt=getBreakpointKeys(c[nt]);return bt.forEach($t=>{mt&&(et.styles[$t]=resolvers[tt.type](mt,d)),vt.forEach(At=>{const Mt=`(min-width: ${d.breakpoints[At]})`;et.media[Mt]={...et.media[Mt],[$t]:resolvers[tt.type](getBreakpointValue(c[nt],At),d)}})}),et},{hasResponsiveStyles:!1,styles:{},inlineStyles:{},media:{}}))}function useRandomClassName(){return`__m__-${reactExports.useId().replace(/:/g,"")}`}function createPolymorphicComponent(c){return c}function transformModKey(c){return c.startsWith("data-")?c:`data-${c}`}function getMod(c){return Object.keys(c).reduce((a,d)=>{const et=c[d];return et===void 0||et===""||et===!1||et===null||(a[transformModKey(d)]=c[d]),a},{})}function getBoxMod(c){return c?typeof c=="string"?{[transformModKey(c)]:!0}:Array.isArray(c)?[...c].reduce((a,d)=>({...a,...getBoxMod(d)}),{}):getMod(c):null}function mergeStyles(c,a){return Array.isArray(c)?[...c].reduce((d,et)=>({...d,...mergeStyles(et,a)}),{}):typeof c=="function"?c(a):c??{}}function getBoxStyle({theme:c,style:a,vars:d,styleProps:et}){const nt=mergeStyles(a,c),tt=mergeStyles(d,c);return{...nt,...tt,...et}}const _Box=reactExports.forwardRef(({component:c,style:a,__vars:d,className:et,variant:nt,mod:tt,size:bt,hiddenFrom:mt,visibleFrom:vt,lightHidden:$t,darkHidden:At,renderRoot:Mt,...Tt},Rt)=>{const kt=useMantineTheme(),It=c||"div",{styleProps:Dt,rest:Nt}=extractStyleProps(Tt),Ot=useRandomClassName(),Ut=parseStyleProps({styleProps:Dt,theme:kt,data:STYlE_PROPS_DATA}),Gt={ref:Rt,style:getBoxStyle({theme:kt,style:a,vars:d,styleProps:Ut.inlineStyles}),className:clsx(et,{[Ot]:Ut.hasResponsiveStyles,"mantine-light-hidden":$t,"mantine-dark-hidden":At,[`mantine-hidden-from-${mt}`]:mt,[`mantine-visible-from-${vt}`]:vt}),"data-variant":nt,"data-size":isNumberLike(bt)?void 0:bt||void 0,...getBoxMod(tt),...Nt};return React.createElement(React.Fragment,null,Ut.hasResponsiveStyles&&React.createElement(InlineStyles,{selector:`.${Ot}`,styles:Ut.styles,media:Ut.media}),typeof Mt=="function"?Mt(Gt):React.createElement(It,{...Gt}))});_Box.displayName="@mantine/core/Box";const Box=_Box;function identity$1(c){return c}function factory(c){const a=reactExports.forwardRef(c);return a.extend=identity$1,a}function polymorphicFactory(c){const a=reactExports.forwardRef(c);return a.extend=identity$1,a}const DirectionContext=reactExports.createContext({dir:"ltr",toggleDirection:()=>{},setDirection:()=>{}});function useDirection(){return reactExports.useContext(DirectionContext)}var classes$E={root:"m_87cf2631"};const defaultProps$1j={__staticSelector:"UnstyledButton"},UnstyledButton=polymorphicFactory((c,a)=>{const d=useProps("UnstyledButton",defaultProps$1j,c),{className:et,component:nt="button",__staticSelector:tt,unstyled:bt,classNames:mt,styles:vt,style:$t,...At}=d,Mt=useStyles({name:tt,props:d,classes:classes$E,className:et,style:$t,classNames:mt,styles:vt,unstyled:bt});return React.createElement(Box,{...Mt("root",{focusable:!0}),component:nt,ref:a,type:nt==="button"?"button":void 0,...At})});UnstyledButton.classes=classes$E;UnstyledButton.displayName="@mantine/core/UnstyledButton";var classes$D={root:"m_515a97f8"};const defaultProps$1i={},VisuallyHidden=factory((c,a)=>{const d=useProps("VisuallyHidden",defaultProps$1i,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,...$t}=d,At=useStyles({name:"VisuallyHidden",classes:classes$D,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt});return React.createElement(Box,{component:"span",ref:a,...At("root"),...$t})});VisuallyHidden.classes=classes$D;VisuallyHidden.displayName="@mantine/core/VisuallyHidden";var classes$C={root:"m_1b7284a3"};const defaultProps$1h={},varsResolver$y=(c,{radius:a,shadow:d})=>({root:{"--paper-radius":a===void 0?void 0:getRadius(a),"--paper-shadow":getShadow(d)}}),Paper=polymorphicFactory((c,a)=>{const d=useProps("Paper",defaultProps$1h,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,withBorder:vt,vars:$t,radius:At,shadow:Mt,variant:Tt,mod:Rt,...kt}=d,It=useStyles({name:"Paper",props:d,classes:classes$C,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:$t,varsResolver:varsResolver$y});return React.createElement(Box,{ref:a,mod:[{"data-with-border":vt},Rt],...It("root"),variant:Tt,...kt})});Paper.classes=classes$C;Paper.displayName="@mantine/core/Paper";function getNodeName(c){return isNode(c)?(c.nodeName||"").toLowerCase():"#document"}function getWindow(c){var a;return(c==null||(a=c.ownerDocument)==null?void 0:a.defaultView)||window}function getDocumentElement(c){var a;return(a=(isNode(c)?c.ownerDocument:c.document)||window.document)==null?void 0:a.documentElement}function isNode(c){return c instanceof Node||c instanceof getWindow(c).Node}function isElement(c){return c instanceof Element||c instanceof getWindow(c).Element}function isHTMLElement(c){return c instanceof HTMLElement||c instanceof getWindow(c).HTMLElement}function isShadowRoot(c){return typeof ShadowRoot>"u"?!1:c instanceof ShadowRoot||c instanceof getWindow(c).ShadowRoot}function isOverflowElement(c){const{overflow:a,overflowX:d,overflowY:et,display:nt}=getComputedStyle(c);return/auto|scroll|overlay|hidden|clip/.test(a+et+d)&&!["inline","contents"].includes(nt)}function isTableElement(c){return["table","td","th"].includes(getNodeName(c))}function isContainingBlock(c){const a=isWebKit(),d=getComputedStyle(c);return d.transform!=="none"||d.perspective!=="none"||(d.containerType?d.containerType!=="normal":!1)||!a&&(d.backdropFilter?d.backdropFilter!=="none":!1)||!a&&(d.filter?d.filter!=="none":!1)||["transform","perspective","filter"].some(et=>(d.willChange||"").includes(et))||["paint","layout","strict","content"].some(et=>(d.contain||"").includes(et))}function getContainingBlock(c){let a=getParentNode(c);for(;isHTMLElement(a)&&!isLastTraversableNode(a);){if(isContainingBlock(a))return a;a=getParentNode(a)}return null}function isWebKit(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function isLastTraversableNode(c){return["html","body","#document"].includes(getNodeName(c))}function getComputedStyle(c){return getWindow(c).getComputedStyle(c)}function getNodeScroll(c){return isElement(c)?{scrollLeft:c.scrollLeft,scrollTop:c.scrollTop}:{scrollLeft:c.pageXOffset,scrollTop:c.pageYOffset}}function getParentNode(c){if(getNodeName(c)==="html")return c;const a=c.assignedSlot||c.parentNode||isShadowRoot(c)&&c.host||getDocumentElement(c);return isShadowRoot(a)?a.host:a}function getNearestOverflowAncestor(c){const a=getParentNode(c);return isLastTraversableNode(a)?c.ownerDocument?c.ownerDocument.body:c.body:isHTMLElement(a)&&isOverflowElement(a)?a:getNearestOverflowAncestor(a)}function getOverflowAncestors(c,a,d){var et;a===void 0&&(a=[]),d===void 0&&(d=!0);const nt=getNearestOverflowAncestor(c),tt=nt===((et=c.ownerDocument)==null?void 0:et.body),bt=getWindow(nt);return tt?a.concat(bt,bt.visualViewport||[],isOverflowElement(nt)?nt:[],bt.frameElement&&d?getOverflowAncestors(bt.frameElement):[]):a.concat(nt,getOverflowAncestors(nt,[],d))}const min=Math.min,max$1=Math.max,round=Math.round,floor=Math.floor,createCoords=c=>({x:c,y:c}),oppositeSideMap={left:"right",right:"left",bottom:"top",top:"bottom"},oppositeAlignmentMap={start:"end",end:"start"};function clamp(c,a,d){return max$1(c,min(a,d))}function evaluate(c,a){return typeof c=="function"?c(a):c}function getSide(c){return c.split("-")[0]}function getAlignment(c){return c.split("-")[1]}function getOppositeAxis(c){return c==="x"?"y":"x"}function getAxisLength(c){return c==="y"?"height":"width"}function getSideAxis(c){return["top","bottom"].includes(getSide(c))?"y":"x"}function getAlignmentAxis(c){return getOppositeAxis(getSideAxis(c))}function getAlignmentSides(c,a,d){d===void 0&&(d=!1);const et=getAlignment(c),nt=getAlignmentAxis(c),tt=getAxisLength(nt);let bt=nt==="x"?et===(d?"end":"start")?"right":"left":et==="start"?"bottom":"top";return a.reference[tt]>a.floating[tt]&&(bt=getOppositePlacement(bt)),[bt,getOppositePlacement(bt)]}function getExpandedPlacements(c){const a=getOppositePlacement(c);return[getOppositeAlignmentPlacement(c),a,getOppositeAlignmentPlacement(a)]}function getOppositeAlignmentPlacement(c){return c.replace(/start|end/g,a=>oppositeAlignmentMap[a])}function getSideList(c,a,d){const et=["left","right"],nt=["right","left"],tt=["top","bottom"],bt=["bottom","top"];switch(c){case"top":case"bottom":return d?a?nt:et:a?et:nt;case"left":case"right":return a?tt:bt;default:return[]}}function getOppositeAxisPlacements(c,a,d,et){const nt=getAlignment(c);let tt=getSideList(getSide(c),d==="start",et);return nt&&(tt=tt.map(bt=>bt+"-"+nt),a&&(tt=tt.concat(tt.map(getOppositeAlignmentPlacement)))),tt}function getOppositePlacement(c){return c.replace(/left|right|bottom|top/g,a=>oppositeSideMap[a])}function expandPaddingObject(c){return{top:0,right:0,bottom:0,left:0,...c}}function getPaddingObject(c){return typeof c!="number"?expandPaddingObject(c):{top:c,right:c,bottom:c,left:c}}function rectToClientRect(c){const{x:a,y:d,width:et,height:nt}=c;return{width:et,height:nt,top:d,left:a,right:a+et,bottom:d+nt,x:a,y:d}}function computeCoordsFromPlacement(c,a,d){let{reference:et,floating:nt}=c;const tt=getSideAxis(a),bt=getAlignmentAxis(a),mt=getAxisLength(bt),vt=getSide(a),$t=tt==="y",At=et.x+et.width/2-nt.width/2,Mt=et.y+et.height/2-nt.height/2,Tt=et[mt]/2-nt[mt]/2;let Rt;switch(vt){case"top":Rt={x:At,y:et.y-nt.height};break;case"bottom":Rt={x:At,y:et.y+et.height};break;case"right":Rt={x:et.x+et.width,y:Mt};break;case"left":Rt={x:et.x-nt.width,y:Mt};break;default:Rt={x:et.x,y:et.y}}switch(getAlignment(a)){case"start":Rt[bt]-=Tt*(d&&$t?-1:1);break;case"end":Rt[bt]+=Tt*(d&&$t?-1:1);break}return Rt}const computePosition$1=async(c,a,d)=>{const{placement:et="bottom",strategy:nt="absolute",middleware:tt=[],platform:bt}=d,mt=tt.filter(Boolean),vt=await(bt.isRTL==null?void 0:bt.isRTL(a));let $t=await bt.getElementRects({reference:c,floating:a,strategy:nt}),{x:At,y:Mt}=computeCoordsFromPlacement($t,et,vt),Tt=et,Rt={},kt=0;for(let It=0;It({name:"arrow",options:c,async fn(a){const{x:d,y:et,placement:nt,rects:tt,platform:bt,elements:mt,middlewareData:vt}=a,{element:$t,padding:At=0}=evaluate(c,a)||{};if($t==null)return{};const Mt=getPaddingObject(At),Tt={x:d,y:et},Rt=getAlignmentAxis(nt),kt=getAxisLength(Rt),It=await bt.getDimensions($t),Dt=Rt==="y",Nt=Dt?"top":"left",Ot=Dt?"bottom":"right",Ut=Dt?"clientHeight":"clientWidth",Gt=tt.reference[kt]+tt.reference[Rt]-Tt[Rt]-tt.floating[kt],Wt=Tt[Rt]-tt.reference[Rt],Xt=await(bt.getOffsetParent==null?void 0:bt.getOffsetParent($t));let a0=Xt?Xt[Ut]:0;(!a0||!await(bt.isElement==null?void 0:bt.isElement(Xt)))&&(a0=mt.floating[Ut]||tt.floating[kt]);const n0=Gt/2-Wt/2,t0=a0/2-It[kt]/2-1,c0=min(Mt[Nt],t0),Ct=min(Mt[Ot],t0),dt=c0,yt=a0-It[kt]-Ct,gt=a0/2-It[kt]/2+n0,xt=clamp(dt,gt,yt),St=!vt.arrow&&getAlignment(nt)!=null&>!==xt&&tt.reference[kt]/2-(gtdt<=0)){var t0,c0;const dt=(((t0=tt.flip)==null?void 0:t0.index)||0)+1,yt=Wt[dt];if(yt)return{data:{index:dt,overflows:n0},reset:{placement:yt}};let gt=(c0=n0.filter(xt=>xt.overflows[0]<=0).sort((xt,St)=>xt.overflows[1]-St.overflows[1])[0])==null?void 0:c0.placement;if(!gt)switch(Rt){case"bestFit":{var Ct;const xt=(Ct=n0.map(St=>[St.placement,St.overflows.filter(_t=>_t>0).reduce((_t,Pt)=>_t+Pt,0)]).sort((St,_t)=>St[1]-_t[1])[0])==null?void 0:Ct[0];xt&&(gt=xt);break}case"initialPlacement":gt=mt;break}if(nt!==gt)return{reset:{placement:gt}}}return{}}}};function getBoundingRect(c){const a=min(...c.map(tt=>tt.left)),d=min(...c.map(tt=>tt.top)),et=max$1(...c.map(tt=>tt.right)),nt=max$1(...c.map(tt=>tt.bottom));return{x:a,y:d,width:et-a,height:nt-d}}function getRectsByLine(c){const a=c.slice().sort((nt,tt)=>nt.y-tt.y),d=[];let et=null;for(let nt=0;ntet.height/2?d.push([tt]):d[d.length-1].push(tt),et=tt}return d.map(nt=>rectToClientRect(getBoundingRect(nt)))}const inline$2=function(c){return c===void 0&&(c={}),{name:"inline",options:c,async fn(a){const{placement:d,elements:et,rects:nt,platform:tt,strategy:bt}=a,{padding:mt=2,x:vt,y:$t}=evaluate(c,a),At=Array.from(await(tt.getClientRects==null?void 0:tt.getClientRects(et.reference))||[]),Mt=getRectsByLine(At),Tt=rectToClientRect(getBoundingRect(At)),Rt=getPaddingObject(mt);function kt(){if(Mt.length===2&&Mt[0].left>Mt[1].right&&vt!=null&&$t!=null)return Mt.find(Dt=>vt>Dt.left-Rt.left&&vtDt.top-Rt.top&&$t=2){if(getSideAxis(d)==="y"){const c0=Mt[0],Ct=Mt[Mt.length-1],dt=getSide(d)==="top",yt=c0.top,gt=Ct.bottom,xt=dt?c0.left:Ct.left,St=dt?c0.right:Ct.right,_t=St-xt,Pt=gt-yt;return{top:yt,bottom:gt,left:xt,right:St,width:_t,height:Pt,x:xt,y:yt}}const Dt=getSide(d)==="left",Nt=max$1(...Mt.map(c0=>c0.right)),Ot=min(...Mt.map(c0=>c0.left)),Ut=Mt.filter(c0=>Dt?c0.left===Ot:c0.right===Nt),Gt=Ut[0].top,Wt=Ut[Ut.length-1].bottom,Xt=Ot,a0=Nt,n0=a0-Xt,t0=Wt-Gt;return{top:Gt,bottom:Wt,left:Xt,right:a0,width:n0,height:t0,x:Xt,y:Gt}}return Tt}const It=await tt.getElementRects({reference:{getBoundingClientRect:kt},floating:et.floating,strategy:bt});return nt.reference.x!==It.reference.x||nt.reference.y!==It.reference.y||nt.reference.width!==It.reference.width||nt.reference.height!==It.reference.height?{reset:{rects:It}}:{}}}};async function convertValueToCoords(c,a){const{placement:d,platform:et,elements:nt}=c,tt=await(et.isRTL==null?void 0:et.isRTL(nt.floating)),bt=getSide(d),mt=getAlignment(d),vt=getSideAxis(d)==="y",$t=["left","top"].includes(bt)?-1:1,At=tt&&vt?-1:1,Mt=evaluate(a,c);let{mainAxis:Tt,crossAxis:Rt,alignmentAxis:kt}=typeof Mt=="number"?{mainAxis:Mt,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...Mt};return mt&&typeof kt=="number"&&(Rt=mt==="end"?kt*-1:kt),vt?{x:Rt*At,y:Tt*$t}:{x:Tt*$t,y:Rt*At}}const offset$2=function(c){return c===void 0&&(c=0),{name:"offset",options:c,async fn(a){var d,et;const{x:nt,y:tt,placement:bt,middlewareData:mt}=a,vt=await convertValueToCoords(a,c);return bt===((d=mt.offset)==null?void 0:d.placement)&&(et=mt.arrow)!=null&&et.alignmentOffset?{}:{x:nt+vt.x,y:tt+vt.y,data:{...vt,placement:bt}}}}},shift$2=function(c){return c===void 0&&(c={}),{name:"shift",options:c,async fn(a){const{x:d,y:et,placement:nt}=a,{mainAxis:tt=!0,crossAxis:bt=!1,limiter:mt={fn:Dt=>{let{x:Nt,y:Ot}=Dt;return{x:Nt,y:Ot}}},...vt}=evaluate(c,a),$t={x:d,y:et},At=await detectOverflow(a,vt),Mt=getSideAxis(getSide(nt)),Tt=getOppositeAxis(Mt);let Rt=$t[Tt],kt=$t[Mt];if(tt){const Dt=Tt==="y"?"top":"left",Nt=Tt==="y"?"bottom":"right",Ot=Rt+At[Dt],Ut=Rt-At[Nt];Rt=clamp(Ot,Rt,Ut)}if(bt){const Dt=Mt==="y"?"top":"left",Nt=Mt==="y"?"bottom":"right",Ot=kt+At[Dt],Ut=kt-At[Nt];kt=clamp(Ot,kt,Ut)}const It=mt.fn({...a,[Tt]:Rt,[Mt]:kt});return{...It,data:{x:It.x-d,y:It.y-et}}}}},limitShift$2=function(c){return c===void 0&&(c={}),{options:c,fn(a){const{x:d,y:et,placement:nt,rects:tt,middlewareData:bt}=a,{offset:mt=0,mainAxis:vt=!0,crossAxis:$t=!0}=evaluate(c,a),At={x:d,y:et},Mt=getSideAxis(nt),Tt=getOppositeAxis(Mt);let Rt=At[Tt],kt=At[Mt];const It=evaluate(mt,a),Dt=typeof It=="number"?{mainAxis:It,crossAxis:0}:{mainAxis:0,crossAxis:0,...It};if(vt){const Ut=Tt==="y"?"height":"width",Gt=tt.reference[Tt]-tt.floating[Ut]+Dt.mainAxis,Wt=tt.reference[Tt]+tt.reference[Ut]-Dt.mainAxis;RtWt&&(Rt=Wt)}if($t){var Nt,Ot;const Ut=Tt==="y"?"width":"height",Gt=["top","left"].includes(getSide(nt)),Wt=tt.reference[Mt]-tt.floating[Ut]+(Gt&&((Nt=bt.offset)==null?void 0:Nt[Mt])||0)+(Gt?0:Dt.crossAxis),Xt=tt.reference[Mt]+tt.reference[Ut]+(Gt?0:((Ot=bt.offset)==null?void 0:Ot[Mt])||0)-(Gt?Dt.crossAxis:0);ktXt&&(kt=Xt)}return{[Tt]:Rt,[Mt]:kt}}}},size$5=function(c){return c===void 0&&(c={}),{name:"size",options:c,async fn(a){const{placement:d,rects:et,platform:nt,elements:tt}=a,{apply:bt=()=>{},...mt}=evaluate(c,a),vt=await detectOverflow(a,mt),$t=getSide(d),At=getAlignment(d),Mt=getSideAxis(d)==="y",{width:Tt,height:Rt}=et.floating;let kt,It;$t==="top"||$t==="bottom"?(kt=$t,It=At===(await(nt.isRTL==null?void 0:nt.isRTL(tt.floating))?"start":"end")?"left":"right"):(It=$t,kt=At==="end"?"top":"bottom");const Dt=Rt-vt.top-vt.bottom,Nt=Tt-vt.left-vt.right,Ot=min(Rt-vt[kt],Dt),Ut=min(Tt-vt[It],Nt),Gt=!a.middlewareData.shift;let Wt=Ot,Xt=Ut;if(Mt?Xt=At||Gt?min(Ut,Nt):Nt:Wt=At||Gt?min(Ot,Dt):Dt,Gt&&!At){const n0=max$1(vt.left,0),t0=max$1(vt.right,0),c0=max$1(vt.top,0),Ct=max$1(vt.bottom,0);Mt?Xt=Tt-2*(n0!==0||t0!==0?n0+t0:max$1(vt.left,vt.right)):Wt=Rt-2*(c0!==0||Ct!==0?c0+Ct:max$1(vt.top,vt.bottom))}await bt({...a,availableWidth:Xt,availableHeight:Wt});const a0=await nt.getDimensions(tt.floating);return Tt!==a0.width||Rt!==a0.height?{reset:{rects:!0}}:{}}}};function getCssDimensions(c){const a=getComputedStyle(c);let d=parseFloat(a.width)||0,et=parseFloat(a.height)||0;const nt=isHTMLElement(c),tt=nt?c.offsetWidth:d,bt=nt?c.offsetHeight:et,mt=round(d)!==tt||round(et)!==bt;return mt&&(d=tt,et=bt),{width:d,height:et,$:mt}}function unwrapElement(c){return isElement(c)?c:c.contextElement}function getScale(c){const a=unwrapElement(c);if(!isHTMLElement(a))return createCoords(1);const d=a.getBoundingClientRect(),{width:et,height:nt,$:tt}=getCssDimensions(a);let bt=(tt?round(d.width):d.width)/et,mt=(tt?round(d.height):d.height)/nt;return(!bt||!Number.isFinite(bt))&&(bt=1),(!mt||!Number.isFinite(mt))&&(mt=1),{x:bt,y:mt}}const noOffsets=createCoords(0);function getVisualOffsets(c){const a=getWindow(c);return!isWebKit()||!a.visualViewport?noOffsets:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function shouldAddVisualOffsets(c,a,d){return a===void 0&&(a=!1),!d||a&&d!==getWindow(c)?!1:a}function getBoundingClientRect(c,a,d,et){a===void 0&&(a=!1),d===void 0&&(d=!1);const nt=c.getBoundingClientRect(),tt=unwrapElement(c);let bt=createCoords(1);a&&(et?isElement(et)&&(bt=getScale(et)):bt=getScale(c));const mt=shouldAddVisualOffsets(tt,d,et)?getVisualOffsets(tt):createCoords(0);let vt=(nt.left+mt.x)/bt.x,$t=(nt.top+mt.y)/bt.y,At=nt.width/bt.x,Mt=nt.height/bt.y;if(tt){const Tt=getWindow(tt),Rt=et&&isElement(et)?getWindow(et):et;let kt=Tt,It=kt.frameElement;for(;It&&et&&Rt!==kt;){const Dt=getScale(It),Nt=It.getBoundingClientRect(),Ot=getComputedStyle(It),Ut=Nt.left+(It.clientLeft+parseFloat(Ot.paddingLeft))*Dt.x,Gt=Nt.top+(It.clientTop+parseFloat(Ot.paddingTop))*Dt.y;vt*=Dt.x,$t*=Dt.y,At*=Dt.x,Mt*=Dt.y,vt+=Ut,$t+=Gt,kt=getWindow(It),It=kt.frameElement}}return rectToClientRect({width:At,height:Mt,x:vt,y:$t})}const topLayerSelectors=[":popover-open",":modal"];function isTopLayer(c){return topLayerSelectors.some(a=>{try{return c.matches(a)}catch{return!1}})}function convertOffsetParentRelativeRectToViewportRelativeRect(c){let{elements:a,rect:d,offsetParent:et,strategy:nt}=c;const tt=nt==="fixed",bt=getDocumentElement(et),mt=a?isTopLayer(a.floating):!1;if(et===bt||mt&&tt)return d;let vt={scrollLeft:0,scrollTop:0},$t=createCoords(1);const At=createCoords(0),Mt=isHTMLElement(et);if((Mt||!Mt&&!tt)&&((getNodeName(et)!=="body"||isOverflowElement(bt))&&(vt=getNodeScroll(et)),isHTMLElement(et))){const Tt=getBoundingClientRect(et);$t=getScale(et),At.x=Tt.x+et.clientLeft,At.y=Tt.y+et.clientTop}return{width:d.width*$t.x,height:d.height*$t.y,x:d.x*$t.x-vt.scrollLeft*$t.x+At.x,y:d.y*$t.y-vt.scrollTop*$t.y+At.y}}function getClientRects(c){return Array.from(c.getClientRects())}function getWindowScrollBarX(c){return getBoundingClientRect(getDocumentElement(c)).left+getNodeScroll(c).scrollLeft}function getDocumentRect(c){const a=getDocumentElement(c),d=getNodeScroll(c),et=c.ownerDocument.body,nt=max$1(a.scrollWidth,a.clientWidth,et.scrollWidth,et.clientWidth),tt=max$1(a.scrollHeight,a.clientHeight,et.scrollHeight,et.clientHeight);let bt=-d.scrollLeft+getWindowScrollBarX(c);const mt=-d.scrollTop;return getComputedStyle(et).direction==="rtl"&&(bt+=max$1(a.clientWidth,et.clientWidth)-nt),{width:nt,height:tt,x:bt,y:mt}}function getViewportRect(c,a){const d=getWindow(c),et=getDocumentElement(c),nt=d.visualViewport;let tt=et.clientWidth,bt=et.clientHeight,mt=0,vt=0;if(nt){tt=nt.width,bt=nt.height;const $t=isWebKit();(!$t||$t&&a==="fixed")&&(mt=nt.offsetLeft,vt=nt.offsetTop)}return{width:tt,height:bt,x:mt,y:vt}}function getInnerBoundingClientRect(c,a){const d=getBoundingClientRect(c,!0,a==="fixed"),et=d.top+c.clientTop,nt=d.left+c.clientLeft,tt=isHTMLElement(c)?getScale(c):createCoords(1),bt=c.clientWidth*tt.x,mt=c.clientHeight*tt.y,vt=nt*tt.x,$t=et*tt.y;return{width:bt,height:mt,x:vt,y:$t}}function getClientRectFromClippingAncestor(c,a,d){let et;if(a==="viewport")et=getViewportRect(c,d);else if(a==="document")et=getDocumentRect(getDocumentElement(c));else if(isElement(a))et=getInnerBoundingClientRect(a,d);else{const nt=getVisualOffsets(c);et={...a,x:a.x-nt.x,y:a.y-nt.y}}return rectToClientRect(et)}function hasFixedPositionAncestor(c,a){const d=getParentNode(c);return d===a||!isElement(d)||isLastTraversableNode(d)?!1:getComputedStyle(d).position==="fixed"||hasFixedPositionAncestor(d,a)}function getClippingElementAncestors(c,a){const d=a.get(c);if(d)return d;let et=getOverflowAncestors(c,[],!1).filter(mt=>isElement(mt)&&getNodeName(mt)!=="body"),nt=null;const tt=getComputedStyle(c).position==="fixed";let bt=tt?getParentNode(c):c;for(;isElement(bt)&&!isLastTraversableNode(bt);){const mt=getComputedStyle(bt),vt=isContainingBlock(bt);!vt&&mt.position==="fixed"&&(nt=null),(tt?!vt&&!nt:!vt&&mt.position==="static"&&!!nt&&["absolute","fixed"].includes(nt.position)||isOverflowElement(bt)&&!vt&&hasFixedPositionAncestor(c,bt))?et=et.filter(At=>At!==bt):nt=mt,bt=getParentNode(bt)}return a.set(c,et),et}function getClippingRect(c){let{element:a,boundary:d,rootBoundary:et,strategy:nt}=c;const bt=[...d==="clippingAncestors"?isTopLayer(a)?[]:getClippingElementAncestors(a,this._c):[].concat(d),et],mt=bt[0],vt=bt.reduce(($t,At)=>{const Mt=getClientRectFromClippingAncestor(a,At,nt);return $t.top=max$1(Mt.top,$t.top),$t.right=min(Mt.right,$t.right),$t.bottom=min(Mt.bottom,$t.bottom),$t.left=max$1(Mt.left,$t.left),$t},getClientRectFromClippingAncestor(a,mt,nt));return{width:vt.right-vt.left,height:vt.bottom-vt.top,x:vt.left,y:vt.top}}function getDimensions(c){const{width:a,height:d}=getCssDimensions(c);return{width:a,height:d}}function getRectRelativeToOffsetParent(c,a,d){const et=isHTMLElement(a),nt=getDocumentElement(a),tt=d==="fixed",bt=getBoundingClientRect(c,!0,tt,a);let mt={scrollLeft:0,scrollTop:0};const vt=createCoords(0);if(et||!et&&!tt)if((getNodeName(a)!=="body"||isOverflowElement(nt))&&(mt=getNodeScroll(a)),et){const Mt=getBoundingClientRect(a,!0,tt,a);vt.x=Mt.x+a.clientLeft,vt.y=Mt.y+a.clientTop}else nt&&(vt.x=getWindowScrollBarX(nt));const $t=bt.left+mt.scrollLeft-vt.x,At=bt.top+mt.scrollTop-vt.y;return{x:$t,y:At,width:bt.width,height:bt.height}}function isStaticPositioned(c){return getComputedStyle(c).position==="static"}function getTrueOffsetParent(c,a){return!isHTMLElement(c)||getComputedStyle(c).position==="fixed"?null:a?a(c):c.offsetParent}function getOffsetParent(c,a){const d=getWindow(c);if(isTopLayer(c))return d;if(!isHTMLElement(c)){let nt=getParentNode(c);for(;nt&&!isLastTraversableNode(nt);){if(isElement(nt)&&!isStaticPositioned(nt))return nt;nt=getParentNode(nt)}return d}let et=getTrueOffsetParent(c,a);for(;et&&isTableElement(et)&&isStaticPositioned(et);)et=getTrueOffsetParent(et,a);return et&&isLastTraversableNode(et)&&isStaticPositioned(et)&&!isContainingBlock(et)?d:et||getContainingBlock(c)||d}const getElementRects=async function(c){const a=this.getOffsetParent||getOffsetParent,d=this.getDimensions,et=await d(c.floating);return{reference:getRectRelativeToOffsetParent(c.reference,await a(c.floating),c.strategy),floating:{x:0,y:0,width:et.width,height:et.height}}};function isRTL(c){return getComputedStyle(c).direction==="rtl"}const platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function observeMove(c,a){let d=null,et;const nt=getDocumentElement(c);function tt(){var mt;clearTimeout(et),(mt=d)==null||mt.disconnect(),d=null}function bt(mt,vt){mt===void 0&&(mt=!1),vt===void 0&&(vt=1),tt();const{left:$t,top:At,width:Mt,height:Tt}=c.getBoundingClientRect();if(mt||a(),!Mt||!Tt)return;const Rt=floor(At),kt=floor(nt.clientWidth-($t+Mt)),It=floor(nt.clientHeight-(At+Tt)),Dt=floor($t),Ot={rootMargin:-Rt+"px "+-kt+"px "+-It+"px "+-Dt+"px",threshold:max$1(0,min(1,vt))||1};let Ut=!0;function Gt(Wt){const Xt=Wt[0].intersectionRatio;if(Xt!==vt){if(!Ut)return bt();Xt?bt(!1,Xt):et=setTimeout(()=>{bt(!1,1e-7)},1e3)}Ut=!1}try{d=new IntersectionObserver(Gt,{...Ot,root:nt.ownerDocument})}catch{d=new IntersectionObserver(Gt,Ot)}d.observe(c)}return bt(!0),tt}function autoUpdate(c,a,d,et){et===void 0&&(et={});const{ancestorScroll:nt=!0,ancestorResize:tt=!0,elementResize:bt=typeof ResizeObserver=="function",layoutShift:mt=typeof IntersectionObserver=="function",animationFrame:vt=!1}=et,$t=unwrapElement(c),At=nt||tt?[...$t?getOverflowAncestors($t):[],...getOverflowAncestors(a)]:[];At.forEach(Nt=>{nt&&Nt.addEventListener("scroll",d,{passive:!0}),tt&&Nt.addEventListener("resize",d)});const Mt=$t&&mt?observeMove($t,d):null;let Tt=-1,Rt=null;bt&&(Rt=new ResizeObserver(Nt=>{let[Ot]=Nt;Ot&&Ot.target===$t&&Rt&&(Rt.unobserve(a),cancelAnimationFrame(Tt),Tt=requestAnimationFrame(()=>{var Ut;(Ut=Rt)==null||Ut.observe(a)})),d()}),$t&&!vt&&Rt.observe($t),Rt.observe(a));let kt,It=vt?getBoundingClientRect(c):null;vt&&Dt();function Dt(){const Nt=getBoundingClientRect(c);It&&(Nt.x!==It.x||Nt.y!==It.y||Nt.width!==It.width||Nt.height!==It.height)&&d(),It=Nt,kt=requestAnimationFrame(Dt)}return d(),()=>{var Nt;At.forEach(Ot=>{nt&&Ot.removeEventListener("scroll",d),tt&&Ot.removeEventListener("resize",d)}),Mt==null||Mt(),(Nt=Rt)==null||Nt.disconnect(),Rt=null,vt&&cancelAnimationFrame(kt)}}const offset$1=offset$2,shift$1=shift$2,flip$1=flip$2,size$4=size$5,arrow$2=arrow$3,inline$1=inline$2,limitShift$1=limitShift$2,computePosition=(c,a,d)=>{const et=new Map,nt={platform,...d},tt={...nt.platform,_c:et};return computePosition$1(c,a,{...nt,platform:tt})};var index$3=typeof document<"u"?reactExports.useLayoutEffect:reactExports.useEffect;function deepEqual(c,a){if(c===a)return!0;if(typeof c!=typeof a)return!1;if(typeof c=="function"&&c.toString()===a.toString())return!0;let d,et,nt;if(c&&a&&typeof c=="object"){if(Array.isArray(c)){if(d=c.length,d!==a.length)return!1;for(et=d;et--!==0;)if(!deepEqual(c[et],a[et]))return!1;return!0}if(nt=Object.keys(c),d=nt.length,d!==Object.keys(a).length)return!1;for(et=d;et--!==0;)if(!{}.hasOwnProperty.call(a,nt[et]))return!1;for(et=d;et--!==0;){const tt=nt[et];if(!(tt==="_owner"&&c.$$typeof)&&!deepEqual(c[tt],a[tt]))return!1}return!0}return c!==c&&a!==a}function getDPR(c){return typeof window>"u"?1:(c.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(c,a){const d=getDPR(c);return Math.round(a*d)/d}function useLatestRef(c){const a=reactExports.useRef(c);return index$3(()=>{a.current=c}),a}function useFloating$1(c){c===void 0&&(c={});const{placement:a="bottom",strategy:d="absolute",middleware:et=[],platform:nt,elements:{reference:tt,floating:bt}={},transform:mt=!0,whileElementsMounted:vt,open:$t}=c,[At,Mt]=reactExports.useState({x:0,y:0,strategy:d,placement:a,middlewareData:{},isPositioned:!1}),[Tt,Rt]=reactExports.useState(et);deepEqual(Tt,et)||Rt(et);const[kt,It]=reactExports.useState(null),[Dt,Nt]=reactExports.useState(null),Ot=reactExports.useCallback(_t=>{_t!==Xt.current&&(Xt.current=_t,It(_t))},[]),Ut=reactExports.useCallback(_t=>{_t!==a0.current&&(a0.current=_t,Nt(_t))},[]),Gt=tt||kt,Wt=bt||Dt,Xt=reactExports.useRef(null),a0=reactExports.useRef(null),n0=reactExports.useRef(At),t0=vt!=null,c0=useLatestRef(vt),Ct=useLatestRef(nt),dt=reactExports.useCallback(()=>{if(!Xt.current||!a0.current)return;const _t={placement:a,strategy:d,middleware:Tt};Ct.current&&(_t.platform=Ct.current),computePosition(Xt.current,a0.current,_t).then(Pt=>{const Et={...Pt,isPositioned:!0};yt.current&&!deepEqual(n0.current,Et)&&(n0.current=Et,reactDomExports.flushSync(()=>{Mt(Et)}))})},[Tt,a,d,Ct]);index$3(()=>{$t===!1&&n0.current.isPositioned&&(n0.current.isPositioned=!1,Mt(_t=>({..._t,isPositioned:!1})))},[$t]);const yt=reactExports.useRef(!1);index$3(()=>(yt.current=!0,()=>{yt.current=!1}),[]),index$3(()=>{if(Gt&&(Xt.current=Gt),Wt&&(a0.current=Wt),Gt&&Wt){if(c0.current)return c0.current(Gt,Wt,dt);dt()}},[Gt,Wt,dt,c0,t0]);const gt=reactExports.useMemo(()=>({reference:Xt,floating:a0,setReference:Ot,setFloating:Ut}),[Ot,Ut]),xt=reactExports.useMemo(()=>({reference:Gt,floating:Wt}),[Gt,Wt]),St=reactExports.useMemo(()=>{const _t={position:d,left:0,top:0};if(!xt.floating)return _t;const Pt=roundByDPR(xt.floating,At.x),Et=roundByDPR(xt.floating,At.y);return mt?{..._t,transform:"translate("+Pt+"px, "+Et+"px)",...getDPR(xt.floating)>=1.5&&{willChange:"transform"}}:{position:d,left:Pt,top:Et}},[d,mt,xt.floating,At.x,At.y]);return reactExports.useMemo(()=>({...At,update:dt,refs:gt,elements:xt,floatingStyles:St}),[At,dt,gt,xt,St])}const arrow$1=c=>{function a(d){return{}.hasOwnProperty.call(d,"current")}return{name:"arrow",options:c,fn(d){const{element:et,padding:nt}=typeof c=="function"?c(d):c;return et&&a(et)?et.current!=null?arrow$2({element:et.current,padding:nt}).fn(d):{}:et?arrow$2({element:et,padding:nt}).fn(d):{}}}},offset=(c,a)=>({...offset$1(c),options:[c,a]}),shift=(c,a)=>({...shift$1(c),options:[c,a]}),limitShift=(c,a)=>({...limitShift$1(c),options:[c,a]}),flip=(c,a)=>({...flip$1(c),options:[c,a]}),size$3=(c,a)=>({...size$4(c),options:[c,a]}),inline=(c,a)=>({...inline$1(c),options:[c,a]}),arrow=(c,a)=>({...arrow$1(c),options:[c,a]}),SafeReact={...React$1},useInsertionEffect=SafeReact.useInsertionEffect,useSafeInsertionEffect=useInsertionEffect||(c=>c());function useEffectEvent(c){const a=reactExports.useRef(()=>{});return useSafeInsertionEffect(()=>{a.current=c}),reactExports.useCallback(function(){for(var d=arguments.length,et=new Array(d),nt=0;nt"floating-ui-"+Math.random().toString(36).slice(2,6)+count++;function useFloatingId(){const[c,a]=reactExports.useState(()=>serverHandoffComplete?genId():void 0);return index$2(()=>{c==null&&a(genId())},[]),reactExports.useEffect(()=>{serverHandoffComplete=!0},[]),c}const useReactId=SafeReact.useId,useId=useReactId||useFloatingId;function createPubSub(){const c=new Map;return{emit(a,d){var et;(et=c.get(a))==null||et.forEach(nt=>nt(d))},on(a,d){c.set(a,[...c.get(a)||[],d])},off(a,d){var et;c.set(a,((et=c.get(a))==null?void 0:et.filter(nt=>nt!==d))||[])}}}const FloatingNodeContext=reactExports.createContext(null),FloatingTreeContext=reactExports.createContext(null),useFloatingParentNodeId=()=>{var c;return((c=reactExports.useContext(FloatingNodeContext))==null?void 0:c.id)||null},useFloatingTree=()=>reactExports.useContext(FloatingTreeContext);function useFloatingRootContext(c){const{open:a=!1,onOpenChange:d,elements:et}=c,nt=useId(),tt=reactExports.useRef({}),[bt]=reactExports.useState(()=>createPubSub()),mt=useFloatingParentNodeId()!=null,[vt,$t]=reactExports.useState(et.reference),At=useEffectEvent((Rt,kt,It)=>{tt.current.openEvent=Rt?kt:void 0,bt.emit("openchange",{open:Rt,event:kt,reason:It,nested:mt}),d==null||d(Rt,kt,It)}),Mt=reactExports.useMemo(()=>({setPositionReference:$t}),[]),Tt=reactExports.useMemo(()=>({reference:vt||et.reference||null,floating:et.floating||null,domReference:et.reference}),[vt,et.reference,et.floating]);return reactExports.useMemo(()=>({dataRef:tt,open:a,onOpenChange:At,elements:Tt,events:bt,floatingId:nt,refs:Mt}),[a,At,Tt,bt,nt,Mt])}function useFloating(c){c===void 0&&(c={});const{nodeId:a}=c,d=useFloatingRootContext({...c,elements:{reference:null,floating:null,...c.elements}}),et=c.rootContext||d,nt=et.elements,[tt,bt]=reactExports.useState(null),[mt,vt]=reactExports.useState(null),At=(nt==null?void 0:nt.reference)||tt,Mt=reactExports.useRef(null),Tt=useFloatingTree();index$2(()=>{At&&(Mt.current=At)},[At]);const Rt=useFloating$1({...c,elements:{...nt,...mt&&{reference:mt}}}),kt=reactExports.useCallback(Ut=>{const Gt=isElement(Ut)?{getBoundingClientRect:()=>Ut.getBoundingClientRect(),contextElement:Ut}:Ut;vt(Gt),Rt.refs.setReference(Gt)},[Rt.refs]),It=reactExports.useCallback(Ut=>{(isElement(Ut)||Ut===null)&&(Mt.current=Ut,bt(Ut)),(isElement(Rt.refs.reference.current)||Rt.refs.reference.current===null||Ut!==null&&!isElement(Ut))&&Rt.refs.setReference(Ut)},[Rt.refs]),Dt=reactExports.useMemo(()=>({...Rt.refs,setReference:It,setPositionReference:kt,domReference:Mt}),[Rt.refs,It,kt]),Nt=reactExports.useMemo(()=>({...Rt.elements,domReference:At}),[Rt.elements,At]),Ot=reactExports.useMemo(()=>({...Rt,...et,refs:Dt,elements:Nt,nodeId:a}),[Rt,Dt,Nt,a,et]);return index$2(()=>{et.dataRef.current.floatingContext=Ot;const Ut=Tt==null?void 0:Tt.nodesRef.current.find(Gt=>Gt.id===a);Ut&&(Ut.context=Ot)}),reactExports.useMemo(()=>({...Rt,context:Ot,refs:Dt,elements:Nt}),[Rt,Dt,Nt,Ot])}function getFloatingPosition(c,a){if(c==="rtl"&&(a.includes("right")||a.includes("left"))){const[d,et]=a.split("-"),nt=d==="right"?"left":"right";return et===void 0?nt:`${nt}-${et}`}return a}function horizontalSide(c,a,d,et){return c==="center"||et==="center"?{top:a}:c==="end"?{bottom:d}:c==="start"?{top:d}:{}}function verticalSide(c,a,d,et,nt){return c==="center"||et==="center"?{left:a}:c==="end"?{[nt==="ltr"?"right":"left"]:d}:c==="start"?{[nt==="ltr"?"left":"right"]:d}:{}}const radiusByFloatingSide={bottom:"borderTopLeftRadius",left:"borderTopRightRadius",right:"borderBottomLeftRadius",top:"borderBottomRightRadius"};function getArrowPositionStyles({position:c,arrowSize:a,arrowOffset:d,arrowRadius:et,arrowPosition:nt,arrowX:tt,arrowY:bt,dir:mt}){const[vt,$t="center"]=c.split("-"),At={width:rem(a),height:rem(a),transform:"rotate(45deg)",position:"absolute",[radiusByFloatingSide[vt]]:rem(et)},Mt=rem(-a/2);return vt==="left"?{...At,...horizontalSide($t,bt,d,nt),right:Mt,borderLeftColor:"transparent",borderBottomColor:"transparent"}:vt==="right"?{...At,...horizontalSide($t,bt,d,nt),left:Mt,borderRightColor:"transparent",borderTopColor:"transparent"}:vt==="top"?{...At,...verticalSide($t,tt,d,nt,mt),bottom:Mt,borderTopColor:"transparent",borderLeftColor:"transparent"}:vt==="bottom"?{...At,...verticalSide($t,tt,d,nt,mt),top:Mt,borderBottomColor:"transparent",borderRightColor:"transparent"}:{}}const FloatingArrow=reactExports.forwardRef(({position:c,arrowSize:a,arrowOffset:d,arrowRadius:et,arrowPosition:nt,visible:tt,arrowX:bt,arrowY:mt,style:vt,...$t},At)=>{const{dir:Mt}=useDirection();return tt?React.createElement("div",{...$t,ref:At,style:{...vt,...getArrowPositionStyles({position:c,arrowSize:a,arrowOffset:d,arrowRadius:et,arrowPosition:nt,dir:Mt,arrowX:bt,arrowY:mt})}}):null});FloatingArrow.displayName="@mantine/core/FloatingArrow";const[PopoverContextProvider,usePopoverContext]=createSafeContext("Popover component was not found in the tree");function FocusTrap({children:c,active:a=!0,refProp:d="ref"}){const et=useFocusTrap(a),nt=useMergedRef(et,c==null?void 0:c.ref);return isElement$1(c)?reactExports.cloneElement(c,{[d]:nt}):c}function FocusTrapInitialFocus(c){return React.createElement(VisuallyHidden,{tabIndex:-1,"data-autofocus":!0,...c})}FocusTrap.displayName="@mantine/core/FocusTrap";FocusTrapInitialFocus.displayName="@mantine/core/FocusTrapInitialFocus";FocusTrap.InitialFocus=FocusTrapInitialFocus;function createPortalNode(c){const a=document.createElement("div");return a.setAttribute("data-portal","true"),typeof c.className=="string"&&a.classList.add(...c.className.split(" ").filter(Boolean)),typeof c.style=="object"&&Object.assign(a.style,c.style),typeof c.id=="string"&&a.setAttribute("id",c.id),a}const defaultProps$1g={},Portal=reactExports.forwardRef((c,a)=>{const{children:d,target:et,...nt}=useProps("Portal",defaultProps$1g,c),[tt,bt]=reactExports.useState(!1),mt=reactExports.useRef(null);return useIsomorphicEffect(()=>(bt(!0),mt.current=et?typeof et=="string"?document.querySelector(et):et:createPortalNode(nt),assignRef(a,mt.current),!et&&mt.current&&document.body.appendChild(mt.current),()=>{!et&&mt.current&&document.body.removeChild(mt.current)}),[et]),!tt||!mt.current?null:reactDomExports.createPortal(React.createElement(React.Fragment,null,d),mt.current)});Portal.displayName="@mantine/core/Portal";function OptionalPortal({withinPortal:c=!0,children:a,...d}){return c?React.createElement(Portal,{...d},a):React.createElement(React.Fragment,null,a)}OptionalPortal.displayName="@mantine/core/OptionalPortal";const popIn=c=>({in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:`scale(.9) translateY(${rem(c==="bottom"?10:-10)})`},transitionProperty:"transform, opacity"}),transitions={fade:{in:{opacity:1},out:{opacity:0},transitionProperty:"opacity"},"fade-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:`translateY(${rem(30)}`},transitionProperty:"opacity, transform"},"fade-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:`translateY(${rem(-30)}`},transitionProperty:"opacity, transform"},"fade-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:`translateX(${rem(30)}`},transitionProperty:"opacity, transform"},"fade-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:`translateX(${rem(-30)}`},transitionProperty:"opacity, transform"},scale:{in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-y":{in:{opacity:1,transform:"scaleY(1)"},out:{opacity:0,transform:"scaleY(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-x":{in:{opacity:1,transform:"scaleX(1)"},out:{opacity:0,transform:"scaleX(0)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"skew-up":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:`translateY(${rem(-20)}) skew(-10deg, -5deg)`},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"skew-down":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:`translateY(${rem(20)}) skew(-10deg, -5deg)`},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-left":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:`translateY(${rem(20)}) rotate(-5deg)`},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-right":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:`translateY(${rem(20)}) rotate(5deg)`},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(-100%)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(100%)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"slide-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(100%)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"slide-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(-100%)"},common:{transformOrigin:"right"},transitionProperty:"transform, opacity"},pop:{...popIn("bottom"),common:{transformOrigin:"center center"}},"pop-bottom-left":{...popIn("bottom"),common:{transformOrigin:"bottom left"}},"pop-bottom-right":{...popIn("bottom"),common:{transformOrigin:"bottom right"}},"pop-top-left":{...popIn("top"),common:{transformOrigin:"top left"}},"pop-top-right":{...popIn("top"),common:{transformOrigin:"top right"}}},transitionStatuses={entering:"in",entered:"in",exiting:"out",exited:"out","pre-exiting":"out","pre-entering":"out"};function getTransitionStyles({transition:c,state:a,duration:d,timingFunction:et}){const nt={transitionDuration:`${d}ms`,transitionTimingFunction:et};return typeof c=="string"?c in transitions?{transitionProperty:transitions[c].transitionProperty,...nt,...transitions[c].common,...transitions[c][transitionStatuses[a]]}:{}:{transitionProperty:c.transitionProperty,...nt,...c.common,...c[transitionStatuses[a]]}}function useTransition({duration:c,exitDuration:a,timingFunction:d,mounted:et,onEnter:nt,onExit:tt,onEntered:bt,onExited:mt}){const vt=useMantineTheme(),$t=useReducedMotion(),At=vt.respectReducedMotion?$t:!1,[Mt,Tt]=reactExports.useState(At?0:c),[Rt,kt]=reactExports.useState(et?"entered":"exited"),It=reactExports.useRef(-1),Dt=reactExports.useRef(-1),Nt=Ot=>{const Ut=Ot?nt:tt,Gt=Ot?bt:mt;window.clearTimeout(It.current);const Wt=At?0:Ot?c:a;Tt(Wt),Wt===0?(typeof Ut=="function"&&Ut(),typeof Gt=="function"&&Gt(),kt(Ot?"entered":"exited")):Dt.current=requestAnimationFrame(()=>{ReactDOM.flushSync(()=>{kt(Ot?"pre-entering":"pre-exiting")}),Dt.current=requestAnimationFrame(()=>{typeof Ut=="function"&&Ut(),kt(Ot?"entering":"exiting"),It.current=window.setTimeout(()=>{typeof Gt=="function"&&Gt(),kt(Ot?"entered":"exited")},Wt)})})};return useDidUpdate(()=>{Nt(et)},[et]),reactExports.useEffect(()=>()=>{window.clearTimeout(It.current),cancelAnimationFrame(Dt.current)},[]),{transitionDuration:Mt,transitionStatus:Rt,transitionTimingFunction:d||"ease"}}function Transition({keepMounted:c,transition:a="fade",duration:d=250,exitDuration:et=d,mounted:nt,children:tt,timingFunction:bt="ease",onExit:mt,onEntered:vt,onEnter:$t,onExited:At}){const{transitionDuration:Mt,transitionStatus:Tt,transitionTimingFunction:Rt}=useTransition({mounted:nt,exitDuration:et,duration:d,timingFunction:bt,onExit:mt,onEntered:vt,onEnter:$t,onExited:At});return Mt===0?nt?React.createElement(React.Fragment,null,tt({})):c?tt({display:"none"}):null:Tt==="exited"?c?tt({display:"none"}):null:React.createElement(React.Fragment,null,tt(getTransitionStyles({transition:a,duration:Mt,state:Tt,timingFunction:Rt})))}Transition.displayName="@mantine/core/Transition";var classes$B={dropdown:"m_38a85659",arrow:"m_a31dc6c1"};const defaultProps$1f={},PopoverDropdown=factory((c,a)=>{var Dt,Nt,Ot,Ut;const d=useProps("PopoverDropdown",defaultProps$1f,c),{className:et,style:nt,vars:tt,children:bt,onKeyDownCapture:mt,variant:vt,classNames:$t,styles:At,...Mt}=d,Tt=usePopoverContext(),Rt=useFocusReturn({opened:Tt.opened,shouldReturnFocus:Tt.returnFocus}),kt=Tt.withRoles?{"aria-labelledby":Tt.getTargetId(),id:Tt.getDropdownId(),role:"dialog",tabIndex:-1}:{},It=useMergedRef(a,Tt.floating);return Tt.disabled?null:React.createElement(OptionalPortal,{...Tt.portalProps,withinPortal:Tt.withinPortal},React.createElement(Transition,{mounted:Tt.opened,...Tt.transitionProps,transition:((Dt=Tt.transitionProps)==null?void 0:Dt.transition)||"fade",duration:((Nt=Tt.transitionProps)==null?void 0:Nt.duration)??150,keepMounted:Tt.keepMounted,exitDuration:typeof((Ot=Tt.transitionProps)==null?void 0:Ot.exitDuration)=="number"?Tt.transitionProps.exitDuration:(Ut=Tt.transitionProps)==null?void 0:Ut.duration},Gt=>React.createElement(FocusTrap,{active:Tt.trapFocus},React.createElement(Box,{...kt,...Mt,variant:vt,ref:It,onKeyDownCapture:closeOnEscape(Tt.onClose,{active:Tt.closeOnEscape,onTrigger:Rt,onKeyDown:mt}),"data-position":Tt.placement,...Tt.getStyles("dropdown",{className:et,props:d,classNames:$t,styles:At,style:[{...Gt,zIndex:Tt.zIndex,top:Tt.y??0,left:Tt.x??0,width:Tt.width==="target"?void 0:rem(Tt.width)},nt]})},bt,React.createElement(FloatingArrow,{ref:Tt.arrowRef,arrowX:Tt.arrowX,arrowY:Tt.arrowY,visible:Tt.withArrow,position:Tt.placement,arrowSize:Tt.arrowSize,arrowRadius:Tt.arrowRadius,arrowOffset:Tt.arrowOffset,arrowPosition:Tt.arrowPosition,...Tt.getStyles("arrow",{props:d,classNames:$t,styles:At})})))))});PopoverDropdown.classes=classes$B;PopoverDropdown.displayName="@mantine/core/PopoverDropdown";const defaultProps$1e={refProp:"ref",popupType:"dialog"},PopoverTarget=factory((c,a)=>{const{children:d,refProp:et,popupType:nt,...tt}=useProps("PopoverTarget",defaultProps$1e,c);if(!isElement$1(d))throw new Error("Popover.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const bt=tt,mt=usePopoverContext(),vt=useMergedRef(mt.reference,d.ref,a),$t=mt.withRoles?{"aria-haspopup":nt,"aria-expanded":mt.opened,"aria-controls":mt.getDropdownId(),id:mt.getTargetId()}:{};return reactExports.cloneElement(d,{...bt,...$t,...mt.targetProps,className:clsx(mt.targetProps.className,bt.className,d.props.className),[et]:vt,...mt.controlled?null:{onClick:mt.onToggle}})});PopoverTarget.displayName="@mantine/core/PopoverTarget";function useFloatingAutoUpdate({opened:c,floating:a,position:d,positionDependencies:et}){const[nt,tt]=reactExports.useState(0);reactExports.useEffect(()=>{if(a.refs.reference.current&&a.refs.floating.current)return autoUpdate(a.refs.reference.current,a.refs.floating.current,a.update)},[a.refs.reference.current,a.refs.floating.current,c,nt,d]),useDidUpdate(()=>{a.update()},et),useDidUpdate(()=>{tt(bt=>bt+1)},[c])}function getDefaultMiddlewares(c){if(c===void 0)return{shift:!0,flip:!0};const a={...c};return c.shift===void 0&&(a.shift=!0),c.flip===void 0&&(a.flip=!0),a}function getPopoverMiddlewares(c,a){const d=getDefaultMiddlewares(c.middlewares),et=[offset(c.offset)];return d.shift&&et.push(shift(typeof d.shift=="boolean"?{limiter:limitShift(),padding:5}:{limiter:limitShift(),padding:5,...d.shift})),d.flip&&et.push(typeof d.flip=="boolean"?flip():flip(d.flip)),d.inline&&et.push(typeof d.inline=="boolean"?inline():inline(d.inline)),et.push(arrow({element:c.arrowRef,padding:c.arrowOffset})),(d.size||c.width==="target")&&et.push(size$3({...typeof d.size=="boolean"?{}:d.size,apply({rects:nt,availableWidth:tt,availableHeight:bt}){var $t;const vt=(($t=a().refs.floating.current)==null?void 0:$t.style)??{};d.size&&Object.assign(vt,{maxWidth:`${tt}px`,maxHeight:`${bt}px`}),c.width==="target"&&Object.assign(vt,{width:`${nt.reference.width}px`})}})),et}function usePopover(c){const[a,d]=useUncontrolled({value:c.opened,defaultValue:c.defaultOpened,finalValue:!1,onChange:c.onChange}),et=()=>{var bt;a&&((bt=c.onClose)==null||bt.call(c),d(!1))},nt=()=>{var bt,mt;a?((bt=c.onClose)==null||bt.call(c),d(!1)):((mt=c.onOpen)==null||mt.call(c),d(!0))},tt=useFloating({strategy:c.strategy,placement:c.position,middleware:getPopoverMiddlewares(c,()=>tt)});return useFloatingAutoUpdate({opened:c.opened,position:c.position,positionDependencies:c.positionDependencies||[],floating:tt}),useDidUpdate(()=>{var bt;(bt=c.onPositionChange)==null||bt.call(c,tt.placement)},[tt.placement]),useDidUpdate(()=>{var bt,mt;c.opened?(mt=c.onOpen)==null||mt.call(c):(bt=c.onClose)==null||bt.call(c)},[c.opened]),{floating:tt,controlled:typeof c.opened=="boolean",opened:a,onClose:et,onToggle:nt}}const defaultProps$1d={position:"bottom",offset:8,positionDependencies:[],transitionProps:{transition:"fade",duration:150},middlewares:{flip:!0,shift:!0,inline:!1},arrowSize:7,arrowOffset:5,arrowRadius:0,arrowPosition:"side",closeOnClickOutside:!0,withinPortal:!0,closeOnEscape:!0,trapFocus:!1,withRoles:!0,returnFocus:!1,clickOutsideEvents:["mousedown","touchstart"],zIndex:getDefaultZIndex("popover"),__staticSelector:"Popover",width:"max-content"},varsResolver$x=(c,{radius:a,shadow:d})=>({dropdown:{"--popover-radius":a===void 0?void 0:getRadius(a),"--popover-shadow":getShadow(d)}});function Popover(c){var $0,p0,u0,J0,v0,E0;const a=useProps("Popover",defaultProps$1d,c),{children:d,position:et,offset:nt,onPositionChange:tt,positionDependencies:bt,opened:mt,transitionProps:vt,width:$t,middlewares:At,withArrow:Mt,arrowSize:Tt,arrowOffset:Rt,arrowRadius:kt,arrowPosition:It,unstyled:Dt,classNames:Nt,styles:Ot,closeOnClickOutside:Ut,withinPortal:Gt,portalProps:Wt,closeOnEscape:Xt,clickOutsideEvents:a0,trapFocus:n0,onClose:t0,onOpen:c0,onChange:Ct,zIndex:dt,radius:yt,shadow:gt,id:xt,defaultOpened:St,__staticSelector:_t,withRoles:Pt,disabled:Et,returnFocus:ht,variant:wt,keepMounted:Bt,vars:Lt,floatingStrategy:jt,...Ft}=a,Vt=useStyles({name:_t,props:a,classes:classes$B,classNames:Nt,styles:Ot,unstyled:Dt,rootSelector:"dropdown",vars:Lt,varsResolver:varsResolver$x}),zt=reactExports.useRef(null),[qt,Kt]=reactExports.useState(null),[e0,Zt]=reactExports.useState(null),{dir:Jt}=useDirection(),i0=useId$1(xt),h0=usePopover({middlewares:At,width:$t,position:getFloatingPosition(Jt,et),offset:typeof nt=="number"?nt+(Mt?Tt/2:0):nt,arrowRef:zt,arrowOffset:Rt,onPositionChange:tt,positionDependencies:bt,opened:mt,defaultOpened:St,onChange:Ct,onOpen:c0,onClose:t0,strategy:jt});useClickOutside(()=>Ut&&h0.onClose(),a0,[qt,e0]);const o0=reactExports.useCallback(Z0=>{Kt(Z0),h0.floating.refs.setReference(Z0)},[h0.floating.refs.setReference]),l0=reactExports.useCallback(Z0=>{Zt(Z0),h0.floating.refs.setFloating(Z0)},[h0.floating.refs.setFloating]);return React.createElement(PopoverContextProvider,{value:{returnFocus:ht,disabled:Et,controlled:h0.controlled,reference:o0,floating:l0,x:h0.floating.x,y:h0.floating.y,arrowX:(u0=(p0=($0=h0.floating)==null?void 0:$0.middlewareData)==null?void 0:p0.arrow)==null?void 0:u0.x,arrowY:(E0=(v0=(J0=h0.floating)==null?void 0:J0.middlewareData)==null?void 0:v0.arrow)==null?void 0:E0.y,opened:h0.opened,arrowRef:zt,transitionProps:vt,width:$t,withArrow:Mt,arrowSize:Tt,arrowOffset:Rt,arrowRadius:kt,arrowPosition:It,placement:h0.floating.placement,trapFocus:n0,withinPortal:Gt,portalProps:Wt,zIndex:dt,radius:yt,shadow:gt,closeOnEscape:Xt,onClose:h0.onClose,onToggle:h0.onToggle,getTargetId:()=>`${i0}-target`,getDropdownId:()=>`${i0}-dropdown`,withRoles:Pt,targetProps:Ft,__staticSelector:_t,classNames:Nt,styles:Ot,unstyled:Dt,variant:wt,keepMounted:Bt,getStyles:Vt}},d)}Popover.Target=PopoverTarget;Popover.Dropdown=PopoverDropdown;Popover.displayName="@mantine/core/Popover";Popover.extend=c=>c;var classes$A={root:"m_5ae2e3c",barsLoader:"m_7a2bd4cd",bar:"m_870bb79","bars-loader-animation":"m_5d2b3b9d",dotsLoader:"m_4e3f22d7",dot:"m_870c4af","loader-dots-animation":"m_aac34a1",ovalLoader:"m_b34414df","oval-loader-animation":"m_f8e89c4b"};const Bars=reactExports.forwardRef(({className:c,...a},d)=>React.createElement(Box,{component:"span",className:clsx(classes$A.barsLoader,c),...a,ref:d},React.createElement("span",{className:classes$A.bar}),React.createElement("span",{className:classes$A.bar}),React.createElement("span",{className:classes$A.bar}))),Dots=reactExports.forwardRef(({className:c,...a},d)=>React.createElement(Box,{component:"span",className:clsx(classes$A.dotsLoader,c),...a,ref:d},React.createElement("span",{className:classes$A.dot}),React.createElement("span",{className:classes$A.dot}),React.createElement("span",{className:classes$A.dot}))),Oval=reactExports.forwardRef(({className:c,...a},d)=>React.createElement(Box,{component:"span",className:clsx(classes$A.ovalLoader,c),...a,ref:d})),defaultLoaders={bars:Bars,oval:Oval,dots:Dots},defaultProps$1c={loaders:defaultLoaders,type:"oval"},varsResolver$w=(c,{size:a,color:d})=>({root:{"--loader-size":getSize(a,"loader-size"),"--loader-color":d?getThemeColor(d,c):void 0}}),Loader=factory((c,a)=>{const d=useProps("Loader",defaultProps$1c,c),{size:et,color:nt,type:tt,vars:bt,className:mt,style:vt,classNames:$t,styles:At,unstyled:Mt,loaders:Tt,variant:Rt,children:kt,...It}=d,Dt=useStyles({name:"Loader",props:d,classes:classes$A,className:mt,style:vt,classNames:$t,styles:At,unstyled:Mt,vars:bt,varsResolver:varsResolver$w});return kt?React.createElement(Box,{...Dt("root"),ref:a,...It},kt):React.createElement(Box,{...Dt("root"),ref:a,component:Tt[tt],variant:Rt,size:et,...It})});Loader.defaultLoaders=defaultLoaders;Loader.classes=classes$A;Loader.displayName="@mantine/core/Loader";var classes$z={root:"m_8d3f4000",icon:"m_8d3afb97",loader:"m_302b9fb1",group:"m_1a0f1b21"};const defaultProps$1b={orientation:"horizontal"},varsResolver$v=(c,{borderWidth:a})=>({group:{"--ai-border-width":rem(a)}}),ActionIconGroup=factory((c,a)=>{const d=useProps("ActionIconGroup",defaultProps$1b,c),{className:et,style:nt,classNames:tt,styles:bt,unstyled:mt,orientation:vt,vars:$t,borderWidth:At,variant:Mt,mod:Tt,...Rt}=useProps("ActionIconGroup",defaultProps$1b,c),kt=useStyles({name:"ActionIconGroup",props:d,classes:classes$z,className:et,style:nt,classNames:tt,styles:bt,unstyled:mt,vars:$t,varsResolver:varsResolver$v,rootSelector:"group"});return React.createElement(Box,{...kt("group"),ref:a,variant:Mt,mod:[{"data-orientation":vt},Tt],role:"group",...Rt})});ActionIconGroup.classes=classes$z;ActionIconGroup.displayName="@mantine/core/ActionIconGroup";const defaultProps$1a={},varsResolver$u=(c,{size:a,radius:d,variant:et,gradient:nt,color:tt,autoContrast:bt})=>{const mt=c.variantColorResolver({color:tt||c.primaryColor,theme:c,gradient:nt,variant:et||"filled",autoContrast:bt});return{root:{"--ai-size":getSize(a,"ai-size"),"--ai-radius":d===void 0?void 0:getRadius(d),"--ai-bg":tt||et?mt.background:void 0,"--ai-hover":tt||et?mt.hover:void 0,"--ai-hover-color":tt||et?mt.hoverColor:void 0,"--ai-color":mt.color,"--ai-bd":tt||et?mt.border:void 0}}},ActionIcon=polymorphicFactory((c,a)=>{const d=useProps("ActionIcon",defaultProps$1a,c),{className:et,unstyled:nt,variant:tt,classNames:bt,styles:mt,style:vt,loading:$t,loaderProps:At,size:Mt,color:Tt,radius:Rt,__staticSelector:kt,gradient:It,vars:Dt,children:Nt,disabled:Ot,"data-disabled":Ut,autoContrast:Gt,mod:Wt,...Xt}=d,a0=useStyles({name:["ActionIcon",kt],props:d,className:et,style:vt,classes:classes$z,classNames:bt,styles:mt,unstyled:nt,vars:Dt,varsResolver:varsResolver$u});return React.createElement(UnstyledButton,{...a0("root",{active:!Ot&&!$t&&!Ut}),...Xt,unstyled:nt,variant:tt,size:Mt,disabled:Ot||$t,ref:a,mod:[{loading:$t,disabled:Ot||Ut},Wt]},React.createElement(Transition,{mounted:!!$t,transition:"slide-down",duration:150},n0=>React.createElement(Box,{component:"span",...a0("loader",{style:n0}),"aria-hidden":!0},React.createElement(Loader,{color:"var(--ai-color)",size:"calc(var(--ai-size) * 0.55)",...At}))),React.createElement(Box,{component:"span",mod:{loading:$t},...a0("icon")},Nt))});ActionIcon.classes=classes$z;ActionIcon.displayName="@mantine/core/ActionIcon";ActionIcon.Group=ActionIconGroup;const CloseIcon=reactExports.forwardRef(({size:c="var(--cb-icon-size, 70%)",style:a,...d},et)=>React.createElement("svg",{viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{...a,width:c,height:c},ref:et,...d},React.createElement("path",{d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"})));CloseIcon.displayName="@mantine/core/CloseIcon";var classes$y={root:"m_86a44da5","root--subtle":"m_220c80f2"};const defaultProps$19={variant:"subtle"},varsResolver$t=(c,{size:a,radius:d,iconSize:et})=>({root:{"--cb-size":getSize(a,"cb-size"),"--cb-radius":d===void 0?void 0:getRadius(d),"--cb-icon-size":rem(et)}}),CloseButton=polymorphicFactory((c,a)=>{const d=useProps("CloseButton",defaultProps$19,c),{iconSize:et,children:nt,vars:tt,radius:bt,className:mt,classNames:vt,style:$t,styles:At,unstyled:Mt,"data-disabled":Tt,disabled:Rt,variant:kt,icon:It,mod:Dt,...Nt}=d,Ot=useStyles({name:"CloseButton",props:d,className:mt,style:$t,classes:classes$y,classNames:vt,styles:At,unstyled:Mt,vars:tt,varsResolver:varsResolver$t});return React.createElement(UnstyledButton,{ref:a,...Nt,unstyled:Mt,variant:kt,disabled:Rt,mod:[{disabled:Rt||Tt},Dt],...Ot("root",{variant:kt,active:!Rt&&!Tt})},It||React.createElement(CloseIcon,null),nt)});CloseButton.classes=classes$y;CloseButton.displayName="@mantine/core/CloseButton";function filterFalsyChildren(c){return reactExports.Children.toArray(c).filter(Boolean)}var classes$x={root:"m_4081bf90"};const defaultProps$18={preventGrowOverflow:!0,gap:"md",align:"center",justify:"flex-start",wrap:"wrap"},varsResolver$s=(c,{grow:a,preventGrowOverflow:d,gap:et,align:nt,justify:tt,wrap:bt},{childWidth:mt})=>({root:{"--group-child-width":a&&d?mt:void 0,"--group-gap":getSpacing(et),"--group-align":nt,"--group-justify":tt,"--group-wrap":bt}}),Group=factory((c,a)=>{const d=useProps("Group",defaultProps$18,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,children:vt,gap:$t,align:At,justify:Mt,wrap:Tt,grow:Rt,preventGrowOverflow:kt,vars:It,variant:Dt,__size:Nt,mod:Ot,...Ut}=d,Gt=filterFalsyChildren(vt),Wt=Gt.length,Xt=getSpacing($t??"md"),n0={childWidth:`calc(${100/Wt}% - (${Xt} - ${Xt} / ${Wt}))`},t0=useStyles({name:"Group",props:d,stylesCtx:n0,className:nt,style:tt,classes:classes$x,classNames:et,styles:bt,unstyled:mt,vars:It,varsResolver:varsResolver$s});return React.createElement(Box,{...t0("root"),ref:a,variant:Dt,mod:[{grow:Rt},Ot],size:Nt,...Ut},Gt)});Group.classes=classes$x;Group.displayName="@mantine/core/Group";var classes$w={root:"m_9814e45f"};const defaultProps$17={zIndex:getDefaultZIndex("modal")},varsResolver$r=(c,{gradient:a,color:d,backgroundOpacity:et,blur:nt,radius:tt,zIndex:bt})=>({root:{"--overlay-bg":a||(d!==void 0||et!==void 0)&&rgba(d||"#000",et??.6)||void 0,"--overlay-filter":nt?`blur(${rem(nt)})`:void 0,"--overlay-radius":tt===void 0?void 0:getRadius(tt),"--overlay-z-index":bt==null?void 0:bt.toString()}}),Overlay=polymorphicFactory((c,a)=>{const d=useProps("Overlay",defaultProps$17,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,fixed:$t,center:At,children:Mt,radius:Tt,zIndex:Rt,gradient:kt,blur:It,color:Dt,backgroundOpacity:Nt,mod:Ot,...Ut}=d,Gt=useStyles({name:"Overlay",props:d,classes:classes$w,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$r});return React.createElement(Box,{ref:a,...Gt("root"),mod:[{center:At,fixed:$t},Ot],...Ut},Mt)});Overlay.classes=classes$w;Overlay.displayName="@mantine/core/Overlay";const[ModalBaseProvider,useModalBaseContext]=createSafeContext("ModalBase component was not found in tree");function useLockScroll({opened:c,transitionDuration:a}){const[d,et]=reactExports.useState(c),nt=reactExports.useRef(),bt=useReducedMotion()?0:a;return reactExports.useEffect(()=>(c?(et(!0),window.clearTimeout(nt.current)):bt===0?et(!1):nt.current=window.setTimeout(()=>et(!1),bt),()=>window.clearTimeout(nt.current)),[c,bt]),d}function useModal({id:c,transitionProps:a,opened:d,trapFocus:et,closeOnEscape:nt,onClose:tt,returnFocus:bt}){const mt=useId$1(c),[vt,$t]=reactExports.useState(!1),[At,Mt]=reactExports.useState(!1),Tt=typeof(a==null?void 0:a.duration)=="number"?a==null?void 0:a.duration:200,Rt=useLockScroll({opened:d,transitionDuration:Tt});return useWindowEvent("keydown",kt=>{var It;kt.key==="Escape"&&nt&&((It=kt.target)==null?void 0:It.getAttribute("data-mantine-stop-propagation"))!=="true"&&tt()},{capture:!0}),useFocusReturn({opened:d,shouldReturnFocus:et&&bt}),{_id:mt,titleMounted:vt,bodyMounted:At,shouldLockScroll:Rt,setTitleMounted:$t,setBodyMounted:Mt}}const ModalBase=reactExports.forwardRef(({keepMounted:c,opened:a,onClose:d,id:et,transitionProps:nt,trapFocus:tt,closeOnEscape:bt,returnFocus:mt,closeOnClickOutside:vt,withinPortal:$t,portalProps:At,lockScroll:Mt,children:Tt,zIndex:Rt,shadow:kt,padding:It,__vars:Dt,unstyled:Nt,removeScrollProps:Ot,...Ut},Gt)=>{const{_id:Wt,titleMounted:Xt,bodyMounted:a0,shouldLockScroll:n0,setTitleMounted:t0,setBodyMounted:c0}=useModal({id:et,transitionProps:nt,opened:a,trapFocus:tt,closeOnEscape:bt,onClose:d,returnFocus:mt});return React.createElement(OptionalPortal,{...At,withinPortal:$t},React.createElement(ModalBaseProvider,{value:{opened:a,onClose:d,closeOnClickOutside:vt,transitionProps:{...nt,keepMounted:c},getTitleId:()=>`${Wt}-title`,getBodyId:()=>`${Wt}-body`,titleMounted:Xt,bodyMounted:a0,setTitleMounted:t0,setBodyMounted:c0,trapFocus:tt,closeOnEscape:bt,zIndex:Rt,unstyled:Nt}},React.createElement(RemoveScroll,{enabled:n0&&Mt,...Ot},React.createElement(Box,{ref:Gt,...Ut,__vars:{...Dt,"--mb-z-index":(Rt||getDefaultZIndex("modal")).toString(),"--mb-shadow":getShadow(kt),"--mb-padding":getSpacing(It)}},Tt))))});function useModalBodyId(){const c=useModalBaseContext();return reactExports.useEffect(()=>(c.setBodyMounted(!0),()=>c.setBodyMounted(!1)),[]),c.getBodyId()}var classes$v={title:"m_615af6c9",header:"m_b5489c3c",inner:"m_60c222c7",content:"m_fd1ab0aa",close:"m_606cb269",body:"m_5df29311"};const ModalBaseBody=reactExports.forwardRef(({className:c,...a},d)=>{const et=useModalBodyId(),nt=useModalBaseContext();return React.createElement(Box,{ref:d,...a,id:et,className:clsx({[classes$v.body]:!nt.unstyled},c)})});ModalBaseBody.displayName="@mantine/core/ModalBaseBody";const ModalBaseCloseButton=reactExports.forwardRef(({className:c,onClick:a,...d},et)=>{const nt=useModalBaseContext();return React.createElement(CloseButton,{ref:et,...d,onClick:tt=>{nt.onClose(),a==null||a(tt)},className:clsx({[classes$v.close]:!nt.unstyled},c),unstyled:nt.unstyled})});ModalBaseCloseButton.displayName="@mantine/core/ModalBaseCloseButton";const ModalBaseContent=reactExports.forwardRef(({transitionProps:c,className:a,innerProps:d,onKeyDown:et,style:nt,...tt},bt)=>{const mt=useModalBaseContext();return React.createElement(Transition,{mounted:mt.opened,transition:"pop",...mt.transitionProps,...c},vt=>React.createElement("div",{...d,className:clsx({[classes$v.inner]:!mt.unstyled},d.className)},React.createElement(FocusTrap,{active:mt.opened&&mt.trapFocus},React.createElement(Paper,{...tt,component:"section",role:"dialog",tabIndex:-1,"aria-modal":!0,"aria-describedby":mt.bodyMounted?mt.getBodyId():void 0,"aria-labelledby":mt.titleMounted?mt.getTitleId():void 0,ref:bt,style:[nt,vt],className:clsx({[classes$v.content]:!mt.unstyled},a),unstyled:mt.unstyled},tt.children))))}),ModalBaseHeader=reactExports.forwardRef(({className:c,...a},d)=>{const et=useModalBaseContext();return React.createElement(Box,{component:"header",ref:d,className:clsx({[classes$v.header]:!et.unstyled},c),...a})});ModalBaseHeader.displayName="@mantine/core/ModalBaseHeader";const DEFAULT_TRANSITION={duration:200,timingFunction:"ease",transition:"fade"};function useModalTransition(c){const a=useModalBaseContext();return{...DEFAULT_TRANSITION,...a.transitionProps,...c}}const ModalBaseOverlay=reactExports.forwardRef(({onClick:c,transitionProps:a,style:d,...et},nt)=>{const tt=useModalBaseContext(),bt=useModalTransition(a);return React.createElement(Transition,{mounted:tt.opened,...bt,transition:"fade"},mt=>React.createElement(Overlay,{ref:nt,fixed:!0,style:[d,mt],zIndex:tt.zIndex,unstyled:tt.unstyled,onClick:vt=>{c==null||c(vt),tt.closeOnClickOutside&&tt.onClose()},...et}))});ModalBaseOverlay.displayName="@mantine/core/ModalBaseOverlay";function useModalTitle(){const c=useModalBaseContext();return reactExports.useEffect(()=>(c.setTitleMounted(!0),()=>c.setTitleMounted(!1)),[]),c.getTitleId()}const ModalBaseTitle=reactExports.forwardRef(({className:c,...a},d)=>{const et=useModalTitle(),nt=useModalBaseContext();return React.createElement(Box,{component:"h2",ref:d,className:clsx({[classes$v.title]:!nt.unstyled},c),...a,id:et})});ModalBaseTitle.displayName="@mantine/core/ModalBaseTitle";function NativeScrollArea({children:c}){return React.createElement(React.Fragment,null,c)}const[InputWrapperProvider,useInputWrapperContext]=createOptionalContext({offsetBottom:!1,offsetTop:!1,describedBy:void 0,getStyles:null,inputId:void 0,labelId:void 0});var classes$u={wrapper:"m_6c018570",input:"m_8fb7ebe7",section:"m_82577fc2",placeholder:"m_88bacfd0",root:"m_46b77525",label:"m_8fdc1311",required:"m_78a94662",error:"m_8f816625",description:"m_fe47ce59"};const defaultProps$16={},varsResolver$q=(c,{size:a})=>({description:{"--input-description-size":a===void 0?void 0:`calc(${getFontSize(a)} - ${rem(2)})`}}),InputDescription=factory((c,a)=>{const d=useProps("InputDescription",defaultProps$16,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,size:$t,__staticSelector:At,__inheritStyles:Mt=!0,variant:Tt,...Rt}=useProps("InputDescription",defaultProps$16,d),kt=useInputWrapperContext(),It=useStyles({name:["InputWrapper",At],props:d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,rootSelector:"description",vars:vt,varsResolver:varsResolver$q}),Dt=Mt&&(kt==null?void 0:kt.getStyles)||It;return React.createElement(Box,{component:"p",ref:a,variant:Tt,size:$t,...Dt("description",kt!=null&&kt.getStyles?{className:nt,style:tt}:void 0),...Rt})});InputDescription.classes=classes$u;InputDescription.displayName="@mantine/core/InputDescription";const defaultProps$15={},varsResolver$p=(c,{size:a})=>({error:{"--input-error-size":a===void 0?void 0:`calc(${getFontSize(a)} - ${rem(2)})`}}),InputError=factory((c,a)=>{const d=useProps("InputError",defaultProps$15,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,size:$t,__staticSelector:At,__inheritStyles:Mt=!0,variant:Tt,...Rt}=d,kt=useStyles({name:["InputWrapper",At],props:d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,rootSelector:"error",vars:vt,varsResolver:varsResolver$p}),It=useInputWrapperContext(),Dt=Mt&&(It==null?void 0:It.getStyles)||kt;return React.createElement(Box,{component:"p",ref:a,variant:Tt,size:$t,...Dt("error",It!=null&&It.getStyles?{className:nt,style:tt}:void 0),...Rt})});InputError.classes=classes$u;InputError.displayName="@mantine/core/InputError";const defaultProps$14={labelElement:"label"},varsResolver$o=(c,{size:a})=>({label:{"--input-label-size":getFontSize(a),"--input-asterisk-color":void 0}}),InputLabel=factory((c,a)=>{const d=useProps("InputLabel",defaultProps$14,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,labelElement:$t,size:At,required:Mt,htmlFor:Tt,onMouseDown:Rt,children:kt,__staticSelector:It,variant:Dt,mod:Nt,...Ot}=useProps("InputLabel",defaultProps$14,d),Ut=useStyles({name:["InputWrapper",It],props:d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,rootSelector:"label",vars:vt,varsResolver:varsResolver$o}),Gt=useInputWrapperContext(),Wt=(Gt==null?void 0:Gt.getStyles)||Ut;return React.createElement(Box,{...Wt("label",Gt!=null&&Gt.getStyles?{className:nt,style:tt}:void 0),component:$t,variant:Dt,size:At,ref:a,htmlFor:$t==="label"?Tt:void 0,mod:[{required:Mt},Nt],onMouseDown:Xt=>{Rt==null||Rt(Xt),!Xt.defaultPrevented&&Xt.detail>1&&Xt.preventDefault()},...Ot},kt,Mt&&React.createElement("span",{...Wt("required"),"aria-hidden":!0}," *"))});InputLabel.classes=classes$u;InputLabel.displayName="@mantine/core/InputLabel";const defaultProps$13={},InputPlaceholder=factory((c,a)=>{const d=useProps("InputPlaceholder",defaultProps$13,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,__staticSelector:$t,variant:At,error:Mt,mod:Tt,...Rt}=useProps("InputPlaceholder",defaultProps$13,d),kt=useStyles({name:["InputPlaceholder",$t],props:d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,rootSelector:"placeholder"});return React.createElement(Box,{...kt("placeholder"),mod:[{error:!!Mt},Tt],component:"span",variant:At,ref:a,...Rt})});InputPlaceholder.classes=classes$u;InputPlaceholder.displayName="@mantine/core/InputPlaceholder";function getInputOffsets(c,{hasDescription:a,hasError:d}){const et=c.findIndex(vt=>vt==="input"),nt=c[et-1],tt=c[et+1];return{offsetBottom:a&&tt==="description"||d&&tt==="error",offsetTop:a&&nt==="description"||d&&nt==="error"}}const defaultProps$12={labelElement:"label",inputContainer:c=>c,inputWrapperOrder:["label","description","input","error"]},varsResolver$n=(c,{size:a})=>({label:{"--input-label-size":getFontSize(a),"--input-asterisk-color":void 0},error:{"--input-error-size":a===void 0?void 0:`calc(${getFontSize(a)} - ${rem(2)})`},description:{"--input-description-size":a===void 0?void 0:`calc(${getFontSize(a)} - ${rem(2)})`}}),InputWrapper=factory((c,a)=>{const d=useProps("InputWrapper",defaultProps$12,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,size:$t,variant:At,__staticSelector:Mt,inputContainer:Tt,inputWrapperOrder:Rt,label:kt,error:It,description:Dt,labelProps:Nt,descriptionProps:Ot,errorProps:Ut,labelElement:Gt,children:Wt,withAsterisk:Xt,id:a0,required:n0,__stylesApiProps:t0,mod:c0,...Ct}=d,dt=useStyles({name:["InputWrapper",Mt],props:t0||d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$n}),yt={size:$t,variant:At,__staticSelector:Mt},gt=useId$1(a0),xt=typeof Xt=="boolean"?Xt:n0,St=(Ut==null?void 0:Ut.id)||`${gt}-error`,_t=(Ot==null?void 0:Ot.id)||`${gt}-description`,Pt=gt,Et=!!It&&typeof It!="boolean",ht=!!Dt,wt=`${Et?St:""} ${ht?_t:""}`,Bt=wt.trim().length>0?wt.trim():void 0,Lt=(Nt==null?void 0:Nt.id)||`${gt}-label`,jt=kt&&React.createElement(InputLabel,{key:"label",labelElement:Gt,id:Lt,htmlFor:Pt,required:xt,...yt,...Nt},kt),Ft=ht&&React.createElement(InputDescription,{key:"description",...Ot,...yt,size:(Ot==null?void 0:Ot.size)||yt.size,id:(Ot==null?void 0:Ot.id)||_t},Dt),Vt=React.createElement(React.Fragment,{key:"input"},Tt(Wt)),zt=Et&&React.createElement(InputError,{...Ut,...yt,size:(Ut==null?void 0:Ut.size)||yt.size,key:"error",id:(Ut==null?void 0:Ut.id)||St},It),qt=Rt.map(Kt=>{switch(Kt){case"label":return jt;case"input":return Vt;case"description":return Ft;case"error":return zt;default:return null}});return React.createElement(InputWrapperProvider,{value:{getStyles:dt,describedBy:Bt,inputId:Pt,labelId:Lt,...getInputOffsets(Rt,{hasDescription:ht,hasError:Et})}},React.createElement(Box,{ref:a,variant:At,size:$t,mod:[{error:!!It},c0],...dt("root"),...Ct},qt))});InputWrapper.classes=classes$u;InputWrapper.displayName="@mantine/core/InputWrapper";const defaultProps$11={variant:"default",leftSectionPointerEvents:"none",rightSectionPointerEvents:"none",withAria:!0,withErrorStyles:!0},varsResolver$m=(c,a,d)=>({wrapper:{"--input-margin-top":d.offsetTop?"calc(var(--mantine-spacing-xs) / 2)":void 0,"--input-margin-bottom":d.offsetBottom?"calc(var(--mantine-spacing-xs) / 2)":void 0,"--input-height":getSize(a.size,"input-height"),"--input-fz":getFontSize(a.size),"--input-radius":a.radius===void 0?void 0:getRadius(a.radius),"--input-left-section-width":a.leftSectionWidth!==void 0?rem(a.leftSectionWidth):void 0,"--input-right-section-width":a.rightSectionWidth!==void 0?rem(a.rightSectionWidth):void 0,"--input-padding-y":a.multiline?getSize(a.size,"input-padding-y"):void 0,"--input-left-section-pointer-events":a.leftSectionPointerEvents,"--input-right-section-pointer-events":a.rightSectionPointerEvents}}),Input=polymorphicFactory((c,a)=>{const d=useProps("Input",defaultProps$11,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,required:vt,__staticSelector:$t,__stylesApiProps:At,size:Mt,wrapperProps:Tt,error:Rt,disabled:kt,leftSection:It,leftSectionProps:Dt,leftSectionWidth:Nt,rightSection:Ot,rightSectionProps:Ut,rightSectionWidth:Gt,rightSectionPointerEvents:Wt,leftSectionPointerEvents:Xt,variant:a0,vars:n0,pointer:t0,multiline:c0,radius:Ct,id:dt,withAria:yt,withErrorStyles:gt,mod:xt,...St}=d,{styleProps:_t,rest:Pt}=extractStyleProps(St),Et=useInputWrapperContext(),ht={offsetBottom:Et==null?void 0:Et.offsetBottom,offsetTop:Et==null?void 0:Et.offsetTop},wt=useStyles({name:["Input",$t],props:At||d,classes:classes$u,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,stylesCtx:ht,rootSelector:"wrapper",vars:n0,varsResolver:varsResolver$m}),Bt=yt?{required:vt,disabled:kt,"aria-invalid":!!Rt,"aria-describedby":Et==null?void 0:Et.describedBy,id:(Et==null?void 0:Et.inputId)||dt}:{};return React.createElement(Box,{...wt("wrapper"),..._t,...Tt,mod:[{error:!!Rt&>,pointer:t0,disabled:kt,multiline:c0,"data-with-right-section":!!Ot,"data-with-left-section":!!It},xt],variant:a0,size:Mt},It&&React.createElement("div",{...Dt,"data-position":"left",...wt("section",{className:Dt==null?void 0:Dt.className,style:Dt==null?void 0:Dt.style})},It),React.createElement(Box,{component:"input",...Pt,...Bt,ref:a,required:vt,mod:{disabled:kt,error:!!Rt&>},variant:a0,...wt("input")}),Ot&&React.createElement("div",{...Ut,"data-position":"right",...wt("section",{className:Ut==null?void 0:Ut.className,style:Ut==null?void 0:Ut.style})},Ot))});Input.classes=classes$u;Input.Wrapper=InputWrapper;Input.Label=InputLabel;Input.Error=InputError;Input.Description=InputDescription;Input.Placeholder=InputPlaceholder;Input.displayName="@mantine/core/Input";function useInputProps(c,a,d){const et=useProps(c,a,d),{label:nt,description:tt,error:bt,required:mt,classNames:vt,styles:$t,className:At,unstyled:Mt,__staticSelector:Tt,__stylesApiProps:Rt,errorProps:kt,labelProps:It,descriptionProps:Dt,wrapperProps:Nt,id:Ot,size:Ut,style:Gt,inputContainer:Wt,inputWrapperOrder:Xt,withAsterisk:a0,variant:n0,vars:t0,mod:c0,...Ct}=et,{styleProps:dt,rest:yt}=extractStyleProps(Ct),gt={label:nt,description:tt,error:bt,required:mt,classNames:vt,className:At,__staticSelector:Tt,__stylesApiProps:Rt||et,errorProps:kt,labelProps:It,descriptionProps:Dt,unstyled:Mt,styles:$t,size:Ut,style:Gt,inputContainer:Wt,inputWrapperOrder:Xt,withAsterisk:a0,variant:n0,id:Ot,mod:c0,...Nt};return{...yt,classNames:vt,styles:$t,unstyled:Mt,wrapperProps:{...gt,...dt},inputProps:{required:mt,classNames:vt,styles:$t,unstyled:Mt,size:Ut,__staticSelector:Tt,__stylesApiProps:Rt||et,error:bt,variant:n0,id:Ot}}}const defaultProps$10={__staticSelector:"InputBase",withAria:!0},InputBase=polymorphicFactory((c,a)=>{const{inputProps:d,wrapperProps:et,...nt}=useInputProps("InputBase",defaultProps$10,c);return React.createElement(Input.Wrapper,{...et},React.createElement(Input,{...d,...nt,ref:a}))});InputBase.classes={...Input.classes,...Input.Wrapper.classes};InputBase.displayName="@mantine/core/InputBase";function AccordionChevron({style:c,size:a=16,...d}){return React.createElement("svg",{viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{...c,width:rem(a),height:rem(a),display:"block"},...d},React.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}AccordionChevron.displayName="@mantine/core/AccordionChevron";var classes$t={root:"m_7f854edf"};const defaultProps$$={position:{bottom:0,right:0},zIndex:getDefaultZIndex("modal"),withinPortal:!0},varsResolver$l=(c,{zIndex:a,position:d})=>({root:{"--affix-z-index":a==null?void 0:a.toString(),"--affix-top":rem(d==null?void 0:d.top),"--affix-left":rem(d==null?void 0:d.left),"--affix-bottom":rem(d==null?void 0:d.bottom),"--affix-right":rem(d==null?void 0:d.right)}}),Affix=factory((c,a)=>{const d=useProps("Affix",defaultProps$$,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,portalProps:$t,zIndex:At,withinPortal:Mt,position:Tt,...Rt}=d,kt=useStyles({name:"Affix",classes:classes$t,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$l});return React.createElement(OptionalPortal,{...$t,withinPortal:Mt},React.createElement(Box,{ref:a,...kt("root"),...Rt}))});Affix.classes=classes$t;Affix.displayName="@mantine/core/Affix";var classes$s={root:"m_66836ed3",wrapper:"m_a5d60502",body:"m_667c2793",title:"m_6a03f287",label:"m_698f4f23",icon:"m_667f2a6a",message:"m_7fa78076",closeButton:"m_87f54839"};const defaultProps$_={},varsResolver$k=(c,{radius:a,color:d,variant:et,autoContrast:nt})=>{const tt=c.variantColorResolver({color:d||c.primaryColor,theme:c,variant:et||"light",autoContrast:nt});return{root:{"--alert-radius":a===void 0?void 0:getRadius(a),"--alert-bg":d||et?tt.background:void 0,"--alert-color":tt.color,"--alert-bd":d||et?tt.border:void 0}}},Alert=factory((c,a)=>{const d=useProps("Alert",defaultProps$_,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,radius:$t,color:At,title:Mt,children:Tt,id:Rt,icon:kt,withCloseButton:It,onClose:Dt,closeButtonLabel:Nt,variant:Ot,autoContrast:Ut,...Gt}=d,Wt=useStyles({name:"Alert",classes:classes$s,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$k}),Xt=useId$1(Rt),a0=Mt&&`${Xt}-title`||void 0,n0=`${Xt}-body`;return React.createElement(Box,{id:Xt,...Wt("root",{variant:Ot}),variant:Ot,ref:a,...Gt,role:"alert","aria-describedby":n0,"aria-labelledby":a0},React.createElement("div",{...Wt("wrapper")},kt&&React.createElement("div",{...Wt("icon")},kt),React.createElement("div",{...Wt("body")},Mt&&React.createElement("div",{...Wt("title"),"data-with-close-button":It||void 0},React.createElement("span",{id:a0,...Wt("label")},Mt)),Tt&&React.createElement("div",{id:n0,...Wt("message"),"data-variant":Ot},Tt)),It&&React.createElement(CloseButton,{...Wt("closeButton"),onClick:Dt,variant:"transparent",size:16,iconSize:16,"aria-label":Nt,unstyled:mt})))});Alert.classes=classes$s;Alert.displayName="@mantine/core/Alert";var classes$r={root:"m_b6d8b162"};function getTextTruncate(c){if(c==="start")return"start";if(c==="end"||c)return"end"}const defaultProps$Z={inherit:!1},varsResolver$j=(c,{variant:a,lineClamp:d,gradient:et,size:nt,color:tt})=>({root:{"--text-fz":getFontSize(nt),"--text-lh":getLineHeight(nt),"--text-gradient":a==="gradient"?getGradient(et,c):void 0,"--text-line-clamp":typeof d=="number"?d.toString():void 0,"--text-color":tt?getThemeColor(tt,c):void 0}}),Text=polymorphicFactory((c,a)=>{const d=useProps("Text",defaultProps$Z,c),{lineClamp:et,truncate:nt,inline:tt,inherit:bt,gradient:mt,span:vt,__staticSelector:$t,vars:At,className:Mt,style:Tt,classNames:Rt,styles:kt,unstyled:It,variant:Dt,mod:Nt,size:Ot,...Ut}=d,Gt=useStyles({name:["Text",$t],props:d,classes:classes$r,className:Mt,style:Tt,classNames:Rt,styles:kt,unstyled:It,vars:At,varsResolver:varsResolver$j});return React.createElement(Box,{...Gt("root",{focusable:!0}),ref:a,component:vt?"span":"p",variant:Dt,mod:[{"data-truncate":getTextTruncate(nt),"data-line-clamp":typeof et=="number","data-inline":tt,"data-inherit":bt},Nt],size:Ot,...Ut})});Text.classes=classes$r;Text.displayName="@mantine/core/Text";var classes$q={root:"m_849cf0da"};const defaultProps$Y={underline:"hover"},Anchor=polymorphicFactory((c,a)=>{const{underline:d,className:et,unstyled:nt,mod:tt,...bt}=useProps("Anchor",defaultProps$Y,c);return React.createElement(Text,{component:"a",ref:a,className:clsx({[classes$q.root]:!nt},et),...bt,mod:[{underline:d},tt],__staticSelector:"Anchor",unstyled:nt})});Anchor.classes=classes$q;Anchor.displayName="@mantine/core/Anchor";const[AppShellProvider,useAppShellContext]=createSafeContext("AppShell was not found in tree");var classes$p={root:"m_89ab340",navbar:"m_45252eee",aside:"m_9cdde9a",header:"m_3b16f56b",main:"m_8983817",footer:"m_3840c879",section:"m_6dcfc7c7"};const defaultProps$X={},AppShellAside=factory((c,a)=>{const d=useProps("AppShellAside",defaultProps$X,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,withBorder:$t,zIndex:At,mod:Mt,...Tt}=d,Rt=useAppShellContext();return Rt.disabled?null:React.createElement(Box,{component:"aside",ref:a,mod:[{"with-border":$t??Rt.withBorder},Mt],...Rt.getStyles("aside",{className:nt,classNames:et,styles:bt,style:tt}),...Tt,__vars:{"--app-shell-aside-z-index":`calc(${At??Rt.zIndex} + 1)`}})});AppShellAside.classes=classes$p;AppShellAside.displayName="@mantine/core/AppShellAside";const defaultProps$W={},AppShellFooter=factory((c,a)=>{var kt;const d=useProps("AppShellFooter",defaultProps$W,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,withBorder:$t,zIndex:At,mod:Mt,...Tt}=d,Rt=useAppShellContext();return Rt.disabled?null:React.createElement(Box,{component:"footer",ref:a,mod:[{"with-border":$t??Rt.withBorder},Mt],...Rt.getStyles("footer",{className:clsx({[RemoveScroll.classNames.zeroRight]:Rt.offsetScrollbars},nt),classNames:et,styles:bt,style:tt}),...Tt,__vars:{"--app-shell-footer-z-index":(kt=At??Rt.zIndex)==null?void 0:kt.toString()}})});AppShellFooter.classes=classes$p;AppShellFooter.displayName="@mantine/core/AppShellFooter";const defaultProps$V={},AppShellHeader=factory((c,a)=>{var kt;const d=useProps("AppShellHeader",defaultProps$V,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,withBorder:$t,zIndex:At,mod:Mt,...Tt}=d,Rt=useAppShellContext();return Rt.disabled?null:React.createElement(Box,{component:"header",ref:a,mod:[{"with-border":$t??Rt.withBorder},Mt],...Rt.getStyles("header",{className:clsx({[RemoveScroll.classNames.zeroRight]:Rt.offsetScrollbars},nt),classNames:et,styles:bt,style:tt}),...Tt,__vars:{"--app-shell-header-z-index":(kt=At??Rt.zIndex)==null?void 0:kt.toString()}})});AppShellHeader.classes=classes$p;AppShellHeader.displayName="@mantine/core/AppShellHeader";const defaultProps$U={},AppShellMain=factory((c,a)=>{const d=useProps("AppShellMain",defaultProps$U,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useAppShellContext();return React.createElement(Box,{component:"main",ref:a,...$t.getStyles("main",{className:nt,style:tt,classNames:et,styles:bt}),...vt})});AppShellMain.classes=classes$p;AppShellMain.displayName="@mantine/core/AppShellMain";function getBaseSize(c){return typeof c=="object"?c.base:c}function isPrimitiveSize(c){const a=typeof c=="object"&&c!==null&&typeof c.base<"u"&&Object.keys(c).length===1;return typeof c=="number"||typeof c=="string"||a}function isResponsiveSize(c){return!(typeof c!="object"||c===null||Object.keys(c).length===1&&"base"in c)}function assignAsideVariables({baseStyles:c,minMediaStyles:a,maxMediaStyles:d,aside:et,theme:nt}){var vt,$t,At;const tt=et==null?void 0:et.width,bt="translateX(var(--app-shell-aside-width))",mt="translateX(calc(var(--app-shell-aside-width) * -1))";if(et!=null&&et.breakpoint&&!((vt=et==null?void 0:et.collapsed)!=null&&vt.mobile)&&(d[et==null?void 0:et.breakpoint]=d[et==null?void 0:et.breakpoint]||{},d[et==null?void 0:et.breakpoint]["--app-shell-aside-width"]="100%",d[et==null?void 0:et.breakpoint]["--app-shell-aside-offset"]="0px"),isPrimitiveSize(tt)){const Mt=rem(getBaseSize(tt));c["--app-shell-aside-width"]=Mt,c["--app-shell-aside-offset"]=Mt}if(isResponsiveSize(tt)&&(typeof tt.base<"u"&&(c["--app-shell-aside-width"]=rem(tt.base),c["--app-shell-aside-offset"]=rem(tt.base)),keys(tt).forEach(Mt=>{Mt!=="base"&&(a[Mt]=a[Mt]||{},a[Mt]["--app-shell-aside-width"]=rem(tt[Mt]),a[Mt]["--app-shell-aside-offset"]=rem(tt[Mt]))})),($t=et==null?void 0:et.collapsed)!=null&&$t.desktop){const Mt=et.breakpoint;a[Mt]=a[Mt]||{},a[Mt]["--app-shell-aside-transform"]=bt,a[Mt]["--app-shell-aside-transform-rtl"]=mt,a[Mt]["--app-shell-aside-offset"]="0px !important"}if((At=et==null?void 0:et.collapsed)!=null&&At.mobile){const Mt=getBreakpointValue$1(et.breakpoint,nt)-.1;d[Mt]=d[Mt]||{},d[Mt]["--app-shell-aside-width"]="100%",d[Mt]["--app-shell-aside-offset"]="0px",d[Mt]["--app-shell-aside-transform"]=bt,d[Mt]["--app-shell-aside-transform-rtl"]=mt}}function assignFooterVariables({baseStyles:c,minMediaStyles:a,footer:d}){const et=d==null?void 0:d.height,nt="translateY(var(--app-shell-footer-height))",tt=(d==null?void 0:d.offset)??!0;if(isPrimitiveSize(et)){const bt=rem(getBaseSize(et));c["--app-shell-footer-height"]=bt,tt&&(c["--app-shell-footer-offset"]=bt)}isResponsiveSize(et)&&(typeof et.base<"u"&&(c["--app-shell-footer-height"]=rem(et.base),tt&&(c["--app-shell-footer-offset"]=rem(et.base))),keys(et).forEach(bt=>{bt!=="base"&&(a[bt]=a[bt]||{},a[bt]["--app-shell-footer-height"]=rem(et[bt]),tt&&(a[bt]["--app-shell-footer-offset"]=rem(et[bt])))})),d!=null&&d.collapsed&&(c["--app-shell-footer-transform"]=nt,c["--app-shell-footer-offset"]="0px !important")}function assignHeaderVariables({baseStyles:c,minMediaStyles:a,header:d}){const et=d==null?void 0:d.height,nt="translateY(calc(var(--app-shell-header-height) * -1))",tt=(d==null?void 0:d.offset)??!0;if(isPrimitiveSize(et)){const bt=rem(getBaseSize(et));c["--app-shell-header-height"]=bt,tt&&(c["--app-shell-header-offset"]=bt)}isResponsiveSize(et)&&(typeof et.base<"u"&&(c["--app-shell-header-height"]=rem(et.base),tt&&(c["--app-shell-header-offset"]=rem(et.base))),keys(et).forEach(bt=>{bt!=="base"&&(a[bt]=a[bt]||{},a[bt]["--app-shell-header-height"]=rem(et[bt]),tt&&(a[bt]["--app-shell-header-offset"]=rem(et[bt])))})),d!=null&&d.collapsed&&(c["--app-shell-header-transform"]=nt,c["--app-shell-header-offset"]="0px !important")}function assignNavbarVariables({baseStyles:c,minMediaStyles:a,maxMediaStyles:d,navbar:et,theme:nt}){var vt,$t,At;const tt=et==null?void 0:et.width,bt="translateX(calc(var(--app-shell-navbar-width) * -1))",mt="translateX(var(--app-shell-navbar-width))";if(et!=null&&et.breakpoint&&!((vt=et==null?void 0:et.collapsed)!=null&&vt.mobile)&&(d[et==null?void 0:et.breakpoint]=d[et==null?void 0:et.breakpoint]||{},d[et==null?void 0:et.breakpoint]["--app-shell-navbar-width"]="100%",d[et==null?void 0:et.breakpoint]["--app-shell-navbar-offset"]="0px"),isPrimitiveSize(tt)){const Mt=rem(getBaseSize(tt));c["--app-shell-navbar-width"]=Mt,c["--app-shell-navbar-offset"]=Mt}if(isResponsiveSize(tt)&&(typeof tt.base<"u"&&(c["--app-shell-navbar-width"]=rem(tt.base),c["--app-shell-navbar-offset"]=rem(tt.base)),keys(tt).forEach(Mt=>{Mt!=="base"&&(a[Mt]=a[Mt]||{},a[Mt]["--app-shell-navbar-width"]=rem(tt[Mt]),a[Mt]["--app-shell-navbar-offset"]=rem(tt[Mt]))})),($t=et==null?void 0:et.collapsed)!=null&&$t.desktop){const Mt=et.breakpoint;a[Mt]=a[Mt]||{},a[Mt]["--app-shell-navbar-transform"]=bt,a[Mt]["--app-shell-navbar-transform-rtl"]=mt,a[Mt]["--app-shell-navbar-offset"]="0px !important"}if((At=et==null?void 0:et.collapsed)!=null&&At.mobile){const Mt=getBreakpointValue$1(et.breakpoint,nt)-.1;d[Mt]=d[Mt]||{},d[Mt]["--app-shell-navbar-width"]="100%",d[Mt]["--app-shell-navbar-offset"]="0px",d[Mt]["--app-shell-navbar-transform"]=bt,d[Mt]["--app-shell-navbar-transform-rtl"]=mt}}function getPaddingValue(c){return Number(c)===0?"0px":getSpacing(c)}function assignPaddingVariables({padding:c,baseStyles:a,minMediaStyles:d}){isPrimitiveSize(c)&&(a["--app-shell-padding"]=getPaddingValue(getBaseSize(c))),isResponsiveSize(c)&&(c.base&&(a["--app-shell-padding"]=getPaddingValue(c.base)),keys(c).forEach(et=>{et!=="base"&&(d[et]=d[et]||{},d[et]["--app-shell-padding"]=getPaddingValue(c[et]))}))}function getVariables({navbar:c,header:a,footer:d,aside:et,padding:nt,theme:tt}){const bt={},mt={},vt={};assignNavbarVariables({baseStyles:vt,minMediaStyles:bt,maxMediaStyles:mt,navbar:c,theme:tt}),assignAsideVariables({baseStyles:vt,minMediaStyles:bt,maxMediaStyles:mt,aside:et,theme:tt}),assignHeaderVariables({baseStyles:vt,minMediaStyles:bt,header:a}),assignFooterVariables({baseStyles:vt,minMediaStyles:bt,footer:d}),assignPaddingVariables({baseStyles:vt,minMediaStyles:bt,padding:nt});const $t=getSortedBreakpoints(keys(bt),tt).map(Tt=>({query:`(min-width: ${em(Tt.px)})`,styles:bt[Tt.value]})),At=getSortedBreakpoints(keys(mt),tt).map(Tt=>({query:`(max-width: ${em(Tt.px)})`,styles:mt[Tt.value]})),Mt=[...$t,...At];return{baseStyles:vt,media:Mt}}function AppShellMediaStyles({navbar:c,header:a,aside:d,footer:et,padding:nt}){const tt=useMantineTheme(),bt=useMantineContext(),{media:mt,baseStyles:vt}=getVariables({navbar:c,header:a,footer:et,aside:d,padding:nt,theme:tt});return React.createElement(InlineStyles,{media:mt,styles:vt,selector:bt.cssVariablesSelector})}const defaultProps$T={},AppShellNavbar=factory((c,a)=>{const d=useProps("AppShellNavbar",defaultProps$T,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,withBorder:$t,zIndex:At,mod:Mt,...Tt}=d,Rt=useAppShellContext();return Rt.disabled?null:React.createElement(Box,{component:"nav",ref:a,mod:[{"with-border":$t??Rt.withBorder},Mt],...Rt.getStyles("navbar",{className:nt,classNames:et,styles:bt,style:tt}),...Tt,__vars:{"--app-shell-navbar-z-index":`calc(${At??Rt.zIndex} + 1)`}})});AppShellNavbar.classes=classes$p;AppShellNavbar.displayName="@mantine/core/AppShellNavbar";const defaultProps$S={},AppShellSection=polymorphicFactory((c,a)=>{const d=useProps("AppShellSection",defaultProps$S,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,grow:vt,mod:$t,...At}=d,Mt=useAppShellContext();return React.createElement(Box,{ref:a,mod:[{grow:vt},$t],...Mt.getStyles("section",{className:nt,style:tt,classNames:et,styles:bt}),...At})});AppShellSection.classes=classes$p;AppShellSection.displayName="@mantine/core/AppShellSection";function useResizing({transitionDuration:c,disabled:a}){const[d,et]=reactExports.useState(!0),nt=reactExports.useRef(),tt=reactExports.useRef();return useWindowEvent("resize",()=>{et(!0),clearTimeout(nt.current),nt.current=window.setTimeout(()=>et(!1),200)}),useIsomorphicEffect(()=>{reactExports.startTransition(()=>{et(!0),clearTimeout(tt.current),tt.current=window.setTimeout(()=>et(!1),c||0)})},[a,c]),d}const defaultProps$R={withBorder:!0,offsetScrollbars:!0,padding:0,transitionDuration:200,transitionTimingFunction:"ease",zIndex:getDefaultZIndex("app")},varsResolver$i=(c,{transitionDuration:a,transitionTimingFunction:d})=>({root:{"--app-shell-transition-duration":`${a}ms`,"--app-shell-transition-timing-function":d}}),AppShell=factory((c,a)=>{const d=useProps("AppShell",defaultProps$R,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,navbar:$t,withBorder:At,padding:Mt,transitionDuration:Tt,transitionTimingFunction:Rt,header:kt,zIndex:It,layout:Dt,disabled:Nt,aside:Ot,footer:Ut,offsetScrollbars:Gt,mod:Wt,...Xt}=d,a0=useStyles({name:"AppShell",classes:classes$p,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$i}),n0=useResizing({disabled:Nt,transitionDuration:Tt});return React.createElement(AppShellProvider,{value:{getStyles:a0,withBorder:At,zIndex:It,disabled:Nt,offsetScrollbars:Gt}},React.createElement(AppShellMediaStyles,{navbar:$t,header:kt,aside:Ot,footer:Ut,padding:Mt}),React.createElement(Box,{ref:a,...a0("root"),mod:[{resizing:n0,layout:Dt,disabled:Nt},Wt],...Xt}))});AppShell.classes=classes$p;AppShell.displayName="@mantine/core/AppShell";AppShell.Navbar=AppShellNavbar;AppShell.Header=AppShellHeader;AppShell.Main=AppShellMain;AppShell.Aside=AppShellAside;AppShell.Footer=AppShellFooter;AppShell.Section=AppShellSection;var classes$o={dropdown:"m_88b62a41",options:"m_b2821a6e",option:"m_92253aa5",search:"m_985517d8",empty:"m_2530cd1d",header:"m_858f94bd",footer:"m_82b967cb",group:"m_254f3e4f",groupLabel:"m_2bb2e9e5",chevron:"m_2943220b",optionsDropdownOption:"m_390b5f4",optionsDropdownCheckIcon:"m_8ee53fc2"};const defaultProps$Q={error:null},varsResolver$h=(c,{size:a})=>({chevron:{"--combobox-chevron-size":getSize(a,"combobox-chevron-size")}}),ComboboxChevron=factory((c,a)=>{const d=useProps("ComboboxChevron",defaultProps$Q,c),{size:et,error:nt,style:tt,className:bt,classNames:mt,styles:vt,unstyled:$t,vars:At,mod:Mt,...Tt}=d,Rt=useStyles({name:"ComboboxChevron",classes:classes$o,props:d,style:tt,className:bt,classNames:mt,styles:vt,unstyled:$t,vars:At,varsResolver:varsResolver$h,rootSelector:"chevron"});return React.createElement(Box,{component:"svg",...Tt,...Rt("chevron"),size:et,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",mod:["combobox-chevron",{error:nt},Mt],ref:a},React.createElement("path",{d:"M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))});ComboboxChevron.classes=classes$o;ComboboxChevron.displayName="@mantine/core/ComboboxChevron";const[ComboboxProvider,useComboboxContext]=createSafeContext("Combobox component was not found in tree"),ComboboxClearButton=reactExports.forwardRef(({size:c,onMouseDown:a,onClick:d,onClear:et,...nt},tt)=>React.createElement(CloseButton,{ref:tt,size:c||"sm",variant:"transparent",tabIndex:-1,"aria-hidden":!0,...nt,onMouseDown:bt=>{bt.preventDefault(),a==null||a(bt)},onClick:bt=>{et(),d==null||d(bt)}}));ComboboxClearButton.displayName="@mantine/core/ComboboxClearButton";const defaultProps$P={},ComboboxDropdown=factory((c,a)=>{const{classNames:d,styles:et,className:nt,style:tt,hidden:bt,...mt}=useProps("ComboboxDropdown",defaultProps$P,c),vt=useComboboxContext();return React.createElement(Popover.Dropdown,{...mt,ref:a,role:"presentation","data-hidden":bt||void 0,...vt.getStyles("dropdown",{className:nt,style:tt,classNames:d,styles:et})})});ComboboxDropdown.classes=classes$o;ComboboxDropdown.displayName="@mantine/core/ComboboxDropdown";const defaultProps$O={refProp:"ref"},ComboboxDropdownTarget=factory((c,a)=>{const{children:d,refProp:et}=useProps("ComboboxDropdownTarget",defaultProps$O,c);if(useComboboxContext(),!isElement$1(d))throw new Error("Combobox.DropdownTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");return React.createElement(Popover.Target,{ref:a,refProp:et},d)});ComboboxDropdownTarget.displayName="@mantine/core/ComboboxDropdownTarget";const defaultProps$N={},ComboboxEmpty=factory((c,a)=>{const{classNames:d,className:et,style:nt,styles:tt,vars:bt,...mt}=useProps("ComboboxEmpty",defaultProps$N,c),vt=useComboboxContext();return React.createElement(Box,{ref:a,...vt.getStyles("empty",{className:et,classNames:d,styles:tt,style:nt}),...mt})});ComboboxEmpty.classes=classes$o;ComboboxEmpty.displayName="@mantine/core/ComboboxEmpty";function useComboboxTargetProps({onKeyDown:c,withKeyboardNavigation:a,withAriaAttributes:d,withExpandedAttribute:et,targetType:nt,autoComplete:tt}){const bt=useComboboxContext(),[mt,vt]=reactExports.useState(null),$t=Mt=>{if(c==null||c(Mt),!bt.readOnly&&a){if(Mt.nativeEvent.isComposing)return;if(Mt.nativeEvent.code==="ArrowDown"&&(Mt.preventDefault(),bt.store.dropdownOpened?vt(bt.store.selectNextOption()):(bt.store.openDropdown("keyboard"),vt(bt.store.selectActiveOption()))),Mt.nativeEvent.code==="ArrowUp"&&(Mt.preventDefault(),bt.store.dropdownOpened?vt(bt.store.selectPreviousOption()):(bt.store.openDropdown("keyboard"),vt(bt.store.selectActiveOption()))),Mt.nativeEvent.code==="Enter"||Mt.nativeEvent.code==="NumpadEnter"){if(Mt.nativeEvent.keyCode===229)return;const Tt=bt.store.getSelectedOptionIndex();bt.store.dropdownOpened&&Tt!==-1?(Mt.preventDefault(),bt.store.clickSelectedOption()):nt==="button"&&(Mt.preventDefault(),bt.store.openDropdown("keyboard"))}Mt.nativeEvent.code==="Escape"&&bt.store.closeDropdown("keyboard"),Mt.nativeEvent.code==="Space"&&nt==="button"&&(Mt.preventDefault(),bt.store.toggleDropdown("keyboard"))}};return{...d?{"aria-haspopup":"listbox","aria-expanded":et&&!!(bt.store.listId&&bt.store.dropdownOpened)||void 0,"aria-controls":bt.store.listId,"aria-activedescendant":bt.store.dropdownOpened&&mt||void 0,autoComplete:tt,"data-expanded":bt.store.dropdownOpened||void 0,"data-mantine-stop-propagation":bt.store.dropdownOpened||void 0}:{},onKeyDown:$t}}const defaultProps$M={refProp:"ref",targetType:"input",withKeyboardNavigation:!0,withAriaAttributes:!0,withExpandedAttribute:!1,autoComplete:"off"},ComboboxEventsTarget=factory((c,a)=>{const{children:d,refProp:et,withKeyboardNavigation:nt,withAriaAttributes:tt,withExpandedAttribute:bt,targetType:mt,autoComplete:vt,...$t}=useProps("ComboboxEventsTarget",defaultProps$M,c);if(!isElement$1(d))throw new Error("Combobox.EventsTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const At=useComboboxContext(),Mt=useComboboxTargetProps({targetType:mt,withAriaAttributes:tt,withKeyboardNavigation:nt,withExpandedAttribute:bt,onKeyDown:d.props.onKeyDown,autoComplete:vt});return reactExports.cloneElement(d,{...Mt,...$t,[et]:useMergedRef(a,At.store.targetRef,d==null?void 0:d.ref)})});ComboboxEventsTarget.displayName="@mantine/core/ComboboxEventsTarget";const defaultProps$L={},ComboboxFooter=factory((c,a)=>{const{classNames:d,className:et,style:nt,styles:tt,vars:bt,...mt}=useProps("ComboboxFooter",defaultProps$L,c),vt=useComboboxContext();return React.createElement(Box,{ref:a,...vt.getStyles("footer",{className:et,classNames:d,style:nt,styles:tt}),...mt})});ComboboxFooter.classes=classes$o;ComboboxFooter.displayName="@mantine/core/ComboboxFooter";const defaultProps$K={},ComboboxGroup=factory((c,a)=>{const{classNames:d,className:et,style:nt,styles:tt,vars:bt,children:mt,label:vt,...$t}=useProps("ComboboxGroup",defaultProps$K,c),At=useComboboxContext();return React.createElement(Box,{ref:a,...At.getStyles("group",{className:et,classNames:d,style:nt,styles:tt}),...$t},vt&&React.createElement("div",{...At.getStyles("groupLabel",{classNames:d,styles:tt})},vt),mt)});ComboboxGroup.classes=classes$o;ComboboxGroup.displayName="@mantine/core/ComboboxGroup";const defaultProps$J={},ComboboxHeader=factory((c,a)=>{const{classNames:d,className:et,style:nt,styles:tt,vars:bt,...mt}=useProps("ComboboxHeader",defaultProps$J,c),vt=useComboboxContext();return React.createElement(Box,{ref:a,...vt.getStyles("header",{className:et,classNames:d,style:nt,styles:tt}),...mt})});ComboboxHeader.classes=classes$o;ComboboxHeader.displayName="@mantine/core/ComboboxHeader";function ComboboxHiddenInput({value:c,valuesDivider:a=",",...d}){return React.createElement("input",{type:"hidden",value:Array.isArray(c)?c.join(a):c||"",...d})}ComboboxHiddenInput.displayName="@mantine/core/ComboboxHiddenInput";const defaultProps$I={},ComboboxOption=factory((c,a)=>{const d=useProps("ComboboxOption",defaultProps$I,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,onClick:vt,id:$t,active:At,onMouseDown:Mt,onMouseOver:Tt,disabled:Rt,selected:kt,mod:It,...Dt}=d,Nt=useComboboxContext(),Ot=reactExports.useId(),Ut=$t||Ot;return React.createElement(Box,{...Nt.getStyles("option",{className:nt,classNames:et,styles:bt,style:tt}),...Dt,ref:a,id:Ut,mod:["combobox-option",{"combobox-active":At,"combobox-disabled":Rt,"combobox-selected":kt},It],role:"option",onClick:Gt=>{var Wt;Rt?Gt.preventDefault():((Wt=Nt.onOptionSubmit)==null||Wt.call(Nt,d.value,d),vt==null||vt(Gt))},onMouseDown:Gt=>{Gt.preventDefault(),Mt==null||Mt(Gt)},onMouseOver:Gt=>{Nt.resetSelectionOnOptionHover&&Nt.store.resetSelectedOption(),Tt==null||Tt(Gt)}})});ComboboxOption.classes=classes$o;ComboboxOption.displayName="@mantine/core/ComboboxOption";const defaultProps$H={},ComboboxOptions=factory((c,a)=>{const d=useProps("ComboboxOptions",defaultProps$H,c),{classNames:et,className:nt,style:tt,styles:bt,id:mt,onMouseDown:vt,labelledBy:$t,...At}=d,Mt=useComboboxContext(),Tt=useId$1(mt);return reactExports.useEffect(()=>{Mt.store.setListId(Tt)},[Tt]),React.createElement(Box,{ref:a,...Mt.getStyles("options",{className:nt,style:tt,classNames:et,styles:bt}),...At,id:Tt,role:"listbox","aria-labelledby":$t,onMouseDown:Rt=>{Rt.preventDefault(),vt==null||vt(Rt)}})});ComboboxOptions.classes=classes$o;ComboboxOptions.displayName="@mantine/core/ComboboxOptions";const defaultProps$G={withAriaAttributes:!0,withKeyboardNavigation:!0},ComboboxSearch=factory((c,a)=>{const d=useProps("ComboboxSearch",defaultProps$G,c),{classNames:et,styles:nt,unstyled:tt,vars:bt,withAriaAttributes:mt,onKeyDown:vt,withKeyboardNavigation:$t,size:At,...Mt}=d,Tt=useComboboxContext(),Rt=Tt.getStyles("search"),kt=useComboboxTargetProps({targetType:"input",withAriaAttributes:mt,withKeyboardNavigation:$t,withExpandedAttribute:!1,onKeyDown:vt,autoComplete:"off"});return React.createElement(Input,{ref:useMergedRef(a,Tt.store.searchRef),classNames:[{input:Rt.className},et],styles:[{input:Rt.style},nt],size:At||Tt.size,...kt,...Mt,__staticSelector:"Combobox"})});ComboboxSearch.classes=classes$o;ComboboxSearch.displayName="@mantine/core/ComboboxSearch";const defaultProps$F={refProp:"ref",targetType:"input",withKeyboardNavigation:!0,withAriaAttributes:!0,withExpandedAttribute:!1,autoComplete:"off"},ComboboxTarget=factory((c,a)=>{const{children:d,refProp:et,withKeyboardNavigation:nt,withAriaAttributes:tt,withExpandedAttribute:bt,targetType:mt,autoComplete:vt,...$t}=useProps("ComboboxTarget",defaultProps$F,c);if(!isElement$1(d))throw new Error("Combobox.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");const At=useComboboxContext(),Mt=useComboboxTargetProps({targetType:mt,withAriaAttributes:tt,withKeyboardNavigation:nt,withExpandedAttribute:bt,onKeyDown:d.props.onKeyDown,autoComplete:vt}),Tt=reactExports.cloneElement(d,{...Mt,...$t});return React.createElement(Popover.Target,{ref:useMergedRef(a,At.store.targetRef)},Tt)});ComboboxTarget.displayName="@mantine/core/ComboboxTarget";function getPreviousIndex(c,a,d){for(let et=c-1;et>=0;et-=1)if(!a[et].hasAttribute("data-combobox-disabled"))return et;if(d){for(let et=a.length-1;et>-1;et-=1)if(!a[et].hasAttribute("data-combobox-disabled"))return et}return c}function getNextIndex$1(c,a,d){for(let et=c+1;et{mt||(vt(!0),nt==null||nt(St))},[vt,nt,mt]),Nt=reactExports.useCallback((St="unknown")=>{mt&&(vt(!1),et==null||et(St))},[vt,et,mt]),Ot=reactExports.useCallback((St="unknown")=>{mt?Nt(St):Dt(St)},[Nt,Dt,mt]),Ut=reactExports.useCallback(()=>{const St=document.querySelector(`#${$t.current} [data-combobox-selected]`);St==null||St.removeAttribute("data-combobox-selected"),St==null||St.removeAttribute("aria-selected")},[]),Gt=reactExports.useCallback(St=>{const _t=document.getElementById($t.current),Pt=_t==null?void 0:_t.querySelectorAll("[data-combobox-option]");if(!Pt)return null;const Et=St>=Pt.length?0:St<0?Pt.length-1:St;return At.current=Et,Pt!=null&&Pt[Et]&&!Pt[Et].hasAttribute("data-combobox-disabled")?(Ut(),Pt[Et].setAttribute("data-combobox-selected","true"),Pt[Et].setAttribute("aria-selected","true"),Pt[Et].scrollIntoView({block:"nearest",behavior:bt}),Pt[Et].id):null},[bt,Ut]),Wt=reactExports.useCallback(()=>{const St=document.querySelector(`#${$t.current} [data-combobox-active]`);if(St){const _t=document.querySelectorAll(`#${$t.current} [data-combobox-option]`),Pt=Array.from(_t).findIndex(Et=>Et===St);return Gt(Pt)}return Gt(0)},[Gt]),Xt=reactExports.useCallback(()=>Gt(getNextIndex$1(At.current,document.querySelectorAll(`#${$t.current} [data-combobox-option]`),tt)),[Gt,tt]),a0=reactExports.useCallback(()=>Gt(getPreviousIndex(At.current,document.querySelectorAll(`#${$t.current} [data-combobox-option]`),tt)),[Gt,tt]),n0=reactExports.useCallback(()=>Gt(getFirstIndex(document.querySelectorAll(`#${$t.current} [data-combobox-option]`))),[Gt]),t0=reactExports.useCallback((St="selected",_t)=>{It.current=window.setTimeout(()=>{var ht;const Pt=document.querySelectorAll(`#${$t.current} [data-combobox-option]`),Et=Array.from(Pt).findIndex(wt=>wt.hasAttribute(`data-combobox-${St}`));At.current=Et,_t!=null&&_t.scrollIntoView&&((ht=Pt[Et])==null||ht.scrollIntoView({block:"nearest",behavior:bt}))},0)},[]),c0=reactExports.useCallback(()=>{At.current=-1,Ut()},[Ut]),Ct=reactExports.useCallback(()=>{const St=document.querySelectorAll(`#${$t.current} [data-combobox-option]`),_t=St==null?void 0:St[At.current];_t==null||_t.click()},[]),dt=reactExports.useCallback(St=>{$t.current=St},[]),yt=reactExports.useCallback(()=>{Rt.current=window.setTimeout(()=>Mt.current.focus(),0)},[]),gt=reactExports.useCallback(()=>{kt.current=window.setTimeout(()=>Tt.current.focus(),0)},[]),xt=reactExports.useCallback(()=>At.current,[]);return reactExports.useEffect(()=>()=>{window.clearTimeout(Rt.current),window.clearTimeout(kt.current),window.clearTimeout(It.current)},[]),{dropdownOpened:mt,openDropdown:Dt,closeDropdown:Nt,toggleDropdown:Ot,selectedOptionIndex:At.current,getSelectedOptionIndex:xt,selectOption:Gt,selectFirstOption:n0,selectActiveOption:Wt,selectNextOption:Xt,selectPreviousOption:a0,resetSelectedOption:c0,updateSelectedOptionIndex:t0,listId:$t.current,setListId:dt,clickSelectedOption:Ct,searchRef:Mt,focusSearchInput:yt,targetRef:Tt,focusTarget:gt}}const defaultProps$E={keepMounted:!0,withinPortal:!0,resetSelectionOnOptionHover:!1,width:"target",transitionProps:{transition:"fade",duration:0}},varsResolver$g=(c,{size:a,dropdownPadding:d})=>({options:{"--combobox-option-fz":getFontSize(a),"--combobox-option-padding":getSize(a,"combobox-option-padding")},dropdown:{"--combobox-padding":d===void 0?void 0:rem(d),"--combobox-option-fz":getFontSize(a),"--combobox-option-padding":getSize(a,"combobox-option-padding")}});function Combobox(c){const a=useProps("Combobox",defaultProps$E,c),{classNames:d,styles:et,unstyled:nt,children:tt,store:bt,vars:mt,onOptionSubmit:vt,onClose:$t,size:At,dropdownPadding:Mt,resetSelectionOnOptionHover:Tt,__staticSelector:Rt,readOnly:kt,...It}=a,Dt=useCombobox(),Nt=bt||Dt,Ot=useStyles({name:Rt||"Combobox",classes:classes$o,props:a,classNames:d,styles:et,unstyled:nt,vars:mt,varsResolver:varsResolver$g}),Ut=()=>{$t==null||$t(),Nt.closeDropdown()};return React.createElement(ComboboxProvider,{value:{getStyles:Ot,store:Nt,onOptionSubmit:vt,size:At,resetSelectionOnOptionHover:Tt,readOnly:kt}},React.createElement(Popover,{opened:Nt.dropdownOpened,...It,onClose:Ut,withRoles:!1,unstyled:nt},tt))}const extendCombobox=c=>c;Combobox.extend=extendCombobox;Combobox.classes=classes$o;Combobox.displayName="@mantine/core/Combobox";Combobox.Target=ComboboxTarget;Combobox.Dropdown=ComboboxDropdown;Combobox.Options=ComboboxOptions;Combobox.Option=ComboboxOption;Combobox.Search=ComboboxSearch;Combobox.Empty=ComboboxEmpty;Combobox.Chevron=ComboboxChevron;Combobox.Footer=ComboboxFooter;Combobox.Header=ComboboxHeader;Combobox.EventsTarget=ComboboxEventsTarget;Combobox.DropdownTarget=ComboboxDropdownTarget;Combobox.Group=ComboboxGroup;Combobox.ClearButton=ComboboxClearButton;Combobox.HiddenInput=ComboboxHiddenInput;function CheckIcon({size:c,style:a,...d}){const et=c!==void 0?{width:rem(c),height:rem(c),...a}:a;return React.createElement("svg",{viewBox:"0 0 10 7",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:et,"aria-hidden":!0,...d},React.createElement("path",{d:"M4 4.586L1.707 2.293A1 1 0 1 0 .293 3.707l3 3a.997.997 0 0 0 1.414 0l5-5A1 1 0 1 0 8.293.293L4 4.586z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const AvatarGroupContext=reactExports.createContext(null),AvatarGroupProvider=AvatarGroupContext.Provider;function useAvatarGroupContext(){return{withinGroup:!!reactExports.useContext(AvatarGroupContext)}}var classes$n={group:"m_11def92b",root:"m_f85678b6",image:"m_11f8ac07",placeholder:"m_104cd71f"};const defaultProps$D={},varsResolver$f=(c,{spacing:a})=>({group:{"--ag-spacing":getSpacing(a)}}),AvatarGroup=factory((c,a)=>{const d=useProps("AvatarGroup",defaultProps$D,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,spacing:$t,...At}=d,Mt=useStyles({name:"AvatarGroup",classes:classes$n,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$f,rootSelector:"group"});return React.createElement(AvatarGroupProvider,{value:!0},React.createElement(Box,{ref:a,...Mt("group"),...At}))});AvatarGroup.classes=classes$n;AvatarGroup.displayName="@mantine/core/AvatarGroup";function AvatarPlaceholderIcon(c){return React.createElement("svg",{...c,"data-avatar-placeholder-icon":!0,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M0.877014 7.49988C0.877014 3.84219 3.84216 0.877045 7.49985 0.877045C11.1575 0.877045 14.1227 3.84219 14.1227 7.49988C14.1227 11.1575 11.1575 14.1227 7.49985 14.1227C3.84216 14.1227 0.877014 11.1575 0.877014 7.49988ZM7.49985 1.82704C4.36683 1.82704 1.82701 4.36686 1.82701 7.49988C1.82701 8.97196 2.38774 10.3131 3.30727 11.3213C4.19074 9.94119 5.73818 9.02499 7.50023 9.02499C9.26206 9.02499 10.8093 9.94097 11.6929 11.3208C12.6121 10.3127 13.1727 8.97172 13.1727 7.49988C13.1727 4.36686 10.6328 1.82704 7.49985 1.82704ZM10.9818 11.9787C10.2839 10.7795 8.9857 9.97499 7.50023 9.97499C6.01458 9.97499 4.71624 10.7797 4.01845 11.9791C4.97952 12.7272 6.18765 13.1727 7.49985 13.1727C8.81227 13.1727 10.0206 12.727 10.9818 11.9787ZM5.14999 6.50487C5.14999 5.207 6.20212 4.15487 7.49999 4.15487C8.79786 4.15487 9.84999 5.207 9.84999 6.50487C9.84999 7.80274 8.79786 8.85487 7.49999 8.85487C6.20212 8.85487 5.14999 7.80274 5.14999 6.50487ZM7.49999 5.10487C6.72679 5.10487 6.09999 5.73167 6.09999 6.50487C6.09999 7.27807 6.72679 7.90487 7.49999 7.90487C8.27319 7.90487 8.89999 7.27807 8.89999 6.50487C8.89999 5.73167 8.27319 5.10487 7.49999 5.10487Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const defaultProps$C={},varsResolver$e=(c,{size:a,radius:d,variant:et,gradient:nt,color:tt,autoContrast:bt})=>{const mt=c.variantColorResolver({color:tt||"gray",theme:c,gradient:nt,variant:et||"light",autoContrast:bt});return{root:{"--avatar-size":getSize(a,"avatar-size"),"--avatar-radius":d===void 0?void 0:getRadius(d),"--avatar-bg":tt||et?mt.background:void 0,"--avatar-color":tt||et?mt.color:void 0,"--avatar-bd":tt||et?mt.border:void 0}}},Avatar=polymorphicFactory((c,a)=>{const d=useProps("Avatar",defaultProps$C,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,src:$t,alt:At,radius:Mt,color:Tt,gradient:Rt,imageProps:kt,children:It,autoContrast:Dt,mod:Nt,...Ot}=d,Ut=useAvatarGroupContext(),[Gt,Wt]=reactExports.useState(!$t),Xt=useStyles({name:"Avatar",props:d,classes:classes$n,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$e});return reactExports.useEffect(()=>Wt(!$t),[$t]),React.createElement(Box,{...Xt("root"),mod:[{"within-group":Ut.withinGroup},Nt],ref:a,...Ot},Gt?React.createElement("span",{...Xt("placeholder"),title:At},It||React.createElement(AvatarPlaceholderIcon,null)):React.createElement("img",{...kt,...Xt("image"),src:$t,alt:At,onError:a0=>{var n0;Wt(!0),(n0=kt==null?void 0:kt.onError)==null||n0.call(kt,a0)}}))});Avatar.classes=classes$n;Avatar.displayName="@mantine/core/Avatar";Avatar.Group=AvatarGroup;var classes$m={root:"m_347db0ec","root--dot":"m_fbd81e3d",label:"m_5add502a",section:"m_91fdda9b"};const defaultProps$B={},varsResolver$d=(c,{radius:a,color:d,gradient:et,variant:nt,size:tt,autoContrast:bt})=>{const mt=c.variantColorResolver({color:d||c.primaryColor,theme:c,gradient:et,variant:nt||"filled",autoContrast:bt});return{root:{"--badge-height":getSize(tt,"badge-height"),"--badge-padding-x":getSize(tt,"badge-padding-x"),"--badge-fz":getSize(tt,"badge-fz"),"--badge-radius":a===void 0?void 0:getRadius(a),"--badge-bg":d||nt?mt.background:void 0,"--badge-color":d||nt?mt.color:void 0,"--badge-bd":d||nt?mt.border:void 0,"--badge-dot-color":nt==="dot"?getThemeColor(d,c):void 0}}},Badge=polymorphicFactory((c,a)=>{const d=useProps("Badge",defaultProps$B,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,radius:$t,color:At,gradient:Mt,leftSection:Tt,rightSection:Rt,children:kt,variant:It,fullWidth:Dt,autoContrast:Nt,circle:Ot,mod:Ut,...Gt}=d,Wt=useStyles({name:"Badge",props:d,classes:classes$m,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$d});return React.createElement(Box,{variant:It,mod:[{block:Dt,circle:Ot},Ut],...Wt("root",{variant:It}),ref:a,...Gt},Tt&&React.createElement("span",{...Wt("section"),"data-position":"left"},Tt),React.createElement("span",{...Wt("label")},kt),Rt&&React.createElement("span",{...Wt("section"),"data-position":"right"},Rt))});Badge.classes=classes$m;Badge.displayName="@mantine/core/Badge";var classes$l={root:"m_77c9d27d",inner:"m_80f1301b",label:"m_811560b9",section:"m_a74036a",loader:"m_a25b86ee",group:"m_80d6d844"};const defaultProps$A={orientation:"horizontal"},varsResolver$c=(c,{borderWidth:a})=>({group:{"--button-border-width":rem(a)}}),ButtonGroup=factory((c,a)=>{const d=useProps("ButtonGroup",defaultProps$A,c),{className:et,style:nt,classNames:tt,styles:bt,unstyled:mt,orientation:vt,vars:$t,borderWidth:At,variant:Mt,mod:Tt,...Rt}=useProps("ButtonGroup",defaultProps$A,c),kt=useStyles({name:"ButtonGroup",props:d,classes:classes$l,className:et,style:nt,classNames:tt,styles:bt,unstyled:mt,vars:$t,varsResolver:varsResolver$c,rootSelector:"group"});return React.createElement(Box,{...kt("group"),ref:a,variant:Mt,mod:[{"data-orientation":vt},Tt],role:"group",...Rt})});ButtonGroup.classes=classes$l;ButtonGroup.displayName="@mantine/core/ButtonGroup";const loaderTransition={in:{opacity:1,transform:`translate(-50%, calc(-50% + ${rem(1)}))`},out:{opacity:0,transform:"translate(-50%, -200%)"},common:{transformOrigin:"center"},transitionProperty:"transform, opacity"},defaultProps$z={},varsResolver$b=(c,{radius:a,color:d,gradient:et,variant:nt,size:tt,justify:bt,autoContrast:mt})=>{const vt=c.variantColorResolver({color:d||c.primaryColor,theme:c,gradient:et,variant:nt||"filled",autoContrast:mt});return{root:{"--button-justify":bt,"--button-height":getSize(tt,"button-height"),"--button-padding-x":getSize(tt,"button-padding-x"),"--button-fz":tt!=null&&tt.includes("compact")?getFontSize(tt.replace("compact-","")):getFontSize(tt),"--button-radius":a===void 0?void 0:getRadius(a),"--button-bg":d||nt?vt.background:void 0,"--button-hover":d||nt?vt.hover:void 0,"--button-color":vt.color,"--button-bd":d||nt?vt.border:void 0,"--button-hover-color":d||nt?vt.hoverColor:void 0}}},Button=polymorphicFactory((c,a)=>{const d=useProps("Button",defaultProps$z,c),{style:et,vars:nt,className:tt,color:bt,disabled:mt,children:vt,leftSection:$t,rightSection:At,fullWidth:Mt,variant:Tt,radius:Rt,loading:kt,loaderProps:It,gradient:Dt,classNames:Nt,styles:Ot,unstyled:Ut,"data-disabled":Gt,autoContrast:Wt,mod:Xt,...a0}=d,n0=useStyles({name:"Button",props:d,classes:classes$l,className:tt,style:et,classNames:Nt,styles:Ot,unstyled:Ut,vars:nt,varsResolver:varsResolver$b}),t0=!!$t,c0=!!At;return React.createElement(UnstyledButton,{ref:a,...n0("root",{active:!mt&&!kt&&!Gt}),unstyled:Ut,variant:Tt,disabled:mt||kt,mod:[{disabled:mt||Gt,loading:kt,block:Mt,"with-left-section":t0,"with-right-section":c0},Xt],...a0},React.createElement(Transition,{mounted:!!kt,transition:loaderTransition,duration:150},Ct=>React.createElement(Box,{component:"span",...n0("loader",{style:Ct}),"aria-hidden":!0},React.createElement(Loader,{color:"var(--button-color)",size:"calc(var(--button-height) / 1.8)",...It}))),React.createElement("span",{...n0("inner")},$t&&React.createElement(Box,{component:"span",...n0("section"),mod:{position:"left"}},$t),React.createElement(Box,{component:"span",mod:{loading:kt},...n0("label")},vt),At&&React.createElement(Box,{component:"span",...n0("section"),mod:{position:"right"}},At)))});Button.classes=classes$l;Button.displayName="@mantine/core/Button";Button.Group=ButtonGroup;var classes$k={root:"m_e2125a27",closeButton:"m_5abab665"};const defaultProps$y={shadow:"md",p:"md",withBorder:!1,transitionProps:{transition:"pop-top-right",duration:200},position:{bottom:30,right:30}},varsResolver$a=(c,{size:a})=>({root:{"--dialog-size":getSize(a,"dialog-size")}}),Dialog=factory((c,a)=>{const d=useProps("Dialog",defaultProps$y,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,zIndex:$t,position:At,keepMounted:Mt,opened:Tt,transitionProps:Rt,withCloseButton:kt,withinPortal:It,children:Dt,onClose:Nt,portalProps:Ot,...Ut}=d,Gt=useStyles({name:"Dialog",classes:classes$k,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$a});return React.createElement(Affix,{zIndex:$t,position:At,ref:a,withinPortal:It,portalProps:Ot,unstyled:mt},React.createElement(Transition,{keepMounted:Mt,mounted:Tt,...Rt},Wt=>React.createElement(Paper,{unstyled:mt,...Gt("root",{style:Wt}),...Ut},kt&&React.createElement(CloseButton,{onClick:Nt,unstyled:mt,...Gt("closeButton")}),Dt)))});Dialog.classes=classes$k;Dialog.displayName="@mantine/core/Dialog";var classes$j={root:"m_9e117634"};const defaultProps$x={},varsResolver$9=(c,{radius:a,fit:d})=>({root:{"--image-radius":a===void 0?void 0:getRadius(a),"--image-object-fit":d}}),Image$1=polymorphicFactory((c,a)=>{const d=useProps("Image",defaultProps$x,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,onError:$t,src:At,radius:Mt,fit:Tt,fallbackSrc:Rt,mod:kt,...It}=d,[Dt,Nt]=reactExports.useState(!At);reactExports.useEffect(()=>Nt(!At),[At]);const Ot=useStyles({name:"Image",classes:classes$j,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$9});return Dt&&Rt?React.createElement(Box,{component:"img",ref:a,src:Rt,...Ot("root"),onError:$t,mod:["fallback",kt],...It}):React.createElement(Box,{component:"img",ref:a,...Ot("root"),src:At,onError:Ut=>{$t==null||$t(Ut),Nt(!0)},mod:kt,...It})});Image$1.classes=classes$j;Image$1.displayName="@mantine/core/Image";const[ModalProvider,useModalContext]=createSafeContext("Modal component was not found in tree");var classes$i={root:"m_9df02822",content:"m_54c44539",inner:"m_1f958f16",header:"m_d0e2b9cd"};const defaultProps$w={},ModalBody=factory((c,a)=>{const d=useProps("ModalBody",defaultProps$w,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useModalContext();return React.createElement(ModalBaseBody,{ref:a,...$t.getStyles("body",{classNames:et,style:tt,styles:bt,className:nt}),...vt})});ModalBody.classes=classes$i;ModalBody.displayName="@mantine/core/ModalBody";const defaultProps$v={},ModalCloseButton=factory((c,a)=>{const d=useProps("ModalCloseButton",defaultProps$v,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useModalContext();return React.createElement(ModalBaseCloseButton,{ref:a,...$t.getStyles("close",{classNames:et,style:tt,styles:bt,className:nt}),...vt})});ModalCloseButton.classes=classes$i;ModalCloseButton.displayName="@mantine/core/ModalCloseButton";const defaultProps$u={},ModalContent=factory((c,a)=>{const d=useProps("ModalContent",defaultProps$u,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,children:vt,...$t}=d,At=useModalContext(),Mt=At.scrollAreaComponent||NativeScrollArea;return React.createElement(ModalBaseContent,{...At.getStyles("content",{className:nt,style:tt,styles:bt,classNames:et}),innerProps:At.getStyles("inner",{className:nt,style:tt,styles:bt,classNames:et}),"data-full-screen":At.fullScreen||void 0,"data-modal-content":!0,ref:a,...$t},React.createElement(Mt,{style:{maxHeight:At.fullScreen?"100dvh":`calc(100dvh - (${rem(At.yOffset)} * 2))`}},vt))});ModalContent.classes=classes$i;ModalContent.displayName="@mantine/core/ModalContent";const defaultProps$t={},ModalHeader=factory((c,a)=>{const d=useProps("ModalHeader",defaultProps$t,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useModalContext();return React.createElement(ModalBaseHeader,{ref:a,...$t.getStyles("header",{classNames:et,style:tt,styles:bt,className:nt}),...vt})});ModalHeader.classes=classes$i;ModalHeader.displayName="@mantine/core/ModalHeader";const defaultProps$s={},ModalOverlay=factory((c,a)=>{const d=useProps("ModalOverlay",defaultProps$s,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useModalContext();return React.createElement(ModalBaseOverlay,{ref:a,...$t.getStyles("overlay",{classNames:et,style:tt,styles:bt,className:nt}),...vt})});ModalOverlay.classes=classes$i;ModalOverlay.displayName="@mantine/core/ModalOverlay";const defaultProps$r={__staticSelector:"Modal",closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:getDefaultZIndex("modal"),transitionProps:{duration:200,transition:"pop"},yOffset:"5dvh"},varsResolver$8=(c,{radius:a,size:d,yOffset:et,xOffset:nt})=>({root:{"--modal-radius":a===void 0?void 0:getRadius(a),"--modal-size":getSize(d,"modal-size"),"--modal-y-offset":rem(et),"--modal-x-offset":rem(nt)}}),ModalRoot=factory((c,a)=>{const d=useProps("ModalRoot",defaultProps$r,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,yOffset:$t,scrollAreaComponent:At,radius:Mt,fullScreen:Tt,centered:Rt,xOffset:kt,__staticSelector:It,...Dt}=d,Nt=useStyles({name:It,classes:classes$i,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$8});return React.createElement(ModalProvider,{value:{yOffset:$t,scrollAreaComponent:At,getStyles:Nt,fullScreen:Tt}},React.createElement(ModalBase,{ref:a,...Nt("root"),"data-full-screen":Tt||void 0,"data-centered":Rt||void 0,unstyled:mt,...Dt}))});ModalRoot.classes=classes$i;ModalRoot.displayName="@mantine/core/ModalRoot";const defaultProps$q={},ModalTitle=factory((c,a)=>{const d=useProps("ModalTitle",defaultProps$q,c),{classNames:et,className:nt,style:tt,styles:bt,vars:mt,...vt}=d,$t=useModalContext();return React.createElement(ModalBaseTitle,{ref:a,...$t.getStyles("title",{classNames:et,style:tt,styles:bt,className:nt}),...vt})});ModalTitle.classes=classes$i;ModalTitle.displayName="@mantine/core/ModalTitle";const defaultProps$p={closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:getDefaultZIndex("modal"),transitionProps:{duration:200,transition:"fade-down"},withOverlay:!0,withCloseButton:!0},Modal=factory((c,a)=>{const{title:d,withOverlay:et,overlayProps:nt,withCloseButton:tt,closeButtonProps:bt,children:mt,radius:vt,...$t}=useProps("Modal",defaultProps$p,c),At=!!d||tt;return React.createElement(ModalRoot,{ref:a,radius:vt,...$t},et&&React.createElement(ModalOverlay,{...nt}),React.createElement(ModalContent,{radius:vt},At&&React.createElement(ModalHeader,null,d&&React.createElement(ModalTitle,null,d),tt&&React.createElement(ModalCloseButton,{...bt})),React.createElement(ModalBody,null,mt)))});Modal.classes=classes$i;Modal.displayName="@mantine/core/Modal";Modal.Root=ModalRoot;Modal.Overlay=ModalOverlay;Modal.Content=ModalContent;Modal.Body=ModalBody;Modal.Header=ModalHeader;Modal.Title=ModalTitle;Modal.CloseButton=ModalCloseButton;var classes$h={root:"m_a513464",icon:"m_a4ceffb",loader:"m_b0920b15",body:"m_a49ed24",title:"m_3feedf16",description:"m_3d733a3a",closeButton:"m_919a4d88"};const defaultProps$o={withCloseButton:!0},varsResolver$7=(c,{radius:a,color:d})=>({root:{"--notification-radius":a===void 0?void 0:getRadius(a),"--notification-color":d?getThemeColor(d,c):void 0}}),Notification=factory((c,a)=>{const d=useProps("Notification",defaultProps$o,c),{className:et,color:nt,radius:tt,loading:bt,withCloseButton:mt,withBorder:vt,title:$t,icon:At,children:Mt,onClose:Tt,closeButtonProps:Rt,classNames:kt,style:It,styles:Dt,unstyled:Nt,variant:Ot,vars:Ut,mod:Gt,...Wt}=d,Xt=useStyles({name:"Notification",classes:classes$h,props:d,className:et,style:It,classNames:kt,styles:Dt,unstyled:Nt,vars:Ut,varsResolver:varsResolver$7});return React.createElement(Box,{...Xt("root"),mod:[{"data-with-icon":!!At||bt,"data-with-border":vt},Gt],ref:a,variant:Ot,...Wt,role:"alert"},At&&!bt&&React.createElement("div",{...Xt("icon")},At),bt&&React.createElement(Loader,{size:28,color:nt,...Xt("loader")}),React.createElement("div",{...Xt("body")},$t&&React.createElement("div",{...Xt("title")},$t),React.createElement(Box,{...Xt("description"),mod:{"data-with-title":!!$t}},Mt)),mt&&React.createElement(CloseButton,{iconSize:16,color:"gray",...Rt,unstyled:Nt,onClick:Tt,...Xt("closeButton")}))});Notification.classes=classes$h;Notification.displayName="@mantine/core/Notification";var classes$g={root:"m_18320242","skeleton-fade":"m_299c329c"};const defaultProps$n={visible:!0,animate:!0},varsResolver$6=(c,{width:a,height:d,radius:et,circle:nt})=>({root:{"--skeleton-height":rem(d),"--skeleton-width":rem(nt?d:a),"--skeleton-radius":nt?"1000px":et===void 0?void 0:getRadius(et)}}),Skeleton=factory((c,a)=>{const d=useProps("Skeleton",defaultProps$n,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,width:$t,height:At,circle:Mt,visible:Tt,radius:Rt,animate:kt,mod:It,...Dt}=d,Nt=useStyles({name:"Skeleton",classes:classes$g,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$6});return React.createElement(Box,{ref:a,...Nt("root"),mod:[{visible:Tt,animate:kt},It],...Dt})});Skeleton.classes=classes$g;Skeleton.displayName="@mantine/core/Skeleton";var classes$f={root:"m_6d731127"};const defaultProps$m={gap:"md",align:"stretch",justify:"flex-start"},varsResolver$5=(c,{gap:a,align:d,justify:et})=>({root:{"--stack-gap":getSpacing(a),"--stack-align":d,"--stack-justify":et}}),Stack=factory((c,a)=>{const d=useProps("Stack",defaultProps$m,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,align:$t,justify:At,gap:Mt,variant:Tt,...Rt}=d,kt=useStyles({name:"Stack",props:d,classes:classes$f,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$5});return React.createElement(Box,{ref:a,...kt("root"),variant:Tt,...Rt})});Stack.classes=classes$f;Stack.displayName="@mantine/core/Stack";const[StepperProvider,useStepperContext]=createSafeContext("Stepper component was not found in tree"),StepperCompleted=()=>null;StepperCompleted.displayName="@mantine/core/StepperCompleted";var classes$e={root:"m_cbb4ea7e",steps:"m_aaf89d0b",separator:"m_2a371ac9",content:"m_78da155d",step:"m_cbb57068","step--horizontal":"m_f56b1e2c","step--vertical":"m_833edb7e",verticalSeparator:"m_6496b3f3",stepWrapper:"m_818e70b",stepIcon:"m_1959ad01",stepCompletedIcon:"m_a79331dc",stepBody:"m_1956aa2a",stepLabel:"m_12051f6c",stepDescription:"m_164eea74"};const getStepFragment=(c,a)=>typeof c=="function"?React.createElement(c,{step:a||0}):c,defaultProps$l={withIcon:!0,allowStepClick:!0,iconPosition:"left"},StepperStep=factory((c,a)=>{const{classNames:d,className:et,style:nt,styles:tt,vars:bt,step:mt,state:vt,color:$t,icon:At,completedIcon:Mt,progressIcon:Tt,label:Rt,description:kt,withIcon:It,iconSize:Dt,loading:Nt,allowStepClick:Ot,allowStepSelect:Ut,iconPosition:Gt,orientation:Wt,mod:Xt,...a0}=useProps("StepperStep",defaultProps$l,c),n0=useStepperContext(),t0=useMantineTheme(),c0={classNames:d,styles:tt},Ct=vt==="stepCompleted"?null:vt==="stepProgress"?Tt:At,dt={"data-progress":vt==="stepProgress"||void 0,"data-completed":vt==="stepCompleted"||void 0};return React.createElement(UnstyledButton,{...n0.getStyles("step",{className:et,style:nt,variant:n0.orientation,...c0}),mod:[{"icon-position":Gt||n0.iconPosition,"allow-click":Ot},Xt],ref:a,...dt,...a0,__vars:{"--step-color":$t?getThemeColor($t,t0):void 0},tabIndex:Ot?0:-1},It&&React.createElement("span",{...n0.getStyles("stepWrapper",c0)},React.createElement("span",{...n0.getStyles("stepIcon",c0),...dt},React.createElement(Transition,{mounted:vt==="stepCompleted",transition:"pop",duration:200},yt=>React.createElement("span",{...n0.getStyles("stepCompletedIcon",{style:yt,...c0})},Nt?React.createElement(Loader,{color:"var(--mantine-color-white)",size:"calc(var(--stepper-icon-size) / 2)",...n0.getStyles("stepLoader",c0)}):getStepFragment(Mt,mt)||React.createElement(CheckIcon,{size:"60%"}))),vt!=="stepCompleted"?Nt?React.createElement(Loader,{...n0.getStyles("stepLoader",c0),size:"calc(var(--stepper-icon-size) / 2)",color:$t}):getStepFragment(Ct||At,mt):null),Wt==="vertical"&&React.createElement("span",{...n0.getStyles("verticalSeparator",c0),"data-active":vt==="stepCompleted"||void 0})),(Rt||kt)&&React.createElement("span",{...n0.getStyles("stepBody",c0),"data-orientation":n0.orientation,"data-icon-position":Gt||n0.iconPosition},Rt&&React.createElement("span",{...n0.getStyles("stepLabel",c0)},getStepFragment(Rt,mt)),kt&&React.createElement("span",{...n0.getStyles("stepDescription",c0)},getStepFragment(kt,mt))))});StepperStep.classes=classes$e;StepperStep.displayName="@mantine/core/StepperStep";const defaultProps$k={orientation:"horizontal",iconPosition:"left",allowNextStepsSelect:!0,wrap:!0},varsResolver$4=(c,{color:a,iconSize:d,size:et,contentPadding:nt,radius:tt,autoContrast:bt})=>({root:{"--stepper-color":a?getThemeColor(a,c):void 0,"--stepper-icon-color":getAutoContrastValue(bt,c)?getContrastColor({color:a,theme:c}):void 0,"--stepper-icon-size":d===void 0?getSize(et,"stepper-icon-size"):rem(d),"--stepper-content-padding":getSpacing(nt),"--stepper-radius":tt===void 0?void 0:getRadius(tt),"--stepper-fz":getFontSize(et),"--stepper-spacing":getSpacing(et)}}),Stepper=factory((c,a)=>{var _t,Pt,Et;const d=useProps("Stepper",defaultProps$k,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,children:$t,onStepClick:At,active:Mt,icon:Tt,completedIcon:Rt,progressIcon:kt,color:It,iconSize:Dt,contentPadding:Nt,orientation:Ot,iconPosition:Ut,size:Gt,radius:Wt,allowNextStepsSelect:Xt,wrap:a0,...n0}=d,t0=useStyles({name:"Stepper",classes:classes$e,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$4}),c0=reactExports.Children.toArray($t),Ct=c0.filter(ht=>ht.type!==StepperCompleted),dt=c0.find(ht=>ht.type===StepperCompleted),yt=Ct.reduce((ht,wt,Bt)=>{const Lt=Mt===Bt?"stepProgress":Mt>Bt?"stepCompleted":"stepInactive",Ft=(()=>typeof At!="function"?!1:typeof wt.props.allowStepSelect=="boolean"?wt.props.allowStepSelect:Lt==="stepCompleted"||Xt)();return ht.push(reactExports.cloneElement(wt,{icon:wt.props.icon||Tt||Bt+1,key:Bt,step:Bt,state:Lt,onClick:()=>Ft&&(At==null?void 0:At(Bt)),allowStepClick:Ft,completedIcon:wt.props.completedIcon||Rt,progressIcon:wt.props.progressIcon||kt,color:wt.props.color||It,iconSize:Dt,radius:Wt,iconPosition:wt.props.iconPosition||Ut,orientation:Ot,unstyled:mt})),Ot==="horizontal"&&Bt!==Ct.length-1&&ht.push(React.createElement("div",{...t0("separator"),"data-active":BtCt.length-1?xt:gt;return React.createElement(StepperProvider,{value:{getStyles:t0,orientation:Ot,iconPosition:Ut}},React.createElement(Box,{...t0("root"),ref:a,size:Gt,...n0},React.createElement(Box,{...t0("steps"),mod:{orientation:Ot,"icon-position":Ut,wrap:a0&&Ot!=="vertical"}},yt),St&&React.createElement("div",{...t0("content")},St)))});Stepper.classes=classes$e;Stepper.displayName="@mantine/core/Stepper";Stepper.Completed=StepperCompleted;Stepper.Step=StepperStep;const defaultProps$j={},TextInput=factory((c,a)=>{const d=useProps("TextInput",defaultProps$j,c);return React.createElement(InputBase,{component:"input",ref:a,...d,__staticSelector:"TextInput"})});TextInput.classes=InputBase.classes;TextInput.displayName="@mantine/core/TextInput";const createStoreImpl=c=>{let a;const d=new Set,et=(At,Mt)=>{const Tt=typeof At=="function"?At(a):At;if(!Object.is(Tt,a)){const Rt=a;a=Mt??(typeof Tt!="object"||Tt===null)?Tt:Object.assign({},a,Tt),d.forEach(kt=>kt(a,Rt))}},nt=()=>a,vt={setState:et,getState:nt,getInitialState:()=>$t,subscribe:At=>(d.add(At),()=>d.delete(At)),destroy:()=>{d.clear()}},$t=a=c(et,nt,vt);return vt},createStore=c=>c?createStoreImpl(c):createStoreImpl;var withSelector={exports:{}},withSelector_production_min={},shim={exports:{}},useSyncExternalStoreShim_production_min={};/** + * @license React + * use-sync-external-store-shim.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var e=reactExports;function h$1(c,a){return c===a&&(c!==0||1/c===1/a)||c!==c&&a!==a}var k$1=typeof Object.is=="function"?Object.is:h$1,l=e.useState,m$1=e.useEffect,n$2=e.useLayoutEffect,p$1=e.useDebugValue;function q$2(c,a){var d=a(),et=l({inst:{value:d,getSnapshot:a}}),nt=et[0].inst,tt=et[1];return n$2(function(){nt.value=d,nt.getSnapshot=a,r$4(nt)&&tt({inst:nt})},[c,d,a]),m$1(function(){return r$4(nt)&&tt({inst:nt}),c(function(){r$4(nt)&&tt({inst:nt})})},[c]),p$1(d),d}function r$4(c){var a=c.getSnapshot;c=c.value;try{var d=a();return!k$1(c,d)}catch{return!0}}function t$2(c,a){return a()}var u$1=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?t$2:q$2;useSyncExternalStoreShim_production_min.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:u$1;shim.exports=useSyncExternalStoreShim_production_min;var shimExports=shim.exports;/** + * @license React + * use-sync-external-store-shim/with-selector.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var h=reactExports,n$1=shimExports;function p(c,a){return c===a&&(c!==0||1/c===1/a)||c!==c&&a!==a}var q$1=typeof Object.is=="function"?Object.is:p,r$3=n$1.useSyncExternalStore,t$1=h.useRef,u=h.useEffect,v$1=h.useMemo,w$1=h.useDebugValue;withSelector_production_min.useSyncExternalStoreWithSelector=function(c,a,d,et,nt){var tt=t$1(null);if(tt.current===null){var bt={hasValue:!1,value:null};tt.current=bt}else bt=tt.current;tt=v$1(function(){function vt(Rt){if(!$t){if($t=!0,At=Rt,Rt=et(Rt),nt!==void 0&&bt.hasValue){var kt=bt.value;if(nt(kt,Rt))return Mt=kt}return Mt=Rt}if(kt=Mt,q$1(At,Rt))return kt;var It=et(Rt);return nt!==void 0&&nt(kt,It)?kt:(At=Rt,Mt=It)}var $t=!1,At,Mt,Tt=d===void 0?null:d;return[function(){return vt(a())},Tt===null?void 0:function(){return vt(Tt())}]},[a,d,et,nt]);var mt=r$3(c,tt[0],tt[1]);return u(function(){bt.hasValue=!0,bt.value=mt},[mt]),w$1(mt),mt};withSelector.exports=withSelector_production_min;var withSelectorExports=withSelector.exports;const useSyncExternalStoreExports=getDefaultExportFromCjs(withSelectorExports),{useDebugValue}=React,{useSyncExternalStoreWithSelector}=useSyncExternalStoreExports;let didWarnAboutEqualityFn=!1;const identity=c=>c;function useStore(c,a=identity,d){const et=useSyncExternalStoreWithSelector(c.subscribe,c.getState,c.getServerState||c.getInitialState,a,d);return useDebugValue(et),et}const createImpl=c=>{const a=typeof c=="function"?createStore(c):c,d=(et,nt)=>useStore(a,et,nt);return Object.assign(d,a),d},create=c=>c?createImpl(c):createImpl;var react=c=>create(c);const useLinkStore=react(c=>({fetching:!1,accountDetails:{},authDetails:{},chainId:localStorage.getItem("chainId")?parseInt(localStorage.getItem("chainId")):11155111,confirming:!1,confirmed:!1,claimDetails:{chainId:11155111},wallet:{},setChainId:a=>{c(d=>({...d,chainId:a}))},setClaimDetails:a=>{c(d=>({...d,claimDetails:a}))},setWallet:a=>{c(d=>({...d,wallet:a}))},setConfirming:a=>{c(d=>({...d,confirming:a}))},setConfirmed:a=>{c(d=>({...d,confirmed:a}))},setFetching:a=>{c(d=>({...d,fetching:a}))},setAccountDetails:a=>c(d=>({accountDetails:a})),setAuthDetails:a=>c(d=>({authDetails:a}))}));function memoize(c){var a=Object.create(null);return function(d){return a[d]===void 0&&(a[d]=c(d)),a[d]}}var reactPropsRegex=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,isPropValid=memoize(function(c){return reactPropsRegex.test(c)||c.charCodeAt(0)===111&&c.charCodeAt(1)===110&&c.charCodeAt(2)<91}),MS="-ms-",MOZ="-moz-",WEBKIT="-webkit-",COMMENT="comm",RULESET="rule",DECLARATION="decl",IMPORT="@import",KEYFRAMES="@keyframes",LAYER="@layer",abs=Math.abs,from=String.fromCharCode,assign=Object.assign;function hash$a(c,a){return charat(c,0)^45?(((a<<2^charat(c,0))<<2^charat(c,1))<<2^charat(c,2))<<2^charat(c,3):0}function trim$1(c){return c.trim()}function match(c,a){return(c=a.exec(c))?c[0]:c}function replace(c,a,d){return c.replace(a,d)}function indexof(c,a,d){return c.indexOf(a,d)}function charat(c,a){return c.charCodeAt(a)|0}function substr(c,a,d){return c.slice(a,d)}function strlen(c){return c.length}function sizeof(c){return c.length}function append(c,a){return a.push(c),c}function combine(c,a){return c.map(a).join("")}function filter(c,a){return c.filter(function(d){return!match(d,a)})}var line=1,column=1,length=0,position=0,character=0,characters="";function node$1(c,a,d,et,nt,tt,bt,mt){return{value:c,root:a,parent:d,type:et,props:nt,children:tt,line,column,length:bt,return:"",siblings:mt}}function copy$4(c,a){return assign(node$1("",null,null,"",null,null,0,c.siblings),c,{length:-c.length},a)}function lift(c){for(;c.root;)c=copy$4(c.root,{children:[c]});append(c,c.siblings)}function char(){return character}function prev(){return character=position>0?charat(characters,--position):0,column--,character===10&&(column=1,line--),character}function next(){return character=position2||token(character)>3?"":" "}function escaping(c,a){for(;--a&&next()&&!(character<48||character>102||character>57&&character<65||character>70&&character<97););return slice$2(c,caret()+(a<6&&peek()==32&&next()==32))}function delimiter(c){for(;next();)switch(character){case c:return position;case 34:case 39:c!==34&&c!==39&&delimiter(character);break;case 40:c===41&&delimiter(c);break;case 92:next();break}return position}function commenter(c,a){for(;next()&&c+character!==47+10;)if(c+character===42+42&&peek()===47)break;return"/*"+slice$2(a,position-1)+"*"+from(c===47?c:next())}function identifier(c){for(;!token(peek());)next();return slice$2(c,position)}function compile(c){return dealloc(parse("",null,null,null,[""],c=alloc(c),0,[0],c))}function parse(c,a,d,et,nt,tt,bt,mt,vt){for(var $t=0,At=0,Mt=bt,Tt=0,Rt=0,kt=0,It=1,Dt=1,Nt=1,Ot=0,Ut="",Gt=nt,Wt=tt,Xt=et,a0=Ut;Dt;)switch(kt=Ot,Ot=next()){case 40:if(kt!=108&&charat(a0,Mt-1)==58){indexof(a0+=replace(delimit(Ot),"&","&\f"),"&\f",abs($t?mt[$t-1]:0))!=-1&&(Nt=-1);break}case 34:case 39:case 91:a0+=delimit(Ot);break;case 9:case 10:case 13:case 32:a0+=whitespace(kt);break;case 92:a0+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append(comment(commenter(next(),caret()),a,d,vt),vt);break;default:a0+="/"}break;case 123*It:mt[$t++]=strlen(a0)*Nt;case 125*It:case 59:case 0:switch(Ot){case 0:case 125:Dt=0;case 59+At:Nt==-1&&(a0=replace(a0,/\f/g,"")),Rt>0&&strlen(a0)-Mt&&append(Rt>32?declaration(a0+";",et,d,Mt-1,vt):declaration(replace(a0," ","")+";",et,d,Mt-2,vt),vt);break;case 59:a0+=";";default:if(append(Xt=ruleset(a0,a,d,$t,At,nt,mt,Ut,Gt=[],Wt=[],Mt,tt),tt),Ot===123)if(At===0)parse(a0,a,Xt,Xt,Gt,tt,Mt,mt,Wt);else switch(Tt===99&&charat(a0,3)===110?100:Tt){case 100:case 108:case 109:case 115:parse(c,Xt,Xt,et&&append(ruleset(c,Xt,Xt,0,0,nt,mt,Ut,nt,Gt=[],Mt,Wt),Wt),nt,Wt,Mt,mt,et?Gt:Wt);break;default:parse(a0,Xt,Xt,Xt,[""],Wt,0,mt,Wt)}}$t=At=Rt=0,It=Nt=1,Ut=a0="",Mt=bt;break;case 58:Mt=1+strlen(a0),Rt=kt;default:if(It<1){if(Ot==123)--It;else if(Ot==125&&It++==0&&prev()==125)continue}switch(a0+=from(Ot),Ot*It){case 38:Nt=At>0?1:(a0+="\f",-1);break;case 44:mt[$t++]=(strlen(a0)-1)*Nt,Nt=1;break;case 64:peek()===45&&(a0+=delimit(next())),Tt=peek(),At=Mt=strlen(Ut=a0+=identifier(caret())),Ot++;break;case 45:kt===45&&strlen(a0)==2&&(It=0)}}return tt}function ruleset(c,a,d,et,nt,tt,bt,mt,vt,$t,At,Mt){for(var Tt=nt-1,Rt=nt===0?tt:[""],kt=sizeof(Rt),It=0,Dt=0,Nt=0;It0?Rt[Ot]+" "+Ut:replace(Ut,/&\f/g,Rt[Ot])))&&(vt[Nt++]=Gt);return node$1(c,a,d,nt===0?RULESET:mt,vt,$t,At,Mt)}function comment(c,a,d,et){return node$1(c,a,d,COMMENT,from(char()),substr(c,2,-2),0,et)}function declaration(c,a,d,et,nt){return node$1(c,a,d,DECLARATION,substr(c,0,et),substr(c,et+1,-1),et,nt)}function prefix(c,a,d){switch(hash$a(c,a)){case 5103:return WEBKIT+"print-"+c+c;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return WEBKIT+c+c;case 4789:return MOZ+c+c;case 5349:case 4246:case 4810:case 6968:case 2756:return WEBKIT+c+MOZ+c+MS+c+c;case 5936:switch(charat(c,a+11)){case 114:return WEBKIT+c+MS+replace(c,/[svh]\w+-[tblr]{2}/,"tb")+c;case 108:return WEBKIT+c+MS+replace(c,/[svh]\w+-[tblr]{2}/,"tb-rl")+c;case 45:return WEBKIT+c+MS+replace(c,/[svh]\w+-[tblr]{2}/,"lr")+c}case 6828:case 4268:case 2903:return WEBKIT+c+MS+c+c;case 6165:return WEBKIT+c+MS+"flex-"+c+c;case 5187:return WEBKIT+c+replace(c,/(\w+).+(:[^]+)/,WEBKIT+"box-$1$2"+MS+"flex-$1$2")+c;case 5443:return WEBKIT+c+MS+"flex-item-"+replace(c,/flex-|-self/g,"")+(match(c,/flex-|baseline/)?"":MS+"grid-row-"+replace(c,/flex-|-self/g,""))+c;case 4675:return WEBKIT+c+MS+"flex-line-pack"+replace(c,/align-content|flex-|-self/g,"")+c;case 5548:return WEBKIT+c+MS+replace(c,"shrink","negative")+c;case 5292:return WEBKIT+c+MS+replace(c,"basis","preferred-size")+c;case 6060:return WEBKIT+"box-"+replace(c,"-grow","")+WEBKIT+c+MS+replace(c,"grow","positive")+c;case 4554:return WEBKIT+replace(c,/([^-])(transform)/g,"$1"+WEBKIT+"$2")+c;case 6187:return replace(replace(replace(c,/(zoom-|grab)/,WEBKIT+"$1"),/(image-set)/,WEBKIT+"$1"),c,"")+c;case 5495:case 3959:return replace(c,/(image-set\([^]*)/,WEBKIT+"$1$`$1");case 4968:return replace(replace(c,/(.+:)(flex-)?(.*)/,WEBKIT+"box-pack:$3"+MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+WEBKIT+c+c;case 4200:if(!match(c,/flex-|baseline/))return MS+"grid-column-align"+substr(c,a)+c;break;case 2592:case 3360:return MS+replace(c,"template-","")+c;case 4384:case 3616:return d&&d.some(function(et,nt){return a=nt,match(et.props,/grid-\w+-end/)})?~indexof(c+(d=d[a].value),"span",0)?c:MS+replace(c,"-start","")+c+MS+"grid-row-span:"+(~indexof(d,"span",0)?match(d,/\d+/):+match(d,/\d+/)-+match(c,/\d+/))+";":MS+replace(c,"-start","")+c;case 4896:case 4128:return d&&d.some(function(et){return match(et.props,/grid-\w+-start/)})?c:MS+replace(replace(c,"-end","-span"),"span ","")+c;case 4095:case 3583:case 4068:case 2532:return replace(c,/(.+)-inline(.+)/,WEBKIT+"$1$2")+c;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(strlen(c)-1-a>6)switch(charat(c,a+1)){case 109:if(charat(c,a+4)!==45)break;case 102:return replace(c,/(.+:)(.+)-([^]+)/,"$1"+WEBKIT+"$2-$3$1"+MOZ+(charat(c,a+3)==108?"$3":"$2-$3"))+c;case 115:return~indexof(c,"stretch",0)?prefix(replace(c,"stretch","fill-available"),a,d)+c:c}break;case 5152:case 5920:return replace(c,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(et,nt,tt,bt,mt,vt,$t){return MS+nt+":"+tt+$t+(bt?MS+nt+"-span:"+(mt?vt:+vt-+tt)+$t:"")+c});case 4949:if(charat(c,a+6)===121)return replace(c,":",":"+WEBKIT)+c;break;case 6444:switch(charat(c,charat(c,14)===45?18:11)){case 120:return replace(c,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+WEBKIT+(charat(c,14)===45?"inline-":"")+"box$3$1"+WEBKIT+"$2$3$1"+MS+"$2box$3")+c;case 100:return replace(c,":",":"+MS)+c}break;case 5719:case 2647:case 2135:case 3927:case 2391:return replace(c,"scroll-","scroll-snap-")+c}return c}function serialize$1(c,a){for(var d="",et=0;et-1&&!c.return)switch(c.type){case DECLARATION:c.return=prefix(c.value,c.length,d);return;case KEYFRAMES:return serialize$1([copy$4(c,{value:replace(c.value,"@","@"+WEBKIT)})],et);case RULESET:if(c.length)return combine(d=c.props,function(nt){switch(match(nt,et=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":lift(copy$4(c,{props:[replace(nt,/:(read-\w+)/,":"+MOZ+"$1")]})),lift(copy$4(c,{props:[nt]})),assign(c,{props:filter(d,et)});break;case"::placeholder":lift(copy$4(c,{props:[replace(nt,/:(plac\w+)/,":"+WEBKIT+"input-$1")]})),lift(copy$4(c,{props:[replace(nt,/:(plac\w+)/,":"+MOZ+"$1")]})),lift(copy$4(c,{props:[replace(nt,/:(plac\w+)/,MS+"input-$1")]})),lift(copy$4(c,{props:[nt]})),assign(c,{props:filter(d,et)});break}return""})}}var unitlessKeys={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},f$1=typeof dist$2.process<"u"&&dist$2.process.env!==void 0&&({}.REACT_APP_SC_ATTR||{}.SC_ATTR)||"data-styled",m="active",y="data-styled-version",v="6.1.11",g$2=`/*!sc*/ +`,S=typeof window<"u"&&"HTMLElement"in window,w=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof dist$2.process<"u"&&dist$2.process.env!==void 0&&{}.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&{}.REACT_APP_SC_DISABLE_SPEEDY!==""?{}.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&{}.REACT_APP_SC_DISABLE_SPEEDY:typeof dist$2.process<"u"&&dist$2.process.env!==void 0&&{}.SC_DISABLE_SPEEDY!==void 0&&{}.SC_DISABLE_SPEEDY!==""&&{}.SC_DISABLE_SPEEDY!=="false"&&{}.SC_DISABLE_SPEEDY),_=Object.freeze([]),C=Object.freeze({});function I(c,a,d){return d===void 0&&(d=C),c.theme!==d.theme&&c.theme||a||d.theme}var A=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),O=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,D=/(^-|-$)/g;function R$1(c){return c.replace(O,"-").replace(D,"")}var T=/(a)(d)/gi,k=52,j=function(c){return String.fromCharCode(c+(c>25?39:97))};function x(c){var a,d="";for(a=Math.abs(c);a>k;a=a/k|0)d=j(a%k)+d;return(j(a%k)+d).replace(T,"$1-$2")}var V,F=5381,M=function(c,a){for(var d=a.length;d;)c=33*c^a.charCodeAt(--d);return c},$=function(c){return M(F,c)};function z(c){return x($(c)>>>0)}function B(c){return c.displayName||c.name||"Component"}function L(c){return typeof c=="string"&&!0}var G$1=typeof Symbol=="function"&&Symbol.for,Y=G$1?Symbol.for("react.memo"):60115,W$6=G$1?Symbol.for("react.forward_ref"):60112,q={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},H={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},U={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},J=((V={})[W$6]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},V[Y]=U,V);function X(c){return("type"in(a=c)&&a.type.$$typeof)===Y?U:"$$typeof"in c?J[c.$$typeof]:q;var a}var Z=Object.defineProperty,K$5=Object.getOwnPropertyNames,Q=Object.getOwnPropertySymbols,ee=Object.getOwnPropertyDescriptor,te=Object.getPrototypeOf,ne=Object.prototype;function oe(c,a,d){if(typeof a!="string"){if(ne){var et=te(a);et&&et!==ne&&oe(c,et,d)}var nt=K$5(a);Q&&(nt=nt.concat(Q(a)));for(var tt=X(c),bt=X(a),mt=0;mt0?" Args: ".concat(a.join(", ")):""))}var fe=function(){function c(a){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=a}return c.prototype.indexOfGroup=function(a){for(var d=0,et=0;et=this.groupSizes.length){for(var et=this.groupSizes,nt=et.length,tt=nt;a>=tt;)if((tt<<=1)<0)throw he(16,"".concat(a));this.groupSizes=new Uint32Array(tt),this.groupSizes.set(et),this.length=tt;for(var bt=nt;bt=this.length||this.groupSizes[a]===0)return d;for(var et=this.groupSizes[a],nt=this.indexOfGroup(a),tt=nt+et,bt=nt;bt=0){var et=document.createTextNode(d);return this.element.insertBefore(et,this.nodes[a]||null),this.length++,!0}return!1},c.prototype.deleteRule=function(a){this.element.removeChild(this.nodes[a]),this.length--},c.prototype.getRule=function(a){return a0&&(Dt+="".concat(Nt,","))}),vt+="".concat(kt).concat(It,'{content:"').concat(Dt,'"}').concat(g$2)},At=0;At0?".".concat(a):Tt},At=vt.slice();At.push(function(Tt){Tt.type===RULESET&&Tt.value.includes("&")&&(Tt.props[0]=Tt.props[0].replace(ke,d).replace(et,$t))}),bt.prefix&&At.push(prefixer),At.push(stringify$2);var Mt=function(Tt,Rt,kt,It){Rt===void 0&&(Rt=""),kt===void 0&&(kt=""),It===void 0&&(It="&"),a=It,d=Rt,et=new RegExp("\\".concat(d,"\\b"),"g");var Dt=Tt.replace(je,""),Nt=compile(kt||Rt?"".concat(kt," ").concat(Rt," { ").concat(Dt," }"):Dt);bt.namespace&&(Nt=xe(Nt,bt.namespace));var Ot=[];return serialize$1(Nt,middleware(At.concat(rulesheet(function(Ut){return Ot.push(Ut)})))),Ot};return Mt.hash=vt.length?vt.reduce(function(Tt,Rt){return Rt.name||he(15),M(Tt,Rt.name)},F).toString():"",Mt}var Fe=new Te,Me=Ve(),$e=React.createContext({shouldForwardProp:void 0,styleSheet:Fe,stylis:Me});$e.Consumer;React.createContext(void 0);function Le(){return reactExports.useContext($e)}var Ye=function(){function c(a,d){var et=this;this.inject=function(nt,tt){tt===void 0&&(tt=Me);var bt=et.name+tt.hash;nt.hasNameForId(et.id,bt)||nt.insertRules(et.id,bt,tt(et.rules,bt,"@keyframes"))},this.name=a,this.id="sc-keyframes-".concat(a),this.rules=d,ue(this,function(){throw he(12,String(et.name))})}return c.prototype.getName=function(a){return a===void 0&&(a=Me),this.name+a.hash},c}(),We=function(c){return c>="A"&&c<="Z"};function qe(c){for(var a="",d=0;d>>0);if(!d.hasNameForId(this.componentId,bt)){var mt=et(tt,".".concat(bt),void 0,this.componentId);d.insertRules(this.componentId,bt,mt)}nt=ie(nt,bt),this.staticRulesId=bt}else{for(var vt=M(this.baseHash,et.hash),$t="",At=0;At>>0);d.hasNameForId(this.componentId,Rt)||d.insertRules(this.componentId,Rt,et($t,".".concat(Rt),void 0,this.componentId)),nt=ie(nt,Rt)}}return nt},c}(),Qe=React.createContext(void 0);Qe.Consumer;var ot={},rt=new Set;function st(c,a,d){var et=se(c),nt=c,tt=!L(c),bt=a.attrs,mt=bt===void 0?_:bt,vt=a.componentId,$t=vt===void 0?function(Gt,Wt){var Xt=typeof Gt!="string"?"sc":R$1(Gt);ot[Xt]=(ot[Xt]||0)+1;var a0="".concat(Xt,"-").concat(z(v+Xt+ot[Xt]));return Wt?"".concat(Wt,"-").concat(a0):a0}(a.displayName,a.parentComponentId):vt,At=a.displayName,Mt=At===void 0?function(Gt){return L(Gt)?"styled.".concat(Gt):"Styled(".concat(B(Gt),")")}(c):At,Tt=a.displayName&&a.componentId?"".concat(R$1(a.displayName),"-").concat(a.componentId):a.componentId||$t,Rt=et&&nt.attrs?nt.attrs.concat(mt).filter(Boolean):mt,kt=a.shouldForwardProp;if(et&&nt.shouldForwardProp){var It=nt.shouldForwardProp;if(a.shouldForwardProp){var Dt=a.shouldForwardProp;kt=function(Gt,Wt){return It(Gt,Wt)&&Dt(Gt,Wt)}}else kt=It}var Nt=new Ke(d,Tt,et?nt.componentStyle:void 0);function Ot(Gt,Wt){return function(Xt,a0,n0){var t0=Xt.attrs,c0=Xt.componentStyle,Ct=Xt.defaultProps,dt=Xt.foldedComponentIds,yt=Xt.styledComponentId,gt=Xt.target,xt=React.useContext(Qe),St=Le(),_t=Xt.shouldForwardProp||St.shouldForwardProp,Pt=I(a0,xt,Ct)||C,Et=function(Ft,Vt,zt){for(var qt,Kt=__assign(__assign({},Vt),{className:void 0,theme:zt}),e0=0;e0{const{children:a}=c;useMantineTheme();const{confirming:d,confirmed:et}=useLinkStore(nt=>nt);return jsxRuntimeExports.jsxs(StyledContainer,{children:[jsxRuntimeExports.jsx(Dialog,{position:{bottom:20,right:100},opened:d,withCloseButton:!0,size:"lg",radius:"md",style:{backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},children:jsxRuntimeExports.jsx(Notification,{withBorder:!1,withCloseButton:!1,style:{margin:10,backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},loading:!0,title:"Confirming the transaction",children:"Waiting for the transaction to get confirmed"})}),jsxRuntimeExports.jsx(Dialog,{position:{bottom:20,right:100},opened:et,withCloseButton:!0,size:"lg",radius:"md",style:{backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},children:jsxRuntimeExports.jsx(Notification,{withBorder:!1,withCloseButton:!1,style:{margin:10,backgroundColor:"light-dark(var(--mantine-color-black),var(--mantine-color-white));"},title:"Transaction confirmed!",children:"Transaction has been confirmed now"})}),a]})};/** + * @remix-run/router v1.16.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function _extends$1(){return _extends$1=Object.assign?Object.assign.bind():function(c){for(var a=1;a"u")throw new Error(a)}function warning(c,a){if(!c){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function createKey(){return Math.random().toString(36).substr(2,8)}function getHistoryState(c,a){return{usr:c.state,key:c.key,idx:a}}function createLocation(c,a,d,et){return d===void 0&&(d=null),_extends$1({pathname:typeof c=="string"?c:c.pathname,search:"",hash:""},typeof a=="string"?parsePath(a):a,{state:d,key:a&&a.key||et||createKey()})}function createPath(c){let{pathname:a="/",search:d="",hash:et=""}=c;return d&&d!=="?"&&(a+=d.charAt(0)==="?"?d:"?"+d),et&&et!=="#"&&(a+=et.charAt(0)==="#"?et:"#"+et),a}function parsePath(c){let a={};if(c){let d=c.indexOf("#");d>=0&&(a.hash=c.substr(d),c=c.substr(0,d));let et=c.indexOf("?");et>=0&&(a.search=c.substr(et),c=c.substr(0,et)),c&&(a.pathname=c)}return a}function getUrlBasedHistory(c,a,d,et){et===void 0&&(et={});let{window:nt=document.defaultView,v5Compat:tt=!1}=et,bt=nt.history,mt=Action.Pop,vt=null,$t=At();$t==null&&($t=0,bt.replaceState(_extends$1({},bt.state,{idx:$t}),""));function At(){return(bt.state||{idx:null}).idx}function Mt(){mt=Action.Pop;let Dt=At(),Nt=Dt==null?null:Dt-$t;$t=Dt,vt&&vt({action:mt,location:It.location,delta:Nt})}function Tt(Dt,Nt){mt=Action.Push;let Ot=createLocation(It.location,Dt,Nt);d&&d(Ot,Dt),$t=At()+1;let Ut=getHistoryState(Ot,$t),Gt=It.createHref(Ot);try{bt.pushState(Ut,"",Gt)}catch(Wt){if(Wt instanceof DOMException&&Wt.name==="DataCloneError")throw Wt;nt.location.assign(Gt)}tt&&vt&&vt({action:mt,location:It.location,delta:1})}function Rt(Dt,Nt){mt=Action.Replace;let Ot=createLocation(It.location,Dt,Nt);d&&d(Ot,Dt),$t=At();let Ut=getHistoryState(Ot,$t),Gt=It.createHref(Ot);bt.replaceState(Ut,"",Gt),tt&&vt&&vt({action:mt,location:It.location,delta:0})}function kt(Dt){let Nt=nt.location.origin!=="null"?nt.location.origin:nt.location.href,Ot=typeof Dt=="string"?Dt:createPath(Dt);return Ot=Ot.replace(/ $/,"%20"),invariant(Nt,"No window.location.(origin|href) available to create URL for href: "+Ot),new URL(Ot,Nt)}let It={get action(){return mt},get location(){return c(nt,bt)},listen(Dt){if(vt)throw new Error("A history only accepts one active listener");return nt.addEventListener(PopStateEventType,Mt),vt=Dt,()=>{nt.removeEventListener(PopStateEventType,Mt),vt=null}},createHref(Dt){return a(nt,Dt)},createURL:kt,encodeLocation(Dt){let Nt=kt(Dt);return{pathname:Nt.pathname,search:Nt.search,hash:Nt.hash}},push:Tt,replace:Rt,go(Dt){return bt.go(Dt)}};return It}var ResultType;(function(c){c.data="data",c.deferred="deferred",c.redirect="redirect",c.error="error"})(ResultType||(ResultType={}));function matchRoutes(c,a,d){d===void 0&&(d="/");let et=typeof a=="string"?parsePath(a):a,nt=stripBasename(et.pathname||"/",d);if(nt==null)return null;let tt=flattenRoutes(c);rankRouteBranches(tt);let bt=null;for(let mt=0;bt==null&&mt{let vt={relativePath:mt===void 0?tt.path||"":mt,caseSensitive:tt.caseSensitive===!0,childrenIndex:bt,route:tt};vt.relativePath.startsWith("/")&&(invariant(vt.relativePath.startsWith(et),'Absolute route path "'+vt.relativePath+'" nested under path '+('"'+et+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),vt.relativePath=vt.relativePath.slice(et.length));let $t=joinPaths([et,vt.relativePath]),At=d.concat(vt);tt.children&&tt.children.length>0&&(invariant(tt.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+$t+'".')),flattenRoutes(tt.children,a,At,$t)),!(tt.path==null&&!tt.index)&&a.push({path:$t,score:computeScore($t,tt.index),routesMeta:At})};return c.forEach((tt,bt)=>{var mt;if(tt.path===""||!((mt=tt.path)!=null&&mt.includes("?")))nt(tt,bt);else for(let vt of explodeOptionalSegments(tt.path))nt(tt,bt,vt)}),a}function explodeOptionalSegments(c){let a=c.split("/");if(a.length===0)return[];let[d,...et]=a,nt=d.endsWith("?"),tt=d.replace(/\?$/,"");if(et.length===0)return nt?[tt,""]:[tt];let bt=explodeOptionalSegments(et.join("/")),mt=[];return mt.push(...bt.map(vt=>vt===""?tt:[tt,vt].join("/"))),nt&&mt.push(...bt),mt.map(vt=>c.startsWith("/")&&vt===""?"/":vt)}function rankRouteBranches(c){c.sort((a,d)=>a.score!==d.score?d.score-a.score:compareIndexes(a.routesMeta.map(et=>et.childrenIndex),d.routesMeta.map(et=>et.childrenIndex)))}const paramRe=/^:[\w-]+$/,dynamicSegmentValue=3,indexRouteValue=2,emptySegmentValue=1,staticSegmentValue=10,splatPenalty=-2,isSplat=c=>c==="*";function computeScore(c,a){let d=c.split("/"),et=d.length;return d.some(isSplat)&&(et+=splatPenalty),a&&(et+=indexRouteValue),d.filter(nt=>!isSplat(nt)).reduce((nt,tt)=>nt+(paramRe.test(tt)?dynamicSegmentValue:tt===""?emptySegmentValue:staticSegmentValue),et)}function compareIndexes(c,a){return c.length===a.length&&c.slice(0,-1).every((et,nt)=>et===a[nt])?c[c.length-1]-a[a.length-1]:0}function matchRouteBranch(c,a){let{routesMeta:d}=c,et={},nt="/",tt=[];for(let bt=0;bt{let{paramName:Tt,isOptional:Rt}=At;if(Tt==="*"){let It=mt[Mt]||"";bt=tt.slice(0,tt.length-It.length).replace(/(.)\/+$/,"$1")}const kt=mt[Mt];return Rt&&!kt?$t[Tt]=void 0:$t[Tt]=(kt||"").replace(/%2F/g,"/"),$t},{}),pathname:tt,pathnameBase:bt,pattern:c}}function compilePath(c,a,d){a===void 0&&(a=!1),d===void 0&&(d=!0),warning(c==="*"||!c.endsWith("*")||c.endsWith("/*"),'Route path "'+c+'" will be treated as if it were '+('"'+c.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+c.replace(/\*$/,"/*")+'".'));let et=[],nt="^"+c.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(bt,mt,vt)=>(et.push({paramName:mt,isOptional:vt!=null}),vt?"/?([^\\/]+)?":"/([^\\/]+)"));return c.endsWith("*")?(et.push({paramName:"*"}),nt+=c==="*"||c==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):d?nt+="\\/*$":c!==""&&c!=="/"&&(nt+="(?:(?=\\/|$))"),[new RegExp(nt,a?void 0:"i"),et]}function decodePath(c){try{return c.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return warning(!1,'The URL path "'+c+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+a+").")),c}}function stripBasename(c,a){if(a==="/")return c;if(!c.toLowerCase().startsWith(a.toLowerCase()))return null;let d=a.endsWith("/")?a.length-1:a.length,et=c.charAt(d);return et&&et!=="/"?null:c.slice(d)||"/"}function resolvePath(c,a){a===void 0&&(a="/");let{pathname:d,search:et="",hash:nt=""}=typeof c=="string"?parsePath(c):c;return{pathname:d?d.startsWith("/")?d:resolvePathname(d,a):a,search:normalizeSearch(et),hash:normalizeHash(nt)}}function resolvePathname(c,a){let d=a.replace(/\/+$/,"").split("/");return c.split("/").forEach(nt=>{nt===".."?d.length>1&&d.pop():nt!=="."&&d.push(nt)}),d.length>1?d.join("/"):"/"}function getInvalidPathError(c,a,d,et){return"Cannot include a '"+c+"' character in a manually specified "+("`to."+a+"` field ["+JSON.stringify(et)+"]. Please separate it out to the ")+("`to."+d+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function getPathContributingMatches(c){return c.filter((a,d)=>d===0||a.route.path&&a.route.path.length>0)}function getResolveToMatches(c,a){let d=getPathContributingMatches(c);return a?d.map((et,nt)=>nt===c.length-1?et.pathname:et.pathnameBase):d.map(et=>et.pathnameBase)}function resolveTo(c,a,d,et){et===void 0&&(et=!1);let nt;typeof c=="string"?nt=parsePath(c):(nt=_extends$1({},c),invariant(!nt.pathname||!nt.pathname.includes("?"),getInvalidPathError("?","pathname","search",nt)),invariant(!nt.pathname||!nt.pathname.includes("#"),getInvalidPathError("#","pathname","hash",nt)),invariant(!nt.search||!nt.search.includes("#"),getInvalidPathError("#","search","hash",nt)));let tt=c===""||nt.pathname==="",bt=tt?"/":nt.pathname,mt;if(bt==null)mt=d;else{let Mt=a.length-1;if(!et&&bt.startsWith("..")){let Tt=bt.split("/");for(;Tt[0]==="..";)Tt.shift(),Mt-=1;nt.pathname=Tt.join("/")}mt=Mt>=0?a[Mt]:"/"}let vt=resolvePath(nt,mt),$t=bt&&bt!=="/"&&bt.endsWith("/"),At=(tt||bt===".")&&d.endsWith("/");return!vt.pathname.endsWith("/")&&($t||At)&&(vt.pathname+="/"),vt}const joinPaths=c=>c.join("/").replace(/\/\/+/g,"/"),normalizePathname=c=>c.replace(/\/+$/,"").replace(/^\/*/,"/"),normalizeSearch=c=>!c||c==="?"?"":c.startsWith("?")?c:"?"+c,normalizeHash=c=>!c||c==="#"?"":c.startsWith("#")?c:"#"+c;function isRouteErrorResponse(c){return c!=null&&typeof c.status=="number"&&typeof c.statusText=="string"&&typeof c.internal=="boolean"&&"data"in c}const validMutationMethodsArr=["post","put","patch","delete"];new Set(validMutationMethodsArr);const validRequestMethodsArr=["get",...validMutationMethodsArr];new Set(validRequestMethodsArr);/** + * React Router v6.23.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function _extends(){return _extends=Object.assign?Object.assign.bind():function(c){for(var a=1;a{mt.current=!0}),reactExports.useCallback(function($t,At){if(At===void 0&&(At={}),!mt.current)return;if(typeof $t=="number"){et.go($t);return}let Mt=resolveTo($t,JSON.parse(bt),tt,At.relative==="path");c==null&&a!=="/"&&(Mt.pathname=Mt.pathname==="/"?a:joinPaths([a,Mt.pathname])),(At.replace?et.replace:et.push)(Mt,At.state,At)},[a,et,bt,tt,c])}function useRoutes(c,a){return useRoutesImpl(c,a)}function useRoutesImpl(c,a,d,et){useInRouterContext()||invariant(!1);let{navigator:nt}=reactExports.useContext(NavigationContext),{matches:tt}=reactExports.useContext(RouteContext),bt=tt[tt.length-1],mt=bt?bt.params:{};bt&&bt.pathname;let vt=bt?bt.pathnameBase:"/";bt&&bt.route;let $t=useLocation(),At;if(a){var Mt;let Dt=typeof a=="string"?parsePath(a):a;vt==="/"||(Mt=Dt.pathname)!=null&&Mt.startsWith(vt)||invariant(!1),At=Dt}else At=$t;let Tt=At.pathname||"/",Rt=Tt;if(vt!=="/"){let Dt=vt.replace(/^\//,"").split("/");Rt="/"+Tt.replace(/^\//,"").split("/").slice(Dt.length).join("/")}let kt=matchRoutes(c,{pathname:Rt}),It=_renderMatches(kt&&kt.map(Dt=>Object.assign({},Dt,{params:Object.assign({},mt,Dt.params),pathname:joinPaths([vt,nt.encodeLocation?nt.encodeLocation(Dt.pathname).pathname:Dt.pathname]),pathnameBase:Dt.pathnameBase==="/"?vt:joinPaths([vt,nt.encodeLocation?nt.encodeLocation(Dt.pathnameBase).pathname:Dt.pathnameBase])})),tt,d,et);return a&&It?reactExports.createElement(LocationContext.Provider,{value:{location:_extends({pathname:"/",search:"",hash:"",state:null,key:"default"},At),navigationType:Action.Pop}},It):It}function DefaultErrorComponent(){let c=useRouteError(),a=isRouteErrorResponse(c)?c.status+" "+c.statusText:c instanceof Error?c.message:JSON.stringify(c),d=c instanceof Error?c.stack:null,nt={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},tt=null;return reactExports.createElement(reactExports.Fragment,null,reactExports.createElement("h2",null,"Unexpected Application Error!"),reactExports.createElement("h3",{style:{fontStyle:"italic"}},a),d?reactExports.createElement("pre",{style:nt},d):null,tt)}const defaultErrorElement=reactExports.createElement(DefaultErrorComponent,null);class RenderErrorBoundary extends reactExports.Component{constructor(a){super(a),this.state={location:a.location,revalidation:a.revalidation,error:a.error}}static getDerivedStateFromError(a){return{error:a}}static getDerivedStateFromProps(a,d){return d.location!==a.location||d.revalidation!=="idle"&&a.revalidation==="idle"?{error:a.error,location:a.location,revalidation:a.revalidation}:{error:a.error!==void 0?a.error:d.error,location:d.location,revalidation:a.revalidation||d.revalidation}}componentDidCatch(a,d){console.error("React Router caught the following error during render",a,d)}render(){return this.state.error!==void 0?reactExports.createElement(RouteContext.Provider,{value:this.props.routeContext},reactExports.createElement(RouteErrorContext.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function RenderedRoute(c){let{routeContext:a,match:d,children:et}=c,nt=reactExports.useContext(DataRouterContext);return nt&&nt.static&&nt.staticContext&&(d.route.errorElement||d.route.ErrorBoundary)&&(nt.staticContext._deepestRenderedBoundaryId=d.route.id),reactExports.createElement(RouteContext.Provider,{value:a},et)}function _renderMatches(c,a,d,et){var nt;if(a===void 0&&(a=[]),d===void 0&&(d=null),et===void 0&&(et=null),c==null){var tt;if((tt=d)!=null&&tt.errors)c=d.matches;else return null}let bt=c,mt=(nt=d)==null?void 0:nt.errors;if(mt!=null){let At=bt.findIndex(Mt=>Mt.route.id&&(mt==null?void 0:mt[Mt.route.id])!==void 0);At>=0||invariant(!1),bt=bt.slice(0,Math.min(bt.length,At+1))}let vt=!1,$t=-1;if(d&&et&&et.v7_partialHydration)for(let At=0;At=0?bt=bt.slice(0,$t+1):bt=[bt[0]];break}}}return bt.reduceRight((At,Mt,Tt)=>{let Rt,kt=!1,It=null,Dt=null;d&&(Rt=mt&&Mt.route.id?mt[Mt.route.id]:void 0,It=Mt.route.errorElement||defaultErrorElement,vt&&($t<0&&Tt===0?(warningOnce("route-fallback",!1),kt=!0,Dt=null):$t===Tt&&(kt=!0,Dt=Mt.route.hydrateFallbackElement||null)));let Nt=a.concat(bt.slice(0,Tt+1)),Ot=()=>{let Ut;return Rt?Ut=It:kt?Ut=Dt:Mt.route.Component?Ut=reactExports.createElement(Mt.route.Component,null):Mt.route.element?Ut=Mt.route.element:Ut=At,reactExports.createElement(RenderedRoute,{match:Mt,routeContext:{outlet:At,matches:Nt,isDataRoute:d!=null},children:Ut})};return d&&(Mt.route.ErrorBoundary||Mt.route.errorElement||Tt===0)?reactExports.createElement(RenderErrorBoundary,{location:d.location,revalidation:d.revalidation,component:It,error:Rt,children:Ot(),routeContext:{outlet:null,matches:Nt,isDataRoute:!0}}):Ot()},null)}var DataRouterHook$1=function(c){return c.UseBlocker="useBlocker",c.UseRevalidator="useRevalidator",c.UseNavigateStable="useNavigate",c}(DataRouterHook$1||{}),DataRouterStateHook$1=function(c){return c.UseBlocker="useBlocker",c.UseLoaderData="useLoaderData",c.UseActionData="useActionData",c.UseRouteError="useRouteError",c.UseNavigation="useNavigation",c.UseRouteLoaderData="useRouteLoaderData",c.UseMatches="useMatches",c.UseRevalidator="useRevalidator",c.UseNavigateStable="useNavigate",c.UseRouteId="useRouteId",c}(DataRouterStateHook$1||{});function useDataRouterContext(c){let a=reactExports.useContext(DataRouterContext);return a||invariant(!1),a}function useDataRouterState(c){let a=reactExports.useContext(DataRouterStateContext);return a||invariant(!1),a}function useRouteContext(c){let a=reactExports.useContext(RouteContext);return a||invariant(!1),a}function useCurrentRouteId(c){let a=useRouteContext(),d=a.matches[a.matches.length-1];return d.route.id||invariant(!1),d.route.id}function useRouteError(){var c;let a=reactExports.useContext(RouteErrorContext),d=useDataRouterState(DataRouterStateHook$1.UseRouteError),et=useCurrentRouteId(DataRouterStateHook$1.UseRouteError);return a!==void 0?a:(c=d.errors)==null?void 0:c[et]}function useNavigateStable(){let{router:c}=useDataRouterContext(DataRouterHook$1.UseNavigateStable),a=useCurrentRouteId(DataRouterStateHook$1.UseNavigateStable),d=reactExports.useRef(!1);return useIsomorphicLayoutEffect(()=>{d.current=!0}),reactExports.useCallback(function(nt,tt){tt===void 0&&(tt={}),d.current&&(typeof nt=="number"?c.navigate(nt):c.navigate(nt,_extends({fromRouteId:a},tt)))},[c,a])}const alreadyWarned={};function warningOnce(c,a,d){!a&&!alreadyWarned[c]&&(alreadyWarned[c]=!0)}function Route(c){invariant(!1)}function Router(c){let{basename:a="/",children:d=null,location:et,navigationType:nt=Action.Pop,navigator:tt,static:bt=!1,future:mt}=c;useInRouterContext()&&invariant(!1);let vt=a.replace(/^\/*/,"/"),$t=reactExports.useMemo(()=>({basename:vt,navigator:tt,static:bt,future:_extends({v7_relativeSplatPath:!1},mt)}),[vt,mt,tt,bt]);typeof et=="string"&&(et=parsePath(et));let{pathname:At="/",search:Mt="",hash:Tt="",state:Rt=null,key:kt="default"}=et,It=reactExports.useMemo(()=>{let Dt=stripBasename(At,vt);return Dt==null?null:{location:{pathname:Dt,search:Mt,hash:Tt,state:Rt,key:kt},navigationType:nt}},[vt,At,Mt,Tt,Rt,kt,nt]);return It==null?null:reactExports.createElement(NavigationContext.Provider,{value:$t},reactExports.createElement(LocationContext.Provider,{children:d,value:It}))}function Routes(c){let{children:a,location:d}=c;return useRoutes(createRoutesFromChildren(a),d)}new Promise(()=>{});function createRoutesFromChildren(c,a){a===void 0&&(a=[]);let d=[];return reactExports.Children.forEach(c,(et,nt)=>{if(!reactExports.isValidElement(et))return;let tt=[...a,nt];if(et.type===reactExports.Fragment){d.push.apply(d,createRoutesFromChildren(et.props.children,tt));return}et.type!==Route&&invariant(!1),!et.props.index||!et.props.children||invariant(!1);let bt={id:et.props.id||tt.join("-"),caseSensitive:et.props.caseSensitive,element:et.props.element,Component:et.props.Component,index:et.props.index,path:et.props.path,loader:et.props.loader,action:et.props.action,errorElement:et.props.errorElement,ErrorBoundary:et.props.ErrorBoundary,hasErrorBoundary:et.props.ErrorBoundary!=null||et.props.errorElement!=null,shouldRevalidate:et.props.shouldRevalidate,handle:et.props.handle,lazy:et.props.lazy};et.props.children&&(bt.children=createRoutesFromChildren(et.props.children,tt)),d.push(bt)}),d}/** + * React Router DOM v6.23.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function createSearchParams(c){return c===void 0&&(c=""),new URLSearchParams(typeof c=="string"||Array.isArray(c)||c instanceof URLSearchParams?c:Object.keys(c).reduce((a,d)=>{let et=c[d];return a.concat(Array.isArray(et)?et.map(nt=>[d,nt]):[[d,et]])},[]))}function getSearchParamsForLocation(c,a){let d=createSearchParams(c);return a&&a.forEach((et,nt)=>{d.has(nt)||a.getAll(nt).forEach(tt=>{d.append(nt,tt)})}),d}const REACT_ROUTER_VERSION="6";try{window.__reactRouterVersion=REACT_ROUTER_VERSION}catch{}const START_TRANSITION="startTransition",startTransitionImpl=React$1[START_TRANSITION];function HashRouter(c){let{basename:a,children:d,future:et,window:nt}=c,tt=reactExports.useRef();tt.current==null&&(tt.current=createHashHistory({window:nt,v5Compat:!0}));let bt=tt.current,[mt,vt]=reactExports.useState({action:bt.action,location:bt.location}),{v7_startTransition:$t}=et||{},At=reactExports.useCallback(Mt=>{$t&&startTransitionImpl?startTransitionImpl(()=>vt(Mt)):vt(Mt)},[vt,$t]);return reactExports.useLayoutEffect(()=>bt.listen(At),[bt,At]),reactExports.createElement(Router,{basename:a,children:d,location:mt.location,navigationType:mt.action,navigator:bt,future:et})}var DataRouterHook;(function(c){c.UseScrollRestoration="useScrollRestoration",c.UseSubmit="useSubmit",c.UseSubmitFetcher="useSubmitFetcher",c.UseFetcher="useFetcher",c.useViewTransitionState="useViewTransitionState"})(DataRouterHook||(DataRouterHook={}));var DataRouterStateHook;(function(c){c.UseFetcher="useFetcher",c.UseFetchers="useFetchers",c.UseScrollRestoration="useScrollRestoration"})(DataRouterStateHook||(DataRouterStateHook={}));function useSearchParams(c){let a=reactExports.useRef(createSearchParams(c)),d=reactExports.useRef(!1),et=useLocation(),nt=reactExports.useMemo(()=>getSearchParamsForLocation(et.search,d.current?null:a.current),[et.search]),tt=useNavigate(),bt=reactExports.useCallback((mt,vt)=>{const $t=createSearchParams(typeof mt=="function"?mt(nt):mt);d.current=!0,tt("?"+$t,vt)},[tt,nt]);return[nt,bt]}function t(){return t=Object.assign?Object.assign.bind():function(c){for(var a=1;a=0||(At[vt]=bt[vt]);return At}(c,a);if(Object.getOwnPropertySymbols){var tt=Object.getOwnPropertySymbols(c);for(et=0;et=0||Object.prototype.propertyIsEnumerable.call(c,d)&&(nt[d]=c[d])}return nt}var Ig=["size","color","stroke"];function Ag(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,Ig);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-brand-github",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("path",{d:"M9 19c-4.3 1.4 -4.3 -2.5 -6 -3m12 5v-3.5c0 -1 .1 -1.4 -.5 -2c2.8 -.3 5.5 -1.4 5.5 -6a4.6 4.6 0 0 0 -1.3 -3.2a4.2 4.2 0 0 0 -.1 -3.2s-1.1 -.3 -3.5 1.3a12.3 12.3 0 0 0 -6.2 0c-2.4 -1.6 -3.5 -1.3 -3.5 -1.3a4.2 4.2 0 0 0 -.1 3.2a4.6 4.6 0 0 0 -1.3 3.2c0 4.6 2.7 5.7 5.5 6c-.6 .6 -.6 1.2 -.5 2v3.5"}))}var WC=["size","color","stroke"];function qC(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,WC);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-bug",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("path",{d:"M9 9v-1a3 3 0 0 1 6 0v1"}),reactExports.createElement("path",{d:"M8 9h8a6 6 0 0 1 1 3v3a5 5 0 0 1 -10 0v-3a6 6 0 0 1 1 -3"}),reactExports.createElement("line",{x1:3,y1:13,x2:7,y2:13}),reactExports.createElement("line",{x1:17,y1:13,x2:21,y2:13}),reactExports.createElement("line",{x1:12,y1:20,x2:12,y2:14}),reactExports.createElement("line",{x1:4,y1:19,x2:7.35,y2:17}),reactExports.createElement("line",{x1:20,y1:19,x2:16.65,y2:17}),reactExports.createElement("line",{x1:4,y1:7,x2:7.75,y2:9.4}),reactExports.createElement("line",{x1:20,y1:7,x2:16.25,y2:9.4}))}var JD=["size","color","stroke"];function KD(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,JD);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-coin",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("circle",{cx:12,cy:12,r:9}),reactExports.createElement("path",{d:"M14.8 9a2 2 0 0 0 -1.8 -1h-2a2 2 0 1 0 0 4h2a2 2 0 1 1 0 4h-2a2 2 0 0 1 -1.8 -1"}),reactExports.createElement("path",{d:"M12 7v10"}))}var WF=["size","color","stroke"];function qF(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,WF);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-confetti",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("path",{d:"M4 5h2"}),reactExports.createElement("path",{d:"M5 4v2"}),reactExports.createElement("path",{d:"M11.5 4l-.5 2"}),reactExports.createElement("path",{d:"M18 5h2"}),reactExports.createElement("path",{d:"M19 4v2"}),reactExports.createElement("path",{d:"M15 9l-1 1"}),reactExports.createElement("path",{d:"M18 13l2 -.5"}),reactExports.createElement("path",{d:"M18 19h2"}),reactExports.createElement("path",{d:"M19 18v2"}),reactExports.createElement("path",{d:"M14 16.518l-6.518 -6.518l-4.39 9.58a1.003 1.003 0 0 0 1.329 1.329l9.579 -4.39z"}))}var Fme=["size","color","stroke"];function Gme(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,Fme);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-moon-stars",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("path",{d:"M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454z"}),reactExports.createElement("path",{d:"M17 4a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"}),reactExports.createElement("path",{d:"M19 11h2m-1 -1v2"}))}var pAe=["size","color","stroke"];function EAe(c){var a=c.size,d=a===void 0?24:a,et=c.color,nt=et===void 0?"currentColor":et,tt=c.stroke,bt=tt===void 0?2:tt,mt=o(c,pAe);return reactExports.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",className:"icon icon-tabler icon-tabler-sun",width:d,height:d,viewBox:"0 0 24 24",strokeWidth:bt,stroke:nt,fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},mt),reactExports.createElement("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),reactExports.createElement("circle",{cx:12,cy:12,r:4}),reactExports.createElement("path",{d:"M3 12h1m8 -9v1m8 8h1m-9 8v1m-6.4 -15.4l.7 .7m12.1 -.7l-.7 .7m0 11.4l.7 .7m-12.1 -.7l-.7 .7"}))}const LogoLight="/assets/logo-light-4eedbe0d.svg",LogoDark="/assets/logo-dark-a42ec370.svg",Base$9="/assets/base-8a61917f.png",ETH="/assets/eth-dc2fb7da.svg";var RoutePath=(c=>(c.home="/",c.claim="/claim",c.account="/account",c.notFound="*",c))(RoutePath||{});const INFURA_API_KEY="05d830413c5a4ac8873c84319679c7b2",ETHERSCAN_API_KEY="H8IGZCCS8XCJYSXIA3GUUKW6CDECYYMNPG",POLYGONSCAN_API_KEY="GVZS4QAMWFBGS5PK2BR76FNFPJ7X2GR44I",accountAddress="",networks={localhost:{name:"Local Chain",chainId:31337,type:"Testnet",url:"http://localhost:8545",safeService:"",blockExplorer:"",api:"",easExplorer:""},mainnet:{name:"Ethereum",type:"mainnet",chainId:1,url:`https://mainnet.infura.io/v3/${INFURA_API_KEY}`,safeService:"https://safe-transaction-mainnet.safe.global",blockExplorer:"https://etherscan.io",api:`https://api.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:""},goerli:{name:"Goerli",type:"testnet",chainId:5,url:`https://goerli.infura.io/v3/${INFURA_API_KEY}`,safeService:"https://safe-transaction-goerli.safe.global",blockExplorer:"https://goerli.etherscan.io",api:`https://api-goerli.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:""},sepolia:{name:"Sepolia",type:"testnet",chainId:11155111,url:"https://eth-sepolia.g.alchemy.com/v2/eCr9bFDzgYgDrox-mnXPPh7_koP-agKo",safeService:"https://safe-transaction-sepolia.safe.global",blockExplorer:"https://sepolia.etherscan.io",api:`https://api-sepolia.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:""},basesepolia:{name:"Base Sepolia",type:"testnet",chainId:84532,url:"https://base-sepolia.g.alchemy.com/v2/wRVILABVfp0WrfAv449B23mIW_SJqOwL",blockExplorer:"https://sepolia.basescan.org",safeService:"https://safe-transaction-base-sepolia.safe.global",api:`https://api-sepolia.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:"https://base-sepolia.easscan.org/attestation/view/"},base:{name:"Base",type:"mainnet",chainId:8453,url:"https://base-mainnet.g.alchemy.com/v2/NTGkSXMuKkoHwQ_W4eNpGlihUScplXYV",blockExplorer:"https://basescan.org",safeService:"https://safe-transaction-base.safe.global",api:`https://api-goerli.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:""},optimism:{name:"Optimism",type:"mainnet",chainId:10,url:`https://optimism-mainnet.infura.io/v3/${INFURA_API_KEY}`,blockExplorer:"https://optimistic.etherscan.io",safeService:"https://safe-transaction-optimism.safe.global",api:`https://api-optimistic.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:"https://optimism.easscan.org/attestation/view/"},gnosis:{name:"Gnosis",type:"mainnet",chainId:100,url:"https://rpc.ankr.com/gnosis",safeService:"https://safe-transaction-gnosis-chain.safe.global",blockExplorer:"https://gnosisscan.io",api:`https://api-goerli.etherscan.io/api?apikey=${ETHERSCAN_API_KEY}`,easExplorer:""},polygontestnet:{name:"Polygon",type:"testnet",chainId:80001,url:"https://matic-mumbai.chainstacklabs.com",safeService:"",blockExplorer:"https://mumbai.polygonscan.com",api:`https://api-testnet.polygonscan.com/api?module=account&action=balance&address=${accountAddress}&apikey=${POLYGONSCAN_API_KEY}`,easExplorer:""},polygon:{name:"Polygon",type:"mainnet",chainId:137,url:"https://rpc.ankr.com/polygon",safeService:"https://safe-transaction-polygon.safe.global",blockExplorer:"https://polygonscan.com",api:"",easExplorer:""},celo:{name:"Celo",type:"mainnet",chainId:42220,url:`https://celo-mainnet.infura.io/v3/${INFURA_API_KEY}`,safeService:"https://safe-transaction-polygon.safe.global",blockExplorer:"https://celoscan.com",api:"",easExplorer:""}};class NetworkUtil{static getNetworkById(a){return Object.values(networks).find(et=>a===et.chainId)}static getNetworkByName(a){return networks[a]}}const version$m="6.7.1";function checkType(c,a,d){const et=a.split("|").map(tt=>tt.trim());for(let tt=0;ttPromise.resolve(c[et])))).reduce((et,nt,tt)=>(et[a[tt]]=nt,et),{})}function defineProperties(c,a,d){for(let et in a){let nt=a[et];const tt=d?d[et]:null;tt&&checkType(nt,tt,et),Object.defineProperty(c,et,{enumerable:!0,value:nt,writable:!1})}}function stringify$1(c){if(c==null)return"null";if(Array.isArray(c))return"[ "+c.map(stringify$1).join(", ")+" ]";if(c instanceof Uint8Array){const a="0123456789abcdef";let d="0x";for(let et=0;et>4],d+=a[c[et]&15];return d}if(typeof c=="object"&&typeof c.toJSON=="function")return stringify$1(c.toJSON());switch(typeof c){case"boolean":case"symbol":return c.toString();case"bigint":return BigInt(c).toString();case"number":return c.toString();case"string":return JSON.stringify(c);case"object":{const a=Object.keys(c);return a.sort(),"{ "+a.map(d=>`${stringify$1(d)}: ${stringify$1(c[d])}`).join(", ")+" }"}}return"[ COULD NOT SERIALIZE ]"}function isError$1(c,a){return c&&c.code===a}function isCallException(c){return isError$1(c,"CALL_EXCEPTION")}function makeError(c,a,d){{const nt=[];if(d){if("message"in d||"code"in d||"name"in d)throw new Error(`value will overwrite populated values: ${stringify$1(d)}`);for(const tt in d){const bt=d[tt];nt.push(tt+"="+stringify$1(bt))}}nt.push(`code=${a}`),nt.push(`version=${version$m}`),nt.length&&(c+=" ("+nt.join(", ")+")")}let et;switch(a){case"INVALID_ARGUMENT":et=new TypeError(c);break;case"NUMERIC_FAULT":case"BUFFER_OVERRUN":et=new RangeError(c);break;default:et=new Error(c)}return defineProperties(et,{code:a}),d&&Object.assign(et,d),et}function assert$y(c,a,d,et){if(!c)throw makeError(a,d,et)}function assertArgument(c,a,d,et){assert$y(c,a,"INVALID_ARGUMENT",{argument:d,value:et})}function assertArgumentCount(c,a,d){d==null&&(d=""),d&&(d=": "+d),assert$y(c>=a,"missing arguemnt"+d,"MISSING_ARGUMENT",{count:c,expectedCount:a}),assert$y(c<=a,"too many arguemnts"+d,"UNEXPECTED_ARGUMENT",{count:c,expectedCount:a})}const _normalizeForms=["NFD","NFC","NFKD","NFKC"].reduce((c,a)=>{try{if("test".normalize(a)!=="test")throw new Error("bad");if(a==="NFD"){const d=String.fromCharCode(233).normalize("NFD"),et=String.fromCharCode(101,769);if(d!==et)throw new Error("broken")}c.push(a)}catch{}return c},[]);function assertNormalize(c){assert$y(_normalizeForms.indexOf(c)>=0,"platform missing String.prototype.normalize","UNSUPPORTED_OPERATION",{operation:"String.prototype.normalize",info:{form:c}})}function assertPrivate(c,a,d){if(d==null&&(d=""),c!==a){let et=d,nt="new";d&&(et+=".",nt+=" "+d),assert$y(!1,`private constructor; use ${et}from* methods`,"UNSUPPORTED_OPERATION",{operation:nt})}}function _getBytes(c,a,d){if(c instanceof Uint8Array)return d?new Uint8Array(c):c;if(typeof c=="string"&&c.match(/^0x([0-9a-f][0-9a-f])*$/i)){const et=new Uint8Array((c.length-2)/2);let nt=2;for(let tt=0;tt>4]+HexCharacters$1[nt&15]}return d}function concat$3(c){return"0x"+c.map(a=>hexlify$1(a).substring(2)).join("")}function dataLength(c){return isHexString$1(c,!0)?(c.length-2)/2:getBytes(c).length}function dataSlice(c,a,d){const et=getBytes(c);return d!=null&&d>et.length&&assert$y(!1,"cannot slice beyond data bounds","BUFFER_OVERRUN",{buffer:et,length:et.length,offset:d}),hexlify$1(et.slice(a??0,d??et.length))}function zeroPad$1(c,a,d){const et=getBytes(c);assert$y(a>=et.length,"padding exceeds data length","BUFFER_OVERRUN",{buffer:new Uint8Array(et),length:a,offset:a+1});const nt=new Uint8Array(a);return nt.fill(0),d?nt.set(et,a-et.length):nt.set(et,0),hexlify$1(nt)}function zeroPadValue(c,a){return zeroPad$1(c,a,!0)}function zeroPadBytes(c,a){return zeroPad$1(c,a,!1)}const BN_0$9=BigInt(0),BN_1$4=BigInt(1),maxValue=9007199254740991;function fromTwos(c,a){const d=getUint(c,"value"),et=BigInt(getNumber(a,"width"));if(assert$y(d>>et===BN_0$9,"overflow","NUMERIC_FAULT",{operation:"fromTwos",fault:"overflow",value:c}),d>>et-BN_1$4){const nt=(BN_1$4<=-maxValue&&c<=maxValue,"overflow",a||"value",c),BigInt(c);case"string":try{if(c==="")throw new Error("empty string");return c[0]==="-"&&c[1]!=="-"?-BigInt(c.substring(1)):BigInt(c)}catch(d){assertArgument(!1,`invalid BigNumberish string: ${d.message}`,a||"value",c)}}assertArgument(!1,"invalid BigNumberish value",a||"value",c)}function getUint(c,a){const d=getBigInt(c,a);return assert$y(d>=BN_0$9,"unsigned value cannot be negative","NUMERIC_FAULT",{fault:"overflow",operation:"getUint",value:c}),d}const Nibbles="0123456789abcdef";function toBigInt(c){if(c instanceof Uint8Array){let a="0x0";for(const d of c)a+=Nibbles[d>>4],a+=Nibbles[d&15];return BigInt(a)}return getBigInt(c)}function getNumber(c,a){switch(typeof c){case"bigint":return assertArgument(c>=-maxValue&&c<=maxValue,"overflow",a||"value",c),Number(c);case"number":return assertArgument(Number.isInteger(c),"underflow",a||"value",c),assertArgument(c>=-maxValue&&c<=maxValue,"overflow",a||"value",c),c;case"string":try{if(c==="")throw new Error("empty string");return getNumber(BigInt(c),a)}catch(d){assertArgument(!1,`invalid numeric string: ${d.message}`,a||"value",c)}}assertArgument(!1,"invalid numeric value",a||"value",c)}function toNumber(c){return getNumber(toBigInt(c))}function toBeHex(c,a){let et=getUint(c,"value").toString(16);if(a==null)et.length%2&&(et="0"+et);else{const nt=getNumber(a,"width");for(assert$y(nt*2>=et.length,`value exceeds width (${nt} bits)`,"NUMERIC_FAULT",{operation:"toBeHex",fault:"overflow",value:c});et.length>6===2;bt++)tt++;return tt}return c==="OVERRUN"?d.length-a-1:0}function replaceFunc(c,a,d,et,nt){return c==="OVERLONG"?(assertArgument(typeof nt=="number","invalid bad code point for replacement","badCodepoint",nt),et.push(nt),0):(et.push(65533),ignoreFunc(c,a,d))}const Utf8ErrorFuncs=Object.freeze({error:errorFunc,ignore:ignoreFunc,replace:replaceFunc});function getUtf8CodePoints(c,a){a==null&&(a=Utf8ErrorFuncs.error);const d=getBytes(c,"bytes"),et=[];let nt=0;for(;nt>7)){et.push(tt);continue}let bt=null,mt=null;if((tt&224)===192)bt=1,mt=127;else if((tt&240)===224)bt=2,mt=2047;else if((tt&248)===240)bt=3,mt=65535;else{(tt&192)===128?nt+=a("UNEXPECTED_CONTINUE",nt-1,d,et):nt+=a("BAD_PREFIX",nt-1,d,et);continue}if(nt-1+bt>=d.length){nt+=a("OVERRUN",nt-1,d,et);continue}let vt=tt&(1<<8-bt-1)-1;for(let $t=0;$t1114111){nt+=a("OUT_OF_RANGE",nt-1-bt,d,et,vt);continue}if(vt>=55296&&vt<=57343){nt+=a("UTF16_SURROGATE",nt-1-bt,d,et,vt);continue}if(vt<=mt){nt+=a("OVERLONG",nt-1-bt,d,et,vt);continue}et.push(vt)}}return et}function toUtf8Bytes$1(c,a){a!=null&&(assertNormalize(a),c=c.normalize(a));let d=[];for(let et=0;et>6|192),d.push(nt&63|128);else if((nt&64512)==55296){et++;const tt=c.charCodeAt(et);assertArgument(et>18|240),d.push(bt>>12&63|128),d.push(bt>>6&63|128),d.push(bt&63|128)}else d.push(nt>>12|224),d.push(nt>>6&63|128),d.push(nt&63|128)}return new Uint8Array(d)}function _toUtf8String(c){return c.map(a=>a<=65535?String.fromCharCode(a):(a-=65536,String.fromCharCode((a>>10&1023)+55296,(a&1023)+56320))).join("")}function toUtf8String(c,a){return _toUtf8String(getUtf8CodePoints(c,a))}async function getUrl$1(c,a){const d=c.url.split(":")[0].toLowerCase();assert$y(d==="http"||d==="https",`unsupported protocol ${d}`,"UNSUPPORTED_OPERATION",{info:{protocol:d},operation:"request"}),assert$y(d==="https"||!c.credentials||c.allowInsecureAuthentication,"insecure authorized connections unsupported","UNSUPPORTED_OPERATION",{operation:"request"});let et;if(a){const $t=new AbortController;et=$t.signal,a.addListener(()=>{$t.abort()})}const nt={method:c.method,headers:new Headers(Array.from(c)),body:c.body||void 0,signal:et},tt=await fetch(c.url,nt),bt={};tt.headers.forEach(($t,At)=>{bt[At.toLowerCase()]=$t});const mt=await tt.arrayBuffer(),vt=mt==null?null:new Uint8Array(mt);return{statusCode:tt.status,statusMessage:tt.statusText,headers:bt,body:vt}}const MAX_ATTEMPTS=12,SLOT_INTERVAL=250;let getUrlFunc=getUrl$1;const reData=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),reIpfs=new RegExp("^ipfs://(ipfs/)?(.*)$","i");let locked$2=!1;async function dataGatewayFunc(c,a){try{const d=c.match(reData);if(!d)throw new Error("invalid data");return new FetchResponse(200,"OK",{"content-type":d[1]||"text/plain"},d[2]?decodeBase64(d[3]):unpercent(d[3]))}catch{return new FetchResponse(599,"BAD REQUEST (invalid data: URI)",{},null,new FetchRequest(c))}}function getIpfsGatewayFunc(c){async function a(d,et){try{const nt=d.match(reIpfs);if(!nt)throw new Error("invalid link");return new FetchRequest(`${c}${nt[2]}`)}catch{return new FetchResponse(599,"BAD REQUEST (invalid IPFS URI)",{},null,new FetchRequest(d))}}return a}const Gateways={data:dataGatewayFunc,ipfs:getIpfsGatewayFunc("https://gateway.ipfs.io/ipfs/")},fetchSignals=new WeakMap;var qn,Tn;class FetchCancelSignal{constructor(a){q0(this,qn,void 0);q0(this,Tn,void 0);m0(this,qn,[]),m0(this,Tn,!1),fetchSignals.set(a,()=>{if(!s0(this,Tn)){m0(this,Tn,!0);for(const d of s0(this,qn))setTimeout(()=>{d()},0);m0(this,qn,[])}})}addListener(a){assert$y(!s0(this,Tn),"singal already cancelled","UNSUPPORTED_OPERATION",{operation:"fetchCancelSignal.addCancelListener"}),s0(this,qn).push(a)}get cancelled(){return s0(this,Tn)}checkSignal(){assert$y(!this.cancelled,"cancelled","CANCELLED",{})}}qn=new WeakMap,Tn=new WeakMap;function checkSignal(c){if(c==null)throw new Error("missing signal; should not happen");return c.checkSignal(),c}var cs,ls,Jr,un,us,ds,Cr,Lr,dn,Vn,Kn,Wn,tn,hn,Jn,Js;const Co=class Co{constructor(a){q0(this,Jn);q0(this,cs,void 0);q0(this,ls,void 0);q0(this,Jr,void 0);q0(this,un,void 0);q0(this,us,void 0);q0(this,ds,void 0);q0(this,Cr,void 0);q0(this,Lr,void 0);q0(this,dn,void 0);q0(this,Vn,void 0);q0(this,Kn,void 0);q0(this,Wn,void 0);q0(this,tn,void 0);q0(this,hn,void 0);m0(this,ds,String(a)),m0(this,cs,!1),m0(this,ls,!0),m0(this,Jr,{}),m0(this,un,""),m0(this,us,3e5),m0(this,hn,{slotInterval:SLOT_INTERVAL,maxAttempts:MAX_ATTEMPTS})}get url(){return s0(this,ds)}set url(a){m0(this,ds,String(a))}get body(){return s0(this,Cr)==null?null:new Uint8Array(s0(this,Cr))}set body(a){if(a==null)m0(this,Cr,void 0),m0(this,Lr,void 0);else if(typeof a=="string")m0(this,Cr,toUtf8Bytes$1(a)),m0(this,Lr,"text/plain");else if(a instanceof Uint8Array)m0(this,Cr,a),m0(this,Lr,"application/octet-stream");else if(typeof a=="object")m0(this,Cr,toUtf8Bytes$1(JSON.stringify(a))),m0(this,Lr,"application/json");else throw new Error("invalid body")}hasBody(){return s0(this,Cr)!=null}get method(){return s0(this,un)?s0(this,un):this.hasBody()?"POST":"GET"}set method(a){a==null&&(a=""),m0(this,un,String(a).toUpperCase())}get headers(){const a=Object.assign({},s0(this,Jr));return s0(this,dn)&&(a.authorization=`Basic ${encodeBase64(toUtf8Bytes$1(s0(this,dn)))}`),this.allowGzip&&(a["accept-encoding"]="gzip"),a["content-type"]==null&&s0(this,Lr)&&(a["content-type"]=s0(this,Lr)),this.body&&(a["content-length"]=String(this.body.length)),a}getHeader(a){return this.headers[a.toLowerCase()]}setHeader(a,d){s0(this,Jr)[String(a).toLowerCase()]=String(d)}clearHeaders(){m0(this,Jr,{})}[Symbol.iterator](){const a=this.headers,d=Object.keys(a);let et=0;return{next:()=>{if(et=0,"timeout must be non-zero","timeout",a),m0(this,us,a)}get preflightFunc(){return s0(this,Vn)||null}set preflightFunc(a){m0(this,Vn,a)}get processFunc(){return s0(this,Kn)||null}set processFunc(a){m0(this,Kn,a)}get retryFunc(){return s0(this,Wn)||null}set retryFunc(a){m0(this,Wn,a)}toString(){return``}setThrottleParams(a){a.slotInterval!=null&&(s0(this,hn).slotInterval=a.slotInterval),a.maxAttempts!=null&&(s0(this,hn).maxAttempts=a.maxAttempts)}send(){return assert$y(s0(this,tn)==null,"request already sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.send"}),m0(this,tn,new FetchCancelSignal(this)),W0(this,Jn,Js).call(this,0,getTime$1()+this.timeout,0,this,new FetchResponse(0,"",{},null,this))}cancel(){assert$y(s0(this,tn)!=null,"request has not been sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.cancel"});const a=fetchSignals.get(this);if(!a)throw new Error("missing signal; should not happen");a()}redirect(a){const d=this.url.split(":")[0].toLowerCase(),et=a.split(":")[0].toLowerCase();assert$y(this.method==="GET"&&(d!=="https"||et!=="http")&&a.match(/^https?:/),"unsupported redirect","UNSUPPORTED_OPERATION",{operation:`redirect(${this.method} ${JSON.stringify(this.url)} => ${JSON.stringify(a)})`});const nt=new Co(a);return nt.method="GET",nt.allowGzip=this.allowGzip,nt.timeout=this.timeout,m0(nt,Jr,Object.assign({},s0(this,Jr))),s0(this,Cr)&&m0(nt,Cr,new Uint8Array(s0(this,Cr))),m0(nt,Lr,s0(this,Lr)),nt}clone(){const a=new Co(this.url);return m0(a,un,s0(this,un)),s0(this,Cr)&&m0(a,Cr,s0(this,Cr)),m0(a,Lr,s0(this,Lr)),m0(a,Jr,Object.assign({},s0(this,Jr))),m0(a,dn,s0(this,dn)),this.allowGzip&&(a.allowGzip=!0),a.timeout=this.timeout,this.allowInsecureAuthentication&&(a.allowInsecureAuthentication=!0),m0(a,Vn,s0(this,Vn)),m0(a,Kn,s0(this,Kn)),m0(a,Wn,s0(this,Wn)),a}static lockConfig(){locked$2=!0}static getGateway(a){return Gateways[a.toLowerCase()]||null}static registerGateway(a,d){if(a=a.toLowerCase(),a==="http"||a==="https")throw new Error(`cannot intercept ${a}; use registerGetUrl`);if(locked$2)throw new Error("gateways locked");Gateways[a]=d}static registerGetUrl(a){if(locked$2)throw new Error("gateways locked");getUrlFunc=a}static createDataGateway(){return dataGatewayFunc}static createIpfsGatewayFunc(a){return getIpfsGatewayFunc(a)}};cs=new WeakMap,ls=new WeakMap,Jr=new WeakMap,un=new WeakMap,us=new WeakMap,ds=new WeakMap,Cr=new WeakMap,Lr=new WeakMap,dn=new WeakMap,Vn=new WeakMap,Kn=new WeakMap,Wn=new WeakMap,tn=new WeakMap,hn=new WeakMap,Jn=new WeakSet,Js=async function(a,d,et,nt,tt){var At,Mt,Tt;if(a>=s0(this,hn).maxAttempts)return tt.makeServerError("exceeded maximum retry limit");assert$y(getTime$1()<=d,"timeout","TIMEOUT",{operation:"request.send",reason:"timeout",request:nt}),et>0&&await wait$1(et);let bt=this.clone();const mt=(bt.url.split(":")[0]||"").toLowerCase();if(mt in Gateways){const Rt=await Gateways[mt](bt.url,checkSignal(s0(nt,tn)));if(Rt instanceof FetchResponse){let kt=Rt;if(this.processFunc){checkSignal(s0(nt,tn));try{kt=await this.processFunc(bt,kt)}catch(It){(It.throttle==null||typeof It.stall!="number")&&kt.makeServerError("error in post-processing function",It).assertOk()}}return kt}bt=Rt}this.preflightFunc&&(bt=await this.preflightFunc(bt));const vt=await getUrlFunc(bt,checkSignal(s0(nt,tn)));let $t=new FetchResponse(vt.statusCode,vt.statusMessage,vt.headers,vt.body,nt);if($t.statusCode===301||$t.statusCode===302){try{const Rt=$t.headers.location||"";return W0(At=bt.redirect(Rt),Jn,Js).call(At,a+1,d,0,nt,$t)}catch{}return $t}else if($t.statusCode===429&&(this.retryFunc==null||await this.retryFunc(bt,$t,a))){const Rt=$t.headers["retry-after"];let kt=s0(this,hn).slotInterval*Math.trunc(Math.random()*Math.pow(2,a));return typeof Rt=="string"&&Rt.match(/^[1-9][0-9]*$/)&&(kt=parseInt(Rt)),W0(Mt=bt.clone(),Jn,Js).call(Mt,a+1,d,kt,nt,$t)}if(this.processFunc){checkSignal(s0(nt,tn));try{$t=await this.processFunc(bt,$t)}catch(Rt){(Rt.throttle==null||typeof Rt.stall!="number")&&$t.makeServerError("error in post-processing function",Rt).assertOk();let kt=s0(this,hn).slotInterval*Math.trunc(Math.random()*Math.pow(2,a));return Rt.stall>=0&&(kt=Rt.stall),W0(Tt=bt.clone(),Jn,Js).call(Tt,a+1,d,kt,nt,$t)}}return $t};let FetchRequest=Co;var eo,to,ro,Yr,hs,Yn;const Qo=class Qo{constructor(a,d,et,nt,tt){q0(this,eo,void 0);q0(this,to,void 0);q0(this,ro,void 0);q0(this,Yr,void 0);q0(this,hs,void 0);q0(this,Yn,void 0);m0(this,eo,a),m0(this,to,d),m0(this,ro,Object.keys(et).reduce((bt,mt)=>(bt[mt.toLowerCase()]=String(et[mt]),bt),{})),m0(this,Yr,nt==null?null:new Uint8Array(nt)),m0(this,hs,tt||null),m0(this,Yn,{message:""})}toString(){return``}get statusCode(){return s0(this,eo)}get statusMessage(){return s0(this,to)}get headers(){return Object.assign({},s0(this,ro))}get body(){return s0(this,Yr)==null?null:new Uint8Array(s0(this,Yr))}get bodyText(){try{return s0(this,Yr)==null?"":toUtf8String(s0(this,Yr))}catch{assert$y(!1,"response body is not valid UTF-8 data","UNSUPPORTED_OPERATION",{operation:"bodyText",info:{response:this}})}}get bodyJson(){try{return JSON.parse(this.bodyText)}catch{assert$y(!1,"response body is not valid JSON","UNSUPPORTED_OPERATION",{operation:"bodyJson",info:{response:this}})}}[Symbol.iterator](){const a=this.headers,d=Object.keys(a);let et=0;return{next:()=>{if(et=0,"invalid stall timeout","stall",d);const et=new Error(a||"throttling requests");throw defineProperties(et,{stall:d,throttle:!0}),et}getHeader(a){return this.headers[a.toLowerCase()]}hasBody(){return s0(this,Yr)!=null}get request(){return s0(this,hs)}ok(){return s0(this,Yn).message===""&&this.statusCode>=200&&this.statusCode<300}assertOk(){if(this.ok())return;let{message:a,error:d}=s0(this,Yn);a===""&&(a=`server response ${this.statusCode} ${this.statusMessage}`),assert$y(!1,a,"SERVER_ERROR",{request:this.request||"unknown request",response:this,error:d})}};eo=new WeakMap,to=new WeakMap,ro=new WeakMap,Yr=new WeakMap,hs=new WeakMap,Yn=new WeakMap;let FetchResponse=Qo;function getTime$1(){return new Date().getTime()}function unpercent(c){return toUtf8Bytes$1(c.replace(/%([0-9a-f][0-9a-f])/gi,(a,d)=>String.fromCharCode(parseInt(d,16))))}function wait$1(c){return new Promise(a=>setTimeout(a,c))}const BN_N1=BigInt(-1),BN_0$8=BigInt(0),BN_1$3=BigInt(1),BN_5=BigInt(5),_guard$3={};let Zeros$1="0000";for(;Zeros$1.length<80;)Zeros$1+=Zeros$1;function getTens(c){let a=Zeros$1;for(;a.length=-nt&&cBN_0$8?c=fromTwos(mask(c,et),et):c=-fromTwos(mask(-c,et),et)}else{const nt=BN_1$3<=0&&ctt[mt]==null?$t:(assertArgument(typeof tt[mt]===vt,"invalid fixed format ("+mt+" not "+vt+")","format."+mt,tt[mt]),tt[mt]);a=bt("signed","boolean",a),d=bt("width","number",d),et=bt("decimals","number",et)}assertArgument(d%8===0,"invalid FixedNumber width (not byte aligned)","format.width",d),assertArgument(et<=80,"invalid FixedNumber decimals (too large)","format.decimals",et);const nt=(a?"":"u")+"fixed"+String(d)+"x"+String(et);return{signed:a,width:d,decimals:et,name:nt}}function toString$1(c,a){let d="";c0?et*=getTens(nt):nt<0&&(d*=getTens(-nt)),det?1:0}eq(a){return this.cmp(a)===0}lt(a){return this.cmp(a)<0}lte(a){return this.cmp(a)<=0}gt(a){return this.cmp(a)>0}gte(a){return this.cmp(a)>=0}floor(){let a=s0(this,Pr);return s0(this,Pr)BN_0$8&&(a+=s0(this,Ir)-BN_1$3),a=s0(this,Pr)/s0(this,Ir)*s0(this,Ir),W0(this,Qr,cn).call(this,a,"ceiling")}round(a){if(a==null&&(a=0),a>=this.decimals)return this;const d=this.decimals-a,et=BN_5*getTens(d-1);let nt=this.value+et;const tt=getTens(d);return nt=nt/tt*tt,checkValue(nt,s0(this,Zr),"round"),new Pn(_guard$3,nt,s0(this,Zr))}isZero(){return s0(this,Pr)===BN_0$8}isNegative(){return s0(this,Pr)0){const vt=getTens(mt);assert$y(bt%vt===BN_0$8,"value loses precision for format","NUMERIC_FAULT",{operation:"fromValue",fault:"underflow",value:a}),bt/=vt}else mt<0&&(bt*=getTens(-mt));return checkValue(bt,tt,"fromValue"),new Pn(_guard$3,bt,tt)}static fromString(a,d){const et=a.match(/^(-?)([0-9]*)\.?([0-9]*)$/);assertArgument(et&&et[2].length+et[3].length>0,"invalid FixedNumber string value","value",a);const nt=getFormat(d);let tt=et[2]||"0",bt=et[3]||"";for(;bt.length{assert$y(et<=c.length,"data short segment too short","BUFFER_OVERRUN",{buffer:c,length:c.length,offset:et})};if(c[a]>=248){const et=c[a]-247;d(a+1+et);const nt=unarrayifyInteger(c,a+1,et);return d(a+1+et+nt),_decodeChildren(c,a,a+1+et,et+nt)}else if(c[a]>=192){const et=c[a]-192;return d(a+1+et),_decodeChildren(c,a,a+1,et)}else if(c[a]>=184){const et=c[a]-183;d(a+1+et);const nt=unarrayifyInteger(c,a+1,et);d(a+1+et+nt);const tt=hexlify$1(c.slice(a+1+et,a+1+et+nt));return{consumed:1+et+nt,result:tt}}else if(c[a]>=128){const et=c[a]-128;d(a+1+et);const nt=hexlify$1(c.slice(a+1,a+1+et));return{consumed:1+et,result:nt}}return{consumed:1,result:hexlifyByte(c[a])}}function decodeRlp(c){const a=getBytes(c,"data"),d=_decode(a,0);return assertArgument(d.consumed===a.length,"unexpected junk after rlp payload","data",c),d.result}function arrayifyInteger$1(c){const a=[];for(;c;)a.unshift(c&255),c>>=8;return a}function _encode$1(c){if(Array.isArray(c)){let et=[];if(c.forEach(function(tt){et=et.concat(_encode$1(tt))}),et.length<=55)return et.unshift(192+et.length),et;const nt=arrayifyInteger$1(et.length);return nt.unshift(247+nt.length),nt.concat(et)}const a=Array.prototype.slice.call(getBytes(c,"object"));if(a.length===1&&a[0]<=127)return a;if(a.length<=55)return a.unshift(128+a.length),a;const d=arrayifyInteger$1(a.length);return d.unshift(183+d.length),d.concat(a)}const nibbles="0123456789abcdef";function encodeRlp(c){let a="0x";for(const d of _encode$1(c))a+=nibbles[d>>4],a+=nibbles[d&15];return a}const names=["wei","kwei","mwei","gwei","szabo","finney","ether"];function formatUnits$1(c,a){let d=18;if(typeof a=="string"){const et=names.indexOf(a);assertArgument(et>=0,"invalid unit","unit",a),d=3*et}else a!=null&&(d=getNumber(a,"unit"));return FixedNumber.fromValue(c,d,{decimals:d,width:512}).toString()}function parseUnits$1(c,a){assertArgument(typeof c=="string","value must be a string","value",c);let d=18;if(typeof a=="string"){const et=names.indexOf(a);assertArgument(et>=0,"invalid unit","unit",a),d=3*et}else a!=null&&(d=getNumber(a,"unit"));return FixedNumber.fromString(c,{decimals:d,width:512}).value}function parseEther(c){return parseUnits$1(c,18)}const WordSize=32,Padding=new Uint8Array(WordSize),passProperties$1=["then"],_guard$2={};function throwError(c,a){const d=new Error(`deferred error during ABI decoding triggered accessing ${c}`);throw d.error=a,d}var Rn;const Qs=class Qs extends Array{constructor(...d){const et=d[0];let nt=d[1],tt=(d[2]||[]).slice(),bt=!0;et!==_guard$2&&(nt=d,tt=[],bt=!1);super(nt.length);q0(this,Rn,void 0);nt.forEach((vt,$t)=>{this[$t]=vt});const mt=tt.reduce((vt,$t)=>(typeof $t=="string"&&vt.set($t,(vt.get($t)||0)+1),vt),new Map);if(m0(this,Rn,Object.freeze(nt.map((vt,$t)=>{const At=tt[$t];return At!=null&&mt.get(At)===1?At:null}))),!!bt)return Object.freeze(this),new Proxy(this,{get:(vt,$t,At)=>{if(typeof $t=="string"){if($t.match(/^[0-9]+$/)){const Tt=getNumber($t,"%index");if(Tt<0||Tt>=this.length)throw new RangeError("out of result range");const Rt=vt[Tt];return Rt instanceof Error&&throwError(`index ${Tt}`,Rt),Rt}if(passProperties$1.indexOf($t)>=0)return Reflect.get(vt,$t,At);const Mt=vt[$t];if(Mt instanceof Function)return function(...Tt){return Mt.apply(this===At?vt:this,Tt)};if(!($t in vt))return vt.getValue.apply(this===At?vt:this,[$t])}return Reflect.get(vt,$t,At)}})}toArray(){const d=[];return this.forEach((et,nt)=>{et instanceof Error&&throwError(`index ${nt}`,et),d.push(et)}),d}toObject(){return s0(this,Rn).reduce((d,et,nt)=>(assert$y(et!=null,"value at index ${ index } unnamed","UNSUPPORTED_OPERATION",{operation:"toObject()"}),et in d||(d[et]=this.getValue(et)),d),{})}slice(d,et){d==null&&(d=0),d<0&&(d+=this.length,d<0&&(d=0)),et==null&&(et=this.length),et<0&&(et+=this.length,et<0&&(et=0)),et>this.length&&(et=this.length);const nt=[],tt=[];for(let bt=d;bt{s0(this,mn)[a]=getValue$1(d)}}}mn=new WeakMap,Zn=new WeakMap,ps=new WeakSet,Eo=function(a){return s0(this,mn).push(a),m0(this,Zn,s0(this,Zn)+a.length),a.length};var Fr,qr,To,e1;const Xo=class Xo{constructor(a,d){q0(this,To);G0(this,"allowLoose");q0(this,Fr,void 0);q0(this,qr,void 0);defineProperties(this,{allowLoose:!!d}),m0(this,Fr,getBytesCopy(a)),m0(this,qr,0)}get data(){return hexlify$1(s0(this,Fr))}get dataLength(){return s0(this,Fr).length}get consumed(){return s0(this,qr)}get bytes(){return new Uint8Array(s0(this,Fr))}subReader(a){return new Xo(s0(this,Fr).slice(s0(this,qr)+a),this.allowLoose)}readBytes(a,d){let et=W0(this,To,e1).call(this,0,a,!!d);return m0(this,qr,s0(this,qr)+et.length),et.slice(0,a)}readValue(){return toBigInt(this.readBytes(WordSize))}readIndex(){return toNumber(this.readBytes(WordSize))}};Fr=new WeakMap,qr=new WeakMap,To=new WeakSet,e1=function(a,d,et){let nt=Math.ceil(d/WordSize)*WordSize;return s0(this,qr)+nt>s0(this,Fr).length&&(this.allowLoose&&et&&s0(this,qr)+d<=s0(this,Fr).length?nt=d:assert$y(!1,"data out-of-bounds","BUFFER_OVERRUN",{buffer:getBytesCopy(s0(this,Fr)),length:s0(this,Fr).length,offset:s0(this,qr)+nt})),s0(this,Fr).slice(s0(this,qr),s0(this,qr)+nt)};let Reader=Xo;function number$2(c){if(!Number.isSafeInteger(c)||c<0)throw new Error(`Wrong positive integer: ${c}`)}function bool(c){if(typeof c!="boolean")throw new Error(`Expected boolean, not ${c}`)}function bytes$2(c,...a){if(!(c instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(a.length>0&&!a.includes(c.length))throw new TypeError(`Expected Uint8Array of length ${a}, not of length=${c.length}`)}function hash$9(c){if(typeof c!="function"||typeof c.create!="function")throw new Error("Hash should be wrapped by utils.wrapConstructor");number$2(c.outputLen),number$2(c.blockLen)}function exists$2(c,a=!0){if(c.destroyed)throw new Error("Hash instance has been destroyed");if(a&&c.finished)throw new Error("Hash#digest() has already been called")}function output$2(c,a){bytes$2(c);const d=a.outputLen;if(c.lengthnew Uint32Array(c.buffer,c.byteOffset,Math.floor(c.byteLength/4)),createView$1=c=>new DataView(c.buffer,c.byteOffset,c.byteLength),rotr$1=(c,a)=>c<<32-a|c>>>a,isLE$2=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;if(!isLE$2)throw new Error("Non little-endian hardware is not supported");Array.from({length:256},(c,a)=>a.toString(16).padStart(2,"0"));function utf8ToBytes$2(c){if(typeof c!="string")throw new TypeError(`utf8ToBytes expected string, got ${typeof c}`);return new TextEncoder().encode(c)}function toBytes$4(c){if(typeof c=="string"&&(c=utf8ToBytes$2(c)),!(c instanceof Uint8Array))throw new TypeError(`Expected input type is Uint8Array (got ${typeof c})`);return c}let Hash$a=class{clone(){return this._cloneInto()}};function wrapConstructor$2(c){const a=et=>c().update(toBytes$4(et)).digest(),d=c();return a.outputLen=d.outputLen,a.blockLen=d.blockLen,a.create=()=>c(),a}function wrapConstructorWithOpts(c){const a=(et,nt)=>c(nt).update(toBytes$4(et)).digest(),d=c({});return a.outputLen=d.outputLen,a.blockLen=d.blockLen,a.create=et=>c(et),a}class HMAC extends Hash$a{constructor(a,d){super(),this.finished=!1,this.destroyed=!1,assert$x.hash(a);const et=toBytes$4(d);if(this.iHash=a.create(),!(this.iHash instanceof Hash$a))throw new TypeError("Expected instance of class which extends utils.Hash");const nt=this.blockLen=this.iHash.blockLen;this.outputLen=this.iHash.outputLen;const tt=new Uint8Array(nt);tt.set(et.length>this.iHash.blockLen?a.create().update(et).digest():et);for(let bt=0;btnew HMAC(c,a).update(d).digest();hmac$1.create=(c,a)=>new HMAC(c,a);function setBigUint64$1(c,a,d,et){if(typeof c.setBigUint64=="function")return c.setBigUint64(a,d,et);const nt=BigInt(32),tt=BigInt(4294967295),bt=Number(d>>nt&tt),mt=Number(d&tt),vt=et?4:0,$t=et?0:4;c.setUint32(a+vt,bt,et),c.setUint32(a+$t,mt,et)}let SHA2$1=class extends Hash$a{constructor(a,d,et,nt){super(),this.blockLen=a,this.outputLen=d,this.padOffset=et,this.isLE=nt,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(a),this.view=createView$1(this.buffer)}update(a){assert$x.exists(this);const{view:d,buffer:et,blockLen:nt}=this;a=toBytes$4(a);const tt=a.length;for(let bt=0;btnt-bt&&(this.process(et,0),bt=0);for(let vt=bt;vtmt.setUint32(4*$t,vt,tt))}digest(){const{buffer:a,outputLen:d}=this;this.digestInto(a);const et=a.slice(0,d);return this.destroy(),et}_cloneInto(a){a||(a=new this.constructor),a.set(...this.get());const{blockLen:d,buffer:et,length:nt,finished:tt,destroyed:bt,pos:mt}=this;return a.length=nt,a.pos=mt,a.finished=tt,a.destroyed=bt,nt%d&&a.buffer.set(et),a}};const Chi$1=(c,a,d)=>c&a^~c&d,Maj$1=(c,a,d)=>c&a^c&d^a&d,SHA256_K$1=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV$1=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W$1=new Uint32Array(64);let SHA256$3=class extends SHA2$1{constructor(){super(64,32,8,!1),this.A=IV$1[0]|0,this.B=IV$1[1]|0,this.C=IV$1[2]|0,this.D=IV$1[3]|0,this.E=IV$1[4]|0,this.F=IV$1[5]|0,this.G=IV$1[6]|0,this.H=IV$1[7]|0}get(){const{A:a,B:d,C:et,D:nt,E:tt,F:bt,G:mt,H:vt}=this;return[a,d,et,nt,tt,bt,mt,vt]}set(a,d,et,nt,tt,bt,mt,vt){this.A=a|0,this.B=d|0,this.C=et|0,this.D=nt|0,this.E=tt|0,this.F=bt|0,this.G=mt|0,this.H=vt|0}process(a,d){for(let Mt=0;Mt<16;Mt++,d+=4)SHA256_W$1[Mt]=a.getUint32(d,!1);for(let Mt=16;Mt<64;Mt++){const Tt=SHA256_W$1[Mt-15],Rt=SHA256_W$1[Mt-2],kt=rotr$1(Tt,7)^rotr$1(Tt,18)^Tt>>>3,It=rotr$1(Rt,17)^rotr$1(Rt,19)^Rt>>>10;SHA256_W$1[Mt]=It+SHA256_W$1[Mt-7]+kt+SHA256_W$1[Mt-16]|0}let{A:et,B:nt,C:tt,D:bt,E:mt,F:vt,G:$t,H:At}=this;for(let Mt=0;Mt<64;Mt++){const Tt=rotr$1(mt,6)^rotr$1(mt,11)^rotr$1(mt,25),Rt=At+Tt+Chi$1(mt,vt,$t)+SHA256_K$1[Mt]+SHA256_W$1[Mt]|0,It=(rotr$1(et,2)^rotr$1(et,13)^rotr$1(et,22))+Maj$1(et,nt,tt)|0;At=$t,$t=vt,vt=mt,mt=bt+Rt|0,bt=tt,tt=nt,nt=et,et=Rt+It|0}et=et+this.A|0,nt=nt+this.B|0,tt=tt+this.C|0,bt=bt+this.D|0,mt=mt+this.E|0,vt=vt+this.F|0,$t=$t+this.G|0,At=At+this.H|0,this.set(et,nt,tt,bt,mt,vt,$t,At)}roundClean(){SHA256_W$1.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}};const sha256$5=wrapConstructor$2(()=>new SHA256$3),U32_MASK64$2=BigInt(2**32-1),_32n$2=BigInt(32);function fromBig$2(c,a=!1){return a?{h:Number(c&U32_MASK64$2),l:Number(c>>_32n$2&U32_MASK64$2)}:{h:Number(c>>_32n$2&U32_MASK64$2)|0,l:Number(c&U32_MASK64$2)|0}}function split$2(c,a=!1){let d=new Uint32Array(c.length),et=new Uint32Array(c.length);for(let nt=0;ntBigInt(c>>>0)<<_32n$2|BigInt(a>>>0),shrSH=(c,a,d)=>c>>>d,shrSL=(c,a,d)=>c<<32-d|a>>>d,rotrSH=(c,a,d)=>c>>>d|a<<32-d,rotrSL=(c,a,d)=>c<<32-d|a>>>d,rotrBH=(c,a,d)=>c<<64-d|a>>>d-32,rotrBL=(c,a,d)=>c>>>d-32|a<<64-d,rotr32H=(c,a)=>a,rotr32L=(c,a)=>c,rotlSH$2=(c,a,d)=>c<>>32-d,rotlSL$2=(c,a,d)=>a<>>32-d,rotlBH$2=(c,a,d)=>a<>>64-d,rotlBL$2=(c,a,d)=>c<>>64-d;function add(c,a,d,et){const nt=(a>>>0)+(et>>>0);return{h:c+d+(nt/2**32|0)|0,l:nt|0}}const add3L=(c,a,d)=>(c>>>0)+(a>>>0)+(d>>>0),add3H=(c,a,d,et)=>a+d+et+(c/2**32|0)|0,add4L=(c,a,d,et)=>(c>>>0)+(a>>>0)+(d>>>0)+(et>>>0),add4H=(c,a,d,et,nt)=>a+d+et+nt+(c/2**32|0)|0,add5L=(c,a,d,et,nt)=>(c>>>0)+(a>>>0)+(d>>>0)+(et>>>0)+(nt>>>0),add5H=(c,a,d,et,nt,tt)=>a+d+et+nt+tt+(c/2**32|0)|0,u64={fromBig:fromBig$2,split:split$2,toBig,shrSH,shrSL,rotrSH,rotrSL,rotrBH,rotrBL,rotr32H,rotr32L,rotlSH:rotlSH$2,rotlSL:rotlSL$2,rotlBH:rotlBH$2,rotlBL:rotlBL$2,add,add3L,add3H,add4L,add4H,add5H,add5L},[SHA512_Kh,SHA512_Kl]=u64.split(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(c=>BigInt(c))),SHA512_W_H=new Uint32Array(80),SHA512_W_L=new Uint32Array(80);let SHA512$3=class extends SHA2$1{constructor(){super(128,64,16,!1),this.Ah=1779033703,this.Al=-205731576,this.Bh=-1150833019,this.Bl=-2067093701,this.Ch=1013904242,this.Cl=-23791573,this.Dh=-1521486534,this.Dl=1595750129,this.Eh=1359893119,this.El=-1377402159,this.Fh=-1694144372,this.Fl=725511199,this.Gh=528734635,this.Gl=-79577749,this.Hh=1541459225,this.Hl=327033209}get(){const{Ah:a,Al:d,Bh:et,Bl:nt,Ch:tt,Cl:bt,Dh:mt,Dl:vt,Eh:$t,El:At,Fh:Mt,Fl:Tt,Gh:Rt,Gl:kt,Hh:It,Hl:Dt}=this;return[a,d,et,nt,tt,bt,mt,vt,$t,At,Mt,Tt,Rt,kt,It,Dt]}set(a,d,et,nt,tt,bt,mt,vt,$t,At,Mt,Tt,Rt,kt,It,Dt){this.Ah=a|0,this.Al=d|0,this.Bh=et|0,this.Bl=nt|0,this.Ch=tt|0,this.Cl=bt|0,this.Dh=mt|0,this.Dl=vt|0,this.Eh=$t|0,this.El=At|0,this.Fh=Mt|0,this.Fl=Tt|0,this.Gh=Rt|0,this.Gl=kt|0,this.Hh=It|0,this.Hl=Dt|0}process(a,d){for(let Ut=0;Ut<16;Ut++,d+=4)SHA512_W_H[Ut]=a.getUint32(d),SHA512_W_L[Ut]=a.getUint32(d+=4);for(let Ut=16;Ut<80;Ut++){const Gt=SHA512_W_H[Ut-15]|0,Wt=SHA512_W_L[Ut-15]|0,Xt=u64.rotrSH(Gt,Wt,1)^u64.rotrSH(Gt,Wt,8)^u64.shrSH(Gt,Wt,7),a0=u64.rotrSL(Gt,Wt,1)^u64.rotrSL(Gt,Wt,8)^u64.shrSL(Gt,Wt,7),n0=SHA512_W_H[Ut-2]|0,t0=SHA512_W_L[Ut-2]|0,c0=u64.rotrSH(n0,t0,19)^u64.rotrBH(n0,t0,61)^u64.shrSH(n0,t0,6),Ct=u64.rotrSL(n0,t0,19)^u64.rotrBL(n0,t0,61)^u64.shrSL(n0,t0,6),dt=u64.add4L(a0,Ct,SHA512_W_L[Ut-7],SHA512_W_L[Ut-16]),yt=u64.add4H(dt,Xt,c0,SHA512_W_H[Ut-7],SHA512_W_H[Ut-16]);SHA512_W_H[Ut]=yt|0,SHA512_W_L[Ut]=dt|0}let{Ah:et,Al:nt,Bh:tt,Bl:bt,Ch:mt,Cl:vt,Dh:$t,Dl:At,Eh:Mt,El:Tt,Fh:Rt,Fl:kt,Gh:It,Gl:Dt,Hh:Nt,Hl:Ot}=this;for(let Ut=0;Ut<80;Ut++){const Gt=u64.rotrSH(Mt,Tt,14)^u64.rotrSH(Mt,Tt,18)^u64.rotrBH(Mt,Tt,41),Wt=u64.rotrSL(Mt,Tt,14)^u64.rotrSL(Mt,Tt,18)^u64.rotrBL(Mt,Tt,41),Xt=Mt&Rt^~Mt&It,a0=Tt&kt^~Tt&Dt,n0=u64.add5L(Ot,Wt,a0,SHA512_Kl[Ut],SHA512_W_L[Ut]),t0=u64.add5H(n0,Nt,Gt,Xt,SHA512_Kh[Ut],SHA512_W_H[Ut]),c0=n0|0,Ct=u64.rotrSH(et,nt,28)^u64.rotrBH(et,nt,34)^u64.rotrBH(et,nt,39),dt=u64.rotrSL(et,nt,28)^u64.rotrBL(et,nt,34)^u64.rotrBL(et,nt,39),yt=et&tt^et&mt^tt&mt,gt=nt&bt^nt&vt^bt&vt;Nt=It|0,Ot=Dt|0,It=Rt|0,Dt=kt|0,Rt=Mt|0,kt=Tt|0,{h:Mt,l:Tt}=u64.add($t|0,At|0,t0|0,c0|0),$t=mt|0,At=vt|0,mt=tt|0,vt=bt|0,tt=et|0,bt=nt|0;const xt=u64.add3L(c0,dt,gt);et=u64.add3H(xt,t0,Ct,yt),nt=xt|0}({h:et,l:nt}=u64.add(this.Ah|0,this.Al|0,et|0,nt|0)),{h:tt,l:bt}=u64.add(this.Bh|0,this.Bl|0,tt|0,bt|0),{h:mt,l:vt}=u64.add(this.Ch|0,this.Cl|0,mt|0,vt|0),{h:$t,l:At}=u64.add(this.Dh|0,this.Dl|0,$t|0,At|0),{h:Mt,l:Tt}=u64.add(this.Eh|0,this.El|0,Mt|0,Tt|0),{h:Rt,l:kt}=u64.add(this.Fh|0,this.Fl|0,Rt|0,kt|0),{h:It,l:Dt}=u64.add(this.Gh|0,this.Gl|0,It|0,Dt|0),{h:Nt,l:Ot}=u64.add(this.Hh|0,this.Hl|0,Nt|0,Ot|0),this.set(et,nt,tt,bt,mt,vt,$t,At,Mt,Tt,Rt,kt,It,Dt,Nt,Ot)}roundClean(){SHA512_W_H.fill(0),SHA512_W_L.fill(0)}destroy(){this.buffer.fill(0),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}};class SHA512_256 extends SHA512$3{constructor(){super(),this.Ah=573645204,this.Al=-64227540,this.Bh=-1621794909,this.Bl=-934517566,this.Ch=596883563,this.Cl=1867755857,this.Dh=-1774684391,this.Dl=1497426621,this.Eh=-1775747358,this.El=-1467023389,this.Fh=-1101128155,this.Fl=1401305490,this.Gh=721525244,this.Gl=746961066,this.Hh=246885852,this.Hl=-2117784414,this.outputLen=32}}let SHA384$1=class extends SHA512$3{constructor(){super(),this.Ah=-876896931,this.Al=-1056596264,this.Bh=1654270250,this.Bl=914150663,this.Ch=-1856437926,this.Cl=812702999,this.Dh=355462360,this.Dl=-150054599,this.Eh=1731405415,this.El=-4191439,this.Fh=-1900787065,this.Fl=1750603025,this.Gh=-619958771,this.Gl=1694076839,this.Hh=1203062813,this.Hl=-1090891868,this.outputLen=48}};const sha512$2=wrapConstructor$2(()=>new SHA512$3);wrapConstructor$2(()=>new SHA512_256);wrapConstructor$2(()=>new SHA384$1);function getGlobal$1(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof dist$2.global<"u")return dist$2.global;throw new Error("unable to locate global object")}const anyGlobal$1=getGlobal$1();anyGlobal$1.crypto||anyGlobal$1.msCrypto;function createHmac(c,a){const d={sha256:sha256$5,sha512:sha512$2}[c];return assertArgument(d!=null,"invalid hmac algorithm","algorithm",c),hmac$1.create(d,a)}let locked$1=!1;const _computeHmac=function(c,a,d){return createHmac(c,a).update(d).digest()};let __computeHmac=_computeHmac;function computeHmac$1(c,a,d){const et=getBytes(a,"key"),nt=getBytes(d,"data");return hexlify$1(__computeHmac(c,et,nt))}computeHmac$1._=_computeHmac;computeHmac$1.lock=function(){locked$1=!0};computeHmac$1.register=function(c){if(locked$1)throw new Error("computeHmac is locked");__computeHmac=c};Object.freeze(computeHmac$1);const[SHA3_PI$2,SHA3_ROTL$2,_SHA3_IOTA$2]=[[],[],[]],_0n$3=BigInt(0),_1n$3=BigInt(1),_2n$3=BigInt(2),_7n$2=BigInt(7),_256n$2=BigInt(256),_0x71n$2=BigInt(113);for(let c=0,a=_1n$3,d=1,et=0;c<24;c++){[d,et]=[et,(2*d+3*et)%5],SHA3_PI$2.push(2*(5*et+d)),SHA3_ROTL$2.push((c+1)*(c+2)/2%64);let nt=_0n$3;for(let tt=0;tt<7;tt++)a=(a<<_1n$3^(a>>_7n$2)*_0x71n$2)%_256n$2,a&_2n$3&&(nt^=_1n$3<<(_1n$3<d>32?u64.rotlBH(c,a,d):u64.rotlSH(c,a,d),rotlL$2=(c,a,d)=>d>32?u64.rotlBL(c,a,d):u64.rotlSL(c,a,d);function keccakP$2(c,a=24){const d=new Uint32Array(10);for(let et=24-a;et<24;et++){for(let bt=0;bt<10;bt++)d[bt]=c[bt]^c[bt+10]^c[bt+20]^c[bt+30]^c[bt+40];for(let bt=0;bt<10;bt+=2){const mt=(bt+8)%10,vt=(bt+2)%10,$t=d[vt],At=d[vt+1],Mt=rotlH$2($t,At,1)^d[mt],Tt=rotlL$2($t,At,1)^d[mt+1];for(let Rt=0;Rt<50;Rt+=10)c[bt+Rt]^=Mt,c[bt+Rt+1]^=Tt}let nt=c[2],tt=c[3];for(let bt=0;bt<24;bt++){const mt=SHA3_ROTL$2[bt],vt=rotlH$2(nt,tt,mt),$t=rotlL$2(nt,tt,mt),At=SHA3_PI$2[bt];nt=c[At],tt=c[At+1],c[At]=vt,c[At+1]=$t}for(let bt=0;bt<50;bt+=10){for(let mt=0;mt<10;mt++)d[mt]=c[bt+mt];for(let mt=0;mt<10;mt++)c[bt+mt]^=~d[(mt+2)%10]&d[(mt+4)%10]}c[0]^=SHA3_IOTA_H$2[et],c[1]^=SHA3_IOTA_L$2[et]}d.fill(0)}let Keccak$2=class t1 extends Hash$a{constructor(a,d,et,nt=!1,tt=24){if(super(),this.blockLen=a,this.suffix=d,this.outputLen=et,this.enableXOF=nt,this.rounds=tt,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,assert$x.number(et),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=u32$2(this.state)}keccak(){keccakP$2(this.state32,this.rounds),this.posOut=0,this.pos=0}update(a){assert$x.exists(this);const{blockLen:d,state:et}=this;a=toBytes$4(a);const nt=a.length;for(let tt=0;tt=et&&this.keccak();const bt=Math.min(et-this.posOut,tt-nt);a.set(d.subarray(this.posOut,this.posOut+bt),nt),this.posOut+=bt,nt+=bt}return a}xofInto(a){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(a)}xof(a){return assert$x.number(a),this.xofInto(new Uint8Array(a))}digestInto(a){if(assert$x.output(a,this),this.finished)throw new Error("digest() was already called");return this.writeInto(a),this.destroy(),a}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(a){const{blockLen:d,suffix:et,outputLen:nt,rounds:tt,enableXOF:bt}=this;return a||(a=new t1(d,et,nt,bt,tt)),a.state32.set(this.state32),a.pos=this.pos,a.posOut=this.posOut,a.finished=this.finished,a.rounds=tt,a.suffix=et,a.outputLen=nt,a.enableXOF=bt,a.destroyed=this.destroyed,a}};const gen$2=(c,a,d)=>wrapConstructor$2(()=>new Keccak$2(a,c,d));gen$2(6,144,224/8);gen$2(6,136,256/8);gen$2(6,104,384/8);gen$2(6,72,512/8);gen$2(1,144,224/8);const keccak_256$2=gen$2(1,136,256/8);gen$2(1,104,384/8);gen$2(1,72,512/8);const genShake=(c,a,d)=>wrapConstructorWithOpts((et={})=>new Keccak$2(a,c,et.dkLen===void 0?d:et.dkLen,!0));genShake(31,168,128/8);genShake(31,136,256/8);let locked=!1;const _keccak256=function(c){return keccak_256$2(c)};let __keccak256=_keccak256;function keccak256$3(c){const a=getBytes(c,"data");return hexlify$1(__keccak256(a))}keccak256$3._=_keccak256;keccak256$3.lock=function(){locked=!0};keccak256$3.register=function(c){if(locked)throw new TypeError("keccak256 is locked");__keccak256=c};Object.freeze(keccak256$3);var cryptoBrowserify={},browser$b={exports:{}},safeBuffer$2={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh */(function(c,a){var d=bufferPolyfill,et=d.Buffer;function nt(bt,mt){for(var vt in bt)mt[vt]=bt[vt]}et.from&&et.alloc&&et.allocUnsafe&&et.allocUnsafeSlow?c.exports=d:(nt(d,a),a.Buffer=tt);function tt(bt,mt,vt){return et(bt,mt,vt)}tt.prototype=Object.create(et.prototype),nt(et,tt),tt.from=function(bt,mt,vt){if(typeof bt=="number")throw new TypeError("Argument must not be a number");return et(bt,mt,vt)},tt.alloc=function(bt,mt,vt){if(typeof bt!="number")throw new TypeError("Argument must be a number");var $t=et(bt);return mt!==void 0?typeof vt=="string"?$t.fill(mt,vt):$t.fill(mt):$t.fill(0),$t},tt.allocUnsafe=function(bt){if(typeof bt!="number")throw new TypeError("Argument must be a number");return et(bt)},tt.allocUnsafeSlow=function(bt){if(typeof bt!="number")throw new TypeError("Argument must be a number");return d.SlowBuffer(bt)}})(safeBuffer$2,safeBuffer$2.exports);var safeBufferExports$1=safeBuffer$2.exports,MAX_BYTES=65536,MAX_UINT32=4294967295;function oldBrowser$1(){throw new Error(`Secure random number generation is not supported by this browser. +Use Chrome, Firefox or Internet Explorer 11`)}var Buffer$A=safeBufferExports$1.Buffer,crypto$3=commonjsGlobal.crypto||commonjsGlobal.msCrypto;crypto$3&&crypto$3.getRandomValues?browser$b.exports=randomBytes$3:browser$b.exports=oldBrowser$1;function randomBytes$3(c,a){if(c>MAX_UINT32)throw new RangeError("requested too many random bytes");var d=Buffer$A.allocUnsafe(c);if(c>0)if(c>MAX_BYTES)for(var et=0;et0&&(bt=d[0]),bt instanceof Error)throw bt;var mt=new Error("Unhandled error."+(bt?" ("+bt.message+")":""));throw mt.context=bt,mt}var vt=tt[a];if(vt===void 0)return!1;if(typeof vt=="function")ReflectApply(vt,this,d);else for(var $t=vt.length,At=arrayClone(vt,$t),et=0;et<$t;++et)ReflectApply(At[et],this,d);return!0};function _addListener(c,a,d,et){var nt,tt,bt;if(checkListener(d),tt=c._events,tt===void 0?(tt=c._events=Object.create(null),c._eventsCount=0):(tt.newListener!==void 0&&(c.emit("newListener",a,d.listener?d.listener:d),tt=c._events),bt=tt[a]),bt===void 0)bt=tt[a]=d,++c._eventsCount;else if(typeof bt=="function"?bt=tt[a]=et?[d,bt]:[bt,d]:et?bt.unshift(d):bt.push(d),nt=_getMaxListeners(c),nt>0&&bt.length>nt&&!bt.warned){bt.warned=!0;var mt=new Error("Possible EventEmitter memory leak detected. "+bt.length+" "+String(a)+" listeners added. Use emitter.setMaxListeners() to increase limit");mt.name="MaxListenersExceededWarning",mt.emitter=c,mt.type=a,mt.count=bt.length,ProcessEmitWarning(mt)}return c}EventEmitter.prototype.addListener=function(a,d){return _addListener(this,a,d,!1)};EventEmitter.prototype.on=EventEmitter.prototype.addListener;EventEmitter.prototype.prependListener=function(a,d){return _addListener(this,a,d,!0)};function onceWrapper(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(c,a,d){var et={fired:!1,wrapFn:void 0,target:c,type:a,listener:d},nt=onceWrapper.bind(et);return nt.listener=d,et.wrapFn=nt,nt}EventEmitter.prototype.once=function(a,d){return checkListener(d),this.on(a,_onceWrap(this,a,d)),this};EventEmitter.prototype.prependOnceListener=function(a,d){return checkListener(d),this.prependListener(a,_onceWrap(this,a,d)),this};EventEmitter.prototype.removeListener=function(a,d){var et,nt,tt,bt,mt;if(checkListener(d),nt=this._events,nt===void 0)return this;if(et=nt[a],et===void 0)return this;if(et===d||et.listener===d)--this._eventsCount===0?this._events=Object.create(null):(delete nt[a],nt.removeListener&&this.emit("removeListener",a,et.listener||d));else if(typeof et!="function"){for(tt=-1,bt=et.length-1;bt>=0;bt--)if(et[bt]===d||et[bt].listener===d){mt=et[bt].listener,tt=bt;break}if(tt<0)return this;tt===0?et.shift():spliceOne(et,tt),et.length===1&&(nt[a]=et[0]),nt.removeListener!==void 0&&this.emit("removeListener",a,mt||d)}return this};EventEmitter.prototype.off=EventEmitter.prototype.removeListener;EventEmitter.prototype.removeAllListeners=function(a){var d,et,nt;if(et=this._events,et===void 0)return this;if(et.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):et[a]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete et[a]),this;if(arguments.length===0){var tt=Object.keys(et),bt;for(nt=0;nt=0;nt--)this.removeListener(a,d[nt]);return this};function _listeners(c,a,d){var et=c._events;if(et===void 0)return[];var nt=et[a];return nt===void 0?[]:typeof nt=="function"?d?[nt.listener||nt]:[nt]:d?unwrapListeners(nt):arrayClone(nt,nt.length)}EventEmitter.prototype.listeners=function(a){return _listeners(this,a,!0)};EventEmitter.prototype.rawListeners=function(a){return _listeners(this,a,!1)};EventEmitter.listenerCount=function(c,a){return typeof c.listenerCount=="function"?c.listenerCount(a):listenerCount.call(c,a)};EventEmitter.prototype.listenerCount=listenerCount;function listenerCount(c){var a=this._events;if(a!==void 0){var d=a[c];if(typeof d=="function")return 1;if(d!==void 0)return d.length}return 0}EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?ReflectOwnKeys(this._events):[]};function arrayClone(c,a){for(var d=new Array(a),et=0;et"u"||!getProto$1?undefined$1:getProto$1(Uint8Array),INTRINSICS={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?undefined$1:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?undefined$1:ArrayBuffer,"%ArrayIteratorPrototype%":hasSymbols&&getProto$1?getProto$1([][Symbol.iterator]()):undefined$1,"%AsyncFromSyncIteratorPrototype%":undefined$1,"%AsyncFunction%":needsEval,"%AsyncGenerator%":needsEval,"%AsyncGeneratorFunction%":needsEval,"%AsyncIteratorPrototype%":needsEval,"%Atomics%":typeof Atomics>"u"?undefined$1:Atomics,"%BigInt%":typeof BigInt>"u"?undefined$1:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?undefined$1:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?undefined$1:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?undefined$1:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":$Error,"%eval%":eval,"%EvalError%":$EvalError,"%Float32Array%":typeof Float32Array>"u"?undefined$1:Float32Array,"%Float64Array%":typeof Float64Array>"u"?undefined$1:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?undefined$1:FinalizationRegistry,"%Function%":$Function,"%GeneratorFunction%":needsEval,"%Int8Array%":typeof Int8Array>"u"?undefined$1:Int8Array,"%Int16Array%":typeof Int16Array>"u"?undefined$1:Int16Array,"%Int32Array%":typeof Int32Array>"u"?undefined$1:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":hasSymbols&&getProto$1?getProto$1(getProto$1([][Symbol.iterator]())):undefined$1,"%JSON%":typeof JSON=="object"?JSON:undefined$1,"%Map%":typeof Map>"u"?undefined$1:Map,"%MapIteratorPrototype%":typeof Map>"u"||!hasSymbols||!getProto$1?undefined$1:getProto$1(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?undefined$1:Promise,"%Proxy%":typeof Proxy>"u"?undefined$1:Proxy,"%RangeError%":$RangeError,"%ReferenceError%":$ReferenceError,"%Reflect%":typeof Reflect>"u"?undefined$1:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?undefined$1:Set,"%SetIteratorPrototype%":typeof Set>"u"||!hasSymbols||!getProto$1?undefined$1:getProto$1(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?undefined$1:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":hasSymbols&&getProto$1?getProto$1(""[Symbol.iterator]()):undefined$1,"%Symbol%":hasSymbols?Symbol:undefined$1,"%SyntaxError%":$SyntaxError$1,"%ThrowTypeError%":ThrowTypeError,"%TypedArray%":TypedArray,"%TypeError%":$TypeError$2,"%Uint8Array%":typeof Uint8Array>"u"?undefined$1:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?undefined$1:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?undefined$1:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?undefined$1:Uint32Array,"%URIError%":$URIError,"%WeakMap%":typeof WeakMap>"u"?undefined$1:WeakMap,"%WeakRef%":typeof WeakRef>"u"?undefined$1:WeakRef,"%WeakSet%":typeof WeakSet>"u"?undefined$1:WeakSet};if(getProto$1)try{null.error}catch(c){var errorProto=getProto$1(getProto$1(c));INTRINSICS["%Error.prototype%"]=errorProto}var doEval=function c(a){var d;if(a==="%AsyncFunction%")d=getEvalledConstructor("async function () {}");else if(a==="%GeneratorFunction%")d=getEvalledConstructor("function* () {}");else if(a==="%AsyncGeneratorFunction%")d=getEvalledConstructor("async function* () {}");else if(a==="%AsyncGenerator%"){var et=c("%AsyncGeneratorFunction%");et&&(d=et.prototype)}else if(a==="%AsyncIteratorPrototype%"){var nt=c("%AsyncGenerator%");nt&&getProto$1&&(d=getProto$1(nt.prototype))}return INTRINSICS[a]=d,d},LEGACY_ALIASES={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},bind=functionBind,hasOwn=hasown,$concat=bind.call(Function.call,Array.prototype.concat),$spliceApply=bind.call(Function.apply,Array.prototype.splice),$replace=bind.call(Function.call,String.prototype.replace),$strSlice=bind.call(Function.call,String.prototype.slice),$exec=bind.call(Function.call,RegExp.prototype.exec),rePropName=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,reEscapeChar=/\\(\\)?/g,stringToPath=function(a){var d=$strSlice(a,0,1),et=$strSlice(a,-1);if(d==="%"&&et!=="%")throw new $SyntaxError$1("invalid intrinsic syntax, expected closing `%`");if(et==="%"&&d!=="%")throw new $SyntaxError$1("invalid intrinsic syntax, expected opening `%`");var nt=[];return $replace(a,rePropName,function(tt,bt,mt,vt){nt[nt.length]=mt?$replace(vt,reEscapeChar,"$1"):bt||tt}),nt},getBaseIntrinsic=function(a,d){var et=a,nt;if(hasOwn(LEGACY_ALIASES,et)&&(nt=LEGACY_ALIASES[et],et="%"+nt[0]+"%"),hasOwn(INTRINSICS,et)){var tt=INTRINSICS[et];if(tt===needsEval&&(tt=doEval(et)),typeof tt>"u"&&!d)throw new $TypeError$2("intrinsic "+a+" exists, but is not available. Please file an issue!");return{alias:nt,name:et,value:tt}}throw new $SyntaxError$1("intrinsic "+a+" does not exist!")},getIntrinsic=function(a,d){if(typeof a!="string"||a.length===0)throw new $TypeError$2("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof d!="boolean")throw new $TypeError$2('"allowMissing" argument must be a boolean');if($exec(/^%?[^%]*%?$/,a)===null)throw new $SyntaxError$1("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var et=stringToPath(a),nt=et.length>0?et[0]:"",tt=getBaseIntrinsic("%"+nt+"%",d),bt=tt.name,mt=tt.value,vt=!1,$t=tt.alias;$t&&(nt=$t[0],$spliceApply(et,$concat([0,1],$t)));for(var At=1,Mt=!0;At=et.length){var It=$gOPD$1(mt,Tt);Mt=!!It,Mt&&"get"in It&&!("originalValue"in It.get)?mt=It.get:mt=mt[Tt]}else Mt=hasOwn(mt,Tt),mt=mt[Tt];Mt&&!vt&&(INTRINSICS[bt]=mt)}}return mt},callBind$2={exports:{}},esDefineProperty,hasRequiredEsDefineProperty;function requireEsDefineProperty(){if(hasRequiredEsDefineProperty)return esDefineProperty;hasRequiredEsDefineProperty=1;var c=getIntrinsic,a=c("%Object.defineProperty%",!0)||!1;if(a)try{a({},"a",{value:1})}catch{a=!1}return esDefineProperty=a,esDefineProperty}var GetIntrinsic$2=getIntrinsic,$gOPD=GetIntrinsic$2("%Object.getOwnPropertyDescriptor%",!0);if($gOPD)try{$gOPD([],"length")}catch{$gOPD=null}var gopd$1=$gOPD,$defineProperty$1=requireEsDefineProperty(),$SyntaxError=syntax,$TypeError$1=type,gopd=gopd$1,defineDataProperty=function(a,d,et){if(!a||typeof a!="object"&&typeof a!="function")throw new $TypeError$1("`obj` must be an object or a function`");if(typeof d!="string"&&typeof d!="symbol")throw new $TypeError$1("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new $TypeError$1("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new $TypeError$1("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new $TypeError$1("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new $TypeError$1("`loose`, if provided, must be a boolean");var nt=arguments.length>3?arguments[3]:null,tt=arguments.length>4?arguments[4]:null,bt=arguments.length>5?arguments[5]:null,mt=arguments.length>6?arguments[6]:!1,vt=!!gopd&&gopd(a,d);if($defineProperty$1)$defineProperty$1(a,d,{configurable:bt===null&&vt?vt.configurable:!bt,enumerable:nt===null&&vt?vt.enumerable:!nt,value:et,writable:tt===null&&vt?vt.writable:!tt});else if(mt||!nt&&!tt&&!bt)a[d]=et;else throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},$defineProperty=requireEsDefineProperty(),hasPropertyDescriptors=function(){return!!$defineProperty};hasPropertyDescriptors.hasArrayLengthDefineBug=function(){if(!$defineProperty)return null;try{return $defineProperty([],"length",{value:1}).length!==1}catch{return!0}};var hasPropertyDescriptors_1=hasPropertyDescriptors,GetIntrinsic$1=getIntrinsic,define=defineDataProperty,hasDescriptors=hasPropertyDescriptors_1(),gOPD$1=gopd$1,$TypeError=type,$floor=GetIntrinsic$1("%Math.floor%"),setFunctionLength=function(a,d){if(typeof a!="function")throw new $TypeError("`fn` is not a function");if(typeof d!="number"||d<0||d>4294967295||$floor(d)!==d)throw new $TypeError("`length` must be a positive 32-bit integer");var et=arguments.length>2&&!!arguments[2],nt=!0,tt=!0;if("length"in a&&gOPD$1){var bt=gOPD$1(a,"length");bt&&!bt.configurable&&(nt=!1),bt&&!bt.writable&&(tt=!1)}return(nt||tt||!et)&&(hasDescriptors?define(a,"length",d,!0,!0):define(a,"length",d)),a};(function(c){var a=functionBind,d=getIntrinsic,et=setFunctionLength,nt=type,tt=d("%Function.prototype.apply%"),bt=d("%Function.prototype.call%"),mt=d("%Reflect.apply%",!0)||a.call(bt,tt),vt=requireEsDefineProperty(),$t=d("%Math.max%");c.exports=function(Tt){if(typeof Tt!="function")throw new nt("a function is required");var Rt=mt(a,bt,arguments);return et(Rt,1+$t(0,Tt.length-(arguments.length-1)),!0)};var At=function(){return mt(a,tt,arguments)};vt?vt(c.exports,"apply",{value:At}):c.exports.apply=At})(callBind$2);var callBindExports=callBind$2.exports,GetIntrinsic=getIntrinsic,callBind$1=callBindExports,$indexOf$1=callBind$1(GetIntrinsic("String.prototype.indexOf")),callBound$2=function(a,d){var et=GetIntrinsic(a,!!d);return typeof et=="function"&&$indexOf$1(a,".prototype.")>-1?callBind$1(et):et},hasToStringTag$3=shams(),callBound$1=callBound$2,$toString$1=callBound$1("Object.prototype.toString"),isStandardArguments=function(a){return hasToStringTag$3&&a&&typeof a=="object"&&Symbol.toStringTag in a?!1:$toString$1(a)==="[object Arguments]"},isLegacyArguments=function(a){return isStandardArguments(a)?!0:a!==null&&typeof a=="object"&&typeof a.length=="number"&&a.length>=0&&$toString$1(a)!=="[object Array]"&&$toString$1(a.callee)==="[object Function]"},supportsStandardArguments=function(){return isStandardArguments(arguments)}();isStandardArguments.isLegacyArguments=isLegacyArguments;var isArguments=supportsStandardArguments?isStandardArguments:isLegacyArguments,toStr$2=Object.prototype.toString,fnToStr$1=Function.prototype.toString,isFnRegex=/^\s*(?:function)?\*/,hasToStringTag$2=shams(),getProto=Object.getPrototypeOf,getGeneratorFunc=function(){if(!hasToStringTag$2)return!1;try{return Function("return function*() {}")()}catch{}},GeneratorFunction,isGeneratorFunction=function(a){if(typeof a!="function")return!1;if(isFnRegex.test(fnToStr$1.call(a)))return!0;if(!hasToStringTag$2){var d=toStr$2.call(a);return d==="[object GeneratorFunction]"}if(!getProto)return!1;if(typeof GeneratorFunction>"u"){var et=getGeneratorFunc();GeneratorFunction=et?getProto(et):!1}return getProto(a)===GeneratorFunction},fnToStr=Function.prototype.toString,reflectApply=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,badArrayLike,isCallableMarker;if(typeof reflectApply=="function"&&typeof Object.defineProperty=="function")try{badArrayLike=Object.defineProperty({},"length",{get:function(){throw isCallableMarker}}),isCallableMarker={},reflectApply(function(){throw 42},null,badArrayLike)}catch(c){c!==isCallableMarker&&(reflectApply=null)}else reflectApply=null;var constructorRegex=/^\s*class\b/,isES6ClassFn=function(a){try{var d=fnToStr.call(a);return constructorRegex.test(d)}catch{return!1}},tryFunctionObject=function(a){try{return isES6ClassFn(a)?!1:(fnToStr.call(a),!0)}catch{return!1}},toStr$1=Object.prototype.toString,objectClass="[object Object]",fnClass="[object Function]",genClass="[object GeneratorFunction]",ddaClass="[object HTMLAllCollection]",ddaClass2="[object HTML document.all class]",ddaClass3="[object HTMLCollection]",hasToStringTag$1=typeof Symbol=="function"&&!!Symbol.toStringTag,isIE68=!(0 in[,]),isDDA=function(){return!1};if(typeof document=="object"){var all=document.all;toStr$1.call(all)===toStr$1.call(document.all)&&(isDDA=function(a){if((isIE68||!a)&&(typeof a>"u"||typeof a=="object"))try{var d=toStr$1.call(a);return(d===ddaClass||d===ddaClass2||d===ddaClass3||d===objectClass)&&a("")==null}catch{}return!1})}var isCallable$1=reflectApply?function(a){if(isDDA(a))return!0;if(!a||typeof a!="function"&&typeof a!="object")return!1;try{reflectApply(a,null,badArrayLike)}catch(d){if(d!==isCallableMarker)return!1}return!isES6ClassFn(a)&&tryFunctionObject(a)}:function(a){if(isDDA(a))return!0;if(!a||typeof a!="function"&&typeof a!="object")return!1;if(hasToStringTag$1)return tryFunctionObject(a);if(isES6ClassFn(a))return!1;var d=toStr$1.call(a);return d!==fnClass&&d!==genClass&&!/^\[object HTML/.test(d)?!1:tryFunctionObject(a)},isCallable=isCallable$1,toStr=Object.prototype.toString,hasOwnProperty=Object.prototype.hasOwnProperty,forEachArray=function(a,d,et){for(var nt=0,tt=a.length;nt=3&&(nt=et),toStr.call(a)==="[object Array]"?forEachArray(a,d,nt):typeof a=="string"?forEachString(a,d,nt):forEachObject(a,d,nt)},forEach_1=forEach$1,possibleTypedArrayNames=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"],possibleNames=possibleTypedArrayNames,g$1=typeof globalThis>"u"?commonjsGlobal:globalThis,availableTypedArrays$1=function(){for(var a=[],d=0;d"u"?commonjsGlobal:globalThis,typedArrays=availableTypedArrays(),$slice=callBound("String.prototype.slice"),getPrototypeOf=Object.getPrototypeOf,$indexOf=callBound("Array.prototype.indexOf",!0)||function(a,d){for(var et=0;et-1?d:d!=="Object"?!1:trySlices(a)}return gOPD?tryTypedArrays(a):null},whichTypedArray=whichTypedArray$1,isTypedArray=function(a){return!!whichTypedArray(a)};(function(c){var a=isArguments,d=isGeneratorFunction,et=whichTypedArray$1,nt=isTypedArray;function tt(u0){return u0.call.bind(u0)}var bt=typeof BigInt<"u",mt=typeof Symbol<"u",vt=tt(Object.prototype.toString),$t=tt(Number.prototype.valueOf),At=tt(String.prototype.valueOf),Mt=tt(Boolean.prototype.valueOf);if(bt)var Tt=tt(BigInt.prototype.valueOf);if(mt)var Rt=tt(Symbol.prototype.valueOf);function kt(u0,J0){if(typeof u0!="object")return!1;try{return J0(u0),!0}catch{return!1}}c.isArgumentsObject=a,c.isGeneratorFunction=d,c.isTypedArray=nt;function It(u0){return typeof Promise<"u"&&u0 instanceof Promise||u0!==null&&typeof u0=="object"&&typeof u0.then=="function"&&typeof u0.catch=="function"}c.isPromise=It;function Dt(u0){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(u0):nt(u0)||Lt(u0)}c.isArrayBufferView=Dt;function Nt(u0){return et(u0)==="Uint8Array"}c.isUint8Array=Nt;function Ot(u0){return et(u0)==="Uint8ClampedArray"}c.isUint8ClampedArray=Ot;function Ut(u0){return et(u0)==="Uint16Array"}c.isUint16Array=Ut;function Gt(u0){return et(u0)==="Uint32Array"}c.isUint32Array=Gt;function Wt(u0){return et(u0)==="Int8Array"}c.isInt8Array=Wt;function Xt(u0){return et(u0)==="Int16Array"}c.isInt16Array=Xt;function a0(u0){return et(u0)==="Int32Array"}c.isInt32Array=a0;function n0(u0){return et(u0)==="Float32Array"}c.isFloat32Array=n0;function t0(u0){return et(u0)==="Float64Array"}c.isFloat64Array=t0;function c0(u0){return et(u0)==="BigInt64Array"}c.isBigInt64Array=c0;function Ct(u0){return et(u0)==="BigUint64Array"}c.isBigUint64Array=Ct;function dt(u0){return vt(u0)==="[object Map]"}dt.working=typeof Map<"u"&&dt(new Map);function yt(u0){return typeof Map>"u"?!1:dt.working?dt(u0):u0 instanceof Map}c.isMap=yt;function gt(u0){return vt(u0)==="[object Set]"}gt.working=typeof Set<"u"&>(new Set);function xt(u0){return typeof Set>"u"?!1:gt.working?gt(u0):u0 instanceof Set}c.isSet=xt;function St(u0){return vt(u0)==="[object WeakMap]"}St.working=typeof WeakMap<"u"&&St(new WeakMap);function _t(u0){return typeof WeakMap>"u"?!1:St.working?St(u0):u0 instanceof WeakMap}c.isWeakMap=_t;function Pt(u0){return vt(u0)==="[object WeakSet]"}Pt.working=typeof WeakSet<"u"&&Pt(new WeakSet);function Et(u0){return Pt(u0)}c.isWeakSet=Et;function ht(u0){return vt(u0)==="[object ArrayBuffer]"}ht.working=typeof ArrayBuffer<"u"&&ht(new ArrayBuffer);function wt(u0){return typeof ArrayBuffer>"u"?!1:ht.working?ht(u0):u0 instanceof ArrayBuffer}c.isArrayBuffer=wt;function Bt(u0){return vt(u0)==="[object DataView]"}Bt.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&Bt(new DataView(new ArrayBuffer(1),0,1));function Lt(u0){return typeof DataView>"u"?!1:Bt.working?Bt(u0):u0 instanceof DataView}c.isDataView=Lt;var jt=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function Ft(u0){return vt(u0)==="[object SharedArrayBuffer]"}function Vt(u0){return typeof jt>"u"?!1:(typeof Ft.working>"u"&&(Ft.working=Ft(new jt)),Ft.working?Ft(u0):u0 instanceof jt)}c.isSharedArrayBuffer=Vt;function zt(u0){return vt(u0)==="[object AsyncFunction]"}c.isAsyncFunction=zt;function qt(u0){return vt(u0)==="[object Map Iterator]"}c.isMapIterator=qt;function Kt(u0){return vt(u0)==="[object Set Iterator]"}c.isSetIterator=Kt;function e0(u0){return vt(u0)==="[object Generator]"}c.isGeneratorObject=e0;function Zt(u0){return vt(u0)==="[object WebAssembly.Module]"}c.isWebAssemblyCompiledModule=Zt;function Jt(u0){return kt(u0,$t)}c.isNumberObject=Jt;function i0(u0){return kt(u0,At)}c.isStringObject=i0;function h0(u0){return kt(u0,Mt)}c.isBooleanObject=h0;function o0(u0){return bt&&kt(u0,Tt)}c.isBigIntObject=o0;function l0(u0){return mt&&kt(u0,Rt)}c.isSymbolObject=l0;function $0(u0){return Jt(u0)||i0(u0)||h0(u0)||o0(u0)||l0(u0)}c.isBoxedPrimitive=$0;function p0(u0){return typeof Uint8Array<"u"&&(wt(u0)||Vt(u0))}c.isAnyArrayBuffer=p0,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(u0){Object.defineProperty(c,u0,{enumerable:!1,value:function(){throw new Error(u0+" is not supported in userland")}})})})(types);var isBufferBrowser=function(a){return a&&typeof a=="object"&&typeof a.copy=="function"&&typeof a.fill=="function"&&typeof a.readUInt8=="function"};(function(c){var a=Object.getOwnPropertyDescriptors||function(Lt){for(var jt=Object.keys(Lt),Ft={},Vt=0;Vt=Vt)return Kt;switch(Kt){case"%s":return String(Ft[jt++]);case"%d":return Number(Ft[jt++]);case"%j":try{return JSON.stringify(Ft[jt++])}catch{return"[Circular]"}default:return Kt}}),qt=Ft[jt];jt"u")return function(){return c.deprecate(Bt,Lt).apply(this,arguments)};var jt=!1;function Ft(){if(!jt){if(dist$2.process.throwDeprecation)throw new Error(Lt);dist$2.process.traceDeprecation?console.trace(Lt):console.error(Lt),jt=!0}return Bt.apply(this,arguments)}return Ft};var et={},nt=/^$/;if({}.NODE_DEBUG){var tt={}.NODE_DEBUG;tt=tt.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),nt=new RegExp("^"+tt+"$","i")}c.debuglog=function(Bt){if(Bt=Bt.toUpperCase(),!et[Bt])if(nt.test(Bt)){var Lt=dist$2.process.pid;et[Bt]=function(){var jt=c.format.apply(c,arguments);console.error("%s %d: %s",Bt,Lt,jt)}}else et[Bt]=function(){};return et[Bt]};function bt(Bt,Lt){var jt={seen:[],stylize:vt};return arguments.length>=3&&(jt.depth=arguments[2]),arguments.length>=4&&(jt.colors=arguments[3]),Nt(Lt)?jt.showHidden=Lt:Lt&&c._extend(jt,Lt),a0(jt.showHidden)&&(jt.showHidden=!1),a0(jt.depth)&&(jt.depth=2),a0(jt.colors)&&(jt.colors=!1),a0(jt.customInspect)&&(jt.customInspect=!0),jt.colors&&(jt.stylize=mt),At(jt,Bt,jt.depth)}c.inspect=bt,bt.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},bt.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function mt(Bt,Lt){var jt=bt.styles[Lt];return jt?"\x1B["+bt.colors[jt][0]+"m"+Bt+"\x1B["+bt.colors[jt][1]+"m":Bt}function vt(Bt,Lt){return Bt}function $t(Bt){var Lt={};return Bt.forEach(function(jt,Ft){Lt[jt]=!0}),Lt}function At(Bt,Lt,jt){if(Bt.customInspect&&Lt&&dt(Lt.inspect)&&Lt.inspect!==c.inspect&&!(Lt.constructor&&Lt.constructor.prototype===Lt)){var Ft=Lt.inspect(jt,Bt);return Wt(Ft)||(Ft=At(Bt,Ft,jt)),Ft}var Vt=Mt(Bt,Lt);if(Vt)return Vt;var zt=Object.keys(Lt),qt=$t(zt);if(Bt.showHidden&&(zt=Object.getOwnPropertyNames(Lt)),Ct(Lt)&&(zt.indexOf("message")>=0||zt.indexOf("description")>=0))return Tt(Lt);if(zt.length===0){if(dt(Lt)){var Kt=Lt.name?": "+Lt.name:"";return Bt.stylize("[Function"+Kt+"]","special")}if(n0(Lt))return Bt.stylize(RegExp.prototype.toString.call(Lt),"regexp");if(c0(Lt))return Bt.stylize(Date.prototype.toString.call(Lt),"date");if(Ct(Lt))return Tt(Lt)}var e0="",Zt=!1,Jt=["{","}"];if(Dt(Lt)&&(Zt=!0,Jt=["[","]"]),dt(Lt)){var i0=Lt.name?": "+Lt.name:"";e0=" [Function"+i0+"]"}if(n0(Lt)&&(e0=" "+RegExp.prototype.toString.call(Lt)),c0(Lt)&&(e0=" "+Date.prototype.toUTCString.call(Lt)),Ct(Lt)&&(e0=" "+Tt(Lt)),zt.length===0&&(!Zt||Lt.length==0))return Jt[0]+e0+Jt[1];if(jt<0)return n0(Lt)?Bt.stylize(RegExp.prototype.toString.call(Lt),"regexp"):Bt.stylize("[Object]","special");Bt.seen.push(Lt);var h0;return Zt?h0=Rt(Bt,Lt,jt,qt,zt):h0=zt.map(function(o0){return kt(Bt,Lt,jt,qt,o0,Zt)}),Bt.seen.pop(),It(h0,e0,Jt)}function Mt(Bt,Lt){if(a0(Lt))return Bt.stylize("undefined","undefined");if(Wt(Lt)){var jt="'"+JSON.stringify(Lt).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return Bt.stylize(jt,"string")}if(Gt(Lt))return Bt.stylize(""+Lt,"number");if(Nt(Lt))return Bt.stylize(""+Lt,"boolean");if(Ot(Lt))return Bt.stylize("null","null")}function Tt(Bt){return"["+Error.prototype.toString.call(Bt)+"]"}function Rt(Bt,Lt,jt,Ft,Vt){for(var zt=[],qt=0,Kt=Lt.length;qt-1&&(zt?Kt=Kt.split(` +`).map(function(Zt){return" "+Zt}).join(` +`).slice(2):Kt=` +`+Kt.split(` +`).map(function(Zt){return" "+Zt}).join(` +`))):Kt=Bt.stylize("[Circular]","special")),a0(qt)){if(zt&&Vt.match(/^\d+$/))return Kt;qt=JSON.stringify(""+Vt),qt.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(qt=qt.slice(1,-1),qt=Bt.stylize(qt,"name")):(qt=qt.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),qt=Bt.stylize(qt,"string"))}return qt+": "+Kt}function It(Bt,Lt,jt){var Ft=Bt.reduce(function(Vt,zt){return zt.indexOf(` +`)>=0,Vt+zt.replace(/\u001b\[\d\d?m/g,"").length+1},0);return Ft>60?jt[0]+(Lt===""?"":Lt+` + `)+" "+Bt.join(`, + `)+" "+jt[1]:jt[0]+Lt+" "+Bt.join(", ")+" "+jt[1]}c.types=types;function Dt(Bt){return Array.isArray(Bt)}c.isArray=Dt;function Nt(Bt){return typeof Bt=="boolean"}c.isBoolean=Nt;function Ot(Bt){return Bt===null}c.isNull=Ot;function Ut(Bt){return Bt==null}c.isNullOrUndefined=Ut;function Gt(Bt){return typeof Bt=="number"}c.isNumber=Gt;function Wt(Bt){return typeof Bt=="string"}c.isString=Wt;function Xt(Bt){return typeof Bt=="symbol"}c.isSymbol=Xt;function a0(Bt){return Bt===void 0}c.isUndefined=a0;function n0(Bt){return t0(Bt)&>(Bt)==="[object RegExp]"}c.isRegExp=n0,c.types.isRegExp=n0;function t0(Bt){return typeof Bt=="object"&&Bt!==null}c.isObject=t0;function c0(Bt){return t0(Bt)&>(Bt)==="[object Date]"}c.isDate=c0,c.types.isDate=c0;function Ct(Bt){return t0(Bt)&&(gt(Bt)==="[object Error]"||Bt instanceof Error)}c.isError=Ct,c.types.isNativeError=Ct;function dt(Bt){return typeof Bt=="function"}c.isFunction=dt;function yt(Bt){return Bt===null||typeof Bt=="boolean"||typeof Bt=="number"||typeof Bt=="string"||typeof Bt=="symbol"||typeof Bt>"u"}c.isPrimitive=yt,c.isBuffer=isBufferBrowser;function gt(Bt){return Object.prototype.toString.call(Bt)}function xt(Bt){return Bt<10?"0"+Bt.toString(10):Bt.toString(10)}var St=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function _t(){var Bt=new Date,Lt=[xt(Bt.getHours()),xt(Bt.getMinutes()),xt(Bt.getSeconds())].join(":");return[Bt.getDate(),St[Bt.getMonth()],Lt].join(" ")}c.log=function(){console.log("%s - %s",_t(),c.format.apply(c,arguments))},c.inherits=inherits_browserExports,c._extend=function(Bt,Lt){if(!Lt||!t0(Lt))return Bt;for(var jt=Object.keys(Lt),Ft=jt.length;Ft--;)Bt[jt[Ft]]=Lt[jt[Ft]];return Bt};function Pt(Bt,Lt){return Object.prototype.hasOwnProperty.call(Bt,Lt)}var Et=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;c.promisify=function(Lt){if(typeof Lt!="function")throw new TypeError('The "original" argument must be of type Function');if(Et&&Lt[Et]){var jt=Lt[Et];if(typeof jt!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(jt,Et,{value:jt,enumerable:!1,writable:!1,configurable:!0}),jt}function jt(){for(var Ft,Vt,zt=new Promise(function(e0,Zt){Ft=e0,Vt=Zt}),qt=[],Kt=0;Kt0?this.tail.next=Nt:this.head=Nt,this.tail=Nt,++this.length}},{key:"unshift",value:function(Dt){var Nt={data:Dt,next:this.head};this.length===0&&(this.tail=Nt),this.head=Nt,++this.length}},{key:"shift",value:function(){if(this.length!==0){var Dt=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,Dt}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(Dt){if(this.length===0)return"";for(var Nt=this.head,Ot=""+Nt.data;Nt=Nt.next;)Ot+=Dt+Nt.data;return Ot}},{key:"concat",value:function(Dt){if(this.length===0)return $t.alloc(0);for(var Nt=$t.allocUnsafe(Dt>>>0),Ot=this.head,Ut=0;Ot;)Rt(Ot.data,Nt,Ut),Ut+=Ot.data.length,Ot=Ot.next;return Nt}},{key:"consume",value:function(Dt,Nt){var Ot;return DtGt.length?Gt.length:Dt;if(Wt===Gt.length?Ut+=Gt:Ut+=Gt.slice(0,Dt),Dt-=Wt,Dt===0){Wt===Gt.length?(++Ot,Nt.next?this.head=Nt.next:this.head=this.tail=null):(this.head=Nt,Nt.data=Gt.slice(Wt));break}++Ot}return this.length-=Ot,Ut}},{key:"_getBuffer",value:function(Dt){var Nt=$t.allocUnsafe(Dt),Ot=this.head,Ut=1;for(Ot.data.copy(Nt),Dt-=Ot.data.length;Ot=Ot.next;){var Gt=Ot.data,Wt=Dt>Gt.length?Gt.length:Dt;if(Gt.copy(Nt,Nt.length-Dt,0,Wt),Dt-=Wt,Dt===0){Wt===Gt.length?(++Ut,Ot.next?this.head=Ot.next:this.head=this.tail=null):(this.head=Ot,Ot.data=Gt.slice(Wt));break}++Ut}return this.length-=Ut,Nt}},{key:Tt,value:function(Dt,Nt){return Mt(this,a(a({},Nt),{},{depth:0,customInspect:!1}))}}]),kt}(),buffer_list}var destroy_1$1,hasRequiredDestroy;function requireDestroy(){if(hasRequiredDestroy)return destroy_1$1;hasRequiredDestroy=1;function c(bt,mt){var vt=this,$t=this._readableState&&this._readableState.destroyed,At=this._writableState&&this._writableState.destroyed;return $t||At?(mt?mt(bt):bt&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,dist$2.process.nextTick(nt,this,bt)):dist$2.process.nextTick(nt,this,bt)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(bt||null,function(Mt){!mt&&Mt?vt._writableState?vt._writableState.errorEmitted?dist$2.process.nextTick(d,vt):(vt._writableState.errorEmitted=!0,dist$2.process.nextTick(a,vt,Mt)):dist$2.process.nextTick(a,vt,Mt):mt?(dist$2.process.nextTick(d,vt),mt(Mt)):dist$2.process.nextTick(d,vt)}),this)}function a(bt,mt){nt(bt,mt),d(bt)}function d(bt){bt._writableState&&!bt._writableState.emitClose||bt._readableState&&!bt._readableState.emitClose||bt.emit("close")}function et(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function nt(bt,mt){bt.emit("error",mt)}function tt(bt,mt){var vt=bt._readableState,$t=bt._writableState;vt&&vt.autoDestroy||$t&&$t.autoDestroy?bt.destroy(mt):bt.emit("error",mt)}return destroy_1$1={destroy:c,undestroy:et,errorOrDestroy:tt},destroy_1$1}var errorsBrowser={},hasRequiredErrorsBrowser;function requireErrorsBrowser(){if(hasRequiredErrorsBrowser)return errorsBrowser;hasRequiredErrorsBrowser=1;function c(mt,vt){mt.prototype=Object.create(vt.prototype),mt.prototype.constructor=mt,mt.__proto__=vt}var a={};function d(mt,vt,$t){$t||($t=Error);function At(Tt,Rt,kt){return typeof vt=="string"?vt:vt(Tt,Rt,kt)}var Mt=function(Tt){c(Rt,Tt);function Rt(kt,It,Dt){return Tt.call(this,At(kt,It,Dt))||this}return Rt}($t);Mt.prototype.name=$t.name,Mt.prototype.code=mt,a[mt]=Mt}function et(mt,vt){if(Array.isArray(mt)){var $t=mt.length;return mt=mt.map(function(At){return String(At)}),$t>2?"one of ".concat(vt," ").concat(mt.slice(0,$t-1).join(", "),", or ")+mt[$t-1]:$t===2?"one of ".concat(vt," ").concat(mt[0]," or ").concat(mt[1]):"of ".concat(vt," ").concat(mt[0])}else return"of ".concat(vt," ").concat(String(mt))}function nt(mt,vt,$t){return mt.substr(!$t||$t<0?0:+$t,vt.length)===vt}function tt(mt,vt,$t){return($t===void 0||$t>mt.length)&&($t=mt.length),mt.substring($t-vt.length,$t)===vt}function bt(mt,vt,$t){return typeof $t!="number"&&($t=0),$t+vt.length>mt.length?!1:mt.indexOf(vt,$t)!==-1}return d("ERR_INVALID_OPT_VALUE",function(mt,vt){return'The value "'+vt+'" is invalid for option "'+mt+'"'},TypeError),d("ERR_INVALID_ARG_TYPE",function(mt,vt,$t){var At;typeof vt=="string"&&nt(vt,"not ")?(At="must not be",vt=vt.replace(/^not /,"")):At="must be";var Mt;if(tt(mt," argument"))Mt="The ".concat(mt," ").concat(At," ").concat(et(vt,"type"));else{var Tt=bt(mt,".")?"property":"argument";Mt='The "'.concat(mt,'" ').concat(Tt," ").concat(At," ").concat(et(vt,"type"))}return Mt+=". Received type ".concat(typeof $t),Mt},TypeError),d("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),d("ERR_METHOD_NOT_IMPLEMENTED",function(mt){return"The "+mt+" method is not implemented"}),d("ERR_STREAM_PREMATURE_CLOSE","Premature close"),d("ERR_STREAM_DESTROYED",function(mt){return"Cannot call "+mt+" after a stream was destroyed"}),d("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),d("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),d("ERR_STREAM_WRITE_AFTER_END","write after end"),d("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),d("ERR_UNKNOWN_ENCODING",function(mt){return"Unknown encoding: "+mt},TypeError),d("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),errorsBrowser.codes=a,errorsBrowser}var state,hasRequiredState;function requireState(){if(hasRequiredState)return state;hasRequiredState=1;var c=requireErrorsBrowser().codes.ERR_INVALID_OPT_VALUE;function a(et,nt,tt){return et.highWaterMark!=null?et.highWaterMark:nt?et[tt]:null}function d(et,nt,tt,bt){var mt=a(nt,bt,tt);if(mt!=null){if(!(isFinite(mt)&&Math.floor(mt)===mt)||mt<0){var vt=bt?tt:"highWaterMark";throw new c(vt,mt)}return Math.floor(mt)}return et.objectMode?16:16*1024}return state={getHighWaterMark:d},state}var browser$a=deprecate;function deprecate(c,a){if(config$1("noDeprecation"))return c;var d=!1;function et(){if(!d){if(config$1("throwDeprecation"))throw new Error(a);config$1("traceDeprecation")?console.trace(a):console.warn(a),d=!0}return c.apply(this,arguments)}return et}function config$1(c){try{if(!commonjsGlobal.localStorage)return!1}catch{return!1}var a=commonjsGlobal.localStorage[c];return a==null?!1:String(a).toLowerCase()==="true"}var _stream_writable$1,hasRequired_stream_writable$1;function require_stream_writable$1(){if(hasRequired_stream_writable$1)return _stream_writable$1;hasRequired_stream_writable$1=1,_stream_writable$1=n0;function c(Vt){var zt=this;this.next=null,this.entry=null,this.finish=function(){Ft(zt,Vt)}}var a;n0.WritableState=Xt;var d={deprecate:browser$a},et=requireStreamBrowser(),nt=bufferPolyfill.Buffer,tt=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function bt(Vt){return nt.from(Vt)}function mt(Vt){return nt.isBuffer(Vt)||Vt instanceof tt}var vt=requireDestroy(),$t=requireState(),At=$t.getHighWaterMark,Mt=requireErrorsBrowser().codes,Tt=Mt.ERR_INVALID_ARG_TYPE,Rt=Mt.ERR_METHOD_NOT_IMPLEMENTED,kt=Mt.ERR_MULTIPLE_CALLBACK,It=Mt.ERR_STREAM_CANNOT_PIPE,Dt=Mt.ERR_STREAM_DESTROYED,Nt=Mt.ERR_STREAM_NULL_VALUES,Ot=Mt.ERR_STREAM_WRITE_AFTER_END,Ut=Mt.ERR_UNKNOWN_ENCODING,Gt=vt.errorOrDestroy;inherits_browserExports(n0,et);function Wt(){}function Xt(Vt,zt,qt){a=a||require_stream_duplex$1(),Vt=Vt||{},typeof qt!="boolean"&&(qt=zt instanceof a),this.objectMode=!!Vt.objectMode,qt&&(this.objectMode=this.objectMode||!!Vt.writableObjectMode),this.highWaterMark=At(this,Vt,"writableHighWaterMark",qt),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Kt=Vt.decodeStrings===!1;this.decodeStrings=!Kt,this.defaultEncoding=Vt.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e0){St(zt,e0)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=Vt.emitClose!==!1,this.autoDestroy=!!Vt.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new c(this)}Xt.prototype.getBuffer=function(){for(var zt=this.bufferedRequest,qt=[];zt;)qt.push(zt),zt=zt.next;return qt},function(){try{Object.defineProperty(Xt.prototype,"buffer",{get:d.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var a0;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(a0=Function.prototype[Symbol.hasInstance],Object.defineProperty(n0,Symbol.hasInstance,{value:function(zt){return a0.call(this,zt)?!0:this!==n0?!1:zt&&zt._writableState instanceof Xt}})):a0=function(zt){return zt instanceof this};function n0(Vt){a=a||require_stream_duplex$1();var zt=this instanceof a;if(!zt&&!a0.call(n0,this))return new n0(Vt);this._writableState=new Xt(Vt,this,zt),this.writable=!0,Vt&&(typeof Vt.write=="function"&&(this._write=Vt.write),typeof Vt.writev=="function"&&(this._writev=Vt.writev),typeof Vt.destroy=="function"&&(this._destroy=Vt.destroy),typeof Vt.final=="function"&&(this._final=Vt.final)),et.call(this)}n0.prototype.pipe=function(){Gt(this,new It)};function t0(Vt,zt){var qt=new Ot;Gt(Vt,qt),dist$2.process.nextTick(zt,qt)}function c0(Vt,zt,qt,Kt){var e0;return qt===null?e0=new Nt:typeof qt!="string"&&!zt.objectMode&&(e0=new Tt("chunk",["string","Buffer"],qt)),e0?(Gt(Vt,e0),dist$2.process.nextTick(Kt,e0),!1):!0}n0.prototype.write=function(Vt,zt,qt){var Kt=this._writableState,e0=!1,Zt=!Kt.objectMode&&mt(Vt);return Zt&&!nt.isBuffer(Vt)&&(Vt=bt(Vt)),typeof zt=="function"&&(qt=zt,zt=null),Zt?zt="buffer":zt||(zt=Kt.defaultEncoding),typeof qt!="function"&&(qt=Wt),Kt.ending?t0(this,qt):(Zt||c0(this,Kt,Vt,qt))&&(Kt.pendingcb++,e0=dt(this,Kt,Zt,Vt,zt,qt)),e0},n0.prototype.cork=function(){this._writableState.corked++},n0.prototype.uncork=function(){var Vt=this._writableState;Vt.corked&&(Vt.corked--,!Vt.writing&&!Vt.corked&&!Vt.bufferProcessing&&Vt.bufferedRequest&&Et(this,Vt))},n0.prototype.setDefaultEncoding=function(zt){if(typeof zt=="string"&&(zt=zt.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((zt+"").toLowerCase())>-1))throw new Ut(zt);return this._writableState.defaultEncoding=zt,this},Object.defineProperty(n0.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function Ct(Vt,zt,qt){return!Vt.objectMode&&Vt.decodeStrings!==!1&&typeof zt=="string"&&(zt=nt.from(zt,qt)),zt}Object.defineProperty(n0.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function dt(Vt,zt,qt,Kt,e0,Zt){if(!qt){var Jt=Ct(zt,Kt,e0);Kt!==Jt&&(qt=!0,e0="buffer",Kt=Jt)}var i0=zt.objectMode?1:Kt.length;zt.length+=i0;var h0=zt.length>5===6?2:c>>4===14?3:c>>3===30?4:c>>6===2?-1:-2}function utf8CheckIncomplete(c,a,d){var et=a.length-1;if(et=0?(nt>0&&(c.lastNeed=nt-1),nt):--et=0?(nt>0&&(c.lastNeed=nt-2),nt):--et=0?(nt>0&&(nt===2?nt=0:c.lastNeed=nt-3),nt):0))}function utf8CheckExtraBytes(c,a,d){if((a[0]&192)!==128)return c.lastNeed=0,"�";if(c.lastNeed>1&&a.length>1){if((a[1]&192)!==128)return c.lastNeed=1,"�";if(c.lastNeed>2&&a.length>2&&(a[2]&192)!==128)return c.lastNeed=2,"�"}}function utf8FillLast(c){var a=this.lastTotal-this.lastNeed,d=utf8CheckExtraBytes(this,c);if(d!==void 0)return d;if(this.lastNeed<=c.length)return c.copy(this.lastChar,a,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,a,0,c.length),this.lastNeed-=c.length}function utf8Text(c,a){var d=utf8CheckIncomplete(this,c,a);if(!this.lastNeed)return c.toString("utf8",a);this.lastTotal=d;var et=c.length-(d-this.lastNeed);return c.copy(this.lastChar,0,et),c.toString("utf8",a,et)}function utf8End(c){var a=c&&c.length?this.write(c):"";return this.lastNeed?a+"�":a}function utf16Text(c,a){if((c.length-a)%2===0){var d=c.toString("utf16le",a);if(d){var et=d.charCodeAt(d.length-1);if(et>=55296&&et<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1],d.slice(0,-1)}return d}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=c[c.length-1],c.toString("utf16le",a,c.length-1)}function utf16End(c){var a=c&&c.length?this.write(c):"";if(this.lastNeed){var d=this.lastTotal-this.lastNeed;return a+this.lastChar.toString("utf16le",0,d)}return a}function base64Text(c,a){var d=(c.length-a)%3;return d===0?c.toString("base64",a):(this.lastNeed=3-d,this.lastTotal=3,d===1?this.lastChar[0]=c[c.length-1]:(this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1]),c.toString("base64",a,c.length-d))}function base64End(c){var a=c&&c.length?this.write(c):"";return this.lastNeed?a+this.lastChar.toString("base64",0,3-this.lastNeed):a}function simpleWrite(c){return c.toString(this.encoding)}function simpleEnd(c){return c&&c.length?this.write(c):""}var endOfStream,hasRequiredEndOfStream;function requireEndOfStream(){if(hasRequiredEndOfStream)return endOfStream;hasRequiredEndOfStream=1;var c=requireErrorsBrowser().codes.ERR_STREAM_PREMATURE_CLOSE;function a(tt){var bt=!1;return function(){if(!bt){bt=!0;for(var mt=arguments.length,vt=new Array(mt),$t=0;$t0)if(typeof Jt!="string"&&!l0.objectMode&&Object.getPrototypeOf(Jt)!==et.prototype&&(Jt=tt(Jt)),h0)l0.endEmitted?Wt(Zt,new Nt):Ct(Zt,l0,Jt,!0);else if(l0.ended)Wt(Zt,new It);else{if(l0.destroyed)return!1;l0.reading=!1,l0.decoder&&!i0?(Jt=l0.decoder.write(Jt),l0.objectMode||Jt.length!==0?Ct(Zt,l0,Jt,!1):Et(Zt,l0)):Ct(Zt,l0,Jt,!1)}else h0||(l0.reading=!1,Et(Zt,l0))}return!l0.ended&&(l0.length=yt?Zt=yt:(Zt--,Zt|=Zt>>>1,Zt|=Zt>>>2,Zt|=Zt>>>4,Zt|=Zt>>>8,Zt|=Zt>>>16,Zt++),Zt}function xt(Zt,Jt){return Zt<=0||Jt.length===0&&Jt.ended?0:Jt.objectMode?1:Zt!==Zt?Jt.flowing&&Jt.length?Jt.buffer.head.data.length:Jt.length:(Zt>Jt.highWaterMark&&(Jt.highWaterMark=gt(Zt)),Zt<=Jt.length?Zt:Jt.ended?Jt.length:(Jt.needReadable=!0,0))}t0.prototype.read=function(Zt){vt("read",Zt),Zt=parseInt(Zt,10);var Jt=this._readableState,i0=Zt;if(Zt!==0&&(Jt.emittedReadable=!1),Zt===0&&Jt.needReadable&&((Jt.highWaterMark!==0?Jt.length>=Jt.highWaterMark:Jt.length>0)||Jt.ended))return vt("read: emitReadable",Jt.length,Jt.ended),Jt.length===0&&Jt.ended?qt(this):_t(this),null;if(Zt=xt(Zt,Jt),Zt===0&&Jt.ended)return Jt.length===0&&qt(this),null;var h0=Jt.needReadable;vt("need readable",h0),(Jt.length===0||Jt.length-Zt0?o0=zt(Zt,Jt):o0=null,o0===null?(Jt.needReadable=Jt.length<=Jt.highWaterMark,Zt=0):(Jt.length-=Zt,Jt.awaitDrain=0),Jt.length===0&&(Jt.ended||(Jt.needReadable=!0),i0!==Zt&&Jt.ended&&qt(this)),o0!==null&&this.emit("data",o0),o0};function St(Zt,Jt){if(vt("onEofChunk"),!Jt.ended){if(Jt.decoder){var i0=Jt.decoder.end();i0&&i0.length&&(Jt.buffer.push(i0),Jt.length+=Jt.objectMode?1:i0.length)}Jt.ended=!0,Jt.sync?_t(Zt):(Jt.needReadable=!1,Jt.emittedReadable||(Jt.emittedReadable=!0,Pt(Zt)))}}function _t(Zt){var Jt=Zt._readableState;vt("emitReadable",Jt.needReadable,Jt.emittedReadable),Jt.needReadable=!1,Jt.emittedReadable||(vt("emitReadable",Jt.flowing),Jt.emittedReadable=!0,dist$2.process.nextTick(Pt,Zt))}function Pt(Zt){var Jt=Zt._readableState;vt("emitReadable_",Jt.destroyed,Jt.length,Jt.ended),!Jt.destroyed&&(Jt.length||Jt.ended)&&(Zt.emit("readable"),Jt.emittedReadable=!1),Jt.needReadable=!Jt.flowing&&!Jt.ended&&Jt.length<=Jt.highWaterMark,Vt(Zt)}function Et(Zt,Jt){Jt.readingMore||(Jt.readingMore=!0,dist$2.process.nextTick(ht,Zt,Jt))}function ht(Zt,Jt){for(;!Jt.reading&&!Jt.ended&&(Jt.length1&&e0(h0.pipes,Zt)!==-1)&&!J0&&(vt("false write response, pause",h0.awaitDrain),h0.awaitDrain++),i0.pause())}function Z0(Qt){vt("onerror",Qt),K0(),Zt.removeListener("error",Z0),a(Zt,"error")===0&&Wt(Zt,Qt)}a0(Zt,"error",Z0);function w0(){Zt.removeListener("finish",b0),K0()}Zt.once("close",w0);function b0(){vt("onfinish"),Zt.removeListener("close",w0),K0()}Zt.once("finish",b0);function K0(){vt("unpipe"),i0.unpipe(Zt)}return Zt.emit("pipe",i0),h0.flowing||(vt("pipe resume"),i0.resume()),Zt};function wt(Zt){return function(){var i0=Zt._readableState;vt("pipeOnDrain",i0.awaitDrain),i0.awaitDrain&&i0.awaitDrain--,i0.awaitDrain===0&&a(Zt,"data")&&(i0.flowing=!0,Vt(Zt))}}t0.prototype.unpipe=function(Zt){var Jt=this._readableState,i0={hasUnpiped:!1};if(Jt.pipesCount===0)return this;if(Jt.pipesCount===1)return Zt&&Zt!==Jt.pipes?this:(Zt||(Zt=Jt.pipes),Jt.pipes=null,Jt.pipesCount=0,Jt.flowing=!1,Zt&&Zt.emit("unpipe",this,i0),this);if(!Zt){var h0=Jt.pipes,o0=Jt.pipesCount;Jt.pipes=null,Jt.pipesCount=0,Jt.flowing=!1;for(var l0=0;l00,h0.flowing!==!1&&this.resume()):Zt==="readable"&&!h0.endEmitted&&!h0.readableListening&&(h0.readableListening=h0.needReadable=!0,h0.flowing=!1,h0.emittedReadable=!1,vt("on readable",h0.length,h0.reading),h0.length?_t(this):h0.reading||dist$2.process.nextTick(Lt,this)),i0},t0.prototype.addListener=t0.prototype.on,t0.prototype.removeListener=function(Zt,Jt){var i0=d.prototype.removeListener.call(this,Zt,Jt);return Zt==="readable"&&dist$2.process.nextTick(Bt,this),i0},t0.prototype.removeAllListeners=function(Zt){var Jt=d.prototype.removeAllListeners.apply(this,arguments);return(Zt==="readable"||Zt===void 0)&&dist$2.process.nextTick(Bt,this),Jt};function Bt(Zt){var Jt=Zt._readableState;Jt.readableListening=Zt.listenerCount("readable")>0,Jt.resumeScheduled&&!Jt.paused?Jt.flowing=!0:Zt.listenerCount("data")>0&&Zt.resume()}function Lt(Zt){vt("readable nexttick read 0"),Zt.read(0)}t0.prototype.resume=function(){var Zt=this._readableState;return Zt.flowing||(vt("resume"),Zt.flowing=!Zt.readableListening,jt(this,Zt)),Zt.paused=!1,this};function jt(Zt,Jt){Jt.resumeScheduled||(Jt.resumeScheduled=!0,dist$2.process.nextTick(Ft,Zt,Jt))}function Ft(Zt,Jt){vt("resume",Jt.reading),Jt.reading||Zt.read(0),Jt.resumeScheduled=!1,Zt.emit("resume"),Vt(Zt),Jt.flowing&&!Jt.reading&&Zt.read(0)}t0.prototype.pause=function(){return vt("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(vt("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Vt(Zt){var Jt=Zt._readableState;for(vt("flow",Jt.flowing);Jt.flowing&&Zt.read()!==null;);}t0.prototype.wrap=function(Zt){var Jt=this,i0=this._readableState,h0=!1;Zt.on("end",function(){if(vt("wrapped end"),i0.decoder&&!i0.ended){var $0=i0.decoder.end();$0&&$0.length&&Jt.push($0)}Jt.push(null)}),Zt.on("data",function($0){if(vt("wrapped data"),i0.decoder&&($0=i0.decoder.write($0)),!(i0.objectMode&&$0==null)&&!(!i0.objectMode&&(!$0||!$0.length))){var p0=Jt.push($0);p0||(h0=!0,Zt.pause())}});for(var o0 in Zt)this[o0]===void 0&&typeof Zt[o0]=="function"&&(this[o0]=function(p0){return function(){return Zt[p0].apply(Zt,arguments)}}(o0));for(var l0=0;l0=Jt.length?(Jt.decoder?i0=Jt.buffer.join(""):Jt.buffer.length===1?i0=Jt.buffer.first():i0=Jt.buffer.concat(Jt.length),Jt.buffer.clear()):i0=Jt.buffer.consume(Zt,Jt.decoder),i0}function qt(Zt){var Jt=Zt._readableState;vt("endReadable",Jt.endEmitted),Jt.endEmitted||(Jt.ended=!0,dist$2.process.nextTick(Kt,Jt,Zt))}function Kt(Zt,Jt){if(vt("endReadableNT",Zt.endEmitted,Zt.length),!Zt.endEmitted&&Zt.length===0&&(Zt.endEmitted=!0,Jt.readable=!1,Jt.emit("end"),Zt.autoDestroy)){var i0=Jt._writableState;(!i0||i0.autoDestroy&&i0.finished)&&Jt.destroy()}}typeof Symbol=="function"&&(t0.from=function(Zt,Jt){return Gt===void 0&&(Gt=requireFromBrowser()),Gt(t0,Zt,Jt)});function e0(Zt,Jt){for(var i0=0,h0=Zt.length;i00;return mt(Ot,Gt,Wt,function(Xt){Dt||(Dt=Xt),Xt&&Nt.forEach(vt),!Gt&&(Nt.forEach(vt),It(Dt))})});return Rt.reduce($t)}return pipeline_1=Mt,pipeline_1}var streamBrowserify=Stream,EE=eventsExports.EventEmitter,inherits$t=inherits_browserExports;inherits$t(Stream,EE);Stream.Readable=require_stream_readable$1();Stream.Writable=require_stream_writable$1();Stream.Duplex=require_stream_duplex$1();Stream.Transform=require_stream_transform();Stream.PassThrough=require_stream_passthrough();Stream.finished=requireEndOfStream();Stream.pipeline=requirePipeline();Stream.Stream=Stream;function Stream(){EE.call(this)}Stream.prototype.pipe=function(c,a){var d=this;function et(At){c.writable&&c.write(At)===!1&&d.pause&&d.pause()}d.on("data",et);function nt(){d.readable&&d.resume&&d.resume()}c.on("drain",nt),!c._isStdio&&(!a||a.end!==!1)&&(d.on("end",bt),d.on("close",mt));var tt=!1;function bt(){tt||(tt=!0,c.end())}function mt(){tt||(tt=!0,typeof c.destroy=="function"&&c.destroy())}function vt(At){if($t(),EE.listenerCount(this,"error")===0)throw At}d.on("error",vt),c.on("error",vt);function $t(){d.removeListener("data",et),c.removeListener("drain",nt),d.removeListener("end",bt),d.removeListener("close",mt),d.removeListener("error",vt),c.removeListener("error",vt),d.removeListener("end",$t),d.removeListener("close",$t),c.removeListener("close",$t)}return d.on("end",$t),d.on("close",$t),c.on("close",$t),c.emit("pipe",d),c};var Buffer$y=safeBufferExports$1.Buffer,Transform$7=streamBrowserify.Transform,inherits$s=inherits_browserExports;function throwIfNotStringOrBuffer(c,a){if(!Buffer$y.isBuffer(c)&&typeof c!="string")throw new TypeError(a+" must be a string or a buffer")}function HashBase$2(c){Transform$7.call(this),this._block=Buffer$y.allocUnsafe(c),this._blockSize=c,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}inherits$s(HashBase$2,Transform$7);HashBase$2.prototype._transform=function(c,a,d){var et=null;try{this.update(c,a)}catch(nt){et=nt}d(et)};HashBase$2.prototype._flush=function(c){var a=null;try{this.push(this.digest())}catch(d){a=d}c(a)};HashBase$2.prototype.update=function(c,a){if(throwIfNotStringOrBuffer(c,"Data"),this._finalized)throw new Error("Digest already called");Buffer$y.isBuffer(c)||(c=Buffer$y.from(c,a));for(var d=this._block,et=0;this._blockOffset+c.length-et>=this._blockSize;){for(var nt=this._blockOffset;nt0;++tt)this._length[tt]+=bt,bt=this._length[tt]/4294967296|0,bt>0&&(this._length[tt]-=4294967296*bt);return this};HashBase$2.prototype._update=function(){throw new Error("_update is not implemented")};HashBase$2.prototype.digest=function(c){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var a=this._digest();c!==void 0&&(a=a.toString(c)),this._block.fill(0),this._blockOffset=0;for(var d=0;d<4;++d)this._length[d]=0;return a};HashBase$2.prototype._digest=function(){throw new Error("_digest is not implemented")};var hashBase=HashBase$2,inherits$r=inherits_browserExports,HashBase$1=hashBase,Buffer$x=safeBufferExports$1.Buffer,ARRAY16$1=new Array(16);function MD5$3(){HashBase$1.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}inherits$r(MD5$3,HashBase$1);MD5$3.prototype._update=function(){for(var c=ARRAY16$1,a=0;a<16;++a)c[a]=this._block.readInt32LE(a*4);var d=this._a,et=this._b,nt=this._c,tt=this._d;d=fnF(d,et,nt,tt,c[0],3614090360,7),tt=fnF(tt,d,et,nt,c[1],3905402710,12),nt=fnF(nt,tt,d,et,c[2],606105819,17),et=fnF(et,nt,tt,d,c[3],3250441966,22),d=fnF(d,et,nt,tt,c[4],4118548399,7),tt=fnF(tt,d,et,nt,c[5],1200080426,12),nt=fnF(nt,tt,d,et,c[6],2821735955,17),et=fnF(et,nt,tt,d,c[7],4249261313,22),d=fnF(d,et,nt,tt,c[8],1770035416,7),tt=fnF(tt,d,et,nt,c[9],2336552879,12),nt=fnF(nt,tt,d,et,c[10],4294925233,17),et=fnF(et,nt,tt,d,c[11],2304563134,22),d=fnF(d,et,nt,tt,c[12],1804603682,7),tt=fnF(tt,d,et,nt,c[13],4254626195,12),nt=fnF(nt,tt,d,et,c[14],2792965006,17),et=fnF(et,nt,tt,d,c[15],1236535329,22),d=fnG(d,et,nt,tt,c[1],4129170786,5),tt=fnG(tt,d,et,nt,c[6],3225465664,9),nt=fnG(nt,tt,d,et,c[11],643717713,14),et=fnG(et,nt,tt,d,c[0],3921069994,20),d=fnG(d,et,nt,tt,c[5],3593408605,5),tt=fnG(tt,d,et,nt,c[10],38016083,9),nt=fnG(nt,tt,d,et,c[15],3634488961,14),et=fnG(et,nt,tt,d,c[4],3889429448,20),d=fnG(d,et,nt,tt,c[9],568446438,5),tt=fnG(tt,d,et,nt,c[14],3275163606,9),nt=fnG(nt,tt,d,et,c[3],4107603335,14),et=fnG(et,nt,tt,d,c[8],1163531501,20),d=fnG(d,et,nt,tt,c[13],2850285829,5),tt=fnG(tt,d,et,nt,c[2],4243563512,9),nt=fnG(nt,tt,d,et,c[7],1735328473,14),et=fnG(et,nt,tt,d,c[12],2368359562,20),d=fnH(d,et,nt,tt,c[5],4294588738,4),tt=fnH(tt,d,et,nt,c[8],2272392833,11),nt=fnH(nt,tt,d,et,c[11],1839030562,16),et=fnH(et,nt,tt,d,c[14],4259657740,23),d=fnH(d,et,nt,tt,c[1],2763975236,4),tt=fnH(tt,d,et,nt,c[4],1272893353,11),nt=fnH(nt,tt,d,et,c[7],4139469664,16),et=fnH(et,nt,tt,d,c[10],3200236656,23),d=fnH(d,et,nt,tt,c[13],681279174,4),tt=fnH(tt,d,et,nt,c[0],3936430074,11),nt=fnH(nt,tt,d,et,c[3],3572445317,16),et=fnH(et,nt,tt,d,c[6],76029189,23),d=fnH(d,et,nt,tt,c[9],3654602809,4),tt=fnH(tt,d,et,nt,c[12],3873151461,11),nt=fnH(nt,tt,d,et,c[15],530742520,16),et=fnH(et,nt,tt,d,c[2],3299628645,23),d=fnI(d,et,nt,tt,c[0],4096336452,6),tt=fnI(tt,d,et,nt,c[7],1126891415,10),nt=fnI(nt,tt,d,et,c[14],2878612391,15),et=fnI(et,nt,tt,d,c[5],4237533241,21),d=fnI(d,et,nt,tt,c[12],1700485571,6),tt=fnI(tt,d,et,nt,c[3],2399980690,10),nt=fnI(nt,tt,d,et,c[10],4293915773,15),et=fnI(et,nt,tt,d,c[1],2240044497,21),d=fnI(d,et,nt,tt,c[8],1873313359,6),tt=fnI(tt,d,et,nt,c[15],4264355552,10),nt=fnI(nt,tt,d,et,c[6],2734768916,15),et=fnI(et,nt,tt,d,c[13],1309151649,21),d=fnI(d,et,nt,tt,c[4],4149444226,6),tt=fnI(tt,d,et,nt,c[11],3174756917,10),nt=fnI(nt,tt,d,et,c[2],718787259,15),et=fnI(et,nt,tt,d,c[9],3951481745,21),this._a=this._a+d|0,this._b=this._b+et|0,this._c=this._c+nt|0,this._d=this._d+tt|0};MD5$3.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var c=Buffer$x.allocUnsafe(16);return c.writeInt32LE(this._a,0),c.writeInt32LE(this._b,4),c.writeInt32LE(this._c,8),c.writeInt32LE(this._d,12),c};function rotl$1(c,a){return c<>>32-a}function fnF(c,a,d,et,nt,tt,bt){return rotl$1(c+(a&d|~a&et)+nt+tt|0,bt)+a|0}function fnG(c,a,d,et,nt,tt,bt){return rotl$1(c+(a&et|d&~et)+nt+tt|0,bt)+a|0}function fnH(c,a,d,et,nt,tt,bt){return rotl$1(c+(a^d^et)+nt+tt|0,bt)+a|0}function fnI(c,a,d,et,nt,tt,bt){return rotl$1(c+(d^(a|~et))+nt+tt|0,bt)+a|0}var md5_js=MD5$3,Buffer$w=bufferPolyfill.Buffer,inherits$q=inherits_browserExports,HashBase=hashBase,ARRAY16=new Array(16),zl=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],zr=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],sl=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],sr=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],hl=[0,1518500249,1859775393,2400959708,2840853838],hr=[1352829926,1548603684,1836072691,2053994217,0];function RIPEMD160$4(){HashBase.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}inherits$q(RIPEMD160$4,HashBase);RIPEMD160$4.prototype._update=function(){for(var c=ARRAY16,a=0;a<16;++a)c[a]=this._block.readInt32LE(a*4);for(var d=this._a|0,et=this._b|0,nt=this._c|0,tt=this._d|0,bt=this._e|0,mt=this._a|0,vt=this._b|0,$t=this._c|0,At=this._d|0,Mt=this._e|0,Tt=0;Tt<80;Tt+=1){var Rt,kt;Tt<16?(Rt=fn1(d,et,nt,tt,bt,c[zl[Tt]],hl[0],sl[Tt]),kt=fn5(mt,vt,$t,At,Mt,c[zr[Tt]],hr[0],sr[Tt])):Tt<32?(Rt=fn2(d,et,nt,tt,bt,c[zl[Tt]],hl[1],sl[Tt]),kt=fn4(mt,vt,$t,At,Mt,c[zr[Tt]],hr[1],sr[Tt])):Tt<48?(Rt=fn3(d,et,nt,tt,bt,c[zl[Tt]],hl[2],sl[Tt]),kt=fn3(mt,vt,$t,At,Mt,c[zr[Tt]],hr[2],sr[Tt])):Tt<64?(Rt=fn4(d,et,nt,tt,bt,c[zl[Tt]],hl[3],sl[Tt]),kt=fn2(mt,vt,$t,At,Mt,c[zr[Tt]],hr[3],sr[Tt])):(Rt=fn5(d,et,nt,tt,bt,c[zl[Tt]],hl[4],sl[Tt]),kt=fn1(mt,vt,$t,At,Mt,c[zr[Tt]],hr[4],sr[Tt])),d=bt,bt=tt,tt=rotl(nt,10),nt=et,et=Rt,mt=Mt,Mt=At,At=rotl($t,10),$t=vt,vt=kt}var It=this._b+nt+At|0;this._b=this._c+tt+Mt|0,this._c=this._d+bt+mt|0,this._d=this._e+d+vt|0,this._e=this._a+et+$t|0,this._a=It};RIPEMD160$4.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var c=Buffer$w.alloc?Buffer$w.alloc(20):new Buffer$w(20);return c.writeInt32LE(this._a,0),c.writeInt32LE(this._b,4),c.writeInt32LE(this._c,8),c.writeInt32LE(this._d,12),c.writeInt32LE(this._e,16),c};function rotl(c,a){return c<>>32-a}function fn1(c,a,d,et,nt,tt,bt,mt){return rotl(c+(a^d^et)+tt+bt|0,mt)+nt|0}function fn2(c,a,d,et,nt,tt,bt,mt){return rotl(c+(a&d|~a&et)+tt+bt|0,mt)+nt|0}function fn3(c,a,d,et,nt,tt,bt,mt){return rotl(c+((a|~d)^et)+tt+bt|0,mt)+nt|0}function fn4(c,a,d,et,nt,tt,bt,mt){return rotl(c+(a&et|d&~et)+tt+bt|0,mt)+nt|0}function fn5(c,a,d,et,nt,tt,bt,mt){return rotl(c+(a^(d|~et))+tt+bt|0,mt)+nt|0}var ripemd160$1=RIPEMD160$4,sha_js={exports:{}},Buffer$v=safeBufferExports$1.Buffer;function Hash$9(c,a){this._block=Buffer$v.alloc(c),this._finalSize=a,this._blockSize=c,this._len=0}Hash$9.prototype.update=function(c,a){typeof c=="string"&&(a=a||"utf8",c=Buffer$v.from(c,a));for(var d=this._block,et=this._blockSize,nt=c.length,tt=this._len,bt=0;bt=this._finalSize&&(this._update(this._block),this._block.fill(0));var d=this._len*8;if(d<=4294967295)this._block.writeUInt32BE(d,this._blockSize-4);else{var et=(d&4294967295)>>>0,nt=(d-et)/4294967296;this._block.writeUInt32BE(nt,this._blockSize-8),this._block.writeUInt32BE(et,this._blockSize-4)}this._update(this._block);var tt=this._hash();return c?tt.toString(c):tt};Hash$9.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var hash$8=Hash$9,inherits$p=inherits_browserExports,Hash$8=hash$8,Buffer$u=safeBufferExports$1.Buffer,K$4=[1518500249,1859775393,-1894007588,-899497514],W$5=new Array(80);function Sha(){this.init(),this._w=W$5,Hash$8.call(this,64,56)}inherits$p(Sha,Hash$8);Sha.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rotl5$1(c){return c<<5|c>>>27}function rotl30$1(c){return c<<30|c>>>2}function ft$1(c,a,d,et){return c===0?a&d|~a&et:c===2?a&d|a&et|d&et:a^d^et}Sha.prototype._update=function(c){for(var a=this._w,d=this._a|0,et=this._b|0,nt=this._c|0,tt=this._d|0,bt=this._e|0,mt=0;mt<16;++mt)a[mt]=c.readInt32BE(mt*4);for(;mt<80;++mt)a[mt]=a[mt-3]^a[mt-8]^a[mt-14]^a[mt-16];for(var vt=0;vt<80;++vt){var $t=~~(vt/20),At=rotl5$1(d)+ft$1($t,et,nt,tt)+bt+a[vt]+K$4[$t]|0;bt=tt,tt=nt,nt=rotl30$1(et),et=d,d=At}this._a=d+this._a|0,this._b=et+this._b|0,this._c=nt+this._c|0,this._d=tt+this._d|0,this._e=bt+this._e|0};Sha.prototype._hash=function(){var c=Buffer$u.allocUnsafe(20);return c.writeInt32BE(this._a|0,0),c.writeInt32BE(this._b|0,4),c.writeInt32BE(this._c|0,8),c.writeInt32BE(this._d|0,12),c.writeInt32BE(this._e|0,16),c};var sha$4=Sha,inherits$o=inherits_browserExports,Hash$7=hash$8,Buffer$t=safeBufferExports$1.Buffer,K$3=[1518500249,1859775393,-1894007588,-899497514],W$4=new Array(80);function Sha1(){this.init(),this._w=W$4,Hash$7.call(this,64,56)}inherits$o(Sha1,Hash$7);Sha1.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rotl1(c){return c<<1|c>>>31}function rotl5(c){return c<<5|c>>>27}function rotl30(c){return c<<30|c>>>2}function ft(c,a,d,et){return c===0?a&d|~a&et:c===2?a&d|a&et|d&et:a^d^et}Sha1.prototype._update=function(c){for(var a=this._w,d=this._a|0,et=this._b|0,nt=this._c|0,tt=this._d|0,bt=this._e|0,mt=0;mt<16;++mt)a[mt]=c.readInt32BE(mt*4);for(;mt<80;++mt)a[mt]=rotl1(a[mt-3]^a[mt-8]^a[mt-14]^a[mt-16]);for(var vt=0;vt<80;++vt){var $t=~~(vt/20),At=rotl5(d)+ft($t,et,nt,tt)+bt+a[vt]+K$3[$t]|0;bt=tt,tt=nt,nt=rotl30(et),et=d,d=At}this._a=d+this._a|0,this._b=et+this._b|0,this._c=nt+this._c|0,this._d=tt+this._d|0,this._e=bt+this._e|0};Sha1.prototype._hash=function(){var c=Buffer$t.allocUnsafe(20);return c.writeInt32BE(this._a|0,0),c.writeInt32BE(this._b|0,4),c.writeInt32BE(this._c|0,8),c.writeInt32BE(this._d|0,12),c.writeInt32BE(this._e|0,16),c};var sha1=Sha1,inherits$n=inherits_browserExports,Hash$6=hash$8,Buffer$s=safeBufferExports$1.Buffer,K$2=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],W$3=new Array(64);function Sha256$1(){this.init(),this._w=W$3,Hash$6.call(this,64,56)}inherits$n(Sha256$1,Hash$6);Sha256$1.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function ch(c,a,d){return d^c&(a^d)}function maj$1(c,a,d){return c&a|d&(c|a)}function sigma0$1(c){return(c>>>2|c<<30)^(c>>>13|c<<19)^(c>>>22|c<<10)}function sigma1$1(c){return(c>>>6|c<<26)^(c>>>11|c<<21)^(c>>>25|c<<7)}function gamma0(c){return(c>>>7|c<<25)^(c>>>18|c<<14)^c>>>3}function gamma1(c){return(c>>>17|c<<15)^(c>>>19|c<<13)^c>>>10}Sha256$1.prototype._update=function(c){for(var a=this._w,d=this._a|0,et=this._b|0,nt=this._c|0,tt=this._d|0,bt=this._e|0,mt=this._f|0,vt=this._g|0,$t=this._h|0,At=0;At<16;++At)a[At]=c.readInt32BE(At*4);for(;At<64;++At)a[At]=gamma1(a[At-2])+a[At-7]+gamma0(a[At-15])+a[At-16]|0;for(var Mt=0;Mt<64;++Mt){var Tt=$t+sigma1$1(bt)+ch(bt,mt,vt)+K$2[Mt]+a[Mt]|0,Rt=sigma0$1(d)+maj$1(d,et,nt)|0;$t=vt,vt=mt,mt=bt,bt=tt+Tt|0,tt=nt,nt=et,et=d,d=Tt+Rt|0}this._a=d+this._a|0,this._b=et+this._b|0,this._c=nt+this._c|0,this._d=tt+this._d|0,this._e=bt+this._e|0,this._f=mt+this._f|0,this._g=vt+this._g|0,this._h=$t+this._h|0};Sha256$1.prototype._hash=function(){var c=Buffer$s.allocUnsafe(32);return c.writeInt32BE(this._a,0),c.writeInt32BE(this._b,4),c.writeInt32BE(this._c,8),c.writeInt32BE(this._d,12),c.writeInt32BE(this._e,16),c.writeInt32BE(this._f,20),c.writeInt32BE(this._g,24),c.writeInt32BE(this._h,28),c};var sha256$4=Sha256$1,inherits$m=inherits_browserExports,Sha256=sha256$4,Hash$5=hash$8,Buffer$r=safeBufferExports$1.Buffer,W$2=new Array(64);function Sha224(){this.init(),this._w=W$2,Hash$5.call(this,64,56)}inherits$m(Sha224,Sha256);Sha224.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this};Sha224.prototype._hash=function(){var c=Buffer$r.allocUnsafe(28);return c.writeInt32BE(this._a,0),c.writeInt32BE(this._b,4),c.writeInt32BE(this._c,8),c.writeInt32BE(this._d,12),c.writeInt32BE(this._e,16),c.writeInt32BE(this._f,20),c.writeInt32BE(this._g,24),c};var sha224$1=Sha224,inherits$l=inherits_browserExports,Hash$4=hash$8,Buffer$q=safeBufferExports$1.Buffer,K$1=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],W$1=new Array(160);function Sha512(){this.init(),this._w=W$1,Hash$4.call(this,128,112)}inherits$l(Sha512,Hash$4);Sha512.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function Ch(c,a,d){return d^c&(a^d)}function maj(c,a,d){return c&a|d&(c|a)}function sigma0(c,a){return(c>>>28|a<<4)^(a>>>2|c<<30)^(a>>>7|c<<25)}function sigma1(c,a){return(c>>>14|a<<18)^(c>>>18|a<<14)^(a>>>9|c<<23)}function Gamma0(c,a){return(c>>>1|a<<31)^(c>>>8|a<<24)^c>>>7}function Gamma0l(c,a){return(c>>>1|a<<31)^(c>>>8|a<<24)^(c>>>7|a<<25)}function Gamma1(c,a){return(c>>>19|a<<13)^(a>>>29|c<<3)^c>>>6}function Gamma1l(c,a){return(c>>>19|a<<13)^(a>>>29|c<<3)^(c>>>6|a<<26)}function getCarry(c,a){return c>>>0>>0?1:0}Sha512.prototype._update=function(c){for(var a=this._w,d=this._ah|0,et=this._bh|0,nt=this._ch|0,tt=this._dh|0,bt=this._eh|0,mt=this._fh|0,vt=this._gh|0,$t=this._hh|0,At=this._al|0,Mt=this._bl|0,Tt=this._cl|0,Rt=this._dl|0,kt=this._el|0,It=this._fl|0,Dt=this._gl|0,Nt=this._hl|0,Ot=0;Ot<32;Ot+=2)a[Ot]=c.readInt32BE(Ot*4),a[Ot+1]=c.readInt32BE(Ot*4+4);for(;Ot<160;Ot+=2){var Ut=a[Ot-30],Gt=a[Ot-15*2+1],Wt=Gamma0(Ut,Gt),Xt=Gamma0l(Gt,Ut);Ut=a[Ot-2*2],Gt=a[Ot-2*2+1];var a0=Gamma1(Ut,Gt),n0=Gamma1l(Gt,Ut),t0=a[Ot-7*2],c0=a[Ot-7*2+1],Ct=a[Ot-16*2],dt=a[Ot-16*2+1],yt=Xt+c0|0,gt=Wt+t0+getCarry(yt,Xt)|0;yt=yt+n0|0,gt=gt+a0+getCarry(yt,n0)|0,yt=yt+dt|0,gt=gt+Ct+getCarry(yt,dt)|0,a[Ot]=gt,a[Ot+1]=yt}for(var xt=0;xt<160;xt+=2){gt=a[xt],yt=a[xt+1];var St=maj(d,et,nt),_t=maj(At,Mt,Tt),Pt=sigma0(d,At),Et=sigma0(At,d),ht=sigma1(bt,kt),wt=sigma1(kt,bt),Bt=K$1[xt],Lt=K$1[xt+1],jt=Ch(bt,mt,vt),Ft=Ch(kt,It,Dt),Vt=Nt+wt|0,zt=$t+ht+getCarry(Vt,Nt)|0;Vt=Vt+Ft|0,zt=zt+jt+getCarry(Vt,Ft)|0,Vt=Vt+Lt|0,zt=zt+Bt+getCarry(Vt,Lt)|0,Vt=Vt+yt|0,zt=zt+gt+getCarry(Vt,yt)|0;var qt=Et+_t|0,Kt=Pt+St+getCarry(qt,Et)|0;$t=vt,Nt=Dt,vt=mt,Dt=It,mt=bt,It=kt,kt=Rt+Vt|0,bt=tt+zt+getCarry(kt,Rt)|0,tt=nt,Rt=Tt,nt=et,Tt=Mt,et=d,Mt=At,At=Vt+qt|0,d=zt+Kt+getCarry(At,Vt)|0}this._al=this._al+At|0,this._bl=this._bl+Mt|0,this._cl=this._cl+Tt|0,this._dl=this._dl+Rt|0,this._el=this._el+kt|0,this._fl=this._fl+It|0,this._gl=this._gl+Dt|0,this._hl=this._hl+Nt|0,this._ah=this._ah+d+getCarry(this._al,At)|0,this._bh=this._bh+et+getCarry(this._bl,Mt)|0,this._ch=this._ch+nt+getCarry(this._cl,Tt)|0,this._dh=this._dh+tt+getCarry(this._dl,Rt)|0,this._eh=this._eh+bt+getCarry(this._el,kt)|0,this._fh=this._fh+mt+getCarry(this._fl,It)|0,this._gh=this._gh+vt+getCarry(this._gl,Dt)|0,this._hh=this._hh+$t+getCarry(this._hl,Nt)|0};Sha512.prototype._hash=function(){var c=Buffer$q.allocUnsafe(64);function a(d,et,nt){c.writeInt32BE(d,nt),c.writeInt32BE(et,nt+4)}return a(this._ah,this._al,0),a(this._bh,this._bl,8),a(this._ch,this._cl,16),a(this._dh,this._dl,24),a(this._eh,this._el,32),a(this._fh,this._fl,40),a(this._gh,this._gl,48),a(this._hh,this._hl,56),c};var sha512$1=Sha512,inherits$k=inherits_browserExports,SHA512$2=sha512$1,Hash$3=hash$8,Buffer$p=safeBufferExports$1.Buffer,W=new Array(160);function Sha384(){this.init(),this._w=W,Hash$3.call(this,128,112)}inherits$k(Sha384,SHA512$2);Sha384.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this};Sha384.prototype._hash=function(){var c=Buffer$p.allocUnsafe(48);function a(d,et,nt){c.writeInt32BE(d,nt),c.writeInt32BE(et,nt+4)}return a(this._ah,this._al,0),a(this._bh,this._bl,8),a(this._ch,this._cl,16),a(this._dh,this._dl,24),a(this._eh,this._el,32),a(this._fh,this._fl,40),c};var sha384$1=Sha384,exports=sha_js.exports=function(a){a=a.toLowerCase();var d=exports[a];if(!d)throw new Error(a+" is not supported (we accept pull requests)");return new d};exports.sha=sha$4;exports.sha1=sha1;exports.sha224=sha224$1;exports.sha256=sha256$4;exports.sha384=sha384$1;exports.sha512=sha512$1;var sha_jsExports=sha_js.exports,Buffer$o=safeBufferExports$1.Buffer,Transform$6=streamBrowserify.Transform,StringDecoder=string_decoder.StringDecoder,inherits$j=inherits_browserExports;function CipherBase$1(c){Transform$6.call(this),this.hashMode=typeof c=="string",this.hashMode?this[c]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}inherits$j(CipherBase$1,Transform$6);CipherBase$1.prototype.update=function(c,a,d){typeof c=="string"&&(c=Buffer$o.from(c,a));var et=this._update(c);return this.hashMode?this:(d&&(et=this._toString(et,d)),et)};CipherBase$1.prototype.setAutoPadding=function(){};CipherBase$1.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")};CipherBase$1.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")};CipherBase$1.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")};CipherBase$1.prototype._transform=function(c,a,d){var et;try{this.hashMode?this._update(c):this.push(this._update(c))}catch(nt){et=nt}finally{d(et)}};CipherBase$1.prototype._flush=function(c){var a;try{this.push(this.__final())}catch(d){a=d}c(a)};CipherBase$1.prototype._finalOrDigest=function(c){var a=this.__final()||Buffer$o.alloc(0);return c&&(a=this._toString(a,c,!0)),a};CipherBase$1.prototype._toString=function(c,a,d){if(this._decoder||(this._decoder=new StringDecoder(a),this._encoding=a),this._encoding!==a)throw new Error("can't switch encodings");var et=this._decoder.write(c);return d&&(et+=this._decoder.end()),et};var cipherBase=CipherBase$1,inherits$i=inherits_browserExports,MD5$2=md5_js,RIPEMD160$3=ripemd160$1,sha$3=sha_jsExports,Base$8=cipherBase;function Hash$2(c){Base$8.call(this,"digest"),this._hash=c}inherits$i(Hash$2,Base$8);Hash$2.prototype._update=function(c){this._hash.update(c)};Hash$2.prototype._final=function(){return this._hash.digest()};var browser$9=function(a){return a=a.toLowerCase(),a==="md5"?new MD5$2:a==="rmd160"||a==="ripemd160"?new RIPEMD160$3:new Hash$2(sha$3(a))},inherits$h=inherits_browserExports,Buffer$n=safeBufferExports$1.Buffer,Base$7=cipherBase,ZEROS$2=Buffer$n.alloc(128),blocksize=64;function Hmac$3(c,a){Base$7.call(this,"digest"),typeof a=="string"&&(a=Buffer$n.from(a)),this._alg=c,this._key=a,a.length>blocksize?a=c(a):a.lengthd){var et=c==="rmd160"?new RIPEMD160$2:sha$2(c);a=et.update(a).digest()}else a.lengthMAX_ALLOC||a!==a)throw new TypeError("Bad key length")},defaultEncoding$2;if(commonjsGlobal.process&&commonjsGlobal.process.browser)defaultEncoding$2="utf-8";else if(commonjsGlobal.process&&commonjsGlobal.process.version){var pVersionMajor=parseInt(dist$2.process.version.split(".")[0].slice(1),10);defaultEncoding$2=pVersionMajor>=6?"utf-8":"binary"}else defaultEncoding$2="utf-8";var defaultEncoding_1=defaultEncoding$2,Buffer$l=safeBufferExports$1.Buffer,toBuffer$2=function(c,a,d){if(Buffer$l.isBuffer(c))return c;if(typeof c=="string")return Buffer$l.from(c,a);if(ArrayBuffer.isView(c))return Buffer$l.from(c.buffer);throw new TypeError(d+" must be a string, a Buffer, a typed array or a DataView")},md5=md5$2,RIPEMD160$1=ripemd160$1,sha$1=sha_jsExports,Buffer$k=safeBufferExports$1.Buffer,checkParameters$1=precondition,defaultEncoding$1=defaultEncoding_1,toBuffer$1=toBuffer$2,ZEROS=Buffer$k.alloc(128),sizes={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function Hmac$1(c,a,d){var et=getDigest(c),nt=c==="sha512"||c==="sha384"?128:64;a.length>nt?a=et(a):a.length>>0};utils$A.writeUInt32BE=function(a,d,et){a[0+et]=d>>>24,a[1+et]=d>>>16&255,a[2+et]=d>>>8&255,a[3+et]=d&255};utils$A.ip=function(a,d,et,nt){for(var tt=0,bt=0,mt=6;mt>=0;mt-=2){for(var vt=0;vt<=24;vt+=8)tt<<=1,tt|=d>>>vt+mt&1;for(var vt=0;vt<=24;vt+=8)tt<<=1,tt|=a>>>vt+mt&1}for(var mt=6;mt>=0;mt-=2){for(var vt=1;vt<=25;vt+=8)bt<<=1,bt|=d>>>vt+mt&1;for(var vt=1;vt<=25;vt+=8)bt<<=1,bt|=a>>>vt+mt&1}et[nt+0]=tt>>>0,et[nt+1]=bt>>>0};utils$A.rip=function(a,d,et,nt){for(var tt=0,bt=0,mt=0;mt<4;mt++)for(var vt=24;vt>=0;vt-=8)tt<<=1,tt|=d>>>vt+mt&1,tt<<=1,tt|=a>>>vt+mt&1;for(var mt=4;mt<8;mt++)for(var vt=24;vt>=0;vt-=8)bt<<=1,bt|=d>>>vt+mt&1,bt<<=1,bt|=a>>>vt+mt&1;et[nt+0]=tt>>>0,et[nt+1]=bt>>>0};utils$A.pc1=function(a,d,et,nt){for(var tt=0,bt=0,mt=7;mt>=5;mt--){for(var vt=0;vt<=24;vt+=8)tt<<=1,tt|=d>>vt+mt&1;for(var vt=0;vt<=24;vt+=8)tt<<=1,tt|=a>>vt+mt&1}for(var vt=0;vt<=24;vt+=8)tt<<=1,tt|=d>>vt+mt&1;for(var mt=1;mt<=3;mt++){for(var vt=0;vt<=24;vt+=8)bt<<=1,bt|=d>>vt+mt&1;for(var vt=0;vt<=24;vt+=8)bt<<=1,bt|=a>>vt+mt&1}for(var vt=0;vt<=24;vt+=8)bt<<=1,bt|=a>>vt+mt&1;et[nt+0]=tt>>>0,et[nt+1]=bt>>>0};utils$A.r28shl=function(a,d){return a<>>28-d};var pc2table=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];utils$A.pc2=function(a,d,et,nt){for(var tt=0,bt=0,mt=pc2table.length>>>1,vt=0;vt>>pc2table[vt]&1;for(var vt=mt;vt>>pc2table[vt]&1;et[nt+0]=tt>>>0,et[nt+1]=bt>>>0};utils$A.expand=function(a,d,et){var nt=0,tt=0;nt=(a&1)<<5|a>>>27;for(var bt=23;bt>=15;bt-=4)nt<<=6,nt|=a>>>bt&63;for(var bt=11;bt>=3;bt-=4)tt|=a>>>bt&63,tt<<=6;tt|=(a&31)<<1|a>>>31,d[et+0]=nt>>>0,d[et+1]=tt>>>0};var sTable=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];utils$A.substitute=function(a,d){for(var et=0,nt=0;nt<4;nt++){var tt=a>>>18-nt*6&63,bt=sTable[nt*64+tt];et<<=4,et|=bt}for(var nt=0;nt<4;nt++){var tt=d>>>18-nt*6&63,bt=sTable[4*64+nt*64+tt];et<<=4,et|=bt}return et>>>0};var permuteTable=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];utils$A.permute=function(a){for(var d=0,et=0;et>>permuteTable[et]&1;return d>>>0};utils$A.padSplit=function(a,d,et){for(var nt=a.toString(2);nt.length0;nt--)d+=this._buffer(a,d),et+=this._flushBuffer(tt,et);return d+=this._buffer(a,d),tt};Cipher$3.prototype.final=function(a){var d;a&&(d=this.update(a));var et;return this.type==="encrypt"?et=this._finalEncrypt():et=this._finalDecrypt(),d?d.concat(et):et};Cipher$3.prototype._pad=function(a,d){if(d===0)return!1;for(;d>>1];et=utils$z.r28shl(et,bt),nt=utils$z.r28shl(nt,bt),utils$z.pc2(et,nt,a.keys,tt)}};DES$3.prototype._update=function(a,d,et,nt){var tt=this._desState,bt=utils$z.readUInt32BE(a,d),mt=utils$z.readUInt32BE(a,d+4);utils$z.ip(bt,mt,tt.tmp,0),bt=tt.tmp[0],mt=tt.tmp[1],this.type==="encrypt"?this._encrypt(tt,bt,mt,tt.tmp,0):this._decrypt(tt,bt,mt,tt.tmp,0),bt=tt.tmp[0],mt=tt.tmp[1],utils$z.writeUInt32BE(et,bt,nt),utils$z.writeUInt32BE(et,mt,nt+4)};DES$3.prototype._pad=function(a,d){if(this.padding===!1)return!1;for(var et=a.length-d,nt=d;nt>>0,bt=Rt}utils$z.rip(mt,bt,nt,tt)};DES$3.prototype._decrypt=function(a,d,et,nt,tt){for(var bt=et,mt=d,vt=a.keys.length-2;vt>=0;vt-=2){var $t=a.keys[vt],At=a.keys[vt+1];utils$z.expand(bt,a.tmp,0),$t^=a.tmp[0],At^=a.tmp[1];var Mt=utils$z.substitute($t,At),Tt=utils$z.permute(Mt),Rt=bt;bt=(mt^Tt)>>>0,mt=Rt}utils$z.rip(bt,mt,nt,tt)};var cbc$1={},assert$t=minimalisticAssert$1,inherits$e=inherits_browserExports,proto={};function CBCState(c){assert$t.equal(c.length,8,"Invalid IV length"),this.iv=new Array(8);for(var a=0;a>nt%8,c._prev=shiftIn(c._prev,d?mt:vt);return bt}function shiftIn(c,a){var d=c.length,et=-1,nt=Buffer$f.allocUnsafe(c.length);for(c=Buffer$f.concat([c,Buffer$f.from([a])]);++et>7;return nt}cfb1.encrypt=function(c,a,d){for(var et=a.length,nt=Buffer$f.allocUnsafe(et),tt=-1;++tt>>24]^bt[At>>>16&255]^mt[Mt>>>8&255]^vt[Tt&255]^a[Nt++],kt=tt[At>>>24]^bt[Mt>>>16&255]^mt[Tt>>>8&255]^vt[$t&255]^a[Nt++],It=tt[Mt>>>24]^bt[Tt>>>16&255]^mt[$t>>>8&255]^vt[At&255]^a[Nt++],Dt=tt[Tt>>>24]^bt[$t>>>16&255]^mt[At>>>8&255]^vt[Mt&255]^a[Nt++],$t=Rt,At=kt,Mt=It,Tt=Dt;return Rt=(et[$t>>>24]<<24|et[At>>>16&255]<<16|et[Mt>>>8&255]<<8|et[Tt&255])^a[Nt++],kt=(et[At>>>24]<<24|et[Mt>>>16&255]<<16|et[Tt>>>8&255]<<8|et[$t&255])^a[Nt++],It=(et[Mt>>>24]<<24|et[Tt>>>16&255]<<16|et[$t>>>8&255]<<8|et[At&255])^a[Nt++],Dt=(et[Tt>>>24]<<24|et[$t>>>16&255]<<16|et[At>>>8&255]<<8|et[Mt&255])^a[Nt++],Rt=Rt>>>0,kt=kt>>>0,It=It>>>0,Dt=Dt>>>0,[Rt,kt,It,Dt]}var RCON=[0,1,2,4,8,16,32,64,128,27,54],G=function(){for(var c=new Array(256),a=0;a<256;a++)a<128?c[a]=a<<1:c[a]=a<<1^283;for(var d=[],et=[],nt=[[],[],[],[]],tt=[[],[],[],[]],bt=0,mt=0,vt=0;vt<256;++vt){var $t=mt^mt<<1^mt<<2^mt<<3^mt<<4;$t=$t>>>8^$t&255^99,d[bt]=$t,et[$t]=bt;var At=c[bt],Mt=c[At],Tt=c[Mt],Rt=c[$t]*257^$t*16843008;nt[0][bt]=Rt<<24|Rt>>>8,nt[1][bt]=Rt<<16|Rt>>>16,nt[2][bt]=Rt<<8|Rt>>>24,nt[3][bt]=Rt,Rt=Tt*16843009^Mt*65537^At*257^bt*16843008,tt[0][$t]=Rt<<24|Rt>>>8,tt[1][$t]=Rt<<16|Rt>>>16,tt[2][$t]=Rt<<8|Rt>>>24,tt[3][$t]=Rt,bt===0?bt=mt=1:(bt=At^c[c[c[Tt^At]]],mt^=c[c[mt]])}return{SBOX:d,INV_SBOX:et,SUB_MIX:nt,INV_SUB_MIX:tt}}();function AES(c){this._key=asUInt32Array(c),this._reset()}AES.blockSize=4*4;AES.keySize=256/8;AES.prototype.blockSize=AES.blockSize;AES.prototype.keySize=AES.keySize;AES.prototype._reset=function(){for(var c=this._key,a=c.length,d=a+6,et=(d+1)*4,nt=[],tt=0;tt>>24,bt=G.SBOX[bt>>>24]<<24|G.SBOX[bt>>>16&255]<<16|G.SBOX[bt>>>8&255]<<8|G.SBOX[bt&255],bt^=RCON[tt/a|0]<<24):a>6&&tt%a===4&&(bt=G.SBOX[bt>>>24]<<24|G.SBOX[bt>>>16&255]<<16|G.SBOX[bt>>>8&255]<<8|G.SBOX[bt&255]),nt[tt]=nt[tt-a]^bt}for(var mt=[],vt=0;vt>>24]]^G.INV_SUB_MIX[1][G.SBOX[At>>>16&255]]^G.INV_SUB_MIX[2][G.SBOX[At>>>8&255]]^G.INV_SUB_MIX[3][G.SBOX[At&255]]}this._nRounds=d,this._keySchedule=nt,this._invKeySchedule=mt};AES.prototype.encryptBlockRaw=function(c){return c=asUInt32Array(c),cryptBlock(c,this._keySchedule,G.SUB_MIX,G.SBOX,this._nRounds)};AES.prototype.encryptBlock=function(c){var a=this.encryptBlockRaw(c),d=Buffer$d.allocUnsafe(16);return d.writeUInt32BE(a[0],0),d.writeUInt32BE(a[1],4),d.writeUInt32BE(a[2],8),d.writeUInt32BE(a[3],12),d};AES.prototype.decryptBlock=function(c){c=asUInt32Array(c);var a=c[1];c[1]=c[3],c[3]=a;var d=cryptBlock(c,this._invKeySchedule,G.INV_SUB_MIX,G.INV_SBOX,this._nRounds),et=Buffer$d.allocUnsafe(16);return et.writeUInt32BE(d[0],0),et.writeUInt32BE(d[3],4),et.writeUInt32BE(d[2],8),et.writeUInt32BE(d[1],12),et};AES.prototype.scrub=function(){scrubVec(this._keySchedule),scrubVec(this._invKeySchedule),scrubVec(this._key)};aes$6.AES=AES;var Buffer$c=safeBufferExports$1.Buffer,ZEROES=Buffer$c.alloc(16,0);function toArray$1(c){return[c.readUInt32BE(0),c.readUInt32BE(4),c.readUInt32BE(8),c.readUInt32BE(12)]}function fromArray(c){var a=Buffer$c.allocUnsafe(16);return a.writeUInt32BE(c[0]>>>0,0),a.writeUInt32BE(c[1]>>>0,4),a.writeUInt32BE(c[2]>>>0,8),a.writeUInt32BE(c[3]>>>0,12),a}function GHASH$1(c){this.h=c,this.state=Buffer$c.alloc(16,0),this.cache=Buffer$c.allocUnsafe(0)}GHASH$1.prototype.ghash=function(c){for(var a=-1;++a0;d--)c[d]=c[d]>>>1|(c[d-1]&1)<<31;c[0]=c[0]>>>1,nt&&(c[0]=c[0]^225<<24)}this.state=fromArray(a)};GHASH$1.prototype.update=function(c){this.cache=Buffer$c.concat([this.cache,c]);for(var a;this.cache.length>=16;)a=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(a)};GHASH$1.prototype.final=function(c,a){return this.cache.length&&this.ghash(Buffer$c.concat([this.cache,ZEROES],16)),this.ghash(fromArray([0,c,0,a])),this.state};var ghash=GHASH$1,aes$5=aes$6,Buffer$b=safeBufferExports$1.Buffer,Transform$5=cipherBase,inherits$b=inherits_browserExports,GHASH=ghash,xor$3=bufferXor,incr32=incr32_1;function xorTest(c,a){var d=0;c.length!==a.length&&d++;for(var et=Math.min(c.length,a.length),nt=0;nt0||et>0;){var vt=new MD5;vt.update(mt),vt.update(c),a&&vt.update(a),mt=vt.digest();var $t=0;if(nt>0){var At=tt.length-nt;$t=Math.min(nt,mt.length),mt.copy(tt,At,0,$t),nt-=$t}if($t0){var Mt=bt.length-et,Tt=Math.min(et,mt.length-$t);mt.copy(bt,Mt,$t,$t+Tt),et-=Tt}}return mt.fill(0),{key:tt,iv:bt}}var evp_bytestokey=EVP_BytesToKey,MODES$1=modes_1,AuthCipher$1=authCipher,Buffer$8=safeBufferExports$1.Buffer,StreamCipher$1=streamCipher,Transform$3=cipherBase,aes$3=aes$6,ebtk$2=evp_bytestokey,inherits$9=inherits_browserExports;function Cipher(c,a,d){Transform$3.call(this),this._cache=new Splitter$1,this._cipher=new aes$3.AES(a),this._prev=Buffer$8.from(d),this._mode=c,this._autopadding=!0}inherits$9(Cipher,Transform$3);Cipher.prototype._update=function(c){this._cache.add(c);for(var a,d,et=[];a=this._cache.get();)d=this._mode.encrypt(this,a),et.push(d);return Buffer$8.concat(et)};var PADDING=Buffer$8.alloc(16,16);Cipher.prototype._final=function(){var c=this._cache.flush();if(this._autopadding)return c=this._mode.encrypt(this,c),this._cipher.scrub(),c;if(!c.equals(PADDING))throw this._cipher.scrub(),new Error("data not multiple of block length")};Cipher.prototype.setAutoPadding=function(c){return this._autopadding=!!c,this};function Splitter$1(){this.cache=Buffer$8.allocUnsafe(0)}Splitter$1.prototype.add=function(c){this.cache=Buffer$8.concat([this.cache,c])};Splitter$1.prototype.get=function(){if(this.cache.length>15){var c=this.cache.slice(0,16);return this.cache=this.cache.slice(16),c}return null};Splitter$1.prototype.flush=function(){for(var c=16-this.cache.length,a=Buffer$8.allocUnsafe(c),d=-1;++d16)return a=this.cache.slice(0,16),this.cache=this.cache.slice(16),a}else if(this.cache.length>=16)return a=this.cache.slice(0,16),this.cache=this.cache.slice(16),a;return null};Splitter.prototype.flush=function(){if(this.cache.length)return this.cache};function unpad(c){var a=c[15];if(a<1||a>16)throw new Error("unable to decrypt data");for(var d=-1;++d0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$7);var bnExports$7=bn$7.exports,bn$6={exports:{}};bn$6.exports;(function(c){(function(a,d){function et(Ct,dt){if(!Ct)throw new Error(dt||"Assertion failed")}function nt(Ct,dt){Ct.super_=dt;var yt=function(){};yt.prototype=dt.prototype,Ct.prototype=new yt,Ct.prototype.constructor=Ct}function tt(Ct,dt,yt){if(tt.isBN(Ct))return Ct;this.negative=0,this.words=null,this.length=0,this.red=null,Ct!==null&&((dt==="le"||dt==="be")&&(yt=dt,dt=10),this._init(Ct||0,dt||10,yt||"be"))}typeof a=="object"?a.exports=tt:d.BN=tt,tt.BN=tt,tt.wordSize=26;var bt;try{typeof window<"u"&&typeof window.Buffer<"u"?bt=window.Buffer:bt=bufferPolyfill.Buffer}catch{}tt.isBN=function(dt){return dt instanceof tt?!0:dt!==null&&typeof dt=="object"&&dt.constructor.wordSize===tt.wordSize&&Array.isArray(dt.words)},tt.max=function(dt,yt){return dt.cmp(yt)>0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$6);var bnExports$6=bn$6.exports,brorand={exports:{}},hasRequiredBrorand;function requireBrorand(){if(hasRequiredBrorand)return brorand.exports;hasRequiredBrorand=1;var c;brorand.exports=function(nt){return c||(c=new a(null)),c.generate(nt)};function a(et){this.rand=et}if(brorand.exports.Rand=a,a.prototype.generate=function(nt){return this._rand(nt)},a.prototype._rand=function(nt){if(this.rand.getBytes)return this.rand.getBytes(nt);for(var tt=new Uint8Array(nt),bt=0;bt=0);return mt},d.prototype._randrange=function(nt,tt){var bt=tt.sub(nt);return nt.add(this._randbelow(bt))},d.prototype.test=function(nt,tt,bt){var mt=nt.bitLength(),vt=c.mont(nt),$t=new c(1).toRed(vt);tt||(tt=Math.max(1,mt/48|0));for(var At=nt.subn(1),Mt=0;!At.testn(Mt);Mt++);for(var Tt=nt.shrn(Mt),Rt=At.toRed(vt),kt=!0;tt>0;tt--){var It=this._randrange(new c(2),At);bt&&bt(It);var Dt=It.toRed(vt).redPow(Tt);if(!(Dt.cmp($t)===0||Dt.cmp(Rt)===0)){for(var Nt=1;Nt0;tt--){var Rt=this._randrange(new c(2),$t),kt=nt.gcd(Rt);if(kt.cmpn(1)!==0)return kt;var It=Rt.toRed(mt).redPow(Mt);if(!(It.cmp(vt)===0||It.cmp(Tt)===0)){for(var Dt=1;DtNt;)Ut.ishrn(1);if(Ut.isEven()&&Ut.iadd(tt),Ut.testn(1)||Ut.iadd(bt),Ot.cmp(bt)){if(!Ot.cmp(mt))for(;Ut.mod(vt).cmp($t);)Ut.iadd(Mt)}else for(;Ut.mod(d).cmp(At);)Ut.iadd(Mt);if(Gt=Ut.shrn(1),kt(Gt)&&kt(Ut)&&It(Gt)&&It(Ut)&&nt.test(Gt)&&nt.test(Ut))return Ut}}return generatePrime}const modp1={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"},require$$1$1={modp1,modp2,modp5,modp14,modp15,modp16,modp17,modp18};var dh,hasRequiredDh;function requireDh(){if(hasRequiredDh)return dh;hasRequiredDh=1;var c=bnExports$7,a=requireMr(),d=new a,et=new c(24),nt=new c(11),tt=new c(10),bt=new c(3),mt=new c(7),vt=requireGeneratePrime(),$t=browserExports;dh=kt;function At(Dt,Nt){return Nt=Nt||"utf8",dist$2.Buffer.isBuffer(Dt)||(Dt=new dist$2.Buffer(Dt,Nt)),this._pub=new c(Dt),this}function Mt(Dt,Nt){return Nt=Nt||"utf8",dist$2.Buffer.isBuffer(Dt)||(Dt=new dist$2.Buffer(Dt,Nt)),this._priv=new c(Dt),this}var Tt={};function Rt(Dt,Nt){var Ot=Nt.toString("hex"),Ut=[Ot,Dt.toString(16)].join("_");if(Ut in Tt)return Tt[Ut];var Gt=0;if(Dt.isEven()||!vt.simpleSieve||!vt.fermatTest(Dt)||!d.test(Dt))return Gt+=1,Ot==="02"||Ot==="05"?Gt+=8:Gt+=4,Tt[Ut]=Gt,Gt;d.test(Dt.shrn(1))||(Gt+=2);var Wt;switch(Ot){case"02":Dt.mod(et).cmp(nt)&&(Gt+=8);break;case"05":Wt=Dt.mod(tt),Wt.cmp(bt)&&Wt.cmp(mt)&&(Gt+=8);break;default:Gt+=4}return Tt[Ut]=Gt,Gt}function kt(Dt,Nt,Ot){this.setGenerator(Nt),this.__prime=new c(Dt),this._prime=c.mont(this.__prime),this._primeLen=Dt.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,Ot?(this.setPublicKey=At,this.setPrivateKey=Mt):this._primeCode=8}Object.defineProperty(kt.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=Rt(this.__prime,this.__gen)),this._primeCode}}),kt.prototype.generateKeys=function(){return this._priv||(this._priv=new c($t(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},kt.prototype.computeSecret=function(Dt){Dt=new c(Dt),Dt=Dt.toRed(this._prime);var Nt=Dt.redPow(this._priv).fromRed(),Ot=new dist$2.Buffer(Nt.toArray()),Ut=this.getPrime();if(Ot.length"u"||!dist$2.process.version||dist$2.process.version.indexOf("v0.")===0||dist$2.process.version.indexOf("v1.")===0&&dist$2.process.version.indexOf("v1.8.")!==0?processNextickArgs.exports={nextTick}:processNextickArgs.exports=dist$2.process;function nextTick(c,a,d,et){if(typeof c!="function")throw new TypeError('"callback" argument must be a function');var nt=arguments.length,tt,bt;switch(nt){case 0:case 1:return dist$2.process.nextTick(c);case 2:return dist$2.process.nextTick(function(){c.call(null,a)});case 3:return dist$2.process.nextTick(function(){c.call(null,a,d)});case 4:return dist$2.process.nextTick(function(){c.call(null,a,d,et)});default:for(tt=new Array(nt-1),bt=0;bt"u"}util$2.isPrimitive=isPrimitive;util$2.isBuffer=bufferPolyfill.Buffer.isBuffer;function objectToString(c){return Object.prototype.toString.call(c)}var BufferList={exports:{}},hasRequiredBufferList;function requireBufferList(){return hasRequiredBufferList||(hasRequiredBufferList=1,function(c){function a(tt,bt){if(!(tt instanceof bt))throw new TypeError("Cannot call a class as a function")}var d=safeBufferExports.Buffer,et=util$3;function nt(tt,bt,mt){tt.copy(bt,mt)}c.exports=function(){function tt(){a(this,tt),this.head=null,this.tail=null,this.length=0}return tt.prototype.push=function(mt){var vt={data:mt,next:null};this.length>0?this.tail.next=vt:this.head=vt,this.tail=vt,++this.length},tt.prototype.unshift=function(mt){var vt={data:mt,next:this.head};this.length===0&&(this.tail=vt),this.head=vt,++this.length},tt.prototype.shift=function(){if(this.length!==0){var mt=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,mt}},tt.prototype.clear=function(){this.head=this.tail=null,this.length=0},tt.prototype.join=function(mt){if(this.length===0)return"";for(var vt=this.head,$t=""+vt.data;vt=vt.next;)$t+=mt+vt.data;return $t},tt.prototype.concat=function(mt){if(this.length===0)return d.alloc(0);for(var vt=d.allocUnsafe(mt>>>0),$t=this.head,At=0;$t;)nt($t.data,vt,At),At+=$t.data.length,$t=$t.next;return vt},tt}(),et&&et.inspect&&et.inspect.custom&&(c.exports.prototype[et.inspect.custom]=function(){var tt=et.inspect({length:this.length});return this.constructor.name+" "+tt})}(BufferList)),BufferList.exports}var pna=processNextickArgsExports;function destroy(c,a){var d=this,et=this._readableState&&this._readableState.destroyed,nt=this._writableState&&this._writableState.destroyed;return et||nt?(a?a(c):c&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,this,c)):pna.nextTick(emitErrorNT,this,c)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(c||null,function(tt){!a&&tt?d._writableState?d._writableState.errorEmitted||(d._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,d,tt)):pna.nextTick(emitErrorNT,d,tt):a&&a(tt)}),this)}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(c,a){c.emit("error",a)}var destroy_1={destroy,undestroy},_stream_writable,hasRequired_stream_writable;function require_stream_writable(){if(hasRequired_stream_writable)return _stream_writable;hasRequired_stream_writable=1;var c=processNextickArgsExports;_stream_writable=It;function a(_t){var Pt=this;this.next=null,this.entry=null,this.finish=function(){St(Pt,_t)}}var d=!dist$2.process.browser&&["v0.10","v0.9."].indexOf(dist$2.process.version.slice(0,5))>-1?setImmediate:c.nextTick,et;It.WritableState=Rt;var nt=Object.create(util$2);nt.inherits=inherits_browserExports;var tt={deprecate:browser$a},bt=streamBrowser,mt=safeBufferExports.Buffer,vt=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function $t(_t){return mt.from(_t)}function At(_t){return mt.isBuffer(_t)||_t instanceof vt}var Mt=destroy_1;nt.inherits(It,bt);function Tt(){}function Rt(_t,Pt){et=et||require_stream_duplex(),_t=_t||{};var Et=Pt instanceof et;this.objectMode=!!_t.objectMode,Et&&(this.objectMode=this.objectMode||!!_t.writableObjectMode);var ht=_t.highWaterMark,wt=_t.writableHighWaterMark,Bt=this.objectMode?16:16*1024;ht||ht===0?this.highWaterMark=ht:Et&&(wt||wt===0)?this.highWaterMark=wt:this.highWaterMark=Bt,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Lt=_t.decodeStrings===!1;this.decodeStrings=!Lt,this.defaultEncoding=_t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(jt){a0(Pt,jt)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new a(this)}Rt.prototype.getBuffer=function(){for(var Pt=this.bufferedRequest,Et=[];Pt;)Et.push(Pt),Pt=Pt.next;return Et},function(){try{Object.defineProperty(Rt.prototype,"buffer",{get:tt.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var kt;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(kt=Function.prototype[Symbol.hasInstance],Object.defineProperty(It,Symbol.hasInstance,{value:function(_t){return kt.call(this,_t)?!0:this!==It?!1:_t&&_t._writableState instanceof Rt}})):kt=function(_t){return _t instanceof this};function It(_t){if(et=et||require_stream_duplex(),!kt.call(It,this)&&!(this instanceof et))return new It(_t);this._writableState=new Rt(_t,this),this.writable=!0,_t&&(typeof _t.write=="function"&&(this._write=_t.write),typeof _t.writev=="function"&&(this._writev=_t.writev),typeof _t.destroy=="function"&&(this._destroy=_t.destroy),typeof _t.final=="function"&&(this._final=_t.final)),bt.call(this)}It.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function Dt(_t,Pt){var Et=new Error("write after end");_t.emit("error",Et),c.nextTick(Pt,Et)}function Nt(_t,Pt,Et,ht){var wt=!0,Bt=!1;return Et===null?Bt=new TypeError("May not write null values to stream"):typeof Et!="string"&&Et!==void 0&&!Pt.objectMode&&(Bt=new TypeError("Invalid non-string/buffer chunk")),Bt&&(_t.emit("error",Bt),c.nextTick(ht,Bt),wt=!1),wt}It.prototype.write=function(_t,Pt,Et){var ht=this._writableState,wt=!1,Bt=!ht.objectMode&&At(_t);return Bt&&!mt.isBuffer(_t)&&(_t=$t(_t)),typeof Pt=="function"&&(Et=Pt,Pt=null),Bt?Pt="buffer":Pt||(Pt=ht.defaultEncoding),typeof Et!="function"&&(Et=Tt),ht.ended?Dt(this,Et):(Bt||Nt(this,ht,_t,Et))&&(ht.pendingcb++,wt=Ut(this,ht,Bt,_t,Pt,Et)),wt},It.prototype.cork=function(){var _t=this._writableState;_t.corked++},It.prototype.uncork=function(){var _t=this._writableState;_t.corked&&(_t.corked--,!_t.writing&&!_t.corked&&!_t.bufferProcessing&&_t.bufferedRequest&&c0(this,_t))},It.prototype.setDefaultEncoding=function(Pt){if(typeof Pt=="string"&&(Pt=Pt.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((Pt+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+Pt);return this._writableState.defaultEncoding=Pt,this};function Ot(_t,Pt,Et){return!_t.objectMode&&_t.decodeStrings!==!1&&typeof Pt=="string"&&(Pt=mt.from(Pt,Et)),Pt}Object.defineProperty(It.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function Ut(_t,Pt,Et,ht,wt,Bt){if(!Et){var Lt=Ot(Pt,ht,wt);ht!==Lt&&(Et=!0,wt="buffer",ht=Lt)}var jt=Pt.objectMode?1:ht.length;Pt.length+=jt;var Ft=Pt.length0?(typeof qt!="string"&&!Jt.objectMode&&Object.getPrototypeOf(qt)!==tt.prototype&&(qt=mt(qt)),e0?Jt.endEmitted?zt.emit("error",new Error("stream.unshift() after end event")):Gt(zt,Jt,qt,!0):Jt.ended?zt.emit("error",new Error("stream.push() after EOF")):(Jt.reading=!1,Jt.decoder&&!Kt?(qt=Jt.decoder.write(qt),Jt.objectMode||qt.length!==0?Gt(zt,Jt,qt,!1):yt(zt,Jt)):Gt(zt,Jt,qt,!1))):e0||(Jt.reading=!1)}return Xt(Jt)}function Gt(zt,qt,Kt,e0){qt.flowing&&qt.length===0&&!qt.sync?(zt.emit("data",Kt),zt.read(0)):(qt.length+=qt.objectMode?1:Kt.length,e0?qt.buffer.unshift(Kt):qt.buffer.push(Kt),qt.needReadable&&Ct(zt)),yt(zt,qt)}function Wt(zt,qt){var Kt;return!vt(qt)&&typeof qt!="string"&&qt!==void 0&&!zt.objectMode&&(Kt=new TypeError("Invalid non-string/buffer chunk")),Kt}function Xt(zt){return!zt.ended&&(zt.needReadable||zt.length=a0?zt=a0:(zt--,zt|=zt>>>1,zt|=zt>>>2,zt|=zt>>>4,zt|=zt>>>8,zt|=zt>>>16,zt++),zt}function t0(zt,qt){return zt<=0||qt.length===0&&qt.ended?0:qt.objectMode?1:zt!==zt?qt.flowing&&qt.length?qt.buffer.head.data.length:qt.length:(zt>qt.highWaterMark&&(qt.highWaterMark=n0(zt)),zt<=qt.length?zt:qt.ended?qt.length:(qt.needReadable=!0,0))}Ot.prototype.read=function(zt){Mt("read",zt),zt=parseInt(zt,10);var qt=this._readableState,Kt=zt;if(zt!==0&&(qt.emittedReadable=!1),zt===0&&qt.needReadable&&(qt.length>=qt.highWaterMark||qt.ended))return Mt("read: emitReadable",qt.length,qt.ended),qt.length===0&&qt.ended?jt(this):Ct(this),null;if(zt=t0(zt,qt),zt===0&&qt.ended)return qt.length===0&&jt(this),null;var e0=qt.needReadable;Mt("need readable",e0),(qt.length===0||qt.length-zt0?Zt=ht(zt,qt):Zt=null,Zt===null?(qt.needReadable=!0,zt=0):qt.length-=zt,qt.length===0&&(qt.ended||(qt.needReadable=!0),Kt!==zt&&qt.ended&&jt(this)),Zt!==null&&this.emit("data",Zt),Zt};function c0(zt,qt){if(!qt.ended){if(qt.decoder){var Kt=qt.decoder.end();Kt&&Kt.length&&(qt.buffer.push(Kt),qt.length+=qt.objectMode?1:Kt.length)}qt.ended=!0,Ct(zt)}}function Ct(zt){var qt=zt._readableState;qt.needReadable=!1,qt.emittedReadable||(Mt("emitReadable",qt.flowing),qt.emittedReadable=!0,qt.sync?c.nextTick(dt,zt):dt(zt))}function dt(zt){Mt("emit readable"),zt.emit("readable"),Et(zt)}function yt(zt,qt){qt.readingMore||(qt.readingMore=!0,c.nextTick(gt,zt,qt))}function gt(zt,qt){for(var Kt=qt.length;!qt.reading&&!qt.flowing&&!qt.ended&&qt.length1&&Vt(e0.pipes,zt)!==-1)&&!l0&&(Mt("false write response, pause",e0.awaitDrain),e0.awaitDrain++,p0=!0),Kt.pause())}function J0(w0){Mt("onerror",w0),Z0(),zt.removeListener("error",J0),et(zt,"error")===0&&zt.emit("error",w0)}Dt(zt,"error",J0);function v0(){zt.removeListener("finish",E0),Z0()}zt.once("close",v0);function E0(){Mt("onfinish"),zt.removeListener("close",v0),Z0()}zt.once("finish",E0);function Z0(){Mt("unpipe"),Kt.unpipe(zt)}return zt.emit("pipe",Kt),e0.flowing||(Mt("pipe resume"),Kt.resume()),zt};function xt(zt){return function(){var qt=zt._readableState;Mt("pipeOnDrain",qt.awaitDrain),qt.awaitDrain&&qt.awaitDrain--,qt.awaitDrain===0&&et(zt,"data")&&(qt.flowing=!0,Et(zt))}}Ot.prototype.unpipe=function(zt){var qt=this._readableState,Kt={hasUnpiped:!1};if(qt.pipesCount===0)return this;if(qt.pipesCount===1)return zt&&zt!==qt.pipes?this:(zt||(zt=qt.pipes),qt.pipes=null,qt.pipesCount=0,qt.flowing=!1,zt&&zt.emit("unpipe",this,Kt),this);if(!zt){var e0=qt.pipes,Zt=qt.pipesCount;qt.pipes=null,qt.pipesCount=0,qt.flowing=!1;for(var Jt=0;Jt=qt.length?(qt.decoder?Kt=qt.buffer.join(""):qt.buffer.length===1?Kt=qt.buffer.head.data:Kt=qt.buffer.concat(qt.length),qt.buffer.clear()):Kt=wt(zt,qt.buffer,qt.decoder),Kt}function wt(zt,qt,Kt){var e0;return ztJt.length?Jt.length:zt;if(i0===Jt.length?Zt+=Jt:Zt+=Jt.slice(0,zt),zt-=i0,zt===0){i0===Jt.length?(++e0,Kt.next?qt.head=Kt.next:qt.head=qt.tail=null):(qt.head=Kt,Kt.data=Jt.slice(i0));break}++e0}return qt.length-=e0,Zt}function Lt(zt,qt){var Kt=tt.allocUnsafe(zt),e0=qt.head,Zt=1;for(e0.data.copy(Kt),zt-=e0.data.length;e0=e0.next;){var Jt=e0.data,i0=zt>Jt.length?Jt.length:zt;if(Jt.copy(Kt,Kt.length-zt,0,i0),zt-=i0,zt===0){i0===Jt.length?(++Zt,e0.next?qt.head=e0.next:qt.head=qt.tail=null):(qt.head=e0,e0.data=Jt.slice(i0));break}++Zt}return qt.length-=Zt,Kt}function jt(zt){var qt=zt._readableState;if(qt.length>0)throw new Error('"endReadable()" called on non-empty stream');qt.endEmitted||(qt.ended=!0,c.nextTick(Ft,qt,zt))}function Ft(zt,qt){!zt.endEmitted&&zt.length===0&&(zt.endEmitted=!0,qt.readable=!1,qt.emit("end"))}function Vt(zt,qt){for(var Kt=0,e0=zt.length;Kt0?gt:xt},tt.min=function(gt,xt){return gt.cmp(xt)<0?gt:xt},tt.prototype._init=function(gt,xt,St){if(typeof gt=="number")return this._initNumber(gt,xt,St);if(typeof gt=="object")return this._initArray(gt,xt,St);xt==="hex"&&(xt=16),et(xt===(xt|0)&&xt>=2&&xt<=36),gt=gt.toString().replace(/\s+/g,"");var _t=0;gt[0]==="-"&&(_t++,this.negative=1),_t=0;_t-=3)Et=gt[_t]|gt[_t-1]<<8|gt[_t-2]<<16,this.words[Pt]|=Et<>>26-ht&67108863,ht+=24,ht>=26&&(ht-=26,Pt++);else if(St==="le")for(_t=0,Pt=0;_t>>26-ht&67108863,ht+=24,ht>=26&&(ht-=26,Pt++);return this._strip()};function mt(yt,gt){var xt=yt.charCodeAt(gt);if(xt>=48&&xt<=57)return xt-48;if(xt>=65&&xt<=70)return xt-55;if(xt>=97&&xt<=102)return xt-87;et(!1,"Invalid character in "+yt)}function vt(yt,gt,xt){var St=mt(yt,xt);return xt-1>=gt&&(St|=mt(yt,xt-1)<<4),St}tt.prototype._parseHex=function(gt,xt,St){this.length=Math.ceil((gt.length-xt)/6),this.words=new Array(this.length);for(var _t=0;_t=xt;_t-=2)ht=vt(gt,xt,_t)<=18?(Pt-=18,Et+=1,this.words[Et]|=ht>>>26):Pt+=8;else{var wt=gt.length-xt;for(_t=wt%2===0?xt+1:xt;_t=18?(Pt-=18,Et+=1,this.words[Et]|=ht>>>26):Pt+=8}this._strip()};function $t(yt,gt,xt,St){for(var _t=0,Pt=0,Et=Math.min(yt.length,xt),ht=gt;ht=49?Pt=wt-49+10:wt>=17?Pt=wt-17+10:Pt=wt,et(wt>=0&&Pt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{tt.prototype[Symbol.for("nodejs.util.inspect.custom")]=Mt}catch{tt.prototype.inspect=Mt}else tt.prototype.inspect=Mt;function Mt(){return(this.red?""}var Tt=["","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"],Rt=[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],kt=[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];tt.prototype.toString=function(gt,xt){gt=gt||10,xt=xt|0||1;var St;if(gt===16||gt==="hex"){St="";for(var _t=0,Pt=0,Et=0;Et>>24-_t&16777215,_t+=2,_t>=26&&(_t-=26,Et--),Pt!==0||Et!==this.length-1?St=Tt[6-wt.length]+wt+St:St=wt+St}for(Pt!==0&&(St=Pt.toString(16)+St);St.length%xt!==0;)St="0"+St;return this.negative!==0&&(St="-"+St),St}if(gt===(gt|0)&>>=2&><=36){var Bt=Rt[gt],Lt=kt[gt];St="";var jt=this.clone();for(jt.negative=0;!jt.isZero();){var Ft=jt.modrn(Lt).toString(gt);jt=jt.idivn(Lt),jt.isZero()?St=Ft+St:St=Tt[Bt-Ft.length]+Ft+St}for(this.isZero()&&(St="0"+St);St.length%xt!==0;)St="0"+St;return this.negative!==0&&(St="-"+St),St}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var gt=this.words[0];return this.length===2?gt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?gt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-gt:gt},tt.prototype.toJSON=function(){return this.toString(16,2)},bt&&(tt.prototype.toBuffer=function(gt,xt){return this.toArrayLike(bt,gt,xt)}),tt.prototype.toArray=function(gt,xt){return this.toArrayLike(Array,gt,xt)};var It=function(gt,xt){return gt.allocUnsafe?gt.allocUnsafe(xt):new gt(xt)};tt.prototype.toArrayLike=function(gt,xt,St){this._strip();var _t=this.byteLength(),Pt=St||Math.max(1,_t);et(_t<=Pt,"byte array longer than desired length"),et(Pt>0,"Requested array length <= 0");var Et=It(gt,Pt),ht=xt==="le"?"LE":"BE";return this["_toArrayLike"+ht](Et,_t),Et},tt.prototype._toArrayLikeLE=function(gt,xt){for(var St=0,_t=0,Pt=0,Et=0;Pt>8&255),St>16&255),Et===6?(St>24&255),_t=0,Et=0):(_t=ht>>>24,Et+=2)}if(St=0&&(gt[St--]=ht>>8&255),St>=0&&(gt[St--]=ht>>16&255),Et===6?(St>=0&&(gt[St--]=ht>>24&255),_t=0,Et=0):(_t=ht>>>24,Et+=2)}if(St>=0)for(gt[St--]=_t;St>=0;)gt[St--]=0},Math.clz32?tt.prototype._countBits=function(gt){return 32-Math.clz32(gt)}:tt.prototype._countBits=function(gt){var xt=gt,St=0;return xt>=4096&&(St+=13,xt>>>=13),xt>=64&&(St+=7,xt>>>=7),xt>=8&&(St+=4,xt>>>=4),xt>=2&&(St+=2,xt>>>=2),St+xt},tt.prototype._zeroBits=function(gt){if(gt===0)return 26;var xt=gt,St=0;return xt&8191||(St+=13,xt>>>=13),xt&127||(St+=7,xt>>>=7),xt&15||(St+=4,xt>>>=4),xt&3||(St+=2,xt>>>=2),xt&1||St++,St},tt.prototype.bitLength=function(){var gt=this.words[this.length-1],xt=this._countBits(gt);return(this.length-1)*26+xt};function Dt(yt){for(var gt=new Array(yt.bitLength()),xt=0;xt>>_t&1}return gt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var gt=0,xt=0;xtgt.length?this.clone().ior(gt):gt.clone().ior(this)},tt.prototype.uor=function(gt){return this.length>gt.length?this.clone().iuor(gt):gt.clone().iuor(this)},tt.prototype.iuand=function(gt){var xt;this.length>gt.length?xt=gt:xt=this;for(var St=0;Stgt.length?this.clone().iand(gt):gt.clone().iand(this)},tt.prototype.uand=function(gt){return this.length>gt.length?this.clone().iuand(gt):gt.clone().iuand(this)},tt.prototype.iuxor=function(gt){var xt,St;this.length>gt.length?(xt=this,St=gt):(xt=gt,St=this);for(var _t=0;_tgt.length?this.clone().ixor(gt):gt.clone().ixor(this)},tt.prototype.uxor=function(gt){return this.length>gt.length?this.clone().iuxor(gt):gt.clone().iuxor(this)},tt.prototype.inotn=function(gt){et(typeof gt=="number"&>>=0);var xt=Math.ceil(gt/26)|0,St=gt%26;this._expand(xt),St>0&&xt--;for(var _t=0;_t0&&(this.words[_t]=~this.words[_t]&67108863>>26-St),this._strip()},tt.prototype.notn=function(gt){return this.clone().inotn(gt)},tt.prototype.setn=function(gt,xt){et(typeof gt=="number"&>>=0);var St=gt/26|0,_t=gt%26;return this._expand(St+1),xt?this.words[St]=this.words[St]|1<<_t:this.words[St]=this.words[St]&~(1<<_t),this._strip()},tt.prototype.iadd=function(gt){var xt;if(this.negative!==0&>.negative===0)return this.negative=0,xt=this.isub(gt),this.negative^=1,this._normSign();if(this.negative===0&>.negative!==0)return gt.negative=0,xt=this.isub(gt),gt.negative=1,xt._normSign();var St,_t;this.length>gt.length?(St=this,_t=gt):(St=gt,_t=this);for(var Pt=0,Et=0;Et<_t.length;Et++)xt=(St.words[Et]|0)+(_t.words[Et]|0)+Pt,this.words[Et]=xt&67108863,Pt=xt>>>26;for(;Pt!==0&&Et>>26;if(this.length=St.length,Pt!==0)this.words[this.length]=Pt,this.length++;else if(St!==this)for(;Etgt.length?this.clone().iadd(gt):gt.clone().iadd(this)},tt.prototype.isub=function(gt){if(gt.negative!==0){gt.negative=0;var xt=this.iadd(gt);return gt.negative=1,xt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(gt),this.negative=1,this._normSign();var St=this.cmp(gt);if(St===0)return this.negative=0,this.length=1,this.words[0]=0,this;var _t,Pt;St>0?(_t=this,Pt=gt):(_t=gt,Pt=this);for(var Et=0,ht=0;ht>26,this.words[ht]=xt&67108863;for(;Et!==0&&ht<_t.length;ht++)xt=(_t.words[ht]|0)+Et,Et=xt>>26,this.words[ht]=xt&67108863;if(Et===0&&ht<_t.length&&_t!==this)for(;ht<_t.length;ht++)this.words[ht]=_t.words[ht];return this.length=Math.max(this.length,ht),_t!==this&&(this.negative=1),this._strip()},tt.prototype.sub=function(gt){return this.clone().isub(gt)};function Nt(yt,gt,xt){xt.negative=gt.negative^yt.negative;var St=yt.length+gt.length|0;xt.length=St,St=St-1|0;var _t=yt.words[0]|0,Pt=gt.words[0]|0,Et=_t*Pt,ht=Et&67108863,wt=Et/67108864|0;xt.words[0]=ht;for(var Bt=1;Bt>>26,jt=wt&67108863,Ft=Math.min(Bt,gt.length-1),Vt=Math.max(0,Bt-yt.length+1);Vt<=Ft;Vt++){var zt=Bt-Vt|0;_t=yt.words[zt]|0,Pt=gt.words[Vt]|0,Et=_t*Pt+jt,Lt+=Et/67108864|0,jt=Et&67108863}xt.words[Bt]=jt|0,wt=Lt|0}return wt!==0?xt.words[Bt]=wt|0:xt.length--,xt._strip()}var Ot=function(gt,xt,St){var _t=gt.words,Pt=xt.words,Et=St.words,ht=0,wt,Bt,Lt,jt=_t[0]|0,Ft=jt&8191,Vt=jt>>>13,zt=_t[1]|0,qt=zt&8191,Kt=zt>>>13,e0=_t[2]|0,Zt=e0&8191,Jt=e0>>>13,i0=_t[3]|0,h0=i0&8191,o0=i0>>>13,l0=_t[4]|0,$0=l0&8191,p0=l0>>>13,u0=_t[5]|0,J0=u0&8191,v0=u0>>>13,E0=_t[6]|0,Z0=E0&8191,w0=E0>>>13,b0=_t[7]|0,K0=b0&8191,Qt=b0>>>13,Ht=_t[8]|0,Yt=Ht&8191,r0=Ht>>>13,f0=_t[9]|0,x0=f0&8191,d0=f0>>>13,y0=Pt[0]|0,Q0=y0&8191,g0=y0>>>13,A0=Pt[1]|0,Y0=A0&8191,_0=A0>>>13,N0=Pt[2]|0,X0=N0&8191,M0=N0>>>13,O0=Pt[3]|0,rr=O0&8191,P0=O0>>>13,D0=Pt[4]|0,nr=D0&8191,C0=D0>>>13,F0=Pt[5]|0,ir=F0&8191,R0=F0>>>13,U0=Pt[6]|0,ar=U0&8191,B0=U0>>>13,z0=Pt[7]|0,or=z0&8191,k0=z0>>>13,H0=Pt[8]|0,fr=H0&8191,I0=H0>>>13,j0=Pt[9]|0,er=j0&8191,tr=j0>>>13;St.negative=gt.negative^xt.negative,St.length=19,wt=Math.imul(Ft,Q0),Bt=Math.imul(Ft,g0),Bt=Bt+Math.imul(Vt,Q0)|0,Lt=Math.imul(Vt,g0);var cr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(cr>>>26)|0,cr&=67108863,wt=Math.imul(qt,Q0),Bt=Math.imul(qt,g0),Bt=Bt+Math.imul(Kt,Q0)|0,Lt=Math.imul(Kt,g0),wt=wt+Math.imul(Ft,Y0)|0,Bt=Bt+Math.imul(Ft,_0)|0,Bt=Bt+Math.imul(Vt,Y0)|0,Lt=Lt+Math.imul(Vt,_0)|0;var lr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(lr>>>26)|0,lr&=67108863,wt=Math.imul(Zt,Q0),Bt=Math.imul(Zt,g0),Bt=Bt+Math.imul(Jt,Q0)|0,Lt=Math.imul(Jt,g0),wt=wt+Math.imul(qt,Y0)|0,Bt=Bt+Math.imul(qt,_0)|0,Bt=Bt+Math.imul(Kt,Y0)|0,Lt=Lt+Math.imul(Kt,_0)|0,wt=wt+Math.imul(Ft,X0)|0,Bt=Bt+Math.imul(Ft,M0)|0,Bt=Bt+Math.imul(Vt,X0)|0,Lt=Lt+Math.imul(Vt,M0)|0;var ur=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(ur>>>26)|0,ur&=67108863,wt=Math.imul(h0,Q0),Bt=Math.imul(h0,g0),Bt=Bt+Math.imul(o0,Q0)|0,Lt=Math.imul(o0,g0),wt=wt+Math.imul(Zt,Y0)|0,Bt=Bt+Math.imul(Zt,_0)|0,Bt=Bt+Math.imul(Jt,Y0)|0,Lt=Lt+Math.imul(Jt,_0)|0,wt=wt+Math.imul(qt,X0)|0,Bt=Bt+Math.imul(qt,M0)|0,Bt=Bt+Math.imul(Kt,X0)|0,Lt=Lt+Math.imul(Kt,M0)|0,wt=wt+Math.imul(Ft,rr)|0,Bt=Bt+Math.imul(Ft,P0)|0,Bt=Bt+Math.imul(Vt,rr)|0,Lt=Lt+Math.imul(Vt,P0)|0;var dr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(dr>>>26)|0,dr&=67108863,wt=Math.imul($0,Q0),Bt=Math.imul($0,g0),Bt=Bt+Math.imul(p0,Q0)|0,Lt=Math.imul(p0,g0),wt=wt+Math.imul(h0,Y0)|0,Bt=Bt+Math.imul(h0,_0)|0,Bt=Bt+Math.imul(o0,Y0)|0,Lt=Lt+Math.imul(o0,_0)|0,wt=wt+Math.imul(Zt,X0)|0,Bt=Bt+Math.imul(Zt,M0)|0,Bt=Bt+Math.imul(Jt,X0)|0,Lt=Lt+Math.imul(Jt,M0)|0,wt=wt+Math.imul(qt,rr)|0,Bt=Bt+Math.imul(qt,P0)|0,Bt=Bt+Math.imul(Kt,rr)|0,Lt=Lt+Math.imul(Kt,P0)|0,wt=wt+Math.imul(Ft,nr)|0,Bt=Bt+Math.imul(Ft,C0)|0,Bt=Bt+Math.imul(Vt,nr)|0,Lt=Lt+Math.imul(Vt,C0)|0;var pr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(pr>>>26)|0,pr&=67108863,wt=Math.imul(J0,Q0),Bt=Math.imul(J0,g0),Bt=Bt+Math.imul(v0,Q0)|0,Lt=Math.imul(v0,g0),wt=wt+Math.imul($0,Y0)|0,Bt=Bt+Math.imul($0,_0)|0,Bt=Bt+Math.imul(p0,Y0)|0,Lt=Lt+Math.imul(p0,_0)|0,wt=wt+Math.imul(h0,X0)|0,Bt=Bt+Math.imul(h0,M0)|0,Bt=Bt+Math.imul(o0,X0)|0,Lt=Lt+Math.imul(o0,M0)|0,wt=wt+Math.imul(Zt,rr)|0,Bt=Bt+Math.imul(Zt,P0)|0,Bt=Bt+Math.imul(Jt,rr)|0,Lt=Lt+Math.imul(Jt,P0)|0,wt=wt+Math.imul(qt,nr)|0,Bt=Bt+Math.imul(qt,C0)|0,Bt=Bt+Math.imul(Kt,nr)|0,Lt=Lt+Math.imul(Kt,C0)|0,wt=wt+Math.imul(Ft,ir)|0,Bt=Bt+Math.imul(Ft,R0)|0,Bt=Bt+Math.imul(Vt,ir)|0,Lt=Lt+Math.imul(Vt,R0)|0;var br=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(br>>>26)|0,br&=67108863,wt=Math.imul(Z0,Q0),Bt=Math.imul(Z0,g0),Bt=Bt+Math.imul(w0,Q0)|0,Lt=Math.imul(w0,g0),wt=wt+Math.imul(J0,Y0)|0,Bt=Bt+Math.imul(J0,_0)|0,Bt=Bt+Math.imul(v0,Y0)|0,Lt=Lt+Math.imul(v0,_0)|0,wt=wt+Math.imul($0,X0)|0,Bt=Bt+Math.imul($0,M0)|0,Bt=Bt+Math.imul(p0,X0)|0,Lt=Lt+Math.imul(p0,M0)|0,wt=wt+Math.imul(h0,rr)|0,Bt=Bt+Math.imul(h0,P0)|0,Bt=Bt+Math.imul(o0,rr)|0,Lt=Lt+Math.imul(o0,P0)|0,wt=wt+Math.imul(Zt,nr)|0,Bt=Bt+Math.imul(Zt,C0)|0,Bt=Bt+Math.imul(Jt,nr)|0,Lt=Lt+Math.imul(Jt,C0)|0,wt=wt+Math.imul(qt,ir)|0,Bt=Bt+Math.imul(qt,R0)|0,Bt=Bt+Math.imul(Kt,ir)|0,Lt=Lt+Math.imul(Kt,R0)|0,wt=wt+Math.imul(Ft,ar)|0,Bt=Bt+Math.imul(Ft,B0)|0,Bt=Bt+Math.imul(Vt,ar)|0,Lt=Lt+Math.imul(Vt,B0)|0;var yr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(yr>>>26)|0,yr&=67108863,wt=Math.imul(K0,Q0),Bt=Math.imul(K0,g0),Bt=Bt+Math.imul(Qt,Q0)|0,Lt=Math.imul(Qt,g0),wt=wt+Math.imul(Z0,Y0)|0,Bt=Bt+Math.imul(Z0,_0)|0,Bt=Bt+Math.imul(w0,Y0)|0,Lt=Lt+Math.imul(w0,_0)|0,wt=wt+Math.imul(J0,X0)|0,Bt=Bt+Math.imul(J0,M0)|0,Bt=Bt+Math.imul(v0,X0)|0,Lt=Lt+Math.imul(v0,M0)|0,wt=wt+Math.imul($0,rr)|0,Bt=Bt+Math.imul($0,P0)|0,Bt=Bt+Math.imul(p0,rr)|0,Lt=Lt+Math.imul(p0,P0)|0,wt=wt+Math.imul(h0,nr)|0,Bt=Bt+Math.imul(h0,C0)|0,Bt=Bt+Math.imul(o0,nr)|0,Lt=Lt+Math.imul(o0,C0)|0,wt=wt+Math.imul(Zt,ir)|0,Bt=Bt+Math.imul(Zt,R0)|0,Bt=Bt+Math.imul(Jt,ir)|0,Lt=Lt+Math.imul(Jt,R0)|0,wt=wt+Math.imul(qt,ar)|0,Bt=Bt+Math.imul(qt,B0)|0,Bt=Bt+Math.imul(Kt,ar)|0,Lt=Lt+Math.imul(Kt,B0)|0,wt=wt+Math.imul(Ft,or)|0,Bt=Bt+Math.imul(Ft,k0)|0,Bt=Bt+Math.imul(Vt,or)|0,Lt=Lt+Math.imul(Vt,k0)|0;var gr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(gr>>>26)|0,gr&=67108863,wt=Math.imul(Yt,Q0),Bt=Math.imul(Yt,g0),Bt=Bt+Math.imul(r0,Q0)|0,Lt=Math.imul(r0,g0),wt=wt+Math.imul(K0,Y0)|0,Bt=Bt+Math.imul(K0,_0)|0,Bt=Bt+Math.imul(Qt,Y0)|0,Lt=Lt+Math.imul(Qt,_0)|0,wt=wt+Math.imul(Z0,X0)|0,Bt=Bt+Math.imul(Z0,M0)|0,Bt=Bt+Math.imul(w0,X0)|0,Lt=Lt+Math.imul(w0,M0)|0,wt=wt+Math.imul(J0,rr)|0,Bt=Bt+Math.imul(J0,P0)|0,Bt=Bt+Math.imul(v0,rr)|0,Lt=Lt+Math.imul(v0,P0)|0,wt=wt+Math.imul($0,nr)|0,Bt=Bt+Math.imul($0,C0)|0,Bt=Bt+Math.imul(p0,nr)|0,Lt=Lt+Math.imul(p0,C0)|0,wt=wt+Math.imul(h0,ir)|0,Bt=Bt+Math.imul(h0,R0)|0,Bt=Bt+Math.imul(o0,ir)|0,Lt=Lt+Math.imul(o0,R0)|0,wt=wt+Math.imul(Zt,ar)|0,Bt=Bt+Math.imul(Zt,B0)|0,Bt=Bt+Math.imul(Jt,ar)|0,Lt=Lt+Math.imul(Jt,B0)|0,wt=wt+Math.imul(qt,or)|0,Bt=Bt+Math.imul(qt,k0)|0,Bt=Bt+Math.imul(Kt,or)|0,Lt=Lt+Math.imul(Kt,k0)|0,wt=wt+Math.imul(Ft,fr)|0,Bt=Bt+Math.imul(Ft,I0)|0,Bt=Bt+Math.imul(Vt,fr)|0,Lt=Lt+Math.imul(Vt,I0)|0;var vr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(vr>>>26)|0,vr&=67108863,wt=Math.imul(x0,Q0),Bt=Math.imul(x0,g0),Bt=Bt+Math.imul(d0,Q0)|0,Lt=Math.imul(d0,g0),wt=wt+Math.imul(Yt,Y0)|0,Bt=Bt+Math.imul(Yt,_0)|0,Bt=Bt+Math.imul(r0,Y0)|0,Lt=Lt+Math.imul(r0,_0)|0,wt=wt+Math.imul(K0,X0)|0,Bt=Bt+Math.imul(K0,M0)|0,Bt=Bt+Math.imul(Qt,X0)|0,Lt=Lt+Math.imul(Qt,M0)|0,wt=wt+Math.imul(Z0,rr)|0,Bt=Bt+Math.imul(Z0,P0)|0,Bt=Bt+Math.imul(w0,rr)|0,Lt=Lt+Math.imul(w0,P0)|0,wt=wt+Math.imul(J0,nr)|0,Bt=Bt+Math.imul(J0,C0)|0,Bt=Bt+Math.imul(v0,nr)|0,Lt=Lt+Math.imul(v0,C0)|0,wt=wt+Math.imul($0,ir)|0,Bt=Bt+Math.imul($0,R0)|0,Bt=Bt+Math.imul(p0,ir)|0,Lt=Lt+Math.imul(p0,R0)|0,wt=wt+Math.imul(h0,ar)|0,Bt=Bt+Math.imul(h0,B0)|0,Bt=Bt+Math.imul(o0,ar)|0,Lt=Lt+Math.imul(o0,B0)|0,wt=wt+Math.imul(Zt,or)|0,Bt=Bt+Math.imul(Zt,k0)|0,Bt=Bt+Math.imul(Jt,or)|0,Lt=Lt+Math.imul(Jt,k0)|0,wt=wt+Math.imul(qt,fr)|0,Bt=Bt+Math.imul(qt,I0)|0,Bt=Bt+Math.imul(Kt,fr)|0,Lt=Lt+Math.imul(Kt,I0)|0,wt=wt+Math.imul(Ft,er)|0,Bt=Bt+Math.imul(Ft,tr)|0,Bt=Bt+Math.imul(Vt,er)|0,Lt=Lt+Math.imul(Vt,tr)|0;var xr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(xr>>>26)|0,xr&=67108863,wt=Math.imul(x0,Y0),Bt=Math.imul(x0,_0),Bt=Bt+Math.imul(d0,Y0)|0,Lt=Math.imul(d0,_0),wt=wt+Math.imul(Yt,X0)|0,Bt=Bt+Math.imul(Yt,M0)|0,Bt=Bt+Math.imul(r0,X0)|0,Lt=Lt+Math.imul(r0,M0)|0,wt=wt+Math.imul(K0,rr)|0,Bt=Bt+Math.imul(K0,P0)|0,Bt=Bt+Math.imul(Qt,rr)|0,Lt=Lt+Math.imul(Qt,P0)|0,wt=wt+Math.imul(Z0,nr)|0,Bt=Bt+Math.imul(Z0,C0)|0,Bt=Bt+Math.imul(w0,nr)|0,Lt=Lt+Math.imul(w0,C0)|0,wt=wt+Math.imul(J0,ir)|0,Bt=Bt+Math.imul(J0,R0)|0,Bt=Bt+Math.imul(v0,ir)|0,Lt=Lt+Math.imul(v0,R0)|0,wt=wt+Math.imul($0,ar)|0,Bt=Bt+Math.imul($0,B0)|0,Bt=Bt+Math.imul(p0,ar)|0,Lt=Lt+Math.imul(p0,B0)|0,wt=wt+Math.imul(h0,or)|0,Bt=Bt+Math.imul(h0,k0)|0,Bt=Bt+Math.imul(o0,or)|0,Lt=Lt+Math.imul(o0,k0)|0,wt=wt+Math.imul(Zt,fr)|0,Bt=Bt+Math.imul(Zt,I0)|0,Bt=Bt+Math.imul(Jt,fr)|0,Lt=Lt+Math.imul(Jt,I0)|0,wt=wt+Math.imul(qt,er)|0,Bt=Bt+Math.imul(qt,tr)|0,Bt=Bt+Math.imul(Kt,er)|0,Lt=Lt+Math.imul(Kt,tr)|0;var wr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(wr>>>26)|0,wr&=67108863,wt=Math.imul(x0,X0),Bt=Math.imul(x0,M0),Bt=Bt+Math.imul(d0,X0)|0,Lt=Math.imul(d0,M0),wt=wt+Math.imul(Yt,rr)|0,Bt=Bt+Math.imul(Yt,P0)|0,Bt=Bt+Math.imul(r0,rr)|0,Lt=Lt+Math.imul(r0,P0)|0,wt=wt+Math.imul(K0,nr)|0,Bt=Bt+Math.imul(K0,C0)|0,Bt=Bt+Math.imul(Qt,nr)|0,Lt=Lt+Math.imul(Qt,C0)|0,wt=wt+Math.imul(Z0,ir)|0,Bt=Bt+Math.imul(Z0,R0)|0,Bt=Bt+Math.imul(w0,ir)|0,Lt=Lt+Math.imul(w0,R0)|0,wt=wt+Math.imul(J0,ar)|0,Bt=Bt+Math.imul(J0,B0)|0,Bt=Bt+Math.imul(v0,ar)|0,Lt=Lt+Math.imul(v0,B0)|0,wt=wt+Math.imul($0,or)|0,Bt=Bt+Math.imul($0,k0)|0,Bt=Bt+Math.imul(p0,or)|0,Lt=Lt+Math.imul(p0,k0)|0,wt=wt+Math.imul(h0,fr)|0,Bt=Bt+Math.imul(h0,I0)|0,Bt=Bt+Math.imul(o0,fr)|0,Lt=Lt+Math.imul(o0,I0)|0,wt=wt+Math.imul(Zt,er)|0,Bt=Bt+Math.imul(Zt,tr)|0,Bt=Bt+Math.imul(Jt,er)|0,Lt=Lt+Math.imul(Jt,tr)|0;var Er=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(Er>>>26)|0,Er&=67108863,wt=Math.imul(x0,rr),Bt=Math.imul(x0,P0),Bt=Bt+Math.imul(d0,rr)|0,Lt=Math.imul(d0,P0),wt=wt+Math.imul(Yt,nr)|0,Bt=Bt+Math.imul(Yt,C0)|0,Bt=Bt+Math.imul(r0,nr)|0,Lt=Lt+Math.imul(r0,C0)|0,wt=wt+Math.imul(K0,ir)|0,Bt=Bt+Math.imul(K0,R0)|0,Bt=Bt+Math.imul(Qt,ir)|0,Lt=Lt+Math.imul(Qt,R0)|0,wt=wt+Math.imul(Z0,ar)|0,Bt=Bt+Math.imul(Z0,B0)|0,Bt=Bt+Math.imul(w0,ar)|0,Lt=Lt+Math.imul(w0,B0)|0,wt=wt+Math.imul(J0,or)|0,Bt=Bt+Math.imul(J0,k0)|0,Bt=Bt+Math.imul(v0,or)|0,Lt=Lt+Math.imul(v0,k0)|0,wt=wt+Math.imul($0,fr)|0,Bt=Bt+Math.imul($0,I0)|0,Bt=Bt+Math.imul(p0,fr)|0,Lt=Lt+Math.imul(p0,I0)|0,wt=wt+Math.imul(h0,er)|0,Bt=Bt+Math.imul(h0,tr)|0,Bt=Bt+Math.imul(o0,er)|0,Lt=Lt+Math.imul(o0,tr)|0;var $r=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+($r>>>26)|0,$r&=67108863,wt=Math.imul(x0,nr),Bt=Math.imul(x0,C0),Bt=Bt+Math.imul(d0,nr)|0,Lt=Math.imul(d0,C0),wt=wt+Math.imul(Yt,ir)|0,Bt=Bt+Math.imul(Yt,R0)|0,Bt=Bt+Math.imul(r0,ir)|0,Lt=Lt+Math.imul(r0,R0)|0,wt=wt+Math.imul(K0,ar)|0,Bt=Bt+Math.imul(K0,B0)|0,Bt=Bt+Math.imul(Qt,ar)|0,Lt=Lt+Math.imul(Qt,B0)|0,wt=wt+Math.imul(Z0,or)|0,Bt=Bt+Math.imul(Z0,k0)|0,Bt=Bt+Math.imul(w0,or)|0,Lt=Lt+Math.imul(w0,k0)|0,wt=wt+Math.imul(J0,fr)|0,Bt=Bt+Math.imul(J0,I0)|0,Bt=Bt+Math.imul(v0,fr)|0,Lt=Lt+Math.imul(v0,I0)|0,wt=wt+Math.imul($0,er)|0,Bt=Bt+Math.imul($0,tr)|0,Bt=Bt+Math.imul(p0,er)|0,Lt=Lt+Math.imul(p0,tr)|0;var Sr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,wt=Math.imul(x0,ir),Bt=Math.imul(x0,R0),Bt=Bt+Math.imul(d0,ir)|0,Lt=Math.imul(d0,R0),wt=wt+Math.imul(Yt,ar)|0,Bt=Bt+Math.imul(Yt,B0)|0,Bt=Bt+Math.imul(r0,ar)|0,Lt=Lt+Math.imul(r0,B0)|0,wt=wt+Math.imul(K0,or)|0,Bt=Bt+Math.imul(K0,k0)|0,Bt=Bt+Math.imul(Qt,or)|0,Lt=Lt+Math.imul(Qt,k0)|0,wt=wt+Math.imul(Z0,fr)|0,Bt=Bt+Math.imul(Z0,I0)|0,Bt=Bt+Math.imul(w0,fr)|0,Lt=Lt+Math.imul(w0,I0)|0,wt=wt+Math.imul(J0,er)|0,Bt=Bt+Math.imul(J0,tr)|0,Bt=Bt+Math.imul(v0,er)|0,Lt=Lt+Math.imul(v0,tr)|0;var Ar=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,wt=Math.imul(x0,ar),Bt=Math.imul(x0,B0),Bt=Bt+Math.imul(d0,ar)|0,Lt=Math.imul(d0,B0),wt=wt+Math.imul(Yt,or)|0,Bt=Bt+Math.imul(Yt,k0)|0,Bt=Bt+Math.imul(r0,or)|0,Lt=Lt+Math.imul(r0,k0)|0,wt=wt+Math.imul(K0,fr)|0,Bt=Bt+Math.imul(K0,I0)|0,Bt=Bt+Math.imul(Qt,fr)|0,Lt=Lt+Math.imul(Qt,I0)|0,wt=wt+Math.imul(Z0,er)|0,Bt=Bt+Math.imul(Z0,tr)|0,Bt=Bt+Math.imul(w0,er)|0,Lt=Lt+Math.imul(w0,tr)|0;var Mr=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,wt=Math.imul(x0,or),Bt=Math.imul(x0,k0),Bt=Bt+Math.imul(d0,or)|0,Lt=Math.imul(d0,k0),wt=wt+Math.imul(Yt,fr)|0,Bt=Bt+Math.imul(Yt,I0)|0,Bt=Bt+Math.imul(r0,fr)|0,Lt=Lt+Math.imul(r0,I0)|0,wt=wt+Math.imul(K0,er)|0,Bt=Bt+Math.imul(K0,tr)|0,Bt=Bt+Math.imul(Qt,er)|0,Lt=Lt+Math.imul(Qt,tr)|0;var _r=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(_r>>>26)|0,_r&=67108863,wt=Math.imul(x0,fr),Bt=Math.imul(x0,I0),Bt=Bt+Math.imul(d0,fr)|0,Lt=Math.imul(d0,I0),wt=wt+Math.imul(Yt,er)|0,Bt=Bt+Math.imul(Yt,tr)|0,Bt=Bt+Math.imul(r0,er)|0,Lt=Lt+Math.imul(r0,tr)|0;var Do=(ht+wt|0)+((Bt&8191)<<13)|0;ht=(Lt+(Bt>>>13)|0)+(Do>>>26)|0,Do&=67108863,wt=Math.imul(x0,er),Bt=Math.imul(x0,tr),Bt=Bt+Math.imul(d0,er)|0,Lt=Math.imul(d0,tr);var Lo=(ht+wt|0)+((Bt&8191)<<13)|0;return ht=(Lt+(Bt>>>13)|0)+(Lo>>>26)|0,Lo&=67108863,Et[0]=cr,Et[1]=lr,Et[2]=ur,Et[3]=dr,Et[4]=pr,Et[5]=br,Et[6]=yr,Et[7]=gr,Et[8]=vr,Et[9]=xr,Et[10]=wr,Et[11]=Er,Et[12]=$r,Et[13]=Sr,Et[14]=Ar,Et[15]=Mr,Et[16]=_r,Et[17]=Do,Et[18]=Lo,ht!==0&&(Et[19]=ht,St.length++),St};Math.imul||(Ot=Nt);function Ut(yt,gt,xt){xt.negative=gt.negative^yt.negative,xt.length=yt.length+gt.length;for(var St=0,_t=0,Pt=0;Pt>>26)|0,_t+=Et>>>26,Et&=67108863}xt.words[Pt]=ht,St=Et,Et=_t}return St!==0?xt.words[Pt]=St:xt.length--,xt._strip()}function Gt(yt,gt,xt){return Ut(yt,gt,xt)}tt.prototype.mulTo=function(gt,xt){var St,_t=this.length+gt.length;return this.length===10&>.length===10?St=Ot(this,gt,xt):_t<63?St=Nt(this,gt,xt):_t<1024?St=Ut(this,gt,xt):St=Gt(this,gt,xt),St},tt.prototype.mul=function(gt){var xt=new tt(null);return xt.words=new Array(this.length+gt.length),this.mulTo(gt,xt)},tt.prototype.mulf=function(gt){var xt=new tt(null);return xt.words=new Array(this.length+gt.length),Gt(this,gt,xt)},tt.prototype.imul=function(gt){return this.clone().mulTo(gt,this)},tt.prototype.imuln=function(gt){var xt=gt<0;xt&&(gt=-gt),et(typeof gt=="number"),et(gt<67108864);for(var St=0,_t=0;_t>=26,St+=Pt/67108864|0,St+=Et>>>26,this.words[_t]=Et&67108863}return St!==0&&(this.words[_t]=St,this.length++),xt?this.ineg():this},tt.prototype.muln=function(gt){return this.clone().imuln(gt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(gt){var xt=Dt(gt);if(xt.length===0)return new tt(1);for(var St=this,_t=0;_t=0);var xt=gt%26,St=(gt-xt)/26,_t=67108863>>>26-xt<<26-xt,Pt;if(xt!==0){var Et=0;for(Pt=0;Pt>>26-xt}Et&&(this.words[Pt]=Et,this.length++)}if(St!==0){for(Pt=this.length-1;Pt>=0;Pt--)this.words[Pt+St]=this.words[Pt];for(Pt=0;Pt=0);var _t;xt?_t=(xt-xt%26)/26:_t=0;var Pt=gt%26,Et=Math.min((gt-Pt)/26,this.length),ht=67108863^67108863>>>Pt<Et)for(this.length-=Et,Bt=0;Bt=0&&(Lt!==0||Bt>=_t);Bt--){var jt=this.words[Bt]|0;this.words[Bt]=Lt<<26-Pt|jt>>>Pt,Lt=jt&ht}return wt&&Lt!==0&&(wt.words[wt.length++]=Lt),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},tt.prototype.ishrn=function(gt,xt,St){return et(this.negative===0),this.iushrn(gt,xt,St)},tt.prototype.shln=function(gt){return this.clone().ishln(gt)},tt.prototype.ushln=function(gt){return this.clone().iushln(gt)},tt.prototype.shrn=function(gt){return this.clone().ishrn(gt)},tt.prototype.ushrn=function(gt){return this.clone().iushrn(gt)},tt.prototype.testn=function(gt){et(typeof gt=="number"&>>=0);var xt=gt%26,St=(gt-xt)/26,_t=1<=0);var xt=gt%26,St=(gt-xt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=St)return this;if(xt!==0&&St++,this.length=Math.min(St,this.length),xt!==0){var _t=67108863^67108863>>>xt<=67108864;xt++)this.words[xt]-=67108864,xt===this.length-1?this.words[xt+1]=1:this.words[xt+1]++;return this.length=Math.max(this.length,xt+1),this},tt.prototype.isubn=function(gt){if(et(typeof gt=="number"),et(gt<67108864),gt<0)return this.iaddn(-gt);if(this.negative!==0)return this.negative=0,this.iaddn(gt),this.negative=1,this;if(this.words[0]-=gt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var xt=0;xt>26)-(wt/67108864|0),this.words[Pt+St]=Et&67108863}for(;Pt>26,this.words[Pt+St]=Et&67108863;if(ht===0)return this._strip();for(et(ht===-1),ht=0,Pt=0;Pt>26,this.words[Pt]=Et&67108863;return this.negative=1,this._strip()},tt.prototype._wordDiv=function(gt,xt){var St=this.length-gt.length,_t=this.clone(),Pt=gt,Et=Pt.words[Pt.length-1]|0,ht=this._countBits(Et);St=26-ht,St!==0&&(Pt=Pt.ushln(St),_t.iushln(St),Et=Pt.words[Pt.length-1]|0);var wt=_t.length-Pt.length,Bt;if(xt!=="mod"){Bt=new tt(null),Bt.length=wt+1,Bt.words=new Array(Bt.length);for(var Lt=0;Lt=0;Ft--){var Vt=(_t.words[Pt.length+Ft]|0)*67108864+(_t.words[Pt.length+Ft-1]|0);for(Vt=Math.min(Vt/Et|0,67108863),_t._ishlnsubmul(Pt,Vt,Ft);_t.negative!==0;)Vt--,_t.negative=0,_t._ishlnsubmul(Pt,1,Ft),_t.isZero()||(_t.negative^=1);Bt&&(Bt.words[Ft]=Vt)}return Bt&&Bt._strip(),_t._strip(),xt!=="div"&&St!==0&&_t.iushrn(St),{div:Bt||null,mod:_t}},tt.prototype.divmod=function(gt,xt,St){if(et(!gt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var _t,Pt,Et;return this.negative!==0&>.negative===0?(Et=this.neg().divmod(gt,xt),xt!=="mod"&&(_t=Et.div.neg()),xt!=="div"&&(Pt=Et.mod.neg(),St&&Pt.negative!==0&&Pt.iadd(gt)),{div:_t,mod:Pt}):this.negative===0&>.negative!==0?(Et=this.divmod(gt.neg(),xt),xt!=="mod"&&(_t=Et.div.neg()),{div:_t,mod:Et.mod}):this.negative>.negative?(Et=this.neg().divmod(gt.neg(),xt),xt!=="div"&&(Pt=Et.mod.neg(),St&&Pt.negative!==0&&Pt.isub(gt)),{div:Et.div,mod:Pt}):gt.length>this.length||this.cmp(gt)<0?{div:new tt(0),mod:this}:gt.length===1?xt==="div"?{div:this.divn(gt.words[0]),mod:null}:xt==="mod"?{div:null,mod:new tt(this.modrn(gt.words[0]))}:{div:this.divn(gt.words[0]),mod:new tt(this.modrn(gt.words[0]))}:this._wordDiv(gt,xt)},tt.prototype.div=function(gt){return this.divmod(gt,"div",!1).div},tt.prototype.mod=function(gt){return this.divmod(gt,"mod",!1).mod},tt.prototype.umod=function(gt){return this.divmod(gt,"mod",!0).mod},tt.prototype.divRound=function(gt){var xt=this.divmod(gt);if(xt.mod.isZero())return xt.div;var St=xt.div.negative!==0?xt.mod.isub(gt):xt.mod,_t=gt.ushrn(1),Pt=gt.andln(1),Et=St.cmp(_t);return Et<0||Pt===1&&Et===0?xt.div:xt.div.negative!==0?xt.div.isubn(1):xt.div.iaddn(1)},tt.prototype.modrn=function(gt){var xt=gt<0;xt&&(gt=-gt),et(gt<=67108863);for(var St=(1<<26)%gt,_t=0,Pt=this.length-1;Pt>=0;Pt--)_t=(St*_t+(this.words[Pt]|0))%gt;return xt?-_t:_t},tt.prototype.modn=function(gt){return this.modrn(gt)},tt.prototype.idivn=function(gt){var xt=gt<0;xt&&(gt=-gt),et(gt<=67108863);for(var St=0,_t=this.length-1;_t>=0;_t--){var Pt=(this.words[_t]|0)+St*67108864;this.words[_t]=Pt/gt|0,St=Pt%gt}return this._strip(),xt?this.ineg():this},tt.prototype.divn=function(gt){return this.clone().idivn(gt)},tt.prototype.egcd=function(gt){et(gt.negative===0),et(!gt.isZero());var xt=this,St=gt.clone();xt.negative!==0?xt=xt.umod(gt):xt=xt.clone();for(var _t=new tt(1),Pt=new tt(0),Et=new tt(0),ht=new tt(1),wt=0;xt.isEven()&&St.isEven();)xt.iushrn(1),St.iushrn(1),++wt;for(var Bt=St.clone(),Lt=xt.clone();!xt.isZero();){for(var jt=0,Ft=1;!(xt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(xt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(Bt),Pt.isub(Lt)),_t.iushrn(1),Pt.iushrn(1);for(var Vt=0,zt=1;!(St.words[0]&zt)&&Vt<26;++Vt,zt<<=1);if(Vt>0)for(St.iushrn(Vt);Vt-- >0;)(Et.isOdd()||ht.isOdd())&&(Et.iadd(Bt),ht.isub(Lt)),Et.iushrn(1),ht.iushrn(1);xt.cmp(St)>=0?(xt.isub(St),_t.isub(Et),Pt.isub(ht)):(St.isub(xt),Et.isub(_t),ht.isub(Pt))}return{a:Et,b:ht,gcd:St.iushln(wt)}},tt.prototype._invmp=function(gt){et(gt.negative===0),et(!gt.isZero());var xt=this,St=gt.clone();xt.negative!==0?xt=xt.umod(gt):xt=xt.clone();for(var _t=new tt(1),Pt=new tt(0),Et=St.clone();xt.cmpn(1)>0&&St.cmpn(1)>0;){for(var ht=0,wt=1;!(xt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(xt.iushrn(ht);ht-- >0;)_t.isOdd()&&_t.iadd(Et),_t.iushrn(1);for(var Bt=0,Lt=1;!(St.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(St.iushrn(Bt);Bt-- >0;)Pt.isOdd()&&Pt.iadd(Et),Pt.iushrn(1);xt.cmp(St)>=0?(xt.isub(St),_t.isub(Pt)):(St.isub(xt),Pt.isub(_t))}var jt;return xt.cmpn(1)===0?jt=_t:jt=Pt,jt.cmpn(0)<0&&jt.iadd(gt),jt},tt.prototype.gcd=function(gt){if(this.isZero())return gt.abs();if(gt.isZero())return this.abs();var xt=this.clone(),St=gt.clone();xt.negative=0,St.negative=0;for(var _t=0;xt.isEven()&&St.isEven();_t++)xt.iushrn(1),St.iushrn(1);do{for(;xt.isEven();)xt.iushrn(1);for(;St.isEven();)St.iushrn(1);var Pt=xt.cmp(St);if(Pt<0){var Et=xt;xt=St,St=Et}else if(Pt===0||St.cmpn(1)===0)break;xt.isub(St)}while(!0);return St.iushln(_t)},tt.prototype.invm=function(gt){return this.egcd(gt).a.umod(gt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(gt){return this.words[0]>},tt.prototype.bincn=function(gt){et(typeof gt=="number");var xt=gt%26,St=(gt-xt)/26,_t=1<>>26,ht&=67108863,this.words[Et]=ht}return Pt!==0&&(this.words[Et]=Pt,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(gt){var xt=gt<0;if(this.negative!==0&&!xt)return-1;if(this.negative===0&&xt)return 1;this._strip();var St;if(this.length>1)St=1;else{xt&&(gt=-gt),et(gt<=67108863,"Number is too big");var _t=this.words[0]|0;St=_t===gt?0:_tgt.length)return 1;if(this.length=0;St--){var _t=this.words[St]|0,Pt=gt.words[St]|0;if(_t!==Pt){_tPt&&(xt=1);break}}return xt},tt.prototype.gtn=function(gt){return this.cmpn(gt)===1},tt.prototype.gt=function(gt){return this.cmp(gt)===1},tt.prototype.gten=function(gt){return this.cmpn(gt)>=0},tt.prototype.gte=function(gt){return this.cmp(gt)>=0},tt.prototype.ltn=function(gt){return this.cmpn(gt)===-1},tt.prototype.lt=function(gt){return this.cmp(gt)===-1},tt.prototype.lten=function(gt){return this.cmpn(gt)<=0},tt.prototype.lte=function(gt){return this.cmp(gt)<=0},tt.prototype.eqn=function(gt){return this.cmpn(gt)===0},tt.prototype.eq=function(gt){return this.cmp(gt)===0},tt.red=function(gt){return new Ct(gt)},tt.prototype.toRed=function(gt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),gt.convertTo(this)._forceRed(gt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(gt){return this.red=gt,this},tt.prototype.forceRed=function(gt){return et(!this.red,"Already a number in reduction context"),this._forceRed(gt)},tt.prototype.redAdd=function(gt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,gt)},tt.prototype.redIAdd=function(gt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,gt)},tt.prototype.redSub=function(gt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,gt)},tt.prototype.redISub=function(gt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,gt)},tt.prototype.redShl=function(gt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,gt)},tt.prototype.redMul=function(gt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,gt),this.red.mul(this,gt)},tt.prototype.redIMul=function(gt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,gt),this.red.imul(this,gt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(gt){return et(this.red&&!gt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,gt)};var Wt={k256:null,p224:null,p192:null,p25519:null};function Xt(yt,gt){this.name=yt,this.p=new tt(gt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Xt.prototype._tmp=function(){var gt=new tt(null);return gt.words=new Array(Math.ceil(this.n/13)),gt},Xt.prototype.ireduce=function(gt){var xt=gt,St;do this.split(xt,this.tmp),xt=this.imulK(xt),xt=xt.iadd(this.tmp),St=xt.bitLength();while(St>this.n);var _t=St0?xt.isub(this.p):xt.strip!==void 0?xt.strip():xt._strip(),xt},Xt.prototype.split=function(gt,xt){gt.iushrn(this.n,0,xt)},Xt.prototype.imulK=function(gt){return gt.imul(this.k)};function a0(){Xt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(a0,Xt),a0.prototype.split=function(gt,xt){for(var St=4194303,_t=Math.min(gt.length,9),Pt=0;Pt<_t;Pt++)xt.words[Pt]=gt.words[Pt];if(xt.length=_t,gt.length<=9){gt.words[0]=0,gt.length=1;return}var Et=gt.words[9];for(xt.words[xt.length++]=Et&St,Pt=10;Pt>>22,Et=ht}Et>>>=22,gt.words[Pt-10]=Et,Et===0&>.length>10?gt.length-=10:gt.length-=9},a0.prototype.imulK=function(gt){gt.words[gt.length]=0,gt.words[gt.length+1]=0,gt.length+=2;for(var xt=0,St=0;St>>=26,gt.words[St]=Pt,xt=_t}return xt!==0&&(gt.words[gt.length++]=xt),gt},tt._prime=function(gt){if(Wt[gt])return Wt[gt];var xt;if(gt==="k256")xt=new a0;else if(gt==="p224")xt=new n0;else if(gt==="p192")xt=new t0;else if(gt==="p25519")xt=new c0;else throw new Error("Unknown prime "+gt);return Wt[gt]=xt,xt};function Ct(yt){if(typeof yt=="string"){var gt=tt._prime(yt);this.m=gt.p,this.prime=gt}else et(yt.gtn(1),"modulus must be greater than 1"),this.m=yt,this.prime=null}Ct.prototype._verify1=function(gt){et(gt.negative===0,"red works only with positives"),et(gt.red,"red works only with red numbers")},Ct.prototype._verify2=function(gt,xt){et((gt.negative|xt.negative)===0,"red works only with positives"),et(gt.red&>.red===xt.red,"red works only with red numbers")},Ct.prototype.imod=function(gt){return this.prime?this.prime.ireduce(gt)._forceRed(this):(At(gt,gt.umod(this.m)._forceRed(this)),gt)},Ct.prototype.neg=function(gt){return gt.isZero()?gt.clone():this.m.sub(gt)._forceRed(this)},Ct.prototype.add=function(gt,xt){this._verify2(gt,xt);var St=gt.add(xt);return St.cmp(this.m)>=0&&St.isub(this.m),St._forceRed(this)},Ct.prototype.iadd=function(gt,xt){this._verify2(gt,xt);var St=gt.iadd(xt);return St.cmp(this.m)>=0&&St.isub(this.m),St},Ct.prototype.sub=function(gt,xt){this._verify2(gt,xt);var St=gt.sub(xt);return St.cmpn(0)<0&&St.iadd(this.m),St._forceRed(this)},Ct.prototype.isub=function(gt,xt){this._verify2(gt,xt);var St=gt.isub(xt);return St.cmpn(0)<0&&St.iadd(this.m),St},Ct.prototype.shl=function(gt,xt){return this._verify1(gt),this.imod(gt.ushln(xt))},Ct.prototype.imul=function(gt,xt){return this._verify2(gt,xt),this.imod(gt.imul(xt))},Ct.prototype.mul=function(gt,xt){return this._verify2(gt,xt),this.imod(gt.mul(xt))},Ct.prototype.isqr=function(gt){return this.imul(gt,gt.clone())},Ct.prototype.sqr=function(gt){return this.mul(gt,gt)},Ct.prototype.sqrt=function(gt){if(gt.isZero())return gt.clone();var xt=this.m.andln(3);if(et(xt%2===1),xt===3){var St=this.m.add(new tt(1)).iushrn(2);return this.pow(gt,St)}for(var _t=this.m.subn(1),Pt=0;!_t.isZero()&&_t.andln(1)===0;)Pt++,_t.iushrn(1);et(!_t.isZero());var Et=new tt(1).toRed(this),ht=Et.redNeg(),wt=this.m.subn(1).iushrn(1),Bt=this.m.bitLength();for(Bt=new tt(2*Bt*Bt).toRed(this);this.pow(Bt,wt).cmp(ht)!==0;)Bt.redIAdd(ht);for(var Lt=this.pow(Bt,_t),jt=this.pow(gt,_t.addn(1).iushrn(1)),Ft=this.pow(gt,_t),Vt=Pt;Ft.cmp(Et)!==0;){for(var zt=Ft,qt=0;zt.cmp(Et)!==0;qt++)zt=zt.redSqr();et(qt=0;Pt--){for(var Lt=xt.words[Pt],jt=Bt-1;jt>=0;jt--){var Ft=Lt>>jt&1;if(Et!==_t[0]&&(Et=this.sqr(Et)),Ft===0&&ht===0){wt=0;continue}ht<<=1,ht|=Ft,wt++,!(wt!==St&&(Pt!==0||jt!==0))&&(Et=this.mul(Et,_t[ht]),wt=0,ht=0)}Bt=26}return Et},Ct.prototype.convertTo=function(gt){var xt=gt.umod(this.m);return xt===gt?xt.clone():xt},Ct.prototype.convertFrom=function(gt){var xt=gt.clone();return xt.red=null,xt},tt.mont=function(gt){return new dt(gt)};function dt(yt){Ct.call(this,yt),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(dt,Ct),dt.prototype.convertTo=function(gt){return this.imod(gt.ushln(this.shift))},dt.prototype.convertFrom=function(gt){var xt=this.imod(gt.mul(this.rinv));return xt.red=null,xt},dt.prototype.imul=function(gt,xt){if(gt.isZero()||xt.isZero())return gt.words[0]=0,gt.length=1,gt;var St=gt.imul(xt),_t=St.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Pt=St.isub(_t).iushrn(this.shift),Et=Pt;return Pt.cmp(this.m)>=0?Et=Pt.isub(this.m):Pt.cmpn(0)<0&&(Et=Pt.iadd(this.m)),Et._forceRed(this)},dt.prototype.mul=function(gt,xt){if(gt.isZero()||xt.isZero())return new tt(0)._forceRed(this);var St=gt.mul(xt),_t=St.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Pt=St.isub(_t).iushrn(this.shift),Et=Pt;return Pt.cmp(this.m)>=0?Et=Pt.isub(this.m):Pt.cmpn(0)<0&&(Et=Pt.iadd(this.m)),Et._forceRed(this)},dt.prototype.invm=function(gt){var xt=this.imod(gt._invmp(this.m).mul(this.r2));return xt._forceRed(this)}})(c,commonjsGlobal)})(bn$5);var bnExports$5=bn$5.exports;const BN$j=getDefaultExportFromCjs(bnExports$5);var BN$i=bnExports$5,randomBytes$2=browserExports;function blind(c){var a=getr(c),d=a.toRed(BN$i.mont(c.modulus)).redPow(new BN$i(c.publicExponent)).fromRed();return{blinder:d,unblinder:a.invm(c.modulus)}}function getr(c){var a=c.modulus.byteLength(),d;do d=new BN$i(randomBytes$2(a));while(d.cmp(c.modulus)>=0||!d.umod(c.prime1)||!d.umod(c.prime2));return d}function crt$2(c,a){var d=blind(a),et=a.modulus.byteLength(),nt=new BN$i(c).mul(d.blinder).umod(a.modulus),tt=nt.toRed(BN$i.mont(a.prime1)),bt=nt.toRed(BN$i.mont(a.prime2)),mt=a.coefficient,vt=a.prime1,$t=a.prime2,At=tt.redPow(a.exponent1).fromRed(),Mt=bt.redPow(a.exponent2).fromRed(),Tt=At.isub(Mt).imul(mt).umod(vt).imul($t);return Mt.iadd(Tt).imul(d.unblinder).umod(a.modulus).toArrayLike(dist$2.Buffer,"be",et)}crt$2.getr=getr;var browserifyRsa=crt$2,elliptic$1={};const name$1="elliptic",version$l="6.5.5",description$1="EC cryptography",main$1="lib/elliptic.js",files$1=["lib"],scripts$1={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository$1={type:"git",url:"git@github.com:indutny/elliptic"},keywords$1=["EC","Elliptic","curve","Cryptography"],author$1="Fedor Indutny ",license$1="MIT",bugs$1={url:"https://github.com/indutny/elliptic/issues"},homepage$1="https://github.com/indutny/elliptic",devDependencies$1={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies$1={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},require$$0$1={name:name$1,version:version$l,description:description$1,main:main$1,files:files$1,scripts:scripts$1,repository:repository$1,keywords:keywords$1,author:author$1,license:license$1,bugs:bugs$1,homepage:homepage$1,devDependencies:devDependencies$1,dependencies:dependencies$1};var utils$y={},bn$4={exports:{}};bn$4.exports;(function(c){(function(a,d){function et(Ct,dt){if(!Ct)throw new Error(dt||"Assertion failed")}function nt(Ct,dt){Ct.super_=dt;var yt=function(){};yt.prototype=dt.prototype,Ct.prototype=new yt,Ct.prototype.constructor=Ct}function tt(Ct,dt,yt){if(tt.isBN(Ct))return Ct;this.negative=0,this.words=null,this.length=0,this.red=null,Ct!==null&&((dt==="le"||dt==="be")&&(yt=dt,dt=10),this._init(Ct||0,dt||10,yt||"be"))}typeof a=="object"?a.exports=tt:d.BN=tt,tt.BN=tt,tt.wordSize=26;var bt;try{typeof window<"u"&&typeof window.Buffer<"u"?bt=window.Buffer:bt=bufferPolyfill.Buffer}catch{}tt.isBN=function(dt){return dt instanceof tt?!0:dt!==null&&typeof dt=="object"&&dt.constructor.wordSize===tt.wordSize&&Array.isArray(dt.words)},tt.max=function(dt,yt){return dt.cmp(yt)>0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$4);var bnExports$4=bn$4.exports,utils$x={};(function(c){var a=c;function d(tt,bt){if(Array.isArray(tt))return tt.slice();if(!tt)return[];var mt=[];if(typeof tt!="string"){for(var vt=0;vt>8,Mt=$t&255;At?mt.push(At,Mt):mt.push(Mt)}return mt}a.toArray=d;function et(tt){return tt.length===1?"0"+tt:tt}a.zero2=et;function nt(tt){for(var bt="",mt=0;mt(It>>1)-1?Nt=(It>>1)-Ot:Nt=Ot,Dt.isubn(Nt)):Nt=0,Rt[kt]=Nt,Dt.iushrn(1)}return Rt}a.getNAF=tt;function bt(At,Mt){var Tt=[[],[]];At=At.clone(),Mt=Mt.clone();for(var Rt=0,kt=0,It;At.cmpn(-Rt)>0||Mt.cmpn(-kt)>0;){var Dt=At.andln(3)+Rt&3,Nt=Mt.andln(3)+kt&3;Dt===3&&(Dt=-1),Nt===3&&(Nt=-1);var Ot;Dt&1?(It=At.andln(7)+Rt&7,(It===3||It===5)&&Nt===2?Ot=-Dt:Ot=Dt):Ot=0,Tt[0].push(Ot);var Ut;Nt&1?(It=Mt.andln(7)+kt&7,(It===3||It===5)&&Dt===2?Ut=-Nt:Ut=Nt):Ut=0,Tt[1].push(Ut),2*Rt===Ot+1&&(Rt=1-Rt),2*kt===Ut+1&&(kt=1-kt),At.iushrn(1),Mt.iushrn(1)}return Tt}a.getJSF=bt;function mt(At,Mt,Tt){var Rt="_"+Mt;At.prototype[Mt]=function(){return this[Rt]!==void 0?this[Rt]:this[Rt]=Tt.call(this)}}a.cachedProperty=mt;function vt(At){return typeof At=="string"?a.toArray(At,"hex"):At}a.parseBytes=vt;function $t(At){return new d(At,"hex","le")}a.intFromLE=$t})(utils$y);var curve$1={},BN$h=bnExports$4,utils$w=utils$y,getNAF$2=utils$w.getNAF,getJSF$2=utils$w.getJSF,assert$r=utils$w.assert;function BaseCurve$2(c,a){this.type=c,this.p=new BN$h(a.p,16),this.red=a.prime?BN$h.red(a.prime):BN$h.mont(this.p),this.zero=new BN$h(0).toRed(this.red),this.one=new BN$h(1).toRed(this.red),this.two=new BN$h(2).toRed(this.red),this.n=a.n&&new BN$h(a.n,16),this.g=a.g&&this.pointFromJSON(a.g,a.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var d=this.n&&this.p.div(this.n);!d||d.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var base$4=BaseCurve$2;BaseCurve$2.prototype.point=function(){throw new Error("Not implemented")};BaseCurve$2.prototype.validate=function(){throw new Error("Not implemented")};BaseCurve$2.prototype._fixedNafMul=function(a,d){assert$r(a.precomputed);var et=a._getDoubles(),nt=getNAF$2(d,1,this._bitLength),tt=(1<=mt;$t--)vt=(vt<<1)+nt[$t];bt.push(vt)}for(var At=this.jpoint(null,null,null),Mt=this.jpoint(null,null,null),Tt=tt;Tt>0;Tt--){for(mt=0;mt=0;vt--){for(var $t=0;vt>=0&&bt[vt]===0;vt--)$t++;if(vt>=0&&$t++,mt=mt.dblp($t),vt<0)break;var At=bt[vt];assert$r(At!==0),a.type==="affine"?At>0?mt=mt.mixedAdd(tt[At-1>>1]):mt=mt.mixedAdd(tt[-At-1>>1].neg()):At>0?mt=mt.add(tt[At-1>>1]):mt=mt.add(tt[-At-1>>1].neg())}return a.type==="affine"?mt.toP():mt};BaseCurve$2.prototype._wnafMulAdd=function(a,d,et,nt,tt){var bt=this._wnafT1,mt=this._wnafT2,vt=this._wnafT3,$t=0,At,Mt,Tt;for(At=0;At=1;At-=2){var kt=At-1,It=At;if(bt[kt]!==1||bt[It]!==1){vt[kt]=getNAF$2(et[kt],bt[kt],this._bitLength),vt[It]=getNAF$2(et[It],bt[It],this._bitLength),$t=Math.max(vt[kt].length,$t),$t=Math.max(vt[It].length,$t);continue}var Dt=[d[kt],null,null,d[It]];d[kt].y.cmp(d[It].y)===0?(Dt[1]=d[kt].add(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg())):d[kt].y.cmp(d[It].y.redNeg())===0?(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].add(d[It].neg())):(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg()));var Nt=[-3,-1,-5,-7,0,7,5,1,3],Ot=getJSF$2(et[kt],et[It]);for($t=Math.max(Ot[0].length,$t),vt[kt]=new Array($t),vt[It]=new Array($t),Mt=0;Mt<$t;Mt++){var Ut=Ot[0][Mt]|0,Gt=Ot[1][Mt]|0;vt[kt][Mt]=Nt[(Ut+1)*3+(Gt+1)],vt[It][Mt]=0,mt[kt]=Dt}}var Wt=this.jpoint(null,null,null),Xt=this._wnafT4;for(At=$t;At>=0;At--){for(var a0=0;At>=0;){var n0=!0;for(Mt=0;Mt=0&&a0++,Wt=Wt.dblp(a0),At<0)break;for(Mt=0;Mt0?Tt=mt[Mt][t0-1>>1]:t0<0&&(Tt=mt[Mt][-t0-1>>1].neg()),Tt.type==="affine"?Wt=Wt.mixedAdd(Tt):Wt=Wt.add(Tt))}}for(At=0;At=Math.ceil((a.bitLength()+1)/d.step):!1};BasePoint$2.prototype._getDoubles=function(a,d){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var et=[this],nt=this,tt=0;tt=0&&(Rt=$t,kt=At),Mt.negative&&(Mt=Mt.neg(),Tt=Tt.neg()),Rt.negative&&(Rt=Rt.neg(),kt=kt.neg()),[{a:Mt,b:Tt},{a:Rt,b:kt}]};ShortCurve$2.prototype._endoSplit=function(a){var d=this.endo.basis,et=d[0],nt=d[1],tt=nt.b.mul(a).divRound(this.n),bt=et.b.neg().mul(a).divRound(this.n),mt=tt.mul(et.a),vt=bt.mul(nt.a),$t=tt.mul(et.b),At=bt.mul(nt.b),Mt=a.sub(mt).sub(vt),Tt=$t.add(At).neg();return{k1:Mt,k2:Tt}};ShortCurve$2.prototype.pointFromX=function(a,d){a=new BN$g(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr().redMul(a).redIAdd(a.redMul(this.a)).redIAdd(this.b),nt=et.redSqrt();if(nt.redSqr().redSub(et).cmp(this.zero)!==0)throw new Error("invalid point");var tt=nt.fromRed().isOdd();return(d&&!tt||!d&&tt)&&(nt=nt.redNeg()),this.point(a,nt)};ShortCurve$2.prototype.validate=function(a){if(a.inf)return!0;var d=a.x,et=a.y,nt=this.a.redMul(d),tt=d.redSqr().redMul(d).redIAdd(nt).redIAdd(this.b);return et.redSqr().redISub(tt).cmpn(0)===0};ShortCurve$2.prototype._endoWnafMulAdd=function(a,d,et){for(var nt=this._endoWnafT1,tt=this._endoWnafT2,bt=0;bt":""};Point$7.prototype.isInfinity=function(){return this.inf};Point$7.prototype.add=function(a){if(this.inf)return a;if(a.inf)return this;if(this.eq(a))return this.dbl();if(this.neg().eq(a))return this.curve.point(null,null);if(this.x.cmp(a.x)===0)return this.curve.point(null,null);var d=this.y.redSub(a.y);d.cmpn(0)!==0&&(d=d.redMul(this.x.redSub(a.x).redInvm()));var et=d.redSqr().redISub(this.x).redISub(a.x),nt=d.redMul(this.x.redSub(et)).redISub(this.y);return this.curve.point(et,nt)};Point$7.prototype.dbl=function(){if(this.inf)return this;var a=this.y.redAdd(this.y);if(a.cmpn(0)===0)return this.curve.point(null,null);var d=this.curve.a,et=this.x.redSqr(),nt=a.redInvm(),tt=et.redAdd(et).redIAdd(et).redIAdd(d).redMul(nt),bt=tt.redSqr().redISub(this.x.redAdd(this.x)),mt=tt.redMul(this.x.redSub(bt)).redISub(this.y);return this.curve.point(bt,mt)};Point$7.prototype.getX=function(){return this.x.fromRed()};Point$7.prototype.getY=function(){return this.y.fromRed()};Point$7.prototype.mul=function(a){return a=new BN$g(a,16),this.isInfinity()?this:this._hasDoubles(a)?this.curve._fixedNafMul(this,a):this.curve.endo?this.curve._endoWnafMulAdd([this],[a]):this.curve._wnafMul(this,a)};Point$7.prototype.mulAdd=function(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt):this.curve._wnafMulAdd(1,nt,tt,2)};Point$7.prototype.jmulAdd=function(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt,!0):this.curve._wnafMulAdd(1,nt,tt,2,!0)};Point$7.prototype.eq=function(a){return this===a||this.inf===a.inf&&(this.inf||this.x.cmp(a.x)===0&&this.y.cmp(a.y)===0)};Point$7.prototype.neg=function(a){if(this.inf)return this;var d=this.curve.point(this.x,this.y.redNeg());if(a&&this.precomputed){var et=this.precomputed,nt=function(tt){return tt.neg()};d.precomputed={naf:et.naf&&{wnd:et.naf.wnd,points:et.naf.points.map(nt)},doubles:et.doubles&&{step:et.doubles.step,points:et.doubles.points.map(nt)}}}return d};Point$7.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var a=this.curve.jpoint(this.x,this.y,this.curve.one);return a};function JPoint$2(c,a,d,et){Base$5.BasePoint.call(this,c,"jacobian"),a===null&&d===null&&et===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new BN$g(0)):(this.x=new BN$g(a,16),this.y=new BN$g(d,16),this.z=new BN$g(et,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}inherits$7(JPoint$2,Base$5.BasePoint);ShortCurve$2.prototype.jpoint=function(a,d,et){return new JPoint$2(this,a,d,et)};JPoint$2.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var a=this.z.redInvm(),d=a.redSqr(),et=this.x.redMul(d),nt=this.y.redMul(d).redMul(a);return this.curve.point(et,nt)};JPoint$2.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};JPoint$2.prototype.add=function(a){if(this.isInfinity())return a;if(a.isInfinity())return this;var d=a.z.redSqr(),et=this.z.redSqr(),nt=this.x.redMul(d),tt=a.x.redMul(et),bt=this.y.redMul(d.redMul(a.z)),mt=a.y.redMul(et.redMul(this.z)),vt=nt.redSub(tt),$t=bt.redSub(mt);if(vt.cmpn(0)===0)return $t.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var At=vt.redSqr(),Mt=At.redMul(vt),Tt=nt.redMul(At),Rt=$t.redSqr().redIAdd(Mt).redISub(Tt).redISub(Tt),kt=$t.redMul(Tt.redISub(Rt)).redISub(bt.redMul(Mt)),It=this.z.redMul(a.z).redMul(vt);return this.curve.jpoint(Rt,kt,It)};JPoint$2.prototype.mixedAdd=function(a){if(this.isInfinity())return a.toJ();if(a.isInfinity())return this;var d=this.z.redSqr(),et=this.x,nt=a.x.redMul(d),tt=this.y,bt=a.y.redMul(d).redMul(this.z),mt=et.redSub(nt),vt=tt.redSub(bt);if(mt.cmpn(0)===0)return vt.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var $t=mt.redSqr(),At=$t.redMul(mt),Mt=et.redMul($t),Tt=vt.redSqr().redIAdd(At).redISub(Mt).redISub(Mt),Rt=vt.redMul(Mt.redISub(Tt)).redISub(tt.redMul(At)),kt=this.z.redMul(mt);return this.curve.jpoint(Tt,Rt,kt)};JPoint$2.prototype.dblp=function(a){if(a===0)return this;if(this.isInfinity())return this;if(!a)return this.dbl();var d;if(this.curve.zeroA||this.curve.threeA){var et=this;for(d=0;d=0)return!1;if(et.redIAdd(tt),this.x.cmp(et)===0)return!0}};JPoint$2.prototype.inspect=function(){return this.isInfinity()?"":""};JPoint$2.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var BN$f=bnExports$4,inherits$6=inherits_browserExports,Base$4=base$4,utils$u=utils$y;function MontCurve$1(c){Base$4.call(this,"mont",c),this.a=new BN$f(c.a,16).toRed(this.red),this.b=new BN$f(c.b,16).toRed(this.red),this.i4=new BN$f(4).toRed(this.red).redInvm(),this.two=new BN$f(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}inherits$6(MontCurve$1,Base$4);var mont$1=MontCurve$1;MontCurve$1.prototype.validate=function(a){var d=a.normalize().x,et=d.redSqr(),nt=et.redMul(d).redAdd(et.redMul(this.a)).redAdd(d),tt=nt.redSqrt();return tt.redSqr().cmp(nt)===0};function Point$6(c,a,d){Base$4.BasePoint.call(this,c,"projective"),a===null&&d===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new BN$f(a,16),this.z=new BN$f(d,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}inherits$6(Point$6,Base$4.BasePoint);MontCurve$1.prototype.decodePoint=function(a,d){return this.point(utils$u.toArray(a,d),1)};MontCurve$1.prototype.point=function(a,d){return new Point$6(this,a,d)};MontCurve$1.prototype.pointFromJSON=function(a){return Point$6.fromJSON(this,a)};Point$6.prototype.precompute=function(){};Point$6.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())};Point$6.fromJSON=function(a,d){return new Point$6(a,d[0],d[1]||a.one)};Point$6.prototype.inspect=function(){return this.isInfinity()?"":""};Point$6.prototype.isInfinity=function(){return this.z.cmpn(0)===0};Point$6.prototype.dbl=function(){var a=this.x.redAdd(this.z),d=a.redSqr(),et=this.x.redSub(this.z),nt=et.redSqr(),tt=d.redSub(nt),bt=d.redMul(nt),mt=tt.redMul(nt.redAdd(this.curve.a24.redMul(tt)));return this.curve.point(bt,mt)};Point$6.prototype.add=function(){throw new Error("Not supported on Montgomery curve")};Point$6.prototype.diffAdd=function(a,d){var et=this.x.redAdd(this.z),nt=this.x.redSub(this.z),tt=a.x.redAdd(a.z),bt=a.x.redSub(a.z),mt=bt.redMul(et),vt=tt.redMul(nt),$t=d.z.redMul(mt.redAdd(vt).redSqr()),At=d.x.redMul(mt.redISub(vt).redSqr());return this.curve.point($t,At)};Point$6.prototype.mul=function(a){for(var d=a.clone(),et=this,nt=this.curve.point(null,null),tt=this,bt=[];d.cmpn(0)!==0;d.iushrn(1))bt.push(d.andln(1));for(var mt=bt.length-1;mt>=0;mt--)bt[mt]===0?(et=et.diffAdd(nt,tt),nt=nt.dbl()):(nt=et.diffAdd(nt,tt),et=et.dbl());return nt};Point$6.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")};Point$6.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")};Point$6.prototype.eq=function(a){return this.getX().cmp(a.getX())===0};Point$6.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this};Point$6.prototype.getX=function(){return this.normalize(),this.x.fromRed()};var utils$t=utils$y,BN$e=bnExports$4,inherits$5=inherits_browserExports,Base$3=base$4,assert$p=utils$t.assert;function EdwardsCurve$1(c){this.twisted=(c.a|0)!==1,this.mOneA=this.twisted&&(c.a|0)===-1,this.extended=this.mOneA,Base$3.call(this,"edwards",c),this.a=new BN$e(c.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new BN$e(c.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new BN$e(c.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),assert$p(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(c.c|0)===1}inherits$5(EdwardsCurve$1,Base$3);var edwards$1=EdwardsCurve$1;EdwardsCurve$1.prototype._mulA=function(a){return this.mOneA?a.redNeg():this.a.redMul(a)};EdwardsCurve$1.prototype._mulC=function(a){return this.oneC?a:this.c.redMul(a)};EdwardsCurve$1.prototype.jpoint=function(a,d,et,nt){return this.point(a,d,et,nt)};EdwardsCurve$1.prototype.pointFromX=function(a,d){a=new BN$e(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr(),nt=this.c2.redSub(this.a.redMul(et)),tt=this.one.redSub(this.c2.redMul(this.d).redMul(et)),bt=nt.redMul(tt.redInvm()),mt=bt.redSqrt();if(mt.redSqr().redSub(bt).cmp(this.zero)!==0)throw new Error("invalid point");var vt=mt.fromRed().isOdd();return(d&&!vt||!d&&vt)&&(mt=mt.redNeg()),this.point(a,mt)};EdwardsCurve$1.prototype.pointFromY=function(a,d){a=new BN$e(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr(),nt=et.redSub(this.c2),tt=et.redMul(this.d).redMul(this.c2).redSub(this.a),bt=nt.redMul(tt.redInvm());if(bt.cmp(this.zero)===0){if(d)throw new Error("invalid point");return this.point(this.zero,a)}var mt=bt.redSqrt();if(mt.redSqr().redSub(bt).cmp(this.zero)!==0)throw new Error("invalid point");return mt.fromRed().isOdd()!==d&&(mt=mt.redNeg()),this.point(mt,a)};EdwardsCurve$1.prototype.validate=function(a){if(a.isInfinity())return!0;a.normalize();var d=a.x.redSqr(),et=a.y.redSqr(),nt=d.redMul(this.a).redAdd(et),tt=this.c2.redMul(this.one.redAdd(this.d.redMul(d).redMul(et)));return nt.cmp(tt)===0};function Point$5(c,a,d,et,nt){Base$3.BasePoint.call(this,c,"projective"),a===null&&d===null&&et===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new BN$e(a,16),this.y=new BN$e(d,16),this.z=et?new BN$e(et,16):this.curve.one,this.t=nt&&new BN$e(nt,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}inherits$5(Point$5,Base$3.BasePoint);EdwardsCurve$1.prototype.pointFromJSON=function(a){return Point$5.fromJSON(this,a)};EdwardsCurve$1.prototype.point=function(a,d,et,nt){return new Point$5(this,a,d,et,nt)};Point$5.fromJSON=function(a,d){return new Point$5(a,d[0],d[1],d[2])};Point$5.prototype.inspect=function(){return this.isInfinity()?"":""};Point$5.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)};Point$5.prototype._extDbl=function(){var a=this.x.redSqr(),d=this.y.redSqr(),et=this.z.redSqr();et=et.redIAdd(et);var nt=this.curve._mulA(a),tt=this.x.redAdd(this.y).redSqr().redISub(a).redISub(d),bt=nt.redAdd(d),mt=bt.redSub(et),vt=nt.redSub(d),$t=tt.redMul(mt),At=bt.redMul(vt),Mt=tt.redMul(vt),Tt=mt.redMul(bt);return this.curve.point($t,At,Tt,Mt)};Point$5.prototype._projDbl=function(){var a=this.x.redAdd(this.y).redSqr(),d=this.x.redSqr(),et=this.y.redSqr(),nt,tt,bt,mt,vt,$t;if(this.curve.twisted){mt=this.curve._mulA(d);var At=mt.redAdd(et);this.zOne?(nt=a.redSub(d).redSub(et).redMul(At.redSub(this.curve.two)),tt=At.redMul(mt.redSub(et)),bt=At.redSqr().redSub(At).redSub(At)):(vt=this.z.redSqr(),$t=At.redSub(vt).redISub(vt),nt=a.redSub(d).redISub(et).redMul($t),tt=At.redMul(mt.redSub(et)),bt=At.redMul($t))}else mt=d.redAdd(et),vt=this.curve._mulC(this.z).redSqr(),$t=mt.redSub(vt).redSub(vt),nt=this.curve._mulC(a.redISub(mt)).redMul($t),tt=this.curve._mulC(mt).redMul(d.redISub(et)),bt=mt.redMul($t);return this.curve.point(nt,tt,bt)};Point$5.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()};Point$5.prototype._extAdd=function(a){var d=this.y.redSub(this.x).redMul(a.y.redSub(a.x)),et=this.y.redAdd(this.x).redMul(a.y.redAdd(a.x)),nt=this.t.redMul(this.curve.dd).redMul(a.t),tt=this.z.redMul(a.z.redAdd(a.z)),bt=et.redSub(d),mt=tt.redSub(nt),vt=tt.redAdd(nt),$t=et.redAdd(d),At=bt.redMul(mt),Mt=vt.redMul($t),Tt=bt.redMul($t),Rt=mt.redMul(vt);return this.curve.point(At,Mt,Rt,Tt)};Point$5.prototype._projAdd=function(a){var d=this.z.redMul(a.z),et=d.redSqr(),nt=this.x.redMul(a.x),tt=this.y.redMul(a.y),bt=this.curve.d.redMul(nt).redMul(tt),mt=et.redSub(bt),vt=et.redAdd(bt),$t=this.x.redAdd(this.y).redMul(a.x.redAdd(a.y)).redISub(nt).redISub(tt),At=d.redMul(mt).redMul($t),Mt,Tt;return this.curve.twisted?(Mt=d.redMul(vt).redMul(tt.redSub(this.curve._mulA(nt))),Tt=mt.redMul(vt)):(Mt=d.redMul(vt).redMul(tt.redSub(nt)),Tt=this.curve._mulC(mt).redMul(vt)),this.curve.point(At,Mt,Tt)};Point$5.prototype.add=function(a){return this.isInfinity()?a:a.isInfinity()?this:this.curve.extended?this._extAdd(a):this._projAdd(a)};Point$5.prototype.mul=function(a){return this._hasDoubles(a)?this.curve._fixedNafMul(this,a):this.curve._wnafMul(this,a)};Point$5.prototype.mulAdd=function(a,d,et){return this.curve._wnafMulAdd(1,[this,d],[a,et],2,!1)};Point$5.prototype.jmulAdd=function(a,d,et){return this.curve._wnafMulAdd(1,[this,d],[a,et],2,!0)};Point$5.prototype.normalize=function(){if(this.zOne)return this;var a=this.z.redInvm();return this.x=this.x.redMul(a),this.y=this.y.redMul(a),this.t&&(this.t=this.t.redMul(a)),this.z=this.curve.one,this.zOne=!0,this};Point$5.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())};Point$5.prototype.getX=function(){return this.normalize(),this.x.fromRed()};Point$5.prototype.getY=function(){return this.normalize(),this.y.fromRed()};Point$5.prototype.eq=function(a){return this===a||this.getX().cmp(a.getX())===0&&this.getY().cmp(a.getY())===0};Point$5.prototype.eqXToP=function(a){var d=a.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(d)===0)return!0;for(var et=a.clone(),nt=this.curve.redN.redMul(this.z);;){if(et.iadd(this.curve.n),et.cmp(this.curve.p)>=0)return!1;if(d.redIAdd(nt),this.x.cmp(d)===0)return!0}};Point$5.prototype.toP=Point$5.prototype.normalize;Point$5.prototype.mixedAdd=Point$5.prototype.add;(function(c){var a=c;a.base=base$4,a.short=short$1,a.mont=mont$1,a.edwards=edwards$1})(curve$1);var curves$3={},hash$7={},utils$s={},assert$o=minimalisticAssert$1,inherits$4=inherits_browserExports;utils$s.inherits=inherits$4;function isSurrogatePair(c,a){return(c.charCodeAt(a)&64512)!==55296||a<0||a+1>=c.length?!1:(c.charCodeAt(a+1)&64512)===56320}function toArray(c,a){if(Array.isArray(c))return c.slice();if(!c)return[];var d=[];if(typeof c=="string")if(a){if(a==="hex")for(c=c.replace(/[^a-z0-9]+/ig,""),c.length%2!==0&&(c="0"+c),nt=0;nt>6|192,d[et++]=tt&63|128):isSurrogatePair(c,nt)?(tt=65536+((tt&1023)<<10)+(c.charCodeAt(++nt)&1023),d[et++]=tt>>18|240,d[et++]=tt>>12&63|128,d[et++]=tt>>6&63|128,d[et++]=tt&63|128):(d[et++]=tt>>12|224,d[et++]=tt>>6&63|128,d[et++]=tt&63|128)}else for(nt=0;nt>>24|c>>>8&65280|c<<8&16711680|(c&255)<<24;return a>>>0}utils$s.htonl=htonl;function toHex32(c,a){for(var d="",et=0;et>>0}return tt}utils$s.join32=join32;function split32(c,a){for(var d=new Array(c.length*4),et=0,nt=0;et>>24,d[nt+1]=tt>>>16&255,d[nt+2]=tt>>>8&255,d[nt+3]=tt&255):(d[nt+3]=tt>>>24,d[nt+2]=tt>>>16&255,d[nt+1]=tt>>>8&255,d[nt]=tt&255)}return d}utils$s.split32=split32;function rotr32$1(c,a){return c>>>a|c<<32-a}utils$s.rotr32=rotr32$1;function rotl32$2(c,a){return c<>>32-a}utils$s.rotl32=rotl32$2;function sum32$3(c,a){return c+a>>>0}utils$s.sum32=sum32$3;function sum32_3$1(c,a,d){return c+a+d>>>0}utils$s.sum32_3=sum32_3$1;function sum32_4$2(c,a,d,et){return c+a+d+et>>>0}utils$s.sum32_4=sum32_4$2;function sum32_5$2(c,a,d,et,nt){return c+a+d+et+nt>>>0}utils$s.sum32_5=sum32_5$2;function sum64$1(c,a,d,et){var nt=c[a],tt=c[a+1],bt=et+tt>>>0,mt=(bt>>0,c[a+1]=bt}utils$s.sum64=sum64$1;function sum64_hi$1(c,a,d,et){var nt=a+et>>>0,tt=(nt>>0}utils$s.sum64_hi=sum64_hi$1;function sum64_lo$1(c,a,d,et){var nt=a+et;return nt>>>0}utils$s.sum64_lo=sum64_lo$1;function sum64_4_hi$1(c,a,d,et,nt,tt,bt,mt){var vt=0,$t=a;$t=$t+et>>>0,vt+=$t>>0,vt+=$t>>0,vt+=$t>>0}utils$s.sum64_4_hi=sum64_4_hi$1;function sum64_4_lo$1(c,a,d,et,nt,tt,bt,mt){var vt=a+et+tt+mt;return vt>>>0}utils$s.sum64_4_lo=sum64_4_lo$1;function sum64_5_hi$1(c,a,d,et,nt,tt,bt,mt,vt,$t){var At=0,Mt=a;Mt=Mt+et>>>0,At+=Mt>>0,At+=Mt>>0,At+=Mt>>0,At+=Mt<$t?1:0;var Tt=c+d+nt+bt+vt+At;return Tt>>>0}utils$s.sum64_5_hi=sum64_5_hi$1;function sum64_5_lo$1(c,a,d,et,nt,tt,bt,mt,vt,$t){var At=a+et+tt+mt+$t;return At>>>0}utils$s.sum64_5_lo=sum64_5_lo$1;function rotr64_hi$1(c,a,d){var et=a<<32-d|c>>>d;return et>>>0}utils$s.rotr64_hi=rotr64_hi$1;function rotr64_lo$1(c,a,d){var et=c<<32-d|a>>>d;return et>>>0}utils$s.rotr64_lo=rotr64_lo$1;function shr64_hi$1(c,a,d){return c>>>d}utils$s.shr64_hi=shr64_hi$1;function shr64_lo$1(c,a,d){var et=c<<32-d|a>>>d;return et>>>0}utils$s.shr64_lo=shr64_lo$1;var common$6={},utils$r=utils$s,assert$n=minimalisticAssert$1;function BlockHash$4(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}common$6.BlockHash=BlockHash$4;BlockHash$4.prototype.update=function(a,d){if(a=utils$r.toArray(a,d),this.pending?this.pending=this.pending.concat(a):this.pending=a,this.pendingTotal+=a.length,this.pending.length>=this._delta8){a=this.pending;var et=a.length%this._delta8;this.pending=a.slice(a.length-et,a.length),this.pending.length===0&&(this.pending=null),a=utils$r.join32(a,0,a.length-et,this.endian);for(var nt=0;nt>>24&255,nt[tt++]=a>>>16&255,nt[tt++]=a>>>8&255,nt[tt++]=a&255}else for(nt[tt++]=a&255,nt[tt++]=a>>>8&255,nt[tt++]=a>>>16&255,nt[tt++]=a>>>24&255,nt[tt++]=0,nt[tt++]=0,nt[tt++]=0,nt[tt++]=0,bt=8;bt>>3}common$5.g0_256=g0_256$1;function g1_256$1(c){return rotr32(c,17)^rotr32(c,19)^c>>>10}common$5.g1_256=g1_256$1;var utils$p=utils$s,common$4=common$6,shaCommon$1=common$5,rotl32$1=utils$p.rotl32,sum32$2=utils$p.sum32,sum32_5$1=utils$p.sum32_5,ft_1=shaCommon$1.ft_1,BlockHash$3=common$4.BlockHash,sha1_K=[1518500249,1859775393,2400959708,3395469782];function SHA1(){if(!(this instanceof SHA1))return new SHA1;BlockHash$3.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}utils$p.inherits(SHA1,BlockHash$3);var _1=SHA1;SHA1.blockSize=512;SHA1.outSize=160;SHA1.hmacStrength=80;SHA1.padLength=64;SHA1.prototype._update=function(a,d){for(var et=this.W,nt=0;nt<16;nt++)et[nt]=a[d+nt];for(;ntthis.blockSize&&(a=new this.Hash().update(a).digest()),assert$k(a.length<=this.blockSize);for(var d=a.length;d=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(a,d,et)}var hmacDrbg$1=HmacDRBG$1;HmacDRBG$1.prototype._init=function(a,d,et){var nt=a.concat(d).concat(et);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var tt=0;tt=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(a.concat(et||[])),this._reseed=1};HmacDRBG$1.prototype.generate=function(a,d,et,nt){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof d!="string"&&(nt=et,et=d,d=null),et&&(et=utils$i.toArray(et,nt||"hex"),this._update(et));for(var tt=[];tt.length"};var BN$c=bnExports$4,utils$g=utils$y,assert$h=utils$g.assert;function Signature$8(c,a){if(c instanceof Signature$8)return c;this._importDER(c,a)||(assert$h(c.r&&c.s,"Signature without r or s"),this.r=new BN$c(c.r,16),this.s=new BN$c(c.s,16),c.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=c.recoveryParam)}var signature$4=Signature$8;function Position$2(){this.place=0}function getLength$2(c,a){var d=c[a.place++];if(!(d&128))return d;var et=d&15;if(et===0||et>4)return!1;for(var nt=0,tt=0,bt=a.place;tt>>=0;return nt<=127?!1:(a.place=bt,nt)}function rmPadding$2(c){for(var a=0,d=c.length-1;!c[a]&&!(c[a+1]&128)&&a>>3);for(c.push(d|128);--d;)c.push(a>>>(d<<3)&255);c.push(a)}Signature$8.prototype.toDER=function(a){var d=this.r.toArray(),et=this.s.toArray();for(d[0]&128&&(d=[0].concat(d)),et[0]&128&&(et=[0].concat(et)),d=rmPadding$2(d),et=rmPadding$2(et);!et[0]&&!(et[1]&128);)et=et.slice(1);var nt=[2];constructLength$2(nt,d.length),nt=nt.concat(d),nt.push(2),constructLength$2(nt,et.length);var tt=nt.concat(et),bt=[48];return constructLength$2(bt,tt.length),bt=bt.concat(tt),utils$g.encode(bt,a)};var ec$2,hasRequiredEc$1;function requireEc$1(){if(hasRequiredEc$1)return ec$2;hasRequiredEc$1=1;var c=bnExports$4,a=hmacDrbg$1,d=utils$y,et=curves$3,nt=requireBrorand(),tt=d.assert,bt=key$4,mt=signature$4;function vt($t){if(!(this instanceof vt))return new vt($t);typeof $t=="string"&&(tt(Object.prototype.hasOwnProperty.call(et,$t),"Unknown curve "+$t),$t=et[$t]),$t instanceof et.PresetCurve&&($t={curve:$t}),this.curve=$t.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=$t.curve.g,this.g.precompute($t.curve.n.bitLength()+1),this.hash=$t.hash||$t.curve.hash}return ec$2=vt,vt.prototype.keyPair=function(At){return new bt(this,At)},vt.prototype.keyFromPrivate=function(At,Mt){return bt.fromPrivate(this,At,Mt)},vt.prototype.keyFromPublic=function(At,Mt){return bt.fromPublic(this,At,Mt)},vt.prototype.genKeyPair=function(At){At||(At={});for(var Mt=new a({hash:this.hash,pers:At.pers,persEnc:At.persEnc||"utf8",entropy:At.entropy||nt(this.hash.hmacStrength),entropyEnc:At.entropy&&At.entropyEnc||"utf8",nonce:this.n.toArray()}),Tt=this.n.byteLength(),Rt=this.n.sub(new c(2));;){var kt=new c(Mt.generate(Tt));if(!(kt.cmp(Rt)>0))return kt.iaddn(1),this.keyFromPrivate(kt)}},vt.prototype._truncateToN=function(At,Mt){var Tt=At.byteLength()*8-this.n.bitLength();return Tt>0&&(At=At.ushrn(Tt)),!Mt&&At.cmp(this.n)>=0?At.sub(this.n):At},vt.prototype.sign=function(At,Mt,Tt,Rt){typeof Tt=="object"&&(Rt=Tt,Tt=null),Rt||(Rt={}),Mt=this.keyFromPrivate(Mt,Tt),At=this._truncateToN(new c(At,16));for(var kt=this.n.byteLength(),It=Mt.getPrivate().toArray("be",kt),Dt=At.toArray("be",kt),Nt=new a({hash:this.hash,entropy:It,nonce:Dt,pers:Rt.pers,persEnc:Rt.persEnc||"utf8"}),Ot=this.n.sub(new c(1)),Ut=0;;Ut++){var Gt=Rt.k?Rt.k(Ut):new c(Nt.generate(this.n.byteLength()));if(Gt=this._truncateToN(Gt,!0),!(Gt.cmpn(1)<=0||Gt.cmp(Ot)>=0)){var Wt=this.g.mul(Gt);if(!Wt.isInfinity()){var Xt=Wt.getX(),a0=Xt.umod(this.n);if(a0.cmpn(0)!==0){var n0=Gt.invm(this.n).mul(a0.mul(Mt.getPrivate()).iadd(At));if(n0=n0.umod(this.n),n0.cmpn(0)!==0){var t0=(Wt.getY().isOdd()?1:0)|(Xt.cmp(a0)!==0?2:0);return Rt.canonical&&n0.cmp(this.nh)>0&&(n0=this.n.sub(n0),t0^=1),new mt({r:a0,s:n0,recoveryParam:t0})}}}}}},vt.prototype.verify=function(At,Mt,Tt,Rt){At=this._truncateToN(new c(At,16)),Tt=this.keyFromPublic(Tt,Rt),Mt=new mt(Mt,"hex");var kt=Mt.r,It=Mt.s;if(kt.cmpn(1)<0||kt.cmp(this.n)>=0||It.cmpn(1)<0||It.cmp(this.n)>=0)return!1;var Dt=It.invm(this.n),Nt=Dt.mul(At).umod(this.n),Ot=Dt.mul(kt).umod(this.n),Ut;return this.curve._maxwellTrick?(Ut=this.g.jmulAdd(Nt,Tt.getPublic(),Ot),Ut.isInfinity()?!1:Ut.eqXToP(kt)):(Ut=this.g.mulAdd(Nt,Tt.getPublic(),Ot),Ut.isInfinity()?!1:Ut.getX().umod(this.n).cmp(kt)===0)},vt.prototype.recoverPubKey=function($t,At,Mt,Tt){tt((3&Mt)===Mt,"The recovery param is more than two bits"),At=new mt(At,Tt);var Rt=this.n,kt=new c($t),It=At.r,Dt=At.s,Nt=Mt&1,Ot=Mt>>1;if(It.cmp(this.curve.p.umod(this.curve.n))>=0&&Ot)throw new Error("Unable to find sencond key candinate");Ot?It=this.curve.pointFromX(It.add(this.curve.n),Nt):It=this.curve.pointFromX(It,Nt);var Ut=At.r.invm(Rt),Gt=Rt.sub(kt).mul(Ut).umod(Rt),Wt=Dt.mul(Ut).umod(Rt);return this.g.mulAdd(Gt,It,Wt)},vt.prototype.getKeyRecoveryParam=function($t,At,Mt,Tt){if(At=new mt(At,Tt),At.recoveryParam!==null)return At.recoveryParam;for(var Rt=0;Rt<4;Rt++){var kt;try{kt=this.recoverPubKey($t,At,Rt)}catch{continue}if(kt.eq(Mt))return Rt}throw new Error("Unable to find valid recovery factor")},ec$2}var utils$f=utils$y,assert$g=utils$f.assert,parseBytes$5=utils$f.parseBytes,cachedProperty$3=utils$f.cachedProperty;function KeyPair$5(c,a){this.eddsa=c,this._secret=parseBytes$5(a.secret),c.isPoint(a.pub)?this._pub=a.pub:this._pubBytes=parseBytes$5(a.pub)}KeyPair$5.fromPublic=function(a,d){return d instanceof KeyPair$5?d:new KeyPair$5(a,{pub:d})};KeyPair$5.fromSecret=function(a,d){return d instanceof KeyPair$5?d:new KeyPair$5(a,{secret:d})};KeyPair$5.prototype.secret=function(){return this._secret};cachedProperty$3(KeyPair$5,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())});cachedProperty$3(KeyPair$5,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())});cachedProperty$3(KeyPair$5,"privBytes",function(){var a=this.eddsa,d=this.hash(),et=a.encodingLength-1,nt=d.slice(0,a.encodingLength);return nt[0]&=248,nt[et]&=127,nt[et]|=64,nt});cachedProperty$3(KeyPair$5,"priv",function(){return this.eddsa.decodeInt(this.privBytes())});cachedProperty$3(KeyPair$5,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()});cachedProperty$3(KeyPair$5,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)});KeyPair$5.prototype.sign=function(a){return assert$g(this._secret,"KeyPair can only verify"),this.eddsa.sign(a,this)};KeyPair$5.prototype.verify=function(a,d){return this.eddsa.verify(a,d,this)};KeyPair$5.prototype.getSecret=function(a){return assert$g(this._secret,"KeyPair is public only"),utils$f.encode(this.secret(),a)};KeyPair$5.prototype.getPublic=function(a){return utils$f.encode(this.pubBytes(),a)};var key$3=KeyPair$5,BN$b=bnExports$4,utils$e=utils$y,assert$f=utils$e.assert,cachedProperty$2=utils$e.cachedProperty,parseBytes$4=utils$e.parseBytes;function Signature$7(c,a){this.eddsa=c,typeof a!="object"&&(a=parseBytes$4(a)),Array.isArray(a)&&(a={R:a.slice(0,c.encodingLength),S:a.slice(c.encodingLength)}),assert$f(a.R&&a.S,"Signature without R or S"),c.isPoint(a.R)&&(this._R=a.R),a.S instanceof BN$b&&(this._S=a.S),this._Rencoded=Array.isArray(a.R)?a.R:a.Rencoded,this._Sencoded=Array.isArray(a.S)?a.S:a.Sencoded}cachedProperty$2(Signature$7,"S",function(){return this.eddsa.decodeInt(this.Sencoded())});cachedProperty$2(Signature$7,"R",function(){return this.eddsa.decodePoint(this.Rencoded())});cachedProperty$2(Signature$7,"Rencoded",function(){return this.eddsa.encodePoint(this.R())});cachedProperty$2(Signature$7,"Sencoded",function(){return this.eddsa.encodeInt(this.S())});Signature$7.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())};Signature$7.prototype.toHex=function(){return utils$e.encode(this.toBytes(),"hex").toUpperCase()};var signature$3=Signature$7,hash$4=hash$7,curves$2=curves$3,utils$d=utils$y,assert$e=utils$d.assert,parseBytes$3=utils$d.parseBytes,KeyPair$4=key$3,Signature$6=signature$3;function EDDSA$1(c){if(assert$e(c==="ed25519","only tested with ed25519 so far"),!(this instanceof EDDSA$1))return new EDDSA$1(c);c=curves$2[c].curve,this.curve=c,this.g=c.g,this.g.precompute(c.n.bitLength()+1),this.pointClass=c.point().constructor,this.encodingLength=Math.ceil(c.n.bitLength()/8),this.hash=hash$4.sha512}var eddsa$1=EDDSA$1;EDDSA$1.prototype.sign=function(a,d){a=parseBytes$3(a);var et=this.keyFromSecret(d),nt=this.hashInt(et.messagePrefix(),a),tt=this.g.mul(nt),bt=this.encodePoint(tt),mt=this.hashInt(bt,et.pubBytes(),a).mul(et.priv()),vt=nt.add(mt).umod(this.curve.n);return this.makeSignature({R:tt,S:vt,Rencoded:bt})};EDDSA$1.prototype.verify=function(a,d,et){a=parseBytes$3(a),d=this.makeSignature(d);var nt=this.keyFromPublic(et),tt=this.hashInt(d.Rencoded(),nt.pubBytes(),a),bt=this.g.mul(d.S()),mt=d.R().add(nt.pub().mul(tt));return mt.eq(bt)};EDDSA$1.prototype.hashInt=function(){for(var a=this.hash(),d=0;d0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$3);var bnExports$3=bn$3.exports,api={},vmBrowserify={},hasRequiredVmBrowserify;function requireVmBrowserify(){return hasRequiredVmBrowserify||(hasRequiredVmBrowserify=1,function(exports){var indexOf=function(c,a){if(c.indexOf)return c.indexOf(a);for(var d=0;d>6],Rt=(Mt&32)===0;if((Mt&31)===31){var kt=Mt;for(Mt=0;(kt&128)===128;){if(kt=$t.readUInt8(At),$t.isError(kt))return kt;Mt<<=7,Mt|=kt&127}}else Mt&=31;var It=nt.tag[Mt];return{cls:Tt,primitive:Rt,tag:Mt,tagStr:It}}function vt($t,At,Mt){var Tt=$t.readUInt8(Mt);if($t.isError(Tt))return Tt;if(!At&&Tt===128)return null;if(!(Tt&128))return Tt;var Rt=Tt&127;if(Rt>4)return $t.error("length octect is too long");Tt=0;for(var kt=0;kt=256;Dt>>=8)It++;var Nt=new a(1+1+It);Nt[0]=kt,Nt[1]=128|It;for(var Dt=1+It,Ot=Rt.length;Ot>0;Dt--,Ot>>=8)Nt[Dt]=Ot&255;return this._createEncoderBuffer([Nt,Rt])},bt.prototype._encodeStr=function(At,Mt){if(Mt==="bitstr")return this._createEncoderBuffer([At.unused|0,At.data]);if(Mt==="bmpstr"){for(var Tt=new a(At.length*2),Rt=0;Rt=40)return this.reporter.error("Second objid identifier OOB");At.splice(0,2,At[0]*40+At[1])}for(var kt=0,Rt=0;Rt=128;It>>=7)kt++}for(var Dt=new a(kt),Nt=Dt.length-1,Rt=At.length-1;Rt>=0;Rt--){var It=At[Rt];for(Dt[Nt--]=It&127;(It>>=7)>0;)Dt[Nt--]=128|It&127}return this._createEncoderBuffer(Dt)};function mt($t){return $t<10?"0"+$t:$t}bt.prototype._encodeTime=function(At,Mt){var Tt,Rt=new Date(At);return Mt==="gentime"?Tt=[mt(Rt.getFullYear()),mt(Rt.getUTCMonth()+1),mt(Rt.getUTCDate()),mt(Rt.getUTCHours()),mt(Rt.getUTCMinutes()),mt(Rt.getUTCSeconds()),"Z"].join(""):Mt==="utctime"?Tt=[mt(Rt.getFullYear()%100),mt(Rt.getUTCMonth()+1),mt(Rt.getUTCDate()),mt(Rt.getUTCHours()),mt(Rt.getUTCMinutes()),mt(Rt.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+Mt+" time is not supported yet"),this._encodeStr(Tt,"octstr")},bt.prototype._encodeNull=function(){return this._createEncoderBuffer("")},bt.prototype._encodeInt=function(At,Mt){if(typeof At=="string"){if(!Mt)return this.reporter.error("String int or enum given, but no values map");if(!Mt.hasOwnProperty(At))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(At));At=Mt[At]}if(typeof At!="number"&&!a.isBuffer(At)){var Tt=At.toArray();!At.sign&&Tt[0]&128&&Tt.unshift(0),At=new a(Tt)}if(a.isBuffer(At)){var Rt=At.length;At.length===0&&Rt++;var It=new a(Rt);return At.copy(It),At.length===0&&(It[0]=0),this._createEncoderBuffer(It)}if(At<128)return this._createEncoderBuffer(At);if(At<256)return this._createEncoderBuffer([0,At]);for(var Rt=1,kt=At;kt>=256;kt>>=8)Rt++;for(var It=new Array(Rt),kt=It.length-1;kt>=0;kt--)It[kt]=At&255,At>>=8;return It[0]&128&&It.unshift(0),this._createEncoderBuffer(new a(It))},bt.prototype._encodeBool=function(At){return this._createEncoderBuffer(At?255:0)},bt.prototype._use=function(At,Mt){return typeof At=="function"&&(At=At(Mt)),At._getEncoder("der").tree},bt.prototype._skipDefault=function(At,Mt,Tt){var Rt=this._baseState,kt;if(Rt.default===null)return!1;var It=At.join();if(Rt.defaultBuffer===void 0&&(Rt.defaultBuffer=this._encodeValue(Rt.default,Mt,Tt).join()),It.length!==Rt.defaultBuffer.length)return!1;for(kt=0;kt=31?Tt.error("Multi-octet tag encoding unsupported"):(At||(Rt|=32),Rt|=nt.tagClassByName[Mt||"universal"]<<6,Rt)}return der_1}var pem,hasRequiredPem;function requirePem(){if(hasRequiredPem)return pem;hasRequiredPem=1;var c=inherits_browserExports,a=requireDer();function d(et){a.call(this,et),this.enc="pem"}return c(d,a),pem=d,d.prototype.encode=function(nt,tt){for(var bt=a.prototype.encode.call(this,nt),mt=bt.toString("base64"),vt=["-----BEGIN "+tt.label+"-----"],$t=0;$t0&&Ut.ishrn(Gt),Ut}function kt(Nt,Ot){Nt=Rt(Nt,Ot),Nt=Nt.mod(Ot);var Ut=c.from(Nt.toArray());if(Ut.length=0)throw new Error("invalid sig")}return verify_1=tt,verify_1}var browser$3,hasRequiredBrowser$1;function requireBrowser$1(){if(hasRequiredBrowser$1)return browser$3;hasRequiredBrowser$1=1;var c=safeBufferExports$1.Buffer,a=browser$9,d=readableBrowserExports,et=inherits_browserExports,nt=requireSign(),tt=requireVerify(),bt=require$$6;Object.keys(bt).forEach(function(Mt){bt[Mt].id=c.from(bt[Mt].id,"hex"),bt[Mt.toLowerCase()]=bt[Mt]});function mt(Mt){d.Writable.call(this);var Tt=bt[Mt];if(!Tt)throw new Error("Unknown message digest");this._hashType=Tt.hash,this._hash=a(Tt.hash),this._tag=Tt.id,this._signType=Tt.sign}et(mt,d.Writable),mt.prototype._write=function(Tt,Rt,kt){this._hash.update(Tt),kt()},mt.prototype.update=function(Tt,Rt){return this._hash.update(typeof Tt=="string"?c.from(Tt,Rt):Tt),this},mt.prototype.sign=function(Tt,Rt){this.end();var kt=this._hash.digest(),It=nt(kt,Tt,this._hashType,this._signType,this._tag);return Rt?It.toString(Rt):It};function vt(Mt){d.Writable.call(this);var Tt=bt[Mt];if(!Tt)throw new Error("Unknown message digest");this._hash=a(Tt.hash),this._tag=Tt.id,this._signType=Tt.sign}et(vt,d.Writable),vt.prototype._write=function(Tt,Rt,kt){this._hash.update(Tt),kt()},vt.prototype.update=function(Tt,Rt){return this._hash.update(typeof Tt=="string"?c.from(Tt,Rt):Tt),this},vt.prototype.verify=function(Tt,Rt,kt){var It=typeof Rt=="string"?c.from(Rt,kt):Rt;this.end();var Dt=this._hash.digest();return tt(It,Dt,Tt,this._signType,this._tag)};function $t(Mt){return new mt(Mt)}function At(Mt){return new vt(Mt)}return browser$3={Sign:$t,Verify:At,createSign:$t,createVerify:At},browser$3}var elliptic={};const name="elliptic",version$k="6.5.4",description="EC cryptography",main="lib/elliptic.js",files=["lib"],scripts={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository={type:"git",url:"git@github.com:indutny/elliptic"},keywords=["EC","Elliptic","curve","Cryptography"],author="Fedor Indutny ",license="MIT",bugs={url:"https://github.com/indutny/elliptic/issues"},homepage="https://github.com/indutny/elliptic",devDependencies={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},require$$0={name,version:version$k,description,main,files,scripts,repository,keywords,author,license,bugs,homepage,devDependencies,dependencies};var utils$c={},bn$2={exports:{}};bn$2.exports;(function(c){(function(a,d){function et(Ct,dt){if(!Ct)throw new Error(dt||"Assertion failed")}function nt(Ct,dt){Ct.super_=dt;var yt=function(){};yt.prototype=dt.prototype,Ct.prototype=new yt,Ct.prototype.constructor=Ct}function tt(Ct,dt,yt){if(tt.isBN(Ct))return Ct;this.negative=0,this.words=null,this.length=0,this.red=null,Ct!==null&&((dt==="le"||dt==="be")&&(yt=dt,dt=10),this._init(Ct||0,dt||10,yt||"be"))}typeof a=="object"?a.exports=tt:d.BN=tt,tt.BN=tt,tt.wordSize=26;var bt;try{typeof window<"u"&&typeof window.Buffer<"u"?bt=window.Buffer:bt=bufferPolyfill.Buffer}catch{}tt.isBN=function(dt){return dt instanceof tt?!0:dt!==null&&typeof dt=="object"&&dt.constructor.wordSize===tt.wordSize&&Array.isArray(dt.words)},tt.max=function(dt,yt){return dt.cmp(yt)>0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$2);var bnExports$2=bn$2.exports;(function(c){var a=c,d=bnExports$2,et=minimalisticAssert$1,nt=utils$x;a.assert=et,a.toArray=nt.toArray,a.zero2=nt.zero2,a.toHex=nt.toHex,a.encode=nt.encode;function tt(At,Mt,Tt){var Rt=new Array(Math.max(At.bitLength(),Tt)+1);Rt.fill(0);for(var kt=1<(kt>>1)-1?Nt=(kt>>1)-Ot:Nt=Ot,It.isubn(Nt)):Nt=0,Rt[Dt]=Nt,It.iushrn(1)}return Rt}a.getNAF=tt;function bt(At,Mt){var Tt=[[],[]];At=At.clone(),Mt=Mt.clone();for(var Rt=0,kt=0,It;At.cmpn(-Rt)>0||Mt.cmpn(-kt)>0;){var Dt=At.andln(3)+Rt&3,Nt=Mt.andln(3)+kt&3;Dt===3&&(Dt=-1),Nt===3&&(Nt=-1);var Ot;Dt&1?(It=At.andln(7)+Rt&7,(It===3||It===5)&&Nt===2?Ot=-Dt:Ot=Dt):Ot=0,Tt[0].push(Ot);var Ut;Nt&1?(It=Mt.andln(7)+kt&7,(It===3||It===5)&&Dt===2?Ut=-Nt:Ut=Nt):Ut=0,Tt[1].push(Ut),2*Rt===Ot+1&&(Rt=1-Rt),2*kt===Ut+1&&(kt=1-kt),At.iushrn(1),Mt.iushrn(1)}return Tt}a.getJSF=bt;function mt(At,Mt,Tt){var Rt="_"+Mt;At.prototype[Mt]=function(){return this[Rt]!==void 0?this[Rt]:this[Rt]=Tt.call(this)}}a.cachedProperty=mt;function vt(At){return typeof At=="string"?a.toArray(At,"hex"):At}a.parseBytes=vt;function $t(At){return new d(At,"hex","le")}a.intFromLE=$t})(utils$c);var curve={},BN$a=bnExports$2,utils$b=utils$c,getNAF$1=utils$b.getNAF,getJSF$1=utils$b.getJSF,assert$d=utils$b.assert;function BaseCurve$1(c,a){this.type=c,this.p=new BN$a(a.p,16),this.red=a.prime?BN$a.red(a.prime):BN$a.mont(this.p),this.zero=new BN$a(0).toRed(this.red),this.one=new BN$a(1).toRed(this.red),this.two=new BN$a(2).toRed(this.red),this.n=a.n&&new BN$a(a.n,16),this.g=a.g&&this.pointFromJSON(a.g,a.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var d=this.n&&this.p.div(this.n);!d||d.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var base$2=BaseCurve$1;BaseCurve$1.prototype.point=function c(){throw new Error("Not implemented")};BaseCurve$1.prototype.validate=function c(){throw new Error("Not implemented")};BaseCurve$1.prototype._fixedNafMul=function c(a,d){assert$d(a.precomputed);var et=a._getDoubles(),nt=getNAF$1(d,1,this._bitLength),tt=(1<=mt;$t--)vt=(vt<<1)+nt[$t];bt.push(vt)}for(var At=this.jpoint(null,null,null),Mt=this.jpoint(null,null,null),Tt=tt;Tt>0;Tt--){for(mt=0;mt=0;vt--){for(var $t=0;vt>=0&&bt[vt]===0;vt--)$t++;if(vt>=0&&$t++,mt=mt.dblp($t),vt<0)break;var At=bt[vt];assert$d(At!==0),a.type==="affine"?At>0?mt=mt.mixedAdd(tt[At-1>>1]):mt=mt.mixedAdd(tt[-At-1>>1].neg()):At>0?mt=mt.add(tt[At-1>>1]):mt=mt.add(tt[-At-1>>1].neg())}return a.type==="affine"?mt.toP():mt};BaseCurve$1.prototype._wnafMulAdd=function c(a,d,et,nt,tt){var bt=this._wnafT1,mt=this._wnafT2,vt=this._wnafT3,$t=0,At,Mt,Tt;for(At=0;At=1;At-=2){var kt=At-1,It=At;if(bt[kt]!==1||bt[It]!==1){vt[kt]=getNAF$1(et[kt],bt[kt],this._bitLength),vt[It]=getNAF$1(et[It],bt[It],this._bitLength),$t=Math.max(vt[kt].length,$t),$t=Math.max(vt[It].length,$t);continue}var Dt=[d[kt],null,null,d[It]];d[kt].y.cmp(d[It].y)===0?(Dt[1]=d[kt].add(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg())):d[kt].y.cmp(d[It].y.redNeg())===0?(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].add(d[It].neg())):(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg()));var Nt=[-3,-1,-5,-7,0,7,5,1,3],Ot=getJSF$1(et[kt],et[It]);for($t=Math.max(Ot[0].length,$t),vt[kt]=new Array($t),vt[It]=new Array($t),Mt=0;Mt<$t;Mt++){var Ut=Ot[0][Mt]|0,Gt=Ot[1][Mt]|0;vt[kt][Mt]=Nt[(Ut+1)*3+(Gt+1)],vt[It][Mt]=0,mt[kt]=Dt}}var Wt=this.jpoint(null,null,null),Xt=this._wnafT4;for(At=$t;At>=0;At--){for(var a0=0;At>=0;){var n0=!0;for(Mt=0;Mt=0&&a0++,Wt=Wt.dblp(a0),At<0)break;for(Mt=0;Mt0?Tt=mt[Mt][t0-1>>1]:t0<0&&(Tt=mt[Mt][-t0-1>>1].neg()),Tt.type==="affine"?Wt=Wt.mixedAdd(Tt):Wt=Wt.add(Tt))}}for(At=0;At=Math.ceil((a.bitLength()+1)/d.step):!1};BasePoint$1.prototype._getDoubles=function c(a,d){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var et=[this],nt=this,tt=0;tt=0&&(Rt=$t,kt=At),Mt.negative&&(Mt=Mt.neg(),Tt=Tt.neg()),Rt.negative&&(Rt=Rt.neg(),kt=kt.neg()),[{a:Mt,b:Tt},{a:Rt,b:kt}]};ShortCurve$1.prototype._endoSplit=function c(a){var d=this.endo.basis,et=d[0],nt=d[1],tt=nt.b.mul(a).divRound(this.n),bt=et.b.neg().mul(a).divRound(this.n),mt=tt.mul(et.a),vt=bt.mul(nt.a),$t=tt.mul(et.b),At=bt.mul(nt.b),Mt=a.sub(mt).sub(vt),Tt=$t.add(At).neg();return{k1:Mt,k2:Tt}};ShortCurve$1.prototype.pointFromX=function c(a,d){a=new BN$9(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr().redMul(a).redIAdd(a.redMul(this.a)).redIAdd(this.b),nt=et.redSqrt();if(nt.redSqr().redSub(et).cmp(this.zero)!==0)throw new Error("invalid point");var tt=nt.fromRed().isOdd();return(d&&!tt||!d&&tt)&&(nt=nt.redNeg()),this.point(a,nt)};ShortCurve$1.prototype.validate=function c(a){if(a.inf)return!0;var d=a.x,et=a.y,nt=this.a.redMul(d),tt=d.redSqr().redMul(d).redIAdd(nt).redIAdd(this.b);return et.redSqr().redISub(tt).cmpn(0)===0};ShortCurve$1.prototype._endoWnafMulAdd=function c(a,d,et){for(var nt=this._endoWnafT1,tt=this._endoWnafT2,bt=0;bt":""};Point$4.prototype.isInfinity=function c(){return this.inf};Point$4.prototype.add=function c(a){if(this.inf)return a;if(a.inf)return this;if(this.eq(a))return this.dbl();if(this.neg().eq(a))return this.curve.point(null,null);if(this.x.cmp(a.x)===0)return this.curve.point(null,null);var d=this.y.redSub(a.y);d.cmpn(0)!==0&&(d=d.redMul(this.x.redSub(a.x).redInvm()));var et=d.redSqr().redISub(this.x).redISub(a.x),nt=d.redMul(this.x.redSub(et)).redISub(this.y);return this.curve.point(et,nt)};Point$4.prototype.dbl=function c(){if(this.inf)return this;var a=this.y.redAdd(this.y);if(a.cmpn(0)===0)return this.curve.point(null,null);var d=this.curve.a,et=this.x.redSqr(),nt=a.redInvm(),tt=et.redAdd(et).redIAdd(et).redIAdd(d).redMul(nt),bt=tt.redSqr().redISub(this.x.redAdd(this.x)),mt=tt.redMul(this.x.redSub(bt)).redISub(this.y);return this.curve.point(bt,mt)};Point$4.prototype.getX=function c(){return this.x.fromRed()};Point$4.prototype.getY=function c(){return this.y.fromRed()};Point$4.prototype.mul=function c(a){return a=new BN$9(a,16),this.isInfinity()?this:this._hasDoubles(a)?this.curve._fixedNafMul(this,a):this.curve.endo?this.curve._endoWnafMulAdd([this],[a]):this.curve._wnafMul(this,a)};Point$4.prototype.mulAdd=function c(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt):this.curve._wnafMulAdd(1,nt,tt,2)};Point$4.prototype.jmulAdd=function c(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt,!0):this.curve._wnafMulAdd(1,nt,tt,2,!0)};Point$4.prototype.eq=function c(a){return this===a||this.inf===a.inf&&(this.inf||this.x.cmp(a.x)===0&&this.y.cmp(a.y)===0)};Point$4.prototype.neg=function c(a){if(this.inf)return this;var d=this.curve.point(this.x,this.y.redNeg());if(a&&this.precomputed){var et=this.precomputed,nt=function(tt){return tt.neg()};d.precomputed={naf:et.naf&&{wnd:et.naf.wnd,points:et.naf.points.map(nt)},doubles:et.doubles&&{step:et.doubles.step,points:et.doubles.points.map(nt)}}}return d};Point$4.prototype.toJ=function c(){if(this.inf)return this.curve.jpoint(null,null,null);var a=this.curve.jpoint(this.x,this.y,this.curve.one);return a};function JPoint$1(c,a,d,et){Base$2.BasePoint.call(this,c,"jacobian"),a===null&&d===null&&et===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new BN$9(0)):(this.x=new BN$9(a,16),this.y=new BN$9(d,16),this.z=new BN$9(et,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}inherits$2(JPoint$1,Base$2.BasePoint);ShortCurve$1.prototype.jpoint=function c(a,d,et){return new JPoint$1(this,a,d,et)};JPoint$1.prototype.toP=function c(){if(this.isInfinity())return this.curve.point(null,null);var a=this.z.redInvm(),d=a.redSqr(),et=this.x.redMul(d),nt=this.y.redMul(d).redMul(a);return this.curve.point(et,nt)};JPoint$1.prototype.neg=function c(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};JPoint$1.prototype.add=function c(a){if(this.isInfinity())return a;if(a.isInfinity())return this;var d=a.z.redSqr(),et=this.z.redSqr(),nt=this.x.redMul(d),tt=a.x.redMul(et),bt=this.y.redMul(d.redMul(a.z)),mt=a.y.redMul(et.redMul(this.z)),vt=nt.redSub(tt),$t=bt.redSub(mt);if(vt.cmpn(0)===0)return $t.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var At=vt.redSqr(),Mt=At.redMul(vt),Tt=nt.redMul(At),Rt=$t.redSqr().redIAdd(Mt).redISub(Tt).redISub(Tt),kt=$t.redMul(Tt.redISub(Rt)).redISub(bt.redMul(Mt)),It=this.z.redMul(a.z).redMul(vt);return this.curve.jpoint(Rt,kt,It)};JPoint$1.prototype.mixedAdd=function c(a){if(this.isInfinity())return a.toJ();if(a.isInfinity())return this;var d=this.z.redSqr(),et=this.x,nt=a.x.redMul(d),tt=this.y,bt=a.y.redMul(d).redMul(this.z),mt=et.redSub(nt),vt=tt.redSub(bt);if(mt.cmpn(0)===0)return vt.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var $t=mt.redSqr(),At=$t.redMul(mt),Mt=et.redMul($t),Tt=vt.redSqr().redIAdd(At).redISub(Mt).redISub(Mt),Rt=vt.redMul(Mt.redISub(Tt)).redISub(tt.redMul(At)),kt=this.z.redMul(mt);return this.curve.jpoint(Tt,Rt,kt)};JPoint$1.prototype.dblp=function c(a){if(a===0)return this;if(this.isInfinity())return this;if(!a)return this.dbl();var d;if(this.curve.zeroA||this.curve.threeA){var et=this;for(d=0;d=0)return!1;if(et.redIAdd(tt),this.x.cmp(et)===0)return!0}};JPoint$1.prototype.inspect=function c(){return this.isInfinity()?"":""};JPoint$1.prototype.isInfinity=function c(){return this.z.cmpn(0)===0};var BN$8=bnExports$2,inherits$1=inherits_browserExports,Base$1=base$2,utils$9=utils$c;function MontCurve(c){Base$1.call(this,"mont",c),this.a=new BN$8(c.a,16).toRed(this.red),this.b=new BN$8(c.b,16).toRed(this.red),this.i4=new BN$8(4).toRed(this.red).redInvm(),this.two=new BN$8(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}inherits$1(MontCurve,Base$1);var mont=MontCurve;MontCurve.prototype.validate=function c(a){var d=a.normalize().x,et=d.redSqr(),nt=et.redMul(d).redAdd(et.redMul(this.a)).redAdd(d),tt=nt.redSqrt();return tt.redSqr().cmp(nt)===0};function Point$3(c,a,d){Base$1.BasePoint.call(this,c,"projective"),a===null&&d===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new BN$8(a,16),this.z=new BN$8(d,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}inherits$1(Point$3,Base$1.BasePoint);MontCurve.prototype.decodePoint=function c(a,d){return this.point(utils$9.toArray(a,d),1)};MontCurve.prototype.point=function c(a,d){return new Point$3(this,a,d)};MontCurve.prototype.pointFromJSON=function c(a){return Point$3.fromJSON(this,a)};Point$3.prototype.precompute=function c(){};Point$3.prototype._encode=function c(){return this.getX().toArray("be",this.curve.p.byteLength())};Point$3.fromJSON=function c(a,d){return new Point$3(a,d[0],d[1]||a.one)};Point$3.prototype.inspect=function c(){return this.isInfinity()?"":""};Point$3.prototype.isInfinity=function c(){return this.z.cmpn(0)===0};Point$3.prototype.dbl=function c(){var a=this.x.redAdd(this.z),d=a.redSqr(),et=this.x.redSub(this.z),nt=et.redSqr(),tt=d.redSub(nt),bt=d.redMul(nt),mt=tt.redMul(nt.redAdd(this.curve.a24.redMul(tt)));return this.curve.point(bt,mt)};Point$3.prototype.add=function c(){throw new Error("Not supported on Montgomery curve")};Point$3.prototype.diffAdd=function c(a,d){var et=this.x.redAdd(this.z),nt=this.x.redSub(this.z),tt=a.x.redAdd(a.z),bt=a.x.redSub(a.z),mt=bt.redMul(et),vt=tt.redMul(nt),$t=d.z.redMul(mt.redAdd(vt).redSqr()),At=d.x.redMul(mt.redISub(vt).redSqr());return this.curve.point($t,At)};Point$3.prototype.mul=function c(a){for(var d=a.clone(),et=this,nt=this.curve.point(null,null),tt=this,bt=[];d.cmpn(0)!==0;d.iushrn(1))bt.push(d.andln(1));for(var mt=bt.length-1;mt>=0;mt--)bt[mt]===0?(et=et.diffAdd(nt,tt),nt=nt.dbl()):(nt=et.diffAdd(nt,tt),et=et.dbl());return nt};Point$3.prototype.mulAdd=function c(){throw new Error("Not supported on Montgomery curve")};Point$3.prototype.jumlAdd=function c(){throw new Error("Not supported on Montgomery curve")};Point$3.prototype.eq=function c(a){return this.getX().cmp(a.getX())===0};Point$3.prototype.normalize=function c(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this};Point$3.prototype.getX=function c(){return this.normalize(),this.x.fromRed()};var utils$8=utils$c,BN$7=bnExports$2,inherits=inherits_browserExports,Base=base$2,assert$b=utils$8.assert;function EdwardsCurve(c){this.twisted=(c.a|0)!==1,this.mOneA=this.twisted&&(c.a|0)===-1,this.extended=this.mOneA,Base.call(this,"edwards",c),this.a=new BN$7(c.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new BN$7(c.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new BN$7(c.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),assert$b(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(c.c|0)===1}inherits(EdwardsCurve,Base);var edwards=EdwardsCurve;EdwardsCurve.prototype._mulA=function c(a){return this.mOneA?a.redNeg():this.a.redMul(a)};EdwardsCurve.prototype._mulC=function c(a){return this.oneC?a:this.c.redMul(a)};EdwardsCurve.prototype.jpoint=function c(a,d,et,nt){return this.point(a,d,et,nt)};EdwardsCurve.prototype.pointFromX=function c(a,d){a=new BN$7(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr(),nt=this.c2.redSub(this.a.redMul(et)),tt=this.one.redSub(this.c2.redMul(this.d).redMul(et)),bt=nt.redMul(tt.redInvm()),mt=bt.redSqrt();if(mt.redSqr().redSub(bt).cmp(this.zero)!==0)throw new Error("invalid point");var vt=mt.fromRed().isOdd();return(d&&!vt||!d&&vt)&&(mt=mt.redNeg()),this.point(a,mt)};EdwardsCurve.prototype.pointFromY=function c(a,d){a=new BN$7(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr(),nt=et.redSub(this.c2),tt=et.redMul(this.d).redMul(this.c2).redSub(this.a),bt=nt.redMul(tt.redInvm());if(bt.cmp(this.zero)===0){if(d)throw new Error("invalid point");return this.point(this.zero,a)}var mt=bt.redSqrt();if(mt.redSqr().redSub(bt).cmp(this.zero)!==0)throw new Error("invalid point");return mt.fromRed().isOdd()!==d&&(mt=mt.redNeg()),this.point(mt,a)};EdwardsCurve.prototype.validate=function c(a){if(a.isInfinity())return!0;a.normalize();var d=a.x.redSqr(),et=a.y.redSqr(),nt=d.redMul(this.a).redAdd(et),tt=this.c2.redMul(this.one.redAdd(this.d.redMul(d).redMul(et)));return nt.cmp(tt)===0};function Point$2(c,a,d,et,nt){Base.BasePoint.call(this,c,"projective"),a===null&&d===null&&et===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new BN$7(a,16),this.y=new BN$7(d,16),this.z=et?new BN$7(et,16):this.curve.one,this.t=nt&&new BN$7(nt,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}inherits(Point$2,Base.BasePoint);EdwardsCurve.prototype.pointFromJSON=function c(a){return Point$2.fromJSON(this,a)};EdwardsCurve.prototype.point=function c(a,d,et,nt){return new Point$2(this,a,d,et,nt)};Point$2.fromJSON=function c(a,d){return new Point$2(a,d[0],d[1],d[2])};Point$2.prototype.inspect=function c(){return this.isInfinity()?"":""};Point$2.prototype.isInfinity=function c(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)};Point$2.prototype._extDbl=function c(){var a=this.x.redSqr(),d=this.y.redSqr(),et=this.z.redSqr();et=et.redIAdd(et);var nt=this.curve._mulA(a),tt=this.x.redAdd(this.y).redSqr().redISub(a).redISub(d),bt=nt.redAdd(d),mt=bt.redSub(et),vt=nt.redSub(d),$t=tt.redMul(mt),At=bt.redMul(vt),Mt=tt.redMul(vt),Tt=mt.redMul(bt);return this.curve.point($t,At,Tt,Mt)};Point$2.prototype._projDbl=function c(){var a=this.x.redAdd(this.y).redSqr(),d=this.x.redSqr(),et=this.y.redSqr(),nt,tt,bt,mt,vt,$t;if(this.curve.twisted){mt=this.curve._mulA(d);var At=mt.redAdd(et);this.zOne?(nt=a.redSub(d).redSub(et).redMul(At.redSub(this.curve.two)),tt=At.redMul(mt.redSub(et)),bt=At.redSqr().redSub(At).redSub(At)):(vt=this.z.redSqr(),$t=At.redSub(vt).redISub(vt),nt=a.redSub(d).redISub(et).redMul($t),tt=At.redMul(mt.redSub(et)),bt=At.redMul($t))}else mt=d.redAdd(et),vt=this.curve._mulC(this.z).redSqr(),$t=mt.redSub(vt).redSub(vt),nt=this.curve._mulC(a.redISub(mt)).redMul($t),tt=this.curve._mulC(mt).redMul(d.redISub(et)),bt=mt.redMul($t);return this.curve.point(nt,tt,bt)};Point$2.prototype.dbl=function c(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()};Point$2.prototype._extAdd=function c(a){var d=this.y.redSub(this.x).redMul(a.y.redSub(a.x)),et=this.y.redAdd(this.x).redMul(a.y.redAdd(a.x)),nt=this.t.redMul(this.curve.dd).redMul(a.t),tt=this.z.redMul(a.z.redAdd(a.z)),bt=et.redSub(d),mt=tt.redSub(nt),vt=tt.redAdd(nt),$t=et.redAdd(d),At=bt.redMul(mt),Mt=vt.redMul($t),Tt=bt.redMul($t),Rt=mt.redMul(vt);return this.curve.point(At,Mt,Rt,Tt)};Point$2.prototype._projAdd=function c(a){var d=this.z.redMul(a.z),et=d.redSqr(),nt=this.x.redMul(a.x),tt=this.y.redMul(a.y),bt=this.curve.d.redMul(nt).redMul(tt),mt=et.redSub(bt),vt=et.redAdd(bt),$t=this.x.redAdd(this.y).redMul(a.x.redAdd(a.y)).redISub(nt).redISub(tt),At=d.redMul(mt).redMul($t),Mt,Tt;return this.curve.twisted?(Mt=d.redMul(vt).redMul(tt.redSub(this.curve._mulA(nt))),Tt=mt.redMul(vt)):(Mt=d.redMul(vt).redMul(tt.redSub(nt)),Tt=this.curve._mulC(mt).redMul(vt)),this.curve.point(At,Mt,Tt)};Point$2.prototype.add=function c(a){return this.isInfinity()?a:a.isInfinity()?this:this.curve.extended?this._extAdd(a):this._projAdd(a)};Point$2.prototype.mul=function c(a){return this._hasDoubles(a)?this.curve._fixedNafMul(this,a):this.curve._wnafMul(this,a)};Point$2.prototype.mulAdd=function c(a,d,et){return this.curve._wnafMulAdd(1,[this,d],[a,et],2,!1)};Point$2.prototype.jmulAdd=function c(a,d,et){return this.curve._wnafMulAdd(1,[this,d],[a,et],2,!0)};Point$2.prototype.normalize=function c(){if(this.zOne)return this;var a=this.z.redInvm();return this.x=this.x.redMul(a),this.y=this.y.redMul(a),this.t&&(this.t=this.t.redMul(a)),this.z=this.curve.one,this.zOne=!0,this};Point$2.prototype.neg=function c(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())};Point$2.prototype.getX=function c(){return this.normalize(),this.x.fromRed()};Point$2.prototype.getY=function c(){return this.normalize(),this.y.fromRed()};Point$2.prototype.eq=function c(a){return this===a||this.getX().cmp(a.getX())===0&&this.getY().cmp(a.getY())===0};Point$2.prototype.eqXToP=function c(a){var d=a.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(d)===0)return!0;for(var et=a.clone(),nt=this.curve.redN.redMul(this.z);;){if(et.iadd(this.curve.n),et.cmp(this.curve.p)>=0)return!1;if(d.redIAdd(nt),this.x.cmp(d)===0)return!0}};Point$2.prototype.toP=Point$2.prototype.normalize;Point$2.prototype.mixedAdd=Point$2.prototype.add;(function(c){var a=c;a.base=base$2,a.short=short,a.mont=mont,a.edwards=edwards})(curve);var curves$1={},secp256k1,hasRequiredSecp256k1;function requireSecp256k1(){return hasRequiredSecp256k1||(hasRequiredSecp256k1=1,secp256k1={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}),secp256k1}(function(c){var a=c,d=hash$7,et=curve,nt=utils$c,tt=nt.assert;function bt($t){$t.type==="short"?this.curve=new et.short($t):$t.type==="edwards"?this.curve=new et.edwards($t):this.curve=new et.mont($t),this.g=this.curve.g,this.n=this.curve.n,this.hash=$t.hash,tt(this.g.validate(),"Invalid curve"),tt(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}a.PresetCurve=bt;function mt($t,At){Object.defineProperty(a,$t,{configurable:!0,enumerable:!0,get:function(){var Mt=new bt(At);return Object.defineProperty(a,$t,{configurable:!0,enumerable:!0,value:Mt}),Mt}})}mt("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:d.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),mt("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:d.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),mt("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:d.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),mt("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:d.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),mt("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:d.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),mt("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:d.sha256,gRed:!1,g:["9"]}),mt("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:d.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var vt;try{vt=requireSecp256k1()}catch{vt=void 0}mt("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:d.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",vt]})})(curves$1);var BN$6=bnExports$2,utils$7=utils$c,assert$a=utils$7.assert;function KeyPair$3(c,a){this.ec=c,this.priv=null,this.pub=null,a.priv&&this._importPrivate(a.priv,a.privEnc),a.pub&&this._importPublic(a.pub,a.pubEnc)}var key$2=KeyPair$3;KeyPair$3.fromPublic=function c(a,d,et){return d instanceof KeyPair$3?d:new KeyPair$3(a,{pub:d,pubEnc:et})};KeyPair$3.fromPrivate=function c(a,d,et){return d instanceof KeyPair$3?d:new KeyPair$3(a,{priv:d,privEnc:et})};KeyPair$3.prototype.validate=function c(){var a=this.getPublic();return a.isInfinity()?{result:!1,reason:"Invalid public key"}:a.validate()?a.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}};KeyPair$3.prototype.getPublic=function c(a,d){return typeof a=="string"&&(d=a,a=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),d?this.pub.encode(d,a):this.pub};KeyPair$3.prototype.getPrivate=function c(a){return a==="hex"?this.priv.toString(16,2):this.priv};KeyPair$3.prototype._importPrivate=function c(a,d){this.priv=new BN$6(a,d||16),this.priv=this.priv.umod(this.ec.curve.n)};KeyPair$3.prototype._importPublic=function c(a,d){if(a.x||a.y){this.ec.curve.type==="mont"?assert$a(a.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&assert$a(a.x&&a.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(a.x,a.y);return}this.pub=this.ec.curve.decodePoint(a,d)};KeyPair$3.prototype.derive=function c(a){return a.validate()||assert$a(a.validate(),"public point not validated"),a.mul(this.priv).getX()};KeyPair$3.prototype.sign=function c(a,d,et){return this.ec.sign(a,this,d,et)};KeyPair$3.prototype.verify=function c(a,d){return this.ec.verify(a,d,this)};KeyPair$3.prototype.inspect=function c(){return""};var BN$5=bnExports$2,utils$6=utils$c,assert$9=utils$6.assert;function Signature$5(c,a){if(c instanceof Signature$5)return c;this._importDER(c,a)||(assert$9(c.r&&c.s,"Signature without r or s"),this.r=new BN$5(c.r,16),this.s=new BN$5(c.s,16),c.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=c.recoveryParam)}var signature$2=Signature$5;function Position$1(){this.place=0}function getLength$1(c,a){var d=c[a.place++];if(!(d&128))return d;var et=d&15;if(et===0||et>4)return!1;for(var nt=0,tt=0,bt=a.place;tt>>=0;return nt<=127?!1:(a.place=bt,nt)}function rmPadding$1(c){for(var a=0,d=c.length-1;!c[a]&&!(c[a+1]&128)&&a>>3);for(c.push(d|128);--d;)c.push(a>>>(d<<3)&255);c.push(a)}Signature$5.prototype.toDER=function c(a){var d=this.r.toArray(),et=this.s.toArray();for(d[0]&128&&(d=[0].concat(d)),et[0]&128&&(et=[0].concat(et)),d=rmPadding$1(d),et=rmPadding$1(et);!et[0]&&!(et[1]&128);)et=et.slice(1);var nt=[2];constructLength$1(nt,d.length),nt=nt.concat(d),nt.push(2),constructLength$1(nt,et.length);var tt=nt.concat(et),bt=[48];return constructLength$1(bt,tt.length),bt=bt.concat(tt),utils$6.encode(bt,a)};var ec$1,hasRequiredEc;function requireEc(){if(hasRequiredEc)return ec$1;hasRequiredEc=1;var c=bnExports$2,a=hmacDrbg$1,d=utils$c,et=curves$1,nt=requireBrorand(),tt=d.assert,bt=key$2,mt=signature$2;function vt($t){if(!(this instanceof vt))return new vt($t);typeof $t=="string"&&(tt(Object.prototype.hasOwnProperty.call(et,$t),"Unknown curve "+$t),$t=et[$t]),$t instanceof et.PresetCurve&&($t={curve:$t}),this.curve=$t.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=$t.curve.g,this.g.precompute($t.curve.n.bitLength()+1),this.hash=$t.hash||$t.curve.hash}return ec$1=vt,vt.prototype.keyPair=function(At){return new bt(this,At)},vt.prototype.keyFromPrivate=function(At,Mt){return bt.fromPrivate(this,At,Mt)},vt.prototype.keyFromPublic=function(At,Mt){return bt.fromPublic(this,At,Mt)},vt.prototype.genKeyPair=function(At){At||(At={});for(var Mt=new a({hash:this.hash,pers:At.pers,persEnc:At.persEnc||"utf8",entropy:At.entropy||nt(this.hash.hmacStrength),entropyEnc:At.entropy&&At.entropyEnc||"utf8",nonce:this.n.toArray()}),Tt=this.n.byteLength(),Rt=this.n.sub(new c(2));;){var kt=new c(Mt.generate(Tt));if(!(kt.cmp(Rt)>0))return kt.iaddn(1),this.keyFromPrivate(kt)}},vt.prototype._truncateToN=function(At,Mt){var Tt=At.byteLength()*8-this.n.bitLength();return Tt>0&&(At=At.ushrn(Tt)),!Mt&&At.cmp(this.n)>=0?At.sub(this.n):At},vt.prototype.sign=function(At,Mt,Tt,Rt){typeof Tt=="object"&&(Rt=Tt,Tt=null),Rt||(Rt={}),Mt=this.keyFromPrivate(Mt,Tt),At=this._truncateToN(new c(At,16));for(var kt=this.n.byteLength(),It=Mt.getPrivate().toArray("be",kt),Dt=At.toArray("be",kt),Nt=new a({hash:this.hash,entropy:It,nonce:Dt,pers:Rt.pers,persEnc:Rt.persEnc||"utf8"}),Ot=this.n.sub(new c(1)),Ut=0;;Ut++){var Gt=Rt.k?Rt.k(Ut):new c(Nt.generate(this.n.byteLength()));if(Gt=this._truncateToN(Gt,!0),!(Gt.cmpn(1)<=0||Gt.cmp(Ot)>=0)){var Wt=this.g.mul(Gt);if(!Wt.isInfinity()){var Xt=Wt.getX(),a0=Xt.umod(this.n);if(a0.cmpn(0)!==0){var n0=Gt.invm(this.n).mul(a0.mul(Mt.getPrivate()).iadd(At));if(n0=n0.umod(this.n),n0.cmpn(0)!==0){var t0=(Wt.getY().isOdd()?1:0)|(Xt.cmp(a0)!==0?2:0);return Rt.canonical&&n0.cmp(this.nh)>0&&(n0=this.n.sub(n0),t0^=1),new mt({r:a0,s:n0,recoveryParam:t0})}}}}}},vt.prototype.verify=function(At,Mt,Tt,Rt){At=this._truncateToN(new c(At,16)),Tt=this.keyFromPublic(Tt,Rt),Mt=new mt(Mt,"hex");var kt=Mt.r,It=Mt.s;if(kt.cmpn(1)<0||kt.cmp(this.n)>=0||It.cmpn(1)<0||It.cmp(this.n)>=0)return!1;var Dt=It.invm(this.n),Nt=Dt.mul(At).umod(this.n),Ot=Dt.mul(kt).umod(this.n),Ut;return this.curve._maxwellTrick?(Ut=this.g.jmulAdd(Nt,Tt.getPublic(),Ot),Ut.isInfinity()?!1:Ut.eqXToP(kt)):(Ut=this.g.mulAdd(Nt,Tt.getPublic(),Ot),Ut.isInfinity()?!1:Ut.getX().umod(this.n).cmp(kt)===0)},vt.prototype.recoverPubKey=function($t,At,Mt,Tt){tt((3&Mt)===Mt,"The recovery param is more than two bits"),At=new mt(At,Tt);var Rt=this.n,kt=new c($t),It=At.r,Dt=At.s,Nt=Mt&1,Ot=Mt>>1;if(It.cmp(this.curve.p.umod(this.curve.n))>=0&&Ot)throw new Error("Unable to find sencond key candinate");Ot?It=this.curve.pointFromX(It.add(this.curve.n),Nt):It=this.curve.pointFromX(It,Nt);var Ut=At.r.invm(Rt),Gt=Rt.sub(kt).mul(Ut).umod(Rt),Wt=Dt.mul(Ut).umod(Rt);return this.g.mulAdd(Gt,It,Wt)},vt.prototype.getKeyRecoveryParam=function($t,At,Mt,Tt){if(At=new mt(At,Tt),At.recoveryParam!==null)return At.recoveryParam;for(var Rt=0;Rt<4;Rt++){var kt;try{kt=this.recoverPubKey($t,At,Rt)}catch{continue}if(kt.eq(Mt))return Rt}throw new Error("Unable to find valid recovery factor")},ec$1}var utils$5=utils$c,assert$8=utils$5.assert,parseBytes$2=utils$5.parseBytes,cachedProperty$1=utils$5.cachedProperty;function KeyPair$2(c,a){this.eddsa=c,this._secret=parseBytes$2(a.secret),c.isPoint(a.pub)?this._pub=a.pub:this._pubBytes=parseBytes$2(a.pub)}KeyPair$2.fromPublic=function c(a,d){return d instanceof KeyPair$2?d:new KeyPair$2(a,{pub:d})};KeyPair$2.fromSecret=function c(a,d){return d instanceof KeyPair$2?d:new KeyPair$2(a,{secret:d})};KeyPair$2.prototype.secret=function c(){return this._secret};cachedProperty$1(KeyPair$2,"pubBytes",function c(){return this.eddsa.encodePoint(this.pub())});cachedProperty$1(KeyPair$2,"pub",function c(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())});cachedProperty$1(KeyPair$2,"privBytes",function c(){var a=this.eddsa,d=this.hash(),et=a.encodingLength-1,nt=d.slice(0,a.encodingLength);return nt[0]&=248,nt[et]&=127,nt[et]|=64,nt});cachedProperty$1(KeyPair$2,"priv",function c(){return this.eddsa.decodeInt(this.privBytes())});cachedProperty$1(KeyPair$2,"hash",function c(){return this.eddsa.hash().update(this.secret()).digest()});cachedProperty$1(KeyPair$2,"messagePrefix",function c(){return this.hash().slice(this.eddsa.encodingLength)});KeyPair$2.prototype.sign=function c(a){return assert$8(this._secret,"KeyPair can only verify"),this.eddsa.sign(a,this)};KeyPair$2.prototype.verify=function c(a,d){return this.eddsa.verify(a,d,this)};KeyPair$2.prototype.getSecret=function c(a){return assert$8(this._secret,"KeyPair is public only"),utils$5.encode(this.secret(),a)};KeyPair$2.prototype.getPublic=function c(a){return utils$5.encode(this.pubBytes(),a)};var key$1=KeyPair$2,BN$4=bnExports$2,utils$4=utils$c,assert$7=utils$4.assert,cachedProperty=utils$4.cachedProperty,parseBytes$1=utils$4.parseBytes;function Signature$4(c,a){this.eddsa=c,typeof a!="object"&&(a=parseBytes$1(a)),Array.isArray(a)&&(a={R:a.slice(0,c.encodingLength),S:a.slice(c.encodingLength)}),assert$7(a.R&&a.S,"Signature without R or S"),c.isPoint(a.R)&&(this._R=a.R),a.S instanceof BN$4&&(this._S=a.S),this._Rencoded=Array.isArray(a.R)?a.R:a.Rencoded,this._Sencoded=Array.isArray(a.S)?a.S:a.Sencoded}cachedProperty(Signature$4,"S",function c(){return this.eddsa.decodeInt(this.Sencoded())});cachedProperty(Signature$4,"R",function c(){return this.eddsa.decodePoint(this.Rencoded())});cachedProperty(Signature$4,"Rencoded",function c(){return this.eddsa.encodePoint(this.R())});cachedProperty(Signature$4,"Sencoded",function c(){return this.eddsa.encodeInt(this.S())});Signature$4.prototype.toBytes=function c(){return this.Rencoded().concat(this.Sencoded())};Signature$4.prototype.toHex=function c(){return utils$4.encode(this.toBytes(),"hex").toUpperCase()};var signature$1=Signature$4,hash$3=hash$7,curves=curves$1,utils$3=utils$c,assert$6=utils$3.assert,parseBytes=utils$3.parseBytes,KeyPair$1=key$1,Signature$3=signature$1;function EDDSA(c){if(assert$6(c==="ed25519","only tested with ed25519 so far"),!(this instanceof EDDSA))return new EDDSA(c);c=curves[c].curve,this.curve=c,this.g=c.g,this.g.precompute(c.n.bitLength()+1),this.pointClass=c.point().constructor,this.encodingLength=Math.ceil(c.n.bitLength()/8),this.hash=hash$3.sha512}var eddsa=EDDSA;EDDSA.prototype.sign=function c(a,d){a=parseBytes(a);var et=this.keyFromSecret(d),nt=this.hashInt(et.messagePrefix(),a),tt=this.g.mul(nt),bt=this.encodePoint(tt),mt=this.hashInt(bt,et.pubBytes(),a).mul(et.priv()),vt=nt.add(mt).umod(this.curve.n);return this.makeSignature({R:tt,S:vt,Rencoded:bt})};EDDSA.prototype.verify=function c(a,d,et){a=parseBytes(a),d=this.makeSignature(d);var nt=this.keyFromPublic(et),tt=this.hashInt(d.Rencoded(),nt.pubBytes(),a),bt=this.g.mul(d.S()),mt=d.R().add(nt.pub().mul(tt));return mt.eq(bt)};EDDSA.prototype.hashInt=function c(){for(var a=this.hash(),d=0;d0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn$1);var bnExports$1=bn$1.exports,browser$2,hasRequiredBrowser;function requireBrowser(){if(hasRequiredBrowser)return browser$2;hasRequiredBrowser=1;var c=requireElliptic(),a=bnExports$1;browser$2=function(bt){return new et(bt)};var d={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};d.p224=d.secp224r1,d.p256=d.secp256r1=d.prime256v1,d.p192=d.secp192r1=d.prime192v1,d.p384=d.secp384r1,d.p521=d.secp521r1;function et(tt){this.curveType=d[tt],this.curveType||(this.curveType={name:tt}),this.curve=new c.ec(this.curveType.name),this.keys=void 0}et.prototype.generateKeys=function(tt,bt){return this.keys=this.curve.genKeyPair(),this.getPublicKey(tt,bt)},et.prototype.computeSecret=function(tt,bt,mt){bt=bt||"utf8",dist$2.Buffer.isBuffer(tt)||(tt=new dist$2.Buffer(tt,bt));var vt=this.curve.keyFromPublic(tt).getPublic(),$t=vt.mul(this.keys.getPrivate()).getX();return nt($t,mt,this.curveType.byteLength)},et.prototype.getPublicKey=function(tt,bt){var mt=this.keys.getPublic(bt==="compressed",!0);return bt==="hybrid"&&(mt[mt.length-1]%2?mt[0]=7:mt[0]=6),nt(mt,tt)},et.prototype.getPrivateKey=function(tt){return nt(this.keys.getPrivate(),tt)},et.prototype.setPublicKey=function(tt,bt){return bt=bt||"utf8",dist$2.Buffer.isBuffer(tt)||(tt=new dist$2.Buffer(tt,bt)),this.keys._importPublic(tt),this},et.prototype.setPrivateKey=function(tt,bt){bt=bt||"utf8",dist$2.Buffer.isBuffer(tt)||(tt=new dist$2.Buffer(tt,bt));var mt=new a(tt);return mt=mt.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(mt),this};function nt(tt,bt,mt){Array.isArray(tt)||(tt=tt.toArray());var vt=new dist$2.Buffer(tt);if(mt&&vt.length0?dt:yt},tt.min=function(dt,yt){return dt.cmp(yt)<0?dt:yt},tt.prototype._init=function(dt,yt,gt){if(typeof dt=="number")return this._initNumber(dt,yt,gt);if(typeof dt=="object")return this._initArray(dt,yt,gt);yt==="hex"&&(yt=16),et(yt===(yt|0)&&yt>=2&&yt<=36),dt=dt.toString().replace(/\s+/g,"");var xt=0;dt[0]==="-"&&(xt++,this.negative=1),xt=0;xt-=3)_t=dt[xt]|dt[xt-1]<<8|dt[xt-2]<<16,this.words[St]|=_t<>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);else if(gt==="le")for(xt=0,St=0;xt>>26-Pt&67108863,Pt+=24,Pt>=26&&(Pt-=26,St++);return this.strip()};function mt(Ct,dt){var yt=Ct.charCodeAt(dt);return yt>=65&&yt<=70?yt-55:yt>=97&&yt<=102?yt-87:yt-48&15}function vt(Ct,dt,yt){var gt=mt(Ct,yt);return yt-1>=dt&&(gt|=mt(Ct,yt-1)<<4),gt}tt.prototype._parseHex=function(dt,yt,gt){this.length=Math.ceil((dt.length-yt)/6),this.words=new Array(this.length);for(var xt=0;xt=yt;xt-=2)Pt=vt(dt,yt,xt)<=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8;else{var Et=dt.length-yt;for(xt=Et%2===0?yt+1:yt;xt=18?(St-=18,_t+=1,this.words[_t]|=Pt>>>26):St+=8}this.strip()};function $t(Ct,dt,yt,gt){for(var xt=0,St=Math.min(Ct.length,yt),_t=dt;_t=49?xt+=Pt-49+10:Pt>=17?xt+=Pt-17+10:xt+=Pt}return xt}tt.prototype._parseBase=function(dt,yt,gt){this.words=[0],this.length=1;for(var xt=0,St=1;St<=67108863;St*=yt)xt++;xt--,St=St/yt|0;for(var _t=dt.length-gt,Pt=_t%xt,Et=Math.min(_t,_t-Pt)+gt,ht=0,wt=gt;wt1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},tt.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},tt.prototype.inspect=function(){return(this.red?""};var At=["","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"],Mt=[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],Tt=[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];tt.prototype.toString=function(dt,yt){dt=dt||10,yt=yt|0||1;var gt;if(dt===16||dt==="hex"){gt="";for(var xt=0,St=0,_t=0;_t>>24-xt&16777215,St!==0||_t!==this.length-1?gt=At[6-Et.length]+Et+gt:gt=Et+gt,xt+=2,xt>=26&&(xt-=26,_t--)}for(St!==0&&(gt=St.toString(16)+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}if(dt===(dt|0)&&dt>=2&&dt<=36){var ht=Mt[dt],wt=Tt[dt];gt="";var Bt=this.clone();for(Bt.negative=0;!Bt.isZero();){var Lt=Bt.modn(wt).toString(dt);Bt=Bt.idivn(wt),Bt.isZero()?gt=Lt+gt:gt=At[ht-Lt.length]+Lt+gt}for(this.isZero()&&(gt="0"+gt);gt.length%yt!==0;)gt="0"+gt;return this.negative!==0&&(gt="-"+gt),gt}et(!1,"Base should be between 2 and 36")},tt.prototype.toNumber=function(){var dt=this.words[0];return this.length===2?dt+=this.words[1]*67108864:this.length===3&&this.words[2]===1?dt+=4503599627370496+this.words[1]*67108864:this.length>2&&et(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-dt:dt},tt.prototype.toJSON=function(){return this.toString(16)},tt.prototype.toBuffer=function(dt,yt){return et(typeof bt<"u"),this.toArrayLike(bt,dt,yt)},tt.prototype.toArray=function(dt,yt){return this.toArrayLike(Array,dt,yt)},tt.prototype.toArrayLike=function(dt,yt,gt){var xt=this.byteLength(),St=gt||Math.max(1,xt);et(xt<=St,"byte array longer than desired length"),et(St>0,"Requested array length <= 0"),this.strip();var _t=yt==="le",Pt=new dt(St),Et,ht,wt=this.clone();if(_t){for(ht=0;!wt.isZero();ht++)Et=wt.andln(255),wt.iushrn(8),Pt[ht]=Et;for(;ht=4096&&(gt+=13,yt>>>=13),yt>=64&&(gt+=7,yt>>>=7),yt>=8&&(gt+=4,yt>>>=4),yt>=2&&(gt+=2,yt>>>=2),gt+yt},tt.prototype._zeroBits=function(dt){if(dt===0)return 26;var yt=dt,gt=0;return yt&8191||(gt+=13,yt>>>=13),yt&127||(gt+=7,yt>>>=7),yt&15||(gt+=4,yt>>>=4),yt&3||(gt+=2,yt>>>=2),yt&1||gt++,gt},tt.prototype.bitLength=function(){var dt=this.words[this.length-1],yt=this._countBits(dt);return(this.length-1)*26+yt};function Rt(Ct){for(var dt=new Array(Ct.bitLength()),yt=0;yt>>xt}return dt}tt.prototype.zeroBits=function(){if(this.isZero())return 0;for(var dt=0,yt=0;ytdt.length?this.clone().ior(dt):dt.clone().ior(this)},tt.prototype.uor=function(dt){return this.length>dt.length?this.clone().iuor(dt):dt.clone().iuor(this)},tt.prototype.iuand=function(dt){var yt;this.length>dt.length?yt=dt:yt=this;for(var gt=0;gtdt.length?this.clone().iand(dt):dt.clone().iand(this)},tt.prototype.uand=function(dt){return this.length>dt.length?this.clone().iuand(dt):dt.clone().iuand(this)},tt.prototype.iuxor=function(dt){var yt,gt;this.length>dt.length?(yt=this,gt=dt):(yt=dt,gt=this);for(var xt=0;xtdt.length?this.clone().ixor(dt):dt.clone().ixor(this)},tt.prototype.uxor=function(dt){return this.length>dt.length?this.clone().iuxor(dt):dt.clone().iuxor(this)},tt.prototype.inotn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=Math.ceil(dt/26)|0,gt=dt%26;this._expand(yt),gt>0&&yt--;for(var xt=0;xt0&&(this.words[xt]=~this.words[xt]&67108863>>26-gt),this.strip()},tt.prototype.notn=function(dt){return this.clone().inotn(dt)},tt.prototype.setn=function(dt,yt){et(typeof dt=="number"&&dt>=0);var gt=dt/26|0,xt=dt%26;return this._expand(gt+1),yt?this.words[gt]=this.words[gt]|1<dt.length?(gt=this,xt=dt):(gt=dt,xt=this);for(var St=0,_t=0;_t>>26;for(;St!==0&&_t>>26;if(this.length=gt.length,St!==0)this.words[this.length]=St,this.length++;else if(gt!==this)for(;_tdt.length?this.clone().iadd(dt):dt.clone().iadd(this)},tt.prototype.isub=function(dt){if(dt.negative!==0){dt.negative=0;var yt=this.iadd(dt);return dt.negative=1,yt._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(dt),this.negative=1,this._normSign();var gt=this.cmp(dt);if(gt===0)return this.negative=0,this.length=1,this.words[0]=0,this;var xt,St;gt>0?(xt=this,St=dt):(xt=dt,St=this);for(var _t=0,Pt=0;Pt>26,this.words[Pt]=yt&67108863;for(;_t!==0&&Pt>26,this.words[Pt]=yt&67108863;if(_t===0&&Pt>>26,Bt=Et&67108863,Lt=Math.min(ht,dt.length-1),jt=Math.max(0,ht-Ct.length+1);jt<=Lt;jt++){var Ft=ht-jt|0;xt=Ct.words[Ft]|0,St=dt.words[jt]|0,_t=xt*St+Bt,wt+=_t/67108864|0,Bt=_t&67108863}yt.words[ht]=Bt|0,Et=wt|0}return Et!==0?yt.words[ht]=Et|0:yt.length--,yt.strip()}var It=function(dt,yt,gt){var xt=dt.words,St=yt.words,_t=gt.words,Pt=0,Et,ht,wt,Bt=xt[0]|0,Lt=Bt&8191,jt=Bt>>>13,Ft=xt[1]|0,Vt=Ft&8191,zt=Ft>>>13,qt=xt[2]|0,Kt=qt&8191,e0=qt>>>13,Zt=xt[3]|0,Jt=Zt&8191,i0=Zt>>>13,h0=xt[4]|0,o0=h0&8191,l0=h0>>>13,$0=xt[5]|0,p0=$0&8191,u0=$0>>>13,J0=xt[6]|0,v0=J0&8191,E0=J0>>>13,Z0=xt[7]|0,w0=Z0&8191,b0=Z0>>>13,K0=xt[8]|0,Qt=K0&8191,Ht=K0>>>13,Yt=xt[9]|0,r0=Yt&8191,f0=Yt>>>13,x0=St[0]|0,d0=x0&8191,y0=x0>>>13,Q0=St[1]|0,g0=Q0&8191,A0=Q0>>>13,Y0=St[2]|0,_0=Y0&8191,N0=Y0>>>13,X0=St[3]|0,M0=X0&8191,O0=X0>>>13,rr=St[4]|0,P0=rr&8191,D0=rr>>>13,nr=St[5]|0,C0=nr&8191,F0=nr>>>13,ir=St[6]|0,R0=ir&8191,U0=ir>>>13,ar=St[7]|0,B0=ar&8191,z0=ar>>>13,or=St[8]|0,k0=or&8191,H0=or>>>13,fr=St[9]|0,I0=fr&8191,j0=fr>>>13;gt.negative=dt.negative^yt.negative,gt.length=19,Et=Math.imul(Lt,d0),ht=Math.imul(Lt,y0),ht=ht+Math.imul(jt,d0)|0,wt=Math.imul(jt,y0);var er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(er>>>26)|0,er&=67108863,Et=Math.imul(Vt,d0),ht=Math.imul(Vt,y0),ht=ht+Math.imul(zt,d0)|0,wt=Math.imul(zt,y0),Et=Et+Math.imul(Lt,g0)|0,ht=ht+Math.imul(Lt,A0)|0,ht=ht+Math.imul(jt,g0)|0,wt=wt+Math.imul(jt,A0)|0;var tr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(tr>>>26)|0,tr&=67108863,Et=Math.imul(Kt,d0),ht=Math.imul(Kt,y0),ht=ht+Math.imul(e0,d0)|0,wt=Math.imul(e0,y0),Et=Et+Math.imul(Vt,g0)|0,ht=ht+Math.imul(Vt,A0)|0,ht=ht+Math.imul(zt,g0)|0,wt=wt+Math.imul(zt,A0)|0,Et=Et+Math.imul(Lt,_0)|0,ht=ht+Math.imul(Lt,N0)|0,ht=ht+Math.imul(jt,_0)|0,wt=wt+Math.imul(jt,N0)|0;var cr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(cr>>>26)|0,cr&=67108863,Et=Math.imul(Jt,d0),ht=Math.imul(Jt,y0),ht=ht+Math.imul(i0,d0)|0,wt=Math.imul(i0,y0),Et=Et+Math.imul(Kt,g0)|0,ht=ht+Math.imul(Kt,A0)|0,ht=ht+Math.imul(e0,g0)|0,wt=wt+Math.imul(e0,A0)|0,Et=Et+Math.imul(Vt,_0)|0,ht=ht+Math.imul(Vt,N0)|0,ht=ht+Math.imul(zt,_0)|0,wt=wt+Math.imul(zt,N0)|0,Et=Et+Math.imul(Lt,M0)|0,ht=ht+Math.imul(Lt,O0)|0,ht=ht+Math.imul(jt,M0)|0,wt=wt+Math.imul(jt,O0)|0;var lr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(lr>>>26)|0,lr&=67108863,Et=Math.imul(o0,d0),ht=Math.imul(o0,y0),ht=ht+Math.imul(l0,d0)|0,wt=Math.imul(l0,y0),Et=Et+Math.imul(Jt,g0)|0,ht=ht+Math.imul(Jt,A0)|0,ht=ht+Math.imul(i0,g0)|0,wt=wt+Math.imul(i0,A0)|0,Et=Et+Math.imul(Kt,_0)|0,ht=ht+Math.imul(Kt,N0)|0,ht=ht+Math.imul(e0,_0)|0,wt=wt+Math.imul(e0,N0)|0,Et=Et+Math.imul(Vt,M0)|0,ht=ht+Math.imul(Vt,O0)|0,ht=ht+Math.imul(zt,M0)|0,wt=wt+Math.imul(zt,O0)|0,Et=Et+Math.imul(Lt,P0)|0,ht=ht+Math.imul(Lt,D0)|0,ht=ht+Math.imul(jt,P0)|0,wt=wt+Math.imul(jt,D0)|0;var ur=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(ur>>>26)|0,ur&=67108863,Et=Math.imul(p0,d0),ht=Math.imul(p0,y0),ht=ht+Math.imul(u0,d0)|0,wt=Math.imul(u0,y0),Et=Et+Math.imul(o0,g0)|0,ht=ht+Math.imul(o0,A0)|0,ht=ht+Math.imul(l0,g0)|0,wt=wt+Math.imul(l0,A0)|0,Et=Et+Math.imul(Jt,_0)|0,ht=ht+Math.imul(Jt,N0)|0,ht=ht+Math.imul(i0,_0)|0,wt=wt+Math.imul(i0,N0)|0,Et=Et+Math.imul(Kt,M0)|0,ht=ht+Math.imul(Kt,O0)|0,ht=ht+Math.imul(e0,M0)|0,wt=wt+Math.imul(e0,O0)|0,Et=Et+Math.imul(Vt,P0)|0,ht=ht+Math.imul(Vt,D0)|0,ht=ht+Math.imul(zt,P0)|0,wt=wt+Math.imul(zt,D0)|0,Et=Et+Math.imul(Lt,C0)|0,ht=ht+Math.imul(Lt,F0)|0,ht=ht+Math.imul(jt,C0)|0,wt=wt+Math.imul(jt,F0)|0;var dr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(dr>>>26)|0,dr&=67108863,Et=Math.imul(v0,d0),ht=Math.imul(v0,y0),ht=ht+Math.imul(E0,d0)|0,wt=Math.imul(E0,y0),Et=Et+Math.imul(p0,g0)|0,ht=ht+Math.imul(p0,A0)|0,ht=ht+Math.imul(u0,g0)|0,wt=wt+Math.imul(u0,A0)|0,Et=Et+Math.imul(o0,_0)|0,ht=ht+Math.imul(o0,N0)|0,ht=ht+Math.imul(l0,_0)|0,wt=wt+Math.imul(l0,N0)|0,Et=Et+Math.imul(Jt,M0)|0,ht=ht+Math.imul(Jt,O0)|0,ht=ht+Math.imul(i0,M0)|0,wt=wt+Math.imul(i0,O0)|0,Et=Et+Math.imul(Kt,P0)|0,ht=ht+Math.imul(Kt,D0)|0,ht=ht+Math.imul(e0,P0)|0,wt=wt+Math.imul(e0,D0)|0,Et=Et+Math.imul(Vt,C0)|0,ht=ht+Math.imul(Vt,F0)|0,ht=ht+Math.imul(zt,C0)|0,wt=wt+Math.imul(zt,F0)|0,Et=Et+Math.imul(Lt,R0)|0,ht=ht+Math.imul(Lt,U0)|0,ht=ht+Math.imul(jt,R0)|0,wt=wt+Math.imul(jt,U0)|0;var pr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(pr>>>26)|0,pr&=67108863,Et=Math.imul(w0,d0),ht=Math.imul(w0,y0),ht=ht+Math.imul(b0,d0)|0,wt=Math.imul(b0,y0),Et=Et+Math.imul(v0,g0)|0,ht=ht+Math.imul(v0,A0)|0,ht=ht+Math.imul(E0,g0)|0,wt=wt+Math.imul(E0,A0)|0,Et=Et+Math.imul(p0,_0)|0,ht=ht+Math.imul(p0,N0)|0,ht=ht+Math.imul(u0,_0)|0,wt=wt+Math.imul(u0,N0)|0,Et=Et+Math.imul(o0,M0)|0,ht=ht+Math.imul(o0,O0)|0,ht=ht+Math.imul(l0,M0)|0,wt=wt+Math.imul(l0,O0)|0,Et=Et+Math.imul(Jt,P0)|0,ht=ht+Math.imul(Jt,D0)|0,ht=ht+Math.imul(i0,P0)|0,wt=wt+Math.imul(i0,D0)|0,Et=Et+Math.imul(Kt,C0)|0,ht=ht+Math.imul(Kt,F0)|0,ht=ht+Math.imul(e0,C0)|0,wt=wt+Math.imul(e0,F0)|0,Et=Et+Math.imul(Vt,R0)|0,ht=ht+Math.imul(Vt,U0)|0,ht=ht+Math.imul(zt,R0)|0,wt=wt+Math.imul(zt,U0)|0,Et=Et+Math.imul(Lt,B0)|0,ht=ht+Math.imul(Lt,z0)|0,ht=ht+Math.imul(jt,B0)|0,wt=wt+Math.imul(jt,z0)|0;var br=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(br>>>26)|0,br&=67108863,Et=Math.imul(Qt,d0),ht=Math.imul(Qt,y0),ht=ht+Math.imul(Ht,d0)|0,wt=Math.imul(Ht,y0),Et=Et+Math.imul(w0,g0)|0,ht=ht+Math.imul(w0,A0)|0,ht=ht+Math.imul(b0,g0)|0,wt=wt+Math.imul(b0,A0)|0,Et=Et+Math.imul(v0,_0)|0,ht=ht+Math.imul(v0,N0)|0,ht=ht+Math.imul(E0,_0)|0,wt=wt+Math.imul(E0,N0)|0,Et=Et+Math.imul(p0,M0)|0,ht=ht+Math.imul(p0,O0)|0,ht=ht+Math.imul(u0,M0)|0,wt=wt+Math.imul(u0,O0)|0,Et=Et+Math.imul(o0,P0)|0,ht=ht+Math.imul(o0,D0)|0,ht=ht+Math.imul(l0,P0)|0,wt=wt+Math.imul(l0,D0)|0,Et=Et+Math.imul(Jt,C0)|0,ht=ht+Math.imul(Jt,F0)|0,ht=ht+Math.imul(i0,C0)|0,wt=wt+Math.imul(i0,F0)|0,Et=Et+Math.imul(Kt,R0)|0,ht=ht+Math.imul(Kt,U0)|0,ht=ht+Math.imul(e0,R0)|0,wt=wt+Math.imul(e0,U0)|0,Et=Et+Math.imul(Vt,B0)|0,ht=ht+Math.imul(Vt,z0)|0,ht=ht+Math.imul(zt,B0)|0,wt=wt+Math.imul(zt,z0)|0,Et=Et+Math.imul(Lt,k0)|0,ht=ht+Math.imul(Lt,H0)|0,ht=ht+Math.imul(jt,k0)|0,wt=wt+Math.imul(jt,H0)|0;var yr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(yr>>>26)|0,yr&=67108863,Et=Math.imul(r0,d0),ht=Math.imul(r0,y0),ht=ht+Math.imul(f0,d0)|0,wt=Math.imul(f0,y0),Et=Et+Math.imul(Qt,g0)|0,ht=ht+Math.imul(Qt,A0)|0,ht=ht+Math.imul(Ht,g0)|0,wt=wt+Math.imul(Ht,A0)|0,Et=Et+Math.imul(w0,_0)|0,ht=ht+Math.imul(w0,N0)|0,ht=ht+Math.imul(b0,_0)|0,wt=wt+Math.imul(b0,N0)|0,Et=Et+Math.imul(v0,M0)|0,ht=ht+Math.imul(v0,O0)|0,ht=ht+Math.imul(E0,M0)|0,wt=wt+Math.imul(E0,O0)|0,Et=Et+Math.imul(p0,P0)|0,ht=ht+Math.imul(p0,D0)|0,ht=ht+Math.imul(u0,P0)|0,wt=wt+Math.imul(u0,D0)|0,Et=Et+Math.imul(o0,C0)|0,ht=ht+Math.imul(o0,F0)|0,ht=ht+Math.imul(l0,C0)|0,wt=wt+Math.imul(l0,F0)|0,Et=Et+Math.imul(Jt,R0)|0,ht=ht+Math.imul(Jt,U0)|0,ht=ht+Math.imul(i0,R0)|0,wt=wt+Math.imul(i0,U0)|0,Et=Et+Math.imul(Kt,B0)|0,ht=ht+Math.imul(Kt,z0)|0,ht=ht+Math.imul(e0,B0)|0,wt=wt+Math.imul(e0,z0)|0,Et=Et+Math.imul(Vt,k0)|0,ht=ht+Math.imul(Vt,H0)|0,ht=ht+Math.imul(zt,k0)|0,wt=wt+Math.imul(zt,H0)|0,Et=Et+Math.imul(Lt,I0)|0,ht=ht+Math.imul(Lt,j0)|0,ht=ht+Math.imul(jt,I0)|0,wt=wt+Math.imul(jt,j0)|0;var gr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(gr>>>26)|0,gr&=67108863,Et=Math.imul(r0,g0),ht=Math.imul(r0,A0),ht=ht+Math.imul(f0,g0)|0,wt=Math.imul(f0,A0),Et=Et+Math.imul(Qt,_0)|0,ht=ht+Math.imul(Qt,N0)|0,ht=ht+Math.imul(Ht,_0)|0,wt=wt+Math.imul(Ht,N0)|0,Et=Et+Math.imul(w0,M0)|0,ht=ht+Math.imul(w0,O0)|0,ht=ht+Math.imul(b0,M0)|0,wt=wt+Math.imul(b0,O0)|0,Et=Et+Math.imul(v0,P0)|0,ht=ht+Math.imul(v0,D0)|0,ht=ht+Math.imul(E0,P0)|0,wt=wt+Math.imul(E0,D0)|0,Et=Et+Math.imul(p0,C0)|0,ht=ht+Math.imul(p0,F0)|0,ht=ht+Math.imul(u0,C0)|0,wt=wt+Math.imul(u0,F0)|0,Et=Et+Math.imul(o0,R0)|0,ht=ht+Math.imul(o0,U0)|0,ht=ht+Math.imul(l0,R0)|0,wt=wt+Math.imul(l0,U0)|0,Et=Et+Math.imul(Jt,B0)|0,ht=ht+Math.imul(Jt,z0)|0,ht=ht+Math.imul(i0,B0)|0,wt=wt+Math.imul(i0,z0)|0,Et=Et+Math.imul(Kt,k0)|0,ht=ht+Math.imul(Kt,H0)|0,ht=ht+Math.imul(e0,k0)|0,wt=wt+Math.imul(e0,H0)|0,Et=Et+Math.imul(Vt,I0)|0,ht=ht+Math.imul(Vt,j0)|0,ht=ht+Math.imul(zt,I0)|0,wt=wt+Math.imul(zt,j0)|0;var vr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(vr>>>26)|0,vr&=67108863,Et=Math.imul(r0,_0),ht=Math.imul(r0,N0),ht=ht+Math.imul(f0,_0)|0,wt=Math.imul(f0,N0),Et=Et+Math.imul(Qt,M0)|0,ht=ht+Math.imul(Qt,O0)|0,ht=ht+Math.imul(Ht,M0)|0,wt=wt+Math.imul(Ht,O0)|0,Et=Et+Math.imul(w0,P0)|0,ht=ht+Math.imul(w0,D0)|0,ht=ht+Math.imul(b0,P0)|0,wt=wt+Math.imul(b0,D0)|0,Et=Et+Math.imul(v0,C0)|0,ht=ht+Math.imul(v0,F0)|0,ht=ht+Math.imul(E0,C0)|0,wt=wt+Math.imul(E0,F0)|0,Et=Et+Math.imul(p0,R0)|0,ht=ht+Math.imul(p0,U0)|0,ht=ht+Math.imul(u0,R0)|0,wt=wt+Math.imul(u0,U0)|0,Et=Et+Math.imul(o0,B0)|0,ht=ht+Math.imul(o0,z0)|0,ht=ht+Math.imul(l0,B0)|0,wt=wt+Math.imul(l0,z0)|0,Et=Et+Math.imul(Jt,k0)|0,ht=ht+Math.imul(Jt,H0)|0,ht=ht+Math.imul(i0,k0)|0,wt=wt+Math.imul(i0,H0)|0,Et=Et+Math.imul(Kt,I0)|0,ht=ht+Math.imul(Kt,j0)|0,ht=ht+Math.imul(e0,I0)|0,wt=wt+Math.imul(e0,j0)|0;var xr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(xr>>>26)|0,xr&=67108863,Et=Math.imul(r0,M0),ht=Math.imul(r0,O0),ht=ht+Math.imul(f0,M0)|0,wt=Math.imul(f0,O0),Et=Et+Math.imul(Qt,P0)|0,ht=ht+Math.imul(Qt,D0)|0,ht=ht+Math.imul(Ht,P0)|0,wt=wt+Math.imul(Ht,D0)|0,Et=Et+Math.imul(w0,C0)|0,ht=ht+Math.imul(w0,F0)|0,ht=ht+Math.imul(b0,C0)|0,wt=wt+Math.imul(b0,F0)|0,Et=Et+Math.imul(v0,R0)|0,ht=ht+Math.imul(v0,U0)|0,ht=ht+Math.imul(E0,R0)|0,wt=wt+Math.imul(E0,U0)|0,Et=Et+Math.imul(p0,B0)|0,ht=ht+Math.imul(p0,z0)|0,ht=ht+Math.imul(u0,B0)|0,wt=wt+Math.imul(u0,z0)|0,Et=Et+Math.imul(o0,k0)|0,ht=ht+Math.imul(o0,H0)|0,ht=ht+Math.imul(l0,k0)|0,wt=wt+Math.imul(l0,H0)|0,Et=Et+Math.imul(Jt,I0)|0,ht=ht+Math.imul(Jt,j0)|0,ht=ht+Math.imul(i0,I0)|0,wt=wt+Math.imul(i0,j0)|0;var wr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(wr>>>26)|0,wr&=67108863,Et=Math.imul(r0,P0),ht=Math.imul(r0,D0),ht=ht+Math.imul(f0,P0)|0,wt=Math.imul(f0,D0),Et=Et+Math.imul(Qt,C0)|0,ht=ht+Math.imul(Qt,F0)|0,ht=ht+Math.imul(Ht,C0)|0,wt=wt+Math.imul(Ht,F0)|0,Et=Et+Math.imul(w0,R0)|0,ht=ht+Math.imul(w0,U0)|0,ht=ht+Math.imul(b0,R0)|0,wt=wt+Math.imul(b0,U0)|0,Et=Et+Math.imul(v0,B0)|0,ht=ht+Math.imul(v0,z0)|0,ht=ht+Math.imul(E0,B0)|0,wt=wt+Math.imul(E0,z0)|0,Et=Et+Math.imul(p0,k0)|0,ht=ht+Math.imul(p0,H0)|0,ht=ht+Math.imul(u0,k0)|0,wt=wt+Math.imul(u0,H0)|0,Et=Et+Math.imul(o0,I0)|0,ht=ht+Math.imul(o0,j0)|0,ht=ht+Math.imul(l0,I0)|0,wt=wt+Math.imul(l0,j0)|0;var Er=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Er>>>26)|0,Er&=67108863,Et=Math.imul(r0,C0),ht=Math.imul(r0,F0),ht=ht+Math.imul(f0,C0)|0,wt=Math.imul(f0,F0),Et=Et+Math.imul(Qt,R0)|0,ht=ht+Math.imul(Qt,U0)|0,ht=ht+Math.imul(Ht,R0)|0,wt=wt+Math.imul(Ht,U0)|0,Et=Et+Math.imul(w0,B0)|0,ht=ht+Math.imul(w0,z0)|0,ht=ht+Math.imul(b0,B0)|0,wt=wt+Math.imul(b0,z0)|0,Et=Et+Math.imul(v0,k0)|0,ht=ht+Math.imul(v0,H0)|0,ht=ht+Math.imul(E0,k0)|0,wt=wt+Math.imul(E0,H0)|0,Et=Et+Math.imul(p0,I0)|0,ht=ht+Math.imul(p0,j0)|0,ht=ht+Math.imul(u0,I0)|0,wt=wt+Math.imul(u0,j0)|0;var $r=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+($r>>>26)|0,$r&=67108863,Et=Math.imul(r0,R0),ht=Math.imul(r0,U0),ht=ht+Math.imul(f0,R0)|0,wt=Math.imul(f0,U0),Et=Et+Math.imul(Qt,B0)|0,ht=ht+Math.imul(Qt,z0)|0,ht=ht+Math.imul(Ht,B0)|0,wt=wt+Math.imul(Ht,z0)|0,Et=Et+Math.imul(w0,k0)|0,ht=ht+Math.imul(w0,H0)|0,ht=ht+Math.imul(b0,k0)|0,wt=wt+Math.imul(b0,H0)|0,Et=Et+Math.imul(v0,I0)|0,ht=ht+Math.imul(v0,j0)|0,ht=ht+Math.imul(E0,I0)|0,wt=wt+Math.imul(E0,j0)|0;var Sr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,Et=Math.imul(r0,B0),ht=Math.imul(r0,z0),ht=ht+Math.imul(f0,B0)|0,wt=Math.imul(f0,z0),Et=Et+Math.imul(Qt,k0)|0,ht=ht+Math.imul(Qt,H0)|0,ht=ht+Math.imul(Ht,k0)|0,wt=wt+Math.imul(Ht,H0)|0,Et=Et+Math.imul(w0,I0)|0,ht=ht+Math.imul(w0,j0)|0,ht=ht+Math.imul(b0,I0)|0,wt=wt+Math.imul(b0,j0)|0;var Ar=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Ar>>>26)|0,Ar&=67108863,Et=Math.imul(r0,k0),ht=Math.imul(r0,H0),ht=ht+Math.imul(f0,k0)|0,wt=Math.imul(f0,H0),Et=Et+Math.imul(Qt,I0)|0,ht=ht+Math.imul(Qt,j0)|0,ht=ht+Math.imul(Ht,I0)|0,wt=wt+Math.imul(Ht,j0)|0;var Mr=(Pt+Et|0)+((ht&8191)<<13)|0;Pt=(wt+(ht>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,Et=Math.imul(r0,I0),ht=Math.imul(r0,j0),ht=ht+Math.imul(f0,I0)|0,wt=Math.imul(f0,j0);var _r=(Pt+Et|0)+((ht&8191)<<13)|0;return Pt=(wt+(ht>>>13)|0)+(_r>>>26)|0,_r&=67108863,_t[0]=er,_t[1]=tr,_t[2]=cr,_t[3]=lr,_t[4]=ur,_t[5]=dr,_t[6]=pr,_t[7]=br,_t[8]=yr,_t[9]=gr,_t[10]=vr,_t[11]=xr,_t[12]=wr,_t[13]=Er,_t[14]=$r,_t[15]=Sr,_t[16]=Ar,_t[17]=Mr,_t[18]=_r,Pt!==0&&(_t[19]=Pt,gt.length++),gt};Math.imul||(It=kt);function Dt(Ct,dt,yt){yt.negative=dt.negative^Ct.negative,yt.length=Ct.length+dt.length;for(var gt=0,xt=0,St=0;St>>26)|0,xt+=_t>>>26,_t&=67108863}yt.words[St]=Pt,gt=_t,_t=xt}return gt!==0?yt.words[St]=gt:yt.length--,yt.strip()}function Nt(Ct,dt,yt){var gt=new Ot;return gt.mulp(Ct,dt,yt)}tt.prototype.mulTo=function(dt,yt){var gt,xt=this.length+dt.length;return this.length===10&&dt.length===10?gt=It(this,dt,yt):xt<63?gt=kt(this,dt,yt):xt<1024?gt=Dt(this,dt,yt):gt=Nt(this,dt,yt),gt};function Ot(Ct,dt){this.x=Ct,this.y=dt}Ot.prototype.makeRBT=function(dt){for(var yt=new Array(dt),gt=tt.prototype._countBits(dt)-1,xt=0;xt>=1;return xt},Ot.prototype.permute=function(dt,yt,gt,xt,St,_t){for(var Pt=0;Pt<_t;Pt++)xt[Pt]=yt[dt[Pt]],St[Pt]=gt[dt[Pt]]},Ot.prototype.transform=function(dt,yt,gt,xt,St,_t){this.permute(_t,dt,yt,gt,xt,St);for(var Pt=1;Pt>>1)St++;return 1<>>13,gt[2*_t+1]=St&8191,St=St>>>13;for(_t=2*yt;_t>=26,yt+=xt/67108864|0,yt+=St>>>26,this.words[gt]=St&67108863}return yt!==0&&(this.words[gt]=yt,this.length++),this},tt.prototype.muln=function(dt){return this.clone().imuln(dt)},tt.prototype.sqr=function(){return this.mul(this)},tt.prototype.isqr=function(){return this.imul(this.clone())},tt.prototype.pow=function(dt){var yt=Rt(dt);if(yt.length===0)return new tt(1);for(var gt=this,xt=0;xt=0);var yt=dt%26,gt=(dt-yt)/26,xt=67108863>>>26-yt<<26-yt,St;if(yt!==0){var _t=0;for(St=0;St>>26-yt}_t&&(this.words[St]=_t,this.length++)}if(gt!==0){for(St=this.length-1;St>=0;St--)this.words[St+gt]=this.words[St];for(St=0;St=0);var xt;yt?xt=(yt-yt%26)/26:xt=0;var St=dt%26,_t=Math.min((dt-St)/26,this.length),Pt=67108863^67108863>>>St<_t)for(this.length-=_t,ht=0;ht=0&&(wt!==0||ht>=xt);ht--){var Bt=this.words[ht]|0;this.words[ht]=wt<<26-St|Bt>>>St,wt=Bt&Pt}return Et&&wt!==0&&(Et.words[Et.length++]=wt),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},tt.prototype.ishrn=function(dt,yt,gt){return et(this.negative===0),this.iushrn(dt,yt,gt)},tt.prototype.shln=function(dt){return this.clone().ishln(dt)},tt.prototype.ushln=function(dt){return this.clone().iushln(dt)},tt.prototype.shrn=function(dt){return this.clone().ishrn(dt)},tt.prototype.ushrn=function(dt){return this.clone().iushrn(dt)},tt.prototype.testn=function(dt){et(typeof dt=="number"&&dt>=0);var yt=dt%26,gt=(dt-yt)/26,xt=1<=0);var yt=dt%26,gt=(dt-yt)/26;if(et(this.negative===0,"imaskn works only with positive numbers"),this.length<=gt)return this;if(yt!==0&>++,this.length=Math.min(gt,this.length),yt!==0){var xt=67108863^67108863>>>yt<=67108864;yt++)this.words[yt]-=67108864,yt===this.length-1?this.words[yt+1]=1:this.words[yt+1]++;return this.length=Math.max(this.length,yt+1),this},tt.prototype.isubn=function(dt){if(et(typeof dt=="number"),et(dt<67108864),dt<0)return this.iaddn(-dt);if(this.negative!==0)return this.negative=0,this.iaddn(dt),this.negative=1,this;if(this.words[0]-=dt,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var yt=0;yt>26)-(Et/67108864|0),this.words[St+gt]=_t&67108863}for(;St>26,this.words[St+gt]=_t&67108863;if(Pt===0)return this.strip();for(et(Pt===-1),Pt=0,St=0;St>26,this.words[St]=_t&67108863;return this.negative=1,this.strip()},tt.prototype._wordDiv=function(dt,yt){var gt=this.length-dt.length,xt=this.clone(),St=dt,_t=St.words[St.length-1]|0,Pt=this._countBits(_t);gt=26-Pt,gt!==0&&(St=St.ushln(gt),xt.iushln(gt),_t=St.words[St.length-1]|0);var Et=xt.length-St.length,ht;if(yt!=="mod"){ht=new tt(null),ht.length=Et+1,ht.words=new Array(ht.length);for(var wt=0;wt=0;Lt--){var jt=(xt.words[St.length+Lt]|0)*67108864+(xt.words[St.length+Lt-1]|0);for(jt=Math.min(jt/_t|0,67108863),xt._ishlnsubmul(St,jt,Lt);xt.negative!==0;)jt--,xt.negative=0,xt._ishlnsubmul(St,1,Lt),xt.isZero()||(xt.negative^=1);ht&&(ht.words[Lt]=jt)}return ht&&ht.strip(),xt.strip(),yt!=="div"&>!==0&&xt.iushrn(gt),{div:ht||null,mod:xt}},tt.prototype.divmod=function(dt,yt,gt){if(et(!dt.isZero()),this.isZero())return{div:new tt(0),mod:new tt(0)};var xt,St,_t;return this.negative!==0&&dt.negative===0?(_t=this.neg().divmod(dt,yt),yt!=="mod"&&(xt=_t.div.neg()),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.iadd(dt)),{div:xt,mod:St}):this.negative===0&&dt.negative!==0?(_t=this.divmod(dt.neg(),yt),yt!=="mod"&&(xt=_t.div.neg()),{div:xt,mod:_t.mod}):this.negative&dt.negative?(_t=this.neg().divmod(dt.neg(),yt),yt!=="div"&&(St=_t.mod.neg(),gt&&St.negative!==0&&St.isub(dt)),{div:_t.div,mod:St}):dt.length>this.length||this.cmp(dt)<0?{div:new tt(0),mod:this}:dt.length===1?yt==="div"?{div:this.divn(dt.words[0]),mod:null}:yt==="mod"?{div:null,mod:new tt(this.modn(dt.words[0]))}:{div:this.divn(dt.words[0]),mod:new tt(this.modn(dt.words[0]))}:this._wordDiv(dt,yt)},tt.prototype.div=function(dt){return this.divmod(dt,"div",!1).div},tt.prototype.mod=function(dt){return this.divmod(dt,"mod",!1).mod},tt.prototype.umod=function(dt){return this.divmod(dt,"mod",!0).mod},tt.prototype.divRound=function(dt){var yt=this.divmod(dt);if(yt.mod.isZero())return yt.div;var gt=yt.div.negative!==0?yt.mod.isub(dt):yt.mod,xt=dt.ushrn(1),St=dt.andln(1),_t=gt.cmp(xt);return _t<0||St===1&&_t===0?yt.div:yt.div.negative!==0?yt.div.isubn(1):yt.div.iaddn(1)},tt.prototype.modn=function(dt){et(dt<=67108863);for(var yt=(1<<26)%dt,gt=0,xt=this.length-1;xt>=0;xt--)gt=(yt*gt+(this.words[xt]|0))%dt;return gt},tt.prototype.idivn=function(dt){et(dt<=67108863);for(var yt=0,gt=this.length-1;gt>=0;gt--){var xt=(this.words[gt]|0)+yt*67108864;this.words[gt]=xt/dt|0,yt=xt%dt}return this.strip()},tt.prototype.divn=function(dt){return this.clone().idivn(dt)},tt.prototype.egcd=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=new tt(0),Pt=new tt(1),Et=0;yt.isEven()&>.isEven();)yt.iushrn(1),gt.iushrn(1),++Et;for(var ht=gt.clone(),wt=yt.clone();!yt.isZero();){for(var Bt=0,Lt=1;!(yt.words[0]&Lt)&&Bt<26;++Bt,Lt<<=1);if(Bt>0)for(yt.iushrn(Bt);Bt-- >0;)(xt.isOdd()||St.isOdd())&&(xt.iadd(ht),St.isub(wt)),xt.iushrn(1),St.iushrn(1);for(var jt=0,Ft=1;!(gt.words[0]&Ft)&&jt<26;++jt,Ft<<=1);if(jt>0)for(gt.iushrn(jt);jt-- >0;)(_t.isOdd()||Pt.isOdd())&&(_t.iadd(ht),Pt.isub(wt)),_t.iushrn(1),Pt.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(_t),St.isub(Pt)):(gt.isub(yt),_t.isub(xt),Pt.isub(St))}return{a:_t,b:Pt,gcd:gt.iushln(Et)}},tt.prototype._invmp=function(dt){et(dt.negative===0),et(!dt.isZero());var yt=this,gt=dt.clone();yt.negative!==0?yt=yt.umod(dt):yt=yt.clone();for(var xt=new tt(1),St=new tt(0),_t=gt.clone();yt.cmpn(1)>0&>.cmpn(1)>0;){for(var Pt=0,Et=1;!(yt.words[0]&Et)&&Pt<26;++Pt,Et<<=1);if(Pt>0)for(yt.iushrn(Pt);Pt-- >0;)xt.isOdd()&&xt.iadd(_t),xt.iushrn(1);for(var ht=0,wt=1;!(gt.words[0]&wt)&&ht<26;++ht,wt<<=1);if(ht>0)for(gt.iushrn(ht);ht-- >0;)St.isOdd()&&St.iadd(_t),St.iushrn(1);yt.cmp(gt)>=0?(yt.isub(gt),xt.isub(St)):(gt.isub(yt),St.isub(xt))}var Bt;return yt.cmpn(1)===0?Bt=xt:Bt=St,Bt.cmpn(0)<0&&Bt.iadd(dt),Bt},tt.prototype.gcd=function(dt){if(this.isZero())return dt.abs();if(dt.isZero())return this.abs();var yt=this.clone(),gt=dt.clone();yt.negative=0,gt.negative=0;for(var xt=0;yt.isEven()&>.isEven();xt++)yt.iushrn(1),gt.iushrn(1);do{for(;yt.isEven();)yt.iushrn(1);for(;gt.isEven();)gt.iushrn(1);var St=yt.cmp(gt);if(St<0){var _t=yt;yt=gt,gt=_t}else if(St===0||gt.cmpn(1)===0)break;yt.isub(gt)}while(!0);return gt.iushln(xt)},tt.prototype.invm=function(dt){return this.egcd(dt).a.umod(dt)},tt.prototype.isEven=function(){return(this.words[0]&1)===0},tt.prototype.isOdd=function(){return(this.words[0]&1)===1},tt.prototype.andln=function(dt){return this.words[0]&dt},tt.prototype.bincn=function(dt){et(typeof dt=="number");var yt=dt%26,gt=(dt-yt)/26,xt=1<>>26,Pt&=67108863,this.words[_t]=Pt}return St!==0&&(this.words[_t]=St,this.length++),this},tt.prototype.isZero=function(){return this.length===1&&this.words[0]===0},tt.prototype.cmpn=function(dt){var yt=dt<0;if(this.negative!==0&&!yt)return-1;if(this.negative===0&&yt)return 1;this.strip();var gt;if(this.length>1)gt=1;else{yt&&(dt=-dt),et(dt<=67108863,"Number is too big");var xt=this.words[0]|0;gt=xt===dt?0:xtdt.length)return 1;if(this.length=0;gt--){var xt=this.words[gt]|0,St=dt.words[gt]|0;if(xt!==St){xtSt&&(yt=1);break}}return yt},tt.prototype.gtn=function(dt){return this.cmpn(dt)===1},tt.prototype.gt=function(dt){return this.cmp(dt)===1},tt.prototype.gten=function(dt){return this.cmpn(dt)>=0},tt.prototype.gte=function(dt){return this.cmp(dt)>=0},tt.prototype.ltn=function(dt){return this.cmpn(dt)===-1},tt.prototype.lt=function(dt){return this.cmp(dt)===-1},tt.prototype.lten=function(dt){return this.cmpn(dt)<=0},tt.prototype.lte=function(dt){return this.cmp(dt)<=0},tt.prototype.eqn=function(dt){return this.cmpn(dt)===0},tt.prototype.eq=function(dt){return this.cmp(dt)===0},tt.red=function(dt){return new t0(dt)},tt.prototype.toRed=function(dt){return et(!this.red,"Already a number in reduction context"),et(this.negative===0,"red works only with positives"),dt.convertTo(this)._forceRed(dt)},tt.prototype.fromRed=function(){return et(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},tt.prototype._forceRed=function(dt){return this.red=dt,this},tt.prototype.forceRed=function(dt){return et(!this.red,"Already a number in reduction context"),this._forceRed(dt)},tt.prototype.redAdd=function(dt){return et(this.red,"redAdd works only with red numbers"),this.red.add(this,dt)},tt.prototype.redIAdd=function(dt){return et(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,dt)},tt.prototype.redSub=function(dt){return et(this.red,"redSub works only with red numbers"),this.red.sub(this,dt)},tt.prototype.redISub=function(dt){return et(this.red,"redISub works only with red numbers"),this.red.isub(this,dt)},tt.prototype.redShl=function(dt){return et(this.red,"redShl works only with red numbers"),this.red.shl(this,dt)},tt.prototype.redMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.mul(this,dt)},tt.prototype.redIMul=function(dt){return et(this.red,"redMul works only with red numbers"),this.red._verify2(this,dt),this.red.imul(this,dt)},tt.prototype.redSqr=function(){return et(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},tt.prototype.redISqr=function(){return et(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},tt.prototype.redSqrt=function(){return et(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},tt.prototype.redInvm=function(){return et(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},tt.prototype.redNeg=function(){return et(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},tt.prototype.redPow=function(dt){return et(this.red&&!dt.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,dt)};var Ut={k256:null,p224:null,p192:null,p25519:null};function Gt(Ct,dt){this.name=Ct,this.p=new tt(dt,16),this.n=this.p.bitLength(),this.k=new tt(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Gt.prototype._tmp=function(){var dt=new tt(null);return dt.words=new Array(Math.ceil(this.n/13)),dt},Gt.prototype.ireduce=function(dt){var yt=dt,gt;do this.split(yt,this.tmp),yt=this.imulK(yt),yt=yt.iadd(this.tmp),gt=yt.bitLength();while(gt>this.n);var xt=gt0?yt.isub(this.p):yt.strip!==void 0?yt.strip():yt._strip(),yt},Gt.prototype.split=function(dt,yt){dt.iushrn(this.n,0,yt)},Gt.prototype.imulK=function(dt){return dt.imul(this.k)};function Wt(){Gt.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}nt(Wt,Gt),Wt.prototype.split=function(dt,yt){for(var gt=4194303,xt=Math.min(dt.length,9),St=0;St>>22,_t=Pt}_t>>>=22,dt.words[St-10]=_t,_t===0&&dt.length>10?dt.length-=10:dt.length-=9},Wt.prototype.imulK=function(dt){dt.words[dt.length]=0,dt.words[dt.length+1]=0,dt.length+=2;for(var yt=0,gt=0;gt>>=26,dt.words[gt]=St,yt=xt}return yt!==0&&(dt.words[dt.length++]=yt),dt},tt._prime=function(dt){if(Ut[dt])return Ut[dt];var yt;if(dt==="k256")yt=new Wt;else if(dt==="p224")yt=new Xt;else if(dt==="p192")yt=new a0;else if(dt==="p25519")yt=new n0;else throw new Error("Unknown prime "+dt);return Ut[dt]=yt,yt};function t0(Ct){if(typeof Ct=="string"){var dt=tt._prime(Ct);this.m=dt.p,this.prime=dt}else et(Ct.gtn(1),"modulus must be greater than 1"),this.m=Ct,this.prime=null}t0.prototype._verify1=function(dt){et(dt.negative===0,"red works only with positives"),et(dt.red,"red works only with red numbers")},t0.prototype._verify2=function(dt,yt){et((dt.negative|yt.negative)===0,"red works only with positives"),et(dt.red&&dt.red===yt.red,"red works only with red numbers")},t0.prototype.imod=function(dt){return this.prime?this.prime.ireduce(dt)._forceRed(this):dt.umod(this.m)._forceRed(this)},t0.prototype.neg=function(dt){return dt.isZero()?dt.clone():this.m.sub(dt)._forceRed(this)},t0.prototype.add=function(dt,yt){this._verify2(dt,yt);var gt=dt.add(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt._forceRed(this)},t0.prototype.iadd=function(dt,yt){this._verify2(dt,yt);var gt=dt.iadd(yt);return gt.cmp(this.m)>=0&>.isub(this.m),gt},t0.prototype.sub=function(dt,yt){this._verify2(dt,yt);var gt=dt.sub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt._forceRed(this)},t0.prototype.isub=function(dt,yt){this._verify2(dt,yt);var gt=dt.isub(yt);return gt.cmpn(0)<0&>.iadd(this.m),gt},t0.prototype.shl=function(dt,yt){return this._verify1(dt),this.imod(dt.ushln(yt))},t0.prototype.imul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.imul(yt))},t0.prototype.mul=function(dt,yt){return this._verify2(dt,yt),this.imod(dt.mul(yt))},t0.prototype.isqr=function(dt){return this.imul(dt,dt.clone())},t0.prototype.sqr=function(dt){return this.mul(dt,dt)},t0.prototype.sqrt=function(dt){if(dt.isZero())return dt.clone();var yt=this.m.andln(3);if(et(yt%2===1),yt===3){var gt=this.m.add(new tt(1)).iushrn(2);return this.pow(dt,gt)}for(var xt=this.m.subn(1),St=0;!xt.isZero()&&xt.andln(1)===0;)St++,xt.iushrn(1);et(!xt.isZero());var _t=new tt(1).toRed(this),Pt=_t.redNeg(),Et=this.m.subn(1).iushrn(1),ht=this.m.bitLength();for(ht=new tt(2*ht*ht).toRed(this);this.pow(ht,Et).cmp(Pt)!==0;)ht.redIAdd(Pt);for(var wt=this.pow(ht,xt),Bt=this.pow(dt,xt.addn(1).iushrn(1)),Lt=this.pow(dt,xt),jt=St;Lt.cmp(_t)!==0;){for(var Ft=Lt,Vt=0;Ft.cmp(_t)!==0;Vt++)Ft=Ft.redSqr();et(Vt=0;St--){for(var wt=yt.words[St],Bt=ht-1;Bt>=0;Bt--){var Lt=wt>>Bt&1;if(_t!==xt[0]&&(_t=this.sqr(_t)),Lt===0&&Pt===0){Et=0;continue}Pt<<=1,Pt|=Lt,Et++,!(Et!==gt&&(St!==0||Bt!==0))&&(_t=this.mul(_t,xt[Pt]),Et=0,Pt=0)}ht=26}return _t},t0.prototype.convertTo=function(dt){var yt=dt.umod(this.m);return yt===dt?yt.clone():yt},t0.prototype.convertFrom=function(dt){var yt=dt.clone();return yt.red=null,yt},tt.mont=function(dt){return new c0(dt)};function c0(Ct){t0.call(this,Ct),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new tt(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)}nt(c0,t0),c0.prototype.convertTo=function(dt){return this.imod(dt.ushln(this.shift))},c0.prototype.convertFrom=function(dt){var yt=this.imod(dt.mul(this.rinv));return yt.red=null,yt},c0.prototype.imul=function(dt,yt){if(dt.isZero()||yt.isZero())return dt.words[0]=0,dt.length=1,dt;var gt=dt.imul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.mul=function(dt,yt){if(dt.isZero()||yt.isZero())return new tt(0)._forceRed(this);var gt=dt.mul(yt),xt=gt.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),St=gt.isub(xt).iushrn(this.shift),_t=St;return St.cmp(this.m)>=0?_t=St.isub(this.m):St.cmpn(0)<0&&(_t=St.iadd(this.m)),_t._forceRed(this)},c0.prototype.invm=function(dt){var yt=this.imod(dt._invmp(this.m).mul(this.r2));return yt._forceRed(this)}})(c,commonjsGlobal)})(bn);var bnExports=bn.exports,BN$3=bnExports,Buffer$3=safeBufferExports$1.Buffer;function withPublic$2(c,a){return Buffer$3.from(c.toRed(BN$3.mont(a.modulus)).redPow(new BN$3(a.publicExponent)).fromRed().toArray())}var withPublic_1=withPublic$2,parseKeys$1=parseAsn1,randomBytes$1=browserExports,createHash$1=browser$9,mgf$1=mgf$2,xor$1=xor$2,BN$2=bnExports,withPublic$1=withPublic_1,crt$1=browserifyRsa,Buffer$2=safeBufferExports$1.Buffer,publicEncrypt=function c(a,d,et){var nt;a.padding?nt=a.padding:et?nt=1:nt=4;var tt=parseKeys$1(a),bt;if(nt===4)bt=oaep$1(tt,d);else if(nt===1)bt=pkcs1$1(tt,d,et);else if(nt===3){if(bt=new BN$2(d),bt.cmp(tt.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return et?crt$1(bt,tt):withPublic$1(bt,tt)};function oaep$1(c,a){var d=c.modulus.byteLength(),et=a.length,nt=createHash$1("sha1").update(Buffer$2.alloc(0)).digest(),tt=nt.length,bt=2*tt;if(et>d-bt-2)throw new Error("message too long");var mt=Buffer$2.alloc(d-et-bt-2),vt=d-tt-1,$t=randomBytes$1(tt),At=xor$1(Buffer$2.concat([nt,mt,Buffer$2.alloc(1,1),a],vt),mgf$1($t,vt)),Mt=xor$1($t,mgf$1(At,tt));return new BN$2(Buffer$2.concat([Buffer$2.alloc(1),Mt,At],d))}function pkcs1$1(c,a,d){var et=a.length,nt=c.modulus.byteLength();if(et>nt-11)throw new Error("message too long");var tt;return d?tt=Buffer$2.alloc(nt-et-3,255):tt=nonZero(nt-et-3),new BN$2(Buffer$2.concat([Buffer$2.from([0,d?1:2]),tt,Buffer$2.alloc(1),a],nt))}function nonZero(c){for(var a=Buffer$2.allocUnsafe(c),d=0,et=randomBytes$1(c*2),nt=0,tt;dbt||new BN$1(d).cmp(tt.modulus)>=0)throw new Error("decryption error");var mt;et?mt=withPublic(new BN$1(d),tt):mt=crt(d,tt);var vt=Buffer$1.alloc(bt-mt.length);if(mt=Buffer$1.concat([vt,mt],bt),nt===4)return oaep(tt,mt);if(nt===1)return pkcs1(tt,mt,et);if(nt===3)return mt;throw new Error("unknown padding")};function oaep(c,a){var d=c.modulus.byteLength(),et=createHash("sha1").update(Buffer$1.alloc(0)).digest(),nt=et.length;if(a[0]!==0)throw new Error("decryption error");var tt=a.slice(1,nt+1),bt=a.slice(nt+1),mt=xor(tt,mgf(bt,nt)),vt=xor(bt,mgf(mt,d-nt-1));if(compare(et,vt.slice(0,nt)))throw new Error("decryption error");for(var $t=nt;vt[$t]===0;)$t++;if(vt[$t++]!==1)throw new Error("decryption error");return vt.slice($t)}function pkcs1(c,a,d){for(var et=a.slice(0,2),nt=2,tt=0;a[nt++]!==0;)if(nt>=a.length){tt++;break}var bt=a.slice(2,nt-1);if((et.toString("hex")!=="0002"&&!d||et.toString("hex")!=="0001"&&d)&&tt++,bt.length<8&&tt++,tt)throw new Error("decryption error");return a.slice(nt)}function compare(c,a){c=Buffer$1.from(c),a=Buffer$1.from(a);var d=0,et=c.length;c.length!==a.length&&(d++,et=Math.min(c.length,a.length));for(var nt=-1;++ntkMaxUint32||c<0)throw new TypeError("offset must be a uint32");if(c>kBufferMaxLength||c>a)throw new RangeError("offset out of range")}function assertSize$2(c,a,d){if(typeof c!="number"||c!==c)throw new TypeError("size must be a number");if(c>kMaxUint32||c<0)throw new TypeError("size must be a uint32");if(c+a>d||c>kBufferMaxLength)throw new RangeError("buffer too small")}crypto$2&&crypto$2.getRandomValues||!dist$2.process.browser?(browser.randomFill=randomFill,browser.randomFillSync=randomFillSync):(browser.randomFill=oldBrowser,browser.randomFillSync=oldBrowser);function randomFill(c,a,d,et){if(!Buffer.isBuffer(c)&&!(c instanceof commonjsGlobal.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof a=="function")et=a,a=0,d=c.length;else if(typeof d=="function")et=d,d=c.length-a;else if(typeof et!="function")throw new TypeError('"cb" argument must be a function');return assertOffset(a,c.length),assertSize$2(d,a,c.length),actualFill(c,a,d,et)}function actualFill(c,a,d,et){if(dist$2.process.browser){var nt=c.buffer,tt=new Uint8Array(nt,a,d);if(crypto$2.getRandomValues(tt),et){dist$2.process.nextTick(function(){et(null,c)});return}return c}if(et){randombytes(d,function(mt,vt){if(mt)return et(mt);vt.copy(c,a),et(null,c)});return}var bt=randombytes(d);return bt.copy(c,a),c}function randomFillSync(c,a,d){if(typeof a>"u"&&(a=0),!Buffer.isBuffer(c)&&!(c instanceof commonjsGlobal.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return assertOffset(a,c.length),d===void 0&&(d=c.length-a),assertSize$2(d,a,c.length),actualFill(c,a,d)}var hasRequiredCryptoBrowserify;function requireCryptoBrowserify(){if(hasRequiredCryptoBrowserify)return cryptoBrowserify;hasRequiredCryptoBrowserify=1,cryptoBrowserify.randomBytes=cryptoBrowserify.rng=cryptoBrowserify.pseudoRandomBytes=cryptoBrowserify.prng=browserExports,cryptoBrowserify.createHash=cryptoBrowserify.Hash=browser$9,cryptoBrowserify.createHmac=cryptoBrowserify.Hmac=browser$8;var c=algos,a=Object.keys(c),d=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(a);cryptoBrowserify.getHashes=function(){return d};var et=browser$7;cryptoBrowserify.pbkdf2=et.pbkdf2,cryptoBrowserify.pbkdf2Sync=et.pbkdf2Sync;var nt=browser$6;cryptoBrowserify.Cipher=nt.Cipher,cryptoBrowserify.createCipher=nt.createCipher,cryptoBrowserify.Cipheriv=nt.Cipheriv,cryptoBrowserify.createCipheriv=nt.createCipheriv,cryptoBrowserify.Decipher=nt.Decipher,cryptoBrowserify.createDecipher=nt.createDecipher,cryptoBrowserify.Decipheriv=nt.Decipheriv,cryptoBrowserify.createDecipheriv=nt.createDecipheriv,cryptoBrowserify.getCiphers=nt.getCiphers,cryptoBrowserify.listCiphers=nt.listCiphers;var tt=requireBrowser$2();cryptoBrowserify.DiffieHellmanGroup=tt.DiffieHellmanGroup,cryptoBrowserify.createDiffieHellmanGroup=tt.createDiffieHellmanGroup,cryptoBrowserify.getDiffieHellman=tt.getDiffieHellman,cryptoBrowserify.createDiffieHellman=tt.createDiffieHellman,cryptoBrowserify.DiffieHellman=tt.DiffieHellman;var bt=requireBrowser$1();cryptoBrowserify.createSign=bt.createSign,cryptoBrowserify.Sign=bt.Sign,cryptoBrowserify.createVerify=bt.createVerify,cryptoBrowserify.Verify=bt.Verify,cryptoBrowserify.createECDH=requireBrowser();var mt=browser$1;cryptoBrowserify.publicEncrypt=mt.publicEncrypt,cryptoBrowserify.privateEncrypt=mt.privateEncrypt,cryptoBrowserify.publicDecrypt=mt.publicDecrypt,cryptoBrowserify.privateDecrypt=mt.privateDecrypt;var vt=browser;return cryptoBrowserify.randomFill=vt.randomFill,cryptoBrowserify.randomFillSync=vt.randomFillSync,cryptoBrowserify.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(` +`))},cryptoBrowserify.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},cryptoBrowserify}var cryptoBrowserifyExports=requireCryptoBrowserify();const index$1=getDefaultExportFromCjs(cryptoBrowserifyExports),nodeCrypto=_mergeNamespaces({__proto__:null,default:index$1},[cryptoBrowserifyExports]);/*! noble-secp256k1 - MIT License (c) 2019 Paul Miller (paulmillr.com) */const _0n$2=BigInt(0),_1n$2=BigInt(1),_2n$2=BigInt(2),_3n=BigInt(3),_8n=BigInt(8),CURVE=Object.freeze({a:_0n$2,b:BigInt(7),P:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),n:BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),h:_1n$2,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee")}),divNearest=(c,a)=>(c+a/_2n$2)/a,endo={beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar(c){const{n:a}=CURVE,d=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),et=-_1n$2*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),nt=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),tt=d,bt=BigInt("0x100000000000000000000000000000000"),mt=divNearest(tt*c,a),vt=divNearest(-et*c,a);let $t=mod(c-mt*d-vt*nt,a),At=mod(-mt*et-vt*tt,a);const Mt=$t>bt,Tt=At>bt;if(Mt&&($t=a-$t),Tt&&(At=a-At),$t>bt||At>bt)throw new Error("splitScalarEndo: Endomorphism failed, k="+c);return{k1neg:Mt,k1:$t,k2neg:Tt,k2:At}}},fieldLen=32,groupLen=32,hashLen=32,compressedLen=fieldLen+1,uncompressedLen=2*fieldLen+1;function weierstrass(c){const{a,b:d}=CURVE,et=mod(c*c),nt=mod(et*c);return mod(nt+a*c+d)}const USE_ENDOMORPHISM=CURVE.a===_0n$2;class ShaError extends Error{constructor(a){super(a)}}function assertJacPoint(c){if(!(c instanceof JacobianPoint))throw new TypeError("JacobianPoint expected")}class JacobianPoint{constructor(a,d,et){this.x=a,this.y=d,this.z=et}static fromAffine(a){if(!(a instanceof Point$1))throw new TypeError("JacobianPoint#fromAffine: expected Point");return a.equals(Point$1.ZERO)?JacobianPoint.ZERO:new JacobianPoint(a.x,a.y,_1n$2)}static toAffineBatch(a){const d=invertBatch(a.map(et=>et.z));return a.map((et,nt)=>et.toAffine(d[nt]))}static normalizeZ(a){return JacobianPoint.toAffineBatch(a).map(JacobianPoint.fromAffine)}equals(a){assertJacPoint(a);const{x:d,y:et,z:nt}=this,{x:tt,y:bt,z:mt}=a,vt=mod(nt*nt),$t=mod(mt*mt),At=mod(d*$t),Mt=mod(tt*vt),Tt=mod(mod(et*mt)*$t),Rt=mod(mod(bt*nt)*vt);return At===Mt&&Tt===Rt}negate(){return new JacobianPoint(this.x,mod(-this.y),this.z)}double(){const{x:a,y:d,z:et}=this,nt=mod(a*a),tt=mod(d*d),bt=mod(tt*tt),mt=a+tt,vt=mod(_2n$2*(mod(mt*mt)-nt-bt)),$t=mod(_3n*nt),At=mod($t*$t),Mt=mod(At-_2n$2*vt),Tt=mod($t*(vt-Mt)-_8n*bt),Rt=mod(_2n$2*d*et);return new JacobianPoint(Mt,Tt,Rt)}add(a){assertJacPoint(a);const{x:d,y:et,z:nt}=this,{x:tt,y:bt,z:mt}=a;if(tt===_0n$2||bt===_0n$2)return this;if(d===_0n$2||et===_0n$2)return a;const vt=mod(nt*nt),$t=mod(mt*mt),At=mod(d*$t),Mt=mod(tt*vt),Tt=mod(mod(et*mt)*$t),Rt=mod(mod(bt*nt)*vt),kt=mod(Mt-At),It=mod(Rt-Tt);if(kt===_0n$2)return It===_0n$2?this.double():JacobianPoint.ZERO;const Dt=mod(kt*kt),Nt=mod(kt*Dt),Ot=mod(At*Dt),Ut=mod(It*It-Nt-_2n$2*Ot),Gt=mod(It*(Ot-Ut)-Tt*Nt),Wt=mod(nt*mt*kt);return new JacobianPoint(Ut,Gt,Wt)}subtract(a){return this.add(a.negate())}multiplyUnsafe(a){const d=JacobianPoint.ZERO;if(typeof a=="bigint"&&a===_0n$2)return d;let et=normalizeScalar(a);if(et===_1n$2)return this;if(!USE_ENDOMORPHISM){let Mt=d,Tt=this;for(;et>_0n$2;)et&_1n$2&&(Mt=Mt.add(Tt)),Tt=Tt.double(),et>>=_1n$2;return Mt}let{k1neg:nt,k1:tt,k2neg:bt,k2:mt}=endo.splitScalar(et),vt=d,$t=d,At=this;for(;tt>_0n$2||mt>_0n$2;)tt&_1n$2&&(vt=vt.add(At)),mt&_1n$2&&($t=$t.add(At)),At=At.double(),tt>>=_1n$2,mt>>=_1n$2;return nt&&(vt=vt.negate()),bt&&($t=$t.negate()),$t=new JacobianPoint(mod($t.x*endo.beta),$t.y,$t.z),vt.add($t)}precomputeWindow(a){const d=USE_ENDOMORPHISM?128/a+1:256/a+1,et=[];let nt=this,tt=nt;for(let bt=0;bt>=Mt,kt>vt&&(kt-=At,a+=_1n$2);const It=Rt,Dt=Rt+Math.abs(kt)-1,Nt=Tt%2!==0,Ot=kt<0;kt===0?bt=bt.add(constTimeNegate(Nt,nt[It])):tt=tt.add(constTimeNegate(Ot,nt[Dt]))}return{p:tt,f:bt}}multiply(a,d){let et=normalizeScalar(a),nt,tt;if(USE_ENDOMORPHISM){const{k1neg:bt,k1:mt,k2neg:vt,k2:$t}=endo.splitScalar(et);let{p:At,f:Mt}=this.wNAF(mt,d),{p:Tt,f:Rt}=this.wNAF($t,d);At=constTimeNegate(bt,At),Tt=constTimeNegate(vt,Tt),Tt=new JacobianPoint(mod(Tt.x*endo.beta),Tt.y,Tt.z),nt=At.add(Tt),tt=Mt.add(Rt)}else{const{p:bt,f:mt}=this.wNAF(et,d);nt=bt,tt=mt}return JacobianPoint.normalizeZ([nt,tt])[0]}toAffine(a){const{x:d,y:et,z:nt}=this,tt=this.equals(JacobianPoint.ZERO);a==null&&(a=tt?_8n:invert(nt));const bt=a,mt=mod(bt*bt),vt=mod(mt*bt),$t=mod(d*mt),At=mod(et*vt),Mt=mod(nt*bt);if(tt)return Point$1.ZERO;if(Mt!==_1n$2)throw new Error("invZ was invalid");return new Point$1($t,At)}}JacobianPoint.BASE=new JacobianPoint(CURVE.Gx,CURVE.Gy,_1n$2);JacobianPoint.ZERO=new JacobianPoint(_0n$2,_1n$2,_0n$2);function constTimeNegate(c,a){const d=a.negate();return c?d:a}const pointPrecomputes=new WeakMap;let Point$1=class _n{constructor(a,d){this.x=a,this.y=d}_setWindowSize(a){this._WINDOW_SIZE=a,pointPrecomputes.delete(this)}hasEvenY(){return this.y%_2n$2===_0n$2}static fromCompressedHex(a){const d=a.length===32,et=bytesToNumber$1(d?a:a.subarray(1));if(!isValidFieldElement(et))throw new Error("Point is not on curve");const nt=weierstrass(et);let tt=sqrtMod(nt);const bt=(tt&_1n$2)===_1n$2;d?bt&&(tt=mod(-tt)):(a[0]&1)===1!==bt&&(tt=mod(-tt));const mt=new _n(et,tt);return mt.assertValidity(),mt}static fromUncompressedHex(a){const d=bytesToNumber$1(a.subarray(1,fieldLen+1)),et=bytesToNumber$1(a.subarray(fieldLen+1,fieldLen*2+1)),nt=new _n(d,et);return nt.assertValidity(),nt}static fromHex(a){const d=ensureBytes(a),et=d.length,nt=d[0];if(et===fieldLen)return this.fromCompressedHex(d);if(et===compressedLen&&(nt===2||nt===3))return this.fromCompressedHex(d);if(et===uncompressedLen&&nt===4)return this.fromUncompressedHex(d);throw new Error(`Point.fromHex: received invalid point. Expected 32-${compressedLen} compressed bytes or ${uncompressedLen} uncompressed bytes, not ${et}`)}static fromPrivateKey(a){return _n.BASE.multiply(normalizePrivateKey(a))}static fromSignature(a,d,et){const{r:nt,s:tt}=normalizeSignature$2(d);if(![0,1,2,3].includes(et))throw new Error("Cannot recover: invalid recovery bit");const bt=truncateHash(ensureBytes(a)),{n:mt}=CURVE,vt=et===2||et===3?nt+mt:nt,$t=invert(vt,mt),At=mod(-bt*$t,mt),Mt=mod(tt*$t,mt),Tt=et&1?"03":"02",Rt=_n.fromHex(Tt+numTo32bStr(vt)),kt=_n.BASE.multiplyAndAddUnsafe(Rt,At,Mt);if(!kt)throw new Error("Cannot recover signature: point at infinify");return kt.assertValidity(),kt}toRawBytes(a=!1){return hexToBytes$2(this.toHex(a))}toHex(a=!1){const d=numTo32bStr(this.x);return a?`${this.hasEvenY()?"02":"03"}${d}`:`04${d}${numTo32bStr(this.y)}`}toHexX(){return this.toHex(!0).slice(2)}toRawX(){return this.toRawBytes(!0).slice(1)}assertValidity(){const a="Point is not on elliptic curve",{x:d,y:et}=this;if(!isValidFieldElement(d)||!isValidFieldElement(et))throw new Error(a);const nt=mod(et*et),tt=weierstrass(d);if(mod(nt-tt)!==_0n$2)throw new Error(a)}equals(a){return this.x===a.x&&this.y===a.y}negate(){return new _n(this.x,mod(-this.y))}double(){return JacobianPoint.fromAffine(this).double().toAffine()}add(a){return JacobianPoint.fromAffine(this).add(JacobianPoint.fromAffine(a)).toAffine()}subtract(a){return this.add(a.negate())}multiply(a){return JacobianPoint.fromAffine(this).multiply(a,this).toAffine()}multiplyAndAddUnsafe(a,d,et){const nt=JacobianPoint.fromAffine(this),tt=d===_0n$2||d===_1n$2||this!==_n.BASE?nt.multiplyUnsafe(d):nt.multiply(d),bt=JacobianPoint.fromAffine(a).multiplyUnsafe(et),mt=tt.add(bt);return mt.equals(JacobianPoint.ZERO)?void 0:mt.toAffine()}};Point$1.BASE=new Point$1(CURVE.Gx,CURVE.Gy);Point$1.ZERO=new Point$1(_0n$2,_0n$2);function sliceDER(c){return Number.parseInt(c[0],16)>=8?"00"+c:c}function parseDERInt(c){if(c.length<2||c[0]!==2)throw new Error(`Invalid signature integer tag: ${bytesToHex$2(c)}`);const a=c[1],d=c.subarray(2,a+2);if(!a||d.length!==a)throw new Error("Invalid signature integer: wrong length");if(d[0]===0&&d[1]<=127)throw new Error("Invalid signature integer: trailing length");return{data:bytesToNumber$1(d),left:c.subarray(a+2)}}function parseDERSignature(c){if(c.length<2||c[0]!=48)throw new Error(`Invalid signature tag: ${bytesToHex$2(c)}`);if(c[1]!==c.length-2)throw new Error("Invalid signature: incorrect length");const{data:a,left:d}=parseDERInt(c.subarray(2)),{data:et,left:nt}=parseDERInt(d);if(nt.length)throw new Error(`Invalid signature: left bytes after parsing: ${bytesToHex$2(nt)}`);return{r:a,s:et}}let Signature$2=class $o{constructor(a,d){this.r=a,this.s=d,this.assertValidity()}static fromCompact(a){const d=a instanceof Uint8Array,et="Signature.fromCompact";if(typeof a!="string"&&!d)throw new TypeError(`${et}: Expected string or Uint8Array`);const nt=d?bytesToHex$2(a):a;if(nt.length!==128)throw new Error(`${et}: Expected 64-byte hex`);return new $o(hexToNumber$1(nt.slice(0,64)),hexToNumber$1(nt.slice(64,128)))}static fromDER(a){const d=a instanceof Uint8Array;if(typeof a!="string"&&!d)throw new TypeError("Signature.fromDER: Expected string or Uint8Array");const{r:et,s:nt}=parseDERSignature(d?a:hexToBytes$2(a));return new $o(et,nt)}static fromHex(a){return this.fromDER(a)}assertValidity(){const{r:a,s:d}=this;if(!isWithinCurveOrder(a))throw new Error("Invalid Signature: r must be 0 < r < n");if(!isWithinCurveOrder(d))throw new Error("Invalid Signature: s must be 0 < s < n")}hasHighS(){const a=CURVE.n>>_1n$2;return this.s>a}normalizeS(){return this.hasHighS()?new $o(this.r,mod(-this.s,CURVE.n)):this}toDERRawBytes(){return hexToBytes$2(this.toDERHex())}toDERHex(){const a=sliceDER(numberToHexUnpadded(this.s)),d=sliceDER(numberToHexUnpadded(this.r)),et=a.length/2,nt=d.length/2,tt=numberToHexUnpadded(et),bt=numberToHexUnpadded(nt);return`30${numberToHexUnpadded(nt+et+4)}02${bt}${d}02${tt}${a}`}toRawBytes(){return this.toDERRawBytes()}toHex(){return this.toDERHex()}toCompactRawBytes(){return hexToBytes$2(this.toCompactHex())}toCompactHex(){return numTo32bStr(this.r)+numTo32bStr(this.s)}};function concatBytes$2(...c){if(!c.every(et=>et instanceof Uint8Array))throw new Error("Uint8Array list expected");if(c.length===1)return c[0];const a=c.reduce((et,nt)=>et+nt.length,0),d=new Uint8Array(a);for(let et=0,nt=0;eta.toString(16).padStart(2,"0"));function bytesToHex$2(c){if(!(c instanceof Uint8Array))throw new Error("Expected Uint8Array");let a="";for(let d=0;d0)return BigInt(c);if(typeof c=="bigint"&&isWithinCurveOrder(c))return c;throw new TypeError("Expected valid private scalar: 0 < scalar < curve.n")}function mod(c,a=CURVE.P){const d=c%a;return d>=_0n$2?d:a+d}function pow2(c,a){const{P:d}=CURVE;let et=c;for(;a-- >_0n$2;)et*=et,et%=d;return et}function sqrtMod(c){const{P:a}=CURVE,d=BigInt(6),et=BigInt(11),nt=BigInt(22),tt=BigInt(23),bt=BigInt(44),mt=BigInt(88),vt=c*c*c%a,$t=vt*vt*c%a,At=pow2($t,_3n)*$t%a,Mt=pow2(At,_3n)*$t%a,Tt=pow2(Mt,_2n$2)*vt%a,Rt=pow2(Tt,et)*Tt%a,kt=pow2(Rt,nt)*Rt%a,It=pow2(kt,bt)*kt%a,Dt=pow2(It,mt)*It%a,Nt=pow2(Dt,bt)*kt%a,Ot=pow2(Nt,_3n)*$t%a,Ut=pow2(Ot,tt)*Rt%a,Gt=pow2(Ut,d)*vt%a,Wt=pow2(Gt,_2n$2);if(Wt*Wt%a!==c)throw new Error("Cannot find square root");return Wt}function invert(c,a=CURVE.P){if(c===_0n$2||a<=_0n$2)throw new Error(`invert: expected positive integers, got n=${c} mod=${a}`);let d=mod(c,a),et=a,nt=_0n$2,tt=_1n$2;for(;d!==_0n$2;){const mt=et/d,vt=et%d,$t=nt-tt*mt;et=d,d=vt,nt=tt,tt=$t}if(et!==_1n$2)throw new Error("invert: does not exist");return mod(nt,a)}function invertBatch(c,a=CURVE.P){const d=new Array(c.length),et=c.reduce((tt,bt,mt)=>bt===_0n$2?tt:(d[mt]=tt,mod(tt*bt,a)),_1n$2),nt=invert(et,a);return c.reduceRight((tt,bt,mt)=>bt===_0n$2?tt:(d[mt]=mod(tt*d[mt],a),mod(tt*bt,a)),nt),d}function bits2int_2(c){const a=c.length*8-groupLen*8,d=bytesToNumber$1(c);return a>0?d>>BigInt(a):d}function truncateHash(c,a=!1){const d=bits2int_2(c);if(a)return d;const{n:et}=CURVE;return d>=et?d-et:d}let _sha256Sync,_hmacSha256Sync;class HmacDrbg{constructor(a,d){if(this.hashLen=a,this.qByteLen=d,typeof a!="number"||a<2)throw new Error("hashLen must be a number");if(typeof d!="number"||d<2)throw new Error("qByteLen must be a number");this.v=new Uint8Array(a).fill(1),this.k=new Uint8Array(a).fill(0),this.counter=0}hmac(...a){return utils$2.hmacSha256(this.k,...a)}hmacSync(...a){return _hmacSha256Sync(this.k,...a)}checkSync(){if(typeof _hmacSha256Sync!="function")throw new ShaError("hmacSha256Sync needs to be set")}incr(){if(this.counter>=1e3)throw new Error("Tried 1,000 k values for sign(), all were invalid");this.counter+=1}async reseed(a=new Uint8Array){this.k=await this.hmac(this.v,Uint8Array.from([0]),a),this.v=await this.hmac(this.v),a.length!==0&&(this.k=await this.hmac(this.v,Uint8Array.from([1]),a),this.v=await this.hmac(this.v))}reseedSync(a=new Uint8Array){this.checkSync(),this.k=this.hmacSync(this.v,Uint8Array.from([0]),a),this.v=this.hmacSync(this.v),a.length!==0&&(this.k=this.hmacSync(this.v,Uint8Array.from([1]),a),this.v=this.hmacSync(this.v))}async generate(){this.incr();let a=0;const d=[];for(;a0)a=BigInt(c);else if(typeof c=="string"){if(c.length!==2*groupLen)throw new Error("Expected 32 bytes of private key");a=hexToNumber$1(c)}else if(c instanceof Uint8Array){if(c.length!==groupLen)throw new Error("Expected 32 bytes of private key");a=bytesToNumber$1(c)}else throw new TypeError("Expected valid private key");if(!isWithinCurveOrder(a))throw new Error("Expected private key: 0 < key < n");return a}function normalizePublicKey(c){return c instanceof Point$1?(c.assertValidity(),c):Point$1.fromHex(c)}function normalizeSignature$2(c){if(c instanceof Signature$2)return c.assertValidity(),c;try{return Signature$2.fromDER(c)}catch{return Signature$2.fromCompact(c)}}function getPublicKey(c,a=!1){return Point$1.fromPrivateKey(c).toRawBytes(a)}function recoverPublicKey(c,a,d,et=!1){return Point$1.fromSignature(c,a,d).toRawBytes(et)}function isProbPub(c){const a=c instanceof Uint8Array,d=typeof c=="string",et=(a||d)&&c.length;return a?et===compressedLen||et===uncompressedLen:d?et===compressedLen*2||et===uncompressedLen*2:c instanceof Point$1}function getSharedSecret(c,a,d=!1){if(isProbPub(c))throw new TypeError("getSharedSecret: first arg must be private key");if(!isProbPub(a))throw new TypeError("getSharedSecret: second arg must be public key");const et=normalizePublicKey(a);return et.assertValidity(),et.multiply(normalizePrivateKey(c)).toRawBytes(d)}function bits2int(c){const a=c.length>fieldLen?c.slice(0,fieldLen):c;return bytesToNumber$1(a)}function bits2octets(c){const a=bits2int(c),d=mod(a,CURVE.n);return int2octets(d<_0n$2?a:d)}function int2octets(c){return numTo32b(c)}function initSigArgs(c,a,d){if(c==null)throw new Error(`sign: expected valid message hash, not "${c}"`);const et=ensureBytes(c),nt=normalizePrivateKey(a),tt=[int2octets(nt),bits2octets(et)];if(d!=null){d===!0&&(d=utils$2.randomBytes(fieldLen));const vt=ensureBytes(d);if(vt.length!==fieldLen)throw new Error(`sign: Expected ${fieldLen} bytes of extra data`);tt.push(vt)}const bt=concatBytes$2(...tt),mt=bits2int(et);return{seed:bt,m:mt,d:nt}}function finalizeSig(c,a){const{sig:d,recovery:et}=c,{der:nt,recovered:tt}=Object.assign({canonical:!0,der:!0},a),bt=nt?d.toDERRawBytes():d.toCompactRawBytes();return tt?[bt,et]:bt}function signSync(c,a,d={}){const{seed:et,m:nt,d:tt}=initSigArgs(c,a,d.extraEntropy),bt=new HmacDrbg(hashLen,groupLen);bt.reseedSync(et);let mt;for(;!(mt=kmdToSig(bt.generateSync(),nt,tt,d.canonical));)bt.reseedSync();return finalizeSig(mt,d)}Point$1.BASE._setWindowSize(8);const crypto$1={node:nodeCrypto,web:typeof self=="object"&&"crypto"in self?self.crypto:void 0},TAGGED_HASH_PREFIXES={},utils$2={bytesToHex:bytesToHex$2,hexToBytes:hexToBytes$2,concatBytes:concatBytes$2,mod,invert,isValidPrivateKey(c){try{return normalizePrivateKey(c),!0}catch{return!1}},_bigintTo32Bytes:numTo32b,_normalizePrivateKey:normalizePrivateKey,hashToPrivateKey:c=>{c=ensureBytes(c);const a=groupLen+8;if(c.length1024)throw new Error("Expected valid bytes of private key as per FIPS 186");const d=mod(bytesToNumber$1(c),CURVE.n-_1n$2)+_1n$2;return numTo32b(d)},randomBytes:(c=32)=>{if(crypto$1.web)return crypto$1.web.getRandomValues(new Uint8Array(c));if(crypto$1.node){const{randomBytes:a}=crypto$1.node;return Uint8Array.from(a(c))}else throw new Error("The environment doesn't have randomBytes function")},randomPrivateKey:()=>utils$2.hashToPrivateKey(utils$2.randomBytes(groupLen+8)),precompute(c=8,a=Point$1.BASE){const d=a===Point$1.BASE?a:new Point$1(a.x,a.y);return d._setWindowSize(c),d.multiply(_3n),d},sha256:async(...c)=>{if(crypto$1.web){const a=await crypto$1.web.subtle.digest("SHA-256",concatBytes$2(...c));return new Uint8Array(a)}else if(crypto$1.node){const{createHash:a}=crypto$1.node,d=a("sha256");return c.forEach(et=>d.update(et)),Uint8Array.from(d.digest())}else throw new Error("The environment doesn't have sha256 function")},hmacSha256:async(c,...a)=>{if(crypto$1.web){const d=await crypto$1.web.subtle.importKey("raw",c,{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),et=concatBytes$2(...a),nt=await crypto$1.web.subtle.sign("HMAC",d,et);return new Uint8Array(nt)}else if(crypto$1.node){const{createHmac:d}=crypto$1.node,et=d("sha256",c);return a.forEach(nt=>et.update(nt)),Uint8Array.from(et.digest())}else throw new Error("The environment doesn't have hmac-sha256 function")},sha256Sync:void 0,hmacSha256Sync:void 0,taggedHash:async(c,...a)=>{let d=TAGGED_HASH_PREFIXES[c];if(d===void 0){const et=await utils$2.sha256(Uint8Array.from(c,nt=>nt.charCodeAt(0)));d=concatBytes$2(et,et),TAGGED_HASH_PREFIXES[c]=d}return utils$2.sha256(d,...a)},taggedHashSync:(c,...a)=>{if(typeof _sha256Sync!="function")throw new ShaError("sha256Sync is undefined, you need to set it");let d=TAGGED_HASH_PREFIXES[c];if(d===void 0){const et=_sha256Sync(Uint8Array.from(c,nt=>nt.charCodeAt(0)));d=concatBytes$2(et,et),TAGGED_HASH_PREFIXES[c]=d}return _sha256Sync(d,...a)},_JacobianPoint:JacobianPoint};Object.defineProperties(utils$2,{sha256Sync:{configurable:!1,get(){return _sha256Sync},set(c){_sha256Sync||(_sha256Sync=c)}},hmacSha256Sync:{configurable:!1,get(){return _hmacSha256Sync},set(c){_hmacSha256Sync||(_hmacSha256Sync=c)}}});const ZeroAddress="0x0000000000000000000000000000000000000000",ZeroHash="0x0000000000000000000000000000000000000000000000000000000000000000",BN_0$7=BigInt(0),BN_1$2=BigInt(1),BN_2$2=BigInt(2),BN_27$1=BigInt(27),BN_28$1=BigInt(28),BN_35$1=BigInt(35),_guard$1={};function toUint256(c){return zeroPadValue(toBeArray(c),32)}var bs,ms,ys,Qn,Hr;let Signature$1=(Hr=class{constructor(a,d,et,nt){q0(this,bs,void 0);q0(this,ms,void 0);q0(this,ys,void 0);q0(this,Qn,void 0);assertPrivate(a,_guard$1,"Signature"),m0(this,bs,d),m0(this,ms,et),m0(this,ys,nt),m0(this,Qn,null)}get r(){return s0(this,bs)}set r(a){assertArgument(dataLength(a)===32,"invalid r","value",a),m0(this,bs,hexlify$1(a))}get s(){return s0(this,ms)}set s(a){assertArgument(dataLength(a)===32,"invalid s","value",a);const d=hexlify$1(a);assertArgument(parseInt(d.substring(0,3))<8,"non-canonical s","value",d),m0(this,ms,d)}get v(){return s0(this,ys)}set v(a){const d=getNumber(a,"value");assertArgument(d===27||d===28,"invalid v","v",a),m0(this,ys,d)}get networkV(){return s0(this,Qn)}get legacyChainId(){const a=this.networkV;return a==null?null:Hr.getChainId(a)}get yParity(){return this.v===27?0:1}get yParityAndS(){const a=getBytes(this.s);return this.yParity&&(a[0]|=128),hexlify$1(a)}get compactSerialized(){return concat$3([this.r,this.yParityAndS])}get serialized(){return concat$3([this.r,this.s,this.yParity?"0x1c":"0x1b"])}[Symbol.for("nodejs.util.inspect.custom")](){return`Signature { r: "${this.r}", s: "${this.s}", yParity: ${this.yParity}, networkV: ${this.networkV} }`}clone(){const a=new Hr(_guard$1,this.r,this.s,this.v);return this.networkV&&m0(a,Qn,this.networkV),a}toJSON(){const a=this.networkV;return{_type:"signature",networkV:a!=null?a.toString():null,r:this.r,s:this.s,v:this.v}}static getChainId(a){const d=getBigInt(a,"v");return d==BN_27$1||d==BN_28$1?BN_0$7:(assertArgument(d>=BN_35$1,"invalid EIP-155 v","v",a),(d-BN_35$1)/BN_2$2)}static getChainIdV(a,d){return getBigInt(a)*BN_2$2+BigInt(35+d-27)}static getNormalizedV(a){const d=getBigInt(a);return d===BN_0$7||d===BN_27$1?27:d===BN_1$2||d===BN_28$1?28:(assertArgument(d>=BN_35$1,"invalid v","v",a),d&BN_1$2?27:28)}static from(a){function d($t,At){assertArgument($t,At,"signature",a)}if(a==null)return new Hr(_guard$1,ZeroHash,ZeroHash,27);if(typeof a=="string"){const $t=getBytes(a,"signature");if($t.length===64){const At=hexlify$1($t.slice(0,32)),Mt=$t.slice(32,64),Tt=Mt[0]&128?28:27;return Mt[0]&=127,new Hr(_guard$1,At,hexlify$1(Mt),Tt)}if($t.length===65){const At=hexlify$1($t.slice(0,32)),Mt=$t.slice(32,64);d((Mt[0]&128)===0,"non-canonical s");const Tt=Hr.getNormalizedV($t[64]);return new Hr(_guard$1,At,hexlify$1(Mt),Tt)}d(!1,"invalid raw signature length")}if(a instanceof Hr)return a.clone();const et=a.r;d(et!=null,"missing r");const nt=toUint256(et),tt=function($t,At){if($t!=null)return toUint256($t);if(At!=null){d(isHexString$1(At,32),"invalid yParityAndS");const Mt=getBytes(At);return Mt[0]&=127,hexlify$1(Mt)}d(!1,"missing s")}(a.s,a.yParityAndS);d((getBytes(tt)[0]&128)==0,"non-canonical s");const{networkV:bt,v:mt}=function($t,At,Mt){if($t!=null){const Tt=getBigInt($t);return{networkV:Tt>=BN_35$1?Tt:void 0,v:Hr.getNormalizedV(Tt)}}if(At!=null)return d(isHexString$1(At,32),"invalid yParityAndS"),{v:getBytes(At)[0]&128?28:27};if(Mt!=null){switch(getNumber(Mt,"sig.yParity")){case 0:return{v:27};case 1:return{v:28}}d(!1,"invalid yParity")}d(!1,"missing v")}(a.v,a.yParityAndS,a.yParity),vt=new Hr(_guard$1,nt,tt,mt);return bt&&m0(vt,Qn,bt),d(a.yParity==null||getNumber(a.yParity,"sig.yParity")===vt.yParity,"yParity mismatch"),d(a.yParityAndS==null||a.yParityAndS===vt.yParityAndS,"yParityAndS mismatch"),vt}},bs=new WeakMap,ms=new WeakMap,ys=new WeakMap,Qn=new WeakMap,Hr);utils$2.hmacSha256Sync=function(c,...a){return getBytes(computeHmac$1("sha256",c,concat$3(a)))};var yn,Mn;let SigningKey$1=(Mn=class{constructor(a){q0(this,yn,void 0);assertArgument(dataLength(a)===32,"invalid private key","privateKey","[REDACTED]"),m0(this,yn,hexlify$1(a))}get privateKey(){return s0(this,yn)}get publicKey(){return Mn.computePublicKey(s0(this,yn))}get compressedPublicKey(){return Mn.computePublicKey(s0(this,yn),!0)}sign(a){assertArgument(dataLength(a)===32,"invalid digest length","digest",a);const[d,et]=signSync(getBytesCopy(a),getBytesCopy(s0(this,yn)),{recovered:!0,canonical:!0}),nt=Signature$2.fromHex(d);return Signature$1.from({r:toBeHex("0x"+nt.r.toString(16),32),s:toBeHex("0x"+nt.s.toString(16),32),v:et?28:27})}computeSharedSecret(a){const d=Mn.computePublicKey(a);return hexlify$1(getSharedSecret(getBytesCopy(s0(this,yn)),getBytes(d)))}static computePublicKey(a,d){let et=getBytes(a,"key");if(et.length===32){const tt=getPublicKey(et,!!d);return hexlify$1(tt)}if(et.length===64){const tt=new Uint8Array(65);tt[0]=4,tt.set(et,1),et=tt}const nt=Point$1.fromHex(et);return hexlify$1(nt.toRawBytes(d))}static recoverPublicKey(a,d){assertArgument(dataLength(a)===32,"invalid digest length","digest",a);const et=Signature$1.from(d),nt=Signature$2.fromCompact(getBytesCopy(concat$3([et.r,et.s]))).toDERRawBytes(),tt=recoverPublicKey(getBytesCopy(a),nt,et.yParity);return assertArgument(tt!=null,"invalid signature for digest","signature",d),hexlify$1(tt)}static addPoints(a,d,et){const nt=Point$1.fromHex(Mn.computePublicKey(a).substring(2)),tt=Point$1.fromHex(Mn.computePublicKey(d).substring(2));return"0x"+nt.add(tt).toHex(!!et)}},yn=new WeakMap,Mn);const BN_0$6=BigInt(0),BN_36=BigInt(36);function getChecksumAddress$1(c){c=c.toLowerCase();const a=c.substring(2).split(""),d=new Uint8Array(40);for(let nt=0;nt<40;nt++)d[nt]=a[nt].charCodeAt(0);const et=getBytes(keccak256$3(d));for(let nt=0;nt<40;nt+=2)et[nt>>1]>>4>=8&&(a[nt]=a[nt].toUpperCase()),(et[nt>>1]&15)>=8&&(a[nt+1]=a[nt+1].toUpperCase());return"0x"+a.join("")}const ibanLookup$1={};for(let c=0;c<10;c++)ibanLookup$1[String(c)]=String(c);for(let c=0;c<26;c++)ibanLookup$1[String.fromCharCode(65+c)]=String(10+c);const safeDigits$1=15;function ibanChecksum$1(c){c=c.toUpperCase(),c=c.substring(4)+c.substring(0,2)+"00";let a=c.split("").map(et=>ibanLookup$1[et]).join("");for(;a.length>=safeDigits$1;){let et=a.substring(0,safeDigits$1);a=parseInt(et,10)%97+a.substring(et.length)}let d=String(98-parseInt(a,10)%97);for(;d.length<2;)d="0"+d;return d}const Base36=function(){const c={};for(let a=0;a<36;a++){const d="0123456789abcdefghijklmnopqrstuvwxyz"[a];c[d]=BigInt(a)}return c}();function fromBase36(c){c=c.toLowerCase();let a=BN_0$6;for(let d=0;da.format()).join(",")})`:this.type}defaultValue(){return 0}minValue(){return 0}maxValue(){return 0}isBigInt(){return!!this.type.match(/^u?int[0-9]+$/)}isData(){return this.type.startsWith("bytes")}isString(){return this.type==="string"}get tupleName(){if(this.type!=="tuple")throw TypeError("not a tuple");return s0(this,Xn)}get arrayLength(){if(this.type!=="array")throw TypeError("not an array");return s0(this,Xn)===!0?-1:s0(this,Xn)===!1?this.value.length:null}static from(a,d){return new ln(_gaurd,a,d)}static uint8(a){return n(a,8)}static uint16(a){return n(a,16)}static uint24(a){return n(a,24)}static uint32(a){return n(a,32)}static uint40(a){return n(a,40)}static uint48(a){return n(a,48)}static uint56(a){return n(a,56)}static uint64(a){return n(a,64)}static uint72(a){return n(a,72)}static uint80(a){return n(a,80)}static uint88(a){return n(a,88)}static uint96(a){return n(a,96)}static uint104(a){return n(a,104)}static uint112(a){return n(a,112)}static uint120(a){return n(a,120)}static uint128(a){return n(a,128)}static uint136(a){return n(a,136)}static uint144(a){return n(a,144)}static uint152(a){return n(a,152)}static uint160(a){return n(a,160)}static uint168(a){return n(a,168)}static uint176(a){return n(a,176)}static uint184(a){return n(a,184)}static uint192(a){return n(a,192)}static uint200(a){return n(a,200)}static uint208(a){return n(a,208)}static uint216(a){return n(a,216)}static uint224(a){return n(a,224)}static uint232(a){return n(a,232)}static uint240(a){return n(a,240)}static uint248(a){return n(a,248)}static uint256(a){return n(a,256)}static uint(a){return n(a,256)}static int8(a){return n(a,-8)}static int16(a){return n(a,-16)}static int24(a){return n(a,-24)}static int32(a){return n(a,-32)}static int40(a){return n(a,-40)}static int48(a){return n(a,-48)}static int56(a){return n(a,-56)}static int64(a){return n(a,-64)}static int72(a){return n(a,-72)}static int80(a){return n(a,-80)}static int88(a){return n(a,-88)}static int96(a){return n(a,-96)}static int104(a){return n(a,-104)}static int112(a){return n(a,-112)}static int120(a){return n(a,-120)}static int128(a){return n(a,-128)}static int136(a){return n(a,-136)}static int144(a){return n(a,-144)}static int152(a){return n(a,-152)}static int160(a){return n(a,-160)}static int168(a){return n(a,-168)}static int176(a){return n(a,-176)}static int184(a){return n(a,-184)}static int192(a){return n(a,-192)}static int200(a){return n(a,-200)}static int208(a){return n(a,-208)}static int216(a){return n(a,-216)}static int224(a){return n(a,-224)}static int232(a){return n(a,-232)}static int240(a){return n(a,-240)}static int248(a){return n(a,-248)}static int256(a){return n(a,-256)}static int(a){return n(a,-256)}static bytes1(a){return b(a,1)}static bytes2(a){return b(a,2)}static bytes3(a){return b(a,3)}static bytes4(a){return b(a,4)}static bytes5(a){return b(a,5)}static bytes6(a){return b(a,6)}static bytes7(a){return b(a,7)}static bytes8(a){return b(a,8)}static bytes9(a){return b(a,9)}static bytes10(a){return b(a,10)}static bytes11(a){return b(a,11)}static bytes12(a){return b(a,12)}static bytes13(a){return b(a,13)}static bytes14(a){return b(a,14)}static bytes15(a){return b(a,15)}static bytes16(a){return b(a,16)}static bytes17(a){return b(a,17)}static bytes18(a){return b(a,18)}static bytes19(a){return b(a,19)}static bytes20(a){return b(a,20)}static bytes21(a){return b(a,21)}static bytes22(a){return b(a,22)}static bytes23(a){return b(a,23)}static bytes24(a){return b(a,24)}static bytes25(a){return b(a,25)}static bytes26(a){return b(a,26)}static bytes27(a){return b(a,27)}static bytes28(a){return b(a,28)}static bytes29(a){return b(a,29)}static bytes30(a){return b(a,30)}static bytes31(a){return b(a,31)}static bytes32(a){return b(a,32)}static address(a){return new ln(_gaurd,"address",a)}static bool(a){return new ln(_gaurd,"bool",!!a)}static bytes(a){return new ln(_gaurd,"bytes",a)}static string(a){return new ln(_gaurd,"string",a)}static array(a,d){throw new Error("not implemented yet")}static tuple(a,d){throw new Error("not implemented yet")}static overrides(a){return new ln(_gaurd,"overrides",Object.assign({},a))}static isTyped(a){return a&&typeof a=="object"&&"_typedSymbol"in a&&a._typedSymbol===_typedSymbol}static dereference(a,d){if(ln.isTyped(a)){if(a.type!==d)throw new Error(`invalid type: expecetd ${d}, got ${a.type}`);return a.value}return a}};Xn=new WeakMap;let Typed=ln;class AddressCoder extends Coder{constructor(a){super("address","address",a,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(a,d){let et=Typed.dereference(d,"string");try{et=getAddress$2(et)}catch(nt){return this._throwError(nt.message,d)}return a.writeValue(et)}decode(a){return getAddress$2(toBeHex(a.readValue(),20))}}class AnonymousCoder extends Coder{constructor(d){super(d.name,d.type,"_",d.dynamic);G0(this,"coder");this.coder=d}defaultValue(){return this.coder.defaultValue()}encode(d,et){return this.coder.encode(d,et)}decode(d){return this.coder.decode(d)}}function pack(c,a,d){let et=[];if(Array.isArray(d))et=d;else if(d&&typeof d=="object"){let vt={};et=a.map($t=>{const At=$t.localName;return assert$y(At,"cannot encode object for signature with missing names","INVALID_ARGUMENT",{argument:"values",info:{coder:$t},value:d}),assert$y(!vt[At],"cannot encode object for signature with duplicate names","INVALID_ARGUMENT",{argument:"values",info:{coder:$t},value:d}),vt[At]=!0,d[At]})}else assertArgument(!1,"invalid tuple value","tuple",d);assertArgument(a.length===et.length,"types/value length mismatch","tuple",d);let nt=new Writer,tt=new Writer,bt=[];a.forEach((vt,$t)=>{let At=et[$t];if(vt.dynamic){let Mt=tt.length;vt.encode(tt,At);let Tt=nt.writeUpdatableValue();bt.push(Rt=>{Tt(Rt+Mt)})}else vt.encode(nt,At)}),bt.forEach(vt=>{vt(nt.length)});let mt=c.appendWriter(nt);return mt+=c.appendWriter(tt),mt}function unpack(c,a){let d=[],et=[],nt=c.subReader(0);return a.forEach(tt=>{let bt=null;if(tt.dynamic){let mt=c.readIndex(),vt=nt.subReader(mt);try{bt=tt.decode(vt)}catch($t){if(isError$1($t,"BUFFER_OVERRUN"))throw $t;bt=$t,bt.baseType=tt.name,bt.name=tt.localName,bt.type=tt.type}}else try{bt=tt.decode(c)}catch(mt){if(isError$1(mt,"BUFFER_OVERRUN"))throw mt;bt=mt,bt.baseType=tt.name,bt.name=tt.localName,bt.type=tt.type}if(bt==null)throw new Error("investigate");d.push(bt),et.push(tt.localName||null)}),Result.fromItems(d,et)}class ArrayCoder extends Coder{constructor(d,et,nt){const tt=d.type+"["+(et>=0?et:"")+"]",bt=et===-1||d.dynamic;super("array",tt,nt,bt);G0(this,"coder");G0(this,"length");defineProperties(this,{coder:d,length:et})}defaultValue(){const d=this.coder.defaultValue(),et=[];for(let nt=0;ntbt||nt<-(bt+BN_1$1))&&this._throwError("value out-of-bounds",et),nt=toTwos(nt,8*WordSize)}else(ntmask(tt,this.size*8))&&this._throwError("value out-of-bounds",et);return d.writeValue(nt)}decode(d){let et=mask(d.readValue(),this.size*8);return this.signed&&(et=fromTwos(et,this.size*8)),et}}class StringCoder extends DynamicBytesCoder{constructor(a){super("string",a)}defaultValue(){return""}encode(a,d){return super.encode(a,toUtf8Bytes$1(Typed.dereference(d,"string")))}decode(a){return toUtf8String(super.decode(a))}}class TupleCoder extends Coder{constructor(d,et){let nt=!1;const tt=[];d.forEach(mt=>{mt.dynamic&&(nt=!0),tt.push(mt.type)});const bt="tuple("+tt.join(",")+")";super("tuple",bt,et,nt);G0(this,"coders");defineProperties(this,{coders:Object.freeze(d.slice())})}defaultValue(){const d=[];this.coders.forEach(nt=>{d.push(nt.defaultValue())});const et=this.coders.reduce((nt,tt)=>{const bt=tt.localName;return bt&&(nt[bt]||(nt[bt]=0),nt[bt]++),nt},{});return this.coders.forEach((nt,tt)=>{let bt=nt.localName;!bt||et[bt]!==1||(bt==="length"&&(bt="_length"),d[bt]==null&&(d[bt]=d[tt]))}),Object.freeze(d)}encode(d,et){const nt=Typed.dereference(et,"tuple");return pack(d,this.coders,nt)}decode(d){return unpack(d,this.coders)}}function id$2(c){return keccak256$3(toUtf8Bytes$1(c))}function decode_arithmetic(c){let a=0;function d(){return c[a++]<<8|c[a++]}let et=d(),nt=1,tt=[0,1];for(let Wt=1;Wt>--vt&1}const Mt=31,Tt=2**Mt,Rt=Tt>>>1,kt=Rt>>1,It=Tt-1;let Dt=0;for(let Wt=0;Wt1;){let c0=Xt+a0>>>1;Wt>>1|At(),n0=n0<<1^Rt,t0=(t0^Rt)<<1|Rt|1;Ot=n0,Ut=1+t0-n0}let Gt=et-4;return Nt.map(Wt=>{switch(Wt-Gt){case 3:return Gt+65792+(c[mt++]<<16|c[mt++]<<8|c[mt++]);case 2:return Gt+256+(c[mt++]<<8|c[mt++]);case 1:return Gt+c[mt++];default:return Wt-1}})}function read_payload(c){let a=0;return()=>c[a++]}function read_compressed_payload(c){return read_payload(decode_arithmetic(unsafe_atob(c)))}function unsafe_atob(c){let a=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach((nt,tt)=>a[nt.charCodeAt(0)]=tt);let d=c.length,et=new Uint8Array(6*d>>3);for(let nt=0,tt=0,bt=0,mt=0;nt=8&&(et[tt++]=mt>>(bt-=8));return et}function signed(c){return c&1?~c>>1:c>>1}function read_deltas(c,a){let d=Array(c);for(let et=0,nt=0;et{let a=read_sorted(c);if(a.length)return a})}function read_mapped(c){let a=[];for(;;){let d=c();if(d==0)break;a.push(read_linear_table(d,c))}for(;;){let d=c()-1;if(d<0)break;a.push(read_replacement_table(d,c))}return a.flat()}function read_array_while(c){let a=[];for(;;){let d=c(a.length);if(!d)break;a.push(d)}return a}function read_transposed(c,a,d){let et=Array(c).fill().map(()=>[]);for(let nt=0;ntet[bt].push(tt));return et}function read_linear_table(c,a){let d=1+a(),et=a(),nt=read_array_while(a);return read_transposed(nt.length,1+c,a).flatMap((bt,mt)=>{let[vt,...$t]=bt;return Array(nt[mt]).fill().map((At,Mt)=>{let Tt=Mt*et;return[vt+Mt*d,$t.map(Rt=>Rt+Tt)]})})}function read_replacement_table(c,a){let d=1+a();return read_transposed(d,1+c,a).map(nt=>[nt[0],nt.slice(1)])}var r$1=read_compressed_payload("AEgSbwjEDVYByQKaAQsBOQDpATQAngDUAHsAoABoANQAagCNAEQAhABMAHIAOwA9ACsANgAmAGIAHgAvACgAJwAXAC0AGgAjAB8ALwAUACkAEgAeAAkAGwARABkAFgA5ACgALQArADcAFQApABAAHgAiABAAGAAeABMAFwAXAA0ADgAWAA8AFAAVBFsF1QEXE0o3xAXUALIArkABaACmAgPGAK6AMDAwMAE/qAYK7P4HQAblMgVYBVkAPSw5Afa3EgfJwgAPA8meNALGCjACjqIChtk/j2+KAsXMAoPzASDgCgDyrgFCAi6OCkCQAOQA4woWABjVuskNDD6eBBx4AP4COhi+D+wKBirqBgSCaA0cBy4ArABqku+mnIAAXAaUJAbqABwAPAyUFvyp/Mo8INAIvCoDshQ8APcubKQAon4ZABgEJtgXAR4AuhnOBPsKIE04CZgJiR8cVlpM5INDABQADQAWAA9sVQAiAA8ASO8W2T30OVnKluYvChEeX05ZPe0AFAANABYAD2wgXUCYAMPsABwAOgzGFryp/AHauQVcBeMC0KACxLEKTR2kZhR0Gm5M9gC8DmgC4gAMLjSKF8qSAoF8ARMcAL4OaALiAAwuAUlQJpJMCwMt/AUpCthqGK4B2EQAciwSeAIyFiIDKCi6OGwAOuIB9iYAyA7MtgEcZIIAsgYABgCK1EoFHNZsGACoKNIBogAAAAAAKy4DnABoAQoaPu43dQQZGACrAcgCIgDgLBJ0OvRQsTOiKDVJBfsoBVoFWbC5BWo7XkITO1hCmHuUZmCh+QwUA8YIJvJ4JASkTAJUVAJ2HKwoAZCkpjZcA0YYBIRiCgDSBqxAMCQHKgI6XgBsAWIgcgCEHhoAlgFKuAAoahgBsMYDOC4iRFQBcFoGZgJmAPJKGAMqAgYASkIArABeAHQALLYGCPTwGo6AAAAKIgAqALQcSAHSAdwIDDKXeYHpAAsAEgA1AD4AOTR3etTBEGAQXQJNCkxtOxUMAq0PpwvmERYM0irM09kANKoH7ANUB+wDVANUB+wH7ANUB+wDVANUA1QDVBwL8BvUwRBgD0kEbgWPBYwE1wiEJkoRggcpCNNUDnQfHEgDRgD9IyZJHTuUMwwlQ0wNTQQH/TZDbKh9OQNIMaxU9pCjA8wyUDltAh5yEqEAKw90HTW2Tn96SHGhCkxPr7WASWNOaAK/Oqk/+QoiCZRvvHdPBj4QGCeiEPQMMAGyATgN6kvVBO4GOATGH3oZFg/KlZkIoi3aDOom4C6egFcj8iqABepL8TzaC0pRZQ9WC2IJ4DpggUsDHgEKIogK2g02CGoQ8ArGaA3iEUIHNgPSSZcAogb+Cw4dMhWyJg1iqQsGOXQG+BrzC4wmrBMmevkF0BoeBkoBJhr8AMwu5IWtWi5cGU9cBgALIiPEFKVQHQ0iQLR4RRoYBxIlpgKOQ21KhFEzHpAh8zw6DWMuEFF5B/I8AhlMC348m0aoRQsRzz6KPUUiRkwpBDJ8LCwniAnMD4IMtnxvAVYJHgmuDG4TLhEUN8IINgcWKpchJxIIHkaSYJcE9JwD8BPOAwgFPAk+BxADshwqEysVJgUKgSHUAvA20i6wAoxWfQEUBcgPIh/cEE1H3Q7mCJgCYgOAJegAKhUeABQimAhAYABcj9VTAi7ICMRqaSNxA2QU5F4RcAeODlQHpBwwFbwc3nDFXgiGBSigrAlYAXIJlgFcBOAIBjVYjJ0gPmdQi1UYmCBeQTxd+QIuDGIVnES6h3UCiA9oEhgBMgFwBzYM/gJ0EeoRaBCSCOiGATWyM/U6IgRMIYAgDgokA0xsywskJvYM9WYBoBJfAwk0OnfrZ6hgsyEX+gcWMsJBXSHuC49PygyZGr4YP1QrGeEHvAPwGvAn50FUBfwDoAAQOkoz6wS6C2YIiAk8AEYOoBQH1BhnCm6MzQEuiAG0lgNUjoACbIwGNAcIAGQIhAV24gAaAqQIoAACAMwDVAA2AqoHmgAWAII+AToDJCwBHuICjAOQCC7IAZIsAfAmBBjADBIA9DRuRwLDrgKAZ2afBdpVAosCRjIBSiIEAktETgOsbt4A2ABIBhDcRAESqEfIF+BAAdxsKADEAPgAAjIHAj4BygHwagC0AVwLLgmfsLIBSuYmAIAAEmgB1AKGANoAMgB87gFQAEoFVvYF0AJMRgEOLhUoVF4BuAMcATABCgB2BsiKosYEHARqB9ACEBgV3gLvKweyAyLcE8pCwgK921IAMhMKNQqkCqNgWF0wAy5vPU0ACx+lPsQ/SwVOO1A7VTtQO1U7UDtVO1A7VTtQO1UDlLzfvN8KaV9CYegMow3RRMU6RhPYYE5gLxPFLbQUvhXLJVMZOhq5JwIl4VUGDwEt0GYtCCk0che5ADwpZYM+Y4MeLQpIHORTjlT1LRgArkufM6wNqRsSRD0FRHXqYicWCwofAmR+AmI/WEqsWDcdAqH0AmiVAmYGAp+BOBgIAmY4AmYjBGsEfAN/EAN+jzkDOXQUOX86ICACbBoCMjM4BwJtxAJtq+yHMGRCKAFkANsA3gBHAgeVDIoA+wi/AAqyAncsAnafPAJ5SEACeLcaWdhFq0bwAnw8AnrFAn0GAnztR/1IemAhACgSSVVKWBIUSskC0P4C0MlLJAOITAOH40TCkS8C8p5dAAMDq0vLTCoiAMxNSU2sAos8AorVvhgEGkBkArQCjjQCjlk9lH4CjtYCjll1UbFTMgdS0VSCApP4ApMJAOYAGVUbVaxVzQMsGCmSgzLeeGNFODYCl5wC769YHqUAViIClowClnmZAKZZqVoGfkoAOAKWsgKWS1xBXM4CmcgCmWFcx10EFgKcmDm/OpoCnBMCn5gCnrWHABoMLicMAp3uAp6PALI6YTFh7AKe0AKgawGmAp6cHAKeS6JjxWQkIigCJ6wCJnsCoPgCoEnUAqYsAqXLAqf8AHoCp+9oeWiuAABGahlqzgKs4AKsqwKtZAKs/wJXGgJV2QKx3tQDH0tslAKyugoCsuUUbN1tYG1FXAMlygK2WTg8bo0DKUICuFsCuUQSArkndHAzcN4CvRYDLa8DMg4CvoVx/wMzbgK+F3Mfc0wCw8gCwwFzf3RIMkJ03QM8pAM8lwM9vALFeQLGRALGDYYCyGZOAshBAslMAskrAmSaAt3PeHZeeKt5IkvNAxigZv8CYfEZ8JUhewhej164DgLPaALPaSxIUM/wEJwAw6oCz3ABJucDTg9+SAIC3CQC24cC0kwDUlkDU1wA/gNViYCGPMgT6l1CcoLLg4oC2sQC2duEDYRGpzkDhqIALANkC4ZuVvYAUgLfYgLetXB0AuIs7REB8y0kAfSYAfLPhALr8ALpbXYC6vYC6uEA9kQBtgLuhgLrmZanlwAC7jwDhd2YdnDdcZ4C8wAAZgOOE5mQAvcQA5FrA5KEAveVAvnWAvhjmhmaqLg0mxsDnYAC/vcBGAA2nxmfsAMFigOmZwOm1gDOwgMGZ6GFogIGAwxGAQwBHAdqBl62ZAIAuARovA6IHrAKABRyNgAgAzASSgOGfAFgJB4AjOwAHgDmoAScjgi0BhygwgCoBRK86h4+PxZ5BWk4P0EsQiJCtV9yEl+9AJbGBTMAkE0am7o7J2AzErrQDjAYxxiKyfcFWAVZBVgFWQVkBVkFWAVZBVgFWQVYBVkFWAVZRxYI2IZoAwMDCmVe6iwEygOyBjC8vAC8BKi8AOhBKhazBUc+aj5xQkBCt192OF/pAFgSM6wAjP/MbMv9puhGez4nJAUsFyg3Nn5u32vB8hnDLGoBbNdvMRgFYAVrycLJuQjQSlwBAQEKfV5+jL8AND+CAAQW0gbmriQGAIzEDAMCDgDlZh4+JSBLQrJCvUI5JF8oYDcoOSQJwj4KRT9EPnk+gj5xPnICikK9SkM8X8xPUGtOCy1sVTBrDG8gX+E0OxwJaJwKYyQsPR4nQqxCvSzMAsv9X8oPIC8KCQoAACN+nt9rOy5LGMmsya0JZsLMzQphQWAP5hCkEgCTjh5GQiYbqm06zjkKND9EPnFCQBwICx5NSG1cLS5a4rwTCn7uHixCQBxeCUsKDzRVREM4BTtEnC0KghwuQkAb9glUIyQZMTIBBo9i8F8KcmTKYAxgLiRvAERgGjoDHB9gtAcDbBFmT2BOEgIAZOhgFmCWYH5gtGBMYJJpFhgGtg/cVqq8WwtDF6wBvCzOwgMgFgEdBB8BegJtMDGWU4EBiwq5SBsA5SR0jwvLDqdN6wGcAoidUAVBYAD4AD4LATUXWHsMpg0lILuwSABQDTUAFhO4NVUC0wxLZhEcANlPBnYECx9bADIAtwKbKAsWcKwzOaAaAVwBhwn9A9ruEAarBksGugAey1aqWwq7YhOKCy1ADrwBvAEjA0hbKSkpIR8gIi0TJwciDY4AVQJvWJFKlgJvIA9ySAHUdRDPUiEaqrFN6wcSBU1gAPgAPgsBewAHJW0LiAymOTEuyLBXDgwAYL0MAGRKaFAiIhzAADIAtwKbKC08D88CkRh8ULxYyXRzjtilnA72mhU+G+0S2hIHDxwByAk7EJQGESwNNwwAPAC0zwEDAKUA4gCbizAAFQBcG8cvbXcrDsIRAzwlRNTiHR8MG34CfATCC6vxbQA4Oi4Opzkuz6IdB7wKABA7Ls8SGgB9rNsdD7wbSBzOoncfAT4qYB0C7KAJBE3z5R9mDL0M+wg9Cj8ABcELPgJMDbwIvQ09CT0KvS7PoisOvAaYAhwPjBriBBwLvBY8AKELPBC8BRihe90AO2wMPQACpwm9BRzR9QYFB2/LBnwAB7wSXBISvQECAOsCAAB1FVwHFswV/HAXvBg8AC68AuyovAAevAJWISuAAAG8AALkFT0VvCvso7zJqDwEAp8nTAACXADn3hm8CaVcD7/FAPUafAiiBQv/cQDfvKe8GNwavKOMeXMG/KmchAASvAcbDAADlABtvAcAC7ynPAIaPLsIopzLDvwHwak8AOF8L7dtvwNJAAPsABW8AAb8AAm8AGmMABq8AA68Axi8jmoV/AABXAAObAAuTB8ABrwAF7wIIgANSwC6vCcAA7wADpwq7ACyWwAcHAAbvAAB7AqiAAXHCxYV3AAHnABCvAEDAGm8AAt8AB28AAi8CaIABcsAbqAZ1gCSCCIABcsAATwAB9wAHZwIIgAGmwAJfAAbLABtHADmvIEACFwACDwAFLwAaPwJIgAGywDjjAAJPAuiDsX7YAAHPABunUBJAEgACrwFAAM8AAmuAzgABxwAGXwAAgym/AAKHAAKPAAJ/KfsBrwACRwAAwwAEDwBABQ8ABFsAA+MAA3sAA28ABkMBxYcABU8AG6cFrQBvAC7ABM8BABpLAsA4UwAAjwABFMAF3wFHAAG0QAYvB8BfClTADpGALAJBw4McwApK3EBpQYIXwJtJA0ACghwTG1gK4oggRVjLjcDogq1AALZABcC/ARvAXdzSFMVIgNQAhY/AS0GBHRHvnxTe0EAKgAyAvwAVAvcAHyRLQEsAHfmDhIzRwJLAFgGAAJRAQiLzQB5PAQhpgBbANcWAJZpOCCMAM5ssgDQ1RcJw3Z0HBlXHgrSAYmRrCNUVE5JEz3DivoAgB04QSos4RKYUABzASosMSlDGhADMVYE+MbvAExm3QBrAnICQBF7Osh4LzXWBhETIAUVCK6v/xPNACYAAQIbAIYAiQCONgDjALQA1QCdPQC7AKsApgChAOcAnwDTAJwA4AEBAPwAwAB6AFsAywDNAPwA1wDrAIkAogEqAOMA2ADVBAIIKzTT09PTtb/bzM/NQjEWAUsBVS5GAVMBYgFhAVQBRUpCRGcMAUwUBgkEMzcMBwAgDSQmKCs3OTk8PDw9Pg0/HVBQUFBSUlFSKFNUVlVVHFxgYF9hYCNlZ29ucXFxcXFxc3Nzc3Nzc3Nzc3N1dXZ1dFsAPesAQgCTAHEAKwBf8QCHAFAAUAAwAm/oAIT+8fEAXQCM6wCYAEgAWwBd+PipAH4AfgBiAE8AqgAdAK8AfAI5AjwA9QDgAPcA9wDhAPgA4gDiAOEA3wAoAnQBSgE5ATcBTQE3ATcBNwEyATEBMQExARUBURAAKgkBAEwYCxcEFhcPAIcAjwCfAEoAYxkCKgBvAGgAkAMOAyArAxpCP0gqAIoCSADAAlACnQC5Ao8CjwKPAo8CjwKPAoQCjwKPAo8CjwKPAo8CjgKOApECmQKQAo8CjwKNAo0CjQKNAosCjgJuAc0CkAKYAo8CjwKOF3oMAPcGA5gCWgIzGAFNETYC2xILLBQBRzgUTpIBdKU9AWJaAP4DOkgA/wCSKh4ZkGsAKmEAagAvAIoDlcyM8K+FWwa7LA/DEgKe1nUrCwQkWwGzAN5/gYB/gX+Cg4N/hIeFf4aJh4GIg4mDin+Lf4x/jYuOf49/kIORf5J/k3+Uf5WElomXg5h/AIMloQCEBDwEOQQ7BD4EPARCBD8EOgRABEIEQQQ9BD8EQgCkA4gAylIA0AINAPdbAPcBGgD3APUA9QD2APXVhSRmvwD3APUA9QD2APUdAIpbAPcAigEaAPcAigLtAPcAitWFJGa/HQD4WwEaAPcA9wD1APUA9gD1APgA9QD1APYA9dWFJGa/HQCKWwEaAPcAigD3AIoC7QD3AIrVhSRmvx0CRAE3AksBOgJMwgOfAu0Dn9WFJGa/HQCKWwEaA58AigOfAIoC7QOfAIrVhSRmvx0EMQCKBDIAigeOMm4hLQCKAT9vBCQA/gDHWwMAVVv/FDMDAIoDPtkASgMAigMAl2dBtv/TrfLzakaPh3aztmIuZQrR3ER2n5Yo+qNR2jK/aP/V04UK1njIJXLgkab9PjOxyJDVbIN3R/FZLoZVl2kYFQIZ7V6LpRqGDt9OdDohnJKp5yX/HLj0voPpLrneDaN11t5W3sSM4ALscgSw8fyWLVkKa/cNcQmjYOgTLZUgOLi2F05g4TR0RfgZ4PBdntxdV3qvdxQt8DeaMMgjJMgwUxYN3tUNpUNx21AvwADDAIa0+raTWaoBXmShAl5AThpMi282o+WzOKMlxjHj7a+DI6AM6VI9w+xyh3Eyg/1XvPmbqjeg2MGXugHt8wW03DQMRTd5iqqOhjLvyOCcKtViGwAHVLyl86KqvxVX7MxSW8HLq6KCrLpB8SspAOHO9IuOwCh9poLoMEha9CHCxlRAXJNDobducWjqhFHqCkzjTM2V9CHslwq4iU19IxqhIFZMve15lDTiMVZIPdADXGxTqzSTv0dDWyk1ht430yvaYCy9qY0MQ3cC5c1uw4mHcTGkMHTAGC99TkNXFAiLQgw9ZWhwKJjGCe+J5FIaMpYhhyUnEgfrF3zEtzn40DdgCIJUJfZ0mo3eXsDwneJ8AYCr7Vx2eHFnt2H6ZEyAHs9JoQ4Lzh5zBoGOGwAz37NOPuqSNmZf51hBEovtpm2T1wI79OBWDyvCFYkONqAKGVYgIL0F+uxTcMLSPtFbiNDbBPFgip8MGDmLLHbSyGXdCMO6f7teiW9EEmorZ+75KzanZwvUySgjoUQBTfHlOIerJs6Y9wLlgDw18AB1ne0tZRNgGjcrqHbtubSUooEpy4hWpDzTSrmvqw0H9AoXQLolMt9eOM+l9RitBB1OBnrdC1XL4yLFyXqZSgZhv7FnnDEXLUeffb4nVDqYTLY6X7gHVaK4ZZlepja2Oe6OhLDI/Ve5SQTCmJdH3HJeb14cw99XsBQAlDy5s5kil2sGezZA3tFok2IsNja7QuFgM30Hff3NGSsSVFYZLOcTBOvlPx8vLhjJrSI7xrNMA/BOzpBIJrdR1+v+zw4RZ7ry6aq4/tFfvPQxQCPDsXlcRvIZYl+E5g3kJ+zLMZon0yElBvEOQTh6SaAdIO6BwdqJqfvgU+e8Y65FQhdiHkZMVt9/39N2jGd26J6cNjq8cQIyp6RonRPgVn2fl89uRDcQ27GacaN0MPrcNyRlbUWelKfDfyrNVVGBG5sjd3jXzTx06ywyzuWn5jbvEfPPCTbpClkgEu9oPLKICxU5HuDe3jA1XnvU85IYYhaEtOU1YVWYhEFsa4/TQj3rHdsU2da2eVbF8YjSI0m619/8bLMZu3xildwqM7zf1cjn4Whx0PSYXcY5bR7wEQfGC7CTOXwZdmsdTO8q3uGm7Rh/RfCWwpzBHCAaVfjxgibL5vUeL0pH6bzDmI9yCXKC/okkmbc28OJvI87L/bjFzpq0DHepw4kT1Od+fL7cyuFaRgfaUWB2++TCFvz11J0leEtrGkpccfX9z2LY39sph4PBHCjNOOkd0ybUm+ZzS8GkFbqMpq8uiX2yHpa0jllTLfGTDBMYR6FT5FWLLDPMkYxt1Q0eyMvxJWztDjy0m6VvZPvamrFXjHmPpU6WxrZqH6WW//I37RwvqPQhPz8I3RPuXAk1C94ZprQWm9iGM/KgiGDO6SV9sjp+Jmk4TBajMNJ5zzWZ1k1jrteQQBp9C2dOvmbIeeEME8y573Q8TgGe+ZCzutM45gYLBzYm2LNvgq2kebAbMpHRDSyh6dQ27GbsAAdCqQVVXWC1C+zpwBM2Lr4eqtobmmu1vJEDlIQR1iN8CUWpztq50z7FFQBn3SKViX6wSqzVQCoYvAjByjeSa+h1PRnYWvBinTDB9cHt4eqDsPS4jcD3FwXJKT0RQsl8EvslI2SFaz2OtmYLFV8FwgvWroZ3fKmh7btewX9tfL2upXsrsqpLJzpzNGyNlnuZyetg7DIOxQTMBR7dqlrTlZ6FWi1g4j1NSjA2j1Yd7fzTH6k9LxCyUCneAKYCU581bnvKih6KJTeTeCX4Zhme/QIz7w2o+AdSgtLAkdrLS9nfweYEqrMLsrGGSWXtgWamAWp6+x6GM/Z8jNw3BqPNQ39hrzYLECn3tPvh/LqKbRSCiDGauDKBBj/kGbpnM1Bb/my8hv4NWStclkwjfl57y4oNDgw1JAG9VOti3QVVoSziMEsSdfEjaCPIDb7SgpLXykQsM+nbqbt97I0mIlzWv0uqFobLMAq8Rd9pszUBKxFhBPwOjf//gVOz2r7URJ2OnpviCXv9iz3a4X/YLBYbXoYwxBv/Kq0a5s4utQHzoTerJ7PmFW/no/ZAsid/hRIV82tD+Qabh5F1ssIM8Ri3chu0PuPD3sSJRMjDoxLAbwUbroiPAz/V52e8s3DIixxlO7OrvhMj3qfzA0kKxzwicr5wJmZwJxTXgrwYsqhRvpgC2Nfdyd+TYYxJSZgk+gk2g9KyHSlwQVAyPtWWgvVGyVBqsU2LpDlLNosSAtolC1uBKt5pQZLhAxTjeGCWIC/HVpagc5rRwkgpCHKEsjA8d+scp8aiMewwQBhp5dYTV5t/Nvl+HbDMu8F3S0psPyZb1bSnqlHPFUnMQeQqSqwDBT23fJO9gO3aVaa1icrXU0PKwlMM5K+iL3ATcVq2fFWKk0irCTF4LDVDG4gUpkyplq6efcZS+WDR1woApjD18x+2JQR9oOXzuA7uy4b+/91WsJd/tSd1QcAH8PVPXApieA37B7YXPhDPH1azP3PKR+HfHmOoDYLeuKsIi/ssSsdYs62qJo14Hw1P2N/6zpr8F3FTWmJ4ysAVcl84Iv/tl///Z8FaAWbBQbyMNDZjrZ2JwdRjtd1jOeNumSodFtr4/Zf45iRJf/8HSW+KIB/+GlKu8Rv1BPLr/4duoL+kFPRqrstEr41gfJupoJRf4hcYDWX93FOcfEBiIivxtjtV8g7mvOReiamYWKE7vfPbv3v2L9Kwq3cIDFGLyhyfOGuf/9vA5muH6Pjg7B4SUj2ydDXra9fSBI+DrsNHA6l51wfHssJb+11TfNk7B8OleUe3Y+ZmHboMFHdv7FFP2cfISFyeAQR0sk/Xv62HBTdW4HmnGSLFk/cqyWVVFJkdIIa+4hos3JRHcqLoRKM5h2Qtk1RZtzISMtlXTfTqIc77YsCCgQD0r61jtxskCctwJOtjE/pL8wC4LBD4AZFjh2wzzFCrT/PNqW0/DeBbkfMfzVm9yy06WiF+1mTdNNEAytVtohBKg3brWd2VQa+aF+cQ0mW5CvbwOlWCT07liX226PjiVLwFCRs/Ax2/u+ZNPjrNFIWIPf5GjHyUKp60OeXe9F01f7IaPf/SDTvyDAf7LSWWejtiZcsqtWZjrdn6A2MqBwnSeKhrZOlUMmgMionmiCIvXqKZfmhGZ1MwD3uMF4n9KJcfWLA3cL5pq48tm5NDYNh3SS/TKUtmFSlQR89MR4+kxcqJgpGbhm9gXneDELkyqAN5nitmIzTscKeJRXqd64RiaOALR2d295NWwbjHRNG2AU5oR9OS2oJg/5CY6BFPc1JvD2Mxdhp2/MZdI8dLePxiP4KRIp8VXmqfg+jqd/RNG7GNuq1U2SiI4735Bdc0MVFx6mH5UOWEa5HuhYykd6t4M1gYLVS8m1B+9bUqi5DziQq7qT8d94cxB6AB4WqMCOF/zPPtRSZUUaMSsvHOWxGASufywTX8ogy6HgUf9p+Z30wUEosl8qgmwm6o2AV6nO9HKQjRHpN6SUegI5pvR61RLnUJ1lqCtmfcsRQutEizVpAaPXN7xMp5UQ5OSZK6tniCK9CpyMd7LjR6+MxfoMEDPpWdf2p2m5N3KO4QMxf+V7vGdYjemQczQ+m2MGIkFNYDMf0Yop2eSx81sP36WHUczqEhKysp2iJSYAvfgJjinKwToPvRKb+HBi+7cJ96S5ngfLOXaHAFRLkulo4TnXTFO51gX0TCCo4ZUHdbpdgkMEwUZAPjh6M+hA8DzycbtxAgH3uD6i0nN1aTiIuQ4BYCE9dEHHwAmINU+4YEWx4EC3OZwFGfYZMPLScVlb+BAAJeARUh+gdWA3/gRqCrf1jecgqeFf1MdzrrP4SVlGm5mMihSP+zYYksAB7O+SBPwNQqSNMiLnkviY/klwgcRmvqtCqeWeA0gjuir4CMZqmw/ntP6M+l0pdN8/P9xI53aP7x/zavJbbKOz8VzO/nXxIr1tjparMnqd6iWdByHKw4lF4p/u57Yv07WeZPDnRl7wgmDVZZ44fQsjdYO/gmXQ+940PRGst8UMQApFC4OOV22e4N+lVOPyFLAOj4t8R3PFw/FjbSWy0ELuAFReNkee8ORcBOT2NPDcs7OfpUmzvn/F9Czk9o9naMyVYy/j8I5qVFmQDFcptBp65J/+sJA3w/j6y/eqUkKxTsf0CZjtNdRSBEmJ2tmfgmJbqpcsSagk+Ul9qdyV+NnqFBIJZFCB1XwPvWGDBOjVUmpWGHsWA5uDuMgLUNKZ4vlq5qfzY1LnRhCc/mh5/EX+hzuGdDy5aYYx4BAdwTTeZHcZpl3X0YyuxZFWNE6wFNppYs3LcFJePOyfKZ8KYb7dmRyvDOcORLPH0sytC6mH1US3JVj6paYM1GEr+CUmyHRnabHPqLlh6Kl0/BWd3ebziDfvpRQpPoR7N+LkUeYWtQ6Rn5v5+NtNeBPs2+DKDlzEVR5aYbTVPrZekJsZ9UC9qtVcP99thVIt1GREnN8zXP8mBfzS+wKYym8fcW6KqrE702Zco+hFQAEIR7qimo7dd7wO8B7R+QZPTuCWm1UAwblDTyURSbd85P4Pz+wBpQyGPeEpsEvxxIZkKsyfSOUcfE3UqzMFwZKYijb7sOkzpou+tC4bPXey5GI1GUAg9c3vLwIwAhcdPHRsYvpAfzkZHWY20vWxxJO0lvKfj6sG2g/pJ1vd/X2EBZkyEjLN4nUZOpOO7MewyHCrxQK8d5aF7rCeQlFX+XksK6l6z971BPuJqwdjj68ULOj9ZTDdOLopMdOLL0PFSS792SXE/EC9EDnIXZGYhr52aQb+9b2zEdBSnpkxAdBUkwJDqGCpZk/HkRidjdp0zKv/Cm52EenmfeKX6HkLUJgMbTTxxIZkIeL/6xuAaAAHbA7mONVduTHNX/UJj1nJEaI7f3HlUyiqKn7VfBE+bdb4HWln1HPJx001Ulq1tOxFf8WZEARvq5Da1+pE7fPVxLntGACz3nkoLsKcPdUqdCwwiyWkmXTd5+bv3j7HaReRt3ESn783Ew3SWsvkEjKtbocNksbrLmV+GVZn1+Uneo35MT1/4r8fngQX5/ptORfgmWfF6KSB/ssJmUSijXxQqUpzkANEkSkYgYj560OOjJr6uqckFuO15TRNgABEwNDjus1V3q2huLPYERMCLXUNmJJpbMrUQsSO7Qnxta55TvPWL6gWmMOvFknqETzqzFVO8SVkovEdYatypLGmDy9VWfgAc0KyIChiOhbd7UlbAeVLPZyEDp4POXKBwN/KP5pT6Cyqs6yaI00vXMn1ubk9OWT9Q/O2t/C25qlnO/zO0xcBzpMBCAB8vsdsh3U8fnPX1XlPEWfaYJxKVaTUgfCESWl4CCkIyjE6iQ5JFcwU6S4/IH0/Agacp8d5Gzq2+GzPnJ7+sqk40mfFQpKrDbAKwLlr3ONEati2k/ycLMSUu7V/7BBkDlNyXoN9tvqXCbbMc4SSQXgC/DBUY9QjtrCtQ+susEomCq8xcNJNNMWCH31GtlTw2BdCXkJBjT+/QNWlBWwQ5SWCh1LdQ99QVii/DyTxjSR6rmdap3l3L3aiplQpPYlrzNm9er88fXd2+ao+YdUNjtqmxiVxmyYPzJxl67OokDcTezEGqldkGgPbRdXA+fGcuZVkembZByo7J1dMnkGNjwwCny+FNcVcWvWYL9mg8oF7jACVWI3bA64EXpdM8bSIEVIAs5JJH+LHXgnCsgcMGPZyAAVBncvbLiexzg9YozcytjPXVlAbQAC7Tc4S0C8QN4LlAGjj4pQAVWrwkaDoUYGxxvkCWKRRHkdzJB5zpREleBDL1oDKEvAqmkDibVC4kTqF89YO6laUjgtJPebBfzr16tg4t10GmN1sJ5vezk2sUOq8blCn5mPZyT3ltaDcddKupQjqusNM9wtFVD0ABzv17fZDn7GPT1nkCtdcgYejcK1qOcTGtPxnCX1rErEjVWCnEJv5HaOAUjgpiKQjUKkQi64D5g2COgwas8FcgIl0Pw95H9dWxE3QG0VbMNffh6BPlAojLDf4es2/5Xfq7hw5NGcON2g8Qsy2UQm94KddKyy3kdJxWgpNaEc15xcylbLC3vnT26u8qS90qc2MU8LdOJc5VPF5KnSpXIhnj1eJJ/jszjZ01oR6JDFJRoeTPO/wh4IPFbdG9KljuSzeuI92p8JF/bpgDE8wG86/W2EBKgPrmzdLijxssQn8mM44ky/KLGOJcrSwXIpZa/Z3v7W6HCRk7ewds99LTsUW1LbeJytw8Q/BFZVZyfO9BUHOCe2suuEkO8DU4fLX0IQSQ2TdOkKXDtPf3sNV9tYhYFueuPRhfQlEEy+aYM/MCz7diDNmFSswYYlZZPmKr2Q5AxLsSVEqqBtn6hVl1BCFOFExnqnIsmyY/NA8jXnDaNzr7Zv3hu+I1Mf/PJjk0gALN2G8ABzdf9FNvWHvZHhv6xIoDCXf964MxG92vGZtx/LYU5PeZqgly8tT5tGeQGeJzMMsJc5p+a5Rn2PtEhiRzo/5Owjy1n0Lzx3ev8GHQmeWb8vagG6O5Qk5nrZuQTiKODI4UqL0LLAusS2Ve7j1Ivdxquu1BR9Rc4QkOiUPwQXJv6du2E8i5pDhVoQpUhyMWGUT2O2YODIhjAfI71gxep5r5zAY7GBUZpy51hAw0pcCCrhOmU8Wp6ujQTdZQsCjtq6SHX8QAMNiPCIIkoxhHEZPgsBcOlP4aErJZPhF7qvx6gHrn8hEwPwYbx8YmT/n7lbcmTip1v8kgsrIjFTAlvLY4Nuil0KDmgz3svYs0ZJ3O3Is/vSx4xpxF1e2VAtZE8dJxGYEIhCSuPvCjP54l/NSNDnwlKvAW8mG+AQkgp7a87Igh26uKMFGD0PoPHTSvoWxiHuk+su8XkQiHIjeYKl/RdcOHpxhQH3zHCNE3aARm83Bl6zGxU/vMltlVPQhubcqhW4RYkl6uXk5JdP/QpzaKFpw2M8zvysv2qj7xaQECuu2akM0Cssj/uB9+wDR7uA6XOnLNaoczalHoMj33eiiu+DRaFsUmlmUZuh9bjDY4INMNSSAivSh03uJvny4Gj+D+neudoa7iJi7c4VFlZ/J5gUR82308zSNAt/ZroBXDWw0fV3eVPAn3aX0mtJabF6RsUZmL+Ehn+wn51/4QipMjD+6y64t7bjL6bjENan2prQ4h7++hBJ9NXvX8CUocJqMC937IasLzm5K0qwXeFMAimMHkEIQIQI2LrQ9sLBfXuyp66zWvlsh74GPv7Xpabj993pRNNDuFud5oIcn/92isbADXdpRPbjmbCNOrwRbxGZx2XmYNGMiV5kjF4IKyxCBvKier9U4uVoheCdmk83rp5G0PihAm2fAtczI4b9BWqX+nrZTrJX5kSwQddi93NQrXG+Cl3eBGNkM77VBsMpEolhXex1MVvMkZN9fG59GGbciH11FEXaY1MxrArovaSjE/lUUqBg2cZBNmiWbvzCHCPJ4RVGFK2dTbObM1m+gJyEX53fa7u3+TZpm74mNEzWbkVL4vjNwfL9uzRCu1cgbrNx5Yv5dDruNrIOgwIk+UZWwJfdbu/WHul6PMmRflVCIzd7B37Pgm/Up/NuCiQW7RXyafevN3AL6ycciCc4ZPlTRzEu+aURGlUBOJbUEsheX7PPyrrhdUt5JAG12EEEZpY/N3Vhbl5uLAfT0CbC2XmpnryFkxZmBTs5prvEeuf0bn73i3O82WTiQtJWEPLsBXnQmdnKhB06NbbhLtlTZYJMxDMJpFeajSNRDB2v61BMUHqXggUwRJ19m6p5zl51v11q34T74lTXdJURuV6+bg2D6qpfGnLy7KGLuLZngobM4pIouz4+n0/UzFKxDgLM4h+fUwKZozQ9UGrHjcif51Ruonz7oIVZ56xWtZS8z7u5zay6J2LD4gCYh2RXoBRLDKsUlZ80R8kmoxlJiL8aZCy2wCAonnucFxCLT1HKoMhbPKt34D97EXPPh0joO93iJVF1Uruew61Qoy3ZUVNX9uIJDt9AQWKLLo+mSzmTibyLHq0D6hhzpvgUgI6ekyVEL3FD+Fi5R3A8MRHPXspN1VyKkfRlC+OGiNgPC4NREZpFETgVmdXrQ2TxChuS3aY+Ndc7CiYv5+CmzfiqeZrWIQJW/C4RvjbGUoJFf1K6ZdR2xL/bG4kVq1+I4jQWX+26YUijpp+lpN7o5c6ZodXJCF56UkFGsqz44sIg8jrdWvbjRCxi2Bk0iyM3a7ecAV93zB6h1Ei38c0s6+8nrbkopArccGP8vntQe1bFeEh2nJIFOHX/k3/UHb5PtKGpnzbkmnRETMX+9X/QduLZWw/feklW/kH/JnzToJe9Kgu9Hct1UGbH5BPCLo4OOtQnZonW0xnyCcdtKyPQ/sbLiSTYJdSx4sJqWLMnfn6fIqPB3WAgk00J+fCOkomPHqtS67pf0mFmKoItYZUlJu6BihSZ8qve8+/X+LX1MhQXF95AshfUleCtmdn6l6QFXzLg2sgLn1oyVFuZecv7fzsIHzoRlAGp0gwYDOn1S4qabWvB5xUaE+Svw4KmjWtxdnuQbI32dw87D4N95u8qQRJTSQg0wLxOLkxSrPMLEn1UIhNKjAa9VLs3WLaXGrtCIt8bKY2AQP/ZdyRU6zT/E8qP2ltyBE2CCZPgWgEYDoJJO4n92y61ylNaSFXKohJhLjkfvYWm592539sIpmBNLlDo1bExFBfmHJJ0lFEiC/fj8v42OoMC9Mo3whIoWvyHfq6Uacqq55mzFf/EGC+NP/gHjhd6urc6R0hES27VXux7UY8CGKPohplWIZtTrFSaPWslCWy78E22Pw8fvReSUZx/txqLtHrFqg1DY/Eus6Iq1heZdrdcqE0/c971Bz1HW/XNXHsXpUIbI4kHdOfCc6T5zHZzvzQJB0ggMFL6IGPAilU9bj/ASdPk6fNvNtZqPuwEDhMBtBnhCexo6D6VAGIOPvJPPV523Y8R8a9vCqZbswSZKzOT1291BsUbmUWehtbb1fdRX9hiJKXvwr1QX6GjnZMgyMvnwOo2Dr24amr7FqEAbVeJAjRNOceM2EQ1Mna9fInqPJ5mh5X8CzT1aDOv08An0blz0fF5Gq4mS2cwq5glwIOlY5nznE8X4j/UdZ3FJsVIXte1JH0A7iibuPfazStM5O/Vo3KXIpXBeGORV0M9XDXFvsYZUHGvFCUubWzTw248EHE0cpQM2zNg6rjavreq3NHCAWsoZ7wvVy7l5gvtKRmIj1MnvfWEm0yFnGcuOq192350a5WefpfKCcX3Sn+AgHU+qnpstNtddbdVebagJU390lq9ko4aI9rqdaWXYG8tv5O/ZQHSqDRYHC6zfH10l5z++opso7aOSaIczlQ13iAzXvLdEu0V7kwNUZ1c8Y8aq7SeIEe5p902FlNkW8DnwHyueHchbK8vVFJfmr9mz7P8nUSccl1ULaoWMRSI1ls32kvlK0h46h3J25Yd9AzfcJbp9qYF/SEt3H5j69mMdcsNxZcAzT/A89ov3tglTX54y/EwjMfuoDoxPwLJDm5I7q6F9Kp469yNy1zSxz0N4HbRRBj9xFFuogvBspv7DXUNIsGxTINEQfmctb42XImWAODgARNo7dfcTqFKq6aTfivmvunLmzP9f8yLsJvXD3JbcPcDGNriMAcjzeDTNr65t8YB5tsnFDFLa0Uwmd2OvUdkLMX9TsAUYUfooSv47sw5J88j7CpahRjjO3/UhOXjTS39W5YZAel2KTbQd1h7INOw9P23GW7GDAe4agIUFHP48MZr7ubq0efFmmtwYMyk7D0r1oeG/CGOODgb9Ur+JMHxkwzPbtCX2ZnENQuI0RN5SyTIZuoY4XS9Rd/tPe3vNAZGSHM/YYwqs9xkkENx0O+eC2YVW1cwOJ3ckE890nbQeHLKlW15L0P0W2VliyYrfNr0nrIYddoRyGaCtj4OYd2MT7ebApqZOAQIaSHJM4mphhfjNjtnjg6YRyx9qM2FT3xOiYIMqXPFWdzhSgFF8ItocqVV09CmIoO8k6U/oJB7++wSX/YksxfPXHyjSgAGZOj1aKEq9fSvXBqtp2wu8/FxEf5AxapAD06pPGuLVUYLdgEzHR8wqRGYEwiUO9MyYbgswstuLYhwYFpSVKOdzAihZ9LuHtD598EGhINU9xc9xhL+QgTLAstmPIvvm2xyRw/WTUPXkP3ZHu6GyPmj5xFH9/QGpkglKXRVUBgVmLOJx8uZO2AstxQYocZH2JhORlxawj66BAXUEs7K/gPxINIRAFyK3WLuyq9oBTF9wEbnmCot82WjIg7CPNwYK3KrZMrKAz5yFszg4wCVLJVnIL8+OYA0xRDH8cHQjQUiQ2i1mr/be32k/3Xej9sdf3iuGvZHyLFSJvPSqz/wltnxumTJYKZsrWXtx/Rmu39jjV9lFaJttfFn57/No2h/unsJmMHbrnZ8csxkp5HQ4xR1s0HH+t3Iz82a3iQWTUDGq/+l2W3TUYLE8zNdL8Y+5oXaIH/Y2UUcX67cXeN4WvENZjz4+8q7vjhowOI3rSjFhGZ6KzwmU7+5nFV+kGWAZ5z2UWvzq0TK0pk1hPwAN4jbw//1CApRvIaIjhSGhioY6TUmsToek9cF9XjJdHvLPcyyCV3lbR5Jiz/ts46ay2F820VjTXvllElwrGzKcNSyvQlWDXdwrUINXmHorAM3fE19ngLZmgeUaCJLsSITf2VcfAOuWwX7mTPdP8Zb/04KqRniufCpwnDUk7sP0RX6cud/sanFMagnzKInSRVey0YzlVSOtA/AjrofmSH6RYbJQ8b4NDeTkIGc6247+Mnbez/qhJ9GAv9fGNFercPnnrf285Qgs+UqThLRgflcAKFuqWhLzZaR4QqvSwa3xe0LPkqj9xJWub195r7NrrR0e78FR+0mRBNMPsraqZctAUVAJfYKehTDV1MGGQSeDsOK9J3sbUuKRIS/WilX/64CBms9jCZocBlsBSZaIAjWm/SUZ8daWL2a/cJFyUOFqE3Epc2RWbtjNyPwOGpWtzu32kUooUqsJud7IV4E8rstUBXM7tGEtBx99x60g1duhyvxeKJSl8s5E34HTMmADT0836aEdg5Dv9rVyCz8i2REOmiz6wtIVFN0HsjAoN37SrY0bV1Ms8CRUILhvZvvRaDzoVCaSI0u8EPuTe4b7OPowgRGODl22UBBmHSTUY8e4DyL+Bc7bngo+2T8HtNvzyATSL5iJZgFPKpmUyZv54vVL90+/RQGATUmNKnrIvcJMYON9fl83naW5sf6hRkbbTC9RUEE6XADwjgA46wWfUQ+QWZl0J4PVTWAln/YfAz/SV3q3J9+yCYDleruoN5uoc/wT2f4YONGTb6zTGq3V+3JqzmCOjwebKln+fExVLN7sqtqfMnsKVXWbb2Ai5m3D/fCTgX7oKYzTZvj+m28XnDqPbXuP4MyWdmPezcesdrh7rCzA7BWdObiuyDEKjjzBbQ0qnuwjliz+b+j7aPMKlkXyIznV3tGzAfYwIbzGGt098oh4eq3ruDjdgHtjxfFCjHrjjRbHajoz/YOY4raojPFQ910GIlBV7hq47UDgpyajBxQUmD8NctiLV1rTSLAEsQDLTeRKcmPBMVMFF0SPBBhZ5oXoxtD3lMhuAQXmA+57OcciczVW9e9zwSIAHS+FJmvfXMJGF1dMBsIUMaPjvgaVqUc3p32qVCMQYFEiRLzlVSOGMCmv/HJIxAHe3mL/XnoZ1IkWLeRZfgyByjnDbbeRK5KL7bYHSVJZ9UFq+yCiNKeRUaYjgbC3hVUvfJAhy/QNl/JqLKVvGMk9ZcfyGidNeo/VTxK9vUpodzfQI9Z2eAre4nmrkzgxKSnT5IJ1D69oHuUS5hp7pK9IAWuNrAOtOH0mAuwCrY8mXAtVXUeaNK3OXr6PRvmWg4VQqFSy+a1GZfFYgdsJELG8N0kvqmzvwZ02Plf5fH9QTy6br0oY/IDsEA+GBf9pEVWCIuBCjsup3LDSDqI+5+0IKSUFr7A96A2f0FbcU9fqljdqvsd8sG55KcKloHIFZem2Wb6pCLXybnVSB0sjCXzdS8IKvE");const FENCED=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]),NSM_MAX=4;function hex_cp(c){return c.toString(16).toUpperCase().padStart(2,"0")}function quote_cp(c){return`{${hex_cp(c)}}`}function explode_cp(c){let a=[];for(let d=0,et=c.length;d>24&255}function unpack_cp(c){return c&16777215}const SHIFTED_RANK=new Map(read_sorted_arrays(r).flatMap((c,a)=>c.map(d=>[d,a+1<<24]))),EXCLUSIONS=new Set(read_sorted(r)),DECOMP=new Map,RECOMP=new Map;for(let[c,a]of read_mapped(r)){if(!EXCLUSIONS.has(c)&&a.length==2){let[d,et]=a,nt=RECOMP.get(d);nt||(nt=new Map,RECOMP.set(d,nt)),nt.set(et,c)}DECOMP.set(c,a.reverse())}const S0=44032,L0=4352,V0=4449,T0=4519,L_COUNT=19,V_COUNT=21,T_COUNT=28,N_COUNT=V_COUNT*T_COUNT,S_COUNT=L_COUNT*N_COUNT,S1=S0+S_COUNT,L1=L0+L_COUNT,V1=V0+V_COUNT,T1=T0+T_COUNT;function is_hangul(c){return c>=S0&&c=L0&&c=V0&&aT0&&a0&&nt(T0+$t)}else{let bt=DECOMP.get(tt);bt?d.push(...bt):nt(tt)}if(!d.length)break;tt=d.pop()}if(et&&a.length>1){let tt=unpack_cc(a[0]);for(let bt=1;bt0&&nt>=bt)bt==0?(a.push(et,...d),d.length=0,et=mt):d.push(mt),nt=bt;else{let vt=compose_pair(et,mt);vt>=0?et=vt:nt==0&&bt==0?(a.push(et),et=mt):(d.push(mt),nt=bt)}}return et>=0&&a.push(et,...d),a}function nfd(c){return decomposed(c).map(unpack_cp)}function nfc(c){return composed_from_decomposed(decomposed(c))}const FE0F=65039,STOP_CH=".",UNIQUE_PH=1,HYPHEN=45;function read_set(){return new Set(read_sorted(r$1))}const MAPPED=new Map(read_mapped(r$1)),IGNORED=read_set(),CM=read_set(),NSM=new Set(read_sorted(r$1).map(function(c){return this[c]},[...CM])),ESCAPE=read_set();read_set();const CHUNKS=read_sorted_arrays(r$1);function read_chunked(){return new Set([read_sorted(r$1).map(c=>CHUNKS[c]),read_sorted(r$1)].flat(2))}const UNRESTRICTED=r$1(),GROUPS=read_array_while(c=>{let a=read_array_while(r$1).map(d=>d+96);if(a.length){let d=c>=UNRESTRICTED;a[0]-=32,a=str_from_cps(a),d&&(a=`Restricted[${a}]`);let et=read_chunked(),nt=read_chunked(),tt=[...et,...nt].sort((mt,vt)=>mt-vt),bt=!r$1();return{N:a,P:et,M:bt,R:d,V:new Set(tt)}}}),WHOLE_VALID=read_set(),WHOLE_MAP=new Map;[...WHOLE_VALID,...read_set()].sort((c,a)=>c-a).map((c,a,d)=>{let et=r$1(),nt=d[a]=et?d[a-et]:{V:[],M:new Map};nt.V.push(c),WHOLE_VALID.has(c)||WHOLE_MAP.set(c,nt)});for(let{V:c,M:a}of new Set(WHOLE_MAP.values())){let d=[];for(let nt of c){let tt=GROUPS.filter(mt=>mt.V.has(nt)),bt=d.find(({G:mt})=>tt.some(vt=>mt.has(vt)));bt||(bt={G:new Set,V:[]},d.push(bt)),bt.V.push(nt),tt.forEach(mt=>bt.G.add(mt))}let et=d.flatMap(({G:nt})=>[...nt]);for(let{G:nt,V:tt}of d){let bt=new Set(et.filter(mt=>!nt.has(mt)));for(let mt of tt)a.set(mt,bt)}}let union=new Set,multi=new Set;for(let c of GROUPS)for(let a of c.V)(union.has(a)?multi:union).add(a);for(let c of union)!WHOLE_MAP.has(c)&&!multi.has(c)&&WHOLE_MAP.set(c,UNIQUE_PH);const VALID=new Set([...union,...nfd(union)]),EMOJI_SORTED=read_sorted(r$1),EMOJI_ROOT=read_emoji_trie([]);function read_emoji_trie(c){let a=read_array_while(()=>{let mt=read_sorted(r$1).map(vt=>EMOJI_SORTED[vt]);if(mt.length)return read_emoji_trie(mt)}).sort((mt,vt)=>vt.Q.size-mt.Q.size),d=r$1(),et=d%3;d=d/3|0;let nt=d&1;d>>=1;let tt=d&1,bt=d&2;return{B:a,V:et,F:nt,S:tt,C:bt,Q:new Set(c)}}class Emoji extends Array{get is_emoji(){return!0}}function safe_str_from_cps(c,a=quote_cp){let d=[];is_combining_mark(c[0])&&d.push("◌");let et=0,nt=c.length;for(let tt=0;tt=4&&c[2]==HYPHEN&&c[3]==HYPHEN)throw new Error("invalid label extension")}function check_leading_underscore(c){for(let d=c.lastIndexOf(95);d>0;)if(c[--d]!==95)throw new Error("underscore allowed only at start")}function check_fenced(c){let a=c[0],d=FENCED.get(a);if(d)throw error_placement(`leading ${d}`);let et=c.length,nt=-1;for(let tt=1;tt{let nt=explode_cp(et),tt={input:nt,offset:d};d+=nt.length+1;let bt;try{let mt=tt.tokens=process(nt,nfc),vt=mt.length,$t;if(vt){let At=mt[0],Mt=vt>1||At.is_emoji;if(!Mt&&At.every(Tt=>Tt<128))bt=At,check_leading_underscore(bt),check_label_extension(bt),$t="ASCII";else if(Mt&&(tt.emoji=!0,At=mt.flatMap(Tt=>Tt.is_emoji?[]:Tt)),bt=mt.flatMap(Tt=>!a&&Tt.is_emoji?filter_fe0f(Tt):Tt),check_leading_underscore(bt),!At.length)$t="Emoji";else{if(CM.has(bt[0]))throw error_placement("leading combining mark");for(let kt=1;ktbt.has(mt)):[...bt],!d.length)return}else et.push(nt)}if(d){for(let nt of d)if(et.every(tt=>nt.V.has(tt)))throw new Error(`whole-script confusable: ${c.N}/${nt.N}`)}}function determine_group(c){let a=GROUPS;for(let d of c){let et=a.filter(nt=>nt.V.has(d));if(!et.length)throw a===GROUPS?error_disallowed(d):error_group_member(a[0],d);if(a=et,et.length==1)break}return a}function flatten(c){return c.map(({input:a,error:d,output:et})=>{if(d){let nt=d.message;throw new Error(c.length==1?nt:`Invalid label ${bidi_qq(safe_str_from_cps(a))}: ${nt}`)}return str_from_cps(et)}).join(STOP_CH)}function error_disallowed(c){return new Error(`disallowed character: ${quoted_cp(c)}`)}function error_group_member(c,a){let d=quoted_cp(a),et=GROUPS.find(nt=>nt.P.has(a));return et&&(d=`${et.N} ${d}`),new Error(`illegal mixture: ${c.N} + ${d}`)}function error_placement(c){return new Error(`illegal placement: ${c}`)}function check_group(c,a){let{V:d,M:et}=c;for(let nt of a)if(!d.has(nt))throw error_group_member(c,nt);if(et){let nt=nfd(a);for(let tt=1,bt=nt.length;ttNSM_MAX)throw new Error(`non-spacing marks: too many ${bidi_qq(safe_str_from_cps(nt.slice(tt-1,mt)))} (${mt-tt}/${NSM_MAX})`);tt=mt}}}function process(c,a){let d=[],et=[];for(c=c.slice().reverse();c.length;){let nt=consume_emoji_reversed(c);if(nt)et.length&&(d.push(a(et)),et=[]),d.push(nt);else{let tt=c.pop();if(VALID.has(tt))et.push(tt);else{let bt=MAPPED.get(tt);if(bt)et.push(...bt);else if(!IGNORED.has(tt))throw error_disallowed(tt)}}}return et.length&&d.push(a(et)),d}function filter_fe0f(c){return c.filter(a=>a!=FE0F)}function consume_emoji_reversed(c,a){let d=EMOJI_ROOT,et,nt,tt=[],bt=c.length;for(a&&(a.length=0);bt;){let mt=c[--bt];if(d=d.B.find(vt=>vt.Q.has(mt)),!d)break;if(d.S)nt=mt;else if(d.C&&mt===nt)break;tt.push(mt),d.F&&(tt.push(FE0F),bt>0&&c[bt-1]==FE0F&&bt--),d.V&&(et=conform_emoji_copy(tt,d),a&&a.push(...c.slice(bt).reverse()),c.length=bt)}return et}function conform_emoji_copy(c,a){let d=Emoji.from(c);return a.V==2&&d.splice(1,1),d}const Zeros=new Uint8Array(32);Zeros.fill(0);function checkComponent(c){return assertArgument(c.length!==0,"invalid ENS name; empty component","comp",c),c}function ensNameSplit(c){const a=toUtf8Bytes$1(ensNormalize(c)),d=[];if(c.length===0)return d;let et=0;for(let nt=0;nt{if(a.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const d=new Uint8Array(a.length+1);return d.set(a,1),d[0]=d.length-1,d})))+"00"}function accessSetify$1(c,a){return{address:getAddress$2(c),storageKeys:a.map((d,et)=>(assertArgument(isHexString$1(d,32),"invalid slot",`storageKeys[${et}]`,d),d.toLowerCase()))}}function accessListify$1(c){if(Array.isArray(c))return c.map((d,et)=>Array.isArray(d)?(assertArgument(d.length===2,"invalid slot set",`value[${et}]`,d),accessSetify$1(d[0],d[1])):(assertArgument(d!=null&&typeof d=="object","invalid address-slot set","value",c),accessSetify$1(d.address,d.storageKeys)));assertArgument(c!=null&&typeof c=="object","invalid access list","value",c);const a=Object.keys(c).map(d=>{const et=c[d].reduce((nt,tt)=>(nt[tt]=!0,nt),{});return accessSetify$1(d,Object.keys(et).sort())});return a.sort((d,et)=>d.address.localeCompare(et.address)),a}function computeAddress$1(c){let a;return typeof c=="string"?a=SigningKey$1.computePublicKey(c,!1):a=c.publicKey,getAddress$2(keccak256$3("0x"+a.substring(4)).substring(26))}function recoverAddress(c,a){return computeAddress$1(SigningKey$1.recoverPublicKey(c,a))}const BN_0$4=BigInt(0),BN_2$1=BigInt(2),BN_27=BigInt(27),BN_28=BigInt(28),BN_35=BigInt(35),BN_MAX_UINT=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function handleAddress(c){return c==="0x"?null:getAddress$2(c)}function handleAccessList(c,a){try{return accessListify$1(c)}catch(d){assertArgument(!1,d.message,a,c)}}function handleNumber(c,a){return c==="0x"?0:getNumber(c,a)}function handleUint(c,a){if(c==="0x")return BN_0$4;const d=getBigInt(c,a);return assertArgument(d<=BN_MAX_UINT,"value exceeds uint size",a,d),d}function formatNumber$1(c,a){const d=getBigInt(c,"value"),et=toBeArray(d);return assertArgument(et.length<=32,"value too large",`tx.${a}`,d),et}function formatAccessList$1(c){return accessListify$1(c).map(a=>[a.address,a.storageKeys])}function _parseLegacy(c){const a=decodeRlp(c);assertArgument(Array.isArray(a)&&(a.length===9||a.length===6),"invalid field count for legacy transaction","data",c);const d={type:0,nonce:handleNumber(a[0],"nonce"),gasPrice:handleUint(a[1],"gasPrice"),gasLimit:handleUint(a[2],"gasLimit"),to:handleAddress(a[3]),value:handleUint(a[4],"value"),data:hexlify$1(a[5]),chainId:BN_0$4};if(a.length===6)return d;const et=handleUint(a[6],"v"),nt=handleUint(a[7],"r"),tt=handleUint(a[8],"s");if(nt===BN_0$4&&tt===BN_0$4)d.chainId=et;else{let bt=(et-BN_35)/BN_2$1;bt=this.maxPriorityFeePerGas,"priorityFee cannot be more than maxFee","BAD_DATA",{value:this}),assert$y(!d||this.type!==0&&this.type!==1,"transaction type cannot have maxFeePerGas or maxPriorityFeePerGas","BAD_DATA",{value:this}),assert$y(this.type!==0||!et,"legacy transaction cannot have accessList","BAD_DATA",{value:this});const nt=[];return this.type!=null?nt.push(this.type):d?nt.push(2):a?(nt.push(1),et||nt.push(0)):et?(nt.push(1),nt.push(2)):(nt.push(0),nt.push(1),nt.push(2)),nt.sort(),nt}isLegacy(){return this.type===0}isBerlin(){return this.type===1}isLondon(){return this.type===2}clone(){return Cn.from(this)}toJSON(){const a=d=>d==null?null:d.toString();return{type:this.type,to:this.to,data:this.data,nonce:this.nonce,gasLimit:a(this.gasLimit),gasPrice:a(this.gasPrice),maxPriorityFeePerGas:a(this.maxPriorityFeePerGas),maxFeePerGas:a(this.maxFeePerGas),value:a(this.value),chainId:a(this.chainId),sig:this.signature?this.signature.toJSON():null,accessList:this.accessList}}static from(a){if(a==null)return new Cn;if(typeof a=="string"){const et=getBytes(a);if(et[0]>=127)return Cn.from(_parseLegacy(et));switch(et[0]){case 1:return Cn.from(_parseEip2930(et));case 2:return Cn.from(_parseEip1559(et))}assert$y(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:"from"})}const d=new Cn;return a.type!=null&&(d.type=a.type),a.to!=null&&(d.to=a.to),a.nonce!=null&&(d.nonce=a.nonce),a.gasLimit!=null&&(d.gasLimit=a.gasLimit),a.gasPrice!=null&&(d.gasPrice=a.gasPrice),a.maxPriorityFeePerGas!=null&&(d.maxPriorityFeePerGas=a.maxPriorityFeePerGas),a.maxFeePerGas!=null&&(d.maxFeePerGas=a.maxFeePerGas),a.data!=null&&(d.data=a.data),a.value!=null&&(d.value=a.value),a.chainId!=null&&(d.chainId=a.chainId),a.signature!=null&&(d.signature=Signature$1.from(a.signature)),a.accessList!=null&&(d.accessList=a.accessList),a.hash!=null&&(assertArgument(d.isSigned(),"unsigned transaction cannot define hash","tx",a),assertArgument(d.hash===a.hash,"hash mismatch","tx",a)),a.from!=null&&(assertArgument(d.isSigned(),"unsigned transaction cannot define from","tx",a),assertArgument(d.from.toLowerCase()===(a.from||"").toLowerCase(),"from mismatch","tx",a)),d}};gn=new WeakMap,gs=new WeakMap,vs=new WeakMap,xs=new WeakMap,ws=new WeakMap,Es=new WeakMap,$s=new WeakMap,Ss=new WeakMap,As=new WeakMap,Ms=new WeakMap,_s=new WeakMap,Ps=new WeakMap;let Transaction=Cn;const padding$1=new Uint8Array(32);padding$1.fill(0);const BN__1=BigInt(-1),BN_0$3=BigInt(0),BN_1=BigInt(1),BN_MAX_UINT256=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function hexPadRight$1(c){const a=getBytes(c),d=a.length%32;return d?concat$3([a,padding$1.slice(d)]):hexlify$1(a)}const hexTrue$1=toBeHex(BN_1,32),hexFalse$1=toBeHex(BN_0$3,32),domainFieldTypes$1={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},domainFieldNames$1=["name","version","chainId","verifyingContract","salt"];function checkString$1(c){return function(a){return assertArgument(typeof a=="string",`invalid domain value for ${JSON.stringify(c)}`,`domain.${c}`,a),a}}const domainChecks$1={name:checkString$1("name"),version:checkString$1("version"),chainId:function(c){const a=getBigInt(c,"domain.chainId");return assertArgument(a>=0,"invalid chain ID","domain.chainId",c),Number.isSafeInteger(a)?Number(a):toQuantity(a)},verifyingContract:function(c){try{return getAddress$2(c).toLowerCase()}catch{}assertArgument(!1,'invalid domain value "verifyingContract"',"domain.verifyingContract",c)},salt:function(c){const a=getBytes(c,"domain.salt");return assertArgument(a.length===32,'invalid domain value "salt"',"domain.salt",c),hexlify$1(a)}};function getBaseEncoder$1(c){{const a=c.match(/^(u?)int(\d*)$/);if(a){const d=a[1]==="",et=parseInt(a[2]||"256");assertArgument(et%8===0&&et!==0&&et<=256&&(a[2]==null||a[2]===String(et)),"invalid numeric width","type",c);const nt=mask(BN_MAX_UINT256,d?et-1:et),tt=d?(nt+BN_1)*BN__1:BN_0$3;return function(bt){const mt=getBigInt(bt,"value");return assertArgument(mt>=tt&&mt<=nt,`value out-of-bounds for ${c}`,"value",mt),toBeHex(d?toTwos(mt,256):mt,32)}}}{const a=c.match(/^bytes(\d+)$/);if(a){const d=parseInt(a[1]);return assertArgument(d!==0&&d<=32&&a[1]===String(d),"invalid bytes width","type",c),function(et){const nt=getBytes(et);return assertArgument(nt.length===d,`invalid length for ${c}`,"value",et),hexPadRight$1(et)}}}switch(c){case"address":return function(a){return zeroPadValue(getAddress$2(a),32)};case"bool":return function(a){return a?hexTrue$1:hexFalse$1};case"bytes":return function(a){return keccak256$3(a)};case"string":return function(a){return id$2(a)}}return null}function encodeType$3(c,a){return`${c}(${a.map(({name:d,type:et})=>et+" "+d).join(",")})`}var oo,vn,Cs,Ro,r1,Dr;let TypedDataEncoder$1=(Dr=class{constructor(a){q0(this,Ro);G0(this,"primaryType");q0(this,oo,void 0);q0(this,vn,void 0);q0(this,Cs,void 0);m0(this,oo,JSON.stringify(a)),m0(this,vn,new Map),m0(this,Cs,new Map);const d=new Map,et=new Map,nt=new Map;Object.keys(a).forEach(mt=>{d.set(mt,new Set),et.set(mt,[]),nt.set(mt,new Set)});for(const mt in a){const vt=new Set;for(const $t of a[mt]){assertArgument(!vt.has($t.name),`duplicate variable name ${JSON.stringify($t.name)} in ${JSON.stringify(mt)}`,"types",a),vt.add($t.name);const At=$t.type.match(/^([^\x5b]*)(\x5b|$)/)[1]||null;assertArgument(At!==mt,`circular type reference to ${JSON.stringify(At)}`,"types",a),!getBaseEncoder$1(At)&&(assertArgument(et.has(At),`unknown type ${JSON.stringify(At)}`,"types",a),et.get(At).push(mt),d.get(mt).add(At))}}const tt=Array.from(et.keys()).filter(mt=>et.get(mt).length===0);assertArgument(tt.length!==0,"missing primary type","types",a),assertArgument(tt.length===1,`ambiguous primary types or unused types: ${tt.map(mt=>JSON.stringify(mt)).join(", ")}`,"types",a),defineProperties(this,{primaryType:tt[0]});function bt(mt,vt){assertArgument(!vt.has(mt),`circular type reference to ${JSON.stringify(mt)}`,"types",a),vt.add(mt);for(const $t of d.get(mt))if(et.has($t)){bt($t,vt);for(const At of vt)nt.get(At).add($t)}vt.delete(mt)}bt(this.primaryType,new Set);for(const[mt,vt]of nt){const $t=Array.from(vt);$t.sort(),s0(this,vn).set(mt,encodeType$3(mt,a[mt])+$t.map(At=>encodeType$3(At,a[At])).join(""))}}get types(){return JSON.parse(s0(this,oo))}getEncoder(a){let d=s0(this,Cs).get(a);return d||(d=W0(this,Ro,r1).call(this,a),s0(this,Cs).set(a,d)),d}encodeType(a){const d=s0(this,vn).get(a);return assertArgument(d,`unknown type: ${JSON.stringify(a)}`,"name",a),d}encodeData(a,d){return this.getEncoder(a)(d)}hashStruct(a,d){return keccak256$3(this.encodeData(a,d))}encode(a){return this.encodeData(this.primaryType,a)}hash(a){return this.hashStruct(this.primaryType,a)}_visit(a,d,et){if(getBaseEncoder$1(a))return et(a,d);const nt=a.match(/^(.*)(\x5b(\d*)\x5d)$/);if(nt)return assertArgument(!nt[3]||parseInt(nt[3])===d.length,`array length mismatch; expected length ${parseInt(nt[3])}`,"value",d),d.map(bt=>this._visit(nt[1],bt,et));const tt=this.types[a];if(tt)return tt.reduce((bt,{name:mt,type:vt})=>(bt[mt]=this._visit(vt,d[mt],et),bt),{});assertArgument(!1,`unknown type: ${a}`,"type",a)}visit(a,d){return this._visit(this.primaryType,a,d)}static from(a){return new Dr(a)}static getPrimaryType(a){return Dr.from(a).primaryType}static hashStruct(a,d,et){return Dr.from(d).hashStruct(a,et)}static hashDomain(a){const d=[];for(const et in a){if(a[et]==null)continue;const nt=domainFieldTypes$1[et];assertArgument(nt,`invalid typed-data domain key: ${JSON.stringify(et)}`,"domain",a),d.push({name:et,type:nt})}return d.sort((et,nt)=>domainFieldNames$1.indexOf(et.name)-domainFieldNames$1.indexOf(nt.name)),Dr.hashStruct("EIP712Domain",{EIP712Domain:d},a)}static encode(a,d,et){return concat$3(["0x1901",Dr.hashDomain(a),Dr.from(d).hash(et)])}static hash(a,d,et){return keccak256$3(Dr.encode(a,d,et))}static async resolveNames(a,d,et,nt){a=Object.assign({},a);for(const mt in a)a[mt]==null&&delete a[mt];const tt={};a.verifyingContract&&!isHexString$1(a.verifyingContract,20)&&(tt[a.verifyingContract]="0x");const bt=Dr.from(d);bt.visit(et,(mt,vt)=>(mt==="address"&&!isHexString$1(vt,20)&&(tt[vt]="0x"),vt));for(const mt in tt)tt[mt]=await nt(mt);return a.verifyingContract&&tt[a.verifyingContract]&&(a.verifyingContract=tt[a.verifyingContract]),et=bt.visit(et,(mt,vt)=>mt==="address"&&tt[vt]?tt[vt]:vt),{domain:a,value:et}}static getPayload(a,d,et){Dr.hashDomain(a);const nt={},tt=[];domainFieldNames$1.forEach(vt=>{const $t=a[vt];$t!=null&&(nt[vt]=domainChecks$1[vt]($t),tt.push({name:vt,type:domainFieldTypes$1[vt]}))});const bt=Dr.from(d),mt=Object.assign({},d);return assertArgument(mt.EIP712Domain==null,"types must not contain EIP712Domain type","types.EIP712Domain",d),mt.EIP712Domain=tt,bt.encode(et),{types:mt,domain:nt,primaryType:bt.primaryType,message:bt.visit(et,(vt,$t)=>{if(vt.match(/^bytes(\d*)/))return hexlify$1(getBytes($t));if(vt.match(/^u?int/))return getBigInt($t).toString();switch(vt){case"address":return $t.toLowerCase();case"bool":return!!$t;case"string":return assertArgument(typeof $t=="string","invalid string","value",$t),$t}assertArgument(!1,"unsupported type","type",vt)})}}},oo=new WeakMap,vn=new WeakMap,Cs=new WeakMap,Ro=new WeakSet,r1=function(a){{const nt=getBaseEncoder$1(a);if(nt)return nt}const d=a.match(/^(.*)(\x5b(\d*)\x5d)$/);if(d){const nt=d[1],tt=this.getEncoder(nt);return bt=>{assertArgument(!d[3]||parseInt(d[3])===bt.length,`array length mismatch; expected length ${parseInt(d[3])}`,"value",bt);let mt=bt.map(tt);return s0(this,vn).has(nt)&&(mt=mt.map(keccak256$3)),keccak256$3(concat$3(mt))}}const et=this.types[a];if(et){const nt=id$2(s0(this,vn).get(a));return tt=>{const bt=et.map(({name:mt,type:vt})=>{const $t=this.getEncoder(vt)(tt[mt]);return s0(this,vn).has(vt)?keccak256$3($t):$t});return bt.unshift(nt),concat$3(bt)}}assertArgument(!1,`unknown type: ${a}`,"type",a)},Dr);function setify(c){const a=new Set;return c.forEach(d=>a.add(d)),Object.freeze(a)}const _kwVisibDeploy="external public payable",KwVisibDeploy=setify(_kwVisibDeploy.split(" ")),_kwVisib="constant external internal payable private public pure view",KwVisib=setify(_kwVisib.split(" ")),_kwTypes="constructor error event fallback function receive struct",KwTypes=setify(_kwTypes.split(" ")),_kwModifiers="calldata memory storage payable indexed",KwModifiers=setify(_kwModifiers.split(" ")),_kwOther="tuple returns",_keywords=[_kwTypes,_kwModifiers,_kwOther,_kwVisib].join(" "),Keywords=setify(_keywords.split(" ")),SimpleTokens={"(":"OPEN_PAREN",")":"CLOSE_PAREN","[":"OPEN_BRACKET","]":"CLOSE_BRACKET",",":"COMMA","@":"AT"},regexWhitespacePrefix=new RegExp("^(\\s*)"),regexNumberPrefix=new RegExp("^([0-9]+)"),regexIdPrefix=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)"),regexId=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)$"),regexType=new RegExp("^(address|bool|bytes([0-9]*)|string|u?int([0-9]*))$");var Tr,Xr,fo,Go;const Bo=class Bo{constructor(a){q0(this,fo);q0(this,Tr,void 0);q0(this,Xr,void 0);m0(this,Tr,0),m0(this,Xr,a.slice())}get offset(){return s0(this,Tr)}get length(){return s0(this,Xr).length-s0(this,Tr)}clone(){return new Bo(s0(this,Xr))}reset(){m0(this,Tr,0)}popKeyword(a){const d=this.peek();if(d.type!=="KEYWORD"||!a.has(d.text))throw new Error(`expected keyword ${d.text}`);return this.pop().text}popType(a){if(this.peek().type!==a)throw new Error(`expected ${a}; got ${JSON.stringify(this.peek())}`);return this.pop().text}popParen(){const a=this.peek();if(a.type!=="OPEN_PAREN")throw new Error("bad start");const d=W0(this,fo,Go).call(this,s0(this,Tr)+1,a.match+1);return m0(this,Tr,a.match+1),d}popParams(){const a=this.peek();if(a.type!=="OPEN_PAREN")throw new Error("bad start");const d=[];for(;s0(this,Tr)=s0(this,Xr).length)throw new Error("out-of-bounds");return s0(this,Xr)[s0(this,Tr)]}peekKeyword(a){const d=this.peekType("KEYWORD");return d!=null&&a.has(d)?d:null}peekType(a){if(this.length===0)return null;const d=this.peek();return d.type===a?d.text:null}pop(){const a=this.peek();return Ws(this,Tr)._++,a}toString(){const a=[];for(let d=s0(this,Tr);d`}};Tr=new WeakMap,Xr=new WeakMap,fo=new WeakSet,Go=function(a=0,d=0){return new Bo(s0(this,Xr).slice(a,d).map(et=>Object.freeze(Object.assign({},et,{match:et.match-a,linkBack:et.linkBack-a,linkNext:et.linkNext-a}))))};let TokenString=Bo;function lex(c){const a=[],d=bt=>{const mt=tt0&&a[a.length-1].type==="NUMBER"){const Mt=a.pop().text;At=Mt+At,a[a.length-1].value=getNumber(Mt)}if(a.length===0||a[a.length-1].type!=="BRACKET")throw new Error("missing opening bracket");a[a.length-1].text+=At}continue}if(mt=bt.match(regexIdPrefix),mt){if(vt.text=mt[1],tt+=vt.text.length,Keywords.has(vt.text)){vt.type="KEYWORD";continue}if(vt.text.match(regexType)){vt.type="TYPE";continue}vt.type="ID";continue}if(mt=bt.match(regexNumberPrefix),mt){vt.text=mt[1],vt.type="NUMBER",tt+=vt.text.length;continue}throw new Error(`unexpected token ${JSON.stringify(bt[0])} at position ${tt}`)}return new TokenString(a.map(bt=>Object.freeze(bt)))}function allowSingle(c,a){let d=[];for(const et in a.keys())c.has(et)&&d.push(et);if(d.length>1)throw new Error(`conflicting types: ${d.join(", ")}`)}function consumeName(c,a){if(a.peekKeyword(KwTypes)){const d=a.pop().text;if(d!==c)throw new Error(`expected ${c}, got ${d}`)}return a.popType("ID")}function consumeKeywords(c,a){const d=new Set;for(;;){const et=c.peekType("KEYWORD");if(et==null||a&&!a.has(et))break;if(c.pop(),d.has(et))throw new Error(`duplicate keywords: ${JSON.stringify(et)}`);d.add(et)}return Object.freeze(d)}function consumeMutability(c){let a=consumeKeywords(c,KwVisib);return allowSingle(a,setify("constant payable nonpayable".split(" "))),allowSingle(a,setify("pure view payable nonpayable".split(" "))),a.has("view")?"view":a.has("pure")?"pure":a.has("payable")?"payable":a.has("nonpayable")?"nonpayable":a.has("constant")?"view":"nonpayable"}function consumeParams(c,a){return c.popParams().map(d=>ParamType.from(d,a))}function consumeGas(c){if(c.peekType("AT")){if(c.pop(),c.peekType("NUMBER"))return getBigInt(c.pop().text);throw new Error("invalid gas")}return null}function consumeEoi(c){if(c.length)throw new Error(`unexpected tokens: ${c.toString()}`)}const regexArrayType=new RegExp(/^(.*)\[([0-9]*)\]$/);function verifyBasicType(c){const a=c.match(regexType);if(assertArgument(a,"invalid type","type",c),c==="uint")return"uint256";if(c==="int")return"int256";if(a[2]){const d=parseInt(a[2]);assertArgument(d!==0&&d<=32,"invalid bytes length","type",c)}else if(a[3]){const d=parseInt(a[3]);assertArgument(d!==0&&d<=256&&d%8===0,"invalid numeric width","type",c)}return c}const _guard={},internal$1=Symbol.for("_ethers_internal"),ParamTypeInternal="_ParamTypeInternal",ErrorFragmentInternal="_ErrorInternal",EventFragmentInternal="_EventInternal",ConstructorFragmentInternal="_ConstructorInternal",FallbackFragmentInternal="_FallbackInternal",FunctionFragmentInternal="_FunctionInternal",StructFragmentInternal="_StructInternal";var Ts,So;const Gr=class Gr{constructor(a,d,et,nt,tt,bt,mt,vt){q0(this,Ts);G0(this,"name");G0(this,"type");G0(this,"baseType");G0(this,"indexed");G0(this,"components");G0(this,"arrayLength");G0(this,"arrayChildren");if(assertPrivate(a,_guard,"ParamType"),Object.defineProperty(this,internal$1,{value:ParamTypeInternal}),bt&&(bt=Object.freeze(bt.slice())),nt==="array"){if(mt==null||vt==null)throw new Error("")}else if(mt!=null||vt!=null)throw new Error("");if(nt==="tuple"){if(bt==null)throw new Error("")}else if(bt!=null)throw new Error("");defineProperties(this,{name:d,type:et,baseType:nt,indexed:tt,components:bt,arrayLength:mt,arrayChildren:vt})}format(a){if(a==null&&(a="sighash"),a==="json"){const et=this.name||"";if(this.isArray()){const tt=JSON.parse(this.arrayChildren.format("json"));return tt.name=et,tt.type+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`,JSON.stringify(tt)}const nt={type:this.baseType==="tuple"?"tuple":this.type,name:et};return typeof this.indexed=="boolean"&&(nt.indexed=this.indexed),this.isTuple()&&(nt.components=this.components.map(tt=>JSON.parse(tt.format(a)))),JSON.stringify(nt)}let d="";return this.isArray()?(d+=this.arrayChildren.format(a),d+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`):this.isTuple()?(a!=="sighash"&&(d+=this.type),d+="("+this.components.map(et=>et.format(a)).join(a==="full"?", ":",")+")"):d+=this.type,a!=="sighash"&&(this.indexed===!0&&(d+=" indexed"),a==="full"&&this.name&&(d+=" "+this.name)),d}isArray(){return this.baseType==="array"}isTuple(){return this.baseType==="tuple"}isIndexable(){return this.indexed!=null}walk(a,d){if(this.isArray()){if(!Array.isArray(a))throw new Error("invalid array value");if(this.arrayLength!==-1&&a.length!==this.arrayLength)throw new Error("array is wrong length");const et=this;return a.map(nt=>et.arrayChildren.walk(nt,d))}if(this.isTuple()){if(!Array.isArray(a))throw new Error("invalid tuple value");if(a.length!==this.components.length)throw new Error("array is wrong length");const et=this;return a.map((nt,tt)=>et.components[tt].walk(nt,d))}return d(this.type,a)}async walkAsync(a,d){const et=[],nt=[a];return W0(this,Ts,So).call(this,et,a,d,tt=>{nt[0]=tt}),et.length&&await Promise.all(et),nt[0]}static from(a,d){if(Gr.isParamType(a))return a;if(typeof a=="string")try{return Gr.from(lex(a),d)}catch{assertArgument(!1,"invalid param type","obj",a)}else if(a instanceof TokenString){let mt="",vt="",$t=null;consumeKeywords(a,setify(["tuple"])).has("tuple")||a.peekType("OPEN_PAREN")?(vt="tuple",$t=a.popParams().map(It=>Gr.from(It)),mt=`tuple(${$t.map(It=>It.format()).join(",")})`):(mt=verifyBasicType(a.popType("TYPE")),vt=mt);let At=null,Mt=null;for(;a.length&&a.peekType("BRACKET");){const It=a.pop();At=new Gr(_guard,"",mt,vt,null,$t,Mt,At),Mt=It.value,mt+=It.text,vt="array",$t=null}let Tt=null;if(consumeKeywords(a,KwModifiers).has("indexed")){if(!d)throw new Error("");Tt=!0}const kt=a.peekType("ID")?a.pop().text:"";if(a.length)throw new Error("leftover tokens");return new Gr(_guard,kt,mt,vt,Tt,$t,Mt,At)}const et=a.name;assertArgument(!et||typeof et=="string"&&et.match(regexId),"invalid name","obj.name",et);let nt=a.indexed;nt!=null&&(assertArgument(d,"parameter cannot be indexed","obj.indexed",a.indexed),nt=!!nt);let tt=a.type,bt=tt.match(regexArrayType);if(bt){const mt=parseInt(bt[2]||"-1"),vt=Gr.from({type:bt[1],components:a.components});return new Gr(_guard,et||"",tt,"array",nt,null,mt,vt)}if(tt==="tuple"||tt.startsWith("tuple(")||tt.startsWith("(")){const mt=a.components!=null?a.components.map($t=>Gr.from($t)):null;return new Gr(_guard,et||"",tt,"tuple",nt,mt,null,null)}return tt=verifyBasicType(a.type),new Gr(_guard,et||"",tt,tt,nt,null,null,null)}static isParamType(a){return a&&a[internal$1]===ParamTypeInternal}};Ts=new WeakSet,So=function(a,d,et,nt){if(this.isArray()){if(!Array.isArray(d))throw new Error("invalid array value");if(this.arrayLength!==-1&&d.length!==this.arrayLength)throw new Error("array is wrong length");const bt=this.arrayChildren,mt=d.slice();mt.forEach((vt,$t)=>{var At;W0(At=bt,Ts,So).call(At,a,vt,et,Mt=>{mt[$t]=Mt})}),nt(mt);return}if(this.isTuple()){const bt=this.components;let mt;if(Array.isArray(d))mt=d.slice();else{if(d==null||typeof d!="object")throw new Error("invalid tuple value");mt=bt.map(vt=>{if(!vt.name)throw new Error("cannot use object value with unnamed components");if(!(vt.name in d))throw new Error(`missing value for component ${vt.name}`);return d[vt.name]})}if(mt.length!==this.components.length)throw new Error("array is wrong length");mt.forEach((vt,$t)=>{var At;W0(At=bt[$t],Ts,So).call(At,a,vt,et,Mt=>{mt[$t]=Mt})}),nt(mt);return}const tt=et(this.type,d);tt.then?a.push(async function(){nt(await tt)}()):nt(tt)};let ParamType=Gr;class Fragment{constructor(a,d,et){G0(this,"type");G0(this,"inputs");assertPrivate(a,_guard,"Fragment"),et=Object.freeze(et.slice()),defineProperties(this,{type:d,inputs:et})}static from(a){if(typeof a=="string"){try{Fragment.from(JSON.parse(a))}catch{}return Fragment.from(lex(a))}if(a instanceof TokenString)switch(a.peekKeyword(KwTypes)){case"constructor":return ConstructorFragment.from(a);case"error":return ErrorFragment.from(a);case"event":return EventFragment.from(a);case"fallback":case"receive":return FallbackFragment.from(a);case"function":return FunctionFragment.from(a);case"struct":return StructFragment.from(a)}else if(typeof a=="object"){switch(a.type){case"constructor":return ConstructorFragment.from(a);case"error":return ErrorFragment.from(a);case"event":return EventFragment.from(a);case"fallback":case"receive":return FallbackFragment.from(a);case"function":return FunctionFragment.from(a);case"struct":return StructFragment.from(a)}assert$y(!1,`unsupported type: ${a.type}`,"UNSUPPORTED_OPERATION",{operation:"Fragment.from"})}assertArgument(!1,"unsupported frgament object","obj",a)}static isConstructor(a){return ConstructorFragment.isFragment(a)}static isError(a){return ErrorFragment.isFragment(a)}static isEvent(a){return EventFragment.isFragment(a)}static isFunction(a){return FunctionFragment.isFragment(a)}static isStruct(a){return StructFragment.isFragment(a)}}class NamedFragment extends Fragment{constructor(d,et,nt,tt){super(d,et,tt);G0(this,"name");assertArgument(typeof nt=="string"&&nt.match(regexId),"invalid identifier","name",nt),tt=Object.freeze(tt.slice()),defineProperties(this,{name:nt})}}function joinParams(c,a){return"("+a.map(d=>d.format(c)).join(c==="full"?", ":",")+")"}class ErrorFragment extends NamedFragment{constructor(a,d,et){super(a,"error",d,et),Object.defineProperty(this,internal$1,{value:ErrorFragmentInternal})}get selector(){return id$2(this.format("sighash")).substring(0,10)}format(a){if(a==null&&(a="sighash"),a==="json")return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map(et=>JSON.parse(et.format(a)))});const d=[];return a!=="sighash"&&d.push("error"),d.push(this.name+joinParams(a,this.inputs)),d.join(" ")}static from(a){if(ErrorFragment.isFragment(a))return a;if(typeof a=="string")return ErrorFragment.from(lex(a));if(a instanceof TokenString){const d=consumeName("error",a),et=consumeParams(a);return consumeEoi(a),new ErrorFragment(_guard,d,et)}return new ErrorFragment(_guard,a.name,a.inputs?a.inputs.map(ParamType.from):[])}static isFragment(a){return a&&a[internal$1]===ErrorFragmentInternal}}class EventFragment extends NamedFragment{constructor(d,et,nt,tt){super(d,"event",et,nt);G0(this,"anonymous");Object.defineProperty(this,internal$1,{value:EventFragmentInternal}),defineProperties(this,{anonymous:tt})}get topicHash(){return id$2(this.format("sighash"))}format(d){if(d==null&&(d="sighash"),d==="json")return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map(nt=>JSON.parse(nt.format(d)))});const et=[];return d!=="sighash"&&et.push("event"),et.push(this.name+joinParams(d,this.inputs)),d!=="sighash"&&this.anonymous&&et.push("anonymous"),et.join(" ")}static getTopicHash(d,et){return et=(et||[]).map(tt=>ParamType.from(tt)),new EventFragment(_guard,d,et,!1).topicHash}static from(d){if(EventFragment.isFragment(d))return d;if(typeof d=="string")try{return EventFragment.from(lex(d))}catch{assertArgument(!1,"invalid event fragment","obj",d)}else if(d instanceof TokenString){const et=consumeName("event",d),nt=consumeParams(d,!0),tt=!!consumeKeywords(d,setify(["anonymous"])).has("anonymous");return consumeEoi(d),new EventFragment(_guard,et,nt,tt)}return new EventFragment(_guard,d.name,d.inputs?d.inputs.map(et=>ParamType.from(et,!0)):[],!!d.anonymous)}static isFragment(d){return d&&d[internal$1]===EventFragmentInternal}}class ConstructorFragment extends Fragment{constructor(d,et,nt,tt,bt){super(d,et,nt);G0(this,"payable");G0(this,"gas");Object.defineProperty(this,internal$1,{value:ConstructorFragmentInternal}),defineProperties(this,{payable:tt,gas:bt})}format(d){if(assert$y(d!=null&&d!=="sighash","cannot format a constructor for sighash","UNSUPPORTED_OPERATION",{operation:"format(sighash)"}),d==="json")return JSON.stringify({type:"constructor",stateMutability:this.payable?"payable":"undefined",payable:this.payable,gas:this.gas!=null?this.gas:void 0,inputs:this.inputs.map(nt=>JSON.parse(nt.format(d)))});const et=[`constructor${joinParams(d,this.inputs)}`];return et.push(this.payable?"payable":"nonpayable"),this.gas!=null&&et.push(`@${this.gas.toString()}`),et.join(" ")}static from(d){if(ConstructorFragment.isFragment(d))return d;if(typeof d=="string")try{return ConstructorFragment.from(lex(d))}catch{assertArgument(!1,"invalid constuctor fragment","obj",d)}else if(d instanceof TokenString){consumeKeywords(d,setify(["constructor"]));const et=consumeParams(d),nt=!!consumeKeywords(d,KwVisibDeploy).has("payable"),tt=consumeGas(d);return consumeEoi(d),new ConstructorFragment(_guard,"constructor",et,nt,tt)}return new ConstructorFragment(_guard,"constructor",d.inputs?d.inputs.map(ParamType.from):[],!!d.payable,d.gas!=null?d.gas:null)}static isFragment(d){return d&&d[internal$1]===ConstructorFragmentInternal}}class FallbackFragment extends Fragment{constructor(d,et,nt){super(d,"fallback",et);G0(this,"payable");Object.defineProperty(this,internal$1,{value:FallbackFragmentInternal}),defineProperties(this,{payable:nt})}format(d){const et=this.inputs.length===0?"receive":"fallback";if(d==="json"){const nt=this.payable?"payable":"nonpayable";return JSON.stringify({type:et,stateMutability:nt})}return`${et}()${this.payable?" payable":""}`}static from(d){if(FallbackFragment.isFragment(d))return d;if(typeof d=="string")try{return FallbackFragment.from(lex(d))}catch{assertArgument(!1,"invalid fallback fragment","obj",d)}else if(d instanceof TokenString){const et=d.toString(),nt=d.peekKeyword(setify(["fallback","receive"]));if(assertArgument(nt,"type must be fallback or receive","obj",et),d.popKeyword(setify(["fallback","receive"]))==="receive"){const vt=consumeParams(d);return assertArgument(vt.length===0,"receive cannot have arguments","obj.inputs",vt),consumeKeywords(d,setify(["payable"])),consumeEoi(d),new FallbackFragment(_guard,[],!0)}let bt=consumeParams(d);bt.length?assertArgument(bt.length===1&&bt[0].type==="bytes","invalid fallback inputs","obj.inputs",bt.map(vt=>vt.format("minimal")).join(", ")):bt=[ParamType.from("bytes")];const mt=consumeMutability(d);if(assertArgument(mt==="nonpayable"||mt==="payable","fallback cannot be constants","obj.stateMutability",mt),consumeKeywords(d,setify(["returns"])).has("returns")){const vt=consumeParams(d);assertArgument(vt.length===1&&vt[0].type==="bytes","invalid fallback outputs","obj.outputs",vt.map($t=>$t.format("minimal")).join(", "))}return consumeEoi(d),new FallbackFragment(_guard,bt,mt==="payable")}if(d.type==="receive")return new FallbackFragment(_guard,[],!0);if(d.type==="fallback"){const et=[ParamType.from("bytes")],nt=d.stateMutability==="payable";return new FallbackFragment(_guard,et,nt)}assertArgument(!1,"invalid fallback description","obj",d)}static isFragment(d){return d&&d[internal$1]===FallbackFragmentInternal}}class FunctionFragment extends NamedFragment{constructor(d,et,nt,tt,bt,mt){super(d,"function",et,tt);G0(this,"constant");G0(this,"outputs");G0(this,"stateMutability");G0(this,"payable");G0(this,"gas");Object.defineProperty(this,internal$1,{value:FunctionFragmentInternal}),bt=Object.freeze(bt.slice()),defineProperties(this,{constant:nt==="view"||nt==="pure",gas:mt,outputs:bt,payable:nt==="payable",stateMutability:nt})}get selector(){return id$2(this.format("sighash")).substring(0,10)}format(d){if(d==null&&(d="sighash"),d==="json")return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:this.stateMutability!=="nonpayable"?this.stateMutability:void 0,payable:this.payable,gas:this.gas!=null?this.gas:void 0,inputs:this.inputs.map(nt=>JSON.parse(nt.format(d))),outputs:this.outputs.map(nt=>JSON.parse(nt.format(d)))});const et=[];return d!=="sighash"&&et.push("function"),et.push(this.name+joinParams(d,this.inputs)),d!=="sighash"&&(this.stateMutability!=="nonpayable"&&et.push(this.stateMutability),this.outputs&&this.outputs.length&&(et.push("returns"),et.push(joinParams(d,this.outputs))),this.gas!=null&&et.push(`@${this.gas.toString()}`)),et.join(" ")}static getSelector(d,et){return et=(et||[]).map(tt=>ParamType.from(tt)),new FunctionFragment(_guard,d,"view",et,[],null).selector}static from(d){if(FunctionFragment.isFragment(d))return d;if(typeof d=="string")try{return FunctionFragment.from(lex(d))}catch{assertArgument(!1,"invalid function fragment","obj",d)}else if(d instanceof TokenString){const nt=consumeName("function",d),tt=consumeParams(d),bt=consumeMutability(d);let mt=[];consumeKeywords(d,setify(["returns"])).has("returns")&&(mt=consumeParams(d));const vt=consumeGas(d);return consumeEoi(d),new FunctionFragment(_guard,nt,bt,tt,mt,vt)}let et=d.stateMutability;return et==null&&(et="payable",typeof d.constant=="boolean"?(et="view",d.constant||(et="payable",typeof d.payable=="boolean"&&!d.payable&&(et="nonpayable"))):typeof d.payable=="boolean"&&!d.payable&&(et="nonpayable")),new FunctionFragment(_guard,d.name,et,d.inputs?d.inputs.map(ParamType.from):[],d.outputs?d.outputs.map(ParamType.from):[],d.gas!=null?d.gas:null)}static isFragment(d){return d&&d[internal$1]===FunctionFragmentInternal}}class StructFragment extends NamedFragment{constructor(a,d,et){super(a,"struct",d,et),Object.defineProperty(this,internal$1,{value:StructFragmentInternal})}format(){throw new Error("@TODO")}static from(a){if(typeof a=="string")try{return StructFragment.from(lex(a))}catch{assertArgument(!1,"invalid struct fragment","obj",a)}else if(a instanceof TokenString){const d=consumeName("struct",a),et=consumeParams(a);return consumeEoi(a),new StructFragment(_guard,d,et)}return new StructFragment(_guard,a.name,a.inputs?a.inputs.map(ParamType.from):[])}static isFragment(a){return a&&a[internal$1]===StructFragmentInternal}}const PanicReasons$1=new Map;PanicReasons$1.set(0,"GENERIC_PANIC");PanicReasons$1.set(1,"ASSERT_FALSE");PanicReasons$1.set(17,"OVERFLOW");PanicReasons$1.set(18,"DIVIDE_BY_ZERO");PanicReasons$1.set(33,"ENUM_RANGE_ERROR");PanicReasons$1.set(34,"BAD_STORAGE_DATA");PanicReasons$1.set(49,"STACK_UNDERFLOW");PanicReasons$1.set(50,"ARRAY_RANGE_ERROR");PanicReasons$1.set(65,"OUT_OF_MEMORY");PanicReasons$1.set(81,"UNINITIALIZED_FUNCTION_CALL");const paramTypeBytes=new RegExp(/^bytes([0-9]*)$/),paramTypeNumber=new RegExp(/^(u?int)([0-9]*)$/);let defaultCoder=null;function getBuiltinCallException(c,a,d,et){let nt="missing revert data",tt=null;const bt=null;let mt=null;if(d){nt="execution reverted";const $t=getBytes(d);if(d=hexlify$1(d),$t.length===0)nt+=" (no data present; likely require(false) occurred",tt="require(false)";else if($t.length%32!==4)nt+=" (could not decode reason; invalid data length)";else if(hexlify$1($t.slice(0,4))==="0x08c379a0")try{tt=et.decode(["string"],$t.slice(4))[0],mt={signature:"Error(string)",name:"Error",args:[tt]},nt+=`: ${JSON.stringify(tt)}`}catch{nt+=" (could not decode reason; invalid string data)"}else if(hexlify$1($t.slice(0,4))==="0x4e487b71")try{const At=Number(et.decode(["uint256"],$t.slice(4))[0]);mt={signature:"Panic(uint256)",name:"Panic",args:[At]},tt=`Panic due to ${PanicReasons$1.get(At)||"UNKNOWN"}(${At})`,nt+=`: ${tt}`}catch{nt+=" (could not decode panic code)"}else nt+=" (unknown custom error)"}const vt={to:a.to?getAddress$2(a.to):null,data:a.data||"0x"};return a.from&&(vt.from=getAddress$2(a.from)),makeError(nt,"CALL_EXCEPTION",{action:c,data:d,reason:tt,transaction:vt,invocation:bt,revert:mt})}var Bn,ns;const ko=class ko{constructor(){q0(this,Bn)}getDefaultValue(a){const d=a.map(nt=>W0(this,Bn,ns).call(this,ParamType.from(nt)));return new TupleCoder(d,"_").defaultValue()}encode(a,d){assertArgumentCount(d.length,a.length,"types/values length mismatch");const et=a.map(bt=>W0(this,Bn,ns).call(this,ParamType.from(bt))),nt=new TupleCoder(et,"_"),tt=new Writer;return nt.encode(tt,d),tt.data}decode(a,d,et){const nt=a.map(bt=>W0(this,Bn,ns).call(this,ParamType.from(bt)));return new TupleCoder(nt,"_").decode(new Reader(d,et))}static defaultAbiCoder(){return defaultCoder==null&&(defaultCoder=new ko),defaultCoder}static getBuiltinCallException(a,d,et){return getBuiltinCallException(a,d,et,ko.defaultAbiCoder())}};Bn=new WeakSet,ns=function(a){if(a.isArray())return new ArrayCoder(W0(this,Bn,ns).call(this,a.arrayChildren),a.arrayLength,a.name);if(a.isTuple())return new TupleCoder(a.components.map(et=>W0(this,Bn,ns).call(this,et)),a.name);switch(a.baseType){case"address":return new AddressCoder(a.name);case"bool":return new BooleanCoder(a.name);case"string":return new StringCoder(a.name);case"bytes":return new BytesCoder(a.name);case"":return new NullCoder(a.name)}let d=a.type.match(paramTypeNumber);if(d){let et=parseInt(d[2]||"256");return assertArgument(et!==0&&et<=256&&et%8===0,"invalid "+d[1]+" bit length","param",a),new NumberCoder(et/8,d[1]==="int",a.name)}if(d=a.type.match(paramTypeBytes),d){let et=parseInt(d[1]);return assertArgument(et!==0&&et<=32,"invalid bytes length","param",a),new FixedBytesCoder(et,a.name)}assertArgument(!1,"invalid type","type",a.type)};let AbiCoder=ko;class LogDescription{constructor(a,d,et){G0(this,"fragment");G0(this,"name");G0(this,"signature");G0(this,"topic");G0(this,"args");const nt=a.name,tt=a.format();defineProperties(this,{fragment:a,name:nt,signature:tt,topic:d,args:et})}}class TransactionDescription{constructor(a,d,et,nt){G0(this,"fragment");G0(this,"name");G0(this,"args");G0(this,"signature");G0(this,"selector");G0(this,"value");const tt=a.name,bt=a.format();defineProperties(this,{fragment:a,name:tt,args:et,signature:bt,selector:d,value:nt})}}class ErrorDescription{constructor(a,d,et){G0(this,"fragment");G0(this,"name");G0(this,"args");G0(this,"signature");G0(this,"selector");const nt=a.name,tt=a.format();defineProperties(this,{fragment:a,name:nt,args:et,signature:tt,selector:d})}}class Indexed{constructor(a){G0(this,"hash");G0(this,"_isIndexed");defineProperties(this,{hash:a,_isIndexed:!0})}static isIndexed(a){return!!(a&&a._isIndexed)}}const PanicReasons={0:"generic panic",1:"assert(false)",17:"arithmetic overflow",18:"division or modulo by zero",33:"enum overflow",34:"invalid encoded storage byte array accessed",49:"out-of-bounds array access; popping on an empty array",50:"out-of-bounds access of an array or bytesN",65:"out of memory",81:"uninitialized function"},BuiltinErrors={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:c=>`reverted with reason string ${JSON.stringify(c)}`},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"],reason:c=>{let a="unknown panic code";return c>=0&&c<=255&&PanicReasons[c.toString()]&&(a=PanicReasons[c.toString()]),`reverted with panic code 0x${c.toString(16)} (${a})`}}};var rn,nn,an,Rr,Rs,Ao,Bs,Mo;const as=class as{constructor(a){q0(this,Rs);q0(this,Bs);G0(this,"fragments");G0(this,"deploy");G0(this,"fallback");G0(this,"receive");q0(this,rn,void 0);q0(this,nn,void 0);q0(this,an,void 0);q0(this,Rr,void 0);let d=[];typeof a=="string"?d=JSON.parse(a):d=a,m0(this,an,new Map),m0(this,rn,new Map),m0(this,nn,new Map);const et=[];for(const bt of d)try{et.push(Fragment.from(bt))}catch(mt){console.log("EE",mt)}defineProperties(this,{fragments:Object.freeze(et)});let nt=null,tt=!1;m0(this,Rr,this.getAbiCoder()),this.fragments.forEach((bt,mt)=>{let vt;switch(bt.type){case"constructor":if(this.deploy){console.log("duplicate definition - constructor");return}defineProperties(this,{deploy:bt});return;case"fallback":bt.inputs.length===0?tt=!0:(assertArgument(!nt||bt.payable!==nt.payable,"conflicting fallback fragments",`fragments[${mt}]`,bt),nt=bt,tt=nt.payable);return;case"function":vt=s0(this,an);break;case"event":vt=s0(this,nn);break;case"error":vt=s0(this,rn);break;default:return}const $t=bt.format();vt.has($t)||vt.set($t,bt)}),this.deploy||defineProperties(this,{deploy:ConstructorFragment.from("constructor()")}),defineProperties(this,{fallback:nt,receive:tt})}format(a){const d=a?"minimal":"full";return this.fragments.map(nt=>nt.format(d))}formatJson(){const a=this.fragments.map(d=>d.format("json"));return JSON.stringify(a.map(d=>JSON.parse(d)))}getAbiCoder(){return AbiCoder.defaultAbiCoder()}getFunctionName(a){const d=W0(this,Rs,Ao).call(this,a,null,!1);return assertArgument(d,"no matching function","key",a),d.name}hasFunction(a){return!!W0(this,Rs,Ao).call(this,a,null,!1)}getFunction(a,d){return W0(this,Rs,Ao).call(this,a,d||null,!0)}forEachFunction(a){const d=Array.from(s0(this,an).keys());d.sort((et,nt)=>et.localeCompare(nt));for(let et=0;etet.localeCompare(nt));for(let et=0;et1){const tt=nt.map(bt=>JSON.stringify(bt.format())).join(", ");assertArgument(!1,`ambiguous error description (i.e. ${tt})`,"name",a)}return nt[0]}if(a=ErrorFragment.from(a).format(),a==="Error(string)")return ErrorFragment.from("error Error(string)");if(a==="Panic(uint256)")return ErrorFragment.from("error Panic(uint256)");const et=s0(this,rn).get(a);return et||null}forEachError(a){const d=Array.from(s0(this,rn).keys());d.sort((et,nt)=>et.localeCompare(nt));for(let et=0;ettt.type==="string"?id$2(bt):tt.type==="bytes"?keccak256$3(hexlify$1(bt)):(tt.type==="bool"&&typeof bt=="boolean"?bt=bt?"0x01":"0x00":tt.type.match(/^u?int/)?bt=toBeHex(bt):tt.type.match(/^bytes/)?bt=zeroPadBytes(bt,32):tt.type==="address"&&s0(this,Rr).encode(["address"],[bt]),zeroPadValue(hexlify$1(bt),32));for(d.forEach((tt,bt)=>{const mt=a.inputs[bt];if(!mt.indexed){assertArgument(tt==null,"cannot filter non-indexed parameters; must be null","contract."+mt.name,tt);return}tt==null?et.push(null):mt.baseType==="array"||mt.baseType==="tuple"?assertArgument(!1,"filtering with tuples or arrays not supported","contract."+mt.name,tt):Array.isArray(tt)?et.push(tt.map(vt=>nt(mt,vt))):et.push(nt(mt,tt))});et.length&&et[et.length-1]===null;)et.pop();return et}encodeEventLog(a,d){if(typeof a=="string"){const bt=this.getEvent(a);assertArgument(bt,"unknown event","eventFragment",a),a=bt}const et=[],nt=[],tt=[];return a.anonymous||et.push(a.topicHash),assertArgument(d.length===a.inputs.length,"event arguments/values mismatch","values",d),a.inputs.forEach((bt,mt)=>{const vt=d[mt];if(bt.indexed)if(bt.type==="string")et.push(id$2(vt));else if(bt.type==="bytes")et.push(keccak256$3(vt));else{if(bt.baseType==="tuple"||bt.baseType==="array")throw new Error("not implemented");et.push(s0(this,Rr).encode([bt.type],[vt]))}else nt.push(bt),tt.push(vt)}),{data:s0(this,Rr).encode(nt,tt),topics:et}}decodeEventLog(a,d,et){if(typeof a=="string"){const Rt=this.getEvent(a);assertArgument(Rt,"unknown event","eventFragment",a),a=Rt}if(et!=null&&!a.anonymous){const Rt=a.topicHash;assertArgument(isHexString$1(et[0],32)&&et[0].toLowerCase()===Rt,"fragment/topic mismatch","topics[0]",et[0]),et=et.slice(1)}const nt=[],tt=[],bt=[];a.inputs.forEach((Rt,kt)=>{Rt.indexed?Rt.type==="string"||Rt.type==="bytes"||Rt.baseType==="tuple"||Rt.baseType==="array"?(nt.push(ParamType.from({type:"bytes32",name:Rt.name})),bt.push(!0)):(nt.push(Rt),bt.push(!1)):(tt.push(Rt),bt.push(!1))});const mt=et!=null?s0(this,Rr).decode(nt,concat$3(et)):null,vt=s0(this,Rr).decode(tt,d,!0),$t=[],At=[];let Mt=0,Tt=0;return a.inputs.forEach((Rt,kt)=>{let It=null;if(Rt.indexed)if(mt==null)It=new Indexed(null);else if(bt[kt])It=new Indexed(mt[Tt++]);else try{It=mt[Tt++]}catch(Dt){It=Dt}else try{It=vt[Mt++]}catch(Dt){It=Dt}$t.push(It),At.push(Rt.name||null)}),Result.fromItems($t,At)}parseTransaction(a){const d=getBytes(a.data,"tx.data"),et=getBigInt(a.value!=null?a.value:0,"tx.value"),nt=this.getFunction(hexlify$1(d.slice(0,4)));if(!nt)return null;const tt=s0(this,Rr).decode(nt.inputs,d.slice(4));return new TransactionDescription(nt,nt.selector,tt,et)}parseCallResult(a){throw new Error("@TODO")}parseLog(a){const d=this.getEvent(a.topics[0]);return!d||d.anonymous?null:new LogDescription(d,d.topicHash,this.decodeEventLog(d,a.data,a.topics))}parseError(a){const d=hexlify$1(a),et=this.getError(dataSlice(d,0,4));if(!et)return null;const nt=s0(this,Rr).decode(et.inputs,dataSlice(d,4));return new ErrorDescription(et,et.selector,nt)}static from(a){return a instanceof as?a:typeof a=="string"?new as(JSON.parse(a)):typeof a.format=="function"?new as(a.format("json")):new as(a)}};rn=new WeakMap,nn=new WeakMap,an=new WeakMap,Rr=new WeakMap,Rs=new WeakSet,Ao=function(a,d,et){if(isHexString$1(a)){const tt=a.toLowerCase();for(const bt of s0(this,an).values())if(tt===bt.selector)return bt;return null}if(a.indexOf("(")===-1){const tt=[];for(const[bt,mt]of s0(this,an))bt.split("(")[0]===a&&tt.push(mt);if(d){const bt=d.length>0?d[d.length-1]:null;let mt=d.length,vt=!0;Typed.isTyped(bt)&&bt.type==="overrides"&&(vt=!1,mt--);for(let $t=tt.length-1;$t>=0;$t--){const At=tt[$t].inputs.length;At!==mt&&(!vt||At!==mt-1)&&tt.splice($t,1)}for(let $t=tt.length-1;$t>=0;$t--){const At=tt[$t].inputs;for(let Mt=0;Mt=At.length){if(d[Mt].type==="overrides")continue;tt.splice($t,1);break}if(d[Mt].type!==At[Mt].baseType){tt.splice($t,1);break}}}}if(tt.length===1&&d&&d.length!==tt[0].inputs.length){const bt=d[d.length-1];(bt==null||Array.isArray(bt)||typeof bt!="object")&&tt.splice(0,1)}if(tt.length===0)return null;if(tt.length>1&&et){const bt=tt.map(mt=>JSON.stringify(mt.format())).join(", ");assertArgument(!1,`ambiguous function description (i.e. matches ${bt})`,"key",a)}return tt[0]}const nt=s0(this,an).get(FunctionFragment.from(a).format());return nt||null},Bs=new WeakSet,Mo=function(a,d,et){if(isHexString$1(a)){const tt=a.toLowerCase();for(const bt of s0(this,nn).values())if(tt===bt.topicHash)return bt;return null}if(a.indexOf("(")===-1){const tt=[];for(const[bt,mt]of s0(this,nn))bt.split("(")[0]===a&&tt.push(mt);if(d){for(let bt=tt.length-1;bt>=0;bt--)tt[bt].inputs.length=0;bt--){const mt=tt[bt].inputs;for(let vt=0;vt1&&et){const bt=tt.map(mt=>JSON.stringify(mt.format())).join(", ");assertArgument(!1,`ambiguous event description (i.e. matches ${bt})`,"key",a)}return tt[0]}const nt=s0(this,nn).get(EventFragment.from(a).format());return nt||null};let Interface=as;const BN_0$2=BigInt(0);function getValue(c){return c??null}function toJson(c){return c==null?null:c.toString()}class FeeData{constructor(a,d,et){G0(this,"gasPrice");G0(this,"maxFeePerGas");G0(this,"maxPriorityFeePerGas");defineProperties(this,{gasPrice:getValue(a),maxFeePerGas:getValue(d),maxPriorityFeePerGas:getValue(et)})}toJSON(){const{gasPrice:a,maxFeePerGas:d,maxPriorityFeePerGas:et}=this;return{_type:"FeeData",gasPrice:toJson(a),maxFeePerGas:toJson(d),maxPriorityFeePerGas:toJson(et)}}}function copyRequest(c){const a={};c.to&&(a.to=c.to),c.from&&(a.from=c.from),c.data&&(a.data=hexlify$1(c.data));const d="chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);for(const nt of d)!(nt in c)||c[nt]==null||(a[nt]=getBigInt(c[nt],`request.${nt}`));const et="type,nonce".split(/,/);for(const nt of et)!(nt in c)||c[nt]==null||(a[nt]=getNumber(c[nt],`request.${nt}`));return c.accessList&&(a.accessList=accessListify$1(c.accessList)),"blockTag"in c&&(a.blockTag=c.blockTag),"enableCcipRead"in c&&(a.enableCcipRead=!!c.enableCcipRead),"customData"in c&&(a.customData=c.customData),a}var xn;class Block{constructor(a,d){G0(this,"provider");G0(this,"number");G0(this,"hash");G0(this,"timestamp");G0(this,"parentHash");G0(this,"nonce");G0(this,"difficulty");G0(this,"gasLimit");G0(this,"gasUsed");G0(this,"miner");G0(this,"extraData");G0(this,"baseFeePerGas");q0(this,xn,void 0);m0(this,xn,a.transactions.map(et=>typeof et!="string"?new TransactionResponse(et,d):et)),defineProperties(this,{provider:d,hash:getValue(a.hash),number:a.number,timestamp:a.timestamp,parentHash:a.parentHash,nonce:a.nonce,difficulty:a.difficulty,gasLimit:a.gasLimit,gasUsed:a.gasUsed,miner:a.miner,extraData:a.extraData,baseFeePerGas:getValue(a.baseFeePerGas)})}get transactions(){return s0(this,xn).map(a=>typeof a=="string"?a:a.hash)}get prefetchedTransactions(){const a=s0(this,xn).slice();return a.length===0?[]:(assert$y(typeof a[0]=="object","transactions were not prefetched with block request","UNSUPPORTED_OPERATION",{operation:"transactionResponses()"}),a)}toJSON(){const{baseFeePerGas:a,difficulty:d,extraData:et,gasLimit:nt,gasUsed:tt,hash:bt,miner:mt,nonce:vt,number:$t,parentHash:At,timestamp:Mt,transactions:Tt}=this;return{_type:"Block",baseFeePerGas:toJson(a),difficulty:toJson(d),extraData:et,gasLimit:toJson(nt),gasUsed:toJson(tt),hash:bt,miner:mt,nonce:vt,number:$t,parentHash:At,timestamp:Mt,transactions:Tt}}[Symbol.iterator](){let a=0;const d=this.transactions;return{next:()=>anew Log(nt,d))));let et=BN_0$2;a.effectiveGasPrice!=null?et=a.effectiveGasPrice:a.gasPrice!=null&&(et=a.gasPrice),defineProperties(this,{provider:d,to:a.to,from:a.from,contractAddress:a.contractAddress,hash:a.hash,index:a.index,blockHash:a.blockHash,blockNumber:a.blockNumber,logsBloom:a.logsBloom,gasUsed:a.gasUsed,cumulativeGasUsed:a.cumulativeGasUsed,gasPrice:et,type:a.type,status:a.status,root:a.root})}get logs(){return s0(this,co)}toJSON(){const{to:a,from:d,contractAddress:et,hash:nt,index:tt,blockHash:bt,blockNumber:mt,logsBloom:vt,logs:$t,status:At,root:Mt}=this;return{_type:"TransactionReceipt",blockHash:bt,blockNumber:mt,contractAddress:et,cumulativeGasUsed:toJson(this.cumulativeGasUsed),from:d,gasPrice:toJson(this.gasPrice),gasUsed:toJson(this.gasUsed),hash:nt,index:tt,logs:$t,logsBloom:vt,root:Mt,status:At,to:a}}get length(){return this.logs.length}[Symbol.iterator](){let a=0;return{next:()=>a{if(mt)return null;const{blockNumber:Tt,nonce:Rt}=await resolveProperties$1({blockNumber:this.provider.getBlockNumber(),nonce:this.provider.getTransactionCount(this.from)});if(Rt{if(Tt==null||Tt.status!==0)return Tt;assert$y(!1,"transaction execution reverted","CALL_EXCEPTION",{action:"sendTransaction",data:null,reason:null,invocation:null,revert:null,transaction:{to:Tt.to,from:Tt.from,data:""},receipt:Tt})},At=await this.provider.getTransactionReceipt(this.hash);if(et===0)return $t(At);if(At){if(await At.confirmations()>=et)return $t(At)}else if(await vt(),et===0)return null;return await new Promise((Tt,Rt)=>{const kt=[],It=()=>{kt.forEach(Nt=>Nt())};if(kt.push(()=>{mt=!0}),nt>0){const Nt=setTimeout(()=>{It(),Rt(makeError("wait for transaction timeout","TIMEOUT"))},nt);kt.push(()=>{clearTimeout(Nt)})}const Dt=async Nt=>{if(await Nt.confirmations()>=et){It();try{Tt($t(Nt))}catch(Ot){Rt(Ot)}}};if(kt.push(()=>{this.provider.off(this.hash,Dt)}),this.provider.on(this.hash,Dt),tt>=0){const Nt=async()=>{try{await vt()}catch(Ot){if(isError$1(Ot,"TRANSACTION_REPLACED")){It(),Rt(Ot);return}}mt||this.provider.once("block",Nt)};kt.push(()=>{this.provider.off("block",Nt)}),this.provider.once("block",Nt)}})}isMined(){return this.blockHash!=null}isLegacy(){return this.type===0}isBerlin(){return this.type===1}isLondon(){return this.type===2}removedEvent(){return assert$y(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),createRemovedTransactionFilter(this)}reorderedEvent(a){return assert$y(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),assert$y(!a||a.isMined(),"unmined 'other' transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),createReorderedTransactionFilter(this,a)}replaceableTransaction(a){assertArgument(Number.isInteger(a)&&a>=0,"invalid startBlock","startBlock",a);const d=new _f(this,this.provider);return m0(d,kn,a),d}};kn=new WeakMap;let TransactionResponse=_f;function createOrphanedBlockFilter(c){return{orphan:"drop-block",hash:c.hash,number:c.number}}function createReorderedTransactionFilter(c,a){return{orphan:"reorder-transaction",tx:c,other:a}}function createRemovedTransactionFilter(c){return{orphan:"drop-transaction",tx:c}}function createRemovedLogFilter(c){return{orphan:"drop-log",log:{transactionHash:c.transactionHash,blockHash:c.blockHash,blockNumber:c.blockNumber,address:c.address,data:c.data,topics:Object.freeze(c.topics.slice()),index:c.index}}}class EventLog extends Log{constructor(d,et,nt){super(d,d.provider);G0(this,"interface");G0(this,"fragment");G0(this,"args");const tt=et.decodeEventLog(nt,d.data,d.topics);defineProperties(this,{args:tt,fragment:nt,interface:et})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}class UndecodedEventLog extends Log{constructor(d,et){super(d,d.provider);G0(this,"error");defineProperties(this,{error:et})}}var ks;class ContractTransactionReceipt extends TransactionReceipt{constructor(d,et,nt){super(nt,et);q0(this,ks,void 0);m0(this,ks,d)}get logs(){return super.logs.map(d=>{const et=d.topics.length?s0(this,ks).getEvent(d.topics[0]):null;if(et)try{return new EventLog(d,s0(this,ks),et)}catch(nt){return new UndecodedEventLog(d,nt)}return d})}}ks=new WeakMap;var lo;class ContractTransactionResponse extends TransactionResponse{constructor(d,et,nt){super(nt,et);q0(this,lo,void 0);m0(this,lo,d)}async wait(d){const et=await super.wait(d);return et==null?null:new ContractTransactionReceipt(s0(this,lo),this.provider,et)}}lo=new WeakMap;class ContractUnknownEventPayload extends EventPayload{constructor(d,et,nt,tt){super(d,et,nt);G0(this,"log");defineProperties(this,{log:tt})}async getBlock(){return await this.log.getBlock()}async getTransaction(){return await this.log.getTransaction()}async getTransactionReceipt(){return await this.log.getTransactionReceipt()}}class ContractEventPayload extends ContractUnknownEventPayload{constructor(a,d,et,nt,tt){super(a,d,et,new EventLog(tt,a.interface,nt));const bt=a.interface.decodeEventLog(nt,this.log.data,this.log.topics);defineProperties(this,{args:bt,fragment:nt})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}const BN_0$1=BigInt(0);function canCall(c){return c&&typeof c.call=="function"}function canEstimate(c){return c&&typeof c.estimateGas=="function"}function canResolve(c){return c&&typeof c.resolveName=="function"}function canSend(c){return c&&typeof c.sendTransaction=="function"}var uo;class PreparedTopicFilter{constructor(a,d,et){q0(this,uo,void 0);G0(this,"fragment");if(defineProperties(this,{fragment:d}),d.inputs.lengthet[vt]==null?null:mt.walkAsync(et[vt],(At,Mt)=>At==="address"?Array.isArray(Mt)?Promise.all(Mt.map(Tt=>resolveAddress(Tt,tt))):resolveAddress(Mt,tt):Mt)));return a.interface.encodeFilterTopics(d,bt)}())}getTopicFilter(){return s0(this,uo)}}uo=new WeakMap;function getRunner(c,a){return c==null?null:typeof c[a]=="function"?c:c.provider&&typeof c.provider[a]=="function"?c.provider:null}function getProvider$1(c){return c==null?null:c.provider||null}async function copyOverrides(c,a){const d=Typed.dereference(c,"overrides");assertArgument(typeof d=="object","invalid overrides parameter","overrides",c);const et=copyRequest(d);return assertArgument(et.to==null||(a||[]).indexOf("to")>=0,"cannot override to","overrides.to",et.to),assertArgument(et.data==null||(a||[]).indexOf("data")>=0,"cannot override data","overrides.data",et.data),et.from&&(et.from=await resolveAddress(et.from)),et}async function resolveArgs(c,a,d){const et=getRunner(c,"resolveName"),nt=canResolve(et)?et:null;return await Promise.all(a.map((tt,bt)=>tt.walkAsync(d[bt],(mt,vt)=>(vt=Typed.dereference(vt,mt),mt==="address"?resolveAddress(vt,nt):vt))))}function buildWrappedFallback(c){const a=async function(bt){const mt=await copyOverrides(bt,["data"]);mt.to=await c.getAddress();const vt=c.interface,$t=getBigInt(mt.value||BN_0$1,"overrides.value")===BN_0$1,At=(mt.data||"0x")==="0x";vt.fallback&&!vt.fallback.payable&&vt.receive&&!At&&!$t&&assertArgument(!1,"cannot send data to receive or send value to non-payable fallback","overrides",bt),assertArgument(vt.fallback||At,"cannot send data to receive-only contract","overrides.data",mt.data);const Mt=vt.receive||vt.fallback&&vt.fallback.payable;return assertArgument(Mt||$t,"cannot send value to non-payable fallback","overrides.value",mt.value),assertArgument(vt.fallback||At,"cannot send data to receive-only contract","overrides.data",mt.data),mt},d=async function(bt){const mt=getRunner(c.runner,"call");assert$y(canCall(mt),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const vt=await a(bt);try{return await mt.call(vt)}catch($t){throw isCallException($t)&&$t.data?c.interface.makeError($t.data,vt):$t}},et=async function(bt){const mt=c.runner;assert$y(canSend(mt),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const vt=await mt.sendTransaction(await a(bt)),$t=getProvider$1(c.runner);return new ContractTransactionResponse(c.interface,$t,vt)},nt=async function(bt){const mt=getRunner(c.runner,"estimateGas");return assert$y(canEstimate(mt),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await mt.estimateGas(await a(bt))},tt=async bt=>await et(bt);return defineProperties(tt,{_contract:c,estimateGas:nt,populateTransaction:a,send:et,staticCall:d}),tt}function buildWrappedMethod(c,a){const d=function(...$t){const At=c.interface.getFunction(a,$t);return assert$y(At,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:a,args:$t}}),At},et=async function(...$t){const At=d(...$t);let Mt={};if(At.inputs.length+1===$t.length&&(Mt=await copyOverrides($t.pop())),At.inputs.length!==$t.length)throw new Error("internal error: fragment inputs doesn't match arguments; should not happen");const Tt=await resolveArgs(c.runner,At.inputs,$t);return Object.assign({},Mt,await resolveProperties$1({to:c.getAddress(),data:c.interface.encodeFunctionData(At,Tt)}))},nt=async function(...$t){const At=await mt(...$t);return At.length===1?At[0]:At},tt=async function(...$t){const At=c.runner;assert$y(canSend(At),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const Mt=await At.sendTransaction(await et(...$t)),Tt=getProvider$1(c.runner);return new ContractTransactionResponse(c.interface,Tt,Mt)},bt=async function(...$t){const At=getRunner(c.runner,"estimateGas");return assert$y(canEstimate(At),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await At.estimateGas(await et(...$t))},mt=async function(...$t){const At=getRunner(c.runner,"call");assert$y(canCall(At),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const Mt=await et(...$t);let Tt="0x";try{Tt=await At.call(Mt)}catch(kt){throw isCallException(kt)&&kt.data?c.interface.makeError(kt.data,Mt):kt}const Rt=d(...$t);return c.interface.decodeFunctionResult(Rt,Tt)},vt=async(...$t)=>d(...$t).constant?await nt(...$t):await tt(...$t);return defineProperties(vt,{name:c.interface.getFunctionName(a),_contract:c,_key:a,getFragment:d,estimateGas:bt,populateTransaction:et,send:tt,staticCall:nt,staticCallResult:mt}),Object.defineProperty(vt,"fragment",{configurable:!1,enumerable:!0,get:()=>{const $t=c.interface.getFunction(a);return assert$y($t,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:a}}),$t}}),vt}function buildWrappedEvent(c,a){const d=function(...nt){const tt=c.interface.getEvent(a,nt);return assert$y(tt,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:a,args:nt}}),tt},et=function(...nt){return new PreparedTopicFilter(c,d(...nt),nt)};return defineProperties(et,{name:c.interface.getEventName(a),_contract:c,_key:a,getFragment:d}),Object.defineProperty(et,"fragment",{configurable:!1,enumerable:!0,get:()=>{const nt=c.interface.getEvent(a);return assert$y(nt,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment",info:{key:a}}),nt}}),et}const internal=Symbol.for("_ethersInternal_contract"),internalValues=new WeakMap;function setInternal(c,a){internalValues.set(c[internal],a)}function getInternal(c){return internalValues.get(c[internal])}function isDeferred(c){return c&&typeof c=="object"&&"getTopicFilter"in c&&typeof c.getTopicFilter=="function"&&c.fragment}async function getSubInfo(c,a){let d,et=null;if(Array.isArray(a)){const tt=function(bt){if(isHexString$1(bt,32))return bt;const mt=c.interface.getEvent(bt);return assertArgument(mt,"unknown fragment","name",bt),mt.topicHash};d=a.map(bt=>bt==null?null:Array.isArray(bt)?bt.map(tt):tt(bt))}else a==="*"?d=[null]:typeof a=="string"?isHexString$1(a,32)?d=[a]:(et=c.interface.getEvent(a),assertArgument(et,"unknown fragment","event",a),d=[et.topicHash]):isDeferred(a)?d=await a.getTopicFilter():"fragment"in a?(et=a.fragment,d=[et.topicHash]):assertArgument(!1,"unknown event name","event",a);d=d.map(tt=>{if(tt==null)return null;if(Array.isArray(tt)){const bt=Array.from(new Set(tt.map(mt=>mt.toLowerCase())).values());return bt.length===1?bt[0]:(bt.sort(),bt)}return tt.toLowerCase()});const nt=d.map(tt=>tt==null?"null":Array.isArray(tt)?tt.join("|"):tt).join("&");return{fragment:et,tag:nt,topics:d}}async function hasSub(c,a){const{subs:d}=getInternal(c);return d.get((await getSubInfo(c,a)).tag)||null}async function getSub(c,a,d){const et=getProvider$1(c.runner);assert$y(et,"contract runner does not support subscribing","UNSUPPORTED_OPERATION",{operation:a});const{fragment:nt,tag:tt,topics:bt}=await getSubInfo(c,d),{addr:mt,subs:vt}=getInternal(c);let $t=vt.get(tt);if(!$t){const Mt={address:mt||c,topics:bt},Tt=Dt=>{let Nt=nt;if(Nt==null)try{Nt=c.interface.getEvent(Dt.topics[0])}catch{}if(Nt){const Ot=Nt,Ut=nt?c.interface.decodeEventLog(nt,Dt.data,Dt.topics):[];emit(c,d,Ut,Gt=>new ContractEventPayload(c,Gt,d,Ot,Dt))}else emit(c,d,[],Ot=>new ContractUnknownEventPayload(c,Ot,d,Dt))};let Rt=[];$t={tag:tt,listeners:[],start:()=>{Rt.length||Rt.push(et.on(Mt,Tt))},stop:async()=>{if(Rt.length==0)return;let Dt=Rt;Rt=[],await Promise.all(Dt),et.off(Mt,Tt)}},vt.set(tt,$t)}return $t}let lastEmit=Promise.resolve();async function _emit(c,a,d,et){await lastEmit;const nt=await hasSub(c,a);if(!nt)return!1;const tt=nt.listeners.length;return nt.listeners=nt.listeners.filter(({listener:bt,once:mt})=>{const vt=Array.from(d);et&&vt.push(et(mt?null:bt));try{bt.call(c,...vt)}catch{}return!mt}),nt.listeners.length===0&&(nt.stop(),getInternal(c).subs.delete(nt.tag)),tt>0}async function emit(c,a,d,et){try{await lastEmit}catch{}const nt=_emit(c,a,d,et);return lastEmit=nt,await nt}const passProperties=["then"];var f1;const Xs=class Xs{constructor(a,d,et,nt){G0(this,"target");G0(this,"interface");G0(this,"runner");G0(this,"filters");G0(this,f1);G0(this,"fallback");assertArgument(typeof a=="string"||isAddressable(a),"invalid value for Contract target","target",a),et==null&&(et=null);const tt=Interface.from(d);defineProperties(this,{target:a,runner:et,interface:tt}),Object.defineProperty(this,internal,{value:{}});let bt,mt=null,vt=null;if(nt){const Mt=getProvider$1(et);vt=new ContractTransactionResponse(this.interface,Mt,nt)}let $t=new Map;if(typeof a=="string")if(isHexString$1(a))mt=a,bt=Promise.resolve(a);else{const Mt=getRunner(et,"resolveName");if(!canResolve(Mt))throw makeError("contract runner does not support name resolution","UNSUPPORTED_OPERATION",{operation:"resolveName"});bt=Mt.resolveName(a).then(Tt=>{if(Tt==null)throw makeError("an ENS name used for a contract target must be correctly configured","UNCONFIGURED_NAME",{value:a});return getInternal(this).addr=Tt,Tt})}else bt=a.getAddress().then(Mt=>{if(Mt==null)throw new Error("TODO");return getInternal(this).addr=Mt,Mt});setInternal(this,{addrPromise:bt,addr:mt,deployTx:vt,subs:$t});const At=new Proxy({},{get:(Mt,Tt,Rt)=>{if(typeof Tt=="symbol"||passProperties.indexOf(Tt)>=0)return Reflect.get(Mt,Tt,Rt);try{return this.getEvent(Tt)}catch(kt){if(!isError$1(kt,"INVALID_ARGUMENT")||kt.argument!=="key")throw kt}},has:(Mt,Tt)=>passProperties.indexOf(Tt)>=0?Reflect.has(Mt,Tt):Reflect.has(Mt,Tt)||this.interface.hasEvent(String(Tt))});return defineProperties(this,{filters:At}),defineProperties(this,{fallback:tt.receive||tt.fallback?buildWrappedFallback(this):null}),new Proxy(this,{get:(Mt,Tt,Rt)=>{if(typeof Tt=="symbol"||Tt in Mt||passProperties.indexOf(Tt)>=0)return Reflect.get(Mt,Tt,Rt);try{return Mt.getFunction(Tt)}catch(kt){if(!isError$1(kt,"INVALID_ARGUMENT")||kt.argument!=="key")throw kt}},has:(Mt,Tt)=>typeof Tt=="symbol"||Tt in Mt||passProperties.indexOf(Tt)>=0?Reflect.has(Mt,Tt):Mt.interface.hasFunction(Tt)})}connect(a){return new Xs(this.target,this.interface,a)}attach(a){return new Xs(a,this.interface,this.runner)}async getAddress(){return await getInternal(this).addrPromise}async getDeployedCode(){const a=getProvider$1(this.runner);assert$y(a,"runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"getDeployedCode"});const d=await a.getCode(await this.getAddress());return d==="0x"?null:d}async waitForDeployment(){const a=this.deploymentTransaction();if(a)return await a.wait(),this;if(await this.getDeployedCode()!=null)return this;const et=getProvider$1(this.runner);return assert$y(et!=null,"contract runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"waitForDeployment"}),new Promise((nt,tt)=>{const bt=async()=>{try{if(await this.getDeployedCode()!=null)return nt(this);et.once("block",bt)}catch(mt){tt(mt)}};bt()})}deploymentTransaction(){return getInternal(this).deployTx}getFunction(a){return typeof a!="string"&&(a=a.format()),buildWrappedMethod(this,a)}getEvent(a){return typeof a!="string"&&(a=a.format()),buildWrappedEvent(this,a)}async queryTransaction(a){throw new Error("@TODO")}async queryFilter(a,d,et){d==null&&(d=0),et==null&&(et="latest");const{addr:nt,addrPromise:tt}=getInternal(this),bt=nt||await tt,{fragment:mt,topics:vt}=await getSubInfo(this,a),$t={address:bt,topics:vt,fromBlock:d,toBlock:et},At=getProvider$1(this.runner);return assert$y(At,"contract runner does not have a provider","UNSUPPORTED_OPERATION",{operation:"queryFilter"}),(await At.getLogs($t)).map(Mt=>{let Tt=mt;if(Tt==null)try{Tt=this.interface.getEvent(Mt.topics[0])}catch{}if(Tt)try{return new EventLog(Mt,this.interface,Tt)}catch(Rt){return new UndecodedEventLog(Mt,Rt)}return new Log(Mt,At)})}async on(a,d){const et=await getSub(this,"on",a);return et.listeners.push({listener:d,once:!1}),et.start(),this}async once(a,d){const et=await getSub(this,"once",a);return et.listeners.push({listener:d,once:!0}),et.start(),this}async emit(a,...d){return await emit(this,a,d,null)}async listenerCount(a){if(a){const nt=await hasSub(this,a);return nt?nt.listeners.length:0}const{subs:d}=getInternal(this);let et=0;for(const{listeners:nt}of d.values())et+=nt.length;return et}async listeners(a){if(a){const nt=await hasSub(this,a);return nt?nt.listeners.map(({listener:tt})=>tt):[]}const{subs:d}=getInternal(this);let et=[];for(const{listeners:nt}of d.values())et=et.concat(nt.map(({listener:tt})=>tt));return et}async off(a,d){const et=await hasSub(this,a);if(!et)return this;if(d){const nt=et.listeners.map(({listener:tt})=>tt).indexOf(d);nt>=0&&et.listeners.splice(nt,1)}return(d==null||et.listeners.length===0)&&(et.stop(),getInternal(this).subs.delete(et.tag)),this}async removeAllListeners(a){if(a){const d=await hasSub(this,a);if(!d)return this;d.stop(),getInternal(this).subs.delete(d.tag)}else{const{subs:d}=getInternal(this);for(const{tag:et,stop:nt}of d.values())nt(),d.delete(et)}return this}async addListener(a,d){return await this.on(a,d)}async removeListener(a,d){return await this.off(a,d)}static buildClass(a){class d extends Xs{constructor(nt,tt=null){super(nt,a,tt)}}return d}static from(a,d,et){return et==null&&(et=null),new this(a,d,et)}};f1=internal;let BaseContract=Xs;function _ContractBase(){return BaseContract}class Contract extends _ContractBase(){}function getIpfsLink(c){return c.match(/^ipfs:\/\/ipfs\//i)?c=c.substring(12):c.match(/^ipfs:\/\//i)?c=c.substring(7):assertArgument(!1,"unsupported IPFS format","link",c),`https://gateway.ipfs.io/ipfs/${c}`}class MulticoinProviderPlugin{constructor(a){G0(this,"name");defineProperties(this,{name:a})}connect(a){return this}supportsCoinType(a){return!1}async encodeAddress(a,d){throw new Error("unsupported coin")}async decodeAddress(a,d){throw new Error("unsupported coin")}}const matcherIpfs=new RegExp("^(ipfs)://(.*)$","i"),matchers=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),matcherIpfs,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];var In,_i,Nn,is,Io,n1;const ss=class ss{constructor(a,d,et){q0(this,Nn);G0(this,"provider");G0(this,"address");G0(this,"name");q0(this,In,void 0);q0(this,_i,void 0);defineProperties(this,{provider:a,address:d,name:et}),m0(this,In,null),m0(this,_i,new Contract(d,["function supportsInterface(bytes4) view returns (bool)","function resolve(bytes, bytes) view returns (bytes)","function addr(bytes32) view returns (address)","function addr(bytes32, uint) view returns (bytes)","function text(bytes32, string) view returns (string)","function contenthash(bytes32) view returns (bytes)"],a))}async supportsWildcard(){return s0(this,In)==null&&m0(this,In,(async()=>{try{return await s0(this,_i).supportsInterface("0x9061b923")}catch(a){if(isError$1(a,"CALL_EXCEPTION"))return!1;throw m0(this,In,null),a}})()),await s0(this,In)}async getAddress(a){if(a==null&&(a=60),a===60)try{const tt=await W0(this,Nn,is).call(this,"addr(bytes32)");return tt==null||tt===ZeroAddress?null:tt}catch(tt){if(isError$1(tt,"CALL_EXCEPTION"))return null;throw tt}if(a>=0&&a<2147483648){let tt=a+2147483648;const bt=await W0(this,Nn,is).call(this,"addr(bytes32,uint)",[tt]);if(isHexString$1(bt,20))return getAddress$2(bt)}let d=null;for(const tt of this.provider.plugins)if(tt instanceof MulticoinProviderPlugin&&tt.supportsCoinType(a)){d=tt;break}if(d==null)return null;const et=await W0(this,Nn,is).call(this,"addr(bytes32,uint)",[a]);if(et==null||et==="0x")return null;const nt=await d.decodeAddress(a,et);if(nt!=null)return nt;assert$y(!1,"invalid coin data","UNSUPPORTED_OPERATION",{operation:`getAddress(${a})`,info:{coinType:a,data:et}})}async getText(a){const d=await W0(this,Nn,is).call(this,"text(bytes32,string)",[a]);return d==null||d==="0x"?null:d}async getContentHash(){const a=await W0(this,Nn,is).call(this,"contenthash(bytes32)");if(a==null||a==="0x")return null;const d=a.match(/^0x(e3010170|e5010172)(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(d){const nt=d[1]==="e3010170"?"ipfs":"ipns",tt=parseInt(d[4],16);if(d[5].length===tt*2)return`${nt}://${encodeBase58("0x"+d[2])}`}const et=a.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(et&&et[1].length===64)return`bzz://${et[1]}`;assert$y(!1,"invalid or unsupported content hash data","UNSUPPORTED_OPERATION",{operation:"getContentHash()",info:{data:a}})}async getAvatar(){return(await this._getAvatar()).url}async _getAvatar(){const a=[{type:"name",value:this.name}];try{const d=await this.getText("avatar");if(d==null)return a.push({type:"!avatar",value:""}),{url:null,linkage:a};a.push({type:"avatar",value:d});for(let et=0;et{if(!Array.isArray(a))throw new Error("not an array");return a.map(d=>c(d))}}function object(c,a){return d=>{const et={};for(const nt in c){let tt=nt;if(a&&nt in a&&!(tt in d)){for(const bt of a[nt])if(bt in d){tt=bt;break}}try{const bt=c[nt](d[tt]);bt!==void 0&&(et[nt]=bt)}catch(bt){const mt=bt instanceof Error?bt.message:"not-an-error";assert$y(!1,`invalid value for value.${nt} (${mt})`,"BAD_DATA",{value:d})}}return et}}function formatBoolean(c){switch(c){case!0:case"true":return!0;case!1:case"false":return!1}assertArgument(!1,`invalid boolean; ${JSON.stringify(c)}`,"value",c)}function formatData(c){return assertArgument(isHexString$1(c,!0),"invalid data","value",c),c}function formatHash(c){return assertArgument(isHexString$1(c,32),"invalid hash","value",c),c}const _formatLog=object({address:getAddress$2,blockHash:formatHash,blockNumber:getNumber,data:formatData,index:getNumber,removed:allowNull(formatBoolean,!1),topics:arrayOf(formatHash),transactionHash:formatHash,transactionIndex:getNumber},{index:["logIndex"]});function formatLog$1(c){return _formatLog(c)}const _formatBlock=object({hash:allowNull(formatHash),parentHash:formatHash,number:getNumber,timestamp:getNumber,nonce:allowNull(formatData),difficulty:getBigInt,gasLimit:getBigInt,gasUsed:getBigInt,miner:allowNull(getAddress$2),extraData:formatData,baseFeePerGas:allowNull(getBigInt)});function formatBlock$1(c){const a=_formatBlock(c);return a.transactions=c.transactions.map(d=>typeof d=="string"?d:formatTransactionResponse(d)),a}const _formatReceiptLog=object({transactionIndex:getNumber,blockNumber:getNumber,transactionHash:formatHash,address:getAddress$2,topics:arrayOf(formatHash),data:formatData,index:getNumber,blockHash:formatHash},{index:["logIndex"]});function formatReceiptLog(c){return _formatReceiptLog(c)}const _formatTransactionReceipt=object({to:allowNull(getAddress$2,null),from:allowNull(getAddress$2,null),contractAddress:allowNull(getAddress$2,null),index:getNumber,root:allowNull(hexlify$1),gasUsed:getBigInt,logsBloom:allowNull(formatData),blockHash:formatHash,hash:formatHash,logs:arrayOf(formatReceiptLog),blockNumber:getNumber,cumulativeGasUsed:getBigInt,effectiveGasPrice:allowNull(getBigInt),status:allowNull(getNumber),type:allowNull(getNumber,0)},{effectiveGasPrice:["gasPrice"],hash:["transactionHash"],index:["transactionIndex"]});function formatTransactionReceipt$1(c){return _formatTransactionReceipt(c)}function formatTransactionResponse(c){c.to&&getBigInt(c.to)===BN_0&&(c.to="0x0000000000000000000000000000000000000000");const a=object({hash:formatHash,type:d=>d==="0x"||d==null?0:getNumber(d),accessList:allowNull(accessListify$1,null),blockHash:allowNull(formatHash,null),blockNumber:allowNull(getNumber,null),transactionIndex:allowNull(getNumber,null),from:getAddress$2,gasPrice:allowNull(getBigInt),maxPriorityFeePerGas:allowNull(getBigInt),maxFeePerGas:allowNull(getBigInt),gasLimit:getBigInt,to:allowNull(getAddress$2,null),value:getBigInt,nonce:getNumber,data:formatData,creates:allowNull(getAddress$2,null),chainId:allowNull(getBigInt,null)},{data:["input"],gasLimit:["gas"]})(c);if(a.to==null&&a.creates==null&&(a.creates=getCreateAddress(a)),(c.type===1||c.type===2)&&c.accessList==null&&(a.accessList=[]),c.signature?a.signature=Signature$1.from(c.signature):a.signature=Signature$1.from(c),a.chainId==null){const d=a.signature.legacyChainId;d!=null&&(a.chainId=d)}return a.blockHash&&getBigInt(a.blockHash)===BN_0&&(a.blockHash=null),a}const EnsAddress="0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e";class NetworkPlugin{constructor(a){G0(this,"name");defineProperties(this,{name:a})}clone(){return new NetworkPlugin(this.name)}}class GasCostPlugin extends NetworkPlugin{constructor(d,et){d==null&&(d=0);super(`org.ethers.network.plugins.GasCost#${d||0}`);G0(this,"effectiveBlock");G0(this,"txBase");G0(this,"txCreate");G0(this,"txDataZero");G0(this,"txDataNonzero");G0(this,"txAccessListStorageKey");G0(this,"txAccessListAddress");const nt={effectiveBlock:d};function tt(bt,mt){let vt=(et||{})[bt];vt==null&&(vt=mt),assertArgument(typeof vt=="number",`invalud value for ${bt}`,"costs",et),nt[bt]=vt}tt("txBase",21e3),tt("txCreate",32e3),tt("txDataZero",4),tt("txDataNonzero",16),tt("txAccessListStorageKey",1900),tt("txAccessListAddress",2400),defineProperties(this,nt)}clone(){return new GasCostPlugin(this.effectiveBlock,this)}}class EnsPlugin extends NetworkPlugin{constructor(d,et){super("org.ethers.plugins.network.Ens");G0(this,"address");G0(this,"targetNetwork");defineProperties(this,{address:d||EnsAddress,targetNetwork:et??1})}clone(){return new EnsPlugin(this.address,this.targetNetwork)}}var ho,po;class FetchUrlFeeDataNetworkPlugin extends NetworkPlugin{constructor(d,et){super("org.ethers.plugins.network.FetchUrlFeeDataPlugin");q0(this,ho,void 0);q0(this,po,void 0);m0(this,ho,d),m0(this,po,et)}get url(){return s0(this,ho)}get processFunc(){return s0(this,po)}clone(){return this}}ho=new WeakMap,po=new WeakMap;const Networks=new Map;var Is,Ns,On;const os=class os{constructor(a,d){q0(this,Is,void 0);q0(this,Ns,void 0);q0(this,On,void 0);m0(this,Is,a),m0(this,Ns,getBigInt(d)),m0(this,On,new Map)}toJSON(){return{name:this.name,chainId:String(this.chainId)}}get name(){return s0(this,Is)}set name(a){m0(this,Is,a)}get chainId(){return s0(this,Ns)}set chainId(a){m0(this,Ns,getBigInt(a,"chainId"))}matches(a){if(a==null)return!1;if(typeof a=="string"){try{return this.chainId===getBigInt(a)}catch{}return this.name===a}if(typeof a=="number"||typeof a=="bigint"){try{return this.chainId===getBigInt(a)}catch{}return!1}if(typeof a=="object"){if(a.chainId!=null){try{return this.chainId===getBigInt(a.chainId)}catch{}return!1}return a.name!=null?this.name===a.name:!1}return!1}get plugins(){return Array.from(s0(this,On).values())}attachPlugin(a){if(s0(this,On).get(a.name))throw new Error(`cannot replace existing plugin: ${a.name} `);return s0(this,On).set(a.name,a.clone()),this}getPlugin(a){return s0(this,On).get(a)||null}getPlugins(a){return this.plugins.filter(d=>d.name.split("#")[0]===a)}clone(){const a=new os(this.name,this.chainId);return this.plugins.forEach(d=>{a.attachPlugin(d.clone())}),a}computeIntrinsicGas(a){const d=this.getPlugin("org.ethers.plugins.network.GasCost")||new GasCostPlugin;let et=d.txBase;if(a.to==null&&(et+=d.txCreate),a.data)for(let nt=2;nt9){let nt=BigInt(et[1].substring(0,9));et[1].substring(9).match(/^0+$/)||nt++,et[1]=nt.toString()}return BigInt(et[0]+et[1])}function getGasStationPlugin(c){return new FetchUrlFeeDataNetworkPlugin(c,async(a,d,et)=>{et.setHeader("User-Agent","ethers");let nt;try{const[tt,bt]=await Promise.all([et.send(),a()]);nt=tt;const mt=nt.bodyJson.standard;return{gasPrice:bt.gasPrice,maxFeePerGas:parseUnits(mt.maxFee,9),maxPriorityFeePerGas:parseUnits(mt.maxPriorityFee,9)}}catch(tt){assert$y(!1,`error encountered with polygon gas station (${JSON.stringify(et.url)})`,"SERVER_ERROR",{request:et,response:nt,error:tt})}})}function getPriorityFeePlugin(c){return new FetchUrlFeeDataNetworkPlugin("data:",async(a,d,et)=>{const nt=await a();if(nt.maxFeePerGas==null||nt.maxPriorityFeePerGas==null)return nt;const tt=nt.maxFeePerGas-nt.maxPriorityFeePerGas;return{gasPrice:nt.gasPrice,maxFeePerGas:tt+c,maxPriorityFeePerGas:c}})}let injected=!1;function injectCommonNetworks(){if(injected)return;injected=!0;function c(a,d,et){const nt=function(){const tt=new Network(a,d);return et.ensNetwork!=null&&tt.attachPlugin(new EnsPlugin(null,et.ensNetwork)),tt.attachPlugin(new GasCostPlugin),(et.plugins||[]).forEach(bt=>{tt.attachPlugin(bt)}),tt};Network.register(a,nt),Network.register(d,nt),et.altNames&&et.altNames.forEach(tt=>{Network.register(tt,nt)})}c("mainnet",1,{ensNetwork:1,altNames:["homestead"]}),c("ropsten",3,{ensNetwork:3}),c("rinkeby",4,{ensNetwork:4}),c("goerli",5,{ensNetwork:5}),c("kovan",42,{ensNetwork:42}),c("sepolia",11155111,{}),c("classic",61,{}),c("classicKotti",6,{}),c("arbitrum",42161,{ensNetwork:1}),c("arbitrum-goerli",421613,{}),c("bnb",56,{ensNetwork:1}),c("bnbt",97,{}),c("linea",59144,{ensNetwork:1}),c("linea-goerli",59140,{}),c("matic",137,{ensNetwork:1,plugins:[getGasStationPlugin("https://gasstation.polygon.technology/v2")]}),c("matic-mumbai",80001,{altNames:["maticMumbai","maticmum"],plugins:[getGasStationPlugin("https://gasstation-testnet.polygon.technology/v2")]}),c("optimism",10,{ensNetwork:1,plugins:[getPriorityFeePlugin(BigInt("1000000"))]}),c("optimism-goerli",420,{}),c("xdai",100,{ensNetwork:1})}function copy$3(c){return JSON.parse(JSON.stringify(c))}var wn,Vr,Dn,sn,Os,_o;class PollingBlockSubscriber{constructor(a){q0(this,Os);q0(this,wn,void 0);q0(this,Vr,void 0);q0(this,Dn,void 0);q0(this,sn,void 0);m0(this,wn,a),m0(this,Vr,null),m0(this,Dn,4e3),m0(this,sn,-2)}get pollingInterval(){return s0(this,Dn)}set pollingInterval(a){m0(this,Dn,a)}start(){s0(this,Vr)||(m0(this,Vr,s0(this,wn)._setTimeout(W0(this,Os,_o).bind(this),s0(this,Dn))),W0(this,Os,_o).call(this))}stop(){s0(this,Vr)&&(s0(this,wn)._clearTimeout(s0(this,Vr)),m0(this,Vr,null))}pause(a){this.stop(),a&&m0(this,sn,-2)}resume(){this.start()}}wn=new WeakMap,Vr=new WeakMap,Dn=new WeakMap,sn=new WeakMap,Os=new WeakSet,_o=async function(){try{const a=await s0(this,wn).getBlockNumber();if(s0(this,sn)===-2){m0(this,sn,a);return}if(a!==s0(this,sn)){for(let d=s0(this,sn)+1;d<=a;d++){if(s0(this,Vr)==null)return;await s0(this,wn).emit("block",d)}m0(this,sn,a)}}catch{}s0(this,Vr)!=null&&m0(this,Vr,s0(this,wn)._setTimeout(W0(this,Os,_o).bind(this),s0(this,Dn)))};var na,ba,Ln;class OnBlockSubscriber{constructor(a){q0(this,na,void 0);q0(this,ba,void 0);q0(this,Ln,void 0);m0(this,na,a),m0(this,Ln,!1),m0(this,ba,d=>{this._poll(d,s0(this,na))})}async _poll(a,d){throw new Error("sub-classes must override this")}start(){s0(this,Ln)||(m0(this,Ln,!0),s0(this,ba).call(this,-2),s0(this,na).on("block",s0(this,ba)))}stop(){s0(this,Ln)&&(m0(this,Ln,!1),s0(this,na).off("block",s0(this,ba)))}pause(a){this.stop()}resume(){this.start()}}na=new WeakMap,ba=new WeakMap,Ln=new WeakMap;var No;class PollingOrphanSubscriber extends OnBlockSubscriber{constructor(d,et){super(d);q0(this,No,void 0);m0(this,No,copy$3(et))}async _poll(d,et){throw new Error("@TODO")}}No=new WeakMap;var Ds;class PollingTransactionSubscriber extends OnBlockSubscriber{constructor(d,et){super(d);q0(this,Ds,void 0);m0(this,Ds,et)}async _poll(d,et){const nt=await et.getTransactionReceipt(s0(this,Ds));nt&&et.emit(s0(this,Ds),nt)}}Ds=new WeakMap;var En,Ls,Fs,Fn,Kr,Oo,i1;class PollingEventSubscriber{constructor(a,d){q0(this,Oo);q0(this,En,void 0);q0(this,Ls,void 0);q0(this,Fs,void 0);q0(this,Fn,void 0);q0(this,Kr,void 0);m0(this,En,a),m0(this,Ls,copy$3(d)),m0(this,Fs,W0(this,Oo,i1).bind(this)),m0(this,Fn,!1),m0(this,Kr,-2)}start(){s0(this,Fn)||(m0(this,Fn,!0),s0(this,Kr)===-2&&s0(this,En).getBlockNumber().then(a=>{m0(this,Kr,a)}),s0(this,En).on("block",s0(this,Fs)))}stop(){s0(this,Fn)&&(m0(this,Fn,!1),s0(this,En).off("block",s0(this,Fs)))}pause(a){this.stop(),a&&m0(this,Kr,-2)}resume(){this.start()}}En=new WeakMap,Ls=new WeakMap,Fs=new WeakMap,Fn=new WeakMap,Kr=new WeakMap,Oo=new WeakSet,i1=async function(a){if(s0(this,Kr)===-2)return;const d=copy$3(s0(this,Ls));d.fromBlock=s0(this,Kr)+1,d.toBlock=a;const et=await s0(this,En).getLogs(d);if(et.length===0){s0(this,Kr){if(et==null)return"null";if(typeof et=="bigint")return`bigint:${et.toString()}`;if(typeof et=="string")return et.toLowerCase();if(typeof et=="object"&&!Array.isArray(et)){const nt=Object.keys(et);return nt.sort(),nt.reduce((tt,bt)=>(tt[bt]=et[bt],tt),{})}return et})}class UnmanagedSubscriber{constructor(a){G0(this,"name");defineProperties(this,{name:a})}start(){}stop(){}pause(a){}resume(){}}function copy$2(c){return JSON.parse(JSON.stringify(c))}function concisify(c){return c=Array.from(new Set(c).values()),c.sort(),c}async function getSubscription(c,a){if(c==null)throw new Error("invalid event");if(Array.isArray(c)&&(c={topics:c}),typeof c=="string")switch(c){case"block":case"pending":case"debug":case"error":case"network":return{type:c,tag:c}}if(isHexString$1(c,32)){const d=c.toLowerCase();return{type:"transaction",tag:getTag("tx",{hash:d}),hash:d}}if(c.orphan){const d=c;return{type:"orphan",tag:getTag("orphan",d),filter:copy$2(d)}}if(c.address||c.topics){const d=c,et={topics:(d.topics||[]).map(nt=>nt==null?null:Array.isArray(nt)?concisify(nt.map(tt=>tt.toLowerCase())):nt.toLowerCase())};if(d.address){const nt=[],tt=[],bt=mt=>{isHexString$1(mt)?nt.push(mt):tt.push((async()=>{nt.push(await resolveAddress(mt,a))})())};Array.isArray(d.address)?d.address.forEach(bt):bt(d.address),tt.length&&await Promise.all(tt),et.address=concisify(nt.map(mt=>mt.toLowerCase()))}return{filter:et,tag:getTag("event",et),type:"event"}}assertArgument(!1,"unknown ProviderEvent","event",c)}function getTime(){return new Date().getTime()}const defaultOptions$1={cacheTimeout:250,pollingInterval:4e3};var Br,Un,kr,Us,Ur,ga,zn,$n,bo,Wr,zs,Hs,Nr,jr,mo,qo,yo,Vo,xa,Ys,go,Ko,$a,Zs,js,Po;class AbstractProvider{constructor(a,d){q0(this,Nr);q0(this,mo);q0(this,yo);q0(this,xa);q0(this,go);q0(this,$a);q0(this,js);q0(this,Br,void 0);q0(this,Un,void 0);q0(this,kr,void 0);q0(this,Us,void 0);q0(this,Ur,void 0);q0(this,ga,void 0);q0(this,zn,void 0);q0(this,$n,void 0);q0(this,bo,void 0);q0(this,Wr,void 0);q0(this,zs,void 0);q0(this,Hs,void 0);if(m0(this,Hs,Object.assign({},defaultOptions$1,d||{})),a==="any")m0(this,ga,!0),m0(this,Ur,null);else if(a){const et=Network.from(a);m0(this,ga,!1),m0(this,Ur,Promise.resolve(et)),setTimeout(()=>{this.emit("network",et,null)},0)}else m0(this,ga,!1),m0(this,Ur,null);m0(this,$n,-1),m0(this,zn,new Map),m0(this,Br,new Map),m0(this,Un,new Map),m0(this,kr,null),m0(this,Us,!1),m0(this,bo,1),m0(this,Wr,new Map),m0(this,zs,!1)}get pollingInterval(){return s0(this,Hs).pollingInterval}get provider(){return this}get plugins(){return Array.from(s0(this,Un).values())}attachPlugin(a){if(s0(this,Un).get(a.name))throw new Error(`cannot replace existing plugin: ${a.name} `);return s0(this,Un).set(a.name,a.connect(this)),this}getPlugin(a){return s0(this,Un).get(a)||null}get disableCcipRead(){return s0(this,zs)}set disableCcipRead(a){m0(this,zs,!!a)}async ccipReadFetch(a,d,et){if(this.disableCcipRead||et.length===0||a.to==null)return null;const nt=a.to.toLowerCase(),tt=d.toLowerCase(),bt=[];for(let mt=0;mt=500,`response not found during CCIP fetch: ${Mt}`,"OFFCHAIN_FAULT",{reason:"404_MISSING_RESOURCE",transaction:a,info:{url:vt,errorMessage:Mt}}),bt.push(Mt)}assert$y(!1,`error encountered during CCIP fetch: ${bt.map(mt=>JSON.stringify(mt)).join(", ")}`,"OFFCHAIN_FAULT",{reason:"500_SERVER_ERROR",transaction:a,info:{urls:et,errorMessages:bt}})}_wrapBlock(a,d){return new Block(formatBlock$1(a),this)}_wrapLog(a,d){return new Log(formatLog$1(a),this)}_wrapTransactionReceipt(a,d){return new TransactionReceipt(formatTransactionReceipt$1(a),this)}_wrapTransactionResponse(a,d){return new TransactionResponse(formatTransactionResponse(a),this)}_detectNetwork(){assert$y(!1,"sub-classes must implement this","UNSUPPORTED_OPERATION",{operation:"_detectNetwork"})}async _perform(a){assert$y(!1,`unsupported method: ${a.method}`,"UNSUPPORTED_OPERATION",{operation:a.method,info:a})}async getBlockNumber(){const a=getNumber(await W0(this,Nr,jr).call(this,{method:"getBlockNumber"}),"%response");return s0(this,$n)>=0&&m0(this,$n,a),a}_getAddress(a){return resolveAddress(a,this)}_getBlockTag(a){if(a==null)return"latest";switch(a){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return a}if(isHexString$1(a))return isHexString$1(a,32)?a:toQuantity(a);if(typeof a=="bigint"&&(a=getNumber(a,"blockTag")),typeof a=="number")return a>=0?toQuantity(a):s0(this,$n)>=0?toQuantity(s0(this,$n)+a):this.getBlockNumber().then(d=>toQuantity(d+a));assertArgument(!1,"invalid blockTag","blockTag",a)}_getFilter(a){const d=(a.topics||[]).map(vt=>vt==null?null:Array.isArray(vt)?concisify(vt.map($t=>$t.toLowerCase())):vt.toLowerCase()),et="blockHash"in a?a.blockHash:void 0,nt=(vt,$t,At)=>{let Mt;switch(vt.length){case 0:break;case 1:Mt=vt[0];break;default:vt.sort(),Mt=vt}if(et&&($t!=null||At!=null))throw new Error("invalid filter");const Tt={};return Mt&&(Tt.address=Mt),d.length&&(Tt.topics=d),$t&&(Tt.fromBlock=$t),At&&(Tt.toBlock=At),et&&(Tt.blockHash=et),Tt};let tt=[];if(a.address)if(Array.isArray(a.address))for(const vt of a.address)tt.push(this._getAddress(vt));else tt.push(this._getAddress(a.address));let bt;"fromBlock"in a&&(bt=this._getBlockTag(a.fromBlock));let mt;return"toBlock"in a&&(mt=this._getBlockTag(a.toBlock)),tt.filter(vt=>typeof vt!="string").length||bt!=null&&typeof bt!="string"||mt!=null&&typeof mt!="string"?Promise.all([Promise.all(tt),bt,mt]).then(vt=>nt(vt[0],vt[1],vt[2])):nt(tt,bt,mt)}_getTransactionRequest(a){const d=copyRequest(a),et=[];if(["to","from"].forEach(nt=>{if(d[nt]==null)return;const tt=resolveAddress(d[nt]);isPromise(tt)?et.push(async function(){d[nt]=await tt}()):d[nt]=tt}),d.blockTag!=null){const nt=this._getBlockTag(d.blockTag);isPromise(nt)?et.push(async function(){d.blockTag=await nt}()):d.blockTag=nt}return et.length?async function(){return await Promise.all(et),d}():d}async getNetwork(){if(s0(this,Ur)==null){const nt=this._detectNetwork().then(tt=>(this.emit("network",tt,null),tt),tt=>{throw s0(this,Ur)===nt&&m0(this,Ur,null),tt});return m0(this,Ur,nt),(await nt).clone()}const a=s0(this,Ur),[d,et]=await Promise.all([a,this._detectNetwork()]);return d.chainId!==et.chainId&&(s0(this,ga)?(this.emit("network",et,d),s0(this,Ur)===a&&m0(this,Ur,Promise.resolve(et))):assert$y(!1,`network changed: ${d.chainId} => ${et.chainId} `,"NETWORK_ERROR",{event:"changed"})),d.clone()}async getFeeData(){const a=await this.getNetwork(),d=async()=>{const{_block:nt,gasPrice:tt}=await resolveProperties$1({_block:W0(this,go,Ko).call(this,"latest",!1),gasPrice:(async()=>{try{const $t=await W0(this,Nr,jr).call(this,{method:"getGasPrice"});return getBigInt($t,"%response")}catch{}return null})()});let bt=null,mt=null;const vt=this._wrapBlock(nt,a);return vt&&vt.baseFeePerGas&&(mt=BigInt("1000000000"),bt=vt.baseFeePerGas*BN_2+mt),new FeeData(tt,bt,mt)},et=a.getPlugin("org.ethers.plugins.network.FetchUrlFeeDataPlugin");if(et){const nt=new FetchRequest(et.url),tt=await et.processFunc(d,this,nt);return new FeeData(tt.gasPrice,tt.maxFeePerGas,tt.maxPriorityFeePerGas)}return await d()}async estimateGas(a){let d=this._getTransactionRequest(a);return isPromise(d)&&(d=await d),getBigInt(await W0(this,Nr,jr).call(this,{method:"estimateGas",transaction:d}),"%response")}async call(a){const{tx:d,blockTag:et}=await resolveProperties$1({tx:this._getTransactionRequest(a),blockTag:this._getBlockTag(a.blockTag)});return await W0(this,yo,Vo).call(this,W0(this,mo,qo).call(this,d,et,a.enableCcipRead?0:-1))}async getBalance(a,d){return getBigInt(await W0(this,xa,Ys).call(this,{method:"getBalance"},a,d),"%response")}async getTransactionCount(a,d){return getNumber(await W0(this,xa,Ys).call(this,{method:"getTransactionCount"},a,d),"%response")}async getCode(a,d){return hexlify$1(await W0(this,xa,Ys).call(this,{method:"getCode"},a,d))}async getStorage(a,d,et){const nt=getBigInt(d,"position");return hexlify$1(await W0(this,xa,Ys).call(this,{method:"getStorage",position:nt},a,et))}async broadcastTransaction(a){const{blockNumber:d,hash:et,network:nt}=await resolveProperties$1({blockNumber:this.getBlockNumber(),hash:this._perform({method:"broadcastTransaction",signedTransaction:a}),network:this.getNetwork()}),tt=Transaction.from(a);if(tt.hash!==et)throw new Error("@TODO: the returned hash did not match");return this._wrapTransactionResponse(tt,nt).replaceableTransaction(d)}async getBlock(a,d){const{network:et,params:nt}=await resolveProperties$1({network:this.getNetwork(),params:W0(this,go,Ko).call(this,a,!!d)});return nt==null?null:this._wrapBlock(nt,et)}async getTransaction(a){const{network:d,params:et}=await resolveProperties$1({network:this.getNetwork(),params:W0(this,Nr,jr).call(this,{method:"getTransaction",hash:a})});return et==null?null:this._wrapTransactionResponse(et,d)}async getTransactionReceipt(a){const{network:d,params:et}=await resolveProperties$1({network:this.getNetwork(),params:W0(this,Nr,jr).call(this,{method:"getTransactionReceipt",hash:a})});if(et==null)return null;if(et.gasPrice==null&&et.effectiveGasPrice==null){const nt=await W0(this,Nr,jr).call(this,{method:"getTransaction",hash:a});if(nt==null)throw new Error("report this; could not find tx or effectiveGasPrice");et.effectiveGasPrice=nt.gasPrice}return this._wrapTransactionReceipt(et,d)}async getTransactionResult(a){const{result:d}=await resolveProperties$1({network:this.getNetwork(),result:W0(this,Nr,jr).call(this,{method:"getTransactionResult",hash:a})});return d==null?null:hexlify$1(d)}async getLogs(a){let d=this._getFilter(a);isPromise(d)&&(d=await d);const{network:et,params:nt}=await resolveProperties$1({network:this.getNetwork(),params:W0(this,Nr,jr).call(this,{method:"getLogs",filter:d})});return nt.map(tt=>this._wrapLog(tt,et))}_getProvider(a){assert$y(!1,"provider cannot connect to target network","UNSUPPORTED_OPERATION",{operation:"_getProvider()"})}async getResolver(a){return await EnsResolver.fromName(this,a)}async getAvatar(a){const d=await this.getResolver(a);return d?await d.getAvatar():null}async resolveName(a){const d=await this.getResolver(a);return d?await d.getAddress():null}async lookupAddress(a){a=getAddress$2(a);const d=namehash$1(a.substring(2).toLowerCase()+".addr.reverse");try{const et=await EnsResolver.getEnsAddress(this),tt=await new Contract(et,["function resolver(bytes32) view returns (address)"],this).resolver(d);if(tt==null||tt===ZeroAddress)return null;const mt=await new Contract(tt,["function name(bytes32) view returns (string)"],this).name(d);return await this.resolveName(mt)!==a?null:mt}catch(et){if(isError$1(et,"BAD_DATA")&&et.value==="0x"||isError$1(et,"CALL_EXCEPTION"))return null;throw et}return null}async waitForTransaction(a,d,et){const nt=d??1;return nt===0?this.getTransactionReceipt(a):new Promise(async(tt,bt)=>{let mt=null;const vt=async $t=>{try{const At=await this.getTransactionReceipt(a);if(At!=null&&$t-At.blockNumber+1>=nt){tt(At),mt&&(clearTimeout(mt),mt=null);return}}catch(At){console.log("EEE",At)}this.once("block",vt)};et!=null&&(mt=setTimeout(()=>{mt!=null&&(mt=null,this.off("block",vt),bt(makeError("timeout","TIMEOUT",{reason:"timeout"})))},et)),vt(await this.getBlockNumber())})}async waitForBlock(a){assert$y(!1,"not implemented yet","NOT_IMPLEMENTED",{operation:"waitForBlock"})}_clearTimeout(a){const d=s0(this,Wr).get(a);d&&(d.timer&&clearTimeout(d.timer),s0(this,Wr).delete(a))}_setTimeout(a,d){d==null&&(d=0);const et=Ws(this,bo)._++,nt=()=>{s0(this,Wr).delete(et),a()};if(this.paused)s0(this,Wr).set(et,{timer:null,func:nt,time:d});else{const tt=setTimeout(nt,d);s0(this,Wr).set(et,{timer:tt,func:nt,time:getTime()})}return et}_forEachSubscriber(a){for(const d of s0(this,Br).values())a(d.subscriber)}_getSubscriber(a){switch(a.type){case"debug":case"error":case"network":return new UnmanagedSubscriber(a.type);case"block":{const d=new PollingBlockSubscriber(this);return d.pollingInterval=this.pollingInterval,d}case"event":return new PollingEventSubscriber(this,a.filter);case"transaction":return new PollingTransactionSubscriber(this,a.hash);case"orphan":return new PollingOrphanSubscriber(this,a.filter)}throw new Error(`unsupported event: ${a.type}`)}_recoverSubscriber(a,d){for(const et of s0(this,Br).values())if(et.subscriber===a){et.started&&et.subscriber.stop(),et.subscriber=d,et.started&&d.start(),s0(this,kr)!=null&&d.pause(s0(this,kr));break}}async on(a,d){const et=await W0(this,js,Po).call(this,a);return et.listeners.push({listener:d,once:!1}),et.started||(et.subscriber.start(),et.started=!0,s0(this,kr)!=null&&et.subscriber.pause(s0(this,kr))),this}async once(a,d){const et=await W0(this,js,Po).call(this,a);return et.listeners.push({listener:d,once:!0}),et.started||(et.subscriber.start(),et.started=!0,s0(this,kr)!=null&&et.subscriber.pause(s0(this,kr))),this}async emit(a,...d){const et=await W0(this,$a,Zs).call(this,a,d);if(!et||et.listeners.length===0)return!1;const nt=et.listeners.length;return et.listeners=et.listeners.filter(({listener:tt,once:bt})=>{const mt=new EventPayload(this,bt?null:tt,a);try{tt.call(this,...d,mt)}catch{}return!bt}),et.listeners.length===0&&(et.started&&et.subscriber.stop(),s0(this,Br).delete(et.tag)),nt>0}async listenerCount(a){if(a){const et=await W0(this,$a,Zs).call(this,a);return et?et.listeners.length:0}let d=0;for(const{listeners:et}of s0(this,Br).values())d+=et.length;return d}async listeners(a){if(a){const et=await W0(this,$a,Zs).call(this,a);return et?et.listeners.map(({listener:nt})=>nt):[]}let d=[];for(const{listeners:et}of s0(this,Br).values())d=d.concat(et.map(({listener:nt})=>nt));return d}async off(a,d){const et=await W0(this,$a,Zs).call(this,a);if(!et)return this;if(d){const nt=et.listeners.map(({listener:tt})=>tt).indexOf(d);nt>=0&&et.listeners.splice(nt,1)}return(!d||et.listeners.length===0)&&(et.started&&et.subscriber.stop(),s0(this,Br).delete(et.tag)),this}async removeAllListeners(a){if(a){const{tag:d,started:et,subscriber:nt}=await W0(this,js,Po).call(this,a);et&&nt.stop(),s0(this,Br).delete(d)}else for(const[d,{started:et,subscriber:nt}]of s0(this,Br))et&&nt.stop(),s0(this,Br).delete(d);return this}async addListener(a,d){return await this.on(a,d)}async removeListener(a,d){return this.off(a,d)}get destroyed(){return s0(this,Us)}destroy(){this.removeAllListeners();for(const a of s0(this,Wr).keys())this._clearTimeout(a);m0(this,Us,!0)}get paused(){return s0(this,kr)!=null}set paused(a){!!a!==this.paused&&(this.paused?this.resume():this.pause(!1))}pause(a){if(m0(this,$n,-1),s0(this,kr)!=null){if(s0(this,kr)==!!a)return;assert$y(!1,"cannot change pause type; resume first","UNSUPPORTED_OPERATION",{operation:"pause"})}this._forEachSubscriber(d=>d.pause(a)),m0(this,kr,!!a);for(const d of s0(this,Wr).values())d.timer&&clearTimeout(d.timer),d.time=getTime()-d.time}resume(){if(s0(this,kr)!=null){this._forEachSubscriber(a=>a.resume()),m0(this,kr,null);for(const a of s0(this,Wr).values()){let d=a.time;d<0&&(d=0),a.time=getTime(),setTimeout(a.func,d)}}}}Br=new WeakMap,Un=new WeakMap,kr=new WeakMap,Us=new WeakMap,Ur=new WeakMap,ga=new WeakMap,zn=new WeakMap,$n=new WeakMap,bo=new WeakMap,Wr=new WeakMap,zs=new WeakMap,Hs=new WeakMap,Nr=new WeakSet,jr=async function(a){const d=s0(this,Hs).cacheTimeout;if(d<0)return await this._perform(a);const et=getTag(a.method,a);let nt=s0(this,zn).get(et);return nt||(nt=this._perform(a),s0(this,zn).set(et,nt),setTimeout(()=>{s0(this,zn).get(et)===nt&&s0(this,zn).delete(et)},d)),await nt},mo=new WeakSet,qo=async function(a,d,et){assert$y(et=0&&d==="latest"&&nt.to!=null&&dataSlice(tt.data,0,4)==="0x556f1830"){const bt=tt.data,mt=await resolveAddress(nt.to,this);let vt;try{vt=parseOffchainLookup(dataSlice(tt.data,4))}catch(Mt){assert$y(!1,Mt.message,"OFFCHAIN_FAULT",{reason:"BAD_DATA",transaction:nt,info:{data:bt}})}assert$y(vt.sender.toLowerCase()===mt.toLowerCase(),"CCIP Read sender mismatch","CALL_EXCEPTION",{action:"call",data:bt,reason:"OffchainLookup",transaction:nt,invocation:null,revert:{signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",name:"OffchainLookup",args:vt.errorArgs}});const $t=await this.ccipReadFetch(nt,vt.calldata,vt.urls);assert$y($t!=null,"CCIP Read failed to fetch data","OFFCHAIN_FAULT",{reason:"FETCH_FAILED",transaction:nt,info:{data:tt.data,errorArgs:vt.errorArgs}});const At={to:mt,data:concat$3([vt.selector,encodeBytes$2([$t,vt.extraData])])};this.emit("debug",{action:"sendCcipReadCall",transaction:At});try{const Mt=await W0(this,mo,qo).call(this,At,d,et+1);return this.emit("debug",{action:"receiveCcipReadCallResult",transaction:Object.assign({},At),result:Mt}),Mt}catch(Mt){throw this.emit("debug",{action:"receiveCcipReadCallError",transaction:Object.assign({},At),error:Mt}),Mt}}throw tt}},yo=new WeakSet,Vo=async function(a){const{value:d}=await resolveProperties$1({network:this.getNetwork(),value:a});return d},xa=new WeakSet,Ys=async function(a,d,et){let nt=this._getAddress(d),tt=this._getBlockTag(et);return(typeof nt!="string"||typeof tt!="string")&&([nt,tt]=await Promise.all([nt,tt])),await W0(this,yo,Vo).call(this,W0(this,Nr,jr).call(this,Object.assign(a,{address:nt,blockTag:tt})))},go=new WeakSet,Ko=async function(a,d){if(isHexString$1(a,32))return await W0(this,Nr,jr).call(this,{method:"getBlock",blockHash:a,includeTransactions:d});let et=this._getBlockTag(a);return typeof et!="string"&&(et=await et),await W0(this,Nr,jr).call(this,{method:"getBlock",blockTag:et,includeTransactions:d})},$a=new WeakSet,Zs=async function(a,d){let et=await getSubscription(a,this);return et.type==="event"&&d&&d.length>0&&d[0].removed===!0&&(et=await getSubscription({orphan:"drop-log",log:d[0]},this)),s0(this,Br).get(et.tag)||null},js=new WeakSet,Po=async function(a){const d=await getSubscription(a,this),et=d.tag;let nt=s0(this,Br).get(et);return nt||(nt={subscriber:this._getSubscriber(d),tag:et,addressableMap:new WeakMap,nameMap:new Map,started:!1,listeners:[]},s0(this,Br).set(et,nt)),nt};function _parseString(c,a){try{const d=_parseBytes(c,a);if(d)return toUtf8String(d)}catch{}return null}function _parseBytes(c,a){if(c==="0x")return null;try{const d=getNumber(dataSlice(c,a,a+32)),et=getNumber(dataSlice(c,d,d+32));return dataSlice(c,d+32,d+32+et)}catch{}return null}function numPad(c){const a=toBeArray(c);if(a.length>32)throw new Error("internal; should not happen");const d=new Uint8Array(32);return d.set(a,32-a.length),d}function bytesPad(c){if(c.length%32===0)return c;const a=new Uint8Array(Math.ceil(c.length/32)*32);return a.set(c),a}const empty=new Uint8Array([]);function encodeBytes$2(c){const a=[];let d=0;for(let et=0;et=5*32,"insufficient OffchainLookup data","OFFCHAIN_FAULT",{reason:"insufficient OffchainLookup data"});const d=dataSlice(c,0,32);assert$y(dataSlice(d,0,12)===dataSlice(zeros,0,12),"corrupt OffchainLookup sender","OFFCHAIN_FAULT",{reason:"corrupt OffchainLookup sender"}),a.sender=dataSlice(d,12);try{const et=[],nt=getNumber(dataSlice(c,32,64)),tt=getNumber(dataSlice(c,nt,nt+32)),bt=dataSlice(c,nt+32);for(let mt=0;mta[et]),a}function checkProvider(c,a){if(c.provider)return c.provider;assert$y(!1,"missing provider","UNSUPPORTED_OPERATION",{operation:a})}async function populate(c,a){let d=copyRequest(a);if(d.to!=null&&(d.to=resolveAddress(d.to,c)),d.from!=null){const et=d.from;d.from=Promise.all([c.getAddress(),resolveAddress(et,c)]).then(([nt,tt])=>(assertArgument(nt.toLowerCase()===tt.toLowerCase(),"transaction from mismatch","tx.from",tt),nt))}else d.from=c.getAddress();return await resolveProperties$1(d)}class AbstractSigner{constructor(a){G0(this,"provider");defineProperties(this,{provider:a||null})}async getNonce(a){return checkProvider(this,"getTransactionCount").getTransactionCount(await this.getAddress(),a)}async populateCall(a){return await populate(this,a)}async populateTransaction(a){const d=checkProvider(this,"populateTransaction"),et=await populate(this,a);et.nonce==null&&(et.nonce=await this.getNonce("pending")),et.gasLimit==null&&(et.gasLimit=await this.estimateGas(et));const nt=await this.provider.getNetwork();if(et.chainId!=null){const bt=getBigInt(et.chainId);assertArgument(bt===nt.chainId,"transaction chainId mismatch","tx.chainId",a.chainId)}else et.chainId=nt.chainId;const tt=et.maxFeePerGas!=null||et.maxPriorityFeePerGas!=null;if(et.gasPrice!=null&&(et.type===2||tt)?assertArgument(!1,"eip-1559 transaction do not support gasPrice","tx",a):(et.type===0||et.type===1)&&tt&&assertArgument(!1,"pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","tx",a),(et.type===2||et.type==null)&&et.maxFeePerGas!=null&&et.maxPriorityFeePerGas!=null)et.type=2;else if(et.type===0||et.type===1){const bt=await d.getFeeData();assert$y(bt.gasPrice!=null,"network does not support gasPrice","UNSUPPORTED_OPERATION",{operation:"getGasPrice"}),et.gasPrice==null&&(et.gasPrice=bt.gasPrice)}else{const bt=await d.getFeeData();if(et.type==null)if(bt.maxFeePerGas!=null&&bt.maxPriorityFeePerGas!=null)if(et.type=2,et.gasPrice!=null){const mt=et.gasPrice;delete et.gasPrice,et.maxFeePerGas=mt,et.maxPriorityFeePerGas=mt}else et.maxFeePerGas==null&&(et.maxFeePerGas=bt.maxFeePerGas),et.maxPriorityFeePerGas==null&&(et.maxPriorityFeePerGas=bt.maxPriorityFeePerGas);else bt.gasPrice!=null?(assert$y(!tt,"network does not support EIP-1559","UNSUPPORTED_OPERATION",{operation:"populateTransaction"}),et.gasPrice==null&&(et.gasPrice=bt.gasPrice),et.type=0):assert$y(!1,"failed to get consistent fee data","UNSUPPORTED_OPERATION",{operation:"signer.getFeeData"});else et.type===2&&(et.maxFeePerGas==null&&(et.maxFeePerGas=bt.maxFeePerGas),et.maxPriorityFeePerGas==null&&(et.maxPriorityFeePerGas=bt.maxPriorityFeePerGas))}return await resolveProperties$1(et)}async estimateGas(a){return checkProvider(this,"estimateGas").estimateGas(await this.populateCall(a))}async call(a){return checkProvider(this,"call").call(await this.populateCall(a))}async resolveName(a){return await checkProvider(this,"resolveName").resolveName(a)}async sendTransaction(a){const d=checkProvider(this,"sendTransaction"),et=await this.populateTransaction(a);delete et.from;const nt=Transaction.from(et);return await d.broadcastTransaction(await this.signTransaction(nt))}}function copy$1(c){return JSON.parse(JSON.stringify(c))}var Or,on,_a,Hn,es,Gs,vo,Wo,xo,Jo;class FilterIdSubscriber{constructor(a){q0(this,vo);q0(this,xo);q0(this,Or,void 0);q0(this,on,void 0);q0(this,_a,void 0);q0(this,Hn,void 0);q0(this,es,void 0);q0(this,Gs,void 0);m0(this,Or,a),m0(this,on,null),m0(this,_a,W0(this,vo,Wo).bind(this)),m0(this,Hn,!1),m0(this,es,null),m0(this,Gs,!1)}_subscribe(a){throw new Error("subclasses must override this")}_emitResults(a,d){throw new Error("subclasses must override this")}_recover(a){throw new Error("subclasses must override this")}start(){s0(this,Hn)||(m0(this,Hn,!0),W0(this,vo,Wo).call(this,-2))}stop(){s0(this,Hn)&&(m0(this,Hn,!1),m0(this,Gs,!0),W0(this,xo,Jo).call(this),s0(this,Or).off("block",s0(this,_a)))}pause(a){a&&W0(this,xo,Jo).call(this),s0(this,Or).off("block",s0(this,_a))}resume(){this.start()}}Or=new WeakMap,on=new WeakMap,_a=new WeakMap,Hn=new WeakMap,es=new WeakMap,Gs=new WeakMap,vo=new WeakSet,Wo=async function(a){try{s0(this,on)==null&&m0(this,on,this._subscribe(s0(this,Or)));let d=null;try{d=await s0(this,on)}catch(tt){if(!isError$1(tt,"UNSUPPORTED_OPERATION")||tt.operation!=="eth_newFilter")throw tt}if(d==null){m0(this,on,null),s0(this,Or)._recoverSubscriber(this,this._recover(s0(this,Or)));return}const et=await s0(this,Or).getNetwork();if(s0(this,es)||m0(this,es,et),s0(this,es).chainId!==et.chainId)throw new Error("chaid changed");if(s0(this,Gs))return;const nt=await s0(this,Or).send("eth_getFilterChanges",[d]);await this._emitResults(s0(this,Or),nt)}catch(d){console.log("@TODO",d)}s0(this,Or).once("block",s0(this,_a))},xo=new WeakSet,Jo=function(){const a=s0(this,on);a&&(m0(this,on,null),a.then(d=>{s0(this,Or).send("eth_uninstallFilter",[d])}))};var ts;class FilterIdEventSubscriber extends FilterIdSubscriber{constructor(d,et){super(d);q0(this,ts,void 0);m0(this,ts,copy$1(et))}_recover(d){return new PollingEventSubscriber(d,s0(this,ts))}async _subscribe(d){return await d.send("eth_newFilter",[s0(this,ts)])}async _emitResults(d,et){for(const nt of et)d.emit(s0(this,ts),d._wrapLog(nt,d._network))}}ts=new WeakMap;class FilterIdPendingSubscriber extends FilterIdSubscriber{async _subscribe(a){return await a.send("eth_newPendingTransactionFilter",[])}async _emitResults(a,d){for(const et of d)a.emit("pending",et)}}const Primitive="bigint,boolean,function,number,string,symbol".split(/,/g);function deepCopy$1(c){if(c==null||Primitive.indexOf(typeof c)>=0||typeof c.getAddress=="function")return c;if(Array.isArray(c))return c.map(deepCopy$1);if(typeof c=="object")return Object.keys(c).reduce((a,d)=>(a[d]=c[d],a),{});throw new Error(`should not happen: ${c} (${typeof c})`)}function stall(c){return new Promise(a=>{setTimeout(a,c)})}function getLowerCase$1(c){return c&&c.toLowerCase()}function isPollable(c){return c&&typeof c.pollingInterval=="number"}const defaultOptions={polling:!1,staticNetwork:null,batchStallTime:10,batchMaxSize:1<<20,batchMaxCount:100,cacheTimeout:250,pollingInterval:4e3};class JsonRpcSigner extends AbstractSigner{constructor(d,et){super(d);G0(this,"address");et=getAddress$2(et),defineProperties(this,{address:et})}connect(d){assert$y(!1,"cannot reconnect JsonRpcSigner","UNSUPPORTED_OPERATION",{operation:"signer.connect"})}async getAddress(){return this.address}async populateTransaction(d){return await this.populateCall(d)}async sendUncheckedTransaction(d){const et=deepCopy$1(d),nt=[];if(et.from){const bt=et.from;nt.push((async()=>{const mt=await resolveAddress(bt,this.provider);assertArgument(mt!=null&&mt.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",d),et.from=mt})())}else et.from=this.address;if(et.gasLimit==null&&nt.push((async()=>{et.gasLimit=await this.provider.estimateGas({...et,from:this.address})})()),et.to!=null){const bt=et.to;nt.push((async()=>{et.to=await resolveAddress(bt,this.provider)})())}nt.length&&await Promise.all(nt);const tt=this.provider.getRpcTransaction(et);return this.provider.send("eth_sendTransaction",[tt])}async sendTransaction(d){const et=await this.provider.getBlockNumber(),nt=await this.sendUncheckedTransaction(d);return await new Promise((tt,bt)=>{const mt=[1e3,100],vt=async()=>{const $t=await this.provider.getTransaction(nt);if($t!=null){tt($t.replaceableTransaction(et));return}this.provider._setTimeout(()=>{vt()},mt.pop()||4e3)};vt()})}async signTransaction(d){const et=deepCopy$1(d);if(et.from){const tt=await resolveAddress(et.from,this.provider);assertArgument(tt!=null&&tt.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",d),et.from=tt}else et.from=this.address;const nt=this.provider.getRpcTransaction(et);return await this.provider.send("eth_signTransaction",[nt])}async signMessage(d){const et=typeof d=="string"?toUtf8Bytes$1(d):d;return await this.provider.send("personal_sign",[hexlify$1(et),this.address.toLowerCase()])}async signTypedData(d,et,nt){const tt=deepCopy$1(nt),bt=await TypedDataEncoder$1.resolveNames(d,et,tt,async mt=>{const vt=await resolveAddress(mt);return assertArgument(vt!=null,"TypedData does not support null address","value",mt),vt});return await this.provider.send("eth_signTypedData_v4",[this.address.toLowerCase(),JSON.stringify(TypedDataEncoder$1.getPayload(bt.domain,et,bt.value))])}async unlock(d){return this.provider.send("personal_unlockAccount",[this.address.toLowerCase(),d,null])}async _legacySignMessage(d){const et=typeof d=="string"?toUtf8Bytes$1(d):d;return await this.provider.send("eth_sign",[this.address.toLowerCase(),hexlify$1(et)])}}var rs,qs,Sn,fn,en,An,wo,Yo;class JsonRpcApiProvider extends AbstractProvider{constructor(d,et){super(d,et);q0(this,wo);q0(this,rs,void 0);q0(this,qs,void 0);q0(this,Sn,void 0);q0(this,fn,void 0);q0(this,en,void 0);q0(this,An,void 0);m0(this,qs,1),m0(this,rs,Object.assign({},defaultOptions,et||{})),m0(this,Sn,[]),m0(this,fn,null),m0(this,An,null);{let tt=null;const bt=new Promise(mt=>{tt=mt});m0(this,en,{promise:bt,resolve:tt})}const nt=this._getOption("staticNetwork");nt&&(assertArgument(d==null||nt.matches(d),"staticNetwork MUST match network object","options",et),m0(this,An,nt))}_getOption(d){return s0(this,rs)[d]}get _network(){return assert$y(s0(this,An),"network is not available yet","NETWORK_ERROR"),s0(this,An)}async _perform(d){if(d.method==="call"||d.method==="estimateGas"){let nt=d.transaction;if(nt&&nt.type!=null&&getBigInt(nt.type)&&nt.maxFeePerGas==null&&nt.maxPriorityFeePerGas==null){const tt=await this.getFeeData();tt.maxFeePerGas==null&&tt.maxPriorityFeePerGas==null&&(d=Object.assign({},d,{transaction:Object.assign({},nt,{type:void 0})}))}}const et=this.getRpcRequest(d);return et!=null?await this.send(et.method,et.args):super._perform(d)}async _detectNetwork(){const d=this._getOption("staticNetwork");if(d)return d;if(this.ready)return Network.from(getBigInt(await this.send("eth_chainId",[])));const et={id:Ws(this,qs)._++,method:"eth_chainId",params:[],jsonrpc:"2.0"};this.emit("debug",{action:"sendRpcPayload",payload:et});let nt;try{nt=(await this._send(et))[0]}catch(tt){throw this.emit("debug",{action:"receiveRpcError",error:tt}),tt}if(this.emit("debug",{action:"receiveRpcResult",result:nt}),"result"in nt)return Network.from(getBigInt(nt.result));throw this.getRpcError(et,nt)}_start(){s0(this,en)==null||s0(this,en).resolve==null||(s0(this,en).resolve(),m0(this,en,null),(async()=>{for(;s0(this,An)==null&&!this.destroyed;)try{m0(this,An,await this._detectNetwork())}catch(d){if(this.destroyed)break;console.log("JsonRpcProvider failed to detect network and cannot start up; retry in 1s (perhaps the URL is wrong or the node is not started)"),this.emit("error",makeError("failed to bootstrap network detection","NETWORK_ERROR",{event:"initial-network-discovery",info:{error:d}})),await stall(1e3)}W0(this,wo,Yo).call(this)})())}async _waitUntilReady(){if(s0(this,en)!=null)return await s0(this,en).promise}_getSubscriber(d){return d.type==="pending"?new FilterIdPendingSubscriber(this):d.type==="event"?this._getOption("polling")?new PollingEventSubscriber(this,d.filter):new FilterIdEventSubscriber(this,d.filter):d.type==="orphan"&&d.filter.orphan==="drop-log"?new UnmanagedSubscriber("orphan"):super._getSubscriber(d)}get ready(){return s0(this,en)==null}getRpcTransaction(d){const et={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(nt=>{if(d[nt]==null)return;let tt=nt;nt==="gasLimit"&&(tt="gas"),et[tt]=toQuantity(getBigInt(d[nt],`tx.${nt}`))}),["from","to","data"].forEach(nt=>{d[nt]!=null&&(et[nt]=hexlify$1(d[nt]))}),d.accessList&&(et.accessList=accessListify$1(d.accessList)),et}getRpcRequest(d){switch(d.method){case"chainId":return{method:"eth_chainId",args:[]};case"getBlockNumber":return{method:"eth_blockNumber",args:[]};case"getGasPrice":return{method:"eth_gasPrice",args:[]};case"getBalance":return{method:"eth_getBalance",args:[getLowerCase$1(d.address),d.blockTag]};case"getTransactionCount":return{method:"eth_getTransactionCount",args:[getLowerCase$1(d.address),d.blockTag]};case"getCode":return{method:"eth_getCode",args:[getLowerCase$1(d.address),d.blockTag]};case"getStorage":return{method:"eth_getStorageAt",args:[getLowerCase$1(d.address),"0x"+d.position.toString(16),d.blockTag]};case"broadcastTransaction":return{method:"eth_sendRawTransaction",args:[d.signedTransaction]};case"getBlock":if("blockTag"in d)return{method:"eth_getBlockByNumber",args:[d.blockTag,!!d.includeTransactions]};if("blockHash"in d)return{method:"eth_getBlockByHash",args:[d.blockHash,!!d.includeTransactions]};break;case"getTransaction":return{method:"eth_getTransactionByHash",args:[d.hash]};case"getTransactionReceipt":return{method:"eth_getTransactionReceipt",args:[d.hash]};case"call":return{method:"eth_call",args:[this.getRpcTransaction(d.transaction),d.blockTag]};case"estimateGas":return{method:"eth_estimateGas",args:[this.getRpcTransaction(d.transaction)]};case"getLogs":return d.filter&&d.filter.address!=null&&(Array.isArray(d.filter.address)?d.filter.address=d.filter.address.map(getLowerCase$1):d.filter.address=getLowerCase$1(d.filter.address)),{method:"eth_getLogs",args:[d.filter]}}return null}getRpcError(d,et){const{method:nt}=d,{error:tt}=et;if(nt==="eth_estimateGas"&&tt.message){const vt=tt.message;if(!vt.match(/revert/i)&&vt.match(/insufficient funds/i))return makeError("insufficient funds","INSUFFICIENT_FUNDS",{transaction:d.params[0],info:{payload:d,error:tt}})}if(nt==="eth_call"||nt==="eth_estimateGas"){const vt=spelunkData(tt),$t=AbiCoder.getBuiltinCallException(nt==="eth_call"?"call":"estimateGas",d.params[0],vt?vt.data:null);return $t.info={error:tt,payload:d},$t}const bt=JSON.stringify(spelunkMessage(tt));if(typeof tt.message=="string"&&tt.message.match(/user denied|ethers-user-denied/i))return makeError("user rejected action","ACTION_REJECTED",{action:{eth_sign:"signMessage",personal_sign:"signMessage",eth_signTypedData_v4:"signTypedData",eth_signTransaction:"signTransaction",eth_sendTransaction:"sendTransaction",eth_requestAccounts:"requestAccess",wallet_requestAccounts:"requestAccess"}[nt]||"unknown",reason:"rejected",info:{payload:d,error:tt}});if(nt==="eth_sendRawTransaction"||nt==="eth_sendTransaction"){const vt=d.params[0];if(bt.match(/insufficient funds|base fee exceeds gas limit/i))return makeError("insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:vt,info:{error:tt}});if(bt.match(/nonce/i)&&bt.match(/too low/i))return makeError("nonce has already been used","NONCE_EXPIRED",{transaction:vt,info:{error:tt}});if(bt.match(/replacement transaction/i)&&bt.match(/underpriced/i))return makeError("replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:vt,info:{error:tt}});if(bt.match(/only replay-protected/i))return makeError("legacy pre-eip-155 transactions not supported","UNSUPPORTED_OPERATION",{operation:nt,info:{transaction:vt,info:{error:tt}}})}let mt=!!bt.match(/the method .* does not exist/i);return mt||tt&&tt.details&&tt.details.startsWith("Unauthorized method:")&&(mt=!0),mt?makeError("unsupported operation","UNSUPPORTED_OPERATION",{operation:d.method,info:{error:tt,payload:d}}):makeError("could not coalesce error","UNKNOWN_ERROR",{error:tt,payload:d})}send(d,et){if(this.destroyed)return Promise.reject(makeError("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:d}));const nt=Ws(this,qs)._++,tt=new Promise((bt,mt)=>{s0(this,Sn).push({resolve:bt,reject:mt,payload:{method:d,params:et,id:nt,jsonrpc:"2.0"}})});return W0(this,wo,Yo).call(this),tt}async getSigner(d){d==null&&(d=0);const et=this.send("eth_accounts",[]);if(typeof d=="number"){const tt=await et;if(d>=tt.length)throw new Error("no such account");return new JsonRpcSigner(this,tt[d])}const{accounts:nt}=await resolveProperties$1({network:this.getNetwork(),accounts:et});d=getAddress$2(d);for(const tt of nt)if(getAddress$2(tt)===d)return new JsonRpcSigner(this,d);throw new Error("invalid account")}async listAccounts(){return(await this.send("eth_accounts",[])).map(et=>new JsonRpcSigner(this,et))}destroy(){s0(this,fn)&&(clearTimeout(s0(this,fn)),m0(this,fn,null));for(const{payload:d,reject:et}of s0(this,Sn))et(makeError("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:d.method}));m0(this,Sn,[]),super.destroy()}}rs=new WeakMap,qs=new WeakMap,Sn=new WeakMap,fn=new WeakMap,en=new WeakMap,An=new WeakMap,wo=new WeakSet,Yo=function(){if(s0(this,fn))return;const d=this._getOption("batchMaxCount")===1?0:this._getOption("batchStallTime");m0(this,fn,setTimeout(()=>{m0(this,fn,null);const et=s0(this,Sn);for(m0(this,Sn,[]);et.length;){const nt=[et.shift()];for(;et.length&&nt.length!==s0(this,rs).batchMaxCount;)if(nt.push(et.shift()),JSON.stringify(nt.map(bt=>bt.payload)).length>s0(this,rs).batchMaxSize){et.unshift(nt.pop());break}(async()=>{const tt=nt.length===1?nt[0].payload:nt.map(bt=>bt.payload);this.emit("debug",{action:"sendRpcPayload",payload:tt});try{const bt=await this._send(tt);this.emit("debug",{action:"receiveRpcResult",result:bt});for(const{resolve:mt,reject:vt,payload:$t}of nt){if(this.destroyed){vt(makeError("provider destroyed; cancelled request","UNSUPPORTED_OPERATION",{operation:$t.method}));continue}const At=bt.filter(Mt=>Mt.id===$t.id)[0];if(At==null){const Mt=makeError("missing response for request","BAD_DATA",{value:bt,info:{payload:$t}});this.emit("error",Mt),vt(Mt);continue}if("error"in At){vt(this.getRpcError($t,At));continue}mt(At.result)}}catch(bt){this.emit("debug",{action:"receiveRpcError",error:bt});for(const{reject:mt}of nt)mt(bt)}})()}},d))};var jn;class JsonRpcApiPollingProvider extends JsonRpcApiProvider{constructor(d,et){super(d,et);q0(this,jn,void 0);m0(this,jn,4e3)}_getSubscriber(d){const et=super._getSubscriber(d);return isPollable(et)&&(et.pollingInterval=s0(this,jn)),et}get pollingInterval(){return s0(this,jn)}set pollingInterval(d){if(!Number.isInteger(d)||d<0)throw new Error("invalid interval");m0(this,jn,d),this._forEachSubscriber(et=>{isPollable(et)&&(et.pollingInterval=s0(this,jn))})}}jn=new WeakMap;var Vs;class JsonRpcProvider extends JsonRpcApiPollingProvider{constructor(d,et,nt){d==null&&(d="http://localhost:8545");super(et,nt);q0(this,Vs,void 0);typeof d=="string"?m0(this,Vs,new FetchRequest(d)):m0(this,Vs,d.clone())}_getConnection(){return s0(this,Vs).clone()}async send(d,et){return await this._start(),await super.send(d,et)}async _send(d){const et=this._getConnection();et.body=JSON.stringify(d),et.setHeader("content-type","application/json");const nt=await et.send();nt.assertOk();let tt=nt.bodyJson;return Array.isArray(tt)||(tt=[tt]),tt}}Vs=new WeakMap;function spelunkData(c){if(c==null)return null;if(typeof c.message=="string"&&c.message.match(/revert/i)&&isHexString$1(c.data))return{message:c.message,data:c.data};if(typeof c=="object"){for(const a in c){const d=spelunkData(c[a]);if(d)return d}return null}if(typeof c=="string")try{return spelunkData(JSON.parse(c))}catch{}return null}function _spelunkMessage(c,a){if(c!=null){if(typeof c.message=="string"&&a.push(c.message),typeof c=="object")for(const d in c)_spelunkMessage(c[d],a);if(typeof c=="string")try{return _spelunkMessage(JSON.parse(c),a)}catch{}}}function spelunkMessage(c){const a=[];return _spelunkMessage(c,a),a}var Ks;class BrowserProvider extends JsonRpcApiPollingProvider{constructor(d,et){super(et,{batchMaxCount:1});q0(this,Ks,void 0);m0(this,Ks,async(nt,tt)=>{const bt={method:nt,params:tt};this.emit("debug",{action:"sendEip1193Request",payload:bt});try{const mt=await d.request(bt);return this.emit("debug",{action:"receiveEip1193Result",result:mt}),mt}catch(mt){const vt=new Error(mt.message);throw vt.code=mt.code,vt.data=mt.data,vt.payload=bt,this.emit("debug",{action:"receiveEip1193Error",error:vt}),vt}})}async send(d,et){return await this._start(),await super.send(d,et)}async _send(d){assertArgument(!Array.isArray(d),"EIP-1193 does not support batch request","payload",d);try{const et=await s0(this,Ks).call(this,d.method,d.params||[]);return[{id:d.id,result:et}]}catch(et){return[{id:d.id,error:{code:et.code,data:et.data,message:et.message}}]}}getRpcError(d,et){switch(et=JSON.parse(JSON.stringify(et)),et.error.code||-1){case 4001:et.error.message=`ethers-user-denied: ${et.error.message}`;break;case 4200:et.error.message=`ethers-unsupported: ${et.error.message}`;break}return super.getRpcError(d,et)}async hasSigner(d){d==null&&(d=0);const et=await this.send("eth_accounts",[]);return typeof d=="number"?et.length>d:(d=d.toLowerCase(),et.filter(nt=>nt.toLowerCase()===d).length!==0)}async getSigner(d){if(d==null&&(d=0),!await this.hasSigner(d))try{await s0(this,Ks).call(this,"eth_requestAccounts",[])}catch(et){const nt=et.payload;throw this.getRpcError(nt,{id:nt.id,error:et})}return await super.getSigner(d)}}Ks=new WeakMap;const getSDKVersion=()=>"9.0.0",dec2hex=c=>c.toString(16).padStart(2,"0"),generateId=c=>{const a=new Uint8Array((c||40)/2);return window.crypto.getRandomValues(a),Array.from(a,dec2hex).join("")},generateRequestId=()=>typeof window<"u"?generateId(10):new Date().getTime().toString(36);class MessageFormatter{}MessageFormatter.makeRequest=(c,a)=>({id:generateRequestId(),method:c,params:a,env:{sdkVersion:getSDKVersion()}});MessageFormatter.makeResponse=(c,a,d)=>({id:c,success:!0,version:d,data:a});MessageFormatter.makeErrorResponse=(c,a,d)=>({id:c,success:!1,error:a,version:d});var Methods;(function(c){c.sendTransactions="sendTransactions",c.rpcCall="rpcCall",c.getChainInfo="getChainInfo",c.getSafeInfo="getSafeInfo",c.getTxBySafeTxHash="getTxBySafeTxHash",c.getSafeBalances="getSafeBalances",c.signMessage="signMessage",c.signTypedMessage="signTypedMessage",c.getEnvironmentInfo="getEnvironmentInfo",c.getOffChainSignature="getOffChainSignature",c.requestAddressBook="requestAddressBook",c.wallet_getPermissions="wallet_getPermissions",c.wallet_requestPermissions="wallet_requestPermissions"})(Methods||(Methods={}));var RestrictedMethods;(function(c){c.requestAddressBook="requestAddressBook"})(RestrictedMethods||(RestrictedMethods={}));class PostMessageCommunicator{constructor(a=null,d=!1){this.allowedOrigins=null,this.callbacks=new Map,this.debugMode=!1,this.isServer=typeof window>"u",this.isValidMessage=({origin:et,data:nt,source:tt})=>{const bt=!nt,mt=!this.isServer&&tt===window.parent,vt=typeof nt.version<"u"&&parseInt(nt.version.split(".")[0]),$t=typeof vt=="number"&&vt>=1;let At=!0;return Array.isArray(this.allowedOrigins)&&(At=this.allowedOrigins.find(Mt=>Mt.test(et))!==void 0),!bt&&mt&&$t&&At},this.logIncomingMessage=et=>{console.info(`Safe Apps SDK v1: A message was received from origin ${et.origin}. `,et.data)},this.onParentMessage=et=>{this.isValidMessage(et)&&(this.debugMode&&this.logIncomingMessage(et),this.handleIncomingMessage(et.data))},this.handleIncomingMessage=et=>{const{id:nt}=et,tt=this.callbacks.get(nt);tt&&(tt(et),this.callbacks.delete(nt))},this.send=(et,nt)=>{const tt=MessageFormatter.makeRequest(et,nt);if(this.isServer)throw new Error("Window doesn't exist");return window.parent.postMessage(tt,"*"),new Promise((bt,mt)=>{this.callbacks.set(tt.id,vt=>{if(!vt.success){mt(new Error(vt.error));return}bt(vt)})})},this.allowedOrigins=a,this.debugMode=d,this.isServer||window.addEventListener("message",this.onParentMessage)}}const isObjectEIP712TypedData=c=>typeof c=="object"&&c!=null&&"domain"in c&&"types"in c&&"message"in c;var dist$1={},endpoint={},utils$1={},__awaiter$6=commonjsGlobal&&commonjsGlobal.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};Object.defineProperty(utils$1,"__esModule",{value:!0});utils$1.getData=utils$1.fetchData=utils$1.stringifyQuery=utils$1.insertParams=void 0;const isErrorResponse=c=>typeof c=="object"&&c!==null&&"code"in c&&"message"in c;function replaceParam(c,a,d){return c.replace(new RegExp(`\\{${a}\\}`,"g"),d)}function insertParams(c,a){return a?Object.keys(a).reduce((d,et)=>replaceParam(d,et,String(a[et])),c):c}utils$1.insertParams=insertParams;function stringifyQuery(c){if(!c)return"";const a=new URLSearchParams;Object.keys(c).forEach(et=>{c[et]!=null&&a.append(et,String(c[et]))});const d=a.toString();return d?`?${d}`:""}utils$1.stringifyQuery=stringifyQuery;function parseResponse(c){return __awaiter$6(this,void 0,void 0,function*(){let a;try{a=c.status===204?{}:yield c.json()}catch{if(c.headers&&c.headers.get("content-length")!=="0")throw new Error(`Invalid response content: ${c.statusText}`)}if(!c.ok){const d=isErrorResponse(a)?`${a.code}: ${a.message}`:c.statusText;throw new Error(d)}return a})}function fetchData(c,a,d,et){return __awaiter$6(this,void 0,void 0,function*(){const nt=Object.assign({"Content-Type":"application/json"},et),tt={method:a??"POST",headers:nt};d!=null&&(tt.body=typeof d=="string"?d:JSON.stringify(d));const bt=yield fetch(c,tt);return parseResponse(bt)})}utils$1.fetchData=fetchData;function getData(c,a){return __awaiter$6(this,void 0,void 0,function*(){const d={method:"GET"};a&&(d.headers=Object.assign(Object.assign({},a),{"Content-Type":"application/json"}));const et=yield fetch(c,d);return parseResponse(et)})}utils$1.getData=getData;Object.defineProperty(endpoint,"__esModule",{value:!0});endpoint.getEndpoint=endpoint.deleteEndpoint=endpoint.putEndpoint=endpoint.postEndpoint=void 0;const utils_1$3=utils$1;function makeUrl(c,a,d,et){const nt=(0,utils_1$3.insertParams)(a,d),tt=(0,utils_1$3.stringifyQuery)(et);return`${c}${nt}${tt}`}function postEndpoint(c,a,d){const et=makeUrl(c,a,d==null?void 0:d.path,d==null?void 0:d.query);return(0,utils_1$3.fetchData)(et,"POST",d==null?void 0:d.body,d==null?void 0:d.headers)}endpoint.postEndpoint=postEndpoint;function putEndpoint(c,a,d){const et=makeUrl(c,a,d==null?void 0:d.path,d==null?void 0:d.query);return(0,utils_1$3.fetchData)(et,"PUT",d==null?void 0:d.body,d==null?void 0:d.headers)}endpoint.putEndpoint=putEndpoint;function deleteEndpoint(c,a,d){const et=makeUrl(c,a,d==null?void 0:d.path,d==null?void 0:d.query);return(0,utils_1$3.fetchData)(et,"DELETE",d==null?void 0:d.body,d==null?void 0:d.headers)}endpoint.deleteEndpoint=deleteEndpoint;function getEndpoint(c,a,d,et){if(et)return(0,utils_1$3.getData)(et);const nt=makeUrl(c,a,d==null?void 0:d.path,d==null?void 0:d.query);return(0,utils_1$3.getData)(nt,d==null?void 0:d.headers)}endpoint.getEndpoint=getEndpoint;var config={};Object.defineProperty(config,"__esModule",{value:!0});config.DEFAULT_BASE_URL=void 0;config.DEFAULT_BASE_URL="https://safe-client.safe.global";var safeInfo={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.ImplementationVersionState=void 0,function(a){a.UP_TO_DATE="UP_TO_DATE",a.OUTDATED="OUTDATED",a.UNKNOWN="UNKNOWN"}(c.ImplementationVersionState||(c.ImplementationVersionState={}))})(safeInfo);var safeApps={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.SafeAppSocialPlatforms=c.SafeAppFeatures=c.SafeAppAccessPolicyTypes=void 0,function(a){a.NoRestrictions="NO_RESTRICTIONS",a.DomainAllowlist="DOMAIN_ALLOWLIST"}(c.SafeAppAccessPolicyTypes||(c.SafeAppAccessPolicyTypes={})),function(a){a.BATCHED_TRANSACTIONS="BATCHED_TRANSACTIONS"}(c.SafeAppFeatures||(c.SafeAppFeatures={})),function(a){a.TWITTER="TWITTER",a.GITHUB="GITHUB",a.DISCORD="DISCORD"}(c.SafeAppSocialPlatforms||(c.SafeAppSocialPlatforms={}))})(safeApps);var transactions={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.LabelValue=c.DetailedExecutionInfoType=c.TransactionListItemType=c.ConflictType=c.TransactionInfoType=c.SettingsInfoType=c.TransactionTokenType=c.TransferDirection=c.TransactionStatus=c.Operation=void 0,function(a){a[a.CALL=0]="CALL",a[a.DELEGATE=1]="DELEGATE"}(c.Operation||(c.Operation={})),function(a){a.AWAITING_CONFIRMATIONS="AWAITING_CONFIRMATIONS",a.AWAITING_EXECUTION="AWAITING_EXECUTION",a.CANCELLED="CANCELLED",a.FAILED="FAILED",a.SUCCESS="SUCCESS"}(c.TransactionStatus||(c.TransactionStatus={})),function(a){a.INCOMING="INCOMING",a.OUTGOING="OUTGOING",a.UNKNOWN="UNKNOWN"}(c.TransferDirection||(c.TransferDirection={})),function(a){a.ERC20="ERC20",a.ERC721="ERC721",a.NATIVE_COIN="NATIVE_COIN"}(c.TransactionTokenType||(c.TransactionTokenType={})),function(a){a.SET_FALLBACK_HANDLER="SET_FALLBACK_HANDLER",a.ADD_OWNER="ADD_OWNER",a.REMOVE_OWNER="REMOVE_OWNER",a.SWAP_OWNER="SWAP_OWNER",a.CHANGE_THRESHOLD="CHANGE_THRESHOLD",a.CHANGE_IMPLEMENTATION="CHANGE_IMPLEMENTATION",a.ENABLE_MODULE="ENABLE_MODULE",a.DISABLE_MODULE="DISABLE_MODULE",a.SET_GUARD="SET_GUARD",a.DELETE_GUARD="DELETE_GUARD"}(c.SettingsInfoType||(c.SettingsInfoType={})),function(a){a.TRANSFER="Transfer",a.SETTINGS_CHANGE="SettingsChange",a.CUSTOM="Custom",a.CREATION="Creation",a.SWAP_ORDER="SwapOrder"}(c.TransactionInfoType||(c.TransactionInfoType={})),function(a){a.NONE="None",a.HAS_NEXT="HasNext",a.END="End"}(c.ConflictType||(c.ConflictType={})),function(a){a.TRANSACTION="TRANSACTION",a.LABEL="LABEL",a.CONFLICT_HEADER="CONFLICT_HEADER",a.DATE_LABEL="DATE_LABEL"}(c.TransactionListItemType||(c.TransactionListItemType={})),function(a){a.MULTISIG="MULTISIG",a.MODULE="MODULE"}(c.DetailedExecutionInfoType||(c.DetailedExecutionInfoType={})),function(a){a.Queued="Queued",a.Next="Next"}(c.LabelValue||(c.LabelValue={}))})(transactions);var chains={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.FEATURES=c.GAS_PRICE_TYPE=c.RPC_AUTHENTICATION=void 0,function(a){a.API_KEY_PATH="API_KEY_PATH",a.NO_AUTHENTICATION="NO_AUTHENTICATION",a.UNKNOWN="UNKNOWN"}(c.RPC_AUTHENTICATION||(c.RPC_AUTHENTICATION={})),function(a){a.ORACLE="ORACLE",a.FIXED="FIXED",a.FIXED_1559="FIXED1559",a.UNKNOWN="UNKNOWN"}(c.GAS_PRICE_TYPE||(c.GAS_PRICE_TYPE={})),function(a){a.ERC721="ERC721",a.SAFE_APPS="SAFE_APPS",a.CONTRACT_INTERACTION="CONTRACT_INTERACTION",a.DOMAIN_LOOKUP="DOMAIN_LOOKUP",a.SPENDING_LIMIT="SPENDING_LIMIT",a.EIP1559="EIP1559",a.SAFE_TX_GAS_OPTIONAL="SAFE_TX_GAS_OPTIONAL",a.TX_SIMULATION="TX_SIMULATION",a.EIP1271="EIP1271"}(c.FEATURES||(c.FEATURES={}))})(chains);var common={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.TokenType=void 0,function(a){a.ERC20="ERC20",a.ERC721="ERC721",a.NATIVE_TOKEN="NATIVE_TOKEN"}(c.TokenType||(c.TokenType={}))})(common);var masterCopies={};Object.defineProperty(masterCopies,"__esModule",{value:!0});var decodedData={};Object.defineProperty(decodedData,"__esModule",{value:!0});var safeMessages={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.SafeMessageStatus=c.SafeMessageListItemType=void 0,function(a){a.DATE_LABEL="DATE_LABEL",a.MESSAGE="MESSAGE"}(c.SafeMessageListItemType||(c.SafeMessageListItemType={})),function(a){a.NEEDS_CONFIRMATION="NEEDS_CONFIRMATION",a.CONFIRMED="CONFIRMED"}(c.SafeMessageStatus||(c.SafeMessageStatus={}))})(safeMessages);var notifications={};(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.DeviceType=void 0,function(a){a.ANDROID="ANDROID",a.IOS="IOS",a.WEB="WEB"}(c.DeviceType||(c.DeviceType={}))})(notifications);var relay={};Object.defineProperty(relay,"__esModule",{value:!0});(function(c){var a=commonjsGlobal&&commonjsGlobal.__createBinding||(Object.create?function(o0,l0,$0,p0){p0===void 0&&(p0=$0);var u0=Object.getOwnPropertyDescriptor(l0,$0);(!u0||("get"in u0?!l0.__esModule:u0.writable||u0.configurable))&&(u0={enumerable:!0,get:function(){return l0[$0]}}),Object.defineProperty(o0,p0,u0)}:function(o0,l0,$0,p0){p0===void 0&&(p0=$0),o0[p0]=l0[$0]}),d=commonjsGlobal&&commonjsGlobal.__exportStar||function(o0,l0){for(var $0 in o0)$0!=="default"&&!Object.prototype.hasOwnProperty.call(l0,$0)&&a(l0,o0,$0)};Object.defineProperty(c,"__esModule",{value:!0}),c.getContract=c.getSafeOverviews=c.unsubscribeAll=c.unsubscribeSingle=c.registerRecoveryModule=c.deleteRegisteredEmail=c.getRegisteredEmail=c.verifyEmail=c.resendEmailVerificationCode=c.changeEmail=c.registerEmail=c.unregisterDevice=c.unregisterSafe=c.registerDevice=c.getDelegates=c.confirmSafeMessage=c.proposeSafeMessage=c.getSafeMessage=c.getSafeMessages=c.getDecodedData=c.getMasterCopies=c.getSafeApps=c.getChainConfig=c.getChainsConfig=c.getConfirmationView=c.proposeTransaction=c.getNonces=c.postSafeGasEstimation=c.deleteTransaction=c.getTransactionDetails=c.getTransactionQueue=c.getTransactionHistory=c.getCollectiblesPage=c.getCollectibles=c.getAllOwnedSafes=c.getOwnedSafes=c.getFiatCurrencies=c.getBalances=c.getMultisigTransactions=c.getModuleTransactions=c.getIncomingTransfers=c.getSafeInfo=c.getRelayCount=c.relayTransaction=c.setBaseUrl=void 0;const et=endpoint,nt=config;d(safeInfo,c),d(safeApps,c),d(transactions,c),d(chains,c),d(common,c),d(masterCopies,c),d(decodedData,c),d(safeMessages,c),d(notifications,c),d(relay,c);let tt=nt.DEFAULT_BASE_URL;const bt=o0=>{tt=o0};c.setBaseUrl=bt;function mt(o0,l0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/relay",{path:{chainId:o0},body:l0})}c.relayTransaction=mt;function vt(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/relay/{address}",{path:{chainId:o0,address:l0}})}c.getRelayCount=vt;function $t(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}",{path:{chainId:o0,address:l0}})}c.getSafeInfo=$t;function At(o0,l0,$0,p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}/incoming-transfers/",{path:{chainId:o0,address:l0},query:$0},p0)}c.getIncomingTransfers=At;function Mt(o0,l0,$0,p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}/module-transactions/",{path:{chainId:o0,address:l0},query:$0},p0)}c.getModuleTransactions=Mt;function Tt(o0,l0,$0,p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}/multisig-transactions/",{path:{chainId:o0,address:l0},query:$0},p0)}c.getMultisigTransactions=Tt;function Rt(o0,l0,$0="usd",p0={}){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}/balances/{currency}",{path:{chainId:o0,address:l0,currency:$0},query:p0})}c.getBalances=Rt;function kt(){return(0,et.getEndpoint)(tt,"/v1/balances/supported-fiat-codes")}c.getFiatCurrencies=kt;function It(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/owners/{address}/safes",{path:{chainId:o0,address:l0}})}c.getOwnedSafes=It;function Dt(o0){return(0,et.getEndpoint)(tt,"/v1/owners/{address}/safes",{path:{address:o0}})}c.getAllOwnedSafes=Dt;function Nt(o0,l0,$0={}){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:o0,address:l0},query:$0})}c.getCollectibles=Nt;function Ot(o0,l0,$0={},p0){return(0,et.getEndpoint)(tt,"/v2/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:o0,address:l0},query:$0},p0)}c.getCollectiblesPage=Ot;function Ut(o0,l0,$0={},p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/transactions/history",{path:{chainId:o0,safe_address:l0},query:$0},p0)}c.getTransactionHistory=Ut;function Gt(o0,l0,$0={},p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/transactions/queued",{path:{chainId:o0,safe_address:l0},query:$0},p0)}c.getTransactionQueue=Gt;function Wt(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/transactions/{transactionId}",{path:{chainId:o0,transactionId:l0}})}c.getTransactionDetails=Wt;function Xt(o0,l0,$0){return(0,et.deleteEndpoint)(tt,"/v1/chains/{chainId}/transactions/{safeTxHash}",{path:{chainId:o0,safeTxHash:l0},body:{signature:$0}})}c.deleteTransaction=Xt;function a0(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v2/chains/{chainId}/safes/{safe_address}/multisig-transactions/estimations",{path:{chainId:o0,safe_address:l0},body:$0})}c.postSafeGasEstimation=a0;function n0(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/nonces",{path:{chainId:o0,safe_address:l0}})}c.getNonces=n0;function t0(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/transactions/{safe_address}/propose",{path:{chainId:o0,safe_address:l0},body:$0})}c.proposeTransaction=t0;function c0(o0,l0,$0,p0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/views/transaction-confirmation",{path:{chainId:o0,safe_address:l0},body:{data:$0,to:p0}})}c.getConfirmationView=c0;function Ct(o0){return(0,et.getEndpoint)(tt,"/v1/chains",{query:o0})}c.getChainsConfig=Ct;function dt(o0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}",{path:{chainId:o0}})}c.getChainConfig=dt;function yt(o0,l0={}){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safe-apps",{path:{chainId:o0},query:l0})}c.getSafeApps=yt;function gt(o0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/about/master-copies",{path:{chainId:o0}})}c.getMasterCopies=gt;function xt(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/data-decoder",{path:{chainId:o0},body:{data:l0,to:$0}})}c.getDecodedData=xt;function St(o0,l0,$0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:o0,safe_address:l0},query:{}},$0)}c.getSafeMessages=St;function _t(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/messages/{message_hash}",{path:{chainId:o0,message_hash:l0}})}c.getSafeMessage=_t;function Pt(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:o0,safe_address:l0},body:$0})}c.proposeSafeMessage=Pt;function Et(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/messages/{message_hash}/signatures",{path:{chainId:o0,message_hash:l0},body:$0})}c.confirmSafeMessage=Et;function ht(o0,l0={}){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/delegates",{path:{chainId:o0},query:l0})}c.getDelegates=ht;function wt(o0){return(0,et.postEndpoint)(tt,"/v1/register/notifications",{body:o0})}c.registerDevice=wt;function Bt(o0,l0,$0){return(0,et.deleteEndpoint)(tt,"/v1/chains/{chainId}/notifications/devices/{uuid}/safes/{safe_address}",{path:{chainId:o0,safe_address:l0,uuid:$0}})}c.unregisterSafe=Bt;function Lt(o0,l0){return(0,et.deleteEndpoint)(tt,"/v1/chains/{chainId}/notifications/devices/{uuid}",{path:{chainId:o0,uuid:l0}})}c.unregisterDevice=Lt;function jt(o0,l0,$0,p0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails",{path:{chainId:o0,safe_address:l0},body:$0,headers:p0})}c.registerEmail=jt;function Ft(o0,l0,$0,p0,u0){return(0,et.putEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:o0,safe_address:l0,signer:$0},body:p0,headers:u0})}c.changeEmail=Ft;function Vt(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}/verify-resend",{path:{chainId:o0,safe_address:l0,signer:$0},body:""})}c.resendEmailVerificationCode=Vt;function zt(o0,l0,$0,p0){return(0,et.putEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}/verify",{path:{chainId:o0,safe_address:l0,signer:$0},body:p0})}c.verifyEmail=zt;function qt(o0,l0,$0,p0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:o0,safe_address:l0,signer:$0},headers:p0})}c.getRegisteredEmail=qt;function Kt(o0,l0,$0,p0){return(0,et.deleteEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:o0,safe_address:l0,signer:$0},headers:p0})}c.deleteRegisteredEmail=Kt;function e0(o0,l0,$0){return(0,et.postEndpoint)(tt,"/v1/chains/{chainId}/safes/{safe_address}/recovery",{path:{chainId:o0,safe_address:l0},body:$0})}c.registerRecoveryModule=e0;function Zt(o0){return(0,et.deleteEndpoint)(tt,"/v1/subscriptions",{query:o0})}c.unsubscribeSingle=Zt;function Jt(o0){return(0,et.deleteEndpoint)(tt,"/v1/subscriptions/all",{query:o0})}c.unsubscribeAll=Jt;function i0(o0,l0){return(0,et.getEndpoint)(tt,"/v1/safes",{query:Object.assign(Object.assign({},l0),{safes:o0.join(",")})})}c.getSafeOverviews=i0;function h0(o0,l0){return(0,et.getEndpoint)(tt,"/v1/chains/{chainId}/contracts/{contractAddress}",{path:{chainId:o0,contractAddress:l0}})}c.getContract=h0})(dist$1);class TXs{constructor(a){this.communicator=a}async getBySafeTxHash(a){if(!a)throw new Error("Invalid safeTxHash");return(await this.communicator.send(Methods.getTxBySafeTxHash,{safeTxHash:a})).data}async signMessage(a){const d={message:a};return(await this.communicator.send(Methods.signMessage,d)).data}async signTypedMessage(a){if(!isObjectEIP712TypedData(a))throw new Error("Invalid typed data");return(await this.communicator.send(Methods.signTypedMessage,{typedData:a})).data}async send({txs:a,params:d}){if(!a||!a.length)throw new Error("No transactions were passed");const et={txs:a,params:d};return(await this.communicator.send(Methods.sendTransactions,et)).data}}const RPC_CALLS={eth_call:"eth_call",eth_gasPrice:"eth_gasPrice",eth_getLogs:"eth_getLogs",eth_getBalance:"eth_getBalance",eth_getCode:"eth_getCode",eth_getBlockByHash:"eth_getBlockByHash",eth_getBlockByNumber:"eth_getBlockByNumber",eth_getStorageAt:"eth_getStorageAt",eth_getTransactionByHash:"eth_getTransactionByHash",eth_getTransactionReceipt:"eth_getTransactionReceipt",eth_getTransactionCount:"eth_getTransactionCount",eth_estimateGas:"eth_estimateGas",safe_setSettings:"safe_setSettings"},inputFormatters={defaultBlockParam:(c="latest")=>c,returnFullTxObjectParam:(c=!1)=>c,blockNumberToHex:c=>Number.isInteger(c)?`0x${c.toString(16)}`:c};class Eth{constructor(a){this.communicator=a,this.call=this.buildRequest({call:RPC_CALLS.eth_call,formatters:[null,inputFormatters.defaultBlockParam]}),this.getBalance=this.buildRequest({call:RPC_CALLS.eth_getBalance,formatters:[null,inputFormatters.defaultBlockParam]}),this.getCode=this.buildRequest({call:RPC_CALLS.eth_getCode,formatters:[null,inputFormatters.defaultBlockParam]}),this.getStorageAt=this.buildRequest({call:RPC_CALLS.eth_getStorageAt,formatters:[null,inputFormatters.blockNumberToHex,inputFormatters.defaultBlockParam]}),this.getPastLogs=this.buildRequest({call:RPC_CALLS.eth_getLogs}),this.getBlockByHash=this.buildRequest({call:RPC_CALLS.eth_getBlockByHash,formatters:[null,inputFormatters.returnFullTxObjectParam]}),this.getBlockByNumber=this.buildRequest({call:RPC_CALLS.eth_getBlockByNumber,formatters:[inputFormatters.blockNumberToHex,inputFormatters.returnFullTxObjectParam]}),this.getTransactionByHash=this.buildRequest({call:RPC_CALLS.eth_getTransactionByHash}),this.getTransactionReceipt=this.buildRequest({call:RPC_CALLS.eth_getTransactionReceipt}),this.getTransactionCount=this.buildRequest({call:RPC_CALLS.eth_getTransactionCount,formatters:[null,inputFormatters.defaultBlockParam]}),this.getGasPrice=this.buildRequest({call:RPC_CALLS.eth_gasPrice}),this.getEstimateGas=d=>this.buildRequest({call:RPC_CALLS.eth_estimateGas})([d]),this.setSafeSettings=this.buildRequest({call:RPC_CALLS.safe_setSettings})}buildRequest(a){const{call:d,formatters:et}=a;return async nt=>{et&&Array.isArray(nt)&&et.forEach((mt,vt)=>{mt&&(nt[vt]=mt(nt[vt]))});const tt={call:d,params:nt||[]};return(await this.communicator.send(Methods.rpcCall,tt)).data}}}function execTyped$1(c,a){const d=c.exec(a);return d==null?void 0:d.groups}const tupleRegex$1=/^tuple(?(\[(\d*)\])*)$/;function formatAbiParameter$1(c){let a=c.type;if(tupleRegex$1.test(c.type)&&"components"in c){a="(";const d=c.components.length;for(let nt=0;ntformatAbiParam$1(d,{includeName:a})).join(a?", ":","):""}function formatAbiParam$1(c,{includeName:a}){return c.type.startsWith("tuple")?`(${formatAbiParams$1(c.components,{includeName:a})})${c.type.slice(5)}`:c.type+(a&&c.name?` ${c.name}`:"")}function isHex$1(c,{strict:a=!0}={}){return!c||typeof c!="string"?!1:a?/^0x[0-9a-fA-F]*$/.test(c):c.startsWith("0x")}function size$2(c){return isHex$1(c,{strict:!1})?Math.ceil((c.length-2)/2):c.length}const version$j="1.21.3",getVersion$1=()=>`viem@${version$j}`;let BaseError$1=class Zo extends Error{constructor(a,d={}){var tt;super(),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ViemError"}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:getVersion$1()});const et=d.cause instanceof Zo?d.cause.details:(tt=d.cause)!=null&&tt.message?d.cause.message:d.details,nt=d.cause instanceof Zo&&d.cause.docsPath||d.docsPath;this.message=[a||"An error occurred.","",...d.metaMessages?[...d.metaMessages,""]:[],...nt?[`Docs: https://viem.sh${nt}.html${d.docsSlug?`#${d.docsSlug}`:""}`]:[],...et?[`Details: ${et}`]:[],`Version: ${this.version}`].join(` +`),d.cause&&(this.cause=d.cause),this.details=et,this.docsPath=nt,this.metaMessages=d.metaMessages,this.shortMessage=a}walk(a){return walk$1(this,a)}};function walk$1(c,a){return a!=null&&a(c)?c:c&&typeof c=="object"&&"cause"in c?walk$1(c.cause,a):a?null:c}let AbiEncodingArrayLengthMismatchError$1=class extends BaseError$1{constructor({expectedLength:a,givenLength:d,type:et}){super([`ABI encoding array length mismatch for type ${et}.`,`Expected length: ${a}`,`Given length: ${d}`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}},AbiEncodingBytesSizeMismatchError$1=class extends BaseError$1{constructor({expectedSize:a,value:d}){super(`Size of bytes "${d}" (bytes${size$2(d)}) does not match expected size (bytes${a}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}},AbiEncodingLengthMismatchError$1=class extends BaseError$1{constructor({expectedLength:a,givenLength:d}){super(["ABI encoding params/values length mismatch.",`Expected length (params): ${a}`,`Given length (values): ${d}`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}},AbiFunctionNotFoundError$1=class extends BaseError$1{constructor(a,{docsPath:d}={}){super([`Function ${a?`"${a}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}},AbiItemAmbiguityError$1=class extends BaseError$1{constructor(a,d){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${a.type}\` in \`${formatAbiItem$2(a.abiItem)}\`, and`,`\`${d.type}\` in \`${formatAbiItem$2(d.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItemAmbiguityError"})}},BytesSizeMismatchError$1=class extends BaseError$1{constructor({expectedSize:a,givenSize:d}){super(`Expected bytes${a}, got bytes${d}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}},InvalidAbiEncodingTypeError$1=class extends BaseError$1{constructor(a,{docsPath:d}){super([`Type "${a}" is not a valid encoding type.`,"Please provide a valid ABI type."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}},InvalidArrayError$1=class extends BaseError$1{constructor(a){super([`Value "${a}" is not a valid array.`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}},InvalidDefinitionTypeError$1=class extends BaseError$1{constructor(a){super([`"${a}" is not a valid definition type.`,'Valid types: "function", "event", "error"'].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}},SliceOffsetOutOfBoundsError$1=class extends BaseError$1{constructor({offset:a,position:d,size:et}){super(`Slice ${d==="start"?"starting":"ending"} at offset "${a}" is out-of-bounds (size: ${et}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}},SizeExceedsPaddingSizeError$1=class extends BaseError$1{constructor({size:a,targetSize:d,type:et}){super(`${et.charAt(0).toUpperCase()}${et.slice(1).toLowerCase()} size (${a}) exceeds padding size (${d}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}};function pad$1(c,{dir:a,size:d=32}={}){return typeof c=="string"?padHex$1(c,{dir:a,size:d}):padBytes$1(c,{dir:a,size:d})}function padHex$1(c,{dir:a,size:d=32}={}){if(d===null)return c;const et=c.replace("0x","");if(et.length>d*2)throw new SizeExceedsPaddingSizeError$1({size:Math.ceil(et.length/2),targetSize:d,type:"hex"});return`0x${et[a==="right"?"padEnd":"padStart"](d*2,"0")}`}function padBytes$1(c,{dir:a,size:d=32}={}){if(d===null)return c;if(c.length>d)throw new SizeExceedsPaddingSizeError$1({size:c.length,targetSize:d,type:"bytes"});const et=new Uint8Array(d);for(let nt=0;nta)throw new SizeOverflowError$1({givenSize:size$2(c),maxSize:a})}const hexes$1=Array.from({length:256},(c,a)=>a.toString(16).padStart(2,"0"));function toHex$2(c,a={}){return typeof c=="number"||typeof c=="bigint"?numberToHex$1(c,a):typeof c=="string"?stringToHex$1(c,a):typeof c=="boolean"?boolToHex$1(c,a):bytesToHex$1(c,a)}function boolToHex$1(c,a={}){const d=`0x${Number(c)}`;return typeof a.size=="number"?(assertSize$1(d,{size:a.size}),pad$1(d,{size:a.size})):d}function bytesToHex$1(c,a={}){let d="";for(let nt=0;nttt||nt=charCodeMap$1.zero&&c<=charCodeMap$1.nine)return c-charCodeMap$1.zero;if(c>=charCodeMap$1.A&&c<=charCodeMap$1.F)return c-(charCodeMap$1.A-10);if(c>=charCodeMap$1.a&&c<=charCodeMap$1.f)return c-(charCodeMap$1.a-10)}function hexToBytes$1(c,a={}){let d=c;a.size&&(assertSize$1(d,{size:a.size}),d=pad$1(d,{dir:"right",size:a.size}));let et=d.slice(2);et.length%2&&(et=`0${et}`);const nt=et.length/2,tt=new Uint8Array(nt);for(let bt=0,mt=0;bt{const a=(()=>typeof c=="string"?c:formatAbiItem$3(c))();return normalizeSignature$1(a)},getEventSignature=c=>getFunctionSignature(c);function number$1(c){if(!Number.isSafeInteger(c)||c<0)throw new Error(`Wrong positive integer: ${c}`)}function bytes$1(c,...a){if(!(c instanceof Uint8Array))throw new Error("Expected Uint8Array");if(a.length>0&&!a.includes(c.length))throw new Error(`Expected Uint8Array of length ${a}, not of length=${c.length}`)}function exists$1(c,a=!0){if(c.destroyed)throw new Error("Hash instance has been destroyed");if(a&&c.finished)throw new Error("Hash#digest() has already been called")}function output$1(c,a){bytes$1(c);const d=a.outputLen;if(c.length>_32n$1&U32_MASK64$1)}:{h:Number(c>>_32n$1&U32_MASK64$1)|0,l:Number(c&U32_MASK64$1)|0}}function split$1(c,a=!1){let d=new Uint32Array(c.length),et=new Uint32Array(c.length);for(let nt=0;ntc<>>32-d,rotlSL$1=(c,a,d)=>a<>>32-d,rotlBH$1=(c,a,d)=>a<>>64-d,rotlBL$1=(c,a,d)=>c<>>64-d;/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */const u8a$1=c=>c instanceof Uint8Array,u32$1=c=>new Uint32Array(c.buffer,c.byteOffset,Math.floor(c.byteLength/4)),isLE$1=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;if(!isLE$1)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes$1(c){if(typeof c!="string")throw new Error(`utf8ToBytes expected string, got ${typeof c}`);return new Uint8Array(new TextEncoder().encode(c))}function toBytes$2(c){if(typeof c=="string"&&(c=utf8ToBytes$1(c)),!u8a$1(c))throw new Error(`expected Uint8Array, got ${typeof c}`);return c}let Hash$1=class{clone(){return this._cloneInto()}};function wrapConstructor$1(c){const a=et=>c().update(toBytes$2(et)).digest(),d=c();return a.outputLen=d.outputLen,a.blockLen=d.blockLen,a.create=()=>c(),a}const[SHA3_PI$1,SHA3_ROTL$1,_SHA3_IOTA$1]=[[],[],[]],_0n$1=BigInt(0),_1n$1=BigInt(1),_2n$1=BigInt(2),_7n$1=BigInt(7),_256n$1=BigInt(256),_0x71n$1=BigInt(113);for(let c=0,a=_1n$1,d=1,et=0;c<24;c++){[d,et]=[et,(2*d+3*et)%5],SHA3_PI$1.push(2*(5*et+d)),SHA3_ROTL$1.push((c+1)*(c+2)/2%64);let nt=_0n$1;for(let tt=0;tt<7;tt++)a=(a<<_1n$1^(a>>_7n$1)*_0x71n$1)%_256n$1,a&_2n$1&&(nt^=_1n$1<<(_1n$1<d>32?rotlBH$1(c,a,d):rotlSH$1(c,a,d),rotlL$1=(c,a,d)=>d>32?rotlBL$1(c,a,d):rotlSL$1(c,a,d);function keccakP$1(c,a=24){const d=new Uint32Array(10);for(let et=24-a;et<24;et++){for(let bt=0;bt<10;bt++)d[bt]=c[bt]^c[bt+10]^c[bt+20]^c[bt+30]^c[bt+40];for(let bt=0;bt<10;bt+=2){const mt=(bt+8)%10,vt=(bt+2)%10,$t=d[vt],At=d[vt+1],Mt=rotlH$1($t,At,1)^d[mt],Tt=rotlL$1($t,At,1)^d[mt+1];for(let Rt=0;Rt<50;Rt+=10)c[bt+Rt]^=Mt,c[bt+Rt+1]^=Tt}let nt=c[2],tt=c[3];for(let bt=0;bt<24;bt++){const mt=SHA3_ROTL$1[bt],vt=rotlH$1(nt,tt,mt),$t=rotlL$1(nt,tt,mt),At=SHA3_PI$1[bt];nt=c[At],tt=c[At+1],c[At]=vt,c[At+1]=$t}for(let bt=0;bt<50;bt+=10){for(let mt=0;mt<10;mt++)d[mt]=c[bt+mt];for(let mt=0;mt<10;mt++)c[bt+mt]^=~d[(mt+2)%10]&d[(mt+4)%10]}c[0]^=SHA3_IOTA_H$1[et],c[1]^=SHA3_IOTA_L$1[et]}d.fill(0)}let Keccak$1=class a1 extends Hash$1{constructor(a,d,et,nt=!1,tt=24){if(super(),this.blockLen=a,this.suffix=d,this.outputLen=et,this.enableXOF=nt,this.rounds=tt,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,number$1(et),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=u32$1(this.state)}keccak(){keccakP$1(this.state32,this.rounds),this.posOut=0,this.pos=0}update(a){exists$1(this);const{blockLen:d,state:et}=this;a=toBytes$2(a);const nt=a.length;for(let tt=0;tt=et&&this.keccak();const bt=Math.min(et-this.posOut,tt-nt);a.set(d.subarray(this.posOut,this.posOut+bt),nt),this.posOut+=bt,nt+=bt}return a}xofInto(a){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(a)}xof(a){return number$1(a),this.xofInto(new Uint8Array(a))}digestInto(a){if(output$1(a,this),this.finished)throw new Error("digest() was already called");return this.writeInto(a),this.destroy(),a}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(a){const{blockLen:d,suffix:et,outputLen:nt,rounds:tt,enableXOF:bt}=this;return a||(a=new a1(d,et,nt,bt,tt)),a.state32.set(this.state32),a.pos=this.pos,a.posOut=this.posOut,a.finished=this.finished,a.rounds=tt,a.suffix=et,a.outputLen=nt,a.enableXOF=bt,a.destroyed=this.destroyed,a}};const gen$1=(c,a,d)=>wrapConstructor$1(()=>new Keccak$1(a,c,d)),keccak_256$1=gen$1(1,136,256/8);function keccak256$2(c,a){const d=a||"hex",et=keccak_256$1(isHex$1(c,{strict:!1})?toBytes$3(c):c);return d==="bytes"?et:toHex$2(et)}const hash$2=c=>keccak256$2(toBytes$3(c)),getEventSelector=c=>hash$2(getEventSignature(c));let InvalidAddressError$1=class extends BaseError$1{constructor({address:a}){super(`Address "${a}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}};const addressRegex$1=/^0x[a-fA-F0-9]{40}$/;function isAddress$1(c){return addressRegex$1.test(c)}function concat$2(c){return typeof c[0]=="string"?concatHex$1(c):concatBytes$1(c)}function concatBytes$1(c){let a=0;for(const nt of c)a+=nt.length;const d=new Uint8Array(a);let et=0;for(const nt of c)d.set(nt,et),et+=nt.length;return d}function concatHex$1(c){return`0x${c.reduce((a,d)=>a+d.replace("0x",""),"")}`}function slice$1(c,a,d,{strict:et}={}){return isHex$1(c,{strict:!1})?sliceHex$1(c,a,d,{strict:et}):sliceBytes$1(c,a,d,{strict:et})}function assertStartOffset$1(c,a){if(typeof a=="number"&&a>0&&a>size$2(c)-1)throw new SliceOffsetOutOfBoundsError$1({offset:a,position:"start",size:size$2(c)})}function assertEndOffset$1(c,a,d){if(typeof a=="number"&&typeof d=="number"&&size$2(c)!==d-a)throw new SliceOffsetOutOfBoundsError$1({offset:d,position:"end",size:size$2(c)})}function sliceBytes$1(c,a,d,{strict:et}={}){assertStartOffset$1(c,a);const nt=c.slice(a,d);return et&&assertEndOffset$1(nt,a,d),nt}function sliceHex$1(c,a,d,{strict:et}={}){assertStartOffset$1(c,a);const nt=`0x${c.replace("0x","").slice((a??0)*2,(d??c.length)*2)}`;return et&&assertEndOffset$1(nt,a,d),nt}function encodeAbiParameters$1(c,a){if(c.length!==a.length)throw new AbiEncodingLengthMismatchError$1({expectedLength:c.length,givenLength:a.length});const d=prepareParams$1({params:c,values:a}),et=encodeParams$1(d);return et.length===0?"0x":et}function prepareParams$1({params:c,values:a}){const d=[];for(let et=0;et0?concat$2([mt,bt]):mt}}if(nt)return{dynamic:!0,encoded:bt}}return{dynamic:!1,encoded:concat$2(tt.map(({encoded:bt})=>bt))}}function encodeBytes$1(c,{param:a}){const[,d]=a.type.split("bytes"),et=size$2(c);if(!d){let nt=c;return et%32!==0&&(nt=padHex$1(nt,{dir:"right",size:Math.ceil((c.length-2)/2/32)*32})),{dynamic:!0,encoded:concat$2([padHex$1(numberToHex$1(et,{size:32})),nt])}}if(et!==parseInt(d))throw new AbiEncodingBytesSizeMismatchError$1({expectedSize:parseInt(d),value:c});return{dynamic:!1,encoded:padHex$1(c,{dir:"right"})}}function encodeBool$1(c){return{dynamic:!1,encoded:padHex$1(boolToHex$1(c))}}function encodeNumber$1(c,{signed:a}){return{dynamic:!1,encoded:numberToHex$1(c,{size:32,signed:a})}}function encodeString$1(c){const a=stringToHex$1(c),d=Math.ceil(size$2(a)/32),et=[];for(let nt=0;ntnt))}}function getArrayComponents$1(c){const a=c.match(/^(.*)\[(\d+)?\]$/);return a?[a[2]?Number(a[2]):null,a[1]]:void 0}const hash$1=c=>keccak256$2(toBytes$3(c)),getFunctionSelector=c=>slice$1(hash$1(getFunctionSignature(c)),0,4);function getAbiItem$1({abi:c,args:a=[],name:d}){const et=isHex$1(d,{strict:!1}),nt=c.filter(bt=>et?bt.type==="function"?getFunctionSelector(bt)===d:bt.type==="event"?getEventSelector(bt)===d:!1:"name"in bt&&bt.name===d);if(nt.length===0)return;if(nt.length===1)return nt[0];let tt;for(const bt of nt){if(!("inputs"in bt))continue;if(!a||a.length===0){if(!bt.inputs||bt.inputs.length===0)return bt;continue}if(!bt.inputs||bt.inputs.length===0||bt.inputs.length!==a.length)continue;if(a.every((vt,$t)=>{const At="inputs"in bt&&bt.inputs[$t];return At?isArgOfType$1(vt,At):!1})){if(tt&&"inputs"in tt&&tt.inputs){const vt=getAmbiguousTypes$1(bt.inputs,tt.inputs,a);if(vt)throw new AbiItemAmbiguityError$1({abiItem:bt,type:vt[0]},{abiItem:tt,type:vt[1]})}tt=bt}}return tt||nt[0]}function isArgOfType$1(c,a){const d=typeof c,et=a.type;switch(et){case"address":return isAddress$1(c);case"bool":return d==="boolean";case"function":return d==="string";case"string":return d==="string";default:return et==="tuple"&&"components"in a?Object.values(a.components).every((nt,tt)=>isArgOfType$1(Object.values(c)[tt],nt)):/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/.test(et)?d==="number"||d==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(et)?d==="string"||c instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(et)?Array.isArray(c)&&c.every(nt=>isArgOfType$1(nt,{...a,type:et.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function getAmbiguousTypes$1(c,a,d){for(const et in c){const nt=c[et],tt=a[et];if(nt.type==="tuple"&&tt.type==="tuple"&&"components"in nt&&"components"in tt)return getAmbiguousTypes$1(nt.components,tt.components,d[et]);const bt=[nt.type,tt.type];if((()=>bt.includes("address")&&bt.includes("bytes20")?!0:bt.includes("address")&&bt.includes("string")||bt.includes("address")&&bt.includes("bytes")?isAddress$1(d[et]):!1)())return bt}}function encodeFunctionData$1({abi:c,args:a,functionName:d}){let et=c[0];if(d&&(et=getAbiItem$1({abi:c,args:a,name:d}),!et))throw new AbiFunctionNotFoundError$1(d,{docsPath:"/docs/contract/encodeFunctionData"});if(et.type!=="function")throw new AbiFunctionNotFoundError$1(void 0,{docsPath:"/docs/contract/encodeFunctionData"});const nt=formatAbiItem$2(et),tt=getFunctionSelector(nt),bt="inputs"in et&&et.inputs?encodeAbiParameters$1(et.inputs,a??[]):void 0;return concatHex$1([tt,bt??"0x"])}const scriptRel="modulepreload",assetsURL=function(c){return"/"+c},seen={},__vitePreload=function c(a,d,et){if(!d||d.length===0)return a();const nt=document.getElementsByTagName("link");return Promise.all(d.map(tt=>{if(tt=assetsURL(tt),tt in seen)return;seen[tt]=!0;const bt=tt.endsWith(".css"),mt=bt?'[rel="stylesheet"]':"";if(!!et)for(let At=nt.length-1;At>=0;At--){const Mt=nt[At];if(Mt.href===tt&&(!bt||Mt.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${tt}"]${mt}`))return;const $t=document.createElement("link");if($t.rel=bt?"stylesheet":scriptRel,bt||($t.as="script",$t.crossOrigin=""),$t.href=tt,document.head.appendChild($t),bt)return new Promise((At,Mt)=>{$t.addEventListener("load",At),$t.addEventListener("error",()=>Mt(new Error(`Unable to preload CSS for ${tt}`)))})})).then(()=>a()).catch(tt=>{const bt=new Event("vite:preloadError",{cancelable:!0});if(bt.payload=tt,window.dispatchEvent(bt),!bt.defaultPrevented)throw tt})},bytesRegex$1=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,integerRegex$1=/^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;function hashTypedData$1({domain:c,message:a,primaryType:d,types:et}){const nt=typeof c>"u"?{}:c,tt={EIP712Domain:getTypesForEIP712Domain$1({domain:nt}),...et};validateTypedData$1({domain:nt,message:a,primaryType:d,types:tt});const bt=["0x1901"];return nt&&bt.push(hashDomain$1({domain:nt,types:tt})),d!=="EIP712Domain"&&bt.push(hashStruct$1({data:a,primaryType:d,types:tt})),keccak256$2(concat$2(bt))}function hashDomain$1({domain:c,types:a}){return hashStruct$1({data:c,primaryType:"EIP712Domain",types:a})}function hashStruct$1({data:c,primaryType:a,types:d}){const et=encodeData$1({data:c,primaryType:a,types:d});return keccak256$2(et)}function encodeData$1({data:c,primaryType:a,types:d}){const et=[{type:"bytes32"}],nt=[hashType$1({primaryType:a,types:d})];for(const tt of d[a]){const[bt,mt]=encodeField$1({types:d,name:tt.name,type:tt.type,value:c[tt.name]});et.push(bt),nt.push(mt)}return encodeAbiParameters$1(et,nt)}function hashType$1({primaryType:c,types:a}){const d=toHex$2(encodeType$2({primaryType:c,types:a}));return keccak256$2(d)}function encodeType$2({primaryType:c,types:a}){let d="";const et=findTypeDependencies$1({primaryType:c,types:a});et.delete(c);const nt=[c,...Array.from(et).sort()];for(const tt of nt)d+=`${tt}(${a[tt].map(({name:bt,type:mt})=>`${mt} ${bt}`).join(",")})`;return d}function findTypeDependencies$1({primaryType:c,types:a},d=new Set){const et=c.match(/^\w*/u),nt=et==null?void 0:et[0];if(d.has(nt)||a[nt]===void 0)return d;d.add(nt);for(const tt of a[nt])findTypeDependencies$1({primaryType:tt.type,types:a},d);return d}function encodeField$1({types:c,name:a,type:d,value:et}){if(c[d]!==void 0)return[{type:"bytes32"},keccak256$2(encodeData$1({data:et,primaryType:d,types:c}))];if(d==="bytes")return et=`0x${(et.length%2?"0":"")+et.slice(2)}`,[{type:"bytes32"},keccak256$2(et)];if(d==="string")return[{type:"bytes32"},keccak256$2(toHex$2(et))];if(d.lastIndexOf("]")===d.length-1){const nt=d.slice(0,d.lastIndexOf("[")),tt=et.map(bt=>encodeField$1({name:a,type:nt,types:c,value:bt}));return[{type:"bytes32"},keccak256$2(encodeAbiParameters$1(tt.map(([bt])=>bt),tt.map(([,bt])=>bt)))]}return[{type:d},et]}function validateTypedData$1({domain:c,message:a,primaryType:d,types:et}){const nt=et,tt=(bt,mt)=>{for(const vt of bt){const{name:$t,type:At}=vt,Mt=At,Tt=mt[$t],Rt=Mt.match(integerRegex$1);if(Rt&&(typeof Tt=="number"||typeof Tt=="bigint")){const[Dt,Nt,Ot]=Rt;numberToHex$1(Tt,{signed:Nt==="int",size:parseInt(Ot)/8})}if(Mt==="address"&&typeof Tt=="string"&&!isAddress$1(Tt))throw new InvalidAddressError$1({address:Tt});const kt=Mt.match(bytesRegex$1);if(kt){const[Dt,Nt]=kt;if(Nt&&size$2(Tt)!==parseInt(Nt))throw new BytesSizeMismatchError$1({expectedSize:parseInt(Nt),givenSize:size$2(Tt)})}const It=nt[Mt];It&&tt(It,Tt)}};if(nt.EIP712Domain&&c&&tt(nt.EIP712Domain,c),d!=="EIP712Domain"){const bt=nt[d];tt(bt,a)}}function getTypesForEIP712Domain$1({domain:c}){return[typeof(c==null?void 0:c.name)=="string"&&{name:"name",type:"string"},(c==null?void 0:c.version)&&{name:"version",type:"string"},typeof(c==null?void 0:c.chainId)=="number"&&{name:"chainId",type:"uint256"},(c==null?void 0:c.verifyingContract)&&{name:"verifyingContract",type:"address"},(c==null?void 0:c.salt)&&{name:"salt",type:"bytes32"}].filter(Boolean)}const presignMessagePrefix$1=`Ethereum Signed Message: +`;function hashMessage$2(c,a){const d=(()=>typeof c=="string"?stringToBytes$1(c):c.raw instanceof Uint8Array?c.raw:toBytes$3(c.raw))(),et=stringToBytes$1(`${presignMessagePrefix$1}${d.length}`);return keccak256$2(concat$2([et,d]),a)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */BigInt(0);BigInt(1);BigInt(2);function equalBytes(c,a){if(c.length!==a.length)return!1;for(let d=0;dtypeof d=="object"?Object.keys(d).every(et=>!!Object.values(RestrictedMethods).includes(et)):!1)}};const hasPermission=(c,a)=>a.some(d=>d.parentCapability===c),requirePermission=()=>(c,a,d)=>{const et=d.value;return d.value=async function(){const nt=new Wallet$1(this.communicator);let tt=await nt.getPermissions();if(hasPermission(a,tt)||(tt=await nt.requestPermissions([{[a]:{}}])),!hasPermission(a,tt))throw new PermissionsError("Permissions rejected",PERMISSIONS_REQUEST_REJECTED);return et.apply(this)},d};var __decorate=globalThis&&globalThis.__decorate||function(c,a,d,et){var nt=arguments.length,tt=nt<3?a:et===null?et=Object.getOwnPropertyDescriptor(a,d):et,bt;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")tt=Reflect.decorate(c,a,d,et);else for(var mt=c.length-1;mt>=0;mt--)(bt=c[mt])&&(tt=(nt<3?bt(tt):nt>3?bt(a,d,tt):bt(a,d))||tt);return nt>3&&tt&&Object.defineProperty(a,d,tt),tt};let Safe$1=class{constructor(a){this.communicator=a}async getChainInfo(){return(await this.communicator.send(Methods.getChainInfo,void 0)).data}async getInfo(){return(await this.communicator.send(Methods.getSafeInfo,void 0)).data}async experimental_getBalances({currency:a="usd"}={}){return(await this.communicator.send(Methods.getSafeBalances,{currency:a})).data}async check1271Signature(a,d="0x"){const et=await this.getInfo(),nt=encodeFunctionData$1({abi:[{constant:!1,inputs:[{name:"_dataHash",type:"bytes32"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[a,d]}),tt={call:RPC_CALLS.eth_call,params:[{to:et.safeAddress,data:nt},"latest"]};try{return(await this.communicator.send(Methods.rpcCall,tt)).data.slice(0,10).toLowerCase()===MAGIC_VALUE}catch{return!1}}async check1271SignatureBytes(a,d="0x"){const et=await this.getInfo(),nt=encodeFunctionData$1({abi:[{constant:!1,inputs:[{name:"_data",type:"bytes"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[a,d]}),tt={call:RPC_CALLS.eth_call,params:[{to:et.safeAddress,data:nt},"latest"]};try{return(await this.communicator.send(Methods.rpcCall,tt)).data.slice(0,10).toLowerCase()===MAGIC_VALUE_BYTES}catch{return!1}}calculateMessageHash(a){return hashMessage$2(a)}calculateTypedMessageHash(a){const d=typeof a.domain.chainId=="object"?a.domain.chainId.toNumber():Number(a.domain.chainId);let et=a.primaryType;if(!et){const nt=Object.values(a.types),tt=Object.keys(a.types).filter(bt=>nt.every(mt=>mt.every(({type:vt})=>vt.replace("[","").replace("]","")!==bt)));if(tt.length===0||tt.length>1)throw new Error("Please specify primaryType");et=tt[0]}return hashTypedData$1({message:a.message,domain:{...a.domain,chainId:d,verifyingContract:a.domain.verifyingContract,salt:a.domain.salt},types:a.types,primaryType:et})}async getOffChainSignature(a){return(await this.communicator.send(Methods.getOffChainSignature,a)).data}async isMessageSigned(a,d="0x"){let et;if(typeof a=="string"&&(et=async()=>{const nt=this.calculateMessageHash(a);return await this.isMessageHashSigned(nt,d)}),isObjectEIP712TypedData(a)&&(et=async()=>{const nt=this.calculateTypedMessageHash(a);return await this.isMessageHashSigned(nt,d)}),et)return await et();throw new Error("Invalid message type")}async isMessageHashSigned(a,d="0x"){const et=[this.check1271Signature.bind(this),this.check1271SignatureBytes.bind(this)];for(const nt of et)if(await nt(a,d))return!0;return!1}async getEnvironmentInfo(){return(await this.communicator.send(Methods.getEnvironmentInfo,void 0)).data}async requestAddressBook(){return(await this.communicator.send(Methods.requestAddressBook,void 0)).data}};__decorate([requirePermission()],Safe$1.prototype,"requestAddressBook",null);class SafeAppsSDK{constructor(a={}){const{allowedDomains:d=null,debug:et=!1}=a;this.communicator=new PostMessageCommunicator(d,et),this.eth=new Eth(this.communicator),this.txs=new TXs(this.communicator),this.safe=new Safe$1(this.communicator),this.wallet=new Wallet$1(this.communicator)}}const SDK=SafeAppsSDK;var dist={},provider={},utils={};Object.defineProperty(utils,"__esModule",{value:!0});utils.getLowerCase=void 0;function getLowerCase(c){return c&&c.toLowerCase()}utils.getLowerCase=getLowerCase;Object.defineProperty(provider,"__esModule",{value:!0});provider.SafeAppProvider=void 0;const events_1=eventsExports,utils_1$2=utils;class SafeAppProvider extends events_1.EventEmitter{constructor(a,d){super(),this.submittedTxs=new Map,this.safe=a,this.sdk=d}async connect(){this.emit("connect",{chainId:this.chainId})}async disconnect(){}get chainId(){return this.safe.chainId}async request(a){const{method:d,params:et=[]}=a;switch(d){case"eth_accounts":return[this.safe.safeAddress];case"net_version":case"eth_chainId":return`0x${this.chainId.toString(16)}`;case"personal_sign":{const[vt,$t]=et;if(this.safe.safeAddress.toLowerCase()!==$t.toLowerCase())throw new Error("The address or message hash is invalid");const At=await this.sdk.txs.signMessage(vt);return("signature"in At?At.signature:void 0)||"0x"}case"eth_sign":{const[vt,$t]=et;if(this.safe.safeAddress.toLowerCase()!==vt.toLowerCase()||!$t.startsWith("0x"))throw new Error("The address or message hash is invalid");const At=await this.sdk.txs.signMessage($t);return("signature"in At?At.signature:void 0)||"0x"}case"eth_signTypedData":case"eth_signTypedData_v4":{const[vt,$t]=et,At=typeof $t=="string"?JSON.parse($t):$t;if(this.safe.safeAddress.toLowerCase()!==vt.toLowerCase())throw new Error("The address is invalid");const Mt=await this.sdk.txs.signTypedMessage(At);return("signature"in Mt?Mt.signature:void 0)||"0x"}case"eth_sendTransaction":const nt={...et[0],value:et[0].value||"0",data:et[0].data||"0x"};typeof nt.gas=="string"&&nt.gas.startsWith("0x")&&(nt.gas=parseInt(nt.gas,16));const tt=await this.sdk.txs.send({txs:[nt],params:{safeTxGas:nt.gas}});return this.submittedTxs.set(tt.safeTxHash,{from:this.safe.safeAddress,hash:tt.safeTxHash,gas:0,gasPrice:"0x00",nonce:0,input:nt.data,value:nt.value,to:nt.to,blockHash:null,blockNumber:null,transactionIndex:null}),tt.safeTxHash;case"eth_blockNumber":return(await this.sdk.eth.getBlockByNumber(["latest"])).number;case"eth_getBalance":return this.sdk.eth.getBalance([(0,utils_1$2.getLowerCase)(et[0]),et[1]]);case"eth_getCode":return this.sdk.eth.getCode([(0,utils_1$2.getLowerCase)(et[0]),et[1]]);case"eth_getTransactionCount":return this.sdk.eth.getTransactionCount([(0,utils_1$2.getLowerCase)(et[0]),et[1]]);case"eth_getStorageAt":return this.sdk.eth.getStorageAt([(0,utils_1$2.getLowerCase)(et[0]),et[1],et[2]]);case"eth_getBlockByNumber":return this.sdk.eth.getBlockByNumber([et[0],et[1]]);case"eth_getBlockByHash":return this.sdk.eth.getBlockByHash([et[0],et[1]]);case"eth_getTransactionByHash":let mt=et[0];try{mt=(await this.sdk.txs.getBySafeTxHash(mt)).txHash||mt}catch{}return this.submittedTxs.has(mt)?this.submittedTxs.get(mt):this.sdk.eth.getTransactionByHash([mt]).then(vt=>(vt&&(vt.hash=et[0]),vt));case"eth_getTransactionReceipt":{let vt=et[0];try{vt=(await this.sdk.txs.getBySafeTxHash(vt)).txHash||vt}catch{}return this.sdk.eth.getTransactionReceipt([vt]).then($t=>($t&&($t.transactionHash=et[0]),$t))}case"eth_estimateGas":return this.sdk.eth.getEstimateGas(et[0]);case"eth_call":return this.sdk.eth.call([et[0],et[1]]);case"eth_getLogs":return this.sdk.eth.getPastLogs([et[0]]);case"eth_gasPrice":return this.sdk.eth.getGasPrice();case"wallet_getPermissions":return this.sdk.wallet.getPermissions();case"wallet_requestPermissions":return this.sdk.wallet.requestPermissions(et[0]);case"safe_setSettings":return this.sdk.eth.setSafeSettings([et[0]]);default:throw Error(`"${a.method}" not implemented`)}}send(a,d){a||d("Undefined request"),this.request(a).then(et=>d(null,{jsonrpc:"2.0",id:a.id,result:et})).catch(et=>d(et,null))}}provider.SafeAppProvider=SafeAppProvider;(function(c){Object.defineProperty(c,"__esModule",{value:!0}),c.SafeAppProvider=void 0;var a=provider;Object.defineProperty(c,"SafeAppProvider",{enumerable:!0,get:function(){return a.SafeAppProvider}})})(dist);const safeAppsSDK=new SDK,waitAndError=c=>new Promise((a,d)=>setTimeout(d,c));let cachedSafeInfo;const getSafeInfo=async()=>(cachedSafeInfo!=null||(cachedSafeInfo=await safeAppsSDK.safe.getInfo(),console.log(cachedSafeInfo)),cachedSafeInfo),isConnectedToSafe=async()=>{try{const c=await Promise.race([waitAndError(300),getSafeInfo()]);return console.log(c),c!=null}catch{return!1}},getSafeAppsProvider=async()=>{const c=await getSafeInfo();if(!c.chainId)throw Error("Unsupported chain");return new BrowserProvider(new dist.SafeAppProvider(c,safeAppsSDK))},submitTxs=async c=>(await safeAppsSDK.txs.send({txs:c})).safeTxHash,PROTOCOL_CHAIN_ID=84531,getProvider=async()=>{var c;return await isConnectedToSafe()?(console.log("Use SafeAppsProvider"),await getSafeAppsProvider()):(console.log("Use JsonRpcProvider"),new JsonRpcProvider((c=NetworkUtil.getNetworkById(PROTOCOL_CHAIN_ID))==null?void 0:c.url))},getJsonRpcProvider=async c=>{var a,d;return console.log("Use JsonRpcProvider"),console.log((a=NetworkUtil.getNetworkById(parseInt(c)))==null?void 0:a.url),new JsonRpcProvider((d=NetworkUtil.getNetworkById(parseInt(c)))==null?void 0:d.url)},nav="_nav_mbz2l_1",wrapper="_wrapper_mbz2l_20",maincontainer="_maincontainer_mbz2l_31",network$1="_network_mbz2l_42",buttonContainer="_buttonContainer_mbz2l_49",container="_container_mbz2l_59",mode$1="_mode_mbz2l_68",root="_root_mbz2l_78",icon$1="_icon_mbz2l_85",iconLight="_iconLight_mbz2l_92",iconDark="_iconDark_mbz2l_97",classes$d={nav,wrapper,maincontainer,network:network$1,buttonContainer,container,mode:mode$1,root,icon:icon$1,iconLight,iconDark},Head=c=>{const{colorScheme:a,toggleColorScheme:d}=useMantineColorScheme(),[et,nt]=reactExports.useState(""),[tt,bt]=reactExports.useState(84531);reactExports.useState(window.innerWidth<=768);const mt=a==="dark",vt=useNavigate();return reactExports.useEffect(()=>{(async()=>{var Mt,Tt;const $t=await getProvider(),{chainId:At}=await $t.getNetwork();bt(At),nt(`${(Mt=NetworkUtil.getNetworkById(parseInt(At)))==null?void 0:Mt.name} ${(Tt=NetworkUtil.getNetworkById(parseInt(At)))==null?void 0:Tt.type}`)})()},[window.innerWidth]),jsxRuntimeExports.jsx(AppShell.Header,{children:jsxRuntimeExports.jsx("div",{className:classes$d.wrapper,children:jsxRuntimeExports.jsxs(Group,{position:"apart",className:classes$d.maincontainer,children:[jsxRuntimeExports.jsx(Group,{className:classes$d.container,children:jsxRuntimeExports.jsx(Image$1,{onClick:()=>{vt(RoutePath.home)},style:{cursor:"pointer",width:"180px"},src:mt?LogoDark:LogoLight,alt:"Logo"})}),jsxRuntimeExports.jsx(Group,{className:classes$d.mode,children:jsxRuntimeExports.jsx("div",{className:classes$d.container,children:mt?jsxRuntimeExports.jsx(EAe,{size:24,stroke:1.5,onClick:()=>d(),style:{cursor:"pointer"}}):jsxRuntimeExports.jsx(Gme,{size:24,stroke:1.5,style:{cursor:"pointer"},onClick:()=>d()})})})]})})})},AppLayout=c=>{const{children:a}=c,[d,et]=reactExports.useState(!1),{colorScheme:nt,toggleColorScheme:tt}=useMantineColorScheme(),bt=nt=="dark";return jsxRuntimeExports.jsxs(AppShell,{header:{height:60},padding:"md",styles:{main:{backgroundColor:bt?"var(--mantine-color-dark-9)":"var(--mantine-color-gray-0)"},header:{backgroundColor:bt?"var(--mantine-color-dark-7)":"var(--mantine-color-white)"}},children:[jsxRuntimeExports.jsx(Head,{setOpened:et,opened:d}),jsxRuntimeExports.jsxs(AppShell.Main,{children:[" ",jsxRuntimeExports.jsx(Container,{children:a})]})]})},homeContainer="_homeContainer_it9to_47",avatar$1="_avatar_it9to_55",avatarContainer$1="_avatarContainer_it9to_62",safe="_safe_it9to_71",safeContainer="_safeContainer_it9to_78",formContainer$1="_formContainer_it9to_86",heading$1="_heading_it9to_93",actions$1="_actions_it9to_6",links$1="_links_it9to_117",subHeading$1="_subHeading_it9to_125",topHeading="_topHeading_it9to_131",inputContainer$1="_inputContainer_it9to_140",selectGroup="_selectGroup_it9to_152",btn$1="_btn_it9to_158",card$1="_card_it9to_170",helperText="_helperText_it9to_183",mode="_mode_it9to_187",successContainer="_successContainer_it9to_197",network="_network_it9to_207",copyContainer="_copyContainer_it9to_215",goBack="_goBack_it9to_221",input="_input_it9to_140",classes$c={homeContainer,avatar:avatar$1,avatarContainer:avatarContainer$1,safe,safeContainer,formContainer:formContainer$1,heading:heading$1,actions:actions$1,links:links$1,subHeading:subHeading$1,topHeading,inputContainer:inputContainer$1,selectGroup,btn:btn$1,card:card$1,helperText,mode,successContainer,network,copyContainer,goBack,input},Safe="/assets/safe-a3da9967.svg";var dayjs_min={exports:{}};(function(c,a){(function(d,et){c.exports=et()})(commonjsGlobal,function(){var d=1e3,et=6e4,nt=36e5,tt="millisecond",bt="second",mt="minute",vt="hour",$t="day",At="week",Mt="month",Tt="quarter",Rt="year",kt="date",It="Invalid Date",Dt=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,Nt=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,Ot={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(gt){var xt=["th","st","nd","rd"],St=gt%100;return"["+gt+(xt[(St-20)%10]||xt[St]||xt[0])+"]"}},Ut=function(gt,xt,St){var _t=String(gt);return!_t||_t.length>=xt?gt:""+Array(xt+1-_t.length).join(St)+gt},Gt={s:Ut,z:function(gt){var xt=-gt.utcOffset(),St=Math.abs(xt),_t=Math.floor(St/60),Pt=St%60;return(xt<=0?"+":"-")+Ut(_t,2,"0")+":"+Ut(Pt,2,"0")},m:function gt(xt,St){if(xt.date()1)return gt(ht[0])}else{var wt=xt.name;Xt[wt]=xt,Pt=wt}return!_t&&Pt&&(Wt=Pt),Pt||!_t&&Wt},c0=function(gt,xt){if(n0(gt))return gt.clone();var St=typeof xt=="object"?xt:{};return St.date=gt,St.args=arguments,new dt(St)},Ct=Gt;Ct.l=t0,Ct.i=n0,Ct.w=function(gt,xt){return c0(gt,{locale:xt.$L,utc:xt.$u,x:xt.$x,$offset:xt.$offset})};var dt=function(){function gt(St){this.$L=t0(St.locale,null,!0),this.parse(St),this.$x=this.$x||St.x||{},this[a0]=!0}var xt=gt.prototype;return xt.parse=function(St){this.$d=function(_t){var Pt=_t.date,Et=_t.utc;if(Pt===null)return new Date(NaN);if(Ct.u(Pt))return new Date;if(Pt instanceof Date)return new Date(Pt);if(typeof Pt=="string"&&!/Z$/i.test(Pt)){var ht=Pt.match(Dt);if(ht){var wt=ht[2]-1||0,Bt=(ht[7]||"0").substring(0,3);return Et?new Date(Date.UTC(ht[1],wt,ht[3]||1,ht[4]||0,ht[5]||0,ht[6]||0,Bt)):new Date(ht[1],wt,ht[3]||1,ht[4]||0,ht[5]||0,ht[6]||0,Bt)}}return new Date(Pt)}(St),this.init()},xt.init=function(){var St=this.$d;this.$y=St.getFullYear(),this.$M=St.getMonth(),this.$D=St.getDate(),this.$W=St.getDay(),this.$H=St.getHours(),this.$m=St.getMinutes(),this.$s=St.getSeconds(),this.$ms=St.getMilliseconds()},xt.$utils=function(){return Ct},xt.isValid=function(){return this.$d.toString()!==It},xt.isSame=function(St,_t){var Pt=c0(St);return this.startOf(_t)<=Pt&&Pt<=this.endOf(_t)},xt.isAfter=function(St,_t){return c0(St)=nt[a][nt[a].length-1]?{levelIndex:a+1,rowIndex:0,cellIndex:et}:{levelIndex:a,rowIndex:d+1,cellIndex:et};case"left":return a===0&&d===0&&et===0?null:d===0&&et===0?{levelIndex:a-1,rowIndex:nt[a-1].length-1,cellIndex:nt[a-1][nt[a-1].length-1]-1}:et===0?{levelIndex:a,rowIndex:d-1,cellIndex:nt[a][d-1]-1}:{levelIndex:a,rowIndex:d,cellIndex:et-1};case"right":return d===nt[a].length-1&&et===nt[a][d]-1?{levelIndex:a+1,rowIndex:0,cellIndex:0}:et===nt[a][d]-1?{levelIndex:a,rowIndex:d+1,cellIndex:0}:{levelIndex:a,rowIndex:d,cellIndex:et+1};default:return{levelIndex:a,rowIndex:d,cellIndex:et}}}function focusOnNextFocusableControl({controlsRef:c,direction:a,levelIndex:d,rowIndex:et,cellIndex:nt,size:tt}){var vt,$t,At;const bt=getNextIndex({direction:a,size:tt,rowIndex:et,cellIndex:nt,levelIndex:d});if(!bt)return;const mt=(At=($t=(vt=c.current)==null?void 0:vt[bt.levelIndex])==null?void 0:$t[bt.rowIndex])==null?void 0:At[bt.cellIndex];mt&&(mt.disabled||mt.getAttribute("data-hidden")||mt.getAttribute("data-outside")?focusOnNextFocusableControl({controlsRef:c,direction:a,levelIndex:bt.levelIndex,cellIndex:bt.cellIndex,rowIndex:bt.rowIndex,size:tt}):mt.focus())}function getDirection(c){switch(c){case"ArrowDown":return"down";case"ArrowUp":return"up";case"ArrowRight":return"right";case"ArrowLeft":return"left";default:return null}}function getControlsSize(c){var a;return(a=c.current)==null?void 0:a.map(d=>d.map(et=>et.length))}function handleControlKeyDown({controlsRef:c,levelIndex:a,rowIndex:d,cellIndex:et,event:nt}){const tt=getDirection(nt.key);if(tt){nt.preventDefault();const bt=getControlsSize(c);focusOnNextFocusableControl({controlsRef:c,direction:tt,levelIndex:a,rowIndex:d,cellIndex:et,size:bt})}}function assignTime(c,a){if(!c||!a)return a;const d=c.getHours(),et=c.getMinutes(),nt=c.getSeconds(),tt=c.getMilliseconds(),bt=new Date(a);return bt.setHours(d),bt.setMinutes(et),bt.setSeconds(nt),bt.setMilliseconds(tt),bt}var timezone={exports:{}};(function(c,a){(function(d,et){c.exports=et()})(commonjsGlobal,function(){var d={year:0,month:1,day:2,hour:3,minute:4,second:5},et={};return function(nt,tt,bt){var mt,vt=function(Tt,Rt,kt){kt===void 0&&(kt={});var It=new Date(Tt),Dt=function(Nt,Ot){Ot===void 0&&(Ot={});var Ut=Ot.timeZoneName||"short",Gt=Nt+"|"+Ut,Wt=et[Gt];return Wt||(Wt=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:Nt,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:Ut}),et[Gt]=Wt),Wt}(Rt,kt);return Dt.formatToParts(It)},$t=function(Tt,Rt){for(var kt=vt(Tt,Rt),It=[],Dt=0;Dt=0&&(It[Gt]=parseInt(Ut,10))}var Wt=It[3],Xt=Wt===24?0:Wt,a0=It[0]+"-"+It[1]+"-"+It[2]+" "+Xt+":"+It[4]+":"+It[5]+":000",n0=+Tt;return(bt.utc(a0).valueOf()-(n0-=n0%1e3))/6e4},At=tt.prototype;At.tz=function(Tt,Rt){Tt===void 0&&(Tt=mt);var kt=this.utcOffset(),It=this.toDate(),Dt=It.toLocaleString("en-US",{timeZone:Tt}),Nt=Math.round((It-new Date(Dt))/1e3/60),Ot=bt(Dt,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(15*-Math.round(It.getTimezoneOffset()/15)-Nt,!0);if(Rt){var Ut=Ot.utcOffset();Ot=Ot.add(kt-Ut,"minute")}return Ot.$x.$timezone=Tt,Ot},At.offsetName=function(Tt){var Rt=this.$x.$timezone||bt.tz.guess(),kt=vt(this.valueOf(),Rt,{timeZoneName:Tt}).find(function(It){return It.type.toLowerCase()==="timezonename"});return kt&&kt.value};var Mt=At.startOf;At.startOf=function(Tt,Rt){if(!this.$x||!this.$x.$timezone)return Mt.call(this,Tt,Rt);var kt=bt(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return Mt.call(kt,Tt,Rt).tz(this.$x.$timezone,!0)},bt.tz=function(Tt,Rt,kt){var It=kt&&Rt,Dt=kt||Rt||mt,Nt=$t(+bt(),Dt);if(typeof Tt!="string")return bt(Tt).tz(Dt);var Ot=function(Xt,a0,n0){var t0=Xt-60*a0*1e3,c0=$t(t0,n0);if(a0===c0)return[t0,a0];var Ct=$t(t0-=60*(c0-a0)*1e3,n0);return c0===Ct?[t0,c0]:[Xt-60*Math.min(c0,Ct)*1e3,Math.max(c0,Ct)]}(bt.utc(Tt,It).valueOf(),Nt,Dt),Ut=Ot[0],Gt=Ot[1],Wt=bt(Ut).utcOffset(Gt);return Wt.$x.$timezone=Dt,Wt},bt.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},bt.tz.setDefault=function(Tt){mt=Tt}}})})(timezone);var timezoneExports=timezone.exports;const timezonePlugin=getDefaultExportFromCjs(timezoneExports);var utc={exports:{}};(function(c,a){(function(d,et){c.exports=et()})(commonjsGlobal,function(){var d="minute",et=/[+-]\d\d(?::?\d\d)?/g,nt=/([+-]|\d\d)/g;return function(tt,bt,mt){var vt=bt.prototype;mt.utc=function(It){var Dt={date:It,utc:!0,args:arguments};return new bt(Dt)},vt.utc=function(It){var Dt=mt(this.toDate(),{locale:this.$L,utc:!0});return It?Dt.add(this.utcOffset(),d):Dt},vt.local=function(){return mt(this.toDate(),{locale:this.$L,utc:!1})};var $t=vt.parse;vt.parse=function(It){It.utc&&(this.$u=!0),this.$utils().u(It.$offset)||(this.$offset=It.$offset),$t.call(this,It)};var At=vt.init;vt.init=function(){if(this.$u){var It=this.$d;this.$y=It.getUTCFullYear(),this.$M=It.getUTCMonth(),this.$D=It.getUTCDate(),this.$W=It.getUTCDay(),this.$H=It.getUTCHours(),this.$m=It.getUTCMinutes(),this.$s=It.getUTCSeconds(),this.$ms=It.getUTCMilliseconds()}else At.call(this)};var Mt=vt.utcOffset;vt.utcOffset=function(It,Dt){var Nt=this.$utils().u;if(Nt(It))return this.$u?0:Nt(this.$offset)?Mt.call(this):this.$offset;if(typeof It=="string"&&(It=function(Wt){Wt===void 0&&(Wt="");var Xt=Wt.match(et);if(!Xt)return null;var a0=(""+Xt[0]).match(nt)||["-",0,0],n0=a0[0],t0=60*+a0[1]+ +a0[2];return t0===0?0:n0==="+"?t0:-t0}(It),It===null))return this;var Ot=Math.abs(It)<=16?60*It:It,Ut=this;if(Dt)return Ut.$offset=Ot,Ut.$u=It===0,Ut;if(It!==0){var Gt=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(Ut=this.local().add(Ot+Gt,d)).$offset=Ot,Ut.$x.$localOffset=Gt}else Ut=this.utc();return Ut};var Tt=vt.format;vt.format=function(It){var Dt=It||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return Tt.call(this,Dt)},vt.valueOf=function(){var It=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*It},vt.isUTC=function(){return!!this.$u},vt.toISOString=function(){return this.toDate().toISOString()},vt.toString=function(){return this.toDate().toUTCString()};var Rt=vt.toDate;vt.toDate=function(It){return It==="s"&&this.$offset?mt(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():Rt.call(this)};var kt=vt.diff;vt.diff=function(It,Dt,Nt){if(It&&this.$u===It.$u)return kt.call(this,It,Dt,Nt);var Ot=this.local(),Ut=mt(It).local();return kt.call(Ot,Ut,Dt,Nt)}}})})(utc);var utcExports=utc.exports;const utcPlugin=getDefaultExportFromCjs(utcExports);dayjs.extend(utcPlugin);dayjs.extend(timezonePlugin);function getTimezoneOffset(c,a){return a?dayjs(c).tz(a).utcOffset()+c.getTimezoneOffset():0}const updateTimezone=(c,a,d)=>{if(!c)return null;if(!a)return c;let et=getTimezoneOffset(c,a);return d==="remove"&&(et*=-1),dayjs(c).add(et,"minutes").toDate()};function shiftTimezone(c,a,d,et){return et||!a?a:Array.isArray(a)?a.map(nt=>updateTimezone(nt,d,c)):updateTimezone(a,d,c)}const DATES_PROVIDER_DEFAULT_SETTINGS={locale:"en",timezone:null,firstDayOfWeek:1,weekendDays:[0,6],labelSeparator:"–",consistentWeeks:!1},DatesProviderContext=reactExports.createContext(DATES_PROVIDER_DEFAULT_SETTINGS);function useDatesContext(){const c=reactExports.useContext(DatesProviderContext),a=reactExports.useCallback(bt=>bt||c.locale,[c.locale]),d=reactExports.useCallback(bt=>bt||c.timezone||void 0,[c.timezone]),et=reactExports.useCallback(bt=>typeof bt=="number"?bt:c.firstDayOfWeek,[c.firstDayOfWeek]),nt=reactExports.useCallback(bt=>Array.isArray(bt)?bt:c.weekendDays,[c.weekendDays]),tt=reactExports.useCallback(bt=>typeof bt=="string"?bt:c.labelSeparator,[c.labelSeparator]);return{...c,getLocale:a,getTimezone:d,getFirstDayOfWeek:et,getWeekendDays:nt,getLabelSeparator:tt}}function formatValue(c,a){if(a==="range"&&Array.isArray(c)){const[d,et]=c;return d?et?`${d.toISOString()} – ${et.toISOString()}`:`${d.toISOString()} –`:""}return a==="multiple"&&Array.isArray(c)?c.map(d=>d==null?void 0:d.toISOString()).filter(Boolean).join(", "):!Array.isArray(c)&&c?c.toISOString():""}function HiddenDatesInput({value:c,type:a,name:d,form:et}){return React.createElement("input",{type:"hidden",value:formatValue(c,a),name:d,form:et})}HiddenDatesInput.displayName="@mantine/dates/HiddenDatesInput";var classes$b={input:"m_468e7eda"};const defaultProps$i={},TimeInput=factory((c,a)=>{const d=useProps("TimeInput",defaultProps$i,c),{classNames:et,styles:nt,unstyled:tt,vars:bt,withSeconds:mt,minTime:vt,maxTime:$t,value:At,onChange:Mt,...Tt}=d,{resolvedClassNames:Rt,resolvedStyles:kt}=useResolvedStylesApi({classNames:et,styles:nt,props:d}),It=Nt=>{if(vt!==void 0||$t!==void 0){const[Ot,Ut,Gt]=Nt.split(":").map(Number);if(vt){const[Wt,Xt,a0]=vt.split(":").map(Number);if(OtWt||Ot===Wt&&Ut>Xt||mt&&Ot===Wt&&Ut===Xt&&Gt>a0)return 1}}return 0},Dt=Nt=>{var Ot,Ut,Gt;if((Ot=d.onBlur)==null||Ot.call(d,Nt),vt!==void 0||$t!==void 0){const Wt=Nt.currentTarget.value;if(Wt){const Xt=It(Wt);Xt===1?(Nt.currentTarget.value=$t,(Ut=d.onChange)==null||Ut.call(d,Nt)):Xt===-1&&(Nt.currentTarget.value=vt,(Gt=d.onChange)==null||Gt.call(d,Nt))}}};return React.createElement(InputBase,{classNames:{...Rt,input:clsx(classes$b.input,Rt==null?void 0:Rt.input)},styles:kt,unstyled:tt,ref:a,value:At,...Tt,step:mt?1:60,onChange:Mt,onBlur:Dt,type:"time",__staticSelector:"TimeInput"})});TimeInput.classes=InputBase.classes;TimeInput.displayName="@mantine/dates/TimeInput";var classes$a={day:"m_396ce5cb"};const defaultProps$h={},varsResolver$3=(c,{size:a})=>({day:{"--day-size":getSize(a,"day-size")}}),Day=factory((c,a)=>{const d=useProps("Day",defaultProps$h,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,date:$t,disabled:At,__staticSelector:Mt,weekend:Tt,outside:Rt,selected:kt,renderDay:It,inRange:Dt,firstInRange:Nt,lastInRange:Ot,hidden:Ut,static:Gt,...Wt}=d,Xt=useStyles({name:Mt||"Day",classes:classes$a,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$3,rootSelector:"day"}),a0=useDatesContext();return React.createElement(UnstyledButton,{...Xt("day",{style:Ut?{display:"none"}:void 0}),component:Gt?"div":"button",ref:a,disabled:At,"data-today":dayjs($t).isSame(shiftTimezone("add",new Date,a0.getTimezone()),"day")||void 0,"data-hidden":Ut||void 0,"data-disabled":At||void 0,"data-weekend":!At&&!Rt&&Tt||void 0,"data-outside":!At&&Rt||void 0,"data-selected":!At&&kt||void 0,"data-in-range":Dt&&!At||void 0,"data-first-in-range":Nt&&!At||void 0,"data-last-in-range":Ot&&!At||void 0,"data-static":Gt||void 0,unstyled:mt,...Wt},(It==null?void 0:It($t))||$t.getDate())});Day.classes=classes$a;Day.displayName="@mantine/dates/Day";function getWeekdayNames({locale:c,format:a="dd",firstDayOfWeek:d=1}){const et=dayjs().day(d),nt=[];for(let tt=0;tt<7;tt+=1)typeof a=="string"?nt.push(dayjs(et).add(tt,"days").locale(c).format(a)):nt.push(a(dayjs(et).add(tt,"days").toDate()));return nt}var classes$9={weekday:"m_18a3eca"};const defaultProps$g={},varsResolver$2=(c,{size:a})=>({weekdaysRow:{"--wr-fz":getFontSize(a),"--wr-spacing":getSpacing(a)}}),WeekdaysRow=factory((c,a)=>{const d=useProps("WeekdaysRow",defaultProps$g,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,locale:$t,firstDayOfWeek:At,weekdayFormat:Mt,cellComponent:Tt="th",__staticSelector:Rt,...kt}=d,It=useStyles({name:Rt||"WeekdaysRow",classes:classes$9,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$2,rootSelector:"weekdaysRow"}),Dt=useDatesContext(),Nt=getWeekdayNames({locale:Dt.getLocale($t),format:Mt,firstDayOfWeek:Dt.getFirstDayOfWeek(At)}).map((Ot,Ut)=>React.createElement(Tt,{key:Ut,...It("weekday")},Ot));return React.createElement(Box,{component:"tr",ref:a,...It("weekdaysRow"),...kt},Nt)});WeekdaysRow.classes=classes$9;WeekdaysRow.displayName="@mantine/dates/WeekdaysRow";function getEndOfWeek(c,a=1){const d=new Date(c),et=a===0?6:a-1;for(;d.getDay()!==et;)d.setDate(d.getDate()+1);return d}function getStartOfWeek(c,a=1){const d=new Date(c);for(;d.getDay()!==a;)d.setDate(d.getDate()-1);return d}function getMonthDays({month:c,firstDayOfWeek:a=1,consistentWeeks:d}){const et=c.getMonth(),nt=new Date(c.getFullYear(),et,1),tt=new Date(c.getFullYear(),c.getMonth()+1,0),bt=getEndOfWeek(tt,a),mt=getStartOfWeek(nt,a),vt=[];for(;mt<=bt;){const $t=[];for(let At=0;At<7;At+=1)$t.push(new Date(mt)),mt.setDate(mt.getDate()+1);vt.push($t)}if(d&&vt.length<6){const $t=vt[vt.length-1],At=$t[$t.length-1],Mt=new Date(At);for(Mt.setDate(Mt.getDate()+1);vt.length<6;){const Tt=[];for(let Rt=0;Rt<7;Rt+=1)Tt.push(new Date(Mt)),Mt.setDate(Mt.getDate()+1);vt.push(Tt)}}return vt}function isSameMonth(c,a){return c.getFullYear()===a.getFullYear()&&c.getMonth()===a.getMonth()}function isAfterMinDate(c,a){return a instanceof Date?dayjs(c).isAfter(dayjs(a).subtract(1,"day"),"day"):!0}function isBeforeMaxDate(c,a){return a instanceof Date?dayjs(c).isBefore(dayjs(a).add(1,"day"),"day"):!0}function getDateInTabOrder(c,a,d,et,nt,tt,bt){const mt=c.flat().filter(At=>{var Mt;return isBeforeMaxDate(At,d)&&isAfterMinDate(At,a)&&!(nt!=null&&nt(At))&&!((Mt=et==null?void 0:et(At))!=null&&Mt.disabled)&&(!tt||isSameMonth(At,bt))}),vt=mt.find(At=>{var Mt;return(Mt=et==null?void 0:et(At))==null?void 0:Mt.selected});if(vt)return vt;const $t=mt.find(At=>dayjs().isSame(At,"date"));return $t||mt[0]}var classes$8={month:"m_cc9820d3",monthCell:"m_8f457cd5"};const defaultProps$f={withCellSpacing:!0},Month=factory((c,a)=>{const d=useProps("Month",defaultProps$f,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,__staticSelector:$t,locale:At,firstDayOfWeek:Mt,weekdayFormat:Tt,month:Rt,weekendDays:kt,getDayProps:It,excludeDate:Dt,minDate:Nt,maxDate:Ot,renderDay:Ut,hideOutsideDates:Gt,hideWeekdays:Wt,getDayAriaLabel:Xt,static:a0,__getDayRef:n0,__onDayKeyDown:t0,__onDayClick:c0,__onDayMouseEnter:Ct,__preventFocus:dt,__stopPropagation:yt,withCellSpacing:gt,size:xt,...St}=d,_t=useStyles({name:$t||"Month",classes:classes$8,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,rootSelector:"month"}),Pt=useDatesContext(),Et=getMonthDays({month:Rt,firstDayOfWeek:Pt.getFirstDayOfWeek(Mt),consistentWeeks:Pt.consistentWeeks}),ht=getDateInTabOrder(Et,Nt,Ot,It,Dt,Gt,Rt),{resolvedClassNames:wt,resolvedStyles:Bt}=useResolvedStylesApi({classNames:et,styles:bt,props:d}),Lt=Et.map((jt,Ft)=>{const Vt=jt.map((zt,qt)=>{const Kt=!isSameMonth(zt,Rt),e0=(Xt==null?void 0:Xt(zt))||dayjs(zt).locale(At||Pt.locale).format("D MMMM YYYY"),Zt=It==null?void 0:It(zt),Jt=dayjs(zt).isSame(ht,"date");return React.createElement("td",{key:zt.toString(),..._t("monthCell"),"data-with-spacing":gt||void 0},React.createElement(Day,{__staticSelector:$t||"Month",classNames:wt,styles:Bt,unstyled:mt,"data-mantine-stop-propagation":yt||void 0,renderDay:Ut,date:zt,size:xt,weekend:Pt.getWeekendDays(kt).includes(zt.getDay()),outside:Kt,hidden:Gt?Kt:!1,"aria-label":e0,static:a0,disabled:(Dt==null?void 0:Dt(zt))||!isBeforeMaxDate(zt,Ot)||!isAfterMinDate(zt,Nt),ref:i0=>n0==null?void 0:n0(Ft,qt,i0),...Zt,onKeyDown:i0=>{var h0;(h0=Zt==null?void 0:Zt.onKeyDown)==null||h0.call(Zt,i0),t0==null||t0(i0,{rowIndex:Ft,cellIndex:qt,date:zt})},onMouseEnter:i0=>{var h0;(h0=Zt==null?void 0:Zt.onMouseEnter)==null||h0.call(Zt,i0),Ct==null||Ct(i0,zt)},onClick:i0=>{var h0;(h0=Zt==null?void 0:Zt.onClick)==null||h0.call(Zt,i0),c0==null||c0(i0,zt)},onMouseDown:i0=>{var h0;(h0=Zt==null?void 0:Zt.onMouseDown)==null||h0.call(Zt,i0),dt&&i0.preventDefault()},tabIndex:dt||!Jt?-1:0}))});return React.createElement("tr",{key:Ft,..._t("monthRow")},Vt)});return React.createElement(Box,{component:"table",..._t("month"),size:xt,ref:a,...St},!Wt&&React.createElement("thead",{..._t("monthThead")},React.createElement(WeekdaysRow,{__staticSelector:$t||"Month",locale:At,firstDayOfWeek:Mt,weekdayFormat:Tt,size:xt,classNames:wt,styles:Bt,unstyled:mt})),React.createElement("tbody",{..._t("monthTbody")},Lt))});Month.classes=classes$8;Month.displayName="@mantine/dates/Month";var classes$7={pickerControl:"m_dc6a3c71"};const defaultProps$e={},varsResolver$1=(c,{size:a})=>({pickerControl:{"--dpc-fz":getFontSize(a),"--dpc-size":getSize(a,"dpc-size")}}),PickerControl=factory((c,a)=>{const d=useProps("PickerControl",defaultProps$e,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,firstInRange:$t,lastInRange:At,inRange:Mt,__staticSelector:Tt,selected:Rt,disabled:kt,...It}=d,Dt=useStyles({name:Tt||"PickerControl",classes:classes$7,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver:varsResolver$1,rootSelector:"pickerControl"});return React.createElement(UnstyledButton,{...Dt("pickerControl"),ref:a,unstyled:mt,"data-picker-control":!0,"data-selected":Rt&&!kt||void 0,"data-disabled":kt||void 0,"data-in-range":Mt&&!kt&&!Rt||void 0,"data-first-in-range":$t&&!kt||void 0,"data-last-in-range":At&&!kt||void 0,disabled:kt,...It})});PickerControl.classes=classes$7;PickerControl.displayName="@mantine/dates/PickerControl";function isYearDisabled(c,a,d){return!a&&!d?!1:!!(a&&dayjs(c).isBefore(a,"year")||d&&dayjs(c).isAfter(d,"year"))}function getYearInTabOrder(c,a,d,et){const nt=c.flat().filter(mt=>{var vt;return!isYearDisabled(mt,a,d)&&!((vt=et==null?void 0:et(mt))!=null&&vt.disabled)}),tt=nt.find(mt=>{var vt;return(vt=et==null?void 0:et(mt))==null?void 0:vt.selected});if(tt)return tt;const bt=nt.find(mt=>dayjs().isSame(mt,"year"));return bt||nt[0]}function getYearsData(c){const a=c.getFullYear(),d=a-a%10;let et=0;const nt=[[],[],[],[]];for(let tt=0;tt<4;tt+=1){const bt=tt===3?1:3;for(let mt=0;mt{const d=useProps("YearsList",defaultProps$d,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,decade:$t,yearsListFormat:At,locale:Mt,minDate:Tt,maxDate:Rt,getYearControlProps:kt,__staticSelector:It,__getControlRef:Dt,__onControlKeyDown:Nt,__onControlClick:Ot,__onControlMouseEnter:Ut,__preventFocus:Gt,__stopPropagation:Wt,withCellSpacing:Xt,size:a0,...n0}=d,t0=useStyles({name:It||"YearsList",classes:classes$6,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,rootSelector:"yearsList"}),c0=useDatesContext(),Ct=getYearsData($t),dt=getYearInTabOrder(Ct,Tt,Rt,kt),yt=Ct.map((gt,xt)=>{const St=gt.map((_t,Pt)=>{const Et=kt==null?void 0:kt(_t),ht=dayjs(_t).isSame(dt,"year");return React.createElement("td",{key:Pt,...t0("yearsListCell"),"data-with-spacing":Xt||void 0},React.createElement(PickerControl,{...t0("yearsListControl"),size:a0,unstyled:mt,"data-mantine-stop-propagation":Wt||void 0,disabled:isYearDisabled(_t,Tt,Rt),ref:wt=>Dt==null?void 0:Dt(xt,Pt,wt),...Et,onKeyDown:wt=>{var Bt;(Bt=Et==null?void 0:Et.onKeyDown)==null||Bt.call(Et,wt),Nt==null||Nt(wt,{rowIndex:xt,cellIndex:Pt,date:_t})},onClick:wt=>{var Bt;(Bt=Et==null?void 0:Et.onClick)==null||Bt.call(Et,wt),Ot==null||Ot(wt,_t)},onMouseEnter:wt=>{var Bt;(Bt=Et==null?void 0:Et.onMouseEnter)==null||Bt.call(Et,wt),Ut==null||Ut(wt,_t)},onMouseDown:wt=>{var Bt;(Bt=Et==null?void 0:Et.onMouseDown)==null||Bt.call(Et,wt),Gt&&wt.preventDefault()},tabIndex:Gt||!ht?-1:0},dayjs(_t).locale(c0.getLocale(Mt)).format(At)))});return React.createElement("tr",{key:xt,...t0("yearsListRow")},St)});return React.createElement(Box,{component:"table",ref:a,size:a0,...t0("yearsList"),...n0},React.createElement("tbody",null,yt))});YearsList.classes=classes$6;YearsList.displayName="@mantine/dates/YearsList";function isMonthDisabled(c,a,d){return!a&&!d?!1:!!(a&&dayjs(c).isBefore(a,"month")||d&&dayjs(c).isAfter(d,"month"))}function getMonthInTabOrder(c,a,d,et){const nt=c.flat().filter(mt=>{var vt;return!isMonthDisabled(mt,a,d)&&!((vt=et==null?void 0:et(mt))!=null&&vt.disabled)}),tt=nt.find(mt=>{var vt;return(vt=et==null?void 0:et(mt))==null?void 0:vt.selected});if(tt)return tt;const bt=nt.find(mt=>dayjs().isSame(mt,"month"));return bt||nt[0]}function getMonthsData(c){const a=dayjs(c).startOf("year").toDate(),d=[[],[],[],[]];let et=0;for(let nt=0;nt<4;nt+=1)for(let tt=0;tt<3;tt+=1)d[nt].push(dayjs(a).add(et,"months").toDate()),et+=1;return d}var classes$5={monthsList:"m_2a6c32d",monthsListCell:"m_fe27622f"};const defaultProps$c={monthsListFormat:"MMM",withCellSpacing:!0},MonthsList=factory((c,a)=>{const d=useProps("MonthsList",defaultProps$c,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,__staticSelector:$t,year:At,monthsListFormat:Mt,locale:Tt,minDate:Rt,maxDate:kt,getMonthControlProps:It,__getControlRef:Dt,__onControlKeyDown:Nt,__onControlClick:Ot,__onControlMouseEnter:Ut,__preventFocus:Gt,__stopPropagation:Wt,withCellSpacing:Xt,size:a0,...n0}=d,t0=useStyles({name:$t||"MonthsList",classes:classes$5,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,rootSelector:"monthsList"}),c0=useDatesContext(),Ct=getMonthsData(At),dt=getMonthInTabOrder(Ct,Rt,kt,It),yt=Ct.map((gt,xt)=>{const St=gt.map((_t,Pt)=>{const Et=It==null?void 0:It(_t),ht=dayjs(_t).isSame(dt,"month");return React.createElement("td",{key:Pt,...t0("monthsListCell"),"data-with-spacing":Xt||void 0},React.createElement(PickerControl,{...t0("monthsListControl"),size:a0,unstyled:mt,__staticSelector:$t||"MonthsList","data-mantine-stop-propagation":Wt||void 0,disabled:isMonthDisabled(_t,Rt,kt),ref:wt=>Dt==null?void 0:Dt(xt,Pt,wt),...Et,onKeyDown:wt=>{var Bt;(Bt=Et==null?void 0:Et.onKeyDown)==null||Bt.call(Et,wt),Nt==null||Nt(wt,{rowIndex:xt,cellIndex:Pt,date:_t})},onClick:wt=>{var Bt;(Bt=Et==null?void 0:Et.onClick)==null||Bt.call(Et,wt),Ot==null||Ot(wt,_t)},onMouseEnter:wt=>{var Bt;(Bt=Et==null?void 0:Et.onMouseEnter)==null||Bt.call(Et,wt),Ut==null||Ut(wt,_t)},onMouseDown:wt=>{var Bt;(Bt=Et==null?void 0:Et.onMouseDown)==null||Bt.call(Et,wt),Gt&&wt.preventDefault()},tabIndex:Gt||!ht?-1:0},dayjs(_t).locale(c0.getLocale(Tt)).format(Mt)))});return React.createElement("tr",{key:xt,...t0("monthsListRow")},St)});return React.createElement(Box,{component:"table",ref:a,size:a0,...t0("monthsList"),...n0},React.createElement("tbody",null,yt))});MonthsList.classes=classes$5;MonthsList.displayName="@mantine/dates/MonthsList";var classes$4={calendarHeader:"m_730a79ed",calendarHeaderLevel:"m_f6645d97",calendarHeaderControl:"m_2351eeb0",calendarHeaderControlIcon:"m_367dc749"};const defaultProps$b={nextDisabled:!1,previousDisabled:!1,hasNextLevel:!0,withNext:!0,withPrevious:!0},varsResolver=(c,{size:a})=>({calendarHeader:{"--dch-control-size":getSize(a,"dch-control-size"),"--dch-fz":getFontSize(a)}}),CalendarHeader=factory((c,a)=>{const d=useProps("CalendarHeader",defaultProps$b,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,nextIcon:$t,previousIcon:At,nextLabel:Mt,previousLabel:Tt,onNext:Rt,onPrevious:kt,onLevelClick:It,label:Dt,nextDisabled:Nt,previousDisabled:Ot,hasNextLevel:Ut,levelControlAriaLabel:Gt,withNext:Wt,withPrevious:Xt,__staticSelector:a0,__preventFocus:n0,__stopPropagation:t0,...c0}=d,Ct=useStyles({name:a0||"CalendarHeader",classes:classes$4,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,varsResolver,rootSelector:"calendarHeader"}),dt=n0?yt=>yt.preventDefault():void 0;return React.createElement(Box,{...Ct("calendarHeader"),ref:a,...c0},Xt&&React.createElement(UnstyledButton,{...Ct("calendarHeaderControl"),"data-direction":"previous","aria-label":Tt,onClick:kt,unstyled:mt,onMouseDown:dt,disabled:Ot,"data-disabled":Ot||void 0,tabIndex:n0||Ot?-1:0,"data-mantine-stop-propagation":t0||void 0},At||React.createElement(AccordionChevron,{...Ct("calendarHeaderControlIcon"),"data-direction":"previous",size:"45%"})),React.createElement(UnstyledButton,{component:Ut?"button":"div",...Ct("calendarHeaderLevel"),onClick:Ut?It:void 0,unstyled:mt,onMouseDown:Ut?dt:void 0,disabled:!Ut,"data-static":!Ut||void 0,"aria-label":Gt,tabIndex:n0||!Ut?-1:0,"data-mantine-stop-propagation":t0||void 0},Dt),Wt&&React.createElement(UnstyledButton,{...Ct("calendarHeaderControl"),"data-direction":"next","aria-label":Mt,onClick:Rt,unstyled:mt,onMouseDown:dt,disabled:Nt,"data-disabled":Nt||void 0,tabIndex:n0||Nt?-1:0,"data-mantine-stop-propagation":t0||void 0},$t||React.createElement(AccordionChevron,{...Ct("calendarHeaderControlIcon"),"data-direction":"next",size:"45%"})))});CalendarHeader.classes=classes$4;CalendarHeader.displayName="@mantine/dates/CalendarHeader";function getDecadeRange(c){const a=getYearsData(c);return[a[0][0],a[3][0]]}const defaultProps$a={decadeLabelFormat:"YYYY"},DecadeLevel=factory((c,a)=>{const d=useProps("DecadeLevel",defaultProps$a,c),{decade:et,locale:nt,minDate:tt,maxDate:bt,yearsListFormat:mt,getYearControlProps:vt,__getControlRef:$t,__onControlKeyDown:At,__onControlClick:Mt,__onControlMouseEnter:Tt,withCellSpacing:Rt,__preventFocus:kt,nextIcon:It,previousIcon:Dt,nextLabel:Nt,previousLabel:Ot,onNext:Ut,onPrevious:Gt,nextDisabled:Wt,previousDisabled:Xt,levelControlAriaLabel:a0,withNext:n0,withPrevious:t0,decadeLabelFormat:c0,classNames:Ct,styles:dt,unstyled:yt,__staticSelector:gt,__stopPropagation:xt,size:St,..._t}=d,Pt=useDatesContext(),[Et,ht]=getDecadeRange(et),wt={__staticSelector:gt||"DecadeLevel",classNames:Ct,styles:dt,unstyled:yt,size:St},Bt=typeof Wt=="boolean"?Wt:bt?!dayjs(ht).endOf("year").isBefore(bt):!1,Lt=typeof Xt=="boolean"?Xt:tt?!dayjs(Et).startOf("year").isAfter(tt):!1,jt=(Ft,Vt)=>dayjs(Ft).locale(nt||Pt.locale).format(Vt);return React.createElement(Box,{"data-decade-level":!0,size:St,ref:a,..._t},React.createElement(CalendarHeader,{label:typeof c0=="function"?c0(Et,ht):`${jt(Et,c0)} – ${jt(ht,c0)}`,__preventFocus:kt,__stopPropagation:xt,nextIcon:It,previousIcon:Dt,nextLabel:Nt,previousLabel:Ot,onNext:Ut,onPrevious:Gt,nextDisabled:Bt,previousDisabled:Lt,hasNextLevel:!1,levelControlAriaLabel:a0,withNext:n0,withPrevious:t0,...wt}),React.createElement(YearsList,{decade:et,locale:nt,minDate:tt,maxDate:bt,yearsListFormat:mt,getYearControlProps:vt,__getControlRef:$t,__onControlKeyDown:At,__onControlClick:Mt,__onControlMouseEnter:Tt,__preventFocus:kt,__stopPropagation:xt,withCellSpacing:Rt,...wt}))});DecadeLevel.classes={...YearsList.classes,...CalendarHeader.classes};DecadeLevel.displayName="@mantine/dates/DecadeLevel";const defaultProps$9={yearLabelFormat:"YYYY"},YearLevel=factory((c,a)=>{const d=useProps("YearLevel",defaultProps$9,c),{year:et,locale:nt,minDate:tt,maxDate:bt,monthsListFormat:mt,getMonthControlProps:vt,__getControlRef:$t,__onControlKeyDown:At,__onControlClick:Mt,__onControlMouseEnter:Tt,withCellSpacing:Rt,__preventFocus:kt,nextIcon:It,previousIcon:Dt,nextLabel:Nt,previousLabel:Ot,onNext:Ut,onPrevious:Gt,onLevelClick:Wt,nextDisabled:Xt,previousDisabled:a0,hasNextLevel:n0,levelControlAriaLabel:t0,withNext:c0,withPrevious:Ct,yearLabelFormat:dt,__staticSelector:yt,__stopPropagation:gt,size:xt,classNames:St,styles:_t,unstyled:Pt,...Et}=d,ht=useDatesContext(),wt={__staticSelector:yt||"YearLevel",classNames:St,styles:_t,unstyled:Pt,size:xt},Bt=typeof Xt=="boolean"?Xt:bt?!dayjs(et).endOf("year").isBefore(bt):!1,Lt=typeof a0=="boolean"?a0:tt?!dayjs(et).startOf("year").isAfter(tt):!1;return React.createElement(Box,{"data-year-level":!0,size:xt,ref:a,...Et},React.createElement(CalendarHeader,{label:typeof dt=="function"?dt(et):dayjs(et).locale(nt||ht.locale).format(dt),__preventFocus:kt,__stopPropagation:gt,nextIcon:It,previousIcon:Dt,nextLabel:Nt,previousLabel:Ot,onNext:Ut,onPrevious:Gt,onLevelClick:Wt,nextDisabled:Bt,previousDisabled:Lt,hasNextLevel:n0,levelControlAriaLabel:t0,withNext:c0,withPrevious:Ct,...wt}),React.createElement(MonthsList,{year:et,locale:nt,minDate:tt,maxDate:bt,monthsListFormat:mt,getMonthControlProps:vt,__getControlRef:$t,__onControlKeyDown:At,__onControlClick:Mt,__onControlMouseEnter:Tt,__preventFocus:kt,__stopPropagation:gt,withCellSpacing:Rt,...wt}))});YearLevel.classes={...CalendarHeader.classes,...MonthsList.classes};YearLevel.displayName="@mantine/dates/YearLevel";const defaultProps$8={monthLabelFormat:"MMMM YYYY"},MonthLevel=factory((c,a)=>{const d=useProps("MonthLevel",defaultProps$8,c),{month:et,locale:nt,firstDayOfWeek:tt,weekdayFormat:bt,weekendDays:mt,getDayProps:vt,excludeDate:$t,minDate:At,maxDate:Mt,renderDay:Tt,hideOutsideDates:Rt,hideWeekdays:kt,getDayAriaLabel:It,__getDayRef:Dt,__onDayKeyDown:Nt,__onDayClick:Ot,__onDayMouseEnter:Ut,withCellSpacing:Gt,__preventFocus:Wt,__stopPropagation:Xt,nextIcon:a0,previousIcon:n0,nextLabel:t0,previousLabel:c0,onNext:Ct,onPrevious:dt,onLevelClick:yt,nextDisabled:gt,previousDisabled:xt,hasNextLevel:St,levelControlAriaLabel:_t,withNext:Pt,withPrevious:Et,monthLabelFormat:ht,classNames:wt,styles:Bt,unstyled:Lt,__staticSelector:jt,size:Ft,static:Vt,...zt}=d,qt=useDatesContext(),Kt={__staticSelector:jt||"MonthLevel",classNames:wt,styles:Bt,unstyled:Lt,size:Ft},e0=typeof gt=="boolean"?gt:Mt?!dayjs(et).endOf("month").isBefore(Mt):!1,Zt=typeof xt=="boolean"?xt:At?!dayjs(et).startOf("month").isAfter(At):!1;return React.createElement(Box,{"data-month-level":!0,size:Ft,ref:a,...zt},React.createElement(CalendarHeader,{label:typeof ht=="function"?ht(et):dayjs(et).locale(nt||qt.locale).format(ht),__preventFocus:Wt,__stopPropagation:Xt,nextIcon:a0,previousIcon:n0,nextLabel:t0,previousLabel:c0,onNext:Ct,onPrevious:dt,onLevelClick:yt,nextDisabled:e0,previousDisabled:Zt,hasNextLevel:St,levelControlAriaLabel:_t,withNext:Pt,withPrevious:Et,...Kt}),React.createElement(Month,{month:et,locale:nt,firstDayOfWeek:tt,weekdayFormat:bt,weekendDays:mt,getDayProps:vt,excludeDate:$t,minDate:At,maxDate:Mt,renderDay:Tt,hideOutsideDates:Rt,hideWeekdays:kt,getDayAriaLabel:It,__getDayRef:Dt,__onDayKeyDown:Nt,__onDayClick:Ot,__onDayMouseEnter:Ut,__preventFocus:Wt,__stopPropagation:Xt,static:Vt,withCellSpacing:Gt,...Kt}))});MonthLevel.classes={...Month.classes,...CalendarHeader.classes};MonthLevel.displayName="@mantine/dates/MonthLevel";var classes$3={levelsGroup:"m_30b26e33"};const defaultProps$7={},LevelsGroup=factory((c,a)=>{const d=useProps("LevelsGroup",defaultProps$7,c),{classNames:et,className:nt,style:tt,styles:bt,unstyled:mt,vars:vt,__staticSelector:$t,...At}=d,Mt=useStyles({name:$t||"LevelsGroup",classes:classes$3,props:d,className:nt,style:tt,classNames:et,styles:bt,unstyled:mt,vars:vt,rootSelector:"levelsGroup"});return React.createElement(Box,{ref:a,...Mt("levelsGroup"),...At})});LevelsGroup.classes=classes$3;LevelsGroup.displayName="@mantine/dates/LevelsGroup";const defaultProps$6={numberOfColumns:1},DecadeLevelGroup=factory((c,a)=>{const d=useProps("DecadeLevelGroup",defaultProps$6,c),{decade:et,locale:nt,minDate:tt,maxDate:bt,yearsListFormat:mt,getYearControlProps:vt,__onControlClick:$t,__onControlMouseEnter:At,withCellSpacing:Mt,__preventFocus:Tt,nextIcon:Rt,previousIcon:kt,nextLabel:It,previousLabel:Dt,onNext:Nt,onPrevious:Ot,nextDisabled:Ut,previousDisabled:Gt,classNames:Wt,styles:Xt,unstyled:a0,__staticSelector:n0,__stopPropagation:t0,numberOfColumns:c0,levelControlAriaLabel:Ct,decadeLabelFormat:dt,size:yt,vars:gt,...xt}=d,St=reactExports.useRef([]),_t=Array(c0).fill(0).map((Pt,Et)=>{const ht=dayjs(et).add(Et*10,"years").toDate();return React.createElement(DecadeLevel,{key:Et,size:yt,yearsListFormat:mt,decade:ht,withNext:Et===c0-1,withPrevious:Et===0,decadeLabelFormat:dt,__onControlClick:$t,__onControlMouseEnter:At,__onControlKeyDown:(wt,Bt)=>handleControlKeyDown({levelIndex:Et,rowIndex:Bt.rowIndex,cellIndex:Bt.cellIndex,event:wt,controlsRef:St}),__getControlRef:(wt,Bt,Lt)=>{Array.isArray(St.current[Et])||(St.current[Et]=[]),Array.isArray(St.current[Et][wt])||(St.current[Et][wt]=[]),St.current[Et][wt][Bt]=Lt},levelControlAriaLabel:typeof Ct=="function"?Ct(ht):Ct,locale:nt,minDate:tt,maxDate:bt,__preventFocus:Tt,__stopPropagation:t0,nextIcon:Rt,previousIcon:kt,nextLabel:It,previousLabel:Dt,onNext:Nt,onPrevious:Ot,nextDisabled:Ut,previousDisabled:Gt,getYearControlProps:vt,__staticSelector:n0||"DecadeLevelGroup",classNames:Wt,styles:Xt,unstyled:a0,withCellSpacing:Mt})});return React.createElement(LevelsGroup,{classNames:Wt,styles:Xt,__staticSelector:n0||"DecadeLevelGroup",ref:a,size:yt,unstyled:a0,...xt},_t)});DecadeLevelGroup.classes={...LevelsGroup.classes,...DecadeLevel.classes};DecadeLevelGroup.displayName="@mantine/dates/DecadeLevelGroup";const defaultProps$5={numberOfColumns:1},YearLevelGroup=factory((c,a)=>{const d=useProps("YearLevelGroup",defaultProps$5,c),{year:et,locale:nt,minDate:tt,maxDate:bt,monthsListFormat:mt,getMonthControlProps:vt,__onControlClick:$t,__onControlMouseEnter:At,withCellSpacing:Mt,__preventFocus:Tt,nextIcon:Rt,previousIcon:kt,nextLabel:It,previousLabel:Dt,onNext:Nt,onPrevious:Ot,onLevelClick:Ut,nextDisabled:Gt,previousDisabled:Wt,hasNextLevel:Xt,classNames:a0,styles:n0,unstyled:t0,__staticSelector:c0,__stopPropagation:Ct,numberOfColumns:dt,levelControlAriaLabel:yt,yearLabelFormat:gt,size:xt,vars:St,..._t}=d,Pt=reactExports.useRef([]),Et=Array(dt).fill(0).map((ht,wt)=>{const Bt=dayjs(et).add(wt,"years").toDate();return React.createElement(YearLevel,{key:wt,size:xt,monthsListFormat:mt,year:Bt,withNext:wt===dt-1,withPrevious:wt===0,yearLabelFormat:gt,__stopPropagation:Ct,__onControlClick:$t,__onControlMouseEnter:At,__onControlKeyDown:(Lt,jt)=>handleControlKeyDown({levelIndex:wt,rowIndex:jt.rowIndex,cellIndex:jt.cellIndex,event:Lt,controlsRef:Pt}),__getControlRef:(Lt,jt,Ft)=>{Array.isArray(Pt.current[wt])||(Pt.current[wt]=[]),Array.isArray(Pt.current[wt][Lt])||(Pt.current[wt][Lt]=[]),Pt.current[wt][Lt][jt]=Ft},levelControlAriaLabel:typeof yt=="function"?yt(Bt):yt,locale:nt,minDate:tt,maxDate:bt,__preventFocus:Tt,nextIcon:Rt,previousIcon:kt,nextLabel:It,previousLabel:Dt,onNext:Nt,onPrevious:Ot,onLevelClick:Ut,nextDisabled:Gt,previousDisabled:Wt,hasNextLevel:Xt,getMonthControlProps:vt,classNames:a0,styles:n0,unstyled:t0,__staticSelector:c0||"YearLevelGroup",withCellSpacing:Mt})});return React.createElement(LevelsGroup,{classNames:a0,styles:n0,__staticSelector:c0||"YearLevelGroup",ref:a,size:xt,unstyled:t0,..._t},Et)});YearLevelGroup.classes={...YearLevel.classes,...LevelsGroup.classes};YearLevelGroup.displayName="@mantine/dates/YearLevelGroup";const defaultProps$4={numberOfColumns:1},MonthLevelGroup=factory((c,a)=>{const d=useProps("MonthLevelGroup",defaultProps$4,c),{month:et,locale:nt,firstDayOfWeek:tt,weekdayFormat:bt,weekendDays:mt,getDayProps:vt,excludeDate:$t,minDate:At,maxDate:Mt,renderDay:Tt,hideOutsideDates:Rt,hideWeekdays:kt,getDayAriaLabel:It,__onDayClick:Dt,__onDayMouseEnter:Nt,withCellSpacing:Ot,__preventFocus:Ut,nextIcon:Gt,previousIcon:Wt,nextLabel:Xt,previousLabel:a0,onNext:n0,onPrevious:t0,onLevelClick:c0,nextDisabled:Ct,previousDisabled:dt,hasNextLevel:yt,classNames:gt,styles:xt,unstyled:St,numberOfColumns:_t,levelControlAriaLabel:Pt,monthLabelFormat:Et,__staticSelector:ht,__stopPropagation:wt,size:Bt,static:Lt,vars:jt,...Ft}=d,Vt=reactExports.useRef([]),zt=Array(_t).fill(0).map((qt,Kt)=>{const e0=dayjs(et).add(Kt,"months").toDate();return React.createElement(MonthLevel,{key:Kt,month:e0,withNext:Kt===_t-1,withPrevious:Kt===0,monthLabelFormat:Et,__stopPropagation:wt,__onDayClick:Dt,__onDayMouseEnter:Nt,__onDayKeyDown:(Zt,Jt)=>handleControlKeyDown({levelIndex:Kt,rowIndex:Jt.rowIndex,cellIndex:Jt.cellIndex,event:Zt,controlsRef:Vt}),__getDayRef:(Zt,Jt,i0)=>{Array.isArray(Vt.current[Kt])||(Vt.current[Kt]=[]),Array.isArray(Vt.current[Kt][Zt])||(Vt.current[Kt][Zt]=[]),Vt.current[Kt][Zt][Jt]=i0},levelControlAriaLabel:typeof Pt=="function"?Pt(e0):Pt,locale:nt,firstDayOfWeek:tt,weekdayFormat:bt,weekendDays:mt,getDayProps:vt,excludeDate:$t,minDate:At,maxDate:Mt,renderDay:Tt,hideOutsideDates:Rt,hideWeekdays:kt,getDayAriaLabel:It,__preventFocus:Ut,nextIcon:Gt,previousIcon:Wt,nextLabel:Xt,previousLabel:a0,onNext:n0,onPrevious:t0,onLevelClick:c0,nextDisabled:Ct,previousDisabled:dt,hasNextLevel:yt,classNames:gt,styles:xt,unstyled:St,__staticSelector:ht||"MonthLevelGroup",size:Bt,static:Lt,withCellSpacing:Ot})});return React.createElement(LevelsGroup,{classNames:gt,styles:xt,__staticSelector:ht||"MonthLevelGroup",ref:a,size:Bt,...Ft},zt)});MonthLevelGroup.classes={...LevelsGroup.classes,...MonthLevel.classes};MonthLevelGroup.displayName="@mantine/dates/MonthLevelGroup";var classes$2={input:"m_6fa5e2aa"};const defaultProps$3={},PickerInputBase=factory((c,a)=>{const{inputProps:d,wrapperProps:et,placeholder:nt,classNames:tt,styles:bt,unstyled:mt,popoverProps:vt,modalProps:$t,dropdownType:At,children:Mt,formattedValue:Tt,dropdownHandlers:Rt,dropdownOpened:kt,onClick:It,clearable:Dt,onClear:Nt,clearButtonProps:Ot,rightSection:Ut,shouldClear:Gt,readOnly:Wt,disabled:Xt,value:a0,name:n0,form:t0,type:c0,...Ct}=useInputProps("PickerInputBase",defaultProps$3,c),dt=Ut||(Dt&&Gt&&!Wt&&!Xt?React.createElement(CloseButton,{variant:"transparent",onClick:Nt,unstyled:mt,size:d.size||"sm",...Ot}):null),yt=()=>{c0==="range"&&Array.isArray(a0)&&a0[0]&&!a0[1]&&Nt(),Rt.close()};return React.createElement(React.Fragment,null,At==="modal"&&!Wt&&React.createElement(Modal,{opened:kt,onClose:yt,withCloseButton:!1,size:"auto","data-dates-modal":!0,unstyled:mt,...$t},Mt),React.createElement(Input.Wrapper,{...et},React.createElement(Popover,{position:"bottom-start",opened:kt,trapFocus:!0,returnFocus:!0,unstyled:mt,...vt,disabled:(vt==null?void 0:vt.disabled)||At==="modal"||Wt,onClose:()=>{var gt;(gt=vt==null?void 0:vt.onClose)==null||gt.call(vt),yt()}},React.createElement(Popover.Target,null,React.createElement(Input,{"aria-label":Tt||nt,"data-dates-input":!0,"data-read-only":Wt||void 0,disabled:Xt,component:"button",type:"button",multiline:!0,onClick:gt=>{It==null||It(gt),Rt.toggle()},rightSection:dt,...d,ref:a,classNames:{...tt,input:clsx(classes$2.input,tt==null?void 0:tt.input)},...Ct},Tt||React.createElement(Input.Placeholder,{error:d.error,unstyled:mt,className:tt==null?void 0:tt.placeholder,style:bt==null?void 0:bt.placeholder},nt))),React.createElement(Popover.Dropdown,{"data-dates-dropdown":!0},Mt))),React.createElement(HiddenDatesInput,{value:a0,name:n0,form:t0,type:c0}))});PickerInputBase.classes=classes$2;PickerInputBase.displayName="@mantine/dates/PickerInputBase";const getEmptyValue=c=>c==="range"?[null,null]:c==="multiple"?[]:null;function useUncontrolledDates({type:c,value:a,defaultValue:d,onChange:et,applyTimezone:nt=!0}){const tt=reactExports.useRef(c),bt=useDatesContext(),[mt,vt,$t]=useUncontrolled({value:shiftTimezone("add",a,bt.getTimezone(),!nt),defaultValue:shiftTimezone("add",d,bt.getTimezone(),!nt),finalValue:getEmptyValue(c),onChange:Mt=>{et==null||et(shiftTimezone("remove",Mt,bt.getTimezone(),!nt))}});let At=mt;return tt.current!==c&&(tt.current=c,a===void 0&&(At=d!==void 0?d:getEmptyValue(c),vt(At))),[At,vt,$t]}function levelToNumber(c,a){return c?c==="month"?0:c==="year"?1:2:a||0}function levelNumberToLevel(c){return c===0?"month":c===1?"year":"decade"}function clampLevel(c,a,d){return levelNumberToLevel(clamp$1(levelToNumber(c,0),levelToNumber(a,0),levelToNumber(d,2)))}const defaultProps$2={maxLevel:"decade",minLevel:"month",__updateDateOnYearSelect:!0,__updateDateOnMonthSelect:!0},Calendar=factory((c,a)=>{const d=useProps("Calendar",defaultProps$2,c),{vars:et,maxLevel:nt,minLevel:tt,defaultLevel:bt,level:mt,onLevelChange:vt,date:$t,defaultDate:At,onDateChange:Mt,numberOfColumns:Tt,columnsToScroll:Rt,ariaLabels:kt,onYearSelect:It,onMonthSelect:Dt,onYearMouseEnter:Nt,onMonthMouseEnter:Ot,__updateDateOnYearSelect:Ut,__updateDateOnMonthSelect:Gt,firstDayOfWeek:Wt,weekdayFormat:Xt,weekendDays:a0,getDayProps:n0,excludeDate:t0,renderDay:c0,hideOutsideDates:Ct,hideWeekdays:dt,getDayAriaLabel:yt,monthLabelFormat:gt,nextIcon:xt,previousIcon:St,__onDayClick:_t,__onDayMouseEnter:Pt,withCellSpacing:Et,monthsListFormat:ht,getMonthControlProps:wt,yearLabelFormat:Bt,yearsListFormat:Lt,getYearControlProps:jt,decadeLabelFormat:Ft,classNames:Vt,styles:zt,unstyled:qt,minDate:Kt,maxDate:e0,locale:Zt,__staticSelector:Jt,size:i0,__preventFocus:h0,__stopPropagation:o0,onNextDecade:l0,onPreviousDecade:$0,onNextYear:p0,onPreviousYear:u0,onNextMonth:J0,onPreviousMonth:v0,static:E0,__timezoneApplied:Z0,...w0}=d,{resolvedClassNames:b0,resolvedStyles:K0}=useResolvedStylesApi({classNames:Vt,styles:zt,props:d}),[Qt,Ht]=useUncontrolled({value:mt?clampLevel(mt,tt,nt):void 0,defaultValue:bt?clampLevel(bt,tt,nt):void 0,finalValue:clampLevel(void 0,tt,nt),onChange:vt}),[Yt,r0]=useUncontrolledDates({type:"default",value:$t,defaultValue:At,onChange:Mt,applyTimezone:!Z0}),f0={__staticSelector:Jt||"Calendar",styles:K0,classNames:b0,unstyled:qt,size:i0},x0=useDatesContext(),d0=Rt||Tt||1,y0=Yt||shiftTimezone("add",new Date,x0.getTimezone()),Q0=()=>{const X0=dayjs(y0).add(d0,"month").toDate();J0==null||J0(X0),r0(X0)},g0=()=>{const X0=dayjs(y0).subtract(d0,"month").toDate();v0==null||v0(X0),r0(X0)},A0=()=>{const X0=dayjs(y0).add(d0,"year").toDate();p0==null||p0(X0),r0(X0)},Y0=()=>{const X0=dayjs(y0).subtract(d0,"year").toDate();u0==null||u0(X0),r0(X0)},_0=()=>{const X0=dayjs(y0).add(10*d0,"year").toDate();l0==null||l0(X0),r0(X0)},N0=()=>{const X0=dayjs(y0).subtract(10*d0,"year").toDate();$0==null||$0(X0),r0(X0)};return React.createElement(Box,{ref:a,size:i0,"data-calendar":!0,...w0},Qt==="month"&&React.createElement(MonthLevelGroup,{month:y0,minDate:Kt,maxDate:e0,firstDayOfWeek:Wt,weekdayFormat:Xt,weekendDays:a0,getDayProps:n0,excludeDate:t0,renderDay:c0,hideOutsideDates:Ct,hideWeekdays:dt,getDayAriaLabel:yt,onNext:Q0,onPrevious:g0,hasNextLevel:nt!=="month",onLevelClick:()=>Ht("year"),numberOfColumns:Tt,locale:Zt,levelControlAriaLabel:kt==null?void 0:kt.monthLevelControl,nextLabel:kt==null?void 0:kt.nextMonth,nextIcon:xt,previousLabel:kt==null?void 0:kt.previousMonth,previousIcon:St,monthLabelFormat:gt,__onDayClick:_t,__onDayMouseEnter:Pt,__preventFocus:h0,__stopPropagation:o0,static:E0,withCellSpacing:Et,...f0}),Qt==="year"&&React.createElement(YearLevelGroup,{year:y0,numberOfColumns:Tt,minDate:Kt,maxDate:e0,monthsListFormat:ht,getMonthControlProps:wt,locale:Zt,onNext:A0,onPrevious:Y0,hasNextLevel:nt!=="month"&&nt!=="year",onLevelClick:()=>Ht("decade"),levelControlAriaLabel:kt==null?void 0:kt.yearLevelControl,nextLabel:kt==null?void 0:kt.nextYear,nextIcon:xt,previousLabel:kt==null?void 0:kt.previousYear,previousIcon:St,yearLabelFormat:Bt,__onControlMouseEnter:Ot,__onControlClick:(X0,M0)=>{Gt&&r0(M0),Ht(clampLevel("month",tt,nt)),Dt==null||Dt(M0)},__preventFocus:h0,__stopPropagation:o0,withCellSpacing:Et,...f0}),Qt==="decade"&&React.createElement(DecadeLevelGroup,{decade:y0,minDate:Kt,maxDate:e0,yearsListFormat:Lt,getYearControlProps:jt,locale:Zt,onNext:_0,onPrevious:N0,numberOfColumns:Tt,nextLabel:kt==null?void 0:kt.nextDecade,nextIcon:xt,previousLabel:kt==null?void 0:kt.previousDecade,previousIcon:St,decadeLabelFormat:Ft,__onControlMouseEnter:Nt,__onControlClick:(X0,M0)=>{Ut&&r0(M0),Ht(clampLevel("year",tt,nt)),It==null||It(M0)},__preventFocus:h0,__stopPropagation:o0,withCellSpacing:Et,...f0}))});Calendar.classes={...DecadeLevelGroup.classes,...YearLevelGroup.classes,...MonthLevelGroup.classes};Calendar.displayName="@mantine/dates/Calendar";function pickCalendarProps(c){const{maxLevel:a,minLevel:d,defaultLevel:et,level:nt,onLevelChange:tt,nextIcon:bt,previousIcon:mt,date:vt,defaultDate:$t,onDateChange:At,numberOfColumns:Mt,columnsToScroll:Tt,ariaLabels:Rt,onYearSelect:kt,onMonthSelect:It,onYearMouseEnter:Dt,onMonthMouseEnter:Nt,onNextMonth:Ot,onPreviousMonth:Ut,onNextYear:Gt,onPreviousYear:Wt,onNextDecade:Xt,onPreviousDecade:a0,withCellSpacing:n0,__updateDateOnYearSelect:t0,__updateDateOnMonthSelect:c0,firstDayOfWeek:Ct,weekdayFormat:dt,weekendDays:yt,getDayProps:gt,excludeDate:xt,renderDay:St,hideOutsideDates:_t,hideWeekdays:Pt,getDayAriaLabel:Et,monthLabelFormat:ht,monthsListFormat:wt,getMonthControlProps:Bt,yearLabelFormat:Lt,yearsListFormat:jt,getYearControlProps:Ft,decadeLabelFormat:Vt,allowSingleDateInRange:zt,allowDeselect:qt,minDate:Kt,maxDate:e0,locale:Zt,...Jt}=c;return{calendarProps:{maxLevel:a,minLevel:d,defaultLevel:et,level:nt,onLevelChange:tt,nextIcon:bt,previousIcon:mt,date:vt,defaultDate:$t,onDateChange:At,numberOfColumns:Mt,columnsToScroll:Tt,ariaLabels:Rt,onYearSelect:kt,onMonthSelect:It,onYearMouseEnter:Dt,onMonthMouseEnter:Nt,onNextMonth:Ot,onPreviousMonth:Ut,onNextYear:Gt,onPreviousYear:Wt,onNextDecade:Xt,onPreviousDecade:a0,withCellSpacing:n0,__updateDateOnYearSelect:t0,__updateDateOnMonthSelect:c0,firstDayOfWeek:Ct,weekdayFormat:dt,weekendDays:yt,getDayProps:gt,excludeDate:xt,renderDay:St,hideOutsideDates:_t,hideWeekdays:Pt,getDayAriaLabel:Et,monthLabelFormat:ht,monthsListFormat:wt,getMonthControlProps:Bt,yearLabelFormat:Lt,yearsListFormat:jt,getYearControlProps:Ft,decadeLabelFormat:Vt,allowSingleDateInRange:zt,allowDeselect:qt,minDate:Kt,maxDate:e0,locale:Zt},others:Jt}}function isInRange(c,a){const d=[...a].sort((et,nt)=>et.getTime()-nt.getTime());return dayjs(d[0]).startOf("day").subtract(1,"ms").isBefore(c)&&dayjs(d[1]).endOf("day").add(1,"ms").isAfter(c)}function useDatesState({type:c,level:a,value:d,defaultValue:et,onChange:nt,allowSingleDateInRange:tt,allowDeselect:bt,onMouseLeave:mt,applyTimezone:vt=!0}){const[$t,At]=useUncontrolledDates({type:c,value:d,defaultValue:et,onChange:nt,applyTimezone:vt}),[Mt,Tt]=reactExports.useState(c==="range"&&$t[0]&&!$t[1]?$t[0]:null),[Rt,kt]=reactExports.useState(null),It=Xt=>{if(c==="range"){if(Mt instanceof Date&&!$t[1]){if(dayjs(Xt).isSame(Mt,a)&&!tt){Tt(null),kt(null),At([null,null]);return}const a0=[Xt,Mt];a0.sort((n0,t0)=>n0.getTime()-t0.getTime()),At(a0),kt(null),Tt(null);return}if($t[0]&&!$t[1]&&dayjs(Xt).isSame($t[0],a)&&!tt){Tt(null),kt(null),At([null,null]);return}At([Xt,null]),kt(null),Tt(Xt);return}if(c==="multiple"){$t.some(a0=>dayjs(a0).isSame(Xt,a))?At($t.filter(a0=>!dayjs(a0).isSame(Xt,a))):At([...$t,Xt]);return}$t&&bt&&dayjs(Xt).isSame($t,a)?At(null):At(Xt)},Dt=Xt=>Mt instanceof Date&&Rt instanceof Date?isInRange(Xt,[Rt,Mt]):$t[0]instanceof Date&&$t[1]instanceof Date?isInRange(Xt,$t):!1,Nt=c==="range"?Xt=>{mt==null||mt(Xt),kt(null)}:mt,Ot=Xt=>$t[0]instanceof Date&&dayjs(Xt).isSame($t[0],a)?!(Rt&&dayjs(Rt).isBefore($t[0])):!1,Ut=Xt=>$t[1]instanceof Date?dayjs(Xt).isSame($t[1],a):!($t[0]instanceof Date)||!Rt?!1:dayjs(Rt).isBefore($t[0])&&dayjs(Xt).isSame($t[0],a),Gt=Xt=>{if(c==="range")return{selected:$t.some(n0=>n0&&dayjs(n0).isSame(Xt,a)),inRange:Dt(Xt),firstInRange:Ot(Xt),lastInRange:Ut(Xt),"data-autofocus":!!$t[0]&&dayjs($t[0]).isSame(Xt,a)||void 0};if(c==="multiple")return{selected:$t.some(n0=>n0&&dayjs(n0).isSame(Xt,a)),"data-autofocus":!!$t[0]&&dayjs($t[0]).isSame(Xt,a)||void 0};const a0=dayjs($t).isSame(Xt,a);return{selected:a0,"data-autofocus":a0||void 0}},Wt=c==="range"&&Mt?kt:()=>{};return reactExports.useEffect(()=>{c==="range"&&!$t[0]&&!$t[1]&&Tt(null)},[d]),{onDateChange:It,onRootMouseLeave:Nt,onHoveredDateChange:Wt,getControlProps:Gt,_value:$t,setValue:At}}const defaultProps$1={type:"default",defaultLevel:"month",numberOfColumns:1},DatePicker=factory((c,a)=>{const d=useProps("DatePicker",defaultProps$1,c),{classNames:et,styles:nt,vars:tt,type:bt,defaultValue:mt,value:vt,onChange:$t,__staticSelector:At,getDayProps:Mt,allowSingleDateInRange:Tt,allowDeselect:Rt,onMouseLeave:kt,numberOfColumns:It,hideOutsideDates:Dt,__onDayMouseEnter:Nt,__onDayClick:Ot,__timezoneApplied:Ut,...Gt}=d,{onDateChange:Wt,onRootMouseLeave:Xt,onHoveredDateChange:a0,getControlProps:n0}=useDatesState({type:bt,level:"day",allowDeselect:Rt,allowSingleDateInRange:Tt,value:vt,defaultValue:mt,onChange:$t,onMouseLeave:kt,applyTimezone:!Ut}),{resolvedClassNames:t0,resolvedStyles:c0}=useResolvedStylesApi({classNames:et,styles:nt,props:d}),Ct=useDatesContext();return React.createElement(Calendar,{ref:a,minLevel:"month",classNames:t0,styles:c0,__staticSelector:At||"DatePicker",onMouseLeave:Xt,numberOfColumns:It,hideOutsideDates:Dt??It!==1,__onDayMouseEnter:(dt,yt)=>{a0(yt),Nt==null||Nt(dt,yt)},__onDayClick:(dt,yt)=>{Wt(yt),Ot==null||Ot(dt,yt)},getDayProps:dt=>({...n0(dt),...Mt==null?void 0:Mt(dt)}),...Gt,date:shiftTimezone("add",Gt.date,Ct.getTimezone(),Ut),__timezoneApplied:!0})});DatePicker.classes=Calendar.classes;DatePicker.displayName="@mantine/dates/DatePicker";var classes$1={timeWrapper:"m_208d2562",timeInput:"m_62ee059"};const defaultProps={dropdownType:"popover"},DateTimePicker=factory((c,a)=>{const d=useProps("DateTimePicker",defaultProps,c),{value:et,defaultValue:nt,onChange:tt,valueFormat:bt,locale:mt,classNames:vt,styles:$t,unstyled:At,timeInputProps:Mt,submitButtonProps:Tt,withSeconds:Rt,level:kt,defaultLevel:It,size:Dt,variant:Nt,dropdownType:Ot,vars:Ut,minDate:Gt,maxDate:Wt,...Xt}=d,a0=useStyles({name:"DateTimePicker",classes:classes$1,props:d,classNames:vt,styles:$t,unstyled:At,vars:Ut}),{resolvedClassNames:n0,resolvedStyles:t0}=useResolvedStylesApi({classNames:vt,styles:$t,props:d}),c0=bt||(Rt?"DD/MM/YYYY HH:mm:ss":"DD/MM/YYYY HH:mm"),Ct=reactExports.useRef(),dt=useMergedRef(Ct,Mt==null?void 0:Mt.ref),{calendarProps:{allowSingleDateInRange:yt,...gt},others:xt}=pickCalendarProps(Xt),St=useDatesContext(),[_t,Pt]=useUncontrolledDates({type:"default",value:et,defaultValue:nt,onChange:tt}),Et=i0=>i0?dayjs(i0).format(Rt?"HH:mm:ss":"HH:mm"):"",[ht,wt]=reactExports.useState(Et(_t)),[Bt,Lt]=reactExports.useState(kt||It||"month"),[jt,Ft]=useDisclosure(!1),Vt=_t?dayjs(_t).locale(St.getLocale(mt)).format(c0):"",zt=i0=>{var o0;(o0=Mt==null?void 0:Mt.onChange)==null||o0.call(Mt,i0);const h0=i0.currentTarget.value;if(wt(h0),h0){const[l0,$0,p0]=h0.split(":").map(Number),u0=shiftTimezone("add",new Date,St.getTimezone());u0.setHours(l0),u0.setMinutes($0),u0.setSeconds(p0||0),Pt(assignTime(u0,_t||shiftTimezone("add",new Date,St.getTimezone())))}},qt=i0=>{var h0;i0&&Pt(assignTime(_t,i0)),(h0=Ct.current)==null||h0.focus()},Kt=i0=>{var h0;(h0=Mt==null?void 0:Mt.onKeyDown)==null||h0.call(Mt,i0),i0.key==="Enter"&&(i0.preventDefault(),Ft.close())};useDidUpdate(()=>{jt||wt(Et(_t))},[_t,jt]),useDidUpdate(()=>{jt&&Lt("month")},[jt]);const e0=Gt?dayjs(Gt).format("HH:mm:ss"):null,Zt=Wt?dayjs(Wt).format("HH:mm:ss"):null,Jt=Ot==="popover";return React.createElement(PickerInputBase,{formattedValue:Vt,dropdownOpened:jt,dropdownHandlers:Ft,classNames:n0,styles:t0,unstyled:At,ref:a,onClear:()=>Pt(null),shouldClear:!!_t,value:_t,size:Dt,variant:Nt,dropdownType:Ot,...xt,type:"default",__staticSelector:"DateTimePicker"},React.createElement(DatePicker,{...gt,maxDate:Wt,minDate:Gt,size:Dt,variant:Nt,type:"default",value:_t,defaultDate:_t,onChange:qt,locale:mt,classNames:n0,styles:t0,unstyled:At,__staticSelector:"DateTimePicker",__stopPropagation:Jt,level:kt,defaultLevel:It,onLevelChange:i0=>{var h0;Lt(i0),(h0=gt.onLevelChange)==null||h0.call(gt,i0)},__timezoneApplied:!0}),Bt==="month"&&React.createElement("div",{...a0("timeWrapper")},React.createElement(TimeInput,{value:ht,withSeconds:Rt,ref:dt,unstyled:At,...Mt,...a0("timeInput",{className:Mt==null?void 0:Mt.className,style:Mt==null?void 0:Mt.style}),onChange:zt,onKeyDown:Kt,minTime:_t&&Gt&&_t.toDateString()===Gt.toDateString()?e0??void 0:void 0,maxTime:_t&&Wt&&_t.toDateString()===Wt.toDateString()?Zt??void 0:void 0,size:Dt,"data-mantine-stop-propagation":Jt||void 0}),React.createElement(ActionIcon,{variant:"default",size:`input-${Dt||"sm"}`,...a0("submitButton",{className:Tt==null?void 0:Tt.className,style:Tt==null?void 0:Tt.style}),unstyled:At,"data-mantine-stop-propagation":Jt||void 0,children:React.createElement(CheckIcon,{size:"30%"}),...Tt,onClick:i0=>{var h0;(h0=Tt==null?void 0:Tt.onClick)==null||h0.call(Tt,i0),Ft.close()}})))});DateTimePicker.classes={...classes$1,...PickerInputBase.classes,...DatePicker.classes};DateTimePicker.displayName="@mantine/dates/DateTimePicker";const version$i="logger/5.7.0";let _permanentCensorErrors=!1,_censorErrors=!1;const LogLevels={debug:1,default:2,info:2,warning:3,error:4,off:5};let _logLevel=LogLevels.default,_globalLogger=null;function _checkNormalize(){try{const c=[];if(["NFD","NFC","NFKD","NFKC"].forEach(a=>{try{if("test".normalize(a)!=="test")throw new Error("bad normalize")}catch{c.push(a)}}),c.length)throw new Error("missing "+c.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(c){return c.message}return null}const _normalizeError=_checkNormalize();var LogLevel;(function(c){c.DEBUG="DEBUG",c.INFO="INFO",c.WARNING="WARNING",c.ERROR="ERROR",c.OFF="OFF"})(LogLevel||(LogLevel={}));var ErrorCode;(function(c){c.UNKNOWN_ERROR="UNKNOWN_ERROR",c.NOT_IMPLEMENTED="NOT_IMPLEMENTED",c.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",c.NETWORK_ERROR="NETWORK_ERROR",c.SERVER_ERROR="SERVER_ERROR",c.TIMEOUT="TIMEOUT",c.BUFFER_OVERRUN="BUFFER_OVERRUN",c.NUMERIC_FAULT="NUMERIC_FAULT",c.MISSING_NEW="MISSING_NEW",c.INVALID_ARGUMENT="INVALID_ARGUMENT",c.MISSING_ARGUMENT="MISSING_ARGUMENT",c.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",c.CALL_EXCEPTION="CALL_EXCEPTION",c.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",c.NONCE_EXPIRED="NONCE_EXPIRED",c.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",c.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",c.TRANSACTION_REPLACED="TRANSACTION_REPLACED",c.ACTION_REJECTED="ACTION_REJECTED"})(ErrorCode||(ErrorCode={}));const HEX="0123456789abcdef";class Logger{constructor(a){Object.defineProperty(this,"version",{enumerable:!0,value:a,writable:!1})}_log(a,d){const et=a.toLowerCase();LogLevels[et]==null&&this.throwArgumentError("invalid log level name","logLevel",a),!(_logLevel>LogLevels[et])&&console.log.apply(console,d)}debug(...a){this._log(Logger.levels.DEBUG,a)}info(...a){this._log(Logger.levels.INFO,a)}warn(...a){this._log(Logger.levels.WARNING,a)}makeError(a,d,et){if(_censorErrors)return this.makeError("censored error",d,{});d||(d=Logger.errors.UNKNOWN_ERROR),et||(et={});const nt=[];Object.keys(et).forEach(vt=>{const $t=et[vt];try{if($t instanceof Uint8Array){let At="";for(let Mt=0;Mt<$t.length;Mt++)At+=HEX[$t[Mt]>>4],At+=HEX[$t[Mt]&15];nt.push(vt+"=Uint8Array(0x"+At+")")}else nt.push(vt+"="+JSON.stringify($t))}catch{nt.push(vt+"="+JSON.stringify(et[vt].toString()))}}),nt.push(`code=${d}`),nt.push(`version=${this.version}`);const tt=a;let bt="";switch(d){case ErrorCode.NUMERIC_FAULT:{bt="NUMERIC_FAULT";const vt=a;switch(vt){case"overflow":case"underflow":case"division-by-zero":bt+="-"+vt;break;case"negative-power":case"negative-width":bt+="-unsupported";break;case"unbound-bitwise-result":bt+="-unbound-result";break}break}case ErrorCode.CALL_EXCEPTION:case ErrorCode.INSUFFICIENT_FUNDS:case ErrorCode.MISSING_NEW:case ErrorCode.NONCE_EXPIRED:case ErrorCode.REPLACEMENT_UNDERPRICED:case ErrorCode.TRANSACTION_REPLACED:case ErrorCode.UNPREDICTABLE_GAS_LIMIT:bt=d;break}bt&&(a+=" [ See: https://links.ethers.org/v5-errors-"+bt+" ]"),nt.length&&(a+=" ("+nt.join(", ")+")");const mt=new Error(a);return mt.reason=tt,mt.code=d,Object.keys(et).forEach(function(vt){mt[vt]=et[vt]}),mt}throwError(a,d,et){throw this.makeError(a,d,et)}throwArgumentError(a,d,et){return this.throwError(a,Logger.errors.INVALID_ARGUMENT,{argument:d,value:et})}assert(a,d,et,nt){a||this.throwError(d,et,nt)}assertArgument(a,d,et,nt){a||this.throwArgumentError(d,et,nt)}checkNormalize(a){_normalizeError&&this.throwError("platform missing String.prototype.normalize",Logger.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:_normalizeError})}checkSafeUint53(a,d){typeof a=="number"&&(d==null&&(d="value not safe"),(a<0||a>=9007199254740991)&&this.throwError(d,Logger.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:a}),a%1&&this.throwError(d,Logger.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:a}))}checkArgumentCount(a,d,et){et?et=": "+et:et="",ad&&this.throwError("too many arguments"+et,Logger.errors.UNEXPECTED_ARGUMENT,{count:a,expectedCount:d})}checkNew(a,d){(a===Object||a==null)&&this.throwError("missing new",Logger.errors.MISSING_NEW,{name:d.name})}checkAbstract(a,d){a===d?this.throwError("cannot instantiate abstract class "+JSON.stringify(d.name)+" directly; use a sub-class",Logger.errors.UNSUPPORTED_OPERATION,{name:a.name,operation:"new"}):(a===Object||a==null)&&this.throwError("missing new",Logger.errors.MISSING_NEW,{name:d.name})}static globalLogger(){return _globalLogger||(_globalLogger=new Logger(version$i)),_globalLogger}static setCensorship(a,d){if(!a&&d&&this.globalLogger().throwError("cannot permanently disable censorship",Logger.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),_permanentCensorErrors){if(!a)return;this.globalLogger().throwError("error censorship permanent",Logger.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}_censorErrors=!!a,_permanentCensorErrors=!!d}static setLogLevel(a){const d=LogLevels[a.toLowerCase()];if(d==null){Logger.globalLogger().warn("invalid log level - "+a);return}_logLevel=d}static from(a){return new Logger(a)}}Logger.errors=ErrorCode;Logger.levels=LogLevel;const version$h="bytes/5.7.0",logger$h=new Logger(version$h);function isHexable(c){return!!c.toHexString}function addSlice(c){return c.slice||(c.slice=function(){const a=Array.prototype.slice.call(arguments);return addSlice(new Uint8Array(Array.prototype.slice.apply(c,a)))}),c}function isBytesLike(c){return isHexString(c)&&!(c.length%2)||isBytes(c)}function isInteger(c){return typeof c=="number"&&c==c&&c%1===0}function isBytes(c){if(c==null)return!1;if(c.constructor===Uint8Array)return!0;if(typeof c=="string"||!isInteger(c.length)||c.length<0)return!1;for(let a=0;a=256)return!1}return!0}function arrayify(c,a){if(a||(a={}),typeof c=="number"){logger$h.checkSafeUint53(c,"invalid arrayify value");const d=[];for(;c;)d.unshift(c&255),c=parseInt(String(c/256));return d.length===0&&d.push(0),addSlice(new Uint8Array(d))}if(a.allowMissingPrefix&&typeof c=="string"&&c.substring(0,2)!=="0x"&&(c="0x"+c),isHexable(c)&&(c=c.toHexString()),isHexString(c)){let d=c.substring(2);d.length%2&&(a.hexPad==="left"?d="0"+d:a.hexPad==="right"?d+="0":logger$h.throwArgumentError("hex data is odd-length","value",c));const et=[];for(let nt=0;ntarrayify(nt)),d=a.reduce((nt,tt)=>nt+tt.length,0),et=new Uint8Array(d);return a.reduce((nt,tt)=>(et.set(tt,nt),nt+tt.length),0),addSlice(et)}function stripZeros(c){let a=arrayify(c);if(a.length===0)return a;let d=0;for(;da&&logger$h.throwArgumentError("value out of range","value",arguments[0]);const d=new Uint8Array(a);return d.set(c,a-c.length),addSlice(d)}function isHexString(c,a){return!(typeof c!="string"||!c.match(/^0x[0-9A-Fa-f]*$/)||a&&c.length!==2+2*a)}const HexCharacters="0123456789abcdef";function hexlify(c,a){if(a||(a={}),typeof c=="number"){logger$h.checkSafeUint53(c,"invalid hexlify value");let d="";for(;c;)d=HexCharacters[c&15]+d,c=Math.floor(c/16);return d.length?(d.length%2&&(d="0"+d),"0x"+d):"0x00"}if(typeof c=="bigint")return c=c.toString(16),c.length%2?"0x0"+c:"0x"+c;if(a.allowMissingPrefix&&typeof c=="string"&&c.substring(0,2)!=="0x"&&(c="0x"+c),isHexable(c))return c.toHexString();if(isHexString(c))return c.length%2&&(a.hexPad==="left"?c="0x0"+c.substring(2):a.hexPad==="right"?c+="0":logger$h.throwArgumentError("hex data is odd-length","value",c)),c.toLowerCase();if(isBytes(c)){let d="0x";for(let et=0;et>4]+HexCharacters[nt&15]}return d}return logger$h.throwArgumentError("invalid hexlify value","value",c)}function hexDataLength(c){if(typeof c!="string")c=hexlify(c);else if(!isHexString(c)||c.length%2)return null;return(c.length-2)/2}function hexDataSlice(c,a,d){return typeof c!="string"?c=hexlify(c):(!isHexString(c)||c.length%2)&&logger$h.throwArgumentError("invalid hexData","value",c),a=2+2*a,d!=null?"0x"+c.substring(a,2+2*d):"0x"+c.substring(a)}function hexConcat(c){let a="0x";return c.forEach(d=>{a+=hexlify(d).substring(2)}),a}function hexZeroPad(c,a){for(typeof c!="string"?c=hexlify(c):isHexString(c)||logger$h.throwArgumentError("invalid hex string","value",c),c.length>2*a+2&&logger$h.throwArgumentError("value out of range","value",arguments[1]);c.length<2*a+2;)c="0x0"+c.substring(2);return c}function splitSignature(c){const a={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(isBytesLike(c)){let d=arrayify(c);d.length===64?(a.v=27+(d[32]>>7),d[32]&=127,a.r=hexlify(d.slice(0,32)),a.s=hexlify(d.slice(32,64))):d.length===65?(a.r=hexlify(d.slice(0,32)),a.s=hexlify(d.slice(32,64)),a.v=d[64]):logger$h.throwArgumentError("invalid signature string","signature",c),a.v<27&&(a.v===0||a.v===1?a.v+=27:logger$h.throwArgumentError("signature invalid v byte","signature",c)),a.recoveryParam=1-a.v%2,a.recoveryParam&&(d[32]|=128),a._vs=hexlify(d.slice(32,64))}else{if(a.r=c.r,a.s=c.s,a.v=c.v,a.recoveryParam=c.recoveryParam,a._vs=c._vs,a._vs!=null){const nt=zeroPad(arrayify(a._vs),32);a._vs=hexlify(nt);const tt=nt[0]>=128?1:0;a.recoveryParam==null?a.recoveryParam=tt:a.recoveryParam!==tt&&logger$h.throwArgumentError("signature recoveryParam mismatch _vs","signature",c),nt[0]&=127;const bt=hexlify(nt);a.s==null?a.s=bt:a.s!==bt&&logger$h.throwArgumentError("signature v mismatch _vs","signature",c)}if(a.recoveryParam==null)a.v==null?logger$h.throwArgumentError("signature missing v and recoveryParam","signature",c):a.v===0||a.v===1?a.recoveryParam=a.v:a.recoveryParam=1-a.v%2;else if(a.v==null)a.v=27+a.recoveryParam;else{const nt=a.v===0||a.v===1?a.v:1-a.v%2;a.recoveryParam!==nt&&logger$h.throwArgumentError("signature recoveryParam mismatch v","signature",c)}a.r==null||!isHexString(a.r)?logger$h.throwArgumentError("signature missing or invalid r","signature",c):a.r=hexZeroPad(a.r,32),a.s==null||!isHexString(a.s)?logger$h.throwArgumentError("signature missing or invalid s","signature",c):a.s=hexZeroPad(a.s,32);const d=arrayify(a.s);d[0]>=128&&logger$h.throwArgumentError("signature s out of range","signature",c),a.recoveryParam&&(d[0]|=128);const et=hexlify(d);a._vs&&(isHexString(a._vs)||logger$h.throwArgumentError("signature invalid _vs","signature",c),a._vs=hexZeroPad(a._vs,32)),a._vs==null?a._vs=et:a._vs!==et&&logger$h.throwArgumentError("signature _vs mismatch v and s","signature",c)}return a.yParityAndS=a._vs,a.compact=a.r+a.yParityAndS.substring(2),a}function joinSignature(c){return c=splitSignature(c),hexlify(concat$1([c.r,c.s,c.recoveryParam?"0x1c":"0x1b"]))}const version$g="bignumber/5.7.0";var BN=BN$j.BN;const logger$g=new Logger(version$g),_constructorGuard$1={},MAX_SAFE=9007199254740991;let _warnedToStringRadix=!1;class BigNumber{constructor(a,d){a!==_constructorGuard$1&&logger$g.throwError("cannot call constructor directly; use BigNumber.from",Logger.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=d,this._isBigNumber=!0,Object.freeze(this)}fromTwos(a){return toBigNumber(toBN(this).fromTwos(a))}toTwos(a){return toBigNumber(toBN(this).toTwos(a))}abs(){return this._hex[0]==="-"?BigNumber.from(this._hex.substring(1)):this}add(a){return toBigNumber(toBN(this).add(toBN(a)))}sub(a){return toBigNumber(toBN(this).sub(toBN(a)))}div(a){return BigNumber.from(a).isZero()&&throwFault("division-by-zero","div"),toBigNumber(toBN(this).div(toBN(a)))}mul(a){return toBigNumber(toBN(this).mul(toBN(a)))}mod(a){const d=toBN(a);return d.isNeg()&&throwFault("division-by-zero","mod"),toBigNumber(toBN(this).umod(d))}pow(a){const d=toBN(a);return d.isNeg()&&throwFault("negative-power","pow"),toBigNumber(toBN(this).pow(d))}and(a){const d=toBN(a);return(this.isNegative()||d.isNeg())&&throwFault("unbound-bitwise-result","and"),toBigNumber(toBN(this).and(d))}or(a){const d=toBN(a);return(this.isNegative()||d.isNeg())&&throwFault("unbound-bitwise-result","or"),toBigNumber(toBN(this).or(d))}xor(a){const d=toBN(a);return(this.isNegative()||d.isNeg())&&throwFault("unbound-bitwise-result","xor"),toBigNumber(toBN(this).xor(d))}mask(a){return(this.isNegative()||a<0)&&throwFault("negative-width","mask"),toBigNumber(toBN(this).maskn(a))}shl(a){return(this.isNegative()||a<0)&&throwFault("negative-width","shl"),toBigNumber(toBN(this).shln(a))}shr(a){return(this.isNegative()||a<0)&&throwFault("negative-width","shr"),toBigNumber(toBN(this).shrn(a))}eq(a){return toBN(this).eq(toBN(a))}lt(a){return toBN(this).lt(toBN(a))}lte(a){return toBN(this).lte(toBN(a))}gt(a){return toBN(this).gt(toBN(a))}gte(a){return toBN(this).gte(toBN(a))}isNegative(){return this._hex[0]==="-"}isZero(){return toBN(this).isZero()}toNumber(){try{return toBN(this).toNumber()}catch{throwFault("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch{}return logger$g.throwError("this platform does not support BigInt",Logger.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(arguments[0]===10?_warnedToStringRadix||(_warnedToStringRadix=!0,logger$g.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):arguments[0]===16?logger$g.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",Logger.errors.UNEXPECTED_ARGUMENT,{}):logger$g.throwError("BigNumber.toString does not accept parameters",Logger.errors.UNEXPECTED_ARGUMENT,{})),toBN(this).toString(10)}toHexString(){return this._hex}toJSON(a){return{type:"BigNumber",hex:this.toHexString()}}static from(a){if(a instanceof BigNumber)return a;if(typeof a=="string")return a.match(/^-?0x[0-9a-f]+$/i)?new BigNumber(_constructorGuard$1,toHex$1(a)):a.match(/^-?[0-9]+$/)?new BigNumber(_constructorGuard$1,toHex$1(new BN(a))):logger$g.throwArgumentError("invalid BigNumber string","value",a);if(typeof a=="number")return a%1&&throwFault("underflow","BigNumber.from",a),(a>=MAX_SAFE||a<=-MAX_SAFE)&&throwFault("overflow","BigNumber.from",a),BigNumber.from(String(a));const d=a;if(typeof d=="bigint")return BigNumber.from(d.toString());if(isBytes(d))return BigNumber.from(hexlify(d));if(d)if(d.toHexString){const et=d.toHexString();if(typeof et=="string")return BigNumber.from(et)}else{let et=d._hex;if(et==null&&d.type==="BigNumber"&&(et=d.hex),typeof et=="string"&&(isHexString(et)||et[0]==="-"&&isHexString(et.substring(1))))return BigNumber.from(et)}return logger$g.throwArgumentError("invalid BigNumber value","value",a)}static isBigNumber(a){return!!(a&&a._isBigNumber)}}function toHex$1(c){if(typeof c!="string")return toHex$1(c.toString(16));if(c[0]==="-")return c=c.substring(1),c[0]==="-"&&logger$g.throwArgumentError("invalid hex","value",c),c=toHex$1(c),c==="0x00"?c:"-"+c;if(c.substring(0,2)!=="0x"&&(c="0x"+c),c==="0x")return"0x00";for(c.length%2&&(c="0x0"+c.substring(2));c.length>4&&c.substring(0,4)==="0x00";)c="0x"+c.substring(4);return c}function toBigNumber(c){return BigNumber.from(toHex$1(c))}function toBN(c){const a=BigNumber.from(c).toHexString();return a[0]==="-"?new BN("-"+a.substring(3),16):new BN(a.substring(2),16)}function throwFault(c,a,d){const et={fault:c,operation:a};return d!=null&&(et.value=d),logger$g.throwError(c,Logger.errors.NUMERIC_FAULT,et)}function _base36To16(c){return new BN(c,36).toString(16)}const version$f="properties/5.7.0";var __awaiter$5=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger$f=new Logger(version$f);function defineReadOnly(c,a,d){Object.defineProperty(c,a,{enumerable:!0,value:d,writable:!1})}function resolveProperties(c){return __awaiter$5(this,void 0,void 0,function*(){const a=Object.keys(c).map(et=>{const nt=c[et];return Promise.resolve(nt).then(tt=>({key:et,value:tt}))});return(yield Promise.all(a)).reduce((et,nt)=>(et[nt.key]=nt.value,et),{})})}function checkProperties(c,a){(!c||typeof c!="object")&&logger$f.throwArgumentError("invalid object","object",c),Object.keys(c).forEach(d=>{a[d]||logger$f.throwArgumentError("invalid object key - "+d,"transaction:"+d,c)})}function shallowCopy(c){const a={};for(const d in c)a[d]=c[d];return a}const opaque={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function _isFrozen(c){if(c==null||opaque[typeof c])return!0;if(Array.isArray(c)||typeof c=="object"){if(!Object.isFrozen(c))return!1;const a=Object.keys(c);for(let d=0;ddeepCopy(a)));if(typeof c=="object"){const a={};for(const d in c){const et=c[d];et!==void 0&&defineReadOnly(a,d,deepCopy(et))}return a}return logger$f.throwArgumentError(`Cannot deepCopy ${typeof c}`,"object",c)}function deepCopy(c){return _deepCopy(c)}class Description{constructor(a){for(const d in a)this[d]=deepCopy(a[d])}}var sha3$1={exports:{}};(function(c){(function(){var a="input is invalid type",d="finalize already called",et=typeof window=="object",nt=et?window:{};nt.JS_SHA3_NO_WINDOW&&(et=!1);var tt=!et&&typeof self=="object",bt=!nt.JS_SHA3_NO_NODE_JS&&typeof dist$2.process=="object"&&dist$2.process.versions&&dist$2.process.versions.node;bt?nt=commonjsGlobal:tt&&(nt=self);var mt=!nt.JS_SHA3_NO_COMMON_JS&&!0&&c.exports,vt=!nt.JS_SHA3_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",$t="0123456789abcdef".split(""),At=[31,7936,2031616,520093696],Mt=[4,1024,262144,67108864],Tt=[1,256,65536,16777216],Rt=[6,1536,393216,100663296],kt=[0,8,16,24],It=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],Dt=[224,256,384,512],Nt=[128,256],Ot=["hex","buffer","arrayBuffer","array","digest"],Ut={128:168,256:136};(nt.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(Ft){return Object.prototype.toString.call(Ft)==="[object Array]"}),vt&&(nt.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(Ft){return typeof Ft=="object"&&Ft.buffer&&Ft.buffer.constructor===ArrayBuffer});for(var Gt=function(Ft,Vt,zt){return function(qt){return new Bt(Ft,Vt,Ft).update(qt)[zt]()}},Wt=function(Ft,Vt,zt){return function(qt,Kt){return new Bt(Ft,Vt,Kt).update(qt)[zt]()}},Xt=function(Ft,Vt,zt){return function(qt,Kt,e0,Zt){return gt["cshake"+Ft].update(qt,Kt,e0,Zt)[zt]()}},a0=function(Ft,Vt,zt){return function(qt,Kt,e0,Zt){return gt["kmac"+Ft].update(qt,Kt,e0,Zt)[zt]()}},n0=function(Ft,Vt,zt,qt){for(var Kt=0;Kt>5,this.byteCount=this.blockCount<<2,this.outputBlocks=zt>>5,this.extraBytes=(zt&31)>>3;for(var qt=0;qt<50;++qt)this.s[qt]=0}Bt.prototype.update=function(Ft){if(this.finalized)throw new Error(d);var Vt,zt=typeof Ft;if(zt!=="string"){if(zt==="object"){if(Ft===null)throw new Error(a);if(vt&&Ft.constructor===ArrayBuffer)Ft=new Uint8Array(Ft);else if(!Array.isArray(Ft)&&(!vt||!ArrayBuffer.isView(Ft)))throw new Error(a)}else throw new Error(a);Vt=!0}for(var qt=this.blocks,Kt=this.byteCount,e0=Ft.length,Zt=this.blockCount,Jt=0,i0=this.s,h0,o0;Jt>2]|=Ft[Jt]<>2]|=o0<>2]|=(192|o0>>6)<>2]|=(128|o0&63)<=57344?(qt[h0>>2]|=(224|o0>>12)<>2]|=(128|o0>>6&63)<>2]|=(128|o0&63)<>2]|=(240|o0>>18)<>2]|=(128|o0>>12&63)<>2]|=(128|o0>>6&63)<>2]|=(128|o0&63)<=Kt){for(this.start=h0-Kt,this.block=qt[Zt],h0=0;h0>8,zt=Ft&255;zt>0;)Kt.unshift(zt),Ft=Ft>>8,zt=Ft&255,++qt;return Vt?Kt.push(qt):Kt.unshift(qt),this.update(Kt),Kt.length},Bt.prototype.encodeString=function(Ft){var Vt,zt=typeof Ft;if(zt!=="string"){if(zt==="object"){if(Ft===null)throw new Error(a);if(vt&&Ft.constructor===ArrayBuffer)Ft=new Uint8Array(Ft);else if(!Array.isArray(Ft)&&(!vt||!ArrayBuffer.isView(Ft)))throw new Error(a)}else throw new Error(a);Vt=!0}var qt=0,Kt=Ft.length;if(Vt)qt=Kt;else for(var e0=0;e0=57344?qt+=3:(Zt=65536+((Zt&1023)<<10|Ft.charCodeAt(++e0)&1023),qt+=4)}return qt+=this.encode(qt*8),this.update(Ft),qt},Bt.prototype.bytepad=function(Ft,Vt){for(var zt=this.encode(Vt),qt=0;qt>2]|=this.padding[Vt&3],this.lastByteIndex===this.byteCount)for(Ft[0]=Ft[zt],Vt=1;Vt>4&15]+$t[Jt&15]+$t[Jt>>12&15]+$t[Jt>>8&15]+$t[Jt>>20&15]+$t[Jt>>16&15]+$t[Jt>>28&15]+$t[Jt>>24&15];e0%Ft===0&&(jt(Vt),Kt=0)}return qt&&(Jt=Vt[Kt],Zt+=$t[Jt>>4&15]+$t[Jt&15],qt>1&&(Zt+=$t[Jt>>12&15]+$t[Jt>>8&15]),qt>2&&(Zt+=$t[Jt>>20&15]+$t[Jt>>16&15])),Zt},Bt.prototype.arrayBuffer=function(){this.finalize();var Ft=this.blockCount,Vt=this.s,zt=this.outputBlocks,qt=this.extraBytes,Kt=0,e0=0,Zt=this.outputBits>>3,Jt;qt?Jt=new ArrayBuffer(zt+1<<2):Jt=new ArrayBuffer(Zt);for(var i0=new Uint32Array(Jt);e0>8&255,Zt[Jt+2]=i0>>16&255,Zt[Jt+3]=i0>>24&255;e0%Ft===0&&jt(Vt)}return qt&&(Jt=e0<<2,i0=Vt[Kt],Zt[Jt]=i0&255,qt>1&&(Zt[Jt+1]=i0>>8&255),qt>2&&(Zt[Jt+2]=i0>>16&255)),Zt};function Lt(Ft,Vt,zt){Bt.call(this,Ft,Vt,zt)}Lt.prototype=new Bt,Lt.prototype.finalize=function(){return this.encode(this.outputBits,!0),Bt.prototype.finalize.call(this)};var jt=function(Ft){var Vt,zt,qt,Kt,e0,Zt,Jt,i0,h0,o0,l0,$0,p0,u0,J0,v0,E0,Z0,w0,b0,K0,Qt,Ht,Yt,r0,f0,x0,d0,y0,Q0,g0,A0,Y0,_0,N0,X0,M0,O0,rr,P0,D0,nr,C0,F0,ir,R0,U0,ar,B0,z0,or,k0,H0,fr,I0,j0,er,tr,cr,lr,ur,dr,pr;for(qt=0;qt<48;qt+=2)Kt=Ft[0]^Ft[10]^Ft[20]^Ft[30]^Ft[40],e0=Ft[1]^Ft[11]^Ft[21]^Ft[31]^Ft[41],Zt=Ft[2]^Ft[12]^Ft[22]^Ft[32]^Ft[42],Jt=Ft[3]^Ft[13]^Ft[23]^Ft[33]^Ft[43],i0=Ft[4]^Ft[14]^Ft[24]^Ft[34]^Ft[44],h0=Ft[5]^Ft[15]^Ft[25]^Ft[35]^Ft[45],o0=Ft[6]^Ft[16]^Ft[26]^Ft[36]^Ft[46],l0=Ft[7]^Ft[17]^Ft[27]^Ft[37]^Ft[47],$0=Ft[8]^Ft[18]^Ft[28]^Ft[38]^Ft[48],p0=Ft[9]^Ft[19]^Ft[29]^Ft[39]^Ft[49],Vt=$0^(Zt<<1|Jt>>>31),zt=p0^(Jt<<1|Zt>>>31),Ft[0]^=Vt,Ft[1]^=zt,Ft[10]^=Vt,Ft[11]^=zt,Ft[20]^=Vt,Ft[21]^=zt,Ft[30]^=Vt,Ft[31]^=zt,Ft[40]^=Vt,Ft[41]^=zt,Vt=Kt^(i0<<1|h0>>>31),zt=e0^(h0<<1|i0>>>31),Ft[2]^=Vt,Ft[3]^=zt,Ft[12]^=Vt,Ft[13]^=zt,Ft[22]^=Vt,Ft[23]^=zt,Ft[32]^=Vt,Ft[33]^=zt,Ft[42]^=Vt,Ft[43]^=zt,Vt=Zt^(o0<<1|l0>>>31),zt=Jt^(l0<<1|o0>>>31),Ft[4]^=Vt,Ft[5]^=zt,Ft[14]^=Vt,Ft[15]^=zt,Ft[24]^=Vt,Ft[25]^=zt,Ft[34]^=Vt,Ft[35]^=zt,Ft[44]^=Vt,Ft[45]^=zt,Vt=i0^($0<<1|p0>>>31),zt=h0^(p0<<1|$0>>>31),Ft[6]^=Vt,Ft[7]^=zt,Ft[16]^=Vt,Ft[17]^=zt,Ft[26]^=Vt,Ft[27]^=zt,Ft[36]^=Vt,Ft[37]^=zt,Ft[46]^=Vt,Ft[47]^=zt,Vt=o0^(Kt<<1|e0>>>31),zt=l0^(e0<<1|Kt>>>31),Ft[8]^=Vt,Ft[9]^=zt,Ft[18]^=Vt,Ft[19]^=zt,Ft[28]^=Vt,Ft[29]^=zt,Ft[38]^=Vt,Ft[39]^=zt,Ft[48]^=Vt,Ft[49]^=zt,u0=Ft[0],J0=Ft[1],R0=Ft[11]<<4|Ft[10]>>>28,U0=Ft[10]<<4|Ft[11]>>>28,d0=Ft[20]<<3|Ft[21]>>>29,y0=Ft[21]<<3|Ft[20]>>>29,lr=Ft[31]<<9|Ft[30]>>>23,ur=Ft[30]<<9|Ft[31]>>>23,nr=Ft[40]<<18|Ft[41]>>>14,C0=Ft[41]<<18|Ft[40]>>>14,_0=Ft[2]<<1|Ft[3]>>>31,N0=Ft[3]<<1|Ft[2]>>>31,v0=Ft[13]<<12|Ft[12]>>>20,E0=Ft[12]<<12|Ft[13]>>>20,ar=Ft[22]<<10|Ft[23]>>>22,B0=Ft[23]<<10|Ft[22]>>>22,Q0=Ft[33]<<13|Ft[32]>>>19,g0=Ft[32]<<13|Ft[33]>>>19,dr=Ft[42]<<2|Ft[43]>>>30,pr=Ft[43]<<2|Ft[42]>>>30,fr=Ft[5]<<30|Ft[4]>>>2,I0=Ft[4]<<30|Ft[5]>>>2,X0=Ft[14]<<6|Ft[15]>>>26,M0=Ft[15]<<6|Ft[14]>>>26,Z0=Ft[25]<<11|Ft[24]>>>21,w0=Ft[24]<<11|Ft[25]>>>21,z0=Ft[34]<<15|Ft[35]>>>17,or=Ft[35]<<15|Ft[34]>>>17,A0=Ft[45]<<29|Ft[44]>>>3,Y0=Ft[44]<<29|Ft[45]>>>3,Yt=Ft[6]<<28|Ft[7]>>>4,r0=Ft[7]<<28|Ft[6]>>>4,j0=Ft[17]<<23|Ft[16]>>>9,er=Ft[16]<<23|Ft[17]>>>9,O0=Ft[26]<<25|Ft[27]>>>7,rr=Ft[27]<<25|Ft[26]>>>7,b0=Ft[36]<<21|Ft[37]>>>11,K0=Ft[37]<<21|Ft[36]>>>11,k0=Ft[47]<<24|Ft[46]>>>8,H0=Ft[46]<<24|Ft[47]>>>8,F0=Ft[8]<<27|Ft[9]>>>5,ir=Ft[9]<<27|Ft[8]>>>5,f0=Ft[18]<<20|Ft[19]>>>12,x0=Ft[19]<<20|Ft[18]>>>12,tr=Ft[29]<<7|Ft[28]>>>25,cr=Ft[28]<<7|Ft[29]>>>25,P0=Ft[38]<<8|Ft[39]>>>24,D0=Ft[39]<<8|Ft[38]>>>24,Qt=Ft[48]<<14|Ft[49]>>>18,Ht=Ft[49]<<14|Ft[48]>>>18,Ft[0]=u0^~v0&Z0,Ft[1]=J0^~E0&w0,Ft[10]=Yt^~f0&d0,Ft[11]=r0^~x0&y0,Ft[20]=_0^~X0&O0,Ft[21]=N0^~M0&rr,Ft[30]=F0^~R0&ar,Ft[31]=ir^~U0&B0,Ft[40]=fr^~j0&tr,Ft[41]=I0^~er&cr,Ft[2]=v0^~Z0&b0,Ft[3]=E0^~w0&K0,Ft[12]=f0^~d0&Q0,Ft[13]=x0^~y0&g0,Ft[22]=X0^~O0&P0,Ft[23]=M0^~rr&D0,Ft[32]=R0^~ar&z0,Ft[33]=U0^~B0&or,Ft[42]=j0^~tr&lr,Ft[43]=er^~cr&ur,Ft[4]=Z0^~b0&Qt,Ft[5]=w0^~K0&Ht,Ft[14]=d0^~Q0&A0,Ft[15]=y0^~g0&Y0,Ft[24]=O0^~P0&nr,Ft[25]=rr^~D0&C0,Ft[34]=ar^~z0&k0,Ft[35]=B0^~or&H0,Ft[44]=tr^~lr&dr,Ft[45]=cr^~ur&pr,Ft[6]=b0^~Qt&u0,Ft[7]=K0^~Ht&J0,Ft[16]=Q0^~A0&Yt,Ft[17]=g0^~Y0&r0,Ft[26]=P0^~nr&_0,Ft[27]=D0^~C0&N0,Ft[36]=z0^~k0&F0,Ft[37]=or^~H0&ir,Ft[46]=lr^~dr&fr,Ft[47]=ur^~pr&I0,Ft[8]=Qt^~u0&v0,Ft[9]=Ht^~J0&E0,Ft[18]=A0^~Yt&f0,Ft[19]=Y0^~r0&x0,Ft[28]=nr^~_0&X0,Ft[29]=C0^~N0&M0,Ft[38]=k0^~F0&R0,Ft[39]=H0^~ir&U0,Ft[48]=dr^~fr&j0,Ft[49]=pr^~I0&er,Ft[0]^=It[qt],Ft[1]^=It[qt+1]};if(mt)c.exports=gt;else for(St=0;St>=8;return a}function _encode(c){if(Array.isArray(c)){let et=[];if(c.forEach(function(tt){et=et.concat(_encode(tt))}),et.length<=55)return et.unshift(192+et.length),et;const nt=arrayifyInteger(et.length);return nt.unshift(247+nt.length),nt.concat(et)}isBytesLike(c)||logger$e.throwArgumentError("RLP object must be BytesLike","object",c);const a=Array.prototype.slice.call(arrayify(c));if(a.length===1&&a[0]<=127)return a;if(a.length<=55)return a.unshift(128+a.length),a;const d=arrayifyInteger(a.length);return d.unshift(183+d.length),d.concat(a)}function encode$1(c){return hexlify(_encode(c))}const version$d="address/5.7.0",logger$d=new Logger(version$d);function getChecksumAddress(c){isHexString(c,20)||logger$d.throwArgumentError("invalid address","address",c),c=c.toLowerCase();const a=c.substring(2).split(""),d=new Uint8Array(40);for(let nt=0;nt<40;nt++)d[nt]=a[nt].charCodeAt(0);const et=arrayify(keccak256$1(d));for(let nt=0;nt<40;nt+=2)et[nt>>1]>>4>=8&&(a[nt]=a[nt].toUpperCase()),(et[nt>>1]&15)>=8&&(a[nt+1]=a[nt+1].toUpperCase());return"0x"+a.join("")}const MAX_SAFE_INTEGER=9007199254740991;function log10(c){return Math.log10?Math.log10(c):Math.log(c)/Math.LN10}const ibanLookup={};for(let c=0;c<10;c++)ibanLookup[String(c)]=String(c);for(let c=0;c<26;c++)ibanLookup[String.fromCharCode(65+c)]=String(10+c);const safeDigits=Math.floor(log10(MAX_SAFE_INTEGER));function ibanChecksum(c){c=c.toUpperCase(),c=c.substring(4)+c.substring(0,2)+"00";let a=c.split("").map(et=>ibanLookup[et]).join("");for(;a.length>=safeDigits;){let et=a.substring(0,safeDigits);a=parseInt(et,10)%97+a.substring(et.length)}let d=String(98-parseInt(a,10)%97);for(;d.length<2;)d="0"+d;return d}function getAddress$1(c){let a=null;if(typeof c!="string"&&logger$d.throwArgumentError("invalid address","address",c),c.match(/^(0x)?[0-9a-fA-F]{40}$/))c.substring(0,2)!=="0x"&&(c="0x"+c),a=getChecksumAddress(c),c.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&a!==c&&logger$d.throwArgumentError("bad address checksum","address",c);else if(c.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(c.substring(2,4)!==ibanChecksum(c)&&logger$d.throwArgumentError("bad icap checksum","address",c),a=_base36To16(c.substring(4));a.length<40;)a="0"+a;a=getChecksumAddress("0x"+a)}else logger$d.throwArgumentError("invalid address","address",c);return a}const version$c="strings/5.7.0",logger$c=new Logger(version$c);var UnicodeNormalizationForm;(function(c){c.current="",c.NFC="NFC",c.NFD="NFD",c.NFKC="NFKC",c.NFKD="NFKD"})(UnicodeNormalizationForm||(UnicodeNormalizationForm={}));var Utf8ErrorReason;(function(c){c.UNEXPECTED_CONTINUE="unexpected continuation byte",c.BAD_PREFIX="bad codepoint prefix",c.OVERRUN="string overrun",c.MISSING_CONTINUE="missing continuation byte",c.OUT_OF_RANGE="out of UTF-8 range",c.UTF16_SURROGATE="UTF-16 surrogate",c.OVERLONG="overlong representation"})(Utf8ErrorReason||(Utf8ErrorReason={}));function toUtf8Bytes(c,a=UnicodeNormalizationForm.current){a!=UnicodeNormalizationForm.current&&(logger$c.checkNormalize(),c=c.normalize(a));let d=[];for(let et=0;et>6|192),d.push(nt&63|128);else if((nt&64512)==55296){et++;const tt=c.charCodeAt(et);if(et>=c.length||(tt&64512)!==56320)throw new Error("invalid utf-8 string");const bt=65536+((nt&1023)<<10)+(tt&1023);d.push(bt>>18|240),d.push(bt>>12&63|128),d.push(bt>>6&63|128),d.push(bt&63|128)}else d.push(nt>>12|224),d.push(nt>>6&63|128),d.push(nt&63|128)}return arrayify(d)}function id$1(c){return keccak256$1(toUtf8Bytes(c))}const version$b="hash/5.7.0",messagePrefix=`Ethereum Signed Message: +`;function hashMessage$1(c){return typeof c=="string"&&(c=toUtf8Bytes(c)),keccak256$1(concat$1([toUtf8Bytes(messagePrefix),toUtf8Bytes(String(c.length)),c]))}var __awaiter$4=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger$b=new Logger(version$b),padding=new Uint8Array(32);padding.fill(0);const NegativeOne=BigNumber.from(-1),Zero=BigNumber.from(0),One=BigNumber.from(1),MaxUint256=BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function hexPadRight(c){const a=arrayify(c),d=a.length%32;return d?hexConcat([a,padding.slice(d)]):hexlify(a)}const hexTrue=hexZeroPad(One.toHexString(),32),hexFalse=hexZeroPad(Zero.toHexString(),32),domainFieldTypes={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},domainFieldNames=["name","version","chainId","verifyingContract","salt"];function checkString(c){return function(a){return typeof a!="string"&&logger$b.throwArgumentError(`invalid domain value for ${JSON.stringify(c)}`,`domain.${c}`,a),a}}const domainChecks={name:checkString("name"),version:checkString("version"),chainId:function(c){try{return BigNumber.from(c).toString()}catch{}return logger$b.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",c)},verifyingContract:function(c){try{return getAddress$1(c).toLowerCase()}catch{}return logger$b.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",c)},salt:function(c){try{const a=arrayify(c);if(a.length!==32)throw new Error("bad length");return hexlify(a)}catch{}return logger$b.throwArgumentError('invalid domain value "salt"',"domain.salt",c)}};function getBaseEncoder(c){{const a=c.match(/^(u?)int(\d*)$/);if(a){const d=a[1]==="",et=parseInt(a[2]||"256");(et%8!==0||et>256||a[2]&&a[2]!==String(et))&&logger$b.throwArgumentError("invalid numeric width","type",c);const nt=MaxUint256.mask(d?et-1:et),tt=d?nt.add(One).mul(NegativeOne):Zero;return function(bt){const mt=BigNumber.from(bt);return(mt.lt(tt)||mt.gt(nt))&&logger$b.throwArgumentError(`value out-of-bounds for ${c}`,"value",bt),hexZeroPad(mt.toTwos(256).toHexString(),32)}}}{const a=c.match(/^bytes(\d+)$/);if(a){const d=parseInt(a[1]);return(d===0||d>32||a[1]!==String(d))&&logger$b.throwArgumentError("invalid bytes width","type",c),function(et){return arrayify(et).length!==d&&logger$b.throwArgumentError(`invalid length for ${c}`,"value",et),hexPadRight(et)}}}switch(c){case"address":return function(a){return hexZeroPad(getAddress$1(a),32)};case"bool":return function(a){return a?hexTrue:hexFalse};case"bytes":return function(a){return keccak256$1(a)};case"string":return function(a){return id$1(a)}}return null}function encodeType$1(c,a){return`${c}(${a.map(({name:d,type:et})=>et+" "+d).join(",")})`}class TypedDataEncoder{constructor(a){defineReadOnly(this,"types",Object.freeze(deepCopy(a))),defineReadOnly(this,"_encoderCache",{}),defineReadOnly(this,"_types",{});const d={},et={},nt={};Object.keys(a).forEach(mt=>{d[mt]={},et[mt]=[],nt[mt]={}});for(const mt in a){const vt={};a[mt].forEach($t=>{vt[$t.name]&&logger$b.throwArgumentError(`duplicate variable name ${JSON.stringify($t.name)} in ${JSON.stringify(mt)}`,"types",a),vt[$t.name]=!0;const At=$t.type.match(/^([^\x5b]*)(\x5b|$)/)[1];At===mt&&logger$b.throwArgumentError(`circular type reference to ${JSON.stringify(At)}`,"types",a),!getBaseEncoder(At)&&(et[At]||logger$b.throwArgumentError(`unknown type ${JSON.stringify(At)}`,"types",a),et[At].push(mt),d[mt][At]=!0)})}const tt=Object.keys(et).filter(mt=>et[mt].length===0);tt.length===0?logger$b.throwArgumentError("missing primary type","types",a):tt.length>1&&logger$b.throwArgumentError(`ambiguous primary types or unused types: ${tt.map(mt=>JSON.stringify(mt)).join(", ")}`,"types",a),defineReadOnly(this,"primaryType",tt[0]);function bt(mt,vt){vt[mt]&&logger$b.throwArgumentError(`circular type reference to ${JSON.stringify(mt)}`,"types",a),vt[mt]=!0,Object.keys(d[mt]).forEach($t=>{et[$t]&&(bt($t,vt),Object.keys(vt).forEach(At=>{nt[At][$t]=!0}))}),delete vt[mt]}bt(this.primaryType,{});for(const mt in nt){const vt=Object.keys(nt[mt]);vt.sort(),this._types[mt]=encodeType$1(mt,a[mt])+vt.map($t=>encodeType$1($t,a[$t])).join("")}}getEncoder(a){let d=this._encoderCache[a];return d||(d=this._encoderCache[a]=this._getEncoder(a)),d}_getEncoder(a){{const nt=getBaseEncoder(a);if(nt)return nt}const d=a.match(/^(.*)(\x5b(\d*)\x5d)$/);if(d){const nt=d[1],tt=this.getEncoder(nt),bt=parseInt(d[3]);return mt=>{bt>=0&&mt.length!==bt&&logger$b.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",mt);let vt=mt.map(tt);return this._types[nt]&&(vt=vt.map(keccak256$1)),keccak256$1(hexConcat(vt))}}const et=this.types[a];if(et){const nt=id$1(this._types[a]);return tt=>{const bt=et.map(({name:mt,type:vt})=>{const $t=this.getEncoder(vt)(tt[mt]);return this._types[vt]?keccak256$1($t):$t});return bt.unshift(nt),hexConcat(bt)}}return logger$b.throwArgumentError(`unknown type: ${a}`,"type",a)}encodeType(a){const d=this._types[a];return d||logger$b.throwArgumentError(`unknown type: ${JSON.stringify(a)}`,"name",a),d}encodeData(a,d){return this.getEncoder(a)(d)}hashStruct(a,d){return keccak256$1(this.encodeData(a,d))}encode(a){return this.encodeData(this.primaryType,a)}hash(a){return this.hashStruct(this.primaryType,a)}_visit(a,d,et){if(getBaseEncoder(a))return et(a,d);const nt=a.match(/^(.*)(\x5b(\d*)\x5d)$/);if(nt){const bt=nt[1],mt=parseInt(nt[3]);return mt>=0&&d.length!==mt&&logger$b.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",d),d.map(vt=>this._visit(bt,vt,et))}const tt=this.types[a];return tt?tt.reduce((bt,{name:mt,type:vt})=>(bt[mt]=this._visit(vt,d[mt],et),bt),{}):logger$b.throwArgumentError(`unknown type: ${a}`,"type",a)}visit(a,d){return this._visit(this.primaryType,a,d)}static from(a){return new TypedDataEncoder(a)}static getPrimaryType(a){return TypedDataEncoder.from(a).primaryType}static hashStruct(a,d,et){return TypedDataEncoder.from(d).hashStruct(a,et)}static hashDomain(a){const d=[];for(const et in a){const nt=domainFieldTypes[et];nt||logger$b.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(et)}`,"domain",a),d.push({name:et,type:nt})}return d.sort((et,nt)=>domainFieldNames.indexOf(et.name)-domainFieldNames.indexOf(nt.name)),TypedDataEncoder.hashStruct("EIP712Domain",{EIP712Domain:d},a)}static encode(a,d,et){return hexConcat(["0x1901",TypedDataEncoder.hashDomain(a),TypedDataEncoder.from(d).hash(et)])}static hash(a,d,et){return keccak256$1(TypedDataEncoder.encode(a,d,et))}static resolveNames(a,d,et,nt){return __awaiter$4(this,void 0,void 0,function*(){a=shallowCopy(a);const tt={};a.verifyingContract&&!isHexString(a.verifyingContract,20)&&(tt[a.verifyingContract]="0x");const bt=TypedDataEncoder.from(d);bt.visit(et,(mt,vt)=>(mt==="address"&&!isHexString(vt,20)&&(tt[vt]="0x"),vt));for(const mt in tt)tt[mt]=yield nt(mt);return a.verifyingContract&&tt[a.verifyingContract]&&(a.verifyingContract=tt[a.verifyingContract]),et=bt.visit(et,(mt,vt)=>mt==="address"&&tt[vt]?tt[vt]:vt),{domain:a,value:et}})}static getPayload(a,d,et){TypedDataEncoder.hashDomain(a);const nt={},tt=[];domainFieldNames.forEach(vt=>{const $t=a[vt];$t!=null&&(nt[vt]=domainChecks[vt]($t),tt.push({name:vt,type:domainFieldTypes[vt]}))});const bt=TypedDataEncoder.from(d),mt=shallowCopy(d);return mt.EIP712Domain?logger$b.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",d):mt.EIP712Domain=tt,bt.encode(et),{types:mt,domain:nt,primaryType:bt.primaryType,message:bt.visit(et,(vt,$t)=>{if(vt.match(/^bytes(\d*)/))return hexlify(arrayify($t));if(vt.match(/^u?int/))return BigNumber.from($t).toString();switch(vt){case"address":return $t.toLowerCase();case"bool":return!!$t;case"string":return typeof $t!="string"&&logger$b.throwArgumentError("invalid string","value",$t),$t}return logger$b.throwArgumentError("unsupported type","type",vt)})}}}const version$a="abstract-provider/5.7.0";var __awaiter$3=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger$a=new Logger(version$a);class Provider{constructor(){logger$a.checkAbstract(new.target,Provider),defineReadOnly(this,"_isProvider",!0)}getFeeData(){return __awaiter$3(this,void 0,void 0,function*(){const{block:a,gasPrice:d}=yield resolveProperties({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch(bt=>null)});let et=null,nt=null,tt=null;return a&&a.baseFeePerGas&&(et=a.baseFeePerGas,tt=BigNumber.from("1500000000"),nt=a.baseFeePerGas.mul(2).add(tt)),{lastBaseFeePerGas:et,maxFeePerGas:nt,maxPriorityFeePerGas:tt,gasPrice:d}})}addListener(a,d){return this.on(a,d)}removeListener(a,d){return this.off(a,d)}static isProvider(a){return!!(a&&a._isProvider)}}const version$9="abstract-signer/5.7.0";var __awaiter$2=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger$9=new Logger(version$9),allowedTransactionKeys$1=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],forwardErrors=[Logger.errors.INSUFFICIENT_FUNDS,Logger.errors.NONCE_EXPIRED,Logger.errors.REPLACEMENT_UNDERPRICED];class Signer{constructor(){logger$9.checkAbstract(new.target,Signer),defineReadOnly(this,"_isSigner",!0)}getBalance(a){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),a)})}getTransactionCount(a){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),a)})}estimateGas(a){return __awaiter$2(this,void 0,void 0,function*(){this._checkProvider("estimateGas");const d=yield resolveProperties(this.checkTransaction(a));return yield this.provider.estimateGas(d)})}call(a,d){return __awaiter$2(this,void 0,void 0,function*(){this._checkProvider("call");const et=yield resolveProperties(this.checkTransaction(a));return yield this.provider.call(et,d)})}sendTransaction(a){return __awaiter$2(this,void 0,void 0,function*(){this._checkProvider("sendTransaction");const d=yield this.populateTransaction(a),et=yield this.signTransaction(d);return yield this.provider.sendTransaction(et)})}getChainId(){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("getChainId"),(yield this.provider.getNetwork()).chainId})}getGasPrice(){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()})}getFeeData(){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()})}resolveName(a){return __awaiter$2(this,void 0,void 0,function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(a)})}checkTransaction(a){for(const et in a)allowedTransactionKeys$1.indexOf(et)===-1&&logger$9.throwArgumentError("invalid transaction key: "+et,"transaction",a);const d=shallowCopy(a);return d.from==null?d.from=this.getAddress():d.from=Promise.all([Promise.resolve(d.from),this.getAddress()]).then(et=>(et[0].toLowerCase()!==et[1].toLowerCase()&&logger$9.throwArgumentError("from address mismatch","transaction",a),et[0])),d}populateTransaction(a){return __awaiter$2(this,void 0,void 0,function*(){const d=yield resolveProperties(this.checkTransaction(a));d.to!=null&&(d.to=Promise.resolve(d.to).then(nt=>__awaiter$2(this,void 0,void 0,function*(){if(nt==null)return null;const tt=yield this.resolveName(nt);return tt==null&&logger$9.throwArgumentError("provided ENS name resolves to null","tx.to",nt),tt})),d.to.catch(nt=>{}));const et=d.maxFeePerGas!=null||d.maxPriorityFeePerGas!=null;if(d.gasPrice!=null&&(d.type===2||et)?logger$9.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",a):(d.type===0||d.type===1)&&et&&logger$9.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",a),(d.type===2||d.type==null)&&d.maxFeePerGas!=null&&d.maxPriorityFeePerGas!=null)d.type=2;else if(d.type===0||d.type===1)d.gasPrice==null&&(d.gasPrice=this.getGasPrice());else{const nt=yield this.getFeeData();if(d.type==null)if(nt.maxFeePerGas!=null&&nt.maxPriorityFeePerGas!=null)if(d.type=2,d.gasPrice!=null){const tt=d.gasPrice;delete d.gasPrice,d.maxFeePerGas=tt,d.maxPriorityFeePerGas=tt}else d.maxFeePerGas==null&&(d.maxFeePerGas=nt.maxFeePerGas),d.maxPriorityFeePerGas==null&&(d.maxPriorityFeePerGas=nt.maxPriorityFeePerGas);else nt.gasPrice!=null?(et&&logger$9.throwError("network does not support EIP-1559",Logger.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),d.gasPrice==null&&(d.gasPrice=nt.gasPrice),d.type=0):logger$9.throwError("failed to get consistent fee data",Logger.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else d.type===2&&(d.maxFeePerGas==null&&(d.maxFeePerGas=nt.maxFeePerGas),d.maxPriorityFeePerGas==null&&(d.maxPriorityFeePerGas=nt.maxPriorityFeePerGas))}return d.nonce==null&&(d.nonce=this.getTransactionCount("pending")),d.gasLimit==null&&(d.gasLimit=this.estimateGas(d).catch(nt=>{if(forwardErrors.indexOf(nt.code)>=0)throw nt;return logger$9.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",Logger.errors.UNPREDICTABLE_GAS_LIMIT,{error:nt,tx:d})})),d.chainId==null?d.chainId=this.getChainId():d.chainId=Promise.all([Promise.resolve(d.chainId),this.getChainId()]).then(nt=>(nt[1]!==0&&nt[0]!==nt[1]&&logger$9.throwArgumentError("chainId address mismatch","transaction",a),nt[0])),yield resolveProperties(d)})}_checkProvider(a){this.provider||logger$9.throwError("missing provider",Logger.errors.UNSUPPORTED_OPERATION,{operation:a||"_checkProvider"})}static isSigner(a){return!!(a&&a._isSigner)}}function createCommonjsModule(c,a,d){return d={path:a,exports:{},require:function(et,nt){return commonjsRequire(et,nt??d.path)}},c(d,d.exports),d.exports}function commonjsRequire(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var minimalisticAssert=assert;function assert(c,a){if(!c)throw new Error(a||"Assertion failed")}assert.equal=function c(a,d,et){if(a!=d)throw new Error(et||"Assertion failed: "+a+" != "+d)};var utils_1=createCommonjsModule(function(c,a){var d=a;function et(bt,mt){if(Array.isArray(bt))return bt.slice();if(!bt)return[];var vt=[];if(typeof bt!="string"){for(var $t=0;$t>8,Tt=At&255;Mt?vt.push(Mt,Tt):vt.push(Tt)}return vt}d.toArray=et;function nt(bt){return bt.length===1?"0"+bt:bt}d.zero2=nt;function tt(bt){for(var mt="",vt=0;vt(Tt>>1)-1?It=(Tt>>1)-Dt:It=Dt,Rt.isubn(It)):It=0,Mt[kt]=It,Rt.iushrn(1)}return Mt}d.getNAF=et;function nt(vt,$t){var At=[[],[]];vt=vt.clone(),$t=$t.clone();for(var Mt=0,Tt=0,Rt;vt.cmpn(-Mt)>0||$t.cmpn(-Tt)>0;){var kt=vt.andln(3)+Mt&3,It=$t.andln(3)+Tt&3;kt===3&&(kt=-1),It===3&&(It=-1);var Dt;kt&1?(Rt=vt.andln(7)+Mt&7,(Rt===3||Rt===5)&&It===2?Dt=-kt:Dt=kt):Dt=0,At[0].push(Dt);var Nt;It&1?(Rt=$t.andln(7)+Tt&7,(Rt===3||Rt===5)&&kt===2?Nt=-It:Nt=It):Nt=0,At[1].push(Nt),2*Mt===Dt+1&&(Mt=1-Mt),2*Tt===Nt+1&&(Tt=1-Tt),vt.iushrn(1),$t.iushrn(1)}return At}d.getJSF=nt;function tt(vt,$t,At){var Mt="_"+$t;vt.prototype[$t]=function(){return this[Mt]!==void 0?this[Mt]:this[Mt]=At.call(this)}}d.cachedProperty=tt;function bt(vt){return typeof vt=="string"?d.toArray(vt,"hex"):vt}d.parseBytes=bt;function mt(vt){return new BN$j(vt,"hex","le")}d.intFromLE=mt}),getNAF=utils_1$1.getNAF,getJSF=utils_1$1.getJSF,assert$1=utils_1$1.assert;function BaseCurve(c,a){this.type=c,this.p=new BN$j(a.p,16),this.red=a.prime?BN$j.red(a.prime):BN$j.mont(this.p),this.zero=new BN$j(0).toRed(this.red),this.one=new BN$j(1).toRed(this.red),this.two=new BN$j(2).toRed(this.red),this.n=a.n&&new BN$j(a.n,16),this.g=a.g&&this.pointFromJSON(a.g,a.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var d=this.n&&this.p.div(this.n);!d||d.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var base$1=BaseCurve;BaseCurve.prototype.point=function c(){throw new Error("Not implemented")};BaseCurve.prototype.validate=function c(){throw new Error("Not implemented")};BaseCurve.prototype._fixedNafMul=function c(a,d){assert$1(a.precomputed);var et=a._getDoubles(),nt=getNAF(d,1,this._bitLength),tt=(1<=mt;$t--)vt=(vt<<1)+nt[$t];bt.push(vt)}for(var At=this.jpoint(null,null,null),Mt=this.jpoint(null,null,null),Tt=tt;Tt>0;Tt--){for(mt=0;mt=0;vt--){for(var $t=0;vt>=0&&bt[vt]===0;vt--)$t++;if(vt>=0&&$t++,mt=mt.dblp($t),vt<0)break;var At=bt[vt];assert$1(At!==0),a.type==="affine"?At>0?mt=mt.mixedAdd(tt[At-1>>1]):mt=mt.mixedAdd(tt[-At-1>>1].neg()):At>0?mt=mt.add(tt[At-1>>1]):mt=mt.add(tt[-At-1>>1].neg())}return a.type==="affine"?mt.toP():mt};BaseCurve.prototype._wnafMulAdd=function c(a,d,et,nt,tt){var bt=this._wnafT1,mt=this._wnafT2,vt=this._wnafT3,$t=0,At,Mt,Tt;for(At=0;At=1;At-=2){var kt=At-1,It=At;if(bt[kt]!==1||bt[It]!==1){vt[kt]=getNAF(et[kt],bt[kt],this._bitLength),vt[It]=getNAF(et[It],bt[It],this._bitLength),$t=Math.max(vt[kt].length,$t),$t=Math.max(vt[It].length,$t);continue}var Dt=[d[kt],null,null,d[It]];d[kt].y.cmp(d[It].y)===0?(Dt[1]=d[kt].add(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg())):d[kt].y.cmp(d[It].y.redNeg())===0?(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].add(d[It].neg())):(Dt[1]=d[kt].toJ().mixedAdd(d[It]),Dt[2]=d[kt].toJ().mixedAdd(d[It].neg()));var Nt=[-3,-1,-5,-7,0,7,5,1,3],Ot=getJSF(et[kt],et[It]);for($t=Math.max(Ot[0].length,$t),vt[kt]=new Array($t),vt[It]=new Array($t),Mt=0;Mt<$t;Mt++){var Ut=Ot[0][Mt]|0,Gt=Ot[1][Mt]|0;vt[kt][Mt]=Nt[(Ut+1)*3+(Gt+1)],vt[It][Mt]=0,mt[kt]=Dt}}var Wt=this.jpoint(null,null,null),Xt=this._wnafT4;for(At=$t;At>=0;At--){for(var a0=0;At>=0;){var n0=!0;for(Mt=0;Mt=0&&a0++,Wt=Wt.dblp(a0),At<0)break;for(Mt=0;Mt0?Tt=mt[Mt][t0-1>>1]:t0<0&&(Tt=mt[Mt][-t0-1>>1].neg()),Tt.type==="affine"?Wt=Wt.mixedAdd(Tt):Wt=Wt.add(Tt))}}for(At=0;At=Math.ceil((a.bitLength()+1)/d.step):!1};BasePoint.prototype._getDoubles=function c(a,d){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var et=[this],nt=this,tt=0;tt=0&&(Rt=$t,kt=At),Mt.negative&&(Mt=Mt.neg(),Tt=Tt.neg()),Rt.negative&&(Rt=Rt.neg(),kt=kt.neg()),[{a:Mt,b:Tt},{a:Rt,b:kt}]};ShortCurve.prototype._endoSplit=function c(a){var d=this.endo.basis,et=d[0],nt=d[1],tt=nt.b.mul(a).divRound(this.n),bt=et.b.neg().mul(a).divRound(this.n),mt=tt.mul(et.a),vt=bt.mul(nt.a),$t=tt.mul(et.b),At=bt.mul(nt.b),Mt=a.sub(mt).sub(vt),Tt=$t.add(At).neg();return{k1:Mt,k2:Tt}};ShortCurve.prototype.pointFromX=function c(a,d){a=new BN$j(a,16),a.red||(a=a.toRed(this.red));var et=a.redSqr().redMul(a).redIAdd(a.redMul(this.a)).redIAdd(this.b),nt=et.redSqrt();if(nt.redSqr().redSub(et).cmp(this.zero)!==0)throw new Error("invalid point");var tt=nt.fromRed().isOdd();return(d&&!tt||!d&&tt)&&(nt=nt.redNeg()),this.point(a,nt)};ShortCurve.prototype.validate=function c(a){if(a.inf)return!0;var d=a.x,et=a.y,nt=this.a.redMul(d),tt=d.redSqr().redMul(d).redIAdd(nt).redIAdd(this.b);return et.redSqr().redISub(tt).cmpn(0)===0};ShortCurve.prototype._endoWnafMulAdd=function c(a,d,et){for(var nt=this._endoWnafT1,tt=this._endoWnafT2,bt=0;bt":""};Point.prototype.isInfinity=function c(){return this.inf};Point.prototype.add=function c(a){if(this.inf)return a;if(a.inf)return this;if(this.eq(a))return this.dbl();if(this.neg().eq(a))return this.curve.point(null,null);if(this.x.cmp(a.x)===0)return this.curve.point(null,null);var d=this.y.redSub(a.y);d.cmpn(0)!==0&&(d=d.redMul(this.x.redSub(a.x).redInvm()));var et=d.redSqr().redISub(this.x).redISub(a.x),nt=d.redMul(this.x.redSub(et)).redISub(this.y);return this.curve.point(et,nt)};Point.prototype.dbl=function c(){if(this.inf)return this;var a=this.y.redAdd(this.y);if(a.cmpn(0)===0)return this.curve.point(null,null);var d=this.curve.a,et=this.x.redSqr(),nt=a.redInvm(),tt=et.redAdd(et).redIAdd(et).redIAdd(d).redMul(nt),bt=tt.redSqr().redISub(this.x.redAdd(this.x)),mt=tt.redMul(this.x.redSub(bt)).redISub(this.y);return this.curve.point(bt,mt)};Point.prototype.getX=function c(){return this.x.fromRed()};Point.prototype.getY=function c(){return this.y.fromRed()};Point.prototype.mul=function c(a){return a=new BN$j(a,16),this.isInfinity()?this:this._hasDoubles(a)?this.curve._fixedNafMul(this,a):this.curve.endo?this.curve._endoWnafMulAdd([this],[a]):this.curve._wnafMul(this,a)};Point.prototype.mulAdd=function c(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt):this.curve._wnafMulAdd(1,nt,tt,2)};Point.prototype.jmulAdd=function c(a,d,et){var nt=[this,d],tt=[a,et];return this.curve.endo?this.curve._endoWnafMulAdd(nt,tt,!0):this.curve._wnafMulAdd(1,nt,tt,2,!0)};Point.prototype.eq=function c(a){return this===a||this.inf===a.inf&&(this.inf||this.x.cmp(a.x)===0&&this.y.cmp(a.y)===0)};Point.prototype.neg=function c(a){if(this.inf)return this;var d=this.curve.point(this.x,this.y.redNeg());if(a&&this.precomputed){var et=this.precomputed,nt=function(tt){return tt.neg()};d.precomputed={naf:et.naf&&{wnd:et.naf.wnd,points:et.naf.points.map(nt)},doubles:et.doubles&&{step:et.doubles.step,points:et.doubles.points.map(nt)}}}return d};Point.prototype.toJ=function c(){if(this.inf)return this.curve.jpoint(null,null,null);var a=this.curve.jpoint(this.x,this.y,this.curve.one);return a};function JPoint(c,a,d,et){base$1.BasePoint.call(this,c,"jacobian"),a===null&&d===null&&et===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new BN$j(0)):(this.x=new BN$j(a,16),this.y=new BN$j(d,16),this.z=new BN$j(et,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}inherits_browser(JPoint,base$1.BasePoint);ShortCurve.prototype.jpoint=function c(a,d,et){return new JPoint(this,a,d,et)};JPoint.prototype.toP=function c(){if(this.isInfinity())return this.curve.point(null,null);var a=this.z.redInvm(),d=a.redSqr(),et=this.x.redMul(d),nt=this.y.redMul(d).redMul(a);return this.curve.point(et,nt)};JPoint.prototype.neg=function c(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};JPoint.prototype.add=function c(a){if(this.isInfinity())return a;if(a.isInfinity())return this;var d=a.z.redSqr(),et=this.z.redSqr(),nt=this.x.redMul(d),tt=a.x.redMul(et),bt=this.y.redMul(d.redMul(a.z)),mt=a.y.redMul(et.redMul(this.z)),vt=nt.redSub(tt),$t=bt.redSub(mt);if(vt.cmpn(0)===0)return $t.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var At=vt.redSqr(),Mt=At.redMul(vt),Tt=nt.redMul(At),Rt=$t.redSqr().redIAdd(Mt).redISub(Tt).redISub(Tt),kt=$t.redMul(Tt.redISub(Rt)).redISub(bt.redMul(Mt)),It=this.z.redMul(a.z).redMul(vt);return this.curve.jpoint(Rt,kt,It)};JPoint.prototype.mixedAdd=function c(a){if(this.isInfinity())return a.toJ();if(a.isInfinity())return this;var d=this.z.redSqr(),et=this.x,nt=a.x.redMul(d),tt=this.y,bt=a.y.redMul(d).redMul(this.z),mt=et.redSub(nt),vt=tt.redSub(bt);if(mt.cmpn(0)===0)return vt.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var $t=mt.redSqr(),At=$t.redMul(mt),Mt=et.redMul($t),Tt=vt.redSqr().redIAdd(At).redISub(Mt).redISub(Mt),Rt=vt.redMul(Mt.redISub(Tt)).redISub(tt.redMul(At)),kt=this.z.redMul(mt);return this.curve.jpoint(Tt,Rt,kt)};JPoint.prototype.dblp=function c(a){if(a===0)return this;if(this.isInfinity())return this;if(!a)return this.dbl();var d;if(this.curve.zeroA||this.curve.threeA){var et=this;for(d=0;d=0)return!1;if(et.redIAdd(tt),this.x.cmp(et)===0)return!0}};JPoint.prototype.inspect=function c(){return this.isInfinity()?"":""};JPoint.prototype.isInfinity=function c(){return this.z.cmpn(0)===0};var curve_1=createCommonjsModule(function(c,a){var d=a;d.base=base$1,d.short=short_1,d.mont=null,d.edwards=null}),curves_1=createCommonjsModule(function(c,a){var d=a,et=utils_1$1.assert;function nt(mt){mt.type==="short"?this.curve=new curve_1.short(mt):mt.type==="edwards"?this.curve=new curve_1.edwards(mt):this.curve=new curve_1.mont(mt),this.g=this.curve.g,this.n=this.curve.n,this.hash=mt.hash,et(this.g.validate(),"Invalid curve"),et(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}d.PresetCurve=nt;function tt(mt,vt){Object.defineProperty(d,mt,{configurable:!0,enumerable:!0,get:function(){var $t=new nt(vt);return Object.defineProperty(d,mt,{configurable:!0,enumerable:!0,value:$t}),$t}})}tt("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:hash$6.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),tt("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:hash$6.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),tt("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:hash$6.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),tt("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:hash$6.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),tt("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:hash$6.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),tt("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:hash$6.sha256,gRed:!1,g:["9"]}),tt("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:hash$6.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var bt;try{bt=null.crash()}catch{bt=void 0}tt("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:hash$6.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",bt]})});function HmacDRBG(c){if(!(this instanceof HmacDRBG))return new HmacDRBG(c);this.hash=c.hash,this.predResist=!!c.predResist,this.outLen=this.hash.outSize,this.minEntropy=c.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var a=utils_1.toArray(c.entropy,c.entropyEnc||"hex"),d=utils_1.toArray(c.nonce,c.nonceEnc||"hex"),et=utils_1.toArray(c.pers,c.persEnc||"hex");minimalisticAssert(a.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(a,d,et)}var hmacDrbg=HmacDRBG;HmacDRBG.prototype._init=function c(a,d,et){var nt=a.concat(d).concat(et);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var tt=0;tt=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(a.concat(et||[])),this._reseed=1};HmacDRBG.prototype.generate=function c(a,d,et,nt){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof d!="string"&&(nt=et,et=d,d=null),et&&(et=utils_1.toArray(et,nt||"hex"),this._update(et));for(var tt=[];tt.length"};var assert$4=utils_1$1.assert;function Signature(c,a){if(c instanceof Signature)return c;this._importDER(c,a)||(assert$4(c.r&&c.s,"Signature without r or s"),this.r=new BN$j(c.r,16),this.s=new BN$j(c.s,16),c.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=c.recoveryParam)}var signature=Signature;function Position(){this.place=0}function getLength(c,a){var d=c[a.place++];if(!(d&128))return d;var et=d&15;if(et===0||et>4)return!1;for(var nt=0,tt=0,bt=a.place;tt>>=0;return nt<=127?!1:(a.place=bt,nt)}function rmPadding(c){for(var a=0,d=c.length-1;!c[a]&&!(c[a+1]&128)&&a>>3);for(c.push(d|128);--d;)c.push(a>>>(d<<3)&255);c.push(a)}Signature.prototype.toDER=function c(a){var d=this.r.toArray(),et=this.s.toArray();for(d[0]&128&&(d=[0].concat(d)),et[0]&128&&(et=[0].concat(et)),d=rmPadding(d),et=rmPadding(et);!et[0]&&!(et[1]&128);)et=et.slice(1);var nt=[2];constructLength(nt,d.length),nt=nt.concat(d),nt.push(2),constructLength(nt,et.length);var tt=nt.concat(et),bt=[48];return constructLength(bt,tt.length),bt=bt.concat(tt),utils_1$1.encode(bt,a)};var rand=function(){throw new Error("unsupported")},assert$5=utils_1$1.assert;function EC(c){if(!(this instanceof EC))return new EC(c);typeof c=="string"&&(assert$5(Object.prototype.hasOwnProperty.call(curves_1,c),"Unknown curve "+c),c=curves_1[c]),c instanceof curves_1.PresetCurve&&(c={curve:c}),this.curve=c.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=c.curve.g,this.g.precompute(c.curve.n.bitLength()+1),this.hash=c.hash||c.curve.hash}var ec=EC;EC.prototype.keyPair=function c(a){return new key(this,a)};EC.prototype.keyFromPrivate=function c(a,d){return key.fromPrivate(this,a,d)};EC.prototype.keyFromPublic=function c(a,d){return key.fromPublic(this,a,d)};EC.prototype.genKeyPair=function c(a){a||(a={});for(var d=new hmacDrbg({hash:this.hash,pers:a.pers,persEnc:a.persEnc||"utf8",entropy:a.entropy||rand(this.hash.hmacStrength),entropyEnc:a.entropy&&a.entropyEnc||"utf8",nonce:this.n.toArray()}),et=this.n.byteLength(),nt=this.n.sub(new BN$j(2));;){var tt=new BN$j(d.generate(et));if(!(tt.cmp(nt)>0))return tt.iaddn(1),this.keyFromPrivate(tt)}};EC.prototype._truncateToN=function c(a,d){var et=a.byteLength()*8-this.n.bitLength();return et>0&&(a=a.ushrn(et)),!d&&a.cmp(this.n)>=0?a.sub(this.n):a};EC.prototype.sign=function c(a,d,et,nt){typeof et=="object"&&(nt=et,et=null),nt||(nt={}),d=this.keyFromPrivate(d,et),a=this._truncateToN(new BN$j(a,16));for(var tt=this.n.byteLength(),bt=d.getPrivate().toArray("be",tt),mt=a.toArray("be",tt),vt=new hmacDrbg({hash:this.hash,entropy:bt,nonce:mt,pers:nt.pers,persEnc:nt.persEnc||"utf8"}),$t=this.n.sub(new BN$j(1)),At=0;;At++){var Mt=nt.k?nt.k(At):new BN$j(vt.generate(this.n.byteLength()));if(Mt=this._truncateToN(Mt,!0),!(Mt.cmpn(1)<=0||Mt.cmp($t)>=0)){var Tt=this.g.mul(Mt);if(!Tt.isInfinity()){var Rt=Tt.getX(),kt=Rt.umod(this.n);if(kt.cmpn(0)!==0){var It=Mt.invm(this.n).mul(kt.mul(d.getPrivate()).iadd(a));if(It=It.umod(this.n),It.cmpn(0)!==0){var Dt=(Tt.getY().isOdd()?1:0)|(Rt.cmp(kt)!==0?2:0);return nt.canonical&&It.cmp(this.nh)>0&&(It=this.n.sub(It),Dt^=1),new signature({r:kt,s:It,recoveryParam:Dt})}}}}}};EC.prototype.verify=function c(a,d,et,nt){a=this._truncateToN(new BN$j(a,16)),et=this.keyFromPublic(et,nt),d=new signature(d,"hex");var tt=d.r,bt=d.s;if(tt.cmpn(1)<0||tt.cmp(this.n)>=0||bt.cmpn(1)<0||bt.cmp(this.n)>=0)return!1;var mt=bt.invm(this.n),vt=mt.mul(a).umod(this.n),$t=mt.mul(tt).umod(this.n),At;return this.curve._maxwellTrick?(At=this.g.jmulAdd(vt,et.getPublic(),$t),At.isInfinity()?!1:At.eqXToP(tt)):(At=this.g.mulAdd(vt,et.getPublic(),$t),At.isInfinity()?!1:At.getX().umod(this.n).cmp(tt)===0)};EC.prototype.recoverPubKey=function(c,a,d,et){assert$5((3&d)===d,"The recovery param is more than two bits"),a=new signature(a,et);var nt=this.n,tt=new BN$j(c),bt=a.r,mt=a.s,vt=d&1,$t=d>>1;if(bt.cmp(this.curve.p.umod(this.curve.n))>=0&&$t)throw new Error("Unable to find sencond key candinate");$t?bt=this.curve.pointFromX(bt.add(this.curve.n),vt):bt=this.curve.pointFromX(bt,vt);var At=a.r.invm(nt),Mt=nt.sub(tt).mul(At).umod(nt),Tt=mt.mul(At).umod(nt);return this.g.mulAdd(Mt,bt,Tt)};EC.prototype.getKeyRecoveryParam=function(c,a,d,et){if(a=new signature(a,et),a.recoveryParam!==null)return a.recoveryParam;for(var nt=0;nt<4;nt++){var tt;try{tt=this.recoverPubKey(c,a,nt)}catch{continue}if(tt.eq(d))return nt}throw new Error("Unable to find valid recovery factor")};var elliptic_1=createCommonjsModule(function(c,a){var d=a;d.version="6.5.4",d.utils=utils_1$1,d.rand=function(){throw new Error("unsupported")},d.curve=curve_1,d.curves=curves_1,d.ec=ec,d.eddsa=null}),EC$1=elliptic_1.ec;const version$8="signing-key/5.7.0",logger$8=new Logger(version$8);let _curve=null;function getCurve(){return _curve||(_curve=new EC$1("secp256k1")),_curve}class SigningKey{constructor(a){defineReadOnly(this,"curve","secp256k1"),defineReadOnly(this,"privateKey",hexlify(a)),hexDataLength(this.privateKey)!==32&&logger$8.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const d=getCurve().keyFromPrivate(arrayify(this.privateKey));defineReadOnly(this,"publicKey","0x"+d.getPublic(!1,"hex")),defineReadOnly(this,"compressedPublicKey","0x"+d.getPublic(!0,"hex")),defineReadOnly(this,"_isSigningKey",!0)}_addPoint(a){const d=getCurve().keyFromPublic(arrayify(this.publicKey)),et=getCurve().keyFromPublic(arrayify(a));return"0x"+d.pub.add(et.pub).encodeCompressed("hex")}signDigest(a){const d=getCurve().keyFromPrivate(arrayify(this.privateKey)),et=arrayify(a);et.length!==32&&logger$8.throwArgumentError("bad digest length","digest",a);const nt=d.sign(et,{canonical:!0});return splitSignature({recoveryParam:nt.recoveryParam,r:hexZeroPad("0x"+nt.r.toString(16),32),s:hexZeroPad("0x"+nt.s.toString(16),32)})}computeSharedSecret(a){const d=getCurve().keyFromPrivate(arrayify(this.privateKey)),et=getCurve().keyFromPublic(arrayify(computePublicKey(a)));return hexZeroPad("0x"+d.derive(et.getPublic()).toString(16),32)}static isSigningKey(a){return!!(a&&a._isSigningKey)}}function computePublicKey(c,a){const d=arrayify(c);if(d.length===32){const et=new SigningKey(d);return a?"0x"+getCurve().keyFromPrivate(d).getPublic(!0,"hex"):et.publicKey}else{if(d.length===33)return a?hexlify(d):"0x"+getCurve().keyFromPublic(d).getPublic(!1,"hex");if(d.length===65)return a?"0x"+getCurve().keyFromPublic(d).getPublic(!0,"hex"):hexlify(d)}return logger$8.throwArgumentError("invalid public or private key","key","[REDACTED]")}const version$7="transactions/5.7.0",logger$7=new Logger(version$7);var TransactionTypes;(function(c){c[c.legacy=0]="legacy",c[c.eip2930=1]="eip2930",c[c.eip1559=2]="eip1559"})(TransactionTypes||(TransactionTypes={}));const transactionFields=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],allowedTransactionKeys={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function computeAddress(c){const a=computePublicKey(c);return getAddress$1(hexDataSlice(keccak256$1(hexDataSlice(a,1)),12))}function formatNumber(c,a){const d=stripZeros(BigNumber.from(c).toHexString());return d.length>32&&logger$7.throwArgumentError("invalid length for "+a,"transaction:"+a,c),d}function accessSetify(c,a){return{address:getAddress$1(c),storageKeys:(a||[]).map((d,et)=>(hexDataLength(d)!==32&&logger$7.throwArgumentError("invalid access list storageKey",`accessList[${c}:${et}]`,d),d.toLowerCase()))}}function accessListify(c){if(Array.isArray(c))return c.map((d,et)=>Array.isArray(d)?(d.length>2&&logger$7.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${et}]`,d),accessSetify(d[0],d[1])):accessSetify(d.address,d.storageKeys));const a=Object.keys(c).map(d=>{const et=c[d].reduce((nt,tt)=>(nt[tt]=!0,nt),{});return accessSetify(d,Object.keys(et).sort())});return a.sort((d,et)=>d.address.localeCompare(et.address)),a}function formatAccessList(c){return accessListify(c).map(a=>[a.address,a.storageKeys])}function _serializeEip1559(c,a){if(c.gasPrice!=null){const et=BigNumber.from(c.gasPrice),nt=BigNumber.from(c.maxFeePerGas||0);et.eq(nt)||logger$7.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:et,maxFeePerGas:nt})}const d=[formatNumber(c.chainId||0,"chainId"),formatNumber(c.nonce||0,"nonce"),formatNumber(c.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),formatNumber(c.maxFeePerGas||0,"maxFeePerGas"),formatNumber(c.gasLimit||0,"gasLimit"),c.to!=null?getAddress$1(c.to):"0x",formatNumber(c.value||0,"value"),c.data||"0x",formatAccessList(c.accessList||[])];if(a){const et=splitSignature(a);d.push(formatNumber(et.recoveryParam,"recoveryParam")),d.push(stripZeros(et.r)),d.push(stripZeros(et.s))}return hexConcat(["0x02",encode$1(d)])}function _serializeEip2930(c,a){const d=[formatNumber(c.chainId||0,"chainId"),formatNumber(c.nonce||0,"nonce"),formatNumber(c.gasPrice||0,"gasPrice"),formatNumber(c.gasLimit||0,"gasLimit"),c.to!=null?getAddress$1(c.to):"0x",formatNumber(c.value||0,"value"),c.data||"0x",formatAccessList(c.accessList||[])];if(a){const et=splitSignature(a);d.push(formatNumber(et.recoveryParam,"recoveryParam")),d.push(stripZeros(et.r)),d.push(stripZeros(et.s))}return hexConcat(["0x01",encode$1(d)])}function _serialize(c,a){checkProperties(c,allowedTransactionKeys);const d=[];transactionFields.forEach(function(bt){let mt=c[bt.name]||[];const vt={};bt.numeric&&(vt.hexPad="left"),mt=arrayify(hexlify(mt,vt)),bt.length&&mt.length!==bt.length&&mt.length>0&&logger$7.throwArgumentError("invalid length for "+bt.name,"transaction:"+bt.name,mt),bt.maxLength&&(mt=stripZeros(mt),mt.length>bt.maxLength&&logger$7.throwArgumentError("invalid length for "+bt.name,"transaction:"+bt.name,mt)),d.push(hexlify(mt))});let et=0;if(c.chainId!=null?(et=c.chainId,typeof et!="number"&&logger$7.throwArgumentError("invalid transaction.chainId","transaction",c)):a&&!isBytesLike(a)&&a.v>28&&(et=Math.floor((a.v-35)/2)),et!==0&&(d.push(hexlify(et)),d.push("0x"),d.push("0x")),!a)return encode$1(d);const nt=splitSignature(a);let tt=27+nt.recoveryParam;return et!==0?(d.pop(),d.pop(),d.pop(),tt+=et*2+8,nt.v>28&&nt.v!==tt&&logger$7.throwArgumentError("transaction.chainId/signature.v mismatch","signature",a)):nt.v!==tt&&logger$7.throwArgumentError("transaction.chainId/signature.v mismatch","signature",a),d.push(hexlify(tt)),d.push(stripZeros(arrayify(nt.r))),d.push(stripZeros(arrayify(nt.s))),encode$1(d)}function serialize(c,a){if(c.type==null||c.type===0)return c.accessList!=null&&logger$7.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",c),_serialize(c,a);switch(c.type){case 1:return _serializeEip2930(c,a);case 2:return _serializeEip1559(c,a)}return logger$7.throwError(`unsupported transaction type: ${c.type}`,Logger.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:c.type})}class BaseX{constructor(a){defineReadOnly(this,"alphabet",a),defineReadOnly(this,"base",a.length),defineReadOnly(this,"_alphabetMap",{}),defineReadOnly(this,"_leader",a.charAt(0));for(let d=0;d0;)et.push(bt%this.base),bt=bt/this.base|0}let nt="";for(let tt=0;d[tt]===0&&tt=0;--tt)nt+=this.alphabet[et[tt]];return nt}decode(a){if(typeof a!="string")throw new TypeError("Expected String");let d=[];if(a.length===0)return new Uint8Array(d);d.push(0);for(let et=0;et>=8;for(;tt>0;)d.push(tt&255),tt>>=8}for(let et=0;a[et]===this._leader&&et>24&255,vt[a.length+1]=Mt>>16&255,vt[a.length+2]=Mt>>8&255,vt[a.length+3]=Mt&255;let Tt=arrayify(computeHmac(nt,c,vt));tt||(tt=Tt.length,At=new Uint8Array(tt),bt=Math.ceil(et/tt),$t=et-(bt-1)*tt),At.set(Tt);for(let It=1;It=256)throw new Error("Depth too large!");return base58check(concat$1([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",hexlify(this.depth),this.parentFingerprint,hexZeroPad(hexlify(this.index),4),this.chainCode,this.privateKey!=null?concat$1(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new HDNode(_constructorGuard,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(a){if(a>4294967295)throw new Error("invalid index - "+String(a));let d=this.path;d&&(d+="/"+(a&~HardenedBit));const et=new Uint8Array(37);if(a&HardenedBit){if(!this.privateKey)throw new Error("cannot derive child of neutered node");et.set(arrayify(this.privateKey),1),d&&(d+="'")}else et.set(arrayify(this.publicKey));for(let Mt=24;Mt>=0;Mt-=8)et[33+(Mt>>3)]=a>>24-Mt&255;const nt=arrayify(computeHmac(SupportedAlgorithm.sha512,this.chainCode,et)),tt=nt.slice(0,32),bt=nt.slice(32);let mt=null,vt=null;this.privateKey?mt=bytes32(BigNumber.from(tt).add(this.privateKey).mod(N)):vt=new SigningKey(hexlify(tt))._addPoint(this.publicKey);let $t=d;const At=this.mnemonic;return At&&($t=Object.freeze({phrase:At.phrase,path:d,locale:At.locale||"en"})),new HDNode(_constructorGuard,mt,vt,this.fingerprint,bytes32(bt),a,this.depth+1,$t)}derivePath(a){const d=a.split("/");if(d.length===0||d[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+a);d[0]==="m"&&d.shift();let et=this;for(let nt=0;nt=HardenedBit)throw new Error("invalid path index - "+tt);et=et._derive(HardenedBit+bt)}else if(tt.match(/^[0-9]+$/)){const bt=parseInt(tt);if(bt>=HardenedBit)throw new Error("invalid path index - "+tt);et=et._derive(bt)}else throw new Error("invalid path component - "+tt)}return et}static _fromSeed(a,d){const et=arrayify(a);if(et.length<16||et.length>64)throw new Error("invalid seed");const nt=arrayify(computeHmac(SupportedAlgorithm.sha512,MasterSecret,et));return new HDNode(_constructorGuard,bytes32(nt.slice(0,32)),null,"0x00000000",bytes32(nt.slice(32)),0,0,d)}static fromMnemonic(a,d,et){return et=getWordlist(et),a=entropyToMnemonic(mnemonicToEntropy(a,et),et),HDNode._fromSeed(mnemonicToSeed(a,d),{phrase:a,path:"m",locale:et.locale})}static fromSeed(a){return HDNode._fromSeed(a,null)}static fromExtendedKey(a){const d=Base58.decode(a);(d.length!==82||base58check(d.slice(0,78))!==a)&&logger$4.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");const et=d[4],nt=hexlify(d.slice(5,9)),tt=parseInt(hexlify(d.slice(9,13)).substring(2),16),bt=hexlify(d.slice(13,45)),mt=d.slice(45,78);switch(hexlify(d.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new HDNode(_constructorGuard,null,hexlify(mt),nt,bt,tt,et,null);case"0x0488ade4":case"0x04358394 ":if(mt[0]!==0)break;return new HDNode(_constructorGuard,hexlify(mt.slice(1)),null,nt,bt,tt,et,null)}return logger$4.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}function mnemonicToSeed(c,a){a||(a="");const d=toUtf8Bytes("mnemonic"+a,UnicodeNormalizationForm.NFKD);return pbkdf2$1(toUtf8Bytes(c,UnicodeNormalizationForm.NFKD),d,2048,64,"sha512")}function mnemonicToEntropy(c,a){a=getWordlist(a),logger$4.checkNormalize();const d=a.split(c);if(d.length%3!==0)throw new Error("invalid mnemonic");const et=arrayify(new Uint8Array(Math.ceil(11*d.length/8)));let nt=0;for(let $t=0;$t>3]|=1<<7-nt%8),nt++}const tt=32*d.length/3,bt=d.length/3,mt=getUpperMask(bt);if((arrayify(sha256$2(et.slice(0,tt/8)))[0]&mt)!==(et[et.length-1]&mt))throw new Error("invalid checksum");return hexlify(et.slice(0,tt/8))}function entropyToMnemonic(c,a){if(a=getWordlist(a),c=arrayify(c),c.length%4!==0||c.length<16||c.length>32)throw new Error("invalid entropy");const d=[0];let et=11;for(let bt=0;bt8?(d[d.length-1]<<=8,d[d.length-1]|=c[bt],et-=8):(d[d.length-1]<<=et,d[d.length-1]|=c[bt]>>8-et,d.push(c[bt]&getLowerMask(8-et)),et+=3);const nt=c.length/4,tt=arrayify(sha256$2(c))[0]&getUpperMask(nt);return d[d.length-1]<<=nt,d[d.length-1]|=tt>>8-nt,a.join(d.map(bt=>a.getWord(bt)))}const version$3="random/5.7.0",logger$3=new Logger(version$3);function getGlobal(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof dist$2.global<"u")return dist$2.global;throw new Error("unable to locate global object")}const anyGlobal=getGlobal();let crypto=anyGlobal.crypto||anyGlobal.msCrypto;(!crypto||!crypto.getRandomValues)&&(logger$3.warn("WARNING: Missing strong random number source"),crypto={getRandomValues:function(c){return logger$3.throwError("no secure random source avaialble",Logger.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function randomBytes(c){(c<=0||c>1024||c%1||c!=c)&&logger$3.throwArgumentError("invalid length","length",c);const a=new Uint8Array(c);return crypto.getRandomValues(a),arrayify(a)}var aesJs={exports:{}};(function(c,a){(function(d){function et(wt){return parseInt(wt)===wt}function nt(wt){if(!et(wt.length))return!1;for(var Bt=0;Bt255)return!1;return!0}function tt(wt,Bt){if(wt.buffer&&ArrayBuffer.isView(wt)&&wt.name==="Uint8Array")return Bt&&(wt.slice?wt=wt.slice():wt=Array.prototype.slice.call(wt)),wt;if(Array.isArray(wt)){if(!nt(wt))throw new Error("Array contains invalid value: "+wt);return new Uint8Array(wt)}if(et(wt.length)&&nt(wt))return new Uint8Array(wt);throw new Error("unsupported array-like object")}function bt(wt){return new Uint8Array(wt)}function mt(wt,Bt,Lt,jt,Ft){(jt!=null||Ft!=null)&&(wt.slice?wt=wt.slice(jt,Ft):wt=Array.prototype.slice.call(wt,jt,Ft)),Bt.set(wt,Lt)}var vt=function(){function wt(Lt){var jt=[],Ft=0;for(Lt=encodeURI(Lt);Ft191&&Vt<224?(jt.push(String.fromCharCode((Vt&31)<<6|Lt[Ft+1]&63)),Ft+=2):(jt.push(String.fromCharCode((Vt&15)<<12|(Lt[Ft+1]&63)<<6|Lt[Ft+2]&63)),Ft+=3)}return jt.join("")}return{toBytes:wt,fromBytes:Bt}}(),$t=function(){function wt(jt){for(var Ft=[],Vt=0;Vt>4]+Bt[zt&15])}return Ft.join("")}return{toBytes:wt,fromBytes:Lt}}(),At={16:10,24:12,32:14},Mt=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],Tt=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],Rt=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],kt=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],It=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],Dt=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],Nt=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],Ot=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],Ut=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],Gt=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],Wt=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],Xt=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],a0=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],n0=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],t0=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function c0(wt){for(var Bt=[],Lt=0;Lt>2,this._Ke[Vt][Bt%4]=Ft[Bt],this._Kd[wt-Vt][Bt%4]=Ft[Bt];for(var zt=0,qt=jt,Kt;qt>16&255]<<24^Tt[Kt>>8&255]<<16^Tt[Kt&255]<<8^Tt[Kt>>24&255]^Mt[zt]<<24,zt+=1,jt!=8)for(var Bt=1;Bt>8&255]<<8^Tt[Kt>>16&255]<<16^Tt[Kt>>24&255]<<24;for(var Bt=jt/2+1;Bt>2,Zt=qt%4,this._Ke[e0][Zt]=Ft[Bt],this._Kd[wt-e0][Zt]=Ft[Bt++],qt++}for(var e0=1;e0>24&255]^a0[Kt>>16&255]^n0[Kt>>8&255]^t0[Kt&255]},Ct.prototype.encrypt=function(wt){if(wt.length!=16)throw new Error("invalid plaintext size (must be 16 bytes)");for(var Bt=this._Ke.length-1,Lt=[0,0,0,0],jt=c0(wt),Ft=0;Ft<4;Ft++)jt[Ft]^=this._Ke[0][Ft];for(var Vt=1;Vt>24&255]^It[jt[(Ft+1)%4]>>16&255]^Dt[jt[(Ft+2)%4]>>8&255]^Nt[jt[(Ft+3)%4]&255]^this._Ke[Vt][Ft];jt=Lt.slice()}for(var zt=bt(16),qt,Ft=0;Ft<4;Ft++)qt=this._Ke[Bt][Ft],zt[4*Ft]=(Tt[jt[Ft]>>24&255]^qt>>24)&255,zt[4*Ft+1]=(Tt[jt[(Ft+1)%4]>>16&255]^qt>>16)&255,zt[4*Ft+2]=(Tt[jt[(Ft+2)%4]>>8&255]^qt>>8)&255,zt[4*Ft+3]=(Tt[jt[(Ft+3)%4]&255]^qt)&255;return zt},Ct.prototype.decrypt=function(wt){if(wt.length!=16)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var Bt=this._Kd.length-1,Lt=[0,0,0,0],jt=c0(wt),Ft=0;Ft<4;Ft++)jt[Ft]^=this._Kd[0][Ft];for(var Vt=1;Vt>24&255]^Ut[jt[(Ft+3)%4]>>16&255]^Gt[jt[(Ft+2)%4]>>8&255]^Wt[jt[(Ft+1)%4]&255]^this._Kd[Vt][Ft];jt=Lt.slice()}for(var zt=bt(16),qt,Ft=0;Ft<4;Ft++)qt=this._Kd[Bt][Ft],zt[4*Ft]=(Rt[jt[Ft]>>24&255]^qt>>24)&255,zt[4*Ft+1]=(Rt[jt[(Ft+3)%4]>>16&255]^qt>>16)&255,zt[4*Ft+2]=(Rt[jt[(Ft+2)%4]>>8&255]^qt>>8)&255,zt[4*Ft+3]=(Rt[jt[(Ft+1)%4]&255]^qt)&255;return zt};var dt=function(wt){if(!(this instanceof dt))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new Ct(wt)};dt.prototype.encrypt=function(wt){if(wt=tt(wt),wt.length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var Bt=bt(wt.length),Lt=bt(16),jt=0;jt=0;--Bt)this._counter[Bt]=wt%256,wt=wt>>8},St.prototype.setBytes=function(wt){if(wt=tt(wt,!0),wt.length!=16)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=wt},St.prototype.increment=function(){for(var wt=15;wt>=0;wt--)if(this._counter[wt]===255)this._counter[wt]=0;else{this._counter[wt]++;break}};var _t=function(wt,Bt){if(!(this instanceof _t))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",Bt instanceof St||(Bt=new St(Bt)),this._counter=Bt,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new Ct(wt)};_t.prototype.encrypt=function(wt){for(var Bt=tt(wt,!0),Lt=0;Lt16)throw new Error("PKCS#7 padding byte out of range");for(var Lt=wt.length-Bt,jt=0;jt=64;){let ht=Nt,wt=Ot,Bt=Ut,Lt=Gt,jt=Wt,Ft=Xt,Vt=a0,zt=n0,qt,Kt,e0,Zt,Jt;for(Kt=0;Kt<16;Kt++)e0=Pt+Kt*4,t0[Kt]=(_t[e0]&255)<<24|(_t[e0+1]&255)<<16|(_t[e0+2]&255)<<8|_t[e0+3]&255;for(Kt=16;Kt<64;Kt++)qt=t0[Kt-2],Zt=(qt>>>17|qt<<32-17)^(qt>>>19|qt<<32-19)^qt>>>10,qt=t0[Kt-15],Jt=(qt>>>7|qt<<32-7)^(qt>>>18|qt<<32-18)^qt>>>3,t0[Kt]=(Zt+t0[Kt-7]|0)+(Jt+t0[Kt-16]|0)|0;for(Kt=0;Kt<64;Kt++)Zt=(((jt>>>6|jt<<32-6)^(jt>>>11|jt<<32-11)^(jt>>>25|jt<<32-25))+(jt&Ft^~jt&Vt)|0)+(zt+(Dt[Kt]+t0[Kt]|0)|0)|0,Jt=((ht>>>2|ht<<32-2)^(ht>>>13|ht<<32-13)^(ht>>>22|ht<<32-22))+(ht&wt^ht&Bt^wt&Bt)|0,zt=Vt,Vt=Ft,Ft=jt,jt=Lt+Zt|0,Lt=Bt,Bt=wt,wt=ht,ht=Zt+Jt|0;Nt=Nt+ht|0,Ot=Ot+wt|0,Ut=Ut+Bt|0,Gt=Gt+Lt|0,Wt=Wt+jt|0,Xt=Xt+Ft|0,a0=a0+Vt|0,n0=n0+zt|0,Pt+=64,Et-=64}}c0(It);let Ct,dt=It.length%64,yt=It.length/536870912|0,gt=It.length<<3,xt=dt<56?56:120,St=It.slice(It.length-dt,It.length);for(St.push(128),Ct=dt+1;Ct>>24&255),St.push(yt>>>16&255),St.push(yt>>>8&255),St.push(yt>>>0&255),St.push(gt>>>24&255),St.push(gt>>>16&255),St.push(gt>>>8&255),St.push(gt>>>0&255),c0(St),[Nt>>>24&255,Nt>>>16&255,Nt>>>8&255,Nt>>>0&255,Ot>>>24&255,Ot>>>16&255,Ot>>>8&255,Ot>>>0&255,Ut>>>24&255,Ut>>>16&255,Ut>>>8&255,Ut>>>0&255,Gt>>>24&255,Gt>>>16&255,Gt>>>8&255,Gt>>>0&255,Wt>>>24&255,Wt>>>16&255,Wt>>>8&255,Wt>>>0&255,Xt>>>24&255,Xt>>>16&255,Xt>>>8&255,Xt>>>0&255,a0>>>24&255,a0>>>16&255,a0>>>8&255,a0>>>0&255,n0>>>24&255,n0>>>16&255,n0>>>8&255,n0>>>0&255]}function tt(It,Dt,Nt){It=It.length<=64?It:nt(It);const Ot=64+Dt.length+4,Ut=new Array(Ot),Gt=new Array(64);let Wt,Xt=[];for(Wt=0;Wt<64;Wt++)Ut[Wt]=54;for(Wt=0;Wt=Ot-4;n0--){if(Ut[n0]++,Ut[n0]<=255)return;Ut[n0]=0}}for(;Nt>=32;)a0(),Xt=Xt.concat(nt(Gt.concat(nt(Ut)))),Nt-=32;return Nt>0&&(a0(),Xt=Xt.concat(nt(Gt.concat(nt(Ut))).slice(0,Nt))),Xt}function bt(It,Dt,Nt,Ot,Ut){let Gt;for(At(It,(2*Nt-1)*16,Ut,0,16),Gt=0;Gt<2*Nt;Gt++)$t(It,Gt*16,Ut,16),vt(Ut,Ot),At(Ut,0,It,Dt+Gt*16,16);for(Gt=0;Gt>>32-Dt}function vt(It,Dt){At(It,0,Dt,0,16);for(let Nt=8;Nt>0;Nt-=2)Dt[4]^=mt(Dt[0]+Dt[12],7),Dt[8]^=mt(Dt[4]+Dt[0],9),Dt[12]^=mt(Dt[8]+Dt[4],13),Dt[0]^=mt(Dt[12]+Dt[8],18),Dt[9]^=mt(Dt[5]+Dt[1],7),Dt[13]^=mt(Dt[9]+Dt[5],9),Dt[1]^=mt(Dt[13]+Dt[9],13),Dt[5]^=mt(Dt[1]+Dt[13],18),Dt[14]^=mt(Dt[10]+Dt[6],7),Dt[2]^=mt(Dt[14]+Dt[10],9),Dt[6]^=mt(Dt[2]+Dt[14],13),Dt[10]^=mt(Dt[6]+Dt[2],18),Dt[3]^=mt(Dt[15]+Dt[11],7),Dt[7]^=mt(Dt[3]+Dt[15],9),Dt[11]^=mt(Dt[7]+Dt[3],13),Dt[15]^=mt(Dt[11]+Dt[7],18),Dt[1]^=mt(Dt[0]+Dt[3],7),Dt[2]^=mt(Dt[1]+Dt[0],9),Dt[3]^=mt(Dt[2]+Dt[1],13),Dt[0]^=mt(Dt[3]+Dt[2],18),Dt[6]^=mt(Dt[5]+Dt[4],7),Dt[7]^=mt(Dt[6]+Dt[5],9),Dt[4]^=mt(Dt[7]+Dt[6],13),Dt[5]^=mt(Dt[4]+Dt[7],18),Dt[11]^=mt(Dt[10]+Dt[9],7),Dt[8]^=mt(Dt[11]+Dt[10],9),Dt[9]^=mt(Dt[8]+Dt[11],13),Dt[10]^=mt(Dt[9]+Dt[8],18),Dt[12]^=mt(Dt[15]+Dt[14],7),Dt[13]^=mt(Dt[12]+Dt[15],9),Dt[14]^=mt(Dt[13]+Dt[12],13),Dt[15]^=mt(Dt[14]+Dt[13],18);for(let Nt=0;Nt<16;++Nt)It[Nt]+=Dt[Nt]}function $t(It,Dt,Nt,Ot){for(let Ut=0;Ut=256)return!1}return!0}function Tt(It,Dt){if(typeof It!="number"||It%1)throw new Error("invalid "+Dt);return It}function Rt(It,Dt,Nt,Ot,Ut,Gt,Wt){if(Nt=Tt(Nt,"N"),Ot=Tt(Ot,"r"),Ut=Tt(Ut,"p"),Gt=Tt(Gt,"dkLen"),Nt===0||Nt&Nt-1)throw new Error("N must be power of 2");if(Nt>2147483647/128/Ot)throw new Error("N too large");if(Ot>2147483647/128/Ut)throw new Error("r too large");if(!Mt(It))throw new Error("password must be an array or buffer");if(It=Array.prototype.slice.call(It),!Mt(Dt))throw new Error("salt must be an array or buffer");Dt=Array.prototype.slice.call(Dt);let Xt=tt(It,Dt,Ut*128*Ot);const a0=new Uint32Array(Ut*32*Ot);for(let jt=0;jtwt&&(jt=wt);for(let Vt=0;Vtwt&&(jt=wt);for(let Vt=0;Vt>0&255),Xt.push(a0[Vt]>>8&255),Xt.push(a0[Vt]>>16&255),Xt.push(a0[Vt]>>24&255);const Ft=tt(It,Xt,Gt);return Wt&&Wt(null,1,Ft),Ft}Wt&&Bt(Lt)};if(!Wt)for(;;){const jt=Lt();if(jt!=null)return jt}Lt()}const kt={scrypt:function(It,Dt,Nt,Ot,Ut,Gt,Wt){return new Promise(function(Xt,a0){let n0=0;Wt&&Wt(0),Rt(It,Dt,Nt,Ot,Ut,Gt,function(t0,c0,Ct){if(t0)a0(t0);else if(Ct)Wt&&n0!==1&&Wt(1),Xt(new Uint8Array(Ct));else if(Wt&&c0!==n0)return n0=c0,Wt(c0)})})},syncScrypt:function(It,Dt,Nt,Ot,Ut,Gt){return new Uint8Array(Rt(It,Dt,Nt,Ot,Ut,Gt))}};c.exports=kt})()})(scrypt$1);var scryptExports=scrypt$1.exports;const scrypt=getDefaultExportFromCjs(scryptExports);var __awaiter$1=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger$1=new Logger(version$2);function hasMnemonic$1(c){return c!=null&&c.mnemonic&&c.mnemonic.phrase}class KeystoreAccount extends Description{isKeystoreAccount(a){return!!(a&&a._isKeystoreAccount)}}function _decrypt(c,a,d){if(searchPath(c,"crypto/cipher")==="aes-128-ctr"){const nt=looseArrayify(searchPath(c,"crypto/cipherparams/iv")),tt=new aes.Counter(nt),bt=new aes.ModeOfOperation.ctr(a,tt);return arrayify(bt.decrypt(d))}return null}function _getAccount(c,a){const d=looseArrayify(searchPath(c,"crypto/ciphertext"));if(hexlify(keccak256$1(concat$1([a.slice(16,32),d]))).substring(2)!==searchPath(c,"crypto/mac").toLowerCase())throw new Error("invalid password");const nt=_decrypt(c,a.slice(0,16),d);nt||logger$1.throwError("unsupported cipher",Logger.errors.UNSUPPORTED_OPERATION,{operation:"decrypt"});const tt=a.slice(32,64),bt=computeAddress(nt);if(c.address){let vt=c.address.toLowerCase();if(vt.substring(0,2)!=="0x"&&(vt="0x"+vt),getAddress$1(vt)!==bt)throw new Error("address mismatch")}const mt={_isKeystoreAccount:!0,address:bt,privateKey:hexlify(nt)};if(searchPath(c,"x-ethers/version")==="0.1"){const vt=looseArrayify(searchPath(c,"x-ethers/mnemonicCiphertext")),$t=looseArrayify(searchPath(c,"x-ethers/mnemonicCounter")),At=new aes.Counter($t),Mt=new aes.ModeOfOperation.ctr(tt,At),Tt=searchPath(c,"x-ethers/path")||defaultPath,Rt=searchPath(c,"x-ethers/locale")||"en",kt=arrayify(Mt.decrypt(vt));try{const It=entropyToMnemonic(kt,Rt),Dt=HDNode.fromMnemonic(It,null,Rt).derivePath(Tt);if(Dt.privateKey!=mt.privateKey)throw new Error("mnemonic mismatch");mt.mnemonic=Dt.mnemonic}catch(It){if(It.code!==Logger.errors.INVALID_ARGUMENT||It.argument!=="wordlist")throw It}}return new KeystoreAccount(mt)}function pbkdf2Sync(c,a,d,et,nt){return arrayify(pbkdf2$1(c,a,d,et,nt))}function pbkdf2(c,a,d,et,nt){return Promise.resolve(pbkdf2Sync(c,a,d,et,nt))}function _computeKdfKey(c,a,d,et,nt){const tt=getPassword(a),bt=searchPath(c,"crypto/kdf");if(bt&&typeof bt=="string"){const mt=function(vt,$t){return logger$1.throwArgumentError("invalid key-derivation function parameters",vt,$t)};if(bt.toLowerCase()==="scrypt"){const vt=looseArrayify(searchPath(c,"crypto/kdfparams/salt")),$t=parseInt(searchPath(c,"crypto/kdfparams/n")),At=parseInt(searchPath(c,"crypto/kdfparams/r")),Mt=parseInt(searchPath(c,"crypto/kdfparams/p"));(!$t||!At||!Mt)&&mt("kdf",bt),$t&$t-1&&mt("N",$t);const Tt=parseInt(searchPath(c,"crypto/kdfparams/dklen"));return Tt!==32&&mt("dklen",Tt),et(tt,vt,$t,At,Mt,64,nt)}else if(bt.toLowerCase()==="pbkdf2"){const vt=looseArrayify(searchPath(c,"crypto/kdfparams/salt"));let $t=null;const At=searchPath(c,"crypto/kdfparams/prf");At==="hmac-sha256"?$t="sha256":At==="hmac-sha512"?$t="sha512":mt("prf",At);const Mt=parseInt(searchPath(c,"crypto/kdfparams/c")),Tt=parseInt(searchPath(c,"crypto/kdfparams/dklen"));return Tt!==32&&mt("dklen",Tt),d(tt,vt,Mt,Tt,$t)}}return logger$1.throwArgumentError("unsupported key-derivation function","kdf",bt)}function decryptSync(c,a){const d=JSON.parse(c),et=_computeKdfKey(d,a,pbkdf2Sync,scrypt.syncScrypt);return _getAccount(d,et)}function decrypt(c,a,d){return __awaiter$1(this,void 0,void 0,function*(){const et=JSON.parse(c),nt=yield _computeKdfKey(et,a,pbkdf2,scrypt.scrypt,d);return _getAccount(et,nt)})}function encrypt(c,a,d,et){try{if(getAddress$1(c.address)!==computeAddress(c.privateKey))throw new Error("address/privateKey mismatch");if(hasMnemonic$1(c)){const Dt=c.mnemonic;if(HDNode.fromMnemonic(Dt.phrase,null,Dt.locale).derivePath(Dt.path||defaultPath).privateKey!=c.privateKey)throw new Error("mnemonic mismatch")}}catch(Dt){return Promise.reject(Dt)}typeof d=="function"&&!et&&(et=d,d={}),d||(d={});const nt=arrayify(c.privateKey),tt=getPassword(a);let bt=null,mt=null,vt=null;if(hasMnemonic$1(c)){const Dt=c.mnemonic;bt=arrayify(mnemonicToEntropy(Dt.phrase,Dt.locale||"en")),mt=Dt.path||defaultPath,vt=Dt.locale||"en"}let $t=d.client;$t||($t="ethers.js");let At=null;d.salt?At=arrayify(d.salt):At=randomBytes(32);let Mt=null;if(d.iv){if(Mt=arrayify(d.iv),Mt.length!==16)throw new Error("invalid iv")}else Mt=randomBytes(16);let Tt=null;if(d.uuid){if(Tt=arrayify(d.uuid),Tt.length!==16)throw new Error("invalid uuid")}else Tt=randomBytes(16);let Rt=1<<17,kt=8,It=1;return d.scrypt&&(d.scrypt.N&&(Rt=d.scrypt.N),d.scrypt.r&&(kt=d.scrypt.r),d.scrypt.p&&(It=d.scrypt.p)),scrypt.scrypt(tt,At,Rt,kt,It,64,et).then(Dt=>{Dt=arrayify(Dt);const Nt=Dt.slice(0,16),Ot=Dt.slice(16,32),Ut=Dt.slice(32,64),Gt=new aes.Counter(Mt),Wt=new aes.ModeOfOperation.ctr(Nt,Gt),Xt=arrayify(Wt.encrypt(nt)),a0=keccak256$1(concat$1([Ot,Xt])),n0={address:c.address.substring(2).toLowerCase(),id:uuidV4(Tt),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:hexlify(Mt).substring(2)},ciphertext:hexlify(Xt).substring(2),kdf:"scrypt",kdfparams:{salt:hexlify(At).substring(2),n:Rt,dklen:32,p:It,r:kt},mac:a0.substring(2)}};if(bt){const t0=randomBytes(16),c0=new aes.Counter(t0),Ct=new aes.ModeOfOperation.ctr(Ut,c0),dt=arrayify(Ct.encrypt(bt)),yt=new Date,gt=yt.getUTCFullYear()+"-"+zpad(yt.getUTCMonth()+1,2)+"-"+zpad(yt.getUTCDate(),2)+"T"+zpad(yt.getUTCHours(),2)+"-"+zpad(yt.getUTCMinutes(),2)+"-"+zpad(yt.getUTCSeconds(),2)+".0Z";n0["x-ethers"]={client:$t,gethFilename:"UTC--"+gt+"--"+n0.address,mnemonicCounter:hexlify(t0).substring(2),mnemonicCiphertext:hexlify(dt).substring(2),path:mt,locale:vt,version:"0.1"}}return JSON.stringify(n0)})}function decryptJsonWallet(c,a,d){if(isCrowdsaleWallet(c)){d&&d(0);const et=decrypt$1(c,a);return d&&d(1),Promise.resolve(et)}return isKeystoreWallet(c)?decrypt(c,a,d):Promise.reject(new Error("invalid JSON wallet"))}function decryptJsonWalletSync(c,a){if(isCrowdsaleWallet(c))return decrypt$1(c,a);if(isKeystoreWallet(c))return decryptSync(c,a);throw new Error("invalid JSON wallet")}const version$1="wallet/5.7.0";var __awaiter=globalThis&&globalThis.__awaiter||function(c,a,d,et){function nt(tt){return tt instanceof d?tt:new d(function(bt){bt(tt)})}return new(d||(d=Promise))(function(tt,bt){function mt(At){try{$t(et.next(At))}catch(Mt){bt(Mt)}}function vt(At){try{$t(et.throw(At))}catch(Mt){bt(Mt)}}function $t(At){At.done?tt(At.value):nt(At.value).then(mt,vt)}$t((et=et.apply(c,a||[])).next())})};const logger=new Logger(version$1);function isAccount(c){return c!=null&&isHexString(c.privateKey,32)&&c.address!=null}function hasMnemonic(c){const a=c.mnemonic;return a&&a.phrase}class Wallet extends Signer{constructor(a,d){if(super(),isAccount(a)){const et=new SigningKey(a.privateKey);if(defineReadOnly(this,"_signingKey",()=>et),defineReadOnly(this,"address",computeAddress(this.publicKey)),this.address!==getAddress$1(a.address)&&logger.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),hasMnemonic(a)){const nt=a.mnemonic;defineReadOnly(this,"_mnemonic",()=>({phrase:nt.phrase,path:nt.path||defaultPath,locale:nt.locale||"en"}));const tt=this.mnemonic,bt=HDNode.fromMnemonic(tt.phrase,null,tt.locale).derivePath(tt.path);computeAddress(bt.privateKey)!==this.address&&logger.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else defineReadOnly(this,"_mnemonic",()=>null)}else{if(SigningKey.isSigningKey(a))a.curve!=="secp256k1"&&logger.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),defineReadOnly(this,"_signingKey",()=>a);else{typeof a=="string"&&a.match(/^[0-9a-f]*$/i)&&a.length===64&&(a="0x"+a);const et=new SigningKey(a);defineReadOnly(this,"_signingKey",()=>et)}defineReadOnly(this,"_mnemonic",()=>null),defineReadOnly(this,"address",computeAddress(this.publicKey))}d&&!Provider.isProvider(d)&&logger.throwArgumentError("invalid provider","provider",d),defineReadOnly(this,"provider",d||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(a){return new Wallet(this,a)}signTransaction(a){return resolveProperties(a).then(d=>{d.from!=null&&(getAddress$1(d.from)!==this.address&&logger.throwArgumentError("transaction from address mismatch","transaction.from",a.from),delete d.from);const et=this._signingKey().signDigest(keccak256$1(serialize(d)));return serialize(d,et)})}signMessage(a){return __awaiter(this,void 0,void 0,function*(){return joinSignature(this._signingKey().signDigest(hashMessage$1(a)))})}_signTypedData(a,d,et){return __awaiter(this,void 0,void 0,function*(){const nt=yield TypedDataEncoder.resolveNames(a,d,et,tt=>(this.provider==null&&logger.throwError("cannot resolve ENS names without a provider",Logger.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:tt}),this.provider.resolveName(tt)));return joinSignature(this._signingKey().signDigest(TypedDataEncoder.hash(nt.domain,d,nt.value)))})}encrypt(a,d,et){if(typeof d=="function"&&!et&&(et=d,d={}),et&&typeof et!="function")throw new Error("invalid callback");return d||(d={}),encrypt(this,a,d,et)}static createRandom(a){let d=randomBytes(16);a||(a={}),a.extraEntropy&&(d=arrayify(hexDataSlice(keccak256$1(concat$1([d,a.extraEntropy])),0,16)));const et=entropyToMnemonic(d,a.locale);return Wallet.fromMnemonic(et,a.path,a.locale)}static fromEncryptedJson(a,d,et){return decryptJsonWallet(a,d,et).then(nt=>new Wallet(nt))}static fromEncryptedJsonSync(a,d){return new Wallet(decryptJsonWalletSync(a,d))}static fromMnemonic(a,d,et){return d||(d=defaultPath),new Wallet(HDNode.fromMnemonic(a,null,et).derivePath(d))}}const SAFE_ABI=["function isModuleEnabled(address module) public view returns (bool)","function nonce() public view returns (uint256)","function enableModule(address module) public","function isModuleInstalled(uint256 moduleType, address module, bytes calldata additionalContext) public view returns (bool)","function setFallbackHandler(address module) public","function setGuard(address module) public","function execTransaction(address to,uint256 value,bytes calldata data,uint8 operation,uint256 safeTxGas,uint256 baseGas,uint256 gasPrice,address gasToken,address payable refundReceiver,bytes memory signatures) public payable returns (bool success)"],getSafe=async c=>{const a=await getProvider();return new Contract(c,SAFE_ABI,a)},isModuleEnabled=async(c,a)=>await(await getSafe(c)).isModuleEnabled(a),isModuleInstalled=async(c,a,d)=>await(await getSafe(c)).isModuleInstalled(d,a,"0x"),buildEnableModule=async(c,a)=>{const d=await getSafe(c);return{to:c,value:"0",data:(await d.enableModule.populateTransaction(a)).data}},buildUpdateFallbackHandler=async(c,a)=>{const d=await getSafe(c);return{to:c,value:"0",data:(await d.setFallbackHandler.populateTransaction(a)).data}},_format$1="hh-sol-artifact-1",contractName$1="Safe7579",sourceName$1="contracts/Safe7579.sol",abi$3=[{inputs:[],name:"AccountAccessUnauthorized",type:"error"},{inputs:[],name:"AccountInitializationFailed",type:"error"},{inputs:[],name:"ExecutionFailed",type:"error"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],name:"FallbackInstalled",type:"error"},{inputs:[{internalType:"address",name:"currentHook",type:"address"}],name:"HookAlreadyInstalled",type:"error"},{inputs:[],name:"HookPostCheckFailed",type:"error"},{inputs:[],name:"InitializerError",type:"error"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],name:"InvalidFallbackHandler",type:"error"},{inputs:[],name:"InvalidHookType",type:"error"},{inputs:[{internalType:"address",name:"safe",type:"address"}],name:"InvalidInitData",type:"error"},{inputs:[],name:"InvalidInput",type:"error"},{inputs:[{internalType:"address",name:"module",type:"address"}],name:"InvalidModule",type:"error"},{inputs:[],name:"LinkedListError",type:"error"},{inputs:[],name:"LinkedList_AlreadyInitialized",type:"error"},{inputs:[],name:"LinkedList_AlreadyInitialized",type:"error"},{inputs:[{internalType:"address",name:"entry",type:"address"}],name:"LinkedList_EntryAlreadyInList",type:"error"},{inputs:[{internalType:"address",name:"entry",type:"address"}],name:"LinkedList_EntryAlreadyInList",type:"error"},{inputs:[{internalType:"address",name:"entry",type:"address"}],name:"LinkedList_InvalidEntry",type:"error"},{inputs:[{internalType:"address",name:"entry",type:"address"}],name:"LinkedList_InvalidEntry",type:"error"},{inputs:[],name:"LinkedList_InvalidPage",type:"error"},{inputs:[],name:"LinkedList_InvalidPage",type:"error"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],name:"NoFallbackHandler",type:"error"},{inputs:[{internalType:"CallType",name:"callType",type:"bytes1"}],name:"UnsupportedCallType",type:"error"},{inputs:[{internalType:"ExecType",name:"execType",type:"bytes1"}],name:"UnsupportedExecType",type:"error"},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256"}],name:"UnsupportedModuleType",type:"error"},{inputs:[],name:"ValidatorStorageHelperError",type:"error"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"smartAccount",type:"address"},{indexed:!0,internalType:"contract IERC7484",name:"registry",type:"address"}],name:"ERC7484RegistryConfigured",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"moduleTypeId",type:"uint256"},{indexed:!1,internalType:"address",name:"module",type:"address"}],name:"ModuleInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"moduleTypeId",type:"uint256"},{indexed:!1,internalType:"address",name:"module",type:"address"}],name:"ModuleUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"safe",type:"address"}],name:"Safe7579Initialized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"contract ISafe",name:"safe",type:"address"},{indexed:!1,internalType:"uint256",name:"numberInBatch",type:"uint256"}],name:"TryExecutionFailed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"contract ISafe",name:"safe",type:"address"},{indexed:!1,internalType:"bool[]",name:"success",type:"bool[]"}],name:"TryExecutionsFailed",type:"event"},{stateMutability:"payable",type:"fallback"},{inputs:[],name:"accountId",outputs:[{internalType:"string",name:"accountImplementationId",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"domainSeparator",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"entryPoint",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"ModeCode",name:"mode",type:"bytes32"},{internalType:"bytes",name:"executionCalldata",type:"bytes"}],name:"execute",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"ModeCode",name:"mode",type:"bytes32"},{internalType:"bytes",name:"executionCalldata",type:"bytes"}],name:"executeFromExecutor",outputs:[{internalType:"bytes[]",name:"returnDatas",type:"bytes[]"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getActiveHook",outputs:[{internalType:"address",name:"hook",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"selector",type:"bytes4"}],name:"getActiveHook",outputs:[{internalType:"address",name:"hook",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"cursor",type:"address"},{internalType:"uint256",name:"size",type:"uint256"}],name:"getExecutorsPaginated",outputs:[{internalType:"address[]",name:"array",type:"address[]"},{internalType:"address",name:"next",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"safe",type:"address"},{internalType:"address",name:"validator",type:"address"}],name:"getNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"start",type:"address"},{internalType:"uint256",name:"pageSize",type:"uint256"}],name:"getValidatorPaginated",outputs:[{internalType:"address[]",name:"array",type:"address[]"},{internalType:"address",name:"next",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],internalType:"struct ModuleInit[]",name:"validators",type:"tuple[]"},{components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],internalType:"struct ModuleInit[]",name:"executors",type:"tuple[]"},{components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],internalType:"struct ModuleInit[]",name:"fallbacks",type:"tuple[]"},{components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],internalType:"struct ModuleInit[]",name:"hooks",type:"tuple[]"},{components:[{internalType:"contract IERC7484",name:"registry",type:"address"},{internalType:"address[]",name:"attesters",type:"address[]"},{internalType:"uint8",name:"threshold",type:"uint8"}],internalType:"struct RegistryInit",name:"registryInit",type:"tuple"}],name:"initializeAccount",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],name:"installModule",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"additionalContext",type:"bytes"}],name:"isModuleInstalled",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"hash",type:"bytes32"},{internalType:"bytes",name:"data",type:"bytes"}],name:"isValidSignature",outputs:[{internalType:"bytes4",name:"magicValue",type:"bytes4"}],stateMutability:"view",type:"function"},{inputs:[{components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],internalType:"struct ModuleInit[]",name:"validators",type:"tuple[]"}],name:"launchpadValidators",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"contract IERC7484",name:"registry",type:"address"},{internalType:"address[]",name:"attesters",type:"address[]"},{internalType:"uint8",name:"threshold",type:"uint8"}],name:"setRegistry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"ModeCode",name:"encodedMode",type:"bytes32"}],name:"supportsExecutionMode",outputs:[{internalType:"bool",name:"supported",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256"}],name:"supportsModule",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"deInitData",type:"bytes"}],name:"uninstallModule",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct PackedUserOperation",name:"userOp",type:"tuple"},{internalType:"bytes32",name:"userOpHash",type:"bytes32"},{internalType:"uint256",name:"missingAccountFunds",type:"uint256"}],name:"validateUserOp",outputs:[{internalType:"uint256",name:"validSignature",type:"uint256"}],stateMutability:"payable",type:"function"},{stateMutability:"payable",type:"receive"}],bytecode$3="0x60806040523480156200001157600080fd5b50604051620000209062000064565b604051809103906000f0801580156200003d573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b039290921691909117905562000072565b610a0b8062004e3983390190565b614db780620000826000396000f3fe6080604052600436106101635760003560e01c8063b0d691fe116100c0578063e9ae5c5311610074578063eab77e1711610059578063eab77e1714610482578063f2dc691d146104a2578063f698da25146104c25761016a565b8063e9ae5c531461044f578063ea5f61d0146104625761016a565b8063d03c7914116100a5578063d03c7914146103ef578063d691c9641461040f578063d828435d1461042f5761016a565b8063b0d691fe14610380578063b875d5d8146103a35761016a565b80636a5e1515116101175780639517e29f116100fc5780639517e29f146103385780639cfd7cff1461034b578063a71763a81461036d5761016a565b80636a5e1515146102f7578063855713681461030a5761016a565b80631626ba7e116101485780631626ba7e1461028857806319822f7c146102c1578063540fb4f9146102e25761016a565b80630a664dba14610214578063112d3a7d146102585761016a565b3661016a57005b600036606060003560e01c63bc197c81811463f23a6e6182141763150b7a028214171561019b57806020526020603cf35b5033600090815260056020908152604080832054600683528184206001600160e01b031985351680865293529083205491926001600160a01b039182169290911690806101e8848461052b565b915091506101f6888861060a565b955061020484848484610756565b5050505050915050805190602001f35b34801561022057600080fd5b50336000908152600560205260409020546001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561026457600080fd5b50610278610273366004613d4e565b6107f2565b604051901515815260200161024f565b34801561029457600080fd5b506102a86102a3366004613daa565b61084f565b6040516001600160e01b0319909116815260200161024f565b6102d46102cf366004613df6565b610b17565b60405190815260200161024f565b6102f56102f0366004613ea7565b610c3c565b005b6102f5610305366004613f8e565b610c89565b34801561031657600080fd5b5061032a610325366004613fd0565b610cea565b60405161024f929190613ffc565b6102f5610346366004613d4e565b610d06565b34801561035757600080fd5b50610360610e52565b60405161024f91906140ac565b6102f561037b366004613d4e565b610ee4565b34801561038c57600080fd5b506f71727de22e5e9d8baf0edac6f37da03261023b565b3480156103af57600080fd5b5061023b6103be3660046140d5565b3360009081526006602090815260408083206001600160e01b0319909416835292905220546001600160a01b031690565b3480156103fb57600080fd5b5061027861040a3660046140f2565b611072565b61042261041d366004613daa565b61111b565b60405161024f919061410b565b34801561043b57600080fd5b506102d461044a36600461416f565b61120f565b6102f561045d366004613daa565b6112e6565b34801561046e57600080fd5b5061032a61047d366004613fd0565b61168b565b34801561048e57600080fd5b506102f561049d3660046141b9565b6116b5565b3480156104ae57600080fd5b506102786104bd3660046140f2565b61170b565b3480156104ce57600080fd5b506102d4604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b6060806001600160a01b038416156105c6576105ad3385600036601319013560601c5b346000366040516024016105659493929190614249565b60408051601f198184030181529190526020810180516001600160e01b03167fd68f60250000000000000000000000000000000000000000000000000000000017905261175a565b9150818060200190518101906105c39190614340565b91505b6001600160a01b03831615610603576105ea3384600036601319013560601c61054e565b9050808060200190518101906106009190614340565b90505b9250929050565b3360009081526004602090815260408083206001600160e01b0319843516845290915290208054606091906001600160a01b03811690600160a01b900460f81b81610694576040517f48c9ceda0000000000000000000000000000000000000000000000000000000081526001600160e01b03196000351660048201526024015b60405180910390fd5b6001600160f81b031981167ffe0000000000000000000000000000000000000000000000000000000000000003610705576106fb3383888836601319013560601c6040516020016106e793929190614375565b604051602081830303815290604052611803565b9350505050610750565b6001600160f81b0319811661074c576106fb33836000898936601319013560601c60405160200161073893929190614375565b60405160208183030381529060405261175a565b5050505b92915050565b6001600160a01b038416156107c5576107c5338560008560405160240161077d91906140ac565b60408051601f198184030181529190526020810180516001600160e01b03167f173bf7da000000000000000000000000000000000000000000000000000000001790526118f5565b6001600160a01b038316156107ec576107ec338460008460405160240161077d91906140ac565b50505050565b60006001850361080c5761080584611994565b9050610847565b6002850361081d57610805846119a2565b60038503610830576108058484846119bb565b6004850361084357610805848484611a08565b5060005b949350505050565b600033821580156108e057506040517f5ae6bd37000000000000000000000000000000000000000000000000000000008152600481018690526001600160a01b03821690635ae6bd3790602401602060405180830381865afa1580156108b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108dd919061439b565b15155b156108f55750630b135d3f60e11b9050610b10565b600061090460148286886143b4565b61090d916143de565b60601c9050801580610925575061092381611994565b155b15610a7b5760006109f0836001600160a01b031663f698da256040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610991919061439b565b60408051602081018b90527f60b3cbf8b4a223d68d641b3b6ddf9a298e7f33710cf3d3a9d1146b5a6150fbca910160408051601f1981840301815282825280516020918201209083015201604051602081830303815290604052611a43565b805160208201209091506001600160a01b03841663934f3a118284610a188a6014818e6143b4565b6040518563ffffffff1660e01b8152600401610a379493929190614413565b60006040518083038186803b158015610a4f57600080fd5b505afa158015610a63573d6000803e3d6000fd5b50630b135d3f60e11b9750610b109650505050505050565b6000610af4338336601319013560601c8a610a998a6014818e6143b4565b604051602401610aac9493929190614249565b60408051601f198184030181529190526020810180516001600160e01b03167ff551e2ee00000000000000000000000000000000000000000000000000000000179052611803565b905080806020019051810190610b0a919061444a565b93505050505b9392505050565b600060131936013560601c6f71727de22e5e9d8baf0edac6f37da03214610b5157604051635629665f60e11b815260040160405180910390fd5b6020840135606081901c90811580610b6f5750610b6d82611994565b155b15610b8457610b7d86611abd565b9250610c02565b6000610be8338460008a8a604051602401610ba09291906144ad565b60408051601f198184030181529190526020810180516001600160e01b03167f970032030000000000000000000000000000000000000000000000000000000017905261175a565b905080806020019051810190610bfe919061439b565b9350505b8315610c3357610c33336f71727de22e5e9d8baf0edac6f37da03286604051806020016040528060008152506118f5565b50509392505050565b610c6e610c4c60208301836145ac565b610c5960208401846145c9565b610c696060860160408701614613565b611b7c565b610c7e8989898989898989611c43565b505050505050505050565b610c94600233611e9f565b8060005b818110156107ec5736848483818110610cb357610cb361462e565b9050602002810190610cc59190614644565b9050610ce133610cd860208401846145ac565b60029190611f1a565b50600101610c98565b60606000610cfb600233868661200f565b915091509250929050565b3360009081526005602090815260408083205460068352818420639517e29f60e01b80865293529083205491926001600160a01b03918216929091169080610d4e848461052b565b91509150606060018a03610d6e57610d678989896121d4565b9050610dec565b60028a03610d8157610d67898989612230565b60038a03610d9457610d6789898961229a565b60048a03610da757610d67898989612457565b89610db757610d678989896125ef565b6040517f41c38b30000000000000000000000000000000000000000000000000000000008152600481018b905260240161068b565b600054604051610e459133916001600160a01b0390911690610e16908e908e908790602401614664565b60408051601f198184030181529190526020810180516001600160e01b0316639517e29f60e01b179052612790565b50610c7e84848484610756565b60606000336001600160a01b031663ffa1ad746040518163ffffffff1660e01b8152600401600060405180830381865afa158015610e94573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ebc919081019061468c565b905080604051602001610ecf91906146d5565b60405160208183030381529060405291505090565b33600090815260056020908152604080832054600683528184207fa71763a80000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b03918216929091169080610f45848461052b565b91509150610f606f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031636601319013560601c6001600160a01b03161480610f8e57503360131936013560601c145b610fab57604051635629665f60e11b815260040160405180910390fd5b606060018a03610fc757610fc0898989612829565b9050611000565b60028a03610fda57610fc0898989612852565b60038a03610fed57610fc089898961287f565b60048a03610db757610fc08989896128cd565b600054604051610e459133916001600160a01b039091169061102a908e908e908790602401614664565b60408051601f198184030181529190526020810180516001600160e01b03167f7827252500000000000000000000000000000000000000000000000000000000179052612985565b600081600881901b6001600160f81b03198216600160f81b0361109857600192506110d4565b6001600160f81b031982166110b057600192506110d4565b6001600160f81b0319808316036110ca57600192506110d4565b5060009392505050565b8280156110e957506001600160f81b03198116155b156110f5575050919050565b82801561110f57506001600160f81b03198116600160f81b145b156110ca575050919050565b606061112d366013190135821c6119a2565b61116d576040517fb927fe5e00000000000000000000000000000000000000000000000000000000815260131936013560601c600482015260240161068b565b33600090815260056020908152604080832054600683528184207fd691c9640000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b039182169290911690806111ce848461052b565b915091503360026111df8282612a4d565b8a600881901b6111f181838e8e612af1565b99505050505061120384848484610756565b50505050509392505050565b6000602082901b77ffffffffffffffffffffffffffffffffffffffff00000000166f71727de22e5e9d8baf0edac6f37da0326040517f35567e1a0000000000000000000000000000000000000000000000000000000081526001600160a01b03868116600483015277ffffffffffffffffffffffffffffffffffffffffffffffff8416602483015291909116906335567e1a90604401602060405180830381865afa1580156112c2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610847919061439b565b33600090815260056020908152604080832054600683528184207fe9ae5c530000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b03918216929091169080611347848461052b565b915091506113626f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031636601319013560601c6001600160a01b0316148061139057503360131936013560601c145b6113ad57604051635629665f60e11b815260040160405180910390fd5b87600881901b336001600160f81b0319821661151c576001600160f81b03198316600160f81b036113f45789358a016020810190356113ed838383612ea4565b5050611672565b6001600160f81b03198316611466576000803660006114138e8e612f14565b935093509350935061145d85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506118f592505050565b50505050611672565b6001600160f81b0319808416036114f75760006114866014828c8e6143b4565b61148f916143de565b60601c90503660008c8c60149080926114aa939291906143b4565b915091506114ef848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061279092505050565b505050611672565b604051632e5bf3f960e21b81526001600160f81b03198416600482015260240161068b565b6001600160f81b03198216600160f81b0361164d576001600160f81b03198316600160f81b0361155b5789358a016020810190356113ed838383612f65565b6001600160f81b031983166115c45760008036600061157a8e8e612f14565b935093509350935061145d85858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612fd592505050565b6001600160f81b0319808416036114f75760006115e46014828c8e6143b4565b6115ed916143de565b60601c90503660008c8c6014908092611608939291906143b4565b915091506114ef848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061298592505050565b6040516308c3ee0360e11b81526001600160f81b03198316600482015260240161068b565b50505061168184848484610756565b5050505050505050565b336000908152600360205260408120606091906116a981868661309d565b92509250509250929050565b60131936013560601c6f71727de22e5e9d8baf0edac6f37da03214806116e257503360131936013560601c145b6116ff57604051635629665f60e11b815260040160405180910390fd5b6107ec84848484611b7c565b60006001820361171d57506001919050565b6002820361172d57506001919050565b6003820361173d57506001919050565b6004820361174d57506001919050565b506000919050565b919050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b81526004016117919493929190614741565b6000604051808303816000875af11580156117b0573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526117d8919081019061478d565b92509050806117fa57604051632b3f6d1160e21b815260040160405180910390fd5b50949350505050565b60606000838360405160240161181a9291906147db565b60408051601f198184030181529181526020820180516001600160e01b03167f6a221657000000000000000000000000000000000000000000000000000000001790526000805491519293509161187f916001600160a01b03169084906024016147db565b60408051601f19818403018152919052602080820180516001600160e01b03167fb4faba090000000000000000000000000000000000000000000000000000000017815282519293509091600091895afa5060203d036040519350808401604052806020853e50600051610c3357825160208401fd5b60405163468721a760e01b81526000906001600160a01b0386169063468721a79061192a908790879087908790600401614741565b6020604051808303816000875af1158015611949573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061196d91906147fd565b90508061198d57604051632b3f6d1160e21b815260040160405180910390fd5b5050505050565b60006107506002338461324a565b336000908152600360205260408120610b10818461328e565b6000806119ca838501856140d5565b3360009081526004602090815260408083206001600160e01b0319909416835292905220546001600160a01b03908116908616149150509392505050565b60008080611a1884860186614827565b915091506000611a2883836132c8565b6001600160a01b039081169088161493505050509392505050565b6060601960f81b600160f81b858585604051602001611a63929190614853565b60408051808303601f190181529082905280516020918201206001600160f81b0319958616918301919091529290931660218401526022830152604282015260620160405160208183030381529060405290509392505050565b600080600080366000611acf87613360565b845160208601206040517f934f3a11000000000000000000000000000000000000000000000000000000008152959a5093985091965094509250339163934f3a1191611b2391899087908790600401614413565b60006040518083038186803b158015611b3b57600080fd5b505afa925050508015611b4c575060015b611b6357611b5c600184866135e5565b9550611b72565b611b6f600084866135e5565b95505b5050505050919050565b3360008181526001602052604080822080546001600160a01b0319166001600160a01b03891617905551611c0792918791611bbf90869089908990602401614879565b60408051601f198184030181529190526020810180516001600160e01b03167ff05c04e1000000000000000000000000000000000000000000000000000000001790526118f5565b6040516001600160a01b0385169033907f9452c8fb077c3ea8f28a77c87488af657b1e44d010ad9a5992d73870da040e9490600090a350505050565b3360009081527fe90b7bceb6e7df5418fb78d8ee546e97c83a08bbccc01a0644d599ccd2a7c2e0602052604090205487906001600160a01b0316611cf057611c8c600233611e9f565b60005b81811015611cea57368a8a83818110611caa57611caa61462e565b9050602002810190611cbc9190614644565b9050611ce0611cce60208301836145ac565b611cdb60208401846148d4565b6121d4565b5050600101611c8f565b50611d2a565b8015611d2a576040517fd8e3ed1b00000000000000000000000000000000000000000000000000000000815233600482015260240161068b565b336000908152600360205260409020611d428161361d565b86915060005b82811015611da35736898983818110611d6357611d6361462e565b9050602002810190611d759190614644565b9050611d99611d8760208301836145ac565b611d9460208401846148d4565b612230565b5050600101611d48565b5084915060005b82811015611e055736878783818110611dc557611dc561462e565b9050602002810190611dd79190614644565b9050611dfb611de960208301836145ac565b611df660208401846148d4565b61229a565b5050600101611daa565b5082915060005b82811015611e675736858583818110611e2757611e2761462e565b9050602002810190611e399190614644565b9050611e5d611e4b60208301836145ac565b611e5860208401846148d4565b612457565b5050600101611e0c565b5060405133907ff48581d8a62b775b74f2fb67f1d5806a9a356fbcc598040ab3071d3e37af40c290600090a250505050505050505050565b60016000908152602083815260408083206001600160a01b0380861685529252909120541615611ee2576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602093845260408082206001600160a01b0394909416825292909352912080546001600160a01b0319169091179055565b6001600160a01b0381161580611f3957506001600160a01b0381166001145b15611f6257604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b0381811660009081526020858152604080832086851684529091529020541615611fb157604051631034f46960e21b81526001600160a01b038216600482015260240161068b565b60016000908152602084815260408083206001600160a01b039586168085528184528285208054968816808752988552838620918652908452919093208054949095166001600160a01b031994851617909455528154169091179055565b606060006001600160a01b038416600114801590612035575061203386868661324a565b155b1561205e57604051637c84ecfb60e01b81526001600160a01b038516600482015260240161068b565b8260000361207f5760405163f725081760e01b815260040160405180910390fd5b8267ffffffffffffffff8111156120985761209861427c565b6040519080825280602002602001820160405280156120c1578160200160208202803683370190505b506001600160a01b038086166000908152602089815260408083208a85168452909152812054929450911691505b6001600160a01b0382161580159061211157506001600160a01b038216600114155b801561211c57508381105b1561218157818382815181106121345761213461462e565b6001600160a01b039283166020918202929092018101919091529281166000908152888452604080822089841683529094529290922054909116908061217981614931565b9150506120ef565b6001600160a01b03821660011480159061219b5750600081115b156121c757826121ac60018361494a565b815181106121bc576121bc61462e565b602002602001015191505b8083525094509492505050565b60608360016121e38282612a4d565b6121ef60023388611f1a565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929998505050505050505050565b606083600261223f8282612a4d565b336000908152600360205260409020612258818861367a565b85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929a9950505050505050505050565b60608360036122a98282612a4d565b600080806122b9878901896149ae565b919450925090506001600160e01b031983167f6d61fe7000000000000000000000000000000000000000000000000000000000148061232157506001600160e01b031983167f8a91b0e300000000000000000000000000000000000000000000000000000000145b15612364576040517f79bd117b0000000000000000000000000000000000000000000000000000000081526001600160e01b03198416600482015260240161068b565b3360009081526004602090815260408083206001600160e01b0319871684529091529020546001600160a01b0316156123d5576040517f74420d150000000000000000000000000000000000000000000000000000000081526001600160e01b03198416600482015260240161068b565b3360009081526004602090815260408083206001600160e01b031990961683529490529290922080546001600160a01b038a166001600160a01b031960f89490941c600160a01b02939093167fffffffffffffffffffffff00000000000000000000000000000000000000000090911617919091179055925050509392505050565b60608360046124668282612a4d565b6000808061247687890189614a1d565b9194509250905060008084600181111561249257612492614a4b565b1480156124a757506001600160e01b03198316155b1561251d5750336000908152600560205260409020546001600160a01b031680156124f05760405163741cbe0360e01b81526001600160a01b038216600482015260240161068b565b33600090815260056020526040902080546001600160a01b0319166001600160a01b038c161790556125e2565b600184600181111561253157612531614a4b565b036125b0576001600160a01b038116156125695760405163741cbe0360e01b81526001600160a01b038216600482015260240161068b565b503360009081526006602090815260408083206001600160e01b031986168452909152902080546001600160a01b038b81166001600160a01b0319831617909255166125e2565b6040517f5691922f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5098975050505050505050565b60608235830160208181019135908581013586018082019190359060408801358801908101903584838114612650576040517fb4fa3fb300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8181101561274957600088888381811061266f5761266f61462e565b905060200201359050600181036126ae576126a88d8888858181106126965761269661462e565b9050602002810190611cdb91906148d4565b50612740565b600281036126de576126a88d8888858181106126cc576126cc61462e565b9050602002810190611d9491906148d4565b6003810361270e576126a88d8888858181106126fc576126fc61462e565b9050602002810190611df691906148d4565b600481036127405761273e8d88888581811061272c5761272c61462e565b9050602002810190611e5891906148d4565b505b50600101612653565b5082828080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929e9d5050505050505050505050505050565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906127c690869085908790600190600401614741565b6020604051808303816000875af11580156127e5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061280991906147fd565b9050806107ec57604051632b3f6d1160e21b815260040160405180910390fd5b6060600061283983850185614a61565b9250905061284a6002338388613750565b509392505050565b33600090815260036020526040812060609161287084860186614a61565b93509050610c33828288613847565b6060600061288f83850185614aa7565b3360009081526004602090815260408083206001600160e01b031990951683529390529190912080546001600160a01b031916905595945050505050565b60606000806128de84860186614a1d565b9450909250905060008260018111156128f9576128f9614a4b565b14801561290e57506001600160e01b03198116155b156129355733600090815260056020526040902080546001600160a01b0319169055610c33565b600182600181111561294957612949614a4b565b036125b0573360009081526006602090815260408083206001600160e01b031985168452909152902080546001600160a01b0319169055610c33565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906129bb90869085908790600190600401614741565b6020604051808303816000875af11580156129da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129fe91906147fd565b9050806107ec57604080516001600160a01b0386168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a150505050565b336000908152600160205260409020546001600160a01b03168015612aec576040517f529562a10000000000000000000000000000000000000000000000000000000081523360048201526001600160a01b0384811660248301526044820184905282169063529562a19060640160006040518083038186803b158015612ad357600080fd5b505afa158015612ae7573d6000803e3d6000fd5b505050505b505050565b60606001600160f81b03198516612cee576001600160f81b03198416600160f81b03612b355782358301602081019035612b2c33838361391c565b92505050610847565b6001600160f81b03198416612bf357600080366000612b548787612f14565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612b73579050509450612bcc33858585858080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175a92505050565b85600081518110612bdf57612bdf61462e565b602002602001018190525050505050610847565b6001600160f81b031980851603612cc9576000612c1360148285876143b4565b612c1c916143de565b60601c9050366000612c3185601481896143b4565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612c4b579050509350612ca3338484848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506139ae92505050565b84600081518110612cb657612cb661462e565b6020026020010181905250505050610847565b604051632e5bf3f960e21b81526001600160f81b03198516600482015260240161068b565b6001600160f81b03198516600160f81b03612e7f576001600160f81b03198416600160f81b03612d385782358301602081019035612d2d338383613a4f565b935061084792505050565b6001600160f81b03198416612dcf57600080366000612d578787612f14565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612d76579050509450612bcc33858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613aea92505050565b6001600160f81b031980851603612cc9576000612def60148285876143b4565b612df8916143de565b60601c9050366000612e0d85601481896143b4565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612e27579050509350612ca3338484848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613bbc92505050565b6040516308c3ee0360e11b81526001600160f81b03198616600482015260240161068b565b600054604051612aec9185916001600160a01b0390911690612ecc9086908690602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f3f707e6b00000000000000000000000000000000000000000000000000000000179052612790565b6000803681612f2660148287896143b4565b612f2f916143de565b60601c9350612f426034601487896143b4565b612f4b91614b70565b9250612f5a85603481896143b4565b949793965094505050565b600054604051612aec9185916001600160a01b0390911690612f8d9086908690602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f50c8902200000000000000000000000000000000000000000000000000000000179052612985565b60405163468721a760e01b81526000906001600160a01b0386169063468721a79061300a908790879087908790600401614741565b6020604051808303816000875af1158015613029573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061304d91906147fd565b90508061198d57604080516001600160a01b0387168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a15050505050565b606060006001600160a01b0384166001148015906130c257506130c0858561328e565b155b156130eb57604051637c84ecfb60e01b81526001600160a01b038516600482015260240161068b565b8260000361310c5760405163f725081760e01b815260040160405180910390fd5b8267ffffffffffffffff8111156131255761312561427c565b60405190808252806020026020018201604052801561314e578160200160208202803683370190505b506001600160a01b03808616600090815260208890526040812054929450911691505b6001600160a01b0382161580159061319357506001600160a01b038216600114155b801561319e57508381105b156131f857818382815181106131b6576131b661462e565b6001600160a01b0392831660209182029290920181019190915292811660009081529287905260409092205490911690806131f081614931565b915050613171565b6001600160a01b0382166001148015906132125750600081115b1561323e578261322360018361494a565b815181106132335761323361462e565b602002602001015191505b80835250935093915050565b600060016001600160a01b038316148015906108475750506001600160a01b0390811660009081526020938452604080822093831682529290935291205416151590565b600060016001600160a01b03831614801590610b105750506001600160a01b03908116600090815260209290925260409091205416151590565b6000808360018111156132dd576132dd614a4b565b1480156132f257506001600160e01b03198216155b156133125750336000908152600560205260409020546001600160a01b03165b600183600181111561332657613326614a4b565b0361075057503360009081526006602090815260408083206001600160e01b0319851684529091529020546001600160a01b031692915050565b6060600080368181816133776101008901896148d4565b909250905061338a6006600083856143b4565b61339391614b8e565b60d01c95506133a6600c600683856143b4565b6133af91614b8e565b60d01c94506133c181600c81856143b4565b9350935050506000604051806101c001604052807f84aa190356f56b8c87825f54884392a9907c23ee0f8e1ea86336b763faf021bd60001b8152602001336001600160a01b031681526020018860200135815260200188806040019061342791906148d4565b604051613435929190614bd4565b604051908190039020815260200161345060608a018a6148d4565b60405161345e929190614bd4565b6040518091039020815260200161347489613c8e565b815260200161348289613cac565b81526020018860a00135815260200161349a89613cbc565b81526020016134a889613cda565b81526020016134ba60e08a018a6148d4565b6040516134c8929190614bd4565b604051809103902081526020018665ffffffffffff1681526020018565ffffffffffff1681526020016135086f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031690526101c081209091507f1900000000000000000000000000000000000000000000000000000000000000600160f81b61359d604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b6040516001600160f81b031993841660208201529290911660218301526022820152604281018290526062016040516020818303038152906040529650505091939590929450565b600060d08265ffffffffffff16901b60a08465ffffffffffff16901b8561360d576000613610565b60015b60ff161717949350505050565b60016000908152602082905260409020546001600160a01b031615613655576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602092909252604090912080546001600160a01b0319169091179055565b6001600160a01b038116158061369957506001600160a01b0381166001145b156136c257604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b03818116600090815260208490526040902054161561370657604051631034f46960e21b81526001600160a01b038216600482015260240161068b565b60016000818152602093909352604080842080546001600160a01b039485168087529286208054959091166001600160a01b03199586161790559190935280549091169091179055565b6001600160a01b038116158061376f57506001600160a01b0381166001145b1561379857604051637c84ecfb60e01b81526001600160a01b038316600482015260240161068b565b6001600160a01b0382811660009081526020868152604080832087851684529091529020548116908216146137eb57604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b039081166000908152602085815260408083209584168084528683528184208054968616855297835281842090845282529091208054939092166001600160a01b031993841617909155919091528154169055565b6001600160a01b038116158061386657506001600160a01b0381166001145b1561388f57604051637c84ecfb60e01b81526001600160a01b038316600482015260240161068b565b6001600160a01b038281166000908152602085905260409020548116908216146138d757604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b0390811660008181526020949094526040808520805494841686529085208054949093166001600160a01b0319948516179092559092528154169055565b600080546040516060929161398f9187916001600160a01b0316906139479088908890602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f61085573000000000000000000000000000000000000000000000000000000001790526139ae565b9050808060200190518101906139a59190614c93565b95945050505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016139e69493929190614741565b6000604051808303816000875af1158015613a05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613a2d919081019061478d565b925090508061284a57604051632b3f6d1160e21b815260040160405180910390fd5b6060806000613ac78660008054906101000a90046001600160a01b03168787604051602401613a7f929190614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f9abb6e1700000000000000000000000000000000000000000000000000000000179052613bbc565b905080806020019051810190613add9190614cc8565b9097909650945050505050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b8152600401613b219493929190614741565b6000604051808303816000875af1158015613b40573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613b68919081019061478d565b92509050806117fa57604080516001600160a01b0388168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a150949350505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b8152600401613bf49493929190614741565b6000604051808303816000875af1158015613c13573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613c3b919081019061478d565b925090508061284a57604080516001600160a01b0387168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a1509392505050565b60006fffffffffffffffffffffffffffffffff608083013516610750565b6000610750826080013560801c90565b60006fffffffffffffffffffffffffffffffff60c083013516610750565b600060c082013560801c610750565b6001600160a01b0381168114613cfe57600080fd5b50565b803561175581613ce9565b60008083601f840112613d1e57600080fd5b50813567ffffffffffffffff811115613d3657600080fd5b60208301915083602082850101111561060357600080fd5b60008060008060608587031215613d6457600080fd5b843593506020850135613d7681613ce9565b9250604085013567ffffffffffffffff811115613d9257600080fd5b613d9e87828801613d0c565b95989497509550505050565b600080600060408486031215613dbf57600080fd5b83359250602084013567ffffffffffffffff811115613ddd57600080fd5b613de986828701613d0c565b9497909650939450505050565b600080600060608486031215613e0b57600080fd5b833567ffffffffffffffff811115613e2257600080fd5b84016101208187031215613e3557600080fd5b95602085013595506040909401359392505050565b60008083601f840112613e5c57600080fd5b50813567ffffffffffffffff811115613e7457600080fd5b6020830191508360208260051b850101111561060357600080fd5b600060608284031215613ea157600080fd5b50919050565b600080600080600080600080600060a08a8c031215613ec557600080fd5b893567ffffffffffffffff80821115613edd57600080fd5b613ee98d838e01613e4a565b909b50995060208c0135915080821115613f0257600080fd5b613f0e8d838e01613e4a565b909950975060408c0135915080821115613f2757600080fd5b613f338d838e01613e4a565b909750955060608c0135915080821115613f4c57600080fd5b613f588d838e01613e4a565b909550935060808c0135915080821115613f7157600080fd5b50613f7e8c828d01613e8f565b9150509295985092959850929598565b60008060208385031215613fa157600080fd5b823567ffffffffffffffff811115613fb857600080fd5b613fc485828601613e4a565b90969095509350505050565b60008060408385031215613fe357600080fd5b8235613fee81613ce9565b946020939093013593505050565b604080825283519082018190526000906020906060840190828701845b8281101561403e5781516001600160a01b031684529284019290840190600101614019565b50505080925050506001600160a01b03831660208301529392505050565b60005b8381101561407757818101518382015260200161405f565b50506000910152565b6000815180845261409881602086016020860161405c565b601f01601f19169290920160200192915050565b602081526000610b106020830184614080565b6001600160e01b031981168114613cfe57600080fd5b6000602082840312156140e757600080fd5b8135610b10816140bf565b60006020828403121561410457600080fd5b5035919050565b600060208083016020845280855180835260408601915060408160051b87010192506020870160005b8281101561416257603f19888603018452614150858351614080565b94509285019290850190600101614134565b5092979650505050505050565b6000806040838503121561418257600080fd5b823561418d81613ce9565b9150602083013561419d81613ce9565b809150509250929050565b803560ff8116811461175557600080fd5b600080600080606085870312156141cf57600080fd5b84356141da81613ce9565b9350602085013567ffffffffffffffff8111156141f657600080fd5b61420287828801613e4a565b90945092506142159050604086016141a8565b905092959194509250565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b6001600160a01b0385168152836020820152606060408201526000614272606083018486614220565b9695505050505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156142bb576142bb61427c565b604052919050565b600067ffffffffffffffff8211156142dd576142dd61427c565b50601f01601f191660200190565b60006142fe6142f9846142c3565b614292565b905082815283838301111561431257600080fd5b610b1083602083018461405c565b600082601f83011261433157600080fd5b610b10838351602085016142eb565b60006020828403121561435257600080fd5b815167ffffffffffffffff81111561436957600080fd5b61084784828501614320565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000602082840312156143ad57600080fd5b5051919050565b600080858511156143c457600080fd5b838611156143d157600080fd5b5050820193919092039150565b6bffffffffffffffffffffffff19813581811691601485101561440b5780818660140360031b1b83161692505b505092915050565b84815260606020820152600061442c6060830186614080565b828103604084015261443f818587614220565b979650505050505050565b60006020828403121561445c57600080fd5b8151610b10816140bf565b6000808335601e1984360301811261447e57600080fd5b830160208101925035905067ffffffffffffffff81111561449e57600080fd5b80360382131561060357600080fd5b604081526144ce604082016144c185613d01565b6001600160a01b03169052565b6020830135606082015260006144e76040850185614467565b6101208060808601526144ff61016086018385614220565b925061450e6060880188614467565b9250603f19808786030160a0880152614528858584614220565b9450608089013560c088015260a089013560e0880152610100935060c08901358488015261455960e08a018a614467565b925081888703018489015261456f868483614220565b95505061457e848a018a614467565b945092508087860301610140880152505061459a838383614220565b93505050508260208301529392505050565b6000602082840312156145be57600080fd5b8135610b1081613ce9565b6000808335601e198436030181126145e057600080fd5b83018035915067ffffffffffffffff8211156145fb57600080fd5b6020019150600581901b360382131561060357600080fd5b60006020828403121561462557600080fd5b610b10826141a8565b634e487b7160e01b600052603260045260246000fd5b60008235603e1983360301811261465a57600080fd5b9190910192915050565b8381526001600160a01b03831660208201526060604082015260006139a56060830184614080565b60006020828403121561469e57600080fd5b815167ffffffffffffffff8111156146b557600080fd5b8201601f810184136146c657600080fd5b610847848251602084016142eb565b7f736166652d00000000000000000000000000000000000000000000000000000081526000825161470d81600585016020870161405c565b7f2e657263373537392e76302e302e3100000000000000000000000000000000006005939091019283015250601401919050565b6001600160a01b03851681528360208201526080604082015260006147696080830185614080565b905060ff8316606083015295945050505050565b8051801515811461175557600080fd5b600080604083850312156147a057600080fd5b6147a98361477d565b9150602083015167ffffffffffffffff8111156147c557600080fd5b6147d185828601614320565b9150509250929050565b6001600160a01b03831681526040602082015260006108476040830184614080565b60006020828403121561480f57600080fd5b610b108261477d565b80356002811061175557600080fd5b6000806040838503121561483a57600080fd5b61484383614818565b9150602083013561419d816140bf565b8281526000825161486b81602085016020870161405c565b919091016020019392505050565b60ff8416815260406020808301829052908201839052600090849060608401835b868110156148c85783356148ad81613ce9565b6001600160a01b03168252928201929082019060010161489a565b50979650505050505050565b6000808335601e198436030181126148eb57600080fd5b83018035915067ffffffffffffffff82111561490657600080fd5b60200191503681900382131561060357600080fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016149435761494361491b565b5060010190565b818103818111156107505761075061491b565b600082601f83011261496e57600080fd5b813561497c6142f9826142c3565b81815284602083860101111561499157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000606084860312156149c357600080fd5b83356149ce816140bf565b925060208401356001600160f81b0319811681146149eb57600080fd5b9150604084013567ffffffffffffffff811115614a0757600080fd5b614a138682870161495d565b9150509250925092565b600080600060608486031215614a3257600080fd5b614a3b84614818565b925060208401356149eb816140bf565b634e487b7160e01b600052602160045260246000fd5b60008060408385031215614a7457600080fd5b8235614a7f81613ce9565b9150602083013567ffffffffffffffff811115614a9b57600080fd5b6147d18582860161495d565b60008060408385031215614aba57600080fd5b8235614a7f816140bf565b60208082528181018390526000906040808401600586901b850182018785805b89811015614b6157888403603f190185528235368c9003605e19018112614b0a578283fd5b8b0160608135614b1981613ce9565b6001600160a01b031686528189013589870152614b3888830183614467565b92508189880152614b4c8288018483614220565b978a0197965050509287019250600101614ae5565b50919998505050505050505050565b8035602083101561075057600019602084900360031b1b1692915050565b7fffffffffffff0000000000000000000000000000000000000000000000000000813581811691600685101561440b5760069490940360031b84901b1690921692915050565b8183823760009101908152919050565b600067ffffffffffffffff821115614bfe57614bfe61427c565b5060051b60200190565b600082601f830112614c1957600080fd5b81516020614c296142f983614be4565b82815260059290921b84018101918181019086841115614c4857600080fd5b8286015b84811015614c8857805167ffffffffffffffff811115614c6c5760008081fd5b614c7a8986838b0101614320565b845250918301918301614c4c565b509695505050505050565b600060208284031215614ca557600080fd5b815167ffffffffffffffff811115614cbc57600080fd5b61084784828501614c08565b60008060408385031215614cdb57600080fd5b825167ffffffffffffffff80821115614cf357600080fd5b818501915085601f830112614d0757600080fd5b81516020614d176142f983614be4565b82815260059290921b84018101918181019089841115614d3657600080fd5b948201945b83861015614d5b57614d4c8661477d565b82529482019490820190614d3b565b91880151919650909350505080821115614d7457600080fd5b506147d185828601614c0856fea2646970667358221220310490ce1c9ce1b361eae1667f3c75f8c90f8265fa8bcd2024bdff0a007dc05564736f6c63430008170033608060405234801561001057600080fd5b506109eb806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c80636a2216571161005b5780636a221657146100df57806378272525146100f25780639517e29f146101055780639abb6e171461011857600080fd5b80633f707e6b1461008257806350c890221461009757806361085573146100bf575b600080fd5b6100956100903660046105fb565b610139565b005b6100aa6100a53660046105fb565b6101a3565b60405190151581526020015b60405180910390f35b6100d26100cd3660046105fb565b610212565b6040516100b691906106f8565b6100956100ed366004610744565b6102cc565b610095610100366004610806565b6102ef565b610095610113366004610806565b6103b1565b61012b6101263660046105fb565b610469565b6040516100b692919061088d565b8060005b8181101561019d5736848483818110610158576101586108e7565b905060200281019061016a91906108fd565b905061019361017c602083018361091d565b602083013561018e6040850185610938565b610593565b505060010161013d565b50505050565b600081815b8181101561020a57368585838181106101c3576101c36108e7565b90506020028101906101d591906108fd565b90506101fe6101e7602083018361091d565b60208301356101f96040850185610938565b6105c9565b509350506001016101a8565b505092915050565b6060818067ffffffffffffffff81111561022e5761022e61072e565b60405190808252806020026020018201604052801561026157816020015b606081526020019060019003908161024c5790505b50915060005b8181101561020a5736858583818110610282576102826108e7565b905060200281019061029491906108fd565b90506102a661017c602083018361091d565b8483815181106102b8576102b86108e7565b602090810291909101015250600101610267565b604051600080835160208501865afa3d6000833e80156102ea573d82f35b503d81fd5b6040517f8a91b0e30000000000000000000000000000000000000000000000000000000081526001600160a01b03841690638a91b0e3906103369085908590600401610986565b600060405180830381600087803b15801561035057600080fd5b505af1158015610364573d6000803e3d6000fd5b5050604080518781526001600160a01b03871660208201527f341347516a9de374859dfda710fa4828b2d48cb57d4fbe4c1149612b8e02276e93500190505b60405180910390a150505050565b6040517f6d61fe700000000000000000000000000000000000000000000000000000000081526001600160a01b03841690636d61fe70906103f89085908590600401610986565b600060405180830381600087803b15801561041257600080fd5b505af1158015610426573d6000803e3d6000fd5b5050604080518781526001600160a01b03871660208201527fd21d0b289f126c4b473ea641963e766833c2f13866e4ff480abd787c100ef12393500190506103a3565b606080828067ffffffffffffffff8111156104865761048661072e565b6040519080825280602002602001820160405280156104b957816020015b60608152602001906001900390816104a45790505b5091508067ffffffffffffffff8111156104d5576104d561072e565b6040519080825280602002602001820160405280156104fe578160200160208202803683370190505b50925060005b8181101561058a573686868381811061051f5761051f6108e7565b905060200281019061053191906108fd565b90506105436101e7602083018361091d565b868481518110610555576105556108e7565b6020026020010186858151811061056e5761056e6108e7565b6020908102919091010191909152901515905250600101610504565b50509250929050565b60405181838237600038838387895af16105b0573d6000823e3d81fd5b3d8152602081013d6000823e3d01604052949350505050565b604051600090828482376000388483888a5af11591503d8152602081013d6000823e3d81016040525094509492505050565b6000806020838503121561060e57600080fd5b823567ffffffffffffffff8082111561062657600080fd5b818501915085601f83011261063a57600080fd5b81358181111561064957600080fd5b8660208260051b850101111561065e57600080fd5b60209290920196919550909350505050565b600082825180855260208086019550808260051b8401018186016000805b858110156106ea57601f1980888603018b5283518051808752845b818110156106c4578281018901518882018a015288016106a9565b5086810188018590529b87019b601f01909116909401850193509184019160010161068e565b509198975050505050505050565b60208152600061070b6020830184610670565b9392505050565b80356001600160a01b038116811461072957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561075757600080fd5b61076083610712565b9150602083013567ffffffffffffffff8082111561077d57600080fd5b818501915085601f83011261079157600080fd5b8135818111156107a3576107a361072e565b604051601f8201601f19908116603f011681019083821181831017156107cb576107cb61072e565b816040528281528860208487010111156107e457600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b6000806000806060858703121561081c57600080fd5b8435935061082c60208601610712565b9250604085013567ffffffffffffffff8082111561084957600080fd5b818701915087601f83011261085d57600080fd5b81358181111561086c57600080fd5b88602082850101111561087e57600080fd5b95989497505060200194505050565b604080825283519082018190526000906020906060840190828701845b828110156108c85781511515845292840192908401906001016108aa565b50505083810360208501526108dd8186610670565b9695505050505050565b634e487b7160e01b600052603260045260246000fd5b60008235605e1983360301811261091357600080fd5b9190910192915050565b60006020828403121561092f57600080fd5b61070b82610712565b6000808335601e1984360301811261094f57600080fd5b83018035915067ffffffffffffffff82111561096a57600080fd5b60200191503681900382131561097f57600080fd5b9250929050565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220b34bcdfa8e8aa5a58ed221d3799926e5a9a47e630242a4d564baf7fa090efe3364736f6c63430008170033",deployedBytecode$3="0x6080604052600436106101635760003560e01c8063b0d691fe116100c0578063e9ae5c5311610074578063eab77e1711610059578063eab77e1714610482578063f2dc691d146104a2578063f698da25146104c25761016a565b8063e9ae5c531461044f578063ea5f61d0146104625761016a565b8063d03c7914116100a5578063d03c7914146103ef578063d691c9641461040f578063d828435d1461042f5761016a565b8063b0d691fe14610380578063b875d5d8146103a35761016a565b80636a5e1515116101175780639517e29f116100fc5780639517e29f146103385780639cfd7cff1461034b578063a71763a81461036d5761016a565b80636a5e1515146102f7578063855713681461030a5761016a565b80631626ba7e116101485780631626ba7e1461028857806319822f7c146102c1578063540fb4f9146102e25761016a565b80630a664dba14610214578063112d3a7d146102585761016a565b3661016a57005b600036606060003560e01c63bc197c81811463f23a6e6182141763150b7a028214171561019b57806020526020603cf35b5033600090815260056020908152604080832054600683528184206001600160e01b031985351680865293529083205491926001600160a01b039182169290911690806101e8848461052b565b915091506101f6888861060a565b955061020484848484610756565b5050505050915050805190602001f35b34801561022057600080fd5b50336000908152600560205260409020546001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561026457600080fd5b50610278610273366004613d4e565b6107f2565b604051901515815260200161024f565b34801561029457600080fd5b506102a86102a3366004613daa565b61084f565b6040516001600160e01b0319909116815260200161024f565b6102d46102cf366004613df6565b610b17565b60405190815260200161024f565b6102f56102f0366004613ea7565b610c3c565b005b6102f5610305366004613f8e565b610c89565b34801561031657600080fd5b5061032a610325366004613fd0565b610cea565b60405161024f929190613ffc565b6102f5610346366004613d4e565b610d06565b34801561035757600080fd5b50610360610e52565b60405161024f91906140ac565b6102f561037b366004613d4e565b610ee4565b34801561038c57600080fd5b506f71727de22e5e9d8baf0edac6f37da03261023b565b3480156103af57600080fd5b5061023b6103be3660046140d5565b3360009081526006602090815260408083206001600160e01b0319909416835292905220546001600160a01b031690565b3480156103fb57600080fd5b5061027861040a3660046140f2565b611072565b61042261041d366004613daa565b61111b565b60405161024f919061410b565b34801561043b57600080fd5b506102d461044a36600461416f565b61120f565b6102f561045d366004613daa565b6112e6565b34801561046e57600080fd5b5061032a61047d366004613fd0565b61168b565b34801561048e57600080fd5b506102f561049d3660046141b9565b6116b5565b3480156104ae57600080fd5b506102786104bd3660046140f2565b61170b565b3480156104ce57600080fd5b506102d4604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b6060806001600160a01b038416156105c6576105ad3385600036601319013560601c5b346000366040516024016105659493929190614249565b60408051601f198184030181529190526020810180516001600160e01b03167fd68f60250000000000000000000000000000000000000000000000000000000017905261175a565b9150818060200190518101906105c39190614340565b91505b6001600160a01b03831615610603576105ea3384600036601319013560601c61054e565b9050808060200190518101906106009190614340565b90505b9250929050565b3360009081526004602090815260408083206001600160e01b0319843516845290915290208054606091906001600160a01b03811690600160a01b900460f81b81610694576040517f48c9ceda0000000000000000000000000000000000000000000000000000000081526001600160e01b03196000351660048201526024015b60405180910390fd5b6001600160f81b031981167ffe0000000000000000000000000000000000000000000000000000000000000003610705576106fb3383888836601319013560601c6040516020016106e793929190614375565b604051602081830303815290604052611803565b9350505050610750565b6001600160f81b0319811661074c576106fb33836000898936601319013560601c60405160200161073893929190614375565b60405160208183030381529060405261175a565b5050505b92915050565b6001600160a01b038416156107c5576107c5338560008560405160240161077d91906140ac565b60408051601f198184030181529190526020810180516001600160e01b03167f173bf7da000000000000000000000000000000000000000000000000000000001790526118f5565b6001600160a01b038316156107ec576107ec338460008460405160240161077d91906140ac565b50505050565b60006001850361080c5761080584611994565b9050610847565b6002850361081d57610805846119a2565b60038503610830576108058484846119bb565b6004850361084357610805848484611a08565b5060005b949350505050565b600033821580156108e057506040517f5ae6bd37000000000000000000000000000000000000000000000000000000008152600481018690526001600160a01b03821690635ae6bd3790602401602060405180830381865afa1580156108b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108dd919061439b565b15155b156108f55750630b135d3f60e11b9050610b10565b600061090460148286886143b4565b61090d916143de565b60601c9050801580610925575061092381611994565b155b15610a7b5760006109f0836001600160a01b031663f698da256040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610991919061439b565b60408051602081018b90527f60b3cbf8b4a223d68d641b3b6ddf9a298e7f33710cf3d3a9d1146b5a6150fbca910160408051601f1981840301815282825280516020918201209083015201604051602081830303815290604052611a43565b805160208201209091506001600160a01b03841663934f3a118284610a188a6014818e6143b4565b6040518563ffffffff1660e01b8152600401610a379493929190614413565b60006040518083038186803b158015610a4f57600080fd5b505afa158015610a63573d6000803e3d6000fd5b50630b135d3f60e11b9750610b109650505050505050565b6000610af4338336601319013560601c8a610a998a6014818e6143b4565b604051602401610aac9493929190614249565b60408051601f198184030181529190526020810180516001600160e01b03167ff551e2ee00000000000000000000000000000000000000000000000000000000179052611803565b905080806020019051810190610b0a919061444a565b93505050505b9392505050565b600060131936013560601c6f71727de22e5e9d8baf0edac6f37da03214610b5157604051635629665f60e11b815260040160405180910390fd5b6020840135606081901c90811580610b6f5750610b6d82611994565b155b15610b8457610b7d86611abd565b9250610c02565b6000610be8338460008a8a604051602401610ba09291906144ad565b60408051601f198184030181529190526020810180516001600160e01b03167f970032030000000000000000000000000000000000000000000000000000000017905261175a565b905080806020019051810190610bfe919061439b565b9350505b8315610c3357610c33336f71727de22e5e9d8baf0edac6f37da03286604051806020016040528060008152506118f5565b50509392505050565b610c6e610c4c60208301836145ac565b610c5960208401846145c9565b610c696060860160408701614613565b611b7c565b610c7e8989898989898989611c43565b505050505050505050565b610c94600233611e9f565b8060005b818110156107ec5736848483818110610cb357610cb361462e565b9050602002810190610cc59190614644565b9050610ce133610cd860208401846145ac565b60029190611f1a565b50600101610c98565b60606000610cfb600233868661200f565b915091509250929050565b3360009081526005602090815260408083205460068352818420639517e29f60e01b80865293529083205491926001600160a01b03918216929091169080610d4e848461052b565b91509150606060018a03610d6e57610d678989896121d4565b9050610dec565b60028a03610d8157610d67898989612230565b60038a03610d9457610d6789898961229a565b60048a03610da757610d67898989612457565b89610db757610d678989896125ef565b6040517f41c38b30000000000000000000000000000000000000000000000000000000008152600481018b905260240161068b565b600054604051610e459133916001600160a01b0390911690610e16908e908e908790602401614664565b60408051601f198184030181529190526020810180516001600160e01b0316639517e29f60e01b179052612790565b50610c7e84848484610756565b60606000336001600160a01b031663ffa1ad746040518163ffffffff1660e01b8152600401600060405180830381865afa158015610e94573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ebc919081019061468c565b905080604051602001610ecf91906146d5565b60405160208183030381529060405291505090565b33600090815260056020908152604080832054600683528184207fa71763a80000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b03918216929091169080610f45848461052b565b91509150610f606f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031636601319013560601c6001600160a01b03161480610f8e57503360131936013560601c145b610fab57604051635629665f60e11b815260040160405180910390fd5b606060018a03610fc757610fc0898989612829565b9050611000565b60028a03610fda57610fc0898989612852565b60038a03610fed57610fc089898961287f565b60048a03610db757610fc08989896128cd565b600054604051610e459133916001600160a01b039091169061102a908e908e908790602401614664565b60408051601f198184030181529190526020810180516001600160e01b03167f7827252500000000000000000000000000000000000000000000000000000000179052612985565b600081600881901b6001600160f81b03198216600160f81b0361109857600192506110d4565b6001600160f81b031982166110b057600192506110d4565b6001600160f81b0319808316036110ca57600192506110d4565b5060009392505050565b8280156110e957506001600160f81b03198116155b156110f5575050919050565b82801561110f57506001600160f81b03198116600160f81b145b156110ca575050919050565b606061112d366013190135821c6119a2565b61116d576040517fb927fe5e00000000000000000000000000000000000000000000000000000000815260131936013560601c600482015260240161068b565b33600090815260056020908152604080832054600683528184207fd691c9640000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b039182169290911690806111ce848461052b565b915091503360026111df8282612a4d565b8a600881901b6111f181838e8e612af1565b99505050505061120384848484610756565b50505050509392505050565b6000602082901b77ffffffffffffffffffffffffffffffffffffffff00000000166f71727de22e5e9d8baf0edac6f37da0326040517f35567e1a0000000000000000000000000000000000000000000000000000000081526001600160a01b03868116600483015277ffffffffffffffffffffffffffffffffffffffffffffffff8416602483015291909116906335567e1a90604401602060405180830381865afa1580156112c2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610847919061439b565b33600090815260056020908152604080832054600683528184207fe9ae5c530000000000000000000000000000000000000000000000000000000080865293529083205491926001600160a01b03918216929091169080611347848461052b565b915091506113626f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031636601319013560601c6001600160a01b0316148061139057503360131936013560601c145b6113ad57604051635629665f60e11b815260040160405180910390fd5b87600881901b336001600160f81b0319821661151c576001600160f81b03198316600160f81b036113f45789358a016020810190356113ed838383612ea4565b5050611672565b6001600160f81b03198316611466576000803660006114138e8e612f14565b935093509350935061145d85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506118f592505050565b50505050611672565b6001600160f81b0319808416036114f75760006114866014828c8e6143b4565b61148f916143de565b60601c90503660008c8c60149080926114aa939291906143b4565b915091506114ef848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061279092505050565b505050611672565b604051632e5bf3f960e21b81526001600160f81b03198416600482015260240161068b565b6001600160f81b03198216600160f81b0361164d576001600160f81b03198316600160f81b0361155b5789358a016020810190356113ed838383612f65565b6001600160f81b031983166115c45760008036600061157a8e8e612f14565b935093509350935061145d85858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612fd592505050565b6001600160f81b0319808416036114f75760006115e46014828c8e6143b4565b6115ed916143de565b60601c90503660008c8c6014908092611608939291906143b4565b915091506114ef848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061298592505050565b6040516308c3ee0360e11b81526001600160f81b03198316600482015260240161068b565b50505061168184848484610756565b5050505050505050565b336000908152600360205260408120606091906116a981868661309d565b92509250509250929050565b60131936013560601c6f71727de22e5e9d8baf0edac6f37da03214806116e257503360131936013560601c145b6116ff57604051635629665f60e11b815260040160405180910390fd5b6107ec84848484611b7c565b60006001820361171d57506001919050565b6002820361172d57506001919050565b6003820361173d57506001919050565b6004820361174d57506001919050565b506000919050565b919050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b81526004016117919493929190614741565b6000604051808303816000875af11580156117b0573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526117d8919081019061478d565b92509050806117fa57604051632b3f6d1160e21b815260040160405180910390fd5b50949350505050565b60606000838360405160240161181a9291906147db565b60408051601f198184030181529181526020820180516001600160e01b03167f6a221657000000000000000000000000000000000000000000000000000000001790526000805491519293509161187f916001600160a01b03169084906024016147db565b60408051601f19818403018152919052602080820180516001600160e01b03167fb4faba090000000000000000000000000000000000000000000000000000000017815282519293509091600091895afa5060203d036040519350808401604052806020853e50600051610c3357825160208401fd5b60405163468721a760e01b81526000906001600160a01b0386169063468721a79061192a908790879087908790600401614741565b6020604051808303816000875af1158015611949573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061196d91906147fd565b90508061198d57604051632b3f6d1160e21b815260040160405180910390fd5b5050505050565b60006107506002338461324a565b336000908152600360205260408120610b10818461328e565b6000806119ca838501856140d5565b3360009081526004602090815260408083206001600160e01b0319909416835292905220546001600160a01b03908116908616149150509392505050565b60008080611a1884860186614827565b915091506000611a2883836132c8565b6001600160a01b039081169088161493505050509392505050565b6060601960f81b600160f81b858585604051602001611a63929190614853565b60408051808303601f190181529082905280516020918201206001600160f81b0319958616918301919091529290931660218401526022830152604282015260620160405160208183030381529060405290509392505050565b600080600080366000611acf87613360565b845160208601206040517f934f3a11000000000000000000000000000000000000000000000000000000008152959a5093985091965094509250339163934f3a1191611b2391899087908790600401614413565b60006040518083038186803b158015611b3b57600080fd5b505afa925050508015611b4c575060015b611b6357611b5c600184866135e5565b9550611b72565b611b6f600084866135e5565b95505b5050505050919050565b3360008181526001602052604080822080546001600160a01b0319166001600160a01b03891617905551611c0792918791611bbf90869089908990602401614879565b60408051601f198184030181529190526020810180516001600160e01b03167ff05c04e1000000000000000000000000000000000000000000000000000000001790526118f5565b6040516001600160a01b0385169033907f9452c8fb077c3ea8f28a77c87488af657b1e44d010ad9a5992d73870da040e9490600090a350505050565b3360009081527fe90b7bceb6e7df5418fb78d8ee546e97c83a08bbccc01a0644d599ccd2a7c2e0602052604090205487906001600160a01b0316611cf057611c8c600233611e9f565b60005b81811015611cea57368a8a83818110611caa57611caa61462e565b9050602002810190611cbc9190614644565b9050611ce0611cce60208301836145ac565b611cdb60208401846148d4565b6121d4565b5050600101611c8f565b50611d2a565b8015611d2a576040517fd8e3ed1b00000000000000000000000000000000000000000000000000000000815233600482015260240161068b565b336000908152600360205260409020611d428161361d565b86915060005b82811015611da35736898983818110611d6357611d6361462e565b9050602002810190611d759190614644565b9050611d99611d8760208301836145ac565b611d9460208401846148d4565b612230565b5050600101611d48565b5084915060005b82811015611e055736878783818110611dc557611dc561462e565b9050602002810190611dd79190614644565b9050611dfb611de960208301836145ac565b611df660208401846148d4565b61229a565b5050600101611daa565b5082915060005b82811015611e675736858583818110611e2757611e2761462e565b9050602002810190611e399190614644565b9050611e5d611e4b60208301836145ac565b611e5860208401846148d4565b612457565b5050600101611e0c565b5060405133907ff48581d8a62b775b74f2fb67f1d5806a9a356fbcc598040ab3071d3e37af40c290600090a250505050505050505050565b60016000908152602083815260408083206001600160a01b0380861685529252909120541615611ee2576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602093845260408082206001600160a01b0394909416825292909352912080546001600160a01b0319169091179055565b6001600160a01b0381161580611f3957506001600160a01b0381166001145b15611f6257604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b0381811660009081526020858152604080832086851684529091529020541615611fb157604051631034f46960e21b81526001600160a01b038216600482015260240161068b565b60016000908152602084815260408083206001600160a01b039586168085528184528285208054968816808752988552838620918652908452919093208054949095166001600160a01b031994851617909455528154169091179055565b606060006001600160a01b038416600114801590612035575061203386868661324a565b155b1561205e57604051637c84ecfb60e01b81526001600160a01b038516600482015260240161068b565b8260000361207f5760405163f725081760e01b815260040160405180910390fd5b8267ffffffffffffffff8111156120985761209861427c565b6040519080825280602002602001820160405280156120c1578160200160208202803683370190505b506001600160a01b038086166000908152602089815260408083208a85168452909152812054929450911691505b6001600160a01b0382161580159061211157506001600160a01b038216600114155b801561211c57508381105b1561218157818382815181106121345761213461462e565b6001600160a01b039283166020918202929092018101919091529281166000908152888452604080822089841683529094529290922054909116908061217981614931565b9150506120ef565b6001600160a01b03821660011480159061219b5750600081115b156121c757826121ac60018361494a565b815181106121bc576121bc61462e565b602002602001015191505b8083525094509492505050565b60608360016121e38282612a4d565b6121ef60023388611f1a565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929998505050505050505050565b606083600261223f8282612a4d565b336000908152600360205260409020612258818861367a565b85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929a9950505050505050505050565b60608360036122a98282612a4d565b600080806122b9878901896149ae565b919450925090506001600160e01b031983167f6d61fe7000000000000000000000000000000000000000000000000000000000148061232157506001600160e01b031983167f8a91b0e300000000000000000000000000000000000000000000000000000000145b15612364576040517f79bd117b0000000000000000000000000000000000000000000000000000000081526001600160e01b03198416600482015260240161068b565b3360009081526004602090815260408083206001600160e01b0319871684529091529020546001600160a01b0316156123d5576040517f74420d150000000000000000000000000000000000000000000000000000000081526001600160e01b03198416600482015260240161068b565b3360009081526004602090815260408083206001600160e01b031990961683529490529290922080546001600160a01b038a166001600160a01b031960f89490941c600160a01b02939093167fffffffffffffffffffffff00000000000000000000000000000000000000000090911617919091179055925050509392505050565b60608360046124668282612a4d565b6000808061247687890189614a1d565b9194509250905060008084600181111561249257612492614a4b565b1480156124a757506001600160e01b03198316155b1561251d5750336000908152600560205260409020546001600160a01b031680156124f05760405163741cbe0360e01b81526001600160a01b038216600482015260240161068b565b33600090815260056020526040902080546001600160a01b0319166001600160a01b038c161790556125e2565b600184600181111561253157612531614a4b565b036125b0576001600160a01b038116156125695760405163741cbe0360e01b81526001600160a01b038216600482015260240161068b565b503360009081526006602090815260408083206001600160e01b031986168452909152902080546001600160a01b038b81166001600160a01b0319831617909255166125e2565b6040517f5691922f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5098975050505050505050565b60608235830160208181019135908581013586018082019190359060408801358801908101903584838114612650576040517fb4fa3fb300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8181101561274957600088888381811061266f5761266f61462e565b905060200201359050600181036126ae576126a88d8888858181106126965761269661462e565b9050602002810190611cdb91906148d4565b50612740565b600281036126de576126a88d8888858181106126cc576126cc61462e565b9050602002810190611d9491906148d4565b6003810361270e576126a88d8888858181106126fc576126fc61462e565b9050602002810190611df691906148d4565b600481036127405761273e8d88888581811061272c5761272c61462e565b9050602002810190611e5891906148d4565b505b50600101612653565b5082828080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929e9d5050505050505050505050505050565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906127c690869085908790600190600401614741565b6020604051808303816000875af11580156127e5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061280991906147fd565b9050806107ec57604051632b3f6d1160e21b815260040160405180910390fd5b6060600061283983850185614a61565b9250905061284a6002338388613750565b509392505050565b33600090815260036020526040812060609161287084860186614a61565b93509050610c33828288613847565b6060600061288f83850185614aa7565b3360009081526004602090815260408083206001600160e01b031990951683529390529190912080546001600160a01b031916905595945050505050565b60606000806128de84860186614a1d565b9450909250905060008260018111156128f9576128f9614a4b565b14801561290e57506001600160e01b03198116155b156129355733600090815260056020526040902080546001600160a01b0319169055610c33565b600182600181111561294957612949614a4b565b036125b0573360009081526006602090815260408083206001600160e01b031985168452909152902080546001600160a01b0319169055610c33565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906129bb90869085908790600190600401614741565b6020604051808303816000875af11580156129da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129fe91906147fd565b9050806107ec57604080516001600160a01b0386168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a150505050565b336000908152600160205260409020546001600160a01b03168015612aec576040517f529562a10000000000000000000000000000000000000000000000000000000081523360048201526001600160a01b0384811660248301526044820184905282169063529562a19060640160006040518083038186803b158015612ad357600080fd5b505afa158015612ae7573d6000803e3d6000fd5b505050505b505050565b60606001600160f81b03198516612cee576001600160f81b03198416600160f81b03612b355782358301602081019035612b2c33838361391c565b92505050610847565b6001600160f81b03198416612bf357600080366000612b548787612f14565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612b73579050509450612bcc33858585858080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175a92505050565b85600081518110612bdf57612bdf61462e565b602002602001018190525050505050610847565b6001600160f81b031980851603612cc9576000612c1360148285876143b4565b612c1c916143de565b60601c9050366000612c3185601481896143b4565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612c4b579050509350612ca3338484848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506139ae92505050565b84600081518110612cb657612cb661462e565b6020026020010181905250505050610847565b604051632e5bf3f960e21b81526001600160f81b03198516600482015260240161068b565b6001600160f81b03198516600160f81b03612e7f576001600160f81b03198416600160f81b03612d385782358301602081019035612d2d338383613a4f565b935061084792505050565b6001600160f81b03198416612dcf57600080366000612d578787612f14565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612d76579050509450612bcc33858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613aea92505050565b6001600160f81b031980851603612cc9576000612def60148285876143b4565b612df8916143de565b60601c9050366000612e0d85601481896143b4565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612e27579050509350612ca3338484848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250613bbc92505050565b6040516308c3ee0360e11b81526001600160f81b03198616600482015260240161068b565b600054604051612aec9185916001600160a01b0390911690612ecc9086908690602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f3f707e6b00000000000000000000000000000000000000000000000000000000179052612790565b6000803681612f2660148287896143b4565b612f2f916143de565b60601c9350612f426034601487896143b4565b612f4b91614b70565b9250612f5a85603481896143b4565b949793965094505050565b600054604051612aec9185916001600160a01b0390911690612f8d9086908690602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f50c8902200000000000000000000000000000000000000000000000000000000179052612985565b60405163468721a760e01b81526000906001600160a01b0386169063468721a79061300a908790879087908790600401614741565b6020604051808303816000875af1158015613029573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061304d91906147fd565b90508061198d57604080516001600160a01b0387168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a15050505050565b606060006001600160a01b0384166001148015906130c257506130c0858561328e565b155b156130eb57604051637c84ecfb60e01b81526001600160a01b038516600482015260240161068b565b8260000361310c5760405163f725081760e01b815260040160405180910390fd5b8267ffffffffffffffff8111156131255761312561427c565b60405190808252806020026020018201604052801561314e578160200160208202803683370190505b506001600160a01b03808616600090815260208890526040812054929450911691505b6001600160a01b0382161580159061319357506001600160a01b038216600114155b801561319e57508381105b156131f857818382815181106131b6576131b661462e565b6001600160a01b0392831660209182029290920181019190915292811660009081529287905260409092205490911690806131f081614931565b915050613171565b6001600160a01b0382166001148015906132125750600081115b1561323e578261322360018361494a565b815181106132335761323361462e565b602002602001015191505b80835250935093915050565b600060016001600160a01b038316148015906108475750506001600160a01b0390811660009081526020938452604080822093831682529290935291205416151590565b600060016001600160a01b03831614801590610b105750506001600160a01b03908116600090815260209290925260409091205416151590565b6000808360018111156132dd576132dd614a4b565b1480156132f257506001600160e01b03198216155b156133125750336000908152600560205260409020546001600160a01b03165b600183600181111561332657613326614a4b565b0361075057503360009081526006602090815260408083206001600160e01b0319851684529091529020546001600160a01b031692915050565b6060600080368181816133776101008901896148d4565b909250905061338a6006600083856143b4565b61339391614b8e565b60d01c95506133a6600c600683856143b4565b6133af91614b8e565b60d01c94506133c181600c81856143b4565b9350935050506000604051806101c001604052807f84aa190356f56b8c87825f54884392a9907c23ee0f8e1ea86336b763faf021bd60001b8152602001336001600160a01b031681526020018860200135815260200188806040019061342791906148d4565b604051613435929190614bd4565b604051908190039020815260200161345060608a018a6148d4565b60405161345e929190614bd4565b6040518091039020815260200161347489613c8e565b815260200161348289613cac565b81526020018860a00135815260200161349a89613cbc565b81526020016134a889613cda565b81526020016134ba60e08a018a6148d4565b6040516134c8929190614bd4565b604051809103902081526020018665ffffffffffff1681526020018565ffffffffffff1681526020016135086f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031690526101c081209091507f1900000000000000000000000000000000000000000000000000000000000000600160f81b61359d604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b6040516001600160f81b031993841660208201529290911660218301526022820152604281018290526062016040516020818303038152906040529650505091939590929450565b600060d08265ffffffffffff16901b60a08465ffffffffffff16901b8561360d576000613610565b60015b60ff161717949350505050565b60016000908152602082905260409020546001600160a01b031615613655576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602092909252604090912080546001600160a01b0319169091179055565b6001600160a01b038116158061369957506001600160a01b0381166001145b156136c257604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b03818116600090815260208490526040902054161561370657604051631034f46960e21b81526001600160a01b038216600482015260240161068b565b60016000818152602093909352604080842080546001600160a01b039485168087529286208054959091166001600160a01b03199586161790559190935280549091169091179055565b6001600160a01b038116158061376f57506001600160a01b0381166001145b1561379857604051637c84ecfb60e01b81526001600160a01b038316600482015260240161068b565b6001600160a01b0382811660009081526020868152604080832087851684529091529020548116908216146137eb57604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b039081166000908152602085815260408083209584168084528683528184208054968616855297835281842090845282529091208054939092166001600160a01b031993841617909155919091528154169055565b6001600160a01b038116158061386657506001600160a01b0381166001145b1561388f57604051637c84ecfb60e01b81526001600160a01b038316600482015260240161068b565b6001600160a01b038281166000908152602085905260409020548116908216146138d757604051637c84ecfb60e01b81526001600160a01b038216600482015260240161068b565b6001600160a01b0390811660008181526020949094526040808520805494841686529085208054949093166001600160a01b0319948516179092559092528154169055565b600080546040516060929161398f9187916001600160a01b0316906139479088908890602401614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f61085573000000000000000000000000000000000000000000000000000000001790526139ae565b9050808060200190518101906139a59190614c93565b95945050505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016139e69493929190614741565b6000604051808303816000875af1158015613a05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613a2d919081019061478d565b925090508061284a57604051632b3f6d1160e21b815260040160405180910390fd5b6060806000613ac78660008054906101000a90046001600160a01b03168787604051602401613a7f929190614ac5565b60408051601f198184030181529190526020810180516001600160e01b03167f9abb6e1700000000000000000000000000000000000000000000000000000000179052613bbc565b905080806020019051810190613add9190614cc8565b9097909650945050505050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b8152600401613b219493929190614741565b6000604051808303816000875af1158015613b40573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613b68919081019061478d565b92509050806117fa57604080516001600160a01b0388168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a150949350505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b8152600401613bf49493929190614741565b6000604051808303816000875af1158015613c13573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052613c3b919081019061478d565b925090508061284a57604080516001600160a01b0387168152600060208201527fb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792ac910160405180910390a1509392505050565b60006fffffffffffffffffffffffffffffffff608083013516610750565b6000610750826080013560801c90565b60006fffffffffffffffffffffffffffffffff60c083013516610750565b600060c082013560801c610750565b6001600160a01b0381168114613cfe57600080fd5b50565b803561175581613ce9565b60008083601f840112613d1e57600080fd5b50813567ffffffffffffffff811115613d3657600080fd5b60208301915083602082850101111561060357600080fd5b60008060008060608587031215613d6457600080fd5b843593506020850135613d7681613ce9565b9250604085013567ffffffffffffffff811115613d9257600080fd5b613d9e87828801613d0c565b95989497509550505050565b600080600060408486031215613dbf57600080fd5b83359250602084013567ffffffffffffffff811115613ddd57600080fd5b613de986828701613d0c565b9497909650939450505050565b600080600060608486031215613e0b57600080fd5b833567ffffffffffffffff811115613e2257600080fd5b84016101208187031215613e3557600080fd5b95602085013595506040909401359392505050565b60008083601f840112613e5c57600080fd5b50813567ffffffffffffffff811115613e7457600080fd5b6020830191508360208260051b850101111561060357600080fd5b600060608284031215613ea157600080fd5b50919050565b600080600080600080600080600060a08a8c031215613ec557600080fd5b893567ffffffffffffffff80821115613edd57600080fd5b613ee98d838e01613e4a565b909b50995060208c0135915080821115613f0257600080fd5b613f0e8d838e01613e4a565b909950975060408c0135915080821115613f2757600080fd5b613f338d838e01613e4a565b909750955060608c0135915080821115613f4c57600080fd5b613f588d838e01613e4a565b909550935060808c0135915080821115613f7157600080fd5b50613f7e8c828d01613e8f565b9150509295985092959850929598565b60008060208385031215613fa157600080fd5b823567ffffffffffffffff811115613fb857600080fd5b613fc485828601613e4a565b90969095509350505050565b60008060408385031215613fe357600080fd5b8235613fee81613ce9565b946020939093013593505050565b604080825283519082018190526000906020906060840190828701845b8281101561403e5781516001600160a01b031684529284019290840190600101614019565b50505080925050506001600160a01b03831660208301529392505050565b60005b8381101561407757818101518382015260200161405f565b50506000910152565b6000815180845261409881602086016020860161405c565b601f01601f19169290920160200192915050565b602081526000610b106020830184614080565b6001600160e01b031981168114613cfe57600080fd5b6000602082840312156140e757600080fd5b8135610b10816140bf565b60006020828403121561410457600080fd5b5035919050565b600060208083016020845280855180835260408601915060408160051b87010192506020870160005b8281101561416257603f19888603018452614150858351614080565b94509285019290850190600101614134565b5092979650505050505050565b6000806040838503121561418257600080fd5b823561418d81613ce9565b9150602083013561419d81613ce9565b809150509250929050565b803560ff8116811461175557600080fd5b600080600080606085870312156141cf57600080fd5b84356141da81613ce9565b9350602085013567ffffffffffffffff8111156141f657600080fd5b61420287828801613e4a565b90945092506142159050604086016141a8565b905092959194509250565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b6001600160a01b0385168152836020820152606060408201526000614272606083018486614220565b9695505050505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156142bb576142bb61427c565b604052919050565b600067ffffffffffffffff8211156142dd576142dd61427c565b50601f01601f191660200190565b60006142fe6142f9846142c3565b614292565b905082815283838301111561431257600080fd5b610b1083602083018461405c565b600082601f83011261433157600080fd5b610b10838351602085016142eb565b60006020828403121561435257600080fd5b815167ffffffffffffffff81111561436957600080fd5b61084784828501614320565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000602082840312156143ad57600080fd5b5051919050565b600080858511156143c457600080fd5b838611156143d157600080fd5b5050820193919092039150565b6bffffffffffffffffffffffff19813581811691601485101561440b5780818660140360031b1b83161692505b505092915050565b84815260606020820152600061442c6060830186614080565b828103604084015261443f818587614220565b979650505050505050565b60006020828403121561445c57600080fd5b8151610b10816140bf565b6000808335601e1984360301811261447e57600080fd5b830160208101925035905067ffffffffffffffff81111561449e57600080fd5b80360382131561060357600080fd5b604081526144ce604082016144c185613d01565b6001600160a01b03169052565b6020830135606082015260006144e76040850185614467565b6101208060808601526144ff61016086018385614220565b925061450e6060880188614467565b9250603f19808786030160a0880152614528858584614220565b9450608089013560c088015260a089013560e0880152610100935060c08901358488015261455960e08a018a614467565b925081888703018489015261456f868483614220565b95505061457e848a018a614467565b945092508087860301610140880152505061459a838383614220565b93505050508260208301529392505050565b6000602082840312156145be57600080fd5b8135610b1081613ce9565b6000808335601e198436030181126145e057600080fd5b83018035915067ffffffffffffffff8211156145fb57600080fd5b6020019150600581901b360382131561060357600080fd5b60006020828403121561462557600080fd5b610b10826141a8565b634e487b7160e01b600052603260045260246000fd5b60008235603e1983360301811261465a57600080fd5b9190910192915050565b8381526001600160a01b03831660208201526060604082015260006139a56060830184614080565b60006020828403121561469e57600080fd5b815167ffffffffffffffff8111156146b557600080fd5b8201601f810184136146c657600080fd5b610847848251602084016142eb565b7f736166652d00000000000000000000000000000000000000000000000000000081526000825161470d81600585016020870161405c565b7f2e657263373537392e76302e302e3100000000000000000000000000000000006005939091019283015250601401919050565b6001600160a01b03851681528360208201526080604082015260006147696080830185614080565b905060ff8316606083015295945050505050565b8051801515811461175557600080fd5b600080604083850312156147a057600080fd5b6147a98361477d565b9150602083015167ffffffffffffffff8111156147c557600080fd5b6147d185828601614320565b9150509250929050565b6001600160a01b03831681526040602082015260006108476040830184614080565b60006020828403121561480f57600080fd5b610b108261477d565b80356002811061175557600080fd5b6000806040838503121561483a57600080fd5b61484383614818565b9150602083013561419d816140bf565b8281526000825161486b81602085016020870161405c565b919091016020019392505050565b60ff8416815260406020808301829052908201839052600090849060608401835b868110156148c85783356148ad81613ce9565b6001600160a01b03168252928201929082019060010161489a565b50979650505050505050565b6000808335601e198436030181126148eb57600080fd5b83018035915067ffffffffffffffff82111561490657600080fd5b60200191503681900382131561060357600080fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016149435761494361491b565b5060010190565b818103818111156107505761075061491b565b600082601f83011261496e57600080fd5b813561497c6142f9826142c3565b81815284602083860101111561499157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000606084860312156149c357600080fd5b83356149ce816140bf565b925060208401356001600160f81b0319811681146149eb57600080fd5b9150604084013567ffffffffffffffff811115614a0757600080fd5b614a138682870161495d565b9150509250925092565b600080600060608486031215614a3257600080fd5b614a3b84614818565b925060208401356149eb816140bf565b634e487b7160e01b600052602160045260246000fd5b60008060408385031215614a7457600080fd5b8235614a7f81613ce9565b9150602083013567ffffffffffffffff811115614a9b57600080fd5b6147d18582860161495d565b60008060408385031215614aba57600080fd5b8235614a7f816140bf565b60208082528181018390526000906040808401600586901b850182018785805b89811015614b6157888403603f190185528235368c9003605e19018112614b0a578283fd5b8b0160608135614b1981613ce9565b6001600160a01b031686528189013589870152614b3888830183614467565b92508189880152614b4c8288018483614220565b978a0197965050509287019250600101614ae5565b50919998505050505050505050565b8035602083101561075057600019602084900360031b1b1692915050565b7fffffffffffff0000000000000000000000000000000000000000000000000000813581811691600685101561440b5760069490940360031b84901b1690921692915050565b8183823760009101908152919050565b600067ffffffffffffffff821115614bfe57614bfe61427c565b5060051b60200190565b600082601f830112614c1957600080fd5b81516020614c296142f983614be4565b82815260059290921b84018101918181019086841115614c4857600080fd5b8286015b84811015614c8857805167ffffffffffffffff811115614c6c5760008081fd5b614c7a8986838b0101614320565b845250918301918301614c4c565b509695505050505050565b600060208284031215614ca557600080fd5b815167ffffffffffffffff811115614cbc57600080fd5b61084784828501614c08565b60008060408385031215614cdb57600080fd5b825167ffffffffffffffff80821115614cf357600080fd5b818501915085601f830112614d0757600080fd5b81516020614d176142f983614be4565b82815260059290921b84018101918181019089841115614d3657600080fd5b948201945b83861015614d5b57614d4c8661477d565b82529482019490820190614d3b565b91880151919650909350505080821115614d7457600080fd5b506147d185828601614c0856fea2646970667358221220310490ce1c9ce1b361eae1667f3c75f8c90f8265fa8bcd2024bdff0a007dc05564736f6c63430008170033",linkReferences$1={},deployedLinkReferences$1={},Safe7579={_format:_format$1,contractName:contractName$1,sourceName:sourceName$1,abi:abi$3,bytecode:bytecode$3,deployedBytecode:deployedBytecode$3,linkReferences:linkReferences$1,deployedLinkReferences:deployedLinkReferences$1},_format="hh-sol-artifact-1",contractName="SpendLimitModule",sourceName="contracts/spendlimit/SpendLimitModule.sol",abi$2=[{inputs:[{internalType:"address",name:"smartAccount",type:"address"}],name:"AlreadyInitialized",type:"error"},{inputs:[],name:"ExecutionFailed",type:"error"},{inputs:[{internalType:"address",name:"smartAccount",type:"address"}],name:"NotInitialized",type:"error"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sessionKey",type:"address"},{indexed:!0,internalType:"address",name:"account",type:"address"}],name:"SessionKeyAdded",type:"event"},{inputs:[{internalType:"address",name:"sessionKey",type:"address"},{components:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"account",type:"address"},{internalType:"uint48",name:"validAfter",type:"uint48"},{internalType:"uint48",name:"validUntil",type:"uint48"},{internalType:"uint256",name:"limitAmount",type:"uint256"},{internalType:"uint256",name:"limitUsed",type:"uint256"},{internalType:"uint48",name:"lastUsed",type:"uint48"},{internalType:"uint48",name:"refreshInterval",type:"uint48"}],internalType:"struct SpendLimitModule.SessionData",name:"sessionData",type:"tuple"}],name:"addSessionKey",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"sessionKey",type:"address"},{internalType:"uint256",name:"sessionId",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"execute",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"sessionKey",type:"address"}],name:"getSessionData",outputs:[{components:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"account",type:"address"},{internalType:"uint48",name:"validAfter",type:"uint48"},{internalType:"uint48",name:"validUntil",type:"uint48"},{internalType:"uint256",name:"limitAmount",type:"uint256"},{internalType:"uint256",name:"limitUsed",type:"uint256"},{internalType:"uint48",name:"lastUsed",type:"uint48"},{internalType:"uint48",name:"refreshInterval",type:"uint48"}],internalType:"struct SpendLimitModule.SessionData[]",name:"",type:"tuple[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"smartAccount",type:"address"}],name:"isInitialized",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"typeID",type:"uint256"}],name:"isModuleType",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"bytes32",name:"hash",type:"bytes32"},{internalType:"bytes",name:"data",type:"bytes"}],name:"isValidSignatureWithSender",outputs:[{internalType:"bytes4",name:"",type:"bytes4"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"bytes",name:"data",type:"bytes"}],name:"onInstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes",name:"",type:"bytes"}],name:"onUninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"uint256",name:"",type:"uint256"}],name:"sessionKeys",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"account",type:"address"},{internalType:"uint48",name:"validAfter",type:"uint48"},{internalType:"uint48",name:"validUntil",type:"uint48"},{internalType:"uint256",name:"limitAmount",type:"uint256"},{internalType:"uint256",name:"limitUsed",type:"uint256"},{internalType:"uint48",name:"lastUsed",type:"uint48"},{internalType:"uint48",name:"refreshInterval",type:"uint48"}],stateMutability:"view",type:"function"},{inputs:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct PackedUserOperation",name:"userOp",type:"tuple"},{internalType:"bytes32",name:"userOpHash",type:"bytes32"}],name:"validateUserOp",outputs:[{internalType:"ERC7579ValidatorBase.ValidationData",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"pure",type:"function"}],bytecode$2="0x6080806040523461001657610f4f908161001c8239f35b600080fdfe60806040908082526004918236101561001757600080fd5b60009160e08335811c91826306fdde0314610b72575081633933fee6146109365781634fe05a511461064e57816354fd4d50146105ed57816368b57a24146105455781636d61fe70146105405781638a91b0e31461054057816397003203146102dc578163ced202321461015457508063d60b347f1461012f578063ecd05961146100f65763f551e2ee146100ab57600080fd5b346100f25760603660031901126100f2576100c4610c17565b5060443567ffffffffffffffff81116100ee576020936100e691369101610cb9565b505051908152f35b8280fd5b5080fd5b5082346100ee5760203660031901126100ee5760209250359060018214918215610124575b50519015158152f35b60021491508361011b565b50346100f25760203660031901126100f2579060209161014d610c17565b5051908152f35b905083346102d8576020806003193601126102d4576001600160a01b03939185918561017e610c17565b16835282815283832093845461019381610dd2565b936101a083519586610c97565b81855283850190819787528487209087925b8b8585106102515750505050505080519582870193838852518094528187019594915b8483106101e25787870388f35b855180518a168852808501518a16888601528082015165ffffffffffff908116898401526060808301518216908a0152608080830151908a015260a080830151908a015260c0808301518216908a015290830151168783015261010090960195948301946001909201916101d5565b8760019288600593819f9a9d9b9c9d519161026b83610c48565b818954168352868901549182168584015265ffffffffffff9160a0918382841c169085015260d01c6060840152600289015460808401526003890154908301528688015481811660c084015260301c168a820152815201930193019291999499979695976101b2565b8480fd5b8380fd5b5050903461053d5760031982813601126100f257833567ffffffffffffffff81116100ee576101208186019282360301126100ee576024906103216064820184610d9f565b9390968460641161053557606319850180601411610539576034116105355760971985016010116105355760a86103b89801356bffffffffffffffffffffffff199081811696601460a71982011061051d575b505050606094851c806103bf60209a8b9560243587527b19457468657265756d205369676e6564204d6573736167653a0a33328b52610104603c8720980190610d9f565b3691610d68565b958880988689019361040a575b50965050505050505050156000146103f7575065ffffffffffff60a01b60ff6001925b519216178152f35b60ff65ffffffffffff60a01b91926103ef565b909192939495969798508a5193888352518b528a8951146104d1575b604189511461048c575b528189527f1626ba7e0000000000000000000000000000000000000000000000000000000095868352848301528101958693898552815186019081604493848601925afa503d01915afa915114163880858180808088816103cc565b80890151821a87528a890151815260018781608085825afa5186183d1517156104b55750610430565b95509750945050935050925283523880858180808088816103cc565b7f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8b8a0151601b8160ff1c01895216815260018781608085825afa5186183d1517156104b55750610426565b60140360a80160031b82901b16169450388080610374565b8580fd5b8680fd5b80fd5b610d19565b90508391346102d857806003193601126102d857610561610c17565b602435946001600160a01b0380921681528060205282812090815487101561053d57506101009561059191610ce7565b508181541694600182015465ffffffffffff94600284015492600385015494015494815198895282166020890152858260a01c169088015260d01c6060870152608086015260a085015281811660c085015260301c1690820152f35b5050346100f257816003193601126100f257805161064a9161060e82610c7b565b600582527f302e302e31000000000000000000000000000000000000000000000000000000602083015251918291602083526020830190610bf2565b0390f35b505082346100ee5760a03660031901126100ee5761066a610c17565b92610673610c32565b91606435946084359067ffffffffffffffff918281116102d45761069d6106d19136908601610cb9565b9190928915908160001461092f5788915b15610928576106c66106c1368688610d68565b610dea565b905b60243591610e00565b1561090057966106e985926107b19798993691610d68565b968851906020988983019285845285602182015285602282015285602682015285602a8201528a815261071b81610c7b565b519251928a81106108ea575b50610773916054918c519586926bffffffffffffffffffffffff199060601b168d84015260348301526107638c82519283918686019101610bcf565b8101036034810185520183610c97565b885196879283927fd691c964000000000000000000000000000000000000000000000000000000008452878401528a60248401526044830190610bf2565b038183335af19384156108e05783946107fa575b50508251156107e75750508161064a9101519251928284938452830190610bf2565b906032602492634e487b7160e01b835252fd5b909193503d8084833e61080d8183610c97565b81019085818303126102d8578051908382116102d457019080601f830112156102d85781519061083c82610dd2565b9361084989519586610c97565b828552878086019360051b8501019382851161053957888101935b858510610879575050505050509185806107c5565b84518381116108dc57820184603f820112156108dc578a8101518c918661089f83610d4c565b936108ac81519586610c97565b83855283830101116108d857916108cd8d94928f9486958685019101610bcf565b815201940193610864565b8a80fd5b8880fd5b86513d85823e3d90fd5b600019908b0360031b1b90921691610773610727565b8387517facfdb444000000000000000000000000000000000000000000000000000000008152fd5b8a906106c8565b87916106ae565b92919050346100f2576101203660031901126100f257610954610c17565b6101003660231901126100ee5781519361096d85610c48565b6001600160a01b03602435818116810361053557865261098b610c32565b50602086019565ffffffffffff916064358381168103610b6e578683019081526084359084821682036108dc5760608401918252608084019160a435835260a085019360c435855260e43598878a168a03610b6a5760c08701998a526101043598888a168a03610b66579082918801998a528d339052169b8c8c528b6020528a8c2080549068010000000000000000821015610b525790610a3191600182018155610ce7565b979097610b4057828f989796959493927fffffffffffff00000000000000000000000000000000000000000000000000009365ffffffffffff60a01b9351167fffffffffffffffffffffffff00000000000000000000000000000000000000008a54161789555116935160a01b16915160d01b169117176001840155516002830155516003820155019251166bffffffffffff0000000000008354925160301b16916bffffffffffffffffffffffff19161717905580519233817f18181a00afae36a38027e087bdecba0ee3dd48839669ffb2b1484450c703267b8580a3825281602052812054906000198201918211610b2d57602083838152f35b80601185634e487b7160e01b6024945252fd5b634e487b7160e01b8d528c8f5260248dfd5b8f8e6041602492634e487b7160e01b835252fd5b8c80fd5b8b80fd5b8780fd5b849084346100ee57826003193601126100ee5761064a9250610b9382610c7b565b601182527f5370656e644c696d697453657373696f6e000000000000000000000000000000602083015251918291602083526020830190610bf2565b60005b838110610be25750506000910152565b8181015183820152602001610bd2565b90602091610c0b81518092818552858086019101610bcf565b601f01601f1916010190565b600435906001600160a01b0382168203610c2d57565b600080fd5b604435906001600160a01b0382168203610c2d57565b610100810190811067ffffffffffffffff821117610c6557604052565b634e487b7160e01b600052604160045260246000fd5b6040810190811067ffffffffffffffff821117610c6557604052565b90601f8019910116810190811067ffffffffffffffff821117610c6557604052565b9181601f84011215610c2d5782359167ffffffffffffffff8311610c2d5760208381860195010111610c2d57565b8054821015610d03576000526005602060002091020190600090565b634e487b7160e01b600052603260045260246000fd5b34610c2d576020366003190112610c2d5760043567ffffffffffffffff8111610c2d57610d4a903690600401610cb9565b005b67ffffffffffffffff8111610c6557601f01601f191660200190565b929192610d7482610d4c565b91610d826040519384610c97565b829481845281830111610c2d578281602093846000960137010152565b903590601e1981360301821215610c2d570180359067ffffffffffffffff8211610c2d57602001918136038313610c2d57565b67ffffffffffffffff8111610c655760051b60200190565b6044815110610dfa576044015190565b50600090565b92610e216001600160a01b0393846000941684528360205260408420610ce7565b509280845416911603610e97576004820180549265ffffffffffff91828560301c1694600283015493600384019660018854950154828160a01c164210908115610f0c575b50610f00578015908115610ed4575b5015610ea7575050508401938410908115610e9d575b50610e97575055600190565b91505090565b9050831138610e8b565b94919680949196935011610ecb57505542169065ffffffffffff1916179055600190565b94505050505090565b905081831601818111610eec57814291161138610e75565b602487634e487b7160e01b81526011600452fd5b50505050505091505090565b905060d01c421138610e6656fea2646970667358221220ee0a81296f714e84b319efed358c41da873049c8b15d4767b6c65d358075c5cd64736f6c63430008170033",deployedBytecode$2="0x60806040908082526004918236101561001757600080fd5b60009160e08335811c91826306fdde0314610b72575081633933fee6146109365781634fe05a511461064e57816354fd4d50146105ed57816368b57a24146105455781636d61fe70146105405781638a91b0e31461054057816397003203146102dc578163ced202321461015457508063d60b347f1461012f578063ecd05961146100f65763f551e2ee146100ab57600080fd5b346100f25760603660031901126100f2576100c4610c17565b5060443567ffffffffffffffff81116100ee576020936100e691369101610cb9565b505051908152f35b8280fd5b5080fd5b5082346100ee5760203660031901126100ee5760209250359060018214918215610124575b50519015158152f35b60021491508361011b565b50346100f25760203660031901126100f2579060209161014d610c17565b5051908152f35b905083346102d8576020806003193601126102d4576001600160a01b03939185918561017e610c17565b16835282815283832093845461019381610dd2565b936101a083519586610c97565b81855283850190819787528487209087925b8b8585106102515750505050505080519582870193838852518094528187019594915b8483106101e25787870388f35b855180518a168852808501518a16888601528082015165ffffffffffff908116898401526060808301518216908a0152608080830151908a015260a080830151908a015260c0808301518216908a015290830151168783015261010090960195948301946001909201916101d5565b8760019288600593819f9a9d9b9c9d519161026b83610c48565b818954168352868901549182168584015265ffffffffffff9160a0918382841c169085015260d01c6060840152600289015460808401526003890154908301528688015481811660c084015260301c168a820152815201930193019291999499979695976101b2565b8480fd5b8380fd5b5050903461053d5760031982813601126100f257833567ffffffffffffffff81116100ee576101208186019282360301126100ee576024906103216064820184610d9f565b9390968460641161053557606319850180601411610539576034116105355760971985016010116105355760a86103b89801356bffffffffffffffffffffffff199081811696601460a71982011061051d575b505050606094851c806103bf60209a8b9560243587527b19457468657265756d205369676e6564204d6573736167653a0a33328b52610104603c8720980190610d9f565b3691610d68565b958880988689019361040a575b50965050505050505050156000146103f7575065ffffffffffff60a01b60ff6001925b519216178152f35b60ff65ffffffffffff60a01b91926103ef565b909192939495969798508a5193888352518b528a8951146104d1575b604189511461048c575b528189527f1626ba7e0000000000000000000000000000000000000000000000000000000095868352848301528101958693898552815186019081604493848601925afa503d01915afa915114163880858180808088816103cc565b80890151821a87528a890151815260018781608085825afa5186183d1517156104b55750610430565b95509750945050935050925283523880858180808088816103cc565b7f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8b8a0151601b8160ff1c01895216815260018781608085825afa5186183d1517156104b55750610426565b60140360a80160031b82901b16169450388080610374565b8580fd5b8680fd5b80fd5b610d19565b90508391346102d857806003193601126102d857610561610c17565b602435946001600160a01b0380921681528060205282812090815487101561053d57506101009561059191610ce7565b508181541694600182015465ffffffffffff94600284015492600385015494015494815198895282166020890152858260a01c169088015260d01c6060870152608086015260a085015281811660c085015260301c1690820152f35b5050346100f257816003193601126100f257805161064a9161060e82610c7b565b600582527f302e302e31000000000000000000000000000000000000000000000000000000602083015251918291602083526020830190610bf2565b0390f35b505082346100ee5760a03660031901126100ee5761066a610c17565b92610673610c32565b91606435946084359067ffffffffffffffff918281116102d45761069d6106d19136908601610cb9565b9190928915908160001461092f5788915b15610928576106c66106c1368688610d68565b610dea565b905b60243591610e00565b1561090057966106e985926107b19798993691610d68565b968851906020988983019285845285602182015285602282015285602682015285602a8201528a815261071b81610c7b565b519251928a81106108ea575b50610773916054918c519586926bffffffffffffffffffffffff199060601b168d84015260348301526107638c82519283918686019101610bcf565b8101036034810185520183610c97565b885196879283927fd691c964000000000000000000000000000000000000000000000000000000008452878401528a60248401526044830190610bf2565b038183335af19384156108e05783946107fa575b50508251156107e75750508161064a9101519251928284938452830190610bf2565b906032602492634e487b7160e01b835252fd5b909193503d8084833e61080d8183610c97565b81019085818303126102d8578051908382116102d457019080601f830112156102d85781519061083c82610dd2565b9361084989519586610c97565b828552878086019360051b8501019382851161053957888101935b858510610879575050505050509185806107c5565b84518381116108dc57820184603f820112156108dc578a8101518c918661089f83610d4c565b936108ac81519586610c97565b83855283830101116108d857916108cd8d94928f9486958685019101610bcf565b815201940193610864565b8a80fd5b8880fd5b86513d85823e3d90fd5b600019908b0360031b1b90921691610773610727565b8387517facfdb444000000000000000000000000000000000000000000000000000000008152fd5b8a906106c8565b87916106ae565b92919050346100f2576101203660031901126100f257610954610c17565b6101003660231901126100ee5781519361096d85610c48565b6001600160a01b03602435818116810361053557865261098b610c32565b50602086019565ffffffffffff916064358381168103610b6e578683019081526084359084821682036108dc5760608401918252608084019160a435835260a085019360c435855260e43598878a168a03610b6a5760c08701998a526101043598888a168a03610b66579082918801998a528d339052169b8c8c528b6020528a8c2080549068010000000000000000821015610b525790610a3191600182018155610ce7565b979097610b4057828f989796959493927fffffffffffff00000000000000000000000000000000000000000000000000009365ffffffffffff60a01b9351167fffffffffffffffffffffffff00000000000000000000000000000000000000008a54161789555116935160a01b16915160d01b169117176001840155516002830155516003820155019251166bffffffffffff0000000000008354925160301b16916bffffffffffffffffffffffff19161717905580519233817f18181a00afae36a38027e087bdecba0ee3dd48839669ffb2b1484450c703267b8580a3825281602052812054906000198201918211610b2d57602083838152f35b80601185634e487b7160e01b6024945252fd5b634e487b7160e01b8d528c8f5260248dfd5b8f8e6041602492634e487b7160e01b835252fd5b8c80fd5b8b80fd5b8780fd5b849084346100ee57826003193601126100ee5761064a9250610b9382610c7b565b601182527f5370656e644c696d697453657373696f6e000000000000000000000000000000602083015251918291602083526020830190610bf2565b60005b838110610be25750506000910152565b8181015183820152602001610bd2565b90602091610c0b81518092818552858086019101610bcf565b601f01601f1916010190565b600435906001600160a01b0382168203610c2d57565b600080fd5b604435906001600160a01b0382168203610c2d57565b610100810190811067ffffffffffffffff821117610c6557604052565b634e487b7160e01b600052604160045260246000fd5b6040810190811067ffffffffffffffff821117610c6557604052565b90601f8019910116810190811067ffffffffffffffff821117610c6557604052565b9181601f84011215610c2d5782359167ffffffffffffffff8311610c2d5760208381860195010111610c2d57565b8054821015610d03576000526005602060002091020190600090565b634e487b7160e01b600052603260045260246000fd5b34610c2d576020366003190112610c2d5760043567ffffffffffffffff8111610c2d57610d4a903690600401610cb9565b005b67ffffffffffffffff8111610c6557601f01601f191660200190565b929192610d7482610d4c565b91610d826040519384610c97565b829481845281830111610c2d578281602093846000960137010152565b903590601e1981360301821215610c2d570180359067ffffffffffffffff8211610c2d57602001918136038313610c2d57565b67ffffffffffffffff8111610c655760051b60200190565b6044815110610dfa576044015190565b50600090565b92610e216001600160a01b0393846000941684528360205260408420610ce7565b509280845416911603610e97576004820180549265ffffffffffff91828560301c1694600283015493600384019660018854950154828160a01c164210908115610f0c575b50610f00578015908115610ed4575b5015610ea7575050508401938410908115610e9d575b50610e97575055600190565b91505090565b9050831138610e8b565b94919680949196935011610ecb57505542169065ffffffffffff1916179055600190565b94505050505090565b905081831601818111610eec57814291161138610e75565b602487634e487b7160e01b81526011600452fd5b50505050505091505090565b905060d01c421138610e6656fea2646970667358221220ee0a81296f714e84b319efed358c41da873049c8b15d4767b6c65d358075c5cd64736f6c63430008170033",linkReferences={},deployedLinkReferences={},SpendLimitModule={_format,contractName,sourceName,abi:abi$2,bytecode:bytecode$2,deployedBytecode:deployedBytecode$2,linkReferences,deployedLinkReferences},address="0x0000000071727De22E5E9d8BAf0edAc6f37da032",abi$1=[{inputs:[{internalType:"bool",name:"success",type:"bool"},{internalType:"bytes",name:"ret",type:"bytes"}],name:"DelegateAndRevert",type:"error"},{inputs:[{internalType:"uint256",name:"opIndex",type:"uint256"},{internalType:"string",name:"reason",type:"string"}],name:"FailedOp",type:"error"},{inputs:[{internalType:"uint256",name:"opIndex",type:"uint256"},{internalType:"string",name:"reason",type:"string"},{internalType:"bytes",name:"inner",type:"bytes"}],name:"FailedOpWithRevert",type:"error"},{inputs:[{internalType:"bytes",name:"returnData",type:"bytes"}],name:"PostOpReverted",type:"error"},{inputs:[],name:"ReentrancyGuardReentrantCall",type:"error"},{inputs:[{internalType:"address",name:"sender",type:"address"}],name:"SenderAddressResult",type:"error"},{inputs:[{internalType:"address",name:"aggregator",type:"address"}],name:"SignatureValidationFailed",type:"error"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"userOpHash",type:"bytes32"},{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"address",name:"factory",type:"address"},{indexed:!1,internalType:"address",name:"paymaster",type:"address"}],name:"AccountDeployed",type:"event"},{anonymous:!1,inputs:[],name:"BeforeExecution",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!1,internalType:"uint256",name:"totalDeposit",type:"uint256"}],name:"Deposited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"userOpHash",type:"bytes32"},{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"nonce",type:"uint256"},{indexed:!1,internalType:"bytes",name:"revertReason",type:"bytes"}],name:"PostOpRevertReason",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"aggregator",type:"address"}],name:"SignatureAggregatorChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!1,internalType:"uint256",name:"totalStaked",type:"uint256"},{indexed:!1,internalType:"uint256",name:"unstakeDelaySec",type:"uint256"}],name:"StakeLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!1,internalType:"uint256",name:"withdrawTime",type:"uint256"}],name:"StakeUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!1,internalType:"address",name:"withdrawAddress",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeWithdrawn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"userOpHash",type:"bytes32"},{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!0,internalType:"address",name:"paymaster",type:"address"},{indexed:!1,internalType:"uint256",name:"nonce",type:"uint256"},{indexed:!1,internalType:"bool",name:"success",type:"bool"},{indexed:!1,internalType:"uint256",name:"actualGasCost",type:"uint256"},{indexed:!1,internalType:"uint256",name:"actualGasUsed",type:"uint256"}],name:"UserOperationEvent",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"userOpHash",type:"bytes32"},{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"nonce",type:"uint256"}],name:"UserOperationPrefundTooLow",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"userOpHash",type:"bytes32"},{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"nonce",type:"uint256"},{indexed:!1,internalType:"bytes",name:"revertReason",type:"bytes"}],name:"UserOperationRevertReason",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!1,internalType:"address",name:"withdrawAddress",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"Withdrawn",type:"event"},{inputs:[{internalType:"uint32",name:"unstakeDelaySec",type:"uint32"}],name:"addStake",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"target",type:"address"},{internalType:"bytes",name:"data",type:"bytes"}],name:"delegateAndRevert",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"depositTo",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"deposits",outputs:[{internalType:"uint256",name:"deposit",type:"uint256"},{internalType:"bool",name:"staked",type:"bool"},{internalType:"uint112",name:"stake",type:"uint112"},{internalType:"uint32",name:"unstakeDelaySec",type:"uint32"},{internalType:"uint48",name:"withdrawTime",type:"uint48"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"getDepositInfo",outputs:[{components:[{internalType:"uint256",name:"deposit",type:"uint256"},{internalType:"bool",name:"staked",type:"bool"},{internalType:"uint112",name:"stake",type:"uint112"},{internalType:"uint32",name:"unstakeDelaySec",type:"uint32"},{internalType:"uint48",name:"withdrawTime",type:"uint48"}],internalType:"struct IStakeManager.DepositInfo",name:"info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint192",name:"key",type:"uint192"}],name:"getNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"initCode",type:"bytes"}],name:"getSenderAddress",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct PackedUserOperation",name:"userOp",type:"tuple"}],name:"getUserOpHash",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{components:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct PackedUserOperation[]",name:"userOps",type:"tuple[]"},{internalType:"contract IAggregator",name:"aggregator",type:"address"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct IEntryPoint.UserOpsPerAggregator[]",name:"opsPerAggregator",type:"tuple[]"},{internalType:"address payable",name:"beneficiary",type:"address"}],name:"handleAggregatedOps",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}],internalType:"struct PackedUserOperation[]",name:"ops",type:"tuple[]"},{internalType:"address payable",name:"beneficiary",type:"address"}],name:"handleOps",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint192",name:"key",type:"uint192"}],name:"incrementNonce",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes",name:"callData",type:"bytes"},{components:[{components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"uint256",name:"verificationGasLimit",type:"uint256"},{internalType:"uint256",name:"callGasLimit",type:"uint256"},{internalType:"uint256",name:"paymasterVerificationGasLimit",type:"uint256"},{internalType:"uint256",name:"paymasterPostOpGasLimit",type:"uint256"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"address",name:"paymaster",type:"address"},{internalType:"uint256",name:"maxFeePerGas",type:"uint256"},{internalType:"uint256",name:"maxPriorityFeePerGas",type:"uint256"}],internalType:"struct EntryPoint.MemoryUserOp",name:"mUserOp",type:"tuple"},{internalType:"bytes32",name:"userOpHash",type:"bytes32"},{internalType:"uint256",name:"prefund",type:"uint256"},{internalType:"uint256",name:"contextOffset",type:"uint256"},{internalType:"uint256",name:"preOpGas",type:"uint256"}],internalType:"struct EntryPoint.UserOpInfo",name:"opInfo",type:"tuple"},{internalType:"bytes",name:"context",type:"bytes"}],name:"innerHandleOp",outputs:[{internalType:"uint256",name:"actualGasCost",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"uint192",name:"",type:"uint192"}],name:"nonceSequenceNumber",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"unlockStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address payable",name:"withdrawAddress",type:"address"}],name:"withdrawStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address payable",name:"withdrawAddress",type:"address"},{internalType:"uint256",name:"withdrawAmount",type:"uint256"}],name:"withdrawTo",outputs:[],stateMutability:"nonpayable",type:"function"},{stateMutability:"payable",type:"receive"}],args=[],numDeployments=1,bytecode$1="0x60a08060405234620000825760016002556101df8181016001600160401b038111838210176200006c57829162003f2b833903906000f080156200006057608052604051613ea39081620000888239608051818181610d22015261324b0152f35b6040513d6000823e3d90fd5b634e487b7160e01b600052604160045260246000fd5b600080fdfe60806040526004361015610024575b361561001957600080fd5b61002233612748565b005b60003560e01c806242dc5314611b0057806301ffc9a7146119ae5780630396cb60146116765780630bd28e3b146115fa5780631b2e01b814611566578063205c2878146113d157806322cdde4c1461136b57806335567e1a146112b35780635287ce12146111a557806370a0823114611140578063765e827f14610e82578063850aaf6214610dc35780639b249f6914610c74578063b760faf914610c3a578063bb9fe6bf14610a68578063c23a5cea146107c4578063dbed18e0146101a15763fc7e286d0361000e573461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff61013a61229f565b16600052600060205260a0604060002065ffffffffffff6001825492015460405192835260ff8116151560208401526dffffffffffffffffffffffffffff8160081c16604084015263ffffffff8160781c16606084015260981c166080820152f35b600080fd5b3461019c576101af36612317565b906101b86129bd565b60009160005b82811061056f57506101d08493612588565b6000805b8481106102fc5750507fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000809360005b81811061024757610240868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2613ba7565b6001600255005b6102a261025582848a612796565b73ffffffffffffffffffffffffffffffffffffffff6102766020830161282a565b167f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a2806127d6565b906000915b8083106102b957505050600101610209565b909194976102f36102ed6001926102e78c8b6102e0826102da8e8b8d61269d565b9261265a565b5191613597565b90612409565b99612416565b950191906102a7565b6020610309828789612796565b61031f61031682806127d6565b9390920161282a565b9160009273ffffffffffffffffffffffffffffffffffffffff8091165b8285106103505750505050506001016101d4565b909192939561037f83610378610366848c61265a565b516103728b898b61269d565b856129f6565b9290613dd7565b9116840361050a576104a5576103958491613dd7565b9116610440576103b5576103aa600191612416565b96019392919061033c565b60a487604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f65000000000000000000000000000000000000000000000000000000000000006084820152fd5b608488604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413334207369676e6174757265206572726f720000000000000000000000006064820152fd5b608488604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f414132322065787069726564206f72206e6f74206475650000000000000000006064820152fd5b608489604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413234207369676e6174757265206572726f720000000000000000000000006064820152fd5b61057a818487612796565b9361058585806127d6565b919095602073ffffffffffffffffffffffffffffffffffffffff6105aa82840161282a565b1697600192838a1461076657896105da575b5050505060019293949550906105d191612409565b939291016101be565b8060406105e892019061284b565b918a3b1561019c57929391906040519485937f2dd8113300000000000000000000000000000000000000000000000000000000855288604486016040600488015252606490818601918a60051b8701019680936000915b8c83106106e657505050505050838392610684927ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8560009803016024860152612709565b03818a5afa90816106d7575b506106c657602486604051907f86a9f7500000000000000000000000000000000000000000000000000000000082526004820152fd5b93945084936105d1600189806105bc565b6106e0906121bd565b88610690565b91939596977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c908a9294969a0301865288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee18336030181121561019c57836107538793858394016128ec565b9a0196019301909189979695949261063f565b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b3461019c576020807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c576107fc61229f565b33600052600082526001604060002001908154916dffffffffffffffffffffffffffff8360081c16928315610a0a5765ffffffffffff8160981c1680156109ac57421061094e5760009373ffffffffffffffffffffffffffffffffffffffff859485947fffffffffffffff000000000000000000000000000000000000000000000000ff86951690556040517fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda33391806108da8786836020909392919373ffffffffffffffffffffffffffffffffffffffff60408201951681520152565b0390a2165af16108e8612450565b50156108f057005b606490604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b606485604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b606486604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b606485604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b3461019c5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c573360005260006020526001604060002001805463ffffffff8160781c16908115610bdc5760ff1615610b7e5765ffffffffffff908142160191818311610b4f5780547fffffffffffffff000000000000ffffffffffffffffffffffffffffffffffff001678ffffffffffff00000000000000000000000000000000000000609885901b161790556040519116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a2005b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c57610022610c6f61229f565b612748565b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043567ffffffffffffffff811161019c576020610cc8610d1b9236906004016122c2565b919073ffffffffffffffffffffffffffffffffffffffff9260405194859283927f570e1a360000000000000000000000000000000000000000000000000000000084528560048501526024840191612709565b03816000857f0000000000000000000000000000000000000000000000000000000000000000165af1908115610db757602492600092610d86575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b610da991925060203d602011610db0575b610da181836121ed565b8101906126dd565b9083610d56565b503d610d97565b6040513d6000823e3d90fd5b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c57610dfa61229f565b60243567ffffffffffffffff811161019c57600091610e1e839236906004016122c2565b90816040519283928337810184815203915af4610e39612450565b90610e7e6040519283927f99410554000000000000000000000000000000000000000000000000000000008452151560048401526040602484015260448301906123c6565b0390fd5b3461019c57610e9036612317565b610e9b9291926129bd565b610ea483612588565b60005b848110610f1c57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000915b858310610eec576102408585613ba7565b909193600190610f12610f0087898761269d565b610f0a888661265a565b519088613597565b0194019190610edb565b610f47610f40610f2e8385979561265a565b51610f3a84898761269d565b846129f6565b9190613dd7565b73ffffffffffffffffffffffffffffffffffffffff929183166110db5761107657610f7190613dd7565b911661101157610f8657600101929092610ea7565b60a490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f65000000000000000000000000000000000000000000000000000000000000006084820152fd5b608482604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413334207369676e6174757265206572726f720000000000000000000000006064820152fd5b608483604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f414132322065787069726564206f72206e6f74206475650000000000000000006064820152fd5b608484604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413234207369676e6174757265206572726f720000000000000000000000006064820152fd5b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff61118c61229f565b1660005260006020526020604060002054604051908152f35b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff6111f161229f565b6000608060405161120181612155565b828152826020820152826040820152826060820152015216600052600060205260a06040600020608060405161123681612155565b6001835493848352015490602081019060ff8316151582526dffffffffffffffffffffffffffff60408201818560081c16815263ffffffff936060840193858760781c16855265ffffffffffff978891019660981c1686526040519788525115156020880152511660408601525116606084015251166080820152f35b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760206112ec61229f565b73ffffffffffffffffffffffffffffffffffffffff6113096122f0565b911660005260018252604060002077ffffffffffffffffffffffffffffffffffffffffffffffff821660005282526040600020547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b3461019c577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60208136011261019c576004359067ffffffffffffffff821161019c5761012090823603011261019c576113c9602091600401612480565b604051908152f35b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5761140861229f565b60243590336000526000602052604060002090815491828411611508576000808573ffffffffffffffffffffffffffffffffffffffff8295839561144c848a612443565b90556040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af16114a2612450565b50156114aa57005b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5761159d61229f565b73ffffffffffffffffffffffffffffffffffffffff6115ba6122f0565b9116600052600160205277ffffffffffffffffffffffffffffffffffffffffffffffff604060002091166000526020526020604060002054604051908152f35b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043577ffffffffffffffffffffffffffffffffffffffffffffffff811680910361019c5733600052600160205260406000209060005260205260406000206116728154612416565b9055005b6020807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043563ffffffff9182821680920361019c5733600052600081526040600020928215611950576001840154908160781c1683106118f2576116f86dffffffffffffffffffffffffffff9182349160081c16612409565b93841561189457818511611836579065ffffffffffff61180592546040519061172082612155565b8152848101926001845260408201908816815260608201878152600160808401936000855233600052600089526040600020905181550194511515917fffffffffffffffffffffffffff0000000000000000000000000000000000000060ff72ffffffff0000000000000000000000000000006effffffffffffffffffffffffffff008954945160081b16945160781b1694169116171717835551167fffffffffffffff000000000000ffffffffffffffffffffffffffffffffffffff78ffffffffffff0000000000000000000000000000000000000083549260981b169116179055565b6040519283528201527fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c0160403392a2005b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b606482604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b606482604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c576004357fffffffff00000000000000000000000000000000000000000000000000000000811680910361019c57807f60fc6b6e0000000000000000000000000000000000000000000000000000000060209214908115611ad6575b8115611aac575b8115611a82575b8115611a58575b506040519015158152f35b7f01ffc9a70000000000000000000000000000000000000000000000000000000091501482611a4d565b7f3e84f0210000000000000000000000000000000000000000000000000000000081149150611a46565b7fcf28ef970000000000000000000000000000000000000000000000000000000081149150611a3f565b7f915074d80000000000000000000000000000000000000000000000000000000081149150611a38565b3461019c576102007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5767ffffffffffffffff60043581811161019c573660238201121561019c57611b62903690602481600401359101612268565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101c0811261019c5761014060405191611b9e83612155565b1261019c5760405192611bb0846121a0565b60243573ffffffffffffffffffffffffffffffffffffffff8116810361019c578452602093604435858201526064356040820152608435606082015260a435608082015260c43560a082015260e43560c08201526101043573ffffffffffffffffffffffffffffffffffffffff8116810361019c5760e08201526101243561010082015261014435610120820152825261016435848301526101843560408301526101a43560608301526101c43560808301526101e43590811161019c57611c7c9036906004016122c2565b905a3033036120f7578351606081015195603f5a0260061c61271060a0840151890101116120ce5760009681519182611ff0575b5050505090611cca915a9003608085015101923691612268565b925a90600094845193611cdc85613ccc565b9173ffffffffffffffffffffffffffffffffffffffff60e0870151168015600014611ea957505073ffffffffffffffffffffffffffffffffffffffff855116935b5a9003019360a06060820151910151016080860151850390818111611e95575b50508302604085015192818410600014611dce5750506003811015611da157600203611d79576113c99293508093611d7481613d65565b613cf6565b5050507fdeadaa51000000000000000000000000000000000000000000000000000000008152fd5b6024857f4e487b710000000000000000000000000000000000000000000000000000000081526021600452fd5b81611dde92979396940390613c98565b506003841015611e6857507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f60808683015192519473ffffffffffffffffffffffffffffffffffffffff865116948873ffffffffffffffffffffffffffffffffffffffff60e0890151169701519160405192835215898301528760408301526060820152a46113c9565b807f4e487b7100000000000000000000000000000000000000000000000000000000602492526021600452fd5b6064919003600a0204909301928780611d3d565b8095918051611eba575b5050611d1d565b6003861015611fc1576002860315611eb35760a088015190823b1561019c57600091611f2491836040519586809581947f7c627b210000000000000000000000000000000000000000000000000000000083528d60048401526080602484015260848301906123c6565b8b8b0260448301528b60648301520393f19081611fad575b50611fa65787893d610800808211611f9e575b506040519282828501016040528184528284013e610e7e6040519283927fad7954bc000000000000000000000000000000000000000000000000000000008452600484015260248301906123c6565b905083611f4f565b8980611eb3565b611fb89199506121bd565b6000978a611f3c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91600092918380938c73ffffffffffffffffffffffffffffffffffffffff885116910192f115612023575b808080611cb0565b611cca929195503d6108008082116120c6575b5060405190888183010160405280825260008983013e805161205f575b5050600194909161201b565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20188870151918973ffffffffffffffffffffffffffffffffffffffff8551169401516120bc604051928392835260408d84015260408301906123c6565b0390a38680612053565b905088612036565b877fdeaddead000000000000000000000000000000000000000000000000000000006000526000fd5b606486604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b60a0810190811067ffffffffffffffff82111761217157604052565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610140810190811067ffffffffffffffff82111761217157604052565b67ffffffffffffffff811161217157604052565b6060810190811067ffffffffffffffff82111761217157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761217157604052565b67ffffffffffffffff811161217157601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b9291926122748261222e565b9161228260405193846121ed565b82948184528183011161019c578281602093846000960137010152565b6004359073ffffffffffffffffffffffffffffffffffffffff8216820361019c57565b9181601f8401121561019c5782359167ffffffffffffffff831161019c576020838186019501011161019c57565b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361019c57565b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc83011261019c5760043567ffffffffffffffff9283821161019c578060238301121561019c57816004013593841161019c5760248460051b8301011161019c57602401919060243573ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b60005b8381106123b65750506000910152565b81810151838201526020016123a6565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f602093612402815180928187528780880191016123a3565b0116010190565b91908201809211610b4f57565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610b4f5760010190565b91908203918211610b4f57565b3d1561247b573d906124618261222e565b9161246f60405193846121ed565b82523d6000602084013e565b606090565b604061248e8183018361284b565b90818351918237206124a3606084018461284b565b90818451918237209260c06124bb60e083018361284b565b908186519182372091845195602087019473ffffffffffffffffffffffffffffffffffffffff833516865260208301358789015260608801526080870152608081013560a087015260a081013582870152013560e08501526101009081850152835261012083019167ffffffffffffffff918484108385111761217157838252845190206101408501908152306101608601524661018086015260608452936101a00191821183831017612171575251902090565b67ffffffffffffffff81116121715760051b60200190565b9061259282612570565b6040906125a260405191826121ed565b8381527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06125d08295612570565b019160005b8381106125e25750505050565b60209082516125f081612155565b83516125fb816121a0565b600081526000849181838201528187820152816060818184015260809282848201528260a08201528260c08201528260e082015282610100820152826101208201528652818587015281898701528501528301528286010152016125d5565b805182101561266e5760209160051b010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b919081101561266e5760051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee18136030182121561019c570190565b9081602091031261019c575173ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b7f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c4602073ffffffffffffffffffffffffffffffffffffffff61278a3485613c98565b936040519485521692a2565b919081101561266e5760051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa18136030182121561019c570190565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18136030182121561019c570180359067ffffffffffffffff821161019c57602001918160051b3603831361019c57565b3573ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18136030182121561019c570180359067ffffffffffffffff821161019c5760200191813603831361019c57565b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561019c57016020813591019167ffffffffffffffff821161019c57813603831361019c57565b61012091813573ffffffffffffffffffffffffffffffffffffffff811680910361019c576129626129476129ba9561299b93855260208601356020860152612937604087018761289c565b9091806040880152860191612709565b612954606086018661289c565b908583036060870152612709565b6080840135608084015260a084013560a084015260c084013560c084015261298d60e085018561289c565b9084830360e0860152612709565b916129ac610100918281019061289c565b929091818503910152612709565b90565b60028054146129cc5760028055565b60046040517f3ee5aeb5000000000000000000000000000000000000000000000000000000008152fd5b926000905a93805194843573ffffffffffffffffffffffffffffffffffffffff811680910361019c5786526020850135602087015260808501356fffffffffffffffffffffffffffffffff90818116606089015260801c604088015260a086013560c088015260c086013590811661010088015260801c610120870152612a8060e086018661284b565b801561357b576034811061351d578060141161019c578060241161019c5760341161019c57602481013560801c60a0880152601481013560801c60808801523560601c60e08701525b612ad285612480565b60208301526040860151946effffffffffffffffffffffffffffff8660c08901511760608901511760808901511760a0890151176101008901511761012089015117116134bf57604087015160608801510160808801510160a08801510160c0880151016101008801510296835173ffffffffffffffffffffffffffffffffffffffff81511690612b66604085018561284b565b806131e4575b505060e0015173ffffffffffffffffffffffffffffffffffffffff1690600082156131ac575b6020612bd7918b828a01516000868a604051978896879586937f19822f7c00000000000000000000000000000000000000000000000000000000855260048501613db5565b0393f160009181613178575b50612c8b573d8c610800808311612c83575b50604051916020818401016040528083526000602084013e610e7e6040519283927f65c8fd4d000000000000000000000000000000000000000000000000000000008452600484015260606024840152600d60648401527f4141323320726576657274656400000000000000000000000000000000000000608484015260a0604484015260a48301906123c6565b915082612bf5565b9a92939495969798999a91156130f2575b509773ffffffffffffffffffffffffffffffffffffffff835116602084015190600052600160205260406000208160401c60005260205267ffffffffffffffff604060002091825492612cee84612416565b9055160361308d575a8503116130285773ffffffffffffffffffffffffffffffffffffffff60e0606093015116612d42575b509060a09184959697986040608096015260608601520135905a900301910152565b969550505a9683519773ffffffffffffffffffffffffffffffffffffffff60e08a01511680600052600060205260406000208054848110612fc3576080612dcd9a9b9c600093878094039055015192602089015183604051809d819582947f52b7512c0000000000000000000000000000000000000000000000000000000084528c60048501613db5565b039286f1978860009160009a612f36575b50612e86573d8b610800808311612e7e575b50604051916020818401016040528083526000602084013e610e7e6040519283927f65c8fd4d000000000000000000000000000000000000000000000000000000008452600484015260606024840152600d60648401527f4141333320726576657274656400000000000000000000000000000000000000608484015260a0604484015260a48301906123c6565b915082612df0565b9991929394959697989998925a900311612eab57509096959094939291906080612d20565b60a490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602760448201527f41413336206f766572207061796d6173746572566572696669636174696f6e4760648201527f61734c696d6974000000000000000000000000000000000000000000000000006084820152fd5b915098503d90816000823e612f4b82826121ed565b604081838101031261019c5780519067ffffffffffffffff821161019c57828101601f83830101121561019c578181015191612f868361222e565b93612f9460405195866121ed565b838552820160208483850101011161019c57602092612fba9184808701918501016123a3565b01519838612dde565b60848b604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601e60448201527f41413331207061796d6173746572206465706f73697420746f6f206c6f7700006064820152fd5b608490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601e60448201527f41413236206f76657220766572696669636174696f6e4761734c696d697400006064820152fd5b608482604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601a60448201527f4141323520696e76616c6964206163636f756e74206e6f6e63650000000000006064820152fd5b600052600060205260406000208054808c11613113578b9003905538612c9c565b608484604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152fd5b9091506020813d6020116131a4575b81613194602093836121ed565b8101031261019c57519038612be3565b3d9150613187565b508060005260006020526040600020548a81116000146131d75750612bd7602060005b915050612b92565b6020612bd7918c036131cf565b833b61345a57604088510151602060405180927f570e1a360000000000000000000000000000000000000000000000000000000082528260048301528160008161323260248201898b612709565b039273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690f1908115610db75760009161343b575b5073ffffffffffffffffffffffffffffffffffffffff811680156133d6578503613371573b1561330c5760141161019c5773ffffffffffffffffffffffffffffffffffffffff9183887fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d604060e0958787602086015195510151168251913560601c82526020820152a391612b6c565b60848d604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152fd5b60848e604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602060448201527f4141313420696e6974436f6465206d7573742072657475726e2073656e6465726064820152fd5b60848f604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601b60448201527f4141313320696e6974436f6465206661696c6564206f72204f4f4700000000006064820152fd5b613454915060203d602011610db057610da181836121ed565b3861327c565b60848d604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b5050600060e087015260006080870152600060a0870152612ac9565b9092915a906060810151916040928351967fffffffff00000000000000000000000000000000000000000000000000000000886135d7606084018461284b565b600060038211613b9f575b7f8dd7712f0000000000000000000000000000000000000000000000000000000094168403613a445750505061379d6000926136b292602088015161363a8a5193849360208501528b602485015260648401906128ec565b90604483015203906136727fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0928381018352826121ed565b61379189519485927e42dc5300000000000000000000000000000000000000000000000000000000602085015261020060248501526102248401906123c6565b613760604484018b60806101a091805173ffffffffffffffffffffffffffffffffffffffff808251168652602082015160208701526040820151604087015260608201516060870152838201518487015260a082015160a087015260c082015160c087015260e08201511660e0860152610100808201519086015261012080910151908501526020810151610140850152604081015161016085015260608101516101808501520151910152565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc83820301610204840152876123c6565b039081018352826121ed565b6020918183809351910182305af1600051988652156137bf575b505050505050565b909192939495965060003d8214613a3a575b7fdeaddead00000000000000000000000000000000000000000000000000000000810361385b57608487878051917f220266b600000000000000000000000000000000000000000000000000000000835260048301526024820152600f60448201527f41413935206f7574206f662067617300000000000000000000000000000000006064820152fd5b7fdeadaa510000000000000000000000000000000000000000000000000000000091929395949650146000146138c55750506138a961389e6138b8935a90612443565b608085015190612409565b9083015183611d748295613d65565b905b3880808080806137b7565b909261395290828601518651907ff62676f440ff169a3a9afdbf812e89e7f95975ee8e5c31214ffdef631c5f479273ffffffffffffffffffffffffffffffffffffffff9580878551169401516139483d610800808211613a32575b508a519084818301018c5280825260008583013e8a805194859485528401528a8301906123c6565b0390a35a90612443565b916139636080860193845190612409565b926000905a94829488519761397789613ccc565b948260e08b0151168015600014613a1857505050875116955b5a9003019560a06060820151910151019051860390818111613a04575b5050840290850151928184106000146139de57505080611e68575090816139d89293611d7481613d65565b906138ba565b6139ee9082849397950390613c98565b50611e68575090826139ff92613cf6565b6139d8565b6064919003600a02049094019338806139ad565b90919892509751613a2a575b50613990565b955038613a24565b905038613920565b8181803e516137d1565b613b97945082935090613a8c917e42dc53000000000000000000000000000000000000000000000000000000006020613b6b9501526102006024860152610224850191612709565b613b3a604484018860806101a091805173ffffffffffffffffffffffffffffffffffffffff808251168652602082015160208701526040820151604087015260608201516060870152838201518487015260a082015160a087015260c082015160c087015260e08201511660e0860152610100808201519086015261012080910151908501526020810151610140850152604081015161016085015260608101516101808501520151910152565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc83820301610204840152846123c6565b037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081018952886121ed565b60008761379d565b5081356135e2565b73ffffffffffffffffffffffffffffffffffffffff168015613c3a57600080809381935af1613bd4612450565b5015613bdc57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b73ffffffffffffffffffffffffffffffffffffffff166000526000602052613cc66040600020918254612409565b80915590565b610120610100820151910151808214613cf257480180821015613ced575090565b905090565b5090565b9190917f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f6080602083015192519473ffffffffffffffffffffffffffffffffffffffff946020868851169660e089015116970151916040519283526000602084015260408301526060820152a4565b60208101519051907f67b4fa9642f42120bf031f3051d1824b0fe25627945b27b8a6a65d5761d5482e60208073ffffffffffffffffffffffffffffffffffffffff855116940151604051908152a3565b613dcd604092959493956060835260608301906128ec565b9460208201520152565b8015613e6457600060408051613dec816121d1565b828152826020820152015273ffffffffffffffffffffffffffffffffffffffff811690604065ffffffffffff91828160a01c16908115613e5c575b60d01c92825191613e37836121d1565b8583528460208401521691829101524211908115613e5457509091565b905042109091565b839150613e27565b5060009060009056fea2646970667358221220b094fd69f04977ae9458e5ba422d01cd2d20dbcfca0992ff37f19aa07deec25464736f6c6343000817003360808060405234610016576101c3908161001c8239f35b600080fdfe6080600436101561000f57600080fd5b6000803560e01c63570e1a361461002557600080fd5b3461018a5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261018a576004359167ffffffffffffffff9081841161018657366023850112156101865783600401358281116101825736602482870101116101825780601411610182577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec810192808411610155577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81600b8501160116830190838210908211176101555792846024819482600c60209a968b9960405286845289840196603889018837830101525193013560601c5af1908051911561014d575b5073ffffffffffffffffffffffffffffffffffffffff60405191168152f35b90503861012e565b6024857f4e487b710000000000000000000000000000000000000000000000000000000081526041600452fd5b8380fd5b8280fd5b80fdfea26469706673582212207adef8895ad3393b02fab10a111d85ea80ff35366aa43995f4ea20e67f29200664736f6c63430008170033",deployedBytecode$1="0x60806040526004361015610024575b361561001957600080fd5b61002233612748565b005b60003560e01c806242dc5314611b0057806301ffc9a7146119ae5780630396cb60146116765780630bd28e3b146115fa5780631b2e01b814611566578063205c2878146113d157806322cdde4c1461136b57806335567e1a146112b35780635287ce12146111a557806370a0823114611140578063765e827f14610e82578063850aaf6214610dc35780639b249f6914610c74578063b760faf914610c3a578063bb9fe6bf14610a68578063c23a5cea146107c4578063dbed18e0146101a15763fc7e286d0361000e573461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff61013a61229f565b16600052600060205260a0604060002065ffffffffffff6001825492015460405192835260ff8116151560208401526dffffffffffffffffffffffffffff8160081c16604084015263ffffffff8160781c16606084015260981c166080820152f35b600080fd5b3461019c576101af36612317565b906101b86129bd565b60009160005b82811061056f57506101d08493612588565b6000805b8481106102fc5750507fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000809360005b81811061024757610240868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2613ba7565b6001600255005b6102a261025582848a612796565b73ffffffffffffffffffffffffffffffffffffffff6102766020830161282a565b167f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a2806127d6565b906000915b8083106102b957505050600101610209565b909194976102f36102ed6001926102e78c8b6102e0826102da8e8b8d61269d565b9261265a565b5191613597565b90612409565b99612416565b950191906102a7565b6020610309828789612796565b61031f61031682806127d6565b9390920161282a565b9160009273ffffffffffffffffffffffffffffffffffffffff8091165b8285106103505750505050506001016101d4565b909192939561037f83610378610366848c61265a565b516103728b898b61269d565b856129f6565b9290613dd7565b9116840361050a576104a5576103958491613dd7565b9116610440576103b5576103aa600191612416565b96019392919061033c565b60a487604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f65000000000000000000000000000000000000000000000000000000000000006084820152fd5b608488604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413334207369676e6174757265206572726f720000000000000000000000006064820152fd5b608488604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f414132322065787069726564206f72206e6f74206475650000000000000000006064820152fd5b608489604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413234207369676e6174757265206572726f720000000000000000000000006064820152fd5b61057a818487612796565b9361058585806127d6565b919095602073ffffffffffffffffffffffffffffffffffffffff6105aa82840161282a565b1697600192838a1461076657896105da575b5050505060019293949550906105d191612409565b939291016101be565b8060406105e892019061284b565b918a3b1561019c57929391906040519485937f2dd8113300000000000000000000000000000000000000000000000000000000855288604486016040600488015252606490818601918a60051b8701019680936000915b8c83106106e657505050505050838392610684927ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8560009803016024860152612709565b03818a5afa90816106d7575b506106c657602486604051907f86a9f7500000000000000000000000000000000000000000000000000000000082526004820152fd5b93945084936105d1600189806105bc565b6106e0906121bd565b88610690565b91939596977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c908a9294969a0301865288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee18336030181121561019c57836107538793858394016128ec565b9a0196019301909189979695949261063f565b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b3461019c576020807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c576107fc61229f565b33600052600082526001604060002001908154916dffffffffffffffffffffffffffff8360081c16928315610a0a5765ffffffffffff8160981c1680156109ac57421061094e5760009373ffffffffffffffffffffffffffffffffffffffff859485947fffffffffffffff000000000000000000000000000000000000000000000000ff86951690556040517fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda33391806108da8786836020909392919373ffffffffffffffffffffffffffffffffffffffff60408201951681520152565b0390a2165af16108e8612450565b50156108f057005b606490604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b606485604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b606486604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b606485604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b3461019c5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c573360005260006020526001604060002001805463ffffffff8160781c16908115610bdc5760ff1615610b7e5765ffffffffffff908142160191818311610b4f5780547fffffffffffffff000000000000ffffffffffffffffffffffffffffffffffff001678ffffffffffff00000000000000000000000000000000000000609885901b161790556040519116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a2005b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c57610022610c6f61229f565b612748565b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043567ffffffffffffffff811161019c576020610cc8610d1b9236906004016122c2565b919073ffffffffffffffffffffffffffffffffffffffff9260405194859283927f570e1a360000000000000000000000000000000000000000000000000000000084528560048501526024840191612709565b03816000857f0000000000000000000000000000000000000000000000000000000000000000165af1908115610db757602492600092610d86575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b610da991925060203d602011610db0575b610da181836121ed565b8101906126dd565b9083610d56565b503d610d97565b6040513d6000823e3d90fd5b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c57610dfa61229f565b60243567ffffffffffffffff811161019c57600091610e1e839236906004016122c2565b90816040519283928337810184815203915af4610e39612450565b90610e7e6040519283927f99410554000000000000000000000000000000000000000000000000000000008452151560048401526040602484015260448301906123c6565b0390fd5b3461019c57610e9036612317565b610e9b9291926129bd565b610ea483612588565b60005b848110610f1c57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000915b858310610eec576102408585613ba7565b909193600190610f12610f0087898761269d565b610f0a888661265a565b519088613597565b0194019190610edb565b610f47610f40610f2e8385979561265a565b51610f3a84898761269d565b846129f6565b9190613dd7565b73ffffffffffffffffffffffffffffffffffffffff929183166110db5761107657610f7190613dd7565b911661101157610f8657600101929092610ea7565b60a490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f65000000000000000000000000000000000000000000000000000000000000006084820152fd5b608482604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413334207369676e6174757265206572726f720000000000000000000000006064820152fd5b608483604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f414132322065787069726564206f72206e6f74206475650000000000000000006064820152fd5b608484604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601460448201527f41413234207369676e6174757265206572726f720000000000000000000000006064820152fd5b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff61118c61229f565b1660005260006020526020604060002054604051908152f35b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5773ffffffffffffffffffffffffffffffffffffffff6111f161229f565b6000608060405161120181612155565b828152826020820152826040820152826060820152015216600052600060205260a06040600020608060405161123681612155565b6001835493848352015490602081019060ff8316151582526dffffffffffffffffffffffffffff60408201818560081c16815263ffffffff936060840193858760781c16855265ffffffffffff978891019660981c1686526040519788525115156020880152511660408601525116606084015251166080820152f35b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760206112ec61229f565b73ffffffffffffffffffffffffffffffffffffffff6113096122f0565b911660005260018252604060002077ffffffffffffffffffffffffffffffffffffffffffffffff821660005282526040600020547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b3461019c577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60208136011261019c576004359067ffffffffffffffff821161019c5761012090823603011261019c576113c9602091600401612480565b604051908152f35b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5761140861229f565b60243590336000526000602052604060002090815491828411611508576000808573ffffffffffffffffffffffffffffffffffffffff8295839561144c848a612443565b90556040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af16114a2612450565b50156114aa57005b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b3461019c5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5761159d61229f565b73ffffffffffffffffffffffffffffffffffffffff6115ba6122f0565b9116600052600160205277ffffffffffffffffffffffffffffffffffffffffffffffff604060002091166000526020526020604060002054604051908152f35b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043577ffffffffffffffffffffffffffffffffffffffffffffffff811680910361019c5733600052600160205260406000209060005260205260406000206116728154612416565b9055005b6020807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5760043563ffffffff9182821680920361019c5733600052600081526040600020928215611950576001840154908160781c1683106118f2576116f86dffffffffffffffffffffffffffff9182349160081c16612409565b93841561189457818511611836579065ffffffffffff61180592546040519061172082612155565b8152848101926001845260408201908816815260608201878152600160808401936000855233600052600089526040600020905181550194511515917fffffffffffffffffffffffffff0000000000000000000000000000000000000060ff72ffffffff0000000000000000000000000000006effffffffffffffffffffffffffff008954945160081b16945160781b1694169116171717835551167fffffffffffffff000000000000ffffffffffffffffffffffffffffffffffffff78ffffffffffff0000000000000000000000000000000000000083549260981b169116179055565b6040519283528201527fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c0160403392a2005b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b606483604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b606482604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b606482604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b3461019c5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c576004357fffffffff00000000000000000000000000000000000000000000000000000000811680910361019c57807f60fc6b6e0000000000000000000000000000000000000000000000000000000060209214908115611ad6575b8115611aac575b8115611a82575b8115611a58575b506040519015158152f35b7f01ffc9a70000000000000000000000000000000000000000000000000000000091501482611a4d565b7f3e84f0210000000000000000000000000000000000000000000000000000000081149150611a46565b7fcf28ef970000000000000000000000000000000000000000000000000000000081149150611a3f565b7f915074d80000000000000000000000000000000000000000000000000000000081149150611a38565b3461019c576102007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261019c5767ffffffffffffffff60043581811161019c573660238201121561019c57611b62903690602481600401359101612268565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101c0811261019c5761014060405191611b9e83612155565b1261019c5760405192611bb0846121a0565b60243573ffffffffffffffffffffffffffffffffffffffff8116810361019c578452602093604435858201526064356040820152608435606082015260a435608082015260c43560a082015260e43560c08201526101043573ffffffffffffffffffffffffffffffffffffffff8116810361019c5760e08201526101243561010082015261014435610120820152825261016435848301526101843560408301526101a43560608301526101c43560808301526101e43590811161019c57611c7c9036906004016122c2565b905a3033036120f7578351606081015195603f5a0260061c61271060a0840151890101116120ce5760009681519182611ff0575b5050505090611cca915a9003608085015101923691612268565b925a90600094845193611cdc85613ccc565b9173ffffffffffffffffffffffffffffffffffffffff60e0870151168015600014611ea957505073ffffffffffffffffffffffffffffffffffffffff855116935b5a9003019360a06060820151910151016080860151850390818111611e95575b50508302604085015192818410600014611dce5750506003811015611da157600203611d79576113c99293508093611d7481613d65565b613cf6565b5050507fdeadaa51000000000000000000000000000000000000000000000000000000008152fd5b6024857f4e487b710000000000000000000000000000000000000000000000000000000081526021600452fd5b81611dde92979396940390613c98565b506003841015611e6857507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f60808683015192519473ffffffffffffffffffffffffffffffffffffffff865116948873ffffffffffffffffffffffffffffffffffffffff60e0890151169701519160405192835215898301528760408301526060820152a46113c9565b807f4e487b7100000000000000000000000000000000000000000000000000000000602492526021600452fd5b6064919003600a0204909301928780611d3d565b8095918051611eba575b5050611d1d565b6003861015611fc1576002860315611eb35760a088015190823b1561019c57600091611f2491836040519586809581947f7c627b210000000000000000000000000000000000000000000000000000000083528d60048401526080602484015260848301906123c6565b8b8b0260448301528b60648301520393f19081611fad575b50611fa65787893d610800808211611f9e575b506040519282828501016040528184528284013e610e7e6040519283927fad7954bc000000000000000000000000000000000000000000000000000000008452600484015260248301906123c6565b905083611f4f565b8980611eb3565b611fb89199506121bd565b6000978a611f3c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91600092918380938c73ffffffffffffffffffffffffffffffffffffffff885116910192f115612023575b808080611cb0565b611cca929195503d6108008082116120c6575b5060405190888183010160405280825260008983013e805161205f575b5050600194909161201b565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20188870151918973ffffffffffffffffffffffffffffffffffffffff8551169401516120bc604051928392835260408d84015260408301906123c6565b0390a38680612053565b905088612036565b877fdeaddead000000000000000000000000000000000000000000000000000000006000526000fd5b606486604051907f08c379a00000000000000000000000000000000000000000000000000000000082526004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b60a0810190811067ffffffffffffffff82111761217157604052565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610140810190811067ffffffffffffffff82111761217157604052565b67ffffffffffffffff811161217157604052565b6060810190811067ffffffffffffffff82111761217157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761217157604052565b67ffffffffffffffff811161217157601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b9291926122748261222e565b9161228260405193846121ed565b82948184528183011161019c578281602093846000960137010152565b6004359073ffffffffffffffffffffffffffffffffffffffff8216820361019c57565b9181601f8401121561019c5782359167ffffffffffffffff831161019c576020838186019501011161019c57565b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361019c57565b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc83011261019c5760043567ffffffffffffffff9283821161019c578060238301121561019c57816004013593841161019c5760248460051b8301011161019c57602401919060243573ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b60005b8381106123b65750506000910152565b81810151838201526020016123a6565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f602093612402815180928187528780880191016123a3565b0116010190565b91908201809211610b4f57565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610b4f5760010190565b91908203918211610b4f57565b3d1561247b573d906124618261222e565b9161246f60405193846121ed565b82523d6000602084013e565b606090565b604061248e8183018361284b565b90818351918237206124a3606084018461284b565b90818451918237209260c06124bb60e083018361284b565b908186519182372091845195602087019473ffffffffffffffffffffffffffffffffffffffff833516865260208301358789015260608801526080870152608081013560a087015260a081013582870152013560e08501526101009081850152835261012083019167ffffffffffffffff918484108385111761217157838252845190206101408501908152306101608601524661018086015260608452936101a00191821183831017612171575251902090565b67ffffffffffffffff81116121715760051b60200190565b9061259282612570565b6040906125a260405191826121ed565b8381527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06125d08295612570565b019160005b8381106125e25750505050565b60209082516125f081612155565b83516125fb816121a0565b600081526000849181838201528187820152816060818184015260809282848201528260a08201528260c08201528260e082015282610100820152826101208201528652818587015281898701528501528301528286010152016125d5565b805182101561266e5760209160051b010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b919081101561266e5760051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee18136030182121561019c570190565b9081602091031261019c575173ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b7f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c4602073ffffffffffffffffffffffffffffffffffffffff61278a3485613c98565b936040519485521692a2565b919081101561266e5760051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa18136030182121561019c570190565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18136030182121561019c570180359067ffffffffffffffff821161019c57602001918160051b3603831361019c57565b3573ffffffffffffffffffffffffffffffffffffffff8116810361019c5790565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18136030182121561019c570180359067ffffffffffffffff821161019c5760200191813603831361019c57565b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561019c57016020813591019167ffffffffffffffff821161019c57813603831361019c57565b61012091813573ffffffffffffffffffffffffffffffffffffffff811680910361019c576129626129476129ba9561299b93855260208601356020860152612937604087018761289c565b9091806040880152860191612709565b612954606086018661289c565b908583036060870152612709565b6080840135608084015260a084013560a084015260c084013560c084015261298d60e085018561289c565b9084830360e0860152612709565b916129ac610100918281019061289c565b929091818503910152612709565b90565b60028054146129cc5760028055565b60046040517f3ee5aeb5000000000000000000000000000000000000000000000000000000008152fd5b926000905a93805194843573ffffffffffffffffffffffffffffffffffffffff811680910361019c5786526020850135602087015260808501356fffffffffffffffffffffffffffffffff90818116606089015260801c604088015260a086013560c088015260c086013590811661010088015260801c610120870152612a8060e086018661284b565b801561357b576034811061351d578060141161019c578060241161019c5760341161019c57602481013560801c60a0880152601481013560801c60808801523560601c60e08701525b612ad285612480565b60208301526040860151946effffffffffffffffffffffffffffff8660c08901511760608901511760808901511760a0890151176101008901511761012089015117116134bf57604087015160608801510160808801510160a08801510160c0880151016101008801510296835173ffffffffffffffffffffffffffffffffffffffff81511690612b66604085018561284b565b806131e4575b505060e0015173ffffffffffffffffffffffffffffffffffffffff1690600082156131ac575b6020612bd7918b828a01516000868a604051978896879586937f19822f7c00000000000000000000000000000000000000000000000000000000855260048501613db5565b0393f160009181613178575b50612c8b573d8c610800808311612c83575b50604051916020818401016040528083526000602084013e610e7e6040519283927f65c8fd4d000000000000000000000000000000000000000000000000000000008452600484015260606024840152600d60648401527f4141323320726576657274656400000000000000000000000000000000000000608484015260a0604484015260a48301906123c6565b915082612bf5565b9a92939495969798999a91156130f2575b509773ffffffffffffffffffffffffffffffffffffffff835116602084015190600052600160205260406000208160401c60005260205267ffffffffffffffff604060002091825492612cee84612416565b9055160361308d575a8503116130285773ffffffffffffffffffffffffffffffffffffffff60e0606093015116612d42575b509060a09184959697986040608096015260608601520135905a900301910152565b969550505a9683519773ffffffffffffffffffffffffffffffffffffffff60e08a01511680600052600060205260406000208054848110612fc3576080612dcd9a9b9c600093878094039055015192602089015183604051809d819582947f52b7512c0000000000000000000000000000000000000000000000000000000084528c60048501613db5565b039286f1978860009160009a612f36575b50612e86573d8b610800808311612e7e575b50604051916020818401016040528083526000602084013e610e7e6040519283927f65c8fd4d000000000000000000000000000000000000000000000000000000008452600484015260606024840152600d60648401527f4141333320726576657274656400000000000000000000000000000000000000608484015260a0604484015260a48301906123c6565b915082612df0565b9991929394959697989998925a900311612eab57509096959094939291906080612d20565b60a490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602760448201527f41413336206f766572207061796d6173746572566572696669636174696f6e4760648201527f61734c696d6974000000000000000000000000000000000000000000000000006084820152fd5b915098503d90816000823e612f4b82826121ed565b604081838101031261019c5780519067ffffffffffffffff821161019c57828101601f83830101121561019c578181015191612f868361222e565b93612f9460405195866121ed565b838552820160208483850101011161019c57602092612fba9184808701918501016123a3565b01519838612dde565b60848b604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601e60448201527f41413331207061796d6173746572206465706f73697420746f6f206c6f7700006064820152fd5b608490604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601e60448201527f41413236206f76657220766572696669636174696f6e4761734c696d697400006064820152fd5b608482604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601a60448201527f4141323520696e76616c6964206163636f756e74206e6f6e63650000000000006064820152fd5b600052600060205260406000208054808c11613113578b9003905538612c9c565b608484604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152fd5b9091506020813d6020116131a4575b81613194602093836121ed565b8101031261019c57519038612be3565b3d9150613187565b508060005260006020526040600020548a81116000146131d75750612bd7602060005b915050612b92565b6020612bd7918c036131cf565b833b61345a57604088510151602060405180927f570e1a360000000000000000000000000000000000000000000000000000000082528260048301528160008161323260248201898b612709565b039273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690f1908115610db75760009161343b575b5073ffffffffffffffffffffffffffffffffffffffff811680156133d6578503613371573b1561330c5760141161019c5773ffffffffffffffffffffffffffffffffffffffff9183887fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d604060e0958787602086015195510151168251913560601c82526020820152a391612b6c565b60848d604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152fd5b60848e604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152602060448201527f4141313420696e6974436f6465206d7573742072657475726e2073656e6465726064820152fd5b60848f604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601b60448201527f4141313320696e6974436f6465206661696c6564206f72204f4f4700000000006064820152fd5b613454915060203d602011610db057610da181836121ed565b3861327c565b60848d604051907f220266b6000000000000000000000000000000000000000000000000000000008252600482015260406024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b5050600060e087015260006080870152600060a0870152612ac9565b9092915a906060810151916040928351967fffffffff00000000000000000000000000000000000000000000000000000000886135d7606084018461284b565b600060038211613b9f575b7f8dd7712f0000000000000000000000000000000000000000000000000000000094168403613a445750505061379d6000926136b292602088015161363a8a5193849360208501528b602485015260648401906128ec565b90604483015203906136727fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0928381018352826121ed565b61379189519485927e42dc5300000000000000000000000000000000000000000000000000000000602085015261020060248501526102248401906123c6565b613760604484018b60806101a091805173ffffffffffffffffffffffffffffffffffffffff808251168652602082015160208701526040820151604087015260608201516060870152838201518487015260a082015160a087015260c082015160c087015260e08201511660e0860152610100808201519086015261012080910151908501526020810151610140850152604081015161016085015260608101516101808501520151910152565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc83820301610204840152876123c6565b039081018352826121ed565b6020918183809351910182305af1600051988652156137bf575b505050505050565b909192939495965060003d8214613a3a575b7fdeaddead00000000000000000000000000000000000000000000000000000000810361385b57608487878051917f220266b600000000000000000000000000000000000000000000000000000000835260048301526024820152600f60448201527f41413935206f7574206f662067617300000000000000000000000000000000006064820152fd5b7fdeadaa510000000000000000000000000000000000000000000000000000000091929395949650146000146138c55750506138a961389e6138b8935a90612443565b608085015190612409565b9083015183611d748295613d65565b905b3880808080806137b7565b909261395290828601518651907ff62676f440ff169a3a9afdbf812e89e7f95975ee8e5c31214ffdef631c5f479273ffffffffffffffffffffffffffffffffffffffff9580878551169401516139483d610800808211613a32575b508a519084818301018c5280825260008583013e8a805194859485528401528a8301906123c6565b0390a35a90612443565b916139636080860193845190612409565b926000905a94829488519761397789613ccc565b948260e08b0151168015600014613a1857505050875116955b5a9003019560a06060820151910151019051860390818111613a04575b5050840290850151928184106000146139de57505080611e68575090816139d89293611d7481613d65565b906138ba565b6139ee9082849397950390613c98565b50611e68575090826139ff92613cf6565b6139d8565b6064919003600a02049094019338806139ad565b90919892509751613a2a575b50613990565b955038613a24565b905038613920565b8181803e516137d1565b613b97945082935090613a8c917e42dc53000000000000000000000000000000000000000000000000000000006020613b6b9501526102006024860152610224850191612709565b613b3a604484018860806101a091805173ffffffffffffffffffffffffffffffffffffffff808251168652602082015160208701526040820151604087015260608201516060870152838201518487015260a082015160a087015260c082015160c087015260e08201511660e0860152610100808201519086015261012080910151908501526020810151610140850152604081015161016085015260608101516101808501520151910152565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc83820301610204840152846123c6565b037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081018952886121ed565b60008761379d565b5081356135e2565b73ffffffffffffffffffffffffffffffffffffffff168015613c3a57600080809381935af1613bd4612450565b5015613bdc57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b73ffffffffffffffffffffffffffffffffffffffff166000526000602052613cc66040600020918254612409565b80915590565b610120610100820151910151808214613cf257480180821015613ced575090565b905090565b5090565b9190917f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f6080602083015192519473ffffffffffffffffffffffffffffffffffffffff946020868851169660e089015116970151916040519283526000602084015260408301526060820152a4565b60208101519051907f67b4fa9642f42120bf031f3051d1824b0fe25627945b27b8a6a65d5761d5482e60208073ffffffffffffffffffffffffffffffffffffffff855116940151604051908152a3565b613dcd604092959493956060835260608301906128ec565b9460208201520152565b8015613e6457600060408051613dec816121d1565b828152826020820152015273ffffffffffffffffffffffffffffffffffffffff811690604065ffffffffffff91828160a01c16908115613e5c575b60d01c92825191613e37836121d1565b8583528460208401521691829101524211908115613e5457509091565b905042109091565b839150613e27565b5060009060009056fea2646970667358221220b094fd69f04977ae9458e5ba422d01cd2d20dbcfca0992ff37f19aa07deec25464736f6c63430008170033",EntryPoint={address,abi:abi$1,args,numDeployments,bytecode:bytecode$1,deployedBytecode:deployedBytecode$1};function execTyped(c,a){const d=c.exec(a);return d==null?void 0:d.groups}const tupleRegex=/^tuple(?(\[(\d*)\])*)$/;function formatAbiParameter(c){let a=c.type;if(tupleRegex.test(c.type)&&"components"in c){a="(";const d=c.components.length;for(let nt=0;nt{var nt,tt;return((nt=c[a.name])==null?void 0:nt.call(c,et))??((tt=c[d])==null?void 0:tt.call(c,et))??a(c,et)}}function formatAbiItem(c,{includeName:a=!1}={}){if(c.type!=="function"&&c.type!=="event"&&c.type!=="error")throw new InvalidDefinitionTypeError(c.type);return`${c.name}(${formatAbiParams(c.inputs,{includeName:a})})`}function formatAbiParams(c,{includeName:a=!1}={}){return c?c.map(d=>formatAbiParam(d,{includeName:a})).join(a?", ":","):""}function formatAbiParam(c,{includeName:a}){return c.type.startsWith("tuple")?`(${formatAbiParams(c.components,{includeName:a})})${c.type.slice(5)}`:c.type+(a&&c.name?` ${c.name}`:"")}function isHex(c,{strict:a=!0}={}){return!c||typeof c!="string"?!1:a?/^0x[0-9a-fA-F]*$/.test(c):c.startsWith("0x")}function size$1(c){return isHex(c,{strict:!1})?Math.ceil((c.length-2)/2):c.length}const version="2.9.25",getContractAddress=c=>c,getUrl=c=>c,getVersion=()=>`viem@${version}`;class BaseError extends Error{constructor(a,d={}){var tt;super(),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ViemError"}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:getVersion()});const et=d.cause instanceof BaseError?d.cause.details:(tt=d.cause)!=null&&tt.message?d.cause.message:d.details,nt=d.cause instanceof BaseError&&d.cause.docsPath||d.docsPath;this.message=[a||"An error occurred.","",...d.metaMessages?[...d.metaMessages,""]:[],...nt?[`Docs: https://viem.sh${nt}${d.docsSlug?`#${d.docsSlug}`:""}`]:[],...et?[`Details: ${et}`]:[],`Version: ${this.version}`].join(` +`),d.cause&&(this.cause=d.cause),this.details=et,this.docsPath=nt,this.metaMessages=d.metaMessages,this.shortMessage=a}walk(a){return walk(this,a)}}function walk(c,a){return a!=null&&a(c)?c:c&&typeof c=="object"&&"cause"in c?walk(c.cause,a):a?null:c}class AbiConstructorNotFoundError extends BaseError{constructor({docsPath:a}){super(["A constructor was not found on the ABI.","Make sure you are using the correct ABI and that the constructor exists on it."].join(` +`),{docsPath:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorNotFoundError"})}}class AbiConstructorParamsNotFoundError extends BaseError{constructor({docsPath:a}){super(["Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.","Make sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists."].join(` +`),{docsPath:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorParamsNotFoundError"})}}class AbiDecodingDataSizeTooSmallError extends BaseError{constructor({data:a,params:d,size:et}){super([`Data size of ${et} bytes is too small for given parameters.`].join(` +`),{metaMessages:[`Params: (${formatAbiParams(d,{includeName:!0})})`,`Data: ${a} (${et} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingDataSizeTooSmallError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=a,this.params=d,this.size=et}}class AbiDecodingZeroDataError extends BaseError{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingZeroDataError"})}}class AbiEncodingArrayLengthMismatchError extends BaseError{constructor({expectedLength:a,givenLength:d,type:et}){super([`ABI encoding array length mismatch for type ${et}.`,`Expected length: ${a}`,`Given length: ${d}`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}}class AbiEncodingBytesSizeMismatchError extends BaseError{constructor({expectedSize:a,value:d}){super(`Size of bytes "${d}" (bytes${size$1(d)}) does not match expected size (bytes${a}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}}class AbiEncodingLengthMismatchError extends BaseError{constructor({expectedLength:a,givenLength:d}){super(["ABI encoding params/values length mismatch.",`Expected length (params): ${a}`,`Given length (values): ${d}`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}}class AbiErrorSignatureNotFoundError extends BaseError{constructor(a,{docsPath:d}){super([`Encoded error signature "${a}" not found on ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://openchain.xyz/signatures?query=${a}.`].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorSignatureNotFoundError"}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=a}}class AbiEventSignatureEmptyTopicsError extends BaseError{constructor({docsPath:a}){super("Cannot extract event signature from empty topics.",{docsPath:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureEmptyTopicsError"})}}class AbiEventSignatureNotFoundError extends BaseError{constructor(a,{docsPath:d}){super([`Encoded event signature "${a}" not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it.",`You can look up the signature here: https://openchain.xyz/signatures?query=${a}.`].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureNotFoundError"})}}class AbiEventNotFoundError extends BaseError{constructor(a,{docsPath:d}={}){super([`Event ${a?`"${a}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventNotFoundError"})}}class AbiFunctionNotFoundError extends BaseError{constructor(a,{docsPath:d}={}){super([`Function ${a?`"${a}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}}class AbiFunctionOutputsNotFoundError extends BaseError{constructor(a,{docsPath:d}){super([`Function "${a}" does not contain any \`outputs\` on ABI.`,"Cannot decode function result without knowing what the parameter types are.","Make sure you are using the correct ABI and that the function exists on it."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionOutputsNotFoundError"})}}class AbiItemAmbiguityError extends BaseError{constructor(a,d){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${a.type}\` in \`${formatAbiItem(a.abiItem)}\`, and`,`\`${d.type}\` in \`${formatAbiItem(d.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItemAmbiguityError"})}}class BytesSizeMismatchError extends BaseError{constructor({expectedSize:a,givenSize:d}){super(`Expected bytes${a}, got bytes${d}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}}class DecodeLogDataMismatch extends BaseError{constructor({abiItem:a,data:d,params:et,size:nt}){super([`Data size of ${nt} bytes is too small for non-indexed event parameters.`].join(` +`),{metaMessages:[`Params: (${formatAbiParams(et,{includeName:!0})})`,`Data: ${d} (${nt} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogDataMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=a,this.data=d,this.params=et,this.size=nt}}class DecodeLogTopicsMismatch extends BaseError{constructor({abiItem:a,param:d}){super([`Expected a topic for indexed event parameter${d.name?` "${d.name}"`:""} on event "${formatAbiItem(a,{includeName:!0})}".`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=a}}class InvalidAbiEncodingTypeError extends BaseError{constructor(a,{docsPath:d}){super([`Type "${a}" is not a valid encoding type.`,"Please provide a valid ABI type."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}}class InvalidAbiDecodingTypeError extends BaseError{constructor(a,{docsPath:d}){super([`Type "${a}" is not a valid decoding type.`,"Please provide a valid ABI type."].join(` +`),{docsPath:d}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiDecodingType"})}}class InvalidArrayError extends BaseError{constructor(a){super([`Value "${a}" is not a valid array.`].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}}class InvalidDefinitionTypeError extends BaseError{constructor(a){super([`"${a}" is not a valid definition type.`,'Valid types: "function", "event", "error"'].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}}class UnsupportedPackedAbiType extends BaseError{constructor(a){super(`Type "${a}" is not supported for packed encoding.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedPackedAbiType"})}}class FilterTypeNotSupportedError extends BaseError{constructor(a){super(`Filter type "${a}" is not supported.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FilterTypeNotSupportedError"})}}class SliceOffsetOutOfBoundsError extends BaseError{constructor({offset:a,position:d,size:et}){super(`Slice ${d==="start"?"starting":"ending"} at offset "${a}" is out-of-bounds (size: ${et}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}}class SizeExceedsPaddingSizeError extends BaseError{constructor({size:a,targetSize:d,type:et}){super(`${et.charAt(0).toUpperCase()}${et.slice(1).toLowerCase()} size (${a}) exceeds padding size (${d}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}}class InvalidBytesLengthError extends BaseError{constructor({size:a,targetSize:d,type:et}){super(`${et.charAt(0).toUpperCase()}${et.slice(1).toLowerCase()} is expected to be ${d} ${et} long, but is ${a} ${et} long.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidBytesLengthError"})}}function pad(c,{dir:a,size:d=32}={}){return typeof c=="string"?padHex(c,{dir:a,size:d}):padBytes(c,{dir:a,size:d})}function padHex(c,{dir:a,size:d=32}={}){if(d===null)return c;const et=c.replace("0x","");if(et.length>d*2)throw new SizeExceedsPaddingSizeError({size:Math.ceil(et.length/2),targetSize:d,type:"hex"});return`0x${et[a==="right"?"padEnd":"padStart"](d*2,"0")}`}function padBytes(c,{dir:a,size:d=32}={}){if(d===null)return c;if(c.length>d)throw new SizeExceedsPaddingSizeError({size:c.length,targetSize:d,type:"bytes"});const et=new Uint8Array(d);for(let nt=0;nta)throw new SizeOverflowError({givenSize:size$1(c),maxSize:a})}function hexToBigInt(c,a={}){const{signed:d}=a;a.size&&assertSize(c,{size:a.size});const et=BigInt(c);if(!d)return et;const nt=(c.length-2)/2,tt=(1n<a.toString(16).padStart(2,"0"));function toHex(c,a={}){return typeof c=="number"||typeof c=="bigint"?numberToHex(c,a):typeof c=="string"?stringToHex(c,a):typeof c=="boolean"?boolToHex(c,a):bytesToHex(c,a)}function boolToHex(c,a={}){const d=`0x${Number(c)}`;return typeof a.size=="number"?(assertSize(d,{size:a.size}),pad(d,{size:a.size})):d}function bytesToHex(c,a={}){let d="";for(let nt=0;nttt||nt=charCodeMap.zero&&c<=charCodeMap.nine)return c-charCodeMap.zero;if(c>=charCodeMap.A&&c<=charCodeMap.F)return c-(charCodeMap.A-10);if(c>=charCodeMap.a&&c<=charCodeMap.f)return c-(charCodeMap.a-10)}function hexToBytes(c,a={}){let d=c;a.size&&(assertSize(d,{size:a.size}),d=pad(d,{dir:"right",size:a.size}));let et=d.slice(2);et.length%2&&(et=`0${et}`);const nt=et.length/2,tt=new Uint8Array(nt);for(let bt=0,mt=0;bt0&&!a.includes(c.length))throw new Error(`Expected Uint8Array of length ${a}, not of length=${c.length}`)}function exists(c,a=!0){if(c.destroyed)throw new Error("Hash instance has been destroyed");if(a&&c.finished)throw new Error("Hash#digest() has already been called")}function output(c,a){bytes(c);const d=a.outputLen;if(c.length>_32n&U32_MASK64)}:{h:Number(c>>_32n&U32_MASK64)|0,l:Number(c&U32_MASK64)|0}}function split(c,a=!1){let d=new Uint32Array(c.length),et=new Uint32Array(c.length);for(let nt=0;ntc<>>32-d,rotlSL=(c,a,d)=>a<>>32-d,rotlBH=(c,a,d)=>a<>>64-d,rotlBL=(c,a,d)=>c<>>64-d;/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */const u8a=c=>c instanceof Uint8Array,u32=c=>new Uint32Array(c.buffer,c.byteOffset,Math.floor(c.byteLength/4)),createView=c=>new DataView(c.buffer,c.byteOffset,c.byteLength),rotr=(c,a)=>c<<32-a|c>>>a,isLE=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;if(!isLE)throw new Error("Non little-endian hardware is not supported");function utf8ToBytes(c){if(typeof c!="string")throw new Error(`utf8ToBytes expected string, got ${typeof c}`);return new Uint8Array(new TextEncoder().encode(c))}function toBytes(c){if(typeof c=="string"&&(c=utf8ToBytes(c)),!u8a(c))throw new Error(`expected Uint8Array, got ${typeof c}`);return c}class Hash{clone(){return this._cloneInto()}}function wrapConstructor(c){const a=et=>c().update(toBytes(et)).digest(),d=c();return a.outputLen=d.outputLen,a.blockLen=d.blockLen,a.create=()=>c(),a}const[SHA3_PI,SHA3_ROTL,_SHA3_IOTA]=[[],[],[]],_0n=BigInt(0),_1n=BigInt(1),_2n=BigInt(2),_7n=BigInt(7),_256n=BigInt(256),_0x71n=BigInt(113);for(let c=0,a=_1n,d=1,et=0;c<24;c++){[d,et]=[et,(2*d+3*et)%5],SHA3_PI.push(2*(5*et+d)),SHA3_ROTL.push((c+1)*(c+2)/2%64);let nt=_0n;for(let tt=0;tt<7;tt++)a=(a<<_1n^(a>>_7n)*_0x71n)%_256n,a&_2n&&(nt^=_1n<<(_1n<d>32?rotlBH(c,a,d):rotlSH(c,a,d),rotlL=(c,a,d)=>d>32?rotlBL(c,a,d):rotlSL(c,a,d);function keccakP(c,a=24){const d=new Uint32Array(10);for(let et=24-a;et<24;et++){for(let bt=0;bt<10;bt++)d[bt]=c[bt]^c[bt+10]^c[bt+20]^c[bt+30]^c[bt+40];for(let bt=0;bt<10;bt+=2){const mt=(bt+8)%10,vt=(bt+2)%10,$t=d[vt],At=d[vt+1],Mt=rotlH($t,At,1)^d[mt],Tt=rotlL($t,At,1)^d[mt+1];for(let Rt=0;Rt<50;Rt+=10)c[bt+Rt]^=Mt,c[bt+Rt+1]^=Tt}let nt=c[2],tt=c[3];for(let bt=0;bt<24;bt++){const mt=SHA3_ROTL[bt],vt=rotlH(nt,tt,mt),$t=rotlL(nt,tt,mt),At=SHA3_PI[bt];nt=c[At],tt=c[At+1],c[At]=vt,c[At+1]=$t}for(let bt=0;bt<50;bt+=10){for(let mt=0;mt<10;mt++)d[mt]=c[bt+mt];for(let mt=0;mt<10;mt++)c[bt+mt]^=~d[(mt+2)%10]&d[(mt+4)%10]}c[0]^=SHA3_IOTA_H[et],c[1]^=SHA3_IOTA_L[et]}d.fill(0)}class Keccak extends Hash{constructor(a,d,et,nt=!1,tt=24){if(super(),this.blockLen=a,this.suffix=d,this.outputLen=et,this.enableXOF=nt,this.rounds=tt,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,number(et),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=u32(this.state)}keccak(){keccakP(this.state32,this.rounds),this.posOut=0,this.pos=0}update(a){exists(this);const{blockLen:d,state:et}=this;a=toBytes(a);const nt=a.length;for(let tt=0;tt=et&&this.keccak();const bt=Math.min(et-this.posOut,tt-nt);a.set(d.subarray(this.posOut,this.posOut+bt),nt),this.posOut+=bt,nt+=bt}return a}xofInto(a){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(a)}xof(a){return number(a),this.xofInto(new Uint8Array(a))}digestInto(a){if(output(a,this),this.finished)throw new Error("digest() was already called");return this.writeInto(a),this.destroy(),a}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(a){const{blockLen:d,suffix:et,outputLen:nt,rounds:tt,enableXOF:bt}=this;return a||(a=new Keccak(d,et,nt,bt,tt)),a.state32.set(this.state32),a.pos=this.pos,a.posOut=this.posOut,a.finished=this.finished,a.rounds=tt,a.suffix=et,a.outputLen=nt,a.enableXOF=bt,a.destroyed=this.destroyed,a}}const gen=(c,a,d)=>wrapConstructor(()=>new Keccak(a,c,d)),keccak_256=gen(1,136,256/8);function keccak256(c,a){const d=a||"hex",et=keccak_256(isHex(c,{strict:!1})?toBytes$1(c):c);return d==="bytes"?et:toHex(et)}const hash=c=>keccak256(toBytes$1(c));function hashSignature(c){return hash(c)}function normalizeSignature(c){let a=!0,d="",et=0,nt="",tt=!1;for(let bt=0;bt{const a=(()=>typeof c=="string"?c:formatAbiItem$1(c))();return normalizeSignature(a)};function toSignatureHash(c){return hashSignature(toSignature(c))}const toEventSelector=toSignatureHash;class InvalidAddressError extends BaseError{constructor({address:a}){super(`Address "${a}" is invalid.`,{metaMessages:["- Address must be a hex value of 20 bytes (40 hex characters).","- Address must match its checksum counterpart."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}}class LruMap extends Map{constructor(a){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=a}set(a,d){return super.set(a,d),this.maxSize&&this.size>this.maxSize&&this.delete(this.keys().next().value),this}}function checksumAddress(c,a){const d=a?`${a}${c.toLowerCase()}`:c.substring(2).toLowerCase(),et=keccak256(stringToBytes(d),"bytes"),nt=(a?d.substring(`${a}0x`.length):d).split("");for(let tt=0;tt<40;tt+=2)et[tt>>1]>>4>=8&&nt[tt]&&(nt[tt]=nt[tt].toUpperCase()),(et[tt>>1]&15)>=8&&nt[tt+1]&&(nt[tt+1]=nt[tt+1].toUpperCase());return`0x${nt.join("")}`}function getAddress(c,a){if(!isAddress(c,{strict:!1}))throw new InvalidAddressError({address:c});return checksumAddress(c,a)}const addressRegex=/^0x[a-fA-F0-9]{40}$/,isAddressCache=new LruMap(8192);function isAddress(c,a){const{strict:d=!0}=a??{};if(isAddressCache.has(c))return isAddressCache.get(c);const et=(()=>addressRegex.test(c)?c.toLowerCase()===c?!0:d?checksumAddress(c)===c:!0:!1)();return isAddressCache.set(c,et),et}function concat(c){return typeof c[0]=="string"?concatHex(c):concatBytes(c)}function concatBytes(c){let a=0;for(const nt of c)a+=nt.length;const d=new Uint8Array(a);let et=0;for(const nt of c)d.set(nt,et),et+=nt.length;return d}function concatHex(c){return`0x${c.reduce((a,d)=>a+d.replace("0x",""),"")}`}function slice(c,a,d,{strict:et}={}){return isHex(c,{strict:!1})?sliceHex(c,a,d,{strict:et}):sliceBytes(c,a,d,{strict:et})}function assertStartOffset(c,a){if(typeof a=="number"&&a>0&&a>size$1(c)-1)throw new SliceOffsetOutOfBoundsError({offset:a,position:"start",size:size$1(c)})}function assertEndOffset(c,a,d){if(typeof a=="number"&&typeof d=="number"&&size$1(c)!==d-a)throw new SliceOffsetOutOfBoundsError({offset:d,position:"end",size:size$1(c)})}function sliceBytes(c,a,d,{strict:et}={}){assertStartOffset(c,a);const nt=c.slice(a,d);return et&&assertEndOffset(nt,a,d),nt}function sliceHex(c,a,d,{strict:et}={}){assertStartOffset(c,a);const nt=`0x${c.replace("0x","").slice((a??0)*2,(d??c.length)*2)}`;return et&&assertEndOffset(nt,a,d),nt}function encodeAbiParameters(c,a){if(c.length!==a.length)throw new AbiEncodingLengthMismatchError({expectedLength:c.length,givenLength:a.length});const d=prepareParams({params:c,values:a}),et=encodeParams(d);return et.length===0?"0x":et}function prepareParams({params:c,values:a}){const d=[];for(let et=0;et0?concat([mt,bt]):mt}}if(nt)return{dynamic:!0,encoded:bt}}return{dynamic:!1,encoded:concat(tt.map(({encoded:bt})=>bt))}}function encodeBytes(c,{param:a}){const[,d]=a.type.split("bytes"),et=size$1(c);if(!d){let nt=c;return et%32!==0&&(nt=padHex(nt,{dir:"right",size:Math.ceil((c.length-2)/2/32)*32})),{dynamic:!0,encoded:concat([padHex(numberToHex(et,{size:32})),nt])}}if(et!==parseInt(d))throw new AbiEncodingBytesSizeMismatchError({expectedSize:parseInt(d),value:c});return{dynamic:!1,encoded:padHex(c,{dir:"right"})}}function encodeBool(c){if(typeof c!="boolean")throw new BaseError(`Invalid boolean value: "${c}" (type: ${typeof c}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:padHex(boolToHex(c))}}function encodeNumber(c,{signed:a}){return{dynamic:!1,encoded:numberToHex(c,{size:32,signed:a})}}function encodeString(c){const a=stringToHex(c),d=Math.ceil(size$1(a)/32),et=[];for(let nt=0;ntnt))}}function getArrayComponents(c){const a=c.match(/^(.*)\[(\d+)?\]$/);return a?[a[2]?Number(a[2]):null,a[1]]:void 0}const toFunctionSelector=c=>slice(toSignatureHash(c),0,4);function getAbiItem(c){const{abi:a,args:d=[],name:et}=c,nt=isHex(et,{strict:!1}),tt=a.filter(mt=>nt?mt.type==="function"?toFunctionSelector(mt)===et:mt.type==="event"?toEventSelector(mt)===et:!1:"name"in mt&&mt.name===et);if(tt.length===0)return;if(tt.length===1)return tt[0];let bt;for(const mt of tt){if(!("inputs"in mt))continue;if(!d||d.length===0){if(!mt.inputs||mt.inputs.length===0)return mt;continue}if(!mt.inputs||mt.inputs.length===0||mt.inputs.length!==d.length)continue;if(d.every(($t,At)=>{const Mt="inputs"in mt&&mt.inputs[At];return Mt?isArgOfType($t,Mt):!1})){if(bt&&"inputs"in bt&&bt.inputs){const $t=getAmbiguousTypes(mt.inputs,bt.inputs,d);if($t)throw new AbiItemAmbiguityError({abiItem:mt,type:$t[0]},{abiItem:bt,type:$t[1]})}bt=mt}}return bt||tt[0]}function isArgOfType(c,a){const d=typeof c,et=a.type;switch(et){case"address":return isAddress(c,{strict:!1});case"bool":return d==="boolean";case"function":return d==="string";case"string":return d==="string";default:return et==="tuple"&&"components"in a?Object.values(a.components).every((nt,tt)=>isArgOfType(Object.values(c)[tt],nt)):/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/.test(et)?d==="number"||d==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(et)?d==="string"||c instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(et)?Array.isArray(c)&&c.every(nt=>isArgOfType(nt,{...a,type:et.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function getAmbiguousTypes(c,a,d){for(const et in c){const nt=c[et],tt=a[et];if(nt.type==="tuple"&&tt.type==="tuple"&&"components"in nt&&"components"in tt)return getAmbiguousTypes(nt.components,tt.components,d[et]);const bt=[nt.type,tt.type];if((()=>bt.includes("address")&&bt.includes("bytes20")?!0:bt.includes("address")&&bt.includes("string")?isAddress(d[et],{strict:!1}):bt.includes("address")&&bt.includes("bytes")?isAddress(d[et],{strict:!1}):!1)())return bt}}const docsPath$4="/docs/contract/encodeEventTopics";function encodeEventTopics(c){var vt;const{abi:a,eventName:d,args:et}=c;let nt=a[0];if(d){const $t=getAbiItem({abi:a,name:d});if(!$t)throw new AbiEventNotFoundError(d,{docsPath:docsPath$4});nt=$t}if(nt.type!=="event")throw new AbiEventNotFoundError(void 0,{docsPath:docsPath$4});const tt=formatAbiItem(nt),bt=toEventSelector(tt);let mt=[];if(et&&"inputs"in nt){const $t=(vt=nt.inputs)==null?void 0:vt.filter(Mt=>"indexed"in Mt&&Mt.indexed),At=Array.isArray(et)?et:Object.values(et).length>0?($t==null?void 0:$t.map(Mt=>et[Mt.name]))??[]:[];At.length>0&&(mt=($t==null?void 0:$t.map((Mt,Tt)=>Array.isArray(At[Tt])?At[Tt].map((Rt,kt)=>encodeArg({param:Mt,value:At[Tt][kt]})):At[Tt]?encodeArg({param:Mt,value:At[Tt]}):null))??[])}return[bt,...mt]}function encodeArg({param:c,value:a}){if(c.type==="string"||c.type==="bytes")return keccak256(toBytes$1(a));if(c.type==="tuple"||c.type.match(/^(.*)\[(\d+)?\]$/))throw new FilterTypeNotSupportedError(c.type);return encodeAbiParameters([c],[a])}function createFilterRequestScope(c,{method:a}){var et,nt;const d={};return c.transport.type==="fallback"&&((nt=(et=c.transport).onResponse)==null||nt.call(et,({method:tt,response:bt,status:mt,transport:vt})=>{mt==="success"&&a===tt&&(d[bt]=vt.request)})),tt=>d[tt]||c.request}async function createContractEventFilter(c,a){const{address:d,abi:et,args:nt,eventName:tt,fromBlock:bt,strict:mt,toBlock:vt}=a,$t=createFilterRequestScope(c,{method:"eth_newFilter"}),At=tt?encodeEventTopics({abi:et,args:nt,eventName:tt}):void 0,Mt=await c.request({method:"eth_newFilter",params:[{address:d,fromBlock:typeof bt=="bigint"?numberToHex(bt):bt,toBlock:typeof vt=="bigint"?numberToHex(vt):vt,topics:At}]});return{abi:et,args:nt,eventName:tt,id:Mt,request:$t(Mt),strict:!!mt,type:"event"}}function parseAccount(c){return typeof c=="string"?{address:c,type:"json-rpc"}:c}const docsPath$3="/docs/contract/encodeFunctionData";function prepareEncodeFunctionData(c){const{abi:a,args:d,functionName:et}=c;let nt=a[0];if(et){const tt=getAbiItem({abi:a,args:d,name:et});if(!tt)throw new AbiFunctionNotFoundError(et,{docsPath:docsPath$3});nt=tt}if(nt.type!=="function")throw new AbiFunctionNotFoundError(void 0,{docsPath:docsPath$3});return{abi:[nt],functionName:toFunctionSelector(formatAbiItem(nt))}}function encodeFunctionData(c){const{args:a}=c,{abi:d,functionName:et}=(()=>{var mt;return c.abi.length===1&&((mt=c.functionName)!=null&&mt.startsWith("0x"))?c:prepareEncodeFunctionData(c)})(),nt=d[0],tt=et,bt="inputs"in nt&&nt.inputs?encodeAbiParameters(nt.inputs,a??[]):void 0;return concatHex([tt,bt??"0x"])}const panicReasons={1:"An `assert` condition failed.",17:"Arithmetic operation resulted in underflow or overflow.",18:"Division or modulo by zero (e.g. `5 / 0` or `23 % 0`).",33:"Attempted to convert to an invalid type.",34:"Attempted to access a storage byte array that is incorrectly encoded.",49:"Performed `.pop()` on an empty array",50:"Array index is out of bounds.",65:"Allocated too much memory or created an array which is too large.",81:"Attempted to call a zero-initialized variable of internal function type."},solidityError={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},solidityPanic={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"};class NegativeOffsetError extends BaseError{constructor({offset:a}){super(`Offset \`${a}\` cannot be negative.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NegativeOffsetError"})}}class PositionOutOfBoundsError extends BaseError{constructor({length:a,position:d}){super(`Position \`${d}\` is out of bounds (\`0 < position < ${a}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PositionOutOfBoundsError"})}}class RecursiveReadLimitExceededError extends BaseError{constructor({count:a,limit:d}){super(`Recursive read limit of \`${d}\` exceeded (recursive read count: \`${a}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RecursiveReadLimitExceededError"})}}const staticCursor={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:1/0,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new RecursiveReadLimitExceededError({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(c){if(c<0||c>this.bytes.length-1)throw new PositionOutOfBoundsError({length:this.bytes.length,position:c})},decrementPosition(c){if(c<0)throw new NegativeOffsetError({offset:c});const a=this.position-c;this.assertPosition(a),this.position=a},getReadCount(c){return this.positionReadCount.get(c||this.position)||0},incrementPosition(c){if(c<0)throw new NegativeOffsetError({offset:c});const a=this.position+c;this.assertPosition(a),this.position=a},inspectByte(c){const a=c??this.position;return this.assertPosition(a),this.bytes[a]},inspectBytes(c,a){const d=a??this.position;return this.assertPosition(d+c-1),this.bytes.subarray(d,d+c)},inspectUint8(c){const a=c??this.position;return this.assertPosition(a),this.bytes[a]},inspectUint16(c){const a=c??this.position;return this.assertPosition(a+1),this.dataView.getUint16(a)},inspectUint24(c){const a=c??this.position;return this.assertPosition(a+2),(this.dataView.getUint16(a)<<8)+this.dataView.getUint8(a+2)},inspectUint32(c){const a=c??this.position;return this.assertPosition(a+3),this.dataView.getUint32(a)},pushByte(c){this.assertPosition(this.position),this.bytes[this.position]=c,this.position++},pushBytes(c){this.assertPosition(this.position+c.length-1),this.bytes.set(c,this.position),this.position+=c.length},pushUint8(c){this.assertPosition(this.position),this.bytes[this.position]=c,this.position++},pushUint16(c){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,c),this.position+=2},pushUint24(c){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,c>>8),this.dataView.setUint8(this.position+2,c&255),this.position+=3},pushUint32(c){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,c),this.position+=4},readByte(){this.assertReadLimit(),this._touch();const c=this.inspectByte();return this.position++,c},readBytes(c,a){this.assertReadLimit(),this._touch();const d=this.inspectBytes(c);return this.position+=a??c,d},readUint8(){this.assertReadLimit(),this._touch();const c=this.inspectUint8();return this.position+=1,c},readUint16(){this.assertReadLimit(),this._touch();const c=this.inspectUint16();return this.position+=2,c},readUint24(){this.assertReadLimit(),this._touch();const c=this.inspectUint24();return this.position+=3,c},readUint32(){this.assertReadLimit(),this._touch();const c=this.inspectUint32();return this.position+=4,c},get remaining(){return this.bytes.length-this.position},setPosition(c){const a=this.position;return this.assertPosition(c),this.position=c,()=>this.position=a},_touch(){if(this.recursiveReadLimit===1/0)return;const c=this.getReadCount();this.positionReadCount.set(this.position,c+1),c>0&&this.recursiveReadCount++}};function createCursor(c,{recursiveReadLimit:a=8192}={}){const d=Object.create(staticCursor);return d.bytes=c,d.dataView=new DataView(c.buffer,c.byteOffset,c.byteLength),d.positionReadCount=new Map,d.recursiveReadLimit=a,d}function bytesToBigInt(c,a={}){typeof a.size<"u"&&assertSize(c,{size:a.size});const d=bytesToHex(c,a);return hexToBigInt(d,a)}function bytesToBool(c,a={}){let d=c;if(typeof a.size<"u"&&(assertSize(d,{size:a.size}),d=trim(d)),d.length>1||d[0]>1)throw new InvalidBytesBooleanError(d);return!!d[0]}function bytesToNumber(c,a={}){typeof a.size<"u"&&assertSize(c,{size:a.size});const d=bytesToHex(c,a);return hexToNumber(d,a)}function bytesToString(c,a={}){let d=c;return typeof a.size<"u"&&(assertSize(d,{size:a.size}),d=trim(d,{dir:"right"})),new TextDecoder().decode(d)}function decodeAbiParameters(c,a){const d=typeof a=="string"?hexToBytes(a):a,et=createCursor(d);if(size$1(d)===0&&c.length>0)throw new AbiDecodingZeroDataError;if(size$1(a)&&size$1(a)<32)throw new AbiDecodingDataSizeTooSmallError({data:typeof a=="string"?a:bytesToHex(a),params:c,size:size$1(a)});let nt=0;const tt=[];for(let bt=0;bt48?bytesToBigInt(nt,{signed:d}):bytesToNumber(nt,{signed:d}),32]}function decodeTuple(c,a,{staticPosition:d}){const et=a.components.length===0||a.components.some(({name:bt})=>!bt),nt=et?[]:{};let tt=0;if(hasDynamicChild(a)){const bt=bytesToNumber(c.readBytes(sizeOfOffset)),mt=d+bt;for(let vt=0;vtbt.type==="error"&&et===toFunctionSelector(formatAbiItem(bt)));if(!tt)throw new AbiErrorSignatureNotFoundError(et,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:tt,args:"inputs"in tt&&tt.inputs&&tt.inputs.length>0?decodeAbiParameters(tt.inputs,slice(d,4)):void 0,errorName:tt.name}}const stringify=(c,a,d)=>JSON.stringify(c,(et,nt)=>{const tt=typeof nt=="bigint"?nt.toString():nt;return typeof a=="function"?a(et,tt):tt},d);function formatAbiItemWithArgs({abiItem:c,args:a,includeFunctionName:d=!0,includeName:et=!1}){if("name"in c&&"inputs"in c&&c.inputs)return`${d?c.name:""}(${c.inputs.map((nt,tt)=>`${et&&nt.name?`${nt.name}: `:""}${typeof a[tt]=="object"?stringify(a[tt]):a[tt]}`).join(", ")})`}const etherUnits={gwei:9,wei:18},gweiUnits={ether:-9,wei:9};function formatUnits(c,a){let d=c.toString();const et=d.startsWith("-");et&&(d=d.slice(1)),d=d.padStart(a,"0");let[nt,tt]=[d.slice(0,d.length-a),d.slice(d.length-a)];return tt=tt.replace(/(0+)$/,""),`${et?"-":""}${nt||"0"}${tt?`.${tt}`:""}`}function formatEther(c,a="wei"){return formatUnits(c,etherUnits[a])}function formatGwei(c,a="wei"){return formatUnits(c,gweiUnits[a])}class AccountStateConflictError extends BaseError{constructor({address:a}){super(`State for account "${a}" is set multiple times.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountStateConflictError"})}}class StateAssignmentConflictError extends BaseError{constructor(){super("state and stateDiff are set on the same account."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"StateAssignmentConflictError"})}}function prettyStateMapping(c){return c.reduce((a,{slot:d,value:et})=>`${a} ${d}: ${et} +`,"")}function prettyStateOverride(c){return c.reduce((a,{address:d,...et})=>{let nt=`${a} ${d}: +`;return et.nonce&&(nt+=` nonce: ${et.nonce} +`),et.balance&&(nt+=` balance: ${et.balance} +`),et.code&&(nt+=` code: ${et.code} +`),et.state&&(nt+=` state: +`,nt+=prettyStateMapping(et.state)),et.stateDiff&&(nt+=` stateDiff: +`,nt+=prettyStateMapping(et.stateDiff)),nt},` State Override: +`).slice(0,-1)}function prettyPrint$1(c){const a=Object.entries(c).map(([et,nt])=>nt===void 0||nt===!1?null:[et,nt]).filter(Boolean),d=a.reduce((et,[nt])=>Math.max(et,nt.length),0);return a.map(([et,nt])=>` ${`${et}:`.padEnd(d+1)} ${nt}`).join(` +`)}class FeeConflictError extends BaseError{constructor(){super(["Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.","Use `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."].join(` +`)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeConflictError"})}}class InvalidLegacyVError extends BaseError{constructor({v:a}){super(`Invalid \`v\` value "${a}". Expected 27 or 28.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidLegacyVError"})}}class InvalidSerializableTransactionError extends BaseError{constructor({transaction:a}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",prettyPrint$1(a),"}","","To infer the type, either provide:","- a `type` to the Transaction, or","- an EIP-1559 Transaction with `maxFeePerGas`, or","- an EIP-2930 Transaction with `gasPrice` & `accessList`, or","- an EIP-4844 Transaction with `blobs`, `blobVersionedHashes`, `sidecars`, or","- a Legacy Transaction with `gasPrice`"]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSerializableTransactionError"})}}class InvalidStorageKeySizeError extends BaseError{constructor({storageKey:a}){super(`Size for storage key "${a}" is invalid. Expected 32 bytes. Got ${Math.floor((a.length-2)/2)} bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidStorageKeySizeError"})}}class TransactionNotFoundError extends BaseError{constructor({blockHash:a,blockNumber:d,blockTag:et,hash:nt,index:tt}){let bt="Transaction";et&&tt!==void 0&&(bt=`Transaction at block time "${et}" at index "${tt}"`),a&&tt!==void 0&&(bt=`Transaction at block hash "${a}" at index "${tt}"`),d&&tt!==void 0&&(bt=`Transaction at block number "${d}" at index "${tt}"`),nt&&(bt=`Transaction with hash "${nt}"`),super(`${bt} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionNotFoundError"})}}class TransactionReceiptNotFoundError extends BaseError{constructor({hash:a}){super(`Transaction receipt with hash "${a}" could not be found. The Transaction may not be processed on a block yet.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionReceiptNotFoundError"})}}class WaitForTransactionReceiptTimeoutError extends BaseError{constructor({hash:a}){super(`Timed out while waiting for transaction with hash "${a}" to be confirmed.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WaitForTransactionReceiptTimeoutError"})}}class CallExecutionError extends BaseError{constructor(a,{account:d,docsPath:et,chain:nt,data:tt,gas:bt,gasPrice:mt,maxFeePerGas:vt,maxPriorityFeePerGas:$t,nonce:At,to:Mt,value:Tt,stateOverride:Rt}){var Dt;const kt=d?parseAccount(d):void 0;let It=prettyPrint$1({from:kt==null?void 0:kt.address,to:Mt,value:typeof Tt<"u"&&`${formatEther(Tt)} ${((Dt=nt==null?void 0:nt.nativeCurrency)==null?void 0:Dt.symbol)||"ETH"}`,data:tt,gas:bt,gasPrice:typeof mt<"u"&&`${formatGwei(mt)} gwei`,maxFeePerGas:typeof vt<"u"&&`${formatGwei(vt)} gwei`,maxPriorityFeePerGas:typeof $t<"u"&&`${formatGwei($t)} gwei`,nonce:At});Rt&&(It+=` +${prettyStateOverride(Rt)}`),super(a.shortMessage,{cause:a,docsPath:et,metaMessages:[...a.metaMessages?[...a.metaMessages," "]:[],"Raw Call Arguments:",It].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"CallExecutionError"}),this.cause=a}}class ContractFunctionExecutionError extends BaseError{constructor(a,{abi:d,args:et,contractAddress:nt,docsPath:tt,functionName:bt,sender:mt}){const vt=getAbiItem({abi:d,args:et,name:bt}),$t=vt?formatAbiItemWithArgs({abiItem:vt,args:et,includeFunctionName:!1,includeName:!1}):void 0,At=vt?formatAbiItem(vt,{includeName:!0}):void 0,Mt=prettyPrint$1({address:nt&&getContractAddress(nt),function:At,args:$t&&$t!=="()"&&`${[...Array((bt==null?void 0:bt.length)??0).keys()].map(()=>" ").join("")}${$t}`,sender:mt});super(a.shortMessage||`An unknown error occurred while executing the contract function "${bt}".`,{cause:a,docsPath:tt,metaMessages:[...a.metaMessages?[...a.metaMessages," "]:[],"Contract Call:",Mt].filter(Boolean)}),Object.defineProperty(this,"abi",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"args",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"contractAddress",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"formattedArgs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"functionName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sender",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionExecutionError"}),this.abi=d,this.args=et,this.cause=a,this.contractAddress=nt,this.functionName=bt,this.sender=mt}}class ContractFunctionRevertedError extends BaseError{constructor({abi:a,data:d,functionName:et,message:nt}){let tt,bt,mt,vt;if(d&&d!=="0x")try{bt=decodeErrorResult({abi:a,data:d});const{abiItem:At,errorName:Mt,args:Tt}=bt;if(Mt==="Error")vt=Tt[0];else if(Mt==="Panic"){const[Rt]=Tt;vt=panicReasons[Rt]}else{const Rt=At?formatAbiItem(At,{includeName:!0}):void 0,kt=At&&Tt?formatAbiItemWithArgs({abiItem:At,args:Tt,includeFunctionName:!1,includeName:!1}):void 0;mt=[Rt?`Error: ${Rt}`:"",kt&&kt!=="()"?` ${[...Array((Mt==null?void 0:Mt.length)??0).keys()].map(()=>" ").join("")}${kt}`:""]}}catch(At){tt=At}else nt&&(vt=nt);let $t;tt instanceof AbiErrorSignatureNotFoundError&&($t=tt.signature,mt=[`Unable to decode signature "${$t}" as it was not found on the provided ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://openchain.xyz/signatures?query=${$t}.`]),super(vt&&vt!=="execution reverted"||$t?[`The contract function "${et}" reverted with the following ${$t?"signature":"reason"}:`,vt||$t].join(` +`):`The contract function "${et}" reverted.`,{cause:tt,metaMessages:mt}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"reason",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=bt,this.reason=vt,this.signature=$t}}class ContractFunctionZeroDataError extends BaseError{constructor({functionName:a}){super(`The contract function "${a}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",` - The contract does not have the function "${a}",`," - The parameters passed to the contract function may be invalid, or"," - The address is not a contract."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionZeroDataError"})}}class RawContractError extends BaseError{constructor({data:a,message:d}){super(d||""),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RawContractError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=a}}class HttpRequestError extends BaseError{constructor({body:a,details:d,headers:et,status:nt,url:tt}){super("HTTP request failed.",{details:d,metaMessages:[nt&&`Status: ${nt}`,`URL: ${getUrl(tt)}`,a&&`Request body: ${stringify(a)}`].filter(Boolean)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"HttpRequestError"}),Object.defineProperty(this,"body",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"headers",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"status",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.body=a,this.headers=et,this.status=nt,this.url=tt}}class RpcRequestError extends BaseError{constructor({body:a,error:d,url:et}){super("RPC Request failed.",{cause:d,details:d.message,metaMessages:[`URL: ${getUrl(et)}`,`Request body: ${stringify(a)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=d.code}}class TimeoutError extends BaseError{constructor({body:a,url:d}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${getUrl(d)}`,`Request body: ${stringify(a)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TimeoutError"})}}const unknownErrorCode=-1;class RpcError extends BaseError{constructor(a,{code:d,docsPath:et,metaMessages:nt,shortMessage:tt}){super(tt,{cause:a,docsPath:et,metaMessages:nt||(a==null?void 0:a.metaMessages)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=a.name,this.code=a instanceof RpcRequestError?a.code:d??unknownErrorCode}}class ProviderRpcError extends RpcError{constructor(a,d){super(a,d),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderRpcError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=d.data}}class ParseRpcError extends RpcError{constructor(a){super(a,{code:ParseRpcError.code,shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ParseRpcError"})}}Object.defineProperty(ParseRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});class InvalidRequestRpcError extends RpcError{constructor(a){super(a,{code:InvalidRequestRpcError.code,shortMessage:"JSON is not a valid request object."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidRequestRpcError"})}}Object.defineProperty(InvalidRequestRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});class MethodNotFoundRpcError extends RpcError{constructor(a){super(a,{code:MethodNotFoundRpcError.code,shortMessage:"The method does not exist / is not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotFoundRpcError"})}}Object.defineProperty(MethodNotFoundRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});class InvalidParamsRpcError extends RpcError{constructor(a){super(a,{code:InvalidParamsRpcError.code,shortMessage:["Invalid parameters were provided to the RPC method.","Double check you have provided the correct parameters."].join(` +`)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParamsRpcError"})}}Object.defineProperty(InvalidParamsRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});class InternalRpcError extends RpcError{constructor(a){super(a,{code:InternalRpcError.code,shortMessage:"An internal error was received."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InternalRpcError"})}}Object.defineProperty(InternalRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});class InvalidInputRpcError extends RpcError{constructor(a){super(a,{code:InvalidInputRpcError.code,shortMessage:["Missing or invalid parameters.","Double check you have provided the correct parameters."].join(` +`)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidInputRpcError"})}}Object.defineProperty(InvalidInputRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});class ResourceNotFoundRpcError extends RpcError{constructor(a){super(a,{code:ResourceNotFoundRpcError.code,shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}}Object.defineProperty(ResourceNotFoundRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});class ResourceUnavailableRpcError extends RpcError{constructor(a){super(a,{code:ResourceUnavailableRpcError.code,shortMessage:"Requested resource not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceUnavailableRpcError"})}}Object.defineProperty(ResourceUnavailableRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});class TransactionRejectedRpcError extends RpcError{constructor(a){super(a,{code:TransactionRejectedRpcError.code,shortMessage:"Transaction creation failed."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionRejectedRpcError"})}}Object.defineProperty(TransactionRejectedRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});class MethodNotSupportedRpcError extends RpcError{constructor(a){super(a,{code:MethodNotSupportedRpcError.code,shortMessage:"Method is not implemented."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotSupportedRpcError"})}}Object.defineProperty(MethodNotSupportedRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});class LimitExceededRpcError extends RpcError{constructor(a){super(a,{code:LimitExceededRpcError.code,shortMessage:"Request exceeds defined limit."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"LimitExceededRpcError"})}}Object.defineProperty(LimitExceededRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});class JsonRpcVersionUnsupportedError extends RpcError{constructor(a){super(a,{code:JsonRpcVersionUnsupportedError.code,shortMessage:"Version of JSON-RPC protocol is not supported."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"JsonRpcVersionUnsupportedError"})}}Object.defineProperty(JsonRpcVersionUnsupportedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});class UserRejectedRequestError extends ProviderRpcError{constructor(a){super(a,{code:UserRejectedRequestError.code,shortMessage:"User rejected the request."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UserRejectedRequestError"})}}Object.defineProperty(UserRejectedRequestError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});class UnauthorizedProviderError extends ProviderRpcError{constructor(a){super(a,{code:UnauthorizedProviderError.code,shortMessage:"The requested method and/or account has not been authorized by the user."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnauthorizedProviderError"})}}Object.defineProperty(UnauthorizedProviderError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});class UnsupportedProviderMethodError extends ProviderRpcError{constructor(a){super(a,{code:UnsupportedProviderMethodError.code,shortMessage:"The Provider does not support the requested method."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedProviderMethodError"})}}Object.defineProperty(UnsupportedProviderMethodError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});class ProviderDisconnectedError extends ProviderRpcError{constructor(a){super(a,{code:ProviderDisconnectedError.code,shortMessage:"The Provider is disconnected from all chains."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderDisconnectedError"})}}Object.defineProperty(ProviderDisconnectedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});class ChainDisconnectedError extends ProviderRpcError{constructor(a){super(a,{code:ChainDisconnectedError.code,shortMessage:"The Provider is not connected to the requested chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDisconnectedError"})}}Object.defineProperty(ChainDisconnectedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});class SwitchChainError extends ProviderRpcError{constructor(a){super(a,{code:SwitchChainError.code,shortMessage:"An error occurred when attempting to switch chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SwitchChainError"})}}Object.defineProperty(SwitchChainError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});class UnknownRpcError extends RpcError{constructor(a){super(a,{shortMessage:"An unknown RPC error occurred."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownRpcError"})}}const EXECUTION_REVERTED_ERROR_CODE=3;function getContractError(c,{abi:a,address:d,args:et,docsPath:nt,functionName:tt,sender:bt}){const{code:mt,data:vt,message:$t,shortMessage:At}=c instanceof RawContractError?c:c instanceof BaseError?c.walk(Tt=>"data"in Tt)||c.walk():{},Mt=(()=>c instanceof AbiDecodingZeroDataError?new ContractFunctionZeroDataError({functionName:tt}):[EXECUTION_REVERTED_ERROR_CODE,InternalRpcError.code].includes(mt)&&(vt||$t||At)?new ContractFunctionRevertedError({abi:a,data:typeof vt=="object"?vt.data:vt,functionName:tt,message:At??$t}):c)();return new ContractFunctionExecutionError(Mt,{abi:a,args:et,contractAddress:d,docsPath:nt,functionName:tt,sender:bt})}class EstimateGasExecutionError extends BaseError{constructor(a,{account:d,docsPath:et,chain:nt,data:tt,gas:bt,gasPrice:mt,maxFeePerGas:vt,maxPriorityFeePerGas:$t,nonce:At,to:Mt,value:Tt}){var kt;const Rt=prettyPrint$1({from:d==null?void 0:d.address,to:Mt,value:typeof Tt<"u"&&`${formatEther(Tt)} ${((kt=nt==null?void 0:nt.nativeCurrency)==null?void 0:kt.symbol)||"ETH"}`,data:tt,gas:bt,gasPrice:typeof mt<"u"&&`${formatGwei(mt)} gwei`,maxFeePerGas:typeof vt<"u"&&`${formatGwei(vt)} gwei`,maxPriorityFeePerGas:typeof $t<"u"&&`${formatGwei($t)} gwei`,nonce:At});super(a.shortMessage,{cause:a,docsPath:et,metaMessages:[...a.metaMessages?[...a.metaMessages," "]:[],"Estimate Gas Arguments:",Rt].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EstimateGasExecutionError"}),this.cause=a}}class ExecutionRevertedError extends BaseError{constructor({cause:a,message:d}={}){var nt;const et=(nt=d==null?void 0:d.replace("execution reverted: ",""))==null?void 0:nt.replace("execution reverted","");super(`Execution reverted ${et?`with reason: ${et}`:"for an unknown reason"}.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ExecutionRevertedError"})}}Object.defineProperty(ExecutionRevertedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:3});Object.defineProperty(ExecutionRevertedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/});class FeeCapTooHighError extends BaseError{constructor({cause:a,maxFeePerGas:d}={}){super(`The fee cap (\`maxFeePerGas\`${d?` = ${formatGwei(d)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooHigh"})}}Object.defineProperty(FeeCapTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});class FeeCapTooLowError extends BaseError{constructor({cause:a,maxFeePerGas:d}={}){super(`The fee cap (\`maxFeePerGas\`${d?` = ${formatGwei(d)}`:""} gwei) cannot be lower than the block base fee.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooLow"})}}Object.defineProperty(FeeCapTooLowError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/});class NonceTooHighError extends BaseError{constructor({cause:a,nonce:d}={}){super(`Nonce provided for the transaction ${d?`(${d}) `:""}is higher than the next one expected.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooHighError"})}}Object.defineProperty(NonceTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});class NonceTooLowError extends BaseError{constructor({cause:a,nonce:d}={}){super([`Nonce provided for the transaction ${d?`(${d}) `:""}is lower than the current nonce of the account.`,"Try increasing the nonce or find the latest nonce with `getTransactionCount`."].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooLowError"})}}Object.defineProperty(NonceTooLowError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});class NonceMaxValueError extends BaseError{constructor({cause:a,nonce:d}={}){super(`Nonce provided for the transaction ${d?`(${d}) `:""}exceeds the maximum allowed nonce.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceMaxValueError"})}}Object.defineProperty(NonceMaxValueError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});class InsufficientFundsError extends BaseError{constructor({cause:a}={}){super(["The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."].join(` +`),{cause:a,metaMessages:["This error could arise when the account does not have enough funds to:"," - pay for the total gas fee,"," - pay for the value to send."," ","The cost of the transaction is calculated as `gas * gas fee + value`, where:"," - `gas` is the amount of gas needed for transaction to execute,"," - `gas fee` is the gas fee,"," - `value` is the amount of ether to send to the recipient."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InsufficientFundsError"})}}Object.defineProperty(InsufficientFundsError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds/});class IntrinsicGasTooHighError extends BaseError{constructor({cause:a,gas:d}={}){super(`The amount of gas ${d?`(${d}) `:""}provided for the transaction exceeds the limit allowed for the block.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooHighError"})}}Object.defineProperty(IntrinsicGasTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});class IntrinsicGasTooLowError extends BaseError{constructor({cause:a,gas:d}={}){super(`The amount of gas ${d?`(${d}) `:""}provided for the transaction is too low.`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooLowError"})}}Object.defineProperty(IntrinsicGasTooLowError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});class TransactionTypeNotSupportedError extends BaseError{constructor({cause:a}){super("The transaction type is not supported for this chain.",{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionTypeNotSupportedError"})}}Object.defineProperty(TransactionTypeNotSupportedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});class TipAboveFeeCapError extends BaseError{constructor({cause:a,maxPriorityFeePerGas:d,maxFeePerGas:et}={}){super([`The provided tip (\`maxPriorityFeePerGas\`${d?` = ${formatGwei(d)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${et?` = ${formatGwei(et)} gwei`:""}).`].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TipAboveFeeCapError"})}}Object.defineProperty(TipAboveFeeCapError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});class UnknownNodeError extends BaseError{constructor({cause:a}){super(`An error occurred while executing: ${a==null?void 0:a.shortMessage}`,{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownNodeError"})}}function getNodeError(c,a){const d=(c.details||"").toLowerCase(),et=c instanceof BaseError?c.walk(nt=>nt.code===ExecutionRevertedError.code):c;return et instanceof BaseError?new ExecutionRevertedError({cause:c,message:et.details}):ExecutionRevertedError.nodeMessage.test(d)?new ExecutionRevertedError({cause:c,message:c.details}):FeeCapTooHighError.nodeMessage.test(d)?new FeeCapTooHighError({cause:c,maxFeePerGas:a==null?void 0:a.maxFeePerGas}):FeeCapTooLowError.nodeMessage.test(d)?new FeeCapTooLowError({cause:c,maxFeePerGas:a==null?void 0:a.maxFeePerGas}):NonceTooHighError.nodeMessage.test(d)?new NonceTooHighError({cause:c,nonce:a==null?void 0:a.nonce}):NonceTooLowError.nodeMessage.test(d)?new NonceTooLowError({cause:c,nonce:a==null?void 0:a.nonce}):NonceMaxValueError.nodeMessage.test(d)?new NonceMaxValueError({cause:c,nonce:a==null?void 0:a.nonce}):InsufficientFundsError.nodeMessage.test(d)?new InsufficientFundsError({cause:c}):IntrinsicGasTooHighError.nodeMessage.test(d)?new IntrinsicGasTooHighError({cause:c,gas:a==null?void 0:a.gas}):IntrinsicGasTooLowError.nodeMessage.test(d)?new IntrinsicGasTooLowError({cause:c,gas:a==null?void 0:a.gas}):TransactionTypeNotSupportedError.nodeMessage.test(d)?new TransactionTypeNotSupportedError({cause:c}):TipAboveFeeCapError.nodeMessage.test(d)?new TipAboveFeeCapError({cause:c,maxFeePerGas:a==null?void 0:a.maxFeePerGas,maxPriorityFeePerGas:a==null?void 0:a.maxPriorityFeePerGas}):new UnknownNodeError({cause:c})}function getEstimateGasError(c,{docsPath:a,...d}){const et=(()=>{const nt=getNodeError(c,d);return nt instanceof UnknownNodeError?c:nt})();return new EstimateGasExecutionError(et,{docsPath:a,...d})}function extract(c,{format:a}){if(!a)return{};const d={};function et(tt){const bt=Object.keys(tt);for(const mt of bt)mt in c&&(d[mt]=c[mt]),tt[mt]&&typeof tt[mt]=="object"&&!Array.isArray(tt[mt])&&et(tt[mt])}const nt=a(c||{});return et(nt),d}function defineFormatter(c,a){return({exclude:d,format:et})=>({exclude:d,format:nt=>{const tt=a(nt);if(d)for(const bt of d)delete tt[bt];return{...tt,...et(nt)}},type:c})}const rpcTransactionType={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3"};function formatTransactionRequest(c){const a={};return typeof c.accessList<"u"&&(a.accessList=c.accessList),typeof c.blobVersionedHashes<"u"&&(a.blobVersionedHashes=c.blobVersionedHashes),typeof c.blobs<"u"&&(typeof c.blobs[0]!="string"?a.blobs=c.blobs.map(d=>bytesToHex(d)):a.blobs=c.blobs),typeof c.data<"u"&&(a.data=c.data),typeof c.from<"u"&&(a.from=c.from),typeof c.gas<"u"&&(a.gas=numberToHex(c.gas)),typeof c.gasPrice<"u"&&(a.gasPrice=numberToHex(c.gasPrice)),typeof c.maxFeePerBlobGas<"u"&&(a.maxFeePerBlobGas=numberToHex(c.maxFeePerBlobGas)),typeof c.maxFeePerGas<"u"&&(a.maxFeePerGas=numberToHex(c.maxFeePerGas)),typeof c.maxPriorityFeePerGas<"u"&&(a.maxPriorityFeePerGas=numberToHex(c.maxPriorityFeePerGas)),typeof c.nonce<"u"&&(a.nonce=numberToHex(c.nonce)),typeof c.to<"u"&&(a.to=c.to),typeof c.type<"u"&&(a.type=rpcTransactionType[c.type]),typeof c.value<"u"&&(a.value=numberToHex(c.value)),a}const defineTransactionRequest=defineFormatter("transactionRequest",formatTransactionRequest);function assertRequest(c){const{account:a,gasPrice:d,maxFeePerGas:et,maxPriorityFeePerGas:nt,to:tt}=c,bt=a?parseAccount(a):void 0;if(bt&&!isAddress(bt.address))throw new InvalidAddressError({address:bt.address});if(tt&&!isAddress(tt))throw new InvalidAddressError({address:tt});if(typeof d<"u"&&(typeof et<"u"||typeof nt<"u"))throw new FeeConflictError;if(et&&et>2n**256n-1n)throw new FeeCapTooHighError({maxFeePerGas:et});if(nt&&et&&nt>et)throw new TipAboveFeeCapError({maxFeePerGas:et,maxPriorityFeePerGas:nt})}class BaseFeeScalarError extends BaseError{constructor(){super("`baseFeeMultiplier` must be greater than 1."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseFeeScalarError"})}}class Eip1559FeesNotSupportedError extends BaseError{constructor(){super("Chain does not support EIP-1559 fees."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Eip1559FeesNotSupportedError"})}}class MaxFeePerGasTooLowError extends BaseError{constructor({maxPriorityFeePerGas:a}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${formatGwei(a)} gwei).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MaxFeePerGasTooLowError"})}}class BlockNotFoundError extends BaseError{constructor({blockHash:a,blockNumber:d}){let et="Block";a&&(et=`Block at hash "${a}"`),d&&(et=`Block at number "${d}"`),super(`${et} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlockNotFoundError"})}}const transactionType={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844"};function formatTransaction(c){const a={...c,blockHash:c.blockHash?c.blockHash:null,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,chainId:c.chainId?hexToNumber(c.chainId):void 0,gas:c.gas?BigInt(c.gas):void 0,gasPrice:c.gasPrice?BigInt(c.gasPrice):void 0,maxFeePerBlobGas:c.maxFeePerBlobGas?BigInt(c.maxFeePerBlobGas):void 0,maxFeePerGas:c.maxFeePerGas?BigInt(c.maxFeePerGas):void 0,maxPriorityFeePerGas:c.maxPriorityFeePerGas?BigInt(c.maxPriorityFeePerGas):void 0,nonce:c.nonce?hexToNumber(c.nonce):void 0,to:c.to?c.to:null,transactionIndex:c.transactionIndex?Number(c.transactionIndex):null,type:c.type?transactionType[c.type]:void 0,typeHex:c.type?c.type:void 0,value:c.value?BigInt(c.value):void 0,v:c.v?BigInt(c.v):void 0};return a.yParity=(()=>{if(c.yParity)return Number(c.yParity);if(typeof a.v=="bigint"){if(a.v===0n||a.v===27n)return 0;if(a.v===1n||a.v===28n)return 1;if(a.v>=35n)return a.v%2n===0n?1:0}})(),a.type==="legacy"&&(delete a.accessList,delete a.maxFeePerBlobGas,delete a.maxFeePerGas,delete a.maxPriorityFeePerGas,delete a.yParity),a.type==="eip2930"&&(delete a.maxFeePerBlobGas,delete a.maxFeePerGas,delete a.maxPriorityFeePerGas),a.type==="eip1559"&&delete a.maxFeePerBlobGas,a}const defineTransaction=defineFormatter("transaction",formatTransaction);function formatBlock(c){var d;const a=(d=c.transactions)==null?void 0:d.map(et=>typeof et=="string"?et:formatTransaction(et));return{...c,baseFeePerGas:c.baseFeePerGas?BigInt(c.baseFeePerGas):null,blobGasUsed:c.blobGasUsed?BigInt(c.blobGasUsed):void 0,difficulty:c.difficulty?BigInt(c.difficulty):void 0,excessBlobGas:c.excessBlobGas?BigInt(c.excessBlobGas):void 0,gasLimit:c.gasLimit?BigInt(c.gasLimit):void 0,gasUsed:c.gasUsed?BigInt(c.gasUsed):void 0,hash:c.hash?c.hash:null,logsBloom:c.logsBloom?c.logsBloom:null,nonce:c.nonce?c.nonce:null,number:c.number?BigInt(c.number):null,size:c.size?BigInt(c.size):void 0,timestamp:c.timestamp?BigInt(c.timestamp):void 0,transactions:a,totalDifficulty:c.totalDifficulty?BigInt(c.totalDifficulty):null}}const defineBlock=defineFormatter("block",formatBlock);async function getBlock(c,{blockHash:a,blockNumber:d,blockTag:et,includeTransactions:nt}={}){var At,Mt,Tt;const tt=et??"latest",bt=nt??!1,mt=d!==void 0?numberToHex(d):void 0;let vt=null;if(a?vt=await c.request({method:"eth_getBlockByHash",params:[a,bt]}):vt=await c.request({method:"eth_getBlockByNumber",params:[mt||tt,bt]}),!vt)throw new BlockNotFoundError({blockHash:a,blockNumber:d});return(((Tt=(Mt=(At=c.chain)==null?void 0:At.formatters)==null?void 0:Mt.block)==null?void 0:Tt.format)||formatBlock)(vt)}async function getGasPrice(c){const a=await c.request({method:"eth_gasPrice"});return BigInt(a)}async function estimateMaxPriorityFeePerGas(c,a){return internal_estimateMaxPriorityFeePerGas(c,a)}async function internal_estimateMaxPriorityFeePerGas(c,a){var tt,bt,mt;const{block:d,chain:et=c.chain,request:nt}=a||{};if(typeof((tt=et==null?void 0:et.fees)==null?void 0:tt.defaultPriorityFee)=="function"){const vt=d||await getAction(c,getBlock,"getBlock")({});return et.fees.defaultPriorityFee({block:vt,client:c,request:nt})}if(typeof((bt=et==null?void 0:et.fees)==null?void 0:bt.defaultPriorityFee)<"u")return(mt=et==null?void 0:et.fees)==null?void 0:mt.defaultPriorityFee;try{const vt=await c.request({method:"eth_maxPriorityFeePerGas"});return hexToBigInt(vt)}catch{const[vt,$t]=await Promise.all([d?Promise.resolve(d):getAction(c,getBlock,"getBlock")({}),getAction(c,getGasPrice,"getGasPrice")({})]);if(typeof vt.baseFeePerGas!="bigint")throw new Eip1559FeesNotSupportedError;const At=$t-vt.baseFeePerGas;return At<0n?0n:At}}async function estimateFeesPerGas(c,a){return internal_estimateFeesPerGas(c,a)}async function internal_estimateFeesPerGas(c,a){var Tt,Rt;const{block:d,chain:et=c.chain,request:nt,type:tt="eip1559"}=a||{},bt=await(async()=>{var kt,It;return typeof((kt=et==null?void 0:et.fees)==null?void 0:kt.baseFeeMultiplier)=="function"?et.fees.baseFeeMultiplier({block:d,client:c,request:nt}):((It=et==null?void 0:et.fees)==null?void 0:It.baseFeeMultiplier)??1.2})();if(bt<1)throw new BaseFeeScalarError;const vt=10**(((Tt=bt.toString().split(".")[1])==null?void 0:Tt.length)??0),$t=kt=>kt*BigInt(Math.ceil(bt*vt))/BigInt(vt),At=d||await getAction(c,getBlock,"getBlock")({});if(typeof((Rt=et==null?void 0:et.fees)==null?void 0:Rt.estimateFeesPerGas)=="function"){const kt=await et.fees.estimateFeesPerGas({block:d,client:c,multiply:$t,request:nt,type:tt});if(kt!==null)return kt}if(tt==="eip1559"){if(typeof At.baseFeePerGas!="bigint")throw new Eip1559FeesNotSupportedError;const kt=typeof(nt==null?void 0:nt.maxPriorityFeePerGas)=="bigint"?nt.maxPriorityFeePerGas:await internal_estimateMaxPriorityFeePerGas(c,{block:At,chain:et,request:nt}),It=$t(At.baseFeePerGas);return{maxFeePerGas:(nt==null?void 0:nt.maxFeePerGas)??It+kt,maxPriorityFeePerGas:kt}}return{gasPrice:(nt==null?void 0:nt.gasPrice)??$t(await getAction(c,getGasPrice,"getGasPrice")({}))}}async function getTransactionCount(c,{address:a,blockTag:d="latest",blockNumber:et}){const nt=await c.request({method:"eth_getTransactionCount",params:[a,et?numberToHex(et):d]});return hexToNumber(nt)}function blobsToCommitments(c){const{kzg:a}=c,d=c.to??(typeof c.blobs[0]=="string"?"hex":"bytes"),et=typeof c.blobs[0]=="string"?c.blobs.map(tt=>hexToBytes(tt)):c.blobs,nt=[];for(const tt of et)nt.push(Uint8Array.from(a.blobToKzgCommitment(tt)));return d==="bytes"?nt:nt.map(tt=>bytesToHex(tt))}function blobsToProofs(c){const{kzg:a}=c,d=c.to??(typeof c.blobs[0]=="string"?"hex":"bytes"),et=typeof c.blobs[0]=="string"?c.blobs.map(bt=>hexToBytes(bt)):c.blobs,nt=typeof c.commitments[0]=="string"?c.commitments.map(bt=>hexToBytes(bt)):c.commitments,tt=[];for(let bt=0;btbytesToHex(bt))}function setBigUint64(c,a,d,et){if(typeof c.setBigUint64=="function")return c.setBigUint64(a,d,et);const nt=BigInt(32),tt=BigInt(4294967295),bt=Number(d>>nt&tt),mt=Number(d&tt),vt=et?4:0,$t=et?0:4;c.setUint32(a+vt,bt,et),c.setUint32(a+$t,mt,et)}class SHA2 extends Hash{constructor(a,d,et,nt){super(),this.blockLen=a,this.outputLen=d,this.padOffset=et,this.isLE=nt,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(a),this.view=createView(this.buffer)}update(a){exists(this);const{view:d,buffer:et,blockLen:nt}=this;a=toBytes(a);const tt=a.length;for(let bt=0;btnt-bt&&(this.process(et,0),bt=0);for(let Mt=bt;MtAt.length)throw new Error("_sha2: outputLen bigger than state");for(let Mt=0;Mt<$t;Mt++)mt.setUint32(4*Mt,At[Mt],tt)}digest(){const{buffer:a,outputLen:d}=this;this.digestInto(a);const et=a.slice(0,d);return this.destroy(),et}_cloneInto(a){a||(a=new this.constructor),a.set(...this.get());const{blockLen:d,buffer:et,length:nt,finished:tt,destroyed:bt,pos:mt}=this;return a.length=nt,a.pos=mt,a.finished=tt,a.destroyed=bt,nt%d&&a.buffer.set(et),a}}const Chi=(c,a,d)=>c&a^~c&d,Maj=(c,a,d)=>c&a^c&d^a&d,SHA256_K=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W=new Uint32Array(64);class SHA256 extends SHA2{constructor(){super(64,32,8,!1),this.A=IV[0]|0,this.B=IV[1]|0,this.C=IV[2]|0,this.D=IV[3]|0,this.E=IV[4]|0,this.F=IV[5]|0,this.G=IV[6]|0,this.H=IV[7]|0}get(){const{A:a,B:d,C:et,D:nt,E:tt,F:bt,G:mt,H:vt}=this;return[a,d,et,nt,tt,bt,mt,vt]}set(a,d,et,nt,tt,bt,mt,vt){this.A=a|0,this.B=d|0,this.C=et|0,this.D=nt|0,this.E=tt|0,this.F=bt|0,this.G=mt|0,this.H=vt|0}process(a,d){for(let Mt=0;Mt<16;Mt++,d+=4)SHA256_W[Mt]=a.getUint32(d,!1);for(let Mt=16;Mt<64;Mt++){const Tt=SHA256_W[Mt-15],Rt=SHA256_W[Mt-2],kt=rotr(Tt,7)^rotr(Tt,18)^Tt>>>3,It=rotr(Rt,17)^rotr(Rt,19)^Rt>>>10;SHA256_W[Mt]=It+SHA256_W[Mt-7]+kt+SHA256_W[Mt-16]|0}let{A:et,B:nt,C:tt,D:bt,E:mt,F:vt,G:$t,H:At}=this;for(let Mt=0;Mt<64;Mt++){const Tt=rotr(mt,6)^rotr(mt,11)^rotr(mt,25),Rt=At+Tt+Chi(mt,vt,$t)+SHA256_K[Mt]+SHA256_W[Mt]|0,It=(rotr(et,2)^rotr(et,13)^rotr(et,22))+Maj(et,nt,tt)|0;At=$t,$t=vt,vt=mt,mt=bt+Rt|0,bt=tt,tt=nt,nt=et,et=Rt+It|0}et=et+this.A|0,nt=nt+this.B|0,tt=tt+this.C|0,bt=bt+this.D|0,mt=mt+this.E|0,vt=vt+this.F|0,$t=$t+this.G|0,At=At+this.H|0,this.set(et,nt,tt,bt,mt,vt,$t,At)}roundClean(){SHA256_W.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const sha256$1=wrapConstructor(()=>new SHA256);function sha256(c,a){const d=a||"hex",et=sha256$1(isHex(c,{strict:!1})?toBytes$1(c):c);return d==="bytes"?et:toHex(et)}function commitmentToVersionedHash(c){const{commitment:a,version:d=1}=c,et=c.to??(typeof a=="string"?"hex":"bytes"),nt=sha256(a,"bytes");return nt.set([d],0),et==="bytes"?nt:bytesToHex(nt)}function commitmentsToVersionedHashes(c){const{commitments:a,version:d}=c,et=c.to??(typeof a[0]=="string"?"hex":"bytes"),nt=[];for(const tt of a)nt.push(commitmentToVersionedHash({commitment:tt,to:et,version:d}));return nt}const blobsPerTransaction=6,bytesPerFieldElement=32,fieldElementsPerBlob=4096,bytesPerBlob=bytesPerFieldElement*fieldElementsPerBlob,maxBytesPerTransaction=bytesPerBlob*blobsPerTransaction-1-1*fieldElementsPerBlob*blobsPerTransaction,versionedHashVersionKzg=1;class BlobSizeTooLargeError extends BaseError{constructor({maxSize:a,size:d}){super("Blob size is too large.",{metaMessages:[`Max: ${a} bytes`,`Given: ${d} bytes`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlobSizeTooLargeError"})}}class EmptyBlobError extends BaseError{constructor(){super("Blob data must not be empty."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EmptyBlobError"})}}class InvalidVersionedHashSizeError extends BaseError{constructor({hash:a,size:d}){super(`Versioned hash "${a}" size is invalid.`,{metaMessages:["Expected: 32",`Received: ${d}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidVersionedHashSizeError"})}}class InvalidVersionedHashVersionError extends BaseError{constructor({hash:a,version:d}){super(`Versioned hash "${a}" version is invalid.`,{metaMessages:[`Expected: ${versionedHashVersionKzg}`,`Received: ${d}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidVersionedHashVersionError"})}}function toBlobs(c){const a=c.to??(typeof c.data=="string"?"hex":"bytes"),d=typeof c.data=="string"?hexToBytes(c.data):c.data,et=size$1(d);if(!et)throw new EmptyBlobError;if(et>maxBytesPerTransaction)throw new BlobSizeTooLargeError({maxSize:maxBytesPerTransaction,size:et});const nt=[];let tt=!0,bt=0;for(;tt;){const mt=createCursor(new Uint8Array(bytesPerBlob));let vt=0;for(;vtmt.bytes):nt.map(mt=>bytesToHex(mt.bytes))}function toBlobSidecars(c){const{data:a,kzg:d,to:et}=c,nt=c.blobs??toBlobs({data:a,to:et}),tt=c.commitments??blobsToCommitments({blobs:nt,kzg:d,to:et}),bt=c.proofs??blobsToProofs({blobs:nt,commitments:tt,kzg:d,to:et}),mt=[];for(let vt=0;vt"u"&&Mt&&(Tt.nonce=await getAction(c,getTransactionCount,"getTransactionCount")({address:Mt.address,blockTag:"pending"})),($t.includes("fees")||$t.includes("type"))&&typeof At>"u")try{Tt.type=getTransactionType(Tt)}catch{const It=await kt();Tt.type=typeof(It==null?void 0:It.baseFeePerGas)=="bigint"?"eip1559":"legacy"}if($t.includes("fees"))if(Tt.type==="eip1559"||Tt.type==="eip4844"){if(typeof Tt.maxFeePerGas>"u"||typeof Tt.maxPriorityFeePerGas>"u"){const It=await kt(),{maxFeePerGas:Dt,maxPriorityFeePerGas:Nt}=await internal_estimateFeesPerGas(c,{block:It,chain:nt,request:Tt});if(typeof a.maxPriorityFeePerGas>"u"&&a.maxFeePerGas&&a.maxFeePerGas"u"&&(Tt.gas=await getAction(c,estimateGas,"estimateGas")({...Tt,account:Mt?{address:Mt.address,type:"json-rpc"}:void 0})),assertRequest(Tt),delete Tt.parameters,Tt}async function estimateGas(c,a){var nt,tt,bt;const d=a.account??c.account,et=d?parseAccount(d):void 0;try{const{accessList:mt,blobs:vt,blobVersionedHashes:$t,blockNumber:At,blockTag:Mt,data:Tt,gas:Rt,gasPrice:kt,maxFeePerBlobGas:It,maxFeePerGas:Dt,maxPriorityFeePerGas:Nt,nonce:Ot,to:Ut,value:Gt,...Wt}=await prepareTransactionRequest(c,{...a,parameters:(et==null?void 0:et.type)==="local"?void 0:["blobVersionedHashes"]}),a0=(At?numberToHex(At):void 0)||Mt;assertRequest(a);const n0=(bt=(tt=(nt=c.chain)==null?void 0:nt.formatters)==null?void 0:tt.transactionRequest)==null?void 0:bt.format,c0=(n0||formatTransactionRequest)({...extract(Wt,{format:n0}),from:et==null?void 0:et.address,accessList:mt,blobs:vt,blobVersionedHashes:$t,data:Tt,gas:Rt,gasPrice:kt,maxFeePerBlobGas:It,maxFeePerGas:Dt,maxPriorityFeePerGas:Nt,nonce:Ot,to:Ut,value:Gt}),Ct=await c.request({method:"eth_estimateGas",params:a0?[c0,a0]:[c0]});return BigInt(Ct)}catch(mt){throw getEstimateGasError(mt,{...a,account:et,chain:c.chain})}}async function estimateContractGas(c,a){const{abi:d,address:et,args:nt,functionName:tt,...bt}=a,mt=encodeFunctionData({abi:d,args:nt,functionName:tt});try{return await getAction(c,estimateGas,"estimateGas")({data:mt,to:et,...bt})}catch(vt){const $t=bt.account?parseAccount(bt.account):void 0;throw getContractError(vt,{abi:d,address:et,args:nt,docsPath:"/docs/contract/estimateContractGas",functionName:tt,sender:$t==null?void 0:$t.address})}}const docsPath$2="/docs/contract/decodeEventLog";function decodeEventLog(c){const{abi:a,data:d,strict:et,topics:nt}=c,tt=et??!0,[bt,...mt]=nt;if(!bt)throw new AbiEventSignatureEmptyTopicsError({docsPath:docsPath$2});const vt=a.find(It=>It.type==="event"&&bt===toEventSelector(formatAbiItem(It)));if(!(vt&&"name"in vt)||vt.type!=="event")throw new AbiEventSignatureNotFoundError(bt,{docsPath:docsPath$2});const{name:$t,inputs:At}=vt,Mt=At==null?void 0:At.some(It=>!("name"in It&&It.name));let Tt=Mt?[]:{};const Rt=At.filter(It=>"indexed"in It&&It.indexed);for(let It=0;It!("indexed"in It&&It.indexed));if(kt.length>0){if(d&&d!=="0x")try{const It=decodeAbiParameters(kt,d);if(It)if(Mt)Tt=[...Tt,...It];else for(let Dt=0;Dt0?Tt:void 0}}function decodeTopic({param:c,value:a}){return c.type==="string"||c.type==="bytes"||c.type==="tuple"||c.type.match(/^(.*)\[(\d+)?\]$/)?a:(decodeAbiParameters([c],a)||[])[0]}function parseEventLogs({abi:c,eventName:a,logs:d,strict:et=!0}){return d.map(nt=>{var tt;try{const bt=decodeEventLog({...nt,abi:c,strict:et});return a&&!a.includes(bt.eventName)?null:{...bt,...nt}}catch(bt){let mt,vt;if(bt instanceof AbiEventSignatureNotFoundError)return null;if(bt instanceof DecodeLogDataMismatch||bt instanceof DecodeLogTopicsMismatch){if(et)return null;mt=bt.abiItem.name,vt=(tt=bt.abiItem.inputs)==null?void 0:tt.some($t=>!("name"in $t&&$t.name))}return{...nt,args:vt?[]:{},eventName:mt}}}).filter(Boolean)}function formatLog(c,{args:a,eventName:d}={}){return{...c,blockHash:c.blockHash?c.blockHash:null,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,logIndex:c.logIndex?Number(c.logIndex):null,transactionHash:c.transactionHash?c.transactionHash:null,transactionIndex:c.transactionIndex?Number(c.transactionIndex):null,...d?{args:a,eventName:d}:{}}}async function getLogs(c,{address:a,blockHash:d,fromBlock:et,toBlock:nt,event:tt,events:bt,args:mt,strict:vt}={}){const $t=vt??!1,At=bt??(tt?[tt]:void 0);let Mt=[];At&&(Mt=[At.flatMap(kt=>encodeEventTopics({abi:[kt],eventName:kt.name,args:mt}))],tt&&(Mt=Mt[0]));let Tt;d?Tt=await c.request({method:"eth_getLogs",params:[{address:a,topics:Mt,blockHash:d}]}):Tt=await c.request({method:"eth_getLogs",params:[{address:a,topics:Mt,fromBlock:typeof et=="bigint"?numberToHex(et):et,toBlock:typeof nt=="bigint"?numberToHex(nt):nt}]});const Rt=Tt.map(kt=>formatLog(kt));return At?parseEventLogs({abi:At,logs:Rt,strict:$t}):Rt}async function getContractEvents(c,a){const{abi:d,address:et,args:nt,blockHash:tt,eventName:bt,fromBlock:mt,toBlock:vt,strict:$t}=a,At=bt?getAbiItem({abi:d,name:bt}):void 0,Mt=At?void 0:d.filter(Tt=>Tt.type==="event");return getAction(c,getLogs,"getLogs")({address:et,args:nt,blockHash:tt,event:At,events:Mt,fromBlock:mt,toBlock:vt,strict:$t})}const docsPath$1="/docs/contract/decodeFunctionResult";function decodeFunctionResult(c){const{abi:a,args:d,functionName:et,data:nt}=c;let tt=a[0];if(et){const mt=getAbiItem({abi:a,args:d,name:et});if(!mt)throw new AbiFunctionNotFoundError(et,{docsPath:docsPath$1});tt=mt}if(tt.type!=="function")throw new AbiFunctionNotFoundError(void 0,{docsPath:docsPath$1});if(!tt.outputs)throw new AbiFunctionOutputsNotFoundError(tt.name,{docsPath:docsPath$1});const bt=decodeAbiParameters(tt.outputs,nt);if(bt&&bt.length>1)return bt;if(bt&&bt.length===1)return bt[0]}const multicall3Abi=[{inputs:[{components:[{name:"target",type:"address"},{name:"allowFailure",type:"bool"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate3",outputs:[{components:[{name:"success",type:"bool"},{name:"returnData",type:"bytes"}],name:"returnData",type:"tuple[]"}],stateMutability:"view",type:"function"}],universalResolverErrors=[{inputs:[],name:"ResolverNotFound",type:"error"},{inputs:[],name:"ResolverWildcardNotSupported",type:"error"},{inputs:[],name:"ResolverNotContract",type:"error"},{inputs:[{name:"returnData",type:"bytes"}],name:"ResolverError",type:"error"},{inputs:[{components:[{name:"status",type:"uint16"},{name:"message",type:"string"}],name:"errors",type:"tuple[]"}],name:"HttpError",type:"error"}],universalResolverResolveAbi=[...universalResolverErrors,{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]},{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"},{name:"gateways",type:"string[]"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],universalResolverReverseAbi=[...universalResolverErrors,{name:"reverse",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolvedAddress"},{type:"address",name:"reverseResolver"},{type:"address",name:"resolver"}]},{name:"reverse",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"},{type:"string[]",name:"gateways"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolvedAddress"},{type:"address",name:"reverseResolver"},{type:"address",name:"resolver"}]}],textResolverAbi=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],addressResolverAbi=[{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"}],outputs:[{name:"",type:"address"}]},{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"coinType",type:"uint256"}],outputs:[{name:"",type:"bytes"}]}],universalSignatureValidatorAbi=[{inputs:[{internalType:"address",name:"_signer",type:"address"},{internalType:"bytes32",name:"_hash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"}],aggregate3Signature="0x82ad56cb";class ChainDoesNotSupportContract extends BaseError{constructor({blockNumber:a,chain:d,contract:et}){super(`Chain "${d.name}" does not support contract "${et.name}".`,{metaMessages:["This could be due to any of the following:",...a&&et.blockCreated&&et.blockCreated>a?[`- The contract "${et.name}" was not deployed until block ${et.blockCreated} (current block ${a}).`]:[`- The chain does not have the contract "${et.name}" configured.`]]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDoesNotSupportContract"})}}class ClientChainNotConfiguredError extends BaseError{constructor(){super("No chain was provided to the Client."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ClientChainNotConfiguredError"})}}class InvalidChainIdError extends BaseError{constructor({chainId:a}){super(typeof a=="number"?`Chain ID "${a}" is invalid.`:"Chain ID is invalid."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidChainIdError"})}}function getChainContractAddress({blockNumber:c,chain:a,contract:d}){var nt;const et=(nt=a==null?void 0:a.contracts)==null?void 0:nt[d];if(!et)throw new ChainDoesNotSupportContract({chain:a,contract:{name:d}});if(c&&et.blockCreated&&et.blockCreated>c)throw new ChainDoesNotSupportContract({blockNumber:c,chain:a,contract:{name:d,blockCreated:et.blockCreated}});return et.address}function getCallError(c,{docsPath:a,...d}){const et=(()=>{const nt=getNodeError(c,d);return nt instanceof UnknownNodeError?c:nt})();return new CallExecutionError(et,{docsPath:a,...d})}const schedulerCache=new Map;function createBatchScheduler({fn:c,id:a,shouldSplitBatch:d,wait:et=0,sort:nt}){const tt=async()=>{const At=vt();bt();const Mt=At.map(({args:Tt})=>Tt);Mt.length!==0&&c(Mt).then(Tt=>{var Rt;nt&&Array.isArray(Tt)&&Tt.sort(nt);for(let kt=0;kt{var Rt;for(let kt=0;ktschedulerCache.delete(a),mt=()=>vt().map(({args:At})=>At),vt=()=>schedulerCache.get(a)||[],$t=At=>schedulerCache.set(a,[...vt(),At]);return{flush:bt,async schedule(At){const Mt={},Tt=new Promise((It,Dt)=>{Mt.resolve=It,Mt.reject=Dt});return(d==null?void 0:d([...mt(),At]))&&tt(),vt().length>0?($t({args:At,pendingPromise:Mt}),Tt):($t({args:At,pendingPromise:Mt}),setTimeout(tt,et),Tt)}}}async function call(c,a){var Gt,Wt,Xt,a0;const{account:d=c.account,batch:et=!!((Gt=c.batch)!=null&&Gt.multicall),blockNumber:nt,blockTag:tt="latest",accessList:bt,blobs:mt,data:vt,gas:$t,gasPrice:At,maxFeePerBlobGas:Mt,maxFeePerGas:Tt,maxPriorityFeePerGas:Rt,nonce:kt,to:It,value:Dt,stateOverride:Nt,...Ot}=a,Ut=d?parseAccount(d):void 0;try{assertRequest(a);const t0=(nt?numberToHex(nt):void 0)||tt,c0=parseStateOverride(Nt),Ct=(a0=(Xt=(Wt=c.chain)==null?void 0:Wt.formatters)==null?void 0:Xt.transactionRequest)==null?void 0:a0.format,yt=(Ct||formatTransactionRequest)({...extract(Ot,{format:Ct}),from:Ut==null?void 0:Ut.address,accessList:bt,blobs:mt,data:vt,gas:$t,gasPrice:At,maxFeePerBlobGas:Mt,maxFeePerGas:Tt,maxPriorityFeePerGas:Rt,nonce:kt,to:It,value:Dt});if(et&&shouldPerformMulticall({request:yt})&&!c0)try{return await scheduleMulticall(c,{...yt,blockNumber:nt,blockTag:tt})}catch(xt){if(!(xt instanceof ClientChainNotConfiguredError)&&!(xt instanceof ChainDoesNotSupportContract))throw xt}const gt=await c.request({method:"eth_call",params:c0?[yt,t0,c0]:[yt,t0]});return gt==="0x"?{data:void 0}:{data:gt}}catch(n0){const t0=getRevertErrorData(n0),{offchainLookup:c0,offchainLookupSignature:Ct}=await __vitePreload(()=>import("./ccip-9e679818.js"),[]);if(c.ccipRead!==!1&&(t0==null?void 0:t0.slice(0,10))===Ct&&It)return{data:await c0(c,{data:t0,to:It})};throw getCallError(n0,{...a,account:Ut,chain:c.chain})}}function shouldPerformMulticall({request:c}){const{data:a,to:d,...et}=c;return!(!a||a.startsWith(aggregate3Signature)||!d||Object.values(et).filter(nt=>typeof nt<"u").length>0)}async function scheduleMulticall(c,a){var It;const{batchSize:d=1024,wait:et=0}=typeof((It=c.batch)==null?void 0:It.multicall)=="object"?c.batch.multicall:{},{blockNumber:nt,blockTag:tt="latest",data:bt,multicallAddress:mt,to:vt}=a;let $t=mt;if(!$t){if(!c.chain)throw new ClientChainNotConfiguredError;$t=getChainContractAddress({blockNumber:nt,chain:c.chain,contract:"multicall3"})}const Mt=(nt?numberToHex(nt):void 0)||tt,{schedule:Tt}=createBatchScheduler({id:`${c.uid}.${Mt}`,wait:et,shouldSplitBatch(Dt){return Dt.reduce((Ot,{data:Ut})=>Ot+(Ut.length-2),0)>d*2},fn:async Dt=>{const Nt=Dt.map(Gt=>({allowFailure:!0,callData:Gt.data,target:Gt.to})),Ot=encodeFunctionData({abi:multicall3Abi,args:[Nt],functionName:"aggregate3"}),Ut=await c.request({method:"eth_call",params:[{data:Ot,to:$t},Mt]});return decodeFunctionResult({abi:multicall3Abi,args:[Nt],functionName:"aggregate3",data:Ut||"0x"})}}),[{returnData:Rt,success:kt}]=await Tt({data:bt,to:vt});if(!kt)throw new RawContractError({data:Rt});return Rt==="0x"?{data:void 0}:{data:Rt}}function getRevertErrorData(c){var d;if(!(c instanceof BaseError))return;const a=c.walk();return typeof(a==null?void 0:a.data)=="object"?(d=a.data)==null?void 0:d.data:a.data}function parseStateMapping(c){if(!(!c||c.length===0))return c.reduce((a,{slot:d,value:et})=>{if(d.length!==66)throw new InvalidBytesLengthError({size:d.length,targetSize:66,type:"hex"});if(et.length!==66)throw new InvalidBytesLengthError({size:et.length,targetSize:66,type:"hex"});return a[d]=et,a},{})}function parseAccountStateOverride(c){const{balance:a,nonce:d,state:et,stateDiff:nt,code:tt}=c,bt={};if(tt!==void 0&&(bt.code=tt),a!==void 0&&(bt.balance=numberToHex(a)),d!==void 0&&(bt.nonce=numberToHex(d)),et!==void 0&&(bt.state=parseStateMapping(et)),nt!==void 0){if(bt.state)throw new StateAssignmentConflictError;bt.stateDiff=parseStateMapping(nt)}return bt}function parseStateOverride(c){if(!c)return;const a={};for(const{address:d,...et}of c){if(!isAddress(d,{strict:!1}))throw new InvalidAddressError({address:d});if(a[d])throw new AccountStateConflictError({address:d});a[d]=parseAccountStateOverride(et)}return a}async function readContract(c,a){const{abi:d,address:et,args:nt,functionName:tt,...bt}=a,mt=encodeFunctionData({abi:d,args:nt,functionName:tt});try{const{data:vt}=await getAction(c,call,"call")({...bt,data:mt,to:et});return decodeFunctionResult({abi:d,args:nt,functionName:tt,data:vt||"0x"})}catch(vt){throw getContractError(vt,{abi:d,address:et,args:nt,docsPath:"/docs/contract/readContract",functionName:tt})}}async function simulateContract(c,a){const{abi:d,address:et,args:nt,dataSuffix:tt,functionName:bt,...mt}=a,vt=mt.account?parseAccount(mt.account):c.account,$t=encodeFunctionData({abi:d,args:nt,functionName:bt});try{const{data:At}=await getAction(c,call,"call")({batch:!1,data:`${$t}${tt?tt.replace("0x",""):""}`,to:et,...mt,account:vt}),Mt=decodeFunctionResult({abi:d,args:nt,functionName:bt,data:At||"0x"}),Tt=d.filter(Rt=>"name"in Rt&&Rt.name===a.functionName);return{result:Mt,request:{abi:Tt,address:et,args:nt,dataSuffix:tt,functionName:bt,...mt,account:vt}}}catch(At){throw getContractError(At,{abi:d,address:et,args:nt,docsPath:"/docs/contract/simulateContract",functionName:bt,sender:vt==null?void 0:vt.address})}}const listenersCache$1=new Map,cleanupCache$1=new Map;let callbackCount$1=0;function observe$1(c,a,d){const et=++callbackCount$1,nt=()=>listenersCache$1.get(c)||[],tt=()=>{const At=nt();listenersCache$1.set(c,At.filter(Mt=>Mt.id!==et))},bt=()=>{const At=cleanupCache$1.get(c);nt().length===1&&At&&At(),tt()},mt=nt();if(listenersCache$1.set(c,[...mt,{id:et,fns:a}]),mt&&mt.length>0)return bt;const vt={};for(const At in a)vt[At]=(...Mt)=>{var Rt,kt;const Tt=nt();if(Tt.length!==0)for(const It of Tt)(kt=(Rt=It.fns)[At])==null||kt.call(Rt,...Mt)};const $t=d(vt);return typeof $t=="function"&&cleanupCache$1.set(c,$t),bt}async function wait(c){return new Promise(a=>setTimeout(a,c))}function poll(c,{emitOnBegin:a,initialWaitTime:d,interval:et}){let nt=!0;const tt=()=>nt=!1;return(async()=>{let mt;a&&(mt=await c({unpoll:tt}));const vt=await(d==null?void 0:d(mt))??et;await wait(vt);const $t=async()=>{nt&&(await c({unpoll:tt}),await wait(et),$t())};$t()})(),tt}const promiseCache=new Map,responseCache=new Map;function getCache(c){const a=(nt,tt)=>({clear:()=>tt.delete(nt),get:()=>tt.get(nt),set:bt=>tt.set(nt,bt)}),d=a(c,promiseCache),et=a(c,responseCache);return{clear:()=>{d.clear(),et.clear()},promise:d,response:et}}async function withCache(c,{cacheKey:a,cacheTime:d=1/0}){const et=getCache(a),nt=et.response.get();if(nt&&d>0&&new Date().getTime()-nt.created.getTime()`blockNumber.${c}`;async function getBlockNumber(c,{cacheTime:a=c.cacheTime}={}){const d=await withCache(()=>c.request({method:"eth_blockNumber"}),{cacheKey:cacheKey(c.uid),cacheTime:a});return BigInt(d)}async function getFilterChanges(c,{filter:a}){const d="strict"in a&&a.strict,et=await a.request({method:"eth_getFilterChanges",params:[a.id]});if(typeof et[0]=="string")return et;const nt=et.map(tt=>formatLog(tt));return!("abi"in a)||!a.abi?nt:parseEventLogs({abi:a.abi,logs:nt,strict:d})}async function uninstallFilter(c,{filter:a}){return a.request({method:"eth_uninstallFilter",params:[a.id]})}function watchContractEvent(c,a){const{abi:d,address:et,args:nt,batch:tt=!0,eventName:bt,fromBlock:mt,onError:vt,onLogs:$t,poll:At,pollingInterval:Mt=c.pollingInterval,strict:Tt}=a;return(()=>typeof At<"u"?At:typeof mt=="bigint"?!0:!(c.transport.type==="webSocket"||c.transport.type==="fallback"&&c.transport.transports[0].config.type==="webSocket"))()?(()=>{const Dt=Tt??!1,Nt=stringify(["watchContractEvent",et,nt,tt,c.uid,bt,Mt,Dt,mt]);return observe$1(Nt,{onLogs:$t,onError:vt},Ot=>{let Ut;mt!==void 0&&(Ut=mt-1n);let Gt,Wt=!1;const Xt=poll(async()=>{var a0;if(!Wt){try{Gt=await getAction(c,createContractEventFilter,"createContractEventFilter")({abi:d,address:et,args:nt,eventName:bt,strict:Dt,fromBlock:mt})}catch{}Wt=!0;return}try{let n0;if(Gt)n0=await getAction(c,getFilterChanges,"getFilterChanges")({filter:Gt});else{const t0=await getAction(c,getBlockNumber,"getBlockNumber")({});Ut&&Ut!==t0?n0=await getAction(c,getContractEvents,"getContractEvents")({abi:d,address:et,args:nt,eventName:bt,fromBlock:Ut+1n,toBlock:t0,strict:Dt}):n0=[],Ut=t0}if(n0.length===0)return;if(tt)Ot.onLogs(n0);else for(const t0 of n0)Ot.onLogs([t0])}catch(n0){Gt&&n0 instanceof InvalidInputRpcError&&(Wt=!1),(a0=Ot.onError)==null||a0.call(Ot,n0)}},{emitOnBegin:!0,interval:Mt});return async()=>{Gt&&await getAction(c,uninstallFilter,"uninstallFilter")({filter:Gt}),Xt()}})})():(()=>{const Dt=Tt??!1,Nt=stringify(["watchContractEvent",et,nt,tt,c.uid,bt,Mt,Dt]);let Ot=!0,Ut=()=>Ot=!1;return observe$1(Nt,{onLogs:$t,onError:vt},Gt=>((async()=>{try{const Wt=(()=>{if(c.transport.type==="fallback"){const n0=c.transport.transports.find(t0=>t0.config.type==="webSocket");return n0?n0.value:c.transport}return c.transport})(),Xt=bt?encodeEventTopics({abi:d,eventName:bt,args:nt}):[],{unsubscribe:a0}=await Wt.subscribe({params:["logs",{address:et,topics:Xt}],onData(n0){var c0;if(!Ot)return;const t0=n0.result;try{const{eventName:Ct,args:dt}=decodeEventLog({abi:d,data:t0.data,topics:t0.topics,strict:Tt}),yt=formatLog(t0,{args:dt,eventName:Ct});Gt.onLogs([yt])}catch(Ct){let dt,yt;if(Ct instanceof DecodeLogDataMismatch||Ct instanceof DecodeLogTopicsMismatch){if(Tt)return;dt=Ct.abiItem.name,yt=(c0=Ct.abiItem.inputs)==null?void 0:c0.some(xt=>!("name"in xt&&xt.name))}const gt=formatLog(t0,{args:yt?[]:{},eventName:dt});Gt.onLogs([gt])}},onError(n0){var t0;(t0=Gt.onError)==null||t0.call(Gt,n0)}});Ut=a0,Ot||Ut()}catch(Wt){vt==null||vt(Wt)}})(),()=>Ut()))})()}async function sendRawTransaction(c,{serializedTransaction:a}){return c.request({method:"eth_sendRawTransaction",params:[a]},{retryCount:0})}const size=256;let index=size,buffer;function uid(c=11){if(!buffer||index+c>size*2){buffer="",index=0;for(let a=0;a{const Ot=Nt(Dt);for(const Gt in kt)delete Ot[Gt];const Ut={...Dt,...Ot};return Object.assign(Ut,{extend:It(Ut)})}}return Object.assign(kt,{extend:It(kt)})}function withRetry(c,{delay:a=100,retryCount:d=2,shouldRetry:et=()=>!0}={}){return new Promise((nt,tt)=>{const bt=async({count:mt=0}={})=>{const vt=async({error:$t})=>{const At=typeof a=="function"?a({count:mt,error:$t}):a;At&&await wait(At),bt({count:mt+1})};try{const $t=await c();nt($t)}catch($t){if(mt{const{retryDelay:nt=150,retryCount:tt=3}={...a,...et};return withRetry(async()=>{try{return await c(d)}catch(bt){const mt=bt;switch(mt.code){case ParseRpcError.code:throw new ParseRpcError(mt);case InvalidRequestRpcError.code:throw new InvalidRequestRpcError(mt);case MethodNotFoundRpcError.code:throw new MethodNotFoundRpcError(mt);case InvalidParamsRpcError.code:throw new InvalidParamsRpcError(mt);case InternalRpcError.code:throw new InternalRpcError(mt);case InvalidInputRpcError.code:throw new InvalidInputRpcError(mt);case ResourceNotFoundRpcError.code:throw new ResourceNotFoundRpcError(mt);case ResourceUnavailableRpcError.code:throw new ResourceUnavailableRpcError(mt);case TransactionRejectedRpcError.code:throw new TransactionRejectedRpcError(mt);case MethodNotSupportedRpcError.code:throw new MethodNotSupportedRpcError(mt);case LimitExceededRpcError.code:throw new LimitExceededRpcError(mt);case JsonRpcVersionUnsupportedError.code:throw new JsonRpcVersionUnsupportedError(mt);case UserRejectedRequestError.code:throw new UserRejectedRequestError(mt);case UnauthorizedProviderError.code:throw new UnauthorizedProviderError(mt);case UnsupportedProviderMethodError.code:throw new UnsupportedProviderMethodError(mt);case ProviderDisconnectedError.code:throw new ProviderDisconnectedError(mt);case ChainDisconnectedError.code:throw new ChainDisconnectedError(mt);case SwitchChainError.code:throw new SwitchChainError(mt);case 5e3:throw new UserRejectedRequestError(mt);default:throw bt instanceof BaseError?bt:new UnknownRpcError(mt)}}},{delay:({count:bt,error:mt})=>{var vt;if(mt&&mt instanceof HttpRequestError){const $t=(vt=mt==null?void 0:mt.headers)==null?void 0:vt.get("Retry-After");if($t!=null&&$t.match(/\d/))return parseInt($t)*1e3}return~~(1<shouldRetry(bt)})}}function shouldRetry(c){return"code"in c&&typeof c.code=="number"?c.code===-1||c.code===LimitExceededRpcError.code||c.code===InternalRpcError.code:c instanceof HttpRequestError&&c.status?c.status===403||c.status===408||c.status===413||c.status===429||c.status===500||c.status===502||c.status===503||c.status===504:!0}function createTransport({key:c,name:a,request:d,retryCount:et=3,retryDelay:nt=150,timeout:tt,type:bt},mt){return{config:{key:c,name:a,request:d,retryCount:et,retryDelay:nt,timeout:tt,type:bt},request:buildRequest(d,{retryCount:et,retryDelay:nt}),value:mt}}class UrlRequiredError extends BaseError{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro"})}}function withTimeout(c,{errorInstance:a=new Error("timed out"),timeout:d,signal:et}){return new Promise((nt,tt)=>{(async()=>{let bt;try{const mt=new AbortController;d>0&&(bt=setTimeout(()=>{et?mt.abort():tt(a)},d)),nt(await c({signal:(mt==null?void 0:mt.signal)||null}))}catch(mt){mt.name==="AbortError"&&tt(a),tt(mt)}finally{clearTimeout(bt)}})()})}function createIdStore(){return{current:0,take(){return this.current++},reset(){this.current=0}}}const idCache=createIdStore();function getHttpRpcClient(c,a={}){return{async request(d){var Mt;const{body:et,fetchOptions:nt={},onRequest:tt=a.onRequest,onResponse:bt=a.onResponse,timeout:mt=a.timeout??1e4}=d,{headers:vt,method:$t,signal:At}={...a.fetchOptions,...nt};try{const Tt=await withTimeout(async({signal:kt})=>{const It={...nt,body:Array.isArray(et)?stringify(et.map(Ot=>({jsonrpc:"2.0",id:Ot.id??idCache.take(),...Ot}))):stringify({jsonrpc:"2.0",id:et.id??idCache.take(),...et}),headers:{...vt,"Content-Type":"application/json"},method:$t||"POST",signal:At||(mt>0?kt:null)},Dt=new Request(c,It);return tt&&await tt(Dt),await fetch(c,It)},{errorInstance:new TimeoutError({body:et,url:c}),timeout:mt,signal:!0});bt&&await bt(Tt);let Rt;if((Mt=Tt.headers.get("Content-Type"))!=null&&Mt.startsWith("application/json")?Rt=await Tt.json():Rt=await Tt.text(),!Tt.ok)throw new HttpRequestError({body:et,details:stringify(Rt.error)||Tt.statusText,headers:Tt.headers,status:Tt.status,url:c});return Rt}catch(Tt){throw Tt instanceof HttpRequestError||Tt instanceof TimeoutError?Tt:new HttpRequestError({body:et,details:Tt.message,url:c})}}}}function http(c,a={}){const{batch:d,fetchOptions:et,key:nt="http",name:tt="HTTP JSON-RPC",onFetchRequest:bt,onFetchResponse:mt,retryDelay:vt}=a;return({chain:$t,retryCount:At,timeout:Mt})=>{const{batchSize:Tt=1e3,wait:Rt=0}=typeof d=="object"?d:{},kt=a.retryCount??At,It=Mt??a.timeout??1e4,Dt=c||($t==null?void 0:$t.rpcUrls.default.http[0]);if(!Dt)throw new UrlRequiredError;const Nt=getHttpRpcClient(Dt,{fetchOptions:et,onRequest:bt,onResponse:mt,timeout:It});return createTransport({key:nt,name:tt,async request({method:Ot,params:Ut}){const Gt={method:Ot,params:Ut},{schedule:Wt}=createBatchScheduler({id:`${c}`,wait:Rt,shouldSplitBatch(t0){return t0.length>Tt},fn:t0=>Nt.request({body:t0}),sort:(t0,c0)=>t0.id-c0.id}),Xt=async t0=>d?Wt(t0):[await Nt.request({body:t0})],[{error:a0,result:n0}]=await Xt(Gt);if(a0)throw new RpcRequestError({body:Gt,error:a0,url:Dt});return n0},retryCount:kt,retryDelay:vt,timeout:It,type:"http"},{fetchOptions:et,url:Dt})}}function isNullUniversalResolverError(c,a){var et,nt,tt,bt,mt,vt;if(!(c instanceof BaseError))return!1;const d=c.walk($t=>$t instanceof ContractFunctionRevertedError);return d instanceof ContractFunctionRevertedError?!!(((et=d.data)==null?void 0:et.errorName)==="ResolverNotFound"||((nt=d.data)==null?void 0:nt.errorName)==="ResolverWildcardNotSupported"||((tt=d.data)==null?void 0:tt.errorName)==="ResolverNotContract"||((bt=d.data)==null?void 0:bt.errorName)==="ResolverError"||((mt=d.data)==null?void 0:mt.errorName)==="HttpError"||(vt=d.reason)!=null&&vt.includes("Wildcard on non-extended resolvers is not supported")||a==="reverse"&&d.reason===panicReasons[50]):!1}function encodedLabelToLabelhash(c){if(c.length!==66||c.indexOf("[")!==0||c.indexOf("]")!==65)return null;const a=`0x${c.slice(1,65)}`;return isHex(a)?a:null}function namehash(c){let a=new Uint8Array(32).fill(0);if(!c)return bytesToHex(a);const d=c.split(".");for(let et=d.length-1;et>=0;et-=1){const nt=encodedLabelToLabelhash(d[et]),tt=nt?toBytes$1(nt):keccak256(stringToBytes(d[et]),"bytes");a=keccak256(concat([a,tt]),"bytes")}return bytesToHex(a)}function encodeLabelhash(c){return`[${c.slice(2)}]`}function labelhash(c){const a=new Uint8Array(32).fill(0);return c?encodedLabelToLabelhash(c)||keccak256(stringToBytes(c)):bytesToHex(a)}function packetToBytes(c){const a=c.replace(/^\.|\.$/gm,"");if(a.length===0)return new Uint8Array(1);const d=new Uint8Array(stringToBytes(a).byteLength+2);let et=0;const nt=a.split(".");for(let tt=0;tt255&&(bt=stringToBytes(encodeLabelhash(labelhash(nt[tt])))),d[et]=bt.length,d.set(bt,et+1),et+=bt.length+1}return d.byteLength!==et+1?d.slice(0,et+1):d}async function getEnsAddress(c,{blockNumber:a,blockTag:d,coinType:et,name:nt,gatewayUrls:tt,strict:bt,universalResolverAddress:mt}){let vt=mt;if(!vt){if(!c.chain)throw new Error("client chain not configured. universalResolverAddress is required.");vt=getChainContractAddress({blockNumber:a,chain:c.chain,contract:"ensUniversalResolver"})}try{const $t=encodeFunctionData({abi:addressResolverAbi,functionName:"addr",...et!=null?{args:[namehash(nt),BigInt(et)]}:{args:[namehash(nt)]}}),At={address:vt,abi:universalResolverResolveAbi,functionName:"resolve",args:[toHex(packetToBytes(nt)),$t],blockNumber:a,blockTag:d},Mt=getAction(c,readContract,"readContract"),Tt=tt?await Mt({...At,args:[...At.args,tt]}):await Mt(At);if(Tt[0]==="0x")return null;const Rt=decodeFunctionResult({abi:addressResolverAbi,args:et!=null?[namehash(nt),BigInt(et)]:void 0,functionName:"addr",data:Tt[0]});return Rt==="0x"||trim(Rt)==="0x00"?null:Rt}catch($t){if(bt)throw $t;if(isNullUniversalResolverError($t,"resolve"))return null;throw $t}}class EnsAvatarInvalidMetadataError extends BaseError{constructor({data:a}){super("Unable to extract image from metadata. The metadata may be malformed or invalid.",{metaMessages:["- Metadata must be a JSON object with at least an `image`, `image_url` or `image_data` property.","",`Provided data: ${JSON.stringify(a)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidMetadataError"})}}class EnsAvatarInvalidNftUriError extends BaseError{constructor({reason:a}){super(`ENS NFT avatar URI is invalid. ${a}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidNftUriError"})}}class EnsAvatarUriResolutionError extends BaseError{constructor({uri:a}){super(`Unable to resolve ENS avatar URI "${a}". The URI may be malformed, invalid, or does not respond with a valid image.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUriResolutionError"})}}class EnsAvatarUnsupportedNamespaceError extends BaseError{constructor({namespace:a}){super(`ENS NFT avatar namespace "${a}" is not supported. Must be "erc721" or "erc1155".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUnsupportedNamespaceError"})}}const networkRegex=/(?https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?\/)?(?ipfs\/|ipns\/)?(?[\w\-.]+)(?\/.*)?/,ipfsHashRegex=/^(Qm[1-9A-HJ-NP-Za-km-z]{44,}|b[A-Za-z2-7]{58,}|B[A-Z2-7]{58,}|z[1-9A-HJ-NP-Za-km-z]{48,}|F[0-9A-F]{50,})(\/(?[\w\-.]+))?(?\/.*)?$/,base64Regex=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,dataURIRegex=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function isImageUri(c){try{const a=await fetch(c,{method:"HEAD"});if(a.status===200){const d=a.headers.get("content-type");return d==null?void 0:d.startsWith("image/")}return!1}catch(a){return typeof a=="object"&&typeof a.response<"u"||!globalThis.hasOwnProperty("Image")?!1:new Promise(d=>{const et=new Image;et.onload=()=>{d(!0)},et.onerror=()=>{d(!1)},et.src=c})}}function getGateway(c,a){return c?c.endsWith("/")?c.slice(0,-1):c:a}function resolveAvatarUri({uri:c,gatewayUrls:a}){const d=base64Regex.test(c);if(d)return{uri:c,isOnChain:!0,isEncoded:d};const et=getGateway(a==null?void 0:a.ipfs,"https://ipfs.io"),nt=getGateway(a==null?void 0:a.arweave,"https://arweave.net"),tt=c.match(networkRegex),{protocol:bt,subpath:mt,target:vt,subtarget:$t=""}=(tt==null?void 0:tt.groups)||{},At=bt==="ipns:/"||mt==="ipns/",Mt=bt==="ipfs:/"||mt==="ipfs/"||ipfsHashRegex.test(c);if(c.startsWith("http")&&!At&&!Mt){let Rt=c;return a!=null&&a.arweave&&(Rt=c.replace(/https:\/\/arweave.net/g,a==null?void 0:a.arweave)),{uri:Rt,isOnChain:!1,isEncoded:!1}}if((At||Mt)&&vt)return{uri:`${et}/${At?"ipns":"ipfs"}/${vt}${$t}`,isOnChain:!1,isEncoded:!1};if(bt==="ar:/"&&vt)return{uri:`${nt}/${vt}${$t||""}`,isOnChain:!1,isEncoded:!1};let Tt=c.replace(dataURIRegex,"");if(Tt.startsWith("nt.json());return await parseAvatarUri({gatewayUrls:c,uri:getJsonImage(d)})}catch{throw new EnsAvatarUriResolutionError({uri:a})}}async function parseAvatarUri({gatewayUrls:c,uri:a}){const{uri:d,isOnChain:et}=resolveAvatarUri({uri:a,gatewayUrls:c});if(et||await isImageUri(d))return d;throw new EnsAvatarUriResolutionError({uri:a})}function parseNftUri(c){let a=c;a.startsWith("did:nft:")&&(a=a.replace("did:nft:","").replace(/_/g,"/"));const[d,et,nt]=a.split("/"),[tt,bt]=d.split(":"),[mt,vt]=et.split(":");if(!tt||tt.toLowerCase()!=="eip155")throw new EnsAvatarInvalidNftUriError({reason:"Only EIP-155 supported"});if(!bt)throw new EnsAvatarInvalidNftUriError({reason:"Chain ID not found"});if(!vt)throw new EnsAvatarInvalidNftUriError({reason:"Contract address not found"});if(!nt)throw new EnsAvatarInvalidNftUriError({reason:"Token ID not found"});if(!mt)throw new EnsAvatarInvalidNftUriError({reason:"ERC namespace not found"});return{chainID:parseInt(bt),namespace:mt.toLowerCase(),contractAddress:vt,tokenID:nt}}async function getNftTokenUri(c,{nft:a}){if(a.namespace==="erc721")return readContract(c,{address:a.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(a.tokenID)]});if(a.namespace==="erc1155")return readContract(c,{address:a.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(a.tokenID)]});throw new EnsAvatarUnsupportedNamespaceError({namespace:a.namespace})}async function parseAvatarRecord(c,{gatewayUrls:a,record:d}){return/eip155:/i.test(d)?parseNftAvatarUri(c,{gatewayUrls:a,record:d}):parseAvatarUri({uri:d,gatewayUrls:a})}async function parseNftAvatarUri(c,{gatewayUrls:a,record:d}){const et=parseNftUri(d),nt=await getNftTokenUri(c,{nft:et}),{uri:tt,isOnChain:bt,isEncoded:mt}=resolveAvatarUri({uri:nt,gatewayUrls:a});if(bt&&(tt.includes("data:application/json;base64,")||tt.startsWith("{"))){const $t=mt?atob(tt.replace("data:application/json;base64,","")):tt,At=JSON.parse($t);return parseAvatarUri({uri:getJsonImage(At),gatewayUrls:a})}let vt=et.tokenID;return et.namespace==="erc1155"&&(vt=vt.replace("0x","").padStart(64,"0")),getMetadataAvatarUri({gatewayUrls:a,uri:tt.replace(/(?:0x)?{id}/,vt)})}async function getEnsText(c,{blockNumber:a,blockTag:d,name:et,key:nt,gatewayUrls:tt,strict:bt,universalResolverAddress:mt}){let vt=mt;if(!vt){if(!c.chain)throw new Error("client chain not configured. universalResolverAddress is required.");vt=getChainContractAddress({blockNumber:a,chain:c.chain,contract:"ensUniversalResolver"})}try{const $t={address:vt,abi:universalResolverResolveAbi,functionName:"resolve",args:[toHex(packetToBytes(et)),encodeFunctionData({abi:textResolverAbi,functionName:"text",args:[namehash(et),nt]})],blockNumber:a,blockTag:d},At=getAction(c,readContract,"readContract"),Mt=tt?await At({...$t,args:[...$t.args,tt]}):await At($t);if(Mt[0]==="0x")return null;const Tt=decodeFunctionResult({abi:textResolverAbi,functionName:"text",data:Mt[0]});return Tt===""?null:Tt}catch($t){if(bt)throw $t;if(isNullUniversalResolverError($t,"resolve"))return null;throw $t}}async function getEnsAvatar(c,{blockNumber:a,blockTag:d,assetGatewayUrls:et,name:nt,gatewayUrls:tt,strict:bt,universalResolverAddress:mt}){const vt=await getAction(c,getEnsText,"getEnsText")({blockNumber:a,blockTag:d,key:"avatar",name:nt,universalResolverAddress:mt,gatewayUrls:tt,strict:bt});if(!vt)return null;try{return await parseAvatarRecord(c,{record:vt,gatewayUrls:et})}catch{return null}}async function getEnsName(c,{address:a,blockNumber:d,blockTag:et,gatewayUrls:nt,strict:tt,universalResolverAddress:bt}){let mt=bt;if(!mt){if(!c.chain)throw new Error("client chain not configured. universalResolverAddress is required.");mt=getChainContractAddress({blockNumber:d,chain:c.chain,contract:"ensUniversalResolver"})}const vt=`${a.toLowerCase().substring(2)}.addr.reverse`;try{const $t={address:mt,abi:universalResolverReverseAbi,functionName:"reverse",args:[toHex(packetToBytes(vt))],blockNumber:d,blockTag:et},At=getAction(c,readContract,"readContract"),[Mt,Tt]=nt?await At({...$t,args:[...$t.args,nt]}):await At($t);return a.toLowerCase()!==Tt.toLowerCase()?null:Mt}catch($t){if(tt)throw $t;if(isNullUniversalResolverError($t,"reverse"))return null;throw $t}}async function getEnsResolver(c,{blockNumber:a,blockTag:d,name:et,universalResolverAddress:nt}){let tt=nt;if(!tt){if(!c.chain)throw new Error("client chain not configured. universalResolverAddress is required.");tt=getChainContractAddress({blockNumber:a,chain:c.chain,contract:"ensUniversalResolver"})}const[bt]=await getAction(c,readContract,"readContract")({address:tt,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[toHex(packetToBytes(et))],blockNumber:a,blockTag:d});return bt}async function createBlockFilter(c){const a=createFilterRequestScope(c,{method:"eth_newBlockFilter"}),d=await c.request({method:"eth_newBlockFilter"});return{id:d,request:a(d),type:"block"}}async function createEventFilter(c,{address:a,args:d,event:et,events:nt,fromBlock:tt,strict:bt,toBlock:mt}={}){const vt=nt??(et?[et]:void 0),$t=createFilterRequestScope(c,{method:"eth_newFilter"});let At=[];vt&&(At=[vt.flatMap(Tt=>encodeEventTopics({abi:[Tt],eventName:Tt.name,args:d}))],et&&(At=At[0]));const Mt=await c.request({method:"eth_newFilter",params:[{address:a,fromBlock:typeof tt=="bigint"?numberToHex(tt):tt,toBlock:typeof mt=="bigint"?numberToHex(mt):mt,...At.length?{topics:At}:{}}]});return{abi:vt,args:d,eventName:et?et.name:void 0,fromBlock:tt,id:Mt,request:$t(Mt),strict:!!bt,toBlock:mt,type:"event"}}async function createPendingTransactionFilter(c){const a=createFilterRequestScope(c,{method:"eth_newPendingTransactionFilter"}),d=await c.request({method:"eth_newPendingTransactionFilter"});return{id:d,request:a(d),type:"transaction"}}async function getBalance(c,{address:a,blockNumber:d,blockTag:et="latest"}){const nt=d?numberToHex(d):void 0,tt=await c.request({method:"eth_getBalance",params:[a,nt||et]});return BigInt(tt)}async function getBlobBaseFee(c){const a=await c.request({method:"eth_blobBaseFee"});return BigInt(a)}async function getBlockTransactionCount(c,{blockHash:a,blockNumber:d,blockTag:et="latest"}={}){const nt=d!==void 0?numberToHex(d):void 0;let tt;return a?tt=await c.request({method:"eth_getBlockTransactionCountByHash",params:[a]}):tt=await c.request({method:"eth_getBlockTransactionCountByNumber",params:[nt||et]}),hexToNumber(tt)}async function getBytecode(c,{address:a,blockNumber:d,blockTag:et="latest"}){const nt=d!==void 0?numberToHex(d):void 0,tt=await c.request({method:"eth_getCode",params:[a,nt||et]});if(tt!=="0x")return tt}function formatFeeHistory(c){var a;return{baseFeePerGas:c.baseFeePerGas.map(d=>BigInt(d)),gasUsedRatio:c.gasUsedRatio,oldestBlock:BigInt(c.oldestBlock),reward:(a=c.reward)==null?void 0:a.map(d=>d.map(et=>BigInt(et)))}}async function getFeeHistory(c,{blockCount:a,blockNumber:d,blockTag:et="latest",rewardPercentiles:nt}){const tt=d?numberToHex(d):void 0,bt=await c.request({method:"eth_feeHistory",params:[numberToHex(a),tt||et,nt]});return formatFeeHistory(bt)}async function getFilterLogs(c,{filter:a}){const d=a.strict??!1,nt=(await a.request({method:"eth_getFilterLogs",params:[a.id]})).map(tt=>formatLog(tt));return a.abi?parseEventLogs({abi:a.abi,logs:nt,strict:d}):nt}function defineChain(c){return{formatters:void 0,fees:void 0,serializers:void 0,...c}}const arrayRegex=/^(.*)\[([0-9]*)\]$/,bytesRegex=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,integerRegex=/^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;function hashTypedData(c){const{domain:a={},message:d,primaryType:et}=c,nt={EIP712Domain:getTypesForEIP712Domain({domain:a}),...c.types};validateTypedData({domain:a,message:d,primaryType:et,types:nt});const tt=["0x1901"];return a&&tt.push(hashDomain({domain:a,types:nt})),et!=="EIP712Domain"&&tt.push(hashStruct({data:d,primaryType:et,types:nt})),keccak256(concat(tt))}function hashDomain({domain:c,types:a}){return hashStruct({data:c,primaryType:"EIP712Domain",types:a})}function hashStruct({data:c,primaryType:a,types:d}){const et=encodeData({data:c,primaryType:a,types:d});return keccak256(et)}function encodeData({data:c,primaryType:a,types:d}){const et=[{type:"bytes32"}],nt=[hashType({primaryType:a,types:d})];for(const tt of d[a]){const[bt,mt]=encodeField({types:d,name:tt.name,type:tt.type,value:c[tt.name]});et.push(bt),nt.push(mt)}return encodeAbiParameters(et,nt)}function hashType({primaryType:c,types:a}){const d=toHex(encodeType({primaryType:c,types:a}));return keccak256(d)}function encodeType({primaryType:c,types:a}){let d="";const et=findTypeDependencies({primaryType:c,types:a});et.delete(c);const nt=[c,...Array.from(et).sort()];for(const tt of nt)d+=`${tt}(${a[tt].map(({name:bt,type:mt})=>`${mt} ${bt}`).join(",")})`;return d}function findTypeDependencies({primaryType:c,types:a},d=new Set){const et=c.match(/^\w*/u),nt=et==null?void 0:et[0];if(d.has(nt)||a[nt]===void 0)return d;d.add(nt);for(const tt of a[nt])findTypeDependencies({primaryType:tt.type,types:a},d);return d}function encodeField({types:c,name:a,type:d,value:et}){if(c[d]!==void 0)return[{type:"bytes32"},keccak256(encodeData({data:et,primaryType:d,types:c}))];if(d==="bytes")return et=`0x${(et.length%2?"0":"")+et.slice(2)}`,[{type:"bytes32"},keccak256(et)];if(d==="string")return[{type:"bytes32"},keccak256(toHex(et))];if(d.lastIndexOf("]")===d.length-1){const nt=d.slice(0,d.lastIndexOf("[")),tt=et.map(bt=>encodeField({name:a,type:nt,types:c,value:bt}));return[{type:"bytes32"},keccak256(encodeAbiParameters(tt.map(([bt])=>bt),tt.map(([,bt])=>bt)))]}return[{type:d},et]}function validateTypedData(c){const{domain:a,message:d,primaryType:et,types:nt}=c,tt=(bt,mt)=>{for(const vt of bt){const{name:$t,type:At}=vt,Mt=mt[$t],Tt=At.match(integerRegex);if(Tt&&(typeof Mt=="number"||typeof Mt=="bigint")){const[It,Dt,Nt]=Tt;numberToHex(Mt,{signed:Dt==="int",size:parseInt(Nt)/8})}if(At==="address"&&typeof Mt=="string"&&!isAddress(Mt))throw new InvalidAddressError({address:Mt});const Rt=At.match(bytesRegex);if(Rt){const[It,Dt]=Rt;if(Dt&&size$1(Mt)!==parseInt(Dt))throw new BytesSizeMismatchError({expectedSize:parseInt(Dt),givenSize:size$1(Mt)})}const kt=nt[At];kt&&tt(kt,Mt)}};if(nt.EIP712Domain&&a&&tt(nt.EIP712Domain,a),et!=="EIP712Domain"){const bt=nt[et];tt(bt,d)}}function getTypesForEIP712Domain({domain:c}){return[typeof(c==null?void 0:c.name)=="string"&&{name:"name",type:"string"},(c==null?void 0:c.version)&&{name:"version",type:"string"},typeof(c==null?void 0:c.chainId)=="number"&&{name:"chainId",type:"uint256"},(c==null?void 0:c.verifyingContract)&&{name:"verifyingContract",type:"address"},(c==null?void 0:c.salt)&&{name:"salt",type:"bytes32"}].filter(Boolean)}const docsPath="/docs/contract/encodeDeployData";function encodeDeployData(c){const{abi:a,args:d,bytecode:et}=c;if(!d||d.length===0)return et;const nt=a.find(bt=>"type"in bt&&bt.type==="constructor");if(!nt)throw new AbiConstructorNotFoundError({docsPath});if(!("inputs"in nt))throw new AbiConstructorParamsNotFoundError({docsPath});if(!nt.inputs||nt.inputs.length===0)throw new AbiConstructorParamsNotFoundError({docsPath});const tt=encodeAbiParameters(nt.inputs,d);return concatHex([et,tt])}function encodePacked(c,a){if(c.length!==a.length)throw new AbiEncodingLengthMismatchError({expectedLength:c.length,givenLength:a.length});const d=[];for(let et=0;etgetEncodable(a))):getEncodableBytes(c)}function getEncodableList(c){const a=c.reduce((nt,tt)=>nt+tt.length,0),d=getSizeOfLength(a);return{length:(()=>a<=55?1+a:1+d+a)(),encode(nt){a<=55?nt.pushByte(192+a):(nt.pushByte(192+55+d),d===1?nt.pushUint8(a):d===2?nt.pushUint16(a):d===3?nt.pushUint24(a):nt.pushUint32(a));for(const{encode:tt}of c)tt(nt)}}}function getEncodableBytes(c){const a=typeof c=="string"?hexToBytes(c):c,d=getSizeOfLength(a.length);return{length:(()=>a.length===1&&a[0]<128?1:a.length<=55?1+a.length:1+d+a.length)(),encode(nt){a.length===1&&a[0]<128?nt.pushBytes(a):a.length<=55?(nt.pushByte(128+a.length),nt.pushBytes(a)):(nt.pushByte(128+55+d),d===1?nt.pushUint8(a.length):d===2?nt.pushUint16(a.length):d===3?nt.pushUint24(a.length):nt.pushUint32(a.length),nt.pushBytes(a))}}}function getSizeOfLength(c){if(c<2**8)return 1;if(c<2**16)return 2;if(c<2**24)return 3;if(c<2**32)return 4;throw new BaseError("Length is too large.")}const receiptStatuses={"0x0":"reverted","0x1":"success"};function formatTransactionReceipt(c){const a={...c,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,contractAddress:c.contractAddress?c.contractAddress:null,cumulativeGasUsed:c.cumulativeGasUsed?BigInt(c.cumulativeGasUsed):null,effectiveGasPrice:c.effectiveGasPrice?BigInt(c.effectiveGasPrice):null,gasUsed:c.gasUsed?BigInt(c.gasUsed):null,logs:c.logs?c.logs.map(d=>formatLog(d)):null,to:c.to?c.to:null,transactionIndex:c.transactionIndex?hexToNumber(c.transactionIndex):null,status:c.status?receiptStatuses[c.status]:null,type:c.type?transactionType[c.type]||c.type:null};return c.blobGasPrice&&(a.blobGasPrice=BigInt(c.blobGasPrice)),c.blobGasUsed&&(a.blobGasUsed=BigInt(c.blobGasUsed)),a}const defineTransactionReceipt=defineFormatter("transactionReceipt",formatTransactionReceipt),presignMessagePrefix=`Ethereum Signed Message: +`;function hashMessage(c,a){const d=(()=>typeof c=="string"?stringToBytes(c):c.raw instanceof Uint8Array?c.raw:toBytes$1(c.raw))(),et=stringToBytes(`${presignMessagePrefix}${d.length}`);return keccak256(concat([et,d]),a)}function assertTransactionEIP4844(c){const{blobVersionedHashes:a}=c;if(a){if(a.length===0)throw new EmptyBlobError;for(const d of a){const et=size$1(d),nt=hexToNumber(slice(d,0,1));if(et!==32)throw new InvalidVersionedHashSizeError({hash:d,size:et});if(nt!==versionedHashVersionKzg)throw new InvalidVersionedHashVersionError({hash:d,version:nt})}}assertTransactionEIP1559(c)}function assertTransactionEIP1559(c){const{chainId:a,maxPriorityFeePerGas:d,maxFeePerGas:et,to:nt}=c;if(a<=0)throw new InvalidChainIdError({chainId:a});if(nt&&!isAddress(nt))throw new InvalidAddressError({address:nt});if(et&&et>2n**256n-1n)throw new FeeCapTooHighError({maxFeePerGas:et});if(d&&et&&d>et)throw new TipAboveFeeCapError({maxFeePerGas:et,maxPriorityFeePerGas:d})}function assertTransactionEIP2930(c){const{chainId:a,maxPriorityFeePerGas:d,gasPrice:et,maxFeePerGas:nt,to:tt}=c;if(a<=0)throw new InvalidChainIdError({chainId:a});if(tt&&!isAddress(tt))throw new InvalidAddressError({address:tt});if(d||nt)throw new BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(et&&et>2n**256n-1n)throw new FeeCapTooHighError({maxFeePerGas:et})}function assertTransactionLegacy(c){const{chainId:a,maxPriorityFeePerGas:d,gasPrice:et,maxFeePerGas:nt,to:tt,accessList:bt}=c;if(tt&&!isAddress(tt))throw new InvalidAddressError({address:tt});if(typeof a<"u"&&a<=0)throw new InvalidChainIdError({chainId:a});if(d||nt)throw new BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(et&&et>2n**256n-1n)throw new FeeCapTooHighError({maxFeePerGas:et});if(bt)throw new BaseError("`accessList` is not a valid Legacy Transaction attribute.")}function serializeAccessList(c){if(!c||c.length===0)return[];const a=[];for(let d=0;d"u"||typeof Rt>"u")){const Ut=typeof c.blobs[0]=="string"?c.blobs:c.blobs.map(Xt=>bytesToHex(Xt)),Gt=c.kzg,Wt=blobsToCommitments({blobs:Ut,kzg:Gt});if(typeof Tt>"u"&&(Tt=commitmentsToVersionedHashes({commitments:Wt})),typeof Rt>"u"){const Xt=blobsToProofs({blobs:Ut,commitments:Wt,kzg:Gt});Rt=toBlobSidecars({blobs:Ut,commitments:Wt,proofs:Xt})}}const kt=serializeAccessList(At),It=[toHex(d),nt?toHex(nt):"0x",$t?toHex($t):"0x",vt?toHex(vt):"0x",et?toHex(et):"0x",tt??"0x",bt?toHex(bt):"0x",Mt??"0x",kt,mt?toHex(mt):"0x",Tt??[],...toYParitySignatureArray(c,a)],Dt=[],Nt=[],Ot=[];if(Rt)for(let Ut=0;Ut{if(a.v>=35n)return(a.v-35n)/2n>0?a.v:27n+(a.v===35n?0n:1n);if(d>0)return BigInt(d*2)+BigInt(35n+a.v-27n);const Mt=27n+(a.v===27n?0n:1n);if(a.v!==Mt)throw new InvalidLegacyVError({v:a.v});return Mt})();$t=[...$t,toHex(At),a.r,a.s]}else d>0&&($t=[...$t,toHex(d),"0x","0x"]);return toRlp($t)}function toYParitySignatureArray(c,a){const{r:d,s:et,v:nt,yParity:tt}=a??c;return typeof d>"u"?[]:typeof et>"u"?[]:typeof nt>"u"&&typeof tt>"u"?[]:[(()=>typeof tt=="number"?tt?toHex(1):"0x":nt===0n?"0x":nt===1n?toHex(1):nt===27n?"0x":toHex(1))(),trim(d),trim(et)]}function formatStorageProof(c){return c.map(a=>({...a,value:BigInt(a.value)}))}function formatProof(c){return{...c,balance:c.balance?BigInt(c.balance):void 0,nonce:c.nonce?hexToNumber(c.nonce):void 0,storageProof:c.storageProof?formatStorageProof(c.storageProof):void 0}}async function getProof(c,{address:a,blockNumber:d,blockTag:et,storageKeys:nt}){const tt=et??"latest",bt=d!==void 0?numberToHex(d):void 0,mt=await c.request({method:"eth_getProof",params:[a,nt,bt||tt]});return formatProof(mt)}async function getStorageAt(c,{address:a,blockNumber:d,blockTag:et="latest",slot:nt}){const tt=d!==void 0?numberToHex(d):void 0;return await c.request({method:"eth_getStorageAt",params:[a,nt,tt||et]})}async function getTransaction(c,{blockHash:a,blockNumber:d,blockTag:et,hash:nt,index:tt}){var At,Mt,Tt;const bt=et||"latest",mt=d!==void 0?numberToHex(d):void 0;let vt=null;if(nt?vt=await c.request({method:"eth_getTransactionByHash",params:[nt]}):a?vt=await c.request({method:"eth_getTransactionByBlockHashAndIndex",params:[a,numberToHex(tt)]}):(mt||bt)&&(vt=await c.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[mt||bt,numberToHex(tt)]})),!vt)throw new TransactionNotFoundError({blockHash:a,blockNumber:d,blockTag:bt,hash:nt,index:tt});return(((Tt=(Mt=(At=c.chain)==null?void 0:At.formatters)==null?void 0:Mt.transaction)==null?void 0:Tt.format)||formatTransaction)(vt)}async function getTransactionConfirmations(c,{hash:a,transactionReceipt:d}){const[et,nt]=await Promise.all([getAction(c,getBlockNumber,"getBlockNumber")({}),a?getAction(c,getTransaction,"getBlockNumber")({hash:a}):void 0]),tt=(d==null?void 0:d.blockNumber)||(nt==null?void 0:nt.blockNumber);return tt?et-tt+1n:0n}async function getTransactionReceipt(c,{hash:a}){var nt,tt,bt;const d=await c.request({method:"eth_getTransactionReceipt",params:[a]});if(!d)throw new TransactionReceiptNotFoundError({hash:a});return(((bt=(tt=(nt=c.chain)==null?void 0:nt.formatters)==null?void 0:tt.transactionReceipt)==null?void 0:bt.format)||formatTransactionReceipt)(d)}async function multicall(c,a){var Dt;const{allowFailure:d=!0,batchSize:et,blockNumber:nt,blockTag:tt,multicallAddress:bt,stateOverride:mt}=a,vt=a.contracts,$t=et??(typeof((Dt=c.batch)==null?void 0:Dt.multicall)=="object"&&c.batch.multicall.batchSize||1024);let At=bt;if(!At){if(!c.chain)throw new Error("client chain not configured. multicallAddress is required.");At=getChainContractAddress({blockNumber:nt,chain:c.chain,contract:"multicall3"})}const Mt=[[]];let Tt=0,Rt=0;for(let Nt=0;Nt0&&Rt>$t&&Mt[Tt].length>0&&(Tt++,Rt=(Xt.length-2)/2,Mt[Tt]=[]),Mt[Tt]=[...Mt[Tt],{allowFailure:!0,callData:Xt,target:Ut}]}catch(Xt){const a0=getContractError(Xt,{abi:Ot,address:Ut,args:Gt,docsPath:"/docs/contract/multicall",functionName:Wt});if(!d)throw a0;Mt[Tt]=[...Mt[Tt],{allowFailure:!0,callData:"0x",target:Ut}]}}const kt=await Promise.allSettled(Mt.map(Nt=>getAction(c,readContract,"readContract")({abi:multicall3Abi,address:At,args:[Nt],blockNumber:nt,blockTag:tt,functionName:"aggregate3",stateOverride:mt}))),It=[];for(let Nt=0;Nttypeof tt<"u"?tt:!(c.transport.type==="webSocket"||c.transport.type==="fallback"&&c.transport.transports[0].config.type==="webSocket"))();let vt;return mt?(()=>{const Mt=stringify(["watchBlockNumber",c.uid,a,d,bt]);return observe$1(Mt,{onBlockNumber:et,onError:nt},Tt=>poll(async()=>{var Rt;try{const kt=await getAction(c,getBlockNumber,"getBlockNumber")({cacheTime:0});if(vt){if(kt===vt)return;if(kt-vt>1&&d)for(let It=vt+1n;Itvt)&&(Tt.onBlockNumber(kt,vt),vt=kt)}catch(kt){(Rt=Tt.onError)==null||Rt.call(Tt,kt)}},{emitOnBegin:a,interval:bt}))})():(()=>{const Mt=stringify(["watchBlockNumber",c.uid,a,d]);return observe$1(Mt,{onBlockNumber:et,onError:nt},Tt=>{let Rt=!0,kt=()=>Rt=!1;return(async()=>{try{const It=(()=>{if(c.transport.type==="fallback"){const Nt=c.transport.transports.find(Ot=>Ot.config.type==="webSocket");return Nt?Nt.value:c.transport}return c.transport})(),{unsubscribe:Dt}=await It.subscribe({params:["newHeads"],onData(Nt){var Ut;if(!Rt)return;const Ot=hexToBigInt((Ut=Nt.result)==null?void 0:Ut.number);Tt.onBlockNumber(Ot,vt),vt=Ot},onError(Nt){var Ot;(Ot=Tt.onError)==null||Ot.call(Tt,Nt)}});kt=Dt,Rt||kt()}catch(It){nt==null||nt(It)}})(),()=>kt()})})()}async function waitForTransactionReceipt(c,{confirmations:a=1,hash:d,onReplaced:et,pollingInterval:nt=c.pollingInterval,retryCount:tt=6,retryDelay:bt=({count:vt})=>~~(1<{mt&&setTimeout(()=>kt(new WaitForTransactionReceiptTimeoutError({hash:d})),mt);const It=observe$1(vt,{onReplaced:et,resolve:Rt,reject:kt},Dt=>{const Nt=getAction(c,watchBlockNumber,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:nt,async onBlockNumber(Ot){if(Tt)return;let Ut=Ot;const Gt=Wt=>{Nt(),Wt(),It()};try{if(Mt){if(a>1&&(!Mt.blockNumber||Ut-Mt.blockNumber+1nDt.resolve(Mt));return}if($t||(Tt=!0,await withRetry(async()=>{$t=await getAction(c,getTransaction,"getTransaction")({hash:d}),$t.blockNumber&&(Ut=$t.blockNumber)},{delay:bt,retryCount:tt}),Tt=!1),Mt=await getAction(c,getTransactionReceipt,"getTransactionReceipt")({hash:d}),a>1&&(!Mt.blockNumber||Ut-Mt.blockNumber+1nDt.resolve(Mt))}catch(Wt){if(Wt instanceof TransactionNotFoundError||Wt instanceof TransactionReceiptNotFoundError){if(!$t){Tt=!1;return}try{At=$t,Tt=!0;const Xt=await withRetry(()=>getAction(c,getBlock,"getBlock")({blockNumber:Ut,includeTransactions:!0}),{delay:bt,retryCount:tt,shouldRetry:({error:t0})=>t0 instanceof BlockNotFoundError});Tt=!1;const a0=Xt.transactions.find(({from:t0,nonce:c0})=>t0===At.from&&c0===At.nonce);if(!a0||(Mt=await getAction(c,getTransactionReceipt,"getTransactionReceipt")({hash:a0.hash}),a>1&&(!Mt.blockNumber||Ut-Mt.blockNumber+1n{var t0;(t0=Dt.onReplaced)==null||t0.call(Dt,{reason:n0,replacedTransaction:At,transaction:a0,transactionReceipt:Mt}),Dt.resolve(Mt)})}catch(Xt){Gt(()=>Dt.reject(Xt))}}else Gt(()=>Dt.reject(Wt))}}})})})}function watchBlocks(c,{blockTag:a="latest",emitMissed:d=!1,emitOnBegin:et=!1,onBlock:nt,onError:tt,includeTransactions:bt,poll:mt,pollingInterval:vt=c.pollingInterval}){const $t=(()=>typeof mt<"u"?mt:!(c.transport.type==="webSocket"||c.transport.type==="fallback"&&c.transport.transports[0].config.type==="webSocket"))(),At=bt??!1;let Mt;return $t?(()=>{const kt=stringify(["watchBlocks",c.uid,a,d,et,At,vt]);return observe$1(kt,{onBlock:nt,onError:tt},It=>poll(async()=>{var Dt;try{const Nt=await getAction(c,getBlock,"getBlock")({blockTag:a,includeTransactions:At});if(Nt.number&&(Mt!=null&&Mt.number)){if(Nt.number===Mt.number)return;if(Nt.number-Mt.number>1&&d)for(let Ot=(Mt==null?void 0:Mt.number)+1n;OtMt.number)&&(It.onBlock(Nt,Mt),Mt=Nt)}catch(Nt){(Dt=It.onError)==null||Dt.call(It,Nt)}},{emitOnBegin:et,interval:vt}))})():(()=>{let kt=!0,It=()=>kt=!1;return(async()=>{try{const Dt=(()=>{if(c.transport.type==="fallback"){const Ot=c.transport.transports.find(Ut=>Ut.config.type==="webSocket");return Ot?Ot.value:c.transport}return c.transport})(),{unsubscribe:Nt}=await Dt.subscribe({params:["newHeads"],onData(Ot){var Wt,Xt,a0;if(!kt)return;const Gt=(((a0=(Xt=(Wt=c.chain)==null?void 0:Wt.formatters)==null?void 0:Xt.block)==null?void 0:a0.format)||formatBlock)(Ot.result);nt(Gt,Mt),Mt=Gt},onError(Ot){tt==null||tt(Ot)}});It=Nt,kt||It()}catch(Dt){tt==null||tt(Dt)}})(),()=>It()})()}function watchEvent(c,{address:a,args:d,batch:et=!0,event:nt,events:tt,fromBlock:bt,onError:mt,onLogs:vt,poll:$t,pollingInterval:At=c.pollingInterval,strict:Mt}){const Tt=(()=>typeof $t<"u"?$t:typeof bt=="bigint"?!0:!(c.transport.type==="webSocket"||c.transport.type==="fallback"&&c.transport.transports[0].config.type==="webSocket"))(),Rt=Mt??!1;return Tt?(()=>{const Dt=stringify(["watchEvent",a,d,et,c.uid,nt,At,bt]);return observe$1(Dt,{onLogs:vt,onError:mt},Nt=>{let Ot;bt!==void 0&&(Ot=bt-1n);let Ut,Gt=!1;const Wt=poll(async()=>{var Xt;if(!Gt){try{Ut=await getAction(c,createEventFilter,"createEventFilter")({address:a,args:d,event:nt,events:tt,strict:Rt,fromBlock:bt})}catch{}Gt=!0;return}try{let a0;if(Ut)a0=await getAction(c,getFilterChanges,"getFilterChanges")({filter:Ut});else{const n0=await getAction(c,getBlockNumber,"getBlockNumber")({});Ot&&Ot!==n0?a0=await getAction(c,getLogs,"getLogs")({address:a,args:d,event:nt,events:tt,fromBlock:Ot+1n,toBlock:n0}):a0=[],Ot=n0}if(a0.length===0)return;if(et)Nt.onLogs(a0);else for(const n0 of a0)Nt.onLogs([n0])}catch(a0){Ut&&a0 instanceof InvalidInputRpcError&&(Gt=!1),(Xt=Nt.onError)==null||Xt.call(Nt,a0)}},{emitOnBegin:!0,interval:At});return async()=>{Ut&&await getAction(c,uninstallFilter,"uninstallFilter")({filter:Ut}),Wt()}})})():(()=>{let Dt=!0,Nt=()=>Dt=!1;return(async()=>{try{const Ot=(()=>{if(c.transport.type==="fallback"){const Xt=c.transport.transports.find(a0=>a0.config.type==="webSocket");return Xt?Xt.value:c.transport}return c.transport})(),Ut=tt??(nt?[nt]:void 0);let Gt=[];Ut&&(Gt=[Ut.flatMap(Xt=>encodeEventTopics({abi:[Xt],eventName:Xt.name,args:d}))],nt&&(Gt=Gt[0]));const{unsubscribe:Wt}=await Ot.subscribe({params:["logs",{address:a,topics:Gt}],onData(Xt){var n0;if(!Dt)return;const a0=Xt.result;try{const{eventName:t0,args:c0}=decodeEventLog({abi:Ut??[],data:a0.data,topics:a0.topics,strict:Rt}),Ct=formatLog(a0,{args:c0,eventName:t0});vt([Ct])}catch(t0){let c0,Ct;if(t0 instanceof DecodeLogDataMismatch||t0 instanceof DecodeLogTopicsMismatch){if(Mt)return;c0=t0.abiItem.name,Ct=(n0=t0.abiItem.inputs)==null?void 0:n0.some(yt=>!("name"in yt&&yt.name))}const dt=formatLog(a0,{args:Ct?[]:{},eventName:c0});vt([dt])}},onError(Xt){mt==null||mt(Xt)}});Nt=Wt,Dt||Nt()}catch(Ot){mt==null||mt(Ot)}})(),()=>Nt()})()}function watchPendingTransactions(c,{batch:a=!0,onError:d,onTransactions:et,poll:nt,pollingInterval:tt=c.pollingInterval}){return(typeof nt<"u"?nt:c.transport.type!=="webSocket")?(()=>{const $t=stringify(["watchPendingTransactions",c.uid,a,tt]);return observe$1($t,{onTransactions:et,onError:d},At=>{let Mt;const Tt=poll(async()=>{var Rt;try{if(!Mt)try{Mt=await getAction(c,createPendingTransactionFilter,"createPendingTransactionFilter")({});return}catch(It){throw Tt(),It}const kt=await getAction(c,getFilterChanges,"getFilterChanges")({filter:Mt});if(kt.length===0)return;if(a)At.onTransactions(kt);else for(const It of kt)At.onTransactions([It])}catch(kt){(Rt=At.onError)==null||Rt.call(At,kt)}},{emitOnBegin:!0,interval:tt});return async()=>{Mt&&await getAction(c,uninstallFilter,"uninstallFilter")({filter:Mt}),Tt()}})})():(()=>{let $t=!0,At=()=>$t=!1;return(async()=>{try{const{unsubscribe:Mt}=await c.transport.subscribe({params:["newPendingTransactions"],onData(Tt){if(!$t)return;const Rt=Tt.result;et([Rt])},onError(Tt){d==null||d(Tt)}});At=Mt,$t||At()}catch(Mt){d==null||d(Mt)}})(),()=>At()})()}function publicActions(c){return{call:a=>call(c,a),createBlockFilter:()=>createBlockFilter(c),createContractEventFilter:a=>createContractEventFilter(c,a),createEventFilter:a=>createEventFilter(c,a),createPendingTransactionFilter:()=>createPendingTransactionFilter(c),estimateContractGas:a=>estimateContractGas(c,a),estimateGas:a=>estimateGas(c,a),getBalance:a=>getBalance(c,a),getBlobBaseFee:()=>getBlobBaseFee(c),getBlock:a=>getBlock(c,a),getBlockNumber:a=>getBlockNumber(c,a),getBlockTransactionCount:a=>getBlockTransactionCount(c,a),getBytecode:a=>getBytecode(c,a),getChainId:()=>getChainId(c),getContractEvents:a=>getContractEvents(c,a),getEnsAddress:a=>getEnsAddress(c,a),getEnsAvatar:a=>getEnsAvatar(c,a),getEnsName:a=>getEnsName(c,a),getEnsResolver:a=>getEnsResolver(c,a),getEnsText:a=>getEnsText(c,a),getFeeHistory:a=>getFeeHistory(c,a),estimateFeesPerGas:a=>estimateFeesPerGas(c,a),getFilterChanges:a=>getFilterChanges(c,a),getFilterLogs:a=>getFilterLogs(c,a),getGasPrice:()=>getGasPrice(c),getLogs:a=>getLogs(c,a),getProof:a=>getProof(c,a),estimateMaxPriorityFeePerGas:a=>estimateMaxPriorityFeePerGas(c,a),getStorageAt:a=>getStorageAt(c,a),getTransaction:a=>getTransaction(c,a),getTransactionConfirmations:a=>getTransactionConfirmations(c,a),getTransactionCount:a=>getTransactionCount(c,a),getTransactionReceipt:a=>getTransactionReceipt(c,a),multicall:a=>multicall(c,a),prepareTransactionRequest:a=>prepareTransactionRequest(c,a),readContract:a=>readContract(c,a),sendRawTransaction:a=>sendRawTransaction(c,a),simulateContract:a=>simulateContract(c,a),verifyMessage:a=>verifyMessage(c,a),verifyTypedData:a=>verifyTypedData(c,a),uninstallFilter:a=>uninstallFilter(c,a),waitForTransactionReceipt:a=>waitForTransactionReceipt(c,a),watchBlocks:a=>watchBlocks(c,a),watchBlockNumber:a=>watchBlockNumber(c,a),watchContractEvent:a=>watchContractEvent(c,a),watchEvent:a=>watchEvent(c,a),watchPendingTransactions:a=>watchPendingTransactions(c,a)}}function createPublicClient(c){const{key:a="public",name:d="Public Client"}=c;return createClient({...c,key:a,name:d,type:"publicClient"}).extend(publicActions)}const ERC20_ABI=["function name() view returns (string)","function symbol() view returns (string)","function decimals() view returns (uint8)","function totalSupply() view returns (uint256)","function balanceOf(address owner) view returns (uint256)","function transfer(address to, uint256 value) returns (bool)","function allowance(address owner, address spender) view returns (uint256)","function approve(address spender, uint256 value) returns (bool)","function transferFrom(address from, address to, uint256 value) returns (bool)"],publicClient=c=>{var a;return createPublicClient({transport:http((a=NetworkUtil.getNetworkById(c))==null?void 0:a.url)})};async function getTokenBalance(c,a,d){const et=new Contract(c,ERC20_ABI,d),nt=await et.balanceOf(a);console.log(nt);const tt=await et.decimals();return formatUnits$1(nt,tt)}async function getTokenDecimals(c,a){return await new Contract(c,ERC20_ABI,a).decimals()}async function buildTransferToken(c,a,d,et){return(await new Contract(c,ERC20_ABI,et).transfer.populateTransaction(a,d)).data}const abi=[{type:"fallback",stateMutability:"payable"},{type:"receive",stateMutability:"payable"},{type:"function",name:"accountId",inputs:[],outputs:[{name:"accountImplementationId",type:"string",internalType:"string"}],stateMutability:"view"},{type:"function",name:"domainSeparator",inputs:[],outputs:[{name:"",type:"bytes32",internalType:"bytes32"}],stateMutability:"view"},{type:"function",name:"entryPoint",inputs:[],outputs:[{name:"",type:"address",internalType:"address"}],stateMutability:"view"},{type:"function",name:"execute",inputs:[{name:"mode",type:"bytes32",internalType:"ModeCode"},{name:"executionCalldata",type:"bytes",internalType:"bytes"}],outputs:[],stateMutability:"payable"},{type:"function",name:"executeFromExecutor",inputs:[{name:"mode",type:"bytes32",internalType:"ModeCode"},{name:"executionCalldata",type:"bytes",internalType:"bytes"}],outputs:[{name:"returnDatas",type:"bytes[]",internalType:"bytes[]"}],stateMutability:"payable"},{type:"function",name:"getActiveHook",inputs:[],outputs:[{name:"hook",type:"address",internalType:"address"}],stateMutability:"view"},{type:"function",name:"getActiveHook",inputs:[{name:"selector",type:"bytes4",internalType:"bytes4"}],outputs:[{name:"hook",type:"address",internalType:"address"}],stateMutability:"view"},{type:"function",name:"getExecutorsPaginated",inputs:[{name:"cursor",type:"address",internalType:"address"},{name:"size",type:"uint256",internalType:"uint256"}],outputs:[{name:"array",type:"address[]",internalType:"address[]"},{name:"next",type:"address",internalType:"address"}],stateMutability:"view"},{type:"function",name:"getNonce",inputs:[{name:"safe",type:"address",internalType:"address"},{name:"validator",type:"address",internalType:"address"}],outputs:[{name:"nonce",type:"uint256",internalType:"uint256"}],stateMutability:"view"},{type:"function",name:"getValidatorPaginated",inputs:[{name:"start",type:"address",internalType:"address"},{name:"pageSize",type:"uint256",internalType:"uint256"}],outputs:[{name:"array",type:"address[]",internalType:"address[]"},{name:"next",type:"address",internalType:"address"}],stateMutability:"view"},{type:"function",name:"initializeAccount",inputs:[{name:"validators",type:"tuple[]",internalType:"struct ModuleInit[]",components:[{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}]},{name:"executors",type:"tuple[]",internalType:"struct ModuleInit[]",components:[{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}]},{name:"fallbacks",type:"tuple[]",internalType:"struct ModuleInit[]",components:[{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}]},{name:"hooks",type:"tuple[]",internalType:"struct ModuleInit[]",components:[{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}]},{name:"registryInit",type:"tuple",internalType:"struct RegistryInit",components:[{name:"registry",type:"address",internalType:"contract IERC7484"},{name:"attesters",type:"address[]",internalType:"address[]"},{name:"threshold",type:"uint8",internalType:"uint8"}]}],outputs:[],stateMutability:"payable"},{type:"function",name:"installModule",inputs:[{name:"moduleType",type:"uint256",internalType:"uint256"},{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}],outputs:[],stateMutability:"payable"},{type:"function",name:"isModuleInstalled",inputs:[{name:"moduleType",type:"uint256",internalType:"uint256"},{name:"module",type:"address",internalType:"address"},{name:"additionalContext",type:"bytes",internalType:"bytes"}],outputs:[{name:"",type:"bool",internalType:"bool"}],stateMutability:"view"},{type:"function",name:"isValidSignature",inputs:[{name:"hash",type:"bytes32",internalType:"bytes32"},{name:"data",type:"bytes",internalType:"bytes"}],outputs:[{name:"magicValue",type:"bytes4",internalType:"bytes4"}],stateMutability:"view"},{type:"function",name:"launchpadValidators",inputs:[{name:"validators",type:"tuple[]",internalType:"struct ModuleInit[]",components:[{name:"module",type:"address",internalType:"address"},{name:"initData",type:"bytes",internalType:"bytes"}]}],outputs:[],stateMutability:"payable"},{type:"function",name:"setRegistry",inputs:[{name:"registry",type:"address",internalType:"contract IERC7484"},{name:"attesters",type:"address[]",internalType:"address[]"},{name:"threshold",type:"uint8",internalType:"uint8"}],outputs:[],stateMutability:"nonpayable"},{type:"function",name:"supportsExecutionMode",inputs:[{name:"encodedMode",type:"bytes32",internalType:"ModeCode"}],outputs:[{name:"supported",type:"bool",internalType:"bool"}],stateMutability:"pure"},{type:"function",name:"supportsModule",inputs:[{name:"moduleTypeId",type:"uint256",internalType:"uint256"}],outputs:[{name:"",type:"bool",internalType:"bool"}],stateMutability:"pure"},{type:"function",name:"uninstallModule",inputs:[{name:"moduleType",type:"uint256",internalType:"uint256"},{name:"module",type:"address",internalType:"address"},{name:"deInitData",type:"bytes",internalType:"bytes"}],outputs:[],stateMutability:"payable"},{type:"function",name:"validateUserOp",inputs:[{name:"userOp",type:"tuple",internalType:"struct PackedUserOperation",components:[{name:"sender",type:"address",internalType:"address"},{name:"nonce",type:"uint256",internalType:"uint256"},{name:"initCode",type:"bytes",internalType:"bytes"},{name:"callData",type:"bytes",internalType:"bytes"},{name:"accountGasLimits",type:"bytes32",internalType:"bytes32"},{name:"preVerificationGas",type:"uint256",internalType:"uint256"},{name:"gasFees",type:"bytes32",internalType:"bytes32"},{name:"paymasterAndData",type:"bytes",internalType:"bytes"},{name:"signature",type:"bytes",internalType:"bytes"}]},{name:"userOpHash",type:"bytes32",internalType:"bytes32"},{name:"missingAccountFunds",type:"uint256",internalType:"uint256"}],outputs:[{name:"validSignature",type:"uint256",internalType:"uint256"}],stateMutability:"payable"},{type:"event",name:"ERC7484RegistryConfigured",inputs:[{name:"smartAccount",type:"address",indexed:!0,internalType:"address"},{name:"registry",type:"address",indexed:!0,internalType:"contract IERC7484"}],anonymous:!1},{type:"event",name:"ModuleInstalled",inputs:[{name:"moduleTypeId",type:"uint256",indexed:!1,internalType:"uint256"},{name:"module",type:"address",indexed:!1,internalType:"address"}],anonymous:!1},{type:"event",name:"ModuleUninstalled",inputs:[{name:"moduleTypeId",type:"uint256",indexed:!1,internalType:"uint256"},{name:"module",type:"address",indexed:!1,internalType:"address"}],anonymous:!1},{type:"event",name:"Safe7579Initialized",inputs:[{name:"safe",type:"address",indexed:!0,internalType:"address"}],anonymous:!1},{type:"event",name:"TryExecutionFailed",inputs:[{name:"safe",type:"address",indexed:!1,internalType:"contract ISafe"},{name:"numberInBatch",type:"uint256",indexed:!1,internalType:"uint256"}],anonymous:!1},{type:"event",name:"TryExecutionsFailed",inputs:[{name:"safe",type:"address",indexed:!1,internalType:"contract ISafe"},{name:"success",type:"bool[]",indexed:!1,internalType:"bool[]"}],anonymous:!1},{type:"error",name:"AccountAccessUnauthorized",inputs:[]},{type:"error",name:"AccountInitializationFailed",inputs:[]},{type:"error",name:"ExecutionFailed",inputs:[]},{type:"error",name:"FallbackInstalled",inputs:[{name:"msgSig",type:"bytes4",internalType:"bytes4"}]},{type:"error",name:"HookAlreadyInstalled",inputs:[{name:"currentHook",type:"address",internalType:"address"}]},{type:"error",name:"HookPostCheckFailed",inputs:[]},{type:"error",name:"InitializerError",inputs:[]},{type:"error",name:"InvalidFallbackHandler",inputs:[{name:"msgSig",type:"bytes4",internalType:"bytes4"}]},{type:"error",name:"InvalidHookType",inputs:[]},{type:"error",name:"InvalidInitData",inputs:[{name:"safe",type:"address",internalType:"address"}]},{type:"error",name:"InvalidInput",inputs:[]},{type:"error",name:"InvalidModule",inputs:[{name:"module",type:"address",internalType:"address"}]},{type:"error",name:"LinkedListError",inputs:[]},{type:"error",name:"LinkedList_AlreadyInitialized",inputs:[]},{type:"error",name:"LinkedList_AlreadyInitialized",inputs:[]},{type:"error",name:"LinkedList_EntryAlreadyInList",inputs:[{name:"entry",type:"address",internalType:"address"}]},{type:"error",name:"LinkedList_EntryAlreadyInList",inputs:[{name:"entry",type:"address",internalType:"address"}]},{type:"error",name:"LinkedList_InvalidEntry",inputs:[{name:"entry",type:"address",internalType:"address"}]},{type:"error",name:"LinkedList_InvalidEntry",inputs:[{name:"entry",type:"address",internalType:"address"}]},{type:"error",name:"LinkedList_InvalidPage",inputs:[]},{type:"error",name:"LinkedList_InvalidPage",inputs:[]},{type:"error",name:"NoFallbackHandler",inputs:[{name:"msgSig",type:"bytes4",internalType:"bytes4"}]},{type:"error",name:"UnsupportedCallType",inputs:[{name:"callType",type:"bytes1",internalType:"CallType"}]},{type:"error",name:"UnsupportedExecType",inputs:[{name:"execType",type:"bytes1",internalType:"ExecType"}]},{type:"error",name:"UnsupportedModuleType",inputs:[{name:"moduleTypeId",type:"uint256",internalType:"uint256"}]},{type:"error",name:"ValidatorStorageHelperError",inputs:[]}],bytecode={object:"0x6080604052348015600f57600080fd5b50604051601a90605a565b604051809103906000f0801580156035573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b03929092169190911790556067565b6109d880614a9483390190565b614a1e806100766000396000f3fe6080604052600436106101235760003560e01c8063b0d691fe116100a0578063e9ae5c5311610064578063e9ae5c531461040f578063ea5f61d014610422578063eab77e1714610442578063f2dc691d14610462578063f698da25146104825761012a565b8063b0d691fe14610340578063b875d5d814610363578063d03c7914146103af578063d691c964146103cf578063d828435d146103ef5761012a565b80636a5e1515116100e75780636a5e1515146102b757806385571368146102ca5780639517e29f146102f85780639cfd7cff1461030b578063a71763a81461032d5761012a565b80630a664dba146101d4578063112d3a7d146102185780631626ba7e1461024857806319822f7c14610281578063540fb4f9146102a25761012a565b3661012a57005b600036606060003560e01c63bc197c81811463f23a6e6182141763150b7a028214171561015b57806020526020603cf35b5033600090815260056020908152604080832054600683528184206001600160e01b031985351680865293529083205491926001600160a01b039182169290911690806101a88484610497565b915091506101b68888610555565b95506101c484848484610669565b5050505050915050805190602001f35b3480156101e057600080fd5b50336000908152600560205260409020546001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561022457600080fd5b506102386102333660046139e3565b6106ec565b604051901515815260200161020f565b34801561025457600080fd5b50610268610263366004613a3e565b610749565b6040516001600160e01b0319909116815260200161020f565b61029461028f366004613a89565b6109de565b60405190815260200161020f565b6102b56102b0366004613b38565b610af2565b005b6102b56102c5366004613c1e565b610b3f565b3480156102d657600080fd5b506102ea6102e5366004613c5f565b610ba0565b60405161020f929190613c8b565b6102b56103063660046139e3565b610bbc565b34801561031757600080fd5b50610320610d61565b60405161020f9190613d3e565b6102b561033b3660046139e3565b610df3565b34801561034c57600080fd5b506f71727de22e5e9d8baf0edac6f37da0326101fb565b34801561036f57600080fd5b506101fb61037e366004613d67565b3360009081526006602090815260408083206001600160e01b0319909416835292905220546001600160a01b031690565b3480156103bb57600080fd5b506102386103ca366004613d84565b610f5f565b6103e26103dd366004613a3e565b611007565b60405161020f9190613d9d565b3480156103fb57600080fd5b5061029461040a366004613e01565b6110d3565b6102b561041d366004613a3e565b611173565b34801561042e57600080fd5b506102ea61043d366004613c5f565b611518565b34801561044e57600080fd5b506102b561045d366004613e4b565b611542565b34801561046e57600080fd5b5061023861047d366004613d84565b6115b1565b34801561048e57600080fd5b50610294611600565b6060806001600160a01b03841615610517576104fe338560006104b8611659565b346000366040516024016104cf9493929190613eda565b60408051601f198184030181529190526020810180516001600160e01b031663d68f602560e01b179052611665565b9150818060200190518101906105149190613fce565b91505b6001600160a01b0383161561054e57610535338460006104b8611659565b90508080602001905181019061054b9190613fce565b90505b9250929050565b3360009081526004602090815260408083206001600160e01b0319843516845290915290208054606091906001600160a01b03811690600160a01b900460f81b816105c657604051632464e76d60e11b81526001600160e01b03196000351660048201526024015b60405180910390fd5b6105d481607f60f91b61170e565b156106185761060e338388886105e8611659565b6040516020016105fa93929190614002565b604051602081830303815290604052611720565b9350505050610663565b61062381600061170e565b1561065f5761060e338360008989610639611659565b60405160200161064b93929190614002565b604051602081830303815290604052611665565b5050505b92915050565b6001600160a01b038416156106bf576106bf33856000856040516024016106909190613d3e565b60408051601f198184030181529190526020810180516001600160e01b0316630b9dfbed60e11b1790526117e0565b6001600160a01b038316156106e6576106e633846000846040516024016106909190613d3e565b50505050565b600060018503610706576106ff8461187f565b9050610741565b60028503610717576106ff8461188d565b6003850361072a576106ff8484846118a6565b6004850361073d576106ff8484846118f3565b5060005b949350505050565b600033821580156107c15750604051635ae6bd3760e01b8152600481018690526001600160a01b03821690635ae6bd3790602401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be9190614028565b15155b156107d65750630b135d3f60e11b90506109d7565b60006107e56014828688614041565b6107ee9161406b565b60601c905080158061080657506108048161187f565b155b1561095c5760006108d1836001600160a01b031663f698da256040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108729190614028565b60408051602081018b90527f60b3cbf8b4a223d68d641b3b6ddf9a298e7f33710cf3d3a9d1146b5a6150fbca910160408051601f198184030181528282528051602091820120908301520160405160208183030381529060405261192e565b805160208201209091506001600160a01b03841663934f3a1182846108f98a6014818e614041565b6040518563ffffffff1660e01b815260040161091894939291906140a0565b60006040518083038186803b15801561093057600080fd5b505afa158015610944573d6000803e3d6000fd5b50630b135d3f60e11b97506109d79650505050505050565b60006109bb338361096b611659565b8a6109798a6014818e614041565b60405160240161098c9493929190613eda565b60408051601f198184030181529190526020810180516001600160e01b0316637aa8f17760e11b179052611720565b9050808060200190518101906109d191906140d7565b93505050505b9392505050565b60006f71727de22e5e9d8baf0edac6f37da0326109f9611659565b6001600160a01b031614610a2057604051635629665f60e11b815260040160405180910390fd5b6020840135606081901c90811580610a3e5750610a3c8261187f565b155b15610a5357610a4c866119a8565b9250610ab8565b6000610a9e338460008a8a604051602401610a6f929190614139565b60408051601f198184030181529190526020810180516001600160e01b0316639700320360e01b179052611665565b905080806020019051810190610ab49190614028565b9350505b8315610ae957610ae9336f71727de22e5e9d8baf0edac6f37da03286604051806020016040528060008152506117e0565b50509392505050565b610b24610b026020830183614238565b610b0f6020840184614255565b610b1f606086016040870161429e565b611a4e565b610b348989898989898989611afc565b505050505050505050565b610b4a600233611d3f565b8060005b818110156106e65736848483818110610b6957610b696142b9565b9050602002810190610b7b91906142cf565b9050610b9733610b8e6020840184614238565b60029190611dba565b50600101610b4e565b60606000610bb16002338686611eaf565b915091509250929050565b3360009081526005602090815260408083205460068352818420639517e29f60e01b80865293529083205491926001600160a01b03918216929091169080610c048484610497565b91509150610c1f6f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b0316610c30611659565b6001600160a01b03161480610c5d5750610c48611659565b6001600160a01b0316336001600160a01b0316145b610c7a57604051635629665f60e11b815260040160405180910390fd5b606060018a03610c9657610c8f898989612065565b9050610cfb565b60028a03610ca957610c8f8989896120c1565b60038a03610cbc57610c8f89898961212b565b60048a03610ccf57610c8f89898961226c565b89610cdf57610c8f8989896123eb565b60405163041c38b360e41b8152600481018b90526024016105bd565b600054604051610d549133916001600160a01b0390911690610d25908e908e9087906024016142ef565b60408051601f198184030181529190526020810180516001600160e01b0316639517e29f60e01b179052612573565b50610b3484848484610669565b60606000336001600160a01b031663ffa1ad746040518163ffffffff1660e01b8152600401600060405180830381865afa158015610da3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610dcb9190810190614319565b905080604051602001610dde9190614361565b60405160208183030381529060405291505090565b33600090815260056020908152604080832054600683528184206314e2ec7560e31b80865293529083205491926001600160a01b03918216929091169080610e3b8484610497565b91509150610e566f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b0316610e67611659565b6001600160a01b03161480610e945750610e7f611659565b6001600160a01b0316336001600160a01b0316145b610eb157604051635629665f60e11b815260040160405180910390fd5b606060018a03610ecd57610ec689898961260c565b9050610f06565b60028a03610ee057610ec6898989612635565b60038a03610ef357610ec6898989612662565b60048a03610cdf57610ec68989896126b0565b600054604051610d549133916001600160a01b0390911690610f30908e908e9087906024016142ef565b60408051601f198184030181529190526020810180516001600160e01b0316637827252560e01b179052612768565b600081600881901b610f7582600160f81b61170e565b15610f835760019250610fc6565b610f8e82600061170e565b15610f9c5760019250610fc6565b610fae826001600160f81b031961170e565b15610fbc5760019250610fc6565b5060009392505050565b828015610fd95750610fd981600061170e565b15610fe5575050919050565b828015610ffb5750610ffb81600160f81b61170e565b15610fbc575050919050565b6060611019611014611659565b61188d565b61104a57611025611659565b604051635c93ff2f60e11b81526001600160a01b0390911660048201526024016105bd565b33600090815260056020908152604080832054600683528184206335a4725960e21b80865293529083205491926001600160a01b039182169290911690806110928484610497565b915091503360026110a3828261281e565b8a600881901b6110b581838e8e6128a9565b9950505050506110c784848484610669565b50505050509392505050565b6000602082901b640100000000600160c01b03166f71727de22e5e9d8baf0edac6f37da032604051631aab3f0d60e11b81526001600160a01b0386811660048301526001600160c01b038416602483015291909116906335567e1a90604401602060405180830381865afa15801561114f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107419190614028565b336000908152600560209081526040808320546006835281842063e9ae5c5360e01b80865293529083205491926001600160a01b039182169290911690806111bb8484610497565b915091506111d66f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b03166111e7611659565b6001600160a01b0316148061121457506111ff611659565b6001600160a01b0316336001600160a01b0316145b61123157604051635629665f60e11b815260040160405180910390fd5b87600881901b3361124382600061170e565b156113a65761125683600160f81b61170e565b156112775789358a01602081019035611270838383612c65565b50506114ff565b61128283600061170e565b156112ea576000803660006112978e8e612cbc565b93509350935093506112e185858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117e092505050565b505050506114ff565b6112fc836001600160f81b031961170e565b156113815760006113106014828c8e614041565b6113199161406b565b60601c90503660008c8c601490809261133493929190614041565b91509150611379848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061257392505050565b5050506114ff565b604051632e5bf3f960e21b81526001600160f81b0319841660048201526024016105bd565b6113b482600160f81b61170e565b156114da576113c783600160f81b61170e565b156113e15789358a01602081019035611270838383612d0d565b6113ec83600061170e565b1561144b576000803660006114018e8e612cbc565b93509350935093506112e185858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612d6492505050565b61145d836001600160f81b031961170e565b156113815760006114716014828c8e614041565b61147a9161406b565b60601c90503660008c8c601490809261149593929190614041565b91509150611379848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061276892505050565b6040516308c3ee0360e11b81526001600160f81b0319831660048201526024016105bd565b50505061150e84848484610669565b5050505050505050565b33600090815260036020526040812060609190611536818686612e1a565b92509250509250929050565b6f71727de22e5e9d8baf0edac6f37da03261155b611659565b6001600160a01b031614806115885750611573611659565b6001600160a01b0316336001600160a01b0316145b6115a557604051635629665f60e11b815260040160405180910390fd5b6106e684848484611a4e565b6000600182036115c357506001919050565b600282036115d357506001919050565b600382036115e357506001919050565b600482036115f357506001919050565b506000919050565b919050565b604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b60131936013560601c90565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b815260040161169c94939291906143a7565b6000604051808303816000875af11580156116bb573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526116e391908101906143f2565b925090508061170557604051632b3f6d1160e21b815260040160405180910390fd5b50949350505050565b6001600160f81b031990811691161490565b60606000838360405160240161173792919061443f565b60408051601f198184030181529181526020820180516001600160e01b0316636a22165760e01b17905260008054915192935091611783916001600160a01b031690849060240161443f565b60408051601f19818403018152919052602080820180516001600160e01b031663b4faba0960e01b17815282519293509091600091895afa5060203d036040519350808401604052806020853e50600051610ae957825160208401fd5b60405163468721a760e01b81526000906001600160a01b0386169063468721a7906118159087908790879087906004016143a7565b6020604051808303816000875af1158015611834573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118589190614463565b90508061187857604051632b3f6d1160e21b815260040160405180910390fd5b5050505050565b600061066360023384612fb8565b3360009081526003602052604081206109d78184612ffc565b6000806118b583850185613d67565b3360009081526004602090815260408083206001600160e01b0319909416835292905220546001600160a01b03908116908616149150509392505050565b600080806119038486018661448d565b9150915060006119138383613036565b6001600160a01b039081169088161493505050509392505050565b6060601960f81b600160f81b85858560405160200161194e9291906144b9565b60408051808303601f190181529082905280516020918201206001600160f81b0319958616918301919091529290931660218401526022830152604282015260620160405160208183030381529060405290509392505050565b6000806000803660006119ba876130ce565b8451602086012060405163934f3a1160e01b8152959a5093985091965094509250339163934f3a11916119f5918990879087906004016140a0565b60006040518083038186803b158015611a0d57600080fd5b505afa925050508015611a1e575060015b611a3557611a2e600184866132e3565b9550611a44565b611a41600084866132e3565b95505b5050505050919050565b3360008181526001602052604080822080546001600160a01b0319166001600160a01b03891617905551611ac092918791611a91908690899089906024016144df565b60408051601f198184030181529190526020810180516001600160e01b031663f05c04e160e01b1790526117e0565b6040516001600160a01b0385169033907f9452c8fb077c3ea8f28a77c87488af657b1e44d010ad9a5992d73870da040e9490600090a350505050565b3360009081527fe90b7bceb6e7df5418fb78d8ee546e97c83a08bbccc01a0644d599ccd2a7c2e0602052604090205487906001600160a01b0316611ba957611b45600233611d3f565b60005b81811015611ba357368a8a83818110611b6357611b636142b9565b9050602002810190611b7591906142cf565b9050611b99611b876020830183614238565b611b94602084018461453a565b612065565b5050600101611b48565b50611bca565b8015611bca5760405163d8e3ed1b60e01b81523360048201526024016105bd565b336000908152600360205260409020611be28161331b565b86915060005b82811015611c435736898983818110611c0357611c036142b9565b9050602002810190611c1591906142cf565b9050611c39611c276020830183614238565b611c34602084018461453a565b6120c1565b5050600101611be8565b5084915060005b82811015611ca55736878783818110611c6557611c656142b9565b9050602002810190611c7791906142cf565b9050611c9b611c896020830183614238565b611c96602084018461453a565b61212b565b5050600101611c4a565b5082915060005b82811015611d075736858583818110611cc757611cc76142b9565b9050602002810190611cd991906142cf565b9050611cfd611ceb6020830183614238565b611cf8602084018461453a565b61226c565b5050600101611cac565b5060405133907ff48581d8a62b775b74f2fb67f1d5806a9a356fbcc598040ab3071d3e37af40c290600090a250505050505050505050565b60016000908152602083815260408083206001600160a01b0380861685529252909120541615611d82576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602093845260408082206001600160a01b0394909416825292909352912080546001600160a01b0319169091179055565b6001600160a01b0381161580611dd957506001600160a01b0381166001145b15611e0257604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b0381811660009081526020858152604080832086851684529091529020541615611e5157604051631034f46960e21b81526001600160a01b03821660048201526024016105bd565b60016000908152602084815260408083206001600160a01b039586168085528184528285208054968816808752988552838620918652908452919093208054949095166001600160a01b031994851617909455528154169091179055565b606060006001600160a01b038416600114801590611ed55750611ed3868686612fb8565b155b15611efe57604051637c84ecfb60e01b81526001600160a01b03851660048201526024016105bd565b82600003611f1f5760405163f725081760e01b815260040160405180910390fd5b826001600160401b03811115611f3757611f37613f0c565b604051908082528060200260200182016040528015611f60578160200160208202803683370190505b506001600160a01b038086166000908152602089815260408083208a85168452909152812054929450911691505b6001600160a01b03821615801590611fb057506001600160a01b038216600114155b8015611fbb57508381105b156120205781838281518110611fd357611fd36142b9565b6001600160a01b039283166020918202929092018101919091529281166000908152888452604080822089841683529094529290922054909116908061201881614596565b915050611f8e565b6001600160a01b038216600114612058578261203d6001836145af565b8151811061204d5761204d6142b9565b602002602001015191505b8083525094509492505050565b6060836001612074828261281e565b61208060023388611dba565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929998505050505050505050565b60608360026120d0828261281e565b3360009081526003602052604090206120e98188613378565b85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929a9950505050505050505050565b606083600361213a828261281e565b6000808061214a87890189614613565b919450925090506001600160e01b031983166306d61fe760e41b148061218057506001600160e01b03198316638a91b0e360e01b145b156121aa576040516379bd117b60e01b81526001600160e01b0319841660048201526024016105bd565b3360009081526004602090815260408083206001600160e01b0319871684529091529020546001600160a01b031615612202576040516374420d1560e01b81526001600160e01b0319841660048201526024016105bd565b3360009081526004602090815260408083206001600160e01b031990961683529490529290922080546001600160a01b038a166001600160a01b031960f89490941c600160a01b02939093166001600160a81b031990911617919091179055925050509392505050565b606083600461227b828261281e565b6000808061228b87890189614681565b919450925090506000808460018111156122a7576122a76146af565b1480156122bc57506001600160e01b03198316155b156123325750336000908152600560205260409020546001600160a01b031680156123055760405163741cbe0360e01b81526001600160a01b03821660048201526024016105bd565b33600090815260056020526040902080546001600160a01b0319166001600160a01b038c161790556123de565b6001846001811115612346576123466146af565b036123c5576001600160a01b0381161561237e5760405163741cbe0360e01b81526001600160a01b03821660048201526024016105bd565b503360009081526006602090815260408083206001600160e01b031986168452909152902080546001600160a01b038b81166001600160a01b0319831617909255166123de565b604051635691922f60e01b815260040160405180910390fd5b5098975050505050505050565b606082358301602081810191359085810135860180820191903590604088013588019081019035848381146124335760405163b4fa3fb360e01b815260040160405180910390fd5b60005b8181101561252c576000888883818110612452576124526142b9565b905060200201359050600181036124915761248b8d888885818110612479576124796142b9565b9050602002810190611b94919061453a565b50612523565b600281036124c15761248b8d8888858181106124af576124af6142b9565b9050602002810190611c34919061453a565b600381036124f15761248b8d8888858181106124df576124df6142b9565b9050602002810190611c96919061453a565b60048103612523576125218d88888581811061250f5761250f6142b9565b9050602002810190611cf8919061453a565b505b50600101612436565b5082828080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929e9d5050505050505050505050505050565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906125a9908690859087906001906004016143a7565b6020604051808303816000875af11580156125c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125ec9190614463565b9050806106e657604051632b3f6d1160e21b815260040160405180910390fd5b6060600061261c838501856146c5565b9250905061262d600233838861344e565b509392505050565b336000908152600360205260408120606091612653848601866146c5565b93509050610ae9828288613545565b606060006126728385018561470a565b3360009081526004602090815260408083206001600160e01b031990951683529390529190912080546001600160a01b031916905595945050505050565b60606000806126c184860186614681565b9450909250905060008260018111156126dc576126dc6146af565b1480156126f157506001600160e01b03198116155b156127185733600090815260056020526040902080546001600160a01b0319169055610ae9565b600182600181111561272c5761272c6146af565b036123c5573360009081526006602090815260408083206001600160e01b031985168452909152902080546001600160a01b0319169055610ae9565b60405163468721a760e01b81526000906001600160a01b0385169063468721a79061279e908690859087906001906004016143a7565b6020604051808303816000875af11580156127bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127e19190614463565b9050806106e657604080516001600160a01b0386168152600060208201526000805160206149c9833981519152910160405180910390a150505050565b336000908152600160205260409020546001600160a01b031680156128a45760405163529562a160e01b81523360048201526001600160a01b0384811660248301526044820184905282169063529562a19060640160006040518083038186803b15801561288b57600080fd5b505afa15801561289f573d6000803e3d6000fd5b505050505b505050565b60606128b685600061170e565b15612aac576128c984600160f81b61170e565b156128ec57823583016020810190356128e333838361361a565b92505050610741565b6128f784600061170e565b156129ab5760008036600061290c8787612cbc565b6040805160018082528183019092529498509296509094509250816020015b606081526020019060019003908161292b57905050945061298433858585858080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061166592505050565b85600081518110612997576129976142b9565b602002602001018190525050505050610741565b6129bd846001600160f81b031961170e565b15612a875760006129d16014828587614041565b6129da9161406b565b60601c90503660006129ef8560148189614041565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612a09579050509350612a61338484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061369392505050565b84600081518110612a7457612a746142b9565b6020026020010181905250505050610741565b604051632e5bf3f960e21b81526001600160f81b0319851660048201526024016105bd565b612aba85600160f81b61170e565b15612c4057612acd84600160f81b61170e565b15612af25782358301602081019035612ae7338383613734565b935061074192505050565b612afd84600061170e565b15612b8a57600080366000612b128787612cbc565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612b3157905050945061298433858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506137b692505050565b612b9c846001600160f81b031961170e565b15612a87576000612bb06014828587614041565b612bb99161406b565b60601c9050366000612bce8560148189614041565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612be8579050509350612a61338484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061387692505050565b6040516308c3ee0360e11b81526001600160f81b0319861660048201526024016105bd565b6000546040516128a49185916001600160a01b0390911690612c8d9086908690602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316633f707e6b60e01b179052612573565b6000803681612cce6014828789614041565b612cd79161406b565b60601c9350612cea603460148789614041565b612cf3916147d3565b9250612d028560348189614041565b949793965094505050565b6000546040516128a49185916001600160a01b0390911690612d359086908690602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316632864481160e11b179052612768565b60405163468721a760e01b81526000906001600160a01b0386169063468721a790612d999087908790879087906004016143a7565b6020604051808303816000875af1158015612db8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ddc9190614463565b90508061187857604080516001600160a01b0387168152600060208201526000805160206149c9833981519152910160405180910390a15050505050565b606060006001600160a01b038416600114801590612e3f5750612e3d8585612ffc565b155b15612e6857604051637c84ecfb60e01b81526001600160a01b03851660048201526024016105bd565b82600003612e895760405163f725081760e01b815260040160405180910390fd5b826001600160401b03811115612ea157612ea1613f0c565b604051908082528060200260200182016040528015612eca578160200160208202803683370190505b506001600160a01b03808616600090815260208890526040812054929450911691505b6001600160a01b03821615801590612f0f57506001600160a01b038216600114155b8015612f1a57508381105b15612f745781838281518110612f3257612f326142b9565b6001600160a01b039283166020918202929092018101919091529281166000908152928790526040909220549091169080612f6c81614596565b915050612eed565b6001600160a01b038216600114612fac5782612f916001836145af565b81518110612fa157612fa16142b9565b602002602001015191505b80835250935093915050565b600060016001600160a01b038316148015906107415750506001600160a01b0390811660009081526020938452604080822093831682529290935291205416151590565b600060016001600160a01b038316148015906109d75750506001600160a01b03908116600090815260209290925260409091205416151590565b60008083600181111561304b5761304b6146af565b14801561306057506001600160e01b03198216155b156130805750336000908152600560205260409020546001600160a01b03165b6001836001811115613094576130946146af565b0361066357503360009081526006602090815260408083206001600160e01b0319851684529091529020546001600160a01b031692915050565b6060600080368181816130e561010089018961453a565b90925090506130f8600660008385614041565b613101916147f1565b60d01c9550613114600c60068385614041565b61311d916147f1565b60d01c945061312f81600c8185614041565b9350935050506000604051806101c001604052807f84aa190356f56b8c87825f54884392a9907c23ee0f8e1ea86336b763faf021bd60001b8152602001336001600160a01b0316815260200188602001358152602001888060400190613195919061453a565b6040516131a392919061481f565b60405190819003902081526020016131be60608a018a61453a565b6040516131cc92919061481f565b604051809103902081526020016131e289613936565b81526020016131f08961394b565b81526020018860a0013581526020016132088961395b565b815260200161321689613970565b815260200161322860e08a018a61453a565b60405161323692919061481f565b604051809103902081526020018665ffffffffffff1681526020018565ffffffffffff1681526020016132766f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031690526101c08120909150601960f81b600160f81b61329b611600565b6040516001600160f81b031993841660208201529290911660218301526022820152604281018290526062016040516020818303038152906040529650505091939590929450565b600060d08265ffffffffffff16901b60a08465ffffffffffff16901b8561330b57600061330e565b60015b60ff161717949350505050565b60016000908152602082905260409020546001600160a01b031615613353576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602092909252604090912080546001600160a01b0319169091179055565b6001600160a01b038116158061339757506001600160a01b0381166001145b156133c057604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b03818116600090815260208490526040902054161561340457604051631034f46960e21b81526001600160a01b03821660048201526024016105bd565b60016000818152602093909352604080842080546001600160a01b039485168087529286208054959091166001600160a01b03199586161790559190935280549091169091179055565b6001600160a01b038116158061346d57506001600160a01b0381166001145b1561349657604051637c84ecfb60e01b81526001600160a01b03831660048201526024016105bd565b6001600160a01b0382811660009081526020868152604080832087851684529091529020548116908216146134e957604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b039081166000908152602085815260408083209584168084528683528184208054968616855297835281842090845282529091208054939092166001600160a01b031993841617909155919091528154169055565b6001600160a01b038116158061356457506001600160a01b0381166001145b1561358d57604051637c84ecfb60e01b81526001600160a01b03831660048201526024016105bd565b6001600160a01b038281166000908152602085905260409020548116908216146135d557604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b0390811660008181526020949094526040808520805494841686529085208054949093166001600160a01b0319948516179092559092528154169055565b60008054604051606092916136749187916001600160a01b0316906136459088908890602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316636108557360e01b179052613693565b90508080602001905181019061368a91906148dc565b95945050505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016136cb94939291906143a7565b6000604051808303816000875af11580156136ea573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261371291908101906143f2565b925090508061262d57604051632b3f6d1160e21b815260040160405180910390fd5b60608060006137938660008054906101000a90046001600160a01b03168787604051602401613764929190614728565b60408051601f198184030181529190526020810180516001600160e01b0316639abb6e1760e01b179052613876565b9050808060200190518101906137a99190614910565b9097909650945050505050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b81526004016137ed94939291906143a7565b6000604051808303816000875af115801561380c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261383491908101906143f2565b925090508061170557604080516001600160a01b0388168152600060208201526000805160206149c9833981519152910160405180910390a150949350505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016138ae94939291906143a7565b6000604051808303816000875af11580156138cd573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526138f591908101906143f2565b925090508061262d57604080516001600160a01b0387168152600060208201526000805160206149c9833981519152910160405180910390a1509392505050565b60006001600160801b03608083013516610663565b6000610663826080013560801c90565b60006001600160801b0360c083013516610663565b600060c082013560801c610663565b6001600160a01b038116811461399457600080fd5b50565b80356115fb8161397f565b60008083601f8401126139b457600080fd5b5081356001600160401b038111156139cb57600080fd5b60208301915083602082850101111561054e57600080fd5b600080600080606085870312156139f957600080fd5b843593506020850135613a0b8161397f565b925060408501356001600160401b03811115613a2657600080fd5b613a32878288016139a2565b95989497509550505050565b600080600060408486031215613a5357600080fd5b8335925060208401356001600160401b03811115613a7057600080fd5b613a7c868287016139a2565b9497909650939450505050565b600080600060608486031215613a9e57600080fd5b83356001600160401b03811115613ab457600080fd5b84016101208187031215613ac757600080fd5b95602085013595506040909401359392505050565b60008083601f840112613aee57600080fd5b5081356001600160401b03811115613b0557600080fd5b6020830191508360208260051b850101111561054e57600080fd5b600060608284031215613b3257600080fd5b50919050565b600080600080600080600080600060a08a8c031215613b5657600080fd5b89356001600160401b0380821115613b6d57600080fd5b613b798d838e01613adc565b909b50995060208c0135915080821115613b9257600080fd5b613b9e8d838e01613adc565b909950975060408c0135915080821115613bb757600080fd5b613bc38d838e01613adc565b909750955060608c0135915080821115613bdc57600080fd5b613be88d838e01613adc565b909550935060808c0135915080821115613c0157600080fd5b50613c0e8c828d01613b20565b9150509295985092959850929598565b60008060208385031215613c3157600080fd5b82356001600160401b03811115613c4757600080fd5b613c5385828601613adc565b90969095509350505050565b60008060408385031215613c7257600080fd5b8235613c7d8161397f565b946020939093013593505050565b604080825283519082018190526000906020906060840190828701845b82811015613ccd5781516001600160a01b031684529284019290840190600101613ca8565b5050506001600160a01b039490941660209390930192909252509092915050565b60005b83811015613d09578181015183820152602001613cf1565b50506000910152565b60008151808452613d2a816020860160208601613cee565b601f01601f19169290920160200192915050565b6020815260006109d76020830184613d12565b6001600160e01b03198116811461399457600080fd5b600060208284031215613d7957600080fd5b81356109d781613d51565b600060208284031215613d9657600080fd5b5035919050565b600060208083016020845280855180835260408601915060408160051b87010192506020870160005b82811015613df457603f19888603018452613de2858351613d12565b94509285019290850190600101613dc6565b5092979650505050505050565b60008060408385031215613e1457600080fd5b8235613e1f8161397f565b91506020830135613e2f8161397f565b809150509250929050565b803560ff811681146115fb57600080fd5b60008060008060608587031215613e6157600080fd5b8435613e6c8161397f565b935060208501356001600160401b03811115613e8757600080fd5b613e9387828801613adc565b9094509250613ea6905060408601613e3a565b905092959194509250565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60018060a01b0385168152836020820152606060408201526000613f02606083018486613eb1565b9695505050505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715613f4a57613f4a613f0c565b604052919050565b60006001600160401b03821115613f6b57613f6b613f0c565b50601f01601f191660200190565b6000613f8c613f8784613f52565b613f22565b9050828152838383011115613fa057600080fd5b6109d7836020830184613cee565b600082601f830112613fbf57600080fd5b6109d783835160208501613f79565b600060208284031215613fe057600080fd5b81516001600160401b03811115613ff657600080fd5b61074184828501613fae565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60006020828403121561403a57600080fd5b5051919050565b6000808585111561405157600080fd5b8386111561405e57600080fd5b5050820193919092039150565b6bffffffffffffffffffffffff1981358181169160148510156140985780818660140360031b1b83161692505b505092915050565b8481526060602082015260006140b96060830186613d12565b82810360408401526140cc818587613eb1565b979650505050505050565b6000602082840312156140e957600080fd5b81516109d781613d51565b6000808335601e1984360301811261410b57600080fd5b83016020810192503590506001600160401b0381111561412a57600080fd5b80360382131561054e57600080fd5b6040815261415a6040820161414d85613997565b6001600160a01b03169052565b60208301356060820152600061417360408501856140f4565b61012080608086015261418b61016086018385613eb1565b925061419a60608801886140f4565b9250603f19808786030160a08801526141b4858584613eb1565b9450608089013560c088015260a089013560e0880152610100935060c0890135848801526141e560e08a018a6140f4565b92508188870301848901526141fb868483613eb1565b95505061420a848a018a6140f4565b9450925080878603016101408801525050614226838383613eb1565b93505050508260208301529392505050565b60006020828403121561424a57600080fd5b81356109d78161397f565b6000808335601e1984360301811261426c57600080fd5b8301803591506001600160401b0382111561428657600080fd5b6020019150600581901b360382131561054e57600080fd5b6000602082840312156142b057600080fd5b6109d782613e3a565b634e487b7160e01b600052603260045260246000fd5b60008235603e198336030181126142e557600080fd5b9190910192915050565b8381526001600160a01b038316602082015260606040820181905260009061368a90830184613d12565b60006020828403121561432b57600080fd5b81516001600160401b0381111561434157600080fd5b8201601f8101841361435257600080fd5b61074184825160208401613f79565b64736166652d60d81b815260008251614381816005850160208701613cee565b6e2e657263373537392e76302e302e3160881b6005939091019283015250601401919050565b60018060a01b03851681528360208201526080604082015260006143ce6080830185613d12565b905060ff8316606083015295945050505050565b805180151581146115fb57600080fd5b6000806040838503121561440557600080fd5b61440e836143e2565b915060208301516001600160401b0381111561442957600080fd5b61443585828601613fae565b9150509250929050565b6001600160a01b038316815260406020820181905260009061074190830184613d12565b60006020828403121561447557600080fd5b6109d7826143e2565b8035600281106115fb57600080fd5b600080604083850312156144a057600080fd5b6144a98361447e565b91506020830135613e2f81613d51565b828152600082516144d1816020850160208701613cee565b919091016020019392505050565b60ff8416815260406020808301829052908201839052600090849060608401835b8681101561452e5783356145138161397f565b6001600160a01b031682529282019290820190600101614500565b50979650505050505050565b6000808335601e1984360301811261455157600080fd5b8301803591506001600160401b0382111561456b57600080fd5b60200191503681900382131561054e57600080fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016145a8576145a8614580565b5060010190565b8181038181111561066357610663614580565b600082601f8301126145d357600080fd5b81356145e1613f8782613f52565b8181528460208386010111156145f657600080fd5b816020850160208301376000918101602001919091529392505050565b60008060006060848603121561462857600080fd5b833561463381613d51565b925060208401356001600160f81b03198116811461465057600080fd5b915060408401356001600160401b0381111561466b57600080fd5b614677868287016145c2565b9150509250925092565b60008060006060848603121561469657600080fd5b61469f8461447e565b9250602084013561465081613d51565b634e487b7160e01b600052602160045260246000fd5b600080604083850312156146d857600080fd5b82356146e38161397f565b915060208301356001600160401b038111156146fe57600080fd5b614435858286016145c2565b6000806040838503121561471d57600080fd5b82356146e381613d51565b60208082528181018390526000906040808401600586901b850182018785805b898110156147c457888403603f190185528235368c9003605e1901811261476d578283fd5b8b016060813561477c8161397f565b6001600160a01b03168652818901358987015261479b888301836140f4565b925081898801526147af8288018483613eb1565b978a0197965050509287019250600101614748565b50919998505050505050505050565b8035602083101561066357600019602084900360031b1b1692915050565b6001600160d01b031981358181169160068510156140985760069490940360031b84901b1690921692915050565b8183823760009101908152919050565b60006001600160401b0382111561484857614848613f0c565b5060051b60200190565b600082601f83011261486357600080fd5b81516020614873613f878361482f565b82815260059290921b8401810191818101908684111561489257600080fd5b8286015b848110156148d15780516001600160401b038111156148b55760008081fd5b6148c38986838b0101613fae565b845250918301918301614896565b509695505050505050565b6000602082840312156148ee57600080fd5b81516001600160401b0381111561490457600080fd5b61074184828501614852565b6000806040838503121561492357600080fd5b82516001600160401b038082111561493a57600080fd5b818501915085601f83011261494e57600080fd5b8151602061495e613f878361482f565b82815260059290921b8401810191818101908984111561497d57600080fd5b948201945b838610156149a257614993866143e2565b82529482019490820190614982565b918801519196509093505050808211156149bb57600080fd5b506144358582860161485256feb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792aca26469706673582212203bf73a2c2062b81b2af0d1e3cda1afef579f700fd7d2e530b6b4eada00b17f5f64736f6c634300081900336080604052348015600f57600080fd5b506109b98061001f6000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c80636a2216571161005b5780636a221657146100df57806378272525146100f25780639517e29f146101055780639abb6e171461011857600080fd5b80633f707e6b1461008257806350c890221461009757806361085573146100bf575b600080fd5b6100956100903660046105c9565b610139565b005b6100aa6100a53660046105c9565b6101a3565b60405190151581526020015b60405180910390f35b6100d26100cd3660046105c9565b610212565b6040516100b691906106c6565b6100956100ed366004610712565b6102cc565b6100956101003660046107d4565b6102ef565b6100956101133660046107d4565b610398565b61012b6101263660046105c9565b610437565b6040516100b692919061085b565b8060005b8181101561019d5736848483818110610158576101586108b5565b905060200281019061016a91906108cb565b905061019361017c60208301836108eb565b602083013561018e6040850185610906565b610561565b505060010161013d565b50505050565b600081815b8181101561020a57368585838181106101c3576101c36108b5565b90506020028101906101d591906108cb565b90506101fe6101e760208301836108eb565b60208301356101f96040850185610906565b610597565b509350506001016101a8565b505092915050565b6060818067ffffffffffffffff81111561022e5761022e6106fc565b60405190808252806020026020018201604052801561026157816020015b606081526020019060019003908161024c5790505b50915060005b8181101561020a5736858583818110610282576102826108b5565b905060200281019061029491906108cb565b90506102a661017c60208301836108eb565b8483815181106102b8576102b86108b5565b602090810291909101015250600101610267565b604051600080835160208501865afa3d6000833e80156102ea573d82f35b503d81fd5b604051638a91b0e360e01b81526001600160a01b03841690638a91b0e39061031d9085908590600401610954565b600060405180830381600087803b15801561033757600080fd5b505af115801561034b573d6000803e3d6000fd5b5050604080518781526001600160a01b03871660208201527f341347516a9de374859dfda710fa4828b2d48cb57d4fbe4c1149612b8e02276e93500190505b60405180910390a150505050565b6040516306d61fe760e41b81526001600160a01b03841690636d61fe70906103c69085908590600401610954565b600060405180830381600087803b1580156103e057600080fd5b505af11580156103f4573d6000803e3d6000fd5b5050604080518781526001600160a01b03871660208201527fd21d0b289f126c4b473ea641963e766833c2f13866e4ff480abd787c100ef123935001905061038a565b606080828067ffffffffffffffff811115610454576104546106fc565b60405190808252806020026020018201604052801561048757816020015b60608152602001906001900390816104725790505b5091508067ffffffffffffffff8111156104a3576104a36106fc565b6040519080825280602002602001820160405280156104cc578160200160208202803683370190505b50925060005b8181101561055857368686838181106104ed576104ed6108b5565b90506020028101906104ff91906108cb565b90506105116101e760208301836108eb565b868481518110610523576105236108b5565b6020026020010186858151811061053c5761053c6108b5565b60209081029190910101919091529015159052506001016104d2565b50509250929050565b60405181838237600038838387895af161057e573d6000823e3d81fd5b3d8152602081013d6000823e3d01604052949350505050565b604051600090828482376000388483888a5af11591503d8152602081013d6000823e3d81016040525094509492505050565b600080602083850312156105dc57600080fd5b823567ffffffffffffffff808211156105f457600080fd5b818501915085601f83011261060857600080fd5b81358181111561061757600080fd5b8660208260051b850101111561062c57600080fd5b60209290920196919550909350505050565b600082825180855260208086019550808260051b8401018186016000805b858110156106b857601f1980888603018b5283518051808752845b81811015610692578281018901518882018a01528801610677565b5086810188018590529b87019b601f01909116909401850193509184019160010161065c565b509198975050505050505050565b6020815260006106d9602083018461063e565b9392505050565b80356001600160a01b03811681146106f757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561072557600080fd5b61072e836106e0565b9150602083013567ffffffffffffffff8082111561074b57600080fd5b818501915085601f83011261075f57600080fd5b813581811115610771576107716106fc565b604051601f8201601f19908116603f01168101908382118183101715610799576107996106fc565b816040528281528860208487010111156107b257600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b600080600080606085870312156107ea57600080fd5b843593506107fa602086016106e0565b9250604085013567ffffffffffffffff8082111561081757600080fd5b818701915087601f83011261082b57600080fd5b81358181111561083a57600080fd5b88602082850101111561084c57600080fd5b95989497505060200194505050565b604080825283519082018190526000906020906060840190828701845b82811015610896578151151584529284019290840190600101610878565b50505083810360208501526108ab818661063e565b9695505050505050565b634e487b7160e01b600052603260045260246000fd5b60008235605e198336030181126108e157600080fd5b9190910192915050565b6000602082840312156108fd57600080fd5b6106d9826106e0565b6000808335601e1984360301811261091d57600080fd5b83018035915067ffffffffffffffff82111561093857600080fd5b60200191503681900382131561094d57600080fd5b9250929050565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220ad7ce283b8d54ac3a1566e8281f813acf154a2a620bfebf9c47aa3d94c3648e764736f6c63430008190033",sourceMap:"2103:22088:37:-:0;;;;;;;;;;;;;259:20:44;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;244:4:44;:36;;-1:-1:-1;;;;;;244:36:44;-1:-1:-1;;;;;244:36:44;;;;;;;;;;2103:22088:37;;;;;;;;;;:::o;:::-;;;;;;;",linkReferences:{}},deployedBytecode={object:"0x6080604052600436106101235760003560e01c8063b0d691fe116100a0578063e9ae5c5311610064578063e9ae5c531461040f578063ea5f61d014610422578063eab77e1714610442578063f2dc691d14610462578063f698da25146104825761012a565b8063b0d691fe14610340578063b875d5d814610363578063d03c7914146103af578063d691c964146103cf578063d828435d146103ef5761012a565b80636a5e1515116100e75780636a5e1515146102b757806385571368146102ca5780639517e29f146102f85780639cfd7cff1461030b578063a71763a81461032d5761012a565b80630a664dba146101d4578063112d3a7d146102185780631626ba7e1461024857806319822f7c14610281578063540fb4f9146102a25761012a565b3661012a57005b600036606060003560e01c63bc197c81811463f23a6e6182141763150b7a028214171561015b57806020526020603cf35b5033600090815260056020908152604080832054600683528184206001600160e01b031985351680865293529083205491926001600160a01b039182169290911690806101a88484610497565b915091506101b68888610555565b95506101c484848484610669565b5050505050915050805190602001f35b3480156101e057600080fd5b50336000908152600560205260409020546001600160a01b03165b6040516001600160a01b0390911681526020015b60405180910390f35b34801561022457600080fd5b506102386102333660046139e3565b6106ec565b604051901515815260200161020f565b34801561025457600080fd5b50610268610263366004613a3e565b610749565b6040516001600160e01b0319909116815260200161020f565b61029461028f366004613a89565b6109de565b60405190815260200161020f565b6102b56102b0366004613b38565b610af2565b005b6102b56102c5366004613c1e565b610b3f565b3480156102d657600080fd5b506102ea6102e5366004613c5f565b610ba0565b60405161020f929190613c8b565b6102b56103063660046139e3565b610bbc565b34801561031757600080fd5b50610320610d61565b60405161020f9190613d3e565b6102b561033b3660046139e3565b610df3565b34801561034c57600080fd5b506f71727de22e5e9d8baf0edac6f37da0326101fb565b34801561036f57600080fd5b506101fb61037e366004613d67565b3360009081526006602090815260408083206001600160e01b0319909416835292905220546001600160a01b031690565b3480156103bb57600080fd5b506102386103ca366004613d84565b610f5f565b6103e26103dd366004613a3e565b611007565b60405161020f9190613d9d565b3480156103fb57600080fd5b5061029461040a366004613e01565b6110d3565b6102b561041d366004613a3e565b611173565b34801561042e57600080fd5b506102ea61043d366004613c5f565b611518565b34801561044e57600080fd5b506102b561045d366004613e4b565b611542565b34801561046e57600080fd5b5061023861047d366004613d84565b6115b1565b34801561048e57600080fd5b50610294611600565b6060806001600160a01b03841615610517576104fe338560006104b8611659565b346000366040516024016104cf9493929190613eda565b60408051601f198184030181529190526020810180516001600160e01b031663d68f602560e01b179052611665565b9150818060200190518101906105149190613fce565b91505b6001600160a01b0383161561054e57610535338460006104b8611659565b90508080602001905181019061054b9190613fce565b90505b9250929050565b3360009081526004602090815260408083206001600160e01b0319843516845290915290208054606091906001600160a01b03811690600160a01b900460f81b816105c657604051632464e76d60e11b81526001600160e01b03196000351660048201526024015b60405180910390fd5b6105d481607f60f91b61170e565b156106185761060e338388886105e8611659565b6040516020016105fa93929190614002565b604051602081830303815290604052611720565b9350505050610663565b61062381600061170e565b1561065f5761060e338360008989610639611659565b60405160200161064b93929190614002565b604051602081830303815290604052611665565b5050505b92915050565b6001600160a01b038416156106bf576106bf33856000856040516024016106909190613d3e565b60408051601f198184030181529190526020810180516001600160e01b0316630b9dfbed60e11b1790526117e0565b6001600160a01b038316156106e6576106e633846000846040516024016106909190613d3e565b50505050565b600060018503610706576106ff8461187f565b9050610741565b60028503610717576106ff8461188d565b6003850361072a576106ff8484846118a6565b6004850361073d576106ff8484846118f3565b5060005b949350505050565b600033821580156107c15750604051635ae6bd3760e01b8152600481018690526001600160a01b03821690635ae6bd3790602401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be9190614028565b15155b156107d65750630b135d3f60e11b90506109d7565b60006107e56014828688614041565b6107ee9161406b565b60601c905080158061080657506108048161187f565b155b1561095c5760006108d1836001600160a01b031663f698da256040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108729190614028565b60408051602081018b90527f60b3cbf8b4a223d68d641b3b6ddf9a298e7f33710cf3d3a9d1146b5a6150fbca910160408051601f198184030181528282528051602091820120908301520160405160208183030381529060405261192e565b805160208201209091506001600160a01b03841663934f3a1182846108f98a6014818e614041565b6040518563ffffffff1660e01b815260040161091894939291906140a0565b60006040518083038186803b15801561093057600080fd5b505afa158015610944573d6000803e3d6000fd5b50630b135d3f60e11b97506109d79650505050505050565b60006109bb338361096b611659565b8a6109798a6014818e614041565b60405160240161098c9493929190613eda565b60408051601f198184030181529190526020810180516001600160e01b0316637aa8f17760e11b179052611720565b9050808060200190518101906109d191906140d7565b93505050505b9392505050565b60006f71727de22e5e9d8baf0edac6f37da0326109f9611659565b6001600160a01b031614610a2057604051635629665f60e11b815260040160405180910390fd5b6020840135606081901c90811580610a3e5750610a3c8261187f565b155b15610a5357610a4c866119a8565b9250610ab8565b6000610a9e338460008a8a604051602401610a6f929190614139565b60408051601f198184030181529190526020810180516001600160e01b0316639700320360e01b179052611665565b905080806020019051810190610ab49190614028565b9350505b8315610ae957610ae9336f71727de22e5e9d8baf0edac6f37da03286604051806020016040528060008152506117e0565b50509392505050565b610b24610b026020830183614238565b610b0f6020840184614255565b610b1f606086016040870161429e565b611a4e565b610b348989898989898989611afc565b505050505050505050565b610b4a600233611d3f565b8060005b818110156106e65736848483818110610b6957610b696142b9565b9050602002810190610b7b91906142cf565b9050610b9733610b8e6020840184614238565b60029190611dba565b50600101610b4e565b60606000610bb16002338686611eaf565b915091509250929050565b3360009081526005602090815260408083205460068352818420639517e29f60e01b80865293529083205491926001600160a01b03918216929091169080610c048484610497565b91509150610c1f6f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b0316610c30611659565b6001600160a01b03161480610c5d5750610c48611659565b6001600160a01b0316336001600160a01b0316145b610c7a57604051635629665f60e11b815260040160405180910390fd5b606060018a03610c9657610c8f898989612065565b9050610cfb565b60028a03610ca957610c8f8989896120c1565b60038a03610cbc57610c8f89898961212b565b60048a03610ccf57610c8f89898961226c565b89610cdf57610c8f8989896123eb565b60405163041c38b360e41b8152600481018b90526024016105bd565b600054604051610d549133916001600160a01b0390911690610d25908e908e9087906024016142ef565b60408051601f198184030181529190526020810180516001600160e01b0316639517e29f60e01b179052612573565b50610b3484848484610669565b60606000336001600160a01b031663ffa1ad746040518163ffffffff1660e01b8152600401600060405180830381865afa158015610da3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610dcb9190810190614319565b905080604051602001610dde9190614361565b60405160208183030381529060405291505090565b33600090815260056020908152604080832054600683528184206314e2ec7560e31b80865293529083205491926001600160a01b03918216929091169080610e3b8484610497565b91509150610e566f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b0316610e67611659565b6001600160a01b03161480610e945750610e7f611659565b6001600160a01b0316336001600160a01b0316145b610eb157604051635629665f60e11b815260040160405180910390fd5b606060018a03610ecd57610ec689898961260c565b9050610f06565b60028a03610ee057610ec6898989612635565b60038a03610ef357610ec6898989612662565b60048a03610cdf57610ec68989896126b0565b600054604051610d549133916001600160a01b0390911690610f30908e908e9087906024016142ef565b60408051601f198184030181529190526020810180516001600160e01b0316637827252560e01b179052612768565b600081600881901b610f7582600160f81b61170e565b15610f835760019250610fc6565b610f8e82600061170e565b15610f9c5760019250610fc6565b610fae826001600160f81b031961170e565b15610fbc5760019250610fc6565b5060009392505050565b828015610fd95750610fd981600061170e565b15610fe5575050919050565b828015610ffb5750610ffb81600160f81b61170e565b15610fbc575050919050565b6060611019611014611659565b61188d565b61104a57611025611659565b604051635c93ff2f60e11b81526001600160a01b0390911660048201526024016105bd565b33600090815260056020908152604080832054600683528184206335a4725960e21b80865293529083205491926001600160a01b039182169290911690806110928484610497565b915091503360026110a3828261281e565b8a600881901b6110b581838e8e6128a9565b9950505050506110c784848484610669565b50505050509392505050565b6000602082901b640100000000600160c01b03166f71727de22e5e9d8baf0edac6f37da032604051631aab3f0d60e11b81526001600160a01b0386811660048301526001600160c01b038416602483015291909116906335567e1a90604401602060405180830381865afa15801561114f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107419190614028565b336000908152600560209081526040808320546006835281842063e9ae5c5360e01b80865293529083205491926001600160a01b039182169290911690806111bb8484610497565b915091506111d66f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b03166111e7611659565b6001600160a01b0316148061121457506111ff611659565b6001600160a01b0316336001600160a01b0316145b61123157604051635629665f60e11b815260040160405180910390fd5b87600881901b3361124382600061170e565b156113a65761125683600160f81b61170e565b156112775789358a01602081019035611270838383612c65565b50506114ff565b61128283600061170e565b156112ea576000803660006112978e8e612cbc565b93509350935093506112e185858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117e092505050565b505050506114ff565b6112fc836001600160f81b031961170e565b156113815760006113106014828c8e614041565b6113199161406b565b60601c90503660008c8c601490809261133493929190614041565b91509150611379848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061257392505050565b5050506114ff565b604051632e5bf3f960e21b81526001600160f81b0319841660048201526024016105bd565b6113b482600160f81b61170e565b156114da576113c783600160f81b61170e565b156113e15789358a01602081019035611270838383612d0d565b6113ec83600061170e565b1561144b576000803660006114018e8e612cbc565b93509350935093506112e185858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612d6492505050565b61145d836001600160f81b031961170e565b156113815760006114716014828c8e614041565b61147a9161406b565b60601c90503660008c8c601490809261149593929190614041565b91509150611379848484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061276892505050565b6040516308c3ee0360e11b81526001600160f81b0319831660048201526024016105bd565b50505061150e84848484610669565b5050505050505050565b33600090815260036020526040812060609190611536818686612e1a565b92509250509250929050565b6f71727de22e5e9d8baf0edac6f37da03261155b611659565b6001600160a01b031614806115885750611573611659565b6001600160a01b0316336001600160a01b0316145b6115a557604051635629665f60e11b815260040160405180910390fd5b6106e684848484611a4e565b6000600182036115c357506001919050565b600282036115d357506001919050565b600382036115e357506001919050565b600482036115f357506001919050565b506000919050565b919050565b604080517f47e79534a245952e8b16893a336b85a3d9ea9fa8c573f3d803afb92a794692186020820152469181019190915230606082015260009060800160405160208183030381529060405280519060200120905090565b60131936013560601c90565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b815260040161169c94939291906143a7565b6000604051808303816000875af11580156116bb573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526116e391908101906143f2565b925090508061170557604051632b3f6d1160e21b815260040160405180910390fd5b50949350505050565b6001600160f81b031990811691161490565b60606000838360405160240161173792919061443f565b60408051601f198184030181529181526020820180516001600160e01b0316636a22165760e01b17905260008054915192935091611783916001600160a01b031690849060240161443f565b60408051601f19818403018152919052602080820180516001600160e01b031663b4faba0960e01b17815282519293509091600091895afa5060203d036040519350808401604052806020853e50600051610ae957825160208401fd5b60405163468721a760e01b81526000906001600160a01b0386169063468721a7906118159087908790879087906004016143a7565b6020604051808303816000875af1158015611834573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118589190614463565b90508061187857604051632b3f6d1160e21b815260040160405180910390fd5b5050505050565b600061066360023384612fb8565b3360009081526003602052604081206109d78184612ffc565b6000806118b583850185613d67565b3360009081526004602090815260408083206001600160e01b0319909416835292905220546001600160a01b03908116908616149150509392505050565b600080806119038486018661448d565b9150915060006119138383613036565b6001600160a01b039081169088161493505050509392505050565b6060601960f81b600160f81b85858560405160200161194e9291906144b9565b60408051808303601f190181529082905280516020918201206001600160f81b0319958616918301919091529290931660218401526022830152604282015260620160405160208183030381529060405290509392505050565b6000806000803660006119ba876130ce565b8451602086012060405163934f3a1160e01b8152959a5093985091965094509250339163934f3a11916119f5918990879087906004016140a0565b60006040518083038186803b158015611a0d57600080fd5b505afa925050508015611a1e575060015b611a3557611a2e600184866132e3565b9550611a44565b611a41600084866132e3565b95505b5050505050919050565b3360008181526001602052604080822080546001600160a01b0319166001600160a01b03891617905551611ac092918791611a91908690899089906024016144df565b60408051601f198184030181529190526020810180516001600160e01b031663f05c04e160e01b1790526117e0565b6040516001600160a01b0385169033907f9452c8fb077c3ea8f28a77c87488af657b1e44d010ad9a5992d73870da040e9490600090a350505050565b3360009081527fe90b7bceb6e7df5418fb78d8ee546e97c83a08bbccc01a0644d599ccd2a7c2e0602052604090205487906001600160a01b0316611ba957611b45600233611d3f565b60005b81811015611ba357368a8a83818110611b6357611b636142b9565b9050602002810190611b7591906142cf565b9050611b99611b876020830183614238565b611b94602084018461453a565b612065565b5050600101611b48565b50611bca565b8015611bca5760405163d8e3ed1b60e01b81523360048201526024016105bd565b336000908152600360205260409020611be28161331b565b86915060005b82811015611c435736898983818110611c0357611c036142b9565b9050602002810190611c1591906142cf565b9050611c39611c276020830183614238565b611c34602084018461453a565b6120c1565b5050600101611be8565b5084915060005b82811015611ca55736878783818110611c6557611c656142b9565b9050602002810190611c7791906142cf565b9050611c9b611c896020830183614238565b611c96602084018461453a565b61212b565b5050600101611c4a565b5082915060005b82811015611d075736858583818110611cc757611cc76142b9565b9050602002810190611cd991906142cf565b9050611cfd611ceb6020830183614238565b611cf8602084018461453a565b61226c565b5050600101611cac565b5060405133907ff48581d8a62b775b74f2fb67f1d5806a9a356fbcc598040ab3071d3e37af40c290600090a250505050505050505050565b60016000908152602083815260408083206001600160a01b0380861685529252909120541615611d82576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602093845260408082206001600160a01b0394909416825292909352912080546001600160a01b0319169091179055565b6001600160a01b0381161580611dd957506001600160a01b0381166001145b15611e0257604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b0381811660009081526020858152604080832086851684529091529020541615611e5157604051631034f46960e21b81526001600160a01b03821660048201526024016105bd565b60016000908152602084815260408083206001600160a01b039586168085528184528285208054968816808752988552838620918652908452919093208054949095166001600160a01b031994851617909455528154169091179055565b606060006001600160a01b038416600114801590611ed55750611ed3868686612fb8565b155b15611efe57604051637c84ecfb60e01b81526001600160a01b03851660048201526024016105bd565b82600003611f1f5760405163f725081760e01b815260040160405180910390fd5b826001600160401b03811115611f3757611f37613f0c565b604051908082528060200260200182016040528015611f60578160200160208202803683370190505b506001600160a01b038086166000908152602089815260408083208a85168452909152812054929450911691505b6001600160a01b03821615801590611fb057506001600160a01b038216600114155b8015611fbb57508381105b156120205781838281518110611fd357611fd36142b9565b6001600160a01b039283166020918202929092018101919091529281166000908152888452604080822089841683529094529290922054909116908061201881614596565b915050611f8e565b6001600160a01b038216600114612058578261203d6001836145af565b8151811061204d5761204d6142b9565b602002602001015191505b8083525094509492505050565b6060836001612074828261281e565b61208060023388611dba565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929998505050505050505050565b60608360026120d0828261281e565b3360009081526003602052604090206120e98188613378565b85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929a9950505050505050505050565b606083600361213a828261281e565b6000808061214a87890189614613565b919450925090506001600160e01b031983166306d61fe760e41b148061218057506001600160e01b03198316638a91b0e360e01b145b156121aa576040516379bd117b60e01b81526001600160e01b0319841660048201526024016105bd565b3360009081526004602090815260408083206001600160e01b0319871684529091529020546001600160a01b031615612202576040516374420d1560e01b81526001600160e01b0319841660048201526024016105bd565b3360009081526004602090815260408083206001600160e01b031990961683529490529290922080546001600160a01b038a166001600160a01b031960f89490941c600160a01b02939093166001600160a81b031990911617919091179055925050509392505050565b606083600461227b828261281e565b6000808061228b87890189614681565b919450925090506000808460018111156122a7576122a76146af565b1480156122bc57506001600160e01b03198316155b156123325750336000908152600560205260409020546001600160a01b031680156123055760405163741cbe0360e01b81526001600160a01b03821660048201526024016105bd565b33600090815260056020526040902080546001600160a01b0319166001600160a01b038c161790556123de565b6001846001811115612346576123466146af565b036123c5576001600160a01b0381161561237e5760405163741cbe0360e01b81526001600160a01b03821660048201526024016105bd565b503360009081526006602090815260408083206001600160e01b031986168452909152902080546001600160a01b038b81166001600160a01b0319831617909255166123de565b604051635691922f60e01b815260040160405180910390fd5b5098975050505050505050565b606082358301602081810191359085810135860180820191903590604088013588019081019035848381146124335760405163b4fa3fb360e01b815260040160405180910390fd5b60005b8181101561252c576000888883818110612452576124526142b9565b905060200201359050600181036124915761248b8d888885818110612479576124796142b9565b9050602002810190611b94919061453a565b50612523565b600281036124c15761248b8d8888858181106124af576124af6142b9565b9050602002810190611c34919061453a565b600381036124f15761248b8d8888858181106124df576124df6142b9565b9050602002810190611c96919061453a565b60048103612523576125218d88888581811061250f5761250f6142b9565b9050602002810190611cf8919061453a565b505b50600101612436565b5082828080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929e9d5050505050505050505050505050565b60405163468721a760e01b81526000906001600160a01b0385169063468721a7906125a9908690859087906001906004016143a7565b6020604051808303816000875af11580156125c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125ec9190614463565b9050806106e657604051632b3f6d1160e21b815260040160405180910390fd5b6060600061261c838501856146c5565b9250905061262d600233838861344e565b509392505050565b336000908152600360205260408120606091612653848601866146c5565b93509050610ae9828288613545565b606060006126728385018561470a565b3360009081526004602090815260408083206001600160e01b031990951683529390529190912080546001600160a01b031916905595945050505050565b60606000806126c184860186614681565b9450909250905060008260018111156126dc576126dc6146af565b1480156126f157506001600160e01b03198116155b156127185733600090815260056020526040902080546001600160a01b0319169055610ae9565b600182600181111561272c5761272c6146af565b036123c5573360009081526006602090815260408083206001600160e01b031985168452909152902080546001600160a01b0319169055610ae9565b60405163468721a760e01b81526000906001600160a01b0385169063468721a79061279e908690859087906001906004016143a7565b6020604051808303816000875af11580156127bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127e19190614463565b9050806106e657604080516001600160a01b0386168152600060208201526000805160206149c9833981519152910160405180910390a150505050565b336000908152600160205260409020546001600160a01b031680156128a45760405163529562a160e01b81523360048201526001600160a01b0384811660248301526044820184905282169063529562a19060640160006040518083038186803b15801561288b57600080fd5b505afa15801561289f573d6000803e3d6000fd5b505050505b505050565b60606128b685600061170e565b15612aac576128c984600160f81b61170e565b156128ec57823583016020810190356128e333838361361a565b92505050610741565b6128f784600061170e565b156129ab5760008036600061290c8787612cbc565b6040805160018082528183019092529498509296509094509250816020015b606081526020019060019003908161292b57905050945061298433858585858080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061166592505050565b85600081518110612997576129976142b9565b602002602001018190525050505050610741565b6129bd846001600160f81b031961170e565b15612a875760006129d16014828587614041565b6129da9161406b565b60601c90503660006129ef8560148189614041565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612a09579050509350612a61338484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061369392505050565b84600081518110612a7457612a746142b9565b6020026020010181905250505050610741565b604051632e5bf3f960e21b81526001600160f81b0319851660048201526024016105bd565b612aba85600160f81b61170e565b15612c4057612acd84600160f81b61170e565b15612af25782358301602081019035612ae7338383613734565b935061074192505050565b612afd84600061170e565b15612b8a57600080366000612b128787612cbc565b6040805160018082528183019092529498509296509094509250816020015b6060815260200190600190039081612b3157905050945061298433858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506137b692505050565b612b9c846001600160f81b031961170e565b15612a87576000612bb06014828587614041565b612bb99161406b565b60601c9050366000612bce8560148189614041565b604080516001808252818301909252929450909250816020015b6060815260200190600190039081612be8579050509350612a61338484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061387692505050565b6040516308c3ee0360e11b81526001600160f81b0319861660048201526024016105bd565b6000546040516128a49185916001600160a01b0390911690612c8d9086908690602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316633f707e6b60e01b179052612573565b6000803681612cce6014828789614041565b612cd79161406b565b60601c9350612cea603460148789614041565b612cf3916147d3565b9250612d028560348189614041565b949793965094505050565b6000546040516128a49185916001600160a01b0390911690612d359086908690602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316632864481160e11b179052612768565b60405163468721a760e01b81526000906001600160a01b0386169063468721a790612d999087908790879087906004016143a7565b6020604051808303816000875af1158015612db8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ddc9190614463565b90508061187857604080516001600160a01b0387168152600060208201526000805160206149c9833981519152910160405180910390a15050505050565b606060006001600160a01b038416600114801590612e3f5750612e3d8585612ffc565b155b15612e6857604051637c84ecfb60e01b81526001600160a01b03851660048201526024016105bd565b82600003612e895760405163f725081760e01b815260040160405180910390fd5b826001600160401b03811115612ea157612ea1613f0c565b604051908082528060200260200182016040528015612eca578160200160208202803683370190505b506001600160a01b03808616600090815260208890526040812054929450911691505b6001600160a01b03821615801590612f0f57506001600160a01b038216600114155b8015612f1a57508381105b15612f745781838281518110612f3257612f326142b9565b6001600160a01b039283166020918202929092018101919091529281166000908152928790526040909220549091169080612f6c81614596565b915050612eed565b6001600160a01b038216600114612fac5782612f916001836145af565b81518110612fa157612fa16142b9565b602002602001015191505b80835250935093915050565b600060016001600160a01b038316148015906107415750506001600160a01b0390811660009081526020938452604080822093831682529290935291205416151590565b600060016001600160a01b038316148015906109d75750506001600160a01b03908116600090815260209290925260409091205416151590565b60008083600181111561304b5761304b6146af565b14801561306057506001600160e01b03198216155b156130805750336000908152600560205260409020546001600160a01b03165b6001836001811115613094576130946146af565b0361066357503360009081526006602090815260408083206001600160e01b0319851684529091529020546001600160a01b031692915050565b6060600080368181816130e561010089018961453a565b90925090506130f8600660008385614041565b613101916147f1565b60d01c9550613114600c60068385614041565b61311d916147f1565b60d01c945061312f81600c8185614041565b9350935050506000604051806101c001604052807f84aa190356f56b8c87825f54884392a9907c23ee0f8e1ea86336b763faf021bd60001b8152602001336001600160a01b0316815260200188602001358152602001888060400190613195919061453a565b6040516131a392919061481f565b60405190819003902081526020016131be60608a018a61453a565b6040516131cc92919061481f565b604051809103902081526020016131e289613936565b81526020016131f08961394b565b81526020018860a0013581526020016132088961395b565b815260200161321689613970565b815260200161322860e08a018a61453a565b60405161323692919061481f565b604051809103902081526020018665ffffffffffff1681526020018565ffffffffffff1681526020016132766f71727de22e5e9d8baf0edac6f37da03290565b6001600160a01b031690526101c08120909150601960f81b600160f81b61329b611600565b6040516001600160f81b031993841660208201529290911660218301526022820152604281018290526062016040516020818303038152906040529650505091939590929450565b600060d08265ffffffffffff16901b60a08465ffffffffffff16901b8561330b57600061330e565b60015b60ff161717949350505050565b60016000908152602082905260409020546001600160a01b031615613353576040516329e42f3360e11b815260040160405180910390fd5b60016000818152602092909252604090912080546001600160a01b0319169091179055565b6001600160a01b038116158061339757506001600160a01b0381166001145b156133c057604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b03818116600090815260208490526040902054161561340457604051631034f46960e21b81526001600160a01b03821660048201526024016105bd565b60016000818152602093909352604080842080546001600160a01b039485168087529286208054959091166001600160a01b03199586161790559190935280549091169091179055565b6001600160a01b038116158061346d57506001600160a01b0381166001145b1561349657604051637c84ecfb60e01b81526001600160a01b03831660048201526024016105bd565b6001600160a01b0382811660009081526020868152604080832087851684529091529020548116908216146134e957604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b039081166000908152602085815260408083209584168084528683528184208054968616855297835281842090845282529091208054939092166001600160a01b031993841617909155919091528154169055565b6001600160a01b038116158061356457506001600160a01b0381166001145b1561358d57604051637c84ecfb60e01b81526001600160a01b03831660048201526024016105bd565b6001600160a01b038281166000908152602085905260409020548116908216146135d557604051637c84ecfb60e01b81526001600160a01b03821660048201526024016105bd565b6001600160a01b0390811660008181526020949094526040808520805494841686529085208054949093166001600160a01b0319948516179092559092528154169055565b60008054604051606092916136749187916001600160a01b0316906136459088908890602401614728565b60408051601f198184030181529190526020810180516001600160e01b0316636108557360e01b179052613693565b90508080602001905181019061368a91906148dc565b95945050505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016136cb94939291906143a7565b6000604051808303816000875af11580156136ea573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261371291908101906143f2565b925090508061262d57604051632b3f6d1160e21b815260040160405180910390fd5b60608060006137938660008054906101000a90046001600160a01b03168787604051602401613764929190614728565b60408051601f198184030181529190526020810180516001600160e01b0316639abb6e1760e01b179052613876565b9050808060200190518101906137a99190614910565b9097909650945050505050565b60606000856001600160a01b0316635229073f86868660006040518563ffffffff1660e01b81526004016137ed94939291906143a7565b6000604051808303816000875af115801561380c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261383491908101906143f2565b925090508061170557604080516001600160a01b0388168152600060208201526000805160206149c9833981519152910160405180910390a150949350505050565b60606000846001600160a01b0316635229073f8560008660016040518563ffffffff1660e01b81526004016138ae94939291906143a7565b6000604051808303816000875af11580156138cd573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526138f591908101906143f2565b925090508061262d57604080516001600160a01b0387168152600060208201526000805160206149c9833981519152910160405180910390a1509392505050565b60006001600160801b03608083013516610663565b6000610663826080013560801c90565b60006001600160801b0360c083013516610663565b600060c082013560801c610663565b6001600160a01b038116811461399457600080fd5b50565b80356115fb8161397f565b60008083601f8401126139b457600080fd5b5081356001600160401b038111156139cb57600080fd5b60208301915083602082850101111561054e57600080fd5b600080600080606085870312156139f957600080fd5b843593506020850135613a0b8161397f565b925060408501356001600160401b03811115613a2657600080fd5b613a32878288016139a2565b95989497509550505050565b600080600060408486031215613a5357600080fd5b8335925060208401356001600160401b03811115613a7057600080fd5b613a7c868287016139a2565b9497909650939450505050565b600080600060608486031215613a9e57600080fd5b83356001600160401b03811115613ab457600080fd5b84016101208187031215613ac757600080fd5b95602085013595506040909401359392505050565b60008083601f840112613aee57600080fd5b5081356001600160401b03811115613b0557600080fd5b6020830191508360208260051b850101111561054e57600080fd5b600060608284031215613b3257600080fd5b50919050565b600080600080600080600080600060a08a8c031215613b5657600080fd5b89356001600160401b0380821115613b6d57600080fd5b613b798d838e01613adc565b909b50995060208c0135915080821115613b9257600080fd5b613b9e8d838e01613adc565b909950975060408c0135915080821115613bb757600080fd5b613bc38d838e01613adc565b909750955060608c0135915080821115613bdc57600080fd5b613be88d838e01613adc565b909550935060808c0135915080821115613c0157600080fd5b50613c0e8c828d01613b20565b9150509295985092959850929598565b60008060208385031215613c3157600080fd5b82356001600160401b03811115613c4757600080fd5b613c5385828601613adc565b90969095509350505050565b60008060408385031215613c7257600080fd5b8235613c7d8161397f565b946020939093013593505050565b604080825283519082018190526000906020906060840190828701845b82811015613ccd5781516001600160a01b031684529284019290840190600101613ca8565b5050506001600160a01b039490941660209390930192909252509092915050565b60005b83811015613d09578181015183820152602001613cf1565b50506000910152565b60008151808452613d2a816020860160208601613cee565b601f01601f19169290920160200192915050565b6020815260006109d76020830184613d12565b6001600160e01b03198116811461399457600080fd5b600060208284031215613d7957600080fd5b81356109d781613d51565b600060208284031215613d9657600080fd5b5035919050565b600060208083016020845280855180835260408601915060408160051b87010192506020870160005b82811015613df457603f19888603018452613de2858351613d12565b94509285019290850190600101613dc6565b5092979650505050505050565b60008060408385031215613e1457600080fd5b8235613e1f8161397f565b91506020830135613e2f8161397f565b809150509250929050565b803560ff811681146115fb57600080fd5b60008060008060608587031215613e6157600080fd5b8435613e6c8161397f565b935060208501356001600160401b03811115613e8757600080fd5b613e9387828801613adc565b9094509250613ea6905060408601613e3a565b905092959194509250565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60018060a01b0385168152836020820152606060408201526000613f02606083018486613eb1565b9695505050505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715613f4a57613f4a613f0c565b604052919050565b60006001600160401b03821115613f6b57613f6b613f0c565b50601f01601f191660200190565b6000613f8c613f8784613f52565b613f22565b9050828152838383011115613fa057600080fd5b6109d7836020830184613cee565b600082601f830112613fbf57600080fd5b6109d783835160208501613f79565b600060208284031215613fe057600080fd5b81516001600160401b03811115613ff657600080fd5b61074184828501613fae565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60006020828403121561403a57600080fd5b5051919050565b6000808585111561405157600080fd5b8386111561405e57600080fd5b5050820193919092039150565b6bffffffffffffffffffffffff1981358181169160148510156140985780818660140360031b1b83161692505b505092915050565b8481526060602082015260006140b96060830186613d12565b82810360408401526140cc818587613eb1565b979650505050505050565b6000602082840312156140e957600080fd5b81516109d781613d51565b6000808335601e1984360301811261410b57600080fd5b83016020810192503590506001600160401b0381111561412a57600080fd5b80360382131561054e57600080fd5b6040815261415a6040820161414d85613997565b6001600160a01b03169052565b60208301356060820152600061417360408501856140f4565b61012080608086015261418b61016086018385613eb1565b925061419a60608801886140f4565b9250603f19808786030160a08801526141b4858584613eb1565b9450608089013560c088015260a089013560e0880152610100935060c0890135848801526141e560e08a018a6140f4565b92508188870301848901526141fb868483613eb1565b95505061420a848a018a6140f4565b9450925080878603016101408801525050614226838383613eb1565b93505050508260208301529392505050565b60006020828403121561424a57600080fd5b81356109d78161397f565b6000808335601e1984360301811261426c57600080fd5b8301803591506001600160401b0382111561428657600080fd5b6020019150600581901b360382131561054e57600080fd5b6000602082840312156142b057600080fd5b6109d782613e3a565b634e487b7160e01b600052603260045260246000fd5b60008235603e198336030181126142e557600080fd5b9190910192915050565b8381526001600160a01b038316602082015260606040820181905260009061368a90830184613d12565b60006020828403121561432b57600080fd5b81516001600160401b0381111561434157600080fd5b8201601f8101841361435257600080fd5b61074184825160208401613f79565b64736166652d60d81b815260008251614381816005850160208701613cee565b6e2e657263373537392e76302e302e3160881b6005939091019283015250601401919050565b60018060a01b03851681528360208201526080604082015260006143ce6080830185613d12565b905060ff8316606083015295945050505050565b805180151581146115fb57600080fd5b6000806040838503121561440557600080fd5b61440e836143e2565b915060208301516001600160401b0381111561442957600080fd5b61443585828601613fae565b9150509250929050565b6001600160a01b038316815260406020820181905260009061074190830184613d12565b60006020828403121561447557600080fd5b6109d7826143e2565b8035600281106115fb57600080fd5b600080604083850312156144a057600080fd5b6144a98361447e565b91506020830135613e2f81613d51565b828152600082516144d1816020850160208701613cee565b919091016020019392505050565b60ff8416815260406020808301829052908201839052600090849060608401835b8681101561452e5783356145138161397f565b6001600160a01b031682529282019290820190600101614500565b50979650505050505050565b6000808335601e1984360301811261455157600080fd5b8301803591506001600160401b0382111561456b57600080fd5b60200191503681900382131561054e57600080fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016145a8576145a8614580565b5060010190565b8181038181111561066357610663614580565b600082601f8301126145d357600080fd5b81356145e1613f8782613f52565b8181528460208386010111156145f657600080fd5b816020850160208301376000918101602001919091529392505050565b60008060006060848603121561462857600080fd5b833561463381613d51565b925060208401356001600160f81b03198116811461465057600080fd5b915060408401356001600160401b0381111561466b57600080fd5b614677868287016145c2565b9150509250925092565b60008060006060848603121561469657600080fd5b61469f8461447e565b9250602084013561465081613d51565b634e487b7160e01b600052602160045260246000fd5b600080604083850312156146d857600080fd5b82356146e38161397f565b915060208301356001600160401b038111156146fe57600080fd5b614435858286016145c2565b6000806040838503121561471d57600080fd5b82356146e381613d51565b60208082528181018390526000906040808401600586901b850182018785805b898110156147c457888403603f190185528235368c9003605e1901811261476d578283fd5b8b016060813561477c8161397f565b6001600160a01b03168652818901358987015261479b888301836140f4565b925081898801526147af8288018483613eb1565b978a0197965050509287019250600101614748565b50919998505050505050505050565b8035602083101561066357600019602084900360031b1b1692915050565b6001600160d01b031981358181169160068510156140985760069490940360031b84901b1690921692915050565b8183823760009101908152919050565b60006001600160401b0382111561484857614848613f0c565b5060051b60200190565b600082601f83011261486357600080fd5b81516020614873613f878361482f565b82815260059290921b8401810191818101908684111561489257600080fd5b8286015b848110156148d15780516001600160401b038111156148b55760008081fd5b6148c38986838b0101613fae565b845250918301918301614896565b509695505050505050565b6000602082840312156148ee57600080fd5b81516001600160401b0381111561490457600080fd5b61074184828501614852565b6000806040838503121561492357600080fd5b82516001600160401b038082111561493a57600080fd5b818501915085601f83011261494e57600080fd5b8151602061495e613f878361482f565b82815260059290921b8401810191818101908984111561497d57600080fd5b948201945b838610156149a257614993866143e2565b82529482019490820190614982565b918801519196509093505050808211156149bb57600080fd5b506144358582860161485256feb8bc84bd77f5eb08210b8eb20fd63b3ec6a7992d277ab94663bae0e066f792aca26469706673582212203bf73a2c2062b81b2af0d1e3cda1afef579f700fd7d2e530b6b4eada00b17f5f64736f6c63430008190033",sourceMap:"2103:22088:37:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8864:24:42;728:1:11;715:15;710:3;706:25;1058:10;1055:1;1052:17;1039:10;1036:1;1033:17;1030:40;1017:10;1014:1;1011:17;1008:63;1005:190;;;1103:1;1097:4;1090:15;1097:4;1149;1142:18;1005:190;-1:-1:-1;12548:10:42::1;8838:7;12536:23:::0;;;:11:::1;:23;::::0;;;;;;;;12587:12:::1;:24:::0;;;;;-1:-1:-1;;;;;;8838:7:42;::::1;;12587:34:::0;;;;;;;;;8838:7;;-1:-1:-1;;;;;12536:23:42;;::::1;::::0;12587:34;;::::1;::::0;8838:7;12673:30:::1;12536:23:::0;12587:34;12673:9:::1;:30::i;:::-;12631:72;;;;8958:30:::2;8979:8;;8958:20;:30::i;:::-;8951:37;;12724:44:::1;12735:10;12747:7;12756:6;12764:3;12724:10;:44::i;:::-;12505:270;;;;1214:1:11;8686:309:42::0;;;2103:22088:37;;;;;;15604:107:42;;;;;;;;;;-1:-1:-1;15693:10:42;15650:12;15681:23;;;:11;:23;;;;;;-1:-1:-1;;;;;15681:23:42;15604:107;;;-1:-1:-1;;;;;287:32:54;;;269:51;;257:2;242:18;15604:107:42;;;;;;;;19031:700:37;;;;;;;;;;-1:-1:-1;19031:700:37;;;;;:::i;:::-;;:::i;:::-;;;1740:14:54;;1733:22;1715:41;;1703:2;1688:18;19031:700:37;1575:187:54;13159:1524:37;;;;;;;;;;-1:-1:-1;13159:1524:37;;;;;:::i;:::-;;:::i;:::-;;;-1:-1:-1;;;;;;2411:33:54;;;2393:52;;2381:2;2366:18;13159:1524:37;2249:202:54;10812:1326:37;;;;;;:::i;:::-;;:::i;:::-;;;3141:25:54;;;3129:2;3114:18;10812:1326:37;2995:177:54;1564:493:41;;;;;;:::i;:::-;;:::i;:::-;;833:680;;;;;;:::i;:::-;;:::i;3661:349:42:-;;;;;;;;;;-1:-1:-1;3661:349:42;;;;;:::i;:::-;;:::i;:::-;;;;;;;;:::i;14734:1437:37:-;;;;;;:::i;:::-;;:::i;19782:237::-;;;;;;;;;;;;;:::i;:::-;;;;;;;:::i;16222:1517::-;;;;;;:::i;:::-;;:::i;895:135:39:-;;;;;;;;;;-1:-1:-1;981:42:39;895:135;;15465:133:42;;;;;;;;;;-1:-1:-1;15465:133:42;;;;;:::i;:::-;15570:10;15526:12;15557:24;;;:12;:24;;;;;;;;-1:-1:-1;;;;;;15557:34:42;;;;;;;;;;-1:-1:-1;;;;;15557:34:42;;15465:133;17790:757:37;;;;;;;;;;-1:-1:-1;17790:757:37;;;;;:::i;:::-;;:::i;6268:674::-;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;23961:228::-;;;;;;;;;;-1:-1:-1;23961:228:37;;;;;:::i;:::-;;:::i;2782:3435::-;;;;;;:::i;:::-;;:::i;5538:344:42:-;;;;;;;;;;-1:-1:-1;5538:344:42;;;;;:::i;:::-;;:::i;4307:234:41:-;;;;;;;;;;-1:-1:-1;4307:234:41;;;;;:::i;:::-;;:::i;18598:382:37:-;;;;;;;;;;-1:-1:-1;18598:382:37;;;;;:::i;:::-;;:::i;23760:150::-;;;;;;;;;;;;;:::i;10793:843:42:-;10905:19;;-1:-1:-1;;;;;10962:24:42;;;10958:339;;11011:225;11053:10;11090;11125:1;11186:12;:10;:12::i;:::-;11200:9;11211:8;;11154:67;;;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;11154:67:42;;;;;;;;;;;;;;-1:-1:-1;;;;;11154:67:42;-1:-1:-1;;;11154:67:42;;;11011:11;:225::i;:::-;11002:234;;11270:6;11259:27;;;;;;;;;;;;:::i;:::-;11250:36;;10958:339;-1:-1:-1;;;;;11310:21:42;;;11306:324;;11353:222;11395:10;11432:7;11464:1;11525:12;:10;:12::i;11353:222::-;11347:228;;11606:3;11595:24;;;;;;;;;;;;:::i;:::-;11589:30;;11306:324;10793:843;;;;;:::o;9001:1249::-;9237:10;9183:34;9220:28;;;:16;:28;;;;;;;;-1:-1:-1;;;;;;9249:7:42;;;9220:37;;;;;;;9285:18;;9089:24;;9220:37;-1:-1:-1;;;;;9285:18:42;;;-1:-1:-1;;;9333:19:42;;;;9285:18;9418:60;;9452:26;;-1:-1:-1;;;9452:26:42;;-1:-1:-1;;;;;;9470:7:42;;;9452:26;;;2393:52:54;2366:18;;9452:26:42;;;;;;;;9418:60;9701:27;:8;-1:-1:-1;;;9701:27:42;:::i;:::-;9697:259;;;9751:194;9799:10;9836:7;9888:8;;9898:12;:10;:12::i;:::-;9871:40;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;9751:17;:194::i;:::-;9744:201;;;;;;;9697:259;9969:27;:8;2726:4:52;9969:27:42;:::i;:::-;9965:279;;;10019:214;10061:10;10098:7;10130:1;10176:8;;10186:12;:10;:12::i;:::-;10159:40;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;10019:11;:214::i;9965:279::-;9119:1131;;;9001:1249;;;;;:::o;11690:667::-;-1:-1:-1;;;;;11859:24:42;;;11855:248;;11899:193;11935:10;11972;12007:1;12069:6;12036:41;;;;;;;;:::i;:::-;;;;-1:-1:-1;;12036:41:42;;;;;;;;;;;;;;-1:-1:-1;;;;;12036:41:42;-1:-1:-1;;;12036:41:42;;;11899:5;:193::i;:::-;-1:-1:-1;;;;;12116:21:42;;;12112:239;;12153:187;12189:10;12226:7;12258:1;12320:3;12287:38;;;;;;;;:::i;12153:187::-;11690:667;;;;:::o;19031:700:37:-;19205:4;276:1:12;19229:10:37;:35;19225:500;;19287:29;19309:6;19287:21;:29::i;:::-;19280:36;;;;19225:500;319:1:12;19337:10:37;:34;19333:392;;19394:28;19415:6;19394:20;:28::i;19333:392::-;362:1:12;19443:10:37;:34;19439:286;;19500:54;19528:6;19536:17;;19500:27;:54::i;19439:286::-;401:1:12;19575:10:37;:30;19571:154;;19628:43;19645:6;19653:17;;19628:16;:43::i;19571:154::-;-1:-1:-1;19709:5:37;19571:154;19031:700;;;;;;:::o;13159:1524::-;13289:17;13341:10;13411:16;;:50;;;;-1:-1:-1;13431:25:37;;-1:-1:-1;;;13431:25:37;;;;;3141::54;;;-1:-1:-1;;;;;13431:19:37;;;;;3114:18:54;;13431:25:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:30;;13411:50;13407:156;;;-1:-1:-1;;;;13518:34:37;-1:-1:-1;13511:41:37;;13407:156;13572:24;13615:9;13621:2;13572:24;13615:4;;:9;:::i;:::-;13607:18;;;:::i;:::-;13599:27;;;-1:-1:-1;13819:30:37;;;:74;;;13854:39;13876:16;13854:21;:39::i;:::-;13853:40;13819:74;13815:456;;;13909:24;13936:138;13978:4;-1:-1:-1;;;;;13978:20:37;;:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;14042:16;;;;;;3141:25:54;;;2531:66:37;;3114:18:54;14042:16:37;;;-1:-1:-1;;14042:16:37;;;;;;;;;14032:27;;14042:16;14032:27;;;;14021:39;;;3141:25:54;3114:18;14021:39:37;;;;;;;;;;;;13936:24;:138::i;:::-;14111:22;;;;;;13909:165;;-1:-1:-1;;;;;;14148:20:37;;;14111:22;13909:165;14195:9;:4;14200:2;14195:4;;:9;:::i;:::-;14148:57;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;14226:34:37;-1:-1:-1;14219:41:37;;-1:-1:-1;;;;;;;14219:41:37;13815:456;14365:16;14384:244;14428:10;14461:16;14573:12;:10;:12::i;:::-;14587:4;14593:9;:4;14598:2;14593:4;;:9;:::i;:::-;14501:116;;;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;14501:116:37;;;;;;;;;;;;;;-1:-1:-1;;;;;14501:116:37;-1:-1:-1;;;14501:116:37;;;14384:17;:244::i;:::-;14365:263;;14662:3;14651:25;;;;;;;;;;;;:::i;:::-;14638:38;;13312:1371;;;13159:1524;;;;;;:::o;10812:1326::-;11025:22;981:42:39;783:12;:10;:12::i;:::-;-1:-1:-1;;;;;783:28:39;;779:93;;834:27;;-1:-1:-1;;;834:27:39;;;;;;;;;;;779:93;11106:12:37::1;::::0;::::1;;11225:2;11221:14:::0;;::::1;::::0;11338:23;;;:60:::1;;;11366:32;11388:9;11366:21;:32::i;:::-;11365:33;11338:60;11334:536;;;11431:27;11451:6;11431:19;:27::i;:::-;11414:44;;11334:536;;;11555:20;11578:220;11620:10;11657:9;11691:1;11763:6;11771:10;11720:63;;;;;;;;;:::i;:::-;;::::0;;-1:-1:-1;;11720:63:37;;::::1;::::0;;;;;;::::1;::::0;::::1;::::0;;-1:-1:-1;;;;;11720:63:37::1;-1:-1:-1::0;;;11720:63:37::1;::::0;;11578:11:::1;:220::i;:::-;11555:243;;11840:7;11829:30;;;;;;;;;;;;:::i;:::-;11812:47;;11475:395;11334:536;11907:24:::0;;11903:229:::1;;11947:174;11983:10;981:42:39::0;12057:19:37::1;11947:174;;;;;;;;;;;::::0;:5:::1;:174::i;:::-;11053:1085;;10812:1326:::0;;;;;:::o;1564:493:41:-;1847:89;1866:21;;;;:12;:21;:::i;:::-;1889:22;;;;:12;:22;:::i;:::-;1913;;;;;;;;:::i;:::-;1847:18;:89::i;:::-;1997:53;2010:10;;2022:9;;2033;;2044:5;;1997:12;:53::i;:::-;1564:493;;;;;;;;;:::o;833:680::-;983:41;:11;1011:10;983:16;:41::i;:::-;1051:10;1034:14;1078:429;1098:6;1094:1;:10;1078:429;;;1125:29;1157:10;;1168:1;1157:13;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;1125:45;-1:-1:-1;1184:69:41;1212:10;1234:16;;;;1125:45;1234:16;:::i;:::-;1184:11;;:69;:16;:69::i;:::-;-1:-1:-1;1106:3:41;;1078:429;;3661:349:42;3810:22;3834:12;3869:134;:11;3924:10;3955:5;3984:8;3869:31;:134::i;:::-;3862:141;;;;3661:349;;;;;:::o;14734:1437:37:-;12548:10:42;12515:18;12536:23;;;:11;:23;;;;;;;;;12587:12;:24;;;;;-1:-1:-1;;;12587:34:42;;;;;;;;;14915:38:37;;-1:-1:-1;;;;;12536:23:42;;;;12587:34;;;;12515:18;12673:30;12536:23;12587:34;12673:9;:30::i;:::-;12631:72;;;;599:12:39::1;981:42:::0;;895:135;599:12:::1;-1:-1:-1::0;;;;;583:28:39::1;:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;583:28:39::1;;:58;;;;629:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;615:26:39::1;:10;-1:-1:-1::0;;;;;615:26:39::1;;583:58;577:126;;665:27;;-1:-1:-1::0;;;665:27:39::1;;;;;;;;;;;577:126;15179:27:37::2;276:1:12;15220:10:37;:35:::0;15216:673:::2;;15288:35;15306:6;15314:8;;15288:17;:35::i;:::-;15271:52;;15216:673;;;319:1:12;15344:10:37;:34:::0;15340:549:::2;;15411:34;15428:6;15436:8;;15411:16;:34::i;15340:549::-;362:1:12;15466:10:37;:34:::0;15462:427:::2;;15533:41;15557:6;15565:8;;15533:23;:41::i;15462:427::-;401:1:12;15595:10:37;:30:::0;15591:298:::2;;15658:30;15671:6;15679:8;;15658:12;:30::i;15591:298::-;15709:10:::0;15705:184:::2;;15772:35;15790:6;15798:8;;15772:17;:35::i;15705:184::-;15845:33;::::0;-1:-1:-1;;;15845:33:37;;::::2;::::0;::::2;3141:25:54::0;;;3114:18;;15845:33:37::2;2995:177:54::0;15705:184:37::2;16010:4;::::0;16038:115:::2;::::0;15937:227:::2;::::0;15977:10:::2;::::0;-1:-1:-1;;;;;16010:4:37;;::::2;::::0;16038:115:::2;::::0;16104:10;;16116:6;;16124:14;;16038:115:::2;;;:::i;:::-;;::::0;;-1:-1:-1;;16038:115:37;;::::2;::::0;;;;;;::::2;::::0;::::2;::::0;;-1:-1:-1;;;;;16038:115:37::2;-1:-1:-1::0;;;16038:115:37::2;::::0;;15937:13:::2;:227::i;:::-;14988:1183;12724:44:42::0;12735:10;12747:7;12756:6;12764:3;12724:10;:44::i;19782:237:37:-;19826:37;19875:25;19909:10;-1:-1:-1;;;;;19903:25:37;;:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;19903:27:37;;;;;;;;;;;;:::i;:::-;19875:55;;19980:11;19954:57;;;;;;;;:::i;:::-;;;;;;;;;;;;;19940:72;;;19782:237;:::o;16222:1517::-;12548:10:42;12515:18;12536:23;;;:11;:23;;;;;;;;;12587:12;:24;;;;;-1:-1:-1;;;12587:34:42;;;;;;;;;16407:40:37;;-1:-1:-1;;;;;12536:23:42;;;;12587:34;;;;12515:18;12673:30;12536:23;12587:34;12673:9;:30::i;:::-;12631:72;;;;599:12:39::1;981:42:::0;;895:135;599:12:::1;-1:-1:-1::0;;;;;583:28:39::1;:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;583:28:39::1;;:58;;;;629:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;615:26:39::1;:10;-1:-1:-1::0;;;;;615:26:39::1;;583:58;577:126;;665:27;;-1:-1:-1::0;;;665:27:39::1;;;;;;;;;;;577:126;16681:29:37::2;276:1:12;16724:10:37;:35:::0;16720:578:::2;;16794:39;16814:6;16822:10;;16794:19;:39::i;:::-;16775:58;;16720:578;;;319:1:12;16854:10:37;:34:::0;16850:448:::2;;16923:38;16942:6;16950:10;;16923:18;:38::i;16850:448::-;362:1:12;16982:10:37;:34:::0;16978:320:::2;;17051:45;17077:6;17085:10;;17051:25;:45::i;16978:320::-;401:1:12;17117:10:37;:30:::0;17113:185:::2;;17182:34;17197:6;17205:10;;17182:14;:34::i;17113:185::-;17574:4;::::0;17602:119:::2;::::0;17498:234:::2;::::0;17541:10:::2;::::0;-1:-1:-1;;;;;17574:4:37;;::::2;::::0;17602:119:::2;::::0;17670:10;;17682:6;;17690:16;;17602:119:::2;;;:::i;:::-;;::::0;;-1:-1:-1;;17602:119:37;;::::2;::::0;;;;;;::::2;::::0;::::2;::::0;;-1:-1:-1;;;;;17602:119:37::2;-1:-1:-1::0;;;17602:119:37::2;::::0;;17498:16:::2;:234::i;17790:757::-:0;17907:14;18082:11;18122:1;18118:19;;;18160:26;18082:11;-1:-1:-1;;;18160:26:37;:::i;:::-;18156:209;;;18200:4;18188:16;;18156:209;;;18223:27;:8;2726:4:52;18223:27:37;:::i;:::-;18219:146;;;18264:4;18252:16;;18219:146;;;18287:33;:8;-1:-1:-1;;;;;;18287:33:37;:::i;:::-;18283:82;;;18334:4;18322:16;;18283:82;;;-1:-1:-1;18360:5:37;;17790:757;-1:-1:-1;;;17790:757:37:o;18283:82::-;18380:9;:41;;;;-1:-1:-1;18393:28:37;:8;3306:4:52;18393:28:37;:::i;:::-;18376:164;;;18423:16;;17790:757;;;:::o;18376:164::-;18458:9;:37;;;;-1:-1:-1;18471:24:37;:8;-1:-1:-1;;;18471:24:37;:::i;:::-;18454:86;;;18497:16;;17790:757;;;:::o;6268:674::-;6580:26;4456:34:42;4477:12;:10;:12::i;:::-;4456:20;:34::i;:::-;4451:75;;4513:12;:10;:12::i;:::-;4499:27;;-1:-1:-1;;;4499:27:42;;-1:-1:-1;;;;;287:32:54;;;4499:27:42;;;269:51:54;242:18;;4499:27:42;123:203:54;4451:75:42;12548:10:::1;12515:18;12536:23:::0;;;:11:::1;:23;::::0;;;;;;;;12587:12:::1;:24:::0;;;;;-1:-1:-1;;;12587:34:42;;;;;;;;;6462:44:37;;-1:-1:-1;;;;;12536:23:42;;::::1;::::0;12587:34;;::::1;::::0;12515:18;12673:30:::1;12536:23:::0;12587:34;12673:9:::1;:30::i;:::-;12631:72;;;;6529:10:37::2;319:1:12;675:34:43;690:6;698:10;675:14;:34::i;:::-;6768:4:37::0;6801:1:::3;6797:12:::0;;::::3;6882:53;6797:12:::0;6768:4;6917:17;;6882:14:::3;:53::i;:::-;6875:60;;;;12713:1:42::2;;12724:44:::1;12735:10;12747:7;12756:6;12764:3;12724:10;:44::i;:::-;12505:270;;;;4536:1;6268:674:37::0;;;;;:::o;23961:228::-;24035:13;24074:45;;;;-1:-1:-1;;;;;24074:45:37;981:42:39;24137:45:37;;-1:-1:-1;;;24137:45:37;;-1:-1:-1;;;;;22049:32:54;;;24137:45:37;;;22031:51:54;-1:-1:-1;;;;;22118:32:54;;22098:18;;;22091:60;24137:34:37;;;;;;;22004:18:54;;24137:45:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;2782:3435::-;12548:10:42;12515:18;12536:23;;;:11;:23;;;;;;;;;12587:12;:24;;;;;-1:-1:-1;;;12587:34:42;;;;;;;;;2920:32:37;;-1:-1:-1;;;;;12536:23:42;;;;12587:34;;;;12515:18;12673:30;12536:23;12587:34;12673:9;:30::i;:::-;12631:72;;;;599:12:39::1;981:42:::0;;895:135;599:12:::1;-1:-1:-1::0;;;;;583:28:39::1;:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;583:28:39::1;;:58;;;;629:12;:10;:12::i;:::-;-1:-1:-1::0;;;;;615:26:39::1;:10;-1:-1:-1::0;;;;;615:26:39::1;;583:58;577:126;;665:27;;-1:-1:-1::0;;;665:27:39::1;;;;;;;;;;;577:126;3143:4:37::0;3176:1:::2;3172:12:::0;;::::2;3516:10;3541:28;3172:12:::0;2997:17:::2;3541:28;:::i;:::-;3537:2674;;;3631:26;:8:::0;-1:-1:-1;;;3631:26:37::2;:::i;:::-;3627:902;;;867:29:51::0;;846:51;;999:2;982:20;;;1040:25;3760:23:37::2;3766:4:::0;982:20:51;1040:25;3760:5:37::2;:23::i;:::-;3659:139;;3537:2674;;3627:902;3861:27;:8:::0;2726:4:52::2;3861:27:37;:::i;:::-;3857:672;;;3909:14;3925:13:::0;3940:23:::2;;3987:32;:17;;:30;:32::i;:::-;3908:111;;;;;;;;4037:36;4043:4;4049:6;4057:5;4064:8;;4037:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::2;::::0;;;;-1:-1:-1;4037:5:37::2;::::0;-1:-1:-1;;;4037:36:37:i:2;:::-;3890:198;;;;3537:2674;;3857:672;4153:33;:8:::0;-1:-1:-1;;;;;;4153:33:37::2;:::i;:::-;4149:380;;;4206:14;4239:22;4258:2;4206:14:::0;4239:17;;:22:::2;:::i;:::-;4231:31;::::0;::::2;:::i;:::-;4223:40;;4206:57;;4281:23;;4307:17;;4325:2;4307:22;;;;;;;;;:::i;:::-;4281:48;;;;4347:37;4361:4;4367:6;4375:8;;4347:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::2;::::0;;;;-1:-1:-1;4347:13:37::2;::::0;-1:-1:-1;;;4347:37:37:i:2;:::-;4188:211;;;3537:2674;;4149:380;4485:29;::::0;-1:-1:-1;;;4485:29:37;;-1:-1:-1;;;;;;22355:26:54;;4485:29:37::2;::::0;::::2;22337:45:54::0;22310:18;;4485:29:37::2;22162:226:54::0;3537:2674:37::2;4851:24;:8:::0;-1:-1:-1;;;4851:24:37::2;:::i;:::-;4847:1364;;;4932:26;:8:::0;-1:-1:-1;;;4932:26:37::2;:::i;:::-;4928:904;;;867:29:51::0;;846:51;;999:2;982:20;;;1040:25;5061:26:37::2;5070:4:::0;982:20:51;1040:25;5061:8:37::2;:26::i;4928:904::-;5162:27;:8:::0;2726:4:52::2;5162:27:37;:::i;:::-;5158:674;;;5210:14;5226:13:::0;5241:23:::2;;5288:32;:17;;:30;:32::i;:::-;5209:111;;;;;;;;5338:39;5347:4;5353:6;5361:5;5368:8;;5338:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::2;::::0;;;;-1:-1:-1;5338:8:37::2;::::0;-1:-1:-1;;;5338:39:37:i:2;5158:674::-;5453:33;:8:::0;-1:-1:-1;;;;;;5453:33:37::2;:::i;:::-;5449:383;;;5506:14;5539:22;5558:2;5506:14:::0;5539:17;;:22:::2;:::i;:::-;5531:31;::::0;::::2;:::i;:::-;5523:40;;5506:57;;5581:23;;5607:17;;5625:2;5607:22;;;;;;;;;:::i;:::-;5581:48;;;;5647:40;5664:4;5670:6;5678:8;;5647:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::2;::::0;;;;-1:-1:-1;5647:16:37::2;::::0;-1:-1:-1;;;5647:40:37:i:2;4847:1364::-;6171:29;::::0;-1:-1:-1;;;6171:29:37;;-1:-1:-1;;;;;;22355:26:54;;6171:29:37::2;::::0;::::2;22337:45:54::0;22310:18;;6171:29:37::2;22162:226:54::0;4847:1364:37::2;2987:3230;;;12724:44:42::0;12735:10;12747:7;12756:6;12764:3;12724:10;:44::i;:::-;12505:270;;;;2782:3435:37;;;;:::o;5538:344:42:-;5803:10;5708:12;5786:28;;;:16;:28;;;;;5684:22;;5708:12;5831:44;5786:28;5862:6;5870:4;5831:30;:44::i;:::-;5824:51;;;;;5538:344;;;;;:::o;4307:234:41:-;981:42:39;583:12;:10;:12::i;:::-;-1:-1:-1;;;;;583:28:39;;:58;;;;629:12;:10;:12::i;:::-;-1:-1:-1;;;;;615:26:39;:10;-1:-1:-1;;;;;615:26:39;;583:58;577:126;;665:27;;-1:-1:-1;;;665:27:39;;;;;;;;;;;577:126;4484:50:41::1;4503:8;4513:9;;4524;4484:18;:50::i;18598:382:37:-:0;18676:4;276:1:12;18696:12:37;:37;18692:281;;-1:-1:-1;18742:4:37;;18598:382;-1:-1:-1;18598:382:37:o;18692:281::-;319:1:12;18765:12:37;:36;18761:212;;-1:-1:-1;18810:4:37;;18598:382;-1:-1:-1;18598:382:37:o;18761:212::-;362:1:12;18833:12:37;:36;18829:144;;-1:-1:-1;18878:4:37;;18598:382;-1:-1:-1;18598:382:37:o;18829:144::-;401:1:12;18901:12:37;:32;18897:76;;-1:-1:-1;18942:4:37;;18598:382;-1:-1:-1;18598:382:37:o;18897:76::-;-1:-1:-1;18968:5:37;;18598:382;-1:-1:-1;18598:382:37:o;18897:76::-;18598:382;;;:::o;23760:150::-;23844:58;;;2357:66;23844:58;;;22852:25:54;23882:13:37;22893:18:54;;;22886:34;;;;23897:4:37;22936:18:54;;;22929:60;23808:7:37;;22825:18:54;;23844:58:37;;;;;;;;;;;;23834:69;;;;;;23827:76;;23760:150;:::o;1053:312:8:-;-1:-1:-1;;1328:14:8;1324:23;1311:37;1307:2;1303:46;;1053:312::o;3039:361:40:-;3198:20;3234:12;3277:4;-1:-1:-1;;;;;3277:40:40;;3318:6;3326:5;3333:8;3343:1;3277:68;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;3277:68:40;;;;;;;;;;;;:::i;:::-;3256:89;-1:-1:-1;3256:89:40;-1:-1:-1;3256:89:40;3355:38;;3376:17;;-1:-1:-1;;;3376:17:40;;;;;;;;;;;3355:38;3224:176;3039:361;;;;;;:::o;5353:120:52:-;-1:-1:-1;;;;;;5430:40:52;;;;;;;5353:120::o;7377:1080:40:-;7532:19;7567:27;7640:6;7648:8;7597:61;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;7597:61:40;;;;;;;;;;;;;;-1:-1:-1;;;;;7597:61:40;-1:-1:-1;;;7597:61:40;;;-1:-1:-1;7763:4:40;;7714:72;;7597:61;;-1:-1:-1;;7714:72:40;;-1:-1:-1;;;;;7763:4:40;;7597:61;;7714:72;;;:::i;:::-;;;;-1:-1:-1;;7714:72:40;;;;;;;;;;;;;;;-1:-1:-1;;;;;7714:72:40;-1:-1:-1;;;7714:72:40;;;8049:25;;7714:72;;-1:-1:-1;7714:72:40;;-1:-1:-1;;7972:4:40;7945:5;7913:231;7892:266;8214:4;8196:16;8192:27;8248:4;8242:11;8232:21;;8291:12;8283:6;8279:25;8273:4;8266:39;8347:12;8341:4;8333:6;8318:42;;8390:4;8384:11;8374:67;;8431:6;8425:13;8418:4;8410:6;8406:17;8399:40;1637:228;1752:58;;-1:-1:-1;;;1752:58:40;;1737:12;;-1:-1:-1;;;;;1752:30:40;;;;;:58;;1783:6;;1791:5;;1798:8;;1737:12;;1752:58;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1737:73;;1825:7;1820:38;;1841:17;;-1:-1:-1;;;1841:17:40;;;;;;;;;;;1820:38;1727:138;1637:228;;;;:::o;3360:229:42:-;3473:16;3519:63;:11;3551:10;3570:9;3519:20;:63::i;5306:226::-;5468:10;5385:4;5451:28;;;:16;:28;;;;;5496:29;5451:28;5516:8;5496:19;:29::i;7905:397::-;8079:4;;8120:39;;;;8131:17;8120:39;:::i;:::-;8224:10;8170:34;8207:28;;;:16;:28;;;;;;;;-1:-1:-1;;;;;;8207:41:42;;;;;;;;;8265:18;-1:-1:-1;;;;;8265:18:42;;;:30;;;;;-1:-1:-1;;7905:397:42;;;;;:::o;15104:355::-;15239:4;;;15298:39;;;;15309:7;15298:39;:::i;:::-;15259:78;;;;15347:12;15362:59;15390:8;15410;15362:15;:59::i;:::-;-1:-1:-1;;;;;15438:14:42;;;;;;;;-1:-1:-1;;;;15104:355:42;;;;;:::o;24214:378:37:-;24383:12;24455:4;24448:12;;24481:4;24474:12;;24500:15;24556:8;24566:7;24539:35;;;;;;;;;:::i;:::-;;;;;;;-1:-1:-1;;24539:35:37;;;;;;;24529:46;;24539:35;24529:46;;;;-1:-1:-1;;;;;;25711:15:54;;;24418:167:37;;;25699:28:54;;;;25756:15;;;;25743:11;;;25736:36;25788:11;;;25781:27;25824:12;;;25817:28;25861:12;;24418:167:37;;;;;;;;;;;;24411:174;;24214:378;;;;;:::o;12339:769::-;12452:22;12504:26;12544:17;12575;12606:25;;12644:18;12655:6;12644:10;:18::i;:::-;12732:24;;;;;;12676:117;;-1:-1:-1;;;12676:117:37;;12490:172;;-1:-1:-1;12490:172:37;;-1:-1:-1;12490:172:37;;-1:-1:-1;12490:172:37;-1:-1:-1;12490:172:37;-1:-1:-1;12690:10:37;;12676:42;;:117;;12490:172;;;;;;12676:117;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12672:430;;13042:49;13062:4;13068:10;13080;13042:19;:49::i;:::-;13025:66;;12672:430;;;12943:50;12963:5;12970:10;12982;12943:19;:50::i;:::-;12926:67;;12672:430;12480:628;;;;;12339:769;;;:::o;1297:468:43:-;1462:10;1452:21;;;;:9;:21;;;;;;:32;;-1:-1:-1;;;;;;1452:32:43;-1:-1:-1;;;;;1452:32:43;;;;;1622:63;1494:202;;1462:10;1452:32;;1622:63;;1663:9;;1674;;;;1622:63;;;:::i;:::-;;;;-1:-1:-1;;1622:63:43;;;;;;;;;;;;;;-1:-1:-1;;;;;1622:63:43;-1:-1:-1;;;1622:63:43;;;1494:5;:202::i;:::-;1711:47;;-1:-1:-1;;;;;1711:47:43;;;1737:10;;1711:47;;;;;1297:468;;;;:::o;2188:2068:41:-;2717:10;1033:4:33;1060:31;;;:22;;:31;:22;:31;;;2425:10:41;;-1:-1:-1;;;;;1060:31:33;2670:494:41;;2746:41;:11;2774:10;2746:16;:41::i;:::-;2806:9;2801:271;2821:6;2817:1;:10;2801:271;;;2852:29;2884:10;;2895:1;2884:13;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;2852:45;-1:-1:-1;3002:55:41;3020:16;;;;2852:45;3020:16;:::i;:::-;3038:18;;;;:9;:18;:::i;:::-;3002:17;:55::i;:::-;-1:-1:-1;;2829:3:41;;2801:271;;;;2670:494;;;3092:11;;3088:76;;3126:27;;-1:-1:-1;;;3126:27:41;;3142:10;3126:27;;;269:51:54;242:18;;3126:27:41;123:203:54;3088:76:41;3241:10;3174:47;3224:28;;;:16;:28;;;;;3314:17;3224:28;3314:15;:17::i;:::-;3351:9;;-1:-1:-1;3382:9:41;3377:250;3397:6;3393:1;:10;3377:250;;;3424:28;3455:9;;3465:1;3455:12;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;3424:43;-1:-1:-1;3564:52:41;3581:15;;;;3424:43;3581:15;:::i;:::-;3598:17;;;;:8;:17;:::i;:::-;3564:16;:52::i;:::-;-1:-1:-1;;3405:3:41;;3377:250;;;-1:-1:-1;3646:9:41;;-1:-1:-1;3677:9:41;3672:260;3692:6;3688:1;:10;3672:260;;;3719:29;3751:9;;3761:1;3751:12;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;3719:44;-1:-1:-1;3860:61:41;3884:16;;;;3719:44;3884:16;:::i;:::-;3902:18;;;;:9;:18;:::i;:::-;3860:23;:61::i;:::-;-1:-1:-1;;3700:3:41;;3672:260;;;-1:-1:-1;3951:5:41;;-1:-1:-1;3978:9:41;3973:230;3993:6;3989:1;:10;3973:230;;;4020:24;4047:5;;4053:1;4047:8;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;4020:35;-1:-1:-1;4152:40:41;4165:11;;;;4020:35;4165:11;:::i;:::-;4178:13;;;;:4;:13;:::i;:::-;4152:12;:40::i;:::-;-1:-1:-1;;4001:3:41;;3973:230;;;-1:-1:-1;4218:31:41;;4238:10;;4218:31;;;;;2398:1858;;2188:2068;;;;;;;;:::o;673:213:33:-;93:3;1033:4;1060:22;;;;;;;;;;;-1:-1:-1;;;;;1060:31:33;;;;;;;;;;;;:47;750:77;;796:31;;-1:-1:-1;;;796:31:33;;;;;;;;;;;750:77;93:3;837:12;:22;;;;;;;;;;;-1:-1:-1;;;;;837:31:33;;;;;;;;;;;;:42;;-1:-1:-1;;;;;;837:42:33;;;;;;673:213::o;1442:480::-;-1:-1:-1;;;;;1541:24:33;;;;:48;;-1:-1:-1;;;;;;1569:20:33;;93:3;1569:20;1541:48;1537:119;;;1612:33;;-1:-1:-1;;;1612:33:33;;-1:-1:-1;;;;;287:32:54;;1612:33:33;;;269:51:54;242:18;;1612:33:33;123:203:54;1537:119:33;-1:-1:-1;;;;;1669:22:33;;;139:3;1669:22;;;;;;;;;;;:31;;;;;;;;;;;;:47;1665:124;;1739:39;;-1:-1:-1;;;1739:39:33;;-1:-1:-1;;;;;287:32:54;;1739:39:33;;;269:51:54;242:18;;1739:39:33;123:203:54;1665:124:33;93:3;1832:12;:22;;;;;;;;;;;-1:-1:-1;;;;;1832:31:33;;;;;;;;;;;;;;1798:22;;;;;;;;;;;;:31;;;;;;;;;;:65;;1832:31;;;;-1:-1:-1;;;;;;1798:65:33;;;;;;;1873:31;:42;;;;;;;;1442:480::o;2738:1781::-;2929:22;2953:12;-1:-1:-1;;;;;2985:17:33;;93:3;2985:17;;;;:52;;;3007:30;3016:4;3022:7;3031:5;3007:8;:30::i;:::-;3006:31;2985:52;2981:120;;;3060:30;;-1:-1:-1;;;3060:30:33;;-1:-1:-1;;;;;287:32:54;;3060:30:33;;;269:51:54;242:18;;3060:30:33;123:203:54;2981:120:33;3114:8;3126:1;3114:13;3110:50;;3136:24;;-1:-1:-1;;;3136:24:33;;;;;;;;;;;3110:50;3233:8;-1:-1:-1;;;;;3219:23:33;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;3219:23:33;-1:-1:-1;;;;;;3325:19:33;;;3286:18;3325:19;;;;;;;;;;;:28;;;;;;;;;;;3211:31;;-1:-1:-1;3325:28:33;;;-1:-1:-1;3363:197:33;-1:-1:-1;;;;;3370:20:33;;;;;;:40;;-1:-1:-1;;;;;;3394:16:33;;93:3;3394:16;;3370:40;:65;;;;;3427:8;3414:10;:21;3370:65;3363:197;;;3471:4;3451:5;3457:10;3451:17;;;;;;;;:::i;:::-;-1:-1:-1;;;;;3451:24:33;;;:17;;;;;;;;;;:24;;;;3496:18;;;:12;:18;;;;;;;;;;:27;;;;;;;;;;;;;;;;;3537:12;;;;:::i;:::-;;;;3363:197;;;-1:-1:-1;;;;;4230:16:33;;93:3;4230:16;4226:75;;4269:5;4275:14;4288:1;4275:10;:14;:::i;:::-;4269:21;;;;;;;;:::i;:::-;;;;;;;4262:28;;4226:75;4492:10;4485:5;4478:25;4464:49;2738:1781;;;;;;;:::o;2134:311:42:-;2312:27;2261:9;276:1:12;675:34:43;690:6;698:10;675:14;:34::i;:::-;2355:62:42::1;:11;2383:10;2405:9:::0;2355:16:::1;:62::i;:::-;2434:4;;2427:11;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;::::0;;;;-1:-1:-1;2427:11:42;;2134:311;-1:-1:-1;;;;;;;;;2134:311:42:o;4550:358::-;4724:27;4675:8;319:1:12;675:34:43;690:6;698:10;675:14;:34::i;:::-;4834:10:42::1;4767:47;4817:28:::0;;;:16:::1;:28;::::0;;;;4855:25:::1;4817:28:::0;4871:8;4855:15:::1;:25::i;:::-;4897:4;;4890:11;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;::::0;;;;-1:-1:-1;4890:11:42;;4550:358;-1:-1:-1;;;;;;;;;;4550:358:42:o;6302:925::-;6499:27;6451:7;362:1:12;675:34:43;690:6;698:10;675:14;:34::i;:::-;6543:18:42::1;::::0;;6619:45:::1;::::0;;::::1;6630:6:::0;6619:45:::1;:::i;:::-;6542:122:::0;;-1:-1:-1;6542:122:42;-1:-1:-1;6542:122:42;-1:-1:-1;;;;;;;6793:41:42;::::1;-1:-1:-1::0;;;6793:41:42::1;::::0;:88:::1;;-1:-1:-1::0;;;;;;;6838:43:42;::::1;-1:-1:-1::0;;;6838:43:42::1;6793:88;6776:158;;;6899:35;::::0;-1:-1:-1;;;6899:35:42;;-1:-1:-1;;;;;;2411:33:54;;6899:35:42::1;::::0;::::1;2393:52:54::0;2366:18;;6899:35:42::1;2249:202:54::0;6776:158:42::1;7391:10:::0;7321:4;7374:28;;;:16;:28;;;;;;;;-1:-1:-1;;;;;;7374:41:42;;;;;;;;;7432:18;-1:-1:-1;;;;;7432:18:42;:32;6944:83:::1;;6997:30;::::0;-1:-1:-1;;;6997:30:42;;-1:-1:-1;;;;;;2411:33:54;;6997:30:42::1;::::0;::::1;2393:52:54::0;2366:18;;6997:30:42::1;2249:202:54::0;6944:83:42::1;7092:10;7038:34;7075:28:::0;;;:16:::1;:28;::::0;;;;;;;-1:-1:-1;;;;;;7075:41:42;;::::1;::::0;;;;;;;;;7126:30;;-1:-1:-1;;;;;7166:28:42;::::1;-1:-1:-1::0;;;;;;7126:30:42::1;::::0;;;::::1;-1:-1:-1::0;;;7126:30:42::1;7166:28:::0;;;;-1:-1:-1;;;;;;7166:28:42;;;;;;;::::1;::::0;;7212:8;-1:-1:-1;6302:925:42;;;;;;;:::o;12781:1306::-;12955:27;12914:4;401:1:12;675:34:43;690:6;698:10;675:14;:34::i;:::-;12999:17:42::1;::::0;;13072:43:::1;::::0;;::::1;13083:4:::0;13072:43:::1;:::i;:::-;12998:117:::0;;-1:-1:-1;12998:117:42;-1:-1:-1;12998:117:42;-1:-1:-1;13125:19:42::1;::::0;13190:8:::1;:27;;;;;;;;:::i;:::-;;:46;;;;-1:-1:-1::0;;;;;;;13221:15:42;::::1;::::0;13190:46:::1;13186:869;;;-1:-1:-1::0;13278:10:42::1;13266:23;::::0;;;:11:::1;:23;::::0;;;;;-1:-1:-1;;;;;13266:23:42::1;13436:25:::0;;13432:104:::1;;13488:33;::::0;-1:-1:-1;;;13488:33:42;;-1:-1:-1;;;;;287:32:54;;13488:33:42::1;::::0;::::1;269:51:54::0;242:18;;13488:33:42::1;123:203:54::0;13432:104:42::1;13561:10;13549:23;::::0;;;:11:::1;:23;::::0;;;;:30;;-1:-1:-1;;;;;;13549:30:42::1;-1:-1:-1::0;;;;;13549:30:42;::::1;;::::0;;13186:869:::1;;;13612:12;13600:8;:24;;;;;;;;:::i;:::-;::::0;13596:459:::1;;-1:-1:-1::0;;;;;13773:25:42;::::1;::::0;13769:104:::1;;13825:33;::::0;-1:-1:-1;;;13825:33:42;;-1:-1:-1;;;;;287:32:54;;13825:33:42::1;::::0;::::1;269:51:54::0;242:18;;13825:33:42::1;123:203:54::0;13769:104:42::1;-1:-1:-1::0;13913:10:42::1;13900:24;::::0;;;:12:::1;:24;::::0;;;;;;;-1:-1:-1;;;;;;13900:34:42;::::1;::::0;;;;;;;;;-1:-1:-1;;;;;13948:41:42;;::::1;-1:-1:-1::0;;;;;;13948:41:42;::::1;;::::0;;;13900:34:::1;13596:459;;;14027:17;;-1:-1:-1::0;;;14027:17:42::1;;;;;;;;;;;13596:459;-1:-1:-1::0;14072:8:42;12781:1306;-1:-1:-1;;;;;;;;12781:1306:42:o;15766:3129::-;15890:28;16367:20;;16351:37;;16435:2;16418:20;;;;16467:25;;16515:15;;;16575:20;16559:37;;16628:20;;;;16680:25;;;16728:15;;;16788:20;16772:37;;16847:20;;;;16905:25;16467;16993;;;16989:52;;17027:14;;-1:-1:-1;;;17027:14:42;;;;;;;;;;;16989:52;17057:9;17052:1795;17072:6;17068:1;:10;17052:1795;;;17099:13;17115:5;;17121:1;17115:8;;;;;;;:::i;:::-;;;;;;;17099:24;;276:1:12;17448:5:42;:30;17444:1393;;17498:38;17516:6;17524:8;;17533:1;17524:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;17498:38::-;;17444:1393;;;319:1:12;17879:5:42;:29;17875:962;;17928:37;17945:6;17953:8;;17962:1;17953:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;17875:962::-;362:1:12;18308:5:42;:29;18304:533;;18357:44;18381:6;18389:8;;18398:1;18389:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;18304:533::-;401:1:12;18744:5:42;:25;18740:97;;18789:33;18802:6;18810:8;;18819:1;18810:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;18789:33::-;;18740:97;-1:-1:-1;17080:3:42;;17052:1795;;;;18874:14;;18856:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;18856:32:42;;15766:3129;-1:-1:-1;;;;;;;;;;;;;;15766:3129:42:o;1871:217:40:-;1979:54;;-1:-1:-1;;;1979:54:40;;1964:12;;-1:-1:-1;;;;;1979:30:40;;;;;:54;;2010:6;;1964:12;;2021:8;;2031:1;;1979:54;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;1964:69;;2048:7;2043:38;;2064:17;;-1:-1:-1;;;2064:17:40;;;;;;;;;;;2787:344:42;2912:27;2955:12;3002:34;;;;3013:4;3002:34;:::i;:::-;2977:59;-1:-1:-1;2977:59:42;-1:-1:-1;3046:78:42;:11;3073:10;2977:59;3112:9;3046:15;:78::i;:::-;2945:186;2787:344;;;;;:::o;4914:386::-;5149:10;5082:47;5132:28;;;:16;:28;;;;;5037:29;;5219:34;;;;5230:4;5219:34;:::i;:::-;5192:61;-1:-1:-1;5192:61:42;-1:-1:-1;5263:30:42;:10;5192:61;5284:8;5263:14;:30::i;7477:422::-;7625:29;7670:18;7732:36;;;;7743:7;7732:36;:::i;:::-;7833:10;7779:34;7816:28;;;:16;:28;;;;;;;;-1:-1:-1;;;;;;7816:41:42;;;;;;;;;;;;7867:25;;-1:-1:-1;;;;;;7867:25:42;;;7698:70;7477:422;-1:-1:-1;;;;;7477:422:42:o;14093:592::-;14224:29;14269:17;;14362:43;;;;14373:4;14362:43;:::i;:::-;14321:84;-1:-1:-1;14321:84:42;;-1:-1:-1;14321:84:42;-1:-1:-1;14431:15:42;14419:8;:27;;;;;;;;:::i;:::-;;:46;;;;-1:-1:-1;;;;;;;14450:15:42;;;14419:46;14415:264;;;14500:10;14488:23;;;;:11;:23;;;;;14481:30;;-1:-1:-1;;;;;;14481:30:42;;;14415:264;;;14544:12;14532:8;:24;;;;;;;;:::i;:::-;;14528:151;;14592:10;14579:24;;;;:12;:24;;;;;;;;-1:-1:-1;;;;;;14579:34:42;;;;;;;;;14572:41;;-1:-1:-1;;;;;;14572:41:42;;;14528:151;;4793:228:40;4904:54;;-1:-1:-1;;;4904:54:40;;4889:12;;-1:-1:-1;;;;;4904:30:40;;;;;:54;;4935:6;;4889:12;;4946:8;;4956:1;;4904:54;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;4889:69;;4973:7;4968:46;;4987:27;;;-1:-1:-1;;;;;31529:32:54;;31511:51;;5012:1:40;31593:2:54;31578:18;;31571:34;-1:-1:-1;;;;;;;;;;;4987:27:40;31484:18:54;4987:27:40;;;;;;;4879:142;4793:228;;;:::o;901:331:43:-;1015:10;985:17;1005:21;;;:9;:21;;;;;;-1:-1:-1;;;;;1005:21:43;1040:31;;1036:190;;1159:56;;-1:-1:-1;;;1159:56:43;;1184:10;1159:56;;;31856:34:54;-1:-1:-1;;;;;31926:15:54;;;31906:18;;;31899:43;31958:18;;;31951:34;;;1159:24:43;;;;;31791:18:54;;1159:56:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1036:190;975:257;901:331;;:::o;7187:3574:37:-;7346:26;7687:28;:8;3306:4:52;7687:28:37;:::i;:::-;7683:3072;;;7777:26;:8;-1:-1:-1;;;7777:26:37;:::i;:::-;7773:1099;;;867:29:51;;846:51;;999:2;982:20;;;1040:25;7920:42:37;7938:10;982:20:51;1040:25;7920:11:37;:42::i;:::-;7906:56;;7805:172;;7683:3072;;7773:1099;8040:27;:8;2726:4:52;8040:27:37;:::i;:::-;8036:836;;;8088:14;8104:13;8119:23;;8166:32;:17;;:30;:32::i;:::-;8230:14;;;8242:1;8230:14;;;;;;;;;8087:111;;-1:-1:-1;8087:111:37;;-1:-1:-1;8087:111:37;;-1:-1:-1;8087:111:37;-1:-1:-1;8230:14:37;;;;;;;;;;;;;;;;;;;;8216:28;;8279:55;8297:10;8310:6;8318:5;8325:8;;8279:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;8279:11:37;;-1:-1:-1;;;8279:55:37:i;:::-;8262:11;8274:1;8262:14;;;;;;;;:::i;:::-;;;;;;:72;;;;8069:280;;;;7683:3072;;8036:836;8414:33;:8;-1:-1:-1;;;;;;8414:33:37;:::i;:::-;8410:462;;;8467:14;8500:22;8519:2;8467:14;8500:17;;:22;:::i;:::-;8492:31;;;:::i;:::-;8484:40;;;-1:-1:-1;8542:23:37;;8568:22;:17;8586:2;8568:17;;:22;:::i;:::-;8622:14;;;8634:1;8622:14;;;;;;;;;8542:48;;-1:-1:-1;8542:48:37;;-1:-1:-1;8622:14:37;;;;;;;;;;;;;;;;;;;;8608:28;;8671:56;8697:10;8710:6;8718:8;;8671:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;8671:19:37;;-1:-1:-1;;;8671:56:37:i;:::-;8654:11;8666:1;8654:14;;;;;;;;:::i;:::-;;;;;;:73;;;;8449:293;;;7683:3072;;8410:462;8828:29;;-1:-1:-1;;;8828:29:37;;-1:-1:-1;;;;;;22355:26:54;;8828:29:37;;;22337:45:54;22310:18;;8828:29:37;22162:226:54;7683:3072:37;9194:24;:8;-1:-1:-1;;;9194:24:37;:::i;:::-;9190:1565;;;9276:26;:8;-1:-1:-1;;;9276:26:37;:::i;:::-;9272:1104;;;867:29:51;;846:51;;999:2;982:20;;;1040:25;9423:45:37;9444:10;982:20:51;1040:25;9423:14:37;:45::i;:::-;9405:63;-1:-1:-1;9190:1565:37;;-1:-1:-1;;;9190:1565:37;9272:1104;9542:27;:8;2726:4:52;9542:27:37;:::i;:::-;9538:838;;;9590:14;9606:13;9621:23;;9668:32;:17;;:30;:32::i;:::-;9732:14;;;9744:1;9732:14;;;;;;;;;9589:111;;-1:-1:-1;9589:111:37;;-1:-1:-1;9589:111:37;;-1:-1:-1;9589:111:37;-1:-1:-1;9732:14:37;;;;;;;;;;;;;;;;;;;;9718:28;;9781:58;9802:10;9815:6;9823:5;9830:8;;9781:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;9781:14:37;;-1:-1:-1;;;9781:58:37:i;9538:838::-;9915:33;:8;-1:-1:-1;;;;;;9915:33:37;:::i;:::-;9911:465;;;9968:14;10001:22;10020:2;9968:14;10001:17;;:22;:::i;:::-;9993:31;;;:::i;:::-;9985:40;;;-1:-1:-1;10043:23:37;;10069:22;:17;10087:2;10069:17;;:22;:::i;:::-;10123:14;;;10135:1;10123:14;;;;;;;;;10043:48;;-1:-1:-1;10043:48:37;;-1:-1:-1;10123:14:37;;;;;;;;;;;;;;;;;;;;10109:28;;10172:59;10201:10;10214:6;10222:8;;10172:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;10172:22:37;;-1:-1:-1;;;10172:59:37:i;9190:1565::-;10715:29;;-1:-1:-1;;;10715:29:37;;-1:-1:-1;;;;;;22355:26:54;;10715:29:37;;;22337:45:54;22310:18;;10715:29:37;22162:226:54;1395:236:40;1534:4;;1562:51;;1474:150;;1508:4;;-1:-1:-1;;;;;1534:4:40;;;;1562:51;;1602:10;;;;1562:51;;;:::i;:::-;;;;-1:-1:-1;;1562:51:40;;;;;;;;;;;;;;-1:-1:-1;;;;;1562:51:40;-1:-1:-1;;;1562:51:40;;;1474:13;:150::i;1269:333:51:-;1372:14;;1403:23;1372:14;1467:23;1487:2;1372:14;1467:17;;:23;:::i;:::-;1459:32;;;:::i;:::-;1451:41;;;-1:-1:-1;1526:24:51;1547:2;1544;1526:17;;:24;:::i;:::-;1518:33;;;:::i;:::-;1510:42;-1:-1:-1;1573:22:51;:17;1591:2;1573:17;;:22;:::i;:::-;1269:333;;;;-1:-1:-1;1562:33:51;-1:-1:-1;;;1269:333:51:o;4297:245:40:-;4442:4;;4470:54;;4379:156;;4416:4;;-1:-1:-1;;;;;4442:4:40;;;;4470:54;;4513:10;;;;4470:54;;;:::i;:::-;;;;-1:-1:-1;;4470:54:40;;;;;;;;;;;;;;-1:-1:-1;;;;;4470:54:40;-1:-1:-1;;;4470:54:40;;;4379:16;:156::i;4548:239::-;4666:58;;-1:-1:-1;;;4666:58:40;;4651:12;;-1:-1:-1;;;;;4666:30:40;;;;;:58;;4697:6;;4705:5;;4712:8;;4651:12;;4666:58;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;4651:73;;4739:7;4734:46;;4753:27;;;-1:-1:-1;;;;;31529:32:54;;31511:51;;4778:1:40;31593:2:54;31578:18;;31571:34;-1:-1:-1;;;;;;;;;;;4753:27:40;31484:18:54;4753:27:40;;;;;;;4641:146;4548:239;;;;:::o;2022:1705:32:-;2188:22;2212:12;-1:-1:-1;;;;;2244:17:32;;93:3;2244:17;;;;:43;;;2266:21;2275:4;2281:5;2266:8;:21::i;:::-;2265:22;2244:43;2240:86;;;2296:30;;-1:-1:-1;;;2296:30:32;;-1:-1:-1;;;;;287:32:54;;2296:30:32;;;269:51:54;242:18;;2296:30:32;123:203:54;2240:86:32;2340:8;2352:1;2340:13;2336:50;;2362:24;;-1:-1:-1;;;2362:24:32;;;;;;;;;;;2336:50;2459:8;-1:-1:-1;;;;;2445:23:32;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2445:23:32;-1:-1:-1;;;;;;2551:19:32;;;2512:18;2551:19;;;;;;;;;;;2437:31;;-1:-1:-1;2551:19:32;;;-1:-1:-1;2580:188:32;-1:-1:-1;;;;;2587:20:32;;;;;;:40;;-1:-1:-1;;;;;;2611:16:32;;93:3;2611:16;;2587:40;:65;;;;;2644:8;2631:10;:21;2587:65;2580:188;;;2688:4;2668:5;2674:10;2668:17;;;;;;;;:::i;:::-;-1:-1:-1;;;;;2668:24:32;;;:17;;;;;;;;;;:24;;;;2713:18;;;:12;:18;;;;;;;;;;;;;;;;2745:12;;;;:::i;:::-;;;;2580:188;;;-1:-1:-1;;;;;3438:16:32;;93:3;3438:16;3434:75;;3477:5;3483:14;3496:1;3483:10;:14;:::i;:::-;3477:21;;;;;;;;:::i;:::-;;;;;;;3470:28;;3434:75;3700:10;3693:5;3686:25;3672:49;2022:1705;;;;;;:::o;2479:253:33:-;2633:4;93:3;-1:-1:-1;;;;;2660:17:33;;;;;;:65;;-1:-1:-1;;;;;;;2681:19:33;;;139:3;2681:19;;;;;;;;;;;:28;;;;;;;;;;;;;:44;;;2479:253::o;1847:169:32:-;1930:4;93:3;-1:-1:-1;;;;;1953:17:32;;;;;;:56;;-1:-1:-1;;;;;;;1974:19:32;;;139:3;1974:19;;;;;;;;;;;;;;:35;;;1847:169::o;14691:407:42:-;14821:12;;14884:8;:27;;;;;;;;:::i;:::-;;:46;;;;-1:-1:-1;;;;;;;14915:15:42;;;14884:46;14880:107;;;-1:-1:-1;14965:10:42;14953:23;;;;:11;:23;;;;;;-1:-1:-1;;;;;14953:23:42;14880:107;15012:12;15000:8;:24;;;;;;;;:::i;:::-;;14996:96;;-1:-1:-1;15060:10:42;15047:24;;;;:12;:24;;;;;;;;-1:-1:-1;;;;;;15047:34:42;;;;;;;;;;-1:-1:-1;;;;;15047:34:42;14691:407;;;;:::o;20508:3201:37:-;20625:26;20665:17;;20727:25;20665:17;20727:25;20665:17;20996:16;;;;:6;:16;:::i;:::-;20975:37;;-1:-1:-1;20975:37:37;-1:-1:-1;21053:8:37;21059:1;21057;20975:37;;21053:8;:::i;:::-;21046:16;;;:::i;:::-;21039:24;;;-1:-1:-1;21104:9:37;21110:2;21108:1;21104:3;;:9;:::i;:::-;21097:17;;;:::i;:::-;21090:25;;;-1:-1:-1;21142:8:37;:3;21146:2;21142:3;;:8;:::i;:::-;21129:21;;;;20961:200;;22158:40;22201:793;;;;;;;;98:66:50;22249:16:37;;22201:793;;;;22289:10;-1:-1:-1;;;;;22201:793:37;;;;;22324:6;:12;;;22201:793;;;;22378:6;:15;;;;;;;;:::i;:::-;22368:26;;;;;;;:::i;:::-;;;;;;;;;22201:793;;;;22436:15;;;;:6;:15;:::i;:::-;22426:26;;;;;;;:::i;:::-;;;;;;;;22201:793;;;;22484:27;:6;:25;:27::i;:::-;22201:793;;;;22551:35;:6;:33;:35::i;:::-;22201:793;;;;22624:6;:25;;;22201:793;;;;22681:27;:6;:25;:27::i;:::-;22201:793;;;;22748:35;:6;:33;:35::i;:::-;22201:793;;;;22833:23;;;;:6;:23;:::i;:::-;22823:34;;;;;;;:::i;:::-;;;;;;;;22201:793;;;;22887:10;22201:793;;;;;;22927:10;22201:793;;;;;;22967:12;981:42:39;;895:135;22967:12:37;-1:-1:-1;;;;;22201:793:37;;;23547:3;23522:29;;22158:836;;-1:-1:-1;;;;;;;23656:17:37;:15;:17::i;:::-;23611:81;;-1:-1:-1;;;;;;25711:15:54;;;23611:81:37;;;25699:28:54;25756:15;;;;25743:11;;;25736:36;25788:11;;;25781:27;25824:12;;;25817:28;;;25861:12;;23611:81:37;;;;;;;;;;;;23579:113;;21680:2023;;20508:3201;;;;;;;:::o;2448:248:0:-;2559:7;2683:8;2667:10;2659:19;;:33;;2643:3;2628:10;2620:19;;:26;;2590:9;:17;;2606:1;2590:17;;;2602:1;2590:17;2589:58;;;:104;;2448:248;-1:-1:-1;;;;2448:248:0:o;440:178:32:-;93:3;702:4;725:22;;;;;;;;;;;-1:-1:-1;;;;;725:22:32;:38;500:68;;537:31;;-1:-1:-1;;;537:31:32;;;;;;;;;;;500:68;93:3;578:12;:22;;;;;;;;;;;;:33;;-1:-1:-1;;;;;;578:33:32;;;;;;440:178::o;1014:403::-;-1:-1:-1;;;;;1096:24:32;;;;:48;;-1:-1:-1;;;;;;1124:20:32;;93:3;1124:20;1096:48;1092:119;;;1167:33;;-1:-1:-1;;;1167:33:32;;-1:-1:-1;;;;;287:32:54;;1167:33:32;;;269:51:54;242:18;;1167:33:32;123:203:54;1092:119:32;-1:-1:-1;;;;;1224:22:32;;;139:3;1224:22;;;;;;;;;;;;:38;1220:90;;1271:39;;-1:-1:-1;;;1271:39:32;;-1:-1:-1;;;;;287:32:54;;1271:39:32;;;269:51:54;242:18;;1271:39:32;123:203:54;1220:90:32;93:3;1345:12;:22;;;;;;;;;;;;;;-1:-1:-1;;;;;1320:22:32;;;;;;;;;:47;;1345:22;;;;-1:-1:-1;;;;;;1320:47:32;;;;;;1377:22;;;;:33;;;;;;;;;;1014:403::o;1928:545:33:-;-1:-1:-1;;;;;2095:24:33;;;;:48;;-1:-1:-1;;;;;;2123:20:33;;93:3;2123:20;2095:48;2091:120;;;2166:34;;-1:-1:-1;;;2166:34:33;;-1:-1:-1;;;;;287:32:54;;2166:34:33;;;269:51:54;242:18;;2166:34:33;123:203:54;2091:120:33;-1:-1:-1;;;;;2224:23:33;;;:12;:23;;;;;;;;;;;:32;;;;;;;;;;;;;:44;;;;2220:115;;2291:33;;-1:-1:-1;;;2291:33:33;;-1:-1:-1;;;;;287:32:54;;2291:33:33;;;269:51:54;242:18;;2291:33:33;123:203:54;2220:115:33;-1:-1:-1;;;;;2379:22:33;;;:12;:22;;;;;;;;;;;:31;;;;;;;;;;;;;;2344:23;;;;;;;;;;;:32;;;;;;;;:66;;2379:31;;;;-1:-1:-1;;;;;;2344:66:33;;;;;;;2420:31;;;;:46;;;;;1928:545::o;1423:418:32:-;-1:-1:-1;;;;;1523:24:32;;;;:48;;-1:-1:-1;;;;;;1551:20:32;;93:3;1551:20;1523:48;1519:120;;;1594:34;;-1:-1:-1;;;1594:34:32;;-1:-1:-1;;;;;287:32:54;;1594:34:32;;;269:51:54;242:18;;1594:34:32;123:203:54;1519:120:32;-1:-1:-1;;;;;1652:23:32;;;:12;:23;;;;;;;;;;;;;:35;;;;1648:81;;1696:33;;-1:-1:-1;;;1696:33:32;;-1:-1:-1;;;;;287:32:54;;1696:33:32;;;269:51:54;242:18;;1696:33:32;123:203:54;1648:81:32;-1:-1:-1;;;;;1765:22:32;;;:12;:22;;;;;;;;;;;;;;1739:23;;;;;;;;:48;;1765:22;;;;-1:-1:-1;;;;;;1739:48:32;;;;;;;1797:22;;;:37;;;;;1423:418::o;2637:396:40:-;2798:16;2883:4;;2911:57;;2759:23;;2798:16;2817:162;;2857:4;;-1:-1:-1;;;;;2883:4:40;;2911:57;;2957:10;;;;2911:57;;;:::i;:::-;;;;-1:-1:-1;;2911:57:40;;;;;;;;;;;;;;-1:-1:-1;;;;;2911:57:40;-1:-1:-1;;;2911:57:40;;;2817:19;:162::i;:::-;2798:181;;3011:3;3000:26;;;;;;;;;;;;:::i;:::-;2989:37;2637:396;-1:-1:-1;;;;;2637:396:40:o;3406:342::-;3550:20;3586:12;3629:4;-1:-1:-1;;;;;3629:40:40;;3670:6;3678:1;3681:8;3691:1;3629:64;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;3629:64:40;;;;;;;;;;;;:::i;:::-;3608:85;-1:-1:-1;3608:85:40;-1:-1:-1;3608:85:40;3703:38;;3724:17;;-1:-1:-1;;;3724:17:40;;;;;;;;;;;5571:447;5696:21;5719:23;5758:16;5777:168;5820:4;5846;;;;;;;;-1:-1:-1;;;;;5846:4:40;5923:10;;5874:60;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;5874:60:40;;;;;;;;;;;;;;-1:-1:-1;;;;;5874:60:40;-1:-1:-1;;;5874:60:40;;;5777:22;:168::i;:::-;5758:187;;5988:3;5977:34;;;;;;;;;;;;:::i;:::-;5955:56;;;;-1:-1:-1;5571:447:40;-1:-1:-1;;;;;5571:447:40:o;6024:372::-;6186:20;6222:12;6265:4;-1:-1:-1;;;;;6265:40:40;;6306:6;6314:5;6321:8;6331:1;6265:68;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;6265:68:40;;;;;;;;;;;;:::i;:::-;6244:89;-1:-1:-1;6244:89:40;-1:-1:-1;6244:89:40;6343:46;;6362:27;;;-1:-1:-1;;;;;31529:32:54;;31511:51;;6387:1:40;31593:2:54;31578:18;;31571:34;-1:-1:-1;;;;;;;;;;;6362:27:40;31484:18:54;6362:27:40;;;;;;;6212:184;6024:372;;;;;;:::o;6402:353::-;6549:20;6585:12;6628:4;-1:-1:-1;;;;;6628:40:40;;6669:6;6677:1;6680:8;6690:1;6628:64;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;6628:64:40;;;;;;;;;;;;:::i;:::-;6607:85;-1:-1:-1;6607:85:40;-1:-1:-1;6607:85:40;6702:46;;6721:27;;;-1:-1:-1;;;;;31529:32:54;;31511:51;;6746:1:40;31593:2:54;31578:18;;31571:34;-1:-1:-1;;;;;;;;;;;6721:27:40;31484:18:54;6721:27:40;;;;;;;6575:180;6402:353;;;;;:::o;3587:162:1:-;3679:7;-1:-1:-1;;;;;3718:23:1;;;;3039:31;3705:37;2959:118;3410:171;3510:7;3536:38;3550:6;:23;;;2887:3;2868:22;;2780:117;3251:153;3343:7;-1:-1:-1;;;;;3382:14:1;;;;3039:31;3369:28;2959:118;3083:162;3183:7;3223:14;;;;2887:3;2868:22;3209:29;2780:117;331:131:54;-1:-1:-1;;;;;406:31:54;;396:42;;386:70;;452:1;449;442:12;386:70;331:131;:::o;467:134::-;535:20;;564:31;535:20;564:31;:::i;606:347::-;657:8;667:6;721:3;714:4;706:6;702:17;698:27;688:55;;739:1;736;729:12;688:55;-1:-1:-1;762:20:54;;-1:-1:-1;;;;;794:30:54;;791:50;;;837:1;834;827:12;791:50;874:4;866:6;862:17;850:29;;926:3;919:4;910:6;902;898:19;894:30;891:39;888:59;;;943:1;940;933:12;958:612;1046:6;1054;1062;1070;1123:2;1111:9;1102:7;1098:23;1094:32;1091:52;;;1139:1;1136;1129:12;1091:52;1175:9;1162:23;1152:33;;1235:2;1224:9;1220:18;1207:32;1248:31;1273:5;1248:31;:::i;:::-;1298:5;-1:-1:-1;1354:2:54;1339:18;;1326:32;-1:-1:-1;;;;;1370:30:54;;1367:50;;;1413:1;1410;1403:12;1367:50;1452:58;1502:7;1493:6;1482:9;1478:22;1452:58;:::i;:::-;958:612;;;;-1:-1:-1;1529:8:54;-1:-1:-1;;;;958:612:54:o;1767:477::-;1846:6;1854;1862;1915:2;1903:9;1894:7;1890:23;1886:32;1883:52;;;1931:1;1928;1921:12;1883:52;1967:9;1954:23;1944:33;;2028:2;2017:9;2013:18;2000:32;-1:-1:-1;;;;;2047:6:54;2044:30;2041:50;;;2087:1;2084;2077:12;2041:50;2126:58;2176:7;2167:6;2156:9;2152:22;2126:58;:::i;:::-;1767:477;;2203:8;;-1:-1:-1;2100:84:54;;-1:-1:-1;;;;1767:477:54:o;2456:534::-;2571:6;2579;2587;2640:2;2628:9;2619:7;2615:23;2611:32;2608:52;;;2656:1;2653;2646:12;2608:52;2696:9;2683:23;-1:-1:-1;;;;;2721:6:54;2718:30;2715:50;;;2761:1;2758;2751:12;2715:50;2784:22;;2840:3;2822:16;;;2818:26;2815:46;;;2857:1;2854;2847:12;2815:46;2880:2;2929;2914:18;;2901:32;;-1:-1:-1;2980:2:54;2965:18;;;2952:32;;2456:534;-1:-1:-1;;;2456:534:54:o;3177:386::-;3259:8;3269:6;3323:3;3316:4;3308:6;3304:17;3300:27;3290:55;;3341:1;3338;3331:12;3290:55;-1:-1:-1;3364:20:54;;-1:-1:-1;;;;;3396:30:54;;3393:50;;;3439:1;3436;3429:12;3393:50;3476:4;3468:6;3464:17;3452:29;;3536:3;3529:4;3519:6;3516:1;3512:14;3504:6;3500:27;3496:38;3493:47;3490:67;;;3553:1;3550;3543:12;3568:160;3633:5;3678:2;3669:6;3664:3;3660:16;3656:25;3653:45;;;3694:1;3691;3684:12;3653:45;-1:-1:-1;3716:6:54;3568:160;-1:-1:-1;3568:160:54:o;3733:1850::-;4093:6;4101;4109;4117;4125;4133;4141;4149;4157;4210:3;4198:9;4189:7;4185:23;4181:33;4178:53;;;4227:1;4224;4217:12;4178:53;4267:9;4254:23;-1:-1:-1;;;;;4337:2:54;4329:6;4326:14;4323:34;;;4353:1;4350;4343:12;4323:34;4392:89;4473:7;4464:6;4453:9;4449:22;4392:89;:::i;:::-;4500:8;;-1:-1:-1;4366:115:54;-1:-1:-1;4588:2:54;4573:18;;4560:32;;-1:-1:-1;4604:16:54;;;4601:36;;;4633:1;4630;4623:12;4601:36;4672:91;4755:7;4744:8;4733:9;4729:24;4672:91;:::i;:::-;4782:8;;-1:-1:-1;4646:117:54;-1:-1:-1;4870:2:54;4855:18;;4842:32;;-1:-1:-1;4886:16:54;;;4883:36;;;4915:1;4912;4905:12;4883:36;4954:91;5037:7;5026:8;5015:9;5011:24;4954:91;:::i;:::-;5064:8;;-1:-1:-1;4928:117:54;-1:-1:-1;5152:2:54;5137:18;;5124:32;;-1:-1:-1;5168:16:54;;;5165:36;;;5197:1;5194;5187:12;5165:36;5236:91;5319:7;5308:8;5297:9;5293:24;5236:91;:::i;:::-;5346:8;;-1:-1:-1;5210:117:54;-1:-1:-1;5434:3:54;5419:19;;5406:33;;-1:-1:-1;5451:16:54;;;5448:36;;;5480:1;5477;5470:12;5448:36;;5503:74;5569:7;5558:8;5547:9;5543:24;5503:74;:::i;:::-;5493:84;;;3733:1850;;;;;;;;;;;:::o;5588:487::-;5705:6;5713;5766:2;5754:9;5745:7;5741:23;5737:32;5734:52;;;5782:1;5779;5772:12;5734:52;5822:9;5809:23;-1:-1:-1;;;;;5847:6:54;5844:30;5841:50;;;5887:1;5884;5877:12;5841:50;5926:89;6007:7;5998:6;5987:9;5983:22;5926:89;:::i;:::-;6034:8;;5900:115;;-1:-1:-1;5588:487:54;-1:-1:-1;;;;5588:487:54:o;6080:315::-;6148:6;6156;6209:2;6197:9;6188:7;6184:23;6180:32;6177:52;;;6225:1;6222;6215:12;6177:52;6264:9;6251:23;6283:31;6308:5;6283:31;:::i;:::-;6333:5;6385:2;6370:18;;;;6357:32;;-1:-1:-1;;;6080:315:54:o;6400:761::-;6618:2;6630:21;;;6700:13;;6603:18;;;6722:22;;;6570:4;;6797;;6775:2;6760:18;;;6824:17;;;6570:4;6869:195;6883:6;6880:1;6877:13;6869:195;;;6948:13;;-1:-1:-1;;;;;6944:39:54;6932:52;;7004:12;;;;7039:15;;;;6980:1;6898:9;6869:195;;;-1:-1:-1;;;;;;;;7122:32:54;;;;7115:4;7100:20;;;;7093:62;;;;-1:-1:-1;7081:3:54;;6400:761;-1:-1:-1;;6400:761:54:o;7166:250::-;7251:1;7261:113;7275:6;7272:1;7269:13;7261:113;;;7351:11;;;7345:18;7332:11;;;7325:39;7297:2;7290:10;7261:113;;;-1:-1:-1;;7408:1:54;7390:16;;7383:27;7166:250::o;7421:271::-;7463:3;7501:5;7495:12;7528:6;7523:3;7516:19;7544:76;7613:6;7606:4;7601:3;7597:14;7590:4;7583:5;7579:16;7544:76;:::i;:::-;7674:2;7653:15;-1:-1:-1;;7649:29:54;7640:39;;;;7681:4;7636:50;;7421:271;-1:-1:-1;;7421:271:54:o;7697:220::-;7846:2;7835:9;7828:21;7809:4;7866:45;7907:2;7896:9;7892:18;7884:6;7866:45;:::i;7922:131::-;-1:-1:-1;;;;;;7996:32:54;;7986:43;;7976:71;;8043:1;8040;8033:12;8058:245;8116:6;8169:2;8157:9;8148:7;8144:23;8140:32;8137:52;;;8185:1;8182;8175:12;8137:52;8224:9;8211:23;8243:30;8267:5;8243:30;:::i;8308:210::-;8397:6;8450:2;8438:9;8429:7;8425:23;8421:32;8418:52;;;8466:1;8463;8456:12;8418:52;-1:-1:-1;8489:23:54;;8308:210;-1:-1:-1;8308:210:54:o;9035:801::-;9195:4;9224:2;9264;9253:9;9249:18;9294:2;9283:9;9276:21;9317:6;9352;9346:13;9383:6;9375;9368:22;9421:2;9410:9;9406:18;9399:25;;9483:2;9473:6;9470:1;9466:14;9455:9;9451:30;9447:39;9433:53;;9521:2;9513:6;9509:15;9542:1;9552:255;9566:6;9563:1;9560:13;9552:255;;;9659:2;9655:7;9643:9;9635:6;9631:22;9627:36;9622:3;9615:49;9687:40;9720:6;9711;9705:13;9687:40;:::i;:::-;9677:50;-1:-1:-1;9785:12:54;;;;9750:15;;;;9588:1;9581:9;9552:255;;;-1:-1:-1;9824:6:54;;9035:801;-1:-1:-1;;;;;;;9035:801:54:o;9841:388::-;9909:6;9917;9970:2;9958:9;9949:7;9945:23;9941:32;9938:52;;;9986:1;9983;9976:12;9938:52;10025:9;10012:23;10044:31;10069:5;10044:31;:::i;:::-;10094:5;-1:-1:-1;10151:2:54;10136:18;;10123:32;10164:33;10123:32;10164:33;:::i;:::-;10216:7;10206:17;;;9841:388;;;;;:::o;10234:156::-;10300:20;;10360:4;10349:16;;10339:27;;10329:55;;10380:1;10377;10370:12;10395:679;10515:6;10523;10531;10539;10592:2;10580:9;10571:7;10567:23;10563:32;10560:52;;;10608:1;10605;10598:12;10560:52;10647:9;10634:23;10666:31;10691:5;10666:31;:::i;:::-;10716:5;-1:-1:-1;10772:2:54;10757:18;;10744:32;-1:-1:-1;;;;;10788:30:54;;10785:50;;;10831:1;10828;10821:12;10785:50;10870:89;10951:7;10942:6;10931:9;10927:22;10870:89;:::i;:::-;10978:8;;-1:-1:-1;10844:115:54;-1:-1:-1;11032:36:54;;-1:-1:-1;11064:2:54;11049:18;;11032:36;:::i;:::-;11022:46;;10395:679;;;;;;;:::o;11446:266::-;11534:6;11529:3;11522:19;11586:6;11579:5;11572:4;11567:3;11563:14;11550:43;-1:-1:-1;11638:1:54;11613:16;;;11631:4;11609:27;;;11602:38;;;;11694:2;11673:15;;;-1:-1:-1;;11669:29:54;11660:39;;;11656:50;;11446:266::o;11717:412::-;11959:1;11955;11950:3;11946:11;11942:19;11934:6;11930:32;11919:9;11912:51;11999:6;11994:2;11983:9;11979:18;11972:34;12042:2;12037;12026:9;12022:18;12015:30;11893:4;12062:61;12119:2;12108:9;12104:18;12096:6;12088;12062:61;:::i;:::-;12054:69;11717:412;-1:-1:-1;;;;;;11717:412:54:o;12134:127::-;12195:10;12190:3;12186:20;12183:1;12176:31;12226:4;12223:1;12216:15;12250:4;12247:1;12240:15;12266:275;12337:2;12331:9;12402:2;12383:13;;-1:-1:-1;;12379:27:54;12367:40;;-1:-1:-1;;;;;12422:34:54;;12458:22;;;12419:62;12416:88;;;12484:18;;:::i;:::-;12520:2;12513:22;12266:275;;-1:-1:-1;12266:275:54:o;12546:186::-;12594:4;-1:-1:-1;;;;;12619:6:54;12616:30;12613:56;;;12649:18;;:::i;:::-;-1:-1:-1;12715:2:54;12694:15;-1:-1:-1;;12690:29:54;12721:4;12686:40;;12546:186::o;12737:320::-;12812:5;12841:52;12857:35;12885:6;12857:35;:::i;:::-;12841:52;:::i;:::-;12832:61;;12916:6;12909:5;12902:21;12956:3;12947:6;12942:3;12938:16;12935:25;12932:45;;;12973:1;12970;12963:12;12932:45;12986:65;13044:6;13037:4;13030:5;13026:16;13021:3;12986:65;:::i;13062:235::-;13115:5;13168:3;13161:4;13153:6;13149:17;13145:27;13135:55;;13186:1;13183;13176:12;13135:55;13208:83;13287:3;13278:6;13272:13;13265:4;13257:6;13253:17;13208:83;:::i;13302:335::-;13381:6;13434:2;13422:9;13413:7;13409:23;13405:32;13402:52;;;13450:1;13447;13440:12;13402:52;13483:9;13477:16;-1:-1:-1;;;;;13508:6:54;13505:30;13502:50;;;13548:1;13545;13538:12;13502:50;13571:60;13623:7;13614:6;13603:9;13599:22;13571:60;:::i;13642:360::-;13853:6;13845;13840:3;13827:33;13923:2;13919:15;;;;-1:-1:-1;;13915:53:54;13879:16;;13904:65;;;13993:2;13985:11;;13642:360;-1:-1:-1;13642:360:54:o;14230:184::-;14300:6;14353:2;14341:9;14332:7;14328:23;14324:32;14321:52;;;14369:1;14366;14359:12;14321:52;-1:-1:-1;14392:16:54;;14230:184;-1:-1:-1;14230:184:54:o;14419:331::-;14524:9;14535;14577:8;14565:10;14562:24;14559:44;;;14599:1;14596;14589:12;14559:44;14628:6;14618:8;14615:20;14612:40;;;14648:1;14645;14638:12;14612:40;-1:-1:-1;;14674:23:54;;;14719:25;;;;;-1:-1:-1;14419:331:54:o;14755:337::-;-1:-1:-1;;14876:19:54;;14963:11;;;;14994:2;14986:11;;14983:103;;;15073:2;15067;15060:3;15056:2;15052:12;15049:1;15045:20;15041:29;15037:2;15033:38;15029:47;15020:56;;14983:103;;;14755:337;;;;:::o;15286:482::-;15523:6;15512:9;15505:25;15566:2;15561;15550:9;15546:18;15539:30;15486:4;15592:45;15633:2;15622:9;15618:18;15610:6;15592:45;:::i;:::-;15685:9;15677:6;15673:22;15668:2;15657:9;15653:18;15646:50;15713:49;15755:6;15747;15739;15713:49;:::i;:::-;15705:57;15286:482;-1:-1:-1;;;;;;;15286:482:54:o;16196:249::-;16265:6;16318:2;16306:9;16297:7;16293:23;16289:32;16286:52;;;16334:1;16331;16324:12;16286:52;16366:9;16360:16;16385:30;16409:5;16385:30;:::i;16450:500::-;16508:5;16515:6;16575:3;16562:17;16661:2;16657:7;16646:8;16630:14;16626:29;16622:43;16602:18;16598:68;16588:96;;16680:1;16677;16670:12;16588:96;16708:33;;16812:4;16799:18;;;-1:-1:-1;16760:21:54;;-1:-1:-1;;;;;;16829:30:54;;16826:50;;;16872:1;16869;16862:12;16826:50;16919:6;16903:14;16899:27;16892:5;16888:39;16885:59;;;16940:1;16937;16930:12;16955:1710;17186:2;17175:9;17168:21;17198:66;17260:2;17249:9;17245:18;17217:26;17236:6;17217:26;:::i;:::-;-1:-1:-1;;;;;80:31:54;68:44;;14:104;17198:66;17325:4;17317:6;17313:17;17300:31;17295:2;17284:9;17280:18;17273:59;17149:4;17375:55;17426:2;17418:6;17414:15;17406:6;17375:55;:::i;:::-;17449:6;17492:2;17486:3;17475:9;17471:19;17464:31;17518:74;17587:3;17576:9;17572:19;17558:12;17544;17518:74;:::i;:::-;17504:88;;17639:55;17690:2;17682:6;17678:15;17670:6;17639:55;:::i;:::-;17601:93;;17717:2;17713:7;17785:2;17773:9;17765:6;17761:22;17757:31;17751:3;17740:9;17736:19;17729:60;17812:65;17870:6;17854:14;17838;17812:65;:::i;:::-;17798:79;;17939:3;17931:6;17927:16;17914:30;17908:3;17897:9;17893:19;17886:59;18007:3;17999:6;17995:16;17982:30;17976:3;17965:9;17961:19;17954:59;18032:3;18022:13;;18096:3;18088:6;18084:16;18071:30;18066:2;18055:9;18051:18;18044:58;18149:56;18200:3;18192:6;18188:16;18180:6;18149:56;:::i;:::-;18111:94;;18269:2;18257:9;18249:6;18245:22;18241:31;18236:2;18225:9;18221:18;18214:59;18296:65;18354:6;18338:14;18322;18296:65;:::i;:::-;18282:79;;;18408:55;18459:2;18451:6;18447:15;18439:6;18408:55;:::i;:::-;18370:93;;;;18528:2;18516:9;18508:6;18504:22;18500:31;18494:3;18483:9;18479:19;18472:60;;;18549:65;18607:6;18591:14;18575;18549:65;:::i;:::-;18541:73;;;;;18652:6;18645:4;18634:9;18630:20;18623:36;16955:1710;;;;;:::o;18670:265::-;18747:6;18800:2;18788:9;18779:7;18775:23;18771:32;18768:52;;;18816:1;18813;18806:12;18768:52;18855:9;18842:23;18874:31;18899:5;18874:31;:::i;18940:545::-;19033:4;19039:6;19099:11;19086:25;19193:2;19189:7;19178:8;19162:14;19158:29;19154:43;19134:18;19130:68;19120:96;;19212:1;19209;19202:12;19120:96;19239:33;;19291:20;;;-1:-1:-1;;;;;;19323:30:54;;19320:50;;;19366:1;19363;19356:12;19320:50;19399:4;19387:17;;-1:-1:-1;19450:1:54;19446:14;;;19430;19426:35;19416:46;;19413:66;;;19475:1;19472;19465:12;19490:182;19547:6;19600:2;19588:9;19579:7;19575:23;19571:32;19568:52;;;19616:1;19613;19606:12;19568:52;19639:27;19656:9;19639:27;:::i;19677:127::-;19738:10;19733:3;19729:20;19726:1;19719:31;19769:4;19766:1;19759:15;19793:4;19790:1;19783:15;19809:328;19906:4;19964:11;19951:25;20058:2;20054:7;20043:8;20027:14;20023:29;20019:43;19999:18;19995:68;19985:96;;20077:1;20074;20067:12;19985:96;20098:33;;;;;19809:328;-1:-1:-1;;19809:328:54:o;20394:386::-;20579:25;;;-1:-1:-1;;;;;20640:32:54;;20635:2;20620:18;;20613:60;20709:2;20704;20689:18;;20682:30;;;-1:-1:-1;;20729:45:54;;20755:18;;20747:6;20729:45;:::i;20785:458::-;20865:6;20918:2;20906:9;20897:7;20893:23;20889:32;20886:52;;;20934:1;20931;20924:12;20886:52;20967:9;20961:16;-1:-1:-1;;;;;20992:6:54;20989:30;20986:50;;;21032:1;21029;21022:12;20986:50;21055:22;;21108:4;21100:13;;21096:27;-1:-1:-1;21086:55:54;;21137:1;21134;21127:12;21086:55;21160:77;21229:7;21224:2;21218:9;21213:2;21209;21205:11;21160:77;:::i;21248:604::-;-1:-1:-1;;;21606:3:54;21599:20;21581:3;21648:6;21642:13;21664:74;21731:6;21727:1;21722:3;21718:11;21711:4;21703:6;21699:17;21664:74;:::i;:::-;-1:-1:-1;;;21797:1:54;21757:16;;;;21789:10;;;21782:37;-1:-1:-1;21843:2:54;21835:11;;21248:604;-1:-1:-1;21248:604:54:o;23000:476::-;23266:1;23262;23257:3;23253:11;23249:19;23241:6;23237:32;23226:9;23219:51;23306:6;23301:2;23290:9;23286:18;23279:34;23349:3;23344:2;23333:9;23329:18;23322:31;23200:4;23370:46;23411:3;23400:9;23396:19;23388:6;23370:46;:::i;:::-;23362:54;;23464:4;23456:6;23452:17;23447:2;23436:9;23432:18;23425:45;23000:476;;;;;;;:::o;23481:164::-;23557:13;;23606;;23599:21;23589:32;;23579:60;;23635:1;23632;23625:12;23650:414;23735:6;23743;23796:2;23784:9;23775:7;23771:23;23767:32;23764:52;;;23812:1;23809;23802:12;23764:52;23835:37;23862:9;23835:37;:::i;:::-;23825:47;;23916:2;23905:9;23901:18;23895:25;-1:-1:-1;;;;;23935:6:54;23932:30;23929:50;;;23975:1;23972;23965:12;23929:50;23998:60;24050:7;24041:6;24030:9;24026:22;23998:60;:::i;:::-;23988:70;;;23650:414;;;;;:::o;24069:315::-;-1:-1:-1;;;;;24244:32:54;;24226:51;;24313:2;24308;24293:18;;24286:30;;;-1:-1:-1;;24333:45:54;;24359:18;;24351:6;24333:45;:::i;24389:202::-;24456:6;24509:2;24497:9;24488:7;24484:23;24480:32;24477:52;;;24525:1;24522;24515:12;24477:52;24548:37;24575:9;24548:37;:::i;24596:149::-;24670:20;;24719:1;24709:12;;24699:40;;24735:1;24732;24725:12;24750:339;24831:6;24839;24892:2;24880:9;24871:7;24867:23;24863:32;24860:52;;;24908:1;24905;24898:12;24860:52;24931:35;24956:9;24931:35;:::i;:::-;24921:45;;25016:2;25005:9;25001:18;24988:32;25029:30;25053:5;25029:30;:::i;25094:359::-;25281:6;25276:3;25269:19;25251:3;25317:6;25311:13;25333:73;25399:6;25394:2;25389:3;25385:12;25380:2;25372:6;25368:15;25333:73;:::i;:::-;25426:16;;;;25444:2;25422:25;;25094:359;-1:-1:-1;;;25094:359:54:o;26365:783::-;26631:4;26619:17;;26601:36;;26589:2;26656;26674:18;;;26667:30;;;26574:18;;;26732:22;;;26541:4;;26811:6;;26785:2;26770:18;;26541:4;26845:277;26859:6;26856:1;26853:13;26845:277;;;26934:6;26921:20;26954:31;26979:5;26954:31;:::i;:::-;-1:-1:-1;;;;;27010:31:54;26998:44;;27097:15;;;;27062:12;;;;27038:1;26874:9;26845:277;;;-1:-1:-1;27139:3:54;26365:783;-1:-1:-1;;;;;;;26365:783:54:o;27153:521::-;27230:4;27236:6;27296:11;27283:25;27390:2;27386:7;27375:8;27359:14;27355:29;27351:43;27331:18;27327:68;27317:96;;27409:1;27406;27399:12;27317:96;27436:33;;27488:20;;;-1:-1:-1;;;;;;27520:30:54;;27517:50;;;27563:1;27560;27553:12;27517:50;27596:4;27584:17;;-1:-1:-1;27627:14:54;27623:27;;;27613:38;;27610:58;;;27664:1;27661;27654:12;27679:127;27740:10;27735:3;27731:20;27728:1;27721:31;27771:4;27768:1;27761:15;27795:4;27792:1;27785:15;27811:135;27850:3;27871:17;;;27868:43;;27891:18;;:::i;:::-;-1:-1:-1;27938:1:54;27927:13;;27811:135::o;27951:128::-;28018:9;;;28039:11;;;28036:37;;;28053:18;;:::i;28084:462::-;28126:5;28179:3;28172:4;28164:6;28160:17;28156:27;28146:55;;28197:1;28194;28187:12;28146:55;28233:6;28220:20;28264:48;28280:31;28308:2;28280:31;:::i;28264:48::-;28337:2;28328:7;28321:19;28383:3;28376:4;28371:2;28363:6;28359:15;28355:26;28352:35;28349:55;;;28400:1;28397;28390:12;28349:55;28465:2;28458:4;28450:6;28446:17;28439:4;28430:7;28426:18;28413:55;28513:1;28488:16;;;28506:4;28484:27;28477:38;;;;28492:7;28084:462;-1:-1:-1;;;28084:462:54:o;28551:659::-;28666:6;28674;28682;28735:2;28723:9;28714:7;28710:23;28706:32;28703:52;;;28751:1;28748;28741:12;28703:52;28790:9;28777:23;28809:30;28833:5;28809:30;:::i;:::-;28858:5;-1:-1:-1;28915:2:54;28900:18;;28887:32;-1:-1:-1;;;;;;28950:27:54;;28938:40;;28928:68;;28992:1;28989;28982:12;28928:68;29015:7;-1:-1:-1;29073:2:54;29058:18;;29045:32;-1:-1:-1;;;;;29089:30:54;;29086:50;;;29132:1;29129;29122:12;29086:50;29155:49;29196:7;29187:6;29176:9;29172:22;29155:49;:::i;:::-;29145:59;;;28551:659;;;;;:::o;29215:547::-;29314:6;29322;29330;29383:2;29371:9;29362:7;29358:23;29354:32;29351:52;;;29399:1;29396;29389:12;29351:52;29422:35;29447:9;29422:35;:::i;:::-;29412:45;;29507:2;29496:9;29492:18;29479:32;29520:30;29544:5;29520:30;:::i;29767:127::-;29828:10;29823:3;29819:20;29816:1;29809:31;29859:4;29856:1;29849:15;29883:4;29880:1;29873:15;30388:463;30473:6;30481;30534:2;30522:9;30513:7;30509:23;30505:32;30502:52;;;30550:1;30547;30540:12;30502:52;30589:9;30576:23;30608:31;30633:5;30608:31;:::i;:::-;30658:5;-1:-1:-1;30714:2:54;30699:18;;30686:32;-1:-1:-1;;;;;30730:30:54;;30727:50;;;30773:1;30770;30763:12;30727:50;30796:49;30837:7;30828:6;30817:9;30813:22;30796:49;:::i;30856:453::-;30932:6;30940;30993:2;30981:9;30972:7;30968:23;30964:32;30961:52;;;31009:1;31006;30999:12;30961:52;31048:9;31035:23;31067:30;31091:5;31067:30;:::i;31996:1495::-;32235:2;32287:21;;;32260:18;;;32343:22;;;32206:4;;32384:2;32402:18;;;32466:1;32462:14;;;32447:30;;32443:39;;32505:6;32206:4;;32560:902;32576:6;32571:3;32568:15;32560:902;;;32645:22;;;-1:-1:-1;;32641:36:54;32629:49;;32717:20;;32792:14;32788:27;;;-1:-1:-1;;32784:41:54;32760:66;;32750:94;;32840:1;32837;32830:12;32750:94;32870:31;;32924:4;32956:19;;32988:33;32956:19;32988:33;:::i;:::-;-1:-1:-1;;;;;33049:33:54;33034:49;;33133:14;;;33120:28;33103:15;;;33096:53;33196;33234:14;;;33137:5;33196:53;:::i;:::-;33162:87;;33286:2;33281;33273:6;33269:15;33262:27;33312:70;33378:2;33370:6;33366:15;33352:12;33338;33312:70;:::i;:::-;33440:12;;;;33302:80;-1:-1:-1;;;33405:15:54;;;;-1:-1:-1;32602:1:54;32593:11;32560:902;;;-1:-1:-1;33479:6:54;;31996:1495;-1:-1:-1;;;;;;;;;31996:1495:54:o;33496:255::-;33616:19;;33655:2;33647:11;;33644:101;;;-1:-1:-1;;33716:2:54;33712:12;;;33709:1;33705:20;33701:33;33690:45;33496:255;;;;:::o;33756:327::-;-1:-1:-1;;;;;;33876:19:54;;33956:11;;;;33987:1;33979:10;;33976:101;;;34048:1;34044:11;;;;34041:1;34037:19;34033:28;;;34025:37;34021:46;;;;33756:327;-1:-1:-1;;33756:327:54:o;34088:271::-;34271:6;34263;34258:3;34245:33;34227:3;34297:16;;34322:13;;;34297:16;34088:271;-1:-1:-1;34088:271:54:o;34364:181::-;34422:4;-1:-1:-1;;;;;34447:6:54;34444:30;34441:56;;;34477:18;;:::i;:::-;-1:-1:-1;34522:1:54;34518:14;34534:4;34514:25;;34364:181::o;34550:892::-;34613:5;34666:3;34659:4;34651:6;34647:17;34643:27;34633:55;;34684:1;34681;34674:12;34633:55;34713:6;34707:13;34739:4;34763:58;34779:41;34817:2;34779:41;:::i;34763:58::-;34855:15;;;34941:1;34937:10;;;;34925:23;;34921:32;;;34886:12;;;;34965:15;;;34962:35;;;34993:1;34990;34983:12;34962:35;35029:2;35021:6;35017:15;35041:372;35057:6;35052:3;35049:15;35041:372;;;35136:3;35130:10;-1:-1:-1;;;;;35159:11:54;35156:35;35153:125;;;35232:1;35261:2;35257;35250:14;35153:125;35303:67;35366:3;35361:2;35347:11;35339:6;35335:24;35331:33;35303:67;:::i;:::-;35291:80;;-1:-1:-1;35391:12:54;;;;35074;;35041:372;;;-1:-1:-1;35431:5:54;34550:892;-1:-1:-1;;;;;;34550:892:54:o;35447:370::-;35551:6;35604:2;35592:9;35583:7;35579:23;35575:32;35572:52;;;35620:1;35617;35610:12;35572:52;35653:9;35647:16;-1:-1:-1;;;;;35678:6:54;35675:30;35672:50;;;35718:1;35715;35708:12;35672:50;35741:70;35803:7;35794:6;35783:9;35779:22;35741:70;:::i;35822:1157::-;35957:6;35965;36018:2;36006:9;35997:7;35993:23;35989:32;35986:52;;;36034:1;36031;36024:12;35986:52;36067:9;36061:16;-1:-1:-1;;;;;36137:2:54;36129:6;36126:14;36123:34;;;36153:1;36150;36143:12;36123:34;36191:6;36180:9;36176:22;36166:32;;36236:7;36229:4;36225:2;36221:13;36217:27;36207:55;;36258:1;36255;36248:12;36207:55;36287:2;36281:9;36309:4;36333:58;36349:41;36387:2;36349:41;:::i;36333:58::-;36425:15;;;36507:1;36503:10;;;;36495:19;;36491:28;;;36456:12;;;;36531:19;;;36528:39;;;36563:1;36560;36553:12;36528:39;36587:11;;;;36607:156;36623:6;36618:3;36615:15;36607:156;;;36689:31;36716:3;36689:31;:::i;:::-;36677:44;;36640:12;;;;36741;;;;36607:156;;;36818:18;;;36812:25;36782:5;;-1:-1:-1;36812:25:54;;-1:-1:-1;;;36849:16:54;;;36846:36;;;36878:1;36875;36868:12;36846:36;;36901:72;36965:7;36954:8;36943:9;36939:24;36901:72;:::i",linkReferences:{}},methodIdentifiers={"accountId()":"9cfd7cff","domainSeparator()":"f698da25","entryPoint()":"b0d691fe","execute(bytes32,bytes)":"e9ae5c53","executeFromExecutor(bytes32,bytes)":"d691c964","getActiveHook()":"0a664dba","getActiveHook(bytes4)":"b875d5d8","getExecutorsPaginated(address,uint256)":"ea5f61d0","getNonce(address,address)":"d828435d","getValidatorPaginated(address,uint256)":"85571368","initializeAccount((address,bytes)[],(address,bytes)[],(address,bytes)[],(address,bytes)[],(address,address[],uint8))":"540fb4f9","installModule(uint256,address,bytes)":"9517e29f","isModuleInstalled(uint256,address,bytes)":"112d3a7d","isValidSignature(bytes32,bytes)":"1626ba7e","launchpadValidators((address,bytes)[])":"6a5e1515","setRegistry(address,address[],uint8)":"eab77e17","supportsExecutionMode(bytes32)":"d03c7914","supportsModule(uint256)":"f2dc691d","uninstallModule(uint256,address,bytes)":"a71763a8","validateUserOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes),bytes32,uint256)":"19822f7c"},rawMetadata=`{"compiler":{"version":"0.8.25+commit.b61c2a91"},"language":"Solidity","output":{"abi":[{"inputs":[],"name":"AccountAccessUnauthorized","type":"error"},{"inputs":[],"name":"AccountInitializationFailed","type":"error"},{"inputs":[],"name":"ExecutionFailed","type":"error"},{"inputs":[{"internalType":"bytes4","name":"msgSig","type":"bytes4"}],"name":"FallbackInstalled","type":"error"},{"inputs":[{"internalType":"address","name":"currentHook","type":"address"}],"name":"HookAlreadyInstalled","type":"error"},{"inputs":[],"name":"HookPostCheckFailed","type":"error"},{"inputs":[],"name":"InitializerError","type":"error"},{"inputs":[{"internalType":"bytes4","name":"msgSig","type":"bytes4"}],"name":"InvalidFallbackHandler","type":"error"},{"inputs":[],"name":"InvalidHookType","type":"error"},{"inputs":[{"internalType":"address","name":"safe","type":"address"}],"name":"InvalidInitData","type":"error"},{"inputs":[],"name":"InvalidInput","type":"error"},{"inputs":[{"internalType":"address","name":"module","type":"address"}],"name":"InvalidModule","type":"error"},{"inputs":[],"name":"LinkedListError","type":"error"},{"inputs":[],"name":"LinkedList_AlreadyInitialized","type":"error"},{"inputs":[],"name":"LinkedList_AlreadyInitialized","type":"error"},{"inputs":[{"internalType":"address","name":"entry","type":"address"}],"name":"LinkedList_EntryAlreadyInList","type":"error"},{"inputs":[{"internalType":"address","name":"entry","type":"address"}],"name":"LinkedList_EntryAlreadyInList","type":"error"},{"inputs":[{"internalType":"address","name":"entry","type":"address"}],"name":"LinkedList_InvalidEntry","type":"error"},{"inputs":[{"internalType":"address","name":"entry","type":"address"}],"name":"LinkedList_InvalidEntry","type":"error"},{"inputs":[],"name":"LinkedList_InvalidPage","type":"error"},{"inputs":[],"name":"LinkedList_InvalidPage","type":"error"},{"inputs":[{"internalType":"bytes4","name":"msgSig","type":"bytes4"}],"name":"NoFallbackHandler","type":"error"},{"inputs":[{"internalType":"CallType","name":"callType","type":"bytes1"}],"name":"UnsupportedCallType","type":"error"},{"inputs":[{"internalType":"ExecType","name":"execType","type":"bytes1"}],"name":"UnsupportedExecType","type":"error"},{"inputs":[{"internalType":"uint256","name":"moduleTypeId","type":"uint256"}],"name":"UnsupportedModuleType","type":"error"},{"inputs":[],"name":"ValidatorStorageHelperError","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"smartAccount","type":"address"},{"indexed":true,"internalType":"contract IERC7484","name":"registry","type":"address"}],"name":"ERC7484RegistryConfigured","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"moduleTypeId","type":"uint256"},{"indexed":false,"internalType":"address","name":"module","type":"address"}],"name":"ModuleInstalled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"moduleTypeId","type":"uint256"},{"indexed":false,"internalType":"address","name":"module","type":"address"}],"name":"ModuleUninstalled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"safe","type":"address"}],"name":"Safe7579Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract ISafe","name":"safe","type":"address"},{"indexed":false,"internalType":"uint256","name":"numberInBatch","type":"uint256"}],"name":"TryExecutionFailed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract ISafe","name":"safe","type":"address"},{"indexed":false,"internalType":"bool[]","name":"success","type":"bool[]"}],"name":"TryExecutionsFailed","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"accountId","outputs":[{"internalType":"string","name":"accountImplementationId","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"domainSeparator","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"entryPoint","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"ModeCode","name":"mode","type":"bytes32"},{"internalType":"bytes","name":"executionCalldata","type":"bytes"}],"name":"execute","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"ModeCode","name":"mode","type":"bytes32"},{"internalType":"bytes","name":"executionCalldata","type":"bytes"}],"name":"executeFromExecutor","outputs":[{"internalType":"bytes[]","name":"returnDatas","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"getActiveHook","outputs":[{"internalType":"address","name":"hook","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"selector","type":"bytes4"}],"name":"getActiveHook","outputs":[{"internalType":"address","name":"hook","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"cursor","type":"address"},{"internalType":"uint256","name":"size","type":"uint256"}],"name":"getExecutorsPaginated","outputs":[{"internalType":"address[]","name":"array","type":"address[]"},{"internalType":"address","name":"next","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"safe","type":"address"},{"internalType":"address","name":"validator","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"start","type":"address"},{"internalType":"uint256","name":"pageSize","type":"uint256"}],"name":"getValidatorPaginated","outputs":[{"internalType":"address[]","name":"array","type":"address[]"},{"internalType":"address","name":"next","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"internalType":"struct ModuleInit[]","name":"validators","type":"tuple[]"},{"components":[{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"internalType":"struct ModuleInit[]","name":"executors","type":"tuple[]"},{"components":[{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"internalType":"struct ModuleInit[]","name":"fallbacks","type":"tuple[]"},{"components":[{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"internalType":"struct ModuleInit[]","name":"hooks","type":"tuple[]"},{"components":[{"internalType":"contract IERC7484","name":"registry","type":"address"},{"internalType":"address[]","name":"attesters","type":"address[]"},{"internalType":"uint8","name":"threshold","type":"uint8"}],"internalType":"struct RegistryInit","name":"registryInit","type":"tuple"}],"name":"initializeAccount","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"moduleType","type":"uint256"},{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"name":"installModule","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"moduleType","type":"uint256"},{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"additionalContext","type":"bytes"}],"name":"isModuleInstalled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"isValidSignature","outputs":[{"internalType":"bytes4","name":"magicValue","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"initData","type":"bytes"}],"internalType":"struct ModuleInit[]","name":"validators","type":"tuple[]"}],"name":"launchpadValidators","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"contract IERC7484","name":"registry","type":"address"},{"internalType":"address[]","name":"attesters","type":"address[]"},{"internalType":"uint8","name":"threshold","type":"uint8"}],"name":"setRegistry","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"ModeCode","name":"encodedMode","type":"bytes32"}],"name":"supportsExecutionMode","outputs":[{"internalType":"bool","name":"supported","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"moduleTypeId","type":"uint256"}],"name":"supportsModule","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"moduleType","type":"uint256"},{"internalType":"address","name":"module","type":"address"},{"internalType":"bytes","name":"deInitData","type":"bytes"}],"name":"uninstallModule","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"bytes","name":"initCode","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"},{"internalType":"bytes32","name":"accountGasLimits","type":"bytes32"},{"internalType":"uint256","name":"preVerificationGas","type":"uint256"},{"internalType":"bytes32","name":"gasFees","type":"bytes32"},{"internalType":"bytes","name":"paymasterAndData","type":"bytes"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct PackedUserOperation","name":"userOp","type":"tuple"},{"internalType":"bytes32","name":"userOpHash","type":"bytes32"},{"internalType":"uint256","name":"missingAccountFunds","type":"uint256"}],"name":"validateUserOp","outputs":[{"internalType":"uint256","name":"validSignature","type":"uint256"}],"stateMutability":"payable","type":"function"},{"stateMutability":"payable","type":"receive"}],"devdoc":{"author":"rhinestone | zeroknots.eth, Konrad Kopp (@kopy-kat)","details":"This contract is a Safe account implementation that supports ERC7579 operations. In order to facilitate full ERC7579 compliance, the contract implements the IERC7579Account interface. This contract is an implementation of a Safe account supporting ERC7579 operations and complying with the IERC7579Account interface. It serves as a Safe FallbackHandler and module for Safe accounts, incorporating complex hacks to ensure ERC7579 compliance and requiring interactions and event emissions to be done via the SafeProxy as msg.sender using Safe's \\"executeTransactionFromModule\\" features.","kind":"dev","methods":{"accountId()":{"details":"Returns the account id of the smart account","returns":{"accountImplementationId":"the account id of the smart account the accountId should be structured like so: \\"vendorname.accountname.semver\\""}},"execute(bytes32,bytes)":{"details":"Executes a transaction on behalf of the Safe account. This function is intended to be called by ERC-4337 EntryPoint.solIf a global hook and/or selector hook is set, it will be calledAccessControl: only Self of Entrypoint can install modules Safe7579 supports the following feature set: CallTypes: - CALLTYPE_SINGLE - CALLTYPE_BATCH - CALLTYPE_DELEGATECALL ExecTypes: - EXECTYPE_DEFAULT (revert if not successful) - EXECTYPE_TRY If a different mode is selected, this function will revert","params":{"executionCalldata":"The encoded execution call data","mode":"The encoded execution mode of the transaction. See ModeLib.sol for details"}},"executeFromExecutor(bytes32,bytes)":{"details":"Executes a transaction on behalf of the Safe account. This function is intended to be called by executor modulesIf a global hook and/or selector hook is set, it will be calledAccessControl: only enabled executor modules Safe7579 supports the following feature set: CallTypes: - CALLTYPE_SINGLE - CALLTYPE_BATCH - CALLTYPE_DELEGATECALL ExecTypes: - EXECTYPE_DEFAULT (revert if not successful) - EXECTYPE_TRY If a different mode is selected, this function will revert","params":{"executionCalldata":"The encoded execution call data","mode":"The encoded execution mode of the transaction. See ModeLib.sol for details"}},"getNonce(address,address)":{"params":{"safe":"address of safe account","validator":"ERC7579 validator to encode"}},"initializeAccount((address,bytes)[],(address,bytes)[],(address,bytes)[],(address,bytes)[],(address,address[],uint8))":{"params":{"executors":"executor modules and initData","fallbacks":"fallback modules and initData","hooks":"hook module and initData","registryInit":"(OPTIONAL) registry, attesters and threshold for IERC7484 Registry If not provided, the registry will be set to the zero address, and no registry checks will be performed","validators":"validator modules and initData"}},"installModule(uint256,address,bytes)":{"details":"The module has to be initialized from msg.sender == SafeProxy, we thus use a delegatecall to DCUtil, which calls the onInstall/onUninstall function on the ERC7579 module and emits the ModuleInstall/ModuleUnintall eventsAccessControl: only Self of Entrypoint can install modulesIf the safe set a registry, ERC7484 registry will be queried before installingIf a global hook and/or selector hook is set, it will be called","params":{"initData":"arbitrary data that may be required on the module during \`onInstall\` initialization.","module":"the module address","moduleType":"the module type ID according the ERC-7579 spec Note: MULTITYPE_MODULE (uint(0)) is a special type to install a module with multiple types"}},"isModuleInstalled(uint256,address,bytes)":{"params":{"additionalContext":"additional context data that the smart account may interpret to identifiy conditions under which the module is installed. usually this is not necessary, but for some special hooks that are stored in mappings, this param might be needed","module":"the module address","moduleType":"the module type ID according the ERC-7579 spec Note: keep in mind that some contracts can be multiple module types at the same time. It thus may be necessary to query multiple module types"}},"isValidSignature(bytes32,bytes)":{"params":{"data":"abi.encodePacked(address validationModule, bytes signatures)","hash":"message hash of ERC1271 request"}},"launchpadValidators((address,bytes)[])":{"details":"it will initialize the SentinelList4337 list for validators, and sstore all validatorsSince this function has to be 4337 compliant (storage access), only validator storage is acccessNote: this function DOES NOT call onInstall() on the validator modules or emit ModuleInstalled events. this has to be done by the launchpad"},"supportsExecutionMode(bytes32)":{"params":{"encodedMode":"the encoded mode"}},"supportsModule(uint256)":{"params":{"moduleTypeId":"the module type ID according the ERC-7579 spec"}},"uninstallModule(uint256,address,bytes)":{"details":"The module has to be initialized from msg.sender == SafeProxy, we thus use a delegatecall to DCUtil, which calls the onInstall/onUninstall function on the ERC7579 module and emits the ModuleInstall/ModuleUnintall eventsAccessControl: only Self of Entrypoint can install modulesIf a global hook and/or selector hook is set, it will be called","params":{"deInitData":"arbitrary data that may be required on the module during \`onUninstall\` de-initialization.","module":"the module address","moduleType":"the module type ID according the ERC-7579 spec"}},"validateUserOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes),bytes32,uint256)":{"details":"expects that a ERC7579 validator module is encoded within the UserOp nonce. if no validator module is provided, it will fallback to validate the transaction with Safe's signers"}},"title":"ERC7579 Adapter for Safe accounts. creates full ERC7579 compliance to Safe accounts","version":1},"userdoc":{"kind":"user","methods":{"domainSeparator()":{"notice":"Domain Separator for EIP-712."},"getNonce(address,address)":{"notice":"Safe7579 is using validator selection encoding in the userop nonce. to make it easier for SDKs / devs to integrate, this function can be called to get the next nonce for a specific validator"},"getValidatorPaginated(address,uint256)":{"notice":"Get paginated list of installed validators"},"initializeAccount((address,bytes)[],(address,bytes)[],(address,bytes)[],(address,bytes)[],(address,address[],uint8))":{"notice":"This function can be called by the Launchpad.initSafe7579() or by already existing Safes that want to use Safe7579 if this is called by the Launchpad, it is expected that launchpadValidators() was called previously, and the param validators is empty"},"installModule(uint256,address,bytes)":{"notice":"Installs a 7579 Module of a certain type on the smart account"},"isModuleInstalled(uint256,address,bytes)":{"notice":"Function to check if the account has a certain module installed"},"isValidSignature(bytes32,bytes)":{"notice":"Will use Safe's signed messages or checkSignatures features or ERC7579 validation modules if no signature is provided, it makes use of Safe's signedMessages if address(0) or a non-installed validator module is provided, it will use Safe's checkSignatures if a valid validator module is provided, it will use the module's validateUserOp function"},"launchpadValidators((address,bytes)[])":{"notice":"This function is intended to be called by Launchpad.validateUserOp()"},"setRegistry(address,address[],uint8)":{"notice":"TODO:"},"supportsExecutionMode(bytes32)":{"notice":"Function to check if the account supports a certain CallType or ExecType (see ModeLib.sol)"},"supportsModule(uint256)":{"notice":"Function to check if the account supports installation of a certain module type Id"},"uninstallModule(uint256,address,bytes)":{"notice":"Uninstalls a Module of a certain type on the smart account."},"validateUserOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes),bytes32,uint256)":{"notice":"ERC4337 v0.7 validation function"}},"version":1}},"settings":{"compilationTarget":{"src/Safe7579.sol":"Safe7579"},"evmVersion":"paris","libraries":{},"metadata":{"bytecodeHash":"ipfs"},"optimizer":{"enabled":true,"runs":200},"remappings":[":@ERC4337/=node_modules/@ERC4337/",":@openzeppelin/=node_modules/@openzeppelin/",":@prb/math/=node_modules/@prb/math/",":@rhinestone/modulekit/=node_modules/@rhinestone/modulekit/packages/modulekit/",":@rhinestone/sessionkeymanager/=node_modules/@rhinestone/modulekit/packages/sessionkeymanager/",":@safe-global/=node_modules/@safe-global/",":account-abstraction-v0.6/=node_modules/@ERC4337/account-abstraction-v0.6/contracts/",":account-abstraction/=node_modules/@ERC4337/account-abstraction/contracts/",":ds-test/=node_modules/ds-test/src/",":erc4337-validation/=node_modules/erc4337-validation/src/",":erc7579/=node_modules/erc7579/src/",":forge-std/=node_modules/forge-std/src/",":sentinellist/=node_modules/sentinellist/src/",":solady/=node_modules/solady/src/",":solarray/=node_modules/solarray/src/",":solmate/=node_modules/solmate/src/"]},"sources":{"node_modules/@ERC4337/account-abstraction/contracts/core/Helpers.sol":{"keccak256":"0x6247e011a6cb0b263b3aa098822977181674d91b62e5bdfe04c6e66f72da25d6","license":"GPL-3.0","urls":["bzz-raw://ca829a69b3fbc74fec8e140d42a2bf93bc3512609272f031c846470f61f0ab7e","dweb:/ipfs/QmP3r3MBgAN39KeVB1rCGJWwcBcotNt26ALtAR54poQ1Jc"]},"node_modules/@ERC4337/account-abstraction/contracts/core/UserOperationLib.sol":{"keccak256":"0x9d50ece985d35f82e33e5da417595c86fac10449e3d10895d08363d33aad454b","license":"GPL-3.0","urls":["bzz-raw://b1d11cc364c8bf7ed5388268c895b5ffed16e87dfbcb320ddeeba5e7974315dc","dweb:/ipfs/QmYSpvjxEjweietQrYZagwQ52ipy7eXx4rwvnTzXKeGeMS"]},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IAggregator.sol":{"keccak256":"0xf100d6fcc0c3b450b13e979b6a42c628c292a1bc340eccc2e7796b80e3975588","license":"GPL-3.0","urls":["bzz-raw://192938b5b27234d35c8098a319e879363c79f750eea4d0e409dc889a8ce5b155","dweb:/ipfs/QmURpaJFPqEtkKP2ngBsgZhAGN8wAWh5XQpYmCkiz4Urz5"]},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IEntryPoint.sol":{"keccak256":"0x1972a5fcb3a808b58c85af5741949ef6af11ab0debd3ae8c708171ae1ae0d0c4","license":"GPL-3.0","urls":["bzz-raw://baa9837ae73b9e2362a47d42d081d7c0f3d8e878e5edb381117d94a6968949c9","dweb:/ipfs/QmUmo6FUE7fv5z1WzW1YFjxp8PqaeN2JrEee9au59w3Xhe"]},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/INonceManager.sol":{"keccak256":"0xd575af0f6ebbd5f0b2933307d44cd7b4e03a69f4b817a67db5409bd3c89aeecb","license":"GPL-3.0","urls":["bzz-raw://3b1e2dea9b05cfba9d13339ed16d96457dc861013cc4f3f35b71a80f82448db3","dweb:/ipfs/QmVaGy5uGDMSiU2SzyokTjoHFyb39VVG5wtaM9KTnHyZSk"]},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IStakeManager.sol":{"keccak256":"0xbe5ca9e7f254d031687419e7b96ef48c9c63e9398bbe992dc72ffc6dc14e0a04","license":"GPL-3.0-only","urls":["bzz-raw://1fffec71c38627a26fabb423350148009579f092623fb02b471a12d973763a00","dweb:/ipfs/QmRBi31QEYXHj3x1AnQ2jKa2eziZH1b9av396P3b4dw6bj"]},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/PackedUserOperation.sol":{"keccak256":"0x1129b46381db68eddbc5cb49e50664667b66b03c480453858e7b25eabe444359","license":"GPL-3.0","urls":["bzz-raw://499a948aba60480dba6e25c763b8d918f1c246eb7a3302e04f493e080f3295be","dweb:/ipfs/QmeRhhswf4NACcBKam2PyjpTP2ddSm648kah5kkQJsvwz3"]},"node_modules/@safe-global/safe-contracts/contracts/handler/HandlerContext.sol":{"keccak256":"0xce6da4c47f8691a4fcf07d20266b1a23ea757e49eedbfcf929f535f3f6e8072d","license":"LGPL-3.0-only","urls":["bzz-raw://b57666c08d90b0b56344813511789a6d21b66044f049146d802f8db0e28899fc","dweb:/ipfs/QmYWHsFYNbibbAGfNNQrWon9KzNHfgu5E6B3bDteLKDEmL"]},"node_modules/erc7579/src/core/AccountBase.sol":{"keccak256":"0x9608c3d2067fb8738c2da734f76317e593b1e3489a20414daabe43ac11addf87","license":"MIT","urls":["bzz-raw://2f036a5262a41a6a49fe529b9321a32c17b64f4cdb1bd4da4b61a1d6463b0588","dweb:/ipfs/QmZ5tunFkQCS68ghd5y4viT4C1smEHgQrT17V1MoViwo6c"]},"node_modules/erc7579/src/core/Receiver.sol":{"keccak256":"0x42d41b30a6582d95d737fd75122b621a8af1ec3123782d91a29385b67612b9e4","license":"MIT","urls":["bzz-raw://bfb32e6d912477279bf3105eeb7afaf4bfb6526541ef9944428a3d5b9133c23f","dweb:/ipfs/QmUc5nZW5NkC2prAUuRbFBdA2vSRwUBHKXD4evb5yiHSKf"]},"node_modules/erc7579/src/interfaces/IERC7579Module.sol":{"keccak256":"0x407d47a2e5951ae6ed9e93ecb5fd6d41f5cac651dad1dee334b607b00c5b343e","license":"MIT","urls":["bzz-raw://b99486d0337fa1a479dd5f83386bb8a22eb2ded026e7ae4a964bb6a5acd2dd9f","dweb:/ipfs/QmcE2sZGX2SZD91gUwxCvaCXZJtaACvaPxmLsQsPAkY8KB"]},"node_modules/sentinellist/src/SentinelList.sol":{"keccak256":"0xf17c11a9d52ed3291ebd6105240ed04c9563552dc0ce2366cc47d6db6f6cb775","license":"MIT","urls":["bzz-raw://eaaf2874245bc7080e2a63a7b866723b17fc97c82c05a1f4cf20376a437f2855","dweb:/ipfs/QmRBwF3WfYRHSqRNfJigmqaZtMSn3bqqHbzzsiZrFUBqTq"]},"node_modules/sentinellist/src/SentinelList4337.sol":{"keccak256":"0xd0e174b3c493faa11d325be52f99a0012d067c9e2a6101b3846edf8e7fe9c9cb","license":"MIT","urls":["bzz-raw://f07c3378d69fa9ea4a286ccfe567106cdfaaca6b74ea9b2fdad8827b1d981867","dweb:/ipfs/QmWm2kkG1ckPY6FYNCtvGgUta22UXHSTw38XLa7hYUedLe"]},"src/DataTypes.sol":{"keccak256":"0x7b2ece19f0e82036352db8e52c8ca68ee225cf927872848cfdaefac774e0174d","license":"GPL-3.0","urls":["bzz-raw://1901f64511210507cc87df2d240063890f11ff1025ae61c1cc7594b2e648786b","dweb:/ipfs/QmPqTthdY7rCb1utBCVcX9F5oj3suEUFEb8xJEYvSrQzH3"]},"src/ISafe7579.sol":{"keccak256":"0x7b0c5a68320c17f8727106d2bed0f2d2555958312bf7b590d758755617bdbed8","license":"UNLICENSED","urls":["bzz-raw://51557acd888e22c67ff934b3dcfb67440a1524134ece2155b4eda9beef513390","dweb:/ipfs/QmZK1Z7XagfQ77EVCymf5U3GXbQtWWRCNPRZ37DHJyNomB"]},"src/Safe7579.sol":{"keccak256":"0xf0fc1445e6ccc4c46f4e6ccafd0f2104a3f2523b47c9d154a5a5d8c4b01a34c4","license":"GPL-3.0","urls":["bzz-raw://e029ce676dd355aa86323b16db624bb6e273323afdcd721eb14eb34e5996364e","dweb:/ipfs/QmXLBmMQ5WP3Rw4weGX3uyYWRN5yimLB8g48ikx9xj2GxN"]},"src/core/AccessControl.sol":{"keccak256":"0x89a575a024cc9919a5ec15a7e506a92f38312722cda47ec3e14475c37f33ad8d","license":"MIT","urls":["bzz-raw://45d3333e9c5b199ec02caad27c1f2568dc04bf910a3a0f3c304eb121ff8bfe79","dweb:/ipfs/QmNwNKJeYjikvYZzQeNgycEnr92Tfoc86bG2ieFytotVqR"]},"src/core/ExecutionHelper.sol":{"keccak256":"0x428e4a69ea31501852614ab1067e575af1ad3c7dc09445dfed95e637d8c45a6c","license":"MIT","urls":["bzz-raw://abd6471b79910b9676036865cc9d7da8c1232ab36b8921b4ee7d53609e3f6a34","dweb:/ipfs/QmNZB5o87tkf8nYixRuLoDauyq38YVD3KCZXRdLsumiigD"]},"src/core/Initializer.sol":{"keccak256":"0xbafbeb9f56aa5e3bacfc2416abfd8f04621ecd4d9a8212b218226ba0ead10a49","license":"MIT","urls":["bzz-raw://0c2c8a19207e7ddcbb1976c241ded1ea165b7a7c108512e2544b2343c353f8e0","dweb:/ipfs/QmQxphwhJ47coJzHt6e388wpRgNUayfvxjjWezqnxT8Z2x"]},"src/core/ModuleManager.sol":{"keccak256":"0x2085aedd2a354fbc1f6eb805dc041451418e2f570a9c5f72cab603984c933c17","license":"MIT","urls":["bzz-raw://ae512f128286c9ca9f4efdbb469a5e7b32fe97bcfe8eebb8d8f1c19bffa1ce4f","dweb:/ipfs/QmaS6u9eq9DdoeBVsAXpga1RTUEjKi5dAvMvWB7QPyQqeU"]},"src/core/RegistryAdapter.sol":{"keccak256":"0x166317a9e2d2b6fdb5358236caf5f081fbe1cbf6e9960c0da77b3bed5d7666e8","license":"MIT","urls":["bzz-raw://168d53af4682f6c31928cf9148ea37abc68b42d3f3f458ffff1d76507caf8a8e","dweb:/ipfs/QmdRDNotVGUNdGBHhq2SU4jQmnYtXW9tboYzxqtgYYFPu5"]},"src/core/SetupDCUtil.sol":{"keccak256":"0x1676b67cf4e6cb99b5c95bc91b53e2fd18d7728812c3f4be4225c860a4c19c23","license":"MIT","urls":["bzz-raw://0db9280866d213480237531776592c3bd3787c087092e005531f6c2ee0cf5607","dweb:/ipfs/QmRTREr7iu2SpXgD4BUAmjKFD6d8n69DUCX7ZiejTNfD5u"]},"src/interfaces/IERC1271.sol":{"keccak256":"0x2faed8b59cb5a7451f842713e295a504230c40ba9ceba6863ed24ac82ad5e941","license":"LGPL-3.0-only","urls":["bzz-raw://cfc5accb2b0c55ebbbd58393fdfc78aeb11dc4146a33467a59ee67dd62f00278","dweb:/ipfs/QmcvsRGJFETpLFBCdZZHbvw5yaJKFLx3BSwQXQgbKgHLnZ"]},"src/interfaces/IERC7484.sol":{"keccak256":"0xf1f6b1b94f6c3ce7413558cc28be572cd16afec8ecc9fbde4cb5cc5b482f5a95","license":"MIT","urls":["bzz-raw://7e2f7627b692047f914e259809c2afc7e3c3dc10727f572db10505101ef33a7e","dweb:/ipfs/QmYYTeVNqX9LmWrwV7wXtREfATEWhacVVhD2jzRnfHiCPc"]},"src/interfaces/IERC7579Account.sol":{"keccak256":"0xa288a5136ef9b8ef413c4f5ee64b2702d3f1330a7a1d4cca543076e89bf4b273","license":"MIT","urls":["bzz-raw://e89e3d86fb3e4baa5a538b10b66a2cef881cb0671e19231a44b4c47ff8dd011b","dweb:/ipfs/QmQiwxpmWAkXpMnXjvYSdM92DE2n6rwSfTC9xPwmzGm18A"]},"src/interfaces/IERC7579Module.sol":{"keccak256":"0xebc1e4d11765e8da6b3e42f74199786178855a575bccc9578897945d11663cfc","urls":["bzz-raw://7d3a110c67aa21055b69a13cb02b78d5e75ea0fe5719a9cde58bae4fc9c4429d","dweb:/ipfs/QmV6F3mbC95e9wioyQum1ct9dNfaeU6tRJ4akwpPS8fW62"]},"src/interfaces/ISafe.sol":{"keccak256":"0xfd9de7afe85ae40bacc324c2d9a70e77318681ed80245076600db1359e592888","license":"LGPL-3.0-only","urls":["bzz-raw://603d08a2f39cb86cde7f101eb6790d001de21e2e2d59edffb24f8b7094d9d5c1","dweb:/ipfs/QmfANMrg8wZF1WrVmwHSLrnFBGywrhZW7LtHHS4VMRRQX2"]},"src/interfaces/ISafeOp.sol":{"keccak256":"0xb7bff9fad01b661a835eece9964f338fbdb4c80d14d438de5c25ea888eb29808","license":"MIT","urls":["bzz-raw://db9654d2d24944f3701494b558af18eea28ce7d3737d5014d339184c699fb729","dweb:/ipfs/QmPas92DYiyHgqZX2RH9AGiNvPA2CDvwdDqwL865RsTo4x"]},"src/lib/ExecutionLib.sol":{"keccak256":"0xa6d41aa7532a4bff83a8c335a8050ebe0c7a73c456d70594d2123dc293892c5c","license":"MIT","urls":["bzz-raw://283fbb850f68f12965f44d6781668be9f77a71d05a13e3e647951e793967e3f1","dweb:/ipfs/QmVv8GfNJ5Bf9nFxV6fvqy2puDjwM4sBuz9nm5mauKTNCC"]},"src/lib/ModeLib.sol":{"keccak256":"0x3a8629e9a8bd3fbc4cc0cc7d030f3eb45d9e50f4c415a68a1e8f083f5abf1605","license":"MIT","urls":["bzz-raw://21291b369f7b422c4427ad21b7c74471ad6d44743fb8807a7237ad300f60ca3d","dweb:/ipfs/QmbztEBpbKzhnEB8mPaHoD2ZQVdfxjkk2budgSfN9znSH9"]},"src/utils/DCUtil.sol":{"keccak256":"0x117e6a8e95dbdb8ceab3a0224306377dd4b196854e37228bd2560aa7904fbeb9","license":"MIT","urls":["bzz-raw://5d7ea50190601ebc96fb0cc719f33a75ecd6416a82159e136a7113c8d8acb2ea","dweb:/ipfs/QmcqdmwczwTBoV5cNZMM2uSAsz3jR3EZuRU9Emmmn4sQR1"]}},"version":1}`,metadata={compiler:{version:"0.8.25+commit.b61c2a91"},language:"Solidity",output:{abi:[{inputs:[],type:"error",name:"AccountAccessUnauthorized"},{inputs:[],type:"error",name:"AccountInitializationFailed"},{inputs:[],type:"error",name:"ExecutionFailed"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],type:"error",name:"FallbackInstalled"},{inputs:[{internalType:"address",name:"currentHook",type:"address"}],type:"error",name:"HookAlreadyInstalled"},{inputs:[],type:"error",name:"HookPostCheckFailed"},{inputs:[],type:"error",name:"InitializerError"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],type:"error",name:"InvalidFallbackHandler"},{inputs:[],type:"error",name:"InvalidHookType"},{inputs:[{internalType:"address",name:"safe",type:"address"}],type:"error",name:"InvalidInitData"},{inputs:[],type:"error",name:"InvalidInput"},{inputs:[{internalType:"address",name:"module",type:"address"}],type:"error",name:"InvalidModule"},{inputs:[],type:"error",name:"LinkedListError"},{inputs:[],type:"error",name:"LinkedList_AlreadyInitialized"},{inputs:[],type:"error",name:"LinkedList_AlreadyInitialized"},{inputs:[{internalType:"address",name:"entry",type:"address"}],type:"error",name:"LinkedList_EntryAlreadyInList"},{inputs:[{internalType:"address",name:"entry",type:"address"}],type:"error",name:"LinkedList_EntryAlreadyInList"},{inputs:[{internalType:"address",name:"entry",type:"address"}],type:"error",name:"LinkedList_InvalidEntry"},{inputs:[{internalType:"address",name:"entry",type:"address"}],type:"error",name:"LinkedList_InvalidEntry"},{inputs:[],type:"error",name:"LinkedList_InvalidPage"},{inputs:[],type:"error",name:"LinkedList_InvalidPage"},{inputs:[{internalType:"bytes4",name:"msgSig",type:"bytes4"}],type:"error",name:"NoFallbackHandler"},{inputs:[{internalType:"CallType",name:"callType",type:"bytes1"}],type:"error",name:"UnsupportedCallType"},{inputs:[{internalType:"ExecType",name:"execType",type:"bytes1"}],type:"error",name:"UnsupportedExecType"},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256"}],type:"error",name:"UnsupportedModuleType"},{inputs:[],type:"error",name:"ValidatorStorageHelperError"},{inputs:[{internalType:"address",name:"smartAccount",type:"address",indexed:!0},{internalType:"contract IERC7484",name:"registry",type:"address",indexed:!0}],type:"event",name:"ERC7484RegistryConfigured",anonymous:!1},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256",indexed:!1},{internalType:"address",name:"module",type:"address",indexed:!1}],type:"event",name:"ModuleInstalled",anonymous:!1},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256",indexed:!1},{internalType:"address",name:"module",type:"address",indexed:!1}],type:"event",name:"ModuleUninstalled",anonymous:!1},{inputs:[{internalType:"address",name:"safe",type:"address",indexed:!0}],type:"event",name:"Safe7579Initialized",anonymous:!1},{inputs:[{internalType:"contract ISafe",name:"safe",type:"address",indexed:!1},{internalType:"uint256",name:"numberInBatch",type:"uint256",indexed:!1}],type:"event",name:"TryExecutionFailed",anonymous:!1},{inputs:[{internalType:"contract ISafe",name:"safe",type:"address",indexed:!1},{internalType:"bool[]",name:"success",type:"bool[]",indexed:!1}],type:"event",name:"TryExecutionsFailed",anonymous:!1},{inputs:[],stateMutability:"payable",type:"fallback"},{inputs:[],stateMutability:"view",type:"function",name:"accountId",outputs:[{internalType:"string",name:"accountImplementationId",type:"string"}]},{inputs:[],stateMutability:"view",type:"function",name:"domainSeparator",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}]},{inputs:[],stateMutability:"view",type:"function",name:"entryPoint",outputs:[{internalType:"address",name:"",type:"address"}]},{inputs:[{internalType:"ModeCode",name:"mode",type:"bytes32"},{internalType:"bytes",name:"executionCalldata",type:"bytes"}],stateMutability:"payable",type:"function",name:"execute"},{inputs:[{internalType:"ModeCode",name:"mode",type:"bytes32"},{internalType:"bytes",name:"executionCalldata",type:"bytes"}],stateMutability:"payable",type:"function",name:"executeFromExecutor",outputs:[{internalType:"bytes[]",name:"returnDatas",type:"bytes[]"}]},{inputs:[],stateMutability:"view",type:"function",name:"getActiveHook",outputs:[{internalType:"address",name:"hook",type:"address"}]},{inputs:[{internalType:"bytes4",name:"selector",type:"bytes4"}],stateMutability:"view",type:"function",name:"getActiveHook",outputs:[{internalType:"address",name:"hook",type:"address"}]},{inputs:[{internalType:"address",name:"cursor",type:"address"},{internalType:"uint256",name:"size",type:"uint256"}],stateMutability:"view",type:"function",name:"getExecutorsPaginated",outputs:[{internalType:"address[]",name:"array",type:"address[]"},{internalType:"address",name:"next",type:"address"}]},{inputs:[{internalType:"address",name:"safe",type:"address"},{internalType:"address",name:"validator",type:"address"}],stateMutability:"view",type:"function",name:"getNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}]},{inputs:[{internalType:"address",name:"start",type:"address"},{internalType:"uint256",name:"pageSize",type:"uint256"}],stateMutability:"view",type:"function",name:"getValidatorPaginated",outputs:[{internalType:"address[]",name:"array",type:"address[]"},{internalType:"address",name:"next",type:"address"}]},{inputs:[{internalType:"struct ModuleInit[]",name:"validators",type:"tuple[]",components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}]},{internalType:"struct ModuleInit[]",name:"executors",type:"tuple[]",components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}]},{internalType:"struct ModuleInit[]",name:"fallbacks",type:"tuple[]",components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}]},{internalType:"struct ModuleInit[]",name:"hooks",type:"tuple[]",components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}]},{internalType:"struct RegistryInit",name:"registryInit",type:"tuple",components:[{internalType:"contract IERC7484",name:"registry",type:"address"},{internalType:"address[]",name:"attesters",type:"address[]"},{internalType:"uint8",name:"threshold",type:"uint8"}]}],stateMutability:"payable",type:"function",name:"initializeAccount"},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}],stateMutability:"payable",type:"function",name:"installModule"},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"additionalContext",type:"bytes"}],stateMutability:"view",type:"function",name:"isModuleInstalled",outputs:[{internalType:"bool",name:"",type:"bool"}]},{inputs:[{internalType:"bytes32",name:"hash",type:"bytes32"},{internalType:"bytes",name:"data",type:"bytes"}],stateMutability:"view",type:"function",name:"isValidSignature",outputs:[{internalType:"bytes4",name:"magicValue",type:"bytes4"}]},{inputs:[{internalType:"struct ModuleInit[]",name:"validators",type:"tuple[]",components:[{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"initData",type:"bytes"}]}],stateMutability:"payable",type:"function",name:"launchpadValidators"},{inputs:[{internalType:"contract IERC7484",name:"registry",type:"address"},{internalType:"address[]",name:"attesters",type:"address[]"},{internalType:"uint8",name:"threshold",type:"uint8"}],stateMutability:"nonpayable",type:"function",name:"setRegistry"},{inputs:[{internalType:"ModeCode",name:"encodedMode",type:"bytes32"}],stateMutability:"pure",type:"function",name:"supportsExecutionMode",outputs:[{internalType:"bool",name:"supported",type:"bool"}]},{inputs:[{internalType:"uint256",name:"moduleTypeId",type:"uint256"}],stateMutability:"pure",type:"function",name:"supportsModule",outputs:[{internalType:"bool",name:"",type:"bool"}]},{inputs:[{internalType:"uint256",name:"moduleType",type:"uint256"},{internalType:"address",name:"module",type:"address"},{internalType:"bytes",name:"deInitData",type:"bytes"}],stateMutability:"payable",type:"function",name:"uninstallModule"},{inputs:[{internalType:"struct PackedUserOperation",name:"userOp",type:"tuple",components:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"nonce",type:"uint256"},{internalType:"bytes",name:"initCode",type:"bytes"},{internalType:"bytes",name:"callData",type:"bytes"},{internalType:"bytes32",name:"accountGasLimits",type:"bytes32"},{internalType:"uint256",name:"preVerificationGas",type:"uint256"},{internalType:"bytes32",name:"gasFees",type:"bytes32"},{internalType:"bytes",name:"paymasterAndData",type:"bytes"},{internalType:"bytes",name:"signature",type:"bytes"}]},{internalType:"bytes32",name:"userOpHash",type:"bytes32"},{internalType:"uint256",name:"missingAccountFunds",type:"uint256"}],stateMutability:"payable",type:"function",name:"validateUserOp",outputs:[{internalType:"uint256",name:"validSignature",type:"uint256"}]},{inputs:[],stateMutability:"payable",type:"receive"}],devdoc:{kind:"dev",methods:{"accountId()":{details:"Returns the account id of the smart account",returns:{accountImplementationId:'the account id of the smart account the accountId should be structured like so: "vendorname.accountname.semver"'}},"execute(bytes32,bytes)":{details:"Executes a transaction on behalf of the Safe account. This function is intended to be called by ERC-4337 EntryPoint.solIf a global hook and/or selector hook is set, it will be calledAccessControl: only Self of Entrypoint can install modules Safe7579 supports the following feature set: CallTypes: - CALLTYPE_SINGLE - CALLTYPE_BATCH - CALLTYPE_DELEGATECALL ExecTypes: - EXECTYPE_DEFAULT (revert if not successful) - EXECTYPE_TRY If a different mode is selected, this function will revert",params:{executionCalldata:"The encoded execution call data",mode:"The encoded execution mode of the transaction. See ModeLib.sol for details"}},"executeFromExecutor(bytes32,bytes)":{details:"Executes a transaction on behalf of the Safe account. This function is intended to be called by executor modulesIf a global hook and/or selector hook is set, it will be calledAccessControl: only enabled executor modules Safe7579 supports the following feature set: CallTypes: - CALLTYPE_SINGLE - CALLTYPE_BATCH - CALLTYPE_DELEGATECALL ExecTypes: - EXECTYPE_DEFAULT (revert if not successful) - EXECTYPE_TRY If a different mode is selected, this function will revert",params:{executionCalldata:"The encoded execution call data",mode:"The encoded execution mode of the transaction. See ModeLib.sol for details"}},"getNonce(address,address)":{params:{safe:"address of safe account",validator:"ERC7579 validator to encode"}},"initializeAccount((address,bytes)[],(address,bytes)[],(address,bytes)[],(address,bytes)[],(address,address[],uint8))":{params:{executors:"executor modules and initData",fallbacks:"fallback modules and initData",hooks:"hook module and initData",registryInit:"(OPTIONAL) registry, attesters and threshold for IERC7484 Registry If not provided, the registry will be set to the zero address, and no registry checks will be performed",validators:"validator modules and initData"}},"installModule(uint256,address,bytes)":{details:"The module has to be initialized from msg.sender == SafeProxy, we thus use a delegatecall to DCUtil, which calls the onInstall/onUninstall function on the ERC7579 module and emits the ModuleInstall/ModuleUnintall eventsAccessControl: only Self of Entrypoint can install modulesIf the safe set a registry, ERC7484 registry will be queried before installingIf a global hook and/or selector hook is set, it will be called",params:{initData:"arbitrary data that may be required on the module during `onInstall` initialization.",module:"the module address",moduleType:"the module type ID according the ERC-7579 spec Note: MULTITYPE_MODULE (uint(0)) is a special type to install a module with multiple types"}},"isModuleInstalled(uint256,address,bytes)":{params:{additionalContext:"additional context data that the smart account may interpret to identifiy conditions under which the module is installed. usually this is not necessary, but for some special hooks that are stored in mappings, this param might be needed",module:"the module address",moduleType:"the module type ID according the ERC-7579 spec Note: keep in mind that some contracts can be multiple module types at the same time. It thus may be necessary to query multiple module types"}},"isValidSignature(bytes32,bytes)":{params:{data:"abi.encodePacked(address validationModule, bytes signatures)",hash:"message hash of ERC1271 request"}},"launchpadValidators((address,bytes)[])":{details:"it will initialize the SentinelList4337 list for validators, and sstore all validatorsSince this function has to be 4337 compliant (storage access), only validator storage is acccessNote: this function DOES NOT call onInstall() on the validator modules or emit ModuleInstalled events. this has to be done by the launchpad"},"supportsExecutionMode(bytes32)":{params:{encodedMode:"the encoded mode"}},"supportsModule(uint256)":{params:{moduleTypeId:"the module type ID according the ERC-7579 spec"}},"uninstallModule(uint256,address,bytes)":{details:"The module has to be initialized from msg.sender == SafeProxy, we thus use a delegatecall to DCUtil, which calls the onInstall/onUninstall function on the ERC7579 module and emits the ModuleInstall/ModuleUnintall eventsAccessControl: only Self of Entrypoint can install modulesIf a global hook and/or selector hook is set, it will be called",params:{deInitData:"arbitrary data that may be required on the module during `onUninstall` de-initialization.",module:"the module address",moduleType:"the module type ID according the ERC-7579 spec"}},"validateUserOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes),bytes32,uint256)":{details:"expects that a ERC7579 validator module is encoded within the UserOp nonce. if no validator module is provided, it will fallback to validate the transaction with Safe's signers"}},version:1},userdoc:{kind:"user",methods:{"domainSeparator()":{notice:"Domain Separator for EIP-712."},"getNonce(address,address)":{notice:"Safe7579 is using validator selection encoding in the userop nonce. to make it easier for SDKs / devs to integrate, this function can be called to get the next nonce for a specific validator"},"getValidatorPaginated(address,uint256)":{notice:"Get paginated list of installed validators"},"initializeAccount((address,bytes)[],(address,bytes)[],(address,bytes)[],(address,bytes)[],(address,address[],uint8))":{notice:"This function can be called by the Launchpad.initSafe7579() or by already existing Safes that want to use Safe7579 if this is called by the Launchpad, it is expected that launchpadValidators() was called previously, and the param validators is empty"},"installModule(uint256,address,bytes)":{notice:"Installs a 7579 Module of a certain type on the smart account"},"isModuleInstalled(uint256,address,bytes)":{notice:"Function to check if the account has a certain module installed"},"isValidSignature(bytes32,bytes)":{notice:"Will use Safe's signed messages or checkSignatures features or ERC7579 validation modules if no signature is provided, it makes use of Safe's signedMessages if address(0) or a non-installed validator module is provided, it will use Safe's checkSignatures if a valid validator module is provided, it will use the module's validateUserOp function"},"launchpadValidators((address,bytes)[])":{notice:"This function is intended to be called by Launchpad.validateUserOp()"},"setRegistry(address,address[],uint8)":{notice:"TODO:"},"supportsExecutionMode(bytes32)":{notice:"Function to check if the account supports a certain CallType or ExecType (see ModeLib.sol)"},"supportsModule(uint256)":{notice:"Function to check if the account supports installation of a certain module type Id"},"uninstallModule(uint256,address,bytes)":{notice:"Uninstalls a Module of a certain type on the smart account."},"validateUserOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes),bytes32,uint256)":{notice:"ERC4337 v0.7 validation function"}},version:1}},settings:{remappings:["@ERC4337/=node_modules/@ERC4337/","@openzeppelin/=node_modules/@openzeppelin/","@prb/math/=node_modules/@prb/math/","@rhinestone/modulekit/=node_modules/@rhinestone/modulekit/packages/modulekit/","@rhinestone/sessionkeymanager/=node_modules/@rhinestone/modulekit/packages/sessionkeymanager/","@safe-global/=node_modules/@safe-global/","account-abstraction-v0.6/=node_modules/@ERC4337/account-abstraction-v0.6/contracts/","account-abstraction/=node_modules/@ERC4337/account-abstraction/contracts/","ds-test/=node_modules/ds-test/src/","erc4337-validation/=node_modules/erc4337-validation/src/","erc7579/=node_modules/erc7579/src/","forge-std/=node_modules/forge-std/src/","sentinellist/=node_modules/sentinellist/src/","solady/=node_modules/solady/src/","solarray/=node_modules/solarray/src/","solmate/=node_modules/solmate/src/"],optimizer:{enabled:!0,runs:200},metadata:{bytecodeHash:"ipfs"},compilationTarget:{"src/Safe7579.sol":"Safe7579"},evmVersion:"paris",libraries:{}},sources:{"node_modules/@ERC4337/account-abstraction/contracts/core/Helpers.sol":{keccak256:"0x6247e011a6cb0b263b3aa098822977181674d91b62e5bdfe04c6e66f72da25d6",urls:["bzz-raw://ca829a69b3fbc74fec8e140d42a2bf93bc3512609272f031c846470f61f0ab7e","dweb:/ipfs/QmP3r3MBgAN39KeVB1rCGJWwcBcotNt26ALtAR54poQ1Jc"],license:"GPL-3.0"},"node_modules/@ERC4337/account-abstraction/contracts/core/UserOperationLib.sol":{keccak256:"0x9d50ece985d35f82e33e5da417595c86fac10449e3d10895d08363d33aad454b",urls:["bzz-raw://b1d11cc364c8bf7ed5388268c895b5ffed16e87dfbcb320ddeeba5e7974315dc","dweb:/ipfs/QmYSpvjxEjweietQrYZagwQ52ipy7eXx4rwvnTzXKeGeMS"],license:"GPL-3.0"},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IAggregator.sol":{keccak256:"0xf100d6fcc0c3b450b13e979b6a42c628c292a1bc340eccc2e7796b80e3975588",urls:["bzz-raw://192938b5b27234d35c8098a319e879363c79f750eea4d0e409dc889a8ce5b155","dweb:/ipfs/QmURpaJFPqEtkKP2ngBsgZhAGN8wAWh5XQpYmCkiz4Urz5"],license:"GPL-3.0"},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IEntryPoint.sol":{keccak256:"0x1972a5fcb3a808b58c85af5741949ef6af11ab0debd3ae8c708171ae1ae0d0c4",urls:["bzz-raw://baa9837ae73b9e2362a47d42d081d7c0f3d8e878e5edb381117d94a6968949c9","dweb:/ipfs/QmUmo6FUE7fv5z1WzW1YFjxp8PqaeN2JrEee9au59w3Xhe"],license:"GPL-3.0"},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/INonceManager.sol":{keccak256:"0xd575af0f6ebbd5f0b2933307d44cd7b4e03a69f4b817a67db5409bd3c89aeecb",urls:["bzz-raw://3b1e2dea9b05cfba9d13339ed16d96457dc861013cc4f3f35b71a80f82448db3","dweb:/ipfs/QmVaGy5uGDMSiU2SzyokTjoHFyb39VVG5wtaM9KTnHyZSk"],license:"GPL-3.0"},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/IStakeManager.sol":{keccak256:"0xbe5ca9e7f254d031687419e7b96ef48c9c63e9398bbe992dc72ffc6dc14e0a04",urls:["bzz-raw://1fffec71c38627a26fabb423350148009579f092623fb02b471a12d973763a00","dweb:/ipfs/QmRBi31QEYXHj3x1AnQ2jKa2eziZH1b9av396P3b4dw6bj"],license:"GPL-3.0-only"},"node_modules/@ERC4337/account-abstraction/contracts/interfaces/PackedUserOperation.sol":{keccak256:"0x1129b46381db68eddbc5cb49e50664667b66b03c480453858e7b25eabe444359",urls:["bzz-raw://499a948aba60480dba6e25c763b8d918f1c246eb7a3302e04f493e080f3295be","dweb:/ipfs/QmeRhhswf4NACcBKam2PyjpTP2ddSm648kah5kkQJsvwz3"],license:"GPL-3.0"},"node_modules/@safe-global/safe-contracts/contracts/handler/HandlerContext.sol":{keccak256:"0xce6da4c47f8691a4fcf07d20266b1a23ea757e49eedbfcf929f535f3f6e8072d",urls:["bzz-raw://b57666c08d90b0b56344813511789a6d21b66044f049146d802f8db0e28899fc","dweb:/ipfs/QmYWHsFYNbibbAGfNNQrWon9KzNHfgu5E6B3bDteLKDEmL"],license:"LGPL-3.0-only"},"node_modules/erc7579/src/core/AccountBase.sol":{keccak256:"0x9608c3d2067fb8738c2da734f76317e593b1e3489a20414daabe43ac11addf87",urls:["bzz-raw://2f036a5262a41a6a49fe529b9321a32c17b64f4cdb1bd4da4b61a1d6463b0588","dweb:/ipfs/QmZ5tunFkQCS68ghd5y4viT4C1smEHgQrT17V1MoViwo6c"],license:"MIT"},"node_modules/erc7579/src/core/Receiver.sol":{keccak256:"0x42d41b30a6582d95d737fd75122b621a8af1ec3123782d91a29385b67612b9e4",urls:["bzz-raw://bfb32e6d912477279bf3105eeb7afaf4bfb6526541ef9944428a3d5b9133c23f","dweb:/ipfs/QmUc5nZW5NkC2prAUuRbFBdA2vSRwUBHKXD4evb5yiHSKf"],license:"MIT"},"node_modules/erc7579/src/interfaces/IERC7579Module.sol":{keccak256:"0x407d47a2e5951ae6ed9e93ecb5fd6d41f5cac651dad1dee334b607b00c5b343e",urls:["bzz-raw://b99486d0337fa1a479dd5f83386bb8a22eb2ded026e7ae4a964bb6a5acd2dd9f","dweb:/ipfs/QmcE2sZGX2SZD91gUwxCvaCXZJtaACvaPxmLsQsPAkY8KB"],license:"MIT"},"node_modules/sentinellist/src/SentinelList.sol":{keccak256:"0xf17c11a9d52ed3291ebd6105240ed04c9563552dc0ce2366cc47d6db6f6cb775",urls:["bzz-raw://eaaf2874245bc7080e2a63a7b866723b17fc97c82c05a1f4cf20376a437f2855","dweb:/ipfs/QmRBwF3WfYRHSqRNfJigmqaZtMSn3bqqHbzzsiZrFUBqTq"],license:"MIT"},"node_modules/sentinellist/src/SentinelList4337.sol":{keccak256:"0xd0e174b3c493faa11d325be52f99a0012d067c9e2a6101b3846edf8e7fe9c9cb",urls:["bzz-raw://f07c3378d69fa9ea4a286ccfe567106cdfaaca6b74ea9b2fdad8827b1d981867","dweb:/ipfs/QmWm2kkG1ckPY6FYNCtvGgUta22UXHSTw38XLa7hYUedLe"],license:"MIT"},"src/DataTypes.sol":{keccak256:"0x7b2ece19f0e82036352db8e52c8ca68ee225cf927872848cfdaefac774e0174d",urls:["bzz-raw://1901f64511210507cc87df2d240063890f11ff1025ae61c1cc7594b2e648786b","dweb:/ipfs/QmPqTthdY7rCb1utBCVcX9F5oj3suEUFEb8xJEYvSrQzH3"],license:"GPL-3.0"},"src/ISafe7579.sol":{keccak256:"0x7b0c5a68320c17f8727106d2bed0f2d2555958312bf7b590d758755617bdbed8",urls:["bzz-raw://51557acd888e22c67ff934b3dcfb67440a1524134ece2155b4eda9beef513390","dweb:/ipfs/QmZK1Z7XagfQ77EVCymf5U3GXbQtWWRCNPRZ37DHJyNomB"],license:"UNLICENSED"},"src/Safe7579.sol":{keccak256:"0xf0fc1445e6ccc4c46f4e6ccafd0f2104a3f2523b47c9d154a5a5d8c4b01a34c4",urls:["bzz-raw://e029ce676dd355aa86323b16db624bb6e273323afdcd721eb14eb34e5996364e","dweb:/ipfs/QmXLBmMQ5WP3Rw4weGX3uyYWRN5yimLB8g48ikx9xj2GxN"],license:"GPL-3.0"},"src/core/AccessControl.sol":{keccak256:"0x89a575a024cc9919a5ec15a7e506a92f38312722cda47ec3e14475c37f33ad8d",urls:["bzz-raw://45d3333e9c5b199ec02caad27c1f2568dc04bf910a3a0f3c304eb121ff8bfe79","dweb:/ipfs/QmNwNKJeYjikvYZzQeNgycEnr92Tfoc86bG2ieFytotVqR"],license:"MIT"},"src/core/ExecutionHelper.sol":{keccak256:"0x428e4a69ea31501852614ab1067e575af1ad3c7dc09445dfed95e637d8c45a6c",urls:["bzz-raw://abd6471b79910b9676036865cc9d7da8c1232ab36b8921b4ee7d53609e3f6a34","dweb:/ipfs/QmNZB5o87tkf8nYixRuLoDauyq38YVD3KCZXRdLsumiigD"],license:"MIT"},"src/core/Initializer.sol":{keccak256:"0xbafbeb9f56aa5e3bacfc2416abfd8f04621ecd4d9a8212b218226ba0ead10a49",urls:["bzz-raw://0c2c8a19207e7ddcbb1976c241ded1ea165b7a7c108512e2544b2343c353f8e0","dweb:/ipfs/QmQxphwhJ47coJzHt6e388wpRgNUayfvxjjWezqnxT8Z2x"],license:"MIT"},"src/core/ModuleManager.sol":{keccak256:"0x2085aedd2a354fbc1f6eb805dc041451418e2f570a9c5f72cab603984c933c17",urls:["bzz-raw://ae512f128286c9ca9f4efdbb469a5e7b32fe97bcfe8eebb8d8f1c19bffa1ce4f","dweb:/ipfs/QmaS6u9eq9DdoeBVsAXpga1RTUEjKi5dAvMvWB7QPyQqeU"],license:"MIT"},"src/core/RegistryAdapter.sol":{keccak256:"0x166317a9e2d2b6fdb5358236caf5f081fbe1cbf6e9960c0da77b3bed5d7666e8",urls:["bzz-raw://168d53af4682f6c31928cf9148ea37abc68b42d3f3f458ffff1d76507caf8a8e","dweb:/ipfs/QmdRDNotVGUNdGBHhq2SU4jQmnYtXW9tboYzxqtgYYFPu5"],license:"MIT"},"src/core/SetupDCUtil.sol":{keccak256:"0x1676b67cf4e6cb99b5c95bc91b53e2fd18d7728812c3f4be4225c860a4c19c23",urls:["bzz-raw://0db9280866d213480237531776592c3bd3787c087092e005531f6c2ee0cf5607","dweb:/ipfs/QmRTREr7iu2SpXgD4BUAmjKFD6d8n69DUCX7ZiejTNfD5u"],license:"MIT"},"src/interfaces/IERC1271.sol":{keccak256:"0x2faed8b59cb5a7451f842713e295a504230c40ba9ceba6863ed24ac82ad5e941",urls:["bzz-raw://cfc5accb2b0c55ebbbd58393fdfc78aeb11dc4146a33467a59ee67dd62f00278","dweb:/ipfs/QmcvsRGJFETpLFBCdZZHbvw5yaJKFLx3BSwQXQgbKgHLnZ"],license:"LGPL-3.0-only"},"src/interfaces/IERC7484.sol":{keccak256:"0xf1f6b1b94f6c3ce7413558cc28be572cd16afec8ecc9fbde4cb5cc5b482f5a95",urls:["bzz-raw://7e2f7627b692047f914e259809c2afc7e3c3dc10727f572db10505101ef33a7e","dweb:/ipfs/QmYYTeVNqX9LmWrwV7wXtREfATEWhacVVhD2jzRnfHiCPc"],license:"MIT"},"src/interfaces/IERC7579Account.sol":{keccak256:"0xa288a5136ef9b8ef413c4f5ee64b2702d3f1330a7a1d4cca543076e89bf4b273",urls:["bzz-raw://e89e3d86fb3e4baa5a538b10b66a2cef881cb0671e19231a44b4c47ff8dd011b","dweb:/ipfs/QmQiwxpmWAkXpMnXjvYSdM92DE2n6rwSfTC9xPwmzGm18A"],license:"MIT"},"src/interfaces/IERC7579Module.sol":{keccak256:"0xebc1e4d11765e8da6b3e42f74199786178855a575bccc9578897945d11663cfc",urls:["bzz-raw://7d3a110c67aa21055b69a13cb02b78d5e75ea0fe5719a9cde58bae4fc9c4429d","dweb:/ipfs/QmV6F3mbC95e9wioyQum1ct9dNfaeU6tRJ4akwpPS8fW62"],license:null},"src/interfaces/ISafe.sol":{keccak256:"0xfd9de7afe85ae40bacc324c2d9a70e77318681ed80245076600db1359e592888",urls:["bzz-raw://603d08a2f39cb86cde7f101eb6790d001de21e2e2d59edffb24f8b7094d9d5c1","dweb:/ipfs/QmfANMrg8wZF1WrVmwHSLrnFBGywrhZW7LtHHS4VMRRQX2"],license:"LGPL-3.0-only"},"src/interfaces/ISafeOp.sol":{keccak256:"0xb7bff9fad01b661a835eece9964f338fbdb4c80d14d438de5c25ea888eb29808",urls:["bzz-raw://db9654d2d24944f3701494b558af18eea28ce7d3737d5014d339184c699fb729","dweb:/ipfs/QmPas92DYiyHgqZX2RH9AGiNvPA2CDvwdDqwL865RsTo4x"],license:"MIT"},"src/lib/ExecutionLib.sol":{keccak256:"0xa6d41aa7532a4bff83a8c335a8050ebe0c7a73c456d70594d2123dc293892c5c",urls:["bzz-raw://283fbb850f68f12965f44d6781668be9f77a71d05a13e3e647951e793967e3f1","dweb:/ipfs/QmVv8GfNJ5Bf9nFxV6fvqy2puDjwM4sBuz9nm5mauKTNCC"],license:"MIT"},"src/lib/ModeLib.sol":{keccak256:"0x3a8629e9a8bd3fbc4cc0cc7d030f3eb45d9e50f4c415a68a1e8f083f5abf1605",urls:["bzz-raw://21291b369f7b422c4427ad21b7c74471ad6d44743fb8807a7237ad300f60ca3d","dweb:/ipfs/QmbztEBpbKzhnEB8mPaHoD2ZQVdfxjkk2budgSfN9znSH9"],license:"MIT"},"src/utils/DCUtil.sol":{keccak256:"0x117e6a8e95dbdb8ceab3a0224306377dd4b196854e37228bd2560aa7904fbeb9",urls:["bzz-raw://5d7ea50190601ebc96fb0cc719f33a75ecd6416a82159e136a7113c8d8acb2ea","dweb:/ipfs/QmcqdmwczwTBoV5cNZMM2uSAsz3jR3EZuRU9Emmmn4sQR1"],license:"MIT"}},version:1},id=37,AccountInterface={abi,bytecode,deployedBytecode,methodIdentifiers,rawMetadata,metadata,id},CALL_TYPE={SINGLE:"0x0000000000000000000000000000000000000000000000000000000000000000",BATCH:"0x0100000000000000000000000000000000000000000000000000000000000000"};function encodeUserOpCallData({actions:c}){if(c.length===0)throw new Error("No actions");if(c.length===1){const{target:a,value:d,callData:et}=c[0];return encodeFunctionData({functionName:"execute",abi:AccountInterface.abi,args:[CALL_TYPE.SINGLE,encodePacked(["address","uint256","bytes"],[a,BigInt(Number(d)),et])]})}else return encodeFunctionData({functionName:"execute",abi:AccountInterface.abi,args:[CALL_TYPE.BATCH,encodeAbiParameters([{components:[{name:"target",type:"address"},{name:"value",type:"uint256"},{name:"callData",type:"bytes"}],name:"Execution",type:"tuple[]"}],[c])]})}const buildUnsignedUserOpTransaction=(c,a,d)=>{const et=encodeUserOpCallData({actions:[a]});return{sender:c,nonce:d,callData:et,preVerificationGas:BigInt(0),verificationGasLimit:BigInt(0),callGasLimit:BigInt(0),maxPriorityFeePerGas:BigInt(0),maxFeePerGas:BigInt(0),signature:"0x000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"}},chainId=async c=>Number(await c.request({method:"eth_chainId",params:[]})),transactionReceiptStatus={"0x0":"reverted","0x1":"success"};function deepHexlify(c){if(typeof c!="function")return c==null||typeof c=="string"||typeof c=="boolean"?c:typeof c=="bigint"?toHex(c):c._isBigNumber!=null||typeof c!="object"?toHex(c).replace(/^0x0/,"0x"):Array.isArray(c)?c.map(a=>deepHexlify(a)):Object.keys(c).reduce((a,d)=>(a[d]=deepHexlify(c[d]),a),{})}function getAddressFromInitCodeOrPaymasterAndData(c){if(c&&c.length>=42)return getAddress(c.slice(0,42))}const ENTRYPOINT_ADDRESS_V06="0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789",ENTRYPOINT_ADDRESS_V07="0x0000000071727De22E5E9d8BAf0edAc6f37da032",getEntryPointVersion=c=>c===ENTRYPOINT_ADDRESS_V06?"v0.6":"v0.7";function getInitCode(c){return c.factory?concat([c.factory,c.factoryData||"0x"]):"0x"}function getAccountGasLimits(c){return concat([pad(toHex(c.verificationGasLimit),{size:16}),pad(toHex(c.callGasLimit),{size:16})])}function getGasLimits(c){return concat([pad(toHex(c.maxPriorityFeePerGas),{size:16}),pad(toHex(c.maxFeePerGas),{size:16})])}function getPaymasterAndData(c){return c.paymaster?concat([c.paymaster,pad(toHex(c.paymasterVerificationGasLimit||BigInt(0)),{size:16}),pad(toHex(c.paymasterPostOpGasLimit||BigInt(0)),{size:16}),c.paymasterData||"0x"]):"0x"}const getPackedUserOperation=c=>({sender:c.sender,nonce:c.nonce,initCode:getInitCode(c),callData:c.callData,accountGasLimits:getAccountGasLimits(c),preVerificationGas:c.preVerificationGas,gasFees:getGasLimits(c),paymasterAndData:getPaymasterAndData(c),signature:c.signature});function prettyPrint(c){const a=Object.entries(c).map(([et,nt])=>nt===void 0||nt===!1?null:[et,nt]).filter(Boolean),d=a.reduce((et,[nt])=>Math.max(et,nt.length),0);return a.map(([et,nt])=>` ${`${et}:`.padEnd(d+1)} ${nt}`).join(` +`)}class EstimateUserOperationGasError extends BaseError{constructor(a,{userOperation:d,entryPoint:et,docsPath:nt}){const tt=prettyPrint({sender:d.sender,nonce:d.nonce,initCode:d.initCode,callData:d.callData,callGasLimit:d.callGasLimit,verificationGasLimit:d.verificationGasLimit,preVerificationGas:d.preVerificationGas,maxFeePerGas:d.maxFeePerGas,maxPriorityFeePerGas:d.maxPriorityFeePerGas,paymasterAndData:d.paymasterAndData,signature:d.signature,entryPoint:et});super(a.shortMessage,{cause:a,docsPath:nt,metaMessages:[...a.metaMessages?[...a.metaMessages," "]:[],"Estimate Gas Arguments:",tt].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EstimateUserOperationGasError"}),this.cause=a}}class SenderAlreadyDeployedError extends BaseError{constructor({cause:a,sender:d,docsPath:et}={}){super([`Smart account ${d} is already deployed.`,"","Possible solutions:",'• Remove the initCode from the user operation and set it to "0x"',"",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SenderAlreadyDeployedError"})}}Object.defineProperty(SenderAlreadyDeployedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa10/});class InitCodeRevertedError extends BaseError{constructor({cause:a,docsPath:d}={}){super(["EntryPoint failed to create the smart account with the initCode provided.","","Possible reasons:","• The initCode ran out of gas","• The initCode reverted during the account deployment process","","Possible solutions:","• Verify that the factory address in the initCode is correct (the factory address is the first 20 bytes of the initCode).","• Verify that the initCode is correct.","• Check whether the verificationGasLimit is sufficient for the initCode to complete without running out of gas.","",d?`Docs: ${d}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InitCodeRevertedError"})}}Object.defineProperty(InitCodeRevertedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa13/});class SenderAddressMismatchError extends BaseError{constructor({cause:a,sender:d,docsPath:et}){super(["The initCode returned a different smart account address than expected.",`Expected: ${d}`,"","Possible reasons:","• Account deployed with the initCode provided does not match match the sender address provided","","Possible solutions:","• Verify that the sender address was generated deterministically from the initCode. (consider leveraging functions like getSenderAddress)","• Verify that the factory address in the initCode is correct (the factory address is the first 20 bytes of the initCode)","• Verify that the initCode is correct.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SenderAddressMismatchError"})}}Object.defineProperty(SenderAddressMismatchError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa14/});class InitCodeDidNotDeploySenderError extends BaseError{constructor({cause:a,sender:d,docsPath:et}){super([`The initCode did not deploy the sender at the address ${d}.`,"","Possible reasons:","• The initCode factory is not creating an account.","• The initCode factory is creating an account, but is not implemented correctly as it is not deploying at the sender address","","Possible solutions:","• Verify that the factory address in the initCode is correct (the factory address is the first 20 bytes of the initCode).","• Verify that the initCode factory is implemented correctly. The factory must deploy the smart account at the sender address.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InitCodeDidNotDeploySenderError"})}}Object.defineProperty(InitCodeDidNotDeploySenderError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa15/});class SenderNotDeployedError extends BaseError{constructor({cause:a,sender:d,docsPath:et}){super([`Smart account ${d} is not deployed.`,"","Possible reasons:","• An initCode was not specified, but the sender address (i.e. the smart account) is not deployed.","","Possible solutions:","• If this is the first transaction by this account, make sure the initCode is included in the user operation.","• If the smart account is already supposed to be deployed, verify that you have selected the correct sender address for the user operation.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SenderNotDeployedError"})}}Object.defineProperty(SenderNotDeployedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa20/});class SmartAccountInsufficientFundsError extends BaseError{constructor({cause:a,sender:d,docsPath:et}){super([`You are not using a paymaster, and the ${d} address did not have enough native tokens to cover the gas costs associated with the user operation.`,"","Possible solutions:","• If you are not using a paymaster, verify that the sender address has enough native tokens to cover the required prefund. Consider leveraging functions like getRequiredPrefund.","• If you are looking to use a paymaster to cover the gas fees, verify that the paymasterAndData field is set.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SmartAccountInsufficientFundsError"})}}Object.defineProperty(SmartAccountInsufficientFundsError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa21/});class SmartAccountSignatureValidityPeriodError extends BaseError{constructor({cause:a,docsPath:d}){super(["The signature used in the user operation is not valid, because it is outside of the time range it specified.","","Possible reasons:","• This error occurs when the block.timestamp falls after the validUntil timestamp, or before the validAfter timestamp.","","Possible solutions:","• If you are looking to use time-based signatures, verify that the validAfter and validUntil fields are set correctly and that the user operation is sent within the specified range.","• If you are not looking to use time-based signatures, verify that the validAfter and validUntil fields are set to 0.","",d?`Docs: ${d}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SmartAccountSignatureValidityPeriodError"})}}Object.defineProperty(SmartAccountSignatureValidityPeriodError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa22/});class SmartAccountValidationRevertedError extends BaseError{constructor({cause:a,sender:d,docsPath:et}){super([`The smart account ${d} reverted or ran out of gas during the validation of the user operation.`,"","Possible solutions:","• Verify that the verificationGasLimit is high enough to cover the validateUserOp function's gas costs.","• Make sure validateUserOp returns uint(1) for invalid signatures, and MUST NOT REVERT when the signature is invalid","• If you are not using a paymaster, verify that the sender address has enough native tokens to cover the required pre fund. Consider leveraging functions like getRequiredPrefund.","• Verify that the validateUserOp function is implemented with the correct logic, and that the user operation is supposed to be valid.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SmartAccountValidationRevertedError"})}}Object.defineProperty(SmartAccountValidationRevertedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa23/});class InvalidSmartAccountNonceError extends BaseError{constructor({cause:a,sender:d,nonce:et,docsPath:nt}){const tt=et>>BigInt(64),bt=et&0xffffffffffffffffn;super([`The smart account ${d} nonce is invalid.`,`Nonce sent: ${et} (key: ${tt}, sequence: ${bt})`,"","Possible solutions:","• Verify that you are using the correct nonce for the user operation. The nonce should be the current nonce of the smart account for the selected key. Consider leveraging functions like getAccountNonce.","• Verify that the nonce is formatted correctly.","",nt?`Docs: ${nt}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSmartAccountNonceError"})}}Object.defineProperty(InvalidSmartAccountNonceError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa25/});function getSendUserOperationError(c,a){const d=(()=>{const et=getBundlerError(c,a);return et instanceof UnknownNodeError?c:et})();throw new SendUserOperationError(d,{...a})}const sendUserOperation$1=async(c,a)=>{const{userOperation:d,entryPoint:et}=a;try{return await c.request({method:"eth_sendUserOperation",params:[deepHexlify(d),et]})}catch(nt){throw getSendUserOperationError(nt,a)}};class SendUserOperationError extends BaseError{constructor(a,{userOperation:d,entryPoint:et,docsPath:nt}){const tt=prettyPrint({...d,entryPoint:et});super(a.shortMessage,{cause:a,docsPath:nt,metaMessages:[...a.metaMessages?[...a.metaMessages," "]:[],"sendUserOperation Arguments:",tt].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SendUserOperationError"}),this.cause=a}}class PaymasterNotDeployedError extends BaseError{constructor({cause:a,paymasterAndData:d,docsPath:et}={}){const nt=d?getAddressFromInitCodeOrPaymasterAndData(d):"0x";super([`Paymaster ${nt} is not deployed.`,"","Possible solutions:","• Verify that the paymasterAndData field is correct, and that the first 20 bytes are the address of the paymaster contract you intend to use.","• Verify that the paymaster contract is deployed on the network you are using.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PaymasterNotDeployedError"})}}Object.defineProperty(PaymasterNotDeployedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa30/});class PaymasterDepositTooLowError extends BaseError{constructor({cause:a,paymasterAndData:d,docsPath:et}={}){const nt=d?getAddressFromInitCodeOrPaymasterAndData(d):"0x";super([`Paymaster ${nt} contract does not have enough funds deposited into the EntryPoint contract to cover the required funds for the user operation.`,"","Possible solutions:","• If you are using your own paymaster contract, deposit more funds into the EntryPoint contract through the deposit() function of the paymaster contract.","• Verify that the paymasterAndData field is correct, and that the first 20 bytes are the address of the paymaster contract you intend to useVerify that the paymasterAndData field is correct, and that the first 20 bytes are the address of the paymaster contract you intend to use.","• If you are using a paymaster service, reach out to them.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PaymasterDepositTooLowError"})}}Object.defineProperty(PaymasterDepositTooLowError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa31/});class PaymasterValidityPeriodError extends BaseError{constructor({cause:a,paymasterAndData:d,docsPath:et}){const nt=d?getAddressFromInitCodeOrPaymasterAndData(d):"0x";super([`Paymaster ${nt}'s data used in the paymasterAndData field of the user operation is not valid, because it is outside of the time range it specified.`,"","Possible reasons:","• This error occurs when the block.timestamp falls after the validUntil timestamp, or before the validAfter timestamp.","","Possible solutions:","• If you are using your own paymaster contract and using time-based signatures, verify that the validAfter and validUntil fields are set correctly and that the user operation is sent within the specified range.","• If you are using your own paymaster contract and not looking to use time-based signatures, verify that the validAfter and validUntil fields are set to 0.","• If you are using a service, contact your service provider for their paymaster's validity.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PaymasterValidityPeriodError"})}}Object.defineProperty(PaymasterValidityPeriodError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa32/});class PaymasterValidationRevertedError extends BaseError{constructor({cause:a,paymasterAndData:d,docsPath:et}){const nt=d?getAddressFromInitCodeOrPaymasterAndData(d):"0x";super([`The validatePaymasterUserOp function of the paymaster ${nt} either reverted or ran out of gas.`,"","Possible solutions:","• Verify that the verificationGasLimit is high enough to cover the validatePaymasterUserOp function's gas costs.","• If you are using your own paymaster contract, verify that the validatePaymasterUserOp function is implemented with the correct logic, and that the user operation is supposed to be valid.","• If you are using a paymaster service, and the user operation is well formed with a high enough verificationGasLimit, reach out to them.","• If you are not looking to use a paymaster to cover the gas fees, verify that the paymasterAndData field is not set.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PaymasterValidationRevertedError"})}}Object.defineProperty(PaymasterValidationRevertedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa33/});class PaymasterDataRejectedError extends BaseError{constructor({cause:a,paymasterAndData:d,docsPath:et}){const nt=d?getAddressFromInitCodeOrPaymasterAndData(d):"0x";super([`The validatePaymasterUserOp function of the paymaster ${nt} rejected paymasterAndData.`,"","Possible solutions:","• If you are using your own paymaster contract, verify that the user operation was correctly signed according to your implementation, and that the paymaster signature was correctly encoded in the paymasterAndData field of the user operation.","• If you are using a paymaster service, make sure you do not modify any of the fields of the user operation after the paymaster signs over it (except the signature field).","• If you are using a paymaster service and you have not modified any of the fields except the signature but you are still getting this error, reach out to them.","",et?`Docs: ${et}`:""].join(` +`),{cause:a}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PaymasterDataRejectedError"})}}Object.defineProperty(PaymasterDataRejectedError,"message",{enumerable:!0,configurable:!0,writable:!0,value:/aa34/});function getBundlerError(c,a){const d=(c.details||"").toLowerCase(),et=c instanceof BaseError?c.walk(nt=>nt.code===ExecutionRevertedError.code):c;return et instanceof BaseError?new ExecutionRevertedError({cause:c,message:et.details}):a.userOperation.sender===void 0?new UnknownNodeError({cause:c}):a.userOperation.nonce===void 0?new UnknownNodeError({cause:c}):SenderAlreadyDeployedError.message.test(d)?new SenderAlreadyDeployedError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa10"}):InitCodeRevertedError.message.test(d)?new InitCodeRevertedError({cause:c,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa13"}):SenderAddressMismatchError.message.test(d)?new SenderAddressMismatchError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa14"}):InitCodeDidNotDeploySenderError.message.test(d)?new InitCodeDidNotDeploySenderError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa15"}):SenderNotDeployedError.message.test(d)?new SenderNotDeployedError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa20"}):SmartAccountInsufficientFundsError.message.test(d)?new SmartAccountInsufficientFundsError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa21"}):SmartAccountSignatureValidityPeriodError.message.test(d)?new SmartAccountSignatureValidityPeriodError({cause:c,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa22"}):SmartAccountValidationRevertedError.message.test(d)?new SmartAccountValidationRevertedError({cause:c,sender:a.userOperation.sender,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa23"}):InvalidSmartAccountNonceError.message.test(d)?new InvalidSmartAccountNonceError({cause:c,sender:a.userOperation.sender,nonce:a.userOperation.nonce,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa25"}):PaymasterNotDeployedError.message.test(d)?new PaymasterNotDeployedError({cause:c,paymasterAndData:a.userOperation.paymasterAndData,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa30"}):PaymasterDepositTooLowError.message.test(d)?new PaymasterDepositTooLowError({cause:c,paymasterAndData:a.userOperation.paymasterAndData,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa31"}):PaymasterValidityPeriodError.message.test(d)?new PaymasterValidityPeriodError({cause:c,paymasterAndData:a.userOperation.paymasterAndData,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa32"}):PaymasterValidationRevertedError.message.test(d)?new PaymasterValidationRevertedError({cause:c,paymasterAndData:a.userOperation.paymasterAndData,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa33"}):PaymasterDataRejectedError.message.test(d)?new PaymasterDataRejectedError({cause:c,paymasterAndData:a.userOperation.paymasterAndData,docsPath:"https://docs.pimlico.io/bundler/reference/entrypoint-errors/aa34"}):new UnknownNodeError({cause:c})}function getEstimateUserOperationGasError(c,a){const d=(()=>{const et=getBundlerError(c,a);return et instanceof UnknownNodeError?c:et})();throw new EstimateUserOperationGasError(d,{...a})}const estimateUserOperationGas=async(c,a,d)=>{const{userOperation:et,entryPoint:nt}=a,tt=deepHexlify(et),bt=deepHexlify(d);try{const mt=await c.request({method:"eth_estimateUserOperationGas",params:d?[tt,nt,bt]:[tt,nt]});if(getEntryPointVersion(nt)==="v0.6"){const At=mt;return{preVerificationGas:BigInt(At.preVerificationGas||0),verificationGasLimit:BigInt(At.verificationGasLimit||0),callGasLimit:BigInt(At.callGasLimit||0)}}const $t=mt;return{preVerificationGas:BigInt($t.preVerificationGas||0),verificationGasLimit:BigInt($t.verificationGasLimit||0),callGasLimit:BigInt($t.callGasLimit||0),paymasterVerificationGasLimit:$t.paymasterVerificationGasLimit?BigInt($t.paymasterVerificationGasLimit):void 0,paymasterPostOpGasLimit:$t.paymasterPostOpGasLimit?BigInt($t.paymasterPostOpGasLimit):void 0}}catch(mt){throw getEstimateUserOperationGasError(mt,a)}},getUserOperationByHash=async(c,{hash:a})=>{const d=[a],et=await c.request({method:"eth_getUserOperationByHash",params:d});if(!et)return null;const{userOperation:nt,entryPoint:tt,transactionHash:bt,blockHash:mt,blockNumber:vt}=et;return{userOperation:tt===ENTRYPOINT_ADDRESS_V06?{...nt,nonce:BigInt(nt.nonce),callGasLimit:BigInt(nt.callGasLimit),verificationGasLimit:BigInt(nt.verificationGasLimit),preVerificationGas:BigInt(nt.preVerificationGas),maxFeePerGas:BigInt(nt.maxFeePerGas),maxPriorityFeePerGas:BigInt(nt.maxPriorityFeePerGas)}:{...nt,nonce:BigInt(nt.nonce),callGasLimit:BigInt(nt.callGasLimit),verificationGasLimit:BigInt(nt.verificationGasLimit),preVerificationGas:BigInt(nt.preVerificationGas),maxFeePerGas:BigInt(nt.maxFeePerGas),maxPriorityFeePerGas:BigInt(nt.maxPriorityFeePerGas),paymasterVerificationGasLimit:nt.paymasterVerificationGasLimit?BigInt(nt.paymasterVerificationGasLimit):void 0,paymasterPostOpGasLimit:nt.paymasterVerificationGasLimit?BigInt(nt.paymasterPostOpGasLimit):void 0},entryPoint:tt,transactionHash:bt,blockHash:mt,blockNumber:BigInt(vt)}},getUserOperationReceipt=async(c,{hash:a})=>{const d=[a],et=await c.request({method:"eth_getUserOperationReceipt",params:d});return et?{userOpHash:et.userOpHash,sender:et.sender,nonce:BigInt(et.nonce),actualGasUsed:BigInt(et.actualGasUsed),actualGasCost:BigInt(et.actualGasCost),success:et.success,receipt:{transactionHash:et.receipt.transactionHash,transactionIndex:BigInt(et.receipt.transactionIndex),blockHash:et.receipt.blockHash,blockNumber:BigInt(et.receipt.blockNumber),from:et.receipt.from,to:et.receipt.to,cumulativeGasUsed:BigInt(et.receipt.cumulativeGasUsed),status:transactionReceiptStatus[et.receipt.status],gasUsed:BigInt(et.receipt.gasUsed),contractAddress:et.receipt.contractAddress,logsBloom:et.receipt.logsBloom,effectiveGasPrice:BigInt(et.receipt.effectiveGasPrice)},logs:et.logs.map(tt=>({data:tt.data,blockNumber:BigInt(tt.blockNumber),blockHash:tt.blockHash,transactionHash:tt.transactionHash,logIndex:BigInt(tt.logIndex),transactionIndex:BigInt(tt.transactionIndex),address:tt.address,topics:tt.topics}))}:null},supportedEntryPoints=async c=>c.request({method:"eth_supportedEntryPoints",params:[]}),listenersCache=new Map,cleanupCache=new Map;let callbackCount=0;function observe(c,a,d){const et=++callbackCount,nt=()=>listenersCache.get(c)||[],tt=()=>{const At=nt();listenersCache.set(c,At.filter(Mt=>Mt.id!==et))},bt=()=>{const At=cleanupCache.get(c);nt().length===1&&At&&At(),tt()},mt=nt();if(listenersCache.set(c,[...mt,{id:et,fns:a}]),mt&&mt.length>0)return bt;const vt={};for(const At in a)vt[At]=(...Mt)=>{var Rt,kt;const Tt=nt();if(Tt.length!==0)for(const It of Tt)(kt=(Rt=It.fns)[At])==null||kt.call(Rt,...Mt)};const $t=d(vt);return typeof $t=="function"&&cleanupCache.set(c,$t),bt}class WaitForUserOperationReceiptTimeoutError extends BaseError{constructor({hash:a}){super(`Timed out while waiting for transaction with hash "${a}" to be confirmed.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WaitForUserOperationReceiptTimeoutError"})}}const waitForUserOperationReceipt=(c,{hash:a,pollingInterval:d=c.pollingInterval,timeout:et})=>{const nt=stringify(["waitForUserOperationReceipt",c.uid,a]);let tt;return new Promise((bt,mt)=>{const vt=observe(nt,{resolve:bt,reject:mt},async $t=>{let At;const Mt=setInterval(async()=>{const Tt=Rt=>{clearInterval(Mt),Rt(),vt(),et&&clearTimeout(At)};try{const Rt=await getAction(c,getUserOperationReceipt,"getUserOperationReceipt")({hash:a});if(Rt!==null&&(tt=Rt),tt){Tt(()=>$t.resolve(tt));return}}catch(Rt){Tt(()=>$t.reject(Rt));return}},d);et&&(At=setTimeout(()=>{clearInterval(Mt),vt(),mt(new WaitForUserOperationReceiptTimeoutError({hash:a})),clearTimeout(At)},et))})})},getAccountNonce=async(c,a)=>{const{sender:d,entryPoint:et,key:nt=BigInt(0)}=a;return await getAction(c,readContract,"readContract")({address:et,abi:[{inputs:[{name:"sender",type:"address"},{name:"key",type:"uint192"}],name:"getNonce",outputs:[{name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],functionName:"getNonce",args:[d,nt]})},bundlerActions=c=>a=>({sendUserOperation:async d=>sendUserOperation$1(a,{...d,entryPoint:c}),estimateUserOperationGas:(d,et)=>estimateUserOperationGas(a,{...d,entryPoint:c},et),supportedEntryPoints:()=>supportedEntryPoints(a),chainId:()=>chainId(a),getUserOperationByHash:d=>getUserOperationByHash(a,d),getUserOperationReceipt:d=>getUserOperationReceipt(a,d),waitForUserOperationReceipt:d=>waitForUserOperationReceipt(a,d)}),contracts={gasPriceOracle:{address:"0x420000000000000000000000000000000000000F"},l1Block:{address:"0x4200000000000000000000000000000000000015"},l2CrossDomainMessenger:{address:"0x4200000000000000000000000000000000000007"},l2Erc721Bridge:{address:"0x4200000000000000000000000000000000000014"},l2StandardBridge:{address:"0x4200000000000000000000000000000000000010"},l2ToL1MessagePasser:{address:"0x4200000000000000000000000000000000000016"}},formatters$1={block:defineBlock({format(c){var d;return{transactions:(d=c.transactions)==null?void 0:d.map(et=>{if(typeof et=="string")return et;const nt=formatTransaction(et);return nt.typeHex==="0x7e"&&(nt.isSystemTx=et.isSystemTx,nt.mint=et.mint?hexToBigInt(et.mint):void 0,nt.sourceHash=et.sourceHash,nt.type="deposit"),nt}),stateRoot:c.stateRoot}}}),transaction:defineTransaction({format(c){const a={};return c.type==="0x7e"&&(a.isSystemTx=c.isSystemTx,a.mint=c.mint?hexToBigInt(c.mint):void 0,a.sourceHash=c.sourceHash,a.type="deposit"),a}}),transactionReceipt:defineTransactionReceipt({format(c){return{l1GasPrice:c.l1GasPrice?hexToBigInt(c.l1GasPrice):null,l1GasUsed:c.l1GasUsed?hexToBigInt(c.l1GasUsed):null,l1Fee:c.l1Fee?hexToBigInt(c.l1Fee):null,l1FeeScalar:c.l1FeeScalar?Number(c.l1FeeScalar):null}}})};function serializeTransaction$1(c,a){return isDeposit(c)?serializeTransactionDeposit(c):serializeTransaction$2(c,a)}const serializers$1={transaction:serializeTransaction$1};function serializeTransactionDeposit(c){assertTransactionDeposit(c);const{sourceHash:a,data:d,from:et,gas:nt,isSystemTx:tt,mint:bt,to:mt,value:vt}=c,$t=[a,et,mt??"0x",bt?toHex(bt):"0x",vt?toHex(vt):"0x",nt?toHex(nt):"0x",tt?"0x1":"0x",d??"0x"];return concatHex(["0x7e",toRlp($t)])}function isDeposit(c){return c.type==="deposit"||typeof c.sourceHash<"u"}function assertTransactionDeposit(c){const{from:a,to:d}=c;if(a&&!isAddress(a))throw new InvalidAddressError({address:a});if(d&&!isAddress(d))throw new InvalidAddressError({address:d})}const chainConfig$1={contracts,formatters:formatters$1,serializers:serializers$1},sourceId$2=1,base=defineChain({...chainConfig$1,id:8453,name:"Base",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://mainnet.base.org"]}},blockExplorers:{default:{name:"Basescan",url:"https://basescan.org",apiUrl:"https://api.basescan.org/api"}},contracts:{...chainConfig$1.contracts,l2OutputOracle:{[sourceId$2]:{address:"0x56315b90c40730925ec5485cf004d835058518A0"}},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:5022},portal:{[sourceId$2]:{address:"0x49048044D57e1C92A77f79988d21Fa8fAF74E97e",blockCreated:17482143}},l1StandardBridge:{[sourceId$2]:{address:"0x3154Cf16ccdb4C6d922629664174b904d80F2C35",blockCreated:17482143}}},sourceId:sourceId$2}),sourceId$1=5,baseGoerli=defineChain({...chainConfig$1,id:84531,name:"Base Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://goerli.base.org"]}},blockExplorers:{default:{name:"Basescan",url:"https://goerli.basescan.org",apiUrl:"https://goerli.basescan.org/api"}},contracts:{...chainConfig$1.contracts,l2OutputOracle:{[sourceId$1]:{address:"0x2A35891ff30313CcFa6CE88dcf3858bb075A2298"}},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:1376988},portal:{[sourceId$1]:{address:"0xe93c8cD0D409341205A592f8c4Ac1A5fe5585cfA"}},l1StandardBridge:{[sourceId$1]:{address:"0xfA6D8Ee5BE770F84FC001D098C4bD604Fe01284a"}}},testnet:!0,sourceId:sourceId$1}),sourceId=11155111,baseSepolia=defineChain({...chainConfig$1,id:84532,network:"base-sepolia",name:"Base Sepolia",nativeCurrency:{name:"Sepolia Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://sepolia.base.org"]}},blockExplorers:{default:{name:"Basescan",url:"https://sepolia.basescan.org",apiUrl:"https://api-sepolia.basescan.org/api"}},contracts:{...chainConfig$1.contracts,l2OutputOracle:{[sourceId]:{address:"0x84457ca9D0163FbC4bbfe4Dfbb20ba46e48DF254"}},portal:{[sourceId]:{address:"0x49f53e41452c74589e85ca1677426ba426459e85",blockCreated:4446677}},l1StandardBridge:{[sourceId]:{address:"0xfd0Bf71F60660E2f608ed56e1659C450eB113120",blockCreated:4446677}},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:1059647}},testnet:!0,sourceId});function isEmpty(c){return c===0||c===0n||c===void 0||c===null||c==="0"||c===""||typeof c=="string"&&(trim(c).toLowerCase()==="0x"||trim(c).toLowerCase()==="0x00")}function isPresent(c){return!isEmpty(c)}function isEIP1559(c){return typeof c.maxFeePerGas<"u"&&typeof c.maxPriorityFeePerGas<"u"}function isCIP42(c){return c.type==="cip42"?!0:isEIP1559(c)&&(isPresent(c.feeCurrency)||isPresent(c.gatewayFeeRecipient)||isPresent(c.gatewayFee))}function isCIP64(c){return c.type==="cip64"?!0:isEIP1559(c)&&isPresent(c.feeCurrency)&&isEmpty(c.gatewayFee)&&isEmpty(c.gatewayFeeRecipient)}const formatters={block:defineBlock({exclude:["difficulty","gasLimit","mixHash","nonce","uncles"],format(c){var d;const a=(d=c.transactions)==null?void 0:d.map(et=>typeof et=="string"?et:{...formatTransaction(et),feeCurrency:et.feeCurrency,...et.type!=="0x7b"?{gatewayFee:et.gatewayFee?hexToBigInt(et.gatewayFee):null,gatewayFeeRecipient:et.gatewayFeeRecipient||null}:{}});return{randomness:c.randomness,transactions:a}}}),transaction:defineTransaction({format(c){const a={feeCurrency:c.feeCurrency};return c.type==="0x7b"?a.type="cip64":(c.type==="0x7c"&&(a.type="cip42"),a.gatewayFee=c.gatewayFee?hexToBigInt(c.gatewayFee):null,a.gatewayFeeRecipient=c.gatewayFeeRecipient),a}}),transactionRequest:defineTransactionRequest({format(c){const a={feeCurrency:c.feeCurrency};return isCIP64(c)?a.type="0x7b":(isCIP42(c)&&(a.type="0x7c"),a.gatewayFee=typeof c.gatewayFee<"u"?numberToHex(c.gatewayFee):void 0,a.gatewayFeeRecipient=c.gatewayFeeRecipient),a}})},fees={estimateFeesPerGas:async c=>{var et;if(!((et=c.request)!=null&&et.feeCurrency))return null;const[a,d]=await Promise.all([estimateFeePerGasInFeeCurrency(c.client,c.request.feeCurrency),estimateMaxPriorityFeePerGasInFeeCurrency(c.client,c.request.feeCurrency)]);return{maxFeePerGas:a,maxPriorityFeePerGas:d}}};async function estimateFeePerGasInFeeCurrency(c,a){const d=await c.request({method:"eth_gasPrice",params:[a]});return BigInt(d)}async function estimateMaxPriorityFeePerGasInFeeCurrency(c,a){const d=await c.request({method:"eth_maxPriorityFeePerGas",params:[a]});return BigInt(d)}function serializeTransaction(c,a){return isCIP64(c)?serializeTransactionCIP64(c,a):isCIP42(c)?serializeTransactionCIP42(c,a):serializeTransaction$2(c,a)}const serializers={transaction:serializeTransaction};function serializeTransactionCIP42(c,a){assertTransactionCIP42(c);const{chainId:d,gas:et,nonce:nt,to:tt,value:bt,maxFeePerGas:mt,maxPriorityFeePerGas:vt,accessList:$t,feeCurrency:At,gatewayFeeRecipient:Mt,gatewayFee:Tt,data:Rt}=c,kt=[toHex(d),nt?toHex(nt):"0x",vt?toHex(vt):"0x",mt?toHex(mt):"0x",et?toHex(et):"0x",At??"0x",Mt??"0x",Tt?toHex(Tt):"0x",tt??"0x",bt?toHex(bt):"0x",Rt??"0x",serializeAccessList($t),...toYParitySignatureArray(c,a)];return concatHex(["0x7c",toRlp(kt)])}function serializeTransactionCIP64(c,a){assertTransactionCIP64(c);const{chainId:d,gas:et,nonce:nt,to:tt,value:bt,maxFeePerGas:mt,maxPriorityFeePerGas:vt,accessList:$t,feeCurrency:At,data:Mt}=c,Tt=[toHex(d),nt?toHex(nt):"0x",vt?toHex(vt):"0x",mt?toHex(mt):"0x",et?toHex(et):"0x",tt??"0x",bt?toHex(bt):"0x",Mt??"0x",serializeAccessList($t),At,...toYParitySignatureArray(c,a)];return concatHex(["0x7b",toRlp(Tt)])}const MAX_MAX_FEE_PER_GAS=2n**256n-1n;function assertTransactionCIP42(c){const{chainId:a,maxPriorityFeePerGas:d,gasPrice:et,maxFeePerGas:nt,to:tt,feeCurrency:bt,gatewayFee:mt,gatewayFeeRecipient:vt}=c;if(a<=0)throw new InvalidChainIdError({chainId:a});if(tt&&!isAddress(tt))throw new InvalidAddressError({address:tt});if(et)throw new BaseError("`gasPrice` is not a valid CIP-42 Transaction attribute.");if(isPresent(nt)&&nt>MAX_MAX_FEE_PER_GAS)throw new FeeCapTooHighError({maxFeePerGas:nt});if(isPresent(d)&&isPresent(nt)&&d>nt)throw new TipAboveFeeCapError({maxFeePerGas:nt,maxPriorityFeePerGas:d});if(isPresent(mt)&&isEmpty(vt)||isPresent(vt)&&isEmpty(mt))throw new BaseError("`gatewayFee` and `gatewayFeeRecipient` must be provided together.");if(isPresent(bt)&&!isAddress(bt))throw new BaseError("`feeCurrency` MUST be a token address for CIP-42 transactions.");if(isPresent(vt)&&!isAddress(vt))throw new InvalidAddressError(vt);if(isEmpty(bt)&&isEmpty(vt))throw new BaseError("Either `feeCurrency` or `gatewayFeeRecipient` must be provided for CIP-42 transactions.")}function assertTransactionCIP64(c){const{chainId:a,maxPriorityFeePerGas:d,gasPrice:et,maxFeePerGas:nt,to:tt,feeCurrency:bt}=c;if(a<=0)throw new InvalidChainIdError({chainId:a});if(tt&&!isAddress(tt))throw new InvalidAddressError({address:tt});if(et)throw new BaseError("`gasPrice` is not a valid CIP-64 Transaction attribute.");if(isPresent(nt)&&nt>MAX_MAX_FEE_PER_GAS)throw new FeeCapTooHighError({maxFeePerGas:nt});if(isPresent(d)&&isPresent(nt)&&d>nt)throw new TipAboveFeeCapError({maxFeePerGas:nt,maxPriorityFeePerGas:d});if(isPresent(bt)&&!isAddress(bt))throw new BaseError("`feeCurrency` MUST be a token address for CIP-64 transactions.");if(isEmpty(bt))throw new BaseError("`feeCurrency` must be provided for CIP-64 transactions.")}const chainConfig={formatters,serializers,fees},celo=defineChain({...chainConfig,id:42220,name:"Celo",nativeCurrency:{decimals:18,name:"CELO",symbol:"CELO"},rpcUrls:{default:{http:["https://forno.celo.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/mainnet",apiUrl:"https://explorer.celo.org/api"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:13112599}},testnet:!1}),goerli=defineChain({id:5,name:"Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://rpc.ankr.com/eth_goerli"]}},blockExplorers:{default:{name:"Etherscan",url:"https://goerli.etherscan.io",apiUrl:"https://api-goerli.etherscan.io/api"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xfc4AC75C46C914aF5892d6d3eFFcebD7917293F1",blockCreated:10339206},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:6507670}},testnet:!0}),gnosis=defineChain({id:100,name:"Gnosis",nativeCurrency:{decimals:18,name:"Gnosis",symbol:"xDAI"},rpcUrls:{default:{http:["https://rpc.gnosischain.com"],webSocket:["wss://rpc.gnosischain.com/wss"]}},blockExplorers:{default:{name:"Gnosisscan",url:"https://gnosisscan.io",apiUrl:"https://api.gnosisscan.io/api"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:21022491}}}),polygon=defineChain({id:137,name:"Polygon",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{default:{http:["https://polygon-rpc.com"]}},blockExplorers:{default:{name:"PolygonScan",url:"https://polygonscan.com",apiUrl:"https://api.polygonscan.com/api"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:25770160}}}),sepolia=defineChain({id:11155111,name:"Sepolia",nativeCurrency:{name:"Sepolia Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://rpc.sepolia.org"]}},blockExplorers:{default:{name:"Etherscan",url:"https://sepolia.etherscan.io",apiUrl:"https://api-sepolia.etherscan.io/api"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:751532},ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xc8Af999e38273D658BE1b921b88A9Ddf005769cC",blockCreated:5317080}},testnet:!0}),getUserOperationGasPrice=async c=>{const a=await c.request({method:"pimlico_getUserOperationGasPrice",params:[]});return{slow:{maxFeePerGas:BigInt(a.slow.maxFeePerGas),maxPriorityFeePerGas:BigInt(a.slow.maxPriorityFeePerGas)},standard:{maxFeePerGas:BigInt(a.standard.maxFeePerGas),maxPriorityFeePerGas:BigInt(a.standard.maxPriorityFeePerGas)},fast:{maxFeePerGas:BigInt(a.fast.maxFeePerGas),maxPriorityFeePerGas:BigInt(a.fast.maxPriorityFeePerGas)}}},getUserOperationStatus=async(c,{hash:a})=>c.request({method:"pimlico_getUserOperationStatus",params:[a]}),sendCompressedUserOperation=async(c,a)=>{const{compressedUserOperation:d,inflatorAddress:et,entryPoint:nt}=a;return c.request({method:"pimlico_sendCompressedUserOperation",params:[d,et,nt]})},sponsorUserOperation=async(c,a)=>{const d=await c.request({method:"pm_sponsorUserOperation",params:a.sponsorshipPolicyId?[deepHexlify(a.userOperation),a.entryPoint,{sponsorshipPolicyId:a.sponsorshipPolicyId}]:[deepHexlify(a.userOperation),a.entryPoint]});if(a.entryPoint===ENTRYPOINT_ADDRESS_V06){const nt=d;return{paymasterAndData:nt.paymasterAndData,preVerificationGas:BigInt(nt.preVerificationGas),verificationGasLimit:BigInt(nt.verificationGasLimit),callGasLimit:BigInt(nt.callGasLimit)}}const et=d;return{callGasLimit:BigInt(et.callGasLimit),verificationGasLimit:BigInt(et.verificationGasLimit),preVerificationGas:BigInt(et.preVerificationGas),paymaster:et.paymaster,paymasterVerificationGasLimit:BigInt(et.paymasterVerificationGasLimit),paymasterPostOpGasLimit:BigInt(et.paymasterPostOpGasLimit),paymasterData:et.paymasterData}},validateSponsorshipPolicies=async(c,a)=>await c.request({method:"pm_validateSponsorshipPolicies",params:[deepHexlify(a.userOperation),a.entryPoint,a.sponsorshipPolicyIds]}),pimlicoBundlerActions=c=>a=>({getUserOperationGasPrice:async()=>getUserOperationGasPrice(a),getUserOperationStatus:async d=>getUserOperationStatus(a,d),sendCompressedUserOperation:async d=>sendCompressedUserOperation(a,{...d,entryPoint:c})}),pimlicoPaymasterActions=c=>a=>({sponsorUserOperation:async d=>sponsorUserOperation(a,{...d,entryPoint:c}),validateSponsorshipPolicies:async d=>validateSponsorshipPolicies(a,{...d,entryPoint:c})}),createPimlicoBundlerClient=c=>{const{key:a="public",name:d="Pimlico Bundler Client"}=c;return createClient({...c,key:a,name:d,type:"pimlicoBundlerClient"}).extend(bundlerActions(c.entryPoint)).extend(pimlicoBundlerActions(c.entryPoint))},createPimlicoPaymasterClient=c=>{const{key:a="public",name:d="Pimlico Paymaster Client"}=c;return createClient({...c,key:a,name:d,type:"pimlicoPaymasterClient"}).extend(pimlicoPaymasterActions(c.entryPoint))},getChain=c=>[base,celo,gnosis,sepolia,baseGoerli,goerli,polygon,baseSepolia].find(a=>a.id==c),sendUserOperation=async(c,a,d)=>{const et=getChain(c);console.log("insider",c,et);const nt=`https://api.pimlico.io/v2/${et.name.toLowerCase().replace(/\s+/g,"-")}/rpc?apikey=6da54156-e08c-4136-afe5-eea678bd5e97`,tt=createPimlicoBundlerClient({transport:http(nt),entryPoint:ENTRYPOINT_ADDRESS_V07}),bt=createPimlicoPaymasterClient({transport:http(nt),entryPoint:ENTRYPOINT_ADDRESS_V07}),mt=await tt.getUserOperationGasPrice();a.maxFeePerGas=mt.fast.maxFeePerGas,a.maxPriorityFeePerGas=mt.fast.maxPriorityFeePerGas,console.log(a);const vt=await bt.sponsorUserOperation({userOperation:a}),$t={...a,...vt};return console.log($t),console.log(await d($t)),$t.signature=await d($t),await tt.sendUserOperation({userOperation:$t})},waitForExecution=async(c,a)=>{const et=`https://api.pimlico.io/v2/${getChain(c).name.toLowerCase().replace(/\s+/g,"-")}/rpc?apikey=6da54156-e08c-4136-afe5-eea678bd5e97`;return await createPimlicoBundlerClient({transport:http(et),entryPoint:ENTRYPOINT_ADDRESS_V07}).waitForUserOperationReceipt({hash:a})},safe7579Module="0x94952C0Ea317E9b8Bca613490AF25f6185623284",spendLimitModule="0x6b29160491Ce38Aba4716b6018F372Ffe6d31eB0",getSessionData=async(c,a)=>{const d=await getJsonRpcProvider(c),nt=await new Contract(spendLimitModule,SpendLimitModule.abi,d).sessionKeys(a,0);return console.log(nt),nt};function generateRandomString(c){const a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";let d="";for(let et=0;et{const bt=["function execute(address sessionKey, uint256 sessionId, address to, uint256 value, bytes calldata data) external"],mt=new Interface(bt).encodeFunctionData("execute",[nt.address,0,a,d,et]),vt={target:spendLimitModule,value:0,callData:mt},$t=BigInt(pad(spendLimitModule,{dir:"right",size:24})||0),At=await getAccountNonce(publicClient(parseInt(c)),{sender:tt,entryPoint:ENTRYPOINT_ADDRESS_V07,key:$t});let Mt=buildUnsignedUserOpTransaction(tt,vt,At);return await sendUserOperation(c,Mt,async function(It){const Dt=await getJsonRpcProvider(c),Nt=new Contract(ENTRYPOINT_ADDRESS_V07,EntryPoint.abi,Dt);let Ot=getBytes(await Nt.getUserOpHash(getPackedUserOperation(It)));return await nt.signMessage(Ot)})},buildInitSafe7579=async()=>{await getSafeInfo();const a=(await(await getProvider()).getNetwork()).chainId.toString(),d=await getJsonRpcProvider(a),et=new Contract(safe7579Module,Safe7579.abi,d);return{to:safe7579Module,value:"0",data:(await et.initializeAccount.populateTransaction([],[],[],[],{registry:ZeroAddress,attesters:[],threshold:0})).data}},buildInstallValidator=async()=>{const c=await getSafeInfo(),d=(await(await getProvider()).getNetwork()).chainId.toString(),et=await getJsonRpcProvider(d),nt=new Contract(safe7579Module,Safe7579.abi,et);return{to:c.safeAddress,value:"0",data:(await nt.installModule.populateTransaction(1,spendLimitModule,"0x")).data}},buildInstallExecutor=async()=>{const c=await getSafeInfo(),d=(await(await getProvider()).getNetwork()).chainId.toString(),et=await getJsonRpcProvider(d),nt=new Contract(safe7579Module,Safe7579.abi,et);return{to:c.safeAddress,value:"0",data:(await nt.installModule.populateTransaction(2,spendLimitModule,"0x")).data}},buildAddSessionKey=async(c,a,d,et,nt,tt)=>{const bt=await getSafeInfo(),mt=await getProvider(),vt={account:bt.safeAddress,token:a,validAfter:nt,validUntil:tt,limitAmount:parseUnits$1(d,a!=ZeroAddress?await getTokenDecimals(a,mt):"ether"),limitUsed:0,lastUsed:0,refreshInterval:et},$t=(await mt.getNetwork()).chainId.toString(),At=await getJsonRpcProvider($t),Mt=new Contract(spendLimitModule,SpendLimitModule.abi,At);return{to:spendLimitModule,value:"0",data:(await Mt.addSessionKey.populateTransaction(c,vt)).data}},createSessionKey=async(c,a,d,et,nt)=>{if(!await isConnectedToSafe())throw Error("Not connected to a Safe");const tt=await getSafeInfo(),bt=[],mt=generateRandomString(18),{address:vt,privateKey:$t}=generateKeysFromString(mt);return await isModuleEnabled(tt.safeAddress,safe7579Module)?await isModuleInstalled(tt.safeAddress,spendLimitModule,1)||(bt.push(await buildInstallValidator()),bt.push(await buildInstallExecutor())):(bt.push(await buildEnableModule(tt.safeAddress,safe7579Module)),bt.push(await buildUpdateFallbackHandler(tt.safeAddress,safe7579Module)),bt.push(await buildInitSafe7579()),bt.push(await buildInstallValidator()),bt.push(await buildInstallExecutor())),bt.push(await buildAddSessionKey(vt,c,a,d,et,nt)),(await(await getProvider()).getNetwork()).chainId.toString(),bt.length==0?"":(await submitTxs(bt),mt)},Celo="/assets/celo-662fcaf6.jpg",Matic="/assets/matic-479d03ee.svg",EURe="/assets/eure-2379d6fa.svg",USDe="/assets/usde-f0eba4d9.svg",badgeIcons=[{ids:["84532","8453"],img:Base$9},{ids:["11155111","5","1"],img:ETH},{ids:["100"],img:"https://app.safe.global/images/networks/gno.png"},{ids:["42220"],img:Celo},{ids:["1101","137","80001"],img:Matic}];function getIconForId(c){for(const a of badgeIcons)if(a.ids.includes(c.toString()))return a.img;return"defaultIcon"}const tokenList={11155111:[{value:"0x0000000000000000000000000000000000000000",label:"ETH",image:ETH,description:"Ether currency"},{value:"0xd58C5Db52B5B3Eb24EE38AF287d2cb0F424172A5",label:"EURe",image:EURe,description:"Monerium EUR emoney"},{value:"0x8bA8662a7C5C6Be4B4ad7049c5DbF59aaCC2cf1e",label:"USDe",image:USDe,description:"Monerium USD emoney"}],84532:[{value:"0x0000000000000000000000000000000000000000",label:"ETH",image:ETH,description:"Ether currency"}],8453:[{value:"0x0000000000000000000000000000000000000000",label:"ETH",image:ETH,description:"Ether currency"},{value:"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",label:"USDC",image:USDe,description:"Circle USDS token"}]},getTokenInfo=(c,a)=>{try{if(Object.keys(tokenList).includes(c.toString()))return tokenList[c].find(d=>d.value.toLowerCase()==(a==null?void 0:a.toLowerCase()))}catch{console.log("Error getting token info")}return{}},getTokenList=c=>Object.keys(tokenList).includes(c.toString())?tokenList[c]:[];var Component={},toggleSelection=function(){var c=document.getSelection();if(!c.rangeCount)return function(){};for(var a=document.activeElement,d=[],et=0;et"u"){d&&console.warn("unable to use e.clipboardData"),d&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var Mt=clipboardToIE11Formatting[a.format]||clipboardToIE11Formatting.default;window.clipboardData.setData(Mt,c)}else At.clipboardData.clearData(),At.clipboardData.setData(a.format,c);a.onCopy&&(At.preventDefault(),a.onCopy(At.clipboardData))}),document.body.appendChild(mt),tt.selectNodeContents(mt),bt.addRange(tt);var $t=document.execCommand("copy");if(!$t)throw new Error("copy command was unsuccessful");vt=!0}catch(At){d&&console.error("unable to copy using execCommand: ",At),d&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(a.format||"text",c),a.onCopy&&a.onCopy(window.clipboardData),vt=!0}catch(Mt){d&&console.error("unable to copy using clipboardData: ",Mt),d&&console.error("falling back to prompt"),et=format("message"in a?a.message:defaultMessage),window.prompt(et,c)}}finally{bt&&(typeof bt.removeRange=="function"?bt.removeRange(tt):bt.removeAllRanges()),mt&&document.body.removeChild(mt),nt()}return vt}var copyToClipboard=copy;function _typeof(c){"@babel/helpers - typeof";return _typeof=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(c)}Object.defineProperty(Component,"__esModule",{value:!0});Component.CopyToClipboard=void 0;var _react=_interopRequireDefault(reactExports),_copyToClipboard=_interopRequireDefault(copyToClipboard),_excluded=["text","onCopy","options","children"];function _interopRequireDefault(c){return c&&c.__esModule?c:{default:c}}function ownKeys(c,a){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var et=Object.getOwnPropertySymbols(c);a&&(et=et.filter(function(nt){return Object.getOwnPropertyDescriptor(c,nt).enumerable})),d.push.apply(d,et)}return d}function _objectSpread(c){for(var a=1;a=0)&&Object.prototype.propertyIsEnumerable.call(c,et)&&(d[et]=c[et])}return d}function _objectWithoutPropertiesLoose(c,a){if(c==null)return{};var d={},et=Object.keys(c),nt,tt;for(tt=0;tt=0)&&(d[nt]=c[nt]);return d}function _classCallCheck(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}function _defineProperties(c,a){for(var d=0;d"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function _getPrototypeOf(c){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(d){return d.__proto__||Object.getPrototypeOf(d)},_getPrototypeOf(c)}function _defineProperty(c,a,d){return a in c?Object.defineProperty(c,a,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[a]=d,c}var CopyToClipboard$1=function(c){_inherits(d,c);var a=_createSuper(d);function d(){var et;_classCallCheck(this,d);for(var nt=arguments.length,tt=new Array(nt),bt=0;bta in c?__defProp(c,a,{enumerable:!0,configurable:!0,writable:!0,value:d}):c[a]=d,__spreadValues=(c,a)=>{for(var d in a||(a={}))__hasOwnProp.call(a,d)&&__defNormalProp(c,d,a[d]);if(__getOwnPropSymbols)for(var d of __getOwnPropSymbols(a))__propIsEnum.call(a,d)&&__defNormalProp(c,d,a[d]);return c},__spreadProps=(c,a)=>__defProps(c,__getOwnPropDescs(a)),__objRest=(c,a)=>{var d={};for(var et in c)__hasOwnProp.call(c,et)&&a.indexOf(et)<0&&(d[et]=c[et]);if(c!=null&&__getOwnPropSymbols)for(var et of __getOwnPropSymbols(c))a.indexOf(et)<0&&__propIsEnum.call(c,et)&&(d[et]=c[et]);return d},createReactComponent=(c,a,d)=>{const et=reactExports.forwardRef((nt,tt)=>{var bt=nt,{color:mt="currentColor",size:vt=24,stroke:$t=2,children:At}=bt,Mt=__objRest(bt,["color","size","stroke","children"]);return reactExports.createElement("svg",__spreadValues(__spreadProps(__spreadValues({ref:tt},defaultAttributes),{width:vt,height:vt,stroke:mt,strokeWidth:$t,className:`tabler-icon tabler-icon-${c}`}),Mt),[...d.map(([Tt,Rt])=>reactExports.createElement(Tt,Rt)),...At||[]])});return et.propTypes={color:PropTypes.string,size:PropTypes.oneOfType([PropTypes.string,PropTypes.number]),stroke:PropTypes.oneOfType([PropTypes.string,PropTypes.number])},et.displayName=`${a}`,et},IconBrandX=createReactComponent("brand-x","IconBrandX",[["path",{d:"M4 4l11.733 16h4.267l-11.733 -16z",key:"svg-0"}],["path",{d:"M4 20l6.768 -6.768m2.46 -2.46l6.772 -6.772",key:"svg-1"}]]);function HomePage(){useDisclosure(!1),useNavigate();const{colorScheme:c}=useMantineColorScheme(),a=c==="dark",{chainId:d,setChainId:et}=useLinkStore(Et=>Et),[nt,tt]=reactExports.useState("0"),[bt,mt]=reactExports.useState("");reactExports.useState(""),reactExports.useState(0);const[vt,$t]=reactExports.useState(Math.floor(Date.now()/1e3)),[At,Mt]=reactExports.useState(Math.floor(Date.now()/1e3)+86400);reactExports.useState("");const[Tt,Rt]=reactExports.useState(""),[kt,It]=reactExports.useState(!1);reactExports.useState("");const[Dt,Nt]=reactExports.useState(""),[Ot,Ut]=reactExports.useState(!1),[Gt,Wt]=reactExports.useState(!1),[Xt,a0]=reactExports.useState(!1),n0=useCombobox({onDropdownClose:()=>n0.resetSelectedOption()}),[t0,c0]=reactExports.useState("0x0000000000000000000000000000000000000000"),[Ct,dt]=reactExports.useState(0),[yt,gt]=reactExports.useState(0),xt=getTokenInfo(d,t0),St=getTokenList(d).map(Et=>jsxRuntimeExports.jsx(Combobox.Option,{value:Et.value,children:jsxRuntimeExports.jsx(_t,{...Et})},Et.value));function _t({image:Et,label:ht}){return jsxRuntimeExports.jsxs(Group,{style:{width:"100%"},children:[jsxRuntimeExports.jsx(Avatar,{src:Et,children:jsxRuntimeExports.jsx(KD,{size:"1.5rem"})}),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx(Text,{fz:"sm",fw:500,children:ht})})]})}const Pt=async()=>{var Et;Ut(!0);try{const ht=await createSessionKey(t0,nt,0,vt,At),wt=(Et=new URLSearchParams({key:ht,chainId:d}))==null?void 0:Et.toString(),Bt=`${window.location.href}#/claim?${wt}`;Nt(Bt),Ut(!1),gt(1)}catch{Ut(!1),Wt(!0)}It(!0)};return reactExports.useEffect(()=>{(async()=>{var Et;try{const ht=await getProvider(),wt=(await ht.getNetwork()).chainId;et(Number(wt)),Rt(`${(Et=NetworkUtil.getNetworkById(Number(wt)))==null?void 0:Et.name}`);const Bt=await getSafeInfo();mt(Bt==null?void 0:Bt.safeAddress),t0==ZeroAddress?dt(parseFloat(formatEther(await ht.getBalance(Bt==null?void 0:Bt.safeAddress))).toFixed(4)):dt(await getTokenBalance(t0,Bt==null?void 0:Bt.safeAddress,ht))}catch{console.log("No safe found"),Wt(!0)}})()},[t0]),jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsxs("h1",{className:classes$c.heading,children:["Share crypto from your",jsxRuntimeExports.jsx("div",{className:classes$c.safeContainer,children:jsxRuntimeExports.jsx("img",{className:classes$c.safe,src:Safe,alt:"avatar"})})]}),jsxRuntimeExports.jsx("h1",{className:classes$c.links,children:"via links 🔗"})]}),jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:jsxRuntimeExports.jsx("div",{className:classes$c.homeContainer,children:jsxRuntimeExports.jsxs(Paper,{className:classes$c.formContainer,shadow:"md",withBorder:!0,radius:"md",p:"xl",children:[!Object.keys(tokenList).includes(d.toString())&&jsxRuntimeExports.jsxs(Alert,{variant:"light",color:"yellow",radius:"lg",title:"Unsupported Network",children:["Safe link App supports only these networks as of now ",jsxRuntimeExports.jsxs("b",{children:[" : ",jsxRuntimeExports.jsx("br",{})," ",Object.keys(tokenList).map(Et=>{var ht,wt;return`${(ht=NetworkUtil.getNetworkById(Number(Et)))==null?void 0:ht.name} ${(wt=NetworkUtil.getNetworkById(Number(Et)))==null?void 0:wt.type}, `})," "]})]}),Gt&&jsxRuntimeExports.jsxs(Alert,{variant:"light",color:"yellow",radius:"lg",title:"Open as Safe App",children:["Try this application as a ",jsxRuntimeExports.jsx("span",{}),jsxRuntimeExports.jsx(Anchor,{href:"https://app.safe.global/share/safe-app?appUrl=https://safe-passkey.zenguard.xyz&chain=sep",children:"Safe App"})," ",jsxRuntimeExports.jsx("span",{}),"on Safe Wallet."]}),jsxRuntimeExports.jsx("div",{className:classes$c.inputContainer,children:jsxRuntimeExports.jsxs(Stepper,{size:"sm",active:yt,color:"green",children:[jsxRuntimeExports.jsxs(Stepper.Step,{label:"Create link",description:"Select crypto asset and amount",children:[jsxRuntimeExports.jsxs("div",{className:classes$c.inputContainer,children:[jsxRuntimeExports.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",marginBottom:"20px"},children:[jsxRuntimeExports.jsxs(Stack,{style:{width:"40%"},children:[jsxRuntimeExports.jsx(Input.Wrapper,{label:"Select Asset ",children:jsxRuntimeExports.jsxs(Combobox,{store:n0,withinPortal:!1,onOptionSubmit:Et=>{c0(Et),n0.closeDropdown()},children:[jsxRuntimeExports.jsx(Combobox.Target,{children:jsxRuntimeExports.jsx(InputBase,{component:"button",type:"button",pointer:!0,rightSection:jsxRuntimeExports.jsx(Combobox.Chevron,{}),onClick:()=>n0.toggleDropdown(),rightSectionPointerEvents:"none",multiline:!0,children:xt?jsxRuntimeExports.jsx(_t,{...xt}):jsxRuntimeExports.jsx(Input.Placeholder,{children:"Pick value"})})}),jsxRuntimeExports.jsx(Combobox.Dropdown,{children:jsxRuntimeExports.jsx(Combobox.Options,{children:St})})]})}),jsxRuntimeExports.jsx(Badge,{pl:0,color:"gray",variant:"light",leftSection:jsxRuntimeExports.jsx(Avatar,{alt:"Avatar for badge",size:20,mr:5,src:getIconForId(d)}),size:"sm",className:classes$c.network,children:Tt})]}),jsxRuntimeExports.jsx(Input.Wrapper,{label:"Amount ",style:{width:"40%"},children:jsxRuntimeExports.jsx(TextInput,{type:"number",size:"lg",value:nt,onChange:Et=>{var ht;return tt((ht=Et==null?void 0:Et.target)==null?void 0:ht.value)},placeholder:"Enter the amount",className:classes$c.input,description:`Balance: ${Ct}`,inputWrapperOrder:["label","input","description"]})})]}),jsxRuntimeExports.jsx(Button,{size:"lg",radius:"md",fullWidth:!0,color:"green",className:classes$c.btn,onClick:Pt,loaderProps:{color:"white",type:"dots",size:"md"},loading:Ot,children:Ot?"Creating Link ...":"Create Link"}),jsxRuntimeExports.jsx("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",marginBottom:"20px",alignSelf:"center"},children:jsxRuntimeExports.jsx(Input.Wrapper,{style:{color:"grey"},children:jsxRuntimeExports.jsx(DateTimePicker,{variant:"unstyled",size:"sm",description:"",valueFormat:"DD MMM YYYY, hh:mm A",value:new Date(At*1e3),label:"The link will be valid until (Click to change)",placeholder:"Pick date and time",onChange:Et=>Mt(Math.floor(Et.getTime()/1e3))})})})]}),jsxRuntimeExports.jsx("br",{})]}),jsxRuntimeExports.jsx(Stepper.Step,{label:"Share link",description:"Share this link to claim crypto",children:jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("h1",{className:classes$c.heading,style:{fontSize:30},children:"Safe link is Ready!"}),jsxRuntimeExports.jsxs("p",{className:classes$c.subheading,style:{textAlign:"center"},children:["This link account is like a magic wand. Check out the magic of this link ",jsxRuntimeExports.jsx(Anchor,{target:"_blank",href:Dt,children:"here "})," ❤️ ❤️"]}),jsxRuntimeExports.jsx("div",{className:classes$c.copyContainer,children:jsxRuntimeExports.jsx(Input,{className:classes$c.input,value:Dt,placeholder:Dt})}),jsxRuntimeExports.jsxs("div",{className:classes$c.actions,children:[jsxRuntimeExports.jsx(Button,{size:"lg",radius:"md",onClick:()=>gt(0),style:{width:"180px"},color:a?"#49494f":"#c3c3c3",variant:"filled",children:"Create New"}),jsxRuntimeExports.jsx(lib.CopyToClipboard,{text:Dt,onCopy:()=>a0(!0),children:jsxRuntimeExports.jsx(Button,{size:"lg",radius:"md",style:{width:"180px"},color:"teal",children:Xt?"Link Copied":"Copy Link"})})]})]})}),jsxRuntimeExports.jsx(Stepper.Completed,{children:"Completed, click back button to get to previous step"})]})})]})})}),jsxRuntimeExports.jsx("div",{className:classes$c.avatarContainer,children:jsxRuntimeExports.jsxs(Group,{className:classes$c.mode,children:[jsxRuntimeExports.jsx(IconBrandX,{size:30,stroke:1.5,onClick:()=>window.open("https://x.com/zenguardxyz"),style:{cursor:"pointer"}}),jsxRuntimeExports.jsx(Ag,{size:30,stroke:1.5,onClick:()=>window.open("https://github.com/koshikraj/safe-link"),style:{cursor:"pointer"}})]})})]})}const accountContainer="_accountContainer_1ox68_3",formContainer="_formContainer_1ox68_15",avatarContainer="_avatarContainer_1ox68_24",balance="_balance_1ox68_32",avatar="_avatar_1ox68_24",heading="_heading_1ox68_45",btn="_btn_1ox68_56",actionsContainer="_actionsContainer_1ox68_71",subHeading="_subHeading_1ox68_79",footerHeading="_footerHeading_1ox68_86",balanceContainer="_balanceContainer_1ox68_91",actions="_actions_1ox68_71",inputContainer="_inputContainer_1ox68_109",accountInputContainer="_accountInputContainer_1ox68_119",card="_card_1ox68_128",icon="_icon_1ox68_135",title="_title_1ox68_141",claimHeading="_claimHeading_1ox68_148",claimInner="_claimInner_1ox68_161",links="_links_1ox68_178",classes={accountContainer,formContainer,avatarContainer,balance,avatar,heading,btn,actionsContainer,subHeading,footerHeading,balanceContainer,actions,inputContainer,accountInputContainer,card,icon,title,claimHeading,claimInner,links};var reactConfetti_min={exports:{}};(function(c,a){(function(d,et){c.exports=et(reactExports)})(typeof self<"u"?self:commonjsGlobal,function(d){return function(et){var nt={};function tt(bt){if(nt[bt])return nt[bt].exports;var mt=nt[bt]={i:bt,l:!1,exports:{}};return et[bt].call(mt.exports,mt,mt.exports,tt),mt.l=!0,mt.exports}return tt.m=et,tt.c=nt,tt.d=function(bt,mt,vt){tt.o(bt,mt)||Object.defineProperty(bt,mt,{enumerable:!0,get:vt})},tt.r=function(bt){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(bt,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(bt,"__esModule",{value:!0})},tt.t=function(bt,mt){if(1&mt&&(bt=tt(bt)),8&mt||4&mt&&typeof bt=="object"&&bt&&bt.__esModule)return bt;var vt=Object.create(null);if(tt.r(vt),Object.defineProperty(vt,"default",{enumerable:!0,value:bt}),2&mt&&typeof bt!="string")for(var $t in bt)tt.d(vt,$t,(function(At){return bt[At]}).bind(null,$t));return vt},tt.n=function(bt){var mt=bt&&bt.__esModule?function(){return bt.default}:function(){return bt};return tt.d(mt,"a",mt),mt},tt.o=function(bt,mt){return Object.prototype.hasOwnProperty.call(bt,mt)},tt.p="",tt(tt.s=2)}([function(et,nt){et.exports=d},function(et,nt,tt){var bt={linear:function(mt,vt,$t,At){return($t-vt)*mt/At+vt},easeInQuad:function(mt,vt,$t,At){return($t-vt)*(mt/=At)*mt+vt},easeOutQuad:function(mt,vt,$t,At){return-($t-vt)*(mt/=At)*(mt-2)+vt},easeInOutQuad:function(mt,vt,$t,At){var Mt=$t-vt;return(mt/=At/2)<1?Mt/2*mt*mt+vt:-Mt/2*(--mt*(mt-2)-1)+vt},easeInCubic:function(mt,vt,$t,At){return($t-vt)*(mt/=At)*mt*mt+vt},easeOutCubic:function(mt,vt,$t,At){return($t-vt)*((mt=mt/At-1)*mt*mt+1)+vt},easeInOutCubic:function(mt,vt,$t,At){var Mt=$t-vt;return(mt/=At/2)<1?Mt/2*mt*mt*mt+vt:Mt/2*((mt-=2)*mt*mt+2)+vt},easeInQuart:function(mt,vt,$t,At){return($t-vt)*(mt/=At)*mt*mt*mt+vt},easeOutQuart:function(mt,vt,$t,At){return-($t-vt)*((mt=mt/At-1)*mt*mt*mt-1)+vt},easeInOutQuart:function(mt,vt,$t,At){var Mt=$t-vt;return(mt/=At/2)<1?Mt/2*mt*mt*mt*mt+vt:-Mt/2*((mt-=2)*mt*mt*mt-2)+vt},easeInQuint:function(mt,vt,$t,At){return($t-vt)*(mt/=At)*mt*mt*mt*mt+vt},easeOutQuint:function(mt,vt,$t,At){return($t-vt)*((mt=mt/At-1)*mt*mt*mt*mt+1)+vt},easeInOutQuint:function(mt,vt,$t,At){var Mt=$t-vt;return(mt/=At/2)<1?Mt/2*mt*mt*mt*mt*mt+vt:Mt/2*((mt-=2)*mt*mt*mt*mt+2)+vt},easeInSine:function(mt,vt,$t,At){var Mt=$t-vt;return-Mt*Math.cos(mt/At*(Math.PI/2))+Mt+vt},easeOutSine:function(mt,vt,$t,At){return($t-vt)*Math.sin(mt/At*(Math.PI/2))+vt},easeInOutSine:function(mt,vt,$t,At){return-($t-vt)/2*(Math.cos(Math.PI*mt/At)-1)+vt},easeInExpo:function(mt,vt,$t,At){return mt==0?vt:($t-vt)*Math.pow(2,10*(mt/At-1))+vt},easeOutExpo:function(mt,vt,$t,At){var Mt=$t-vt;return mt==At?vt+Mt:Mt*(1-Math.pow(2,-10*mt/At))+vt},easeInOutExpo:function(mt,vt,$t,At){var Mt=$t-vt;return mt===0?vt:mt===At?vt+Mt:(mt/=At/2)<1?Mt/2*Math.pow(2,10*(mt-1))+vt:Mt/2*(2-Math.pow(2,-10*--mt))+vt},easeInCirc:function(mt,vt,$t,At){return-($t-vt)*(Math.sqrt(1-(mt/=At)*mt)-1)+vt},easeOutCirc:function(mt,vt,$t,At){return($t-vt)*Math.sqrt(1-(mt=mt/At-1)*mt)+vt},easeInOutCirc:function(mt,vt,$t,At){var Mt=$t-vt;return(mt/=At/2)<1?-Mt/2*(Math.sqrt(1-mt*mt)-1)+vt:Mt/2*(Math.sqrt(1-(mt-=2)*mt)+1)+vt},easeInElastic:function(mt,vt,$t,At){var Mt,Tt,Rt,kt=$t-vt;return Rt=1.70158,mt===0?vt:(mt/=At)==1?vt+kt:((Tt=0)||(Tt=.3*At),(Mt=kt)=1&&this.rotationDirection===mt.Positive?this.rotationDirection=mt.Negative:this.rotateY<=-1&&this.rotationDirection===mt.Negative&&(this.rotationDirection=mt.Positive);var $0=.1*this.rotationDirection;if(this.rotateY+=$0,this.angle+=this.angularSpin,this.context.save(),this.context.translate(this.x,this.y),this.context.rotate(this.angle),this.context.scale(1,this.rotateY),this.context.rotate(this.angle),this.context.beginPath(),this.context.fillStyle=this.color,this.context.strokeStyle=this.color,this.context.globalAlpha=o0,this.context.lineCap="round",this.context.lineWidth=2,l0&&typeof l0=="function")l0.call(this,this.context);else switch(this.shape){case bt.Circle:this.context.beginPath(),this.context.arc(0,0,this.radius,0,2*Math.PI),this.context.fill();break;case bt.Square:this.context.fillRect(-this.w/2,-this.h/2,this.w,this.h);break;case bt.Strip:this.context.fillRect(-this.w/6,-this.h/2,this.w/3,this.h)}this.context.closePath(),this.context.restore()}}])&&Rt(Kt.prototype,e0),qt}();function Dt(qt,Kt,e0){return Kt in qt?Object.defineProperty(qt,Kt,{value:e0,enumerable:!0,configurable:!0,writable:!0}):qt[Kt]=e0,qt}var Nt=function qt(Kt,e0){var Zt=this;(function(i0,h0){if(!(i0 instanceof h0))throw new TypeError("Cannot call a class as a function")})(this,qt),Dt(this,"canvas",void 0),Dt(this,"context",void 0),Dt(this,"getOptions",void 0),Dt(this,"x",0),Dt(this,"y",0),Dt(this,"w",0),Dt(this,"h",0),Dt(this,"lastNumberOfPieces",0),Dt(this,"tweenInitTime",Date.now()),Dt(this,"particles",[]),Dt(this,"particlesGenerated",0),Dt(this,"removeParticleAt",function(i0){Zt.particles.splice(i0,1)}),Dt(this,"getParticle",function(){var i0=Tt(Zt.x,Zt.w+Zt.x),h0=Tt(Zt.y,Zt.h+Zt.y);return new It(Zt.context,Zt.getOptions,i0,h0)}),Dt(this,"animate",function(){var i0=Zt.canvas,h0=Zt.context,o0=Zt.particlesGenerated,l0=Zt.lastNumberOfPieces,$0=Zt.getOptions(),p0=$0.run,u0=$0.recycle,J0=$0.numberOfPieces,v0=$0.debug,E0=$0.tweenFunction,Z0=$0.tweenDuration;if(!p0)return!1;var w0=Zt.particles.length,b0=u0?w0:o0,K0=Date.now();if(b0Z0?Z0:Math.max(0,K0-Qt),b0,J0,Z0),Yt=Math.round(Ht-b0),r0=0;r0i0.height||f0.y<-100||f0.x>i0.width+100||f0.x<-100)&&(u0&&b0<=J0?Zt.particles[x0]=Zt.getParticle():Zt.removeParticleAt(x0))}),w0>0||b00&&$0.call(i0,i0),i0._options.run=!1)}),Wt(this,"reset",function(){i0.generator&&i0.generator.particlesGenerated>0&&(i0.generator.particlesGenerated=0,i0.generator.particles=[],i0.generator.lastNumberOfPieces=0)}),Wt(this,"stop",function(){i0.options={run:!1},i0.rafId&&(cancelAnimationFrame(i0.rafId),i0.rafId=void 0)}),this.canvas=Zt;var h0=this.canvas.getContext("2d");if(!h0)throw new Error("Could not get canvas context");this.context=h0,this.generator=new Nt(this.canvas,function(){return i0.options}),this.options=Jt,this.update()}var Kt,e0;return Kt=qt,(e0=[{key:"options",get:function(){return this._options},set:function(Zt){var Jt=this._options&&this._options.run,i0=this._options&&this._options.recycle;this.setOptionsWithDefaults(Zt),this.generator&&(Object.assign(this.generator,this.options.confettiSource),typeof Zt.recycle=="boolean"&&Zt.recycle&&i0===!1&&(this.generator.lastNumberOfPieces=this.generator.particles.length)),typeof Zt.run=="boolean"&&Zt.run&&Jt===!1&&this.update()}}])&&Gt(Kt.prototype,e0),qt}();function n0(qt){return function(Kt){if(Array.isArray(Kt))return xt(Kt)}(qt)||function(Kt){if(typeof Symbol<"u"&&Symbol.iterator in Object(Kt))return Array.from(Kt)}(qt)||gt(qt)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function t0(qt){return(t0=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Kt){return typeof Kt}:function(Kt){return Kt&&typeof Symbol=="function"&&Kt.constructor===Symbol&&Kt!==Symbol.prototype?"symbol":typeof Kt})(qt)}function c0(){return(c0=Object.assign||function(qt){for(var Kt=1;Kt"u"||!(Symbol.iterator in Object(e0)))){var Jt=[],i0=!0,h0=!1,o0=void 0;try{for(var l0,$0=e0[Symbol.iterator]();!(i0=(l0=$0.next()).done)&&(Jt.push(l0.value),!Zt||Jt.length!==Zt);i0=!0);}catch(p0){h0=!0,o0=p0}finally{try{i0||$0.return==null||$0.return()}finally{if(h0)throw o0}}return Jt}}(qt,Kt)||gt(qt,Kt)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function gt(qt,Kt){if(qt){if(typeof qt=="string")return xt(qt,Kt);var e0=Object.prototype.toString.call(qt).slice(8,-1);return e0==="Object"&&qt.constructor&&(e0=qt.constructor.name),e0==="Map"||e0==="Set"?Array.from(qt):e0==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e0)?xt(qt,Kt):void 0}}function xt(qt,Kt){(Kt==null||Kt>qt.length)&&(Kt=qt.length);for(var e0=0,Zt=new Array(Kt);e0"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}();return function(){var e0,Zt=Bt(qt);if(Kt){var Jt=Bt(this).constructor;e0=Reflect.construct(Zt,arguments,Jt)}else e0=Zt.apply(this,arguments);return ht(this,e0)}}function ht(qt,Kt){return!Kt||t0(Kt)!=="object"&&typeof Kt!="function"?wt(qt):Kt}function wt(qt){if(qt===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return qt}function Bt(qt){return(Bt=Object.setPrototypeOf?Object.getPrototypeOf:function(Kt){return Kt.__proto__||Object.getPrototypeOf(Kt)})(qt)}function Lt(qt,Kt,e0){return Kt in qt?Object.defineProperty(qt,Kt,{value:e0,enumerable:!0,configurable:!0,writable:!0}):qt[Kt]=e0,qt}var jt=$t.a.createRef(),Ft=function(qt){(function(i0,h0){if(typeof h0!="function"&&h0!==null)throw new TypeError("Super expression must either be null or a function");i0.prototype=Object.create(h0&&h0.prototype,{constructor:{value:i0,writable:!0,configurable:!0}}),h0&&Pt(i0,h0)})(Jt,qt);var Kt,e0,Zt=Et(Jt);function Jt(i0){var h0;St(this,Jt);for(var o0=arguments.length,l0=new Array(o0>1?o0-1:0),$0=1;$0{var u0,J0,v0,E0,Z0,w0;const{authDetails:c,setAuthDetails:a,chainId:d,setChainId:et,setConfirming:nt,confirming:tt}=useLinkStore(b0=>b0);useSearchParams(),useDisclosure(!1);const[bt,mt]=reactExports.useState(!1),[vt,$t]=reactExports.useState(""),[At,Mt]=reactExports.useState(""),[Tt,Rt]=reactExports.useState(!1),[kt,It]=reactExports.useState(!1),[Dt,Nt]=reactExports.useState(!1),[Ot,Ut]=reactExports.useState({width:window.innerWidth,height:window.innerHeight}),[Gt,Wt]=reactExports.useState("0x0000000000000000000000000000000000000000"),[Xt,a0]=reactExports.useState(),[n0,t0]=reactExports.useState(!0),[c0,Ct]=reactExports.useState(!1),[dt,yt]=reactExports.useState(""),[gt,xt]=reactExports.useState(""),[St,_t]=reactExports.useState(0),[Pt,Et]=reactExports.useState(0),[ht,wt]=reactExports.useState(!0),[Bt,Lt]=reactExports.useState(""),[jt,Ft]=reactExports.useState({key:"",chainId:""}),Vt=Object.keys(tokenList).filter(b0=>{var K0;return((K0=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:K0.type)=="testnet"}).map(b0=>{var K0,Qt;return{label:`${(K0=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:K0.name}`,type:`${(Qt=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:Qt.type}`,image:getIconForId(b0),value:b0}}),qt=Object.keys(tokenList).filter(b0=>{var K0;return((K0=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:K0.type)=="mainnet"}).map(b0=>{var K0,Qt;return{label:`${(K0=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:K0.name}`,type:`${(Qt=NetworkUtil.getNetworkById(Number(b0)))==null?void 0:Qt.type}`,image:getIconForId(b0),value:b0}}).map(b0=>jsxRuntimeExports.jsx(Combobox.Option,{value:b0.value,children:jsxRuntimeExports.jsx(Jt,{...b0})},b0.value)),Kt=Vt.map(b0=>jsxRuntimeExports.jsx(Combobox.Option,{value:b0.value,children:jsxRuntimeExports.jsx(Jt,{...b0})},b0.value));Combobox.Options,Combobox.Group,Combobox.Group;const e0=useCombobox({onDropdownClose:()=>e0.resetSelectedOption()}),Zt=useCombobox({onDropdownClose:()=>Zt.resetSelectedOption()});function Jt({image:b0,label:K0}){return jsxRuntimeExports.jsxs(Group,{style:{width:"100%"},children:[jsxRuntimeExports.jsx(Avatar,{src:b0,children:jsxRuntimeExports.jsx(KD,{size:"1.5rem"})}),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx(Text,{fz:"sm",fw:500,children:K0})})]})}const i0=getTokenInfo(d,Gt),h0=getTokenList(d).map(b0=>jsxRuntimeExports.jsx(Combobox.Option,{value:b0.value,children:jsxRuntimeExports.jsx(o0,{...b0})},b0.value));function o0({image:b0,label:K0}){return jsxRuntimeExports.jsxs(Group,{style:{width:"100%"},children:[jsxRuntimeExports.jsx(Avatar,{src:b0,children:jsxRuntimeExports.jsx(KD,{size:"1.5rem"})}),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx(Text,{fz:"sm",fw:500,children:K0})})]})}function l0(b0){const K0=b0.split("?")[1];if(!K0)return null;const Qt=new URLSearchParams(K0),Ht={};for(const[Yt,r0]of Qt.entries())Ht[Yt]=r0;return Ht}async function $0(){Nt(!0),Rt(!1),Lt("");try{let b0,K0="0x",Qt=At;if(Gt==ZeroAddress)b0=parseEther(vt.toString());else{const Yt=await getJsonRpcProvider(d.toString());b0=parseUnits$1(vt.toString(),await getTokenDecimals(Gt,Yt)),console.log(b0),K0=await buildTransferToken(Gt,Qt,b0,Yt),b0=0n,Qt=Gt}const Ht=await sendTransaction(d.toString(),Qt,b0,K0,Xt,gt);Ht?(mt(!1),nt(!0),await waitForExecution(d,Ht),Rt(!0),nt(!1)):Rt(!1)}catch(b0){console.log("Something went wrong!",b0),Nt(!1),Lt("Oops! Gremlins have invaded your transaction. Please try again later.")}Nt(!1)}async function p0(b0,K0){const Qt=await getJsonRpcProvider(K0.toString());t0(!0);const{validAfter:Ht,validUntil:Yt,limitAmount:r0,limitUsed:f0,account:x0,token:d0}=await getSessionData(K0,b0),y0=Date.now(),Q0=r0-f0;Et(parseInt(Ht)),_t(parseInt(Yt)),Ct(y0parseInt(Ht)*1e3),yt(formatUnits$1(Q0,d0==ZeroAddress?"ether":await getTokenDecimals(d0,Qt))),t0(!1),xt(x0),Wt(d0)}return reactExports.useEffect(()=>{(async()=>{const b0=l0(window.location.href);Ft(b0),et(b0.chainId);const{privateKey:K0,address:Qt}=generateKeysFromString(b0.key);await p0(Qt,b0.chainId),a0(new Wallet(K0)),wt(!1),window.addEventListener("resize",()=>Ut({width:window.innerWidth,height:window.innerHeight}))})()},[tt]),jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Modal,{opened:bt,onClose:()=>{mt(!1),Rt(!1)},title:"Transfer your crypto",centered:!0,children:jsxRuntimeExports.jsxs("div",{className:classes.formContainer,children:[jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx("h1",{className:classes.heading,children:"Claim your crypto "})}),jsxRuntimeExports.jsx("p",{className:classes.subHeading,children:"Send your crypto gas free."}),jsxRuntimeExports.jsxs("div",{className:classes.inputContainer,children:[jsxRuntimeExports.jsxs("div",{style:{display:"flex",justifyContent:"space-between",marginTop:"20px",alignItems:"center"},children:[jsxRuntimeExports.jsxs(Combobox,{store:Zt,withinPortal:!1,onOptionSubmit:b0=>{Wt(b0),Zt.closeDropdown()},children:[jsxRuntimeExports.jsx(Combobox.Target,{children:jsxRuntimeExports.jsx(InputBase,{style:{width:"50%"},component:"button",rightSection:jsxRuntimeExports.jsx(Combobox.Chevron,{}),rightSectionPointerEvents:"none",multiline:!0,children:i0?jsxRuntimeExports.jsx(o0,{...i0}):jsxRuntimeExports.jsx(Input.Placeholder,{children:"Pick Token"})})}),jsxRuntimeExports.jsx(Combobox.Dropdown,{children:jsxRuntimeExports.jsx(Combobox.Options,{children:h0})})]}),jsxRuntimeExports.jsx(Input,{style:{width:"40%"},type:"number",size:"lg",value:vt,onChange:b0=>{var K0;return $t((K0=b0==null?void 0:b0.target)==null?void 0:K0.value)},placeholder:"Value",className:classes.input})]}),jsxRuntimeExports.jsx(Text,{size:"sm",style:{cursor:"pointer"},onClick:()=>{$t(dt)},children:kt?jsxRuntimeExports.jsx(Skeleton,{height:15,width:90,mt:6,radius:"xl"}):`Balance: ${dt} ${(u0=getTokenInfo(d,Gt))==null?void 0:u0.label}`}),jsxRuntimeExports.jsx(Input,{type:"string",style:{marginTop:"20px"},size:"lg",value:At,onChange:b0=>{var K0;return Mt((K0=b0==null?void 0:b0.target)==null?void 0:K0.value)},placeholder:"Recipient Address",className:classes.input})]}),jsxRuntimeExports.jsx(Button,{size:"lg",radius:"md",style:{marginBottom:"20px"},fullWidth:!0,color:"green",className:classes.btn,onClick:async()=>await $0(),loaderProps:{color:"white",type:"dots",size:"md"},loading:Dt,children:"Claim Now"}),Tt&&jsxRuntimeExports.jsx(Alert,{variant:"light",color:"lime",radius:"md",title:"Transfer Successful",icon:jsxRuntimeExports.jsx(qF,{}),children:"Your crypto assets have safely landed in the Success Galaxy. Buckle up for a stellar financial journey! 🚀💰"}),Bt&&jsxRuntimeExports.jsx(Alert,{variant:"light",color:"red",radius:"md",title:"Transfer Error",icon:jsxRuntimeExports.jsx(qC,{}),children:Bt})]})}),jsxRuntimeExports.jsx(Paper,{className:classes.accountContainer,shadow:"md",withBorder:!0,radius:"md",p:"xl",children:jsxRuntimeExports.jsx("div",{className:classes.formContainer,children:n0?jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Skeleton,{style:{marginBottom:"10px"},height:20,width:200,mt:6,radius:"xl"}),jsxRuntimeExports.jsx(Skeleton,{style:{marginBottom:"20px"},height:20,width:200,mt:6,radius:"xl"}),jsxRuntimeExports.jsx(Skeleton,{style:{marginBottom:"20px"},height:40,width:150,mt:6,radius:"md"})]}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[Tt&&jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsxs("h1",{className:classes.claimHeading,children:["You have claimed",jsxRuntimeExports.jsxs("h1",{className:classes.claimInner,children:[vt+" ",(J0=getTokenInfo(d,Gt))==null?void 0:J0.label," ",jsxRuntimeExports.jsx(Avatar,{src:(v0=getTokenInfo(d,Gt))==null?void 0:v0.image})]})]}),jsxRuntimeExports.jsx("h1",{className:classes.links,children:" 🎉 😍"}),!!parseFloat(dt)&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsxs("h1",{className:classes.claimHeading,children:["You have ",dt||0," "+((E0=getTokenInfo(d,Gt))==null?void 0:E0.label)]}),jsxRuntimeExports.jsx("h1",{className:classes.links,children:" more to claim"})]})]}),!Tt&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[" ",parseFloat(dt)&&c0?jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsxs("h1",{className:classes.claimHeading,children:["You have",jsxRuntimeExports.jsxs("h1",{className:classes.claimInner,children:[dt||0," ",(Z0=getTokenInfo(d,Gt))==null?void 0:Z0.label," ",jsxRuntimeExports.jsx(Avatar,{src:(w0=getTokenInfo(d,Gt))==null?void 0:w0.image})]})]}),jsxRuntimeExports.jsx("h1",{className:classes.links,children:" to claim 🎉 😍"})]}):jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("h1",{className:classes.claimHeading,children:"Looks like there is nothing to claim"}),jsxRuntimeExports.jsx("h1",{className:classes.links,children:" 👀 😢"})]})]}),!!parseFloat(dt)&&c0&&jsxRuntimeExports.jsx(Button,{size:"lg",radius:"md",style:{width:"50%",marginTop:"20px"},fullWidth:!0,color:"teal",type:"button",className:classes.btn,onClick:async()=>{mt(!0),$t(dt)},children:"Claim Now"})]})})}),Tt&&jsxRuntimeExports.jsx(Confetti,{width:Ot.width,height:Ot.height})]})},Navigation=()=>jsxRuntimeExports.jsxs(Routes,{children:[jsxRuntimeExports.jsx(Route,{path:RoutePath.home,element:jsxRuntimeExports.jsx(HomePage,{})}),jsxRuntimeExports.jsx(Route,{path:RoutePath.claim,element:jsxRuntimeExports.jsx(ClaimPage,{})})]}),theme={fontFamily:"Inter, sans-serif"};function App(){return jsxRuntimeExports.jsx(MantineProvider,{theme,defaultColorScheme:"dark",children:jsxRuntimeExports.jsx(HashRouter,{children:jsxRuntimeExports.jsx(AppLayout,{children:jsxRuntimeExports.jsx(Navigation,{})})})})}client.createRoot(document.getElementById("root")).render(jsxRuntimeExports.jsx(App,{}));export{BaseError as B,HttpRequestError as H,InvalidAddressError as I,concat as a,isHex as b,call as c,decodeErrorResult as d,encodeAbiParameters as e,getUrl as g,isAddress as i,stringify as s}; diff --git a/assets/logo-dark-9ba4d21d.svg b/assets/logo-dark-a42ec370.svg similarity index 79% rename from assets/logo-dark-9ba4d21d.svg rename to assets/logo-dark-a42ec370.svg index 297a7747..4715a57a 100644 --- a/assets/logo-dark-9ba4d21d.svg +++ b/assets/logo-dark-a42ec370.svg @@ -1,54 +1,54 @@ - - + + - + - + - + - + - + - - + + - + - - + + - + - - + + diff --git a/assets/logo-light-a2d4109f.svg b/assets/logo-light-4eedbe0d.svg similarity index 67% rename from assets/logo-light-a2d4109f.svg rename to assets/logo-light-4eedbe0d.svg index e69a7676..0c437f66 100644 --- a/assets/logo-light-a2d4109f.svg +++ b/assets/logo-light-4eedbe0d.svg @@ -1,54 +1,54 @@ - - - - - - + + + + + + - - + + - + - - - + + + - + - + - + - - + + - + - - + + - + - - + + diff --git a/assets/nodecrypto-7fa9a5ea.js b/assets/nodecrypto-7fa9a5ea.js deleted file mode 100644 index 507cbc69..00000000 --- a/assets/nodecrypto-7fa9a5ea.js +++ /dev/null @@ -1 +0,0 @@ -import{a as r,c as n,d as y}from"./index-96283bad.js";const p=async t=>{const{content:s,publicKey:i,privateKey:o}=t,c=r.createPrivateKey({key:n({uncompressedPrivateKeyHex:o,compressedPublicKeyHex:i}),format:"jwk"}),e=r.createSign("SHA256");return e.write(y.Buffer.from(s)),e.end(),e.sign(c,"hex")};export{p as signWithApiKey}; diff --git a/assets/usde-f0eba4d9.svg b/assets/usde-f0eba4d9.svg new file mode 100644 index 00000000..ed2b8ab3 --- /dev/null +++ b/assets/usde-f0eba4d9.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/assets/usdt-cddba428.svg b/assets/usdt-cddba428.svg deleted file mode 100644 index 38c491c9..00000000 --- a/assets/usdt-cddba428.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/assets/webcrypto-31cddabe.js b/assets/webcrypto-31cddabe.js deleted file mode 100644 index 5a0e9d08..00000000 --- a/assets/webcrypto-31cddabe.js +++ /dev/null @@ -1 +0,0 @@ -import{c,u as i}from"./index-96283bad.js";const y=async n=>{const{content:e,publicKey:s,privateKey:t}=n,o=await g({uncompressedPrivateKeyHex:t,compressedPublicKeyHex:s});return await l({key:o,content:e})};async function g(n){const{uncompressedPrivateKeyHex:e,compressedPublicKeyHex:s}=n,t=c({uncompressedPrivateKeyHex:e,compressedPublicKeyHex:s});return await crypto.subtle.importKey("jwk",t,{name:"ECDSA",namedCurve:"P-256"},!1,["sign"])}async function l(n){const{key:e,content:s}=n,t=await crypto.subtle.sign({name:"ECDSA",hash:"SHA-256"},e,new TextEncoder().encode(s)),o=u(new Uint8Array(t));return i(o)}function u(n){if(n.length%2!=0||n.length==0||n.length>132)throw new Error("Invalid IEEE P1363 signature encoding. Length: "+n.length);const e=a(n.subarray(0,n.length/2)),s=a(n.subarray(n.length/2,n.length));let t=0;const o=1+1+e.length+1+1+s.length;let r;return o>=128?(r=new Uint8Array(o+3),r[t++]=48,r[t++]=128+1,r[t++]=o):(r=new Uint8Array(o+2),r[t++]=48,r[t++]=o),r[t++]=2,r[t++]=e.length,r.set(e,t),t+=e.length,r[t++]=2,r[t++]=s.length,r.set(s,t),r}function a(n){let e=0;for(;e - - + + - Share crypto from Safe via links + Share crypto from your Safe via links - - + +
diff --git a/manifest.json b/manifest.json index 1f2e04eb..7316bbc2 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { - "short_name": "Safe2Link App", - "name": "Safe2Link App", - "description": "Share crypto directly from your Safe with links", + "short_name": "SafeLink App", + "name": "SafeLink App", + "description": "Share crypto from your Safe via links", "iconPath": "logo192.png", "icons": [ {