PageSourceSearch

https://give-away3.vercel.app/_next/static/chunks/pages/_app-cc0e176e9db38a23.js

js give-away3.vercel.app collected 2026-10-03 07:00:57 UTC 1,123,021 bytes, 1,114 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2888],{77777:function(e,t,n){"use strict";t.N=void 0;var o=n(7352);Object.defineProperty(t,"N",{enumerable:!0,get:function(){return o.SafeAppProvider}})},7352:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SafeAppProvider=void 0;let o=n(17187),i=n(93080);let SafeAppProvider=class SafeAppProvider extends o.EventEmitter{constructor(e,t){super(),this.submittedTxs=new Map,this.safe=e,this.sdk=t}async connect(){this.emit("connect",{chainId:this.chainId})}async disconnect(){}get chainId(){return this.safe.chainId}async request(e){let{method:t,params:n=[]}=e;switch(t){case"eth_accounts":return[this.safe.safeAddress];case"net_version":case"eth_chainId":return`0x${this.chainId.toString(16)}`;case"personal_sign":{let[e,t]=n;if(this.safe.safeAddress.toLowerCase()!==t.toLowerCase())throw Error("The address or message hash is invalid");let o=await this.sdk.txs.signMessage(e),i="signature"in o?o.signature:void 0;return i||"0x"}case"eth_sign":{let[e,t]=n;if(this.safe.safeAddress.toLowerCase()!==e.toLowerCase()||!t.startsWith("0x"))throw Error("The address or message hash is invalid");let o=await this.sdk.txs.signMessage(t),i="signature"in o?o.signature:void 0;return i||"0x"}case"eth_signTypedData":case"eth_signTypedData_v4":{let[e,t]=n,o="string"==typeof t?JSON.parse(t):t;if(this.safe.safeAddress.toLowerCase()!==e.toLowerCase())throw Error("The address is invalid");let i=await this.sdk.txs.signTypedMessage(o),s="signature"in i?i.signature:void 0;return s||"0x"}case"eth_sendTransaction":let o={...n[0],value:n[0].value||"0",data:n[0].data||"0x"};"string"==typeof o.gas&&o.gas.startsWith("0x")&&(o.gas=parseInt(o.gas,16));let s=await this.sdk.txs.send({txs:[o],params:{safeTxGas:o.gas}});return this.submittedTxs.set(s.safeTxHash,{from:this.safe.safeAddress,hash:s.safeTxHash,gas:0,gasPrice:"0x00",nonce:0,input:o.data,value:o.value,to:o.to,blockHash:null,blockNumber:null,transactionIndex:null}),s.safeTxHash;case"eth_blockNumber":let c=await this.sdk.eth.getBlockByNumber(["latest"]);return c.number;case"eth_getBalance":return this.sdk.eth.getBalance([(0,i.getLowerCase)(n[0]),n[1]]);case"eth_getCode":return this.sdk.eth.getCode([(0,i.getLowerCase)(n[0]),n[1]]);case"eth_getTransactionCount":return this.sdk.eth.getTransactionCount([(0,i.getLowerCase)(n[0]),n[1]]);case"eth_getStorageAt":return this.sdk.eth.getStorageAt([(0,i.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 l=n[0];try{let e=await this.sdk.txs.getBySafeTxHash(l);l=e.txHash||l}catch(e){}if(this.submittedTxs.has(l))return this.submittedTxs.get(l);return this.sdk.eth.getTransactionByHash([l]).then(e=>(e&&(e.hash=n[0]),e));case"eth_getTransactionReceipt":{let e=n[0];try{let t=await this.sdk.txs.getBySafeTxHash(e);e=t.txHash||e}catch(e){}return this.sdk.eth.getTransactionReceipt([e]).then(e=>(e&&(e.transactionHash=n[0]),e))}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,t){e||t("Undefined request"),this.request(e).then(n=>t(null,{jsonrpc:"2.0",id:e.id,result:n}
1)).catch(e=>t(e,null))}};t.SafeAppProvider=SafeAppProvider},93080:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getLowerCase=void 0,t.getLowerCase=function(e){return e?e.toLowerCase():e}},95068:function(e,t,n){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,n,o){void 0===o&&(o=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,o,i)}:function(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||o(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0});let s=n(65938);t.default=class{constructor(e=null,t=!1){this.allowedOrigins=null,this.callbacks=new Map,this.debugMode=!1,this.isServer="undefined"==typeof window,this.isValidMessage=({origin:e,data:t,source:n})=>{let o=!this.isServer&&n===window.parent,i=void 0!==t.version&&parseInt(t.version.split(".")[0]),s=!0;return Array.isArray(this.allowedOrigins)&&(s=void 0!==this.allowedOrigins.find(t=>t.test(e))),!!t&&o&&i>=1&&s},this.logIncomingMessage=e=>{console.info(`Safe Apps SDK v1: A message was received from origin ${e.origin}. `,e.data)},this.onParentMessage=e=>{this.isValidMessage(e)&&(this.debugMode&&this.logIncomingMessage(e),this.handleIncomingMessage(e.data))},this.handleIncomingMessage=e=>{let{id:t}=e,n=this.callbacks.get(t);n&&(n(e),this.callbacks.delete(t))},this.send=(e,t)=>{let n=s.MessageFormatter.makeRequest(e,t);if(this.isServer)throw Error("Window doesn't exist");return window.parent.postMessage(n,"*"),new Promise((e,t)=>{this.callbacks.set(n.id,n=>{if(!n.success){t(Error(n.error));return}e(n)})})},this.allowedOrigins=e,this.debugMode=t,this.isServer||window.addEventListener("message",this.onParentMessage)}},i(n(27473),t)},65938:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessageFormatter=void 0;let o=n(55445),i=n(9331);let MessageFormatter=class MessageFormatter{};t.MessageFormatter=MessageFormatter,MessageFormatter.makeRequest=(e,t)=>{let n=(0,i.generateRequestId)();return{id:n,method:e,params:t,env:{sdkVersion:(0,o.getSDKVersion)()}}},MessageFormatter.makeResponse=(e,t,n)=>({id:e,success:!0,version:n,data:t}),MessageFormatter.makeErrorResponse=(e,t,n)=>({id:e,success:!1,error:t,version:n})},27473:function(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.RestrictedMethods=t.Methods=void 0,(n=t.Methods||(t.Methods={})).sendTransactions="sendTransactions",n.rpcCall="rpcCall",n.getChainInfo="getChainInfo",n.getSafeInfo="getSafeInfo",n.getTxBySafeTxHash="getTxBySafeTxHash",n.getSafeBalances="getSafeBalances",n.signMessage="signMessage",n.signTypedMessage="signTypedMessage",n.getEnvironmentInfo="getEnvironmentInfo",n.getOffChainSignature="getOffChainSignature",n.requestAddressBook="requestAddressBook",n.wallet_getPermissions="wallet_getPermissions",n.wallet_requestPermissions="wallet_requestPermissions",(t.RestrictedMethods||(t.RestrictedMethods={})).requestAddressBook="requestAddressBook"},9331:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateRequestId=void 0;let dec2hex=e=>e.toString(16).padStart(2,"0"),generateId=e=>{let t=new Uint8Array((e||40)/2);return window.crypto.getRandomValues(t),Array.from(t,dec2hex).join("")};t.generateRequestId=()=>"undefined"!=typeof window?generateId(10):new Date().getTime().toString(36)},23417:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let o=n(11285),i=n(51741),hasPermission=(e,t)=>t.some(t=>t.parentCapability===e);t.default=()=>(e,t,n)=>{let s=n.value;return n.value=async function(){let e=new o.Wallet(this.communicator),n=await e.getPermissions();if(hasPermission(t,n)||(n=await e.requestPermissions([{[t]:{}}])),!hasPermission(t,n))throw new i.PermissionsError("Permissions rejected",i.PERMISSIONS_REQUEST_REJECTED);return s.apply(this)},n}},46794:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RPC_CALLS=void 0,t.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"}},99750:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0}),t.Eth=void 0;let o=n(46794),i=n(27473),s={defaultBlockParam:(e="latest")=>e,returnFullTxObjectParam:(e=!1)=>e,blockNumberToHex:e=>Number.isInteger(e)?`0x${e.toString(16)}`:e};t.Eth=class{constructor(e){this.communicator=e,this.call=this.buildRequest({call:o.RPC_CALLS.eth_call,formatters:[null,s.defaultBlockParam]}),this.getBalance=this.buildRequest({call:o.RPC_CALLS.eth_getBalance,formatters:[null,s.defaultBlockParam]}),this.getCode=this.buildRequest({call:o.RPC_CALLS.eth_getCode,formatters:[null,s.defaultBlockParam]}),this.getStorageAt=this.buildRequest({call:o.RPC_CALLS.eth_getStorageAt,formatters:[null,s.blockNumberToHex,s.defaultBlockParam]}),this.getPastLogs=this.buildRequest({call:o.RPC_CALLS.eth_getLogs}),this.getBlockByHash=this.buildRequest({call:o.RPC_CALLS.eth_getBlockByHash,formatters:[null,s.returnFullTxObjectParam]}),this.getBlockByNumber=this.buildRequest({call:o.RPC_CALLS.eth_getBlockByNumber,formatters:[s.blockNumberToHex,s.returnFullTxObjectParam]}),this.getTransactionByHash=this.buildRequest({call:o.RPC_CALLS.eth_getTransactionByHash}),this.getTransactionReceipt=this.buildRequest({call:o.RPC_CALLS.eth_getTransactionReceipt}),this.getTransactionCount=this.buildRequest({call:o.RPC_CALLS.eth_getTransactionCount,formatters:[null,s.defaultBlockParam]}),this.getGasPrice=this.buildRequest({call:o.RPC_CALLS.eth_gasPrice}),this.getEstimateGas=e=>this.buildRequest({call:o.RPC_CALLS.eth_estimateGas})([e]),this.setSafeSettings=this.buildRequest({call:o.RPC_CALLS.safe_setSettings})}buildRequest(e){let{call:t,formatters:n}=e;return async e=>{n&&Array.isArray(e)&&n.forEach((t,n)=>{t&&(e[n]=t(e[n]))});let o=await this.communicator.send(i.Methods.rpcCall,{call:t,params:e||[]});return o.data}}}},40936:function(e,t,n){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,n,o){void 0===o&&(o=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,o,i)}:function(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||o(t,e,n)},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getSDKVersion=void 0;let c=s(n(66638));t.default=c.default,i(n(66638),t),i(n(8550),t),i(n(27473),t),i(n(65938),t);var l=n(55445);Object.defineProperty(t,"getSDKVersion",{enumerable:!0,get:function(){return l.getSDKVersion}})},89385:function(e,t,n){"use strict";var o=this&&this.__decorate||function(e,t,n,o){var i,s=arguments.length,c=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)c=Reflect.decorate(e,t,n,o);else for(var l=e.length-1;l>=0;l--)(i=e[l])&&(c=(s<3?i(c):s>3?i(t,n,c):i(t,n))||c);return s>3&&c&&Object.defineProperty(t,n,c),c},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Safe=void 0;let s=n(56431),c=n(61181),l=n(27473),u=n(46794),d=n(8550),p=i(n(23417));let Safe=class Safe{constructor(e){this.communicator=e}async getChainInfo(){let e=await this.communicator.send(l.Methods.getChainInfo,void 0);return e.data}async getInfo(){let e=await this.communicator.send(l.Methods.getSafeInfo,void 0);return e.data}async experimental_getBalances({currency:e="usd"}={}){let t=await this.communicator.send(l.Methods.getSafeBalances,{currency:e});return t.data}async check1271Signature(e,t="0x"){let n=await this.getInfo(),o=(0,s.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,t]}),i={call:u.RPC_CALLS.eth_call,params:[{to:n.safeAddress,data:o},"latest"]};try{let e=await this.communicator.send(l.Methods.rpcCall,i);return e.data.slice(0,10).toLowerCase()===c.MAGIC_VALUE}catch(e){return!1}}async check1271SignatureBytes(e,t="0x"){let n=await this.getInfo(),o=(0,s.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,t]}),i={call:u.RPC_CALLS.eth_call,params:[{to:n.safeAddress,data:o},"latest"]};try{let e=await this.communicator.send(l.Methods.rpcCall,i);return e.data.slice(0,10).toLowerCase()===c.MAGIC_VALUE_BYTES}catch(e){return!1}}calculateMessageHash(e){return(0,s.hashMessage)(e)}calculateTypedMessageHash(e){let t="object"==typeof e.domain.chainId?e.domain.chainId.toNumber():Number(e.domain.chainId),n=e.primaryType;if(!n){let t=Object.values(e.types),o=Object.keys(e.types).filter(e=>t.every(t=>t.every(({type:t})=>t.replace("[","").replace("]","")!==e)));if(0===o.length||o.length>1)throw Error("Please specify primaryType");
1n=o[0]}return(0,s.hashTypedData)({message:e.message,domain:Object.assign(Object.assign({},e.domain),{chainId:t,verifyingContract:e.domain.verifyingContract,salt:e.domain.salt}),types:e.types,primaryType:n})}async getOffChainSignature(e){let t=await this.communicator.send(l.Methods.getOffChainSignature,e);return t.data}async isMessageSigned(e,t="0x"){let n;if("string"==typeof e&&(n=async()=>{let n=this.calculateMessageHash(e),o=await this.isMessageHashSigned(n,t);return o}),(0,d.isObjectEIP712TypedData)(e)&&(n=async()=>{let n=this.calculateTypedMessageHash(e),o=await this.isMessageHashSigned(n,t);return o}),n){let e=await n();return e}throw Error("Invalid message type")}async isMessageHashSigned(e,t="0x"){let n=[this.check1271Signature.bind(this),this.check1271SignatureBytes.bind(this)];for(let o of n){let n=await o(e,t);if(n)return!0}return!1}async getEnvironmentInfo(){let e=await this.communicator.send(l.Methods.getEnvironmentInfo,void 0);return e.data}async requestAddressBook(){let e=await this.communicator.send(l.Methods.requestAddressBook,void 0);return e.data}};o([(0,p.default)()],Safe.prototype,"requestAddressBook",null),t.Safe=Safe},61181:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MAGIC_VALUE_BYTES=t.MAGIC_VALUE=void 0,t.MAGIC_VALUE="0x1626ba7e",t.MAGIC_VALUE_BYTES="0x20c13b0b"},66638:function(e,t,n){"use strict";var o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});let i=o(n(95068)),s=n(44070),c=n(99750),l=n(89385),u=n(11285);t.default=class{constructor(e={}){let{allowedDomains:t=null,debug:n=!1}=e;this.communicator=new i.default(t,n),this.eth=new c.Eth(this.communicator),this.txs=new s.TXs(this.communicator),this.safe=new l.Safe(this.communicator),this.wallet=new u.Wallet(this.communicator)}}},44070:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TXs=void 0;let o=n(27473),i=n(8550);t.TXs=class{constructor(e){this.communicator=e}async getBySafeTxHash(e){if(!e)throw Error("Invalid safeTxHash");let t=await this.communicator.send(o.Methods.getTxBySafeTxHash,{safeTxHash:e});return t.data}async signMessage(e){let t=await this.communicator.send(o.Methods.signMessage,{message:e});return t.data}async signTypedMessage(e){if(!(0,i.isObjectEIP712TypedData)(e))throw Error("Invalid typed data");let t=await this.communicator.send(o.Methods.signTypedMessage,{typedData:e});return t.data}async send({txs:e,params:t}){if(!e||!e.length)throw Error("No transactions were passed");let n=await this.communicator.send(o.Methods.sendTransactions,{txs:e,params:t});return n.data}}},25946:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TransferDirection=t.TransactionStatus=t.TokenType=t.Operation=void 0;var o=n(18831);Object.defineProperty(t,"Operation",{enumerable:!0,get:function(){return o.Operation}}),Object.defineProperty(t,"TokenType",{enumerable:!0,get:function(){return o.TokenType}}),Object.defineProperty(t,"TransactionStatus",{enumerable:!0,get:function(){return o.TransactionStatus}}),Object.defineProperty(t,"TransferDirection",{enumerable:!0,get:function(){return o.TransferDirection}})},8550:function(e,t,n){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,n,o){void 0===o&&(o=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,o,i)}:function(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||o(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),i(n(71734),t),i(n(13788),t),i(n(25946),t),i(n(13754),t)},13754:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n(27473)},51741:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PermissionsError=t.PERMISSIONS_REQUEST_REJECTED=void 0,t.PERMISSIONS_REQUEST_REJECTED=4001;
1let PermissionsError=class PermissionsError extends Error{constructor(e,t,n){super(e),this.code=t,this.data=n,Object.setPrototypeOf(this,PermissionsError.prototype)}};t.PermissionsError=PermissionsError},13788:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},71734:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isObjectEIP712TypedData=void 0,t.isObjectEIP712TypedData=e=>"object"==typeof e&&null!=e&&"domain"in e&&"types"in e&&"message"in e},55445:function(e,t,n){"use strict";var o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getSDKVersion=void 0;let i=o(n(29242));t.getSDKVersion=()=>i.default.version.split("-")[0]},11285:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wallet=void 0;let o=n(27473),i=n(51741);t.Wallet=class{constructor(e){this.communicator=e}async getPermissions(){let e=await this.communicator.send(o.Methods.wallet_getPermissions,void 0);return e.data}async requestPermissions(e){if(!this.isPermissionRequestValid(e))throw new i.PermissionsError("Permissions request is invalid",i.PERMISSIONS_REQUEST_REJECTED);try{let t=await this.communicator.send(o.Methods.wallet_requestPermissions,e);return t.data}catch(e){throw new i.PermissionsError("Permissions rejected",i.PERMISSIONS_REQUEST_REJECTED)}}isPermissionRequestValid(e){return e.every(e=>"object"==typeof e&&Object.keys(e).every(e=>!!Object.values(o.RestrictedMethods).includes(e)))}}},65421:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCurve=t.getHash=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let o=n(2738),i=n(824),s=n(51983);function getHash(e){return{hash:e,hmac:(t,...n)=>(0,o.hmac)(e,t,(0,i.concatBytes)(...n)),randomBytes:i.randomBytes}}t.getHash=getHash,t.createCurve=function(e,t){let create=t=>(0,s.weierstrass)({...e,...getHash(t)});return Object.freeze({...create(t),create})}},46014:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateBasic=t.wNAF=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let o=n(37610),i=n(34131),s=BigInt(0),c=BigInt(1);t.wNAF=function(e,t){let constTimeNegate=(e,t)=>
1{let n=t.negate();return e?n:t},opts=e=>({windows:Math.ceil(t/e)+1,windowSize:2**(e-1)});return{constTimeNegate,unsafeLadder(t,n){let o=e.ZERO,i=t;for(;n>s;)n&c&&(o=o.add(i)),i=i.double(),n>>=c;return o},precomputeWindow(e,t){let{windows:n,windowSize:o}=opts(t),i=[],s=e,c=s;for(let e=0;e<n;e++){c=s,i.push(c);for(let e=1;e<o;e++)c=c.add(s),i.push(c);s=c.double()}return i},wNAF(t,n,o){let{windows:i,windowSize:s}=opts(t),l=e.ZERO,u=e.BASE,d=BigInt(2**t-1),p=2**t,m=BigInt(t);for(let e=0;e<i;e++){let t=e*s,i=Number(o&d);o>>=m,i>s&&(i-=p,o+=c);let b=t+Math.abs(i)-1,g=e%2!=0,y=i<0;0===i?u=u.add(constTimeNegate(g,n[t])):l=l.add(constTimeNegate(y,n[b]))}return{p:l,f:u}},wNAFCached(e,t,n,o){let i=e._WINDOW_SIZE||1,s=t.get(e);return s||(s=this.precomputeWindow(e,i),1!==i&&t.set(e,o(s))),this.wNAF(i,s,n)}}},t.validateBasic=function(e){return(0,o.validateField)(e.Fp),(0,i.validateObject)(e,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...(0,o.nLength)(e.n,e.nBitLength),...e,p:e.Fp.ORDER})}},57486:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createHasher=t.isogenyMap=t.hash_to_field=t.expand_message_xof=t.expand_message_xmd=void 0;let o=n(37610),i=n(34131),s=i.bytesToNumberBE;function i2osp(e,t){if(e<0||e>=1<<8*t)throw Error(`bad I2OSP call: value=${e} length=${t}`);let n=Array.from({length:t}).fill(0);for(let o=t-1;o>=0;o--)n[o]=255&e,e>>>=8;return new Uint8Array(n)}function isBytes(e){if(!(e instanceof Uint8Array))throw Error("Uint8Array expected")}function isNum(e){if(!Number.isSafeInteger(e))throw Error("number expected")}function expand_message_xmd(e,t,n,o){isBytes(e),isBytes(t),isNum(n),t.length>255&&(t=o((0,i.concatBytes)((0,i.utf8ToBytes)("H2C-OVERSIZE-DST-"),t)));let{outputLen:s,blockLen:c}=o,l=Math.ceil(n/s);if(l>255)throw Error("Invalid xmd length");let u=(0,i.concatBytes)(t,i2osp(t.length,1)),d=i2osp(0,c),p=i2osp(n,2),m=Array(l),b=o((0,i.concatBytes)(d,e,p,i2osp(0,1),u));m[0]=o((0,i.concatBytes)(b,i2osp(1,1),u));for(let e=1;e<=l;e++){let t=[function(e,t){let n=new Uint8Array(e.length);for(let o=0;o<e.length;o++)n[o]=e[o]^t[o];return n}(b,m[e-1]),i2osp(e+1,1),u];m[e]=o((0,i.concatBytes)(...t))}let g=(0,i.concatBytes)(...m);return g.slice(0,n)}function expand_message_xof(e,t,n,o,s){if(isBytes(e),isBytes(t),isNum(n),t.length>255&&(t=s.create({dkLen:Math.ceil(2*o/8)}).update((0,i.utf8ToBytes)("H2C-OVERSIZE-DST-")).update(t).digest()),n>65535||t.length>255)throw Error("expand_message_xof: invalid lenInBytes");return s.create({dkLen:n}).update(e).update(i2osp(n,2)).update(t).update(i2osp(t.length,1)).digest()}function hash_to_field(e,t,n){let c;(0,i.validateObject)(n,{DST:"stringOrUint8Array",p:"bigint",m:"isSafeInteger",k:"isSafeInteger",hash:"hash"});let{p:l,k:u,m:d,hash:p,expand:m,DST:b}=n;isBytes(e),isNum(t);let g=function(e){if(e instanceof Uint8Array)return e;if("string"==typeof e)return(0,i.utf8ToBytes)(e);throw Error("DST must be Uint8Array or string")}(b),y=l.toString(2).length,v=Math.ceil((y+u)/8),E=t*d*v;if("xmd"===m)c=expand_message_xmd(e,g,E,p);else if("xof"===m)c=expand_message_xof(e,g,E,u,p);else if("_internal_pass"===m)c=e;else throw Error('expand must be "xmd" or "xof"');let x=Array(t);for(let e=0;e<t;e++){let t=Array(d);for(let n=0;n<d;n++){let i=v*(n+e*d),u=c.subarray(i,i+v);t[n]=(0,o.mod)(s(u),l)}x[e]=t}return x}t.expand_message_xmd=expand_message_xmd,t.expand_message_xof=expand_message_xof,t.hash_to_field=hash_to_field,t.isogenyMap=function(e,t){let n=t.map(e=>Array.from(e).reverse());return(t,o)=>{let[i,s,c,l]=n.map(n=>n.reduce((n,o)=>e.add(e.mul(n,t),o)));return{x:t=e.div(i,s),y:o=e.mul(o,e.div(c,l))}}},t.createHasher=function(e,t,n){if("function"!=typeof t)throw Error("mapToCurve() must be defined");return{hashToCurve(o,i){let s=hash_to_field(o,2,{...n,DST:n.DST,...i}),c=e.fromAffine(t(s[0])),l=e.fromAffine(t(s[1])),u=c.add(l).clearCofactor();return u.assertValidity(),u},encodeToCurve(o,i){let s=hash_to_field(o,1,{...n,DST:n.encodeDST,...i}),c=e.fromAffine(t(s[0])).clearCofactor();return c.assertValidity(),c}}}},37610:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0}),t.mapHashToField=t.getMinHashLength=t.getFieldBytesLength=t.hashToPrivateScalar=t.FpSqrtEven=t.FpSqrtOdd=t.Field=t.nLength=t.FpIsSquare=t.FpDiv=t.FpInvertBatch=t.FpPow=t.validateField=t.isNegativeLE=t.FpSqrt=t.tonelliShanks=t.invert=t.pow2=t.pow=t.mod=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let o=n(34131),i=BigInt(0),s=BigInt(1),c=BigInt(2),l=BigInt(3),u=BigInt(4),d=BigInt(5),p=BigInt(8);function mod(e,t){let n=e%t;return n>=i?n:t+n}function pow(e,t,n){if(n<=i||t<i)throw Error("Expected power/modulo > 0");if(n===s)return i;let o=s;for(;t>i;)t&s&&(o=o*e%n),e=e*e%n,t>>=s;return o}function invert(e,t){if(e===i||t<=i)throw Error(`invert: expected positive integers, got n=${e} mod=${t}`);let n=mod(e,t),o=t,c=i,l=s,u=s,d=i;for(;n!==i;){let e=o/n,t=o%n,i=c-u*e,s=l-d*e;o=n,n=t,c=u,l=d,u=i,d=s}let p=o;if(p!==s)throw Error("invert: does not exist");return mod(c,t)}function tonelliShanks(e){let t,n,o;let l=(e-s)/c;for(t=e-s,n=0;t%c===i;t/=c,n++);for(o=c;o<e&&pow(o,l,e)!==e-s;o++);if(1===n){let t=(e+s)/u;return function(e,n){let o=e.pow(n,t);if(!e.eql(e.sqr(o),n))throw Error("Cannot find square root");return o}}let d=(t+s)/c;return function(e,i){if(e.pow(i,l)===e.neg(e.ONE))throw Error("Cannot find square root");let c=n,u=e.pow(e.mul(e.ONE,o),t),p=e.pow(i,d),m=e.pow(i,t);for(;!e.eql(m,e.ONE);){if(e.eql(m,e.ZERO))return e.ZERO;let t=1;for(let n=e.sqr(m);t<c&&!e.eql(n,e.ONE);t++)n=e.sqr(n);let n=e.pow(u,s<<BigInt(c-t-1));u=e.sqr(n),p=e.mul(p,n),m=e.mul(m,u),c=t}return p}}function FpSqrt(e){if(e%u===l){let t=(e+s)/u;return function(e,n){let o=e.pow(n,t);if(!e.eql(e.sqr(o),n))throw Error("Cannot find square root");return o}}if(e%p===d){let t=(e-d)/p;return function(e,n){let o=e.mul(n,c),i=e.pow(o,t),s=e.mul(n,i),l=e.mul(e.mul(s,c),i),u=e.mul(s,e.sub(l,e.ONE));if(!e.eql(e.sqr(u),n))throw Error("Cannot find square root");return u}}return tonelliShanks(e)}BigInt(9),BigInt(16),t.mod=mod,t.pow=pow,t.pow2=function(e,t,n){let o=e;for(;t-- >i;)o*=o,o%=n;return o},t.invert=invert,t.tonelliShanks=tonelliShanks,t.FpSqrt=FpSqrt,t.isNegativeLE=(e,t)=>(mod(e,t)&s)===s;let m=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function FpPow(e,t,n){if(n<i)throw Error("Expected power > 0");if(n===i)return e.ONE;if(n===s)return t;let o=e.ONE,c=t;
1for(;n>i;)n&s&&(o=e.mul(o,c)),c=e.sqr(c),n>>=s;return o}function FpInvertBatch(e,t){let n=Array(t.length),o=t.reduce((t,o,i)=>e.is0(o)?t:(n[i]=t,e.mul(t,o)),e.ONE),i=e.inv(o);return t.reduceRight((t,o,i)=>e.is0(o)?t:(n[i]=e.mul(t,n[i]),e.mul(t,o)),i),n}function nLength(e,t){let n=void 0!==t?t:e.toString(2).length;return{nBitLength:n,nByteLength:Math.ceil(n/8)}}function getFieldBytesLength(e){if("bigint"!=typeof e)throw Error("field order must be bigint");let t=e.toString(2).length;return Math.ceil(t/8)}function getMinHashLength(e){let t=getFieldBytesLength(e);return t+Math.ceil(t/2)}t.validateField=function(e){let t=m.reduce((e,t)=>(e[t]="function",e),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"});return(0,o.validateObject)(e,t)},t.FpPow=FpPow,t.FpInvertBatch=FpInvertBatch,t.FpDiv=function(e,t,n){return e.mul(t,"bigint"==typeof n?invert(n,e.ORDER):e.inv(n))},t.FpIsSquare=function(e){let t=(e.ORDER-s)/c;return n=>{let o=e.pow(n,t);return e.eql(o,e.ZERO)||e.eql(o,e.ONE)}},t.nLength=nLength,t.Field=function(e,t,n=!1,c={}){if(e<=i)throw Error(`Expected Field ORDER > 0, got ${e}`);let{nBitLength:l,nByteLength:u}=nLength(e,t);if(u>2048)throw Error("Field lengths over 2048 bytes are not supported");let d=FpSqrt(e),p=Object.freeze({ORDER:e,BITS:l,BYTES:u,MASK:(0,o.bitMask)(l),ZERO:i,ONE:s,create:t=>mod(t,e),isValid:t=>{if("bigint"!=typeof t)throw Error(`Invalid field element: expected bigint, got ${typeof t}`);return i<=t&&t<e},is0:e=>e===i,isOdd:e=>(e&s)===s,neg:t=>mod(-t,e),eql:(e,t)=>e===t,sqr:t=>mod(t*t,e),add:(t,n)=>mod(t+n,e),sub:(t,n)=>mod(t-n,e),mul:(t,n)=>mod(t*n,e),pow:(e,t)=>FpPow(p,e,t),div:(t,n)=>mod(t*invert(n,e),e),sqrN:e=>e*e,addN:(e,t)=>e+t,subN:(e,t)=>e-t,mulN:(e,t)=>e*t,inv:t=>invert(t,e),sqrt:c.sqrt||(e=>d(p,e)),invertBatch:e=>FpInvertBatch(p,e),cmov:(e,t,n)=>n?t:e,toBytes:e=>n?(0,o.numberToBytesLE)(e,u):(0,o.numberToBytesBE)(e,u),fromBytes:e=>{if(e.length!==u)throw Error(`Fp.fromBytes: expected ${u}, got ${e.length}`);return n?(0,o.bytesToNumberLE)(e):(0,o.bytesToNumberBE)(e)}});return Object.freeze(p)},t.FpSqrtOdd=function(e,t){if(!e.isOdd)throw Error("Field doesn't have isOdd");let n=e.sqrt(t);return e.isOdd(n)?n:e.neg(n)},t.FpSqrtEven=function(e,t){if(!e.isOdd)throw Error("Field doesn't have isOdd");let n=e.sqrt(t);return e.isOdd(n)?e.neg(n):n},t.hashToPrivateScalar=function(e,t,n=!1){e=(0,o.ensureBytes)("privateHash",e);let i=e.length,c=nLength(t).nByteLength+8;if(c<24||i<c||i>1024)throw Error(`hashToPrivateScalar: expected ${c}-1024 bytes of input, got ${i}`);let l=n?(0,o.bytesToNumberLE)(e):(0,o.bytesToNumberBE)(e);return mod(l,t-s)+s},t.getFieldBytesLength=getFieldBytesLength,t.getMinHashLength=getMinHashLength,t.mapHashToField=function(e,t,n=!1){let i=e.length,c=getFieldBytesLength(t),l=getMinHashLength(t);if(i<16||i<l||i>1024)throw Error(`expected ${l}-1024 bytes of input, got ${i}`);let u=n?(0,o.bytesToNumberBE)(e):(0,o.bytesToNumberLE)(e),d=mod(u,t-s)+s;return n?(0,o.numberToBytesLE)(d,c):(0,o.numberToBytesBE)(d,c)}},34131:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateObject=t.createHmacDrbg=t.bitMask=t.bitSet=t.bitGet=t.bitLen=t.utf8ToBytes=t.equalBytes=t.concatBytes=t.ensureBytes=t.numberToVarBytesBE=t.numberToBytesLE=t.numberToBytesBE=t.bytesToNumberLE=t.bytesToNumberBE=t.hexToBytes=t.hexToNumber=t.numberToHexUnpadded=t.bytesToHex=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let n=BigInt(0),o=BigInt(1),i=BigInt(2),u8a=e=>e instanceof Uint8Array,s=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function bytesToHex(e){if(!u8a(e))throw Error("Uint8Array expected");let t="";for(let n=0;n<e.length;n++)t+=s[e[n]];return t}function numberToHexUnpadded(e){let t=e.toString(16);return 1&t.length?`0${t}`:t}function hexToNumber(e){if("string"!=typeof e)throw Error("hex string expected, got "+typeof e);return BigInt(""===e?"0":`0x${e}`)}function hexToBytes(e){if("string"!=typeof e)throw Error("hex string expected, got "+typeof e);let t=e.length;if(t%2)throw Error("padded hex string expected, got unpadded hex of length "+t);let n=new Uint8Array(t/2);for(let t=0;t<n.length;t++){let o=2*t,i=e.slice(o,o+2),s=Number.parseInt(i,16);if(Number.isNaN(s)||s<0)throw Error("Invalid byte sequence");n[t]=s}return n}function numberToBytesBE(e,t){return hexToBytes(e.toString(16).padStart(2*t,"0"))}function concatBytes(...e){let t=new Uint8Array(e.reduce((e,t)=>
1e+t.length,0)),n=0;return e.forEach(e=>{if(!u8a(e))throw Error("Uint8Array expected");t.set(e,n),n+=e.length}),t}t.bytesToHex=bytesToHex,t.numberToHexUnpadded=numberToHexUnpadded,t.hexToNumber=hexToNumber,t.hexToBytes=hexToBytes,t.bytesToNumberBE=function(e){return hexToNumber(bytesToHex(e))},t.bytesToNumberLE=function(e){if(!u8a(e))throw Error("Uint8Array expected");return hexToNumber(bytesToHex(Uint8Array.from(e).reverse()))},t.numberToBytesBE=numberToBytesBE,t.numberToBytesLE=function(e,t){return numberToBytesBE(e,t).reverse()},t.numberToVarBytesBE=function(e){return hexToBytes(numberToHexUnpadded(e))},t.ensureBytes=function(e,t,n){let o;if("string"==typeof t)try{o=hexToBytes(t)}catch(n){throw Error(`${e} must be valid hex string, got "${t}". Cause: ${n}`)}else if(u8a(t))o=Uint8Array.from(t);else throw Error(`${e} must be hex string or Uint8Array`);let i=o.length;if("number"==typeof n&&i!==n)throw Error(`${e} expected ${n} bytes, got ${i}`);return o},t.concatBytes=concatBytes,t.equalBytes=function(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0},t.utf8ToBytes=function(e){if("string"!=typeof e)throw Error(`utf8ToBytes expected string, got ${typeof e}`);return new Uint8Array(new TextEncoder().encode(e))},t.bitLen=function(e){let t;for(t=0;e>n;e>>=o,t+=1);return t},t.bitGet=function(e,t){return e>>BigInt(t)&o},t.bitSet=(e,t,i)=>e|(i?o:n)<<BigInt(t),t.bitMask=e=>(i<<BigInt(e-1))-o;let u8n=e=>new Uint8Array(e),u8fr=e=>Uint8Array.from(e);t.createHmacDrbg=function(e,t,n){if("number"!=typeof e||e<2)throw Error("hashLen must be a number");if("number"!=typeof t||t<2)throw Error("qByteLen must be a number");if("function"!=typeof n)throw Error("hmacFn must be a function");let o=u8n(e),i=u8n(e),s=0,reset=()=>{o.fill(1),i.fill(0),s=0},h=(...e)=>n(i,o,...e),reseed=(e=u8n())=>{i=h(u8fr([0]),e),o=h(),0!==e.length&&(i=h(u8fr([1]),e),o=h())},gen=()=>{if(s++>=1e3)throw Error("drbg: tried 1000 values");let e=0,n=[];for(;e<t;){o=h();let t=o.slice();n.push(t),e+=o.length}return concatBytes(...n)};return(e,t)=>{let n;for(reset(),reseed(e);!(n=t(gen()));)reseed();return reset(),n}};let c={bigint:e=>"bigint"==typeof e,function:e=>"function"==typeof e,boolean:e=>"boolean"==typeof e,string:e=>"string"==typeof e,stringOrUint8Array:e=>"string"==typeof e||e instanceof Uint8Array,isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>"function"==typeof e&&Number.isSafeInteger(e.outputLen)};t.validateObject=function(e,t,n={}){let checkField=(t,n,o)=>{let i=c[n];if("function"!=typeof i)throw Error(`Invalid validator "${n}", expected function`);let s=e[t];if((!o||void 0!==s)&&!i(s,e))throw Error(`Invalid param ${String(t)}=${s} (${typeof s}), expected ${n}`)};for(let[e,n]of Object.entries(t))checkField(e,n,!1);for(let[e,t]of Object.entries(n))checkField(e,t,!0);return e}},51983:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mapToCurveSimpleSWU=t.SWUFpSqrtRatio=t.weierstrass=t.weierstrassPoints=t.DER=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let o=n(37610),i=n(34131),s=n(34131),c=n(46014),{bytesToNumberBE:l,hexToBytes:u}=i;t.DER={Err:class extends Error{constructor(e=""){super(e)}},_parseInt(e){let{Err:n}=t.DER;if(e.length<2||2!==e[0])throw new n("Invalid signature integer tag");let o=e[1],i=e.subarray(2,o+2);if(!o||i.length!==o)throw new n("Invalid signature integer: wrong length");if(128&i[0])throw new n("Invalid signature integer: negative");if(0===i[0]&&!(128&i[1]))throw new n("Invalid signature integer: unnecessary leading zero");return{d:l(i),l:e.subarray(o+2)}},toSig(e){let{Err:n}=t.DER,o="string"==typeof e?u(e):e;if(!(o instanceof Uint8Array))throw Error("ui8a expected");let i=o.length;if(i<2||48!=o[0])throw new n("Invalid signature tag");if(o[1]!==i-2)throw new n("Invalid signature: incorrect length");let{d:s,l:c}=t.DER._parseInt(o.subarray(2)),{d:l,l:d}=t.DER._parseInt(c);if(d.length)throw new n("Invalid signature: left bytes after parsing");return{r:s,s:l}},hexFromSig(e){let slice=e=>8&Number.parseInt(e[0],16)?"00"+e:e,h=e=>{let t=e.toString(16);return 1&t.length?`0${t}`:t},t=slice(h(e.s)),n=slice(h(e.r)),o=t.length/2,i=n.length/2,s=h(o),c=h(i);return`30${h(i+o+4)}02${c}${n}02${s}${t}`}};
1let d=BigInt(0),p=BigInt(1),m=BigInt(2),b=BigInt(3),g=BigInt(4);function weierstrassPoints(e){let t=function(e){let t=(0,c.validateBasic)(e);i.validateObject(t,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});let{endo:n,Fp:o,a:s}=t;if(n){if(!o.eql(s,o.ZERO))throw Error("Endomorphism can only be defined for Koblitz curves that have a=0");if("object"!=typeof n||"bigint"!=typeof n.beta||"function"!=typeof n.splitScalar)throw Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...t})}(e),{Fp:n}=t,l=t.toBytes||((e,t,o)=>{let s=t.toAffine();return i.concatBytes(Uint8Array.from([4]),n.toBytes(s.x),n.toBytes(s.y))}),u=t.fromBytes||(e=>{let t=e.subarray(1),o=n.fromBytes(t.subarray(0,n.BYTES)),i=n.fromBytes(t.subarray(n.BYTES,2*n.BYTES));return{x:o,y:i}});function weierstrassEquation(e){let{a:o,b:i}=t,s=n.sqr(e),c=n.mul(s,e);return n.add(n.add(c,n.mul(e,o)),i)}if(!n.eql(n.sqr(t.Gy),weierstrassEquation(t.Gx)))throw Error("bad generator point: equation left != right");function isWithinCurveOrder(e){return"bigint"==typeof e&&d<e&&e<t.n}function assertGE(e){if(!isWithinCurveOrder(e))throw Error("Expected valid bigint: 0 < bigint < curve.n")}function normPrivateKeyToScalar(e){let n;let{allowedPrivateKeyLengths:c,nByteLength:l,wrapPrivateKey:u,n:d}=t;if(c&&"bigint"!=typeof e){if(e instanceof Uint8Array&&(e=i.bytesToHex(e)),"string"!=typeof e||!c.includes(e.length))throw Error("Invalid key");e=e.padStart(2*l,"0")}try{n="bigint"==typeof e?e:i.bytesToNumberBE((0,s.ensureBytes)("private key",e,l))}catch(t){throw Error(`private key must be ${l} bytes, hex or bigint, not ${typeof e}`)}return u&&(n=o.mod(n,d)),assertGE(n),n}let m=new Map;function assertPrjPoint(e){if(!(e instanceof Point))throw Error("ProjectivePoint expected")}let Point=class Point{constructor(e,t,o){if(this.px=e,this.py=t,this.pz=o,null==e||!n.isValid(e))throw Error("x required");if(null==t||!n.isValid(t))throw Error("y required");if(null==o||!n.isValid(o))throw Error("z required")}static fromAffine(e){let{x:t,y:o}=e||{};if(!e||!n.isValid(t)||!n.isValid(o))throw Error("invalid affine point");if(e instanceof Point)throw Error("projective point not allowed");let is0=e=>n.eql(e,n.ZERO);return is0(t)&&is0(o)?Point.ZERO:new Point(t,o,n.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(e){let t=n.invertBatch(e.map(e=>e.pz));return e.map((e,n)=>e.toAffine(t[n])).map(Point.fromAffine)}static fromHex(e){let t=Point.fromAffine(u((0,s.ensureBytes)("pointHex",e)));return t.assertValidity(),t}static fromPrivateKey(e){return Point.BASE.multiply(normPrivateKeyToScalar(e))}_setWindowSize(e){this._WINDOW_SIZE=e,m.delete(this)}assertValidity(){if(this.is0()){if(t.allowInfinityPoint&&!n.is0(this.py))return;throw Error("bad point: ZERO")}let{x:e,y:o}=this.toAffine();if(!n.isValid(e)||!n.isValid(o))throw Error("bad point: x or y not FE");let i=n.sqr(o),s=weierstrassEquation(e);if(!n.eql(i,s))throw Error("bad point: equation left != right");if(!this.isTorsionFree())throw Error("bad point: not in prime-order subgroup")}hasEvenY(){let{y:e}=this.toAffine();if(n.isOdd)return!n.isOdd(e);throw Error("Field doesn't support isOdd")}equals(e){assertPrjPoint(e);let{px:t,py:o,pz:i}=this,{px:s,py:c,pz:l}=e,u=n.eql(n.mul(t,l),n.mul(s,i)),d=n.eql(n.mul(o,l),n.mul(c,i));return u&&d}negate(){return new Point(this.px,n.neg(this.py),this.pz)}double(){let{a:e,b:o}=t,i=n.mul(o,b),{px:s,py:c,pz:l}=this,u=n.ZERO,d=n.ZERO,p=n.ZERO,m=n.mul(s,s),g=n.mul(c,c),y=n.mul(l,l),v=n.mul(s,c);return v=n.add(v,v),p=n.mul(s,l),p=n.add(p,p),u=n.mul(e,p),d=n.mul(i,y),d=n.add(u,d),u=n.sub(g,d),d=n.add(g,d),d=n.mul(u,d),u=n.mul(v,u),p=n.mul(i,p),y=n.mul(e,y),v=n.sub(m,y),v=n.mul(e,v),v=n.add(v,p),p=n.add(m,m),m=n.add(p,m),m=n.add(m,y),m=n.mul(m,v),d=n.add(d,m),y=n.mul(c,l),y=n.add(y,y),m=n.mul(y,v),u=n.sub(u,m),p=n.mul(y,g),p=n.add(p,p),p=n.add(p,p),new Point(u,d,p)}add(e){assertPrjPoint(e);let{px:o,py:i,pz:s}=this,{px:c,py:l,pz:u}=e,d=n.ZERO,p=n.ZERO,m=n.ZERO,g=t.a,y=n.mul(t.b,b),v=n.mul(o,c),E=n.mul(i,l),x=n.mul(s,u),P=n.add(o,i),_=n.add(c,l);P=n.mul(P,_),_=n.add(v,E),P=n.sub(P,_),_=n.add(o,s);let I=n.add(c,u);return _=n.mul(_,I),I=n.add(v,x),_=n.sub(_,I),I=n.add(i,s),d=n.add(l,u),I=n.mul(I,d),d=n.add(E,x),I=n.sub(I,d),m=n.mul(g,_),d=n.mul(y,x),m=n.add(d,m),d=n.sub(E,m),m=n.add(E,m),p=n.mul(d,m),E=n.add(v,v),E=n.add(E,v),x=n.mul(g,x),_=n.mul(y,_),E=n.add(E,x),x=n.sub(v,x),x=n.mul(g,x),_=n.add(_,x),v=n.mul(E,_),p=n.add(p,v),v=n.mul(I,_),d=n.mul(P,d),d=n.sub(d,v),v=n.mul(P,E),m=n.mul(I,m),m=n.add(m,v),new Point(d,p,m)}subtract(e){return this.add(e.negate())}is0(){return this.equals(Point.ZERO)}wNAF(e){return y.wNAFCached(this,m,e,e=>{let t=n.invertBatch(e.map(e=>e.pz));return e.map((e,n)=>e.toAffine(t[n])).map(Point.fromAffine)})}multiplyUnsafe(e){let o=Point.ZERO;if(e===d)return o;if(assertGE(e),e===p)return this;let{endo:i}=t;if(!i)return y.unsafeLadder(this,e);
1let{k1neg:s,k1:c,k2neg:l,k2:u}=i.splitScalar(e),m=o,b=o,g=this;for(;c>d||u>d;)c&p&&(m=m.add(g)),u&p&&(b=b.add(g)),g=g.double(),c>>=p,u>>=p;return s&&(m=m.negate()),l&&(b=b.negate()),b=new Point(n.mul(b.px,i.beta),b.py,b.pz),m.add(b)}multiply(e){let o,i;assertGE(e);let{endo:s}=t;if(s){let{k1neg:t,k1:c,k2neg:l,k2:u}=s.splitScalar(e),{p:d,f:p}=this.wNAF(c),{p:m,f:b}=this.wNAF(u);d=y.constTimeNegate(t,d),m=y.constTimeNegate(l,m),m=new Point(n.mul(m.px,s.beta),m.py,m.pz),o=d.add(m),i=p.add(b)}else{let{p:t,f:n}=this.wNAF(e);o=t,i=n}return Point.normalizeZ([o,i])[0]}multiplyAndAddUnsafe(e,t,n){let o=Point.BASE,mul=(e,t)=>t!==d&&t!==p&&e.equals(o)?e.multiply(t):e.multiplyUnsafe(t),i=mul(this,t).add(mul(e,n));return i.is0()?void 0:i}toAffine(e){let{px:t,py:o,pz:i}=this,s=this.is0();null==e&&(e=s?n.ONE:n.inv(i));let c=n.mul(t,e),l=n.mul(o,e),u=n.mul(i,e);if(s)return{x:n.ZERO,y:n.ZERO};if(!n.eql(u,n.ONE))throw Error("invZ was invalid");return{x:c,y:l}}isTorsionFree(){let{h:e,isTorsionFree:n}=t;if(e===p)return!0;if(n)return n(Point,this);throw Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){let{h:e,clearCofactor:n}=t;return e===p?this:n?n(Point,this):this.multiplyUnsafe(t.h)}toRawBytes(e=!0){return this.assertValidity(),l(Point,this,e)}toHex(e=!0){return i.bytesToHex(this.toRawBytes(e))}};Point.BASE=new Point(t.Gx,t.Gy,n.ONE),Point.ZERO=new Point(n.ZERO,n.ONE,n.ZERO);let g=t.nBitLength,y=(0,c.wNAF)(Point,t.endo?Math.ceil(g/2):g);return{CURVE:t,ProjectivePoint:Point,normPrivateKeyToScalar,weierstrassEquation,isWithinCurveOrder}}function SWUFpSqrtRatio(e,t){let n=e.ORDER,o=d;for(let e=n-p;e%m===d;e/=m)o+=p;let i=o,s=m<<i-p-p,c=s*m,l=(n-p)/c,u=(l-p)/m,y=c-p,v=e.pow(t,l),E=e.pow(t,(l+p)/m),sqrtRatio=(t,n)=>{let o=v,c=e.pow(n,y),l=e.sqr(c);l=e.mul(l,n);let d=e.mul(t,l);d=e.pow(d,u),d=e.mul(d,c),c=e.mul(d,n),l=e.mul(d,t);let b=e.mul(l,c);d=e.pow(b,s);let g=e.eql(d,e.ONE);c=e.mul(l,E),d=e.mul(b,o),l=e.cmov(c,l,g),b=e.cmov(d,b,g);for(let t=i;t>p;t--){let n=t-m;n=m<<n-p;let i=e.pow(b,n),s=e.eql(i,e.ONE);c=e.mul(l,o),o=e.mul(o,o),i=e.mul(b,o),l=e.cmov(c,l,s),b=e.cmov(i,b,s)}return{isValid:g,value:l}};if(e.ORDER%g===b){let n=(e.ORDER-b)/g,o=e.sqrt(e.neg(t));sqrtRatio=(t,i)=>{let s=e.sqr(i),c=e.mul(t,i);s=e.mul(s,c);let l=e.pow(s,n);l=e.mul(l,c);let u=e.mul(l,o),d=e.mul(e.sqr(l),i),p=e.eql(d,t),m=e.cmov(u,l,p);return{isValid:p,value:m}}}return sqrtRatio}t.weierstrassPoints=weierstrassPoints,t.weierstrass=function(e){let n=function(e){let t=(0,c.validateBasic)(e);return i.validateObject(t,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...t})}(e),{Fp:l,n:u}=n,m=l.BYTES+1,b=2*l.BYTES+1;function modN(e){return o.mod(e,u)}function invN(e){return o.invert(e,u)}let{ProjectivePoint:g,normPrivateKeyToScalar:y,weierstrassEquation:v,isWithinCurveOrder:E}=weierstrassPoints({...n,toBytes(e,t,n){let o=t.toAffine(),s=l.toBytes(o.x),c=i.concatBytes;return n?c(Uint8Array.from([t.hasEvenY()?2:3]),s):c(Uint8Array.from([4]),s,l.toBytes(o.y))},fromBytes(e){let t=e.length,n=e[0],o=e.subarray(1);if(t===m&&(2===n||3===n)){let e=i.bytesToNumberBE(o);if(!(d<e&&e<l.ORDER))throw Error("Point is not on curve");let t=v(e),s=l.sqrt(t),c=(s&p)===p;return(1&n)==1!==c&&(s=l.neg(s)),{x:e,y:s}}if(t===b&&4===n){let e=l.fromBytes(o.subarray(0,l.BYTES)),t=l.fromBytes(o.subarray(l.BYTES,2*l.BYTES));return{x:e,y:t}}throw Error(`Point of length ${t} was invalid. Expected ${m} compressed bytes or ${b} uncompressed bytes`)}}),numToNByteStr=e=>i.bytesToHex(i.numberToBytesBE(e,n.nByteLength));function isBiggerThanHalfOrder(e){let t=u>>p;return e>t}let slcNum=(e,t,n)=>i.bytesToNumberBE(e.slice(t,n));let Signature=class Signature{constructor(e,t,n){this.r=e,this.s=t,this.recovery=n,this.assertValidity()}static fromCompact(e){let t=n.nByteLength;return e=(0,s.ensureBytes)("compactSignature",e,2*t),new Signature(slcNum(e,0,t),slcNum(e,t,2*t))}static fromDER(e){let{r:n,s:o}=t.DER.toSig((0,s.ensureBytes)("DER",e));return new Signature(n,o)}assertValidity(){if(!E(this.r))throw Error("r must be 0 < r < CURVE.n");if(!E(this.s))throw Error("s must be 0 < s < CURVE.n")}addRecoveryBit(e){return new Signature(this.r,this.s,e)}recoverPublicKey(e){let{r:t,s:o,recovery:i}=this,c=P((0,s.ensureBytes)("msgHash",e));if(null==i||![0,1,2,3].includes(i))throw Error("recovery id invalid");let u=2===i||3===i?t+n.n:t;if(u>=l.ORDER)throw Error("recovery id 2 or 3 invalid");let d=(1&i)==0?"02":"03",p=g.fromHex(d+numToNByteStr(u)),m=invN(u),b=modN(-c*m),y=modN(o*m),v=g.BASE.multiplyAndAddUnsafe(p,b,y);if(!v)throw Error("point at infinify");return v.assertValidity(),v}
1hasHighS(){return isBiggerThanHalfOrder(this.s)}normalizeS(){return this.hasHighS()?new Signature(this.r,modN(-this.s),this.recovery):this}toDERRawBytes(){return i.hexToBytes(this.toDERHex())}toDERHex(){return t.DER.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return i.hexToBytes(this.toCompactHex())}toCompactHex(){return numToNByteStr(this.r)+numToNByteStr(this.s)}};function isProbPub(e){let t=e instanceof Uint8Array,n="string"==typeof e,o=(t||n)&&e.length;return t?o===m||o===b:n?o===2*m||o===2*b:e instanceof g}let x=n.bits2int||function(e){let t=i.bytesToNumberBE(e),o=8*e.length-n.nBitLength;return o>0?t>>BigInt(o):t},P=n.bits2int_modN||function(e){return modN(x(e))},_=i.bitMask(n.nBitLength);function int2octets(e){if("bigint"!=typeof e)throw Error("bigint expected");if(!(d<=e&&e<_))throw Error(`bigint expected < 2^${n.nBitLength}`);return i.numberToBytesBE(e,n.nByteLength)}let I={lowS:n.lowS,prehash:!1},j={lowS:n.lowS,prehash:!1};return g.BASE._setWindowSize(8),{CURVE:n,getPublicKey:function(e,t=!0){return g.fromPrivateKey(e).toRawBytes(t)},getSharedSecret:function(e,t,n=!0){if(isProbPub(e))throw Error("first arg must be private key");if(!isProbPub(t))throw Error("second arg must be public key");let o=g.fromHex(t);return o.multiply(y(e)).toRawBytes(n)},sign:function(e,t,o=I){let{seed:c,k2sig:u}=function(e,t,o=I){if(["recovered","canonical"].some(e=>e in o))throw Error("sign() legacy options not supported");let{hash:c,randomBytes:u}=n,{lowS:m,prehash:b,extraEntropy:v}=o;null==m&&(m=!0),e=(0,s.ensureBytes)("msgHash",e),b&&(e=(0,s.ensureBytes)("prehashed msgHash",c(e)));let _=P(e),j=y(t),R=[int2octets(j),int2octets(_)];if(null!=v){let e=!0===v?u(l.BYTES):v;R.push((0,s.ensureBytes)("extraEntropy",e))}let M=i.concatBytes(...R);return{seed:M,k2sig:function(e){let t=x(e);if(!E(t))return;let n=invN(t),o=g.BASE.multiply(t).toAffine(),i=modN(o.x);if(i===d)return;let s=modN(n*modN(_+i*j));if(s===d)return;let c=(o.x===i?0:2)|Number(o.y&p),l=s;return m&&isBiggerThanHalfOrder(s)&&(l=isBiggerThanHalfOrder(s)?modN(-s):s,c^=1),new Signature(i,l,c)}}}(e,t,o),m=i.createHmacDrbg(n.hash.outputLen,n.nByteLength,n.hmac);return m(c,u)},verify:function(e,o,i,c=j){let l,u;if(o=(0,s.ensureBytes)("msgHash",o),i=(0,s.ensureBytes)("publicKey",i),"strict"in c)throw Error("options.strict was renamed to lowS");let{lowS:d,prehash:p}=c;try{if("string"==typeof e||e instanceof Uint8Array)try{u=Signature.fromDER(e)}catch(n){if(!(n instanceof t.DER.Err))throw n;u=Signature.fromCompact(e)}else if("object"==typeof e&&"bigint"==typeof e.r&&"bigint"==typeof e.s){let{r:t,s:n}=e;u=new Signature(t,n)}else throw Error("PARSE");l=g.fromHex(i)}catch(e){if("PARSE"===e.message)throw Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(d&&u.hasHighS())return!1;p&&(o=n.hash(o));let{r:m,s:b}=u,y=P(o),v=invN(b),E=modN(y*v),x=modN(m*v),_=g.BASE.multiplyAndAddUnsafe(l,E,x)?.toAffine();if(!_)return!1;let I=modN(_.x);return I===m},ProjectivePoint:g,Signature,utils:{isValidPrivateKey(e){try{return y(e),!0}catch(e){return!1}},normPrivateKeyToScalar:y,randomPrivateKey:()=>{let e=o.getMinHashLength(n.n);return o.mapHashToField(n.randomBytes(e),n.n)},precompute:(e=8,t=g.BASE)=>(t._setWindowSize(e),t.multiply(BigInt(3)),t)}}},t.SWUFpSqrtRatio=SWUFpSqrtRatio,t.mapToCurveSimpleSWU=function(e,t){if(o.validateField(e),!e.isValid(t.A)||!e.isValid(t.B)||!e.isValid(t.Z))throw Error("mapToCurveSimpleSWU: invalid opts");let n=SWUFpSqrtRatio(e,t.Z);if(!e.isOdd)throw Error("Fp.isOdd is not implemented!");return o=>{let i,s,c,l,u,d,p,m;i=e.sqr(o),i=e.mul(i,t.Z),s=e.sqr(i),s=e.add(s,i),c=e.add(s,e.ONE),c=e.mul(c,t.B),l=e.cmov(t.Z,e.neg(s),!e.eql(s,e.ZERO)),l=e.mul(l,t.A),s=e.sqr(c),d=e.sqr(l),u=e.mul(d,t.A),s=e.add(s,u),s=e.mul(s,c),d=e.mul(d,l),u=e.mul(d,t.B),s=e.add(s,u),p=e.mul(i,c);let{isValid:b,value:g}=n(s,d);m=e.mul(i,o),m=e.mul(m,g),p=e.cmov(p,c,b),m=e.cmov(m,g,b);let y=e.isOdd(o)===e.isOdd(m);return m=e.cmov(e.neg(m),m,y),{x:p=e.div(p,l),y:m}}}},61567:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeToCurve=t.hashToCurve=t.schnorr=t.secp256k1=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */let o=n(92030),i=n(824),s=n(37610),c=n(51983),l=n(34131),u=n(57486),d=n(65421),p=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),m=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),b=BigInt(1),g=BigInt(2),divNearest=(e,t)=>
1(e+t/g)/t;function sqrtMod(e){let t=BigInt(3),n=BigInt(6),o=BigInt(11),i=BigInt(22),c=BigInt(23),l=BigInt(44),u=BigInt(88),d=e*e*e%p,m=d*d*e%p,b=(0,s.pow2)(m,t,p)*m%p,v=(0,s.pow2)(b,t,p)*m%p,E=(0,s.pow2)(v,g,p)*d%p,x=(0,s.pow2)(E,o,p)*E%p,P=(0,s.pow2)(x,i,p)*x%p,_=(0,s.pow2)(P,l,p)*P%p,I=(0,s.pow2)(_,u,p)*_%p,j=(0,s.pow2)(I,l,p)*P%p,R=(0,s.pow2)(j,t,p)*m%p,M=(0,s.pow2)(R,c,p)*x%p,F=(0,s.pow2)(M,n,p)*d%p,q=(0,s.pow2)(F,g,p);if(!y.eql(y.sqr(q),e))throw Error("Cannot find square root");return q}let y=(0,s.Field)(p,void 0,void 0,{sqrt:sqrtMod});t.secp256k1=(0,d.createCurve)({a:BigInt(0),b:BigInt(7),Fp:y,n:m,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:e=>{let t=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),n=-b*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),o=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),i=BigInt("0x100000000000000000000000000000000"),c=divNearest(t*e,m),l=divNearest(-n*e,m),u=(0,s.mod)(e-c*t-l*o,m),d=(0,s.mod)(-c*n-l*t,m),p=u>i,g=d>i;if(p&&(u=m-u),g&&(d=m-d),u>i||d>i)throw Error("splitScalar: Endomorphism failed, k="+e);return{k1neg:p,k1:u,k2neg:g,k2:d}}}},o.sha256);let v=BigInt(0),fe=e=>"bigint"==typeof e&&v<e&&e<p,ge=e=>"bigint"==typeof e&&v<e&&e<m,E={};function taggedHash(e,...t){let n=E[e];if(void 0===n){let t=(0,o.sha256)(Uint8Array.from(e,e=>e.charCodeAt(0)));n=(0,l.concatBytes)(t,t),E[e]=n}return(0,o.sha256)((0,l.concatBytes)(n,...t))}let pointToBytes=e=>e.toRawBytes(!0).slice(1),numTo32b=e=>(0,l.numberToBytesBE)(e,32),modP=e=>(0,s.mod)(e,p),modN=e=>(0,s.mod)(e,m),x=t.secp256k1.ProjectivePoint,GmulAdd=(e,t,n)=>x.BASE.multiplyAndAddUnsafe(e,t,n);function schnorrGetExtPubKey(e){let n=t.secp256k1.utils.normPrivateKeyToScalar(e),o=x.fromPrivateKey(n),i=o.hasEvenY()?n:modN(-n);return{scalar:i,bytes:pointToBytes(o)}}function lift_x(e){if(!fe(e))throw Error("bad x: need 0 < x < p");let t=modP(e*e),n=modP(t*e+BigInt(7)),o=sqrtMod(n);o%g!==v&&(o=modP(-o));let i=new x(e,o,b);return i.assertValidity(),i}function challenge(...e){return modN((0,l.bytesToNumberBE)(taggedHash("BIP0340/challenge",...e)))}function schnorrVerify(e,t,n){let o=(0,l.ensureBytes)("signature",e,64),i=(0,l.ensureBytes)("message",t),s=(0,l.ensureBytes)("publicKey",n,32);try{let e=lift_x((0,l.bytesToNumberBE)(s)),t=(0,l.bytesToNumberBE)(o.subarray(0,32));if(!fe(t))return!1;let n=(0,l.bytesToNumberBE)(o.subarray(32,64));if(!ge(n))return!1;let c=challenge(numTo32b(t),pointToBytes(e),i),u=GmulAdd(e,n,modN(-c));if(!u||!u.hasEvenY()||u.toAffine().x!==t)return!1;return!0}catch(e){return!1}}t.schnorr={getPublicKey:function(e){return schnorrGetExtPubKey(e).bytes},sign:function(e,t,n=(0,i.randomBytes)(32)){let o=(0,l.ensureBytes)("message",e),{bytes:s,scalar:c}=schnorrGetExtPubKey(t),u=(0,l.ensureBytes)("auxRand",n,32),d=numTo32b(c^(0,l.bytesToNumberBE)(taggedHash("BIP0340/aux",u))),p=taggedHash("BIP0340/nonce",d,s,o),m=modN((0,l.bytesToNumberBE)(p));if(m===v)throw Error("sign failed: k is zero");let{bytes:b,scalar:g}=schnorrGetExtPubKey(m),y=challenge(b,s,o),E=new Uint8Array(64);if(E.set(b,0),E.set(numTo32b(modN(g+y*c)),32),!schnorrVerify(E,o,s))throw Error("sign: Invalid signature produced");return E},verify:schnorrVerify,utils:{randomPrivateKey:t.secp256k1.utils.randomPrivateKey,lift_x,pointToBytes,numberToBytesBE:l.numberToBytesBE,bytesToNumberBE:l.bytesToNumberBE,taggedHash,mod:s.mod}};let P=(0,u.isogenyMap)(y,[["0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa8c7","0x7d3d4c80bc321d5b9f315cea7fd44c5d595d2fc0bf63b92dfff1044f17c6581","0x534c328d23f234e6e2a413deca25caece4506144037c40314ecbd0b53d9dd262","0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa88c"],["0xd35771193d94918a9ca34ccbb7b640dd86cd409542f8487d9fe6b745781eb49b","0xedadc6f64383dc1df7c4b2d51b54225406d36b641f5e41bbc52a56612a8c6d14","0x0000000000000000000000000000000000000000000000000000000000000001"],["0x4bda12f684bda12f684bda12f684bda12f684bda12f684bda12f684b8e38e23c","0xc75e0c32d5cb7c0fa9d0a54b12a0a6d5647ab046d686da6fdffc90fc201d71a3","0x29a6194691f91a73715209ef6512e576722830a201be2018a765e85a9ecee931","0x2f684bda12f684bda12f684bda12f684bda12f684bda12f684bda12f38e38d84"],["0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffff93b","0x7a06534bb8bdb49fd5e9e6632722c2989467c1bfc8e8d978dfb425d2685c2573","0x6484aa716545ca2cf3a70c3fa8fe337e0a3d21162f0d6299a7bf8192bfd2a76f","0x0000000000000000000000000000000000000000000000000000000000000001"]].map(e=>e.map(e=>
1BigInt(e)))),_=(0,c.mapToCurveSimpleSWU)(y,{A:BigInt("0x3f8731abdd661adca08a5558f0f5d272e953d363cb6f0e5d405447c01a444533"),B:BigInt("1771"),Z:y.create(BigInt("-11"))}),I=(0,u.createHasher)(t.secp256k1.ProjectivePoint,e=>{let{x:t,y:n}=_(y.create(e[0]));return P(t,n)},{DST:"secp256k1_XMD:SHA-256_SSWU_RO_",encodeDST:"secp256k1_XMD:SHA-256_SSWU_NU_",p:y.ORDER,m:1,k:128,expand:"xmd",hash:o.sha256});t.hashToCurve=I.hashToCurve,t.encodeToCurve=I.encodeToCurve},33793:function(e,t){"use strict";function number(e){if(!Number.isSafeInteger(e)||e<0)throw Error(`Wrong positive integer: ${e}`)}function bool(e){if("boolean"!=typeof e)throw Error(`Expected boolean, not ${e}`)}function bytes(e,...t){if(!(e instanceof Uint8Array))throw Error("Expected Uint8Array");if(t.length>0&&!t.includes(e.length))throw Error(`Expected Uint8Array of length ${t}, not of length=${e.length}`)}function hash(e){if("function"!=typeof e||"function"!=typeof e.create)throw Error("Hash should be wrapped by utils.wrapConstructor");number(e.outputLen),number(e.blockLen)}function exists(e,t=!0){if(e.destroyed)throw Error("Hash instance has been destroyed");if(t&&e.finished)throw Error("Hash#digest() has already been called")}function output(e,t){bytes(e);let n=t.outputLen;if(e.length<n)throw Error(`digestInto() expects output buffer of length at least ${n}`)}Object.defineProperty(t,"__esModule",{value:!0}),t.output=t.exists=t.hash=t.bytes=t.bool=t.number=void 0,t.number=number,t.bool=bool,t.bytes=bytes,t.hash=hash,t.exists=exists,t.output=output,t.default={number,bool,bytes,hash,exists,output}},74228:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SHA2=void 0;let o=n(33793),i=n(824);let SHA2=class SHA2 extends i.Hash{constructor(e,t,n,o){super(),this.blockLen=e,this.outputLen=t,this.padOffset=n,this.isLE=o,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=(0,i.createView)(this.buffer)}update(e){(0,o.exists)(this);let{view:t,buffer:n,blockLen:s}=this;e=(0,i.toBytes)(e);let c=e.length;for(let o=0;o<c;){let l=Math.min(s-this.pos,c-o);if(l===s){let t=(0,i.createView)(e);for(;s<=c-o;o+=s)this.process(t,o);continue}n.set(e.subarray(o,o+l),this.pos),this.pos+=l,o+=l,this.pos===s&&(this.process(t,0),this.pos=0)}return this.length+=e.length,this.roundClean(),this}digestInto(e){(0,o.exists)(this),(0,o.output)(e,this),this.finished=!0;let{buffer:t,view:n,blockLen:s,isLE:c}=this,{pos:l}=this;t[l++]=128,this.buffer.subarray(l).fill(0),this.padOffset>s-l&&(this.process(n,0),l=0);for(let e=l;e<s;e++)t[e]=0;!function(e,t,n,o){if("function"==typeof e.setBigUint64)return e.setBigUint64(t,n,o);let i=BigInt(32),s=BigInt(4294967295),c=Number(n>>i&s),l=Number(n&s),u=o?4:0,d=o?0:4;e.setUint32(t+u,c,o),e.setUint32(t+d,l,o)}(n,s-8,BigInt(8*this.length),c),this.process(n,0);let u=(0,i.createView)(e),d=this.outputLen;if(d%4)throw Error("_sha2: outputLen should be aligned to 32bit");let p=d/4,m=this.get();if(p>m.length)throw Error("_sha2: outputLen bigger than state");for(let e=0;e<p;e++)u.setUint32(4*e,m[e],c)}digest(){let{buffer:e,outputLen:t}=this;this.digestInto(e);let n=e.slice(0,t);return this.destroy(),n}_cloneInto(e){e||(e=new this.constructor),e.set(...this.get());let{blockLen:t,buffer:n,length:o,finished:i,destroyed:s,pos:c}=this;return e.length=o,e.pos=c,e.finished=i,e.destroyed=s,o%t&&e.buffer.set(n),e}};t.SHA2=SHA2},33820:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.add5L=t.add5H=t.add4H=t.add4L=t.add3H=t.add3L=t.add=t.rotlBL=t.rotlBH=t.rotlSL=t.rotlSH=t.rotr32L=t.rotr32H=t.rotrBL=t.rotrBH=t.rotrSL=t.rotrSH=t.shrSL=t.shrSH=t.toBig=t.split=t.fromBig=void 0;let n=BigInt(4294967296-1),o=BigInt(32);function fromBig(e,t=!1){return t?{h:Number(e&n),l:Number(e>>o&n)}:{h:0|Number(e>>o&n),l:0|Number(e&n)}}function split(e,t=!1){let n=new Uint32Array(e.length),o=new Uint32Array(e.length);for(let i=0;i<e.length;i++){let{h:s,l:c}=fromBig(e[i],t);[n[i],o[i]]=[s,c]}return[n,o]}t.fromBig=fromBig,t.split=split;let toBig=(e,t)=>BigInt(e>>>0)<<o|BigInt(t>>>0);t.toBig=toBig;let shrSH=(e,t,n)=>e>>>n;t.shrSH=shrSH;let shrSL=(e,t,n)=>e<<32-n|t>>>n;t.shrSL=shrSL;let rotrSH=(e,t,n)=>e>>>n|t<<32-n;t.rotrSH=rotrSH;let rotrSL=(e,t,n)=>e<<32-n|t>>>n;t.rotrSL=rotrSL;let rotrBH=(e,t,n)=>e<<64-n|t>>>n-32;t.rotrBH=rotrBH;let rotrBL=(e,t,n)=>e>>>n-32|t<<64-n;t.rotrBL=rotrBL;let rotr32H=(e,t)=>t;t.rotr32H=rotr32H;let rotr32L=(e,t)=>e;t.rotr32L=rotr32L;let rotlSH=(e,t,n)=>e<<n|t>>>32-n;t.rotlSH=rotlSH;let rotlSL=(e,t,n)=>t<<n|e>>>32-n;t.rotlSL=rotlSL;let rotlBH=(e,t,n)=>t<<n-32|e>>>64-n;t.rotlBH=rotlBH;let rotlBL=(e,t,n)=>e<<n-32|t>>>64-n;function add(e,t,n,o){let i=(t>>>0)+(o>>>0);return{h:e+n+(i/4294967296|0)|0,l:0|i}}t.rotlBL=rotlBL,t.add=add;let add3L=(e,t,n)=>(e>>>0)+(t>>>0)+(n>>>0);t.add3L=add3L;let add3H=(e,t,n,o)=>t+n+o+(e/4294967296|0)|0;t.add3H=add3H;let add4L=(e,t,n,o)=>(e>>>0)+(t>>>0)+(n>>>0)+(o>>>0);t.add4L=add4L;let add4H=(e,t,n,o,i)=>t+n+o+i+(e/4294967296|0)|0;t.add4H=add4H;let add5L=(e,t,n,o,i)=>(e>>>0)+(t>>>0)+(n>>>0)+(o>>>0)+(i>>>0);t.add5L=add5L;let add5H=(e,t,n,o,i,s)=>t+n+o+i+s+(e/4294967296|0)|0;t.add5H=add5H,t.default={fromBig,split,toBig,shrSH,shrSL,rotrSH,rotrSL,rotrBH,rotrBL,rotr32H,rotr32L,rotlSH,rotlSL,rotlBH,rotlBL,add,add3L,add3H,add4L,add4H,add5H,add5L}},3777:function(e,t){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0},2738:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hmac=t.HMAC=void 0;let o=n(33793),i=n(824);let HMAC=class HMAC extends i.Hash{constructor(e,t){super(),this.finished=!1,this.destroyed=!1,(0,o.hash)(e);let n=(0,i.toBytes)(t);if(this.iHash=e.create(),"function"!=typeof this.iHash.update)throw Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;let s=this.blockLen,c=new Uint8Array(s);c.set(n.length>s?e.create().update(n).digest():n);for(let e=0;e<c.length;e++)c[e]^=54;this.iHash.update(c),this.oHash=e.create();for(let e=0;e<c.length;e++)c[e]^=106;this.oHash.update(c),c.fill(0)}update(e){return(0,o.exists)(this),this.iHash.update(e),this}digestInto(e){(0,o.exists)(this),(0,o.bytes)(e,this.outputLen),this.finished=!0,this.iHash.digestInto(e),this.oHash.update(e),this.oHash.digestInto(e),this.destroy()}digest(){let e=new Uint8Array(this.oHash.outputLen);return this.digestInto(e),e}_cloneInto(e){e||(e=Object.create(Object.getPrototypeOf(this),{}));let{oHash:t,iHash:n,finished:o,destroyed:i,blockLen:s,outputLen:c}=this;return e.finished=o,e.destroyed=i,e.blockLen=s,e.outputLen=c,e.oHash=t._cloneInto(e.oHash),e.iHash=n._cloneInto(e.iHash),e}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}};t.HMAC=HMAC,t.hmac=(e,t,n)=>new HMAC(e,t).update(n).digest(),t.hmac.create=(e,t)=>new HMAC(e,t)},83837:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=t.RIPEMD160=void 0;let o=n(74228),i=n(824),s=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),c=Uint8Array.from({length:16},(e,t)=>t),l=c.map(e=>(9*e+5)%16),u=[c],d=[l];for(let e=0;e<4;e++)for(let t of[u,d])t.push(t[e].map(e=>s[e]));let p=[[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(e=>new Uint8Array(e)),m=u.map((e,t)=>e.map(e=>p[t][e])),b=d.map((e,t)=>e.map(e=>p[t][e])),g=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),y=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),rotl=(e,t)=>e<<t|e>>>32-t;function f(e,t,n,o){return 0===e?t^n^o:1===e?t&n|~t&o:2===e?(t|~n)^o:3===e?t&o|n&~o:t^(n|~o)}let v=new Uint32Array(16);let RIPEMD160=class RIPEMD160 extends o.SHA2{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){let{h0:e,h1:t,h2:n,h3:o,h4:i}=this;return[e,t,n,o,i]}set(e,t,n,o,i){this.h0=0|e,this.h1=0|t,this.h2=0|n,this.h3=0|o,this.h4=0|i}process(e,t){for(let n=0;n<16;n++,t+=4)v[n]=e.getUint32(t,!0);let n=0|this.h0,o=n,i=0|this.h1,s=i,c=0|this.h2,l=c,p=0|this.h3,E=p,x=0|this.h4,P=x;for(let e=0;e<5;e++){let t=4-e,_=g[e],I=y[e],j=u[e],R=d[e],M=m[e],F=b[e];for(let t=0;t<16;t++){let o=rotl(n+f(e,i,c,p)+v[j[t]]+_,M[t])+x|0;n=x,x=p,p=0|rotl(c,10),c=i,i=o}for(let e=0;e<16;e++){let n=rotl(o+f(t,s,l,E)+v[R[e]]+I,F[e])+P|0;o=P,P=E,E=0|rotl(l,10),l=s,s=n}}this.set(this.h1+c+E|0,this.h2+p+P|0,this.h3+x+o|0,this.h4+n+s|0,this.h0+i+l|0)}roundClean(){v.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}};t.RIPEMD160=RIPEMD160,t.ripemd160=(0,i.wrapConstructor)(()=>new RIPEMD160)},92030:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha224=t.sha256=void 0;let o=n(74228),i=n(824),Chi=(e,t,n)=>e&t^~e&n,Maj=(e,t,n)=>e&t^e&n^t&n,s=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,2756
1734187,3204031479,3329325298]),c=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),l=new Uint32Array(64);let SHA256=class SHA256 extends o.SHA2{constructor(){super(64,32,8,!1),this.A=0|c[0],this.B=0|c[1],this.C=0|c[2],this.D=0|c[3],this.E=0|c[4],this.F=0|c[5],this.G=0|c[6],this.H=0|c[7]}get(){let{A:e,B:t,C:n,D:o,E:i,F:s,G:c,H:l}=this;return[e,t,n,o,i,s,c,l]}set(e,t,n,o,i,s,c,l){this.A=0|e,this.B=0|t,this.C=0|n,this.D=0|o,this.E=0|i,this.F=0|s,this.G=0|c,this.H=0|l}process(e,t){for(let n=0;n<16;n++,t+=4)l[n]=e.getUint32(t,!1);for(let e=16;e<64;e++){let t=l[e-15],n=l[e-2],o=(0,i.rotr)(t,7)^(0,i.rotr)(t,18)^t>>>3,s=(0,i.rotr)(n,17)^(0,i.rotr)(n,19)^n>>>10;l[e]=s+l[e-7]+o+l[e-16]|0}let{A:n,B:o,C:c,D:u,E:d,F:p,G:m,H:b}=this;for(let e=0;e<64;e++){let t=(0,i.rotr)(d,6)^(0,i.rotr)(d,11)^(0,i.rotr)(d,25),g=b+t+Chi(d,p,m)+s[e]+l[e]|0,y=(0,i.rotr)(n,2)^(0,i.rotr)(n,13)^(0,i.rotr)(n,22),v=y+Maj(n,o,c)|0;b=m,m=p,p=d,d=u+g|0,u=c,c=o,o=n,n=g+v|0}n=n+this.A|0,o=o+this.B|0,c=c+this.C|0,u=u+this.D|0,d=d+this.E|0,p=p+this.F|0,m=m+this.G|0,b=b+this.H|0,this.set(n,o,c,u,d,p,m,b)}roundClean(){l.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}};let SHA224=class SHA224 extends SHA256{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}};t.sha256=(0,i.wrapConstructor)(()=>new SHA256),t.sha224=(0,i.wrapConstructor)(()=>new SHA224)},67808:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shake256=t.shake128=t.keccak_512=t.keccak_384=t.keccak_256=t.keccak_224=t.sha3_512=t.sha3_384=t.sha3_256=t.sha3_224=t.Keccak=t.keccakP=void 0;let o=n(33793),i=n(33820),s=n(824),[c,l,u]=[[],[],[]],d=BigInt(0),p=BigInt(1),m=BigInt(2),b=BigInt(7),g=BigInt(256),y=BigInt(113);for(let e=0,t=p,n=1,o=0;e<24;e++){[n,o]=[o,(2*n+3*o)%5],c.push(2*(5*o+n)),l.push((e+1)*(e+2)/2%64);let i=d;for(let e=0;e<7;e++)(t=(t<<p^(t>>b)*y)%g)&m&&(i^=p<<(p<<BigInt(e))-p);u.push(i)}let[v,E]=(0,i.split)(u,!0),rotlH=(e,t,n)=>n>32?(0,i.rotlBH)(e,t,n):(0,i.rotlSH)(e,t,n),rotlL=(e,t,n)=>n>32?(0,i.rotlBL)(e,t,n):(0,i.rotlSL)(e,t,n);function keccakP(e,t=24){let n=new Uint32Array(10);for(let o=24-t;o<24;o++){for(let t=0;t<10;t++)n[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){let o=(t+8)%10,i=(t+2)%10,s=n[i],c=n[i+1],l=rotlH(s,c,1)^n[o],u=rotlL(s,c,1)^n[o+1];for(let n=0;n<50;n+=10)e[t+n]^=l,e[t+n+1]^=u}let t=e[2],i=e[3];for(let n=0;n<24;n++){let o=l[n],s=rotlH(t,i,o),u=rotlL(t,i,o),d=c[n];t=e[d],i=e[d+1],e[d]=s,e[d+1]=u}for(let t=0;t<50;t+=10){for(let o=0;o<10;o++)n[o]=e[t+o];for(let o=0;o<10;o++)e[t+o]^=~n[(o+2)%10]&n[(o+4)%10]}e[0]^=v[o],e[1]^=E[o]}n.fill(0)}t.keccakP=keccakP;let Keccak=class Keccak extends s.Hash{constructor(e,t,n,i=!1,c=24){if(super(),this.blockLen=e,this.suffix=t,this.outputLen=n,this.enableXOF=i,this.rounds=c,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,(0,o.number)(n),0>=this.blockLen||this.blockLen>=200)throw Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=(0,s.u32)(this.state)}keccak(){keccakP(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){(0,o.exists)(this);let{blockLen:t,state:n}=this;e=(0,s.toBytes)(e);let i=e.length;for(let o=0;o<i;){let s=Math.min(t-this.pos,i-o);for(let t=0;t<s;t++)n[this.pos++]^=e[o++];this.pos===t&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;let{state:e,suffix:t,pos:n,blockLen:o}=this;e[n]^=t,(128&t)!=0&&n===o-1&&this.keccak(),e[o-1]^=128,this.keccak()}writeInto(e){(0,o.exists)(this,!1),(0,o.bytes)(e),this.finish();let t=this.state,{blockLen:n}=this;for(let o=0,i=e.length;o<i;){this.posOut>=n&&this.keccak();let s=Math.min(n-this.posOut,i-o);e.set(t.subarray(this.posOut,this.posOut+s),o),this.posOut+=s,o+=s}return e}xofInto(e){if(!this.enableXOF)throw Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return(0,o.number)(e),this.xofInto(new Uint8Array(e))}digestInto(e){if((0,o.output)(e,this),this.finished)throw 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){let{blockLen:t,suffix:n,outputLen:o,rounds:i,enableXOF:s}=this;return e||(e=new Keccak(t,n,o,s,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=o,e.enableXOF=s,e.destroyed=this.destroyed,e}};t.Keccak=Keccak;let gen=(e,t,n)=>(0,s.wrapConstructor)(()=>new Keccak(t,e,n));t.sha3_224=gen(6,144,28),t.sha3_256=gen(6,136,32),t.sha3_384=gen(6,104,48),t.sha3_512=gen(6,72,64),t.keccak_224=gen(1,144,28),t.keccak_256=gen(1,136,32),t.keccak_384=gen(1,104,48),t.keccak_512=gen(1,72,64);let genShake=(e,t,n)=>(0,s.wrapXOFConstructorWithOpts)((o={})=>new Keccak(t,e,void 0===o.dkLen?n:o.dkLen,!0));t.shake128=genShake(31,168,16),t.shake256=genShake(31,136,32)},824:function(e,t,n){"use strict";/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */Object.defineProperty(t,"__esMo
1dule",{value:!0}),t.randomBytes=t.wrapXOFConstructorWithOpts=t.wrapConstructorWithOpts=t.wrapConstructor=t.checkOpts=t.Hash=t.concatBytes=t.toBytes=t.utf8ToBytes=t.asyncLoop=t.nextTick=t.hexToBytes=t.bytesToHex=t.isLE=t.rotr=t.createView=t.u32=t.u8=void 0;let o=n(3777),u8a=e=>e instanceof Uint8Array;if(t.u8=e=>new Uint8Array(e.buffer,e.byteOffset,e.byteLength),t.u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4)),t.createView=e=>new DataView(e.buffer,e.byteOffset,e.byteLength),t.rotr=(e,t)=>e<<32-t|e>>>t,t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!t.isLE)throw Error("Non little-endian hardware is not supported");let i=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));t.bytesToHex=function(e){if(!u8a(e))throw Error("Uint8Array expected");let t="";for(let n=0;n<e.length;n++)t+=i[e[n]];return t},t.hexToBytes=function(e){if("string"!=typeof e)throw Error("hex string expected, got "+typeof e);let t=e.length;if(t%2)throw Error("padded hex string expected, got unpadded hex of length "+t);let n=new Uint8Array(t/2);for(let t=0;t<n.length;t++){let o=2*t,i=e.slice(o,o+2),s=Number.parseInt(i,16);if(Number.isNaN(s)||s<0)throw Error("Invalid byte sequence");n[t]=s}return n};let nextTick=async()=>{};async function asyncLoop(e,n,o){let i=Date.now();for(let s=0;s<e;s++){o(s);let e=Date.now()-i;e>=0&&e<n||(await (0,t.nextTick)(),i+=e)}}function utf8ToBytes(e){if("string"!=typeof e)throw Error(`utf8ToBytes expected string, got ${typeof e}`);return new Uint8Array(new TextEncoder().encode(e))}function toBytes(e){if("string"==typeof e&&(e=utf8ToBytes(e)),!u8a(e))throw Error(`expected Uint8Array, got ${typeof e}`);return e}t.nextTick=nextTick,t.asyncLoop=asyncLoop,t.utf8ToBytes=utf8ToBytes,t.toBytes=toBytes,t.concatBytes=function(...e){let t=new Uint8Array(e.reduce((e,t)=>e+t.length,0)),n=0;return e.forEach(e=>{if(!u8a(e))throw Error("Uint8Array expected");t.set(e,n),n+=e.length}),t},t.Hash=class{clone(){return this._cloneInto()}};let s={}.toString;t.checkOpts=function(e,t){if(void 0!==t&&"[object Object]"!==s.call(t))throw Error("Options should be object or undefined");let n=Object.assign(e,t);return n},t.wrapConstructor=function(e){let hashC=t=>e().update(toBytes(t)).digest(),t=e();return hashC.outputLen=t.outputLen,hashC.blockLen=t.blockLen,hashC.create=()=>e(),hashC},t.wrapConstructorWithOpts=function(e){let hashC=(t,n)=>e(n).update(toBytes(t)).digest(),t=e({});return hashC.outputLen=t.outputLen,hashC.blockLen=t.blockLen,hashC.create=t=>e(t),hashC},t.wrapXOFConstructorWithOpts=function(e){let hashC=(t,n)=>e(n).update(toBytes(t)).digest(),t=e({});return hashC.outputLen=t.outputLen,hashC.blockLen=t.blockLen,hashC.create=t=>e(t),hashC},t.randomBytes=function(e=32){if(o.crypto&&"function"==typeof o.crypto.getRandomValues)return o.crypto.getRandomValues(new Uint8Array(e));throw Error("crypto.getRandomValues must be defined")}},1074:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_BASE_URL=void 0,t.DEFAULT_BASE_URL="https://safe-client.safe.global"},76287:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEndpoint=t.deleteEndpoint=t.putEndpoint=t.postEndpoint=void 0;let o=n(59136);function makeUrl(e,t,n,i){let s=(0,o.insertParams)(t,n),c=(0,o.stringifyQuery)(i);return`${e}${s}${c}`}t.postEndpoint=function(e,t,n){let i=makeUrl(e,t,null==n?void 0:n.path,null==n?void 0:n.query);return(0,o.fetchData)(i,"POST",null==n?void 0:n.body,null==n?void 0:n.headers)},t.putEndpoint=function(e,t,n){let i=makeUrl(e,t,null==n?void 0:n.path,null==n?void 0:n.query);return(0,o.fetchData)(i,"PUT",null==n?void 0:n.body,null==n?void 0:n.headers)},t.deleteEndpoint=function(e,t,n){let i=makeUrl(e,t,null==n?void 0:n.path,null==n?void 0:n.query);return(0,o.fetchData)(i,"DELETE",null==n?void 0:n.body,null==n?void 0:n.headers)},t.getEndpoint=function(e,t,n,i){if(i)return(0,o.getData)(i);let s=makeUrl(e,t,null==n?void 0:n.path,null==n?void 0:n.query);return(0,o.getData)(s,null==n?void 0:n.headers)}},18831:function(e,t,n){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,n,o){void 0===o&&(o=n);var i=Object.getOwnPropertyDescriptor(t,n);
1(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,o,i)}:function(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||o(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.unsubscribeAll=t.unsubscribeSingle=t.registerRecoveryModule=t.deleteRegisteredEmail=t.getRegisteredEmail=t.verifyEmail=t.resendEmailVerificationCode=t.changeEmail=t.registerEmail=t.unregisterDevice=t.unregisterSafe=t.registerDevice=t.getDelegates=t.confirmSafeMessage=t.proposeSafeMessage=t.getSafeMessage=t.getSafeMessages=t.getDecodedData=t.getMasterCopies=t.getSafeApps=t.getChainConfig=t.getChainsConfig=t.proposeTransaction=t.getNonces=t.postSafeGasEstimation=t.deleteTransaction=t.getTransactionDetails=t.getTransactionQueue=t.getTransactionHistory=t.getCollectiblesPage=t.getCollectibles=t.getAllOwnedSafes=t.getOwnedSafes=t.getFiatCurrencies=t.getBalances=t.getMultisigTransactions=t.getModuleTransactions=t.getIncomingTransfers=t.getSafeInfo=t.getRelayCount=t.relayTransaction=t.setBaseUrl=void 0;let s=n(76287),c=n(1074);i(n(32733),t),i(n(22394),t),i(n(17584),t),i(n(28996),t),i(n(23075),t),i(n(80247),t),i(n(83571),t),i(n(43150),t),i(n(50379),t),i(n(88553),t);let l=c.DEFAULT_BASE_URL;t.setBaseUrl=e=>{l=e},t.relayTransaction=function(e,t){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/relay",{path:{chainId:e},body:t})},t.getRelayCount=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/relay/{address}",{path:{chainId:e,address:t}})},t.getSafeInfo=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}",{path:{chainId:e,address:t}})},t.getIncomingTransfers=function(e,t,n,o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}/incoming-transfers/",{path:{chainId:e,address:t},query:n},o)},t.getModuleTransactions=function(e,t,n,o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}/module-transactions/",{path:{chainId:e,address:t},query:n},o)},t.getMultisigTransactions=function(e,t,n,o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}/multisig-transactions/",{path:{chainId:e,address:t},query:n},o)},t.getBalances=function(e,t,n="usd",o={}){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}/balances/{currency}",{path:{chainId:e,address:t,currency:n},query:o})},t.getFiatCurrencies=function(){return(0,s.getEndpoint)(l,"/v1/balances/supported-fiat-codes")},t.getOwnedSafes=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/owners/{address}/safes",{path:{chainId:e,address:t}})},t.getAllOwnedSafes=function(e){return(0,s.getEndpoint)(l,"/v1/owners/{address}/safes",{path:{address:e}})},t.getCollectibles=function(e,t,n={}){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:e,address:t},query:n})},t.getCollectiblesPage=function(e,t,n={},o){return(0,s.getEndpoint)(l,"/v2/chains/{chainId}/safes/{address}/collectibles",{path:{chainId:e,address:t},query:n},o)},t.getTransactionHistory=function(e,t,n={},o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/transactions/history",{path:{chainId:e,safe_address:t},query:n},o)},t.getTransactionQueue=function(e,t,n={},o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/transactions/queued",{path:{chainId:e,safe_address:t},query:n},o)},t.getTransactionDetails=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/transactions/{transactionId}",{path:{chainId:e,transactionId:t}})},t.deleteTransaction=function(e,t,n){return(0,s.deleteEndpoint)(l,"/v1/chains/{chainId}/transactions/{safeTxHash}",{path:{chainId:e,safeTxHash:t},body:{signature:n}})},t.postSafeGasEstimation=function(e,t,n){return(0,s.postEndpoint)(l,"/v2/chains/{chainId}/safes/{safe_address}/multisig-transactions/estimations",{path:{chainId:e,safe_address:t},body:n})},t.getNonces=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/nonces",{path:{chainId:e,safe_address:t}})},t.proposeTransaction=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/transactions/{safe_address}/propose",{path:{chainId:e,safe_address:t},body:n})},t.getChainsConfig=function(e){return(0,s.getEndpoint)(l,"/v1/chains",{query:e})},t.getChainConfig=function(e){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}",{path:{chainId:e}})},t.getSafeApps=function(e,t={}){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safe-apps",{path:{chainId:e},query:t})},t.getMasterCopies=function(e){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/about/master-copies",{path:{chainId:e}})},t.getDecodedData=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/data-decoder",{path:{chainId:e},body:{data:t,to:n}})},t.getSafeMessages=function(e,t,n){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:e,safe_address:t},query:{}},n)},t.getSafeMessage=function(e,t){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/messages/{message_hash}",{path:{chainId:e,message_hash:t}}
1)},t.proposeSafeMessage=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/messages",{path:{chainId:e,safe_address:t},body:n})},t.confirmSafeMessage=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/messages/{message_hash}/signatures",{path:{chainId:e,message_hash:t},body:n})},t.getDelegates=function(e,t={}){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/delegates",{path:{chainId:e},query:t})},t.registerDevice=function(e){return(0,s.postEndpoint)(l,"/v1/register/notifications",{body:e})},t.unregisterSafe=function(e,t,n){return(0,s.deleteEndpoint)(l,"/v1/chains/{chainId}/notifications/devices/{uuid}/safes/{safe_address}",{path:{chainId:e,safe_address:t,uuid:n}})},t.unregisterDevice=function(e,t){return(0,s.deleteEndpoint)(l,"/v1/chains/{chainId}/notifications/devices/{uuid}",{path:{chainId:e,uuid:t}})},t.registerEmail=function(e,t,n,o){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails",{path:{chainId:e,safe_address:t},body:n,headers:o})},t.changeEmail=function(e,t,n,o,i){return(0,s.putEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:e,safe_address:t,signer:n},body:o,headers:i})},t.resendEmailVerificationCode=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}/verify-resend",{path:{chainId:e,safe_address:t,signer:n},body:""})},t.verifyEmail=function(e,t,n,o){return(0,s.putEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}/verify",{path:{chainId:e,safe_address:t,signer:n},body:o})},t.getRegisteredEmail=function(e,t,n,o){return(0,s.getEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:e,safe_address:t,signer:n},headers:o})},t.deleteRegisteredEmail=function(e,t,n,o){return(0,s.deleteEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/emails/{signer}",{path:{chainId:e,safe_address:t,signer:n},headers:o})},t.registerRecoveryModule=function(e,t,n){return(0,s.postEndpoint)(l,"/v1/chains/{chainId}/safes/{safe_address}/recovery",{path:{chainId:e,safe_address:t},body:n})},t.unsubscribeSingle=function(e){return(0,s.deleteEndpoint)(l,"/v1/subscriptions",{query:e})},t.unsubscribeAll=function(e){return(0,s.deleteEndpoint)(l,"/v1/subscriptions/all",{query:e})}},28996:function(e,t){"use strict";var n,o,i;Object.defineProperty(t,"__esModule",{value:!0}),t.FEATURES=t.GAS_PRICE_TYPE=t.RPC_AUTHENTICATION=void 0,(n=t.RPC_AUTHENTICATION||(t.RPC_AUTHENTICATION={})).API_KEY_PATH="API_KEY_PATH",n.NO_AUTHENTICATION="NO_AUTHENTICATION",n.UNKNOWN="UNKNOWN",(o=t.GAS_PRICE_TYPE||(t.GAS_PRICE_TYPE={})).ORACLE="ORACLE",o.FIXED="FIXED",o.FIXED_1559="FIXED1559",o.UNKNOWN="UNKNOWN",(i=t.FEATURES||(t.FEATURES={})).ERC721="ERC721",i.SAFE_APPS="SAFE_APPS",i.CONTRACT_INTERACTION="CONTRACT_INTERACTION",i.DOMAIN_LOOKUP="DOMAIN_LOOKUP",i.SPENDING_LIMIT="SPENDING_LIMIT",i.EIP1559="EIP1559",i.SAFE_TX_GAS_OPTIONAL="SAFE_TX_GAS_OPTIONAL",i.TX_SIMULATION="TX_SIMULATION",i.EIP1271="EIP1271"},23075:function(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.TokenType=void 0,(n=t.TokenType||(t.TokenType={})).ERC20="ERC20",n.ERC721="ERC721",n.NATIVE_TOKEN="NATIVE_TOKEN"},83571:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},80247:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},50379:function(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.DeviceType=void 0,(n=t.DeviceType||(t.DeviceType={})).ANDROID="ANDROID",n.IOS="IOS",n.WEB="WEB"},88553:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},22394:function(e,t){"use strict";var n,o;Object.defineProperty(t,"__esModule",{value:!0}
1),t.SafeAppSocialPlatforms=t.SafeAppFeatures=t.SafeAppAccessPolicyTypes=void 0,(n=t.SafeAppAccessPolicyTypes||(t.SafeAppAccessPolicyTypes={})).NoRestrictions="NO_RESTRICTIONS",n.DomainAllowlist="DOMAIN_ALLOWLIST",(t.SafeAppFeatures||(t.SafeAppFeatures={})).BATCHED_TRANSACTIONS="BATCHED_TRANSACTIONS",(o=t.SafeAppSocialPlatforms||(t.SafeAppSocialPlatforms={})).TWITTER="TWITTER",o.GITHUB="GITHUB",o.DISCORD="DISCORD"},32733:function(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationVersionState=void 0,(n=t.ImplementationVersionState||(t.ImplementationVersionState={})).UP_TO_DATE="UP_TO_DATE",n.OUTDATED="OUTDATED",n.UNKNOWN="UNKNOWN"},43150:function(e,t){"use strict";var n,o;Object.defineProperty(t,"__esModule",{value:!0}),t.SafeMessageStatus=t.SafeMessageListItemType=void 0,(n=t.SafeMessageListItemType||(t.SafeMessageListItemType={})).DATE_LABEL="DATE_LABEL",n.MESSAGE="MESSAGE",(o=t.SafeMessageStatus||(t.SafeMessageStatus={})).NEEDS_CONFIRMATION="NEEDS_CONFIRMATION",o.CONFIRMED="CONFIRMED"},17584:function(e,t){"use strict";var n,o,i,s,c,l,u,d,p,m;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,(n=t.Operation||(t.Operation={}))[n.CALL=0]="CALL",n[n.DELEGATE=1]="DELEGATE",(o=t.TransactionStatus||(t.TransactionStatus={})).AWAITING_CONFIRMATIONS="AWAITING_CONFIRMATIONS",o.AWAITING_EXECUTION="AWAITING_EXECUTION",o.CANCELLED="CANCELLED",o.FAILED="FAILED",o.SUCCESS="SUCCESS",(i=t.TransferDirection||(t.TransferDirection={})).INCOMING="INCOMING",i.OUTGOING="OUTGOING",i.UNKNOWN="UNKNOWN",(s=t.TransactionTokenType||(t.TransactionTokenType={})).ERC20="ERC20",s.ERC721="ERC721",s.NATIVE_COIN="NATIVE_COIN",(c=t.SettingsInfoType||(t.SettingsInfoType={})).SET_FALLBACK_HANDLER="SET_FALLBACK_HANDLER",c.ADD_OWNER="ADD_OWNER",c.REMOVE_OWNER="REMOVE_OWNER",c.SWAP_OWNER="SWAP_OWNER",c.CHANGE_THRESHOLD="CHANGE_THRESHOLD",c.CHANGE_IMPLEMENTATION="CHANGE_IMPLEMENTATION",c.ENABLE_MODULE="ENABLE_MODULE",c.DISABLE_MODULE="DISABLE_MODULE",c.SET_GUARD="SET_GUARD",c.DELETE_GUARD="DELETE_GUARD",(l=t.TransactionInfoType||(t.TransactionInfoType={})).TRANSFER="Transfer",l.SETTINGS_CHANGE="SettingsChange",l.CUSTOM="Custom",l.CREATION="Creation",(u=t.ConflictType||(t.ConflictType={})).NONE="None",u.HAS_NEXT="HasNext",u.END="End",(d=t.TransactionListItemType||(t.TransactionListItemType={})).TRANSACTION="TRANSACTION",d.LABEL="LABEL",d.CONFLICT_HEADER="CONFLICT_HEADER",d.DATE_LABEL="DATE_LABEL",(p=t.DetailedExecutionInfoType||(t.DetailedExecutionInfoType={})).MULTISIG="MULTISIG",p.MODULE="MODULE",(m=t.LabelValue||(t.LabelValue={})).Queued="Queued",m.Next="Next"},59136:function(e,t){"use strict";var n=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))(function(i,s){function fulfilled(e){try{step(o.next(e))}catch(e){s(e)}}function rejected(e){try{step(o.throw(e))}catch(e){s(e)}}function step(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(fulfilled,rejected)}step((o=o.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.fetchData=t.stringifyQuery=t.insertParams=void 0;let isErrorResponse=e=>"object"==typeof e&&null!==e&&"code"in e&&"message"in e;function parseResponse(e){return n(this,void 0,void 0,function*(){let t;try{t=204===e.status?{}:yield e.json()}catch(t){if(e.headers&&"0"!==e.headers.get("content-length"))throw Error(`Invalid response content: ${e.statusText}`)}if(!e.ok){let n=isErrorResponse(t)?`${t.code}: ${t.message}`:e.statusText;throw Error(n)}return t})}t.insertParams=function(e,t){return t?Object.keys(t).reduce((e,n)=>{var o;return o=String(t[n]),e.replace(RegExp(`\\{${n}\\}`,"g"),o)},e):e},t.stringifyQuery=function(e){if(!e)return"";let t=new URLSearchParams;Object.keys(e).forEach(n=>{null!=e[n]&&t.append(n,String(e[n]))});let n=t.toString();return n?`?${n}`:""},t.fetchData=function(e,t,o,i){return n(this,void 0,void 0,function*(){let n=Object.assign({"Content-Type":"application/json"},i),s={method:null!=t?t:"POST",headers:n};null!=o&&(s.body="string"==typeof o?o:JSON.stringify(o));let c=yield fetch(e,s);return parseResponse(c)})},t.getData=function(e,t){return n(this,void 0,void 0,function*(){let n={method:"GET"};t&&(n.headers=Object.assign(Object.assign({},t),{"Content-Type":"application/json"}));
1let o=yield fetch(e,n);return parseResponse(o)})}},98099:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(97117);function writeUint16BE(e,t,n){return void 0===t&&(t=new Uint8Array(2)),void 0===n&&(n=0),t[n+0]=e>>>8,t[n+1]=e>>>0,t}function writeUint16LE(e,t,n){return void 0===t&&(t=new Uint8Array(2)),void 0===n&&(n=0),t[n+0]=e>>>0,t[n+1]=e>>>8,t}function readInt32BE(e,t){return void 0===t&&(t=0),e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3]}function readUint32BE(e,t){return void 0===t&&(t=0),(e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3])>>>0}function readInt32LE(e,t){return void 0===t&&(t=0),e[t+3]<<24|e[t+2]<<16|e[t+1]<<8|e[t]}function readUint32LE(e,t){return void 0===t&&(t=0),(e[t+3]<<24|e[t+2]<<16|e[t+1]<<8|e[t])>>>0}function writeUint32BE(e,t,n){return void 0===t&&(t=new Uint8Array(4)),void 0===n&&(n=0),t[n+0]=e>>>24,t[n+1]=e>>>16,t[n+2]=e>>>8,t[n+3]=e>>>0,t}function writeUint32LE(e,t,n){return void 0===t&&(t=new Uint8Array(4)),void 0===n&&(n=0),t[n+0]=e>>>0,t[n+1]=e>>>8,t[n+2]=e>>>16,t[n+3]=e>>>24,t}function writeUint64BE(e,t,n){return void 0===t&&(t=new Uint8Array(8)),void 0===n&&(n=0),writeUint32BE(e/4294967296>>>0,t,n),writeUint32BE(e>>>0,t,n+4),t}function writeUint64LE(e,t,n){return void 0===t&&(t=new Uint8Array(8)),void 0===n&&(n=0),writeUint32LE(e>>>0,t,n),writeUint32LE(e/4294967296>>>0,t,n+4),t}t.readInt16BE=function(e,t){return void 0===t&&(t=0),(e[t+0]<<8|e[t+1])<<16>>16},t.readUint16BE=function(e,t){return void 0===t&&(t=0),(e[t+0]<<8|e[t+1])>>>0},t.readInt16LE=function(e,t){return void 0===t&&(t=0),(e[t+1]<<8|e[t])<<16>>16},t.readUint16LE=function(e,t){return void 0===t&&(t=0),(e[t+1]<<8|e[t])>>>0},t.writeUint16BE=writeUint16BE,t.writeInt16BE=writeUint16BE,t.writeUint16LE=writeUint16LE,t.writeInt16LE=writeUint16LE,t.readInt32BE=readInt32BE,t.readUint32BE=readUint32BE,t.readInt32LE=readInt32LE,t.readUint32LE=readUint32LE,t.writeUint32BE=writeUint32BE,t.writeInt32BE=writeUint32BE,t.writeUint32LE=writeUint32LE,t.writeInt32LE=writeUint32LE,t.readInt64BE=function(e,t){void 0===t&&(t=0);var n=readInt32BE(e,t),o=readInt32BE(e,t+4);return 4294967296*n+o-(o>>31)*4294967296},t.readUint64BE=function(e,t){return void 0===t&&(t=0),4294967296*readUint32BE(e,t)+readUint32BE(e,t+4)},t.readInt64LE=function(e,t){void 0===t&&(t=0);var n=readInt32LE(e,t);return 4294967296*readInt32LE(e,t+4)+n-(n>>31)*4294967296},t.readUint64LE=function(e,t){void 0===t&&(t=0);var n=readUint32LE(e,t);return 4294967296*readUint32LE(e,t+4)+n},t.writeUint64BE=writeUint64BE,t.writeInt64BE=writeUint64BE,t.writeUint64LE=writeUint64LE,t.writeInt64LE=writeUint64LE,t.readUintBE=function(e,t,n){if(void 0===n&&(n=0),e%8!=0)throw Error("readUintBE supports only bitLengths divisible by 8");if(e/8>t.length-n)throw Error("readUintBE: array is too short for the given b
1itLength");for(var o=0,i=1,s=e/8+n-1;s>=n;s--)o+=t[s]*i,i*=256;return o},t.readUintLE=function(e,t,n){if(void 0===n&&(n=0),e%8!=0)throw Error("readUintLE supports only bitLengths divisible by 8");if(e/8>t.length-n)throw Error("readUintLE: array is too short for the given bitLength");for(var o=0,i=1,s=n;s<n+e/8;s++)o+=t[s]*i,i*=256;return o},t.writeUintBE=function(e,t,n,i){if(void 0===n&&(n=new Uint8Array(e/8)),void 0===i&&(i=0),e%8!=0)throw Error("writeUintBE supports only bitLengths divisible by 8");if(!o.isSafeInteger(t))throw Error("writeUintBE value must be an integer");for(var s=1,c=e/8+i-1;c>=i;c--)n[c]=t/s&255,s*=256;return n},t.writeUintLE=function(e,t,n,i){if(void 0===n&&(n=new Uint8Array(e/8)),void 0===i&&(i=0),e%8!=0)throw Error("writeUintLE supports only bitLengths divisible by 8");if(!o.isSafeInteger(t))throw Error("writeUintLE value must be an integer");for(var s=1,c=i;c<i+e/8;c++)n[c]=t/s&255,s*=256;return n},t.readFloat32BE=function(e,t){return void 0===t&&(t=0),new DataView(e.buffer,e.byteOffset,e.byteLength).getFloat32(t)},t.readFloat32LE=function(e,t){return void 0===t&&(t=0),new DataView(e.buffer,e.byteOffset,e.byteLength).getFloat32(t,!0)},t.readFloat64BE=function(e,t){return void 0===t&&(t=0),new DataView(e.buffer,e.byteOffset,e.byteLength).getFloat64(t)},t.readFloat64LE=function(e,t){return void 0===t&&(t=0),new DataView(e.buffer,e.byteOffset,e.byteLength).getFloat64(t,!0)},t.writeFloat32BE=function(e,t,n){return void 0===t&&(t=new Uint8Array(4)),void 0===n&&(n=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat32(n,e),t},t.writeFloat32LE=function(e,t,n){return void 0===t&&(t=new Uint8Array(4)),void 0===n&&(n=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat32(n,e,!0),t},t.writeFloat64BE=function(e,t,n){return void 0===t&&(t=new Uint8Array(8)),void 0===n&&(n=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat64(n,e),t},t.writeFloat64LE=function(e,t,n){return void 0===t&&(t=new Uint8Array(8)),void 0===n&&(n=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat64(n,e,!0),t}},25439:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(98099),i=n(17309);function streamXOR(e,t,n,s,c){if(void 0===c&&(c=0),32!==e.length)throw Error("ChaCha: key size must be 32 bytes");if(s.length<n.length)throw Error("ChaCha: destination is shorter than source");if(0===c){if(8!==t.length&&12!==t.length)throw Error("ChaCha nonce must be 8 or 12 bytes");u=(l=new Uint8Array(16)).length-t.length,l.set(t,u)}else{if(16!==t.length)throw Error("ChaCha nonce with counter must be 16 bytes");l=t,u=c}for(var l,u,d=new Uint8Array(64),p=0;p<n.length;p+=64){!function(e,t,n){for(var i=n[3]<<24|n[2]<<16|n[1]<<8|n[0],s=n[7]<<24|n[6]<<16|n[5]<<8|n[4],c=n[11]<<24|n[10]<<16|n[9]<<8|n[8],l=n[15]<<24|n[14]<<16|n[13]<<8|n[12],u=n[19]<<24|n[18]<<16|n[17]<<8|n[16],d=n[23]<<24|n[22]<<16|n[21]<<8|n[20],p=n[27]<<24|n[26]<<16|n[25]<<8|n[24],m=n[31]<<24|n[30]<<16|n[29]<<8|n[28],b=t[3]<<24|t[2]<<16|t[1]<<8|t[0],g=t[7]<<24|t[6]<<16|t[5]<<8|t[4],y=t[11]<<24|t[10]<<16|t[9]<<8|t[8],v=t[15]<<24|t[14]<<16|t[13]<<8|t[12],E=1634760805,x=857760878,P=2036477234,_=1797285236,I=i,j=s,R=c,M=l,F=u,q=d,H=p,z=m,W=b,K=g,Q=y,Z=v,X=0;X<20;X+=2)W^=E=E+I|0,I^=F=F+(W=W>>>16|W<<16)|0,I=I>>>20|I<<12,K^=x=x+j|0,j^=q=q+(K=K>>>16|K<<16)|0,j=j>>>20|j<<12,Q^=P=P+R|0,R^=H=H+(Q=Q>>>16|Q<<16)|0,R=R>>>20|R<<12,Z^=_=_+M|0,M^=z=z+(Z=Z>>>16|Z<<16)|0,M=M>>>20|M<<12,Q^=P=P+R|0,R^=H=H+(Q=Q>>>24|Q<<8)|0,R=R>>>25|R<<7,Z^=_=_+M|0,M^=z=z+(Z=Z>>>24|Z<<8)|0,M=M>>>25|M<<7,K^=x=x+j|0,j^=q=q+(K=K>>>24|K<<8)|0,j=j>>>25|j<<7,W^=E=E+I|0,I^=F=F+(W=W>>>24|W<<8)|0,I=I>>>25|I<<7,Z^=E=E+j|0,j^=H=H+(Z=Z>>>16|Z<<16)|0,j=j>>>20|j<<12,W^=x=x+R|0,R^=z=z+(W=W>>>16|W<<16)|0,R=R>>>20|R<<12,K^=P=P+M|0,M^=F=F+(K=K>>>16|K<<16)|0,M=M>>>20|M<<12,Q^=_=_+I|0,I^=q=q+(Q=Q>>>16|Q<<16)|0,I=I>>>20|I<<12,K^=P=P+M|0,M^=F=F+(K=K>>>24|K<<8)|0,M=M>>>25|M<<7,Q^=_=_+I|0,I^=q=q+(Q=Q>>>24|Q<<8)|0,I=I>>>25|I<<7,W^=x=x+R|0,R^=z=z+(W=W>>>24|W<<8)|0,R=R>>>25|R<<7,Z^=E=E+j|0,j^=H=H+(Z=Z>>>24|Z<<8)|0,j=j>>>25|j<<7;o.writeUint32LE(E+1634760805|0,e,0),o.writeUint32LE(x+857760878|0,e,4),o.writeUint32LE(P+2036477234|0,e,8),o.writeUint32LE(_+1797285236|0,e,12),o.writeUint32LE(I+i|0,e,16),o.writeUint32LE(j+s|0,e,20),o.writeUint32LE(R+c|0,e,24),o.writeUint32LE(M+l|0,e,28),o.writeUint32LE(F+u|0,e,32),o.writeUint32LE(q+d|0,e,36),o.writeUint32LE(H+p|0,e,40),o.writeUint32LE(z+m|0,e,44),o.writeUint32LE(W+b|0,e,48),o.writeUint32LE(K+g|0,e,52),o.writeUint32LE(Q+y|0,e,56),o.writeUint32LE(Z+v|0,e,60)}(d,l,e);for(var m=p;m<p+64&&m<n.length;m++)s[m]=n[m]^d[m-p];!function(e,t,n){for(var o=1;n--;)o=o+(255&e[t])|0,e[t]=255&o,o>>>=8,t++;if(o>0)throw Error("ChaCha: counter overflow")}(l,0,u)}return i.wipe(d),0===c&&i.wipe(l),s}t.streamXOR=streamXOR,t.stream=function(e,t,n,o){return void 0===o&&(o=0),i.wipe(n),streamXOR(e,t,n,n,o)}},15501:function(e,t,n){"use strict";var o=n(25439),i=n(63027),s=n(17309),c=n(98099),l=n(4153);t.Cv=32,t.WH=12,t.pg=16;var u=new Uint8Array(16),d=function(){function ChaCha20Poly1305(e){if(this.nonceLength=t.WH,this.tagLength=t.pg,e.length!==t.Cv)throw Error("ChaCha20Poly1305 needs 32-byte key");this._key=new Uint8Array(e)}return ChaCha20Poly1305.prototype.seal=function(e,t,n,i){if(e.length>16)throw Error("ChaCha20Poly1305: incorrect nonce length");var c,l=new Uint8Array(16);l.set(e,l.length-e.length);var u=new Uint8Array(32);o.stream(this._key,l,u,4);var d=t.length+this.tagLength;if(i){if(i.length!==d)throw Error("ChaCha20Poly1305: incorrect destination length");c=i}else c=new Uint8Array(d);return o.streamXOR(this._key,l,t,c,4),this._authenticate(c.subarray(c.length-this.tagLength,c.length),u,c.subarray(0,c.length-this.tagLength),n),s.wipe(l),c},ChaCha20Poly1305.prototype.open=function(e,t,n,i){if(e.length>16)throw Error("ChaCha20Poly1305: incorrect nonce length");if(t.length<this.tagLength)return null;var c,u=new Uint8Array(16);u.set(e,u.length-e.length);var d=new Uint8Array(32);o.stream(this._key,u,d,4);var p=new Uint8Array(this.tagLength);if(this._authenticate(p,d,t.subarray(0,t.length-this.tagLength),n),!l.equal(p,t.subarray(t.length-this.tagLength,t.length)))return null;var m=t.length-this.tagLength;if(i){if(i.length!==m)throw Error("ChaCha20Poly1305: incorrect destination length");c=i}else c=new Uint8Array(m);return o.streamXOR(this._key,u,t.subarray(0,t.length-this.tagLength),c,4),s.wipe(u),c},ChaCha20Poly1305.prototype.clean=function(){return s.wipe(this._key),this},ChaCha20Poly1305.prototype._authenticate=function(e,t,n,o){var l=new i.Poly1305(t);o&&(l.update(o),o.length%16>0&&l.update(u.subarray(o.length%16))),l.update(n),n.length%16>0&&l.update(u.subarray(n.length%16));var d=new Uint8Array(8);o&&c.writeUint64LE(o.length,d),l.update(d),c.writeUint64LE(n.length,d),l.update(d);for(var p=l.digest(),m=0;m<p.length;m++)e[m]=p[m];l.clean(),s.wipe(p),s.wipe(d)},ChaCha20Poly1305}();t.OK=d},4153:function(e,t){"use strict";function compare(e,t){if(e.length!==t.length)return 0;for(var n=0,o=0;o<e.length;o++)n|=e[o]^t[o];return 1&n-1>>>8}
1Object.defineProperty(t,"__esModule",{value:!0}),t.select=function(e,t,n){return~(e-1)&t|e-1&n},t.lessOrEqual=function(e,t){return(0|e)-(0|t)-1>>>31&1},t.compare=compare,t.equal=function(e,t){return 0!==e.length&&0!==t.length&&0!==compare(e,t)}},79984:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isSerializableHash=function(e){return void 0!==e.saveState&&void 0!==e.restoreState&&void 0!==e.cleanSavedState}},512:function(e,t,n){"use strict";var o=n(25629),i=n(17309),s=function(){function HKDF(e,t,n,i){void 0===n&&(n=new Uint8Array(0)),this._counter=new Uint8Array(1),this._hash=e,this._info=i;var s=o.hmac(this._hash,n,t);this._hmac=new o.HMAC(e,s),this._buffer=new Uint8Array(this._hmac.digestLength),this._bufpos=this._buffer.length}return HKDF.prototype._fillBuffer=function(){this._counter[0]++;var e=this._counter[0];if(0===e)throw Error("hkdf: cannot expand more");this._hmac.reset(),e>1&&this._hmac.update(this._buffer),this._info&&this._hmac.update(this._info),this._hmac.update(this._counter),this._hmac.finish(this._buffer),this._bufpos=0},HKDF.prototype.expand=function(e){for(var t=new Uint8Array(e),n=0;n<t.length;n++)this._bufpos===this._buffer.length&&this._fillBuffer(),t[n]=this._buffer[this._bufpos++];return t},HKDF.prototype.clean=function(){this._hmac.clean(),i.wipe(this._buffer),i.wipe(this._counter),this._bufpos=0},HKDF}();t.t=s},25629:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(79984),i=n(4153),s=n(17309),c=function(){function HMAC(e,t){this._finished=!1,this._inner=new e,this._outer=new e,this.blockSize=this._outer.blockSize,this.digestLength=this._outer.digestLength;var n=new Uint8Array(this.blockSize);t.length>this.blockSize?this._inner.update(t).finish(n).clean():n.set(t);for(var i=0;i<n.length;i++)n[i]^=54;this._inner.update(n);for(var i=0;i<n.length;i++)n[i]^=106;this._outer.update(n),o.isSerializableHash(this._inner)&&o.isSerializableHash(this._outer)&&(this._innerKeyedState=this._inner.saveState(),this._outerKeyedState=this._outer.saveState()),s.wipe(n)}return HMAC.prototype.reset=function(){if(!o.isSerializableHash(this._inner)||!o.isSerializableHash(this._outer))throw Error("hmac: can't reset() because hash doesn't implement restoreState()");return this._inner.restoreState(this._innerKeyedState),this._outer.restoreState(this._outerKeyedState),this._finished=!1,this},HMAC.prototype.clean=function(){o.isSerializableHash(this._inner)&&this._inner.cleanSavedState(this._innerKeyedState),o.isSerializableHash(this._outer)&&this._outer.cleanSavedState(this._outerKeyedState),this._inner.clean(),this._outer.clean()},HMAC.prototype.update=function(e){return this._inner.update(e),this},HMAC.prototype.finish=function(e){return this._finished?this._outer.finish(e):(this._inner.finish(e),this._outer.update(e.subarray(0,this.digestLength)).finish(e),this._finished=!0),this},HMAC.prototype.digest=function(){var e=new Uint8Array(this.digestLength);return this.finish(e),e},HMAC.prototype.saveState=function(){if(!o.isSerializableHash(this._inner))throw Error("hmac: can't saveState() because hash doesn't implement it");return this._inner.saveState()},HMAC.prototype.restoreState=function(e){if(!o.isSerializableHash(this._inner)||!o.isSerializableHash(this._outer))throw Error("hmac: can't restoreState() because hash doesn't implement it");return this._inner.restoreState(e),this._outer.restoreState(this._outerKeyedState),this._finished=!1,this},HMAC.prototype.cleanSavedState=function(e){if(!o.isSerializableHash(this._inner))throw Error("hmac: can't cleanSavedState() because hash doesn't implement it");this._inner.cleanSavedState(e)},HMAC}();t.HMAC=c,t.hmac=function(e,t,n){var o=new c(e,t);o.update(n);var i=o.digest();return o.clean(),i},t.equal=i.equal},97117:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mul=Math.imul||function(e,t){var n=65535&e,o=65535&t;return n*o+((e>>>16&65535)*o+n*(t>>>16&65535)<<16>>>0)|0},t.add=function(e,t){return e+t|0},t.sub=function(e,t){return e-t|0},t.rotl=function(e,t){return e<<t|e>>>32-t},t.rotr=function(e,t){return e<<32-t|e>>>t},t.isInteger=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},t.MAX_SAFE_INTEGER=9007199254740991,t.isSafeInteger=function(e){return t.isInteger(e)&&e>=-t.MAX_SAFE_INTEGER&&e<=t.MAX_SAFE_INTEGER}},63027:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var o=n(4153),i=n(17309);t.DIGEST_LENGTH=16;var s=function(){function Poly1305(e){this.digestLength=t.DIGEST_LENGTH,this._buffer=new Uint8Array(16),this._r=new Uint16Array(10),this._h=new Uint16Array(10),this._pad=new Uint16Array(8),this._leftover=0,this._fin=0,this._finished=!1;var n=e[0]|e[1]<<8;this._r[0]=8191&n;var o=e[2]|e[3]<<8;this._r[1]=(n>>>13|o<<3)&8191;var i=e[4]|e[5]<<8;this._r[2]=(o>>>10|i<<6)&7939;var s=e[6]|e[7]<<8;this._r[3]=(i>>>7|s<<9)&8191;var c=e[8]|e[9]<<8;this._r[4]=(s>>>4|c<<12)&255,this._r[5]=c>>>1&8190;var l=e[10]|e[11]<<8;this._r[6]=(c>>>14|l<<2)&8191;var u=e[12]|e[13]<<8;this._r[7]=(l>>>11|u<<5)&8065;var d=e[14]|e[15]<<8;this._r[8]=(u>>>8|d<<8)&8191,this._r[9]=d>>>5&127,this._pad[0]=e[16]|e[17]<<8,this._pad[1]=e[18]|e[19]<<8,this._pad[2]=e[20]|e[21]<<8,this._pad[3]=e[22]|e[23]<<8,this._pad[4]=e[24]|e[25]<<8,this._pad[5]=e[26]|e[27]<<8,this._pad[6]=e[28]|e[29]<<8,this._pad[7]=e[30]|e[31]<<8}return Poly1305.prototype._blocks=function(e,t,n){for(var o=this._fin?0:2048,i=this._h[0],s=this._h[1],c=this._h[2],l=this._h[3],u=this._h[4],d=this._h[5],p=this._h[6],m=this._h[7],b=this._h[8],g=this._h[9],y=this._r[0],v=this._r[1],E=this._r[2],x=this._r[3],P=this._r[4],_=this._r[5],I=this._r[6],j=this._r[7],R=this._r[8],M=this._r[9];n>=16;){var F,q=e[t+0]|e[t+1]<<8;i+=8191&q;var H=e[t+2]|e[t+3]<<8;s+=(q>>>13|H<<3)&8191;var z=e[t+4]|e[t+5]<<8;c+=(H>>>10|z<<6)&8191;var W=e[t+6]|e[t+7]<<8;l+=(z>>>7|W<<9)&8191;var K=e[t+8]|e[t+9]<<8;u+=(W>>>4|K<<12)&8191,d+=K>>>1&8191;var Q=e[t+10]|e[t+11]<<8;p+=(K>>>14|Q<<2)&8191;var Z=e[t+12]|e[t+13]<<8;m+=(Q>>>11|Z<<5)&8191;var X=e[t+14]|e[t+15]<<8;b+=(Z>>>8|X<<8)&8191,g+=X>>>5|o;var Y=0;Y=(F=0+i*y+s*(5*M)+c*(5*R)+l*(5*j)+u*(5*I))>>>13,F&=8191,F+=d*(5*_)+p*(5*P)+m*(5*x)+b*(5*E)+g*(5*v),Y+=F>>>13,F&=8191;var J=Y;J+=i*v+s*y+c*(5*M)+l*(5*R)+u*(5*j),Y=J>>>13,J&=8191,J+=d*(5*I)+p*(5*_)+m*(5*P)+b*(5*x)+g*(5*E),Y+=J>>>13,J&=8191;var et=Y;et+=i*E+s*v+c*y+l*(5*M)+u*(5*R),Y=et>>>13,et&=8191,et+=d*(5*j)+p*(5*I)+m*(5*_)+b*(5*P)+g*(5*x),Y+=et>>>13,et&=8191;var eo=Y;eo+=i*x+s*E+c*v+l*y+u*(5*M),Y=eo>>>13,eo&=8191,eo+=d*(5*R)+p*(5*j)+m*(5*I)+b*(5*_)+g*(5*P),Y+=eo>>>13,eo&=8191;var ea=Y;ea+=i*P+s*x+c*E+l*v+u*y,Y=ea>>>13,ea&=8191,ea+=d*(5*M)+p*(5*R)+m*(5*j)+b*(5*I)+g*(5*_),Y+=ea>>>13,ea&=8191;var ei=Y;ei+=i*_+s*P+c*x+l*E+u*v,Y=ei>>>13,ei&=8191,ei+=d*y+p*(5*M)+m*(5*R)+b*(5*j)+g*(5*I),Y+=ei>>>13,ei&=8191;var es=Y;es+=i*I+s*_+c*P+l*x+u*E,Y=es>>>13,es&=8191,es+=d*v+p*y+m*(5*M)+b*(5*R)+g*(5*j),Y+=es>>>13,es&=8191;var ec=Y;ec+=i*j+s*I+c*_+l*P+u*x,Y=ec>>>13,ec&=8191,ec+=d*E+p*v+m*y+b*(5*M)+g*(5*R),Y+=ec>>>13,ec&=8191;var el=Y;el+=i*R+s*j+c*I+l*_+u*P,Y=el>>>13,el&=8191,el+=d*x+p*E+m*v+b*y+g*(5*M),Y+=el>>>13,el&=8191;var eu=Y;eu+=i*M+s*R+c*j+l*I+u*_,Y=eu>>>13,eu&=8191,eu+=d*P+p*x+m*E+b*v+g*y,Y+=eu>>>13,eu&=8191,F=8191&(Y=(Y=(Y<<2)+Y|0)+F|0),Y>>>=13,J+=Y,i=F,s=J,c=et,l=eo,u=ea,d=ei,p=es,m=ec,b=el,g=eu,t+=16,n-=16}this._h[0]=i,this._h[1]=s,this._h[2]=c,this._h[3]=l,this._h[4]=u,this._h[5]=d,this._h[6]=p,this._h[7]=m,this._h[8]=b,this._h[9]=g},Poly1305.prototype.finish=function(e,t){void 0===t&&(t=0);var n,o,i,s,c=new Uint16Array(10);if(this._leftover){for(s=this._leftover,this._buffer[s++]=1;s<16;s++)this._buffer[s]=0;this._fin=1,this._blocks(this._buffer,0,16)}for(n=this._h[1]>>>13,this._h[1]&=8191,s=2;s<10;s++)this._h[s]+=n,n=this._h[s]>>>13,this._h[s]&=8191;for(this._h[0]+=5*n,n=this._h[0]>>>13,this._h[0]&=8191,this._h[1]+=n,n=this._h[1]>>>13,this._h[1]&=8191,this._h[2]+=n,c[0]=this._h[0]+5,n=c[0]>>>13,c[0]&=8191,s=1;s<10;s++)c[s]=this._h[s]+n,n=c[s]>>>13,c[s]&=8191;for(c[9]-=8192,o=(1^n)-1,s=0;s<10;s++)c[s]&=o;for(s=0,o=~o;s<10;s++)this._h[s]=this._h[s]&o|c[s];for(s=1,this._h[0]=(this._h[0]|this._h[1]<<13)&65535,this._h[1]=(this._h[1]>>>3|this._h[2]<<10)&65535,this._h[2]=(this._h[2]>>>6|this._h[3]<<7)&65535,this._h[3]=(this._h[3]>>>9|this._h[4]<<4)&65535,this._h[4]=(this._h[4]>>>12|this._h[5]<<1|this._h[6]<<14)&65535,this._h[5]=(this._h[6]>>>2|this._h[7]<<11)&65535,this._h[6]=(this._h[7]>>>5|this._h[8]<<8)&65535,this._h[7]=(this._h[8]>>>8|this._h[9]<<5)&65535,i=this._h[0]+this._pad[0],this._h[0]=65535&i;s<8;s++)i=(this._h[s]+this._pad[s]|0)+(i>>>16)|0,this._h[s]=65535&i;return e[t+0]=this._h[0]>>>
10,e[t+1]=this._h[0]>>>8,e[t+2]=this._h[1]>>>0,e[t+3]=this._h[1]>>>8,e[t+4]=this._h[2]>>>0,e[t+5]=this._h[2]>>>8,e[t+6]=this._h[3]>>>0,e[t+7]=this._h[3]>>>8,e[t+8]=this._h[4]>>>0,e[t+9]=this._h[4]>>>8,e[t+10]=this._h[5]>>>0,e[t+11]=this._h[5]>>>8,e[t+12]=this._h[6]>>>0,e[t+13]=this._h[6]>>>8,e[t+14]=this._h[7]>>>0,e[t+15]=this._h[7]>>>8,this._finished=!0,this},Poly1305.prototype.update=function(e){var t,n=0,o=e.length;if(this._leftover){(t=16-this._leftover)>o&&(t=o);for(var i=0;i<t;i++)this._buffer[this._leftover+i]=e[n+i];if(o-=t,n+=t,this._leftover+=t,this._leftover<16)return this;this._blocks(this._buffer,0,16),this._leftover=0}if(o>=16&&(t=o-o%16,this._blocks(e,n,t),n+=t,o-=t),o){for(var i=0;i<o;i++)this._buffer[this._leftover+i]=e[n+i];this._leftover+=o}return this},Poly1305.prototype.digest=function(){if(this._finished)throw Error("Poly1305 was finished");var e=new Uint8Array(16);return this.finish(e),e},Poly1305.prototype.clean=function(){return i.wipe(this._buffer),i.wipe(this._r),i.wipe(this._h),i.wipe(this._pad),this._leftover=0,this._fin=0,this._finished=!0,this},Poly1305}();t.Poly1305=s,t.oneTimeAuth=function(e,t){var n=new s(e);n.update(t);var o=n.digest();return n.clean(),o},t.equal=function(e,n){return e.length===t.DIGEST_LENGTH&&n.length===t.DIGEST_LENGTH&&o.equal(e,n)}},31416:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomStringForEntropy=t.randomString=t.randomUint32=t.randomBytes=t.defaultRandomSource=void 0;let o=n(46008),i=n(98099),s=n(17309);function randomBytes(e,n=t.defaultRandomSource){return n.randomBytes(e)}t.defaultRandomSource=new o.SystemRandomSource,t.randomBytes=randomBytes,t.randomUint32=function(e=t.defaultRandomSource){let n=randomBytes(4,e),o=(0,i.readUint32LE)(n);return(0,s.wipe)(n),o};let c="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";function randomString(e,n=c,o=t.defaultRandomSource){if(n.length<2)throw Error("randomString charset is too short");if(n.length>256)throw Error("randomString charset is too long");let i="",l=n.length,u=256-256%l;for(;e>0;){let t=randomBytes(Math.ceil(256*e/u),o);for(let o=0;o<t.length&&e>0;o++){let s=t[o];s<u&&(i+=n.charAt(s%l),e--)}(0,s.wipe)(t)}return i}t.randomString=randomString,t.randomStringForEntropy=function(e,n=c,o=t.defaultRandomSource){let i=Math.ceil(e/(Math.log(n.length)/Math.LN2));return randomString(i,n,o)}},75455:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BrowserRandomSource=void 0,t.BrowserRandomSource=class{constructor(){this.isAvailable=!1,this.isInstantiated=!1;let e="undefined"!=typeof self?self.crypto||self.msCrypto:null;e&&void 0!==e.getRandomValues&&(this._crypto=e,this.isAvailable=!0,this.isInstantiated=!0)}randomBytes(e){if(!this.isAvailable||!this._crypto)throw Error("Browser random byte generator is not available.");let t=new Uint8Array(e);for(let e=0;e<t.length;e+=65536)this._crypto.getRandomValues(t.subarray(e,e+Math.min(t.length-e,65536)));return t}}},58871:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeRandomSource=void 0;let o=n(17309);t.NodeRandomSource=class{constructor(){this.isAvailable=!1,this.isInstantiated=!1;{let e=n(35883);e&&e.randomBytes&&(this._crypto=e,this.isAvailable=!0,this.isInstantiated=!0)}}randomBytes(e){if(!this.isAvailable||!this._crypto)throw Error("Node.js random byte generator is not available.");let t=this._crypto.randomBytes(e);if(t.length!==e)throw Error("NodeRandomSource: got fewer bytes than requested");let n=new Uint8Array(e);for(let e=0;e<n.length;e++)n[e]=t[e];return(0,o.wipe)(t),n}}},46008:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SystemRandomSource=void 0;let o=n(75455),i=n(58871);t.SystemRandomSource=class{constructor(){if(this.isAvailable=!1,this.name="",this._source=new o.BrowserRandomSource,this._source.isAvailable){this.isAvailable=!0,this.name="Browser";return}if(this._source=new i.NodeRandomSource,this._source.isAvailable){this.isAvailable=!0,this.name="Node";return}}randomBytes(e){if(!this.isAvailable)throw Error("System random byte generator is not available.");return this._source.randomBytes(e)}}},73294:function(e,t,n){"use strict";var o=n(98099),i=n(17309);t.k=32,t.cn=64;var s=function(){function SHA256(){this.digestLength=t.k,this.blockSize=t.cn,this._state=new Int32Array(8),this._temp=new Int32Array(64),this._buffer=new Uint8Array(128),this._bufferLength=0,this._bytesHashed=0,this._finished=!1,this.reset()}return SHA256.prototype._initState=function(){this._state[0]=1779033703,this._state[1]=3144134277,this._state[2]=1013904242,this._state[3]=2773480762,this._state[4]=1359893119,this._state[5]=2600822924,this._state[6]=528734635,this._state[7]=1541459225},SHA256.prototype.reset=function(){return this._initState(),this._bufferLength=0,this._bytesHashed=0,this._finished=!1,this},SHA256.prototype.clean=function(){i.wipe(this._buffer),i.wipe(this._temp),this.reset()},SHA256.prototype.update=function(e,t){if(void 0===t&&(t=e.length),this._finished)throw Error("SHA256: can't update because hash was finished.");var n=0;if(this._bytesHashed+=t,this._bufferLength>0){for(;this._bufferLength<this.blockSize&&t>0;)this._buffer[this._bufferLength++]=e[n++],t--;this._bufferLength===this.blockSize&&(hashBlocks(this._temp,this._state,this._buffer,0,this.blockSize),this._bufferLength=0)}for(t>=this.blockSize&&(n=hashBlocks(this._temp,this._state,e,n,t),t%=this.blockSize);t>0;)this._buffer[this._bufferLength++]=e[n++],t--;return this},SHA256.prototype.finish=function(e){if(!this._finished){var t=this._bytesHashed,n=this._bufferLength,i=t%64
1<56?64:128;this._buffer[n]=128;for(var s=n+1;s<i-8;s++)this._buffer[s]=0;o.writeUint32BE(t/536870912|0,this._buffer,i-8),o.writeUint32BE(t<<3,this._buffer,i-4),hashBlocks(this._temp,this._state,this._buffer,0,i),this._finished=!0}for(var s=0;s<this.digestLength/4;s++)o.writeUint32BE(this._state[s],e,4*s);return this},SHA256.prototype.digest=function(){var e=new Uint8Array(this.digestLength);return this.finish(e),e},SHA256.prototype.saveState=function(){if(this._finished)throw Error("SHA256: cannot save finished state");return{state:new Int32Array(this._state),buffer:this._bufferLength>0?new Uint8Array(this._buffer):void 0,bufferLength:this._bufferLength,bytesHashed:this._bytesHashed}},SHA256.prototype.restoreState=function(e){return this._state.set(e.state),this._bufferLength=e.bufferLength,e.buffer&&this._buffer.set(e.buffer),this._bytesHashed=e.bytesHashed,this._finished=!1,this},SHA256.prototype.cleanSavedState=function(e){i.wipe(e.state),e.buffer&&i.wipe(e.buffer),e.bufferLength=0,e.bytesHashed=0},SHA256}();t.mE=s;var c=new Int32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]);function hashBlocks(e,t,n,i,s){for(;s>=64;){for(var l=t[0],u=t[1],d=t[2],p=t[3],m=t[4],b=t[5],g=t[6],y=t[7],v=0;v<16;v++){var E=i+4*v;e[v]=o.readUint32BE(n,E)}for(var v=16;v<64;v++){var x=e[v-2],P=(x>>>17|x<<15)^(x>>>19|x<<13)^x>>>10,_=((x=e[v-15])>>>7|x<<25)^(x>>>18|x<<14)^x>>>3;e[v]=(P+e[v-7]|0)+(_+e[v-16]|0)}for(var v=0;v<64;v++){var P=(((m>>>6|m<<26)^(m>>>11|m<<21)^(m>>>25|m<<7))+(m&b^~m&g)|0)+(y+(c[v]+e[v]|0)|0)|0,_=((l>>>2|l<<30)^(l>>>13|l<<19)^(l>>>22|l<<10))+(l&u^l&d^u&d)|0;y=g,g=b,b=m,m=p+P|0,p=d,d=u,u=l,l=P+_|0}t[0]+=l,t[1]+=u,t[2]+=d,t[3]+=p,t[4]+=m,t[5]+=b,t[6]+=g,t[7]+=y,i+=64,s-=64}return i}t.vp=function(e){var t=new s;t.update(e);var n=t.digest();return t.clean(),n}},17309:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wipe=function(e){for(var t=0;t<e.length;t++)e[t]=0;return e}},57664:function(e,t,n){"use strict";t.gi=t.Au=t.KS=t.kz=void 0;let o=n(31416),i=n(17309);function gf(e){let t=new Float64Array(16);if(e)for(let n=0;n<e.length;n++)t[n]=e[n];return t}t.kz=32,t.KS=32;let s=new Uint8Array(32);s[0]=9;let c=gf([56129,1]);function car25519(e){let t=1;for(let n=0;n<16;n++){let o=e[n]+t+65535;t=Math.floor(o/65536),e[n]=o-65536*t}e[0]+=t-1+37*(t-1)}function sel25519(e,t,n){let o=~(n-1);for(let n=0;n<16;n++){let i=o&(e[n]^t[n]);e[n]^=i,t[n]^=i}}function add(e,t,n){for(let o=0;o<16;o++)e[o]=t[o]+n[o]}function sub(e,t,n){for(let o=0;o<16;o++)e[o]=t[o]-n[o]}function mul(e,t,n){let o,i,s=0,c=0,l=0,u=0,d=0,p=0,m=0,b=0,g=0,y=0,v=0,E=0,x=0,P=0,_=0,I=0,j=0,R=0,M=0,F=0,q=0,H=0,z=0,W=0,K=0,Q=0,Z=0,X=0,Y=0,J=0,et=0,eo=n[0],ea=n[1],ei=n[2],es=n[3],ec=n[4],el=n[5],eu=n[6],ed=n[7],ef=n[8],ep=n[9],eh=n[10],em=n[11],eb=n[12],eg=n[13],ey=n[14],ev=n[15];s+=(o=t[0])*eo,c+=o*ea,l+=o*ei,u+=o*es,d+=o*ec,p+=o*el,m+=o*eu,b+=o*ed,g+=o*ef,y+=o*ep,v+=o*eh,E+=o*em,x+=o*eb,P+=o*eg,_+=o*ey,I+=o*ev,c+=(o=t[1])*eo,l+=o*ea,u+=o*ei,d+=o*es,p+=o*ec,m+=o*el,b+=o*eu,g+=o*ed,y+=o*ef,v+=o*ep,E+=o*eh,x+=o*em,P+=o*eb,_+=o*eg,I+=o*ey,j+=o*ev,l+=(o=t[2])*eo,u+=o*ea,d+=o*ei,p+=o*es,m+=o*ec,b+=o*el,g+=o*eu,y+=o*ed,v+=o*ef,E+=o*ep,x+=o*eh,P+=o*em,_+=o*eb,I+=o*eg,j+=o*ey,R+=o*ev,u+=(o=t[3])*eo,d+=o*ea,p+=o*ei,m+=o*es,b+=o*ec,g+=o*el,y+=o*eu,v+=o*ed,E+=o*ef,x+=o*ep,P+=o*eh,_+=o*em,I+=o*eb,j+=o*eg,R+=o*ey,M+=o*ev,d+=(o=t[4])*eo,p+=o*ea,m+=o*ei,b+=o*es,g+=o*ec,y+=o*el,v+=o*eu,E+=o*ed,x+=o*ef,P+=o*ep,_+=o*eh,I+=o*em,j+=o*eb,R+=o*eg,M+=o*ey,F+=o*ev,p+=(o=t[5])*eo,m+=o*ea,b+=o*ei,g+=o*es,y+=o*ec,v+=o*el,E+=o*eu,x+=o*ed,P+=o*ef,_+=o*ep,I+=o*eh,j+=o*em,R+=o*eb,M+=o*eg,F+=o*ey,q+=o
1*ev,m+=(o=t[6])*eo,b+=o*ea,g+=o*ei,y+=o*es,v+=o*ec,E+=o*el,x+=o*eu,P+=o*ed,_+=o*ef,I+=o*ep,j+=o*eh,R+=o*em,M+=o*eb,F+=o*eg,q+=o*ey,H+=o*ev,b+=(o=t[7])*eo,g+=o*ea,y+=o*ei,v+=o*es,E+=o*ec,x+=o*el,P+=o*eu,_+=o*ed,I+=o*ef,j+=o*ep,R+=o*eh,M+=o*em,F+=o*eb,q+=o*eg,H+=o*ey,z+=o*ev,g+=(o=t[8])*eo,y+=o*ea,v+=o*ei,E+=o*es,x+=o*ec,P+=o*el,_+=o*eu,I+=o*ed,j+=o*ef,R+=o*ep,M+=o*eh,F+=o*em,q+=o*eb,H+=o*eg,z+=o*ey,W+=o*ev,y+=(o=t[9])*eo,v+=o*ea,E+=o*ei,x+=o*es,P+=o*ec,_+=o*el,I+=o*eu,j+=o*ed,R+=o*ef,M+=o*ep,F+=o*eh,q+=o*em,H+=o*eb,z+=o*eg,W+=o*ey,K+=o*ev,v+=(o=t[10])*eo,E+=o*ea,x+=o*ei,P+=o*es,_+=o*ec,I+=o*el,j+=o*eu,R+=o*ed,M+=o*ef,F+=o*ep,q+=o*eh,H+=o*em,z+=o*eb,W+=o*eg,K+=o*ey,Q+=o*ev,E+=(o=t[11])*eo,x+=o*ea,P+=o*ei,_+=o*es,I+=o*ec,j+=o*el,R+=o*eu,M+=o*ed,F+=o*ef,q+=o*ep,H+=o*eh,z+=o*em,W+=o*eb,K+=o*eg,Q+=o*ey,Z+=o*ev,x+=(o=t[12])*eo,P+=o*ea,_+=o*ei,I+=o*es,j+=o*ec,R+=o*el,M+=o*eu,F+=o*ed,q+=o*ef,H+=o*ep,z+=o*eh,W+=o*em,K+=o*eb,Q+=o*eg,Z+=o*ey,X+=o*ev,P+=(o=t[13])*eo,_+=o*ea,I+=o*ei,j+=o*es,R+=o*ec,M+=o*el,F+=o*eu,q+=o*ed,H+=o*ef,z+=o*ep,W+=o*eh,K+=o*em,Q+=o*eb,Z+=o*eg,X+=o*ey,Y+=o*ev,_+=(o=t[14])*eo,I+=o*ea,j+=o*ei,R+=o*es,M+=o*ec,F+=o*el,q+=o*eu,H+=o*ed,z+=o*ef,W+=o*ep,K+=o*eh,Q+=o*em,Z+=o*eb,X+=o*eg,Y+=o*ey,J+=o*ev,I+=(o=t[15])*eo,j+=o*ea,R+=o*ei,M+=o*es,F+=o*ec,q+=o*el,H+=o*eu,z+=o*ed,W+=o*ef,K+=o*ep,Q+=o*eh,Z+=o*em,X+=o*eb,Y+=o*eg,J+=o*ey,et+=o*ev,s+=38*j,c+=38*R,l+=38*M,u+=38*F,d+=38*q,p+=38*H,m+=38*z,b+=38*W,g+=38*K,y+=38*Q,v+=38*Z,E+=38*X,x+=38*Y,P+=38*J,_+=38*et,i=Math.floor((o=s+(i=1)+65535)/65536),s=o-65536*i,i=Math.floor((o=c+i+65535)/65536),c=o-65536*i,i=Math.floor((o=l+i+65535)/65536),l=o-65536*i,i=Math.floor((o=u+i+65535)/65536),u=o-65536*i,i=Math.floor((o=d+i+65535)/65536),d=o-65536*i,i=Math.floor((o=p+i+65535)/65536),p=o-65536*i,i=Math.floor((o=m+i+65535)/65536),m=o-65536*i,i=Math.floor((o=b+i+65535)/65536),b=o-65536*i,i=Math.floor((o=g+i+65535)/65536),g=o-65536*i,i=Math.floor((o=y+i+65535)/65536),y=o-65536*i,i=Math.floor((o=v+i+65535)/65536),v=o-65536*i,i=Math.floor((o=E+i+65535)/65536),E=o-65536*i,i=Math.floor((o=x+i+65535)/65536),x=o-65536*i,i=Math.floor((o=P+i+65535)/65536),P=o-65536*i,i=Math.floor((o=_+i+65535)/65536),_=o-65536*i,i=Math.floor((o=I+i+65535)/65536),I=o-65536*i,s+=i-1+37*(i-1),i=Math.floor((o=s+(i=1)+65535)/65536),s=o-65536*i,i=Math.floor((o=c+i+65535)/65536),c=o-65536*i,i=Math.floor((o=l+i+65535)/65536),l=o-65536*i,i=Math.floor((o=u+i+65535)/65536),u=o-65536*i,i=Math.floor((o=d+i+65535)/65536),d=o-65536*i,i=Math.floor((o=p+i+65535)/65536),p=o-65536*i,i=Math.floor((o=m+i+65535)/65536),m=o-65536*i,i=Math.floor((o=b+i+65535)/65536),b=o-65536*i,i=Math.floor((o=g+i+65535)/65536),g=o-65536*i,i=Math.floor((o=y+i+65535)/65536),y=o-65536*i,i=Math.floor((o=v+i+65535)/65536),v=o-65536*i,i=Math.floor((o=E+i+65535)/65536),E=o-65536*i,i=Math.floor((o=x+i+65535)/65536),x=o-65536*i,i=Math.floor((o=P+i+65535)/65536),P=o-65536*i,i=Math.floor((o=_+i+65535)/65536),_=o-65536*i,i=Math.floor((o=I+i+65535)/65536),I=o-65536*i,s+=i-1+37*(i-1),e[0]=s,e[1]=c,e[2]=l,e[3]=u,e[4]=d,e[5]=p,e[6]=m,e[7]=b,e[8]=g,e[9]=y,e[10]=v,e[11]=E,e[12]=x,e[13]=P,e[14]=_,e[15]=I}function scalarMult(e,t){let n=new Uint8Array(32),o=new Float64Array(80),i=gf(),s=gf(),l=gf(),u=gf(),d=gf(),p=gf();for(let t=0;t<31;t++)n[t]=e[t];n[31]=127&e[31]|64,n[0]&=248,function(e,t){for(let n=0;n<16;n++)e[n]=t[2*n]+(t[2*n+1]<<8);e[15]&=32767}(o,t);for(let e=0;e<16;e++)s[e]=o[e];i[0]=u[0]=1;for(let e=254;e>=0;--e){let t=n[e>>>3]>>>(7&e)&1;sel25519(i,s,t),sel25519(l,u,t),add(d,i,l),sub(i,i,l),add(l,s,u),sub(s,s,u),mul(u,d,d),mul(p,i,i),mul(i,l,i),mul(l,s,d),add(d,i,l),sub(i,i,l),mul(s,i,i),sub(l,u,p),mul(i,l,c),add(i,i,u),mul(l,l,i),mul(i,u,p),mul(u,s,o),mul(s,d,d),sel25519(i,s,t),sel25519(l,u,t)}for(let e=0;e<16;e++)o[e+16]=i[e],o[e+32]=l[e],o[e+48]=s[e],o[e+64]=u[e];let m=o.subarray(32),b=o.subarray(16);!function(e,t){let n=gf();for(let e=0;e<16;e++)n[e]=t[e];for(let e=253;e>=0;e--)mul(n,n,n),2!==e&&4!==e&&mul(n,n,t);for(let t=0;t<16;t++)e[t]=n[t]}(m,m),mul(b,b,m);let g=new Uint8Array(32);return!function(e,t){let n=gf(),o=gf();for(let e=0;e<16;e++)o[e]=t[e];car25519(o),car25519(o),car25519(o);for(let e=0;e<2;e++){n[0]=o[0]-65517;for(let e=1;e<15;e++)n[e]=o[e]-65535-(n[e-1]>>16&1),n[e-1]&=65535;n[15]=o[15]-32767-(n[14]>>16&1);let e=n[15]>>16&1;n[14]&=65535,sel25519(o,n,1-e)}for(let t=0;t<16;t++)e[2*t]=255&o[t],e[2*t+1]=o[t]>>8}(g,b),g}t.Au=function(e){let n=(0,o.randomBytes)(32,e),c=function(e){if(e.length!==t.KS)throw Error(`x25519: seed must be ${t.KS} bytes`);let n=new Uint8Array(e),o=scalarMult(n,s);return{publicKey:o,secretKey:n}}(n);return(0,i.wipe)(n),c},t.gi=function(e,n,o=!1){if(e.length!==t.kz)throw Error("X25519: incorrect secret key length");if(n.length!==t.kz)throw Error("X25519: incorrect public key length");let i=scalarMult(e,n);if(o){let e=0;for(let t=0;t<i.length;t++)e|=i[t];if(0===e)throw Error("X25519: invalid shared key")}return i}},61882:function(){},36900:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});let o=n(30004);o.__exportStar(n(46869),t),o.__exportStar(n(88033),t)},46869:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ONE_THOUSAND=t.ONE_HUNDRED=void 0,t.ONE_HUNDRED=100,t.ONE_THOUSAND=1e3},88033:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ONE_YEAR=t.FOUR_WEEKS=t.THREE_WEEKS=t.TWO_WEEKS=t.ONE_WEEK=t.THIRTY_DAYS=t.SEVEN_DAYS=t.FIVE_DAYS=t.THREE_DAYS=t.ONE_DAY=t.TWENTY_FOUR_HOURS=t.TWELVE_HOURS=t.SIX_HOURS=t.THREE_HOURS=t.ONE_HOUR=t.SIXTY_MINUTES=t.THIRTY_MINUTES=t.TEN_MINUTES=t.FIVE_MINUTES=t.ONE_MINUTE=t.SIXTY_SECONDS=t.THIRTY_SECONDS=t.TEN_SECONDS=t.FIVE_SECONDS=t.ONE_SECOND=void 0,t.ONE_SECOND=1,t.FIVE_SECONDS=5,t.TEN_SECONDS=10,t.THIRTY_SECONDS=30,t.SIXTY_SECONDS=60,t.ONE_MINUTE=t.SIXTY_SECONDS,t.FIVE_MINUTES=5*t.ONE_MINUTE,t.TEN_MINUTES=10*t.ONE_MINUTE,t.THIRTY_MINUTES=30*t.ONE_MINUTE,t.SIXTY_MINUTES=60*t.ONE_MINUTE,t.ONE_HOUR=t.SIXTY_MINUTES,t.THREE_HOURS=3*t.ONE_HOUR,t.SIX_HOURS=6*t.ONE_HOUR,t.TWELVE_HOURS=12*t.ONE_HOUR,t.TWENTY_FOUR_HOURS=24*t.ONE_HOUR,t.ONE_DAY=t.TWENTY_FOUR_HOURS,t.THREE_DAYS=3*t.ONE_DAY,t.FIVE_DAYS=5*t.ONE_DAY,t.SEVEN_DAYS=7*t.ONE_DAY,t.THIRTY_DAYS=30*t.ONE_DAY,t.ONE_WEEK=t.SEVEN_DAYS,t.TWO_WEEKS=2*t.ONE_WEEK,t.THREE_WEEKS=3*t.ONE_WEEK,t.FOUR_WEEKS=4*t.ONE_WEEK,t.ONE_YEAR=365*t.ONE_DAY},66736:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let o=n(30004);o.__exportStar(n(44273),t),o.__exportStar(n(47001),t),o.__exportStar(n(52939),t),o.__exportStar(n(36900),t)},52939:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let o=n(30004);o.__exportStar(n(88766),t)},88766:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IWatch=void 0,t.IWatch=class{}},83207:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.fromMiliseconds=t.toMiliseconds=void 0;let o=n(36900);t.toMiliseconds=function(e){return e*o.ONE_THOUSAND},t.fromMiliseconds=function(e){return Math.floor(e/o.ONE_THOUSAND)}},83873:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.delay=void 0,t.delay=function(e){return new Promise(t=>{setTimeout(()=>{t(!0)},e)})}},44273:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let o=n(30004);o.__exportStar(n(83873),t),o.__exportStar(n(83207),t)},47001:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Watch=void 0;let Watch=class Watch{constructor(){this.timestamps=new Map}start(e){if(this.timestamps.has(e))throw Error(`Watch already started for label: ${e}`);this.timestamps.set(e,{started:Date.now()})}stop(e){let t=this.get(e);if(void 0!==t.elapsed)throw Error(`Watch already stopped for label: ${e}`);let n=Date.now()-t.started;this.timestamps.set(e,{started:t.started,elapsed:n})}get(e){let t=this.timestamps.get(e);if(void 0===t)throw Error(`No timestamp found for label: ${e}`);return t}elapsed(e){let t=this.get(e),n=t.elapsed||Date.now()-t.started;return n}};t.Watch=Watch,t.default=Watch},30004:function(e,t,n){"use strict";n.r(t),n.d(t,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar}
1,__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! *****************************************************************************
2Copyright (c) Microsoft Corporation.
3
4Permission to use, copy, modify, and/or distribute this software for any
5purpose with or without fee is hereby granted.
6
7THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
8REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
9AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
10INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
11LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
12OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
13PERFORMANCE OF THIS SOFTWARE.
14***************************************************************************** */var extendStatics=function(e,t){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function __extends(e,t){function __(){this.constructor=e}extendStatics(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __rest(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&0>t.indexOf(o)&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,o=Object.getOwnPropertySymbols(e);i<o.length;i++)0>t.indexOf(o[i])&&Object.prototype.propertyIsEnumerable.call(e,o[i])&&(n[o[i]]=e[o[i]]);return n}function __decorate(e,t,n,o){var i,s=arguments.length,c=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)c=Reflect.decorate(e,t,n,o);else for(var l=e.length-1;l>=0;l--)(i=e[l])&&(c=(s<3?i(c):s>3?i(t,n,c):i(t,n))||c);return s>3&&c&&Object.defineProperty(t,n,c),c}function __param(e,t){return function(n,o){t(n,o,e)}}function __metadata(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function __awaiter(e,t,n,o){return new(n||(n=Promise))(function(i,s){function fulfilled(e){try{step(o.next(e))}catch(e){s(e)}}function rejected(e){try{step(o.throw(e))}catch(e){s(e)}}function step(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(fulfilled,rejected)}step((o=o.apply(e,t||[])).next())})}function __generator(e,t){var n,o,i,s,c={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return s={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function verb(s){return function(l){return function(s){if(n)throw TypeError("Generator is already executing.");for(;c;)try{if(n=1,o&&(i=2&s[0]?o.return:s[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,s[1])).done)return i;switch(o=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return c.label++,{value:s[1],done:!1};case 5:c.label++,o=s[1],s=[0];continue;case 7:s=c.ops.pop(),c.trys.pop();continue;default:if(!(i=(i=c.trys).length>0&&i[i.length-1])&&(6===s[0]||2===s[0])){c=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){c.label=s[1];break}if(6===s[0]&&c.label<i[1]){c.label=i[1],i=s;break}if(i&&c.label<i[2]){c.label=i[2],c.ops.push(s);break}i[2]&&c.ops.pop(),c.trys.pop();continue}s=t.call(e,c)}catch(e){s=[6,e],o=0}finally{n=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,l])}}}function __createBinding(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]}function __exportStar(e,t){for(var n in e)"default"===n||t.hasOwnProperty(n)||(t[n]=e[n])}function __values(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],o=0;if(n)return n.call(e);
vendor: 2,253 bytes, line 14
14if(e&&"number"==typeof e.length)return{next:function(){return e&&o>=e.length&&(e=void 0),{value:e&&e[o++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var o,i,s=n.call(e),c=[];try{for(;(void 0===t||t-- >0)&&!(o=s.next()).done;)c.push(o.value)}catch(e){i={error:e}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}finally{if(i)throw i.error}}return c}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}function __spreadArrays(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var o=Array(e),i=0,t=0;t<n;t++)for(var s=arguments[t],c=0,l=s.length;c<l;c++,i++)o[i]=s[c];return o}function __await(e){return this instanceof __await?(this.v=e,this):new __await(e)}function __asyncGenerator(e,t,n){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var o,i=n.apply(e,t||[]),s=[];return o={},verb("next"),verb("throw"),verb("return"),o[Symbol.asyncIterator]=function(){return this},o;function verb(e){i[e]&&(o[e]=function(t){return new Promise(function(n,o){s.push([e,t,n,o])>1||resume(e,t)})})}function resume(e,t){try{var n;(n=i[e](t)).value instanceof __await?Promise.resolve(n.value.v).then(fulfill,reject):settle(s[0][2],n)}catch(e){settle(s[0][3],e)}}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){e(t),s.shift(),s.length&&resume(s[0][0],s[0][1])}}function __asyncDelegator(e){var t,n;return t={},verb("next"),verb("throw",function(e){throw e}),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(o,i){t[o]=e[o]?function(t){return(n=!n)?{value:__await(e[o](t)),done:"return"===o}:i?i(t):t}:i}}function __asyncValues(e){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=__values(e),t={},verb("next"),verb("throw"),verb("return"),t[Symbol.asyncIterator]=function(){return this},t);function verb(n){t[n]=e[n]&&function(t){return new Promise(function(o,i){!function(e,t,n,o){Promise.resolve(o).then(function(t){e({value:t,done:n})},t)}(o,i,(t=e[n](t)).done,t.value)})}}}
14function __makeTemplateObject(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function __importStar(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function __importDefault(e){return e&&e.__esModule?e:{default:e}}function __classPrivateFieldGet(e,t){if(!t.has(e))throw TypeError("attempted to get private field on non-instance");return t.get(e)}function __classPrivateFieldSet(e,t,n){if(!t.has(e))throw TypeError("attempted to set private field on non-instance");return t.set(e,n),n}},50778:function(e,t,n){"use strict";n.d(t,{AW:function(){return x},O6:function(){return tr},rV:function(){return I},gn:function(){return pt},H1:function(){return at},hF:function(){return ut},WG:function(){return $},pe:function(){return Fn},m$:function(){return Mn},vB:function(){return ee},HI:function(){return xn},E0:function(){return yt},Gq:function(){return dt},$0:function(){return Xn},Z4:function(){return lt},Bv:function(){return It},Au:function(){return kn},jd:function(){return Vn},gu:function(){return Un},D:function(){return Qn},X_:function(){return Jn},bW:function(){return gt},Z7:function(){return N},cO:function(){return Et},_H:function(){return vt},fc:function(){return jt},D6:function(){return U},Hh:function(){return ht},Ym:function(){return Kn},rj:function(){return Ln},jU:function(){return D},gp:function(){return oe},rF:function(){return fn},Bw:function(){return mt},UG:function(){return te},Gg:function(){return er},xW:function(){return Vt},b$:function(){return C},Ih:function(){return Dt},h1:function(){return Mt},Q8:function(){return qn},o8:function(){return w},qt:function(){return k},Dd:function(){return Kt},$t:function(){return qt},nf:function(){return Wt},Q0:function(){return Ft},in:function(){return ln},p8:function(){return zt},sI:function(){return Jt},al:function(){return Yt},L5:function(){return B},EJ:function(){return Ht},Z2:function(){return dn},PM:function(){return xt},hH:function(){return Bt},ON:function(){return Xt},n:function(){return Lt},JT:function(){return Gt},M_:function(){return h},jv:function(){return kt},KC:function(){return rt},eG:function(){return S},fK:function(){return se},IP:function(){return ot},DQ:function(){return ve},iP:function(){return ft},M:function(){return en},he:function(){return wt},uw:function(){return nr},Ll:function(){return Hn},EN:function(){return Ae}});var o=n(15501),i=n(512),s=n(31416),c=n(73294),l=n(57664),u=n(37466),d=n(43631),p=n(66736),m=n(62873),b=n(65755),g=n(66151);n(61882);let y={waku:{publish:"waku_publish",batchPublish:"waku_batchPublish",subscribe:"waku_subscribe",batchSubscribe:"waku_batchSubscribe",subscription:"waku_subscription",unsubscribe:"waku_unsubscribe",batchUnsubscribe:"waku_batchUnsubscribe"},irn:{publish:"irn_publish",batchPublish:"irn_batchPublish",subscribe:"irn_subscribe",batchSubscribe:"irn_batchSubscribe",subscription:"irn_subscription",unsubscribe:"irn_unsubscribe",batchUnsubscribe:"irn_batchUnsubscribe"},iridium:{publish:"iridium_publish",batchPublish:"iridium_batchPublish",subscribe:"iridium_subscribe",batchSubscribe:"iridium_batchSubscribe",subscription:"iridium_subscription",unsubscribe:"iridium_unsubscribe",batchUnsubscribe:"iridium_batchUnsubscribe"}};var v=n(83454);function ve(e){let[t,n]=e.split(":");return{namespace:t,reference:n}}function Un(e,t=[]){let n=[];return Object.keys(e).forEach(o=>{if(t.length&&!t.includes(o))return;let i=e[o];n.push(...i.accounts)}),n}function L(e,t){return e.includes(":")?[e]:t.chains||[]}let E="base10",x="base16",P="base64pad",_="utf8",I=1;function kn(){let e=l.Au();return{privateKey:(0,u.BB)(e.secretKey,x),publicKey:(0,u.BB)(e.publicKey,x)}}function Vn(){let e=(0,s.randomBytes)(32);return(0,u.BB)(e,x)}function Mn(e,t){let n=l.gi((0,u.mL)(e,x),(0,u.mL)(t,x),!0),o=new i.t(c.mE,n).expand(32);return(0,u.BB)(o,x)}function Kn(e){let t=(0,c.vp)((0,u.mL)(e,x));return(0,u.BB)(t,x)}function Ln(e){let t=(0,c.vp)((0,u.mL)(e,_));return(0,u.BB)(t,x)}function $(e){return Number((0,u.BB)(e,E))}function xn(e){var t;let n=(t="u">typeof e.type?e.type:0,(0,u.mL)(`${t}`,E));if($(n)===I&&typeof e.senderPublicKey>"u")throw Error("Missing sender public key for type 1 envelope");let i="u">typeof e.senderPublicKey?(0,u.mL)(e.senderPublicKey,x):void 0,c="u">typeof e.iv?(0,u.mL)(e.iv,x):(0,s.randomBytes)(12),l=new o.OK((0,u.mL)(e.symKey,x)).seal(c,(0,u.mL)(e.message,_));return function(e){if($(e.type)===I){if(typeof e.senderPublicKey>"u")throw Error("Missing sender public key for type 1 envelope");
14return(0,u.BB)((0,u.zo)([e.type,e.senderPublicKey,e.iv,e.sealed]),P)}return(0,u.BB)((0,u.zo)([e.type,e.iv,e.sealed]),P)}({type:n,sealed:l,iv:c,senderPublicKey:i})}function Fn(e){let t=new o.OK((0,u.mL)(e.symKey,x)),{sealed:n,iv:i}=ee(e.encoded),s=t.open(i,n);if(null===s)throw Error("Failed to decrypt");return(0,u.BB)(s,_)}function ee(e){let t=(0,u.mL)(e,P),n=t.slice(0,1);if($(n)===I){let e=t.slice(1,33),o=t.slice(33,45),i=t.slice(45);return{type:n,sealed:i,iv:o,senderPublicKey:e}}let o=t.slice(1,13),i=t.slice(13);return{type:n,sealed:i,iv:o}}function Hn(e,t){let n=ee(e);return Ae({type:$(n.type),senderPublicKey:"u">typeof n.senderPublicKey?(0,u.BB)(n.senderPublicKey,x):void 0,receiverPublicKey:t?.receiverPublicKey})}function Ae(e){let t=e?.type||0;if(t===I){if(typeof e?.senderPublicKey>"u")throw Error("missing sender public key");if(typeof e?.receiverPublicKey>"u")throw Error("missing receiver public key")}return{type:t,senderPublicKey:e?.senderPublicKey,receiverPublicKey:e?.receiverPublicKey}}function qn(e){return e.type===I&&"string"==typeof e.senderPublicKey&&"string"==typeof e.receiverPublicKey}var j=Object.defineProperty,R=Object.getOwnPropertySymbols,M=Object.prototype.hasOwnProperty,F=Object.prototype.propertyIsEnumerable,_e=(e,t,n)=>t in e?j(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ce=(e,t)=>{for(var n in t||(t={}))M.call(t,n)&&_e(e,n,t[n]);if(R)for(var n of R(t))F.call(t,n)&&_e(e,n,t[n]);return e};let q={reactNative:"react-native",node:"node",browser:"browser",unknown:"unknown"};function te(){return"u">typeof v&&"u">typeof v.versions&&"u">typeof v.versions.node}function C(){return!(0,m.getDocument)()&&!!(0,m.getNavigator)()&&"ReactNative"===navigator.product}function D(){return!te()&&!!(0,m.getNavigator)()&&!!(0,m.getDocument)()}function T(){return C()?q.reactNative:te()?q.node:D()?q.browser:q.unknown}function Jn(){var e;try{return C()&&"u">typeof n.g&&"u">typeof(null==n.g?void 0:n.g.Application)?null==(e=n.g.Application)?void 0:e.applicationId:void 0}catch{return}}function Qn(){return(0,b.D)()||{name:"",description:"",url:"",icons:[""]}}function Xn({protocol:e,version:t,relayUrl:o,sdkVersion:i,auth:s,projectId:c,useOnCloseEvent:l,bundleId:u}){var p;let b;let y=o.split("?"),v=function(e,t,o){let i=function(){if(T()===q.reactNative&&"u">typeof n.g&&"u">typeof(null==n.g?void 0:n.g.Platform)){let{OS:e,Version:t}=n.g.Platform;return[e,t].join("-")}let e=(0,d.qY)();if(null===e)return"unknown";let t=e.os?e.os.replace(" ","").toLowerCase():"unknown";return"browser"===e.type?[t,e.name,e.version].join("-"):[t,e.version].join("-")}(),s=function(){var e;let t=T();return t===q.browser?[t,(null==(e=(0,m.getLocation)())?void 0:e.host)||"unknown"].join(":"):t}();return[[e,t].join("-"),["js",o].join("-"),i,s].join("/")}(e,t,i),E=(p=y[1]||"",b=Ce(Ce({},b=g.parse(p)),{auth:s,ua:v,projectId:c,useOnCloseEvent:l||void 0,origin:u||void 0}),p=g.stringify(b));return y[0]+"?"+E}function O(e,t){return e.filter(e=>t.includes(e)).length===e.length}function rt(e){return Object.fromEntries(e.entries())}function ot(e){return new Map(Object.entries(e))}function at(e=p.FIVE_MINUTES,t){let n,o,i;let s=(0,p.toMiliseconds)(e||p.FIVE_MINUTES);return{resolve:e=>{i&&n&&(clearTimeout(i),n(e))},reject:e=>{i&&o&&(clearTimeout(i),o(e))},done:()=>new Promise((e,c)=>{i=setTimeout(()=>{c(Error(t))},s),n=e,o=c})}}function ut(e,t,n){return new Promise(async(o,i)=>{let s=setTimeout(()=>i(Error(n)),t);try{let t=await e;o(t)}catch(e){i(e)}clearTimeout(s)})}function re(e,t){if("string"==typeof t&&t.startsWith(`${e}:`))return t;if("topic"===e.toLowerCase()){if("string"!=typeof t)throw Error('Value must be "string" for expirer target type: topic');return`topic:${t}`}if("id"===e.toLowerCase()){if("number"!=typeof t)throw Error('Value must be "number" for expirer target type: id');return`id:${t}`}throw Error(`Unknown expirer target type: ${e}`)}function lt(e){return re("topic",e)}function dt(e){return re("id",e)}function ft(e){let[t,n]=e.split(":"),o={id:void 0,topic:void 0};if("topic"===t&&"string"==typeof n)o.topic=n;else if("id"===t&&Number.isInteger(Number(n)))o.id=Number(n);else throw Error(`Invalid target, expected id:number or topic:string, got ${t}:${n}`);return o}function pt(e,t){return(0,p.fromMiliseconds)((t||Date.now())+(0,p.toMiliseconds)(e))}function mt(e){return Date.now()>=(0,p.toMiliseconds)(e)}function yt(e,t){return`${e}${t?`:${t}`:""}`}function S(e=[],t=[]){return[...new Set([...e,...t])]}async function ht({id:e,topic:t,wcDeepLink:o}){try{if(!o)return;let i="string"==typeof o?JSON.parse(o):o,s=i?.href;if("string"!=typeof s)return;s.endsWith("/")&&(s=s.slice(0,-1));let c=`${s}/wc?requestId=${e}&sessionTopic=${t}`,l=T();l===q.browser?c.startsWith("https://")?window.open(c,"_blank","noreferrer noopener"):window.open(c,"_self","noreferrer noopener"):l===q.reactNative&&"u">typeof(null==n.g?void 0:n.g.Linking)&&await n.g.Linking.openURL(c)}catch(e){console.error(e)}}async function gt(e,t){try{return await e.getItem(t)||(D()?localStorage.getItem(t):void 0)}catch(e){console.error(e)}}function vt(e){return e?.relay||{protocol:"irn"}}function Et(e){let t=y[e];if(typeof t>"u")throw Error(`Relay Protocol not supported: ${e}`);return t}var H=Object.defineProperty,z=Object.getOwnPropertySymbols,W=Object.prototype.hasOwnProperty,K=Object.prototype.propertyIsEnumerable,Be=(e,t,n)=>t in e?H(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,St=(e,t)=>
14{for(var n in t||(t={}))W.call(t,n)&&Be(e,n,t[n]);if(z)for(var n of z(t))K.call(t,n)&&Be(e,n,t[n]);return e};function wt(e){var t;e=(e=e.includes("wc://")?e.replace("wc://",""):e).includes("wc:")?e.replace("wc:",""):e;let n=e.indexOf(":"),o=-1!==e.indexOf("?")?e.indexOf("?"):void 0,i=e.substring(0,n),s=e.substring(n+1,o).split("@"),c="u">typeof o?e.substring(o):"",l=g.parse(c);return{protocol:i,topic:(t=s[0]).startsWith("//")?t.substring(2):t,version:parseInt(s[1],10),symKey:l.symKey,relay:function(e,t="-"){let n={},o="relay"+t;return Object.keys(e).forEach(t=>{if(t.startsWith(o)){let i=t.replace(o,""),s=e[t];n[i]=s}}),n}(l)}}function It(e){return`${e.protocol}:${e.topic}@${e.version}?`+g.stringify(St({symKey:e.symKey},function(e,t="-"){let n={};return Object.keys(e).forEach(o=>{e[o]&&(n["relay"+t+o]=e[o])}),n}(e.relay)))}var Q=Object.defineProperty,Z=Object.defineProperties,X=Object.getOwnPropertyDescriptors,Y=Object.getOwnPropertySymbols,J=Object.prototype.hasOwnProperty,et=Object.prototype.propertyIsEnumerable,Je=(e,t,n)=>t in e?Q(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_t=(e,t)=>{for(var n in t||(t={}))J.call(t,n)&&Je(e,n,t[n]);if(Y)for(var n of Y(t))et.call(t,n)&&Je(e,n,t[n]);return e},Ct=(e,t)=>Z(e,X(t));function A(e){let t=[];return e.forEach(e=>{let[n,o]=e.split(":");t.push(`${n}:${o}`)}),t}function jt(e,t){let n=ln(e,t);if(n)throw Error(n.message);let o={};for(let[t,n]of Object.entries(e))o[t]={methods:n.methods,events:n.events,chains:n.accounts.map(e=>`${e.split(":")[0]}:${e.split(":")[1]}`)};return o}function oe(e){return e.includes(":")}function en(e){return oe(e)?e.split(":")[0]:e}function se(e){var t,n,o;let i={};if(!B(e))return i;for(let[s,c]of Object.entries(e)){let e=oe(s)?[s]:c.chains,l=c.methods||[],u=c.events||[],d=en(s);i[d]=Ct(_t({},i[d]),{chains:S(e,null==(t=i[d])?void 0:t.chains),methods:S(l,null==(n=i[d])?void 0:n.methods),events:S(u,null==(o=i[d])?void 0:o.events)})}return i}let eo={INVALID_METHOD:{message:"Invalid method.",code:1001},INVALID_EVENT:{message:"Invalid event.",code:1002},INVALID_UPDATE_REQUEST:{message:"Invalid update request.",code:1003},INVALID_EXTEND_REQUEST:{message:"Invalid extend request.",code:1004},INVALID_SESSION_SETTLE_REQUEST:{message:"Invalid session settle request.",code:1005},UNAUTHORIZED_METHOD:{message:"Unauthorized method.",code:3001},UNAUTHORIZED_EVENT:{message:"Unauthorized event.",code:3002},UNAUTHORIZED_UPDATE_REQUEST:{message:"Unauthorized update request.",code:3003},UNAUTHORIZED_EXTEND_REQUEST:{message:"Unauthorized extend request.",code:3004},USER_REJECTED:{message:"User rejected.",code:5e3},USER_REJECTED_CHAINS:{message:"User rejected chains.",code:5001},USER_REJECTED_METHODS:{message:"User rejected methods.",code:5002},USER_REJECTED_EVENTS:{message:"User rejected events.",code:5003},UNSUPPORTED_CHAINS:{message:"Unsupported chains.",code:5100},UNSUPPORTED_METHODS:{message:"Unsupported methods.",code:5101},UNSUPPORTED_EVENTS:{message:"Unsupported events.",code:5102},UNSUPPORTED_ACCOUNTS:{message:"Unsupported accounts.",code:5103},UNSUPPORTED_NAMESPACE_KEY:{message:"Unsupported namespace key.",code:5104},USER_DISCONNECTED:{message:"User disconnected.",code:6e3},SESSION_SETTLEMENT_FAILED:{message:"Session settlement failed.",code:7e3},WC_METHOD_UNSUPPORTED:{message:"Unsupported wc_ method.",code:10001}},ea={NOT_INITIALIZED:{message:"Not initialized.",code:1},NO_MATCHING_KEY:{message:"No matching key.",code:2},RESTORE_WILL_OVERRIDE:{message:"Restore will override.",code:3},RESUBSCRIBED:{message:"Resubscribed.",code:4},MISSING_OR_INVALID:{message:"Missing or invalid.",code:5},EXPIRED:{message:"Expired.",code:6},UNKNOWN_TYPE:{message:"Unknown type.",code:7},MISMATCHED_TOPIC:{message:"Mismatched topic.",code:8},NON_CONFORMING_NAMESPACES:{message:"Non conforming namespaces.",code:9}};function N(e,t){let{message:n,code:o}=ea[e];return{message:t?`${n} ${t}`:n,code:o}}function U(e,t){let{message:n,code:o}=eo[e];return{message:t?`${n} ${t}`:n,code:o}}function k(e,t){return!!Array.isArray(e)&&(!("u">typeof t)||!e.length||e.every(t))}function B(e){return Object.getPrototypeOf(e)===Object.prototype&&Object.keys(e).length}function w(e){return typeof e>"u"}function h(e,t){return!!(t&&w(e))||"string"==typeof e&&!!e.trim().length}function G(e,t){return!!(t&&w(e))||"number"==typeof e&&!isNaN(e)}function Dt(e,t){let{requiredNamespaces:n}=t,o=Object.keys(e.namespaces),i=Object.keys(n),s=!0;
14return!!O(i,o)&&(o.forEach(t=>{let{accounts:o,methods:i,events:c}=e.namespaces[t],l=A(o),u=n[t];O(L(t,u),l)&&O(u.methods,i)&&O(u.events,c)||(s=!1)}),s)}function V(e){return!!(h(e,!1)&&e.includes(":"))&&2===e.split(":").length}function kt(e){if(h(e,!1))try{return"u">typeof new URL(e)}catch{}return!1}function Vt(e){var t;return null==(t=e?.proposer)?void 0:t.publicKey}function Mt(e){return e?.topic}function Kt(e,t){let n=null;return h(e?.publicKey,!1)||(n=N("MISSING_OR_INVALID",`${t} controller public key should be a string`)),n}function ie(e){let t=!0;return k(e)?e.length&&(t=e.every(e=>h(e,!1))):t=!1,t}function ce(e,t){let n=null;return Object.values(e).forEach(e=>{var o;let i;if(n)return;let s=(o=`${t}, namespace`,i=null,ie(e?.methods)?ie(e?.events)||(i=U("UNSUPPORTED_EVENTS",`${o}, events should be an array of strings or empty array for no events`)):i=U("UNSUPPORTED_METHODS",`${o}, methods should be an array of strings or empty array for no methods`),i);s&&(n=s)}),n}function Lt(e,t,n){let o=null;if(e&&B(e)){let i;let s=ce(e,t);s&&(o=s);let c=(i=null,Object.entries(e).forEach(([e,o])=>{var s,c;let l;if(i)return;let u=(s=L(e,o),c=`${t} ${n}`,l=null,k(s)&&s.length?s.forEach(e=>{l||V(e)||(l=U("UNSUPPORTED_CHAINS",`${c}, chain ${e} should be a string and conform to "namespace:chainId" format`))}):V(e)||(l=U("UNSUPPORTED_CHAINS",`${c}, chains must be defined as "namespace:chainId" e.g. "eip155:1": {...} in the namespace key OR as an array of CAIP-2 chainIds e.g. eip155: { chains: ["eip155:1", "eip155:5"] }`)),l);u&&(i=u)}),i);c&&(o=c)}else o=N("MISSING_OR_INVALID",`${t}, ${n} should be an object with data`);return o}function ln(e,t){let n=null;if(e&&B(e)){let o;let i=ce(e,t);i&&(n=i);let s=(o=null,Object.values(e).forEach(e=>{var n,i;let s;if(o)return;let c=(n=e?.accounts,i=`${t} namespace`,s=null,k(n)?n.forEach(e=>{s||function(e){if(h(e,!1)&&e.includes(":")){let t=e.split(":");if(3===t.length){let e=t[0]+":"+t[1];return!!t[2]&&V(e)}}return!1}(e)||(s=U("UNSUPPORTED_ACCOUNTS",`${i}, account ${e} should be a string and conform to "namespace:chainId:address" format`))}):s=U("UNSUPPORTED_ACCOUNTS",`${i}, accounts should be an array of strings conforming to "namespace:chainId:address" format`),s);c&&(o=c)}),o);s&&(n=s)}else n=N("MISSING_OR_INVALID",`${t}, namespaces should be an object with data`);return n}function dn(e){return h(e.protocol,!0)}function xt(e,t){let n=!1;return t&&!e?n=!0:e&&k(e)&&e.length&&e.forEach(e=>{n=dn(e)}),n}function Ft(e){return"number"==typeof e}function Ht(e){return"u">typeof e}function qt(e){return!(!e||"object"!=typeof e||!e.code||!G(e.code,!1)||!e.message||!h(e.message,!1))}function Bt(e){return!(w(e)||!h(e.method,!1))}function Gt(e){return!(w(e)||w(e.result)&&w(e.error)||!G(e.id,!1)||!h(e.jsonrpc,!1))}function Wt(e){return!(w(e)||!h(e.name,!1))}function zt(e,t){return!(!V(t)||!(function(e){let t=[];return Object.values(e).forEach(e=>{t.push(...A(e.accounts))}),t})(e).includes(t))}function Yt(e,t,n){return!!h(n,!1)&&(function(e,t){let n=[];return Object.values(e).forEach(e=>{A(e.accounts).includes(t)&&n.push(...e.methods)}),n})(e,t).includes(n)}function Jt(e,t,n){return!!h(n,!1)&&(function(e,t){let n=[];return Object.values(e).forEach(e=>{A(e.accounts).includes(t)&&n.push(...e.events)}),n})(e,t).includes(n)}function fn(e,t,n){let o=null,i=function(e){let t={};return Object.keys(e).forEach(n=>{var o;n.includes(":")?t[n]=e[n]:null==(o=e[n].chains)||o.forEach(o=>{t[o]={methods:e[n].methods,events:e[n].events}})}),t}(e),s=function(e){let t={};return Object.keys(e).forEach(n=>{if(n.includes(":"))t[n]=e[n];else{let o=A(e[n].accounts);o?.forEach(o=>{t[o]={accounts:e[n].accounts.filter(e=>e.includes(`${o}:`)),methods:e[n].methods,events:e[n].events}})}}),t}(t),c=Object.keys(i),l=Object.keys(s),u=pn(Object.keys(e)),d=pn(Object.keys(t)),p=u.filter(e=>!d.includes(e));return p.length&&(o=N("NON_CONFORMING_NAMESPACES",`${n} namespaces keys don't satisfy requiredNamespaces.
15      Required: ${p.toString()}
16      Received: ${Object.keys(t).toString()}`)),O(c,l)||(o=N("NON_CONFORMING_NAMESPACES",`${n} namespaces chains don't satisfy required namespaces.
17      Required: ${c.toString()}
18      Approved: ${l.toString()}
18`)),Object.keys(t).forEach(e=>{if(!e.includes(":")||o)return;let i=A(t[e].accounts);i.includes(e)||(o=N("NON_CONFORMING_NAMESPACES",`${n} namespaces accounts don't satisfy namespace accounts for ${e}
19        Required: ${e}
20        Approved: ${i.toString()}`))}),c.forEach(e=>{o||(O(i[e].methods,s[e].methods)?O(i[e].events,s[e].events)||(o=N("NON_CONFORMING_NAMESPACES",`${n} namespaces events don't satisfy namespace events for ${e}`)):o=N("NON_CONFORMING_NAMESPACES",`${n} namespaces methods don't satisfy namespace methods for ${e}`))}),o}function pn(e){return[...new Set(e.map(e=>e.includes(":")?e.split(":")[0]:e))]}function Xt(e,t){return G(e,!1)&&e<=t.max&&e>=t.min}function er(){let e=T();return new Promise(t=>{switch(e){case q.browser:t(D()&&navigator?.onLine);break;case q.reactNative:t(yn());break;case q.node:default:t(!0)}})}async function yn(){if(C()&&"u">typeof n.g&&null!=n.g&&n.g.NetInfo){let e=await (null==n.g?void 0:n.g.NetInfo.fetch());return e?.isConnected}return!0}function nr(e){switch(T()){case q.browser:!C()&&D()&&(window.addEventListener("online",()=>e(!0)),window.addEventListener("offline",()=>e(!1)));break;case q.reactNative:C()&&"u">typeof n.g&&null!=n.g&&n.g.NetInfo&&n.g?.NetInfo.addEventListener(t=>e(t?.isConnected));case q.node:}}let ei={};let tr=class tr{static get(e){return ei[e]}static set(e,t){ei[e]=t}static delete(e){delete ei[e]}}},66151:function(e,t,n){"use strict";let o=n(70610),i=n(44020),s=n(80500),c=n(92806),isNullOrUndefined=e=>null==e,l=Symbol("encodeFragmentIdentifier");function validateArrayFormatSeparator(e){if("string"!=typeof e||1!==e.length)throw TypeError("arrayFormatSeparator must be single character string")}function encode(e,t){return t.encode?t.strict?o(e):encodeURIComponent(e):e}function decode(e,t){return t.decode?i(e):e}function removeHash(e){let t=e.indexOf("#");return -1!==t&&(e=e.slice(0,t)),e}function extract(e){e=removeHash(e);let t=e.indexOf("?");return -1===t?"":e.slice(t+1)}function parseValue(e,t){return t.parseNumbers&&!Number.isNaN(Number(e))&&"string"==typeof e&&""!==e.trim()?e=Number(e):t.parseBooleans&&null!==e&&("true"===e.toLowerCase()||"false"===e.toLowerCase())&&(e="true"===e.toLowerCase()),e}function parse(e,t){validateArrayFormatSeparator((t=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},t)).arrayFormatSeparator);let n=function(e){let t;switch(e.arrayFormat){case"index":return(e,n,o)=>{if(t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),!t){o[e]=n;return}void 0===o[e]&&(o[e]={}),o[e][t[1]]=n};case"bracket":return(e,n,o)=>{if(t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),!t){o[e]=n;return}if(void 0===o[e]){o[e]=[n];return}o[e]=[].concat(o[e],n)};case"colon-list-separator":return(e,n,o)=>{if(t=/(:list)$/.exec(e),e=e.replace(/:list$/,""),!t){o[e]=n;return}if(void 0===o[e]){o[e]=[n];return}o[e]=[].concat(o[e],n)};case"comma":case"separator":return(t,n,o)=>{let i="string"==typeof n&&n.includes(e.arrayFormatSeparator),s="string"==typeof n&&!i&&decode(n,e).includes(e.arrayFormatSeparator);n=s?decode(n,e):n;let c=i||s?n.split(e.arrayFormatSeparator).map(t=>decode(t,e)):null===n?n:decode(n,e);o[t]=c};case"bracket-separator":return(t,n,o)=>{let i=/(\[\])$/.test(t);if(t=t.replace(/\[\]$/,""),!i){o[t]=n?decode(n,e):n;return}let s=null===n?[]:n.split(e.arrayFormatSeparator).map(t=>decode(t,e));if(void 0===o[t]){o[t]=s;return}o[t]=[].concat(o[t],s)};default:return(e,t,n)=>{if(void 0===n[e]){n[e]=t;return}n[e]=[].concat(n[e],t)}}}(t),o=Object.create(null);if("string"!=typeof e||!(e=e.trim().replace(/^[?#&]/,"")))return o;for(let i of e.split("&")){if(""===i)continue;let[e,c]=s(t.decode?i.replace(/\+/g," "):i,"=");c=void 0===c?null:["comma","separator","bracket-separator"].includes(t.arrayFormat)?c:decode(c,t),n(decode(e,t),c,o)}for(let e of Object.keys(o)){let n=o[e];if("object"==typeof n&&null!==n)for(let e of Object.keys(n))n[e]=parseValue(n[e],t);else o[e]=parseValue(n,t)}return!1===t.sort?o:(!0===t.sort?Object.keys(o).sort():Object.keys(o).sort(t.sort)).reduce((e,t)=>{let n=o[t];return n&&"object"==typeof n&&!Array.isArray(n)?e[t]=function keysSorter(e){return Array.isArray(e)?e.sort():"object"==typeof e?keysSorter(Object.keys(e)).sort((e,t)=>
20Number(e)-Number(t)).map(t=>e[t]):e}(n):e[t]=n,e},Object.create(null))}t.extract=extract,t.parse=parse,t.stringify=(e,t)=>{if(!e)return"";validateArrayFormatSeparator((t=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},t)).arrayFormatSeparator);let shouldFilter=n=>t.skipNull&&isNullOrUndefined(e[n])||t.skipEmptyString&&""===e[n],n=function(e){switch(e.arrayFormat){case"index":return t=>(n,o)=>{let i=n.length;return void 0===o||e.skipNull&&null===o||e.skipEmptyString&&""===o?n:null===o?[...n,[encode(t,e),"[",i,"]"].join("")]:[...n,[encode(t,e),"[",encode(i,e),"]=",encode(o,e)].join("")]};case"bracket":return t=>(n,o)=>void 0===o||e.skipNull&&null===o||e.skipEmptyString&&""===o?n:null===o?[...n,[encode(t,e),"[]"].join("")]:[...n,[encode(t,e),"[]=",encode(o,e)].join("")];case"colon-list-separator":return t=>(n,o)=>void 0===o||e.skipNull&&null===o||e.skipEmptyString&&""===o?n:null===o?[...n,[encode(t,e),":list="].join("")]:[...n,[encode(t,e),":list=",encode(o,e)].join("")];case"comma":case"separator":case"bracket-separator":{let t="bracket-separator"===e.arrayFormat?"[]=":"=";return n=>(o,i)=>void 0===i||e.skipNull&&null===i||e.skipEmptyString&&""===i?o:(i=null===i?"":i,0===o.length)?[[encode(n,e),t,encode(i,e)].join("")]:[[o,encode(i,e)].join(e.arrayFormatSeparator)]}default:return t=>(n,o)=>void 0===o||e.skipNull&&null===o||e.skipEmptyString&&""===o?n:null===o?[...n,encode(t,e)]:[...n,[encode(t,e),"=",encode(o,e)].join("")]}}(t),o={};for(let t of Object.keys(e))shouldFilter(t)||(o[t]=e[t]);let i=Object.keys(o);return!1!==t.sort&&i.sort(t.sort),i.map(o=>{let i=e[o];return void 0===i?"":null===i?encode(o,t):Array.isArray(i)?0===i.length&&"bracket-separator"===t.arrayFormat?encode(o,t)+"[]":i.reduce(n(o),[]).join("&"):encode(o,t)+"="+encode(i,t)}).filter(e=>e.length>0).join("&")},t.parseUrl=(e,t)=>
20{t=Object.assign({decode:!0},t);let[n,o]=s(e,"#");return Object.assign({url:n.split("?")[0]||"",query:parse(extract(e),t)},t&&t.parseFragmentIdentifier&&o?{fragmentIdentifier:decode(o,t)}:{})},t.stringifyUrl=(e,n)=>{n=Object.assign({encode:!0,strict:!0,[l]:!0},n);let o=removeHash(e.url).split("?")[0]||"",i=t.extract(e.url),s=t.parse(i,{sort:!1}),c=Object.assign(s,e.query),u=t.stringify(c,n);u&&(u=`?${u}`);let d=function(e){let t="",n=e.indexOf("#");return -1!==n&&(t=e.slice(n)),t}(e.url);return e.fragmentIdentifier&&(d=`#${n[l]?encode(e.fragmentIdentifier,n):e.fragmentIdentifier}`),`${o}${u}${d}`},t.pick=(e,n,o)=>{o=Object.assign({parseFragmentIdentifier:!0,[l]:!1},o);let{url:i,query:s,fragmentIdentifier:u}=t.parseUrl(e,o);return t.stringifyUrl({url:i,query:c(s,n),fragmentIdentifier:u},o)},t.exclude=(e,n,o)=>{let i=Array.isArray(n)?e=>!n.includes(e):(e,t)=>!n(e,t);return t.pick(e,i,o)}},62873:function(e,t){"use strict";function getFromWindow(e){let t;return"undefined"!=typeof window&&void 0!==window[e]&&(t=window[e]),t}function getFromWindowOrThrow(e){let t=getFromWindow(e);if(!t)throw Error(`${e} is not defined in Window`);return t}Object.defineProperty(t,"__esModule",{value:!0}),t.getLocalStorage=t.getLocalStorageOrThrow=t.getCrypto=t.getCryptoOrThrow=t.getLocation=t.getLocationOrThrow=t.getNavigator=t.getNavigatorOrThrow=t.getDocument=t.getDocumentOrThrow=t.getFromWindowOrThrow=t.getFromWindow=void 0,t.getFromWindow=getFromWindow,t.getFromWindowOrThrow=getFromWindowOrThrow,t.getDocumentOrThrow=function(){return getFromWindowOrThrow("document")},t.getDocument=function(){return getFromWindow("document")},t.getNavigatorOrThrow=function(){return getFromWindowOrThrow("navigator")},t.getNavigator=function(){return getFromWindow("navigator")},t.getLocationOrThrow=function(){return getFromWindowOrThrow("location")},t.getLocation=function(){return getFromWindow("location")},t.getCryptoOrThrow=function(){return getFromWindowOrThrow("crypto")},t.getCrypto=function(){return getFromWindow("crypto")},t.getLocalStorageOrThrow=function(){return getFromWindowOrThrow("localStorage")},t.getLocalStorage=function(){return getFromWindow("localStorage")}},65755:function(e,t,n){"use strict";t.D=void 0;let o=n(62873);t.D=function(){let e,t,n;try{e=o.getDocumentOrThrow(),t=o.getLocationOrThrow()}catch(e){return null}function getWindowMetadataOfAny(...t){let n=e.getElementsByTagName("meta");for(let e=0;e<n.length;e++){let o=n[e],i=["itemprop","property","name"].map(e=>o.getAttribute(e)).filter(e=>!!e&&t.includes(e));if(i.length&&i){let e=o.getAttribute("content");if(e)return e}}return""}let i=((n=getWindowMetadataOfAny("name","og:site_name","og:title","twitter:title"))||(n=e.title),n),s=function(){let e=getWindowMetadataOfAny("description","og:description","twitter:description","keywords");return e}(),c=t.origin,l=function(){let n=e.getElementsByTagName("link"),o=[];for(let e=0;e<n.length;e++){let i=n[e],s=i.getAttribute("rel");if(s&&s.toLowerCase().indexOf("icon")>-1){let e=i.getAttribute("href");if(e){if(-1===e.toLowerCase().indexOf("https:")&&-1===e.toLowerCase().indexOf("http:")&&0!==e.indexOf("//")){let n=t.protocol+"//"+t.host;if(0===e.indexOf("/"))n+=e;else{let o=t.pathname.split("/");o.pop();let i=o.join("/");n+=i+"/"+e}o.push(n)}else if(0===e.indexOf("//")){let n=t.protocol+e;o.push(n)}else o.push(e)}}}return o}();return{description:s,url:c,icons:l,name:i}}},44020:function(e){"use strict";var t="%[a-f0-9]{2}",n=RegExp("("+t+")|([^%]+?)","gi"),o=RegExp("("+t+")+","gi");e.exports=function(e){if("string"!=typeof e)throw TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`");try{return e=e.replace(/\+/g," "),decodeURIComponent(e)}catch(t){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},i=o.exec(e);i;){try{t[i[0]]=decodeURIComponent(i[0])}catch(e){var s=function(e){try{return decodeURIComponent(e)}catch(i){for(var t=e.match(n)||[],o=1;o<t.length;o++)t=(e=(function decodeComponents(e,t){try{return[decodeURIComponent(e.join(""))]}catch(e){}if(1===e.length)return e;t=t||1;var n=e.slice(0,t),o=e.slice(t);return Array.prototype.concat.call([],decodeComponents(n),decodeComponents(o)
20)})(t,o).join("")).match(n)||[];return e}}(i[0]);s!==i[0]&&(t[i[0]]=s)}i=o.exec(e)}t["%C2"]="�";for(var c=Object.keys(t),l=0;l<c.length;l++){var u=c[l];e=e.replace(RegExp(u,"g"),t[u])}return e}(e)}}},43631:function(e,t,n){"use strict";n.d(t,{qY:function(){return detect}});var o=n(83454),__spreadArray=function(e,t,n){if(n||2==arguments.length)for(var o,i=0,s=t.length;i<s;i++)!o&&i in t||(o||(o=Array.prototype.slice.call(t,0,i)),o[i]=t[i]);return e.concat(o||Array.prototype.slice.call(t))},BrowserInfo=function(e,t,n){this.name=e,this.version=t,this.os=n,this.type="browser"},NodeInfo=function(e){this.version=e,this.type="node",this.name="node",this.os=o.platform},SearchBotDeviceInfo=function(e,t,n,o){this.name=e,this.version=t,this.os=n,this.bot=o,this.type="bot-device"},BotInfo=function(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null},ReactNativeInfo=function(){this.type="react-native",this.name="react-native",this.version=null,this.os=null},i=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,s=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/]],c=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function detect(e){return e?parseUserAgent(e):"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product?new ReactNativeInfo:"undefined"!=typeof navigator?parseUserAgent(navigator.userAgent):void 0!==o&&o.version?new NodeInfo(o.version.slice(1)):null}function parseUserAgent(e){var t=""!==e&&s.reduce(function(t,n){var o=n[0],i=n[1];if(t)return t;var s=i.exec(e);return!!s&&[o,s]},!1);if(!t)return null;var n=t[0],o=t[1];if("searchbot"===n)return new BotInfo;var l=o[1]&&o[1].split(".").join("_").split("_").slice(0,3);l?l.length<3&&(l=__spreadArray(__spreadArray([],l,!0),function(e){for(var t=[],n=0;n<e;n++)t.push("0");return t}(3-l.length),!0)):l=[];var u=l.join("."),d=function(e){for(var t=0,n=c.length;t<n;t++){var o=c[t],i=o[0];if(o[1].exec(e))return i}return null}(e),p=i.exec(e);return p&&p[1]?new SearchBotDeviceInfo(n,u,d,p[1]):new BrowserInfo(n,u,d)}},65987:function(e){"use strict";var t={single_source_shortest_paths:function(e,n,o){var i,s,c,l,u,d,p,m={},b={};b[n]=0;var g=t.PriorityQueue.make();for(g.push(n,0);!g.empty();)for(c in s=(i=g.pop()).value,l=i.cost,u=e[s]||{})u.hasOwnProperty(c)&&(d=l+u[c],p=b[c],(void 0===b[c]||p>
20d)&&(b[c]=d,g.push(c,d),m[c]=s));if(void 0!==o&&void 0===b[o])throw Error(["Could not find a path from ",n," to ",o,"."].join(""));return m},extract_shortest_path_from_predecessor_list:function(e,t){for(var n=[],o=t;o;)n.push(o),e[o],o=e[o];return n.reverse(),n},find_path:function(e,n,o){var i=t.single_source_shortest_paths(e,n,o);return t.extract_shortest_path_from_predecessor_list(i,o)},PriorityQueue:{make:function(e){var n,o=t.PriorityQueue,i={};for(n in e=e||{},o)o.hasOwnProperty(n)&&(i[n]=o[n]);return i.queue=[],i.sorter=e.sorter||o.default_sorter,i},default_sorter:function(e,t){return e.cost-t.cost},push:function(e,t){this.queue.push({value:e,cost:t}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};e.exports=t},62378:function(e){"use strict";e.exports=function(e){for(var t=[],n=e.length,o=0;o<n;o++){var i=e.charCodeAt(o);if(i>=55296&&i<=56319&&n>o+1){var s=e.charCodeAt(o+1);s>=56320&&s<=57343&&(i=(i-55296)*1024+s-56320+65536,o+=1)}if(i<128){t.push(i);continue}if(i<2048){t.push(i>>6|192),t.push(63&i|128);continue}if(i<55296||i>=57344&&i<65536){t.push(i>>12|224),t.push(i>>6&63|128),t.push(63&i|128);continue}if(i>=65536&&i<=1114111){t.push(i>>18|240),t.push(i>>12&63|128),t.push(i>>6&63|128),t.push(63&i|128);continue}t.push(239,191,189)}return new Uint8Array(t).buffer}},26729:function(e){"use strict";var t=Object.prototype.hasOwnProperty,n="~";function Events(){}function EE(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function addListener(e,t,o,i,s){if("function"!=typeof o)throw TypeError("The listener must be a function");var c=new EE(o,i||e,s),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],c]:e._events[l].push(c):(e._events[l]=c,e._eventsCount++),e}function clearEvent(e,t){0==--e._eventsCount?e._events=new Events:delete e._events[t]}function EventEmitter(){this._events=new Events,this._eventsCount=0}Object.create&&(Events.prototype=Object.create(null),new Events().__proto__||(n=!1)),EventEmitter.prototype.eventNames=function(){var e,o,i=[];if(0===this._eventsCount)return i;for(o in e=this._events)t.call(e,o)&&i.push(n?o.slice(1):o);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(e)):i},EventEmitter.prototype.listeners=function(e){var t=n?n+e:e,o=this._events[t];if(!o)return[];if(o.fn)return[o.fn];for(var i=0,s=o.length,c=Array(s);i<s;i++)c[i]=o[i].fn;return c},EventEmitter.prototype.listenerCount=function(e){var t=n?n+e:e,o=this._events[t];return o?o.fn?1:o.length:0},EventEmitter.prototype.emit=function(e,t,o,i,s,c){var l=n?n+e:e;if(!this._events[l])return!1;var u,d,p=this._events[l],m=arguments.length;if(p.fn){switch(p.once&&this.removeListener(e,p.fn,void 0,!0),m){case 1:return p.fn.call(p.context),!0;case 2:return p.fn.call(p.context,t),!0;case 3:return p.fn.call(p.context,t,o),!0;case 4:return p.fn.call(p.context,t,o,i),!0;case 5:return p.fn.call(p.context,t,o,i,s),!0;case 6:return p.fn.call(p.context,t,o,i,s,c),!0}for(d=1,u=Array(m-1);d<m;d++)u[d-1]=arguments[d];p.fn.apply(p.context,u)}else{var b,g=p.length;for(d=0;d<g;d++)switch(p[d].once&&this.removeListener(e,p[d].fn,void 0,!0),m){case 1:p[d].fn.call(p[d].context);break;case 2:p[d].fn.call(p[d].context,t);break;case 3:p[d].fn.call(p[d].context,t,o);break;case 4:p[d].fn.call(p[d].context,t,o,i);break;default:if(!u)for(b=1,u=Array(m-1);b<m;b++)u[b-1]=arguments[b];p[d].fn.apply(p[d].context,u)}}return!0},EventEmitter.prototype.on=function(e,t,n){return addListener(this,e,t,n,!1)},EventEmitter.prototype.once=function(e,t,n){return addListener(this,e,t,n,!0)},EventEmitter.prototype.removeListener=function(e,t,o,i){var s=n?n+e:e;if(!this._events[s])return this;if(!t)return clearEvent(this,s),this;var c=this._events[s];if(c.fn)c.fn!==t||i&&!c.once||o&&c.context!==o||clearEvent(this,s);else{for(var l=0,u=[],d=c.length;l<d;l++)(c[l].fn!==t||i&&!c[l].once||o&&c[l].context!==o)&&u.push(c[l]);u.length?this._events[s]=1===u.length?u[0]:u:clearEvent(this,s)}return this},EventEmitter.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&clearEvent(this,t)):(this._events=new Events,this._eventsCount=0),this},EventEmitter.prototype.off=EventEmitter.prototype.removeListener,EventEmitter.prototype.addListener=EventEmitter.prototype.on,EventEmitter.prefixed=n,EventEmitter.EventEmitter=EventEmitter,e.exports=EventEmitter}
20,17187:function(e){"use strict";var t,n="object"==typeof Reflect?Reflect:null,o=n&&"function"==typeof n.apply?n.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};t=n&&"function"==typeof n.ownKeys?n.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var i=Number.isNaN||function(e){return e!=e};function EventEmitter(){EventEmitter.init.call(this)}e.exports=EventEmitter,e.exports.once=function(e,t){return new Promise(function(n,o){function errorListener(n){e.removeListener(t,resolver),o(n)}function resolver(){"function"==typeof e.removeListener&&e.removeListener("error",errorListener),n([].slice.call(arguments))}eventTargetAgnosticAddListener(e,t,resolver,{once:!0}),"error"!==t&&"function"==typeof e.on&&eventTargetAgnosticAddListener(e,"error",errorListener,{once:!0})})},EventEmitter.EventEmitter=EventEmitter,EventEmitter.prototype._events=void 0,EventEmitter.prototype._eventsCount=0,EventEmitter.prototype._maxListeners=void 0;var s=10;function checkListener(e){if("function"!=typeof e)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function _getMaxListeners(e){return void 0===e._maxListeners?EventEmitter.defaultMaxListeners:e._maxListeners}function _addListener(e,t,n,o){if(checkListener(n),void 0===(s=e._events)?(s=e._events=Object.create(null),e._eventsCount=0):(void 0!==s.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),s=e._events),c=s[t]),void 0===c)c=s[t]=n,++e._eventsCount;else if("function"==typeof c?c=s[t]=o?[n,c]:[c,n]:o?c.unshift(n):c.push(n),(i=_getMaxListeners(e))>0&&c.length>i&&!c.warned){c.warned=!0;var i,s,c,l=Error("Possible EventEmitter memory leak detected. "+c.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=c.length,console&&console.warn&&console.warn(l)}return e}function onceWrapper(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(e,t,n){var o={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=onceWrapper.bind(o);return i.listener=n,o.wrapFn=i,i}function _listeners(e,t,n){var o=e._events;if(void 0===o)return[];var i=o[t];return void 0===i?[]:"function"==typeof i?n?[i.listener||i]:[i]:n?function(e){for(var t=Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(i):arrayClone(i,i.length)}function listenerCount(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function arrayClone(e,t){for(var n=Array(t),o=0;o<t;++o)n[o]=e[o];return n}function eventTargetAgnosticAddListener(e,t,n,o){if("function"==typeof e.on)o.once?e.once(t,n):e.on(t,n);else if("function"==typeof e.addEventListener)e.addEventListener(t,function wrapListener(i){o.once&&e.removeEventListener(t,wrapListener),n(i)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}Object.defineProperty(EventEmitter,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||i(e))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),EventEmitter.init=function(){(void 0===this._events||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},EventEmitter.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||i(e))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},EventEmitter.prototype.getMaxListeners=function(){return _getMaxListeners(this)},EventEmitter.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var i="error"===e,s=this._events;if(void 0!==s)i=i&&void 0===s.error;else if(!i)return!1;if(i){if(t.length>0&&(c=t[0]),c instanceof Error)throw c;var c,l=Error("Unhandled error."+(c?" ("+c.message+")":""));throw l.context=c,l}var u=s[e];if(void 0===u)return!1;if("function"==typeof u)o(u,this,t);else for(var d=u.length,p=arrayClone(u,d),n=0;n<d;++n)o(p[n],this,t);return!0},EventEmitter.prototype.addListener=function(e,t){return _addListener(this,e,t,!1)},EventEmitter.prototype.on=EventEmitter.prototype.addListener,EventEmitter.prototype.prependListener=function(e,t){return _addListener(this,e,t,!0)},EventEmitter.prototype.once=function(e,t){return checkListener(t),this.on(e,_onceWrap(this,e,t)),this},EventEmitter.prototype.prependOnceListener=function(e,t){return checkListener(t),this.prependListener(e,_onceWrap(this,e,t)),this},EventEmitter.prototype.removeListener=function(e,t){var n,o,i,s,c;if(checkListener(t),void 0===(o=this._events)||void 0===(n=o[e]))return this;if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete o[e],o.removeListener&&this.emit
20("removeListener",e,n.listener||t));else if("function"!=typeof n){for(i=-1,s=n.length-1;s>=0;s--)if(n[s]===t||n[s].listener===t){c=n[s].listener,i=s;break}if(i<0)return this;0===i?n.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(n,i),1===n.length&&(o[e]=n[0]),void 0!==o.removeListener&&this.emit("removeListener",e,c||t)}return this},EventEmitter.prototype.off=EventEmitter.prototype.removeListener,EventEmitter.prototype.removeAllListeners=function(e){var t,n,o;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0==arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0==arguments.length){var i,s=Object.keys(n);for(o=0;o<s.length;++o)"removeListener"!==(i=s[o])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(o=t.length-1;o>=0;o--)this.removeListener(e,t[o]);return this},EventEmitter.prototype.listeners=function(e){return _listeners(this,e,!0)},EventEmitter.prototype.rawListeners=function(e){return _listeners(this,e,!1)},EventEmitter.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):listenerCount.call(e,t)},EventEmitter.prototype.listenerCount=listenerCount,EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},92806:function(e){"use strict";e.exports=function(e,t){for(var n={},o=Object.keys(e),i=Array.isArray(t),s=0;s<o.length;s++){var c=o[s],l=e[c];(i?-1!==t.indexOf(c):t(c,l,e))&&(n[c]=l)}return n}},45711:function(e,t,n){"use strict";n.d(t,{Z:function(){return createLucideIcon}});var o=n(67294),i={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
21 * @license lucide-react v0.363.0 - ISC
22 *
23 * This source code is licensed under the ISC license.
24 * See the LICENSE file in the root directory of this source tree.
25 */let toKebabCase=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),createLucideIcon=(e,t)=>{let n=(0,o.forwardRef)(({color:n="currentColor",size:s=24,strokeWidth:c=2,absoluteStrokeWidth:l,className:u="",children:d,...p},m)=>(0,o.createElement)("svg",{ref:m,...i,width:s,height:s,stroke:n,strokeWidth:l?24*Number(c)/Number(s):c,className:["lucide",`lucide-${toKebabCase(e)}`,u].join(" "),...p},[...t.map(([e,t])=>(0,o.createElement)(e,t)),...Array.isArray(d)?d:[d]]));return n.displayName=`${e}`,n}},41352:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var o=n(45711);/**
26 * @license lucide-react v0.363.0 - ISC
27 *
28 * This source code is licensed under the ISC license.
29 * See the LICENSE file in the root directory of this source tree.
30 */let i=(0,o.Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},83454:function(e,t,n){"use strict";var o,i;e.exports=(null==(o=n.g.process)?void 0:o.env)&&"object"==typeof(null==(i=n.g.process)?void 0:i.env)?n.g.process:n(77663)},6840:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return n(39964)}])},13474:function(e,t,n){"use strict";n.d(t,{pm:function(){return useToast}});var o=n(67294);let i=0,s=new Map,addToRemoveQueue=e=>{if(s.has(e))return;let t=setTimeout(()=>{s.delete(e),dispatch({type:"REMOVE_TOAST",toastId:e})},1e6);s.set(e,t)},reducer=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,1)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case"DISMISS_TOAST":{let{toastId:n}=t;return n?addToRemoveQueue(n):e.toasts.forEach(e=>{addToRemoveQueue(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===n||void 0===n?{...e,open:!1}:e)}}case"REMOVE_TOAST":if(void 0===t.toastId)return{...e,toasts:[]};return{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)}}},c=[],l={toasts:[]};function dispatch(e){l=reducer(l,e),c.forEach(e=>{e(l)})}function toast(e){let{...t}=e,n=(i=(i+1)%Number.MAX_SAFE_INTEGER).toString(),dismiss=()=>
30dispatch({type:"DISMISS_TOAST",toastId:n});return dispatch({type:"ADD_TOAST",toast:{...t,id:n,open:!0,onOpenChange:e=>{e||dismiss()}}}),{id:n,dismiss,update:e=>dispatch({type:"UPDATE_TOAST",toast:{...e,id:n}})}}function useToast(){let[e,t]=o.useState(l);return o.useEffect(()=>(c.push(t),()=>{let e=c.indexOf(t);e>-1&&c.splice(e,1)}),[e]),{...e,toast,dismiss:e=>dispatch({type:"DISMISS_TOAST",toastId:e})}}},97537:function(e,t,n){"use strict";n.d(t,{cn:function(){return cn}});var o=n(90512);let i=/^\[(.+)\]$/;function getPart(e,t){let n=e;return t.split("-").forEach(e=>{n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)}),n}let s=/\s+/;function twJoin(){let e,t,n=0,o="";for(;n<arguments.length;)(e=arguments[n++])&&(t=function toValue(e){let t;if("string"==typeof e)return e;let n="";for(let o=0;o<e.length;o++)e[o]&&(t=toValue(e[o]))&&(n&&(n+=" "),n+=t);return n}(e))&&(o&&(o+=" "),o+=t);return o}function fromTheme(e){let themeGetter=t=>t[e]||[];return themeGetter.isThemeGetter=!0,themeGetter}let c=/^\[(?:([a-z-]+):)?(.+)\]$/i,l=/^\d+\/\d+$/,u=new Set(["px","full","screen"]),d=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,p=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,m=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,b=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,g=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;function isLength(e){return isNumber(e)||u.has(e)||l.test(e)}function isArbitraryLength(e){return getIsArbitraryValue(e,"length",isLengthOnly)}function isNumber(e){return!!e&&!Number.isNaN(Number(e))}function isArbitraryNumber(e){return getIsArbitraryValue(e,"number",isNumber)}function isInteger(e){return!!e&&Number.isInteger(Number(e))}function isPercent(e){return e.endsWith("%")&&isNumber(e.slice(0,-1))}function isArbitraryValue(e){return c.test(e)}function isTshirtSize(e){return d.test(e)}let y=new Set(["length","size","percentage"]);function isArbitrarySize(e){return getIsArbitraryValue(e,y,isNever)}function isArbitraryPosition(e){return getIsArbitraryValue(e,"position",isNever)}let v=new Set(["image","url"]);function isArbitraryImage(e){return getIsArbitraryValue(e,v,isImage)}function isArbitraryShadow(e){return getIsArbitraryValue(e,"",isShadow)}function isAny(){return!0}function getIsArbitraryValue(e,t,n){let o=c.exec(e);return!!o&&(o[1]?"string"==typeof t?o[1]===t:t.has(o[1]):n(o[2]))}function isLengthOnly(e){return p.test(e)&&!m.test(e)}function isNever(){return!1}function isShadow(e){return b.test(e)}function isImage(e){return g.test(e)}let E=function(e){let t,n,o;let functionToCall=function(s){let c=[].reduce((e,t)=>t(e),e());return n=(t={cache:function(e){if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=new Map,o=new Map;function update(i,s){n.set(i,s),++t>e&&(t=0,o=n,n=new Map)}return{get(e){let t=n.get(e);return void 0!==t?t:void 0!==(t=o.get(e))?(update(e,t),t):void 0},set(e,t){n.has(e)?n.set(e,t):update(e,t)}}}(c.cacheSize),splitModifiers:function(e){let t=e.separator,n=1===t.length,o=t[0],i=t.length;return function(e){let s;let c=[],l=0,u=0;for(let d=0;d<e.length;d++){let p=e[d];if(0===l){if(p===o&&(n||e.slice(d,d+i)===t)){c.push(e.slice(u,d)),u=d+i;continue}if("/"===p){s=d;continue}}"["===p?l++:"]"===p&&l--}let d=0===c.length?e:e.substring(u),p=d.startsWith("!"),m=p?d.substring(1):d,b=s&&s>u?s-u:void 0;return{modifiers:c,hasImportantModifier:p,baseClassName:m,maybePostfixModifierPosition:b}}}(c),...function(e){let t=function(e){var t;let{theme:n,prefix:o}=e,i={nextPart:new Map,validators:[]},s=(t=Object.entries(e.classGroups),o?t.map(([e,t])=>{let n=t.map(e=>"string"==typeof e?o+e:"object"==typeof e?Object.fromEntries(Object.entries(e).map(([e,t])=>[o+e,t])):e);return[e,n]}):t);return s.forEach(([e,t])=>{(function processClassesRecursively(e,t,n,o){e.forEach(e=>{if("string"==typeof e){let o=""===e?t:getPart(t,e);o.classGroupId=n;return}if("function"==typeof e){if(e.isThemeGetter){processClassesRecursively(e(o),t,n,o);return}t.validators.push({validator:e,classGroupId:n});return}Object.entries(e).forEach(([e,i])=>{processClassesRecursively(i,getPart(t,e),n,o)})})})(t,i,e,n)}),i}(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:function(e){let n=e.split("-");return""===n[0]&&1!==n.length&&n.shift(),function getGroupRecursive(e,t){if(0===e.length)return t.classGroupId;let n=e[0],o=t.nextPart.get(n),i=o?getGroupRecursive(e.slice(1),o):void 0;if(i)return i;if(0===t.validators.length)return;let s=e.join("-");return t.validators.find(({validator:e})=>e(s))?.classGroupId}(n,t)||function(e){if(i.test(e)){let t=i.exec(e)[1],n=t?.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}}(e)},getConflictingClassGroupIds:function(e,t){let i=n[e]||[];return t&&o[e]?[...i,...o[e]]:i}}}(c)}).cache.get,o=t.cache.set,functionToCall=tailwindMerge,tailwindMerge(s)};function tailwindMerge(e){let i=n(e);if(i)return i;let c=function(e,t){let{splitModifiers:n,getClassGroupId:o,getConflictingClassGroupIds:i}=t,c=new Set;return e.trim().split(s).map(e=>{let{modifiers:t,hasImportantModifier:i,baseClassName:s,maybePostfixModifierPosition:c}=n(e),l=o(c?s.substring(0,c):s),u=!!c;if(!l){if(!c||!(l=o(s)))return{isTailwindClass:!1,originalClassName:e};u=!1}let d=(function(e){if(e.length<=1)return e;let t=[],n=[];
30return e.forEach(e=>{let o="["===e[0];o?(t.push(...n.sort(),e),n=[]):n.push(e)}),t.push(...n.sort()),t})(t).join(":");return{isTailwindClass:!0,modifierId:i?d+"!":d,classGroupId:l,originalClassName:e,hasPostfixModifier:u}}).reverse().filter(e=>{if(!e.isTailwindClass)return!0;let{modifierId:t,classGroupId:n,hasPostfixModifier:o}=e,s=t+n;return!c.has(s)&&(c.add(s),i(n,o).forEach(e=>c.add(t+e)),!0)}).reverse().map(e=>e.originalClassName).join(" ")}(e,t);return o(e,c),c}return function(){return functionToCall(twJoin.apply(null,arguments))}}(function(){let e=fromTheme("colors"),t=fromTheme("spacing"),n=fromTheme("blur"),o=fromTheme("brightness"),i=fromTheme("borderColor"),s=fromTheme("borderRadius"),c=fromTheme("borderSpacing"),l=fromTheme("borderWidth"),u=fromTheme("contrast"),d=fromTheme("grayscale"),p=fromTheme("hueRotate"),m=fromTheme("invert"),b=fromTheme("gap"),g=fromTheme("gradientColorStops"),y=fromTheme("gradientColorStopPositions"),v=fromTheme("inset"),E=fromTheme("margin"),x=fromTheme("opacity"),P=fromTheme("padding"),_=fromTheme("saturate"),I=fromTheme("scale"),j=fromTheme("sepia"),R=fromTheme("skew"),M=fromTheme("space"),F=fromTheme("translate"),getOverscroll=()=>["auto","contain","none"],getOverflow=()=>["auto","hidden","clip","visible","scroll"],getSpacingWithAutoAndArbitrary=()=>["auto",isArbitraryValue,t],getSpacingWithArbitrary=()=>[isArbitraryValue,t],getLengthWithEmptyAndArbitrary=()=>["",isLength,isArbitraryLength],getNumberWithAutoAndArbitrary=()=>["auto",isNumber,isArbitraryValue],getPositions=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],getLineStyles=()=>["solid","dashed","dotted","double","none"],getBlendModes=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"],getAlign=()=>["start","end","center","between","around","evenly","stretch"],getZeroAndEmpty=()=>["","0",isArbitraryValue],getBreaks=()=>["auto","avoid","all","avoid-page","page","left","right","column"],getNumber=()=>[isNumber,isArbitraryNumber],getNumberAndArbitrary=()=>[isNumber,isArbitraryValue];return{cacheSize:500,separator:":",theme:{colors:[isAny],spacing:[isLength,isArbitraryLength],blur:["none","",isTshirtSize,isArbitraryValue],brightness:getNumber(),borderColor:[e],borderRadius:["none","","full",isTshirtSize,isArbitraryValue],borderSpacing:getSpacingWithArbitrary(),borderWidth:getLengthWithEmptyAndArbitrary(),contrast:getNumber(),grayscale:getZeroAndEmpty(),hueRotate:getNumberAndArbitrary(),invert:getZeroAndEmpty(),gap:getSpacingWithArbitrary(),gradientColorStops:[e],gradientColorStopPositions:[isPercent,isArbitraryLength],inset:getSpacingWithAutoAndArbitrary(),margin:getSpacingWithAutoAndArbitrary(),opacity:getNumber(),padding:getSpacingWithArbitrary(),saturate:getNumber(),scale:getNumber(),sepia:getZeroAndEmpty(),skew:getNumberAndArbitrary(),space:getSpacingWithArbitrary(),translate:getSpacingWithArbitrary()},classGroups:{aspect:[{aspect:["auto","square","video",isArbitraryValue]}],container:["container"],columns:[{columns:[isTshirtSize]}],"break-after":[{"break-after":getBreaks()}],"break-before":[{"break-before":getBreaks()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...getPositions(),isArbitraryValue]}],overflow:[{overflow:getOverflow()}],"overflow-x":[{"overflow-x":getOverflow()}],"overflow-y":[{"overflow-y":getOverflow()}],overscroll:[{overscroll:getOverscroll()}],"overscroll-x":[{"overscroll-x":getOverscroll()}],"overscroll-y":[{"overscroll-y":getOverscroll()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}
vendor: 7,230 bytes, line 30
30],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",isInteger,isArbitraryValue]}],basis:[{basis:getSpacingWithAutoAndArbitrary()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",isArbitraryValue]}],grow:[{grow:getZeroAndEmpty()}],shrink:[{shrink:getZeroAndEmpty()}],order:[{order:["first","last","none",isInteger,isArbitraryValue]}],"grid-cols":[{"grid-cols":[isAny]}],"col-start-end":[{col:["auto",{span:["full",isInteger,isArbitraryValue]},isArbitraryValue]}],"col-start":[{"col-start":getNumberWithAutoAndArbitrary()}],"col-end":[{"col-end":getNumberWithAutoAndArbitrary()}],"grid-rows":[{"grid-rows":[isAny]}],"row-start-end":[{row:["auto",{span:[isInteger,isArbitraryValue]},isArbitraryValue]}],"row-start":[{"row-start":getNumberWithAutoAndArbitrary()}],"row-end":[{"row-end":getNumberWithAutoAndArbitrary()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",isArbitraryValue]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",isArbitraryValue]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...getAlign()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...getAlign(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...getAlign(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[P]}],px:[{px:[P]}],py:[{py:[P]}],ps:[{ps:[P]}],pe:[{pe:[P]}],pt:[{pt:[P]}],pr:[{pr:[P]}],pb:[{pb:[P]}],pl:[{pl:[P]}],m:[{m:[E]}],mx:[{mx:[E]}],my:[{my:[E]}],ms:[{ms:[E]}],me:[{me:[E]}],mt:[{mt:[E]}],mr:[{mr:[E]}],mb:[{mb:[E]}],ml:[{ml:[E]}],"space-x":[{"space-x":[M]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[M]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",isArbitraryValue,t]}],"min-w":[{"min-w":[isArbitraryValue,t,"min","max","fit"]}],"max-w":[{"max-w":[isArbitraryValue,t,"none","full","min","max","fit","prose",{screen:[isTshirtSize]},isTshirtSize]}],h:[{h:[isArbitraryValue,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[isArbitraryValue,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[isArbitraryValue,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[isArbitraryValue,t,"auto","min","max","fit"]}],"font-size":[{text:["base",isTshirtSize,isArbitraryLength]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",isArbitraryNumber]}],"font-family":[{font:[isAny]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",isArbitraryValue]}],"line-clamp":[{"line-clamp":["none",isNumber,isArbitraryNumber]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",isLength,isArbitraryValue]}],"list-image":[{"list-image":["none",isArbitraryValue]}],"list-style-type":[{list:["none","disc","decimal",isArbitraryValue]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[x]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[x]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...getLineStyles(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",isLength,isArbitraryLength]}],"underline-offset":[{"underline-offset":["auto",isLength,isArbitraryValue]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:getSpacingWithArbitrary()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",isArbitraryValue]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",isArbitraryValue]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[x]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...getPositions(),isArbitraryPosition]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",isArbitrarySize]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},isArbitraryImage]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[y]}],"gradient-via-pos":[{via:[y]}],"gradient-to-pos":[{to:[y]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-to":[{to:[g]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[x]}],"border-style":[{border:[...getLineStyles(),"hidden"]}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[x]}],"divide-style":[{divide:getLineStyles()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...getLineStyles()]}],"outline-offset":[{"outline-offset":[isLength,isArbitraryValue]}],"outline-w":[{outline:[isLength,isArbitraryLength]}],"outline-color":[{outline:[e]}
vendor: 4,092 bytes, line 30
30],"ring-w":[{ring:getLengthWithEmptyAndArbitrary()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[x]}],"ring-offset-w":[{"ring-offset":[isLength,isArbitraryLength]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",isTshirtSize,isArbitraryShadow]}],"shadow-color":[{shadow:[isAny]}],opacity:[{opacity:[x]}],"mix-blend":[{"mix-blend":getBlendModes()}],"bg-blend":[{"bg-blend":getBlendModes()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[o]}],contrast:[{contrast:[u]}],"drop-shadow":[{"drop-shadow":["","none",isTshirtSize,isArbitraryValue]}],grayscale:[{grayscale:[d]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[m]}],saturate:[{saturate:[_]}],sepia:[{sepia:[j]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[u]}],"backdrop-grayscale":[{"backdrop-grayscale":[d]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[m]}],"backdrop-opacity":[{"backdrop-opacity":[x]}],"backdrop-saturate":[{"backdrop-saturate":[_]}],"backdrop-sepia":[{"backdrop-sepia":[j]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-y":[{"border-spacing-y":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",isArbitraryValue]}],duration:[{duration:getNumberAndArbitrary()}],ease:[{ease:["linear","in","out","in-out",isArbitraryValue]}],delay:[{delay:getNumberAndArbitrary()}],animate:[{animate:["none","spin","ping","pulse","bounce",isArbitraryValue]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-x":[{"scale-x":[I]}],"scale-y":[{"scale-y":[I]}],rotate:[{rotate:[isInteger,isArbitraryValue]}],"translate-x":[{"translate-x":[F]}],"translate-y":[{"translate-y":[F]}],"skew-x":[{"skew-x":[R]}],"skew-y":[{"skew-y":[R]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",isArbitraryValue]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",isArbitraryValue]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":getSpacingWithArbitrary()}],"scroll-mx":[{"scroll-mx":getSpacingWithArbitrary()}],"scroll-my":[{"scroll-my":getSpacingWithArbitrary()}],"scroll-ms":[{"scroll-ms":getSpacingWithArbitrary()}],"scroll-me":[{"scroll-me":getSpacingWithArbitrary()}],"scroll-mt":[{"scroll-mt":getSpacingWithArbitrary()}],"scroll-mr":[{"scroll-mr":getSpacingWithArbitrary()}],"scroll-mb":[{"scroll-mb":getSpacingWithArbitrary()}],"scroll-ml":[{"scroll-ml":getSpacingWithArbitrary()}],"scroll-p":[{"scroll-p":getSpacingWithArbitrary()}],"scroll-px":[{"scroll-px":getSpacingWithArbitrary()}],"scroll-py":[{"scroll-py":getSpacingWithArbitrary()}],"scroll-ps":[{"scroll-ps":getSpacingWithArbitrary()}],"scroll-pe":[{"scroll-pe":getSpacingWithArbitrary()}],"scroll-pt":[{"scroll-pt":getSpacingWithArbitrary()}],"scroll-pr":[{"scroll-pr":getSpacingWithArbitrary()}],"scroll-pb":[{"scroll-pb":getSpacingWithArbitrary()}],"scroll-pl":[{"scroll-pl":getSpacingWithArbitrary()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
30],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",isArbitraryValue]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[isLength,isArbitraryLength,isArbitraryNumber]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}});function cn(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return E((0,o.W)(t))}},39964:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return App}});var o=n(85893);n(32352),n(56953);var i=n(91547),s=n(87403),c=n(69077),l=n(67294),u=n(87462),d=n(73935),p=n(36206),m=n(28771),b=n(65936),g=n(25360),y=n(46063),v=n(42651),E=n(29115),x=n(75320),P=n(79698),_=n(77342),I=n(9981),j=n(96219);let R="ToastProvider",[M,F,q]=(0,b.B)("Toast"),[H,z]=(0,g.b)("Toast",[q]),[W,K]=H(R),$054eb8030ebde76e$export$f5d03d415824e0e=e=>{let{__scopeToast:t,label:n="Notification",duration:o=5e3,swipeDirection:i="right",swipeThreshold:s=50,children:c}=e,[u,d]=(0,l.useState)(null),[p,m]=(0,l.useState)(0),b=(0,l.useRef)(!1),g=(0,l.useRef)(!1);return(0,l.createElement)(M.Provider,{scope:t},(0,l.createElement)(W,{scope:t,label:n,duration:o,swipeDirection:i,swipeThreshold:s,toastCount:p,viewport:u,onViewportChange:d,onToastAdd:(0,l.useCallback)(()=>m(e=>e+1),[]),onToastRemove:(0,l.useCallback)(()=>m(e=>e-1),[]),isFocusedToastEscapeKeyDownRef:b,isClosePausedRef:g},c))};$054eb8030ebde76e$export$f5d03d415824e0e.propTypes={label(e){if(e.label&&"string"==typeof e.label&&!e.label.trim()){let e=`Invalid prop \`label\` supplied to \`${R}\`. Expected non-empty \`string\`.`;return Error(e)}return null}};let Q=["F8"],Z="toast.viewportPause",X="toast.viewportResume",Y=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,hotkey:o=Q,label:i="Notifications ({hotkey})",...s}=e,c=K("ToastViewport",n),d=F(n),p=(0,l.useRef)(null),b=(0,l.useRef)(null),g=(0,l.useRef)(null),v=(0,l.useRef)(null),E=(0,m.e)(t,v,c.onViewportChange),P=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),_=c.toastCount>0;(0,l.useEffect)(()=>{let handleKeyDown=e=>{var t;let n=o.every(t=>e[t]||e.code===t);n&&(null===(t=v.current)||void 0===t||t.focus())};return document.addEventListener("keydown",handleKeyDown),()=>document.removeEventListener("keydown",handleKeyDown)},[o]),(0,l.useEffect)(()=>{let e=p.current,t=v.current;if(_&&e&&t){let handlePause=()=>{if(!c.isClosePausedRef.current){let e=new CustomEvent(Z);t.dispatchEvent(e),c.isClosePausedRef.current=!0}},handleResume=()=>{if(c.isClosePausedRef.current){let e=new CustomEvent(X);t.dispatchEvent(e),c.isClosePausedRef.current=!1}},handleFocusOutResume=t=>{let n=!e.contains(t.relatedTarget);n&&handleResume()},handlePointerLeaveResume=()=>{let t=e.contains(document.activeElement);t||handleResume()};return e.addEventListener("focusin",handlePause),e.addEventListener("focusout",handleFocusOutResume),e.addEventListener("pointermove",handlePause),e.addEventListener("pointerleave",handlePointerLeaveResume),window.addEventListener("blur",handlePause),window.addEventListener("focus",handleResume),()=>{e.removeEventListener("focusin",handlePause),e.removeEventListener("focusout",handleFocusOutResume),e.removeEventListener("pointermove",handlePause),e.removeEventListener("pointerleave",handlePointerLeaveResume),window.removeEventListener("blur",handlePause),window.removeEventListener("focus",handleResume)}}},[_,c.isClosePausedRef]);let I=(0,l.useCallback)(({tabbingDirection:e})=>{let t=d(),n=t.map(t=>{let n=t.ref.current,o=[n,...function(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}(n)];return"forwards"===e?o:o.reverse()});return("forwards"===e?n.reverse():n).flat()},[d]);return(0,l.useEffect)(()=>{let e=v.current;if(e){let handleKeyDown=t=>{let n=t.altKey||t.ctrlKey||t.metaKey,o="Tab"===t.key&&!n;if(o){var i,s,c;let n=document.activeElement,o=t.shiftKey,l=t.target===e;if(l&&o){null===(i=b.current)||void 0===i||i.focus();return}let u=I({tabbingDirection:o?"backwards":"forwards"}),d=u.findIndex(e=>e===n);$054eb8030ebde76e$var$focusFirst(u.slice(d+1))?t.preventDefault():o?null===(s=b.current)||void 0===s||s.focus():null===(c=g.current)||void 0===c||c.focus()}};return e.addEventListener("keydown",handleKeyDown),()=>e.removeEventListener("keydown",handleKeyDown)}},[d,I]),(0,l.createElement)(y.I0,{ref:p,role:"region","aria-label":i.replace("{hotkey}",P),tabIndex:-1,style:{pointerEvents:_?void 0:"none"}},_&&(0,l.createElement)(J,{ref:b,onFocusFromOutsideViewport:()=>{let e=I({tabbingDirection:"forwards"});$054eb8030ebde76e$var$focusFirst(e)}}),(0,l.createElement)(M.Slot,{scope:n},(0,l.createElement)(x.WV.ol,(0,u.Z)({tabIndex:-1},s,{ref:E}))),_&&(0,l.createElement)(J,{ref:g,onFocusFromOutsideViewport:()=>{let e=I({tabbingDirection:"backwards"});$054eb8030ebde76e$var$focusFirst(e)}}))}),J=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,onFocusFromOutsideViewport:o,...i}=e,s=K("ToastFocusProxy",n);return(0,l.createElement)(j.T,(0,u.Z)({"aria-hidden":!0,tabIndex:0},i,{ref:t,style:{position:"fixed"},onFocus:e=>{var t;let n=e.relatedTarget,i=!(null!==(t=s.viewport)&&void 0!==t&&t.contains(n));i&&o()}}))}),et="Toast",eo=(0,l.forwardRef)((e,t)=>{let{forceMount:n,open:o,defaultOpen:i,onOpenChange:s,...c}=e,[d=!0,m]=(0,_.T)({prop:o,defaultProp:i,onChange:s});return(0,l.createElement)(E.z,{present:n||d},(0,l.createElement)(es,(0,u.Z)({open:d},c,{ref:t,onClose:()=>m(!1),onPause:(0,P.W)(e.onPause),onResume:(0,P.W)(e.onResume),onSwipeStart:(0,p.M)(e.onSwipeStart,e=>{e.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:(0,p.M)(e.onSwipeMove,e=>{let{x:t,y:n}=e.detail.delta;e.currentTarget.setAttribute("data-swipe","move"),e.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${t}px`),e.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${n}px`)}
30),onSwipeCancel:(0,p.M)(e.onSwipeCancel,e=>{e.currentTarget.setAttribute("data-swipe","cancel"),e.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),e.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),e.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),e.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:(0,p.M)(e.onSwipeEnd,e=>{let{x:t,y:n}=e.detail.delta;e.currentTarget.setAttribute("data-swipe","end"),e.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),e.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),e.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${t}px`),e.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${n}px`),m(!1)})})))}),[ea,ei]=H(et,{onClose(){}}),es=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,type:o="foreground",duration:i,open:s,onClose:c,onEscapeKeyDown:b,onPause:g,onResume:v,onSwipeStart:E,onSwipeMove:_,onSwipeCancel:I,onSwipeEnd:j,...R}=e,F=K(et,n),[q,H]=(0,l.useState)(null),z=(0,m.e)(t,e=>H(e)),W=(0,l.useRef)(null),Q=(0,l.useRef)(null),Y=i||F.duration,J=(0,l.useRef)(0),eo=(0,l.useRef)(Y),ei=(0,l.useRef)(0),{onToastAdd:es,onToastRemove:ec}=F,el=(0,P.W)(()=>{var e;let t=null==q?void 0:q.contains(document.activeElement);t&&(null===(e=F.viewport)||void 0===e||e.focus()),c()}),eu=(0,l.useCallback)(e=>{e&&e!==1/0&&(window.clearTimeout(ei.current),J.current=new Date().getTime(),ei.current=window.setTimeout(el,e))},[el]);(0,l.useEffect)(()=>{let e=F.viewport;if(e){let handleResume=()=>{eu(eo.current),null==v||v()},handlePause=()=>{let e=new Date().getTime()-J.current;eo.current=eo.current-e,window.clearTimeout(ei.current),null==g||g()};return e.addEventListener(Z,handlePause),e.addEventListener(X,handleResume),()=>{e.removeEventListener(Z,handlePause),e.removeEventListener(X,handleResume)}}},[F.viewport,Y,g,v,eu]),(0,l.useEffect)(()=>{s&&!F.isClosePausedRef.current&&eu(Y)},[s,Y,F.isClosePausedRef,eu]),(0,l.useEffect)(()=>(es(),()=>ec()),[es,ec]);let ed=(0,l.useMemo)(()=>q?function $054eb8030ebde76e$var$getAnnounceTextContent(e){let t=[],n=Array.from(e.childNodes);return n.forEach(e=>{if(e.nodeType===e.TEXT_NODE&&e.textContent&&t.push(e.textContent),e.nodeType===e.ELEMENT_NODE){let n=e.ariaHidden||e.hidden||"none"===e.style.display,o=""===e.dataset.radixToastAnnounceExclude;if(!n){if(o){let n=e.dataset.radixToastAnnounceAlt;n&&t.push(n)}else t.push(...$054eb8030ebde76e$var$getAnnounceTextContent(e))}}}),t}(q):null,[q]);return F.viewport?(0,l.createElement)(l.Fragment,null,ed&&(0,l.createElement)($054eb8030ebde76e$var$ToastAnnounce,{__scopeToast:n,role:"status","aria-live":"foreground"===o?"assertive":"polite","aria-atomic":!0},ed),(0,l.createElement)(ea,{scope:n,onClose:el},(0,d.createPortal)((0,l.createElement)(M.ItemSlot,{scope:n},(0,l.createElement)(y.fC,{asChild:!0,onEscapeKeyDown:(0,p.M)(b,()=>{F.isFocusedToastEscapeKeyDownRef.current||el(),F.isFocusedToastEscapeKeyDownRef.current=!1})},(0,l.createElement)(x.WV.li,(0,u.Z)({role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":s?"open":"closed","data-swipe-direction":F.swipeDirection},R,{ref:z,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:(0,p.M)(e.onKeyDown,e=>{"Escape"!==e.key||(null==b||b(e.nativeEvent),e.nativeEvent.defaultPrevented||(F.isFocusedToastEscapeKeyDownRef.current=!0,el()))}),onPointerDown:(0,p.M)(e.onPointerDown,e=>{0===e.button&&(W.current={x:e.clientX,y:e.clientY})}),onPointerMove:(0,p.M)(e.onPointerMove,e=>{if(!W.current)return;let t=e.clientX-W.current.x,n=e.clientY-W.current.y,o=!!Q.current,i=["left","right"].includes(F.swipeDirection),s=["left","up"].includes(F.swipeDirection)?Math.min:Math.max,c=i?s(0,t):0,l=i?0:s(0,n),u="touch"===e.pointerType?10:2,d={x:c,y:l},p={originalEvent:e,delta:d};o?(Q.current=d,$054eb8030ebde76e$var$handleAndDispatchCustomEvent("toast.swipeMove",_,p,{discrete:!1})):$054eb8030ebde76e$var$isDeltaInDirection(d,F.swipeDirection,u)?(Q.current=d,$054eb8030ebde76e$var$handleAndDispatchCustomEvent("toast.swipeStart",E,p,{discrete:!1}),e.target.setPointerCapture(e.pointerId)):(Math.abs(t)>u||Math.abs(n)>u)&&(W.current=null)}),onPointerUp:(0,p.M)(e.onPointerUp,e=>{let t=Q.current,n=e.target;if(n.hasPointerCapture(e.pointerId)&&n.releasePointerCapture(e.pointerId),Q.current=null,W.current=null,t){let n=e.currentTarget,o={originalEvent:e,delta:t};$054eb8030ebde76e$var$isDeltaInDirection(t,F.swipeDirection,F.swipeThreshold)?$054eb8030ebde76e$var$handleAndDispatchCustomEvent("toast.swipeEnd",j,o,{discrete:!0}):$054eb8030ebde76e$var$handleAndDispatchCustomEvent("toast.swipeCancel",I,o,{discrete:!0}),n.addEventListener("click",e=>e.preventDefault(),{once:!0})}})})))),F.viewport))):null});es.propTypes={type(e){if(e.type&&!["foreground","background"].includes(e.type)){let e=`Invalid prop \`type\` supplied to \`${et}\`. Expected \`foreground | background\`.`;return Error(e)}return null}};let $054eb8030ebde76e$var$ToastAnnounce=e=>{let{__scopeToast:t,children:n,...o}=e,i=K(et,t),[s,c]=(0,l.useState)(!1),[u,d]=(0,l.useState)(!1);return function(e=()=>{}){let t=(0,P.W)(e);(0,I.b)(()=>{let e=0,n=0;return e=window.requestAnimationFrame(()=>n=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(e),window.cancelAnimationFrame(n)}},[t])}(()=>c(!0)),(0,l.useEffect)(()=>{let e=window.setTimeout(()=>d(!0),1e3);return()=>window.clearTimeout(e)},[]),u?null:(0,l.createElement)(v.h,{asChild:!0},(0,l.createElement)(j.T,o,s&&(0,l.createElement)(l.Fragment,null,i.label," ",n)))},ec=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,...o}=e;return(0,l.createElement)(x.WV.div,(0,u.Z)({},o,{ref:t}))}),el=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,...o}=e;return(0,l.createElement)(x.WV.div,(0,u.Z)({},o,{ref:t}))}),eu=(0,l.forwardRef)((e,t)=>{let{altText:n,...o}=e;return n?(0,l.createElement)(ef,{altText:n,asChild:!0},(0,l.createElement)(ed,(0,u.Z)({},o,{ref:t}))):null});eu.propTypes={altText:e=>e.altText?null:Error("Missing prop `altText` expected on `ToastAction`")};let ed=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,...o}=e,i=ei("ToastClose",n);return(0,l.createElement)(ef,{asChild:!0},(0,l.createElement)(x.WV.button,(0,u.Z)({type:"button"},o,{ref:t,onClick:(0,p.M)(e.onClick,i.onClose)})))}),ef=(0,l.forwardRef)((e,t)=>{let{__scopeToast:n,altText:o,...i}=e;return(0,l.createElement)(x.WV.div,(0,u.Z)({"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":o||void 0},i,{ref:t}))});function $054eb8030ebde76e$var$handleAndDispatchCustomEvent(e,t,n,{discrete:o}){let i=n.originalEvent.currentTarget,s=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),o?(0,x.jH)(i,s):i.dispatchEvent(s)}let $054eb8030ebde76e$var$isDeltaInDirection=(e,t,n=0)=>{let o=Math.abs(e.x),i=Math.abs(e.y),s=o>i;return"left"===t||"right"===t?s&&o>n:!s&&i>n};function $054eb8030ebde76e$var$focusFirst(e){let t=document.activeElement;return e.some(e=>e===t||(e.focus(),document.activeElement!==t))}var ep=n(45139),eh=n(41352),em=n(97537);let eb=l.forwardRef((e,t)=>
30{let{className:n,...i}=e;return(0,o.jsx)(Y,{ref:t,className:(0,em.cn)("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",n),...i})});eb.displayName=Y.displayName;let eg=(0,ep.j)("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),ey=l.forwardRef((e,t)=>{let{className:n,variant:i,...s}=e;return(0,o.jsx)(eo,{ref:t,className:(0,em.cn)(eg({variant:i}),n),...s})});ey.displayName=eo.displayName;let ev=l.forwardRef((e,t)=>{let{className:n,...i}=e;return(0,o.jsx)(eu,{ref:t,className:(0,em.cn)("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors hover:bg-secondary focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",n),...i})});ev.displayName=eu.displayName;let ew=l.forwardRef((e,t)=>{let{className:n,...i}=e;return(0,o.jsx)(ed,{ref:t,className:(0,em.cn)("absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",n),"toast-close":"",...i,children:(0,o.jsx)(eh.Z,{className:"h-4 w-4"})})});ew.displayName=ed.displayName;let eE=l.forwardRef((e,t)=>{let{className:n,...i}=e;return(0,o.jsx)(ec,{ref:t,className:(0,em.cn)("text-sm font-semibold",n),...i})});eE.displayName=ec.displayName;let ex=l.forwardRef((e,t)=>{let{className:n,...i}=e;return(0,o.jsx)(el,{ref:t,className:(0,em.cn)("text-sm opacity-90",n),...i})});ex.displayName=el.displayName;var eC=n(13474);function Toaster(){let{toasts:e}=(0,eC.pm)();return(0,o.jsxs)($054eb8030ebde76e$export$f5d03d415824e0e,{children:[e.map(function(e){let{id:t,title:n,description:i,action:s,...c}=e;return(0,o.jsxs)(ey,{...c,children:[(0,o.jsxs)("div",{className:"grid gap-1",children:[n&&(0,o.jsx)(eE,{children:n}),i&&(0,o.jsx)(ex,{children:i})]}),s,(0,o.jsx)(ew,{})]},t)}),(0,o.jsx)(eb,{})]})}var eP=n(60481),eT=n(81782);let{chains:eA,publicClient:eS}=(0,eP.QB)([eT.v8,{id:421614,name:"Arbitrum Sepolia",network:"arbitrum",nativeCurrency:{decimals:18,name:"Arbitrum Sepolia Ether",symbol:"ETH"},rpcUrls:{public:{http:[]}
30,default:{http:["https://sepolia-rollup.arbitrum.io/rpc"]}},blockExplorers:{default:{name:"Arbiscan",url:"https://sepolia.arbiscan.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:81930}},testnet:!0},eT.P7],[function({rpc:e}){return function(t){let n=e(t);return n&&""!==n.http?{chain:{...t,rpcUrls:{...t.rpcUrls,default:{http:[n.http]}}},rpcUrls:{http:[n.http],webSocket:n.webSocket?[n.webSocket]:void 0}}:null}}({rpc:e=>({http:e.rpcUrls.default.http[0]})})]),{connectors:e_}=(0,i.wo)({appName:"GiveAway3",projectId:"f458861edfe9d081b76e150c79144a35",chains:eA}),eI=(0,c._g)({autoConnect:!0,connectors:e_,publicClient:eS}),ek={wagmiConfig:eI,chains:eA};function App(e){let{Component:t,pageProps:n}=e;return(0,o.jsx)(c.eM,{config:ek.wagmiConfig,children:(0,o.jsxs)(i.pj,{chains:ek.chains,theme:(0,s.W)({accentColor:"#dcaac7",accentColorForeground:"white"}),children:[(0,o.jsx)(t,{...n}),(0,o.jsx)(Toaster,{})]})})}},56953:function(){},32352:function(){},77663:function(e){!function(){var t={229:function(e){var t,n,o,i=e.exports={};function defaultSetTimout(){throw Error("setTimeout has not been defined")}function defaultClearTimeout(){throw Error("clearTimeout has not been defined")}function runTimeout(e){if(t===setTimeout)return setTimeout(e,0);if((t===defaultSetTimout||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:defaultSetTimout}catch(e){t=defaultSetTimout}try{n="function"==typeof clearTimeout?clearTimeout:defaultClearTimeout}catch(e){n=defaultClearTimeout}}();var s=[],c=!1,l=-1;function cleanUpNextTick(){c&&o&&(c=!1,o.length?s=o.concat(s):l=-1,s.length&&drainQueue())}function drainQueue(){if(!c){var e=runTimeout(cleanUpNextTick);c=!0;for(var t=s.length;t;){for(o=s,s=[];++l<t;)o&&o[l].run();l=-1,t=s.length}o=null,c=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===defaultClearTimeout||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(e)}}function Item(e,t){this.fun=e,this.array=t}function noop(){}i.nextTick=function(e){var t=Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];s.push(new Item(e,t)),1!==s.length||c||runTimeout(drainQueue)},Item.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=noop,i.addListener=noop,i.once=noop,i.off=noop,i.removeListener=noop,i.removeAllListeners=noop,i.emit=noop,i.prependListener=noop,i.prependOnceListener=noop,i.listeners=function(e){return[]},i.binding=function(e){throw Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw Error("process.chdir is not supported")},i.umask=function(){return 0}}},n={};function __nccwpck_require__(e){var o=n[e];if(void 0!==o)return o.exports;var i=n[e]={exports:{}},s=!0;try{t[e](i,i.exports,__nccwpck_require__),s=!1}finally{s&&delete n[e]}return i.exports}__nccwpck_require__.ab="//";var o=__nccwpck_require__(229);e.exports=o}()},92592:function(e,t,n){let o=n(47138),i=n(95115),s=n(6907),c=n(93776);function renderCanvas(e,t,n,s,c){let l=[].slice.call(arguments,1),u=l.length,d="function"==typeof l[u-1];if(!d&&!o())throw Error("Callback required as last argument");if(d){if(u<2)throw Error("Too few arguments provided");2===u?(c=n,n=t,t=s=void 0):3===u&&(t.getContext&&void 0===c?(c=s,s=void 0):(c=s,s=n,n=t,t=void 0))}else{if(u<1)throw Error("Too few arguments provided");return 1===u?(n=t,t=s=void 0):2!==u||t.getContext||(s=n,n=t,t=void 0),new Promise(function(o,c){try{let c=i.create(n,s);o(e(c,t,s))}catch(e){c(e)}})}try{let o=i.create(n,s);c(null,e(o,t,s))}catch(e){c(e)}}t.create=i.create,t.toCanvas=renderCanvas.bind(null,s.render),t.toDataURL=renderCanvas.bind(null,s.renderToDataURL),t.toString=renderCanvas.bind(null,function(e,t,n){return c.render(e,n)})},47138:function(e){e.exports=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then}},21845:function(e,t,n){let o=n(10242).getSymbolSize;t.getRowColCoords=function(e){if(1===e)return[];let t=Math.floor(e/7)+2,n=o(e),i=145===n?26:2*Math.ceil((n-13)/(2*t-2)),s=[n-7];for(let e=1;e<t-1;e++)s[e]=s[e-1]-i;return s.push(6),s.reverse()},t.getPositions=function(e){let n=[],o=t.getRowColCoords(e),i=o.length;for(let e=0;e<i;e++)for(let t=0;t<i;t++)(0!==e||0!==t)&&(0!==e||t!==i-1)&&(e!==i-1||0!==t)&&n.push([o[e],o[t]]);return n}},8260:function(e,t,n){let o=n(76910),i=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function AlphanumericData(e){this.mode=o.ALPHANUMERIC,this.data=e}AlphanumericData.getBitsLength=function(e){return 11*Math.floor(e/2)+6*(e%2)},AlphanumericData.prototype.getLength=function(){return this.data.length},AlphanumericData.prototype.getBitsLength=function(){return AlphanumericData.getBitsLength(this.data.length)},AlphanumericData.prototype.write=function(e){let t;for(t=0;t+2<=this.data.length;t+=2){let n=45*i.indexOf(this.data[t]);n+=i.indexOf(this.data[t+1]),e.put(n,11)}this.data.length%2&&e.put(i.indexOf(this.data[t]),6)},e.exports=AlphanumericData},97245:function(e){function BitBuffer(){this.buffer=[],this.length=0}BitBuffer.prototype={get:function(e){return(this.buffer[Math.floor(e/8)]>>>7-e%8&1)==1},put:function(e,t){for(let n=0;n<t;n++)this.putBit((e>>>t-n-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(e){let t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}},e.exports=BitBuffer},73280:function(e){function BitMatrix(e){if(!e||e<1)throw Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}BitMatrix.prototype.set=function(e,t,n,o){let i=e*this.size+t;this.data[i]=n,o&&(this.reservedBit[i]=!0)},BitMatrix.prototype.get=function(e,t){return this.data[e*this.size+t]},BitMatrix.prototype.xor=function(e,t,n){this.data[e*this.size+t]^=n},BitMatrix.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]},e.exports=BitMatrix},43424:function(e,t,n){let o=n(62378),i=n(76910);function ByteData(e){this.mode=i.BYTE,"string"==typeof e&&(e=o(e)),this.data=new Uint8Array(e)}ByteData.getBitsLength=function(e){return 8*e},ByteData.prototype.getLength=function(){return this.data.length},ByteData.prototype.getBitsLength=function(){return ByteData.getBitsLength(this.data.length)},ByteData.prototype.write=function(e){for(let t=0,n=this.data.length;t<n;t++)e.put(this.data[t],8)},e.exports=ByteData},35393:function(e,t,n){let o=n(64908),i=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],s=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,
30192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];t.getBlocksCount=function(e,t){switch(t){case o.L:return i[(e-1)*4+0];case o.M:return i[(e-1)*4+1];case o.Q:return i[(e-1)*4+2];case o.H:return i[(e-1)*4+3];default:return}},t.getTotalCodewordsCount=function(e,t){switch(t){case o.L:return s[(e-1)*4+0];case o.M:return s[(e-1)*4+1];case o.Q:return s[(e-1)*4+2];case o.H:return s[(e-1)*4+3];default:return}}},64908:function(e,t){t.L={bit:1},t.M={bit:0},t.Q={bit:3},t.H={bit:2},t.isValid=function(e){return e&&void 0!==e.bit&&e.bit>=0&&e.bit<4},t.from=function(e,n){if(t.isValid(e))return e;try{return function(e){if("string"!=typeof e)throw Error("Param is not a string");let n=e.toLowerCase();switch(n){case"l":case"low":return t.L;case"m":case"medium":return t.M;case"q":case"quartile":return t.Q;case"h":case"high":return t.H;default:throw Error("Unknown EC Level: "+e)}}(e)}catch(e){return n}}},76526:function(e,t,n){let o=n(10242).getSymbolSize;t.getPositions=function(e){let t=o(e);return[[0,0],[t-7,0],[0,t-7]]}},61642:function(e,t,n){let o=n(10242),i=o.getBCHDigit(1335);t.getEncodedBits=function(e,t){let n=e.bit<<3|t,s=n<<10;for(;o.getBCHDigit(s)-i>=0;)s^=1335<<o.getBCHDigit(s)-i;return(n<<10|s)^21522}},69729:function(e,t){let n=new Uint8Array(512),o=new Uint8Array(256);!function(){let e=1;for(let t=0;t<255;t++)n[t]=e,o[e]=t,256&(e<<=1)&&(e^=285);for(let e=255;e<512;e++)n[e]=n[e-255]}(),t.log=function(e){if(e<1)throw Error("log("+e+")");return o[e]},t.exp=function(e){return n[e]},t.mul=function(e,t){return 0===e||0===t?0:n[o[e]+o[t]]}},35442:function(e,t,n){let o=n(76910),i=n(10242);function KanjiData(e){this.mode=o.KANJI,this.data=e}KanjiData.getBitsLength=function(e){return 13*e},KanjiData.prototype.getLength=function(){return this.data.length},KanjiData.prototype.getBitsLength=function(){return KanjiData.getBitsLength(this.data.length)},KanjiData.prototype.write=function(e){let t;for(t=0;t<this.data.length;t++){let n=i.toSJIS(this.data[t]);if(n>=33088&&n<=40956)n-=33088;else if(n>=57408&&n<=60351)n-=49472;else throw Error("Invalid SJIS character: "+this.data[t]+"\nMake sure your charset is UTF-8");n=(n>>>8&255)*192+(255&n),e.put(n,13)}},e.exports=KanjiData},27126:function(e,t){t.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};let n={N1:3,N2:3,N3:40,N4:10};t.isValid=function(e){return null!=e&&""!==e&&!isNaN(e)&&e>=0&&e<=7},t.from=function(e){return t.isValid(e)?parseInt(e,10):void 0},t.getPenaltyN1=function(e){let t=e.size,o=0,i=0,s=0,c=null,l=null;for(let u=0;u<t;u++){i=s=0,c=l=null;for(let d=0;d<t;d++){let t=e.get(u,d);t===c?i++:(i>=5&&(o+=n.N1+(i-5)),c=t,i=1),(t=e.get(d,u))===l?s++:(s>=5&&(o+=n.N1+(s-5)),l=t,s=1)}i>=5&&(o+=n.N1+(i-5)),s>=5&&(o+=n.N1+(s-5))}return o},t.getPenaltyN2=function(e){let t=e.size,o=0;for(let n=0;n<t-1;n++)for(let i=0;i<t-1;i++){let t=e.get(n,i)+e.get(n,i+1)+e.get(n+1,i)+e.get(n+1,i+1);(4===t||0===t)&&o++}return o*n.N2},t.getPenaltyN3=function(e){let t=e.size,o=0,i=0,s=0;for(let n=0;n<t;n++){i=s=0;for(let c=0;c<t;c++)i=i<<1&2047|e.get(n,c),c>=10&&(1488===i||93===i)&&o++,s=s<<1&2047|e.get(c,n),c>=10&&(1488===s||93===s)&&o++}return o*n.N3},t.getPenaltyN4=function(e){let t=0,o=e.data.length;for(let n=0;n<o;n++)t+=e.data[n];let i=Math.abs(Math.ceil(100*t/o/5)-10);return i*n.N4},t.applyMask=function(e,n){let o=n.size;for(let i=0;i<o;i++)for(let s=0;s<o;s++)n.isReserved(s,i)||n.xor(s,i,function(e,n,o){switch(e){case t.Patterns.PATTERN000:return(n+o)%2==0;case t.Patterns.PATTERN001:return n%2==0;case t.Patterns.PATTERN010:return o%3==0;case t.Patterns.PATTERN011:return(n+o)%3==0;case t.Patterns.PATTERN100:return(Math.floor(n/2)+Math.floor(o/3))%2==0;case t.Patterns.PATTERN101:return n*o%2+n*o%3==0;case t.Patterns.PATTERN110:return(n*o%2+n*o%3)%2==0;case t.Patterns.PATTERN111:return(n*o%3+(n+o)%2)%2==0;default:throw Error("bad maskPattern:"+e)}}(e,s,i))},t.getBestMask=function(e,n){let o=Object.keys(t.Patterns).length,i=0,s=1/0;for(let c=0;c<o;
vendor: 4,737 bytes, line 30
30c++){n(c),t.applyMask(c,e);let o=t.getPenaltyN1(e)+t.getPenaltyN2(e)+t.getPenaltyN3(e)+t.getPenaltyN4(e);t.applyMask(c,e),o<s&&(s=o,i=c)}return i}},76910:function(e,t,n){let o=n(43114),i=n(7007);t.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},t.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},t.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},t.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},t.MIXED={bit:-1},t.getCharCountIndicator=function(e,t){if(!e.ccBits)throw Error("Invalid mode: "+e);if(!o.isValid(t))throw Error("Invalid version: "+t);return t>=1&&t<10?e.ccBits[0]:t<27?e.ccBits[1]:e.ccBits[2]},t.getBestModeForData=function(e){return i.testNumeric(e)?t.NUMERIC:i.testAlphanumeric(e)?t.ALPHANUMERIC:i.testKanji(e)?t.KANJI:t.BYTE},t.toString=function(e){if(e&&e.id)return e.id;throw Error("Invalid mode")},t.isValid=function(e){return e&&e.bit&&e.ccBits},t.from=function(e,n){if(t.isValid(e))return e;try{return function(e){if("string"!=typeof e)throw Error("Param is not a string");let n=e.toLowerCase();switch(n){case"numeric":return t.NUMERIC;case"alphanumeric":return t.ALPHANUMERIC;case"kanji":return t.KANJI;case"byte":return t.BYTE;default:throw Error("Unknown mode: "+e)}}(e)}catch(e){return n}}},41085:function(e,t,n){let o=n(76910);function NumericData(e){this.mode=o.NUMERIC,this.data=e.toString()}NumericData.getBitsLength=function(e){return 10*Math.floor(e/3)+(e%3?e%3*3+1:0)},NumericData.prototype.getLength=function(){return this.data.length},NumericData.prototype.getBitsLength=function(){return NumericData.getBitsLength(this.data.length)},NumericData.prototype.write=function(e){let t,n;for(t=0;t+3<=this.data.length;t+=3)n=parseInt(this.data.substr(t,3),10),e.put(n,10);let o=this.data.length-t;o>0&&(n=parseInt(this.data.substr(t),10),e.put(n,3*o+1))},e.exports=NumericData},26143:function(e,t,n){let o=n(69729);t.mul=function(e,t){let n=new Uint8Array(e.length+t.length-1);for(let i=0;i<e.length;i++)for(let s=0;s<t.length;s++)n[i+s]^=o.mul(e[i],t[s]);return n},t.mod=function(e,t){let n=new Uint8Array(e);for(;n.length-t.length>=0;){let e=n[0];for(let i=0;i<t.length;i++)n[i]^=o.mul(t[i],e);let i=0;for(;i<n.length&&0===n[i];)i++;n=n.slice(i)}return n},t.generateECPolynomial=function(e){let n=new Uint8Array([1]);for(let i=0;i<e;i++)n=t.mul(n,new Uint8Array([1,o.exp(i)]));return n}},95115:function(e,t,n){let o=n(10242),i=n(64908),s=n(97245),c=n(73280),l=n(21845),u=n(76526),d=n(27126),p=n(35393),m=n(52882),b=n(23103),g=n(61642),y=n(76910),v=n(16130);function setupFormatInfo(e,t,n){let o,i;let s=e.size,c=g.getEncodedBits(t,n);for(o=0;o<15;o++)i=(c>>o&1)==1,o<6?e.set(o,8,i,!0):o<8?e.set(o+1,8,i,!0):e.set(s-15+o,8,i,!0),o<8?e.set(8,s-o-1,i,!0):o<9?e.set(8,15-o-1+1,i,!0):e.set(8,15-o-1,i,!0);e.set(s-8,8,1,!0)}t.create=function(e,t){let n,g;if(void 0===e||""===e)throw Error("No input text");let E=i.M;return void 0!==t&&(E=i.from(t.errorCorrectionLevel,i.M),n=b.from(t.version),g=d.from(t.maskPattern),t.toSJISFunc&&o.setToSJISFunction(t.toSJISFunc)),function(e,t,n,i){let g;if(Array.isArray(e))g=v.fromArray(e);else if("string"==typeof e){let o=t;if(!o){let t=v.rawSplit(e);o=b.getBestVersionForData(t,n)}g=v.fromString(e,o||40)}else throw Error("Invalid data");let E=b.getBestVersionForData(g,n);if(!E)throw Error("The amount of data is too big to be stored in a QR Code");if(t){if(t<E)throw Error("\nThe chosen QR Code version cannot contain this amount of data.\nMinimum version required to store current data is: "+E+".\n")}else t=E;let x=function(e,t,n){let i=new s;n.forEach(function(t){i.put(t.mode.bit,4),i.put(t.getLength(),y.getCharCountIndicator(t.mode,e)),t.write(i)});let c=o.getSymbolTotalCodewords(e),l=p.getTotalCodewordsCount(e,t),u=(c-l)*8;for(i.getLengthInBits()+4<=u&&i.put(0,4);i.getLengthInBits()%8!=0;)i.putBit(0);let d=(u-i.getLengthInBits())/8;for(let e=0;e<d;e++)i.put(e%2?17:236,8);return function(e,t,n){let i,s;let c=o.getSymbolTotalCodewords(t),l=p.getTotalCodewordsCount(t,n),u=c-l,d=p.getBlocksCount(t,n),b=c%d,g=d-b,y=Math.floor(c/d),v=Math.floor(u/d),E=v+1,x=y-v,P=new m(x),_=0,I=Array(d),j=Array(d),R=0,M=new Uint8Array(e.buffer);for(let e=0;e<d;e++){let t=e<g?v:E;I[e]=M.slice(_,_+t),j[e]=P.encode(I[e]),_+=t,R=Math.max(R,t)}let F=new Uint8Array(c),q=0;for(i=0;i<R;i++)for(s=0;s<d;s++)i<I[s].length&&(F[q++]=I[s][i]);for(i=0;i<x;i++)for(s=0;s<d;s++)F[q++]=j[s][i];return F}(i,e,t)}(t,n,g),P=o.getSymbolSize(t),_=new c(P);return function(e,t){let n=e.size,o=u.getPositions(t);for(let t=0;t<o.length;t++){let i=o[t][0],s=o[t][1];for(let t=-1;t<=7;t++)if(!(i+t<=-1)&&!(n<=i+t))for(let o=-1;o<=7;o++)s+o<=-1||n<=s+o||(t>=0&&t<=6&&(0===o||6===o)||o>=0&&o<=6&&(0===t||6===t)||t>=2&&t<=4&&o>=2&&o<=4?e.set(i+t,s+o,!0,!0):e.set(i+t,s+o,!1,!0))}}(_,t),function(e){let t=e.size;
30for(let n=8;n<t-8;n++){let t=n%2==0;e.set(n,6,t,!0),e.set(6,n,t,!0)}}(_),function(e,t){let n=l.getPositions(t);for(let t=0;t<n.length;t++){let o=n[t][0],i=n[t][1];for(let t=-2;t<=2;t++)for(let n=-2;n<=2;n++)-2===t||2===t||-2===n||2===n||0===t&&0===n?e.set(o+t,i+n,!0,!0):e.set(o+t,i+n,!1,!0)}}(_,t),setupFormatInfo(_,n,0),t>=7&&function(e,t){let n,o,i;let s=e.size,c=b.getEncodedBits(t);for(let t=0;t<18;t++)n=Math.floor(t/3),o=t%3+s-8-3,i=(c>>t&1)==1,e.set(n,o,i,!0),e.set(o,n,i,!0)}(_,t),function(e,t){let n=e.size,o=-1,i=n-1,s=7,c=0;for(let l=n-1;l>0;l-=2)for(6===l&&l--;;){for(let n=0;n<2;n++)if(!e.isReserved(i,l-n)){let o=!1;c<t.length&&(o=(t[c]>>>s&1)==1),e.set(i,l-n,o),-1==--s&&(c++,s=7)}if((i+=o)<0||n<=i){i-=o,o=-o;break}}}(_,x),isNaN(i)&&(i=d.getBestMask(_,setupFormatInfo.bind(null,_,n))),d.applyMask(i,_),setupFormatInfo(_,n,i),{modules:_,version:t,errorCorrectionLevel:n,maskPattern:i,segments:g}}(e,n,E,g)}},52882:function(e,t,n){let o=n(26143);function ReedSolomonEncoder(e){this.genPoly=void 0,this.degree=e,this.degree&&this.initialize(this.degree)}ReedSolomonEncoder.prototype.initialize=function(e){this.degree=e,this.genPoly=o.generateECPolynomial(this.degree)},ReedSolomonEncoder.prototype.encode=function(e){if(!this.genPoly)throw Error("Encoder not initialized");let t=new Uint8Array(e.length+this.degree);t.set(e);let n=o.mod(t,this.genPoly),i=this.degree-n.length;if(i>0){let e=new Uint8Array(this.degree);return e.set(n,i),e}return n},e.exports=ReedSolomonEncoder},7007:function(e,t){let n="[0-9]+",o="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";o=o.replace(/u/g,"\\u");let i="(?:(?![A-Z0-9 $%*+\\-./:]|"+o+")(?:.|[\r\n]))+";t.KANJI=RegExp(o,"g"),t.BYTE_KANJI=RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),t.BYTE=RegExp(i,"g"),t.NUMERIC=RegExp(n,"g"),t.ALPHANUMERIC=RegExp("[A-Z $%*+\\-./:]+","g");let s=RegExp("^"+o+"$"),c=RegExp("^"+n+"$"),l=RegExp("^[A-Z0-9 $%*+\\-./:]+$");t.testKanji=function(e){return s.test(e)},t.testNumeric=function(e){return c.test(e)},t.testAlphanumeric=function(e){return l.test(e)}},16130:function(e,t,n){let o=n(76910),i=n(41085),s=n(8260),c=n(43424),l=n(35442),u=n(7007),d=n(10242),p=n(65987);function getStringByteLength(e){return unescape(encodeURIComponent(e)).length}function getSegments(e,t,n){let o;let i=[];for(;null!==(o=e.exec(n));)i.push({data:o[0],index:o.index,mode:t,length:o[0].length});return i}function getSegmentsFromString(e){let t,n;let i=getSegments(u.NUMERIC,o.NUMERIC,e),s=getSegments(u.ALPHANUMERIC,o.ALPHANUMERIC,e);d.isKanjiModeEnabled()?(t=getSegments(u.BYTE,o.BYTE,e),n=getSegments(u.KANJI,o.KANJI,e)):(t=getSegments(u.BYTE_KANJI,o.BYTE,e),n=[]);let c=i.concat(s,t,n);return c.sort(function(e,t){return e.index-t.index}).map(function(e){return{data:e.data,mode:e.mode,length:e.length}})}function getSegmentBitsLength(e,t){switch(t){case o.NUMERIC:return i.getBitsLength(e);case o.ALPHANUMERIC:return s.getBitsLength(e);case o.KANJI:return l.getBitsLength(e);case o.BYTE:return c.getBitsLength(e)}}function buildSingleSegment(e,t){let n;let u=o.getBestModeForData(e);if((n=o.from(t,u))!==o.BYTE&&n.bit<u.bit)throw Error('"'+e+'" cannot be encoded with mode '+o.toString(n)+".\n Suggested mode is: "+o.toString(u));switch(n!==o.KANJI||d.isKanjiModeEnabled()||(n=o.BYTE),n){case o.NUMERIC:return new i(e);case o.ALPHANUMERIC:return new s(e);case o.KANJI:return new l(e);case o.BYTE:return new c(e)}}t.fromArray=function(e){return e.reduce(function(e,t){return"string"==typeof t?e.push(buildSingleSegment(t,null)):t.data&&e.push(buildSingleSegment(t.data,t.mode)),e},[])},t.fromString=function(e,n){let i=getSegmentsFromString(e,d.isKanjiModeEnabled()),s=function(e){let t=[];for(let n=0;n<e.length;n++){let i=e[n];switch(i.mode){case o.NUMERIC:t.push([i,{data:i.data,mode:o.ALPHANUMERIC,length:i.length},{data:i.data,mode:o.BYTE,length:i.length}]);break;case o.ALPHANUMERIC:t.push([i,{data:i.data,mode:o.BYTE,length:i.length}]);break;case o.KANJI:t.push([i,{data:i.data,mode:o.BYTE,length:getStringByteLength(i.data)}]);break;case o.BYTE:t.push([{data:i.data,mode:o.BYTE,length:getStringByteLength(i.data)}])}}return t}(i),c=function(e,t){let n={},i={start:{}},s=["start"];for(let c=0;c<e.length;c++){let l=e[c],u=[];for(let e=0;e<l.length;e++){let d=l[e],p=""+c+e;u.push(p),n[p]={node:d,lastCount:0},i[p]={};for(let e=0;e<s.length;e++){let c=s[e];n[c]&&n[c].node.mode===d.mode?(i[c][p]=getSegmentBitsLength(n[c].lastCount+d.length,d.mode)-getSegmentBitsLength(n[c].lastCount,d.mode),n[c].lastCount+=d.length):(n[c]&&(n[c].lastCount=d.length),i[c][p]=getSegmentBitsLength(d.length,d.mode)+4+o.getCharCountIndicator(d.mode,t))}}s=u}for(let e=0;e<s.length;e++)i[s[e]].end=0;return{map:i,table:n}}(s,n),l=p.find_path(c.map,"start","end"),u=[];for(let e=1;e<l.length-1;e++)u.push(c.table[l[e]].node);return t.fromArray(u.reduce(function(e,t){let n=e.length-1>=0?e[e.length-1]:null;return n&&n.mode===t.mode?e[e.length-1].data+=t.data:e.push(t),e},[]))},t.rawSplit=function(e){return t.fromArray(getSegmentsFromString(e,d.isKanjiModeEnabled()))}},10242:function(e,t){let n;let o=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];t.getSymbolSize=function(e){if(!e)throw Error('"version" cannot be null or undefined');if(e<1||e>40)throw Error('"version" should be in range from 1 to 40');return 4*e+17},t.getSymbolTotalCodewords=function(e){return o[e]},t.getBCHDigit=function(e){let t=0;for(;0!==e;)t++,e>>>=1;return t},t.setToSJISFunction=function(e){if("function"!=typeof e)throw Error('"toSJISFunc" is not a valid function.');n=e},t.isKanjiModeEnabled=function(){return void 0!==n},t.toSJIS=function(e){return n(e)}},43114:function(e,t){t.isValid=function(e){return!isNaN(e)&&e>=1&&e<=40}},23103:function(e,t,n){let o=n(10242),i=n(35393),s=n(64908),c=n(76910),l=n(43114),u=o.getBCHDigit
30(7973);function getReservedBitsCount(e,t){return c.getCharCountIndicator(e,t)+4}t.from=function(e,t){return l.isValid(e)?parseInt(e,10):t},t.getCapacity=function(e,t,n){if(!l.isValid(e))throw Error("Invalid QR Code version");void 0===n&&(n=c.BYTE);let s=o.getSymbolTotalCodewords(e),u=i.getTotalCodewordsCount(e,t),d=(s-u)*8;if(n===c.MIXED)return d;let p=d-getReservedBitsCount(n,e);switch(n){case c.NUMERIC:return Math.floor(p/10*3);case c.ALPHANUMERIC:return Math.floor(p/11*2);case c.KANJI:return Math.floor(p/13);case c.BYTE:default:return Math.floor(p/8)}},t.getBestVersionForData=function(e,n){let o;let i=s.from(n,s.M);if(Array.isArray(e)){if(e.length>1)return function(e,n){for(let o=1;o<=40;o++){let i=function(e,t){let n=0;return e.forEach(function(e){let o=getReservedBitsCount(e.mode,t);n+=o+e.getBitsLength()}),n}(e,o);if(i<=t.getCapacity(o,n,c.MIXED))return o}}(e,i);if(0===e.length)return 1;o=e[0]}else o=e;return function(e,n,o){for(let i=1;i<=40;i++)if(n<=t.getCapacity(i,o,e))return i}(o.mode,o.getLength(),i)},t.getEncodedBits=function(e){if(!l.isValid(e)||e<7)throw Error("Invalid QR Code version");let t=e<<12;for(;o.getBCHDigit(t)-u>=0;)t^=7973<<o.getBCHDigit(t)-u;return e<<12|t}},6907:function(e,t,n){let o=n(89653);t.render=function(e,t,n){var i;let s=n,c=t;void 0!==s||t&&t.getContext||(s=t,t=void 0),t||(c=function(){try{return document.createElement("canvas")}catch(e){throw Error("You need to specify a canvas element")}}()),s=o.getOptions(s);let l=o.getImageWidth(e.modules.size,s),u=c.getContext("2d"),d=u.createImageData(l,l);return o.qrToImageData(d.data,e,s),i=c,u.clearRect(0,0,i.width,i.height),i.style||(i.style={}),i.height=l,i.width=l,i.style.height=l+"px",i.style.width=l+"px",u.putImageData(d,0,0),c},t.renderToDataURL=function(e,n,o){let i=o;void 0!==i||n&&n.getContext||(i=n,n=void 0),i||(i={});let s=t.render(e,n,i),c=i.type||"image/png",l=i.rendererOpts||{};return s.toDataURL(c,l.quality)}},93776:function(e,t,n){let o=n(89653);function getColorAttrib(e,t){let n=e.a/255,o=t+'="'+e.hex+'"';return n<1?o+" "+t+'-opacity="'+n.toFixed(2).slice(1)+'"':o}function svgCmd(e,t,n){let o=e+t;return void 0!==n&&(o+=" "+n),o}t.render=function(e,t,n){let i=o.getOptions(t),s=e.modules.size,c=e.modules.data,l=s+2*i.margin,u=i.color.light.a?"<path "+getColorAttrib(i.color.light,"fill")+' d="M0 0h'+l+"v"+l+'H0z"/>':"",d="<path "+getColorAttrib(i.color.dark,"stroke")+' d="'+function(e,t,n){let o="",i=0,s=!1,c=0;for(let l=0;l<e.length;l++){let u=Math.floor(l%t),d=Math.floor(l/t);u||s||(s=!0),e[l]?(c++,l>0&&u>0&&e[l-1]||(o+=s?svgCmd("M",u+n,.5+d+n):svgCmd("m",i,0),i=0,s=!1),u+1<t&&e[l+1]||(o+=svgCmd("h",c),c=0)):i++}return o}(c,s,i.margin)+'"/>',p=i.width?'width="'+i.width+'" height="'+i.width+'" ':"",m='<svg xmlns="http://www.w3.org/2000/svg" '+p+('viewBox="0 0 '+l)+" "+l+'" shape-rendering="crispEdges">'+u+d+"</svg>\n";return"function"==typeof n&&n(null,m),m}},89653:function(e,t){function hex2rgba(e){if("number"==typeof e&&(e=e.toString()),"string"!=typeof e)throw Error("Color should be defined as hex string");let t=e.slice().replace("#","").split("");if(t.length<3||5===t.length||t.length>8)throw Error("Invalid hex color: "+e);(3===t.length||4===t.length)&&(t=Array.prototype.concat.apply([],t.map(function(e){return[e,e]}))),6===t.length&&t.push("F","F");let n=parseInt(t.join(""),16);return{r:n>>24&255,g:n>>16&255,b:n>>8&255,a:255&n,hex:"#"+t.slice(0,6).join("")}}t.getOptions=function(e){e||(e={}),e.color||(e.color={});let t=void 0===e.margin||null===e.margin||e.margin<0?4:e.margin,n=e.width&&e.width>=21?e.width:void 0,o=e.scale||4;return{width:n,scale:n?4:o,margin:t,color:{dark:hex2rgba(e.color.dark||"#000000ff"),light:hex2rgba(e.color.light||"#ffffffff")},type:e.type,rendererOpts:e.rendererOpts||{}}},t.getScale=function(e,t){return t.width&&t.width>=e+2*t.margin?t.width/(e+2*t.margin):t.scale},t.getImageWidth=function(e,n){let o=t.getScale(e,n);return Math.floor((e+2*n.margin)*o)},t.qrToImageData=function(e,n,o){let i=n.modules.size,s=n.modules.data,c=t.getScale(i,o),l=Math.floor((i+2*o.margin)*c),u=o.margin*c,d=[o.color.light,o.color.dark];for(let t=0;t<l;t++)for(let n=0;n<l;n++){let p=(t*l+n)*4,m=o.color.light;if(t>=u&&n>=u&&t<l-u&&n<l-u){let e=Math.floor((t-u)/c),o=Math.floor((n-u)/c);m=d[s[e*i+o]?1:0]}e[p++]=m.r,e[p++]=m.g,e[p++]=m.b,e[p]=m.a}}},71642:function(e,t,n){"use strict";n.d(t,{Av:function(){return c},pF:function(){return o},xv:function(){return s},zi:function(){return i}});var o="right-scroll-bar-position",i="width-before-scroll-bar",s="with-scroll-bars-hidden",c="--removed-body-scroll-bar-size"},37087:function(e,t,n){"use strict";n.d(t,{jp:function(){return RemoveScrollBar}});var o=n(67294),i=n(6525),s=n(71642),c={left:0,top:0,right:0,gap:0},parse=function(e){return parseInt(e||"",10)||0},getOffset=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],o=t["padding"===e?"paddingTop":"marginTop"],i=t["padding"===e?"paddingRight":"marginRight"];return[parse(n),parse(o),parse(i)]},getGapWidth=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return c;var t=getOffset(e),n=document.documentElement.clientWidth,o=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,o-n+t[2]-t[0])}},l=(0,i.Ws)(),u="data-scroll-locked",getStyles=function(e,t,n,o){var i=e.left,c=e.top,l=e.right,d=e.gap;return void 0===n&&(n="margin"),"\n  .".concat(s.xv," {\n   overflow: hidden ").concat(o,";\n   padding-right: ").concat(d,"px ").concat(o,";\n  }\n  body[").concat(u,"] {\n    overflow: hidden ").concat(o,";\n    overscroll-behavior: contain;\n    ").concat([t&&"position: relative ".concat(o,";"),"margin"===n&&"\n    padding-left: ".concat(i,"px;\n    padding-top: ").concat(c,"px;\n    padding-right: ").concat(l,"px;\n    margin-left:0;\n    margin-top:0;\n    margin-right: ").concat(d,"px ").concat(o,";\n    "),"padding"===n&&"padding-right: ".concat(d,"px ").concat(o,";
30")].filter(Boolean).join(""),"\n  }\n  \n  .").concat(s.pF," {\n    right: ").concat(d,"px ").concat(o,";\n  }\n  \n  .").concat(s.zi," {\n    margin-right: ").concat(d,"px ").concat(o,";\n  }\n  \n  .").concat(s.pF," .").concat(s.pF," {\n    right: 0 ").concat(o,";\n  }\n  \n  .").concat(s.zi," .").concat(s.zi," {\n    margin-right: 0 ").concat(o,";\n  }\n  \n  body[").concat(u,"] {\n    ").concat(s.Av,": ").concat(d,"px;\n  }\n")},getCurrentUseCounter=function(){var e=parseInt(document.body.getAttribute(u)||"0",10);return isFinite(e)?e:0},useLockAttribute=function(){o.useEffect(function(){return document.body.setAttribute(u,(getCurrentUseCounter()+1).toString()),function(){var e=getCurrentUseCounter()-1;e<=0?document.body.removeAttribute(u):document.body.setAttribute(u,e.toString())}},[])},RemoveScrollBar=function(e){var t=e.noRelative,n=e.noImportant,i=e.gapMode,s=void 0===i?"margin":i;useLockAttribute();var c=o.useMemo(function(){return getGapWidth(s)},[s]);return o.createElement(l,{styles:getStyles(c,!t,s,n?"":"!important")})}},6525:function(e,t,n){"use strict";n.d(t,{Ws:function(){return styleSingleton}});var o,i=n(67294),stylesheetSingleton=function(){var e=0,t=null;return{add:function(i){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=o||n.nc;return t&&e.setAttribute("nonce",t),e}())){var s,c;(s=t).styleSheet?s.styleSheet.cssText=i:s.appendChild(document.createTextNode(i)),c=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(c)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},styleHookSingleton=function(){var e=stylesheetSingleton();return function(t,n){i.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},styleSingleton=function(){var e=styleHookSingleton();return function(t){return e(t.styles,t.dynamic),null}}},80500:function(e){"use strict";e.exports=(e,t)=>{if(!("string"==typeof e&&"string"==typeof t))throw TypeError("Expected the arguments to be of type `string`");if(""===t)return[e];let n=e.indexOf(t);return -1===n?[e]:[e.slice(0,n),e.slice(n+t.length)]}},70610:function(e){"use strict";e.exports=e=>encodeURIComponent(e).replace(/[!'()*]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`)},42238:function(e,t,n){var o;!function(i,s){"use strict";var c="function",l="undefined",u="object",d="string",p="major",m="model",b="name",g="type",y="vendor",v="version",E="architecture",x="console",P="mobile",_="tablet",I="smarttv",j="wearable",R="embedded",M="Amazon",F="Apple",q="ASUS",H="BlackBerry",z="Browser",W="Chrome",K="Firefox",Q="Google",Z="Huawei",X="Microsoft",Y="Motorola",J="Opera",et="Samsung",eo="Sharp",ea="Sony",ei="Xiaomi",es="Zebra",ec="Facebook",el="Chromium OS",eu="Mac OS",extend=function(e,t){var n={};for(var o in e)t[o]&&t[o].length%2==0?n[o]=t[o].concat(e[o]):n[o]=e[o];return n},enumerize=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},has=function(e,t){return typeof e===d&&-1!==lowerize(t).indexOf(lowerize(e))},lowerize=function(e){return e.toLowerCase()},trim=function(e,t){if(typeof e===d)return e=e.replace(/^\s\s*/,""),typeof t===l?e:e.substring(0,500)},rgxMapper=function(e,t){for(var n,o,i,l,d,p,m=0;m<t.length&&!d;){var b=t[m],g=t[m+1];for(n=o=0;n<b.length&&!d&&b[n];)if(d=b[n++].exec(e))for(i=0;i<g.length;i++)p=d[++o],typeof(l=g[i])===u&&l.length>0?2===l.length?typeof l[1]==c?this[l[0]]=l[1].call(this,p):this[l[0]]=l[1]:3===l.length?typeof l[1]!==c||l[1].exec&&l[1].test?this[l[0]]=p?p.replace(l[1],l[2]):s:this[l[0]]=p?l[1].call(this,p,l[2]):s:4===l.length&&(this[l[0]]=p?l[3].call(this,p.replace(l[1],l[2])):s):this[l]=p||s;m+=2}},strMapper=function(e,t){for(var n in t)if(typeof t[n]===u&&t[n].length>0){for(var o=0;o<t[n].length;o++)if(has(t[n][o],e))return"?"===n?s:n}else if(has(t[n],e))return"?"===n?s:n;return e},ed={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},ef={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[v,[b,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[v,[b,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[b,v],[/opios[\/ ]+([\w\.]+)/i],[v,[b,J+" Mini"]],[/\bopr\/([\w\.]+)/i],[v,[b,J]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[v,[b,"Baidu"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim)\s?(?:browser)?[\/ ]?([\w\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,/(heytap|ovi)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[b,v],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[v,[b,"UC"+z]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[v,[b,"WeChat"]],[/konqueror\/([\w\.]+)/i],[v,[b,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[v,[b,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[v,[b,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[v,[b,"Smart Lenovo "+z]],[/(avast|avg)\/([\w\.]+)/i],[[b,/(.+)/,"$1 Secure "+z],v],[/\bfocus\/([\w\.]+)/i],[v,[b,K+" Focus"]],[/\bopt\/([\w\.]+)/i],[v,[b,J+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[v,[b,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[v,[b,"Dolphin"]],[/coast\/([\w\.]+)/i],[v,[b,J+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[v,[b,"MIUI "+z]],[/fxios\/([-\w\.]+)/i],[v,[b,K]],[/\bqihu|(qi?ho?o?|360)browser/i],[[b,"360 "+z]],[/(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i],[[b,/(.+)/,"$1 "+z],v],[/samsungbrowser\/([\w\.]+)/i],[v,[b,et+" Internet"]],[/(comodo_dragon)\/([\w\.]+)/i],[[b,/_/g," "],v],[/metasr[\/ ]?([\d\.]+)/i],[v,[b,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[b,"Sogou Mobile"],v],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345Explorer)[\/ ]?([\w\.]+)/i],[b,v],[/(lbbrowser)/i,/\[(linkedin)app\]/i],[b],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[b,ec],v],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[b,v],[/\bgsa\/([\w\.]+) .*safari\//i],[v,[b,"GSA"]],[/musical_ly(?:.
vendor: 4,491 bytes, line 30
30+app_?version\/|_)([\w\.]+)/i],[v,[b,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[v,[b,W+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[b,W+" WebView"],v],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[v,[b,"Android "+z]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[b,v],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[v,[b,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[v,b],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[b,[v,strMapper,{"1.0":"/8","1.2":"/1","1.3":"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[b,v],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[b,"Netscape"],v],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[v,[b,K+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i,/panasonic;(viera)/i],[b,v],[/(cobalt)\/([\w\.]+)/i],[b,[v,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[E,"amd64"]],[/(ia32(?=;))/i],[[E,lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[E,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[E,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[E,"armhf"]],[/windows (ce|mobile); ppc;/i],[[E,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[E,/ower/,"",lowerize]],[/(sun4\w)[;\)]/i],[[E,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[E,lowerize]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[m,[y,et],[g,_]],[/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]([-\w]+)/i,/sec-(sgh\w+)/i],[m,[y,et],[g,P]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[m,[y,F],[g,P]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[m,[y,F],[g,_]],[/(macintosh);/i],[m,[y,F]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[m,[y,eo],[g,P]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[m,[y,Z],[g,_]],[/(?:huawei|honor)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[m,[y,Z],[g,P]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i],[[m,/_/g," "],[y,ei],[g,P]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[m,/_/g," "],[y,ei],[g,_]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[m,[y,"OPPO"],[g,P]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[m,[y,"Vivo"],[g,P]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[m,[y,"Realme"],[g,P]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[m,[y,Y],[g,P]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[m,[y,Y],[g,_]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[m,[y,"LG"],[g,_]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[m,[y,"LG"],[g,P]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[m,[y,"Lenovo"],[g,_]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[m,/_/g," "],[y,"Nokia"],[g,P]],[/(pixel c)\b/i],[m,[y,Q],[g,_]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[m,[y,Q],[g,P]],[/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[m,[y,ea],[g,P]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[m,"Xperia Tablet"],[y,ea],[g,_]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[m,[y,"OnePlus"],[g,P]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[m,[y,M],[g,_]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[m,/(.+
vendor: 5,520 bytes, line 30
30)/g,"Fire Phone $1"],[y,M],[g,P]],[/(playbook);[-\w\),; ]+(rim)/i],[m,y,[g,_]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[m,[y,H],[g,P]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[m,[y,q],[g,_]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[m,[y,q],[g,P]],[/(nexus 9)/i],[m,[y,"HTC"],[g,_]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[y,[m,/_/g," "],[g,P]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[m,[y,"Acer"],[g,_]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[m,[y,"Meizu"],[g,P]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[m,[y,"Ulefone"],[g,P]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[y,m,[g,P]],[/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[y,m,[g,_]],[/(surface duo)/i],[m,[y,X],[g,_]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[m,[y,"Fairphone"],[g,P]],[/(u304aa)/i],[m,[y,"AT&T"],[g,P]],[/\bsie-(\w*)/i],[m,[y,"Siemens"],[g,P]],[/\b(rct\w+) b/i],[m,[y,"RCA"],[g,_]],[/\b(venue[\d ]{2,7}) b/i],[m,[y,"Dell"],[g,_]],[/\b(q(?:mv|ta)\w+) b/i],[m,[y,"Verizon"],[g,_]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[m,[y,"Barnes & Noble"],[g,_]],[/\b(tm\d{3}\w+) b/i],[m,[y,"NuVision"],[g,_]],[/\b(k88) b/i],[m,[y,"ZTE"],[g,_]],[/\b(nx\d{3}j) b/i],[m,[y,"ZTE"],[g,P]],[/\b(gen\d{3}) b.+49h/i],[m,[y,"Swiss"],[g,P]],[/\b(zur\d{3}) b/i],[m,[y,"Swiss"],[g,_]],[/\b((zeki)?tb.*\b) b/i],[m,[y,"Zeki"],[g,_]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[y,"Dragon Touch"],m,[g,_]],[/\b(ns-?\w{0,9}) b/i],[m,[y,"Insignia"],[g,_]],[/\b((nxa|next)-?\w{0,9}) b/i],[m,[y,"NextBook"],[g,_]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[y,"Voice"],m,[g,P]],[/\b(lvtel\-)?(v1[12]) b/i],[[y,"LvTel"],m,[g,P]],[/\b(ph-1) /i],[m,[y,"Essential"],[g,P]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[m,[y,"Envizen"],[g,_]],[/\b(trio[-\w\. ]+) b/i],[m,[y,"MachSpeed"],[g,_]],[/\btu_(1491) b/i],[m,[y,"Rotor"],[g,_]],[/(shield[\w ]+) b/i],[m,[y,"Nvidia"],[g,_]],[/(sprint) (\w+)/i],[y,m,[g,P]],[/(kin\.[onetw]{3})/i],[[m,/\./g," "],[y,X],[g,P]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[m,[y,es],[g,_]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[m,[y,es],[g,P]],[/smart-tv.+(samsung)/i],[y,[g,I]],[/hbbtv.+maple;(\d+)/i],[[m,/^/,"SmartTV"],[y,et],[g,I]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[y,"LG"],[g,I]],[/(apple) ?tv/i],[y,[m,F+" TV"],[g,I]],[/crkey/i],[[m,W+"cast"],[y,Q],[g,I]],[/droid.+aft(\w+)( bui|\))/i],[m,[y,M],[g,I]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[m,[y,eo],[g,I]],[/(bravia[\w ]+)( bui|\))/i],[m,[y,ea],[g,I]],[/(mitv-\w{5}) bui/i],[m,[y,ei],[g,I]],[/Hbbtv.*(technisat) (.*);/i],[y,m,[g,I]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[y,trim],[m,trim],[g,I]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[g,I]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[y,m,[g,x]],[/droid.+; (shield) bui/i],[m,[y,"Nvidia"],[g,x]],[/(playstation [345portablevi]+)/i],[m,[y,ea],[g,x]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[m,[y,X],[g,x]],[/((pebble))app/i],[y,m,[g,j]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[m,[y,F],[g,j]],[/droid.+; (glass) \d/i],[m,[y,Q],[g,j]],[/droid.+; (wt63?0{2,3})\)/i],[m,[y,es],[g,j]],[/(quest( 2| pro)?)/i],[m,[y,ec],[g,j]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[y,[g,R]],[/(aeobc)\b/i],[m,[y,M],[g,R]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[m,[g,P]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[m,[g,_]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[g,_]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[g,P]],[/(android[-\w\. ]{0,9});.+buil/i],[m,[y,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[v,[b,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[v,[b,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[b,v],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[v,b]],os:[[/microsoft (windows) (vista|xp)/i],[b,v],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[b,[v,strMapper,ed]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[v,strMapper,ed],[b,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[v,/_/g,"."],[b,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[b,eu],[v,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[v,b],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[b,v],[/\(bb(10);/i],[v,[b,H]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[v,[b,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+);
30 rv:.+ gecko\/([\w\.]+)/i],[v,[b,K+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[v,[b,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[v,[b,"watchOS"]],[/crkey\/([\d\.]+)/i],[v,[b,W+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[b,el],v],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[b,v],[/(sunos) ?([\w\.\d]*)/i],[[b,"Solaris"],v],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[b,v]]},UAParser=function(e,t){if(typeof e===u&&(t=e,e=s),!(this instanceof UAParser))return new UAParser(e,t).getResult();var n=typeof i!==l&&i.navigator?i.navigator:s,o=e||(n&&n.userAgent?n.userAgent:""),x=n&&n.userAgentData?n.userAgentData:s,I=t?extend(ef,t):ef,j=n&&n.userAgent==o;return this.getBrowser=function(){var e,t={};return t[b]=s,t[v]=s,rgxMapper.call(t,o,I.browser),t[p]=typeof(e=t[v])===d?e.replace(/[^\d\.]/g,"").split(".")[0]:s,j&&n&&n.brave&&typeof n.brave.isBrave==c&&(t[b]="Brave"),t},this.getCPU=function(){var e={};return e[E]=s,rgxMapper.call(e,o,I.cpu),e},this.getDevice=function(){var e={};return e[y]=s,e[m]=s,e[g]=s,rgxMapper.call(e,o,I.device),j&&!e[g]&&x&&x.mobile&&(e[g]=P),j&&"Macintosh"==e[m]&&n&&typeof n.standalone!==l&&n.maxTouchPoints&&n.maxTouchPoints>2&&(e[m]="iPad",e[g]=_),e},this.getEngine=function(){var e={};return e[b]=s,e[v]=s,rgxMapper.call(e,o,I.engine),e},this.getOS=function(){var e={};return e[b]=s,e[v]=s,rgxMapper.call(e,o,I.os),j&&!e[b]&&x&&"Unknown"!=x.platform&&(e[b]=x.platform.replace(/chrome os/i,el).replace(/macos/i,eu)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return o},this.setUA=function(e){return o=typeof e===d&&e.length>500?trim(e,500):e,this},this.setUA(o),this};UAParser.VERSION="1.0.37",UAParser.BROWSER=enumerize([b,v,p]),UAParser.CPU=enumerize([E]),UAParser.DEVICE=enumerize([m,y,g,x,P,I,_,j,R]),UAParser.ENGINE=UAParser.OS=enumerize([b,v]),typeof t!==l?(e.exports&&(t=e.exports=UAParser),t.UAParser=UAParser):n.amdO?s!==(o=(function(){return UAParser}).call(t,n,t,e))&&(e.exports=o):typeof i!==l&&(i.UAParser=UAParser);var ep=typeof i!==l&&(i.jQuery||i.Zepto);if(ep&&!ep.ua){var eh=new UAParser;ep.ua=eh.getResult(),ep.ua.get=function(){return eh.getUA()},ep.ua.set=function(e){eh.setUA(e);var t=eh.getResult();for(var n in t)ep.ua[n]=t[n]}}}("object"==typeof window?window:this)},99495:function(e,t,n){"use strict";n.d(t,{q:function(){return useMergeRefs}});var o=n(67294);function assignRef(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var i="undefined"!=typeof window?o.useLayoutEffect:o.useEffect,s=new WeakMap;function useMergeRefs(e,t){var n,c,l,u=(n=t||null,c=function(t){return e.forEach(function(e){return assignRef(e,t)})},(l=(0,o.useState)(function(){return{value:n,callback:c,facade:{get current(){return l.value},set current(value){var e=l.value;e!==value&&(l.value=value,l.callback(value,e))}}}})[0]).callback=c,l.facade);return i(function(){var t=s.get(u);if(t){var n=new Set(t),o=new Set(e),i=u.current;n.forEach(function(e){o.has(e)||assignRef(e,null)}),o.forEach(function(e){n.has(e)||assignRef(e,i)})}s.set(u,e)},[e]),u}},66781:function(e,t,n){"use strict";n.d(t,{L:function(){return exportSidecar}});var o=n(97582),i=n(67294),SideCar=function(e){var t=e.sideCar,n=(0,o.__rest)(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var s=t.read();if(!s)throw Error("Sidecar medium not found");return i.createElement(s,(0,o.__assign)({},n))};function exportSidecar(e,t){return e.useMedium(t),SideCar}
30SideCar.isSideCarExport=!0},87122:function(e,t,n){"use strict";n.d(t,{_:function(){return createSidecarMedium}});var o=n(97582);function ItoI(e){return e}function createSidecarMedium(e){void 0===e&&(e={});var t,n,i,s=(void 0===t&&(t=ItoI),n=[],i=!1,{read:function(){if(i)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:null},useMedium:function(e){var o=t(e,i);return n.push(o),function(){n=n.filter(function(e){return e!==o})}},assignSyncMedium:function(e){for(i=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){i=!0;var t=[];if(n.length){var o=n;n=[],o.forEach(e),t=n}var executeQueue=function(){var n=t;t=[],n.forEach(e)},cycle=function(){return Promise.resolve().then(executeQueue)};cycle(),n={push:function(e){t.push(e),cycle()},filter:function(e){return t=t.filter(e),n}}}});return s.options=(0,o.__assign)({async:!0,ssr:!1},e),s}},53250:function(e,t,n){"use strict";/**
31 * @license React
32 * use-sync-external-store-shim.production.min.js
33 *
34 * Copyright (c) Facebook, Inc. and its affiliates.
35 *
36 * This source code is licensed under the MIT license found in the
37 * LICENSE file in the root directory of this source tree.
38 */var o=n(67294),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=o.useState,c=o.useEffect,l=o.useLayoutEffect,u=o.useDebugValue;function r(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch(e){return!0}}var d="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),o=s({inst:{value:n,getSnapshot:t}}),i=o[0].inst,d=o[1];return l(function(){i.value=n,i.getSnapshot=t,r(i)&&d({inst:i})},[e,n,t]),c(function(){return r(i)&&d({inst:i}),e(function(){r(i)&&d({inst:i})})},[e]),u(n),n};t.useSyncExternalStore=void 0!==o.useSyncExternalStore?o.useSyncExternalStore:d},50139:function(e,t,n){"use strict";/**
39 * @license React
40 * use-sync-external-store-shim/with-selector.production.min.js
41 *
42 * Copyright (c) Facebook, Inc. and its affiliates.
43 *
44 * This source code is licensed under the MIT license found in the
45 * LICENSE file in the root directory of this source tree.
46 */var o=n(67294),i=n(61688),s="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},c=i.useSyncExternalStore,l=o.useRef,u=o.useEffect,d=o.useMemo,p=o.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,o,i){var m=l(null);if(null===m.current){var b={hasValue:!1,value:null};m.current=b}else b=m.current;var g=c(e,(m=d(function(){function a(t){if(!l){if(l=!0,e=t,t=o(t),void 0!==i&&b.hasValue){var n=b.value;if(i(n,t))return c=n}return c=t}if(n=c,s(e,t))return n;var u=o(t);return void 0!==i&&i(n,u)?n:(e=t,c=u)}var e,c,l=!1,u=void 0===n?null:n;return[function(){return a(t())},null===u?void 0:function(){return a(u())}]},[t,n,o,i]))[0],m[1]);return u(function(){b.hasValue=!0,b.value=g},[g]),p(g),g}},61688:function(e,t,n){"use strict";e.exports=n(53250)},52798:function(e,t,n){"use strict";e.exports=n(50139)},35883:function(){},58799:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseError=void 0;let o=n(4734);let BaseError=class BaseError extends Error{constructor(e,t={}){let n=t.cause instanceof BaseError?t.cause.details:t.cause?.message?t.cause.message:t.details,i=t.cause instanceof BaseError&&t.cause.docsPath||t.docsPath,s=[e||"An error occurred.","",...t.metaMessages?[...t.metaMessages,""]:[],...i?[`Docs: https://abitype.dev${i}`]:[],...n?[`Details: ${n}`]:[],`Version: abitype@${o.version}`].join("\n");super(s),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"}),t.cause&&(this.cause=t.cause),this.details=n,this.docsPath=i,this.metaMessages=t.metaMessages,this.shortMessage=e}};t.BaseError=BaseError},65550:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.UnknownSolidityTypeError=t.UnknownTypeError=t.InvalidAbiItemError=void 0;let o=n(58799);let InvalidAbiItemError=class InvalidAbiItemError extends o.BaseError{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"})}};t.InvalidAbiItemError=InvalidAbiItemError;let UnknownTypeError=class UnknownTypeError extends o.BaseError{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"})}};t.UnknownTypeError=UnknownTypeError;let UnknownSolidityTypeError=class UnknownSolidityTypeError extends o.BaseError{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"})}};t.UnknownSolidityTypeError=UnknownSolidityTypeError},5162:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidAbiTypeParameterError=t.InvalidFunctionModifierError=t.InvalidModifierError=t.SolidityProtectedKeywordError=t.InvalidParameterError=t.InvalidAbiParametersError=t.InvalidAbiParameterError=void 0;let o=n(58799);let InvalidAbiParameterError=class InvalidAbiParameterError extends o.BaseError{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"})}};t.InvalidAbiParameterError=InvalidAbiParameterError;let InvalidAbiParametersError=class InvalidAbiParametersError extends o.BaseError{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"})}};t.InvalidAbiParametersError=InvalidAbiParametersError;let InvalidParameterError=class InvalidParameterError extends o.BaseError{constructor({param:e}){super("Invalid ABI parameter.",{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParameterError"})}};t.InvalidParameterError=InvalidParameterError;let SolidityProtectedKeywordError=class SolidityProtectedKeywordError extends o.BaseError{constructor({param:e,name:t}){super("Invalid ABI parameter.",{details:e,metaMessages:[`"${t}" 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"})}};t.SolidityProtectedKeywordError=SolidityProtectedKeywordError;let InvalidModifierError=class InvalidModifierError extends o.BaseError{constructor({param:e,type:t,modifier:n}){super("Invalid ABI parameter.",{details:e,metaMessages:[`Modifier "${n}" not allowed${t?` in "${t}" type`:""}.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidModifierError"})}};t.InvalidModifierError=InvalidModifierError;let InvalidFunctionModifierError=class InvalidFunctionModifierError extends o.BaseError{constructor({param:e,type:t,modifier:n}){super("Invalid ABI parameter.",{details:e,metaMessages:[`Modifier "${n}" not allowed${t?` in "${t}" 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"})}};t.InvalidFunctionModifierError=InvalidFunctionModifierError;let InvalidAbiTypeParameterError=class InvalidAbiTypeParameterError extends o.BaseError{constructor({abiParameter:e}){super("Invalid ABI parameter.",{details:JSON.stringify(e,null,2),metaMessages:["ABI parameter type is invali
46d."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiTypeParameterError"})}};t.InvalidAbiTypeParameterError=InvalidAbiTypeParameterError},69036:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidStructSignatureError=t.UnknownSignatureError=t.InvalidSignatureError=void 0;let o=n(58799);let InvalidSignatureError=class InvalidSignatureError extends o.BaseError{constructor({signature:e,type:t}){super(`Invalid ${t} signature.`,{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSignatureError"})}};t.InvalidSignatureError=InvalidSignatureError;let UnknownSignatureError=class UnknownSignatureError extends o.BaseError{constructor({signature:e}){super("Unknown signature.",{details:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSignatureError"})}};t.UnknownSignatureError=UnknownSignatureError;let InvalidStructSignatureError=class InvalidStructSignatureError extends o.BaseError{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"})}};t.InvalidStructSignatureError=InvalidStructSignatureError},88939:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidParenthesisError=void 0;let o=n(58799);let InvalidParenthesisError=class InvalidParenthesisError extends o.BaseError{constructor({current:e,depth:t}){super("Unbalanced parentheses.",{metaMessages:[`"${e.trim()}" has too many ${t>0?"opening":"closing"} parentheses.`],details:`Depth "${t}"`}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParenthesisError"})}};t.InvalidParenthesisError=InvalidParenthesisError},11378:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CircularReferenceError=void 0;let o=n(58799);let CircularReferenceError=class CircularReferenceError extends o.BaseError{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"})}};t.CircularReferenceError=CircularReferenceError},9677:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbi=void 0;let o=n(64257);t.formatAbi=function(e){let t=[],n=e.length;for(let i=0;i<n;i++){let n=e[i],s=(0,o.formatAbiItem)(n);t.push(s)}return t}},64257:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbiItem=void 0;let o=n(19339);t.formatAbiItem=function(e){return"function"===e.type?`function ${e.name}(${(0,o.formatAbiParameters)(e.inputs)})${e.stateMutability&&"nonpayable"!==e.stateMutability?` ${e.stateMutability}`:""}${e.outputs.length?` returns (${(0,o.formatAbiParameters)(e.outputs)})`:""}`:"event"===e.type?`event ${e.name}(${(0,o.formatAbiParameters)(e.inputs)})`:"error"===e.type?`error ${e.name}(${(0,o.formatAbiParameters)(e.inputs)})`:"constructor"===e.type?`constructor(${(0,o.formatAbiParameters)(e.inputs)})${"payable"===e.stateMutability?" payable":""}`:"fallback"===e.type?"fallback()":"receive() external payable"}},81907:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbiParameter=void 0;let o=n(66128),i=/^tuple(?<array>(\[(\d*)\])*)$/;t.formatAbiParameter=function formatAbiParameter(e){let t=e.type;if(i.test(e.type)&&"components"in e){t="(";let n=e.components.length;for(let o=0;o<n;o++){let i=e.components[o];t+=formatAbiParameter(i),o<n-1&&(t+=", ")}let s=(0,o.execTyped)(i,e.type);return t+=`)${s?.array??""}`,formatAbiParameter({...e,type:t})}return("indexed"in e&&e.indexed&&(t=`${t} indexed`),e.name)?`${t} ${e.name}`:t}},19339:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbiParameters=void 0;let o=n(81907);t.formatAbiParameters=function(e){let t="",n=e.length;for(let i=0;i<n;i++){let s=e[i];t+=(0,o.formatAbiParameter)(s),i!==n-1&&(t+=", ")}return t}},30464:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.parseAbi=void 0;let o=n(95206),i=n(59625),s=n(99828);t.parseAbi=function(e){let t=(0,i.parseStructs)(e),n=[],c=e.length;for(let i=0;i<c;i++){let c=e[i];(0,o.isStructSignature)(c)||n.push((0,s.parseSignature)(c,t))}return n}},14263:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAbiItem=void 0;let o=n(8270),i=n(95206),s=n(59625),c=n(99828);t.parseAbiItem=function(e){let t;if("string"==typeof e)t=(0,c.parseSignature)(e);else{let n=(0,s.parseStructs)(e),o=e.length;for(let s=0;s<o;s++){let o=e[s];if(!(0,i.isStructSignature)(o)){t=(0,c.parseSignature)(o,n);break}}}if(!t)throw new o.InvalidAbiItemError({signature:e});return t}},15485:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAbiParameter=void 0;let o=n(8270),i=n(95206),s=n(59625),c=n(99828);t.parseAbiParameter=function(e){let t;if("string"==typeof e)t=(0,c.parseAbiParameter)(e,{modifiers:i.modifiers});else{let n=(0,s.parseStructs)(e),o=e.length;for(let s=0;s<o;s++){let o=e[s];if(!(0,i.isStructSignature)(o)){t=(0,c.parseAbiParameter)(o,{modifiers:i.modifiers,structs:n}
46);break}}}if(!t)throw new o.InvalidAbiParameterError({param:e});return t}},4898:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAbiParameters=void 0;let o=n(8270),i=n(95206),s=n(59625),c=n(99828),l=n(99828);t.parseAbiParameters=function(e){let t=[];if("string"==typeof e){let n=(0,c.splitParameters)(e),o=n.length;for(let e=0;e<o;e++)t.push((0,l.parseAbiParameter)(n[e],{modifiers:i.modifiers}))}else{let n=(0,s.parseStructs)(e),o=e.length;for(let s=0;s<o;s++){let o=e[s];if((0,i.isStructSignature)(o))continue;let u=(0,c.splitParameters)(o),d=u.length;for(let e=0;e<d;e++)t.push((0,l.parseAbiParameter)(u[e],{modifiers:i.modifiers,structs:n}))}}if(0===t.length)throw new o.InvalidAbiParametersError({params:e});return t}},3856:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parameterCache=t.getParameterCacheKey=void 0,t.getParameterCacheKey=function(e,t){return t?`${t}:${e}`:e},t.parameterCache=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}]])},95206:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.functionModifiers=t.eventModifiers=t.modifiers=t.isReceiveSignature=t.isFallbackSignature=t.execConstructorSignature=t.isConstructorSignature=t.execStructSignature=t.isStructSignature=t.execFunctionSignature=t.isFunctionSignature=t.execEventSignature=t.isEventSignature=t.execErrorSignature=t.isErrorSignature=void 0;let o=n(66128),i=/^error (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;t.isErrorSignature=function(e){return i.test(e)},t.execErrorSignature=function(e){return(0,o.execTyped)(i,e)};let s=/^event (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;t.isEventSignature=function(e){return s.test(e)},t.execEventSignature=function(e){return(0,o.execTyped)(s,e)};let c=/^function (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)(?: (?<scope>external|public{1}))?(?: (?<stateMutability>pure|view|nonpayable|payable{1}))?(?: returns\s?\((?<returns>.*?)\))?$/;t.isFunctionSignature=function(e){return c.test(e)},t.execFunctionSignature=function(e){return(0,o.execTyped)(c,e)};let l=/^struct (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?<properties>.*?)\}$/;t.isStructSignature=function(e){return l.test(e)},t.execStructSignature=function(e){return(0,o.execTyped)(l,e)};let u=/^constructor\((?<parameters>.*?)\)(?:\s(?<stateMutability>payable{1}))?$/;t.isConstructorSignature=function(e){return u.test(e)},t.execConstructorSignature=function(e){return(0,o.execTyped)(u,e)};let d=/^fallback\(\)$/;t.isFallbackSignature=function(e){return d.test(e)};let p=/^receive\(\) external payable$/;t.isReceiveSignature=function(e){return p.test(e)},t.modifiers=new Set(["memory","indexed","storage","calldata"]),t.eventModifiers=new Set(["indexed"]),t.functionModifiers=new Set(["calldata","memory","storage"])},59625:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.parseStructs=void 0;let o=n(66128),i=n(65550),s=n(5162),c=n(69036),l=n(11378),u=n(95206),d=n(99828);t.parseStructs=function(e){let t={},n=e.length;for(let o=0;o<n;o++){let n=e[o];if(!(0,u.isStructSignature)(n))continue;let i=(0,u.execStructSignature)(n);if(!i)throw new c.InvalidSignatureError({signature:n,type:"struct"});let s=i.properties.split(";"),l=[],p=s.length;for(let e=0;e<p;e++){let t=s[e],n=t.trim();if(!n)continue;let o=(0,d.parseAbiParameter)(n,{type:"struct"});l.push(o)}if(!l.length)throw new c.InvalidStructSignatureError({signature:n});t[i.name]=l}let m={},b=Object.entries(t),g=b.length;for(let e=0;e<g;e++){let[n,c]=b[e];m[n]=function resolveStructs(e,t,n=new Set){let c=[],u=e.length;for(let m=0;m<u;m++){let u=e[m],b=o.isTupleRegex.test(u.type);if(b)c.push(u);else{let e=(0,o.execTyped)(p,u.type);if(!e?.type)throw new s.InvalidAbiTypeParameterError({abiParameter:u});let{array:m,type:b}=e;if(b in t){if(n.has(b))throw new l.CircularReferenceError({type:b});c.push({...u,type:`tuple${m??""}`,components:resolveStructs(t[b]??[],t,new Set([...n,b]))})}else if((0,d.isSolidityType)(b))c.push(u);else throw new i.UnknownTypeError({type:b})}}return c}(c,t)}return m};let p=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?$/},99828:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isValidDataLocation=t.isSolidityKeyword=t.isSolidityType=t.splitParameters=t.parseAbiParameter=t.parseSignature=void 0;let o=n(66128),i=n(65550),s=n(5162),c=n(69036),l=n(88939),u=n(3856),d=n(95206);t.parseSignature=function(e,t={}){if((0,d.isFunctionSignature)(e)){let n=(0,d.execFunctionSignature)(e);if(!n)throw new c.InvalidSignatureError({signature:e,type:"function"});let o=splitParameters(n.parameters),i=[],s=o.length;for(let e=0;e<s;e++)i.push(parseAbiParameter(o[e],{modifiers:d.functionModifiers,structs:t,type:"function"}));let l=[];if(n.returns){let e=splitParameters(n.returns),o=e.length;for(let n=0;n<o;n++)l.push(parseAbiParameter(e[n],{modifiers:d.functionModifiers,structs:t,type:"function"}))}return{name:n.name,type:"function",stateMutability:n.stateMutability??"nonpayable",inputs:i,outputs:l}}if((0,d.isEventSignature)(e)){let n=(0,d.execEventSignature)(e);if(!n)throw new c.InvalidSignatureError({signature:e,type:"event"});let o=splitParameters(n.parameters),i=[],s=o.length;for(let e=0;e<s;e++)i.push(parseAbiParameter(o[e],{modifiers:d.eventModifiers,structs:t,type:"event"}));return{name:n.name,type:"event",inputs:i}}if((0,d.isErrorSignature)(e)){let n=(0,d.execErrorSignature)(e);if(!n)throw new c.InvalidSignatureError({signature:e,type:"error"});let o=splitParameters(n.parameters),i=[],s=o.length;for(let e=0;e<s;e++)i.push(parseAbiParameter(o[e],{structs:t,type:"error"}));return{name:n.name,type:"error",inputs:i}}if((0,d.isConstructorSignature)(e)){let n=(0,d.execConstructorSignature)(e);if(!n)throw new c.InvalidSignatureError({signature:e,type:"constructor"});let o=splitParameters(n.parameters),i=[],s=o.length;for(let e=0;e<s;e++)i.push(parseAbiParameter(o[e],{structs:t,type:"constructor"}));return{type:"constructor",stateMutability:n.stateMutability??"nonpayable",inputs:i}}if((0,d.isFallbackSignature)(e))return{type:"fallback"};if((0,d.isReceiveSignature)(e))return{type:"receive",stateMutability:"payable"};throw new c.UnknownSignatureError({signature:e})};let p=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,m=/^\((?<type>.+?)\)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,b=/^u?int$/;function parseAbiParameter(e,t){let n;let c=(0,u.getParameterCacheKey)(e,t?.type);if(u.parameterCache.has(c))return u.parameterCache.get(c);let l=o.isTupleRegex.test(e),g=(0,o.execTyped)(l?m:p,e);if(!g)throw new s.InvalidParameterError({param:e});if(g.name&&isSolidityKeyword(g.name))throw new s.SolidityProtectedKeywordError({param:e,name:g.name});let y=g.name?{name:g.name}:{},v="indexed"===g.modifier?{indexed:!0}:{},E=t?.structs??{},x={};if(l){n="tuple";let e=splitParameters(g.type),t=[],o=e.length;for(let n=0;n<o;n++)t.push(parseAbiParameter(e[n],{structs:E}));x={components:t}}else if(g.type in E)n="tuple",x={components:E[g.type]};else if(b.test(g.type))n=`${g.type}256`;else if(n=g.type,t?.type!=="struct"&&!isSolidityType(n))throw new i.UnknownSolidityTypeError({type:n});if(g.modifier){if(!t?.modifiers?.has?.(g.modifier))throw new s.InvalidModifierError({param:e,type:t?.type,modifier:g.modifier});if(d.functionModifiers.has(g.modifier)&&!isValidDataLocation(n,!!g.array))throw new s.InvalidFunctionModifierError({param:e,type:t?.type,modifier:g.modifier})}let P={type:`${n}${g.array??""}`,...y,...v,...x};return u.parameterCache.set(c,P),P}function splitParameters(e,t=[],n="",o=0){if(""===e){if(""===n)return t;if(0!==o)throw new l.InvalidParenthesisError({current:n,depth:o});return t.push(n.trim()),t}let i=e.length;for(let s=0;s<i;s++){let i=e[s],c=e.slice(s+1);switch(i){case",":return 0===o?splitParameters(c,[...t,n.trim()]):splitParameters(c,t,`${n}${i}`,o);case"(":return splitParameters(c,t,`${n}${i}`,o+1);case")":return splitParameters(c,t,`${n}${i}`,o-1);default:return splitParameters(c,t,`${n}${i}`,o)}}return[]}function isSolidityType(e){return"address"===e||"bool"===e||"function"===e||"string"===e||o.bytesRegex.test(e)||o.integerRegex.test(e)}t.parseAbiParameter=parseAbiParameter,t.splitParameters=splitParameters,t.isSolidityType=isSolidityType;let g=/^(?:after|alias|anonymous|apply|auto|byte|calldata|case|catch|constant|copyof|default|defined|error|event|external|false|final|function|immutable|implements|in|indexed|inline|internal|let|mapping|match|memory|mutable|null|of|override|partial|private|promise|public|pure|reference|relocatable|return|returns|sizeof|static|storage|struct|super|supports|switch|this|true|try|typedef|typeof|var|view|virtual)$/;function isSolidityKeyword(e){return"address"===e||"bool"===e||"function"===e||"string"===e||"tuple"===e||o.bytesRegex.test(e)||o.integerRegex.test(e)||g.test(e)}function isValidDataLocation(e,t){return t||"bytes"===e||"string"===e||"tuple"===e}t.isSolidityKeyword=isSolidityKeyword,t.isValidDataLocation=isValidDataLocation},8270:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.CircularReferenceError=t.InvalidParenthesisError=t.UnknownSignatureError=t.InvalidSignatureError=t.InvalidStructSignatureError=t.InvalidAbiParameterError=t.InvalidAbiParametersError=t.InvalidParameterError=t.SolidityProtectedKeywordError=t.InvalidModifierError=t.InvalidFunctionModifierError=t.InvalidAbiTypeParameterError=t.UnknownSolidityTypeError=t.InvalidAbiItemError=t.UnknownTypeError=t.parseAbiParameters=t.parseAbiParameter=t.parseAbiItem=t.parseAbi=t.formatAbiParameters=t.formatAbiParameter=t.formatAbiItem=t.formatAbi=t.narrow=t.BaseError=void 0;var o=n(58799);Object.defineProperty(t,"BaseError",{enumerable:!0,get:function(){return o.BaseError}});var i=n(74014);Object.defineProperty(t,"narrow",{enumerable:!0,get:function(){return i.narrow}});var s=n(9677);Object.defineProperty(t,"formatAbi",{enumerable:!0,get:function(){return s.formatAbi}});var c=n(64257);Object.defineProperty(t,"formatAbiItem",{enumerable:!0,get:function(){return c.formatAbiItem}});var l=n(81907);Object.defineProperty(t,"formatAbiParameter",{enumerable:!0,get:function(){return l.formatAbiParameter}});var u=n(19339);Object.defineProperty(t,"formatAbiParameters",{enumerable:!0,get:function(){return u.formatAbiParameters}});var d=n(30464);Object.defineProperty(t,"parseAbi",{enumerable:!0,get:function(){return d.parseAbi}});var p=n(14263);Object.defineProperty(t,"parseAbiItem",{enumerable:!0,get:function(){return p.parseAbiItem}});var m=n(15485);Object.defineProperty(t,"parseAbiParameter",{enumerable:!0,get:function(){return m.parseAbiParameter}});var b=n(4898);Object.defineProperty(t,"parseAbiParameters",{enumerable:!0,get:function(){return b.parseAbiParameters}});var g=n(65550);Object.defineProperty(t,"UnknownTypeError",{enumerable:!0,get:function(){return g.UnknownTypeError}}),Object.defineProperty(t,"InvalidAbiItemError",{enumerable:!0,get:function(){return g.InvalidAbiItemError}}),Object.defineProperty(t,"UnknownSolidityTypeError",{enumerable:!0,get:function(){return g.UnknownSolidityTypeError}});var y=n(5162);Object.defineProperty(t,"InvalidAbiTypeParameterError",{enumerable:!0,get:function(){return y.InvalidAbiTypeParameterError}}),Object.defineProperty(t,"InvalidFunctionModifierError",{enumerable:!0,get:function(){return y.InvalidFunctionModifierError}}),Object.defineProperty(t,"InvalidModifierError",{enumerable:!0,get:function(){return y.InvalidModifierError}}),Object.defineProperty(t,"SolidityProtectedKeywordError",{enumerable:!0,get:function(){return y.SolidityProtectedKeywordError}}),Object.defineProperty(t,"InvalidParameterError",{enumerable:!0,get:function(){return y.InvalidParameterError}}),Object.defineProperty(t,"InvalidAbiParametersError",{enumerable:!0,get:function(){return y.InvalidAbiParametersError}}),Object.defineProperty(t,"InvalidAbiParameterError",{enumerable:!0,get:function(){return y.InvalidAbiParameterError}});var v=n(69036);Object.defineProperty(t,"InvalidStructSignatureError",{enumerable:!0,get:function(){return v.InvalidStructSignatureError}}),Object.defineProperty(t,"InvalidSignatureError",{enumerable:!0,get:function(){return v.InvalidSignatureError}}),Object.defineProperty(t,"UnknownSignatureError",{enumerable:!0,get:function(){return v.UnknownSignatureError}});var E=n(88939);Object.defineProperty(t,"InvalidParenthesisError",{enumerable:!0,get:function(){return E.InvalidParenthesisError}});var x=n(11378);Object.defineProperty(t,"CircularReferenceError",{enumerable:!0,get:function(){return x.CircularReferenceError}})},74014:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.narrow=void 0,t.narrow=function(e){return e}},66128:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isTupleRegex=t.integerRegex=t.bytesRegex=t.execTyped=void 0,t.execTyped=function(e,t){let n=e.exec(t);return n?.groups},t.bytesRegex=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,t.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)?$/,t.isTupleRegex=/^\(.+?\).*?$/},4734:function(e,t){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="0.9.8"},27558:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAccount=void 0,t.parseAccount=function(e){return"string"==typeof e?{address:e,type:"json-rpc"}:e}},35334:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.publicKeyToAddress=void 0;let o=n(66830),i=n(35841);t.publicKeyToAddress=function(e){let t=(0,i.keccak256)(`0x${e.substring(4)}`).substring(26);return(0,o.checksumAddress)(`0x${t}`)}},50151:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEnsAddress=void 0;let o=n(55906),i=n(90181),s=n(48635),c=n(27025),l=n(41691),u=n(56945),d=n(7088),p=n(23412),m=n(37458),b=n(45828),g=n(2333);async function getEnsAddress(e,{blockNumber:t,blockTag:n,coinType:y,name:v,universalResolverAddress:E}){let x=E;if(!x){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");x=(0,c.getChainContractAddress)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}try{let c=(0,s.encodeFunctionData)({abi:o.addressResolverAbi,functionName:"addr",...null!=y?{args:[(0,p.namehash)(v),BigInt(y)]}:{args:[(0,p.namehash)(v)]}}),d=await (0,b.getAction)(e,g.readContract,"readContract")({address:x,abi:o.universalResolverResolveAbi,functionName:"resolve",args:[(0,u.toHex)((0,m.packetToBytes)(v)),c],blockNumber:t,blockTag:n});if("0x"===d[0])return null;let E=(0,i.decodeFunctionResult)({abi:o.addressResolverAbi,args:null!=y?[(0,p.namehash)(v),BigInt(y)]:void 0,functionName:"addr",data:d[0]});if("0x"===E||"0x00"===(0,l.trim)(E))return null;return E}catch(e){if((0,d.isNullUniversalResolverError)(e,"resolve"))return null;throw e}}t.getEnsAddress=getEnsAddress},19715:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEnsAvatar=void 0;let o=n(67299),i=n(45828),s=n(78376);async function getEnsAvatar(e,{blockNumber:t,blockTag:n,gatewayUrls:c,name:l,universalResolverAddress:u}){let d=await (0,i.getAction)(e,s.getEnsText,"getEnsText")({blockNumber:t,blockTag:n,key:"avatar",name:l,universalResolverAddress:u});if(!d)return null;try{return await (0,o.parseAvatarRecord)(e,{record:d,gatewayUrls:c})}catch{return null}}t.getEnsAvatar=getEnsAvatar},87935:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEnsName=void 0;let o=n(55906),i=n(27025),s=n(56945),c=n(7088),l=n(37458),u=n(45828),d=n(2333);async function getEnsName(e,{address:t,blockNumber:n,blockTag:p,universalResolverAddress:m}){let b=m;if(!b){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");b=(0,i.getChainContractAddress)({blockNumber:n,chain:e.chain,contract:"ensUniversalResolver"})}let g=`${t.toLowerCase().substring(2)}.addr.reverse`;try{let[i,c]=await (0,u.getAction)(e,d.readContract,"readContract")({address:b,abi:o.universalResolverReverseAbi,functionName:"reverse",args:[(0,s.toHex)((0,l.packetToBytes)(g))],blockNumber:n,blockTag:p});if(t.toLowerCase()!==c.toLowerCase())return null;return i}catch(e){if((0,c.isNullUniversalResolverError)(e,"reverse"))return null;throw e}}t.getEnsName=getEnsName},66738:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEnsResolver=void 0;let o=n(27025),i=n(56945),s=n(37458),c=n(45828),l=n(2333);async function getEnsResolver(e,{blockNumber:t,blockTag:n,name:u,universalResolverAddress:d}){let p=d;if(!p){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");p=(0,o.getChainContractAddress)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}let[m]=await (0,c.getAction)(e,l.readContract,"readContract")({address:p,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[(0,i.toHex)((0,s.packetToBytes)(u))],blockNumber:t,blockTag:n});return m}t.getEnsResolver=getEnsResolver},78376:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEnsText=void 0;let o=n(55906),i=n(90181),s=n(48635),c=n(27025),l=n(56945),u=n(7088),d=n(23412),p=n(37458),m=n(45828),b=n(2333);async function getEnsText(e,{blockNumber:t,blockTag:n,name:g,key:y,universalResolverAddress:v}){let E=v;if(!E){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");E=(0,c.getChainContractAddress)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}try{let c=await (0,m.getAction)(e,b.readContract,"readContract")({address:E,abi:o.universalResolverResolveAbi,functionName:"resolve",args:[(0,l.toHex)((0,p.packetToBytes)(g)),(0,s.encodeFunctionData)({abi:o.textResolverAbi,functionName:"text",args:[(0,d.namehash)(g),y]})],blockNumber:t,blockTag:n});if("0x"===c[0])return null;let u=(0,i.decodeFunctionResult)({abi:o.textResolverAbi,functionName:"text",data:c[0]});return""===u?null:u}catch(e){if((0,u.isNullUniversalResolverError)(e,"resolve"))return null;throw e}}t.getEnsText=getEnsText},61519:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.getEventParameters=t.getFunctionParameters=t.getContract=void 0;let o=n(45828),i=n(1001),s=n(15965),c=n(58958),l=n(2333),u=n(22140),d=n(42573),p=n(60722);function getFunctionParameters(e){let t=e.length&&Array.isArray(e[0]),n=t?e[0]:[],o=(t?e[1]:e[0])??{};return{args:n,options:o}}function getEventParameters(e,t){let n=!1;Array.isArray(e[0])?n=!0:1===e.length?n=t.inputs.some(e=>e.indexed):2===e.length&&(n=!0);let o=n?e[0]:void 0,i=(n?e[1]:e[0])??{};return{args:o,options:i}}t.getContract=function({abi:e,address:t,publicClient:n,walletClient:m}){let b=null!=n,g=null!=m,y={},v=!1,E=!1,x=!1;for(let t of e)if("function"===t.type?"view"===t.stateMutability||"pure"===t.stateMutability?v=!0:E=!0:"event"===t.type&&(x=!0),v&&E&&x)break;return b&&(v&&(y.read=new Proxy({},{get:(i,s)=>(...i)=>{let{args:c,options:u}=getFunctionParameters(i);return(0,o.getAction)(n,l.readContract,"readContract")({abi:e,address:t,functionName:s,args:c,...u})}})),E&&(y.simulate=new Proxy({},{get:(i,s)=>(...i)=>{let{args:c,options:l}=getFunctionParameters(i);return(0,o.getAction)(n,u.simulateContract,"simulateContract")({abi:e,address:t,functionName:s,args:c,...l})}})),x&&(y.createEventFilter=new Proxy({},{get:(s,c)=>(...s)=>{let l=e.find(e=>"event"===e.type&&e.name===c),{args:u,options:d}=getEventParameters(s,l);return(0,o.getAction)(n,i.createContractEventFilter,"createContractEventFilter")({abi:e,address:t,eventName:c,args:u,...d})}}),y.getEvents=new Proxy({},{get:(i,s)=>(...i)=>{let l=e.find(e=>"event"===e.type&&e.name===s),{args:u,options:d}=getEventParameters(i,l);return(0,o.getAction)(n,c.getContractEvents,"getContractEvents")({abi:e,address:t,eventName:s,args:u,...d})}}),y.watchEvent=new Proxy({},{get:(i,s)=>(...i)=>{let c=e.find(e=>"event"===e.type&&e.name===s),{args:l,options:u}=getEventParameters(i,c);return(0,o.getAction)(n,d.watchContractEvent,"watchContractEvent")({abi:e,address:t,eventName:s,args:l,...u})}}))),g&&E&&(y.write=new Proxy({},{get:(n,i)=>(...n)=>{let{args:s,options:c}=getFunctionParameters(n);return(0,o.getAction)(m,p.writeContract,"writeContract")({abi:e,address:t,functionName:i,args:s,...c})}})),(b||g)&&E&&(y.estimateGas=new Proxy({},{get:(i,c)=>(...i)=>{let{args:l,options:u}=getFunctionParameters(i),d=n??m;return(0,o.getAction)(d,s.estimateContractGas,"estimateContractGas")({abi:e,address:t,functionName:c,args:l,...u,account:u.account??m.account})}})),y.address=t,y.abi=e,y},t.getFunctionParameters=getFunctionParameters,t.getEventParameters=getEventParameters},52234:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getRevertErrorData=t.call=void 0;let o=n(27558),i=n(55906),s=n(48914),c=n(78498),l=n(99174),u=n(91349),d=n(90181),p=n(48635),m=n(27025),b=n(56945),g=n(91414),y=n(56725),v=n(77300),E=n(32875),x=n(80525);async function call(e,t){let{account:i=e.account,batch:c=!!e.batch?.multicall,blockNumber:u,blockTag:d="latest",accessList:p,data:m,gas:E,gasPrice:P,maxFeePerGas:_,maxPriorityFeePerGas:I,nonce:j,to:R,value:M,...F}=t,q=i?(0,o.parseAccount)(i):void 0;try{(0,x.assertRequest)(t);let n=u?(0,b.numberToHex)(u):void 0,o=n||d,i=e.chain?.formatters?.transactionRequest?.format,g=i||v.formatTransactionRequest,H=g({...(0,y.extract)(F,{format:i}),from:q?.address,accessList:p,data:m,gas:E,gasPrice:P,maxFeePerGas:_,maxPriorityFeePerGas:I,nonce:j,to:R,value:M});if(c&&function({request:e}){let{data:t,to:n,...o}=e;return!(!t||t.startsWith(s.aggregate3Signature))&&!!n&&!(Object.values(o).filter(e=>void 0!==e).length>0)}({request:H}))try{return await scheduleMulticall(e,{...H,blockNumber:u,blockTag:d})}catch(e){if(!(e instanceof l.ClientChainNotConfiguredError)&&!(e instanceof l.ChainDoesNotSupportContract))throw e}let z=await e.request({method:"eth_call",params:o?[H,o]:[H]});if("0x"===z)return{data:void 0};return{data:z}}catch(c){let o=getRevertErrorData(c),{offchainLookup:i,offchainLookupSignature:s}=await Promise.resolve().then(()=>n(39978));if(o?.slice(0,10)===s&&R)return{data:await i(e,{data:o,to:R})};throw(0,g.getCallError)(c,{...t,account:q,chain:e.chain})}}async function scheduleMulticall(e,t){let{batchSize:n=1024,wait:o=0}="object"==typeof e.batch?.multicall?e.batch.multicall:{},{blockNumber:s,blockTag:c="latest",data:g,multicallAddress:y,to:v}=t,x=y;if(!x){if(!e.chain)throw new l.ClientChainNotConfiguredError;x=(0,m.getChainContractAddress)({blockNumber:s,chain:e.chain,contract:"multicall3"})}let P=s?(0,b.numberToHex)(s):void 0,_=P||c,{schedule:I}=(0,E.createBatchScheduler)({id:`${e.uid}.${_}`,wait:o,shouldSplitBatch(e){let t=e.reduce((e,{data:t})=>e+(t.length-2),0);return t>2*n},fn:async t=>{let n=t.map(e=>
46({allowFailure:!0,callData:e.data,target:e.to})),o=(0,p.encodeFunctionData)({abi:i.multicall3Abi,args:[n],functionName:"aggregate3"}),s=await e.request({method:"eth_call",params:[{data:o,to:x},_]});return(0,d.decodeFunctionResult)({abi:i.multicall3Abi,args:[n],functionName:"aggregate3",data:s||"0x"})}}),[{returnData:j,success:R}]=await I({data:g,to:v});if(!R)throw new u.RawContractError({data:j});return"0x"===j?{data:void 0}:{data:j}}function getRevertErrorData(e){if(!(e instanceof c.BaseError))return;let t=e.walk();return"object"==typeof t.data?t.data.data:t.data}t.call=call,t.getRevertErrorData=getRevertErrorData},89973:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createBlockFilter=void 0;let o=n(65208);async function createBlockFilter(e){let t=(0,o.createFilterRequestScope)(e,{method:"eth_newBlockFilter"}),n=await e.request({method:"eth_newBlockFilter"});return{id:n,request:t(n),type:"block"}}t.createBlockFilter=createBlockFilter},1001:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createContractEventFilter=void 0;let o=n(3540),i=n(56945),s=n(65208);async function createContractEventFilter(e,{address:t,abi:n,args:c,eventName:l,fromBlock:u,strict:d,toBlock:p}){let m=(0,s.createFilterRequestScope)(e,{method:"eth_newFilter"}),b=l?(0,o.encodeEventTopics)({abi:n,args:c,eventName:l}):void 0,g=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:"bigint"==typeof u?(0,i.numberToHex)(u):u,toBlock:"bigint"==typeof p?(0,i.numberToHex)(p):p,topics:b}]});return{abi:n,args:c,eventName:l,id:g,request:m(g),strict:d,type:"event"}}t.createContractEventFilter=createContractEventFilter},38412:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createEventFilter=void 0;let o=n(3540),i=n(56945),s=n(65208);async function createEventFilter(e,{address:t,args:n,event:c,events:l,fromBlock:u,strict:d,toBlock:p}={}){let m=l??(c?[c]:void 0),b=(0,s.createFilterRequestScope)(e,{method:"eth_newFilter"}),g=[];m&&(g=[m.flatMap(e=>(0,o.encodeEventTopics)({abi:[e],eventName:e.name,args:n}))],c&&(g=g[0]));let y=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:"bigint"==typeof u?(0,i.numberToHex)(u):u,toBlock:"bigint"==typeof p?(0,i.numberToHex)(p):p,...g.length?{topics:g}:{}}]});return{abi:m,args:n,eventName:c?c.name:void 0,fromBlock:u,id:y,request:b(y),strict:d,toBlock:p,type:"event"}}t.createEventFilter=createEventFilter},83323:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createPendingTransactionFilter=void 0;let o=n(65208);async function createPendingTransactionFilter(e){let t=(0,o.createFilterRequestScope)(e,{method:"eth_newPendingTransactionFilter"}),n=await e.request({method:"eth_newPendingTransactionFilter"});return{id:n,request:t(n),type:"transaction"}}t.createPendingTransactionFilter=createPendingTransactionFilter},15965:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.estimateContractGas=void 0;let o=n(27558),i=n(48635),s=n(59895),c=n(45828),l=n(89335);async function estimateContractGas(e,{abi:t,address:n,args:u,functionName:d,...p}){let m=(0,i.encodeFunctionData)({abi:t,args:u,functionName:d});try{let t=await (0,c.getAction)(e,l.estimateGas,"estimateGas")({data:m,to:n,...p});return t}catch(i){let e=p.account?(0,o.parseAccount)(p.account):void 0;throw(0,s.getContractError)(i,{abi:t,address:n,args:u,docsPath:"/docs/contract/estimateContractGas",functionName:d,sender:e?.address})}}t.estimateContractGas=estimateContractGas},98346:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.internal_estimateFeesPerGas=t.estimateFeesPerGas=void 0;let o=n(30375),i=n(45828),s=n(63433),c=n(67728),l=n(1896);async function estimateFeesPerGas(e,t){return internal_estimateFeesPerGas(e,t)}async function internal_estimateFeesPerGas(e,t){let{block:n,chain:u=e.chain,request:d,type:p="eip1559"}=t||{},m=await (async()=>"function"==typeof u?.fees?.baseFeeMultiplier?u.fees.baseFeeMultiplier({block:n,client:e,request:d}):u?.fees?.baseFeeMultiplier??1.2)();if(m<1)throw new o.BaseFeeScalarError;let b=m.toString().split(".")[1]?.length??0,g=10**b,multiply=e=>e*BigInt(Math.ceil(m*g))/BigInt(g),y=n||await (0,i.getAction)(e,c.getBlock,"getBlock")({});if("function"==typeof u?.fees?.estimateFeesPerGas)return u.fees.estimateFeesPerGas({block:n,client:e,multiply,request:d,type:p});if("eip1559"===p){if("bigint"!=typeof y.baseFeePerGas)throw new o.Eip1559FeesNotSupportedError;let t=d?.maxPriorityFeePerGas?d.maxPriorityFeePerGas:await (0,s.internal_estimateMaxPriorityFeePerGas)(e,{block:y,chain:u,request:d}),n=multiply(y.baseFeePerGas),i=d?.maxFeePerGas??n+t;return{maxFeePerGas:i,maxPriorityFeePerGas:t}}let v=d?.gasPrice??multiply(await (0,i.getAction)(e,l.getGasPrice,"getGasPrice")({}));return{gasPrice:v}}
46t.estimateFeesPerGas=estimateFeesPerGas,t.internal_estimateFeesPerGas=internal_estimateFeesPerGas},89335:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.estimateGas=void 0;let o=n(27558),i=n(21506),s=n(56945),c=n(35043),l=n(56725),u=n(77300),d=n(80525),p=n(68094);async function estimateGas(e,t){let n=t.account??e.account;if(!n)throw new i.AccountNotFoundError({docsPath:"/docs/actions/public/estimateGas"});let m=(0,o.parseAccount)(n);try{let{accessList:n,blockNumber:o,blockTag:i,data:c,gas:b,gasPrice:g,maxFeePerGas:y,maxPriorityFeePerGas:v,nonce:E,to:x,value:P,..._}="local"===m.type?await (0,p.prepareTransactionRequest)(e,t):t,I=o?(0,s.numberToHex)(o):void 0,j=I||i;(0,d.assertRequest)(t);let R=e.chain?.formatters?.transactionRequest?.format,M=R||u.formatTransactionRequest,F=M({...(0,l.extract)(_,{format:R}),from:m.address,accessList:n,data:c,gas:b,gasPrice:g,maxFeePerGas:y,maxPriorityFeePerGas:v,nonce:E,to:x,value:P}),q=await e.request({method:"eth_estimateGas",params:j?[F,j]:[F]});return BigInt(q)}catch(n){throw(0,c.getEstimateGasError)(n,{...t,account:m,chain:e.chain})}}t.estimateGas=estimateGas},63433:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.internal_estimateMaxPriorityFeePerGas=t.estimateMaxPriorityFeePerGas=void 0;let o=n(30375),i=n(84008),s=n(45828),c=n(67728),l=n(1896);async function estimateMaxPriorityFeePerGas(e,t){return internal_estimateMaxPriorityFeePerGas(e,t)}async function internal_estimateMaxPriorityFeePerGas(e,t){let{block:n,chain:u=e.chain,request:d}=t||{};if("function"==typeof u?.fees?.defaultPriorityFee){let t=n||await (0,s.getAction)(e,c.getBlock,"getBlock")({});return u.fees.defaultPriorityFee({block:t,client:e,request:d})}if(void 0!==u?.fees?.defaultPriorityFee)return u?.fees?.defaultPriorityFee;try{let t=await e.request({method:"eth_maxPriorityFeePerGas"});return(0,i.hexToBigInt)(t)}catch{let[t,i]=await Promise.all([n?Promise.resolve(n):(0,s.getAction)(e,c.getBlock,"getBlock")({}),(0,s.getAction)(e,l.getGasPrice,"getGasPrice")({})]);if("bigint"!=typeof t.baseFeePerGas)throw new o.Eip1559FeesNotSupportedError;let u=i-t.baseFeePerGas;if(u<0n)return 0n;return u}}t.estimateMaxPriorityFeePerGas=estimateMaxPriorityFeePerGas,t.internal_estimateMaxPriorityFeePerGas=internal_estimateMaxPriorityFeePerGas},62932:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getBalance=void 0;let o=n(56945);async function getBalance(e,{address:t,blockNumber:n,blockTag:i="latest"}){let s=n?(0,o.numberToHex)(n):void 0,c=await e.request({method:"eth_getBalance",params:[t,s||i]});return BigInt(c)}t.getBalance=getBalance},67728:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getBlock=void 0;let o=n(48962),i=n(56945),s=n(5729);async function getBlock(e,{blockHash:t,blockNumber:n,blockTag:c,includeTransactions:l}={}){let u=l??!1,d=void 0!==n?(0,i.numberToHex)(n):void 0,p=null;if(!(p=t?await e.request({method:"eth_getBlockByHash",params:[t,u]}):await e.request({method:"eth_getBlockByNumber",params:[d||(c??"latest"),u]})))throw new o.BlockNotFoundError({blockHash:t,blockNumber:n});let m=e.chain?.formatters?.block?.format||s.formatBlock;return m(p)}t.getBlock=getBlock},99615:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getBlockNumber=t.getBlockNumberCache=void 0;let o=n(68414),cacheKey=e=>`blockNumber.${e}`;async function getBlockNumber(e,{cacheTime:t=e.cacheTime,maxAge:n}={}){let i=await (0,o.withCache)(()=>e.request({method:"eth_blockNumber"}),{cacheKey:cacheKey(e.uid),cacheTime:n??t});return BigInt(i)}t.getBlockNumberCache=function(e){return(0,o.getCache)(cacheKey(e))},t.getBlockNumber=getBlockNumber},73156:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getBlockTransactionCount=void 0;let o=n(84008),i=n(56945);async function getBlockTransactionCount(e,{blockHash:t,blockNumber:n,blockTag:s="latest"}={}){let c;let l=void 0!==n?(0,i.numberToHex)(n):void 0;return c=t?await e.request({method:"eth_getBlockTransactionCountByHash",params:[t]}):await e.request({method:"eth_getBlockTransactionCountByNumber",params:[l||s]}),(0,o.hexToNumber)(c)}t.getBlockTransactionCount=getBlockTransactionCount},16408:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.getBytecode=void 0;let o=n(56945);async function getBytecode(e,{address:t,blockNumber:n,blockTag:i="latest"}){let s=void 0!==n?(0,o.numberToHex)(n):void 0,c=await e.request({method:"eth_getCode",params:[t,s||i]});if("0x"!==c)return c}t.getBytecode=getBytecode},16849:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getChainId=void 0;let o=n(84008);async function getChainId(e){let t=await e.request({method:"eth_chainId"});return(0,o.hexToNumber)(t)}t.getChainId=getChainId},58958:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getContractEvents=void 0;let o=n(68340),i=n(45828),s=n(72362);async function getContractEvents(e,{abi:t,address:n,args:c,blockHash:l,eventName:u,fromBlock:d,toBlock:p,strict:m}){let b=u?(0,o.getAbiItem)({abi:t,name:u}):void 0,g=b?void 0:t.filter(e=>"event"===e.type);return(0,i.getAction)(e,s.getLogs,"getLogs")({address:n,args:c,blockHash:l,event:b,events:g,fromBlock:d,toBlock:p,strict:m})}t.getContractEvents=getContractEvents},49161:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFeeHistory=void 0;let o=n(56945),i=n(9023);async function getFeeHistory(e,{blockCount:t,blockNumber:n,blockTag:s="latest",rewardPercentiles:c}){let l=n?(0,o.numberToHex)(n):void 0,u=await e.request({method:"eth_feeHistory",params:[(0,o.numberToHex)(t),l||s,c]});return(0,i.formatFeeHistory)(u)}t.getFeeHistory=getFeeHistory},55371:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFilterChanges=void 0;let o=n(82521),i=n(35813),s=n(8875);async function getFilterChanges(e,{filter:t}){let n="strict"in t&&t.strict,c=await t.request({method:"eth_getFilterChanges",params:[t.id]});return c.map(e=>{if("string"==typeof e)return e;try{let{eventName:o,args:c}="abi"in t&&t.abi?(0,i.decodeEventLog)({abi:t.abi,data:e.data,topics:e.topics,strict:n}):{eventName:void 0,args:void 0};return(0,s.formatLog)(e,{args:c,eventName:o})}catch(c){let n,i;if(c instanceof o.DecodeLogDataMismatch||c instanceof o.DecodeLogTopicsMismatch){if("strict"in t&&t.strict)return;n=c.abiItem.name,i=c.abiItem.inputs?.some(e=>!("name"in e&&e.name))}return(0,s.formatLog)(e,{args:i?[]:{},eventName:n})}}).filter(Boolean)}t.getFilterChanges=getFilterChanges},58431:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFilterLogs=void 0;let o=n(82521),i=n(35813),s=n(8875);async function getFilterLogs(e,{filter:t}){let n=t.strict??!1,c=await t.request({method:"eth_getFilterLogs",params:[t.id]});return c.map(e=>{try{let{eventName:o,args:c}="abi"in t&&t.abi?(0,i.decodeEventLog)({abi:t.abi,data:e.data,topics:e.topics,strict:n}):{eventName:void 0,args:void 0};return(0,s.formatLog)(e,{args:c,eventName:o})}catch(c){let n,i;if(c instanceof o.DecodeLogDataMismatch||c instanceof o.DecodeLogTopicsMismatch){if("strict"in t&&t.strict)return;n=c.abiItem.name,i=c.abiItem.inputs?.some(e=>!("name"in e&&e.name))}return(0,s.formatLog)(e,{args:i?[]:{},eventName:n})}}).filter(Boolean)}t.getFilterLogs=getFilterLogs},1896:function(e,t){"use strict";async function getGasPrice(e){let t=await e.request({method:"eth_gasPrice"});return BigInt(t)}Object.defineProperty(t,"__esModule",{value:!0}),t.getGasPrice=void 0,t.getGasPrice=getGasPrice},72362:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getLogs=void 0;let o=n(82521),i=n(35813),s=n(3540),c=n(56945),l=n(8875);async function getLogs(e,{address:t,blockHash:n,fromBlock:u,toBlock:d,event:p,events:m,args:b,strict:g}={}){let y=g??!1,v=m??(p?[p]:void 0),E=[];return v&&(E=[v.flatMap(e=>(0,s.encodeEventTopics)({abi:[e],eventName:e.name,args:b}))],p&&(E=E[0])),(n?await e.request({method:"eth_getLogs",params:[{address:t,topics:E,blockHash:n}]}):await e.request({method:"eth_getLogs",params:[{address:t,topics:E,fromBlock:"bigint"==typeof u?(0,c.numberToHex)(u):u,toBlock:"bigint"==typeof d?(0,c.numberToHex)(d):d}]})).map(e=>{try{let{eventName:t,args:n}=v?(0,i.decodeEventLog)({abi:v,data:e.data,topics:e.topics,strict:y}):{eventName:void 0,args:void 0};return(0,l.formatLog)(e,{args:n,eventName:t})}catch(i){let t,n;if(i instanceof o.DecodeLogDataMismatch||i instanceof o.DecodeLogTopicsMismatch){if
46(y)return;t=i.abiItem.name,n=i.abiItem.inputs?.some(e=>!("name"in e&&e.name))}return(0,l.formatLog)(e,{args:n?[]:{},eventName:t})}}).filter(Boolean)}t.getLogs=getLogs},37561:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getProof=void 0;let o=n(56945),i=n(76837);async function getProof(e,{address:t,blockNumber:n,blockTag:s,storageKeys:c}){let l=void 0!==n?(0,o.numberToHex)(n):void 0,u=await e.request({method:"eth_getProof",params:[t,c,l||(s??"latest")]});return(0,i.formatProof)(u)}t.getProof=getProof},4782:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getStorageAt=void 0;let o=n(56945);async function getStorageAt(e,{address:t,blockNumber:n,blockTag:i="latest",slot:s}){let c=void 0!==n?(0,o.numberToHex)(n):void 0,l=await e.request({method:"eth_getStorageAt",params:[t,s,c||i]});return l}t.getStorageAt=getStorageAt},92357:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTransaction=void 0;let o=n(33841),i=n(56945),s=n(93756);async function getTransaction(e,{blockHash:t,blockNumber:n,blockTag:c,hash:l,index:u}){let d=c||"latest",p=void 0!==n?(0,i.numberToHex)(n):void 0,m=null;if(l?m=await e.request({method:"eth_getTransactionByHash",params:[l]}):t?m=await e.request({method:"eth_getTransactionByBlockHashAndIndex",params:[t,(0,i.numberToHex)(u)]}):(p||d)&&(m=await e.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[p||d,(0,i.numberToHex)(u)]})),!m)throw new o.TransactionNotFoundError({blockHash:t,blockNumber:n,blockTag:d,hash:l,index:u});let b=e.chain?.formatters?.transaction?.format||s.formatTransaction;return b(m)}t.getTransaction=getTransaction},74271:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTransactionConfirmations=void 0;let o=n(45828),i=n(99615),s=n(92357);async function getTransactionConfirmations(e,{hash:t,transactionReceipt:n}){let[c,l]=await Promise.all([(0,o.getAction)(e,i.getBlockNumber,"getBlockNumber")({}),t?(0,o.getAction)(e,s.getTransaction,"getBlockNumber")({hash:t}):void 0]),u=n?.blockNumber||l?.blockNumber;return u?c-u+1n:0n}t.getTransactionConfirmations=getTransactionConfirmations},72888:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTransactionCount=void 0;let o=n(84008),i=n(56945);async function getTransactionCount(e,{address:t,blockTag:n="latest",blockNumber:s}){let c=await e.request({method:"eth_getTransactionCount",params:[t,s?(0,i.numberToHex)(s):n]});return(0,o.hexToNumber)(c)}t.getTransactionCount=getTransactionCount},72471:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTransactionReceipt=void 0;let o=n(33841),i=n(10198);async function getTransactionReceipt(e,{hash:t}){let n=await e.request({method:"eth_getTransactionReceipt",params:[t]});if(!n)throw new o.TransactionReceiptNotFoundError({hash:t});let s=e.chain?.formatters?.transactionReceipt?.format||i.formatTransactionReceipt;return s(n)}t.getTransactionReceipt=getTransactionReceipt},27779:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.multicall=void 0;let o=n(55906),i=n(82521),s=n(78498),c=n(91349),l=n(90181),u=n(48635),d=n(27025),p=n(59895),m=n(45828),b=n(2333);async function multicall(e,t){let{allowFailure:n=!0,batchSize:g,blockNumber:y,blockTag:v,contracts:E,multicallAddress:x}=t,P=g??("object"==typeof e.batch?.multicall&&e.batch.multicall.batchSize||1024),_=x;if(!_){if(!e.chain)throw Error("client chain not configured. multicallAddress is required.");_=(0,d.getChainContractAddress)({blockNumber:y,chain:e.chain,contract:"multicall3"})}let I=[[]],j=0,R=0;for(let e=0;e<E.length;e++){let{abi:t,address:o,args:i,functionName:s}=E[e];try{let e=(0,u.encodeFunctionData)({abi:t,args:i,functionName:s});R+=(e.length-2)/2,P>0&&R>P&&I[j].length>0&&(j++,R=(e.length-2)/2,I[j]=[]),I[j]=[...I[j],{allowFailure:!0,callData:e,target:o}]}catch(c){let e=(0,p.getContractError)(c,{abi:t,address:o,args:i,docsPath:"/docs/contract/multicall",functionName:s});if(!n)throw e;I[j]=[...I[j],{allowFailure:!0,callData:"0x",target:o}]}}let M=await Promise.allSettled(I.map(t=>(0,m.getAction)(e,b.readContract,"readContract")({abi:o.multicall3Abi,address:_,args:[t],blockNumber:y,blockTag:v,functionName:"aggregate3"}))),F=[];for(let e=0;e<M.length;e++){let t=M[e];if("rejected"===t.status){if(!n)throw t.reason;for(let n=0;n<I[e].length;n++)F.push({status:"failure",error:t.reason,result:void 0});continue}let o=t.value;for(let t=0;t<o.length;t++){let{returnData:s,success:u}=o[t],{callData:d}=I[e][t],{abi:m,address:b,functionName:g,args:y}=E[F.length];try{if("0x"===d)throw new i.AbiDecodingZeroDataError;if(!u)throw new c.RawContractError({data:s});let e=(0,l.decodeFunctionResult)({abi:m,args:y,data:s,functionName:g});F.push(n?{result:e,status:"success"}:e)}catch(t){let e=(0,p.getContractError)(t,{abi:m,address:b,args:y,docsPath:"/docs/contract/multicall",functionName:g});if(!n)throw e;F.push({error:e,result:void 0,status:"failure"})}}}if(F.length!==E.length)throw new s.BaseError("multicall results mismatch");return F}t.multicall=multicall},2333:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.readContract=void 0;let o=n(90181),i=n(48635),s=n(59895),c=n(45828),l=n(52234);async function readContract(e,{abi:t,address:n,args:u,functionName:d,...p}){let m=(0,i.encodeFunctionData)({abi:t,args:u,functionName:d});try{let{data:i}=await (0,c.getAction)(e,l.call,"call")({data:m,to:n,...p});return(0,o.decodeFunctionResult)({abi:t,args:u,functionName:d,data:i||"0x"})}catch(e){throw(0,s.getContractError)(e,{abi:t,address:n,args:u,docsPath:"/docs/contract/readContract",functionName:d})}}t.readContract=readContract},22140:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.simulateContract=void 0;let o=n(27558),i=n(90181),s=n(48635),c=n(59895),l=n(45828),u=n(52234);async function simulateContract(e,{abi:t,address:n,args:d,dataSuffix:p,functionName:m,...b}){let g=b.account?(0,o.parseAccount)(b.account):void 0,y=(0,s.encodeFunctionData)({abi:t,args:d,functionName:m});try{let{data:o}=await (0,l.getAction)(e,u.call,"call")({batch:!1,data:`${y}${p?p.replace("0x",""):""}`,to:n,...b}),s=(0,i.decodeFunctionResult)({abi:t,args:d,functionName:m,data:o||"0x"});return{result:s,request:{abi:t,address:n,args:d,dataSuffix:p,functionName:m,...b}}}catch(e){throw(0,c.getContractError)(e,{abi:t,address:n,args:d,docsPath:"/docs/contract/simulateContract",functionName:m,sender:g?.address})}}t.simulateContract=simulateContract},35220:function(e,t){"use strict";async function uninstallFilter(e,{filter:t}){return t.request({method:"eth_uninstallFilter",params:[t.id]})}Object.defineProperty(t,"__esModule",{value:!0}),t.uninstallFilter=void 0,t.uninstallFilter=uninstallFilter},48433:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyHash=void 0;let o=n(55906),i=n(72229),s=n(91349),c=n(46241),l=n(45828),u=n(51999),d=n(52234);async function verifyHash(e,{address:t,hash:n,signature:p,...m}){let b=(0,u.isHex)(p)?p:(0,u.toHex)(p);try{let{data:s}=await (0,l.getAction)(e,d.call,"call")({data:(0,u.encodeDeployData)({abi:o.universalSignatureValidatorAbi,args:[t,n,b],bytecode:i.universalSignatureValidatorByteCode}),...m});return(0,c.isBytesEqual)(s??"0x0","0x1")}catch(e){if(e instanceof s.CallExecutionError)return!1;throw e}}t.verifyHash=verifyHash},95832:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyMessage=void 0;let o=n(51999),i=n(48433);async function verifyMessage(e,{address:t,message:n,signature:s,...c}){let l=(0,o.hashMessage)(n);return(0,i.verifyHash)(e,{address:t,hash:l,signature:s,...c})}t.verifyMessage=verifyMessage},3213:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyTypedData=void 0;let o=n(59454),i=n(48433);async function verifyTypedData(e,{address:t,signature:n,message:s,primaryType:c,types:l,domain:u,...d}){let p=(0,o.hashTypedData)({message:s,primaryType:c,types:l,domain:u});return(0,i.verifyHash)(e,{address:t,hash:p,signature:n,...d})}t.verifyTypedData=verifyTypedData},93492:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.waitForTransactionReceipt=void 0;let o=n(48962),i=n(33841),s=n(45828),c=n(27057),l=n(67783),u=n(36774),d=n(67728),p=n(92357),m=n(72471),b=n(97866);async function waitForTransactionReceipt(e,{confirmations:t=1,hash:n,onReplaced:g,pollingInterval:y=e.pollingInterval,timeout:v}){let E,x,P;let _=(0,u.stringify)(["waitForTransactionReceipt",e.uid,n]),I=!1;return new Promise((u,j)=>{v&&setTimeout(()=>j(new i.WaitForTransactionReceiptTimeoutError({hash:n})),v);let R=(0,c.observe)(_,{onReplaced:g,resolve:u,reject:j},c=>{let u=(0,s.getAction)(e,b.watchBlockNumber,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:y,async onBlockNumber(b){if(I)return;let g=b,done=e=>{u(),e(),R()};try{if(P){if(t>1&&(!P.blockNumber||g-P.blockNumber+1n<t))return;done(()=>c.resolve(P));return}if(E||(I=!0,await (0,l.withRetry)(async()=>{(E=await (0,s.getAction)(e,p.getTransaction,"getTransaction")({hash:n})).blockNumber&&(g=E.blockNumber)},{delay:({count:e})=>200*~~(1<<e),retryCount:6}),I=!1),P=await (0,s.getAction)(e,m.getTransactionReceipt,"getTransactionReceipt")({hash:n}),t>1&&(!P.blockNumber||g-P.blockNumber+1n<t))return;done(()=>c.resolve(P))}catch(n){if(E&&(n instanceof i.TransactionNotFoundError||n instanceof i.TransactionReceiptNotFoundError))try{x=E,I=!0;let n=await (0,l.withRetry)(()=>(0,s.getAction)(e,d.getBlock,"getBlock")({blockNumber:g,includeTransactions:!0}),{delay:({count:e})=>200*~~(1<<e),retryCount:6,shouldRetry:({error:e})=>e instanceof o.BlockNotFoundError});I=!1;let i=n.transactions.find(({from:e,nonce:t})=>e===x.from&&t===x.nonce);if(!i||(P=await (0,s.getAction)(e,m.getTransactionReceipt,"getTransactionReceipt")({hash:i.hash}),t>1&&(!P.blockNumber||g-P.blockNumber+1n<t)))return;let u="replaced";i.to===x.to&&i.value===x.value?u="repriced":i.from===i.to&&0n===i.value&&(u="cancelled"),done(()=>{c.onReplaced?.({reason:u,replacedTransaction:x,transaction:i,transactionReceipt:P}),c.resolve(P)})}catch(e){done(()=>c.reject(e))}else done(()=>c.reject(n))}}})})})}t.waitForTransactionReceipt=waitForTransactionReceipt},97866:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.watchBlockNumber=void 0;let o=n(84008),i=n(45828),s=n(27057),c=n(32815),l=n(36774),u=n(99615);t.watchBlockNumber=function(e,{emitOnBegin:t=!1,emitMissed:n=!1,onBlockNumber:d,onError:p,poll:m,pollingInterval:b=e.pollingInterval}){let g,y,v;let E=void 0!==m?m:"webSocket"!==e.transport.type;return E?(()=>{let o=(0,l.stringify)(["watchBlockNumber",e.uid,t,n,b]);return(0,s.observe)(o,{onBlockNumber:d,onError:p},o=>(0,c.poll)(async()=>{try{let t=await (0,i.getAction)(e,u.getBlockNumber,"getBlockNumber")({cacheTime:0});if(g){if(t===g)return;if(t-g>1&&n)for(let e=g+1n;e<t;e++)o.onBlockNumber(e,g),g=e}(!g||t>g)&&(o.onBlockNumber(t,g),g=t)}catch(e){o.onError?.(e)}},{emitOnBegin:t,interval:b}))})():(y=!0,v=()=>y=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newHeads"],onData(e){if(!y)return;let t=(0,o.hexToBigInt)(e.result?.number);d(t,g),g=t},onError(e){p?.(e)}});v=t,y||v()}catch(e){p?.(e)}})(),v)}},76168:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.watchBlocks=void 0;let o=n(5729),i=n(45828),s=n(27057),c=n(32815),l=n(36774),u=n(67728);t.watchBlocks=function(e,{blockTag:t="latest",emitMissed:n=!1,emitOnBegin:d=!1,onBlock:p,onError:m,includeTransactions:b,poll:g,pollingInterval:y=e.pollingInterval}){let v,E,x;let P=void 0!==g?g:"webSocket"!==e.transport.type,_=b??!1;return P?(()=>{let o=(0,l.stringify)(["watchBlocks",e.uid,n,d,_,y]);return(0,s.observe)(o,{onBlock:p,onError:m},o=>(0,c.poll)(async()=>{try{let s=await (0,i.getAction)(e,u.getBlock,"getBlock")({blockTag:t,includeTransactions:_});if(s.number&&v?.number){if(s.number===v.number)return;if(s.number-v.number>1&&n)for(let t=v?.number+1n;t<s.number;t++){let n=await (0,i.getAction)(e,u.getBlock,"getBlock")({blockNumber:t,includeTransactions:_});o.onBlock(n,v),v=n}}(!v?.number||"pending"===t&&!s?.number||s.number&&s.number>v.number)&&(o.onBlock(s,v),v=s)}catch(e){o.onError?.(e)}},{emitOnBegin:d,interval:y}))})():(E=!0,x=()=>E=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newHeads"],onData(t){if(!E)return;let n=e.chain?.formatters?.block?.format||o.formatBlock,i=n(t.result);p(i,v),v=i},onError(e){m?.(e)}});x=t,E||x()}catch(e){m?.(e)}})(),x)}},42573:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.watchContractEvent=void 0;let o=n(27057),i=n(32815),s=n(36774),c=n(82521),l=n(28516),u=n(35813),d=n(3540),p=n(8875),m=n(45828),b=n(1001),g=n(99615),y=n(58958),v=n(55371),E=n(35220);t.watchContractEvent=function(e,{abi:t,address:n,args:x,batch:P=!0,eventName:_,onError:I,onLogs:j,poll:R,pollingInterval:M=e.pollingInterval,strict:F}){let q,H;let z=void 0!==R?R:"webSocket"!==e.transport.type;return z?(()=>{let c=(0,s.stringify)(["watchContractEvent",n,x,P,e.uid,_,M]),u=F??!1;return(0,o.observe)(c,{onLogs:j,onError:I},o=>{let s,c;let d=!1,p=(0,i.poll)(async()=>{if(!d){try{c=await (0,m.getAction)(e,b.createContractEventFilter,"createContractEventFilter")({abi:t,address:n,args:x,eventName:_,strict:u})}catch{}d=!0;return}try{let i;if(c)i=await (0,m.getAction)(e,v.getFilterChanges,"getFilterChanges")({filter:c});else{let o=await (0,m.getAction)(e,g.getBlockNumber,"getBlockNumber")({});i=s&&s!==o?await (0,m.getAction)(e,y.getContractEvents,"getContractEvents")({abi:t,address:n,args:x,eventName:_,fromBlock:s+1n,toBlock:o,strict:u}):[],s=o}if(0===i.length)return;if(P)o.onLogs(i);else for(let e of i)o.onLogs([e])}catch(e){c&&e instanceof l.InvalidInputRpcError&&(d=!1),o.onError?.(e)}},{emitOnBegin:!0,interval:M});return async()=>{c&&await (0,m.getAction)(e,E.uninstallFilter,"uninstallFilter")({filter:c}),p()}})})():(q=!0,H=()=>q=!1,(async()=>{try{let o=_?(0,d.encodeEventTopics)({abi:t,eventName:_,args:x}):[],{unsubscribe:i}=await e.transport.subscribe({params:["logs",{address:n,topics:o}],onData(e){if(!q)return;let n=e.result;try{let{eventName:e,args:o}=(0,u.decodeEventLog)({abi:t,data:n.data,topics:n.topics,strict:F}),i=(0,p.formatLog)(n,{args:o,eventName:e});j([i])}catch(i){let e,t;if(i instanceof c.DecodeLogDataMismatch||i instanceof c.DecodeLogTopicsMismatch){if
46(F)return;e=i.abiItem.name,t=i.abiItem.inputs?.some(e=>!("name"in e&&e.name))}let o=(0,p.formatLog)(n,{args:t?[]:{},eventName:e});j([o])}},onError(e){I?.(e)}});H=i,q||H()}catch(e){I?.(e)}})(),H)}},92080:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.watchEvent=void 0;let o=n(27057),i=n(32815),s=n(36774),c=n(82521),l=n(28516),u=n(45828),d=n(51999),p=n(38412),m=n(99615),b=n(55371),g=n(72362),y=n(35220);t.watchEvent=function(e,{address:t,args:n,batch:v=!0,event:E,events:x,onError:P,onLogs:_,poll:I,pollingInterval:j=e.pollingInterval,strict:R}){let M,F;let q=void 0!==I?I:"webSocket"!==e.transport.type,H=R??!1;return q?(()=>{let c=(0,s.stringify)(["watchEvent",t,n,v,e.uid,E,j]);return(0,o.observe)(c,{onLogs:_,onError:P},o=>{let s,c;let d=!1,P=(0,i.poll)(async()=>{if(!d){try{c=await (0,u.getAction)(e,p.createEventFilter,"createEventFilter")({address:t,args:n,event:E,events:x,strict:H})}catch{}d=!0;return}try{let i;if(c)i=await (0,u.getAction)(e,b.getFilterChanges,"getFilterChanges")({filter:c});else{let o=await (0,u.getAction)(e,m.getBlockNumber,"getBlockNumber")({});i=s&&s!==o?await (0,u.getAction)(e,g.getLogs,"getLogs")({address:t,args:n,event:E,events:x,fromBlock:s+1n,toBlock:o}):[],s=o}if(0===i.length)return;if(v)o.onLogs(i);else for(let e of i)o.onLogs([e])}catch(e){c&&e instanceof l.InvalidInputRpcError&&(d=!1),o.onError?.(e)}},{emitOnBegin:!0,interval:j});return async()=>{c&&await (0,u.getAction)(e,y.uninstallFilter,"uninstallFilter")({filter:c}),P()}})})():(M=!0,F=()=>M=!1,(async()=>{try{let o=x??(E?[E]:void 0),i=[];o&&(i=[o.flatMap(e=>(0,d.encodeEventTopics)({abi:[e],eventName:e.name,args:n}))],E&&(i=i[0]));let{unsubscribe:s}=await e.transport.subscribe({params:["logs",{address:t,topics:i}],onData(e){if(!M)return;let t=e.result;try{let{eventName:e,args:n}=(0,d.decodeEventLog)({abi:o,data:t.data,topics:t.topics,strict:H}),i=(0,d.formatLog)(t,{args:n,eventName:e});_([i])}catch(i){let e,n;if(i instanceof c.DecodeLogDataMismatch||i instanceof c.DecodeLogTopicsMismatch){if(R)return;e=i.abiItem.name,n=i.abiItem.inputs?.some(e=>!("name"in e&&e.name))}let o=(0,d.formatLog)(t,{args:n?[]:{},eventName:e});_([o])}},onError(e){P?.(e)}});F=s,M||F()}catch(e){P?.(e)}})(),F)}},51529:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.watchPendingTransactions=void 0;let o=n(45828),i=n(27057),s=n(32815),c=n(36774),l=n(83323),u=n(55371),d=n(35220);t.watchPendingTransactions=function(e,{batch:t=!0,onError:n,onTransactions:p,poll:m,pollingInterval:b=e.pollingInterval}){let g,y;let v=void 0!==m?m:"webSocket"!==e.transport.type;return v?(()=>{let m=(0,c.stringify)(["watchPendingTransactions",e.uid,t,b]);return(0,i.observe)(m,{onTransactions:p,onError:n},n=>{let i;let c=(0,s.poll)(async()=>{try{if(!i)try{i=await (0,o.getAction)(e,l.createPendingTransactionFilter,"createPendingTransactionFilter")({});return}catch(e){throw c(),e}let s=await (0,o.getAction)(e,u.getFilterChanges,"getFilterChanges")({filter:i});if(0===s.length)return;if(t)n.onTransactions(s);else for(let e of s)n.onTransactions([e])}catch(e){n.onError?.(e)}},{emitOnBegin:!0,interval:b});return async()=>{i&&await (0,o.getAction)(e,d.uninstallFilter,"uninstallFilter")({filter:i}),c()}})})():(g=!0,y=()=>g=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newPendingTransactions"],onData(e){if(!g)return;let t=e.result;p([t])},onError(e){n?.(e)}});y=t,g||y()}catch(e){n?.(e)}})(),y)}},33622:function(e,t){"use strict";async function dropTransaction(e,{hash:t}){await e.request({method:`${e.mode}_dropTransaction`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.dropTransaction=void 0,t.dropTransaction=dropTransaction},5014:function(e,t){"use strict";async function dumpState(e){return e.request({method:`${e.mode}_dumpState`})}Object.defineProperty(t,"__esModule",{value:!0}),t.dumpState=void 0,t.dumpState=dumpState},74660:function(e,t){"use strict";async function getAutomine(e){return"ganache"===e.mode?await e.request({method:"eth_mining"}):await e.request({method:`${e.mode}_getAutomine`})}
46Object.defineProperty(t,"__esModule",{value:!0}),t.getAutomine=void 0,t.getAutomine=getAutomine},61110:function(e,t){"use strict";async function getTxpoolContent(e){return await e.request({method:"txpool_content"})}Object.defineProperty(t,"__esModule",{value:!0}),t.getTxpoolContent=void 0,t.getTxpoolContent=getTxpoolContent},29653:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTxpoolStatus=void 0;let o=n(84008);async function getTxpoolStatus(e){let{pending:t,queued:n}=await e.request({method:"txpool_status"});return{pending:(0,o.hexToNumber)(t),queued:(0,o.hexToNumber)(n)}}t.getTxpoolStatus=getTxpoolStatus},9287:function(e,t){"use strict";async function impersonateAccount(e,{address:t}){await e.request({method:`${e.mode}_impersonateAccount`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.impersonateAccount=void 0,t.impersonateAccount=impersonateAccount},44050:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.increaseTime=void 0;let o=n(56945);async function increaseTime(e,{seconds:t}){return await e.request({method:"evm_increaseTime",params:[(0,o.numberToHex)(t)]})}t.increaseTime=increaseTime},48753:function(e,t){"use strict";async function inspectTxpool(e){return await e.request({method:"txpool_inspect"})}Object.defineProperty(t,"__esModule",{value:!0}),t.inspectTxpool=void 0,t.inspectTxpool=inspectTxpool},65193:function(e,t){"use strict";async function loadState(e,{state:t}){await e.request({method:`${e.mode}_loadState`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.loadState=void 0,t.loadState=loadState},13619:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mine=void 0;let o=n(56945);async function mine(e,{blocks:t,interval:n}){"ganache"===e.mode?await e.request({method:"evm_mine",params:[{blocks:(0,o.numberToHex)(t)}]}):await e.request({method:`${e.mode}_mine`,params:[(0,o.numberToHex)(t),(0,o.numberToHex)(n||0)]})}t.mine=mine},41597:function(e,t){"use strict";async function removeBlockTimestampInterval(e){await e.request({method:`${e.mode}_removeBlockTimestampInterval`})}Object.defineProperty(t,"__esModule",{value:!0}),t.removeBlockTimestampInterval=void 0,t.removeBlockTimestampInterval=removeBlockTimestampInterval},25544:function(e,t){"use strict";async function reset(e,{blockNumber:t,jsonRpcUrl:n}={}){await e.request({method:`${e.mode}_reset`,params:[{forking:{blockNumber:Number(t),jsonRpcUrl:n}}]})}Object.defineProperty(t,"__esModule",{value:!0}),t.reset=void 0,t.reset=reset},5264:function(e,t){"use strict";async function revert(e,{id:t}){await e.request({method:"evm_revert",params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.revert=void 0,t.revert=revert},26703:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sendUnsignedTransaction=void 0;let o=n(56725),i=n(77300);async function sendUnsignedTransaction(e,t){let{accessList:n,data:s,from:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:b,value:g,...y}=t,v=e.chain?.formatters?.transactionRequest?.format,E=v||i.formatTransactionRequest,x=E({...(0,o.extract)(y,{format:v}),accessList:n,data:s,from:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:b,value:g}),P=await e.request({method:"eth_sendUnsignedTransaction",params:[x]});return P}t.sendUnsignedTransaction=sendUnsignedTransaction},67423:function(e,t){"use strict";async function setAutomine(e,t){"ganache"===e.mode?t?await e.request({method:"miner_start"}):await e.request({method:"miner_stop"}):await e.request({method:"evm_setAutomine",params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setAutomine=void 0,t.setAutomine=setAutomine},10047:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setBalance=void 0;let o=n(56945);async function setBalance(e,{address:t,value:n}){"ganache"===e.mode?await e.request({method:"evm_setAccountBalance",params:[t,(0,o.numberToHex)(n)]}):await e.request({method:`${e.mode}_setBalance`,params:[t,(0,o.numberToHex)(n)]})}t.setBalance=setBalance},50909:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.setBlockGasLimit=void 0;let o=n(56945);async function setBlockGasLimit(e,{gasLimit:t}){await e.request({method:"evm_setBlockGasLimit",params:[(0,o.numberToHex)(t)]})}t.setBlockGasLimit=setBlockGasLimit},4699:function(e,t){"use strict";async function setBlockTimestampInterval(e,{interval:t}){let n="hardhat"===e.mode?1e3*t:t;await e.request({method:`${e.mode}_setBlockTimestampInterval`,params:[n]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setBlockTimestampInterval=void 0,t.setBlockTimestampInterval=setBlockTimestampInterval},24116:function(e,t){"use strict";async function setCode(e,{address:t,bytecode:n}){await e.request({method:`${e.mode}_setCode`,params:[t,n]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setCode=void 0,t.setCode=setCode},7122:function(e,t){"use strict";async function setCoinbase(e,{address:t}){await e.request({method:`${e.mode}_setCoinbase`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setCoinbase=void 0,t.setCoinbase=setCoinbase},37258:function(e,t){"use strict";async function setIntervalMining(e,{interval:t}){let n="hardhat"===e.mode?1e3*t:t;await e.request({method:"evm_setIntervalMining",params:[n]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setIntervalMining=void 0,t.setIntervalMining=setIntervalMining},8771:function(e,t){"use strict";async function setLoggingEnabled(e,t){await e.request({method:`${e.mode}_setLoggingEnabled`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setLoggingEnabled=void 0,t.setLoggingEnabled=setLoggingEnabled},65010:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setMinGasPrice=void 0;let o=n(56945);async function setMinGasPrice(e,{gasPrice:t}){await e.request({method:`${e.mode}_setMinGasPrice`,params:[(0,o.numberToHex)(t)]})}t.setMinGasPrice=setMinGasPrice},12100:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setNextBlockBaseFeePerGas=void 0;let o=n(56945);async function setNextBlockBaseFeePerGas(e,{baseFeePerGas:t}){await e.request({method:`${e.mode}_setNextBlockBaseFeePerGas`,params:[(0,o.numberToHex)(t)]})}t.setNextBlockBaseFeePerGas=setNextBlockBaseFeePerGas},85265:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setNextBlockTimestamp=void 0;let o=n(56945);async function setNextBlockTimestamp(e,{timestamp:t}){await e.request({method:"evm_setNextBlockTimestamp",params:[(0,o.numberToHex)(t)]})}t.setNextBlockTimestamp=setNextBlockTimestamp},30996:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setNonce=void 0;let o=n(56945);async function setNonce(e,{address:t,nonce:n}){await e.request({method:`${e.mode}_setNonce`,params:[t,(0,o.numberToHex)(n)]})}t.setNonce=setNonce},30284:function(e,t){"use strict";async function setRpcUrl(e,t){await e.request({method:`${e.mode}_setRpcUrl`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.setRpcUrl=void 0,t.setRpcUrl=setRpcUrl},9929:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setStorageAt=void 0;let o=n(56945);async function setStorageAt(e,{address:t,index:n,value:i}){await e.request({method:`${e.mode}_setStorageAt`,params:[t,"number"==typeof n?(0,o.numberToHex)(n):n,i]})}t.setStorageAt=setStorageAt},74527:function(e,t){"use strict";async function snapshot(e){return await e.request({method:"evm_snapshot"})}Object.defineProperty(t,"__esModule",{value:!0}),t.snapshot=void 0,t.snapshot=snapshot},64225:function(e,t){"use strict";async function stopImpersonatingAccount(e,{address:t}){await e.request({method:`${e.mode}_stopImpersonatingAccount`,params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.stopImpersonatingAccount=void 0,t.stopImpersonatingAccount=stopImpersonatingAccount},51764:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addChain=void 0;let o=n(56945);async function addChain(e,{chain:t}){let{id:n,name:i,nativeCurrency:s,rpcUrls:c,blockExplorers:l}=t;await e.request({method:"wallet_addEthereumChain",params:[{chainId:(0,o.numberToHex)(n),chainName:i,nativeCurrency:s,rpcUrls:c.default.http,blockExplorerUrls:l?Object.values(l).map(({url:e})=>e):void 0}]})}t.addChain=addChain},71016:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.deployContract=void 0;let o=n(94335),i=n(96347);t.deployContract=function(e,{abi:t,args:n,bytecode:s,...c}){let l=(0,o.encodeDeployData)({abi:t,args:n,bytecode:s});return(0,i.sendTransaction)(e,{...c,data:l})}},67314:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAddresses=void 0;let o=n(66830);async function getAddresses(e){if(e.account?.type==="local")return[e.account.address];let t=await e.request({method:"eth_accounts"});return t.map(e=>(0,o.checksumAddress)(e))}t.getAddresses=getAddresses},18390:function(e,t){"use strict";async function getPermissions(e){let t=await e.request({method:"wallet_getPermissions"});return t}Object.defineProperty(t,"__esModule",{value:!0}),t.getPermissions=void 0,t.getPermissions=getPermissions},68094:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.prepareTransactionRequest=void 0;let o=n(27558),i=n(98346),s=n(89335),c=n(67728),l=n(72888),u=n(21506),d=n(30375),p=n(45828),m=n(80525),b=n(71040);async function prepareTransactionRequest(e,t){let{account:n=e.account,chain:g,gas:y,nonce:v,type:E}=t;if(!n)throw new u.AccountNotFoundError;let x=(0,o.parseAccount)(n),P=await (0,p.getAction)(e,c.getBlock,"getBlock")({blockTag:"latest"}),_={...t,from:x.address};if(void 0===v&&(_.nonce=await (0,p.getAction)(e,l.getTransactionCount,"getTransactionCount")({address:x.address,blockTag:"pending"})),void 0===E)try{_.type=(0,b.getTransactionType)(_)}catch{_.type="bigint"==typeof P.baseFeePerGas?"eip1559":"legacy"}if("eip1559"===_.type){let{maxFeePerGas:n,maxPriorityFeePerGas:o}=await (0,i.internal_estimateFeesPerGas)(e,{block:P,chain:g,request:_});if(void 0===t.maxPriorityFeePerGas&&t.maxFeePerGas&&t.maxFeePerGas<o)throw new d.MaxFeePerGasTooLowError({maxPriorityFeePerGas:o});_.maxPriorityFeePerGas=o,_.maxFeePerGas=n}else{if(void 0!==t.maxFeePerGas||void 0!==t.maxPriorityFeePerGas)throw new d.Eip1559FeesNotSupportedError;let{gasPrice:n}=await (0,i.internal_estimateFeesPerGas)(e,{block:P,chain:g,request:_,type:"legacy"});_.gasPrice=n}return void 0===y&&(_.gas=await (0,p.getAction)(e,s.estimateGas,"estimateGas")({..._,account:{address:x.address,type:"json-rpc"}})),(0,m.assertRequest)(_),_}t.prepareTransactionRequest=prepareTransactionRequest},58019:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.requestAddresses=void 0;let o=n(66830);async function requestAddresses(e){let t=await e.request({method:"eth_requestAccounts"});return t.map(e=>(0,o.getAddress)(e))}t.requestAddresses=requestAddresses},70330:function(e,t){"use strict";async function requestPermissions(e,t){return e.request({method:"wallet_requestPermissions",params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.requestPermissions=void 0,t.requestPermissions=requestPermissions},90275:function(e,t){"use strict";async function sendRawTransaction(e,{serializedTransaction:t}){return e.request({method:"eth_sendRawTransaction",params:[t]})}Object.defineProperty(t,"__esModule",{value:!0}),t.sendRawTransaction=void 0,t.sendRawTransaction=sendRawTransaction},96347:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sendTransaction=void 0;let o=n(27558),i=n(21506),s=n(54037),c=n(53268),l=n(56725),u=n(77300),d=n(45828),p=n(80525),m=n(16849),b=n(68094),g=n(90275);async function sendTransaction(e,t){let{account:n=e.account,chain:y=e.chain,accessList:v,data:E,gas:x,gasPrice:P,maxFeePerGas:_,maxPriorityFeePerGas:I,nonce:j,to:R,value:M,...F}=t;if(!n)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/sendTransaction"});let q=(0,o.parseAccount)(n);try{let n;if((0,p.assertRequest)(t),null!==y&&(n=await (0,d.getAction)(e,m.getChainId,"getChainId")({}),(0,s.assertCurrentChain)({currentChainId:n,chain:y})),"local"===q.type){let t=await (0,d.getAction)(e,b.prepareTransactionRequest,"prepareTransactionRequest")({account:q,accessList:v,chain:y,data:E,gas:x,gasPrice:P,maxFeePerGas:_,maxPriorityFeePerGas:I,nonce:j,to:R,value:M,...F});n||(n=await (0,d.getAction)(e,m.getChainId,"getChainId")({}));let o=y?.serializers?.transaction,i=await q.signTransaction({...t,chainId:n},{serializer:o});return await (0,d.getAction)(e,g.sendRawTransaction,"sendRawTransaction")({serializedTransaction:i})}let o=e.chain?.formatters?.transactionRequest?.format,i=o||u.formatTransactionRequest,c=i({...(0,l.extract)(F,{format:o}),accessList:v,data:E,from:q.address,gas:x,gasPrice:P,maxFeePerGas:_,maxPriorityFeePerGas:I,nonce:j,to:R,value:M});return await e.request({method:"eth_sendTransaction",params:[c]})}catch(e){throw(0,c.getTransactionError)(e,{...t,account:q,chain:t.chain||void 0})}}t.sendTransaction=sendTransaction},83445:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.signMessage=void 0;let o=n(27558),i=n(21506),s=n(56945);async function signMessage(e,{account:t=e.account,message:n}){if(!t)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signMessage"});let c=(0,o.parseAccount)(t);if("local"===c.type)return c.signMessage({message:n});let l="string"==typeof n?(0,s.stringToHex)(n):n.raw instanceof Uint8Array?(0,s.toHex)(n.raw):n.raw;return e.request({method:"personal_sign",params:[l,c.address]})}t.signMessage=signMessage},18907:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.signTransaction=void 0;let o=n(27558),i=n(21506),s=n(54037),c=n(77300),l=n(45828),u=n(51999),d=n(80525),p=n(16849);async function signTransaction(e,t){let{account:n=e.account,chain:m=e.chain,...b}=t;if(!n)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signTransaction"});let g=(0,o.parseAccount)(n);(0,d.assertRequest)({account:g,...t});let y=await (0,l.getAction)(e,p.getChainId,"getChainId")({});null!==m&&(0,s.assertCurrentChain)({currentChainId:y,chain:m});let v=m?.formatters||e.chain?.formatters,E=v?.transactionRequest?.format||c.formatTransactionRequest;return"local"===g.type?g.signTransaction({...b,chainId:y},{serializer:e.chain?.serializers?.transaction}):await e.request({method:"eth_signTransaction",params:[{...E(b),chainId:(0,u.numberToHex)(y),from:g.address}]})}t.signTransaction=signTransaction},58446:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.signTypedData=void 0;let o=n(27558),i=n(21506),s=n(29281),c=n(36774),l=n(86931);async function signTypedData(e,{account:t=e.account,domain:n,message:u,primaryType:d,types:p}){if(!t)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signTypedData"});let m=(0,o.parseAccount)(t),b={EIP712Domain:(0,l.getTypesForEIP712Domain)({domain:n}),...p};if((0,l.validateTypedData)({domain:n,message:u,primaryType:d,types:b}),"local"===m.type)return m.signTypedData({domain:n,primaryType:d,types:b,message:u});let g=(0,c.stringify)({domain:n??{},primaryType:d,types:b,message:u},(e,t)=>(0,s.isHex)(t)?t.toLowerCase():t);return e.request({method:"eth_signTypedData_v4",params:[m.address,g]})}t.signTypedData=signTypedData},4262:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.switchChain=void 0;let o=n(56945);async function switchChain(e,{id:t}){await e.request({method:"wallet_switchEthereumChain",params:[{chainId:(0,o.numberToHex)(t)}]})}t.switchChain=switchChain},7514:function(e,t){"use strict";async function watchAsset(e,t){let n=await e.request({method:"wallet_watchAsset",params:t});return n}Object.defineProperty(t,"__esModule",{value:!0}),t.watchAsset=void 0,t.watchAsset=watchAsset},60722:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.writeContract=void 0;let o=n(48635),i=n(45828),s=n(96347);async function writeContract(e,{abi:t,address:n,args:c,dataSuffix:l,functionName:u,...d}){let p=(0,o.encodeFunctionData)({abi:t,args:c,functionName:u}),m=await (0,i.getAction)(e,s.sendTransaction,"sendTransaction")({data:`${p}${l?l.replace("0x",""):""}`,to:n,...d});return m}t.writeContract=writeContract},39189:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createClient=void 0;let o=n(13385),i=n(66615);t.createClient=function(e){let{batch:t,cacheTime:n=e.pollingInterval??4e3,key:s="base",name:c="Base Client",pollingInterval:l=4e3,type:u="base"}=e,d=e.chain,p=e.account?(0,o.parseAccount)(e.account):void 0,{config:m,request:b,value:g}=e.transport({chain:d,pollingInterval:l}),y={...m,...g},v={account:p,batch:t,cacheTime:n,chain:d,key:s,name:c,pollingInterval:l,request:b,transport:y,type:u,uid:(0,i.uid)()};return Object.assign(v,{extend:function extend(e){return t=>{let n=t(e);for(let e in v)delete n[e];let o={...e,...n};return Object.assign(o,{extend:extend(o)})}}(v)})}},13527:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createPublicClient=void 0;let o=n(39189),i=n(28454);t.createPublicClient=function(e){let{key:t="public",name:n="Public Client"}=e,s=(0,o.createClient)({...e,key:t,name:n,type:"publicClient"});return s.extend(i.publicActions)}},65829:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.createTestClient=void 0;let o=n(39189),i=n(41391);t.createTestClient=function(e){let{key:t="test",name:n="Test Client",mode:s}=e,c=(0,o.createClient)({...e,key:t,name:n,type:"testClient"});return c.extend(e=>({mode:s,...(0,i.testActions)({mode:s})(e)}))}},68982:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createWalletClient=void 0;let o=n(39189),i=n(92693);t.createWalletClient=function(e){let{key:t="wallet",name:n="Wallet Client",transport:s}=e,c=(0,o.createClient)({...e,key:t,name:n,transport:e=>s({...e,retryCount:0}),type:"walletClient"});return c.extend(i.walletActions)}},28454:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.publicActions=void 0;let o=n(50151),i=n(19715),s=n(87935),c=n(66738),l=n(78376),u=n(52234),d=n(89973),p=n(1001),m=n(38412),b=n(83323),g=n(15965),y=n(98346),v=n(89335),E=n(63433),x=n(62932),P=n(67728),_=n(99615),I=n(73156),j=n(16408),R=n(16849),M=n(58958),F=n(49161),q=n(55371),H=n(58431),z=n(1896),W=n(72362),K=n(37561),Q=n(4782),Z=n(92357),X=n(74271),Y=n(72888),J=n(72471),et=n(27779),eo=n(2333),ea=n(22140),ei=n(35220),es=n(95832),ec=n(3213),el=n(93492),eu=n(97866),ed=n(76168),ef=n(42573),ep=n(92080),eh=n(51529),em=n(68094),eb=n(90275);t.publicActions=function(e){return{call:t=>(0,u.call)(e,t),createBlockFilter:()=>(0,d.createBlockFilter)(e),createContractEventFilter:t=>(0,p.createContractEventFilter)(e,t),createEventFilter:t=>(0,m.createEventFilter)(e,t),createPendingTransactionFilter:()=>(0,b.createPendingTransactionFilter)(e),estimateContractGas:t=>(0,g.estimateContractGas)(e,t),estimateGas:t=>(0,v.estimateGas)(e,t),getBalance:t=>(0,x.getBalance)(e,t),getBlock:t=>(0,P.getBlock)(e,t),getBlockNumber:t=>(0,_.getBlockNumber)(e,t),getBlockTransactionCount:t=>(0,I.getBlockTransactionCount)(e,t),getBytecode:t=>(0,j.getBytecode)(e,t),getChainId:()=>(0,R.getChainId)(e),getContractEvents:t=>(0,M.getContractEvents)(e,t),getEnsAddress:t=>(0,o.getEnsAddress)(e,t),getEnsAvatar:t=>(0,i.getEnsAvatar)(e,t),getEnsName:t=>(0,s.getEnsName)(e,t),getEnsResolver:t=>(0,c.getEnsResolver)(e,t),getEnsText:t=>(0,l.getEnsText)(e,t),getFeeHistory:t=>(0,F.getFeeHistory)(e,t),estimateFeesPerGas:t=>(0,y.estimateFeesPerGas)(e,t),getFilterChanges:t=>(0,q.getFilterChanges)(e,t),getFilterLogs:t=>(0,H.getFilterLogs)(e,t),getGasPrice:()=>(0,z.getGasPrice)(e),getLogs:t=>(0,W.getLogs)(e,t),getProof:t=>(0,K.getProof)(e,t),estimateMaxPriorityFeePerGas:t=>(0,E.estimateMaxPriorityFeePerGas)(e,t),getStorageAt:t=>(0,Q.getStorageAt)(e,t),getTransaction:t=>(0,Z.getTransaction)(e,t),getTransactionConfirmations:t=>(0,X.getTransactionConfirmations)(e,t),getTransactionCount:t=>(0,Y.getTransactionCount)(e,t),getTransactionReceipt:t=>(0,J.getTransactionReceipt)(e,t),multicall:t=>(0,et.multicall)(e,t),prepareTransactionRequest:t=>(0,em.prepareTransactionRequest)(e,t),readContract:t=>(0,eo.readContract)(e,t),sendRawTransaction:t=>(0,eb.sendRawTransaction)(e,t),simulateContract:t=>(0,ea.simulateContract)(e,t),verifyMessage:t=>(0,es.verifyMessage)(e,t),verifyTypedData:t=>(0,ec.verifyTypedData)(e,t),uninstallFilter:t=>(0,ei.uninstallFilter)(e,t),waitForTransactionReceipt:t=>(0,el.waitForTransactionReceipt)(e,t),watchBlocks:t=>(0,ed.watchBlocks)(e,t),watchBlockNumber:t=>(0,eu.watchBlockNumber)(e,t),watchContractEvent:t=>(0,ef.watchContractEvent)(e,t),watchEvent:t=>(0,ep.watchEvent)(e,t),watchPendingTransactions:t=>(0,eh.watchPendingTransactions)(e,t)}}},41391:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.testActions=void 0;let o=n(33622),i=n(5014),s=n(74660),c=n(61110),l=n(29653),u=n(9287),d=n(44050),p=n(48753),m=n(65193),b=n(13619),g=n(41597),y=n(25544),v=n(5264),E=n(26703),x=n(67423),P=n(10047),_=n(50909),I=n(4699),j=n(24116),R=n(7122),M=n(37258),F=n(8771),q=n(65010),H=n(12100),z=n(85265),W=n(30996),K=n(30284),Q=n(9929),Z=n(74527),X=n(64225);t.testActions=function({mode:e}){return t=>{let n=t.extend(()=>({mode:e}));return{dropTransaction:e=>(0,o.dropTransaction)(n,e),dumpState:()=>(0,i.dumpState)(n),getAutomine:()=>(0,s.getAutomine)(n),getTxpoolContent:()=>(0,c.getTxpoolContent)(n),getTxpoolStatus:()=>(0,l.getTxpoolStatus)(n),impersonateAccount:e=>(0,u.impersonateAccount)(n,e),increaseTime:e=>(0,d.increaseTime)(n,e),inspectTxpool:()=>(0,p.inspectTxpool)(n),loadState:e=>(0,m.loadState)(n,e),mine:e=>(0,b.mine)(n,e),removeBlockTimestampInterval:()=>(0,g.removeBlockTimestampInterval)(n),reset:e=>(0,y.reset)(n,e),revert:e=>(0,v.revert)(n,e),sendUnsignedTransaction:e=>(0,E.sendUnsignedTransaction)(n,e),setAutomine:e=>(0,x.setAutomine)(n,e),setBalance:e=>(0,P.setBalance)(n,e),setBlockGasLimit:e=>(0,_.setBlockGasLimit)(n,e),setBlockTimestampInterval:e=>(0,I.setBlockTimestampInterval)(n,e),setCode:e=>(0,j.setCode)(n,e),setCoinbase:e=>(0,R.setCoinbase)(n,e),setIntervalMining:e=>(0,M.setIntervalMining)(n,e),setLoggingEnabled:e=>(0,F.setLoggingEnabled)(n,e),setMinGasPrice:e=>(0,q.setMinGasPrice)(n,e),setNextBlockBaseFeePerGas:e=>(0,H.setNextBlockBaseFeePerGas)(n,e),setNextBlockTimestamp:e=>(0,z.setNextBlockTimestamp)(n,e),setNonce:e=>(0,W.setNonce)(n,e),setRpcUrl:e=>(0,K.setRpcUrl)(n,e),setStorageAt:e=>(0,Q.setStorageAt)(n,e),snapshot:()=>(0,Z.snapshot)(n),stopImpersonatingAccount:e=>(0,X.stopImpersonatingAccount)(n,e)}}}},92693:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.walletActions=void 0;let o=n(16849),i=n(51764),s=n(71016),c=n(67314),l=n(18390),u=n(68094),d=n(58019),p=n(70330),m=n(90275),b=n(96347),g=n(83445),y=n(18907),v=n(58446),E=n(4262),x=n(7514),P=n(60722);t.walletActions=function(e){return{addChain:t=>(0,i.addChain)(e,t),deployContract:t=>(0,s.deployContract)(e,t),getAddresses:()=>(0,c.getAddresses)(e),getChainId:()=>(0,o.getChainId)(e),getPermissions:()=>(0,l.getPermissions)(e),prepareTransactionRequest:t=>(0,u.prepareTransactionRequest)(e,t),requestAddresses:()=>(0,d.requestAddresses)(e),requestPermissions:t=>(0,p.requestPermissions)(e,t),sendRawTransaction:t=>(0,m.sendRawTransaction)(e,t),sendTransaction:t=>(0,b.sendTransaction)(e,t),signMessage:t=>(0,g.signMessage)(e,t),signTransaction:t=>(0,y.signTransaction)(e,t),signTypedData:t=>(0,v.signTypedData)(e,t),switchChain:t=>(0,E.switchChain)(e,t),watchAsset:t=>(0,x.watchAsset)(e,t),writeContract:t=>(0,P.writeContract)(e,t)}}},20025:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createTransport=void 0;let o=n(24859);t.createTransport=function({key:e,name:t,request:n,retryCount:i=3,retryDelay:s=150,timeout:c,type:l},u){return{config:{key:e,name:t,request:n,retryCount:i,retryDelay:s,timeout:c,type:l},request:(0,o.buildRequest)(n,{retryCount:i,retryDelay:s}),value:u}}},59341:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.custom=void 0;let o=n(20025);t.custom=function(e,t={}){let{key:n="custom",name:i="Custom Provider",retryDelay:s}=t;return({retryCount:c})=>(0,o.createTransport)({key:n,name:i,request:e.request.bind(e),retryCount:t.retryCount??c,retryDelay:s,type:"custom"})}},54229:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.rankTransports=t.fallback=void 0;let o=n(24859),i=n(86390),s=n(20025);function rankTransports({chain:e,interval:t=4e3,onTransports:n,sampleCount:o=10,timeout:s=1e3,transports:c,weights:l={}}){let{stability:u=.7,latency:d=.3}=l,p=[],rankTransports_=async()=>{let l=await Promise.all(c.map(async t=>{let n,o;let i=t({chain:e,retryCount:0,timeout:s}),c=Date.now();try{await i.request({method:"net_listening"}),o=1}catch{o=0}finally{n=Date.now()}let l=n-c;return{latency:l,success:o}}));p.push(l),p.length>o&&p.shift();let m=Math.max(...p.map(e=>Math.max(...e.map(({latency:e})=>e)))),b=c.map((e,t)=>{let n=p.map(e=>e[t].latency),o=n.reduce((e,t)=>e+t,0)/n.length,i=p.map(e=>e[t].success),s=i.reduce((e,t)=>e+t,0)/i.length;return 0===s?[0,t]:[d*(1-o/m)+u*s,t]}).sort((e,t)=>t[0]-e[0]);n(b.map(([,e])=>c[e])),await (0,i.wait)(t),rankTransports_()};rankTransports_()}t.fallback=function(e,t={}){let{key:n="fallback",name:i="Fallback",rank:c=!1,retryCount:l,retryDelay:u}=t;return({chain:t,pollingInterval:d=4e3,timeout:p})=>{let m=e,onResponse=()=>{},b=(0,s.createTransport)({key:n,name:i,async request({method:e,params:n}){let fetch=async(i=0)=>{let s=m[i]({chain:t,retryCount:0,timeout:p});try{let t=await s.request({method:e,params:n});return onResponse({method:e,params:n,response:t,transport:s,status:"success"}),t}catch(t){if(onResponse({error:t,method:e,params:n,transport:s,status:"error"}),(0,o.isDeterministicError)(t)||i===m.length-1)throw t;return fetch(i+1)}};return fetch()},retryCount:l,retryDelay:u,type:"fallback"},{onResponse:e=>onResponse=e,transports:m.map(e=>e({chain:t,retryCount:0}))});if(c){let e="object"==typeof c?c:{};rankTransports({chain:t,interval:e.interval??d,onTransports:e=>m=e,sampleCount:e.sampleCount,timeout:e.timeout,transports:m,weights:e.weights})}return b}},t.rankTransports=rankTransports},37517:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.http=void 0;let o=n(86617),i=n(86550),s=n(32875),c=n(66934),l=n(20025);t.http=function(e,t={}){let{batch:n,fetchOptions:u,key:d="http",name:p="HTTP JSON-RPC",retryDelay:m}=t;return({chain:b,retryCount:g,timeout:y})=>{let{batchSize:v=1e3,wait:E=0}="object"==typeof n?n:{},x=t.retryCount??g,P=y??t.timeout??1e4,_=e||b?.rpcUrls.default.http[0];if(!_)throw new i.UrlRequiredError;return(0,l.createTransport)({key:d,name:p,async request({method:t,params:i}){let l={method:t,params:i},{schedule:d}=(0,s.createBatchScheduler)({id:`${e}`,wait:E,shouldSplitBatch:e=>e.length>v,fn:e=>c.rpc.http(_,{body:e,fetchOptions:u,timeout:P}),sort:(e,t)=>e.id-t.id}),fn=async e=>n?d(e):[await c.rpc.http(_,{body:e,fetchOptions:u,timeout:P})],[{error:p,result:m}]=await fn(l);if(p)throw new o.RpcRequestError({body:l,error:p,url:_});return m},retryCount:x,retryDelay:m,timeout:P,type:"http"},{fetchOptions:u,url:e})}}},51562:function(e,t,n){"use strict";
46Object.defineProperty(t,"__esModule",{value:!0}),t.webSocket=void 0;let o=n(86617),i=n(86550),s=n(66934),c=n(20025);t.webSocket=function(e,t={}){let{key:n="webSocket",name:l="WebSocket JSON-RPC",retryDelay:u}=t;return({chain:d,retryCount:p,timeout:m})=>{let b=t.retryCount??p,g=m??t.timeout??1e4,y=e||d?.rpcUrls.default.webSocket?.[0];if(!y)throw new i.UrlRequiredError;return(0,c.createTransport)({key:n,name:l,async request({method:e,params:t}){let n={method:e,params:t},i=await (0,s.getSocket)(y),{error:c,result:l}=await s.rpc.webSocketAsync(i,{body:n,timeout:g});if(c)throw new o.RpcRequestError({body:n,error:c,url:y});return l},retryCount:b,retryDelay:u,timeout:g,type:"webSocket"},{getSocket:()=>(0,s.getSocket)(y),async subscribe({params:e,onData:t,onError:n}){let o=await (0,s.getSocket)(y),{result:i}=await new Promise((i,c)=>s.rpc.webSocket(o,{body:{method:"eth_subscribe",params:e},onResponse(e){if(e.error){c(e.error),n?.(e.error);return}if("number"==typeof e.id){i(e);return}"eth_subscription"===e.method&&t(e.params)}}));return{subscriptionId:i,unsubscribe:async()=>new Promise(e=>s.rpc.webSocket(o,{body:{method:"eth_unsubscribe",params:[i]},onResponse:e}))}}})}}},55906:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.universalSignatureValidatorAbi=t.smartAccountAbi=t.addressResolverAbi=t.textResolverAbi=t.universalResolverReverseAbi=t.universalResolverResolveAbi=t.multicall3Abi=void 0,t.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"}];let n=[{inputs:[],name:"ResolverNotFound",type:"error"},{inputs:[],name:"ResolverWildcardNotSupported",type:"error"}];t.universalResolverResolveAbi=[...n,{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],t.universalResolverReverseAbi=[...n,{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"}]}],t.textResolverAbi=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],t.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"}]}],t.smartAccountAbi=[{name:"isValidSignature",type:"function",stateMutability:"view",inputs:[{name:"hash",type:"bytes32"},{name:"signature",type:"bytes"}],outputs:[{name:"",type:"bytes4"}]}],t.universalSignatureValidatorAbi=[{inputs:[{internalType:"address",name:"_signer",type:"address"},{internalType:"bytes32",name:"_hash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"}]},16738:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.zeroAddress=void 0,t.zeroAddress="0x0000000000000000000000000000000000000000"},83446:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.zeroHash=void 0,t.zeroHash="0x0000000000000000000000000000000000000000000000000000000000000000"},48914:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.aggregate3Signature=void 0,t.aggregate3Signature="0x82ad56cb"},72229:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.universalSignatureValidatorByteCode=void 0,t.universalSignatureValidatorByteCode=
vendor: 3,588 bytes, line 46
46"0x60806040523480156200001157600080fd5b50604051620007003803806200070083398101604081905262000034916200056f565b6000620000438484846200004f565b9050806000526001601ff35b600080846001600160a01b0316803b806020016040519081016040528181526000908060200190933c90507f6492649264926492649264926492649264926492649264926492649264926492620000a68462000451565b036200021f57600060608085806020019051810190620000c79190620005ce565b8651929550909350915060000362000192576000836001600160a01b031683604051620000f5919062000643565b6000604051808303816000865af19150503d806000811462000134576040519150601f19603f3d011682016040523d82523d6000602084013e62000139565b606091505b5050905080620001905760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b505b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90620001c4908b90869060040162000661565b602060405180830381865afa158015620001e2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200020891906200069d565b6001600160e01b031916149450505050506200044a565b805115620002b157604051630b135d3f60e11b808252906001600160a01b03871690631626ba7e9062000259908890889060040162000661565b602060405180830381865afa15801562000277573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200029d91906200069d565b6001600160e01b031916149150506200044a565b8251604114620003195760405162461bcd60e51b815260206004820152603a6024820152600080516020620006e083398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e677468000000000000606482015260840162000187565b620003236200046b565b506020830151604080850151855186939260009185919081106200034b576200034b620006c9565b016020015160f81c9050601b81148015906200036b57508060ff16601c14155b15620003cf5760405162461bcd60e51b815260206004820152603b6024820152600080516020620006e083398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c75650000000000606482015260840162000187565b6040805160008152602081018083528a905260ff83169181019190915260608101849052608081018390526001600160a01b038a169060019060a0016020604051602081039080840390855afa1580156200042e573d6000803e3d6000fd5b505050602060405103516001600160a01b031614955050505050505b9392505050565b60006020825110156200046357600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b03811681146200049f57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b83811015620004d5578181015183820152602001620004bb565b50506000910152565b600082601f830112620004f057600080fd5b81516001600160401b03808211156200050d576200050d620004a2565b604051601f8301601f19908116603f01168101908282118183101715620005385762000538620004a2565b816040528381528660208588010111156200055257600080fd5b62000565846020830160208901620004b8565b9695505050505050565b6000806000606084860312156200058557600080fd5b8351620005928162000489565b6020850151604086015191945092506001600160401b03811115620005b657600080fd5b620005c486828701620004de565b9150509250925092565b600080600060608486031215620005e457600080fd5b8351620005f18162000489565b60208501519093506001600160401b03808211156200060f57600080fd5b6200061d87838801620004de565b935060408601519150808211156200063457600080fd5b50620005c486828701620004de565b6000825162000657818460208701620004b8565b9190910192915050565b828152604060208201526000825180604084015262000688816060850160208701620004b8565b601f01601f1916919091016060019392505050565b600060208284031215620006b057600080fd5b81516001600160e01b0319811681146200044a57600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572"
46},14940:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.minInt144=t.minInt136=t.minInt128=t.minInt120=t.minInt112=t.minInt104=t.minInt96=t.minInt88=t.minInt80=t.minInt72=t.minInt64=t.minInt56=t.minInt48=t.minInt40=t.minInt32=t.minInt24=t.minInt16=t.minInt8=t.maxInt256=t.maxInt248=t.maxInt240=t.maxInt232=t.maxInt224=t.maxInt216=t.maxInt208=t.maxInt200=t.maxInt192=t.maxInt184=t.maxInt176=t.maxInt168=t.maxInt160=t.maxInt152=t.maxInt144=t.maxInt136=t.maxInt128=t.maxInt120=t.maxInt112=t.maxInt104=t.maxInt96=t.maxInt88=t.maxInt80=t.maxInt72=t.maxInt64=t.maxInt56=t.maxInt48=t.maxInt40=t.maxInt32=t.maxInt24=t.maxInt16=t.maxInt8=void 0,t.maxUint256=t.maxUint248=t.maxUint240=t.maxUint232=t.maxUint224=t.maxUint216=t.maxUint208=t.maxUint200=t.maxUint192=t.maxUint184=t.maxUint176=t.maxUint168=t.maxUint160=t.maxUint152=t.maxUint144=t.maxUint136=t.maxUint128=t.maxUint120=t.maxUint112=t.maxUint104=t.maxUint96=t.maxUint88=t.maxUint80=t.maxUint72=t.maxUint64=t.maxUint56=t.maxUint48=t.maxUint40=t.maxUint32=t.maxUint24=t.maxUint16=t.maxUint8=t.minInt256=t.minInt248=t.minInt240=t.minInt232=t.minInt224=t.minInt216=t.minInt208=t.minInt200=t.minInt192=t.minInt184=t.minInt176=t.minInt168=t.minInt160=t.minInt152=void 0,t.maxInt8=2n**(8n-1n)-1n,t.maxInt16=2n**(16n-1n)-1n,t.maxInt24=2n**(24n-1n)-1n,t.maxInt32=2n**(32n-1n)-1n,t.maxInt40=2n**(40n-1n)-1n,t.maxInt48=2n**(48n-1n)-1n,t.maxInt56=2n**(56n-1n)-1n,t.maxInt64=2n**(64n-1n)-1n,t.maxInt72=2n**(72n-1n)-1n,t.maxInt80=2n**(80n-1n)-1n,t.maxInt88=2n**(88n-1n)-1n,t.maxInt96=2n**(96n-1n)-1n,t.maxInt104=2n**(104n-1n)-1n,t.maxInt112=2n**(112n-1n)-1n,t.maxInt120=2n**(120n-1n)-1n,t.maxInt128=2n**(128n-1n)-1n,t.maxInt136=2n**(136n-1n)-1n,t.maxInt144=2n**(144n-1n)-1n,t.maxInt152=2n**(152n-1n)-1n,t.maxInt160=2n**(160n-1n)-1n,t.maxInt168=2n**(168n-1n)-1n,t.maxInt176=2n**(176n-1n)-1n,t.maxInt184=2n**(184n-1n)-1n,t.maxInt192=2n**(192n-1n)-1n,t.maxInt200=2n**(200n-1n)-1n,t.maxInt208=2n**(208n-1n)-1n,t.maxInt216=2n**(216n-1n)-1n,t.maxInt224=2n**(224n-1n)-1n,t.maxInt232=2n**(232n-1n)-1n,t.maxInt240=2n**(240n-1n)-1n,t.maxInt248=2n**(248n-1n)-1n,t.maxInt256=2n**(256n-1n)-1n,t.minInt8=-(2n**(8n-1n)),t.minInt16=-(2n**(16n-1n)),t.minInt24=-(2n**(24n-1n)),t.minInt32=-(2n**(32n-1n)),t.minInt40=-(2n**(40n-1n)),t.minInt48=-(2n**(48n-1n)),t.minInt56=-(2n**(56n-1n)),t.minInt64=-(2n**(64n-1n)),t.minInt72=-(2n**(72n-1n)),t.minInt80=-(2n**(80n-1n)),t.minInt88=-(2n**(88n-1n)),t.minInt96=-(2n**(96n-1n)),t.minInt104=-(2n**(104n-1n)),t.minInt112=-(2n**(112n-1n)),t.minInt120=-(2n**(120n-1n)),t.minInt128=-(2n**(128n-1n)),t.minInt136=-(2n**(136n-1n)),t.minInt144=-(2n**(144n-1n)),t.minInt152=-(2n**(152n-1n)),t.minInt160=-(2n**(160n-1n)),t.minInt168=-(2n**(168n-1n)),t.minInt176=-(2n**(176n-1n)),t.minInt184=-(2n**(184n-1n)),t.minInt192=-(2n**(192n-1n)),t.minInt200=-(2n**(200n-1n)),t.minInt208=-(2n**(208n-1n)),t.minInt216=-(2n**(216n-1n)),t.minInt224=-(2n**(224n-1n)),t.minInt232=-(2n**(232n-1n)),t.minInt240=-(2n**(240n-1n)),t.minInt248=-(2n**(248n-1n)),t.minInt256=-(2n**(256n-1n)),t.maxUint8=2n**8n-1n,t.maxUint16=2n**16n-1n,t.maxUint24=2n**24n-1n,t.maxUint32=2n**32n-1n,t.maxUint40=2n**40n-1n,t.maxUint48=2n**48n-1n,t.maxUint56=2n**56n-1n,t.maxUint64=2n**64n-1n,t.maxUint72=2n**72n-1n,t.maxUint80=2n**80n-1n,t.maxUint88=2n**88n-1n,t.maxUint96=2n**96n-1n,t.maxUint104=2n**104n-1n,t.maxUint112=2n**112n-1n,t.maxUint120=2n**120n-1n,t.maxUint128=2n**128n-1n,t.maxUint136=2n**136n-1n,t.maxUint144=2n**144n-1n,t.maxUint152=2n**152n-1n,t.maxUint160=2n**160n-1n,t.maxUint168=2n**168n-1n,t.maxUint176=2n**176n-1n,t.maxUint184=2n**184n-1n,t.maxUint192=2n**192n-1n,t.maxUint200=2n**200n-1n,t.maxUint208=2n**208n-1n,t.maxUint216=2n**216n-1n,t.maxUint224=2n**224n-1n,t.maxUint232=2n**232n-1n,t.maxUint240=2n**240n-1n,t.maxUint248=2n**248n-1n,t.maxUint256=2n**256n-1n},35087:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.solidityPanic=t.solidityError=t.panicReasons=void 0,t.panicReasons={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 invali
46d 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."},t.solidityError={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},t.solidityPanic={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"}},76770:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.presignMessagePrefix=void 0,t.presignMessagePrefix="\x19Ethereum Signed Message:\n"},71035:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.weiUnits=t.gweiUnits=t.etherUnits=void 0,t.etherUnits={gwei:9,wei:18},t.gweiUnits={ether:-9,wei:9},t.weiUnits={ether:-18,gwei:-9}},82521:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UnsupportedPackedAbiType=t.InvalidDefinitionTypeError=t.InvalidArrayError=t.InvalidAbiDecodingTypeError=t.InvalidAbiEncodingTypeError=t.DecodeLogTopicsMismatch=t.DecodeLogDataMismatch=t.BytesSizeMismatchError=t.AbiItemAmbiguityError=t.AbiFunctionSignatureNotFoundError=t.AbiFunctionOutputsNotFoundError=t.AbiFunctionNotFoundError=t.AbiEventNotFoundError=t.AbiEventSignatureNotFoundError=t.AbiEventSignatureEmptyTopicsError=t.AbiErrorSignatureNotFoundError=t.AbiErrorNotFoundError=t.AbiErrorInputsNotFoundError=t.AbiEncodingLengthMismatchError=t.AbiEncodingBytesSizeMismatchError=t.AbiEncodingArrayLengthMismatchError=t.AbiDecodingZeroDataError=t.AbiDecodingDataSizeTooSmallError=t.AbiDecodingDataSizeInvalidError=t.AbiConstructorParamsNotFoundError=t.AbiConstructorNotFoundError=void 0;let o=n(26352),i=n(96711),s=n(78498);let AbiConstructorNotFoundError=class AbiConstructorNotFoundError extends s.BaseError{constructor({docsPath:e}){super("A constructor was not found on the ABI.\nMake sure you are using the correct ABI and that the constructor exists on it.",{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorNotFoundError"})}};t.AbiConstructorNotFoundError=AbiConstructorNotFoundError;let AbiConstructorParamsNotFoundError=class AbiConstructorParamsNotFoundError extends s.BaseError{constructor({docsPath:e}){super("Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.\nMake sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists.",{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorParamsNotFoundError"})}};t.AbiConstructorParamsNotFoundError=AbiConstructorParamsNotFoundError;let AbiDecodingDataSizeInvalidError=class AbiDecodingDataSizeInvalidError extends s.BaseError{constructor({data:e,size:t}){super(`Data size of ${t}
46 bytes is invalid.
47Size must be in increments of 32 bytes (size % 32 === 0).`,{metaMessages:[`Data: ${e} (${t} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingDataSizeInvalidError"})}};t.AbiDecodingDataSizeInvalidError=AbiDecodingDataSizeInvalidError;let AbiDecodingDataSizeTooSmallError=class AbiDecodingDataSizeTooSmallError extends s.BaseError{constructor({data:e,params:t,size:n}){super(`Data size of ${n} bytes is too small for given parameters.`,{metaMessages:[`Params: (${(0,o.formatAbiParams)(t,{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=t,this.size=n}};t.AbiDecodingDataSizeTooSmallError=AbiDecodingDataSizeTooSmallError;let AbiDecodingZeroDataError=class AbiDecodingZeroDataError extends s.BaseError{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingZeroDataError"})}};t.AbiDecodingZeroDataError=AbiDecodingZeroDataError;let AbiEncodingArrayLengthMismatchError=class AbiEncodingArrayLengthMismatchError extends s.BaseError{constructor({expectedLength:e,givenLength:t,type:n}){super(`ABI encoding array length mismatch for type ${n}.
48Expected length: ${e}
49Given length: ${t}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}};t.AbiEncodingArrayLengthMismatchError=AbiEncodingArrayLengthMismatchError;let AbiEncodingBytesSizeMismatchError=class AbiEncodingBytesSizeMismatchError extends s.BaseError{constructor({expectedSize:e,value:t}){super(`Size of bytes "${t}" (bytes${(0,i.size)(t)}) does not match expected size (bytes${e}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}};t.AbiEncodingBytesSizeMismatchError=AbiEncodingBytesSizeMismatchError;let AbiEncodingLengthMismatchError=class AbiEncodingLengthMismatchError extends s.BaseError{constructor({expectedLength:e,givenLength:t}){super(`ABI encoding params/values length mismatch.
50Expected length (params): ${e}
51Given length (values): ${t}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}};t.AbiEncodingLengthMismatchError=AbiEncodingLengthMismatchError;let AbiErrorInputsNotFoundError=class AbiErrorInputsNotFoundError extends s.BaseError{constructor(e,{docsPath:t}){super(`Arguments (\`args\`) were provided to "${e}", but "${e}" on the ABI does not contain any parameters (\`inputs\`).
52Cannot encode error result without knowing what the parameter types are.
53Make sure you are using the correct ABI and that the inputs exist on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorInputsNotFoundError"})}};t.AbiErrorInputsNotFoundError=AbiErrorInputsNotFoundError;let AbiErrorNotFoundError=class AbiErrorNotFoundError extends s.BaseError{constructor(e,{docsPath:t}={}){super(`Error ${e?`"${e}" `:""}not found on ABI.
54Make sure you are using the correct ABI and that the error exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorNotFoundError"})}};t.AbiErrorNotFoundError=AbiErrorNotFoundError;let AbiErrorSignatureNotFoundError=class AbiErrorSignatureNotFoundError extends s.BaseError{constructor(e,{docsPath:t}){super(`Encoded error signature "${e}" not found on ABI.
55Make sure you are using the correct ABI and that the error exists on it.
56You can look up the decoded signature here: https://openchain.xyz/signatures?query=${e}.`,{docsPath:t}),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}};t.AbiErrorSignatureNotFoundError=AbiErrorSignatureNotFoundError;let AbiEventSignatureEmptyTopicsError=class AbiEventSignatureEmptyTopicsError extends s.BaseError{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"})}};t.AbiEventSignatureEmptyTopicsError=AbiEventSignatureEmptyTopicsError;let AbiEventSignatureNotFoundError=class AbiEventSignatureNotFoundError extends s.BaseError{constructor(e,{docsPath:t}){super(`Encoded event signature "${e}" not found on ABI.
57Make sure you are using the correct ABI and that the event exists on it.
58You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureNotFoundError"})}};t.AbiEventSignatureNotFoundError=AbiEventSignatureNotFoundError;let AbiEventNotFoundError=class AbiEventNotFoundError extends s.BaseError{constructor(e,{docsPath:t}={}){super(`Event ${e?`"${e}" `:""}not found on ABI.
59Make sure you are using the correct ABI and that the event exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventNotFoundError"})}};t.AbiEventNotFoundError=AbiEventNotFoundError;let AbiFunctionNotFoundError=class AbiFunctionNotFoundError extends s.BaseError{constructor(e,{docsPath:t}={}){super(`Function ${e?`"${e}" `:""}not found on ABI.
60Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}};t.AbiFunctionNotFoundError=AbiFunctionNotFoundError;let AbiFunctionOutputsNotFoundError=class AbiFunctionOutputsNotFoundError extends s.BaseError{constructor(e,{docsPath:t}){super(`Function "${e}" does not contain any \`outputs\` on ABI.
61Cannot decode function result without knowing what the parameter types are.
62Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionOutputsNotFoundError"})}};t.AbiFunctionOutputsNotFoundError=AbiFunctionOutputsNotFoundError;let AbiFunctionSignatureNotFoundError=class AbiFunctionSignatureNotFoundError extends s.BaseError{constructor(e,{docsPath:t}){super(`Encoded function signature "${e}" not found on ABI.
63Make sure you are using the correct ABI and that the function exists on it.
64You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionSignatureNotFoundError"})}};t.AbiFunctionSignatureNotFoundError=AbiFunctionSignatureNotFoundError;let AbiItemAmbiguityError=class AbiItemAmbiguityError extends s.BaseError{constructor(e,t){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${e.type}
64\` in \`${(0,o.formatAbiItem)(e.abiItem)}\`, and`,`\`${t.type}\` in \`${(0,o.formatAbiItem)(t.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"})}};t.AbiItemAmbiguityError=AbiItemAmbiguityError;let BytesSizeMismatchError=class BytesSizeMismatchError extends s.BaseError{constructor({expectedSize:e,givenSize:t}){super(`Expected bytes${e}, got bytes${t}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}};t.BytesSizeMismatchError=BytesSizeMismatchError;let DecodeLogDataMismatch=class DecodeLogDataMismatch extends s.BaseError{constructor({abiItem:e,data:t,params:n,size:i}){super(`Data size of ${i} bytes is too small for non-indexed event parameters.`,{metaMessages:[`Params: (${(0,o.formatAbiParams)(n,{includeName:!0})})`,`Data:   ${t} (${i} 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=t,this.params=n,this.size=i}};t.DecodeLogDataMismatch=DecodeLogDataMismatch;let DecodeLogTopicsMismatch=class DecodeLogTopicsMismatch extends s.BaseError{constructor({abiItem:e,param:t}){super(`Expected a topic for indexed event parameter${t.name?` "${t.name}"`:""} on event "${(0,o.formatAbiItem)(e,{includeName:!0})}".`),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}};t.DecodeLogTopicsMismatch=DecodeLogTopicsMismatch;let InvalidAbiEncodingTypeError=class InvalidAbiEncodingTypeError extends s.BaseError{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid encoding type.
65Please provide a valid ABI type.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}};t.InvalidAbiEncodingTypeError=InvalidAbiEncodingTypeError;let InvalidAbiDecodingTypeError=class InvalidAbiDecodingTypeError extends s.BaseError{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid decoding type.
66Please provide a valid ABI type.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiDecodingType"})}};t.InvalidAbiDecodingTypeError=InvalidAbiDecodingTypeError;let InvalidArrayError=class InvalidArrayError extends s.BaseError{constructor(e){super(`Value "${e}" is not a valid array.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}};t.InvalidArrayError=InvalidArrayError;let InvalidDefinitionTypeError=class InvalidDefinitionTypeError extends s.BaseError{constructor(e){super(`"${e}" is not a valid definition type.
67Valid types: "function", "event", "error"`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}};t.InvalidDefinitionTypeError=InvalidDefinitionTypeError;let UnsupportedPackedAbiType=class UnsupportedPackedAbiType extends s.BaseError{constructor(e){super(`Type "${e}" is not supported for packed encoding.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedPackedAbiType"})}};t.UnsupportedPackedAbiType=UnsupportedPackedAbiType},21506:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AccountNotFoundError=void 0;let o=n(78498);let AccountNotFoundError=class AccountNotFoundError extends o.BaseError{constructor({docsPath:e}={}){super("Could not find an Account to execute with this Action.\nPlease provide an Account with the `account` argument on the Action, or by supplying an `account` to the WalletClient.",{docsPath:e,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountNotFoundError"})}};t.AccountNotFoundError=AccountNotFoundError},61235:function(e,t,n){"use strict";
67Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidAddressError=void 0;let o=n(78498);let InvalidAddressError=class InvalidAddressError extends o.BaseError{constructor({address:e}){super(`Address "${e}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}};t.InvalidAddressError=InvalidAddressError},78498:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseError=void 0;let o=n(81147);let BaseError=class BaseError extends Error{constructor(e,t={}){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:(0,o.getVersion)()});let n=t.cause instanceof BaseError?t.cause.details:t.cause?.message?t.cause.message:t.details,i=t.cause instanceof BaseError&&t.cause.docsPath||t.docsPath;this.message=[e||"An error occurred.","",...t.metaMessages?[...t.metaMessages,""]:[],...i?[`Docs: https://viem.sh${i}.html${t.docsSlug?`#${t.docsSlug}`:""}`]:[],...n?[`Details: ${n}`]:[],`Version: ${this.version}`].join("\n"),t.cause&&(this.cause=t.cause),this.details=n,this.docsPath=i,this.metaMessages=t.metaMessages,this.shortMessage=e}walk(e){return function walk(e,t){return t?.(e)?e:e&&"object"==typeof e&&"cause"in e?walk(e.cause,t):t?null:e}(this,e)}};t.BaseError=BaseError},48962:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BlockNotFoundError=void 0;let o=n(78498);let BlockNotFoundError=class BlockNotFoundError extends o.BaseError{constructor({blockHash:e,blockNumber:t}){let n="Block";e&&(n=`Block at hash "${e}"`),t&&(n=`Block at number "${t}"`),super(`${n} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlockNotFoundError"})}};t.BlockNotFoundError=BlockNotFoundError},59232:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OffchainLookupSenderMismatchError=t.OffchainLookupResponseMalformedError=t.OffchainLookupError=void 0;let o=n(36774),i=n(78498),s=n(81147);let OffchainLookupError=class OffchainLookupError extends i.BaseError{constructor({callbackSelector:e,cause:t,data:n,extraData:o,sender:i,urls:c}){super(t.shortMessage||"An error occurred while fetching for an offchain result.",{cause:t,metaMessages:[...t.metaMessages||[],t.metaMessages?.length?"":[],"Offchain Gateway Call:",c&&["  Gateway URL(s):",...c.map(e=>`    ${(0,s.getUrl)(e)}`)],`  Sender: ${i}`,`  Data: ${n}`,`  Callback selector: ${e}`,`  Extra data: ${o}`].flat()}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupError"})}};t.OffchainLookupError=OffchainLookupError;let OffchainLookupResponseMalformedError=class OffchainLookupResponseMalformedError extends i.BaseError{constructor({result:e,url:t}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${(0,s.getUrl)(t)}`,`Response: ${(0,o.stringify)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupResponseMalformedError"})}};t.OffchainLookupResponseMalformedError=OffchainLookupResponseMalformedError;let OffchainLookupSenderMismatchError=class OffchainLookupSenderMismatchError extends i.BaseError{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"})}};t.OffchainLookupSenderMismatchError=OffchainLookupSenderMismatchError},99174:function(e,t,n){"use strict";
67Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidChainIdError=t.ClientChainNotConfiguredError=t.ChainNotFoundError=t.ChainMismatchError=t.ChainDoesNotSupportContract=void 0;let o=n(78498);let ChainDoesNotSupportContract=class ChainDoesNotSupportContract extends o.BaseError{constructor({blockNumber:e,chain:t,contract:n}){super(`Chain "${t.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"})}};t.ChainDoesNotSupportContract=ChainDoesNotSupportContract;let ChainMismatchError=class ChainMismatchError extends o.BaseError{constructor({chain:e,currentChainId:t}){super(`The current chain of the wallet (id: ${t}) does not match the target chain for the transaction (id: ${e.id} – ${e.name}).`,{metaMessages:[`Current Chain ID:  ${t}`,`Expected Chain ID: ${e.id} – ${e.name}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainMismatchError"})}};t.ChainMismatchError=ChainMismatchError;let ChainNotFoundError=class ChainNotFoundError extends o.BaseError{constructor(){super("No chain was provided to the request.\nPlease provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotFoundError"})}};t.ChainNotFoundError=ChainNotFoundError;let ClientChainNotConfiguredError=class ClientChainNotConfiguredError extends o.BaseError{constructor(){super("No chain was provided to the Client."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ClientChainNotConfiguredError"})}};t.ClientChainNotConfiguredError=ClientChainNotConfiguredError;let InvalidChainIdError=class InvalidChainIdError extends o.BaseError{constructor({chainId:e}){super(`Chain ID "${e}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidChainIdError"})}};t.InvalidChainIdError=InvalidChainIdError},91349:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RawContractError=t.ContractFunctionZeroDataError=t.ContractFunctionRevertedError=t.ContractFunctionExecutionError=t.CallExecutionError=void 0;let o=n(27558),i=n(35087),s=n(37113),c=n(26352),l=n(79075),u=n(68340),d=n(74869),p=n(67505),m=n(82521),b=n(78498),g=n(33841),y=n(81147);let CallExecutionError=class CallExecutionError extends b.BaseError{constructor(e,{account:t,docsPath:n,chain:i,data:s,gas:c,gasPrice:l,maxFeePerGas:u,maxPriorityFeePerGas:m,nonce:b,to:y,value:v}){let E=t?(0,o.parseAccount)(t):void 0,x=(0,g.prettyPrint)({from:E?.address,to:y,value:void 0!==v&&`${(0,d.formatEther)(v)} ${i?.nativeCurrency?.symbol||"ETH"}`,data:s,gas:c,gasPrice:void 0!==l&&`${(0,p.formatGwei)(l)} gwei`,maxFeePerGas:void 0!==u&&`${(0,p.formatGwei)(u)} gwei`,maxPriorityFeePerGas:void 0!==m&&`${(0,p.formatGwei)(m)} gwei`,nonce:b});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Raw Call Arguments:",x].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}};t.CallExecutionError=CallExecutionError;let ContractFunctionExecutionError=class ContractFunctionExecutionError extends b.BaseError{constructor(e,{abi:t,args:n,contractAddress:o,docsPath:i,functionName:s,sender:d}){let p=(0,u.getAbiItem)({abi:t,args:n,name:s}),m=p?(0,l.formatAbiItemWithArgs)({abiItem:p,args:n,includeFunctionName:!1,includeName:!1}):void 0,b=p?(0,c.formatAbiItem)(p,{includeName:!0}):void 0,v=(0,g.prettyPrint)({address:o&&(0,y.getContractAddress)(o),function:b,args:m&&"()"!==m&&`${[...Array(s?.length??0).keys()].map(()=>" ").join("")}${m}`,sender:d});super(e.shortMessage||`An unknown error occurred while executing the contract function "${s}".`,{cause:e,docsPath:i,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Contract Call:",v].filter(
67Boolean)}),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=t,this.args=n,this.cause=e,this.contractAddress=o,this.functionName=s,this.sender=d}};t.ContractFunctionExecutionError=ContractFunctionExecutionError;let ContractFunctionRevertedError=class ContractFunctionRevertedError extends b.BaseError{constructor({abi:e,data:t,functionName:n,message:o}){let u,d,p,b,g;if(t&&"0x"!==t)try{g=(0,s.decodeErrorResult)({abi:e,data:t});let{abiItem:n,errorName:o,args:u}=g;if("Error"===o)p=u[0];else if("Panic"===o){let[e]=u;p=i.panicReasons[e]}else{let e=n?(0,c.formatAbiItem)(n,{includeName:!0}):void 0,t=n&&u?(0,l.formatAbiItemWithArgs)({abiItem:n,args:u,includeFunctionName:!1,includeName:!1}):void 0;d=[e?`Error: ${e}`:"",t&&"()"!==t?`       ${[...Array(o?.length??0).keys()].map(()=>" ").join("")}${t}`:""]}}catch(e){u=e}else o&&(p=o);u instanceof m.AbiErrorSignatureNotFoundError&&(b=u.signature,d=[`Unable to decode signature "${b}" 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=${b}.`]),super(p&&"execution reverted"!==p||b?[`The contract function "${n}" reverted with the following ${b?"signature":"reason"}:`,p||b].join("\n"):`The contract function "${n}" reverted.`,{cause:u,metaMessages:d}),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=g,this.reason=p,this.signature=b}};t.ContractFunctionRevertedError=ContractFunctionRevertedError;let ContractFunctionZeroDataError=class ContractFunctionZeroDataError extends b.BaseError{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"})}};t.ContractFunctionZeroDataError=ContractFunctionZeroDataError;let RawContractError=class RawContractError extends b.BaseError{constructor({data:e,message:t}){super(t||""),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}};t.RawContractError=RawContractError},43342:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PositionOutOfBoundsError=t.NegativeOffsetError=void 0;let o=n(78498);let NegativeOffsetError=class NegativeOffsetError extends o.BaseError{constructor({offset:e}){super(`Offset \`${e}\` cannot be negative.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NegativeOffsetError"})}};t.NegativeOffsetError=NegativeOffsetError;let PositionOutOfBoundsError=class PositionOutOfBoundsError extends o.BaseError{constructor({length:e,position:t}){super(`Position \`${t}\` is out of bounds (\`0 < position < ${e}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PositionOutOfBoundsError"})}};t.PositionOutOfBoundsError=PositionOutOfBoundsError},50562:function(e,t,n){"use strict";
67Object.defineProperty(t,"__esModule",{value:!0}),t.SizeExceedsPaddingSizeError=t.SliceOffsetOutOfBoundsError=void 0;let o=n(78498);let SliceOffsetOutOfBoundsError=class SliceOffsetOutOfBoundsError extends o.BaseError{constructor({offset:e,position:t,size:n}){super(`Slice ${"start"===t?"starting":"ending"} at offset "${e}" is out-of-bounds (size: ${n}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}};t.SliceOffsetOutOfBoundsError=SliceOffsetOutOfBoundsError;let SizeExceedsPaddingSizeError=class SizeExceedsPaddingSizeError extends o.BaseError{constructor({size:e,targetSize:t,type:n}){super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} size (${e}) exceeds padding size (${t}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}};t.SizeExceedsPaddingSizeError=SizeExceedsPaddingSizeError},62608:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SizeOverflowError=t.OffsetOutOfBoundsError=t.InvalidHexValueError=t.InvalidHexBooleanError=t.InvalidBytesBooleanError=t.IntegerOutOfRangeError=t.DataLengthTooShortError=t.DataLengthTooLongError=void 0;let o=n(78498);let DataLengthTooLongError=class DataLengthTooLongError extends o.BaseError{constructor({consumed:e,length:t}){super(`Consumed bytes (${e}) is shorter than data length (${t-1}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DataLengthTooLongError"})}};t.DataLengthTooLongError=DataLengthTooLongError;let DataLengthTooShortError=class DataLengthTooShortError extends o.BaseError{constructor({length:e,dataLength:t}){super(`Data length (${t-1}) is shorter than consumed bytes length (${e-1}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DataLengthTooShortError"})}};t.DataLengthTooShortError=DataLengthTooShortError;let IntegerOutOfRangeError=class IntegerOutOfRangeError extends o.BaseError{constructor({max:e,min:t,signed:n,size:o,value:i}){super(`Number "${i}" is not in safe ${o?`${8*o}-bit ${n?"signed":"unsigned"} `:""}integer range ${e?`(${t} to ${e})`:`(above ${t})`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntegerOutOfRangeError"})}};t.IntegerOutOfRangeError=IntegerOutOfRangeError;let InvalidBytesBooleanError=class InvalidBytesBooleanError extends o.BaseError{constructor(e){super(`Bytes value "${e}" is not a valid boolean. The bytes array must contain a single byte of either a 0 or 1 value.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidBytesBooleanError"})}};t.InvalidBytesBooleanError=InvalidBytesBooleanError;let InvalidHexBooleanError=class InvalidHexBooleanError extends o.BaseError{constructor(e){super(`Hex value "${e}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidHexBooleanError"})}};t.InvalidHexBooleanError=InvalidHexBooleanError;let InvalidHexValueError=class InvalidHexValueError extends o.BaseError{constructor(e){super(`Hex value "${e}" is an odd length (${e.length}). It must be an even length.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidHexValueError"})}};t.InvalidHexValueError=InvalidHexValueError;let OffsetOutOfBoundsError=class OffsetOutOfBoundsError extends o.BaseError{constructor({nextOffset:e,offset:t}){super(`Next offset (${e}) is greater than previous offset + consumed bytes (${t})`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffsetOutOfBoundsError"})}};t.OffsetOutOfBoundsError=OffsetOutOfBoundsError;let SizeOverflowError=class SizeOverflowError extends o.BaseError{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed ${t} bytes. Given size: ${e} bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeOverflowError"})}};t.SizeOverflowError=SizeOverflowError},8370:function(e,t,n){"use strict";
67Object.defineProperty(t,"__esModule",{value:!0}),t.EnsAvatarUnsupportedNamespaceError=t.EnsAvatarUriResolutionError=t.EnsAvatarInvalidNftUriError=t.EnsAvatarInvalidMetadataError=void 0;let o=n(78498);let EnsAvatarInvalidMetadataError=class EnsAvatarInvalidMetadataError extends o.BaseError{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"})}};t.EnsAvatarInvalidMetadataError=EnsAvatarInvalidMetadataError;let EnsAvatarInvalidNftUriError=class EnsAvatarInvalidNftUriError extends o.BaseError{constructor({reason:e}){super(`ENS NFT avatar URI is invalid. ${e}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidNftUriError"})}};t.EnsAvatarInvalidNftUriError=EnsAvatarInvalidNftUriError;let EnsAvatarUriResolutionError=class EnsAvatarUriResolutionError extends o.BaseError{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"})}};t.EnsAvatarUriResolutionError=EnsAvatarUriResolutionError;let EnsAvatarUnsupportedNamespaceError=class EnsAvatarUnsupportedNamespaceError extends o.BaseError{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"})}};t.EnsAvatarUnsupportedNamespaceError=EnsAvatarUnsupportedNamespaceError},26265:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EstimateGasExecutionError=void 0;let o=n(74869),i=n(67505),s=n(78498),c=n(33841);let EstimateGasExecutionError=class EstimateGasExecutionError extends s.BaseError{constructor(e,{account:t,docsPath:n,chain:s,data:l,gas:u,gasPrice:d,maxFeePerGas:p,maxPriorityFeePerGas:m,nonce:b,to:g,value:y}){let v=(0,c.prettyPrint)({from:t?.address,to:g,value:void 0!==y&&`${(0,o.formatEther)(y)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:l,gas:u,gasPrice:void 0!==d&&`${(0,i.formatGwei)(d)} gwei`,maxFeePerGas:void 0!==p&&`${(0,i.formatGwei)(p)} gwei`,maxPriorityFeePerGas:void 0!==m&&`${(0,i.formatGwei)(m)} gwei`,nonce:b});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Estimate Gas Arguments:",v].filter(
67Boolean)}),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}};t.EstimateGasExecutionError=EstimateGasExecutionError},30375:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MaxFeePerGasTooLowError=t.Eip1559FeesNotSupportedError=t.BaseFeeScalarError=void 0;let o=n(67505),i=n(78498);let BaseFeeScalarError=class BaseFeeScalarError extends i.BaseError{constructor(){super("`baseFeeMultiplier` must be greater than 1."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseFeeScalarError"})}};t.BaseFeeScalarError=BaseFeeScalarError;let Eip1559FeesNotSupportedError=class Eip1559FeesNotSupportedError extends i.BaseError{constructor(){super("Chain does not support EIP-1559 fees."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Eip1559FeesNotSupportedError"})}};t.Eip1559FeesNotSupportedError=Eip1559FeesNotSupportedError;let MaxFeePerGasTooLowError=class MaxFeePerGasTooLowError extends i.BaseError{constructor({maxPriorityFeePerGas:e}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${(0,o.formatGwei)(e)} gwei).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MaxFeePerGasTooLowError"})}};t.MaxFeePerGasTooLowError=MaxFeePerGasTooLowError},84166:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FilterTypeNotSupportedError=void 0;let o=n(78498);let FilterTypeNotSupportedError=class FilterTypeNotSupportedError extends o.BaseError{constructor(e){super(`Filter type "${e}" is not supported.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FilterTypeNotSupportedError"})}};t.FilterTypeNotSupportedError=FilterTypeNotSupportedError},48016:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UnknownNodeError=t.TipAboveFeeCapError=t.TransactionTypeNotSupportedError=t.IntrinsicGasTooLowError=t.IntrinsicGasTooHighError=t.InsufficientFundsError=t.NonceMaxValueError=t.NonceTooLowError=t.NonceTooHighError=t.FeeCapTooLowError=t.FeeCapTooHighError=t.ExecutionRevertedError=void 0;let o=n(67505),i=n(78498);let ExecutionRevertedError=class ExecutionRevertedError extends i.BaseError{constructor({cause:e,message:t}={}){let n=t?.replace("execution reverted: ","")?.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(ExecutionRevertedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(ExecutionRevertedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/}),t.ExecutionRevertedError=ExecutionRevertedError;let FeeCapTooHighError=class FeeCapTooHighError extends i.BaseError{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,o.formatGwei)(t)} 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"})}};
67Object.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/}),t.FeeCapTooHighError=FeeCapTooHighError;let FeeCapTooLowError=class FeeCapTooLowError extends i.BaseError{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,o.formatGwei)(t)}`:""} 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(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/}),t.FeeCapTooLowError=FeeCapTooLowError;let NonceTooHighError=class NonceTooHighError extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is higher than the next one expected.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooHighError"})}};
67Object.defineProperty(NonceTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/}),t.NonceTooHighError=NonceTooHighError;let NonceTooLowError=class NonceTooLowError extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is lower than the current nonce of the account.
68Try increasing the nonce or find the latest nonce with \`getTransactionCount\`.`,{cause:e}),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/}),t.NonceTooLowError=NonceTooLowError;let NonceMaxValueError=class NonceMaxValueError extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}exceeds the maximum allowed nonce.`,{cause:e}),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/}),t.NonceMaxValueError=NonceMaxValueError;let InsufficientFundsError=class InsufficientFundsError extends i.BaseError{constructor({cause:e}={}){super("The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account.",{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(InsufficientFundsError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds/}),t.InsufficientFundsError=InsufficientFundsError;let IntrinsicGasTooHighError=class IntrinsicGasTooHighError extends i.BaseError{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}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"})}};
68Object.defineProperty(IntrinsicGasTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/}),t.IntrinsicGasTooHighError=IntrinsicGasTooHighError;let IntrinsicGasTooLowError=class IntrinsicGasTooLowError extends i.BaseError{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}provided for the transaction is too low.`,{cause:e}),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/}),t.IntrinsicGasTooLowError=IntrinsicGasTooLowError;let TransactionTypeNotSupportedError=class TransactionTypeNotSupportedError extends i.BaseError{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(TransactionTypeNotSupportedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/}),t.TransactionTypeNotSupportedError=TransactionTypeNotSupportedError;let TipAboveFeeCapError=class TipAboveFeeCapError extends i.BaseError{constructor({cause:e,maxPriorityFeePerGas:t,maxFeePerGas:n}={}){super(`The provided tip (\`maxPriorityFeePerGas\`${t?` = ${(0,o.formatGwei)(t)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${n?` = ${(0,o.formatGwei)(n)} gwei`:""}).`,{cause:e}),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/}),t.TipAboveFeeCapError=TipAboveFeeCapError;let UnknownNodeError=class UnknownNodeError extends i.BaseError{constructor({cause:e}){super(`An error occurred while executing: ${e?.shortMessage}`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownNodeError"})}};t.UnknownNodeError=UnknownNodeError},86617:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TimeoutError=t.RpcRequestError=t.WebSocketRequestError=t.HttpRequestError=void 0;let o=n(36774),i=n(78498),s=n(81147);let HttpRequestError=class HttpRequestError extends i.BaseError{constructor({body:e,details:t,headers:n,status:i,url:c}){super("HTTP request failed.",{details:t,metaMessages:[i&&`Status: ${i}`,`URL: ${(0,s.getUrl)(c)}`,e&&`Request body: ${(0,o.stringify)(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=i,this.url=c}};t.HttpRequestError=HttpRequestError;let WebSocketRequestError=class WebSocketRequestError extends i.BaseError{constructor({body:e,details:t,url:n}){super("WebSocket request failed.",{details:t,metaMessages:[`URL: ${(0,s.getUrl)(n)}`,`Request body: ${(0,o.stringify)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WebSocketRequestError"})}};t.WebSocketRequestError=WebSocketRequestError;let RpcRequestError=class RpcRequestError extends i.BaseError{constructor({body:e,error:t,url:n}){super("RPC Request failed.",{cause:t,details:t.message,metaMessages:[`URL: ${(0,s.getUrl)(n)}`,`Request body: ${(0,o.stringify)(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=t.code}};t.RpcRequestError=RpcRequestError;let TimeoutError=class TimeoutError extends i.BaseError{constructor({body:e,url:t}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${(0,s.getUrl)(t)}`,`Request body: ${(0,o.stringify)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TimeoutError"})}};t.TimeoutError=TimeoutError},28516:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.UnknownRpcError=t.SwitchChainError=t.ChainDisconnectedError=t.ProviderDisconnectedError=t.UnsupportedProviderMethodError=t.UnauthorizedProviderError=t.UserRejectedRequestError=t.JsonRpcVersionUnsupportedError=t.LimitExceededRpcError=t.MethodNotSupportedRpcError=t.TransactionRejectedRpcError=t.ResourceUnavailableRpcError=t.ResourceNotFoundRpcError=t.InvalidInputRpcError=t.InternalRpcError=t.InvalidParamsRpcError=t.MethodNotFoundRpcError=t.InvalidRequestRpcError=t.ParseRpcError=t.ProviderRpcError=t.RpcError=void 0;let o=n(78498),i=n(86617);let RpcError=class RpcError extends o.BaseError{constructor(e,{code:t,docsPath:n,metaMessages:o,shortMessage:s}){super(s,{cause:e,docsPath:n,metaMessages:o||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 i.RpcRequestError?e.code:t??-1}};t.RpcError=RpcError;let ProviderRpcError=class ProviderRpcError extends RpcError{constructor(e,t){super(e,t),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=t.data}};t.ProviderRpcError=ProviderRpcError;let ParseRpcError=class ParseRpcError extends RpcError{constructor(e){super(e,{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}),t.ParseRpcError=ParseRpcError;let InvalidRequestRpcError=class InvalidRequestRpcError extends RpcError{constructor(e){super(e,{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}),t.InvalidRequestRpcError=InvalidRequestRpcError;let MethodNotFoundRpcError=class MethodNotFoundRpcError extends RpcError{constructor(e){super(e,{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}),t.MethodNotFoundRpcError=MethodNotFoundRpcError;let InvalidParamsRpcError=class InvalidParamsRpcError extends RpcError{constructor(e){super(e,{code:InvalidParamsRpcError.code,shortMessage:"Invalid parameters were provided to the RPC method.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParamsRpcError"})}};Object.defineProperty(InvalidParamsRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602}),t.InvalidParamsRpcError=InvalidParamsRpcError;let InternalRpcError=class InternalRpcError extends RpcError{constructor(e){super(e,{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}),t.InternalRpcError=InternalRpcError;let InvalidInputRpcError=class InvalidInputRpcError extends RpcError{constructor(e){super(e,{code:InvalidInputRpcError.code,shortMessage:"Missing or invalid parameters.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidInputRpcError"})}};Object.defineProperty(InvalidInputRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3}
68),t.InvalidInputRpcError=InvalidInputRpcError;let ResourceNotFoundRpcError=class ResourceNotFoundRpcError extends RpcError{constructor(e){super(e,{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}),t.ResourceNotFoundRpcError=ResourceNotFoundRpcError;let ResourceUnavailableRpcError=class ResourceUnavailableRpcError extends RpcError{constructor(e){super(e,{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}),t.ResourceUnavailableRpcError=ResourceUnavailableRpcError;let TransactionRejectedRpcError=class TransactionRejectedRpcError extends RpcError{constructor(e){super(e,{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}),t.TransactionRejectedRpcError=TransactionRejectedRpcError;let MethodNotSupportedRpcError=class MethodNotSupportedRpcError extends RpcError{constructor(e){super(e,{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}),t.MethodNotSupportedRpcError=MethodNotSupportedRpcError;let LimitExceededRpcError=class LimitExceededRpcError extends RpcError{constructor(e){super(e,{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}),t.LimitExceededRpcError=LimitExceededRpcError;let JsonRpcVersionUnsupportedError=class JsonRpcVersionUnsupportedError extends RpcError{constructor(e){super(e,{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}),t.JsonRpcVersionUnsupportedError=JsonRpcVersionUnsupportedError;let UserRejectedRequestError=class UserRejectedRequestError extends ProviderRpcError{constructor(e){super(e,{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}),t.UserRejectedRequestError=UserRejectedRequestError;let UnauthorizedProviderError=class UnauthorizedProviderError extends ProviderRpcError{constructor(e){super(e,{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}),t.UnauthorizedProviderError=UnauthorizedProviderError;let UnsupportedProviderMethodError=class UnsupportedProviderMethodError extends ProviderRpcError{constructor(e){super(e,{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}),t.UnsupportedProviderMethodError=UnsupportedProviderMethodError;let ProviderDisconnectedError=class ProviderDisconnectedError extends ProviderRpcError{constructor(e){super(e,{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}),t.ProviderDisconnectedError=ProviderDisconnectedError;let ChainDisconnectedError=class ChainDisconnectedError extends ProviderRpcError{constructor(e){super(e,{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"})}};
68Object.defineProperty(ChainDisconnectedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901}),t.ChainDisconnectedError=ChainDisconnectedError;let SwitchChainError=class SwitchChainError extends ProviderRpcError{constructor(e){super(e,{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}),t.SwitchChainError=SwitchChainError,t.UnknownRpcError=class extends RpcError{constructor(e){super(e,{shortMessage:"An unknown RPC error occurred."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownRpcError"})}}},33841:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WaitForTransactionReceiptTimeoutError=t.TransactionReceiptNotFoundError=t.TransactionNotFoundError=t.TransactionExecutionError=t.InvalidStorageKeySizeError=t.InvalidSerializedTransactionError=t.InvalidSerializedTransactionTypeError=t.InvalidSerializableTransactionError=t.InvalidLegacyVError=t.FeeConflictError=t.prettyPrint=void 0;let o=n(74869),i=n(67505),s=n(78498);function prettyPrint(e){let t=Object.entries(e).map(([e,t])=>void 0===t||!1===t?null:[e,t]).filter(Boolean),n=t.reduce((e,[t])=>Math.max(e,t.length),0);return t.map(([e,t])=>`  ${`${e}:`.padEnd(n+1)}  ${t}`).join("\n")}t.prettyPrint=prettyPrint;let FeeConflictError=class FeeConflictError extends s.BaseError{constructor(){super("Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.\nUse `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeConflictError"})}};t.FeeConflictError=FeeConflictError;let InvalidLegacyVError=class InvalidLegacyVError extends s.BaseError{constructor({v:e}){super(`Invalid \`v\` value "${e}". Expected 27 or 28.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidLegacyVError"})}};t.InvalidLegacyVError=InvalidLegacyVError;let InvalidSerializableTransactionError=class InvalidSerializableTransactionError extends s.BaseError{constructor({transaction:e}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",prettyPrint(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"})}};t.InvalidSerializableTransactionError=InvalidSerializableTransactionError;let InvalidSerializedTransactionTypeError=class InvalidSerializedTransactionTypeError extends s.BaseError{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}};t.InvalidSerializedTransactionTypeError=InvalidSerializedTransactionTypeError;let InvalidSerializedTransactionError=class InvalidSerializedTransactionError extends s.BaseError{constructor({attributes:e,serializedTransaction:t,type:n}){let o=Object.entries(e).map(([e,t])=>void 0===t?e:void 0).filter(Boolean);super(`Invalid serialized transaction of type "${n}" was provided.`,{metaMessages:[`Serialized Transaction: "${t}"`,o.length>0?`Missing Attributes: ${o.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=t,this.type=n}};
68t.InvalidSerializedTransactionError=InvalidSerializedTransactionError;let InvalidStorageKeySizeError=class InvalidStorageKeySizeError extends s.BaseError{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"})}};t.InvalidStorageKeySizeError=InvalidStorageKeySizeError;let TransactionExecutionError=class TransactionExecutionError extends s.BaseError{constructor(e,{account:t,docsPath:n,chain:s,data:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:b,value:g}){let y=prettyPrint({chain:s&&`${s?.name} (id: ${s?.id})`,from:t?.address,to:b,value:void 0!==g&&`${(0,o.formatEther)(g)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:c,gas:l,gasPrice:void 0!==u&&`${(0,i.formatGwei)(u)} gwei`,maxFeePerGas:void 0!==d&&`${(0,i.formatGwei)(d)} gwei`,maxPriorityFeePerGas:void 0!==p&&`${(0,i.formatGwei)(p)} gwei`,nonce:m});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Request Arguments:",y].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}};t.TransactionExecutionError=TransactionExecutionError;let TransactionNotFoundError=class TransactionNotFoundError extends s.BaseError{constructor({blockHash:e,blockNumber:t,blockTag:n,hash:o,index:i}){let s="Transaction";n&&void 0!==i&&(s=`Transaction at block time "${n}" at index "${i}"`),e&&void 0!==i&&(s=`Transaction at block hash "${e}" at index "${i}"`),t&&void 0!==i&&(s=`Transaction at block number "${t}" at index "${i}"`),o&&(s=`Transaction with hash "${o}"`),super(`${s} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionNotFoundError"})}};t.TransactionNotFoundError=TransactionNotFoundError;let TransactionReceiptNotFoundError=class TransactionReceiptNotFoundError extends s.BaseError{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"})}};t.TransactionReceiptNotFoundError=TransactionReceiptNotFoundError;let WaitForTransactionReceiptTimeoutError=class WaitForTransactionReceiptTimeoutError extends s.BaseError{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"})}};t.WaitForTransactionReceiptTimeoutError=WaitForTransactionReceiptTimeoutError},86550:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UrlRequiredError=void 0;let o=n(78498);let UrlRequiredError=class UrlRequiredError extends o.BaseError{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro"})}};t.UrlRequiredError=UrlRequiredError},81147:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getVersion=t.getUrl=t.getContractAddress=void 0;let o=n(63570);t.getContractAddress=e=>e,t.getUrl=e=>e,t.getVersion=()=>`viem@${o.version}`},63570:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="1.21.3"},56431:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.maxInt112=t.maxInt104=t.maxInt96=t.maxInt88=t.maxInt80=t.maxInt72=t.maxInt64=t.maxInt56=t.maxInt48=t.maxInt40=t.maxInt32=t.maxInt24=t.maxInt16=t.maxInt8=t.weiUnits=t.gweiUnits=t.etherUnits=t.zeroAddress=t.multicall3Abi=t.webSocket=t.createWalletClient=t.createTransport=t.walletActions=t.testActions=t.publicActions=t.createTestClient=t.createPublicClient=t.http=t.fallback=t.custom=t.createClient=t.getContract=t.parseAbiParameters=t.parseAbiParameter=t.parseAbiItem=t.parseAbi=t.UnknownSignatureError=t.UnknownTypeError=t.SolidityProtectedKeywordError=t.InvalidStructSignatureError=t.InvalidSignatureError=t.InvalidParenthesisError=t.InvalidParameterError=t.InvalidModifierError=t.InvalidFunctionModifierError=t.InvalidAbiTypeParameterError=t.InvalidAbiItemError=t.InvalidAbiParametersError=t.InvalidAbiParameterError=t.CircularReferenceError=void 0,t.maxUint256=t.maxUint248=t.maxUint240=t.maxUint232=t.maxUint224=t.maxUint216=t.maxUint208=t.maxUint200=t.maxUint192=t.maxUint184=t.maxUint176=t.maxUint168=t.maxUint160=t.maxUint152=t.maxUint144=t.maxUint136=t.maxUint128=t.maxUint120=t.maxUint112=t.maxUint104=t.maxUint96=t.maxUint88=t.maxUint80=t.maxUint72=t.maxUint64=t.maxUint56=t.maxUint48=t.maxUint40=t.maxUint32=t.maxUint24=t.maxUint16=t.maxUint8=t.maxInt256=t.maxInt248=t.maxInt240=t.maxInt232=t.maxInt224=t.maxInt216=t.maxInt208=t.maxInt200=t.maxInt192=t.maxInt184=t.maxInt176=t.maxInt168=t.maxInt160=t.maxInt152=t.maxInt144=t.maxInt136=t.maxInt128=t.maxInt120=void 0,t.AbiFunctionOutputsNotFoundError=t.AbiFunctionNotFoundError=t.AbiEventSignatureNotFoundError=t.AbiEventSignatureEmptyTopicsError=t.AbiEventNotFoundError=t.AbiErrorSignatureNotFoundError=t.AbiErrorNotFoundError=t.AbiErrorInputsNotFoundError=t.AbiEncodingBytesSizeMismatchError=t.AbiEncodingLengthMismatchError=t.AbiEncodingArrayLe
68ngthMismatchError=t.AbiDecodingZeroDataError=t.AbiDecodingDataSizeTooSmallError=t.AbiDecodingDataSizeInvalidError=t.AbiConstructorParamsNotFoundError=t.AbiConstructorNotFoundError=t.presignMessagePrefix=t.zeroHash=t.minInt256=t.minInt248=t.minInt240=t.minInt232=t.minInt224=t.minInt216=t.minInt208=t.minInt200=t.minInt192=t.minInt184=t.minInt176=t.minInt168=t.minInt160=t.minInt152=t.minInt144=t.minInt136=t.minInt128=t.minInt120=t.minInt112=t.minInt104=t.minInt96=t.minInt88=t.minInt80=t.minInt72=t.minInt64=t.minInt56=t.minInt48=t.minInt40=t.minInt32=t.minInt24=t.minInt16=t.minInt8=void 0,t.InvalidHexBooleanError=t.IntegerOutOfRangeError=t.InvalidBytesBooleanError=t.DataLengthTooShortError=t.DataLengthTooLongError=t.InvalidChainIdError=t.ClientChainNotConfiguredError=t.ChainNotFoundError=t.ChainMismatchError=t.ChainDoesNotSupportContract=t.UserRejectedRequestError=t.UnsupportedProviderMethodError=t.UnknownRpcError=t.UnauthorizedProviderError=t.TransactionRejectedRpcError=t.SwitchChainError=t.RpcError=t.ResourceUnavailableRpcError=t.ResourceNotFoundRpcError=t.ProviderRpcError=t.ProviderDisconnectedError=t.ParseRpcError=t.MethodNotSupportedRpcError=t.MethodNotFoundRpcError=t.LimitExceededRpcError=t.JsonRpcVersionUnsupportedError=t.InvalidRequestRpcError=t.InvalidParamsRpcError=t.InvalidInputRpcError=t.InternalRpcError=t.ChainDisconnectedError=t.MaxFeePerGasTooLowError=t.Eip1559FeesNotSupportedError=t.BaseFeeScalarError=t.RawContractError=t.ContractFunctionZeroDataError=t.ContractFunctionRevertedError=t.ContractFunctionExecutionError=t.CallExecutionError=t.BlockNotFoundError=t.BaseError=t.UnsupportedPackedAbiType=t.InvalidDefinitionTypeError=t.InvalidArrayError=t.InvalidAbiEncodingTypeError=t.InvalidAbiDecodingTypeError=t.DecodeLogTopicsMismatch=t.DecodeLogDataMismatch=t.BytesSizeMismatchError=t.AbiFunctionSignatureNotFoundError=void 0,t.encodeAbiParameters=t.decodeFunctionResult=t.decodeFunctionData=t.decodeEventLog=t.decodeErrorResult=t.decodeDeployData=t.decodeAbiParameters=t.formatLog=t.formatBlock=t.defineBlock=t.namehash=t.labelhash=t.UrlRequiredError=t.SliceOffsetOutOfBoundsError=t.SizeExceedsPaddingSizeError=t.WaitForTransactionReceiptTimeoutError=t.TransactionReceiptNotFoundError=t.TransactionNotFoundError=t.TransactionExecutionError=t.InvalidStorageKeySizeError=t.InvalidSerializedTransactionTypeError=t.InvalidSerializedTransactionError=t.InvalidSerializableTransactionError=t.InvalidLegacyVError=t.FeeConflictError=t.InvalidAddressError=t.WebSocketRequestError=t.TimeoutError=t.RpcRequestError=t.HttpRequestError=t.FilterTypeNotSupportedError=t.UnknownNodeError=t.TransactionTypeNotSupportedError=t.TipAboveFeeCapError=t.NonceTooLowError=t.NonceTooHighError=t.NonceMaxValueError=t.IntrinsicGasTooLowError=t.IntrinsicGasTooHighError=t.InsufficientFundsError=t.FeeCapTooLowError=t.FeeCapTooHighError=t.ExecutionRevertedError=t.EstimateGasExecutionError=t.EnsAvatarUnsupportedNamespaceError=t.EnsAvatarInvalidNftUriError=t.EnsAvatarUriResolutionError=t.SizeOverflowError=t.OffsetOutOfBoundsError=t.InvalidHexValueError=void 0,t.toHex=t.stringToHex=t.numberToHex=t.bytesToHex=t.boolToHex=t.toBytes=t.stringToBytes=t.numberToBytes=t.hexToBytes=t.boolToBytes=t.assertTransactionLegacy=t.assertTransactionEIP2930=t.assertTransactionEIP1559=t.assertRequest=t.verifyTypedData=t.verifyMessage=t.toRlp=t.hexToRlp=t.bytesToRlp=t.signatureToHex=t.compactSignatureToHex=t.signatureToCompactSignature=t.recoverTypedDataAddress=t.recoverPublicKey=t.recoverMessageAddress=t.recoverAddress=t.hexToSignature=t.hexToCompactSignature=t.compactSignatureToSignature=t.hashTypedData=t.hashDomain=t.getTransactionType=t.getSerializedTransactionType=t.getCreateAddress=t.getCreate2Address=t.getContractAddress=t.getAbiItem=t.rpcTransactionType=t.formatTransactionRequest=t.defineTransactionRequest=t.formatTransactionReceipt=t.defineTransactionReceipt=t.transactionType=t.formatTransaction=t.defineTransaction=t.encodeFunctionResult=t.encodeFunctionData=t.encodeEventTopics=t.encodeErrorResult=t.encodeDeployData=void 0,t.parseUnits=t.parseTransaction=t.parseGwei=t.parseEther=t.padHex=t.padBytes=t.pad=t.ripemd160=t.sha256=t.keccak256=t.isHex=t.isHash=t.isBytes=t.isAddressEqual=t.isAddress=t.hashMessage=t.getFunctionSignature=t.getFunctionSelector=t.getEventSignature=t.getEventSelector=t.getContractError=t.getAddress=t.checksumAddress=t.fromRlp=t.hexToString=t.hexToNumber=t.hexToBool=t.hexToBigInt=t.fromHex=t.formatUnits=t.formatGwei=t.formatEther=t.encodePacked=t.getChainContractAddress=t.extractChain=t.defineChain=t.assertCurrentChain=t.concatHex=t.concatBytes=t.concat=t.offchainLookupSignature=t.offchainLookupAbiItem=t.offchainLookup=t.ccipFetch=t.fromBytes=t.bytesToString=t.bytesToNumber=t.bytesToBool=t.bytesToBigint=t.bytesToBigInt=void 0,t.getTypesForEIP712Domain=t.domainSeparator=t.validateTypedData=t.trim=t.stringify=t.sliceHex=t.sliceBytes=t.slice=t.size=t.serializeTransaction=t.serializeAccessList=void 0;var o=n(8270);Object.defineProperty(t,"CircularReferenceError",{enumerable:!0,get:function(){return o.CircularReferenceError}}),Object.defineProperty(t,"InvalidAbiParameterError",{enumerable:!0,get:function(){return o.InvalidAbiParameterError}}),Object.defineProperty(t,"InvalidAbiParametersError",{enumerable:!0,get:function(){return o.InvalidAbiParametersError}}),Object.defineProperty(t,"InvalidAbiItemError",{enumerable:!0,get:function(){return o.InvalidAbiItemError}}),Object.defineProperty(t,"InvalidAbiTypeParameterError",{enumerable:!0,get:function(){return o.InvalidAbiTypeParameterError}}),Object.defineProperty(t,"InvalidFunctionModifierError",{enumerable:!0,get:function(){return o.InvalidFunctionModifierError}}),Object.defineProperty(t,"InvalidModifierError",{enumerable:!0,get:function(){return o.InvalidModifierError}}),Object.defineProperty(t,"InvalidParameterError",{enumerable:!0,get:function(){return o.InvalidParameterError}}),Object.defineProperty(t,"InvalidParenthesisError",{enumerable:!0,get:function(){return o.InvalidParenthesisError}}),Object.defineProperty(t,"InvalidSignatureError",{enumerable:!0,get:function(){return o.InvalidSignatureError}}),Object.defineProperty(t,"InvalidStructSignatureError",{enumerable:!0,get:function(){return o.InvalidStructSignatureError}}),Object.defineProperty(t,"SolidityProtectedKeywordError",{enumerable:!0,get:function(){return o.SolidityProtectedKeywordError}}),Object.defineProperty(t,"UnknownTypeError",{enumerable:!0,get:function(){return o.UnknownTypeError}}),Object.defineProperty(t,"UnknownSignatureError",{enumerable:!0,get:function(){return o.UnknownSignatureError}}),Object.defineProperty(t,"parseAbi",{enumerable:!0,get:function(){return o.parseAbi}}),Object.defineProperty(t,"parseAbiItem",{enumerable:!0,get:function(){return o.parseAbiItem}}),Object.defineProperty(t,"parseAbiParameter",{enumerable:!0,get:function(){return o.parseAbiParameter}}),Object.defineProperty(t,"parseAbiParameters",{enumerable:!0,get:function(){return o.parseAbiParameters}});var i=n(61519);Object.defineProperty(t,"getContract",{enumerable:!0,get:function(){return i.getContract}});var s=n(39189);Object.defineProperty(t,"createClient",{enumerable:!0,get:function(){return s.createClient}});var c=n(59341);Object.defineProperty(t,"custom",{enumerable:!0,get:function(){return c.custom}});var l=n(54229);Object.defineProperty(t,"fallback",{enumerable:!0,get:function(){return l.fallback}});var u=n(37517);Object.defineProperty(t,"http",{enumerable:!0,get:function(){return u.http}});var d=n(13527);Object.defineProperty(t,"createPublicClient",{enumerable:!0,get:function(){return d.createPublicClient}});var p=n(65829);Object.defineProperty(t,"createTestClient",{enumerable:!0,get:function(){return p.createTestClient}});var m=n(28454);Object.defineProperty(t,"publicActions",{enumerable:!0,get:function(){return m.publicActions}});var b=n(41391);Object.defineProperty(t,"testActions",{enumerable:!0,get:function(){return b.testActions}});var g=n(92693);Object.defineProperty(t,"walletActions",{enumerable:!0,get:function(){return g.w
68alletActions}});var y=n(20025);Object.defineProperty(t,"createTransport",{enumerable:!0,get:function(){return y.createTransport}});var v=n(68982);Object.defineProperty(t,"createWalletClient",{enumerable:!0,get:function(){return v.createWalletClient}});var E=n(51562);Object.defineProperty(t,"webSocket",{enumerable:!0,get:function(){return E.webSocket}});var x=n(55906);Object.defineProperty(t,"multicall3Abi",{enumerable:!0,get:function(){return x.multicall3Abi}});var P=n(16738);Object.defineProperty(t,"zeroAddress",{enumerable:!0,get:function(){return P.zeroAddress}});var _=n(71035);Object.defineProperty(t,"etherUnits",{enumerable:!0,get:function(){return _.etherUnits}}),Object.defineProperty(t,"gweiUnits",{enumerable:!0,get:function(){return _.gweiUnits}}),Object.defineProperty(t,"weiUnits",{enumerable:!0,get:function(){return _.weiUnits}});var I=n(14940);Object.defineProperty(t,"maxInt8",{enumerable:!0,get:function(){return I.maxInt8}}),Object.defineProperty(t,"maxInt16",{enumerable:!0,get:function(){return I.maxInt16}}),Object.defineProperty(t,"maxInt24",{enumerable:!0,get:function(){return I.maxInt24}}),Object.defineProperty(t,"maxInt32",{enumerable:!0,get:function(){return I.maxInt32}}),Object.defineProperty(t,"maxInt40",{enumerable:!0,get:function(){return I.maxInt40}}),Object.defineProperty(t,"maxInt48",{enumerable:!0,get:function(){return I.maxInt48}}),Object.defineProperty(t,"maxInt56",{enumerable:!0,get:function(){return I.maxInt56}}),Object.defineProperty(t,"maxInt64",{enumerable:!0,get:function(){return I.maxInt64}}),Object.defineProperty(t,"maxInt72",{enumerable:!0,get:function(){return I.maxInt72}}),Object.defineProperty(t,"maxInt80",{enumerable:!0,get:function(){return I.maxInt80}}),Object.defineProperty(t,"maxInt88",{enumerable:!0,get:function(){return I.maxInt88}}),Object.defineProperty(t,"maxInt96",{enumerable:!0,get:function(){return I.maxInt96}}),Object.defineProperty(t,"maxInt104",{enumerable:!0,get:function(){return I.maxInt104}}),Object.defineProperty(t,"maxInt112",{enumerable:!0,get:function(){return I.maxInt112}}),Object.defineProperty(t,"maxInt120",{enumerable:!0,get:function(){return I.maxInt120}}),Object.defineProperty(t,"maxInt128",{enumerable:!0,get:function(){return I.maxInt128}}),Object.defineProperty(t,"maxInt136",{enumerable:!0,get:function(){return I.maxInt136}}),Object.defineProperty(t,"maxInt144",{enumerable:!0,get:function(){return I.maxInt144}}),Object.defineProperty(t,"maxInt152",{enumerable:!0,get:function(){return I.maxInt152}}),Object.defineProperty(t,"maxInt160",{enumerable:!0,get:function(){return I.maxInt160}}),Object.defineProperty(t,"maxInt168",{enumerable:!0,get:function(){return I.maxInt168}}),Object.defineProperty(t,"maxInt176",{enumerable:!0,get:function(){return I.maxInt176}}),Object.defineProperty(t,"maxInt184",{enumerable:!0,get:function(){return I.maxInt184}}),Object.defineProperty(t,"maxInt192",{enumerable:!0,get:function(){return I.maxInt192}}),Object.defineProperty(t,"maxInt200",{enumerable:!0,get:function(){return I.maxInt200}}),Object.defineProperty(t,"maxInt208",{enumerable:!0,get:function(){return I.maxInt208}}),Object.defineProperty(t,"maxInt216",{enumerable:!0,get:function(){return I.maxInt216}}),Object.defineProperty(t,"maxInt224",{enumerable:!0,get:function(){return I.maxInt224}}),Object.defineProperty(t,"maxInt232",{enumerable:!0,get:function(){return I.maxInt232}}),Object.defineProperty(t,"maxInt240",{enumerable:!0,get:function(){return I.maxInt240}}),Object.defineProperty(t,"maxInt248",{enumerable:!0,get:function(){return I.maxInt248}}),Object.defineProperty(t,"maxInt256",{enumerable:!0,get:function(){return I.maxInt256}}),Object.defineProperty(t,"maxUint8",{enumerable:!0,get:function(){return I.maxUint8}}),Object.defineProperty(t,"maxUint16",{enumerable:!0,get:function(){return I.maxUint16}}),Object.defineProperty(t,"maxUint24",{enumerable:!0,get:function(){return I.maxUint24}}),Object.defineProperty(t,"maxUint32",{enumerable:!0,get:function(){return I.maxUint32}}),Object.defineProperty(t,"maxUint40",{enumerable:!0,get:function(){return I.maxUint40}}),Object.defineProperty(t,"maxUint48",{enumerable:!0,get:function(){return I.maxUint48}}),Object.defineProperty(t,"maxUint56",{enumerable:!0,get:function(){return I.maxUint56}}),Object.defineProperty(t,"maxUint64",{enumerable:!0,get:function(){return I.maxUint64}}),Object.defineProperty(t,"maxUint72",{enumerable:!0,get:function(){return I.maxUint72}}),Object.defineProperty(t,"maxUint80",{enumerable:!0,get:function(){return I.maxUint80}}),Object.defineProperty(t,"maxUint88",{enumerable:!0,get:function(){return I.maxUint88}}),Object.defineProperty(t,"maxUint96",{enumerable:!0,get:function(){return I.maxUint96}}),Object.defineProperty(t,"maxUint104",{enumerable:!0,get:function(){return I.maxUint104}}),Object.defineProperty(t,"maxUint112",{enumerable:!0,get:function(){return I.maxUint112}}),Object.defineProperty(t,"maxUint120",{enumerable:!0,get:function(){return I.maxUint120}}),Object.defineProperty(t,"maxUint128",{enumerable:!0,get:function(){return I.maxUint128}}),Object.defineProperty(t,"maxUint136",{enumerable:!0,get:function(){return I.maxUint136}}),Object.defineProperty(t,"maxUint144",{enumerable:!0,get:function(){return I.maxUint144}}),Object.defineProperty(t,"maxUint152",{enumerable:!0,get:function(){return I.maxUint152}}),Object.defineProperty(t,"maxUint160",{enumerable:!0,get:function(){return I.maxUint160}}),Object.defineProperty(t,"maxUint168",{enumerable:!0,get:function(){return I.maxUint168}}),Object.defineProperty(t,"maxUint176",{enumerable:!0,get:function(){return I.maxUint176}}),Object.defineProperty(t,"maxUint184",{enumerable:!0,get:function(){return I.maxUint184}}),Object.defineProperty(t,"maxUint192",{enumerable:!0,get:function(){return I.maxUint192}}),Object.defineProperty(t,"maxUint200",{enumerable:!0,get:function(){return I.maxUint200}}),Object.defineProperty(t,"maxUint208",{enumerable:!0,get:function(){return I.maxUint208}}),Object.defineProperty(t,"maxUint216",{enumerable:!0,get:function(){return I.maxUint216}}),Object.defineProperty(t,"maxUint224",{enumerable:!0,get:function(){return I.maxUint224}}),Object.defineProperty(t,"maxUint232",{enumerable:!0,get:function(){return I.maxUint232}}),Object.defineProperty(t,"maxUint240",{enumerable:!0,get:function(){return I.maxUint240}}),Object.defineProperty(t,"maxUint248",{enumerable:!0,get:function(){return I.maxUint248}}),Object.defineProperty(t,"maxUint256",{enumerable:!0,get:function(){return I.maxUint256}}),Object.defineProperty(t,"minInt8",{enumerable:!0,get:function(){return I.minInt8}}),Object.defineProperty(t,"minInt16",{enumerable:!0,get:function(){return I.minInt16}}),Object.defineProperty(t,"minInt24",{enumerable:!0,get:function(){return I.minInt24}}),Object.defineProperty(t,"minInt32",{enumerable:!0,get:function(){return I.minInt32}}),Object.defineProperty(t,"minInt40",{enumerable:!0,get:function(){return I.minInt40}}),Object.defineProperty(t,"minInt48",{enumerable:!0,get:function(){return I.minInt48}}),Object.defineProperty(t,"minInt56",{enumerable:!0,get:function(){return I.minInt56}}),Object.defineProperty(t,"minInt64",{enumerable:!0,get:function(){return I.minInt64}}),Object.defineProperty(t,"minInt72",{enumerable:!0,get:function(){return I.minInt72}}),Object.defineProperty(t,"minInt80",{enumerable:!0,get:function(){return I.minInt80}}),Object.defineProperty(t,"minInt88",{enumerable:!0,get:function(){return I.minInt88}}),Object.defineProperty(t,"minInt96",{enumerable:!0,get:function(){return I.minInt96}}),Object.defineProperty(t,"minInt104",{enumerable:!0,get:function(){return I.minInt104}}),Object.defineProperty(t,"minInt112",{enumerable:!0,get:function(){return I.minInt112}}),Object.defineProperty(t,"minInt120",{enumerable:!0,get:function(){return I.minInt120}}),Object.defineProperty(t,"minInt128",{enumerable:!0,get:function(){return I.minInt128}}),Object.defineProperty(t,"minInt136",{enumerable:!0,get:function(){return I.minInt136}}),Object.defineProperty(t,"minInt144",{enumerable:!0,get:function(){return I.minInt144}}),Object.defineProperty(t,"minInt152",{enumerable:!0,get:function(){return I.minInt152}}),Object.defineProperty(t,"minInt160",{enumerable:!0,get:function(){return I.minInt160}}),Object.defineProperty(t,"minInt168",{enumerable:!0,get:function(){return I.minInt168}}),Object.defineProperty(t,"minInt176",{enumerable:!0,get:function(){return I.minInt176}}),Object.defineProperty(t,"minInt184",{enumerable:!0,get:function(){return I.minInt184}}),Object.defineProperty(t,"minInt192",{enumerable:!0,get:function(){return I.minInt192}}),Object.defineProperty(t,"minInt200",{enumerable:!0,get:function(){return I.minInt200}}),Object.defineProperty(t,"minInt208",{enumerable:!0,get:function(){return I.minInt208}}),Object.defineProperty(t,"minInt216",{enumerable:!0,get:function(){return I.minInt216}}),Object.defineProperty(t,"minInt224",{enumerable:!0,get:function(){return I.minInt224}}),Object.defineProperty(t,"minInt232",{enumerable:!0,get:function(){return I.minInt232}}),Object.defineProperty(t,"minInt240",{enumerable:!0,get:function(){return I.minInt240}}),Object.defineProperty(t,"minInt248",{enumerable:!0,get:function(){return I.minInt248}}),Object.defineProperty(t,"minInt256",{enumerable:!0,get:function(){return I.minInt256}});var j=n(83446);Object.defineProperty(t,"zeroHash",{enumerable:!0,get:function(){return j.zeroHash}});var R=n(76770);Object.defineProperty(t,"presignMessagePrefix",{enumerable:!0,get:function(){return R.presignMessagePrefix}});var M=n(82521);Object.defineProperty(t,"AbiConstructorNotFoundError",{enumerable:!0,get:function(){return M.AbiConstructorNotFoundError}}),Object.defineProperty(t,"AbiConstructorParamsNotFoundError",{enumerable:!0,get:function(){return M.AbiConstructorParamsNotFoundError}}),Object.defineProperty(t,"AbiDecodingDataSizeInvalidError",{enumerable:!0,get:function(){return M.AbiDecodingDataSizeInvalidError}}),Object.defineProperty(t,"AbiDecodingDataSizeTooSmallError",{enumerable:!0,get:function(){return M.AbiDecodingDataSizeTooSmallError}}),Object.defineProperty(t,"AbiDecodingZeroDataError",{enumerable:!0,get:function(){return M.AbiDecodingZeroDataError}}
68),Object.defineProperty(t,"AbiEncodingArrayLengthMismatchError",{enumerable:!0,get:function(){return M.AbiEncodingArrayLengthMismatchError}}),Object.defineProperty(t,"AbiEncodingLengthMismatchError",{enumerable:!0,get:function(){return M.AbiEncodingLengthMismatchError}}),Object.defineProperty(t,"AbiEncodingBytesSizeMismatchError",{enumerable:!0,get:function(){return M.AbiEncodingBytesSizeMismatchError}}),Object.defineProperty(t,"AbiErrorInputsNotFoundError",{enumerable:!0,get:function(){return M.AbiErrorInputsNotFoundError}}),Object.defineProperty(t,"AbiErrorNotFoundError",{enumerable:!0,get:function(){return M.AbiErrorNotFoundError}}),Object.defineProperty(t,"AbiErrorSignatureNotFoundError",{enumerable:!0,get:function(){return M.AbiErrorSignatureNotFoundError}}),Object.defineProperty(t,"AbiEventNotFoundError",{enumerable:!0,get:function(){return M.AbiEventNotFoundError}}),Object.defineProperty(t,"AbiEventSignatureEmptyTopicsError",{enumerable:!0,get:function(){return M.AbiEventSignatureEmptyTopicsError}}),Object.defineProperty(t,"AbiEventSignatureNotFoundError",{enumerable:!0,get:function(){return M.AbiEventSignatureNotFoundError}}),Object.defineProperty(t,"AbiFunctionNotFoundError",{enumerable:!0,get:function(){return M.AbiFunctionNotFoundError}}),Object.defineProperty(t,"AbiFunctionOutputsNotFoundError",{enumerable:!0,get:function(){return M.AbiFunctionOutputsNotFoundError}}),Object.defineProperty(t,"AbiFunctionSignatureNotFoundError",{enumerable:!0,get:function(){return M.AbiFunctionSignatureNotFoundError}}),Object.defineProperty(t,"BytesSizeMismatchError",{enumerable:!0,get:function(){return M.BytesSizeMismatchError}}),Object.defineProperty(t,"DecodeLogDataMismatch",{enumerable:!0,get:function(){return M.DecodeLogDataMismatch}}),Object.defineProperty(t,"DecodeLogTopicsMismatch",{enumerable:!0,get:function(){return M.DecodeLogTopicsMismatch}}),Object.defineProperty(t,"InvalidAbiDecodingTypeError",{enumerable:!0,get:function(){return M.InvalidAbiDecodingTypeError}}),Object.defineProperty(t,"InvalidAbiEncodingTypeError",{enumerable:!0,get:function(){return M.InvalidAbiEncodingTypeError}}),Object.defineProperty(t,"InvalidArrayError",{enumerable:!0,get:function(){return M.InvalidArrayError}}),Object.defineProperty(t,"InvalidDefinitionTypeError",{enumerable:!0,get:function(){return M.InvalidDefinitionTypeError}}),Object.defineProperty(t,"UnsupportedPackedAbiType",{enumerable:!0,get:function(){return M.UnsupportedPackedAbiType}});var F=n(78498);Object.defineProperty(t,"BaseError",{enumerable:!0,get:function(){return F.BaseError}});var q=n(48962);Object.defineProperty(t,"BlockNotFoundError",{enumerable:!0,get:function(){return q.BlockNotFoundError}});var H=n(91349);Object.defineProperty(t,"CallExecutionError",{enumerable:!0,get:function(){return H.CallExecutionError}}),Object.defineProperty(t,"ContractFunctionExecutionError",{enumerable:!0,get:function(){return H.ContractFunctionExecutionError}}),Object.defineProperty(t,"ContractFunctionRevertedError",{enumerable:!0,get:function(){return H.ContractFunctionRevertedError}}),Object.defineProperty(t,"ContractFunctionZeroDataError",{enumerable:!0,get:function(){return H.ContractFunctionZeroDataError}}),Object.defineProperty(t,"RawContractError",{enumerable:!0,get:function(){return H.RawContractError}});var z=n(30375);Object.defineProperty(t,"BaseFeeScalarError",{enumerable:!0,get:function(){return z.BaseFeeScalarError}}),Object.defineProperty(t,"Eip1559FeesNotSupportedError",{enumerable:!0,get:function(){return z.Eip1559FeesNotSupportedError}}),Object.defineProperty(t,"MaxFeePerGasTooLowError",{enumerable:!0,get:function(){return z.MaxFeePerGasTooLowError}});var W=n(28516);Object.defineProperty(t,"ChainDisconnectedError",{enumerable:!0,get:function(){return W.ChainDisconnectedError}}),Object.defineProperty(t,"InternalRpcError",{enumerable:!0,get:function(){return W.InternalRpcError}}),Object.defineProperty(t,"InvalidInputRpcError",{enumerable:!0,get:function(){return W.InvalidInputRpcError}}),Object.defineProperty(t,"InvalidParamsRpcError",{enumerable:!0,get:function(){return W.InvalidParamsRpcError}}),Object.defineProperty(t,"InvalidRequestRpcError",{enumerable:!0,get:function(){return W.InvalidRequestRpcError}}),Object.defineProperty(t,"JsonRpcVersionUnsupportedError",{enumerable:!0,get:function(){return W.JsonRpcVersionUnsupportedError}}),Object.defineProperty(t,"LimitExceededRpcError",{enumerable:!0,get:function(){return W.LimitExceededRpcError}}),Object.defineProperty(t,"MethodNotFoundRpcError",{enumerable:!0,get:function(){return W.MethodNotFoundRpcError}}),Object.defineProperty(t,"MethodNotSupportedRpcError",{enumerable:!0,get:function(){return W.MethodNotSupportedRpcError}}),Object.defineProperty(t,"ParseRpcError",{enumerable:!0,get:function(){return W.ParseRpcError}}),Object.defineProperty(t,"ProviderDisconnectedError",{enumerable:!0,get:function(){return W.ProviderDisconnectedError}}),Object.defineProperty(t,"ProviderRpcError",{enumerable:!0,get:function(){return W.ProviderRpcError}}),Object.defineProperty(t,"ResourceNotFoundRpcError",{enumerable:!0,get:function(){return W.ResourceNotFoundRpcError}}),Object.defineProperty(t,"ResourceUnavailableRpcError",{enumerable:!0,get:function(){return W.ResourceUnavailableRpcError}}),Object.defineProperty(t,"RpcError",{enumerable:!0,get:function(){return W.RpcError}}),Object.defineProperty(t,"SwitchChainError",{enumerable:!0,get:function(){return W.SwitchChainError}}),Object.defineProperty(t,"TransactionRejectedRpcError",{enumerable:!0,get:function(){return W.TransactionRejectedRpcError}}),Object.defineProperty(t,"UnauthorizedProviderError",{enumerable:!0,get:function(){return W.UnauthorizedProviderError}}),Object.defineProperty(t,"UnknownRpcError",{enumerable:!0,get:function(){return W.UnknownRpcError}}),Object.defineProperty(t,"UnsupportedProviderMethodError",{enumerable:!0,get:function(){return W.UnsupportedProviderMethodError}}),Object.defineProperty(t,"UserRejectedRequestError",{enumerable:!0,get:function(){return W.UserRejectedRequestError}});var K=n(99174);Object.defineProperty(t,"ChainDoesNotSupportContract",{enumerable:!0,get:function(){return K.ChainDoesNotSupportContract}}),Object.defineProperty(t,"ChainMismatchError",{enumerable:!0,get:function(){return K.ChainMismatchError}}),Object.defineProperty(t,"ChainNotFoundError",{enumerable:!0,get:function(){return K.ChainNotFoundError}}),Object.defineProperty(t,"ClientChainNotConfiguredError",{enumerable:!0,get:function(){return K.ClientChainNotConfiguredError}}),Object.defineProperty(t,"InvalidChainIdError",{enumerable:!0,get:function(){return K.InvalidChainIdError}});var Q=n(62608);Object.defineProperty(t,"DataLengthTooLongError",{enumerable:!0,get:function(){return Q.DataLengthTooLongError}}),Object.defineProperty(t,"DataLengthTooShortError",{enumerable:!0,get:function(){return Q.DataLengthTooShortError}}),Object.defineProperty(t,"InvalidBytesBooleanError",{enumerable:!0,get:function(){return Q.InvalidBytesBooleanError}}),Object.defineProperty(t,"IntegerOutOfRangeError",{enumerable:!0,get:function(){return Q.IntegerOutOfRangeError}}),Object.defineProperty(t,"InvalidHexBooleanError",{enumerable:!0,get:function(){return Q.InvalidHexBooleanError}}),Object.defineProperty(t,"InvalidHexValueError",{enumerable:!0,get:function(){return Q.InvalidHexValueError}}),Object.defineProperty(t,"OffsetOutOfBoundsError",{enumerable:!0,get:function(){return Q.OffsetOutOfBoundsError}}),Object.defineProperty(t,"SizeOverflowError",{enumerable:!0,get:function(){return Q.SizeOverflowError}});var Z=n(8370);Object.defineProperty(t,"EnsAvatarUriResolutionError",{enumerable:!0,get:function(){return Z.EnsAvatarUriResolutionError}}),Object.defineProperty(t,"EnsAvatarInvalidNftUriError",{enumerable:!0,get:function(){return Z.EnsAvatarInvalidNftUriError}}),Object.defineProperty(t,"EnsAvatarUnsupportedNamespaceError",{enumerable:!0,get:function(){return Z.EnsAvatarUnsupportedNamespaceError}});var X=n(26265);Object.defineProperty(t,"EstimateGasExecutionError",{enumerable:!0,get:function(){return X.EstimateGasExecutionError}});var Y=n(48016);Object.defineProperty(t,"ExecutionRevertedError",{enumerable:!0,get:function(){return Y.ExecutionRevertedError}}),Object.defineProperty(t,"FeeCapTooHighError",{enumerable:!0,get:function(){return Y.FeeCapTooHighError}}),Object.defineProperty(t,"FeeCapTooLowError",{enumerable:!0,get:function(){return Y.FeeCapTooLowError}}),Object.defineProperty(t,"InsufficientFundsError",{enumerable:!0,get:function(){return Y.InsufficientFundsError}}),Object.defineProperty(t,"IntrinsicGasTooHighError",{enumerable:!0,get:function(){return Y.IntrinsicGasTooHighError}}),Object.defineProperty(t,"IntrinsicGasTooLowError",{enumerable:!0,get:function(){return Y.IntrinsicGasTooLowError}}),Object.defineProperty(t,"NonceMaxValueError",{enumerable:!0,get:function(){return Y.NonceMaxValueError}}),Object.defineProperty(t,"NonceTooHighError",{enumerable:!0,get:function(){return Y.NonceTooHighError}}),Object.defineProperty(t,"NonceTooLowError",{enumerable:!0,get:function(){return Y.NonceTooLowError}}),Object.defineProperty(t,"TipAboveFeeCapError",{enumerable:!0,get:function(){return Y.TipAboveFeeCapError}}),Object.defineProperty(t,"TransactionTypeNotSupportedError",{enumerable:!0,get:function(){return Y.TransactionTypeNotSupportedError}}),Object.defineProperty(t,"UnknownNodeError",{enumerable:!0,get:function(){return Y.UnknownNodeError}});var J=n(84166);Object.defineProperty(t,"FilterTypeNotSupportedError",{enumerable:!0,get:function(){return J.FilterTypeNotSupportedError}});var et=n(86617);Object.defineProperty(t,"HttpRequestError",{enumerable:!0,get:function(){return et.HttpRequestError}}),Object.defineProperty(t,"RpcRequestError",{enumerable:!0,get:function(){return et.RpcRequestError}}),Object.defineProperty(t,"TimeoutError",{enumerable:!0,get:function(){return et.TimeoutError}}),Object.defineProperty(t,"WebSocketRequestError",{enumerable:!0,get:function(){return et.WebSocketRequestError}});var eo=n(61235);Object.defineProperty(t,"InvalidAddressError",{enumerable:!0,get:function(){return eo.InvalidAddressError}});var ea=n(33841);Object.defineProperty(t,"FeeConflictError",{enumerable:!0,get:function(){return ea.FeeConflictError}}),Object.defineProperty(t,"InvalidLegacyVError",{enumerable:!0,get:function(){return ea.InvalidLegacyVError}}),Object.defineProperty(t,"InvalidSerializableTransactionError",{enumerable:!0,get:function(){return ea.InvalidSerializableTransactionError}}),Object.defineProperty(t,"InvalidSerializedTransactionError",{enumerable:!0,get:function(){return ea.InvalidSerializedTransactionError}}),Object.defineProperty(t,"InvalidSerializedTransactionTypeError",{enumerable:!0,get:function(){return ea.InvalidSerializedTransactionTypeError}}),Object.defineProperty(t,"InvalidStorageKeySizeError",{enumerable:!0,get:function(){return ea.InvalidStorageKeySizeError}}),Object.defineProperty(t,"TransactionExecutionError",{enumerable:!0,get:function(){return ea.TransactionExecutionError}}),Object.defineProperty(t,"TransactionNotFoundError",{enumerable:!0,get:function(){return ea.TransactionNotFoundError}}),Object.defineProperty(t,"TransactionReceiptNotFoundError",{enumerable:!0,get:function(){return ea.TransactionReceiptNotFoundError}}),Object.defineProperty(t,"WaitForTransactionReceiptTimeoutError",{enumerable:!0,get:function(){return ea.WaitForTransactionReceiptTimeoutError}});var ei=n(50562);Object.defineProperty(t,"SizeExceedsPaddingSizeError",{enumerable:!0,get:function(){return ei.SizeExceedsPaddingSizeError}}),Object.defineProperty(t,"SliceOffsetOutOfBoundsError",{enumerable:!0,get:function(){return ei.SliceOffsetOutOfBoundsError}});var es=n(86550);Object.defineProperty(t,"UrlRequiredError",{enumerable:!0,get:function(){return es.UrlRequiredError}});var ec=n(43337);Object.defineProperty(t,"labelhash",{enumerable:!0,get:function(){return ec.labelhash}});var el=n(23412);Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return el.namehash}});var eu=n(5729);Object.defineProperty(t,"defineBlock",{enumerable:!0,get:function(){return eu.defineBlock}}),Object.defineProperty(t,"formatBlock",{enumerable:!0,get:function(){return eu.formatBlock}});var ed=n(8875);Object.defineProperty(t,"formatLog",{enumerable:!0,get:function(){return ed.formatLog}});var ef=n(59530);Object.defineProperty(t,"decodeAbiParameters",{enumerable:!0,get:function(){return ef.decodeAbiParameters}});var ep=n(6717);Object.defineProperty(t,"decodeDeployData",{enumerable:!0,get:function(){return ep.decodeDeployData}});var eh=n(37113);Object.defineProperty(t,"decodeErrorResult",{enumerable:!0,get:function(){return eh.decodeErrorResult}});var em=n(35813);Object.defineProperty(t,"decodeEventLog",{enumerable:!0,get:function(){return em.decodeEventLog}});var eb=n(20587);Object.defineProperty(t,"decodeFunctionData",{enumerable:!0,get:function(){return eb.decodeFunctionData}});var eg=n(90181);Object.defineProperty(t,"decodeFunctionResult",{enumerable:!0,get:function(){return eg.decodeFunctionResult}});var ey=n(82121);Object.defineProperty(t,"encodeAbiParameters",{enumerable:!0,get:function(){return ey.encodeAbiParameters}});var ev=n(94335);Object.defineProperty(t,"encodeDeployData",{enumerable:!0,get:function(){return ev.encodeDeployData}});var ew=n(62863);Object.defineProperty(t,"encodeErrorResult",{enumerable:!0,get:function(){return ew.encodeErrorResult}});var eE=n(3540);Object.defineProperty(t,"encodeEventTopics",{enumerable:!0,get:function(){return eE.encodeEventTopics}});var ex=n(48635);Object.defineProperty(t,"encodeFunctionData",{enumerable:!0,get:function(){return ex.encodeFunctionData}});var eC=n(63736);Object.defineProperty(t,"encodeFunctionResult",{enumerable:!0,get:function(){return eC.encodeFunctionResult}});var eP=n(93756);Object.defineProperty(t,"defineTransaction",{enumerable:!0,get:function(){return eP.defineTransaction}}),Object.defineProperty(t,"formatTransaction",{enumerable:!0,get:function(){return eP.formatTransaction}}),Object.defineProperty(t,"transactionType",{enumerable:!0,get:function(){return eP.transactionType}});var eT=n(10198);Object.defineProperty(t,"defineTransactionReceipt",{enumerable:!0,get:function(){return eT.defineTransactionReceipt}}),Object.defineProperty(t,"formatTransactionReceipt",{enumerable:!0,get:function(){return eT.formatTransactionReceipt}});var eA=n(77300);Object.defineProperty(t,"defineTransactionRequest",{enumerable:!0,get:function(){return eA.defineTransactionRequest}}),Object.defineProperty(t,"formatTransactionRequest",{enumerable:!0,get:function(){return eA.formatTransactionRequest}}),Object.defineProperty(t,"rpcTransactionType",{enumerable:!0,get:function(){return eA.rpcTransactionType}});var eS=n(68340);Object.defineProperty(t,"getAbiItem",{enumerable:!0,get:function(){return eS.getAbiItem}});var e_=n(63965);Object.defineProperty(t,"getContractAddress",{enumerable:!0,get:function(){return e_.getContractAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return e_.getCreate2Address}}),Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return e_.getCreateAddress}});var eI=n(67076);Object.defineProperty(t,"getSerializedTransactionType",{enumerable:!0,get:function(){return eI.getSerializedTransactionType}});var ek=n(71040);Object.defineProperty(t,"getTransactionType",{enumerable:!0,get:function(){return ek.getTransactionType}});var eO=n(59454);Object.defineProperty(t,"hashDomain",{enumerable:!0,get:function(){return eO.hashDomain}}),Object.defineProperty(t,"hashTypedData",{enumerable:!0,get:function(){return eO.hashTypedData}
68});var ej=n(80381);Object.defineProperty(t,"compactSignatureToSignature",{enumerable:!0,get:function(){return ej.compactSignatureToSignature}});var eB=n(5922);Object.defineProperty(t,"hexToCompactSignature",{enumerable:!0,get:function(){return eB.hexToCompactSignature}});var eD=n(21286);Object.defineProperty(t,"hexToSignature",{enumerable:!0,get:function(){return eD.hexToSignature}});var eR=n(21116);Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return eR.recoverAddress}});var eM=n(62965);Object.defineProperty(t,"recoverMessageAddress",{enumerable:!0,get:function(){return eM.recoverMessageAddress}});var eN=n(41909);Object.defineProperty(t,"recoverPublicKey",{enumerable:!0,get:function(){return eN.recoverPublicKey}});var eF=n(10914);Object.defineProperty(t,"recoverTypedDataAddress",{enumerable:!0,get:function(){return eF.recoverTypedDataAddress}});var eU=n(33743);Object.defineProperty(t,"signatureToCompactSignature",{enumerable:!0,get:function(){return eU.signatureToCompactSignature}});var eL=n(24341);Object.defineProperty(t,"compactSignatureToHex",{enumerable:!0,get:function(){return eL.compactSignatureToHex}});var e$=n(44911);Object.defineProperty(t,"signatureToHex",{enumerable:!0,get:function(){return e$.signatureToHex}});var eq=n(88377);Object.defineProperty(t,"bytesToRlp",{enumerable:!0,get:function(){return eq.bytesToRlp}}),Object.defineProperty(t,"hexToRlp",{enumerable:!0,get:function(){return eq.hexToRlp}}),Object.defineProperty(t,"toRlp",{enumerable:!0,get:function(){return eq.toRlp}});var eH=n(49757);Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return eH.verifyMessage}});var ez=n(84182);Object.defineProperty(t,"verifyTypedData",{enumerable:!0,get:function(){return ez.verifyTypedData}});var eW=n(80525);Object.defineProperty(t,"assertRequest",{enumerable:!0,get:function(){return eW.assertRequest}});var eG=n(67539);Object.defineProperty(t,"assertTransactionEIP1559",{enumerable:!0,get:function(){return eG.assertTransactionEIP1559}}),Object.defineProperty(t,"assertTransactionEIP2930",{enumerable:!0,get:function(){return eG.assertTransactionEIP2930}}),Object.defineProperty(t,"assertTransactionLegacy",{enumerable:!0,get:function(){return eG.assertTransactionLegacy}});var eK=n(37281);Object.defineProperty(t,"boolToBytes",{enumerable:!0,get:function(){return eK.boolToBytes}}),Object.defineProperty(t,"hexToBytes",{enumerable:!0,get:function(){return eK.hexToBytes}}),Object.defineProperty(t,"numberToBytes",{enumerable:!0,get:function(){return eK.numberToBytes}}),Object.defineProperty(t,"stringToBytes",{enumerable:!0,get:function(){return eK.stringToBytes}}),Object.defineProperty(t,"toBytes",{enumerable:!0,get:function(){return eK.toBytes}});var eV=n(56945);Object.defineProperty(t,"boolToHex",{enumerable:!0,get:function(){return eV.boolToHex}}),Object.defineProperty(t,"bytesToHex",{enumerable:!0,get:function(){return eV.bytesToHex}}),Object.defineProperty(t,"numberToHex",{enumerable:!0,get:function(){return eV.numberToHex}}),Object.defineProperty(t,"stringToHex",{enumerable:!0,get:function(){return eV.stringToHex}}),Object.defineProperty(t,"toHex",{enumerable:!0,get:function(){return eV.toHex}});var eQ=n(70185);Object.defineProperty(t,"bytesToBigInt",{enumerable:!0,get:function(){return eQ.bytesToBigInt}}),Object.defineProperty(t,"bytesToBigint",{enumerable:!0,get:function(){return eQ.bytesToBigInt}}),Object.defineProperty(t,"bytesToBool",{enumerable:!0,get:function(){return eQ.bytesToBool}}),Object.defineProperty(t,"bytesToNumber",{enumerable:!0,get:function(){return eQ.bytesToNumber}}),Object.defineProperty(t,"bytesToString",{enumerable:!0,get:function(){return eQ.bytesToString}}),Object.defineProperty(t,"fromBytes",{enumerable:!0,get:function(){return eQ.fromBytes}});var eZ=n(39978);Object.defineProperty(t,"ccipFetch",{enumerable:!0,get:function(){return eZ.ccipFetch}}),Object.defineProperty(t,"offchainLookup",{enumerable:!0,get:function(){return eZ.offchainLookup}}),Object.defineProperty(t,"offchainLookupAbiItem",{enumerable:!0,get:function(){return eZ.offchainLookupAbiItem}}),Object.defineProperty(t,"offchainLookupSignature",{enumerable:!0,get:function(){return eZ.offchainLookupSignature}});var eX=n(22913);Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return eX.concat}}),Object.defineProperty(t,"concatBytes",{enumerable:!0,get:function(){return eX.concatBytes}}),Object.defineProperty(t,"concatHex",{enumerable:!0,get:function(){return eX.concatHex}});var eY=n(54037);Object.defineProperty(t,"assertCurrentChain",{enumerable:!0,get:function(){return eY.assertCurrentChain}});var eJ=n(57401);Object.defineProperty(t,"defineChain",{enumerable:!0,get:function(){return eJ.defineChain}});var e0=n(80328);Object.defineProperty(t,"extractChain",{enumerable:!0,get:function(){return e0.extractChain}});var e1=n(27025);Object.defineProperty(t,"getChainContractAddress",{enumerable:!0,get:function(){return e1.getChainContractAddress}});var e2=n(8347);Object.defineProperty(t,"encodePacked",{enumerable:!0,get:function(){return e2.encodePacked}});var e6=n(74869);Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return e6.formatEther}});var e3=n(67505);Object.defineProperty(t,"formatGwei",{enumerable:!0,get:function(){return e3.formatGwei}});var e5=n(55934);Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return e5.formatUnits}});var e8=n(84008);Object.defineProperty(t,"fromHex",{enumerable:!0,get:function(){return e8.fromHex}}),Object.defineProperty(t,"hexToBigInt",{enumerable:!0,get:function(){return e8.hexToBigInt}}),Object.defineProperty(t,"hexToBool",{enumerable:!0,get:function(){return e8.hexToBool}}),Object.defineProperty(t,"hexToNumber",{enumerable:!0,get:function(){return e8.hexToNumber}}),Object.defineProperty(t,"hexToString",{enumerable:!0,get:function(){return e8.hexToString}});var e4=n(74500);Object.defineProperty(t,"fromRlp",{enumerable:!0,get:function(){return e4.fromRlp}});var e7=n(66830);Object.defineProperty(t,"checksumAddress",{enumerable:!0,get:function(){return e7.checksumAddress}}),Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return e7.getAddress}});var e9=n(59895);Object.defineProperty(t,"getContractError",{enumerable:!0,get:function(){return e9.getContractError}});var tt=n(22834);Object.defineProperty(t,"getEventSelector",{enumerable:!0,get:function(){return tt.getEventSelector}});var tn=n(49952);Object.defineProperty(t,"getEventSignature",{enumerable:!0,get:function(){return tn.getEventSignature}});var to=n(9684);Object.defineProperty(t,"getFunctionSelector",{enumerable:!0,get:function(){return to.getFunctionSelector}});var ta=n(14683);Object.defineProperty(t,"getFunctionSignature",{enumerable:!0,get:function(){return ta.getFunctionSignature}});var ti=n(91628);Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return ti.hashMessage}});var ts=n(9322);Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return ts.isAddress}});var tc=n(64924);Object.defineProperty(t,"isAddressEqual",{enumerable:!0,get:function(){return tc.isAddressEqual}});var tl=n(28360);Object.defineProperty(t,"isBytes",{enumerable:!0,get:function(){return tl.isBytes}});var tu=n(56870);Object.defineProperty(t,"isHash",{enumerable:!0,get:function(){return tu.isHash}});var td=n(29281);Object.defineProperty(t,"isHex",{enumerable:!0,get:function(){return td.isHex}});var tf=n(35841);Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return tf.keccak256}});var tp=n(84357);Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return tp.sha256}});var th=n(86558);Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return th.ripemd160}});var tm=n(51474);Object.defineProperty(t,"pad",{enumerable:!0,get:function(){return tm.pad}}),Object.defineProperty(t,"padBytes",{enumerable:!0,get:function(){return tm.padBytes}}),Object.defineProperty(t,"padHex",{enumerable:!0,get:function(){return tm.padHex}});var tb=n(70778);Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return tb.parseEther}});var tg=n(94041);Object.defineProperty(t,"parseGwei",{enumerable:!0,get:function(){return tg.parseGwei}});var ty=n(77889);Object.defineProperty(t,"parseTransaction",{enumerable:!0,get:function(){return ty.parseTransaction}});var tv=n(22856);Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return tv.parseUnits}});var tw=n(35108);Object.defineProperty(t,"serializeAccessList",{enumerable:!0,get:function(){return tw.serializeAccessList}});var tE=n(36957);Object.defineProperty(t,"serializeTransaction",{enumerable:!0,get:function(){return tE.serializeTransaction}});var tx=n(96711);Object.defineProperty(t,"size",{enumerable:!0,get:function(){return tx.size}});var tC=n(42013);Object.defineProperty(t,"slice",{enumerable:!0,get:function(){return tC.slice}}),Object.defineProperty(t,"sliceBytes",{enumerable:!0,get:function(){return tC.sliceBytes}}),Object.defineProperty(t,"sliceHex",{enumerable:!0,get:function(){return tC.sliceHex}});var tP=n(36774);Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return tP.stringify}});var tT=n(41691);Object.defineProperty(t,"trim",{enumerable:!0,get:function(){return tT.trim}});var tA=n(86931);Object.defineProperty(t,"validateTypedData",{enumerable:!0,get:function(){return tA.validateTypedData}
68}),Object.defineProperty(t,"domainSeparator",{enumerable:!0,get:function(){return tA.domainSeparator}}),Object.defineProperty(t,"getTypesForEIP712Domain",{enumerable:!0,get:function(){return tA.getTypesForEIP712Domain}})},59530:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeAbiParameters=void 0;let o=n(82521),i=n(66830),s=n(96711),c=n(42013),l=n(41691),u=n(84008),d=n(82121);function hasDynamicChild(e){let{type:t}=e;if("string"===t||"bytes"===t||t.endsWith("[]"))return!0;if("tuple"===t)return e.components?.some(hasDynamicChild);let n=(0,d.getArrayComponents)(e.type);return!!(n&&hasDynamicChild({...e,type:n[1]}))}t.decodeAbiParameters=function(e,t){if("0x"===t&&e.length>0)throw new o.AbiDecodingZeroDataError;if((0,s.size)(t)&&32>(0,s.size)(t))throw new o.AbiDecodingDataSizeTooSmallError({data:t,params:e,size:(0,s.size)(t)});return function({data:e,params:t}){let n=[],p=0;for(let m=0;m<t.length;m++){if(p>=(0,s.size)(e))throw new o.AbiDecodingDataSizeTooSmallError({data:e,params:t,size:(0,s.size)(e)});let b=t[m],{consumed:g,value:y}=function decodeParam({data:e,param:t,position:n}){let s=(0,d.getArrayComponents)(t.type);if(s){let[o,i]=s;return function(e,{param:t,length:n,position:o}){if(!n){let n=(0,u.hexToNumber)((0,c.slice)(e,o,o+32,{strict:!0})),i=(0,u.hexToNumber)((0,c.slice)(e,n,n+32,{strict:!0})),s=0,l=[];for(let o=0;o<i;++o){let o=decodeParam({data:(0,c.slice)(e,n+32),param:t,position:s});s+=o.consumed,l.push(o.value)}return{value:l,consumed:32}}if(hasDynamicChild(t)){let i=(0,d.getArrayComponents)(t.type),s=!i?.[0],l=0,p=[];for(let i=0;i<n;++i){let n=(0,u.hexToNumber)((0,c.slice)(e,o,o+32,{strict:!0})),d=decodeParam({data:(0,c.slice)(e,n),param:t,position:s?l:32*i});l+=d.consumed,p.push(d.value)}return{value:p,consumed:32}}let i=0,s=[];for(let c=0;c<n;++c){let n=decodeParam({data:e,param:t,position:o+i});i+=n.consumed,s.push(n.value)}return{value:s,consumed:i}}(e,{length:o,param:{...t,type:i},position:n})}if("tuple"===t.type)return function(e,{param:t,position:n}){let o=0===t.components.length||t.components.some(({name:e})=>!e),i=o?[]:{},s=0;if(hasDynamicChild(t)){let l=(0,u.hexToNumber)((0,c.slice)(e,n,n+32,{strict:!0}));for(let n=0;n<t.components.length;++n){let u=t.components[n],d=decodeParam({data:(0,c.slice)(e,l),param:u,position:s});s+=d.consumed,i[o?n:u?.name]=d.value}return{consumed:32,value:i}}for(let c=0;c<t.components.length;++c){let l=t.components[c],u=decodeParam({data:e,param:l,position:n+s});s+=u.consumed,i[o?c:l?.name]=u.value}return{consumed:s,value:i}}(e,{param:t,position:n});if("string"===t.type)return function(e,{position:t}){let n=(0,u.hexToNumber)((0,c.slice)(e,t,t+32,{strict:!0})),o=(0,u.hexToNumber)((0,c.slice)(e,n,n+32,{strict:!0}));if(0===o)return{consumed:32,value:""};let i=(0,u.hexToString)((0,l.trim)((0,c.slice)(e,n+32,n+32+o,{strict:!0})));return{consumed:32,value:i}}(e,{position:n});if(t.type.startsWith("bytes"))return function(e,{param:t,position:n}){let[o,i]=t.type.split("bytes");if(!i){let t=(0,u.hexToNumber)((0,c.slice)(e,n,n+32,{strict:!0})),o=(0,u.hexToNumber)((0,c.slice)(e,t,t+32,{strict:!0}));if(0===o)return{consumed:32,value:"0x"};let i=(0,c.slice)(e,t+32,t+32+o,{strict:!0});return{consumed:32,value:i}}let s=(0,c.slice)(e,n,n+parseInt(i),{strict:!0});return{consumed:32,value:s}}(e,{param:t,position:n});let p=(0,c.slice)(e,n,n+32,{strict:!0});if(t.type.startsWith("uint")||t.type.startsWith("int"))return function(e,{param:t}){let n=t.type.startsWith("int"),o=parseInt(t.type.split("int")[1]||"256");return{consumed:32,value:o>48?(0,u.hexToBigInt)(e,{signed:n}):(0,u.hexToNumber)(e,{signed:n})}}(p,{param:t});if("address"===t.type)return{consumed:32,value:(0,i.checksumAddress)((0,c.slice)(p,-20))};if("bool"===t.type)return{consumed:32,value:(0,u.hexToBool)(p)};throw new o.InvalidAbiDecodingTypeError(t.type,{docsPath:"/docs/contract/decodeAbiParameters"})}({data:e,param:b,position:p});n.push(y),p+=g}return n}({data:t,params:e})}},6717:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeDeployData=void 0;let o=n(82521),i=n(59530),s="/docs/contract/decodeDeployData";t.decodeDeployData=function({abi:e,bytecode:t,data:n}){if(n===t)return{bytecode:t};let c=e.find(e=>"type"in e&&"constructor"===e.type);if(!c)throw new o.AbiConstructorNotFoundError({docsPath:s});if(!("inputs"in c)||!c.inputs||0===c.inputs.length)throw new o.AbiConstructorParamsNotFoundError({docsPath:s});let l=(0,i.decodeAbiParameters)(c.inputs,`0x${n.replace(t,"")}`);return{args:l,bytecode:t}}},37113:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.decodeErrorResult=void 0;let o=n(35087),i=n(82521),s=n(42013),c=n(9684),l=n(59530),u=n(26352);t.decodeErrorResult=function({abi:e,data:t}){let n=(0,s.slice)(t,0,4);if("0x"===n)throw new i.AbiDecodingZeroDataError;let d=[...e||[],o.solidityError,o.solidityPanic],p=d.find(e=>"error"===e.type&&n===(0,c.getFunctionSelector)((0,u.formatAbiItem)(e)));if(!p)throw new i.AbiErrorSignatureNotFoundError(n,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:p,args:"inputs"in p&&p.inputs&&p.inputs.length>0?(0,l.decodeAbiParameters)(p.inputs,(0,s.slice)(t,4)):void 0,errorName:p.name}}},35813:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeEventLog=void 0;let o=n(82521),i=n(22834),s=n(59530),c=n(26352),l="/docs/contract/decodeEventLog";t.decodeEventLog=function({abi:e,data:t,strict:n,topics:u}){let d=n??!0,[p,...m]=u;if(!p)throw new o.AbiEventSignatureEmptyTopicsError({docsPath:l});let b=e.find(e=>"event"===e.type&&p===(0,i.getEventSelector)((0,c.formatAbiItem)(e)));if(!(b&&"name"in b)||"event"!==b.type)throw new o.AbiEventSignatureNotFoundError(p,{docsPath:l});let{name:g,inputs:y}=b,v=y?.some(e=>!("name"in e&&e.name)),E=v?[]:{},x=y.filter(e=>"indexed"in e&&e.indexed);for(let e=0;e<x.length;e++){let t=x[e],n=m[e];if(!n)throw new o.DecodeLogTopicsMismatch({abiItem:b,param:t});E[t.name||e]=function({param:e,value:t}){if("string"===e.type||"bytes"===e.type||"tuple"===e.type||e.type.match(/^(.*)\[(\d+)?\]$/))return t;let n=(0,s.decodeAbiParameters)([e],t)||[];return n[0]}({param:t,value:n})}let P=y.filter(e=>!("indexed"in e&&e.indexed));if(P.length>0){if(t&&"0x"!==t)try{let e=(0,s.decodeAbiParameters)(P,t);if(e){if(v)E=[...E,...e];else for(let t=0;t<P.length;t++)E[P[t].name]=e[t]}}catch(e){if(d){if(e instanceof o.AbiDecodingDataSizeTooSmallError)throw new o.DecodeLogDataMismatch({abiItem:b,data:e.data,params:e.params,size:e.size});throw e}}else if(d)throw new o.DecodeLogDataMismatch({abiItem:b,data:"0x",params:P,size:0})}return{eventName:g,args:Object.values(E).length>0?E:void 0}}},20587:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeFunctionData=void 0;let o=n(82521),i=n(42013),s=n(9684),c=n(59530),l=n(26352);t.decodeFunctionData=function({abi:e,data:t}){let n=(0,i.slice)(t,0,4),u=e.find(e=>"function"===e.type&&n===(0,s.getFunctionSelector)((0,l.formatAbiItem)(e)));if(!u)throw new o.AbiFunctionSignatureNotFoundError(n,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:u.name,args:"inputs"in u&&u.inputs&&u.inputs.length>0?(0,c.decodeAbiParameters)(u.inputs,(0,i.slice)(t,4)):void 0}}},90181:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeFunctionResult=void 0;let o=n(82521),i=n(59530),s=n(68340),c="/docs/contract/decodeFunctionResult";t.decodeFunctionResult=function({abi:e,args:t,functionName:n,data:l}){let u=e[0];if(n&&!(u=(0,s.getAbiItem)({abi:e,args:t,name:n})))throw new o.AbiFunctionNotFoundError(n,{docsPath:c});if("function"!==u.type)throw new o.AbiFunctionNotFoundError(void 0,{docsPath:c});if(!u.outputs)throw new o.AbiFunctionOutputsNotFoundError(u.name,{docsPath:c});let d=(0,i.decodeAbiParameters)(u.outputs,l);return d&&d.length>1?d:d&&1===d.length?d[0]:void 0}},82121:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getArrayComponents=t.encodeAbiParameters=void 0;let o=n(82521),i=n(61235),s=n(9322),c=n(22913),l=n(51474),u=n(96711),d=n(42013),p=n(56945);function encodeParams(e){let t=0;for(let n=0;n<e.length;n++){let{dynamic:o,encoded:i}=e[n];o?t+=32:t+=(0,u.size)(i)}let n=[],o=[],i=0;for(let s=0;s<e.length;s++){let{dynamic:c,encoded:l}=e[s];c?(n.push((0,p.numberToHex)(t+i,{size:32})),o.push(l),i+=(0,u.size)(l)):n.push(l)}return(0,c.concat)([...n,...o])}function getArrayComponents(e){let t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}t.encodeAbiParameters=function(e,t){if(e.length!==t.length)throw new o.AbiEncodingLengthMismatchError({expectedLength:e.length,givenLength:t.length});let n=function({params:e,values:t}){let n=[];for(let m=0;m<e.length;m++)n.push(function prepareParam({param:e,value:t}){let n=getArrayComponents(e.type);if(n){let[i,s]=n;return function(e,{length:t,param:n}){let i=null===t;if(!Array.isArray(e))throw new o.InvalidArrayError(e);
68if(!i&&e.length!==t)throw new o.AbiEncodingArrayLengthMismatchError({expectedLength:t,givenLength:e.length,type:`${n.type}[${t}]`});let s=!1,l=[];for(let t=0;t<e.length;t++){let o=prepareParam({param:n,value:e[t]});o.dynamic&&(s=!0),l.push(o)}if(i||s){let e=encodeParams(l);if(i){let t=(0,p.numberToHex)(l.length,{size:32});return{dynamic:!0,encoded:l.length>0?(0,c.concat)([t,e]):t}}if(s)return{dynamic:!0,encoded:e}}return{dynamic:!1,encoded:(0,c.concat)(l.map(({encoded:e})=>e))}}(t,{length:i,param:{...e,type:s}})}if("tuple"===e.type)return function(e,{param:t}){let n=!1,o=[];for(let i=0;i<t.components.length;i++){let s=t.components[i],c=Array.isArray(e)?i:s.name,l=prepareParam({param:s,value:e[c]});o.push(l),l.dynamic&&(n=!0)}return{dynamic:n,encoded:n?encodeParams(o):(0,c.concat)(o.map(({encoded:e})=>e))}}(t,{param:e});if("address"===e.type)return function(e){if(!(0,s.isAddress)(e))throw new i.InvalidAddressError({address:e});return{dynamic:!1,encoded:(0,l.padHex)(e.toLowerCase())}}(t);if("bool"===e.type)return{dynamic:!1,encoded:(0,l.padHex)((0,p.boolToHex)(t))};if(e.type.startsWith("uint")||e.type.startsWith("int")){let n=e.type.startsWith("int");return function(e,{signed:t}){return{dynamic:!1,encoded:(0,p.numberToHex)(e,{size:32,signed:t})}}(t,{signed:n})}if(e.type.startsWith("bytes"))return function(e,{param:t}){let[,n]=t.type.split("bytes"),i=(0,u.size)(e);if(!n){let t=e;return i%32!=0&&(t=(0,l.padHex)(t,{dir:"right",size:32*Math.ceil((e.length-2)/2/32)})),{dynamic:!0,encoded:(0,c.concat)([(0,l.padHex)((0,p.numberToHex)(i,{size:32})),t])}}if(i!==parseInt(n))throw new o.AbiEncodingBytesSizeMismatchError({expectedSize:parseInt(n),value:e});return{dynamic:!1,encoded:(0,l.padHex)(e,{dir:"right"})}}(t,{param:e});if("string"===e.type)return function(e){let t=(0,p.stringToHex)(e),n=Math.ceil((0,u.size)(t)/32),o=[];for(let e=0;e<n;e++)o.push((0,l.padHex)((0,d.slice)(t,32*e,(e+1)*32),{dir:"right"}));return{dynamic:!0,encoded:(0,c.concat)([(0,l.padHex)((0,p.numberToHex)((0,u.size)(t),{size:32})),...o])}}(t);throw new o.InvalidAbiEncodingTypeError(e.type,{docsPath:"/docs/contract/encodeAbiParameters"})}({param:e[m],value:t[m]}));return n}({params:e,values:t}),m=encodeParams(n);return 0===m.length?"0x":m},t.getArrayComponents=getArrayComponents},94335:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeDeployData=void 0;let o=n(82521),i=n(22913),s=n(82121),c="/docs/contract/encodeDeployData";t.encodeDeployData=function({abi:e,args:t,bytecode:n}){if(!t||0===t.length)return n;let l=e.find(e=>"type"in e&&"constructor"===e.type);if(!l)throw new o.AbiConstructorNotFoundError({docsPath:c});if(!("inputs"in l)||!l.inputs||0===l.inputs.length)throw new o.AbiConstructorParamsNotFoundError({docsPath:c});let u=(0,s.encodeAbiParameters)(l.inputs,t);return(0,i.concatHex)([n,u])}},62863:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeErrorResult=void 0;let o=n(82521),i=n(22913),s=n(9684),c=n(82121),l=n(26352),u=n(68340),d="/docs/contract/encodeErrorResult";t.encodeErrorResult=function({abi:e,errorName:t,args:n}){let p=e[0];if(t&&!(p=(0,u.getAbiItem)({abi:e,args:n,name:t})))throw new o.AbiErrorNotFoundError(t,{docsPath:d});if("error"!==p.type)throw new o.AbiErrorNotFoundError(void 0,{docsPath:d});let m=(0,l.formatAbiItem)(p),b=(0,s.getFunctionSelector)(m),g="0x";if(n&&n.length>0){if(!p.inputs)throw new o.AbiErrorInputsNotFoundError(p.name,{docsPath:d});g=(0,c.encodeAbiParameters)(p.inputs,n)}return(0,i.concatHex)([b,g])}},3540:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeEventTopics=void 0;let o=n(82521),i=n(84166),s=n(37281),c=n(22834),l=n(35841),u=n(82121),d=n(26352),p=n(68340);function encodeArg({param:e,value:t}){if("string"===e.type||"bytes"===e.type)return(0,l.keccak256)((0,s.toBytes)(t));if("tuple"===e.type||e.type.match(/^(.*)\[(\d+)?\]$/))throw new i.FilterTypeNotSupportedError(e.type);return(0,u.encodeAbiParameters)([e],[t])}t.encodeEventTopics=function({abi:e,eventName:t,args:n}){let i=e[0];if(t&&!(i=(0,p.getAbiItem)({abi:e,args:n,name:t})))throw new o.AbiEventNotFoundError(t,{docsPath:"/docs/contract/encodeEventTopics"});if("event"!==i.type)throw new o.AbiEventNotFoundError(void 0,{docsPath:"/docs/contract/encodeEventTopics"});let s=(0,d.formatAbiItem)(i),l=(0,c.getEventSelector)(s),u=[];
68if(n&&"inputs"in i){let e=i.inputs?.filter(e=>"indexed"in e&&e.indexed),t=Array.isArray(n)?n:Object.values(n).length>0?e?.map(e=>n[e.name])??[]:[];t.length>0&&(u=e?.map((e,n)=>Array.isArray(t[n])?t[n].map((o,i)=>encodeArg({param:e,value:t[n][i]})):t[n]?encodeArg({param:e,value:t[n]}):null)??[])}return[l,...u]}},48635:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeFunctionData=void 0;let o=n(82521),i=n(22913),s=n(9684),c=n(82121),l=n(26352),u=n(68340);t.encodeFunctionData=function({abi:e,args:t,functionName:n}){let d=e[0];if(n&&!(d=(0,u.getAbiItem)({abi:e,args:t,name:n})))throw new o.AbiFunctionNotFoundError(n,{docsPath:"/docs/contract/encodeFunctionData"});if("function"!==d.type)throw new o.AbiFunctionNotFoundError(void 0,{docsPath:"/docs/contract/encodeFunctionData"});let p=(0,l.formatAbiItem)(d),m=(0,s.getFunctionSelector)(p),b="inputs"in d&&d.inputs?(0,c.encodeAbiParameters)(d.inputs,t??[]):void 0;return(0,i.concatHex)([m,b??"0x"])}},63736:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeFunctionResult=void 0;let o=n(82521),i=n(82121),s=n(68340);t.encodeFunctionResult=function({abi:e,functionName:t,result:n}){let c=e[0];if(t&&!(c=(0,s.getAbiItem)({abi:e,name:t})))throw new o.AbiFunctionNotFoundError(t,{docsPath:"/docs/contract/encodeFunctionResult"});if("function"!==c.type)throw new o.AbiFunctionNotFoundError(void 0,{docsPath:"/docs/contract/encodeFunctionResult"});if(!c.outputs)throw new o.AbiFunctionOutputsNotFoundError(c.name,{docsPath:"/docs/contract/encodeFunctionResult"});let l=Array.isArray(n)?n:[n];return 0!==c.outputs.length||l[0]||(l=[]),(0,i.encodeAbiParameters)(c.outputs,l)}},8347:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodePacked=void 0;let o=n(82521),i=n(61235),s=n(9322),c=n(22913),l=n(51474),u=n(56945),d=n(72494);t.encodePacked=function(e,t){if(e.length!==t.length)throw new o.AbiEncodingLengthMismatchError({expectedLength:e.length,givenLength:t.length});let n=[];for(let p=0;p<e.length;p++){let m=e[p],b=t[p];n.push(function encode(e,t,n=!1){if("address"===e){if(!(0,s.isAddress)(t))throw new i.InvalidAddressError({address:t});return(0,l.pad)(t.toLowerCase(),{size:n?32:null})}if("string"===e)return(0,u.stringToHex)(t);if("bytes"===e)return t;if("bool"===e)return(0,l.pad)((0,u.boolToHex)(t),{size:n?32:1});let p=e.match(d.integerRegex);if(p){let[e,o,i="256"]=p,s=parseInt(i)/8;return(0,u.numberToHex)(t,{size:n?32:s,signed:"int"===o})}let m=e.match(d.bytesRegex);if(m){let[e,i]=m;if(parseInt(i)!==(t.length-2)/2)throw new o.BytesSizeMismatchError({expectedSize:parseInt(i),givenSize:(t.length-2)/2});return(0,l.pad)(t,{dir:"right",size:n?32:null})}let b=e.match(d.arrayRegex);if(b&&Array.isArray(t)){let[e,n]=b,o=[];for(let e=0;e<t.length;e++)o.push(encode(n,t[e],!0));return 0===o.length?"0x":(0,c.concatHex)(o)}throw new o.UnsupportedPackedAbiType(e)}(m,b))}return(0,c.concatHex)(n)}},26352:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbiParams=t.formatAbiItem=void 0;let o=n(82521);function formatAbiParams(e,{includeName:t=!1}={}){return e?e.map(e=>(function(e,{includeName:t}){return e.type.startsWith("tuple")?`(${formatAbiParams(e.components,{includeName:t})})${e.type.slice(5)}`:e.type+(t&&e.name?` ${e.name}`:"")})(e,{includeName:t})).join(t?", ":","):""}t.formatAbiItem=function(e,{includeName:t=!1}={}){if("function"!==e.type&&"event"!==e.type&&"error"!==e.type)throw new o.InvalidDefinitionTypeError(e.type);return`${e.name}(${formatAbiParams(e.inputs,{includeName:t})})`},t.formatAbiParams=formatAbiParams},79075:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAbiItemWithArgs=void 0;let o=n(36774);t.formatAbiItemWithArgs=function({abiItem:e,args:t,includeFunctionName:n=!0,includeName:i=!1}){if("name"in e&&"inputs"in e&&e.inputs)return`${n?e.name:""}(${e.inputs.map((e,n)=>`${i&&e.name?`${e.name}: `:""}${"object"==typeof t[n]?(0,o.stringify)(t[n]):t[n]}`).join(", ")})`}}
68,68340:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAmbiguousTypes=t.isArgOfType=t.getAbiItem=void 0;let o=n(82521),i=n(29281),s=n(22834),c=n(9684),l=n(9322);function isArgOfType(e,t){let n=typeof e,o=t.type;switch(o){case"address":return(0,l.isAddress)(e);case"bool":return"boolean"===n;case"function":case"string":return"string"===n;default:if("tuple"===o&&"components"in t)return Object.values(t.components).every((t,n)=>isArgOfType(Object.values(e)[n],t));if(/^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(o))return"number"===n||"bigint"===n;if(/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(o))return"string"===n||e instanceof Uint8Array;if(/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(o))return Array.isArray(e)&&e.every(e=>isArgOfType(e,{...t,type:o.replace(/(\[[0-9]{0,}\])$/,"")}));return!1}}function getAmbiguousTypes(e,t,n){for(let o in e){let i=e[o],s=t[o];if("tuple"===i.type&&"tuple"===s.type&&"components"in i&&"components"in s)return getAmbiguousTypes(i.components,s.components,n[o]);let c=[i.type,s.type],u=!!(c.includes("address")&&c.includes("bytes20"))||!!(c.includes("address")&&c.includes("string")||c.includes("address")&&c.includes("bytes"))&&(0,l.isAddress)(n[o]);if(u)return c}}t.getAbiItem=function({abi:e,args:t=[],name:n}){let l;let u=(0,i.isHex)(n,{strict:!1}),d=e.filter(e=>u?"function"===e.type?(0,c.getFunctionSelector)(e)===n:"event"===e.type&&(0,s.getEventSelector)(e)===n:"name"in e&&e.name===n);if(0!==d.length){if(1===d.length)return d[0];for(let e of d){if(!("inputs"in e))continue;if(!t||0===t.length){if(!e.inputs||0===e.inputs.length)return e;continue}if(!e.inputs||0===e.inputs.length||e.inputs.length!==t.length)continue;let n=t.every((t,n)=>{let o="inputs"in e&&e.inputs[n];return!!o&&isArgOfType(t,o)});if(n){if(l&&"inputs"in l&&l.inputs){let n=getAmbiguousTypes(e.inputs,l.inputs,t);if(n)throw new o.AbiItemAmbiguityError({abiItem:e,type:n[0]},{abiItem:l,type:n[1]})}l=e}}return l||d[0]}},t.isArgOfType=isArgOfType,t.getAmbiguousTypes=getAmbiguousTypes},13385:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.publicKeyToAddress=t.parseAccount=void 0;var o=n(27558);Object.defineProperty(t,"parseAccount",{enumerable:!0,get:function(){return o.parseAccount}});var i=n(35334);Object.defineProperty(t,"publicKeyToAddress",{enumerable:!0,get:function(){return i.publicKeyToAddress}})},66830:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAddress=t.checksumAddress=void 0;let o=n(61235),i=n(37281),s=n(35841),c=n(9322);function checksumAddress(e,t){let n=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),o=(0,s.keccak256)((0,i.stringToBytes)(n),"bytes"),c=(t?n.substring(`${t}0x`.length):n).split("");for(let e=0;e<40;e+=2)o[e>>1]>>4>=8&&c[e]&&(c[e]=c[e].toUpperCase()),(15&o[e>>1])>=8&&c[e+1]&&(c[e+1]=c[e+1].toUpperCase());return`0x${c.join("")}`}t.checksumAddress=checksumAddress,t.getAddress=function(e,t){if(!(0,c.isAddress)(e))throw new o.InvalidAddressError({address:e});return checksumAddress(e,t)}},63965:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCreate2Address=t.getCreateAddress=t.getContractAddress=void 0;let o=n(22913),i=n(28360),s=n(51474),c=n(42013),l=n(37281),u=n(88377),d=n(35841),p=n(66830);function getCreateAddress(e){let t=(0,l.toBytes)((0,p.getAddress)(e.from)),n=(0,l.toBytes)(e.nonce);return 0===n[0]&&(n=new Uint8Array([])),(0,p.getAddress)(`0x${(0,d.keccak256)((0,u.toRlp)([t,n],"bytes")).slice(26)}`)}function getCreate2Address(e){let t=(0,l.toBytes)((0,p.getAddress)(e.from)),n=(0,s.pad)((0,i.isBytes)(e.salt)?e.salt:(0,l.toBytes)(e.salt),{size:32}),u="bytecodeHash"in e?(0,i.isBytes)(e.bytecodeHash)?e.bytecodeHash:(0,l.toBytes)(e.bytecodeHash):(0,d.keccak256)(e.bytecode,"bytes");return(0,p.getAddress)((0,c.slice)((0,d.keccak256)((0,o.concat)([(0,l.toBytes)("0xff"),t,n,u])),12))}t.getContractAddress=function(e){return"CREATE2"===e.opcode?getCreate2Address(e):getCreateAddress(e)},t.getCreateAddress=getCreateAddress,t.getCreate2Address=getCreate2Address},9322:function(e,t){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.isAddress=void 0;let n=/^0x[a-fA-F0-9]{40}$/;t.isAddress=function(e){return n.test(e)}},64924:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isAddressEqual=void 0;let o=n(61235),i=n(9322);t.isAddressEqual=function(e,t){if(!(0,i.isAddress)(e))throw new o.InvalidAddressError({address:e});if(!(0,i.isAddress)(t))throw new o.InvalidAddressError({address:t});return e.toLowerCase()===t.toLowerCase()}},24859:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.buildRequest=t.isDeterministicError=void 0;let o=n(78498),i=n(86617),s=n(28516),c=n(67783);t.isDeterministicError=e=>"code"in e?-1!==e.code&&-32004!==e.code&&-32005!==e.code&&-32042!==e.code&&-32603!==e.code:e instanceof i.HttpRequestError&&!!e.status&&403!==e.status&&408!==e.status&&413!==e.status&&429!==e.status&&500!==e.status&&502!==e.status&&503!==e.status&&504!==e.status,t.buildRequest=function(e,{retryDelay:n=150,retryCount:l=3}={}){return async u=>(0,c.withRetry)(async()=>{try{return await e(u)}catch(e){switch(e.code){case s.ParseRpcError.code:throw new s.ParseRpcError(e);case s.InvalidRequestRpcError.code:throw new s.InvalidRequestRpcError(e);case s.MethodNotFoundRpcError.code:throw new s.MethodNotFoundRpcError(e);case s.InvalidParamsRpcError.code:throw new s.InvalidParamsRpcError(e);case s.InternalRpcError.code:throw new s.InternalRpcError(e);case s.InvalidInputRpcError.code:throw new s.InvalidInputRpcError(e);case s.ResourceNotFoundRpcError.code:throw new s.ResourceNotFoundRpcError(e);case s.ResourceUnavailableRpcError.code:throw new s.ResourceUnavailableRpcError(e);case s.TransactionRejectedRpcError.code:throw new s.TransactionRejectedRpcError(e);case s.MethodNotSupportedRpcError.code:throw new s.MethodNotSupportedRpcError(e);case s.LimitExceededRpcError.code:throw new s.LimitExceededRpcError(e);case s.JsonRpcVersionUnsupportedError.code:throw new s.JsonRpcVersionUnsupportedError(e);case s.UserRejectedRequestError.code:throw new s.UserRejectedRequestError(e);case s.UnauthorizedProviderError.code:throw new s.UnauthorizedProviderError(e);case s.UnsupportedProviderMethodError.code:throw new s.UnsupportedProviderMethodError(e);case s.ProviderDisconnectedError.code:throw new s.ProviderDisconnectedError(e);case s.ChainDisconnectedError.code:throw new s.ChainDisconnectedError(e);case s.SwitchChainError.code:throw new s.SwitchChainError(e);case 5e3:throw new s.UserRejectedRequestError(e);default:if(e instanceof o.BaseError)throw e;throw new s.UnknownRpcError(e)}}},{delay:({count:e,error:t})=>{if(t&&t instanceof i.HttpRequestError){let e=t?.headers?.get("Retry-After");if(e?.match(/\d/))return 1e3*parseInt(e)}return~~(1<<e)*n},retryCount:l,shouldRetry:({error:e})=>!(0,t.isDeterministicError)(e)})}},39978:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ccipFetch=t.offchainLookup=t.offchainLookupAbiItem=t.offchainLookupSignature=void 0;let o=n(52234),i=n(59232),s=n(86617),c=n(37113),l=n(82121),u=n(64924),d=n(22913),p=n(29281),m=n(36774);async function offchainLookup(e,{blockNumber:n,blockTag:s,data:p,to:m}){let{args:b}=(0,c.decodeErrorResult)({data:p,abi:[t.offchainLookupAbiItem]}),[g,y,v,E,x]=b;try{if(!(0,u.isAddressEqual)(m,g))throw new i.OffchainLookupSenderMismatchError({sender:g,to:m});let t=await ccipFetch({data:v,sender:g,urls:y}),{data:c}=await (0,o.call)(e,{blockNumber:n,blockTag:s,data:(0,d.concat)([E,(0,l.encodeAbiParameters)([{type:"bytes"},{type:"bytes"}],[t,x])]),to:m});return c}catch(e){throw new i.OffchainLookupError({callbackSelector:E,cause:e,data:p,extraData:x,sender:g,urls:y})}}async function ccipFetch({data:e,sender:t,urls:n}){let o=Error("An unknown error occurred.");for(let c=0;c<n.length;c++){let l=n[c],u=l.includes("{data}")?"GET":"POST",d="POST"===u?{data:e,sender:t}:void 0;try{let n;let c=await fetch(l.replace("{sender}",t).replace("{data}",e),{body:JSON.stringify(d),method:u});if(n=c.headers.get("Content-Type")?.startsWith("application/json")?(await c.json()).data:await c.text(),!c.ok){o=new s.HttpRequestError({body:d,details:n?.error?(0,m.stringify)(n.error):c.statusText,headers:c.headers,status:c.status,url:l});continue}if(!(0,p.isHex)(n)){o=new i.OffchainLookupResponseMalformedError({result:n,url:l});continue}return n}catch(e){o=new s.HttpRequestError({body:d,details:e.message,url:l})}}throw o}t.offchainLookupSignature="0x556f1830",t.offchainLookupAbiItem={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"}]},t.offchainLookup=offchainLookup,t.ccipFetch=ccipFetch},54037:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.assertCurrentChain=void 0;let o=n(99174);t.assertCurrentChain=function({chain:e,currentChainId:t}){if(!e)throw new o.ChainNotFoundError;if(t!==e.id)throw new o.ChainMismatchError({chain:e,currentChainId:t})}},57401:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.defineChain=void 0,t.defineChain=function(e,t={}){let{fees:n=e.fees,formatters:o=e.formatters,serializers:i=e.serializers}=t;return{...e,fees:n,formatters:o,serializers:i}}},80328:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extractChain=void 0,t.extractChain=function({chains:e,id:t}){return e.find(e=>e.id===t)}},27025:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getChainContractAddress=void 0;let o=n(99174);t.getChainContractAddress=function({blockNumber:e,chain:t,contract:n}){let i=t?.contracts?.[n];if(!i)throw new o.ChainDoesNotSupportContract({chain:t,contract:{name:n}});if(e&&i.blockCreated&&i.blockCreated>e)throw new o.ChainDoesNotSupportContract({blockNumber:e,chain:t,contract:{name:n,blockCreated:i.blockCreated}});return i.address}},51027:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extractFunctionType=t.extractFunctionParams=t.extractFunctionName=t.extractFunctionParts=void 0;let n=/((function|event)\s)?(.*)(\((.*)\))/;function extractFunctionParts(e){let t=e.match(n),o=t?.[2]||void 0,i=t?.[3],s=t?.[5]||void 0;return{type:o,name:i,params:s}}t.extractFunctionParts=extractFunctionParts,t.extractFunctionName=function(e){return extractFunctionParts(e).name},t.extractFunctionParams=function(e){let t=extractFunctionParts(e).params,n=t?.split(",").map(e=>e.trim().split(" "));return n?.map(e=>({type:e[0],name:"indexed"===e[1]?e[2]:e[1],..."indexed"===e[1]?{indexed:!0}:{}}))},t.extractFunctionType=function(e){return extractFunctionParts(e).type}},1526:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCursor=void 0;let o=n(43342),i={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,assertPosition(e){if(e<0||e>this.bytes.length-1)throw new o.PositionOutOfBoundsError({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new o.NegativeOffsetError({offset:e});let t=this.position-e;this.assertPosition(t),this.position=t},incrementPosition(e){if(e<0)throw new o.NegativeOffsetError({offset:e});let t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){let n=t??this.position;return this.assertPosition(n+e-1),this.bytes.subarray(n,n+e)},inspectUint8(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){let t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){let t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){let t=e??this.position;return this.assertPosition(t+3),this.dataView.getUint32(t)},pushByte(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushBytes(e){this.assertPosition(this.position+e.length-1),this.bytes.set(e,this.position),this.position+=e.length},pushUint8(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushUint16(e){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,e),this.position+=2},pushUint24(e){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,e>>8),this.dataView.setUint8(this.position+2,255&e),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){let e=this.inspectByte();return this.position++,e},readBytes(e){let t=this.inspectBytes(e);return this.position+=e,t},readUint8(){let e=this.inspectUint8();return this.position+=1,e},readUint16(){let e=this.inspectUint16();return this.position+=2,e},readUint24(){let e=this.inspectUint24();return this.position+=3,e},readUint32(){let e=this.inspectUint32();return this.position+=4,e},setPosition(e){this.assertPosition(e),this.position=e}};t.createCursor=function(e){let t=Object.create(i);return t.bytes=e,t.dataView=new DataView(e.buffer,e.byteOffset,e.byteLength),t}},22913:function(e,t){"use strict";function concatBytes(e){let t=0;for(let n of e)t+=n.length;let n=new Uint8Array(t),o=0;for(let t of e)n.set(t,o),o+=t.length;return n}function concatHex(e){return`0x${e.reduce((e,t)=>
68e+t.replace("0x",""),"")}`}Object.defineProperty(t,"__esModule",{value:!0}),t.concatHex=t.concatBytes=t.concat=void 0,t.concat=function(e){return"string"==typeof e[0]?concatHex(e):concatBytes(e)},t.concatBytes=concatBytes,t.concatHex=concatHex},28360:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isBytes=void 0,t.isBytes=function(e){return!!e&&"object"==typeof e&&"BYTES_PER_ELEMENT"in e&&1===e.BYTES_PER_ELEMENT&&"Uint8Array"===e.constructor.name}},46241:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isBytesEqual=void 0;let o=n(34131),i=n(37281),s=n(29281);t.isBytesEqual=function(e,t){let n=(0,s.isHex)(e)?(0,i.toBytes)(e):e,c=(0,s.isHex)(t)?(0,i.toBytes)(t):t;return(0,o.equalBytes)(n,c)}},29281:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHex=void 0,t.isHex=function(e,{strict:t=!0}={}){return!!e&&"string"==typeof e&&(t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x"))}},51474:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.padBytes=t.padHex=t.pad=void 0;let o=n(50562);function padHex(e,{dir:t,size:n=32}={}){if(null===n)return e;let i=e.replace("0x","");if(i.length>2*n)throw new o.SizeExceedsPaddingSizeError({size:Math.ceil(i.length/2),targetSize:n,type:"hex"});return`0x${i["right"===t?"padEnd":"padStart"](2*n,"0")}`}function padBytes(e,{dir:t,size:n=32}={}){if(null===n)return e;if(e.length>n)throw new o.SizeExceedsPaddingSizeError({size:e.length,targetSize:n,type:"bytes"});let i=new Uint8Array(n);for(let o=0;o<n;o++){let s="right"===t;i[s?o:n-o-1]=e[s?o:e.length-o-1]}return i}t.pad=function(e,{dir:t,size:n=32}={}){return"string"==typeof e?padHex(e,{dir:t,size:n}):padBytes(e,{dir:t,size:n})},t.padHex=padHex,t.padBytes=padBytes},96711:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.size=void 0;let o=n(29281);t.size=function(e){return(0,o.isHex)(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length}},42013:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sliceHex=t.sliceBytes=t.slice=void 0;let o=n(50562),i=n(29281),s=n(96711);function assertStartOffset(e,t){if("number"==typeof t&&t>0&&t>(0,s.size)(e)-1)throw new o.SliceOffsetOutOfBoundsError({offset:t,position:"start",size:(0,s.size)(e)})}function assertEndOffset(e,t,n){if("number"==typeof t&&"number"==typeof n&&(0,s.size)(e)!==n-t)throw new o.SliceOffsetOutOfBoundsError({offset:n,position:"end",size:(0,s.size)(e)})}function sliceBytes(e,t,n,{strict:o}={}){assertStartOffset(e,t);let i=e.slice(t,n);return o&&assertEndOffset(i,t,n),i}function sliceHex(e,t,n,{strict:o}={}){assertStartOffset(e,t);let i=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return o&&assertEndOffset(i,t,n),i}t.slice=function(e,t,n,{strict:o}={}){return(0,i.isHex)(e,{strict:!1})?sliceHex(e,t,n,{strict:o}):sliceBytes(e,t,n,{strict:o})},t.sliceBytes=sliceBytes,t.sliceHex=sliceHex},41691:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.trim=void 0,t.trim=function(e,{dir:t="left"}={}){let n="string"==typeof e?e.replace("0x",""):e,o=0;for(let e=0;e<n.length-1&&"0"===n["left"===t?e:n.length-e-1].toString();e++)o++;return(n="left"===t?n.slice(o):n.slice(0,n.length-o),"string"==typeof e)?(1===n.length&&"right"===t&&(n=`${n}0`),`0x${n.length%2==1?`0${n}`:n}`):n}},70185:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.bytesToString=t.bytesToNumber=t.bytesToBool=t.bytesToBigInt=t.fromBytes=void 0;let o=n(62608),i=n(41691),s=n(84008),c=n(56945);function bytesToBigInt(e,t={}){void 0!==t.size&&(0,s.assertSize)(e,{size:t.size});let n=(0,c.bytesToHex)(e,t);return(0,s.hexToBigInt)(n)}function bytesToBool(e,t={}){let n=e;if(void 0!==t.size&&((0,s.assertSize)(n,{size:t.size}),n=(0,i.trim)(n)),n.length>1||n[0]>1)throw new o.InvalidBytesBooleanError(n);return!!n[0]}function bytesToNumber(e,t={}){void 0!==t.size&&(0,s.assertSize)(e,{size:t.size});let n=(0,c.bytesToHex)(e,t);return(0,s.hexToNumber)(n)}function bytesToString(e,t={}){let n=e;return void 0!==t.size&&((0,s.assertSize)(n,{size:t.size}),n=(0,i.trim)(n,{dir:"right"})),new TextDecoder().decode(n)}t.fromBytes=function(e,t){let n="string"==typeof t?{to:t}:t,o=n.to;return"number"===o?bytesToNumber(e,n):"bigint"===o?bytesToBigInt(e,n):"boolean"===o?bytesToBool(e,n):"string"===o?bytesToString(e,n):(0,c.bytesToHex)(e,n
68)},t.bytesToBigInt=bytesToBigInt,t.bytesToBool=bytesToBool,t.bytesToNumber=bytesToNumber,t.bytesToString=bytesToString},84008:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hexToString=t.hexToNumber=t.hexToBool=t.hexToBigInt=t.fromHex=t.assertSize=void 0;let o=n(62608),i=n(96711),s=n(41691),c=n(37281);function assertSize(e,{size:t}){if((0,i.size)(e)>t)throw new o.SizeOverflowError({givenSize:(0,i.size)(e),maxSize:t})}function hexToBigInt(e,t={}){let{signed:n}=t;t.size&&assertSize(e,{size:t.size});let o=BigInt(e);if(!n)return o;let i=(e.length-2)/2,s=(1n<<8n*BigInt(i)-1n)-1n;return o<=s?o:o-BigInt(`0x${"f".padStart(2*i,"f")}`)-1n}function hexToBool(e,t={}){let n=e;if(t.size&&(assertSize(n,{size:t.size}),n=(0,s.trim)(n)),"0x00"===(0,s.trim)(n))return!1;if("0x01"===(0,s.trim)(n))return!0;throw new o.InvalidHexBooleanError(n)}function hexToNumber(e,t={}){return Number(hexToBigInt(e,t))}function hexToString(e,t={}){let n=(0,c.hexToBytes)(e);return t.size&&(assertSize(n,{size:t.size}),n=(0,s.trim)(n,{dir:"right"})),new TextDecoder().decode(n)}t.assertSize=assertSize,t.fromHex=function(e,t){let n="string"==typeof t?{to:t}:t,o=n.to;return"number"===o?hexToNumber(e,n):"bigint"===o?hexToBigInt(e,n):"string"===o?hexToString(e,n):"boolean"===o?hexToBool(e,n):(0,c.hexToBytes)(e,n)},t.hexToBigInt=hexToBigInt,t.hexToBool=hexToBool,t.hexToNumber=hexToNumber,t.hexToString=hexToString},74500:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.rlpToHex=t.rlpToBytes=t.fromRlp=void 0;let o=n(78498),i=n(62608),s=n(1526),c=n(37281),l=n(56945);function fromRlp(e,t="hex"){let n=(()=>{if("string"==typeof e){if(e.length>3&&e.length%2!=0)throw new i.InvalidHexValueError(e);return(0,c.hexToBytes)(e)}return e})(),o=(0,s.createCursor)(n),u=function fromRlpCursor(e,t="hex"){if(0===e.bytes.length)return"hex"===t?(0,l.bytesToHex)(e.bytes):e.bytes;let n=e.readByte();if(n<128&&e.decrementPosition(1),n<192){let o=readLength(e,n,128),i=e.readBytes(o);return"hex"===t?(0,l.bytesToHex)(i):i}let o=readLength(e,n,192);return function(e,t,n){let o=e.position,i=[];for(;e.position-o<t;)i.push(fromRlpCursor(e,n));return i}(e,o,t)}(o,t);return u}function readLength(e,t,n){if(128===n&&t<128)return 1;if(t<=n+55)return t-n;if(t===n+55+1)return e.readUint8();if(t===n+55+2)return e.readUint16();if(t===n+55+3)return e.readUint24();if(t===n+55+4)return e.readUint32();throw new o.BaseError("Invalid RLP prefix")}t.fromRlp=fromRlp,t.rlpToBytes=function(e,t="bytes"){return fromRlp(e,t)},t.rlpToHex=function(e,t="hex"){return fromRlp(e,t)}},37281:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stringToBytes=t.numberToBytes=t.hexToBytes=t.boolToBytes=t.toBytes=void 0;let o=n(78498),i=n(29281),s=n(51474),c=n(84008),l=n(56945),u=new TextEncoder;function boolToBytes(e,t={}){let n=new Uint8Array(1);return(n[0]=Number(e),"number"==typeof t.size)?((0,c.assertSize)(n,{size:t.size}),(0,s.pad)(n,{size:t.size})):n}t.toBytes=function(e,t={}){return"number"==typeof e||"bigint"==typeof e?numberToBytes(e,t):"boolean"==typeof e?boolToBytes(e,t):(0,i.isHex)(e)?hexToBytes(e,t):stringToBytes(e,t)},t.boolToBytes=boolToBytes;let d={zero:48,nine:57,A:65,F:70,a:97,f:102};function charCodeToBase16(e){return e>=d.zero&&e<=d.nine?e-d.zero:e>=d.A&&e<=d.F?e-(d.A-10):e>=d.a&&e<=d.f?e-(d.a-10):void 0}function hexToBytes(e,t={}){let n=e;t.size&&((0,c.assertSize)(n,{size:t.size}),n=(0,s.pad)(n,{dir:"right",size:t.size}));let i=n.slice(2);i.length%2&&(i=`0${i}`);let l=i.length/2,u=new Uint8Array(l);for(let e=0,t=0;e<l;e++){let n=charCodeToBase16(i.charCodeAt(t++)),s=charCodeToBase16(i.charCodeAt(t++));if(void 0===n||void 0===s)throw new o.BaseError(`Invalid byte sequence ("${i[t-2]}${i[t-1]}" in "${i}").`);u[e]=16*n+s}return u}function numberToBytes(e,t){let n=(0,l.numberToHex)(e,t);return hexToBytes(n)}function stringToBytes(e,t={}){let n=u.encode(e);return"number"==typeof t.size?((0,c.assertSize)(n,{size:t.size}),(0,s.pad)(n,{dir:"right",size:t.size})):n}t.hexToBytes=hexToBytes,t.numberToBytes=numberToBytes,t.stringToBytes=stringToBytes},56945:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.stringToHex=t.numberToHex=t.bytesToHex=t.boolToHex=t.toHex=void 0;let o=n(62608),i=n(51474),s=n(84008),c=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function boolToHex(e,t={}){let n=`0x${Number(e)}`;return"number"==typeof t.size?((0,s.assertSize)(n,{size:t.size}),(0,i.pad)(n,{size:t.size})):n}function bytesToHex(e,t={}){let n="";for(let t=0;t<e.length;t++)n+=c[e[t]];let o=`0x${n}`;return"number"==typeof t.size?((0,s.assertSize)(o,{size:t.size}),(0,i.pad)(o,{dir:"right",size:t.size})):o}function numberToHex(e,t={}){let n;let{signed:s,size:c}=t,l=BigInt(e);c?n=s?(1n<<8n*BigInt(c)-1n)-1n:2n**(8n*BigInt(c))-1n:"number"==typeof e&&(n=BigInt(Number.MAX_SAFE_INTEGER));let u="bigint"==typeof n&&s?-n-1n:0;if(n&&l>n||l<u){let t="bigint"==typeof e?"n":"";throw new o.IntegerOutOfRangeError({max:n?`${n}${t}`:void 0,min:`${u}${t}`,signed:s,size:c,value:`${e}${t}`})}let d=`0x${(s&&l<0?(1n<<BigInt(8*c))+BigInt(l):l).toString(16)}`;return c?(0,i.pad)(d,{size:c}):d}t.toHex=function(e,t={}){return"number"==typeof e||"bigint"==typeof e?numberToHex(e,t):"string"==typeof e?stringToHex(e,t):"boolean"==typeof e?boolToHex(e,t):bytesToHex(e,t)},t.boolToHex=boolToHex,t.bytesToHex=bytesToHex,t.numberToHex=numberToHex;let l=new TextEncoder;function stringToHex(e,t={}){let n=l.encode(e);return bytesToHex(n,t)}t.stringToHex=stringToHex},88377:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hexToRlp=t.bytesToRlp=t.toRlp=void 0;let o=n(56431),i=n(1526),s=n(37281),c=n(56945);function toRlp(e,t="hex"){let n=function getEncodable(e){return Array.isArray(e)?function(e){let t=e.reduce((e,t)=>e+t.length,0),n=getSizeOfLength(t),o=t<=55?1+t:1+n+t;return{length:o,encode(o){for(let{encode:i}of(t<=55?o.pushByte(192+t):(o.pushByte(247+n),1===n?o.pushUint8(t):2===n?o.pushUint16(t):3===n?o.pushUint24(t):o.pushUint32(t)),e))i(o)}}}(e.map(e=>getEncodable(e))):function(e){let t="string"==typeof e?(0,s.hexToBytes)(e):e,n=getSizeOfLength(t.length),o=1===t.length&&t[0]<128?1:t.length<=55?1+t.length:1+n+t.length;return{length:o,encode(e){1===t.length&&t[0]<128||(t.length<=55?e.pushByte(128+t.length):(e.pushByte(183+n),1===n?e.pushUint8(t.length):2===n?e.pushUint16(t.length):3===n?e.pushUint24(t.length):e.pushUint32(t.length))),e.pushBytes(t)}}}(e)}(e),o=(0,i.createCursor)(new Uint8Array(n.length));return(n.encode(o),"hex"===t)?(0,c.bytesToHex)(o.bytes):o.bytes}function getSizeOfLength(e){if(e<256)return 1;if(e<65536)return 2;if(e<16777216)return 3;if(e<4294967296)return 4;throw new o.BaseError("Length is too large.")}t.toRlp=toRlp,t.bytesToRlp=function(e,t="bytes"){return toRlp(e,t)},t.hexToRlp=function(e,t="hex"){return toRlp(e,t)}},67299:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAvatarRecord=void 0;let o=n(14221);async function parseAvatarRecord(e,{gatewayUrls:t,record:n}){return/eip155:/i.test(n)?parseNftAvatarUri(e,{gatewayUrls:t,record:n}):(0,o.parseAvatarUri)({uri:n,gatewayUrls:t})}async function parseNftAvatarUri(e,{gatewayUrls:t,record:n}){let i=(0,o.parseNftUri)(n),s=await (0,o.getNftTokenUri)(e,{nft:i}),{uri:c,isOnChain:l,isEncoded:u}=(0,o.resolveAvatarUri)({uri:s,gatewayUrls:t});if(l&&(c.includes("data:application/json;base64,")||c.startsWith("{"))){let e=u?atob(c.replace("data:application/json;base64,","")):c,n=JSON.parse(e);return(0,o.parseAvatarUri)({uri:(0,o.getJsonImage)(n),gatewayUrls:t})}let d=i.tokenID;return"erc1155"===i.namespace&&(d=d.replace("0x","").padStart(64,"0")),(0,o.getMetadataAvatarUri)({gatewayUrls:t,uri:c.replace(/(?:0x)?{id}/,d)})}t.parseAvatarRecord=parseAvatarRecord},14221:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getNftTokenUri=t.parseNftUri=t.parseAvatarUri=t.getMetadataAvatarUri=t.getJsonImage=t.resolveAvatarUri=t.getGateway=t.isImageUri=void 0;let o=n(2333),i=n(8370),s=/(?<protocol>https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?<root>\/)?(?<subpath>ipfs\/|ipns\/)?(?<target>[\w\-.]+)(?<subtarget>\/.*)?/,c=/^(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,})(\/(?<target>[\w\-.]+))?(?<subtarget>\/.*)?$/,l=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,u=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function isImageUri(e){try{let t=await fetch(e,{method:"HEAD"});if(200===t.status){let e=t.headers.get("content-type");return e?.startsWith("image/")}return!1}catch(t){if("object"==typeof t&&void 0!==t.response||!globalThis.hasOwnProperty("Image"))return!1;return new Promise(t=>{let n=new Image;n.onload=()=>{t(!0)},n.onerror=()=>{t(!1)},n.src=e})}}function getGateway(e,t){return e?e.endsWith("/")?e.slice(0,-1):e:t}function resolveAvatarUri({uri:e,gatewayUrls:t}){let n=l.test(e);
68if(n)return{uri:e,isOnChain:!0,isEncoded:n};let o=getGateway(t?.ipfs,"https://ipfs.io"),d=getGateway(t?.arweave,"https://arweave.net"),p=e.match(s),{protocol:m,subpath:b,target:g,subtarget:y=""}=p?.groups||{},v="ipns:/"===m||"ipns/"===b,E="ipfs:/"===m||"ipfs/"===b||c.test(e);if(e.startsWith("http")&&!v&&!E){let n=e;return t?.arweave&&(n=e.replace(/https:\/\/arweave.net/g,t?.arweave)),{uri:n,isOnChain:!1,isEncoded:!1}}if((v||E)&&g)return{uri:`${o}/${v?"ipns":"ipfs"}/${g}${y}`,isOnChain:!1,isEncoded:!1};if("ar:/"===m&&g)return{uri:`${d}/${g}${y||""}`,isOnChain:!1,isEncoded:!1};let x=e.replace(u,"");if(x.startsWith("<svg")&&(x=`data:image/svg+xml;base64,${btoa(x)}`),x.startsWith("data:")||x.startsWith("{"))return{uri:x,isOnChain:!0,isEncoded:!1};throw new i.EnsAvatarUriResolutionError({uri:e})}function getJsonImage(e){if("object"!=typeof e||!("image"in e)&&!("image_url"in e)&&!("image_data"in e))throw new i.EnsAvatarInvalidMetadataError({data:e});return e.image||e.image_url||e.image_data}async function getMetadataAvatarUri({gatewayUrls:e,uri:t}){try{let n=await fetch(t).then(e=>e.json()),o=await parseAvatarUri({gatewayUrls:e,uri:getJsonImage(n)});return o}catch{throw new i.EnsAvatarUriResolutionError({uri:t})}}async function parseAvatarUri({gatewayUrls:e,uri:t}){let{uri:n,isOnChain:o}=resolveAvatarUri({uri:t,gatewayUrls:e});if(o)return n;let s=await isImageUri(n);if(s)return n;throw new i.EnsAvatarUriResolutionError({uri:t})}async function getNftTokenUri(e,{nft:t}){if("erc721"===t.namespace)return(0,o.readContract)(e,{address:t.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(t.tokenID)]});if("erc1155"===t.namespace)return(0,o.readContract)(e,{address:t.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(t.tokenID)]});throw new i.EnsAvatarUnsupportedNamespaceError({namespace:t.namespace})}t.isImageUri=isImageUri,t.getGateway=getGateway,t.resolveAvatarUri=resolveAvatarUri,t.getJsonImage=getJsonImage,t.getMetadataAvatarUri=getMetadataAvatarUri,t.parseAvatarUri=parseAvatarUri,t.parseNftUri=function(e){let t=e;t.startsWith("did:nft:")&&(t=t.replace("did:nft:","").replace(/_/g,"/"));let[n,o,s]=t.split("/"),[c,l]=n.split(":"),[u,d]=o.split(":");if(!c||"eip155"!==c.toLowerCase())throw new i.EnsAvatarInvalidNftUriError({reason:"Only EIP-155 supported"});if(!l)throw new i.EnsAvatarInvalidNftUriError({reason:"Chain ID not found"});if(!d)throw new i.EnsAvatarInvalidNftUriError({reason:"Contract address not found"});if(!s)throw new i.EnsAvatarInvalidNftUriError({reason:"Token ID not found"});if(!u)throw new i.EnsAvatarInvalidNftUriError({reason:"ERC namespace not found"});return{chainID:parseInt(l),namespace:u.toLowerCase(),contractAddress:d,tokenID:s}},t.getNftTokenUri=getNftTokenUri},81877:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeLabelhash=void 0,t.encodeLabelhash=function(e){return`[${e.slice(2)}]`}},11256:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodedLabelToLabelhash=void 0;let o=n(29281);t.encodedLabelToLabelhash=function(e){if(66!==e.length||0!==e.indexOf("[")||65!==e.indexOf("]"))return null;let t=`0x${e.slice(1,65)}`;return(0,o.isHex)(t)?t:null}},7088:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNullUniversalResolverError=void 0;let o=n(35087),i=n(78498),s=n(91349);t.isNullUniversalResolverError=function(e,t){if(!(e instanceof i.BaseError))return!1;let n=e.walk(e=>e instanceof s.ContractFunctionRevertedError);return n instanceof s.ContractFunctionRevertedError&&(!!(n.data?.errorName==="ResolverNotFound"||n.data?.errorName==="ResolverWildcardNotSupported"||n.reason?.includes("Wildcard on non-extended resolvers is not supported"))||"reverse"===t&&n.reason===o.panicReasons[50])}},43337:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.labelhash=void 0;let o=n(37281),i=n(56945),s=n(35841),c=n(11256);t.labelhash=function(e){let t=new Uint8Array(32).fill(0);return e?(0,c.encodedLabelToLabelhash)(e)||(0,s.keccak256)((0,o.stringToBytes)(e)):(0,i.bytesToHex)(t)}},23412:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.namehash=void 0;let o=n(22913),i=n(37281),s=n(56945),c=n(35841),l=n(11256);t.namehash=function(e){let t=new Uint8Array(32).fill(0);if(!e)return(0,s.bytesToHex)(t);let n=e.split(".");for(let e=n.length-1;e>=0;e-=1){let s=(0,l.encodedLabelToLabelhash)(n[e]),u=s?(0,i.toBytes)(s):(0,c.keccak256)((0,i.stringToBytes)(n[e]),"bytes");t=(0,c.keccak256)((0,o.concat)([t,u]),"bytes")}return(0,s.bytesToHex)(t)}},37458:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.packetToBytes=void 0;let o=n(37281),i=n(81877),s=n(43337);t.packetToBytes=function(e){let t=e.replace(/^\.|\.$/gm,"");if(0===t.length)return new Uint8Array(1);let n=new Uint8Array((0,o.stringToBytes)(t).byteLength+2),c=0,l=t.split(".");for(let e=0;e<l.length;e++){let t=(0,o.stringToBytes)(l[e]);t.byteLength>255&&(t=(0,o.stringToBytes)((0,i.encodeLabelhash)((0,s.labelhash)(l[e])))),n[c]=t.length,n.set(t,c+1),c+=t.length+1}return n.byteLength!==c+1?n.slice(0,c+1):n}},91414:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCallError=void 0;let o=n(91349),i=n(48016),s=n(8842);t.getCallError=function(e,{docsPath:t,...n}){let c=(()=>{let t=(0,s.getNodeError)(e,n);return t instanceof i.UnknownNodeError?e:t})();return new o.CallExecutionError(c,{docsPath:t,...n})}},59895:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getContractError=void 0;let o=n(82521),i=n(78498),s=n(91349),c=n(28516);t.getContractError=function(e,{abi:t,address:n,args:l,docsPath:u,functionName:d,sender:p}){let{code:m,data:b,message:g,shortMessage:y}=e instanceof s.RawContractError?e:e instanceof i.BaseError?e.walk(e=>"data"in e)||e.walk():{},v=e instanceof o.AbiDecodingZeroDataError?new s.ContractFunctionZeroDataError({functionName:d}):[3,c.InternalRpcError.code].includes(m)&&(b||g||y)?new s.ContractFunctionRevertedError({abi:t,data:"object"==typeof b?b.data:b,functionName:d,message:y??g}):e;return new s.ContractFunctionExecutionError(v,{abi:t,args:l,contractAddress:n,docsPath:u,functionName:d,sender:p})}},35043:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEstimateGasError=void 0;let o=n(26265),i=n(48016),s=n(8842);t.getEstimateGasError=function(e,{docsPath:t,...n}){let c=(()=>{let t=(0,s.getNodeError)(e,n);return t instanceof i.UnknownNodeError?e:t})();return new o.EstimateGasExecutionError(c,{docsPath:t,...n})}},8842:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getNodeError=t.containsNodeError=void 0;let o=n(78498),i=n(48016),s=n(86617),c=n(28516);t.containsNodeError=function(e){return e instanceof c.TransactionRejectedRpcError||e instanceof c.InvalidInputRpcError||e instanceof s.RpcRequestError&&e.code===i.ExecutionRevertedError.code},t.getNodeError=function(e,t){let n=(e.details||"").toLowerCase(),s=e.walk(e=>e.code===i.ExecutionRevertedError.code);return s instanceof o.BaseError?new i.ExecutionRevertedError({cause:e,message:s.details}):i.ExecutionRevertedError.nodeMessage.test(n)?new i.ExecutionRevertedError({cause:e,message:e.details}):i.FeeCapTooHighError.nodeMessage.test(n)?new i.FeeCapTooHighError({cause:e,maxFeePerGas:t?.maxFeePerGas}):i.FeeCapTooLowError.nodeMessage.test(n)?new i.FeeCapTooLowError({cause:e,maxFeePerGas:t?.maxFeePerGas}):i.NonceTooHighError.nodeMessage.test(n)?new i.NonceTooHighError({cause:e,nonce:t?.nonce}):i.NonceTooLowError.nodeMessage.test(n)?new i.NonceTooLowError({cause:e,nonce:t?.nonce}):i.NonceMaxValueError.nodeMessage.test(n)?new i.NonceMaxValueError({cause:e,nonce:t?.nonce}):i.InsufficientFundsError.nodeMessage.test(n)?new i.InsufficientFundsError({cause:e}):i.IntrinsicGasTooHighError.nodeMessage.test(n)?new i.IntrinsicGasTooHighError({cause:e,gas:t?.gas}):i.IntrinsicGasTooLowError.nodeMessage.test(n)?new i.IntrinsicGasTooLowError({cause:e,gas:t?.gas}):i.TransactionTypeNotSupportedError.nodeMessage.test(n)?new i.TransactionTypeNotSupportedError({cause:e}):i.TipAboveFeeCapError.nodeMessage.test(n)?new i.TipAboveFeeCapError({cause:e,maxFeePerGas:t?.maxFeePerGas,maxPriorityFeePerGas:t?.maxPriorityFeePerGas}):new i.UnknownNodeError({cause:e})}},53268:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.getTransactionError=void 0;let o=n(48016),i=n(33841),s=n(8842);t.getTransactionError=function(e,{docsPath:t,...n}){let c=(()=>{let t=(0,s.getNodeError)(e,n);return t instanceof o.UnknownNodeError?e:t})();return new i.TransactionExecutionError(c,{docsPath:t,...n})}},65208:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createFilterRequestScope=void 0,t.createFilterRequestScope=function(e,{method:t}){let n={};return"fallback"===e.transport.type&&e.transport.onResponse?.(({method:e,response:o,status:i,transport:s})=>{"success"===i&&t===e&&(n[o]=s.request)}),t=>n[t]||e.request}},5729:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.defineBlock=t.formatBlock=void 0;let o=n(82867),i=n(93756);function formatBlock(e){let t=e.transactions?.map(e=>"string"==typeof e?e:i.formatTransaction(e));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,difficulty:e.difficulty?BigInt(e.difficulty):void 0,gasLimit:e.gasLimit?BigInt(e.gasLimit):void 0,gasUsed:e.gasUsed?BigInt(e.gasUsed):void 0,hash:e.hash?e.hash:null,logsBloom:e.logsBloom?e.logsBloom:null,nonce:e.nonce?e.nonce:null,number:e.number?BigInt(e.number):null,size:e.size?BigInt(e.size):void 0,timestamp:e.timestamp?BigInt(e.timestamp):void 0,transactions:t,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}t.formatBlock=formatBlock,t.defineBlock=(0,o.defineFormatter)("block",formatBlock)},56725:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extract=void 0,t.extract=function(e,{format:t}){if(!t)return{};let n={},o=t(e||{});return function extract_(t){let o=Object.keys(t);for(let i of o)i in e&&(n[i]=e[i]),t[i]&&"object"==typeof t[i]&&!Array.isArray(t[i])&&extract_(t[i])}(o),n}},9023:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatFeeHistory=void 0,t.formatFeeHistory=function(e){return{baseFeePerGas:e.baseFeePerGas.map(e=>BigInt(e)),gasUsedRatio:e.gasUsedRatio,oldestBlock:BigInt(e.oldestBlock),reward:e.reward?.map(e=>e.map(e=>BigInt(e)))}}},82867:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.defineFormatter=void 0,t.defineFormatter=function(e,t){return({exclude:n,format:o})=>({exclude:n,format:e=>{let i=t(e);if(n)for(let e of n)delete i[e];return{...i,...o(e)}},type:e})}},8875:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatLog=void 0,t.formatLog=function(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,logIndex:e.logIndex?Number(e.logIndex):null,transactionHash:e.transactionHash?e.transactionHash:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,...n?{args:t,eventName:n}:{}}}},76837:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatProof=void 0;let o=n(51999);t.formatProof=function(e){return{...e,balance:e.balance?BigInt(e.balance):void 0,nonce:e.nonce?(0,o.hexToNumber)(e.nonce):void 0,storageProof:e.storageProof?e.storageProof.map(e=>({...e,value:BigInt(e.value)})):void 0}}},93756:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.defineTransaction=t.formatTransaction=t.transactionType=void 0;let o=n(84008),i=n(82867);function formatTransaction(e){let n={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,chainId:e.chainId?(0,o.hexToNumber)(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?(0,o.hexToNumber)(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?t.transactionType[e.type]:void 0,typeHex:e.type?e.type:void 0,value:e.value?BigInt(e.value):void 0,v:e.v?BigInt(e.v):void 0};return n.yParity=(()=>{if(e.yParity)return Number(e.yParity);if("bigint"==typeof n.v){if(0n===n.v||27n===n.v)return 0;if(1n===n.v||28n===n.v)return 1;if(n.v>=35n)return n.v%2n===0n?1:0}})(),"legacy"===n.type&&(delete n.accessList,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas,delete n.yParity),"eip2930"===n.type&&(delete n.maxFeePerGas,delete n.maxPriorityFeePerGas),n}t.transactionType={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559"},t.formatTransaction=formatTransaction,t.defineTransaction=(0,i.defineFormatter)("transaction",formatTransaction)},10198:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.defineTransactionReceipt=t.formatTransactionReceipt=void 0;let o=n(84008),i=n(82867),s=n(8875),c=n(93756),l={"0x0":"reverted","0x1":"success"};function formatTransactionReceipt(e){return{...e,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,contractAddress:e.contractAddress?e.contractAddress:null,cumulativeGasUsed:e.cumulativeGasUsed?BigInt(e.cumulativeGasUsed):null,effectiveGasPrice:e.effectiveGasPrice?BigInt(e.effectiveGasPrice):null,gasUsed:e.gasUsed?BigInt(e.gasUsed):null,logs:e.logs?e.logs.map(e=>(0,s.formatLog)(e)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?(0,o.hexToNumber)(e.transactionIndex):null,status:e.status?l[e.status]:null,type:e.type?c.transactionType[e.type]||e.type:null}}t.formatTransactionReceipt=formatTransactionReceipt,t.defineTransactionReceipt=(0,i.defineFormatter)("transactionReceipt",formatTransactionReceipt)},77300:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.defineTransactionRequest=t.formatTransactionRequest=t.rpcTransactionType=void 0;let o=n(56945),i=n(82867);function formatTransactionRequest(e){return{...e,gas:void 0!==e.gas?(0,o.numberToHex)(e.gas):void 0,gasPrice:void 0!==e.gasPrice?(0,o.numberToHex)(e.gasPrice):void 0,maxFeePerGas:void 0!==e.maxFeePerGas?(0,o.numberToHex)(e.maxFeePerGas):void 0,maxPriorityFeePerGas:void 0!==e.maxPriorityFeePerGas?(0,o.numberToHex)(e.maxPriorityFeePerGas):void 0,nonce:void 0!==e.nonce?(0,o.numberToHex)(e.nonce):void 0,type:void 0!==e.type?t.rpcTransactionType[e.type]:void 0,value:void 0!==e.value?(0,o.numberToHex)(e.value):void 0}}t.rpcTransactionType={legacy:"0x0",eip2930:"0x1",eip1559:"0x2"},t.formatTransactionRequest=formatTransactionRequest,t.defineTransactionRequest=(0,i.defineFormatter)("transactionRequest",formatTransactionRequest)},45828:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAction=void 0,t.getAction=function(e,t,n){return o=>e[t.name||n]?.(o)??t(e,o)}},22834:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEventSelector=void 0;let o=n(37281),i=n(49952),s=n(35841),hash=e=>(0,s.keccak256)((0,o.toBytes)(e));t.getEventSelector=e=>hash((0,i.getEventSignature)(e))},49952:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEventSignature=void 0;let o=n(14683);t.getEventSignature=e=>(0,o.getFunctionSignature)(e)},9684:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFunctionSelector=void 0;let o=n(42013),i=n(37281),s=n(14683),c=n(35841),hash=e=>(0,c.keccak256)((0,i.toBytes)(e));t.getFunctionSelector=e=>(0,o.slice)(hash((0,s.getFunctionSignature)(e)),0,4)},14683:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFunctionSignature=void 0;let o=n(8270),i=n(19485);t.getFunctionSignature=e=>{let t="string"==typeof e?e:(0,o.formatAbiItem)(e);return(0,i.normalizeSignature)(t)}},56870:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHash=void 0;let o=n(29281),i=n(96711);t.isHash=function(e){return(0,o.isHex)(e)&&32===(0,i.size)(e)}},35841:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.keccak256=void 0;let o=n(67808),i=n(29281),s=n(37281),c=n(56945);t.keccak256=function(e,t){let n=(0,o.keccak_256)((0,i.isHex)(e,{strict:!1})?(0,s.toBytes)(e):e);return"bytes"===(t||"hex")?n:(0,c.toHex)(n)}},19485:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.normalizeSignature=void 0;let o=n(78498);t.normalizeSignature=function(e){let t=!0,n="",i=0,s="",c=!1;for(let o=0;o<e.length;o++){let l=e[o];if(["(",")",","].includes(l)&&(t=!0),"("===l&&i++,")"===l&&i--,t){if(0===i){if(" "===l&&["event","function",""].includes(s))s="";else if(s+=l,")"===l){c=!0;break}continue}if(" "===l){","!==e[o-1]&&","!==n&&",("!==n&&(n="",t=!1);continue}s+=l,n+=l}}if(!c)throw new o.BaseError("Unable to normalize signature.");return s}},86558:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=void 0;let o=n(83837),i=n(29281),s=n(37281),c=n(56945);t.ripemd160=function(e,t){let n=(0,o.ripemd160)((0,i.isHex)(e,{strict:!1})?(0,s.toBytes)(e):e);return"bytes"===(t||"hex")?n:(0,c.toHex)(n)}},84357:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.sha256=void 0;let o=n(92030),i=n(29281),s=n(37281),c=n(56945);t.sha256=function(e,t){let n=(0,o.sha256)((0,i.isHex)(e,{strict:!1})?(0,s.toBytes)(e):e);return"bytes"===(t||"hex")?n:(0,c.toHex)(n)}},51999:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.concat=t.extractFunctionParts=t.extractFunctionType=t.extractFunctionParams=t.extractFunctionName=t.isAddressEqual=t.isAddress=t.getAddress=t.getCreate2Address=t.getCreateAddress=t.getContractAddress=t.publicKeyToAddress=t.parseAccount=t.formatAbiParams=t.formatAbiItem=t.formatAbiItemWithArgs=t.encodePacked=t.parseAbiParameters=t.parseAbiParameter=t.parseAbiItem=t.parseAbi=t.getAbiItem=t.encodeFunctionResult=t.encodeFunctionData=t.encodeEventTopics=t.encodeErrorResult=t.encodeDeployData=t.encodeAbiParameters=t.decodeFunctionResult=t.decodeFunctionData=t.decodeEventLog=t.decodeErrorResult=t.decodeAbiParameters=t.validateTypedData=t.stringify=t.rpc=t.getSocket=t.integerRegex=t.bytesRegex=t.arrayRegex=t.getChainContractAddress=t.extractChain=t.defineChain=t.assertCurrentChain=t.offchainLookupSignature=t.offchainLookupAbiItem=t.offchainLookup=t.ccipFetch=t.buildRequest=t.isDeterministicError=void 0,t.getEstimateGasError=t.getContractError=t.getCallError=t.getNodeError=t.containsNodeError=t.fromRlp=t.hexToString=t.hexToNumber=t.hexToBigInt=t.hexToBool=t.fromHex=t.fromBytes=t.bytesToString=t.bytesToNumber=t.bytesToBool=t.bytesToBigint=t.bytesToBigInt=t.stringToHex=t.numberToHex=t.toHex=t.bytesToHex=t.boolToHex=t.stringToBytes=t.numberToBytes=t.hexToBytes=t.toBytes=t.boolToBytes=t.toRlp=t.extract=t.formatTransactionRequest=t.defineTransactionRequest=t.defineTransactionReceipt=t.formatLog=t.transactionType=t.formatTransaction=t.defineTransaction=t.formatBlock=t.defineBlock=t.trim=t.sliceHex=t.sliceBytes=t.slice=t.size=t.padHex=t.padBytes=t.pad=t.isHex=t.isBytes=t.concatHex=t.concatBytes=void 0,t.parseGwei=t.parseEther=t.parseUnits=t.formatUnits=t.formatGwei=t.formatEther=t.serializeAccessList=t.serializeTransaction=t.prepareTransactionRequest=t.parseTransaction=t.assertTransactionLegacy=t.assertTransactionEIP2930=t.assertTransactionEIP1559=t.assertRequest=t.getTransactionType=t.getSerializedTransactionType=t.hashMessage=t.verifyTypedData=t.verifyMessage=t.recoverTypedDataAddress=t.recoverPublicKey=t.recoverMessageAddress=t.recoverAddress=t.hashTypedData=t.ripemd160=t.sha256=t.keccak256=t.isHash=t.getFunctionSelector=t.getEventSelector=t.defineFormatter=t.getTransactionError=void 0;var o=n(24859);Object.defineProperty(t,"isDeterministicError",{enumerable:!0,get:function(){return o.isDeterministicError}}),Object.defineProperty(t,"buildRequest",{enumerable:!0,get:function(){return o.buildRequest}});var i=n(39978);Object.defineProperty(t,"ccipFetch",{enumerable:!0,get:function(){return i.ccipFetch}}),Object.defineProperty(t,"offchainLookup",{enumerable:!0,get:function(){return i.offchainLookup}}),Object.defineProperty(t,"offchainLookupAbiItem",{enumerable:!0,get:function(){return i.offchainLookupAbiItem}}),Object.defineProperty(t,"offchainLookupSignature",{enumerable:!0,get:function(){return i.offchainLookupSignature}});var s=n(54037);Object.defineProperty(t,"assertCurrentChain",{enumerable:!0,get:function(){return s.assertCurrentChain}});var c=n(57401);Object.defineProperty(t,"defineChain",{enumerable:!0,get:function(){return c.defineChain}});var l=n(80328);Object.defineProperty(t,"extractChain",{enumerable:!0,get:function(){return l.extractChain}});var u=n(27025);Object.defineProperty(t,"getChainContractAddress",{enumerable:!0,get:function(){return u.getChainContractAddress}});var d=n(72494);Object.defineProperty(t,"arrayRegex",{enumerable:!0,get:function(){return d.arrayRegex}}),Object.defineProperty(t,"bytesRegex",{enumerable:!0,get:function(){return d.bytesRegex}}),Object.defineProperty(t,"integerRegex",{enumerable:!0,get:function(){return d.integerRegex}});var p=n(66934);Object.defineProperty(t,"getSocket",{enumerable:!0,get:function(){return p.getSocket}}),Object.defineProperty(t,"rpc",{enumerable:!0,get:function(){return p.rpc}});var m=n(36774);Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return m.stringify}});var b=n(86931);Object.defineProperty(t,"validateTypedData",{enumerable:!0,get:function(){return b.validateTypedData}
68});var g=n(59530);Object.defineProperty(t,"decodeAbiParameters",{enumerable:!0,get:function(){return g.decodeAbiParameters}});var y=n(37113);Object.defineProperty(t,"decodeErrorResult",{enumerable:!0,get:function(){return y.decodeErrorResult}});var v=n(35813);Object.defineProperty(t,"decodeEventLog",{enumerable:!0,get:function(){return v.decodeEventLog}});var E=n(20587);Object.defineProperty(t,"decodeFunctionData",{enumerable:!0,get:function(){return E.decodeFunctionData}});var x=n(90181);Object.defineProperty(t,"decodeFunctionResult",{enumerable:!0,get:function(){return x.decodeFunctionResult}});var P=n(82121);Object.defineProperty(t,"encodeAbiParameters",{enumerable:!0,get:function(){return P.encodeAbiParameters}});var _=n(94335);Object.defineProperty(t,"encodeDeployData",{enumerable:!0,get:function(){return _.encodeDeployData}});var I=n(62863);Object.defineProperty(t,"encodeErrorResult",{enumerable:!0,get:function(){return I.encodeErrorResult}});var j=n(3540);Object.defineProperty(t,"encodeEventTopics",{enumerable:!0,get:function(){return j.encodeEventTopics}});var R=n(48635);Object.defineProperty(t,"encodeFunctionData",{enumerable:!0,get:function(){return R.encodeFunctionData}});var M=n(63736);Object.defineProperty(t,"encodeFunctionResult",{enumerable:!0,get:function(){return M.encodeFunctionResult}});var F=n(68340);Object.defineProperty(t,"getAbiItem",{enumerable:!0,get:function(){return F.getAbiItem}});var q=n(8270);Object.defineProperty(t,"parseAbi",{enumerable:!0,get:function(){return q.parseAbi}}),Object.defineProperty(t,"parseAbiItem",{enumerable:!0,get:function(){return q.parseAbiItem}}),Object.defineProperty(t,"parseAbiParameter",{enumerable:!0,get:function(){return q.parseAbiParameter}}),Object.defineProperty(t,"parseAbiParameters",{enumerable:!0,get:function(){return q.parseAbiParameters}});var H=n(8347);Object.defineProperty(t,"encodePacked",{enumerable:!0,get:function(){return H.encodePacked}});var z=n(79075);Object.defineProperty(t,"formatAbiItemWithArgs",{enumerable:!0,get:function(){return z.formatAbiItemWithArgs}});var W=n(26352);Object.defineProperty(t,"formatAbiItem",{enumerable:!0,get:function(){return W.formatAbiItem}}),Object.defineProperty(t,"formatAbiParams",{enumerable:!0,get:function(){return W.formatAbiParams}});var K=n(27558);Object.defineProperty(t,"parseAccount",{enumerable:!0,get:function(){return K.parseAccount}});var Q=n(35334);Object.defineProperty(t,"publicKeyToAddress",{enumerable:!0,get:function(){return Q.publicKeyToAddress}});var Z=n(63965);Object.defineProperty(t,"getContractAddress",{enumerable:!0,get:function(){return Z.getContractAddress}}),Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return Z.getCreateAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return Z.getCreate2Address}});var X=n(66830);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return X.getAddress}});var Y=n(9322);Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return Y.isAddress}});var J=n(64924);Object.defineProperty(t,"isAddressEqual",{enumerable:!0,get:function(){return J.isAddressEqual}});var et=n(51027);Object.defineProperty(t,"extractFunctionName",{enumerable:!0,get:function(){return et.extractFunctionName}}),Object.defineProperty(t,"extractFunctionParams",{enumerable:!0,get:function(){return et.extractFunctionParams}}),Object.defineProperty(t,"extractFunctionType",{enumerable:!0,get:function(){return et.extractFunctionType}}),Object.defineProperty(t,"extractFunctionParts",{enumerable:!0,get:function(){return et.extractFunctionParts}});var eo=n(22913);Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return eo.concat}}),Object.defineProperty(t,"concatBytes",{enumerable:!0,get:function(){return eo.concatBytes}}),Object.defineProperty(t,"concatHex",{enumerable:!0,get:function(){return eo.concatHex}});var ea=n(28360);Object.defineProperty(t,"isBytes",{enumerable:!0,get:function(){return ea.isBytes}});var ei=n(29281);Object.defineProperty(t,"isHex",{enumerable:!0,get:function(){return ei.isHex}});var es=n(51474);Object.defineProperty(t,"pad",{enumerable:!0,get:function(){return es.pad}}),Object.defineProperty(t,"padBytes",{enumerable:!0,get:function(){return es.padBytes}}),Object.defineProperty(t,"padHex",{enumerable:!0,get:function(){return es.padHex}});var ec=n(96711);Object.defineProperty(t,"size",{enumerable:!0,get:function(){return ec.size}}
68);var el=n(42013);Object.defineProperty(t,"slice",{enumerable:!0,get:function(){return el.slice}}),Object.defineProperty(t,"sliceBytes",{enumerable:!0,get:function(){return el.sliceBytes}}),Object.defineProperty(t,"sliceHex",{enumerable:!0,get:function(){return el.sliceHex}});var eu=n(41691);Object.defineProperty(t,"trim",{enumerable:!0,get:function(){return eu.trim}});var ed=n(5729);Object.defineProperty(t,"defineBlock",{enumerable:!0,get:function(){return ed.defineBlock}}),Object.defineProperty(t,"formatBlock",{enumerable:!0,get:function(){return ed.formatBlock}});var ef=n(93756);Object.defineProperty(t,"defineTransaction",{enumerable:!0,get:function(){return ef.defineTransaction}}),Object.defineProperty(t,"formatTransaction",{enumerable:!0,get:function(){return ef.formatTransaction}}),Object.defineProperty(t,"transactionType",{enumerable:!0,get:function(){return ef.transactionType}});var ep=n(8875);Object.defineProperty(t,"formatLog",{enumerable:!0,get:function(){return ep.formatLog}});var eh=n(10198);Object.defineProperty(t,"defineTransactionReceipt",{enumerable:!0,get:function(){return eh.defineTransactionReceipt}});var em=n(77300);Object.defineProperty(t,"defineTransactionRequest",{enumerable:!0,get:function(){return em.defineTransactionRequest}}),Object.defineProperty(t,"formatTransactionRequest",{enumerable:!0,get:function(){return em.formatTransactionRequest}});var eb=n(56725);Object.defineProperty(t,"extract",{enumerable:!0,get:function(){return eb.extract}});var eg=n(88377);Object.defineProperty(t,"toRlp",{enumerable:!0,get:function(){return eg.toRlp}});var ey=n(37281);Object.defineProperty(t,"boolToBytes",{enumerable:!0,get:function(){return ey.boolToBytes}}),Object.defineProperty(t,"toBytes",{enumerable:!0,get:function(){return ey.toBytes}}),Object.defineProperty(t,"hexToBytes",{enumerable:!0,get:function(){return ey.hexToBytes}}),Object.defineProperty(t,"numberToBytes",{enumerable:!0,get:function(){return ey.numberToBytes}}),Object.defineProperty(t,"stringToBytes",{enumerable:!0,get:function(){return ey.stringToBytes}});var ev=n(56945);Object.defineProperty(t,"boolToHex",{enumerable:!0,get:function(){return ev.boolToHex}}),Object.defineProperty(t,"bytesToHex",{enumerable:!0,get:function(){return ev.bytesToHex}}),Object.defineProperty(t,"toHex",{enumerable:!0,get:function(){return ev.toHex}}),Object.defineProperty(t,"numberToHex",{enumerable:!0,get:function(){return ev.numberToHex}}),Object.defineProperty(t,"stringToHex",{enumerable:!0,get:function(){return ev.stringToHex}});var ew=n(70185);Object.defineProperty(t,"bytesToBigInt",{enumerable:!0,get:function(){return ew.bytesToBigInt}}),Object.defineProperty(t,"bytesToBigint",{enumerable:!0,get:function(){return ew.bytesToBigInt}}),Object.defineProperty(t,"bytesToBool",{enumerable:!0,get:function(){return ew.bytesToBool}}),Object.defineProperty(t,"bytesToNumber",{enumerable:!0,get:function(){return ew.bytesToNumber}}),Object.defineProperty(t,"bytesToString",{enumerable:!0,get:function(){return ew.bytesToString}}),Object.defineProperty(t,"fromBytes",{enumerable:!0,get:function(){return ew.fromBytes}});var eE=n(84008);Object.defineProperty(t,"fromHex",{enumerable:!0,get:function(){return eE.fromHex}}),Object.defineProperty(t,"hexToBool",{enumerable:!0,get:function(){return eE.hexToBool}}),Object.defineProperty(t,"hexToBigInt",{enumerable:!0,get:function(){return eE.hexToBigInt}}),Object.defineProperty(t,"hexToNumber",{enumerable:!0,get:function(){return eE.hexToNumber}}),Object.defineProperty(t,"hexToString",{enumerable:!0,get:function(){return eE.hexToString}});var ex=n(74500);Object.defineProperty(t,"fromRlp",{enumerable:!0,get:function(){return ex.fromRlp}});var eC=n(8842);Object.defineProperty(t,"containsNodeError",{enumerable:!0,get:function(){return eC.containsNodeError}}),Object.defineProperty(t,"getNodeError",{enumerable:!0,get:function(){return eC.getNodeError}});var eP=n(91414);Object.defineProperty(t,"getCallError",{enumerable:!0,get:function(){return eP.getCallError}});var eT=n(59895);Object.defineProperty(t,"getContractError",{enumerable:!0,get:function(){return eT.getContractError}});var eA=n(35043);Object.defineProperty(t,"getEstimateGasError",{enumerable:!0,get:function(){return eA.getEstimateGasError}});var eS=n(53268);Object.defineProperty(t,"getTransactionError",{enumerable:!0,get:function(){return eS.getTransactionError}});var e_=n(82867);Object.defineProperty(t,"defineFormatter",{enumerable:!0,get:function(){return e_.defineFormatter}});var eI=n(22834);Object.defineProperty(t,"getEventSelector",{enumerable:!0,get:function(){return eI.getEventSelector}});var ek=n(9684);Object.defineProperty(t,"getFunctionSelector",{enumerable:!0,get:function(){return ek.getFunctionSelector}});var eO=n(56870);Object.defineProperty(t,"isHash",{enumerable:!0,get:function(){return eO.isHash}});var ej=n(35841);Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return ej.keccak256}});var eB=n(84357);Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return eB.sha256}});var eD=n(86558);Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return eD.ripemd160}});var eR=n(59454);Object.defineProperty(t,"hashTypedData",{enumerable:!0,get:function(){return eR.hashTypedData}
68});var eM=n(21116);Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return eM.recoverAddress}});var eN=n(62965);Object.defineProperty(t,"recoverMessageAddress",{enumerable:!0,get:function(){return eN.recoverMessageAddress}});var eF=n(41909);Object.defineProperty(t,"recoverPublicKey",{enumerable:!0,get:function(){return eF.recoverPublicKey}});var eU=n(10914);Object.defineProperty(t,"recoverTypedDataAddress",{enumerable:!0,get:function(){return eU.recoverTypedDataAddress}});var eL=n(49757);Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return eL.verifyMessage}});var e$=n(84182);Object.defineProperty(t,"verifyTypedData",{enumerable:!0,get:function(){return e$.verifyTypedData}});var eq=n(91628);Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return eq.hashMessage}});var eH=n(67076);Object.defineProperty(t,"getSerializedTransactionType",{enumerable:!0,get:function(){return eH.getSerializedTransactionType}});var ez=n(71040);Object.defineProperty(t,"getTransactionType",{enumerable:!0,get:function(){return ez.getTransactionType}});var eW=n(80525);Object.defineProperty(t,"assertRequest",{enumerable:!0,get:function(){return eW.assertRequest}});var eG=n(67539);Object.defineProperty(t,"assertTransactionEIP1559",{enumerable:!0,get:function(){return eG.assertTransactionEIP1559}}),Object.defineProperty(t,"assertTransactionEIP2930",{enumerable:!0,get:function(){return eG.assertTransactionEIP2930}}),Object.defineProperty(t,"assertTransactionLegacy",{enumerable:!0,get:function(){return eG.assertTransactionLegacy}});var eK=n(77889);Object.defineProperty(t,"parseTransaction",{enumerable:!0,get:function(){return eK.parseTransaction}});var eV=n(68094);Object.defineProperty(t,"prepareTransactionRequest",{enumerable:!0,get:function(){return eV.prepareTransactionRequest}});var eQ=n(36957);Object.defineProperty(t,"serializeTransaction",{enumerable:!0,get:function(){return eQ.serializeTransaction}});var eZ=n(35108);Object.defineProperty(t,"serializeAccessList",{enumerable:!0,get:function(){return eZ.serializeAccessList}});var eX=n(74869);Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return eX.formatEther}});var eY=n(67505);Object.defineProperty(t,"formatGwei",{enumerable:!0,get:function(){return eY.formatGwei}});var eJ=n(55934);Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return eJ.formatUnits}});var e0=n(22856);Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return e0.parseUnits}});var e1=n(70778);Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return e1.parseEther}});var e2=n(94041);Object.defineProperty(t,"parseGwei",{enumerable:!0,get:function(){return e2.parseGwei}})},27057:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.observe=t.cleanupCache=t.listenersCache=void 0,t.listenersCache=new Map,t.cleanupCache=new Map;let n=0;t.observe=function(e,o,i){let s=++n,getListeners=()=>t.listenersCache.get(e)||[],unsubscribe=()=>{let n=getListeners();t.listenersCache.set(e,n.filter(e=>e.id!==s))},unwatch=()=>{let n=t.cleanupCache.get(e);1===getListeners().length&&n&&n(),unsubscribe()},c=getListeners();if(t.listenersCache.set(e,[...c,{id:s,fns:o}]),c&&c.length>0)return unwatch;let l={};for(let e in o)l[e]=(...t)=>{let n=getListeners();if(0!==n.length)for(let o of n)o.fns[e]?.(...t)};let u=i(l);return"function"==typeof u&&t.cleanupCache.set(e,u),unwatch}},32815:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.poll=void 0;let o=n(86390);t.poll=function(e,{emitOnBegin:t,initialWaitTime:n,interval:i}){let s=!0,unwatch=()=>s=!1,watch=async()=>{let c;t&&(c=await e({unpoll:unwatch}));let l=await n?.(c)??i;await (0,o.wait)(l);let poll=async()=>{s&&(await e({unpoll:unwatch}),await (0,o.wait)(i),poll())};poll()};return watch(),unwatch}},32875:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createBatchScheduler=void 0;let n=new Map;t.createBatchScheduler=function({fn:e,id:t,shouldSplitBatch:o,wait:i=0,sort:s}){let exec=async()=>{let t=getScheduler();flush();let n=t.map(({args:e})=>e);0!==n.length&&e(n).then(e=>{s&&Array.isArray(e)&&e.sort(s);for(let n=0;n<t.length;n++){let{pendingPromise:o}=t[n];o.resolve?.([e[n],e])}}).catch(e=>{for(let n=0;n<t.length;n++){let{pendingPromise:o}=t[n];o.reject?.(e)}})},flush=()=>n.delete(t),getBatchedArgs=()=>getScheduler().map(({args:e})=>
68e),getScheduler=()=>n.get(t)||[],setScheduler=e=>n.set(t,[...getScheduler(),e]);return{flush,async schedule(e){let t={},n=new Promise((e,n)=>{t.resolve=e,t.reject=n}),s=o?.([...getBatchedArgs(),e]);s&&exec();let c=getScheduler().length>0;return c?setScheduler({args:e,pendingPromise:t}):(setScheduler({args:e,pendingPromise:t}),setTimeout(exec,i)),n}}}},68414:function(e,t){"use strict";function getCache(e){let buildCache=(e,t)=>({clear:()=>t.delete(e),get:()=>t.get(e),set:n=>t.set(e,n)}),n=buildCache(e,t.promiseCache),o=buildCache(e,t.responseCache);return{clear:()=>{n.clear(),o.clear()},promise:n,response:o}}async function withCache(e,{cacheKey:t,cacheTime:n=1/0}){let o=getCache(t),i=o.response.get();if(i&&n>0){let e=new Date().getTime()-i.created.getTime();if(e<n)return i.data}let s=o.promise.get();s||(s=e(),o.promise.set(s));try{let e=await s;return o.response.set({created:new Date,data:e}),e}finally{o.promise.clear()}}Object.defineProperty(t,"__esModule",{value:!0}),t.withCache=t.getCache=t.responseCache=t.promiseCache=void 0,t.promiseCache=new Map,t.responseCache=new Map,t.getCache=getCache,t.withCache=withCache},67783:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.withRetry=void 0;let o=n(86390);t.withRetry=function(e,{delay:t=100,retryCount:n=2,shouldRetry:i=()=>!0}={}){return new Promise((s,c)=>{let attemptRetry=async({count:l=0}={})=>{let retry=async({error:e})=>{let n="function"==typeof t?t({count:l,error:e}):t;n&&await (0,o.wait)(n),attemptRetry({count:l+1})};try{let t=await e();s(t)}catch(e){if(l<n&&await i({count:l,error:e}))return retry({error:e});c(e)}};attemptRetry()})}},52268:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.withTimeout=void 0,t.withTimeout=function(e,{errorInstance:t=Error("timed out"),timeout:n,signal:o}){return new Promise((i,s)=>{(async()=>{let c;try{let l=new AbortController;n>0&&(c=setTimeout(()=>{o?l.abort():s(t)},n)),i(await e({signal:l?.signal}))}catch(e){"AbortError"===e.name&&s(t),s(e)}finally{clearTimeout(c)}})()})}},72494:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.integerRegex=t.bytesRegex=t.arrayRegex=void 0,t.arrayRegex=/^(.*)\[([0-9]*)\]$/,t.bytesRegex=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,t.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)?$/},66934:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.rpc=t.getSocket=t.socketsCache=void 0;let o=n(54943),i=n(86617),s=n(32875),c=n(52268),l=n(36774),u=0;async function http(e,{body:t,fetchOptions:n={},timeout:o=1e4}){let{headers:s,method:d,signal:p}=n;try{let m;let b=await (0,c.withTimeout)(async({signal:i})=>{let c=await fetch(e,{...n,body:Array.isArray(t)?(0,l.stringify)(t.map(e=>({jsonrpc:"2.0",id:e.id??u++,...e}))):(0,l.stringify)({jsonrpc:"2.0",id:t.id??u++,...t}),headers:{...s,"Content-Type":"application/json"},method:d||"POST",signal:p||(o>0?i:void 0)});return c},{errorInstance:new i.TimeoutError({body:t,url:e}),timeout:o,signal:!0});if(m=b.headers.get("Content-Type")?.startsWith("application/json")?await b.json():await b.text(),!b.ok)throw new i.HttpRequestError({body:t,details:(0,l.stringify)(m.error)||b.statusText,headers:b.headers,status:b.status,url:e});return m}catch(n){if(n instanceof i.HttpRequestError||n instanceof i.TimeoutError)throw n;throw new i.HttpRequestError({body:t,details:n.message,url:e})}}async function getSocket(e){let n=t.socketsCache.get(e);if(n)return n;let{schedule:i}=(0,s.createBatchScheduler)({id:e,fn:async()=>{let i=new o.WebSocket(e),s=new Map,c=new Map,onMessage=({data:e})=>{let t=JSON.parse(e),n="eth_subscription"===t.method,o=n?t.params.subscription:t.id,i=n?c:s,l=i.get(o);l&&l({data:e}),n||i.delete(o)},onClose=()=>{t.socketsCache.delete(e),i.removeEventListener("close",onClose),i.removeEventListener("message",onMessage)};return i.addEventListener("close",onClose),i.addEventListener("message",onMessage),i.readyState===o.WebSocket.CONNECTING&&await new Promise((e,t)=>{i&&(i.onopen=e,i.onerror=t)}),n=Object.assign(i,{requests:s,subscriptions:c}),t.socketsCache.set(e,n),[n]}}),[c,[l]]=await i();return l}async function webSocketAsync(e,{body:n,timeout:o=1e4}){return(0,c.withTimeout)(()=>new Promise(o=>
68t.rpc.webSocket(e,{body:n,onResponse:o})),{errorInstance:new i.TimeoutError({body:n,url:e.url}),timeout:o})}t.socketsCache=new Map,t.getSocket=getSocket,t.rpc={http,webSocket:function(e,{body:t,onResponse:n}){if(e.readyState===e.CLOSED||e.readyState===e.CLOSING)throw new i.WebSocketRequestError({body:t,url:e.url,details:"Socket is closed."});let o=u++,callback=({data:i})=>{let s=JSON.parse(i);("number"!=typeof s.id||o===s.id)&&(n?.(s),"eth_subscribe"===t.method&&"string"==typeof s.result&&e.subscriptions.set(s.result,callback),"eth_unsubscribe"===t.method&&e.subscriptions.delete(t.params?.[0]))};return e.requests.set(o,callback),e.send(JSON.stringify({jsonrpc:"2.0",...t,id:o})),e},webSocketAsync}},24341:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.compactSignatureToHex=void 0;let o=n(61567),i=n(84008);t.compactSignatureToHex=function({r:e,yParityAndS:t}){return`0x${new o.secp256k1.Signature((0,i.hexToBigInt)(e),(0,i.hexToBigInt)(t)).toCompactHex()}`}},80381:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.compactSignatureToSignature=void 0;let o=n(37281),i=n(56945);t.compactSignatureToSignature=function({r:e,yParityAndS:t}){let n=(0,o.hexToBytes)(t),s=128&n[0]?28n:27n;return 28n===s&&(n[0]&=127),{r:e,s:(0,i.bytesToHex)(n),v:s}}},91628:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashMessage=void 0;let o=n(76770),i=n(22913),s=n(37281),c=n(35841);t.hashMessage=function(e,t){let n="string"==typeof e?(0,s.stringToBytes)(e):e.raw instanceof Uint8Array?e.raw:(0,s.toBytes)(e.raw),l=(0,s.stringToBytes)(`${o.presignMessagePrefix}${n.length}`);return(0,c.keccak256)((0,i.concat)([l,n]),t)}},59454:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashDomain=t.hashTypedData=void 0;let o=n(82121),i=n(22913),s=n(56945),c=n(35841),l=n(86931);function hashDomain({domain:e,types:t}){return hashStruct({data:e,primaryType:"EIP712Domain",types:t})}function hashStruct({data:e,primaryType:t,types:n}){let i=function encodeData({data:e,primaryType:t,types:n}){let i=[{type:"bytes32"}],l=[function({primaryType:e,types:t}){let n=(0,s.toHex)(function({primaryType:e,types:t}){let n="",o=function findTypeDependencies({primaryType:e,types:t},n=new Set){let o=e.match(/^\w*/u),i=o?.[0];if(n.has(i)||void 0===t[i])return n;for(let e of(n.add(i),t[i]))findTypeDependencies({primaryType:e.type,types:t},n);return n}({primaryType:e,types:t});o.delete(e);let i=[e,...Array.from(o).sort()];for(let e of i)n+=`${e}(${t[e].map(({name:e,type:t})=>`${t} ${e}`).join(",")})`;return n}({primaryType:e,types:t}));return(0,c.keccak256)(n)}({primaryType:t,types:n})];for(let u of n[t]){let[t,d]=function encodeField({types:e,name:t,type:n,value:i}){if(void 0!==e[n])return[{type:"bytes32"},(0,c.keccak256)(encodeData({data:i,primaryType:n,types:e}))];if("bytes"===n){let e=i.length%2?"0":"";return i=`0x${e+i.slice(2)}`,[{type:"bytes32"},(0,c.keccak256)(i)]}if("string"===n)return[{type:"bytes32"},(0,c.keccak256)((0,s.toHex)(i))];if(n.lastIndexOf("]")===n.length-1){let s=n.slice(0,n.lastIndexOf("[")),l=i.map(n=>encodeField({name:t,type:s,types:e,value:n}));return[{type:"bytes32"},(0,c.keccak256)((0,o.encodeAbiParameters)(l.map(([e])=>e),l.map(([,e])=>e)))]}return[{type:n},i]}({types:n,name:u.name,type:u.type,value:e[u.name]});i.push(t),l.push(d)}return(0,o.encodeAbiParameters)(i,l)}({data:e,primaryType:t,types:n});return(0,c.keccak256)(i)}t.hashTypedData=function({domain:e,message:t,primaryType:n,types:o}){let s=void 0===e?{}:e,u={EIP712Domain:(0,l.getTypesForEIP712Domain)({domain:s}),...o};(0,l.validateTypedData)({domain:s,message:t,primaryType:n,types:u});let d=["0x1901"];return s&&d.push(hashDomain({domain:s,types:u})),"EIP712Domain"!==n&&d.push(hashStruct({data:t,primaryType:n,types:u})),(0,c.keccak256)((0,i.concat)(d))},t.hashDomain=hashDomain},5922:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hexToCompactSignature=void 0;let o=n(61567),i=n(56945);t.hexToCompactSignature=function(e){let{r:t,s:n}=o.secp256k1.Signature.fromCompact(e.slice(2,130));return{r:(0,i.numberToHex)(t,{size:32}),yParityAndS:(0,i.numberToHex)(n,{size:32})}}},21286:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.hexToSignature=void 0;let o=n(61567),i=n(56945);t.hexToSignature=function(e){let{r:t,s:n}=o.secp256k1.Signature.fromCompact(e.slice(2,130)),s=BigInt(`0x${e.slice(130)}`);return{r:(0,i.numberToHex)(t,{size:32}),s:(0,i.numberToHex)(n,{size:32}),v:s}}},21116:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverAddress=void 0;let o=n(35334),i=n(41909);async function recoverAddress({hash:e,signature:t}){return(0,o.publicKeyToAddress)(await (0,i.recoverPublicKey)({hash:e,signature:t}))}t.recoverAddress=recoverAddress},62965:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverMessageAddress=void 0;let o=n(91628),i=n(21116);async function recoverMessageAddress({message:e,signature:t}){return(0,i.recoverAddress)({hash:(0,o.hashMessage)(e),signature:t})}t.recoverMessageAddress=recoverMessageAddress},41909:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverPublicKey=void 0;let o=n(29281),i=n(84008),s=n(56945);async function recoverPublicKey({hash:e,signature:t}){let c=(0,o.isHex)(t)?t:(0,s.toHex)(t),l=(0,o.isHex)(e)?e:(0,s.toHex)(e),u=(0,i.hexToNumber)(`0x${c.slice(130)}`);(0===u||1===u)&&(u+=27);let{secp256k1:d}=await Promise.resolve().then(()=>n(61567)),p=d.Signature.fromCompact(c.substring(2,130)).addRecoveryBit(u-27).recoverPublicKey(l.substring(2)).toHex(!1);return`0x${p}`}t.recoverPublicKey=recoverPublicKey},10914:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverTypedDataAddress=void 0;let o=n(59454),i=n(21116);async function recoverTypedDataAddress({domain:e,message:t,primaryType:n,signature:s,types:c}){return(0,i.recoverAddress)({hash:(0,o.hashTypedData)({domain:e,message:t,primaryType:n,types:c}),signature:s})}t.recoverTypedDataAddress=recoverTypedDataAddress},33743:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.signatureToCompactSignature=void 0;let o=n(51999);t.signatureToCompactSignature=function(e){let{r:t,s:n,v:i}=e,s=n;if(1n===i-27n){let e=(0,o.hexToBytes)(n);e[0]|=128,s=(0,o.bytesToHex)(e)}return{r:t,yParityAndS:s}}},44911:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.signatureToHex=void 0;let o=n(61567),i=n(84008),s=n(56945);t.signatureToHex=function({r:e,s:t,v:n}){return`0x${new o.secp256k1.Signature((0,i.hexToBigInt)(e),(0,i.hexToBigInt)(t)).toCompactHex()}${(0,s.toHex)(n).slice(2)}`}},49757:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyMessage=void 0;let o=n(66830),i=n(64924),s=n(62965);async function verifyMessage({address:e,message:t,signature:n}){return(0,i.isAddressEqual)((0,o.getAddress)(e),await (0,s.recoverMessageAddress)({message:t,signature:n}))}t.verifyMessage=verifyMessage},84182:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyTypedData=void 0;let o=n(66830),i=n(64924),s=n(10914);async function verifyTypedData({address:e,domain:t,message:n,primaryType:c,signature:l,types:u}){return(0,i.isAddressEqual)((0,o.getAddress)(e),await (0,s.recoverTypedDataAddress)({domain:t,message:n,primaryType:c,signature:l,types:u}))}t.verifyTypedData=verifyTypedData},36774:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stringify=void 0,t.stringify=(e,t,n)=>JSON.stringify(e,(e,n)=>{let o="bigint"==typeof n?n.toString():n;return"function"==typeof t?t(e,o):o},n)},80525:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertRequest=void 0;let o=n(27558),i=n(61235),s=n(48016),c=n(33841),l=n(9322);t.assertRequest=function(e){let{account:t,gasPrice:n,maxFeePerGas:u,maxPriorityFeePerGas:d,to:p}=e,m=t?(0,o.parseAccount)(t):void 0;if(m&&!(0,l.isAddress)(m.address))throw new i.InvalidAddressError({address:m.address});if(p&&!(0,l.isAddress)(p))throw new i.InvalidAddressError({address:p});if(void 0!==n&&(void 0!==u||void 0!==d))throw new c.FeeConflictError;if(u&&u>2n**256n-1n)throw new s.FeeCapTooHighError({maxFeePerGas:u});if(d&&u&&d>u)throw new s.TipAboveFeeCapError({maxFeePerGas:u,maxPriorityFeePerGas:d})}},67539:function(e,t,n){"use strict";
68Object.defineProperty(t,"__esModule",{value:!0}),t.assertTransactionLegacy=t.assertTransactionEIP2930=t.assertTransactionEIP1559=void 0;let o=n(61235),i=n(78498),s=n(99174),c=n(48016),l=n(9322);t.assertTransactionEIP1559=function(e){let{chainId:t,maxPriorityFeePerGas:n,gasPrice:u,maxFeePerGas:d,to:p}=e;if(t<=0)throw new s.InvalidChainIdError({chainId:t});if(p&&!(0,l.isAddress)(p))throw new o.InvalidAddressError({address:p});if(u)throw new i.BaseError("`gasPrice` is not a valid EIP-1559 Transaction attribute.");if(d&&d>2n**256n-1n)throw new c.FeeCapTooHighError({maxFeePerGas:d});if(n&&d&&n>d)throw new c.TipAboveFeeCapError({maxFeePerGas:d,maxPriorityFeePerGas:n})},t.assertTransactionEIP2930=function(e){let{chainId:t,maxPriorityFeePerGas:n,gasPrice:u,maxFeePerGas:d,to:p}=e;if(t<=0)throw new s.InvalidChainIdError({chainId:t});if(p&&!(0,l.isAddress)(p))throw new o.InvalidAddressError({address:p});if(n||d)throw new i.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(u&&u>2n**256n-1n)throw new c.FeeCapTooHighError({maxFeePerGas:u})},t.assertTransactionLegacy=function(e){let{chainId:t,maxPriorityFeePerGas:n,gasPrice:u,maxFeePerGas:d,to:p,accessList:m}=e;if(p&&!(0,l.isAddress)(p))throw new o.InvalidAddressError({address:p});if(void 0!==t&&t<=0)throw new s.InvalidChainIdError({chainId:t});if(n||d)throw new i.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(u&&u>2n**256n-1n)throw new c.FeeCapTooHighError({maxFeePerGas:u});if(m)throw new i.BaseError("`accessList` is not a valid Legacy Transaction attribute.")}},67076:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSerializedTransactionType=void 0;let o=n(33841),i=n(42013),s=n(84008);t.getSerializedTransactionType=function(e){let t=(0,i.sliceHex)(e,0,1);if("0x02"===t)return"eip1559";if("0x01"===t)return"eip2930";if("0x"!==t&&(0,s.hexToNumber)(t)>=192)return"legacy";throw new o.InvalidSerializedTransactionTypeError({serializedType:t})}},71040:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTransactionType=void 0;let o=n(33841);t.getTransactionType=function(e){if(e.type)return e.type;if(void 0!==e.maxFeePerGas||void 0!==e.maxPriorityFeePerGas)return"eip1559";if(void 0!==e.gasPrice)return void 0!==e.accessList?"eip2930":"legacy";throw new o.InvalidSerializableTransactionError({transaction:e})}},77889:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseAccessList=t.toTransactionArray=t.parseTransaction=void 0;let o=n(61235),i=n(33841),s=n(9322),c=n(29281),l=n(51474),u=n(41691),d=n(84008),p=n(74500),m=n(56870),b=n(67539),g=n(67076);function toTransactionArray(e){return(0,p.fromRlp)(`0x${e.slice(4)}`,"hex")}function parseAccessList(e){let t=[];for(let n=0;n<e.length;n++){let[i,c]=e[n];if(!(0,s.isAddress)(i))throw new o.InvalidAddressError({address:i});t.push({address:i,storageKeys:c.map(e=>(0,m.isHash)(e)?e:(0,u.trim)(e))})}return t}function parseEIP155Signature(e){let t=e.slice(-3),n="0x"===t[0]||0n===(0,d.hexToBigInt)(t[0])?27n:28n;return{r:(0,l.padHex)(t[1],{size:32}),s:(0,l.padHex)(t[2],{size:32}),v:n,yParity:27n===n?0:1}}t.parseTransaction=function(e){let t=(0,g.getSerializedTransactionType)(e);return"eip1559"===t?function(e){let t=toTransactionArray(e),[n,o,s,l,u,p,m,g,y,v,E,x]=t;if(!(9===t.length||12===t.length))throw new i.InvalidSerializedTransactionError({attributes:{chainId:n,nonce:o,maxPriorityFeePerGas:s,maxFeePerGas:l,gas:u,to:p,value:m,data:g,accessList:y,...t.length>9?{v,r:E,s:x}:{}},serializedTransaction:e,type:"eip1559"});let P={chainId:(0,d.hexToNumber)(n),type:"eip1559"};(0,c.isHex)(p)&&"0x"!==p&&(P.to=p),(0,c.isHex)(u)&&"0x"!==u&&(P.gas=(0,d.hexToBigInt)(u)),(0,c.isHex)(g)&&"0x"!==g&&(P.data=g),(0,c.isHex)(o)&&"0x"!==o&&(P.nonce=(0,d.hexToNumber)(o)),(0,c.isHex)(m)&&"0x"!==m&&(P.value=(0,d.hexToBigInt)(m)),(0,c.isHex)(l)&&"0x"!==l&&(P.maxFeePerGas=(0,d.hexToBigInt)(l)),(0,c.isHex)(s)&&"0x"!==s&&(P.maxPriorityFeePerGas=(0,d.hexToBigInt)(s)),0!==y.length&&"0x"!==y&&(P.accessList=parseAccessList(y)),(0,b.assertTransactionEIP1559)(P);let _=12===t.length?parseEIP155Signature(t):void 0;return{..._,...P}}(e):"eip2930"===t?function(e){let t=toTransactionArray(e),[n,o,s,l,u,p,m,g,y,v,E]=t;if(!(8===t.length||11===t.length))throw new i.InvalidSerializedTransactionError({attributes:{chainId:n,nonce:o,gasPrice:s,gas:l,to:u,value:p,data:m,accessList:g,...t.length>8?{v:y,r:v,s:E}:{}},serializedTransaction:e,type:"eip2930"});let x={chainId:(0,d.hexToNumber)(n),type:"eip2930"};(0,c.isHex)(u)&&"0x"!==u&&(x.to=u),(0,c.isHex)(l)&&"0x"!==l&&(x.gas=(0,d.hexToBigInt)(l)),(0,c.isHex)(m)&&"0x"!==m&&(x.data=m),(0,c.isHex)(o)&&"0x"!==o&&(x.nonce=(0,d.hexToNumber)(o)),(0,c.isHex)(p)&&"0x"!==p&&(x.value=(0,d.hexToBigInt)(p)),(0,c.isHex)(s)&&"0x"!==s&&(x.gasPrice=(0,d.hexToBigInt)(s)),0!==g.length&&"0x"!==g&&(x.accessList=parseAccessList(g)),(0,b.assertTransactionEIP2930)(x);let P=11===t.length?parseEIP155Signature(t):void 0;return{...P,...x}}(e):function(e){let t=(0,p.fromRlp)(e,"hex"),[n,o,s,l,u,m,g,y,v]=t;if(!(6===t.length||9===t.length))throw new i.InvalidSerializedTransactionError({attributes:{nonce:n,gasPrice:o,gas:s,to:l,value:u,data:m,...t.length>6?{v:g,r:y,s:v}:{}},serializedTransaction:e,type:"legacy"});let E={type:"legacy"};
68if((0,c.isHex)(l)&&"0x"!==l&&(E.to=l),(0,c.isHex)(s)&&"0x"!==s&&(E.gas=(0,d.hexToBigInt)(s)),(0,c.isHex)(m)&&"0x"!==m&&(E.data=m),(0,c.isHex)(n)&&"0x"!==n&&(E.nonce=(0,d.hexToNumber)(n)),(0,c.isHex)(u)&&"0x"!==u&&(E.value=(0,d.hexToBigInt)(u)),(0,c.isHex)(o)&&"0x"!==o&&(E.gasPrice=(0,d.hexToBigInt)(o)),(0,b.assertTransactionLegacy)(E),6===t.length)return E;let x=(0,c.isHex)(g)&&"0x"!==g?(0,d.hexToBigInt)(g):0n;if("0x"===v&&"0x"===y)return x>0&&(E.chainId=Number(x)),E;let P=Number((x-35n)/2n);if(P>0)E.chainId=P;else if(27n!==x&&28n!==x)throw new i.InvalidLegacyVError({v:x});return E.v=x,E.s=v,E.r=y,E}(e)},t.toTransactionArray=toTransactionArray,t.parseAccessList=parseAccessList},35108:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAccessList=void 0;let o=n(61235),i=n(33841),s=n(9322);t.serializeAccessList=function(e){if(!e||0===e.length)return[];let t=[];for(let n=0;n<e.length;n++){let{address:c,storageKeys:l}=e[n];for(let e=0;e<l.length;e++)if(l[e].length-2!=64)throw new i.InvalidStorageKeySizeError({storageKey:l[e]});if(!(0,s.isAddress)(c))throw new o.InvalidAddressError({address:c});t.push([c,l])}return t}},36957:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTransaction=void 0;let o=n(33841),i=n(22913),s=n(41691),c=n(56945),l=n(88377),u=n(67539),d=n(71040),p=n(35108);t.serializeTransaction=function(e,t){let n=(0,d.getTransactionType)(e);return"eip1559"===n?function(e,t){let{chainId:n,gas:o,nonce:d,to:m,value:b,maxFeePerGas:g,maxPriorityFeePerGas:y,accessList:v,data:E}=e;(0,u.assertTransactionEIP1559)(e);let x=(0,p.serializeAccessList)(v),P=[(0,c.toHex)(n),d?(0,c.toHex)(d):"0x",y?(0,c.toHex)(y):"0x",g?(0,c.toHex)(g):"0x",o?(0,c.toHex)(o):"0x",m??"0x",b?(0,c.toHex)(b):"0x",E??"0x",x];if(t){let e=0n===t.v?"0x":1n===t.v?(0,c.toHex)(1):27n===t.v?"0x":(0,c.toHex)(1);P.push(e,(0,s.trim)(t.r),(0,s.trim)(t.s))}return(0,i.concatHex)(["0x02",(0,l.toRlp)(P)])}(e,t):"eip2930"===n?function(e,t){let{chainId:n,gas:o,data:d,nonce:m,to:b,value:g,accessList:y,gasPrice:v}=e;(0,u.assertTransactionEIP2930)(e);let E=(0,p.serializeAccessList)(y),x=[(0,c.toHex)(n),m?(0,c.toHex)(m):"0x",v?(0,c.toHex)(v):"0x",o?(0,c.toHex)(o):"0x",b??"0x",g?(0,c.toHex)(g):"0x",d??"0x",E];if(t){let e=0n===t.v?"0x":1n===t.v?(0,c.toHex)(1):27n===t.v?"0x":(0,c.toHex)(1);x.push(e,(0,s.trim)(t.r),(0,s.trim)(t.s))}return(0,i.concatHex)(["0x01",(0,l.toRlp)(x)])}(e,t):function(e,t){let{chainId:n=0,gas:i,data:s,nonce:d,to:p,value:m,gasPrice:b}=e;(0,u.assertTransactionLegacy)(e);let g=[d?(0,c.toHex)(d):"0x",b?(0,c.toHex)(b):"0x",i?(0,c.toHex)(i):"0x",p??"0x",m?(0,c.toHex)(m):"0x",s??"0x"];if(t){let e=(()=>{if(n>0)return BigInt(2*n)+BigInt(35n+t.v-27n);if(t.v>=35n){let e=(t.v-35n)/2n;return e>0?t.v:27n+(35n===t.v?0n:1n)}let e=27n+(27n===t.v?0n:1n);if(t.v!==e)throw new o.InvalidLegacyVError({v:t.v});return e})();g=[...g,(0,c.toHex)(e),t.r,t.s]}else n>0&&(g=[...g,(0,c.toHex)(n),"0x","0x"]);return(0,l.toRlp)(g)}(e,t)}},86931:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.domainSeparator=t.getTypesForEIP712Domain=t.validateTypedData=void 0;let o=n(82521),i=n(61235),s=n(9322),c=n(96711),l=n(56945),u=n(72494),d=n(59454);function getTypesForEIP712Domain({domain:e}){return["string"==typeof e?.name&&{name:"name",type:"string"},e?.version&&{name:"version",type:"string"},"number"==typeof e?.chainId&&{name:"chainId",type:"uint256"},e?.verifyingContract&&{name:"verifyingContract",type:"address"},e?.salt&&{name:"salt",type:"bytes32"}].filter(Boolean)}t.validateTypedData=function({domain:e,message:t,primaryType:n,types:d}){let validateData=(e,t)=>{for(let n of e){let{name:e,type:p}=n,m=t[e],b=p.match(u.integerRegex);if(b&&("number"==typeof m||"bigint"==typeof m)){let[e,t,n]=b;(0,l.numberToHex)(m,{signed:"int"===t,size:parseInt(n)/8})}if("address"===p&&"string"==typeof m&&!(0,s.isAddress)(m))throw new i.InvalidAddressError({address:m});let g=p.match(u.bytesRegex);if(g){let[e,t]=g;if(t&&(0,c.size)(m)!==parseInt(t))throw new o.BytesSizeMismatchError({expectedSize:parseInt(t),givenSize:(0,c.size)(m)})}let y=d[p];y&&validateData(y,m)}};if(d.EIP712Domain&&e&&validateData(d.EIP712Domain,e),"EIP712Domain"!==n){let e=d[n];validateData(e,t)}},t.getTypesForEIP712Domain=getTypesForEIP712Domain,t.domainSeparator=function({domain:e}){return(0,d.hashDomain)({domain:e,types:{EIP712Domain:getTypesForEIP712Domain({domain:e})}})}},66615:function(e,t){"use strict";let n;
68Object.defineProperty(t,"__esModule",{value:!0}),t.uid=void 0;let o=256;t.uid=function(e=11){if(!n||o+e>512){n="",o=0;for(let e=0;e<256;e++)n+=(256+256*Math.random()|0).toString(16).substring(1)}return n.substring(o,o+++e)}},74869:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatEther=void 0;let o=n(71035),i=n(55934);t.formatEther=function(e,t="wei"){return(0,i.formatUnits)(e,o.etherUnits[t])}},67505:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatGwei=void 0;let o=n(71035),i=n(55934);t.formatGwei=function(e,t="wei"){return(0,i.formatUnits)(e,o.gweiUnits[t])}},55934:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatUnits=void 0,t.formatUnits=function(e,t){let n=e.toString(),o=n.startsWith("-");o&&(n=n.slice(1));let[i,s]=[(n=n.padStart(t,"0")).slice(0,n.length-t),n.slice(n.length-t)];return s=s.replace(/(0+)$/,""),`${o?"-":""}${i||"0"}${s?`.${s}`:""}`}},70778:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseEther=void 0;let o=n(71035),i=n(22856);t.parseEther=function(e,t="wei"){return(0,i.parseUnits)(e,o.etherUnits[t])}},94041:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseGwei=void 0;let o=n(71035),i=n(22856);t.parseGwei=function(e,t="wei"){return(0,i.parseUnits)(e,o.gweiUnits[t])}},22856:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseUnits=void 0,t.parseUnits=function(e,t){let[n,o="0"]=e.split("."),i=n.startsWith("-");if(i&&(n=n.slice(1)),o=o.replace(/(0+)$/,""),0===t)1===Math.round(Number(`.${o}`))&&(n=`${BigInt(n)+1n}`),o="";else if(o.length>t){let[e,i,s]=[o.slice(0,t-1),o.slice(t-1,t),o.slice(t)],c=Math.round(Number(`${i}.${s}`));(o=c>9?`${BigInt(e)+BigInt(1)}0`.padStart(e.length+1,"0"):`${e}${c}`).length>t&&(o=o.slice(1),n=`${BigInt(n)+1n}`),o=o.slice(0,t)}else o=o.padEnd(t,"0");return BigInt(`${i?"-":""}${n}${o}`)}},86390:function(e,t){"use strict";async function wait(e){return new Promise(t=>setTimeout(t,e))}Object.defineProperty(t,"__esModule",{value:!0}),t.wait=void 0,t.wait=wait},87462:function(e,t,n){"use strict";function _extends(){return(_extends=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}n.d(t,{Z:function(){return _extends}})},27499:function(e,t,n){"use strict";n.d(t,{FF:function(){return validateObject},S5:function(){return numberToBytesLE},Wd:function(){return equalBytes},bytesToNumberBE:function(){return bytesToNumberBE},ci:function(){return bytesToHex},dQ:function(){return bitMask},eV:function(){return concatBytes},hexToBytes:function(){return hexToBytes},iY:function(){return utf8ToBytes},n$:function(){return createHmacDrbg},ql:function(){return ensureBytes},tL:function(){return numberToBytesBE},ty:function(){return bytesToNumberLE}}),BigInt(0);let o=BigInt(1),i=BigInt(2),u8a=e=>e instanceof Uint8Array,s=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function bytesToHex(e){if(!u8a(e))throw Error("Uint8Array expected");let t="";for(let n=0;n<e.length;n++)t+=s[e[n]];return t}function hexToNumber(e){if("string"!=typeof e)throw Error("hex string expected, got "+typeof e);return BigInt(""===e?"0":`0x${e}`)}function hexToBytes(e){if("string"!=typeof e)throw Error("hex string expected, got "+typeof e);if(e.length%2)throw Error("hex string is invalid: unpadded "+e.length);let t=new Uint8Array(e.length/2);for(let n=0;n<t.length;n++){let o=2*n,i=e.slice(o,o+2),s=Number.parseInt(i,16);if(Number.isNaN(s)||s<0)throw Error("invalid byte sequence");t[n]=s}return t}function bytesToNumberBE(e){return hexToNumber(bytesToHex(e))}function bytesToNumberLE(e){if(!u8a(e))throw Error("Uint8Array expected");return hexToNumber(bytesToHex(Uint8Array.from(e).reverse()))}let numberToBytesBE=(e,t)=>hexToBytes(e.toString(16).padStart(2*t,"0")),numberToBytesLE=(e,t)=>numberToBytesBE(e,t).reverse();function ensureBytes(e,t,n){let o;if("string"==typeof t)try{o=hexToBytes(t)}catch(n){throw Error(`${e} must be valid hex string, got "${t}". Cause: ${n}`)}else if(u8a(t))o=Uint8Array.from(t);else throw Error(`${e} must be hex string or Uint8Array`);let i=o.length;if("number"==typeof n&&i!==n)throw Error(`${e} expected ${n} bytes, got ${i}`);return o}function concatBytes(...e){let t=new Uint8Array(e.reduce((e,t)=>
68e+t.length,0)),n=0;return e.forEach(e=>{if(!u8a(e))throw Error("Uint8Array expected");t.set(e,n),n+=e.length}),t}function equalBytes(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function utf8ToBytes(e){if("string"!=typeof e)throw Error(`utf8ToBytes expected string, got ${typeof e}`);return new TextEncoder().encode(e)}let bitMask=e=>(i<<BigInt(e-1))-o,u8n=e=>new Uint8Array(e),u8fr=e=>Uint8Array.from(e);function createHmacDrbg(e,t,n){if("number"!=typeof e||e<2)throw Error("hashLen must be a number");if("number"!=typeof t||t<2)throw Error("qByteLen must be a number");if("function"!=typeof n)throw Error("hmacFn must be a function");let o=u8n(e),i=u8n(e),s=0,reset=()=>{o.fill(1),i.fill(0),s=0},h=(...e)=>n(i,o,...e),reseed=(e=u8n())=>{i=h(u8fr([0]),e),o=h(),0!==e.length&&(i=h(u8fr([1]),e),o=h())},gen=()=>{if(s++>=1e3)throw Error("drbg: tried 1000 values");let e=0,n=[];for(;e<t;){o=h();let t=o.slice();n.push(t),e+=o.length}return concatBytes(...n)};return(e,t)=>{let n;for(reset(),reseed(e);!(n=t(gen()));)reseed();return reset(),n}}let c={bigint:e=>"bigint"==typeof e,function:e=>"function"==typeof e,boolean:e=>"boolean"==typeof e,string:e=>"string"==typeof e,isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>"function"==typeof e&&Number.isSafeInteger(e.outputLen)};function validateObject(e,t,n={}){let checkField=(t,n,o)=>{let i=c[n];if("function"!=typeof i)throw Error(`Invalid validator "${n}", expected function`);let s=e[t];if((!o||void 0!==s)&&!i(s,e))throw Error(`Invalid param ${String(t)}=${s} (${typeof s}), expected ${n}`)};for(let[e,n]of Object.entries(t))checkField(e,n,!1);for(let[e,t]of Object.entries(n))checkField(e,t,!0);return e}},36206:function(e,t,n){"use strict";function $e42e1063c40fb3ef$export$b9ecd428b558ff10(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(null==e||e(o),!1===n||!o.defaultPrevented)return null==t?void 0:t(o)}}n.d(t,{M:function(){return $e42e1063c40fb3ef$export$b9ecd428b558ff10}})},65936:function(e,t,n){"use strict";n.d(t,{B:function(){return $e02a7d9cb1dc128c$export$c74125a8e3af6bb2}});var o=n(67294),i=n(25360),s=n(28771),c=n(88426);function $e02a7d9cb1dc128c$export$c74125a8e3af6bb2(e){let t=e+"CollectionProvider",[n,l]=(0,i.b)(t),[u,d]=n(t,{collectionRef:{current:null},itemMap:new Map}),p=e+"CollectionSlot",m=o.forwardRef((e,t)=>{let{scope:n,children:i}=e,l=d(p,n),u=(0,s.e)(t,l.collectionRef);return o.createElement(c.g7,{ref:u},i)}),b=e+"CollectionItemSlot",g="data-radix-collection-item",y=o.forwardRef((e,t)=>{let{scope:n,children:i,...l}=e,u=o.useRef(null),p=(0,s.e)(t,u),m=d(b,n);return o.useEffect(()=>(m.itemMap.set(u,{ref:u,...l}),()=>void m.itemMap.delete(u))),o.createElement(c.g7,{[g]:"",ref:p},i)});return[{Provider:e=>{let{scope:t,children:n}=e,i=o.useRef(null),s=o.useRef(new Map).current;return o.createElement(u,{scope:t,itemMap:s,collectionRef:i},n)},Slot:m,ItemSlot:y},function(t){let n=d(e+"CollectionConsumer",t),i=o.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${g}]`)),o=Array.from(n.itemMap.values()),i=o.sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current));return i},[n.collectionRef,n.itemMap]);return i},l]}},28771:function(e,t,n){"use strict";n.d(t,{F:function(){return $6ed0406888f73fc4$export$43e446d32b3d21af},e:function(){return $6ed0406888f73fc4$export$c7b2cbe3552a0d05}});var o=n(67294);function $6ed0406888f73fc4$export$43e446d32b3d21af(...e){return t=>e.forEach(e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)})}function $6ed0406888f73fc4$export$c7b2cbe3552a0d05(...e){return(0,o.useCallback)($6ed0406888f73fc4$export$43e446d32b3d21af(...e),e)}},25360:function(e,t,n){"use strict";n.d(t,{b:function(){return $c512c27ab02ef895$export$50c7b4e9d9f19c1},k:function(){return $c512c27ab02ef895$export$fd42f52fd3ae1109}});var o=n(67294);function $c512c27ab02ef895$export$fd42f52fd3ae1109(e,t){let n=(0,o.createContext)(t);function Provider(e){let{children:t,...i}=e,s=(0,o.useMemo)(()=>i,Object.values(i));return(0,o.createElement)(n.Provider,{value:s},t)}return Provider.displayName=e+"Provider",[Provider,function(i){let s=(0,o.useContext)(n);if(s)return s;if(void 0!==t)return t;throw Error(`\`${i}\` must be used within \`${e}\``)}]}function $c512c27ab02ef895$export$50c7b4e9d9f19c1(e,t=[]){let n=[],createScope=()=>{let t=n.map(e=>(0,o.createContext)(e));return function(n){let i=(null==n?void 0:n[e])||t;return(0,o.useMemo)(()=>({[`__scope${e}`]:{...n,[e]:i}}),[n,i])}};return createScope.scopeName=e,[function(t,i){let s=(0,o.createContext)(i),c=n.length;function Provider(t){let{scope:n,children:i,...l}=t,u=(null==n?void 0:n[e][c])||s,d=(0,o.useMemo)(()=>l,Object.values(l));return(0,o.createElement)(u.Provider,{value:d},i)}return n=[...n,i],Provider.displayName=t+"Provider",[Provider,function(n,l){let u=(null==l?void 0:l[e][c])||s,d=(0,o.useContext)(u);if(d)return d;if(void 0!==i)return i;throw Error(`\`${n}\` must be used within \`${t}\``)}]},function(...e){let t=e[0];if(1===e.length)return t;let createScope1=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let i=n.reduce((t,{useScope:n,scopeName:o})=>{let i=n(e),s=i[`__scope${o}`];return{...t,...s}},{});return(0,o.useMemo)(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return createScope1.scopeName=t.scopeName,createScope1}(createScope,...t)]}},46063:function(e,t,n){"use strict";let o;n.d(t,{I0:function(){return v},XB:function(){return b},fC:function(){return y}});var i=n(87462),s=n(67294),c=n(36206),l=n(75320),u=n(28771),d=n(79698);
68let p="dismissableLayer.update",m=(0,s.createContext)({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),b=(0,s.forwardRef)((e,t)=>{var n;let{disableOutsidePointerEvents:b=!1,onEscapeKeyDown:g,onPointerDownOutside:y,onFocusOutside:v,onInteractOutside:E,onDismiss:x,...P}=e,_=(0,s.useContext)(m),[I,j]=(0,s.useState)(null),R=null!==(n=null==I?void 0:I.ownerDocument)&&void 0!==n?n:null==globalThis?void 0:globalThis.document,[,M]=(0,s.useState)({}),F=(0,u.e)(t,e=>j(e)),q=Array.from(_.layers),[H]=[..._.layersWithOutsidePointerEventsDisabled].slice(-1),z=q.indexOf(H),W=I?q.indexOf(I):-1,K=_.layersWithOutsidePointerEventsDisabled.size>0,Q=W>=z,Z=function(e,t=null==globalThis?void 0:globalThis.document){let n=(0,d.W)(e),o=(0,s.useRef)(!1),i=(0,s.useRef)(()=>{});return(0,s.useEffect)(()=>{let handlePointerDown=e=>{if(e.target&&!o.current){let o={originalEvent:e};function handleAndDispatchPointerDownOutsideEvent(){$5cb92bef7577960e$var$handleAndDispatchCustomEvent("dismissableLayer.pointerDownOutside",n,o,{discrete:!0})}"touch"===e.pointerType?(t.removeEventListener("click",i.current),i.current=handleAndDispatchPointerDownOutsideEvent,t.addEventListener("click",i.current,{once:!0})):handleAndDispatchPointerDownOutsideEvent()}else t.removeEventListener("click",i.current);o.current=!1},e=window.setTimeout(()=>{t.addEventListener("pointerdown",handlePointerDown)},0);return()=>{window.clearTimeout(e),t.removeEventListener("pointerdown",handlePointerDown),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>o.current=!0}}(e=>{let t=e.target,n=[..._.branches].some(e=>e.contains(t));!Q||n||(null==y||y(e),null==E||E(e),e.defaultPrevented||null==x||x())},R),X=function(e,t=null==globalThis?void 0:globalThis.document){let n=(0,d.W)(e),o=(0,s.useRef)(!1);return(0,s.useEffect)(()=>{let handleFocus=e=>{e.target&&!o.current&&$5cb92bef7577960e$var$handleAndDispatchCustomEvent("dismissableLayer.focusOutside",n,{originalEvent:e},{discrete:!1})};return t.addEventListener("focusin",handleFocus),()=>t.removeEventListener("focusin",handleFocus)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}(e=>{let t=e.target,n=[..._.branches].some(e=>e.contains(t));n||(null==v||v(e),null==E||E(e),e.defaultPrevented||null==x||x())},R);return!function(e,t=null==globalThis?void 0:globalThis.document){let n=(0,d.W)(e);(0,s.useEffect)(()=>{let handleKeyDown=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",handleKeyDown),()=>t.removeEventListener("keydown",handleKeyDown)},[n,t])}(e=>{let t=W===_.layers.size-1;t&&(null==g||g(e),!e.defaultPrevented&&x&&(e.preventDefault(),x()))},R),(0,s.useEffect)(()=>{if(I)return b&&(0===_.layersWithOutsidePointerEventsDisabled.size&&(o=R.body.style.pointerEvents,R.body.style.pointerEvents="none"),_.layersWithOutsidePointerEventsDisabled.add(I)),_.layers.add(I),$5cb92bef7577960e$var$dispatchUpdate(),()=>{b&&1===_.layersWithOutsidePointerEventsDisabled.size&&(R.body.style.pointerEvents=o)}},[I,R,b,_]),(0,s.useEffect)(()=>()=>{I&&(_.layers.delete(I),_.layersWithOutsidePointerEventsDisabled.delete(I),$5cb92bef7577960e$var$dispatchUpdate())},[I,_]),(0,s.useEffect)(()=>{let handleUpdate=()=>M({});return document.addEventListener(p,handleUpdate),()=>document.removeEventListener(p,handleUpdate)},[]),(0,s.createElement)(l.WV.div,(0,i.Z)({},P,{ref:F,style:{pointerEvents:K?Q?"auto":"none":void 0,...e.style},onFocusCapture:(0,c.M)(e.onFocusCapture,X.onFocusCapture),onBlurCapture:(0,c.M)(e.onBlurCapture,X.onBlurCapture),onPointerDownCapture:(0,c.M)(e.onPointerDownCapture,Z.onPointerDownCapture)}))}),g=(0,s.forwardRef)((e,t)=>{let n=(0,s.useContext)(m),o=(0,s.useRef)(null),c=(0,u.e)(t,o);return(0,s.useEffect)(()=>{let e=o.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,s.createElement)(l.WV.div,(0,i.Z)({},e,{ref:c}))});function $5cb92bef7577960e$var$dispatchUpdate(){let e=new CustomEvent(p);document.dispatchEvent(e)}function $5cb92bef7577960e$var$handleAndDispatchCustomEvent(e,t,n,{discrete:o}){let i=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),o?(0,l.jH)(i,s):i.dispatchEvent(s)}let y=b,v=g},42651:function(e,t,n){"use strict";n.d(t,{h:function(){return l}});var o=n(87462),i=n(67294),s=n(73935),c=n(75320);let l=(0,i.forwardRef)((e,t)=>{var n;
68let{container:l=null==globalThis?void 0:null===(n=globalThis.document)||void 0===n?void 0:n.body,...u}=e;return l?s.createPortal((0,i.createElement)(c.WV.div,(0,o.Z)({},u,{ref:t})),l):null})},29115:function(e,t,n){"use strict";n.d(t,{z:function(){return $921a889cee6df7e8$export$99c2b779aa4e8b8b}});var o=n(67294),i=n(73935),s=n(28771),c=n(9981);let $921a889cee6df7e8$export$99c2b779aa4e8b8b=e=>{let{present:t,children:n}=e,l=function(e){var t;let[n,s]=(0,o.useState)(),l=(0,o.useRef)({}),u=(0,o.useRef)(e),d=(0,o.useRef)("none"),p=e?"mounted":"unmounted",[m,b]=(t={mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}},(0,o.useReducer)((e,n)=>{let o=t[e][n];return null!=o?o:e},p));return(0,o.useEffect)(()=>{let e=$921a889cee6df7e8$var$getAnimationName(l.current);d.current="mounted"===m?e:"none"},[m]),(0,c.b)(()=>{let t=l.current,n=u.current,o=n!==e;if(o){let o=d.current,i=$921a889cee6df7e8$var$getAnimationName(t);e?b("MOUNT"):"none"===i||(null==t?void 0:t.display)==="none"?b("UNMOUNT"):n&&o!==i?b("ANIMATION_OUT"):b("UNMOUNT"),u.current=e}},[e,b]),(0,c.b)(()=>{if(n){let handleAnimationEnd=e=>{let t=$921a889cee6df7e8$var$getAnimationName(l.current),o=t.includes(e.animationName);e.target===n&&o&&(0,i.flushSync)(()=>b("ANIMATION_END"))},handleAnimationStart=e=>{e.target===n&&(d.current=$921a889cee6df7e8$var$getAnimationName(l.current))};return n.addEventListener("animationstart",handleAnimationStart),n.addEventListener("animationcancel",handleAnimationEnd),n.addEventListener("animationend",handleAnimationEnd),()=>{n.removeEventListener("animationstart",handleAnimationStart),n.removeEventListener("animationcancel",handleAnimationEnd),n.removeEventListener("animationend",handleAnimationEnd)}}b("ANIMATION_END")},[n,b]),{isPresent:["mounted","unmountSuspended"].includes(m),ref:(0,o.useCallback)(e=>{e&&(l.current=getComputedStyle(e)),s(e)},[])}}(t),u="function"==typeof n?n({present:l.isPresent}):o.Children.only(n),d=(0,s.e)(l.ref,u.ref),p="function"==typeof n;return p||l.isPresent?(0,o.cloneElement)(u,{ref:d}):null};function $921a889cee6df7e8$var$getAnimationName(e){return(null==e?void 0:e.animationName)||"none"}$921a889cee6df7e8$export$99c2b779aa4e8b8b.displayName="Presence"},75320:function(e,t,n){"use strict";n.d(t,{WV:function(){return l},jH:function(){return $8927f6f2acc4f386$export$6d1a0317bde7de7f}});var o=n(87462),i=n(67294),s=n(73935),c=n(88426);let l=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{let n=(0,i.forwardRef)((e,n)=>{let{asChild:s,...l}=e,u=s?c.g7:t;return(0,i.useEffect)(()=>{window[Symbol.for("radix-ui")]=!0},[]),(0,i.createElement)(u,(0,o.Z)({},l,{ref:n}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function $8927f6f2acc4f386$export$6d1a0317bde7de7f(e,t){e&&(0,s.flushSync)(()=>
68e.dispatchEvent(t))}},88426:function(e,t,n){"use strict";n.d(t,{g7:function(){return c}});var o=n(87462),i=n(67294),s=n(28771);let c=(0,i.forwardRef)((e,t)=>{let{children:n,...s}=e,c=i.Children.toArray(n),u=c.find($5e63c961fc1ce211$var$isSlottable);if(u){let e=u.props.children,n=c.map(t=>t!==u?t:i.Children.count(e)>1?i.Children.only(null):(0,i.isValidElement)(e)?e.props.children:null);return(0,i.createElement)(l,(0,o.Z)({},s,{ref:t}),(0,i.isValidElement)(e)?(0,i.cloneElement)(e,void 0,n):null)}return(0,i.createElement)(l,(0,o.Z)({},s,{ref:t}),n)});c.displayName="Slot";let l=(0,i.forwardRef)((e,t)=>{let{children:n,...o}=e;return(0,i.isValidElement)(n)?(0,i.cloneElement)(n,{...function(e,t){let n={...t};for(let o in t){let i=e[o],s=t[o],c=/^on[A-Z]/.test(o);c?i&&s?n[o]=(...e)=>{s(...e),i(...e)}:i&&(n[o]=i):"style"===o?n[o]={...i,...s}:"className"===o&&(n[o]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}(o,n.props),ref:t?(0,s.F)(t,n.ref):n.ref}):i.Children.count(n)>1?i.Children.only(null):null});l.displayName="SlotClone";let $5e63c961fc1ce211$export$d9f1ccf0bdb05d45=({children:e})=>(0,i.createElement)(i.Fragment,null,e);function $5e63c961fc1ce211$var$isSlottable(e){return(0,i.isValidElement)(e)&&e.type===$5e63c961fc1ce211$export$d9f1ccf0bdb05d45}},79698:function(e,t,n){"use strict";n.d(t,{W:function(){return $b1b2314f5f9a1d84$export$25bec8c6f54ee79a}});var o=n(67294);function $b1b2314f5f9a1d84$export$25bec8c6f54ee79a(e){let t=(0,o.useRef)(e);return(0,o.useEffect)(()=>{t.current=e}),(0,o.useMemo)(()=>(...e)=>{var n;return null===(n=t.current)||void 0===n?void 0:n.call(t,...e)},[])}},77342:function(e,t,n){"use strict";n.d(t,{T:function(){return $71cd76cc60e0454e$export$6f32135080cb4c3}});var o=n(67294),i=n(79698);function $71cd76cc60e0454e$export$6f32135080cb4c3({prop:e,defaultProp:t,onChange:n=()=>{}}){let[s,c]=function({defaultProp:e,onChange:t}){let n=(0,o.useState)(e),[s]=n,c=(0,o.useRef)(s),l=(0,i.W)(t);return(0,o.useEffect)(()=>{c.current!==s&&(l(s),c.current=s)},[s,c,l]),n}({defaultProp:t,onChange:n}),l=void 0!==e,u=l?e:s,d=(0,i.W)(n),p=(0,o.useCallback)(t=>{if(l){let n="function"==typeof t?t(e):t;n!==e&&d(n)}else c(t)},[l,e,c,d]);return[u,p]}},9981:function(e,t,n){"use strict";n.d(t,{b:function(){return i}});var o=n(67294);let i=(null==globalThis?void 0:globalThis.document)?o.useLayoutEffect:()=>{}},96219:function(e,t,n){"use strict";n.d(t,{T:function(){return c}});var o=n(87462),i=n(67294),s=n(75320);let c=(0,i.forwardRef)((e,t)=>(0,i.createElement)(s.WV.span,(0,o.Z)({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})))},95016:function(e,t,n){"use strict";n.d(t,{I:function(){return o}});var o=`{
69  "connect_wallet": {
70    "label": "Connect Wallet",
71    "wrong_network": {
72      "label": "Wrong network"
73    }
74  },
75
76  "intro": {
77    "title": "What is a Wallet?",
78    "description": "A wallet is used to send, receive, store, and display digital assets. It's also a new way to log in, without needing to create new accounts and passwords on every website.",
79    "digital_asset": {
80      "title": "A Home for your Digital Assets",
81      "description": "Wallets are used to send, receive, store, and display digital assets like Ethereum and NFTs."
82    },
83    "login": {
84      "title": "A New Way to Log In",
85      "description": "Instead of creating new accounts and passwords on every website, just connect your wallet."
86    },
87    "get": {
88      "label": "Get a Wallet"
89    },
90    "learn_more": {
91      "label": "Learn More"
92    }
93  },
94
95  "sign_in": {
96    "label": "Verify your account",
97    "description": "To finish connecting, you must sign a message in your wallet to verify that you are the owner of this account.",
98    "message": {
99      "send": "Sign message",
100      "preparing": "Preparing message...",
101      "cancel": "Cancel",
102      "preparing_error": "Error preparing message, please retry!"
103    },
104    "signature": {
105      "waiting": "Waiting for signature...",
106      "verifying": "Verifying signature...",
107      "signing_error": "Error signing message, please retry!",
108      "verifying_error": "Error verifying signature, please retry!",
109      "oops_error": "Oops, something went wrong!"
110    }
111  },
112
113  "connect": {
114    "label": "Connect",
115    "title": "Connect a Wallet",
116    "new_to_ethereum": {
117      "description": "New to Ethereum wallets?",
118      "learn_more": {
119        "label": "Learn More"
120      }
121    },
122    "learn_more": {
123      "label": "Learn more"
124    },
125    "recent": "Recent",
126    "status": {
127      "opening": "Opening %{wallet}...",
128      "connecting": "Connecting",
129      "connect_mobile": "Continue in %{wallet}",
130      "not_installed": "%{wallet} is not installed",
131      "not_available": "%{wallet} is not available",
132      "confirm": "Confirm connection in the extension",
133      "confirm_mobile": "Accept connection request in the wallet"
134    },
135    "secondary_action": {
136      "get": {
137        "description": "Don't have %{wallet}?",
138        "label": "GET"
139      },
140      "install": {
141        "label": "INSTALL"
142      },
143      "retry": {
144        "label": "RETRY"
145      }
146    },
147    "walletconnect": {
148      "description": {
149        "full": "Need the official WalletConnect modal?",
150        "compact": "Need the WalletConnect modal?"
151      },
152      "open": {
153        "label": "OPEN"
154      }
155    }
156  },
157
158  "connect_scan": {
159    "title": "Scan with %{wallet}",
160    "fallback_title": "Scan with your phone"
161  },
162
163  "connector_group": {
164    "recommended": "Recommended",
165    "other": "Other",
166    "popular": "Popular",
167    "more": "More",
168    "others": "Others"
169  },
170
171  "get": {
172    "title": "Get a Wallet",
173    "action": {
174      "label": "GET"
175    },
176    "mobile": {
177      "description": "Mobile Wallet"
178    },
179    "extension": {
180      "description": "Browser Extension"
181    },
182    "mobile_and_extension": {
183      "description": "Mobile Wallet and Extension"
184    },
185    "mobile_and_desktop": {
186      "description": "Mobile and Desktop Wallet"
187    },
188    "looking_for": {
189      "title": "Not what you're looking for?",
190      "mobile": {
191        "description": "Select a wallet on the main screen to get started with a different wallet provider."
192      },
193      "desktop": {
194        "compact_description": "Select a wallet on the main screen to get started with a different wallet provider.",
195        "wide_description": "Select a wallet on the left to get started with a different wallet provider."
196      }
197    }
198  },
199
200  "get_options": {
201    "title": "Get started with %{wallet}",
202    "short_title": "Get %{wallet}",
203    "mobile": {
204      "title": "%{wallet} for Mobile",
205      "description": "Use the mobile wallet to explore the world of Ethereum.",
206      "download": {
207        "label": "Get the app"
208      }
209    },
210    "extension": {
211      "title": "%{wallet} for %{browser}",
212      "description": "Access your wallet right from your favorite web browser.",
213      "download": {
214        "label": "Add to %{browser}"
215      }
216    },
217    "desktop": {
218      "title": "%{wallet} for %{platform}",
219      "description": "Access your wallet natively from your powerful desktop.",
220      "download": {
221        "label": "Add to %{platform}"
222      }
223    }
224  },
225
226  "get_mobile": {
227    "title": "Install %{wallet}",
228    "description": "Scan with your phone to download on iOS or Android",
229    "continue": {
230      "label": "Continue"
231    }
232  },
233
234  "get_instructions": {
235    "mobile": {
236      "connect": {
237        "label": "Connect"
238      },
239      "learn_more": {
240        "label": "Learn More"
241      }
242    },
243    "extension": {
244      "refresh": {
245        "label": "Refresh"
246      },
247      "learn_more": {
248        "label": "Learn More"
249      }
250    },
251    "desktop": {
252      "connect": {
253        "label": "Connect"
254      },
255      "learn_more": {
256        "label": "Learn More"
257      }
258    }
259  },
260
261  "chains": {
262    "title": "Switch Networks",
263    "wrong_network": "Wrong network detected, switch or disconnect to continue.",
264    "confirm": "Confirm in Wallet",
265    "switching_not_supported": "Your wallet does not support switching networks from %{appName}. Try switching networks from within your wallet instead.",
266    "switching_not_supported_fallback": "Your wallet does not support switching networks from this app. Try switching networks from within your wallet instead.",
267    "disconnect": "Disconnect",
268    "connected": "Connected"
269  },
270
271  "profile": {
272    "disconnect": {
273      "label": "Disconnect"
274    },
275    "copy_address": {
276      "label": "Copy Address",
277      "copied": "Copied!"
278    },
279    "explorer": {
280      "label": "View more on explorer"
281    },
282    "transactions": {
283      "description": "%{appName} transactions will appear here...",
284      "description_fallback": "Your transactions will appear here...",
285      "recent": {
286        "title": "Recent Transactions"
287      },
288      "clear": {
289        "label": "Clear All"
290      }
291    }
292  },
293
294  "wallet_connectors": {
295    "argent": {
296      "qr_code": {
297        "step1": {
298          "description": "Put Argent on your home screen for faster access to your wallet.",
299          "title": "Open the Argent app"
300        },
301        "step2": {
302          "description": "Create a wallet and username, or import an existing wallet.",
303          "title": "Create or Import a Wallet"
304        },
305        "step3": {
306          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
307          "title": "Tap the Scan QR button"
308        }
309      }
310    },
311
312    "bifrost": {
313      "qr_code": {
314        "step1": {
315          "description": "We recommend putting Bifrost Wallet on your home screen for quicker access.",
316          "title": "Open the Bifrost Wallet app"
317        },
318        "step2": {
319          "description": "Create or import a wallet using your recovery phrase.",
320          "title": "Create or Import a Wallet"
321        },
322        "step3": {
323          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
324          "title": "Tap the scan button"
325        }
326      }
327    },
328
329    "bitget": {
330      "qr_code": {
331        "step1": {
332          "description": "We recommend putting Bitget Wallet on your home screen for quicker access.",
333          "title": "Open the Bitget Wallet app"
334        },
335        "step2": {
336          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
337          "title": "Create or Import a Wallet"
338        },
339        "step3": {
340          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
341          "title": "Tap the scan button"
342        }
343      },
344
345      "extension": {
346        "step1": {
347          "description": "We recommend pinning Bitget Wallet to your taskbar for quicker access to your wallet.",
348          "title": "Install the Bitget Wallet extension"
349        },
350        "step2": {
351          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
352          "title": "Create or Import a Wallet"
353        },
354        "step3": {
355          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
356          "title": "Refresh your browser"
357        }
358      }
359    },
360
361    "bitski": {
362      "extension": {
363        "step1": {
364          "description": "We recommend pinning Bitski to your taskbar for quicker access to your wallet.",
365          "title": "Install the Bitski extension"
366        },
367        "step2": {
368          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
369          "title": "Create or Import a Wallet"
370        },
371        "step3": {
372          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
373          "title": "Refresh your browser"
374        }
375      }
376    },
377
378    "coin98": {
379      "qr_code": {
380        "step1": {
381          "description": "We recommend putting Coin98 Wallet on your home screen for faster access to your wallet.",
382          "title": "Open the Coin98 Wallet app"
383        },
384        "step2": {
385          "description": "You can easily backup your wallet using our backup feature on your phone.",
386          "title": "Create or Import a Wallet"
387        },
388        "step3": {
389          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
390          "title": "Tap the WalletConnect button"
391        }
392      },
393
394      "extension": {
395        "step1": {
396          "description": "Click at the top right of your browser and pin Coin98 Wallet for easy access.",
397          "title": "Install the Coin98 Wallet extension"
398        },
399        "step2": {
400          "description": "Create a new wallet or import an existing one.",
401          "title": "Create or Import a wallet"
402        },
403        "step3": {
404          "description": "Once you set up Coin98 Wallet, click below to refresh the browser and load up the extension.",
405          "title": "Refresh your browser"
406        }
407      }
408    },
409
410    "coinbase": {
411      "qr_code": {
412        "step1": {
413          "description": "We recommend putting Coinbase Wallet on your home screen for quicker access.",
414          "title": "Open the Coinbase Wallet app"
415        },
416        "step2": {
417          "description": "You can easily backup your wallet using the cloud backup feature.",
418          "title": "Create or Import a Wallet"
419        },
420        "step3": {
421          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
422          "title": "Tap the scan button"
423        }
424      },
425
426      "extension": {
427        "step1": {
428          "description": "We recommend pinning Coinbase Wallet to your taskbar for quicker access to your wallet.",
429          "title": "Install the Coinbase Wallet extension"
430        },
431        "step2": {
432          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
433          "title": "Create or Import a Wallet"
434        },
435        "step3": {
436          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
437          "title": "Refresh your browser"
438        }
439      }
440    },
441
442    "core": {
443      "qr_code": {
444        "step1": {
445          "description": "We recommend putting Core on your home screen for faster access to your wallet.",
446          "title": "Open the Core app"
447        },
448        "step2": {
449          "description": "You can easily backup your wallet using our backup feature on your phone.",
450          "title": "Create or Import a Wallet"
451        },
452        "step3": {
453          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
454          "title": "Tap the WalletConnect button"
455        }
456      },
457
458      "extension": {
459        "step1": {
460          "description": "We recommend pinning Core to your taskbar for quicker access to your wallet.",
461          "title": "Install the Core extension"
462        },
463        "step2": {
464          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
465          "title": "Create or Import a Wallet"
466        },
467        "step3": {
468          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
469          "title": "Refresh your browser"
470        }
471      }
472    },
473
474    "fox": {
475      "qr_code": {
476        "step1": {
477          "description": "We recommend putting FoxWallet on your home screen for quicker access.",
478          "title": "Open the FoxWallet app"
479        },
480        "step2": {
481          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
482          "title": "Create or Import a Wallet"
483        },
484        "step3": {
485          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
486          "title": "Tap the scan button"
487        }
488      }
489    },
490
491    "frontier": {
492      "qr_code": {
493        "step1": {
494          "description": "We recommend putting Frontier Wallet on your home screen for quicker access.",
495          "title": "Open the Frontier Wallet app"
496        },
497        "step2": {
498          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
499          "title": "Create or Import a Wallet"
500        },
501        "step3": {
502          "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
503          "title": "Tap the scan button"
504        }
505      },
506
507      "extension": {
508        "step1": {
509          "description": "We recommend pinning Frontier Wallet to your taskbar for quicker access to your wallet.",
510          "title": "Install the Frontier Wallet extension"
511        },
512        "step2": {
513          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
514          "title": "Create or Import a Wallet"
515        },
516        "step3": {
517          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
518          "title": "Refresh your browser"
519        }
520      }
521    },
522
523    "im_token": {
524      "qr_code": {
525        "step1": {
526          "title": "Open the imToken app",
527          "description": "Put imToken app on your home screen for faster access to your wallet."
528        },
529        "step2": {
530          "title": "Create or Import a Wallet",
531          "description": "Create a new wallet or import an existing one."
532        },
533        "step3": {
534          "title": "Tap Scanner Icon in top right corner",
535          "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
536        }
537      }
538    },
539
540    "metamask": {
541      "qr_code": {
542        "step1": {
543          "title": "Open the MetaMask app",
544          "description": "We recommend putting MetaMask on your home screen for quicker access."
545        },
546        "step2": {
547          "title": "Create or Import a Wallet",
548          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
549        },
550        "step3": {
551          "title": "Tap the scan button",
552          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
553        }
554      },
555
556      "extension": {
557        "step1": {
558          "title": "Install the MetaMask extension",
559          "description": "We recommend pinning MetaMask to your taskbar for quicker access to your wallet."
560        },
561        "step2": {
562          "title": "Create or Import a Wallet",
563          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
564        },
565        "step3": {
566          "title": "Refresh your browser",
567          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
568        }
569      }
570    },
571
572    "okx": {
573      "qr_code": {
574        "step1": {
575          "title": "Open the OKX Wallet app",
576          "description": "We recommend putting OKX Wallet on your home screen for quicker access."
577        },
578        "step2": {
579          "title": "Create or Import a Wallet",
580          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
581        },
582        "step3": {
583          "title": "Tap the scan button",
584          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
585        }
586      },
587
588      "extension": {
589        "step1": {
590          "title": "Install the OKX Wallet extension",
591          "description": "We recommend pinning OKX Wallet to your taskbar for quicker access to your wallet."
592        },
593        "step2": {
594          "title": "Create or Import a Wallet",
595          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
596        },
597        "step3": {
598          "title": "Refresh your browser",
599          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
600        }
601      }
602    },
603
604    "omni": {
605      "qr_code": {
606        "step1": {
607          "title": "Open the Omni app",
608          "description": "Add Omni to your home screen for faster access to your wallet."
609        },
610        "step2": {
611          "title": "Create or Import a Wallet",
612          "description": "Create a new wallet or import an existing one."
613        },
614        "step3": {
615          "title": "Tap the QR icon and scan",
616          "description": "Tap the QR icon on your home screen, scan the code and confirm the prompt to connect."
617        }
618      }
619    },
620
621    "token_pocket": {
622      "qr_code": {
623        "step1": {
624          "title": "Open the TokenPocket app",
625          "description": "We recommend putting TokenPocket on your home screen for quicker access."
626        },
627        "step2": {
628          "title": "Create or Import a Wallet",
629          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
630        },
631        "step3": {
632          "title": "Tap the scan button",
633          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
634        }
635      },
636
637      "extension": {
638        "step1": {
639          "title": "Install the TokenPocket extension",
640          "description": "We recommend pinning TokenPocket to your taskbar for quicker access to your wallet."
641        },
642        "step2": {
643          "title": "Create or Import a Wallet",
644          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
645        },
646        "step3": {
647          "title": "Refresh your browser",
648          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
649        }
650      }
651    },
652
653    "trust": {
654      "qr_code": {
655        "step1": {
656          "title": "Open the Trust Wallet app",
657          "description": "Put Trust Wallet on your home screen for faster access to your wallet."
658        },
659        "step2": {
660          "title": "Create or Import a Wallet",
661          "description": "Create a new wallet or import an existing one."
662        },
663        "step3": {
664          "title": "Tap WalletConnect in Settings",
665          "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
666        }
667      },
668
669      "extension": {
670        "step1": {
671          "title": "Install the Trust Wallet extension",
672          "description": "Click at the top right of your browser and pin Trust Wallet for easy access."
673        },
674        "step2": {
675          "title": "Create or Import a wallet",
676          "description": "Create a new wallet or import an existing one."
677        },
678        "step3": {
679          "title": "Refresh your browser",
680          "description": "Once you set up Trust Wallet, click below to refresh the browser and load up the extension."
681        }
682      }
683    },
684
685    "uniswap": {
686      "qr_code": {
687        "step1": {
688          "title": "Open the Uniswap app",
689          "description": "Add Uniswap Wallet to your home screen for faster access to your wallet."
690        },
691        "step2": {
692          "title": "Create or Import a Wallet",
693          "description": "Create a new wallet or import an existing one."
694        },
695        "step3": {
696          "title": "Tap the QR icon and scan",
697          "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
698        }
699      }
700    },
701
702    "zerion": {
703      "qr_code": {
704        "step1": {
705          "title": "Open the Zerion app",
706          "description": "We recommend putting Zerion on your home screen for quicker access."
707        },
708        "step2": {
709          "title": "Create or Import a Wallet",
710          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
711        },
712        "step3": {
713          "title": "Tap the scan button",
714          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
715        }
716      },
717
718      "extension": {
719        "step1": {
720          "title": "Install the Zerion extension",
721          "description": "We recommend pinning Zerion to your taskbar for quicker access to your wallet."
722        },
723        "step2": {
724          "title": "Create or Import a Wallet",
725          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
726        },
727        "step3": {
728          "title": "Refresh your browser",
729          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
730        }
731      }
732    },
733
734    "rainbow": {
735      "qr_code": {
736        "step1": {
737          "title": "Open the Rainbow app",
738          "description": "We recommend putting Rainbow on your home screen for faster access to your wallet."
739        },
740        "step2": {
741          "title": "Create or Import a Wallet",
742          "description": "You can easily backup your wallet using our backup feature on your phone."
743        },
744        "step3": {
745          "title": "Tap the scan button",
746          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
747        }
748      }
749    },
750
751    "enkrypt": {
752      "extension": {
753        "step1": {
754          "description": "We recommend pinning Enkrypt Wallet to your taskbar for quicker access to your wallet.",
755          "title": "Install the Enkrypt Wallet extension"
756        },
757        "step2": {
758          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
759          "title": "Create or Import a Wallet"
760        },
761        "step3": {
762          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
763          "title": "Refresh your browser"
764        }
765      }
766    },
767
768    "frame": {
769      "extension": {
770        "step1": {
771          "description": "We recommend pinning Frame to your taskbar for quicker access to your wallet.",
772          "title": "Install Frame & the companion extension"
773        },
774        "step2": {
775          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
776          "title": "Create or Import a Wallet"
777        },
778        "step3": {
779          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
780          "title": "Refresh your browser"
781        }
782      }
783    },
784
785    "one_key": {
786      "extension": {
787        "step1": {
788          "title": "Install the OneKey Wallet extension",
789          "description": "We recommend pinning OneKey Wallet to your taskbar for quicker access to your wallet."
790        },
791        "step2": {
792          "title": "Create or Import a Wallet",
793          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
794        },
795        "step3": {
796          "title": "Refresh your browser",
797          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
798        }
799      }
800    },
801
802    "phantom": {
803      "extension": {
804        "step1": {
805          "title": "Install the Phantom extension",
806          "description": "We recommend pinning Phantom to your taskbar for easier access to your wallet."
807        },
808        "step2": {
809          "title": "Create or Import a Wallet",
810          "description": "Be sure to back up your wallet using a secure method. Never share your secret recovery phrase with anyone."
811        },
812        "step3": {
813          "title": "Refresh your browser",
814          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
815        }
816      }
817    },
818
819    "rabby": {
820      "extension": {
821        "step1": {
822          "title": "Install the Rabby extension",
823          "description": "We recommend pinning Rabby to your taskbar for quicker access to your wallet."
824        },
825        "step2": {
826          "title": "Create or Import a Wallet",
827          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
828        },
829        "step3": {
830          "title": "Refresh your browser",
831          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
832        }
833      }
834    },
835
836    "safeheron": {
837      "extension": {
838        "step1": {
839          "title": "Install the Core extension",
840          "description": "We recommend pinning Safeheron to your taskbar for quicker access to your wallet."
841        },
842        "step2": {
843          "title": "Create or Import a Wallet",
844          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
845        },
846        "step3": {
847          "title": "Refresh your browser",
848          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
849        }
850      }
851    },
852
853    "taho": {
854      "extension": {
855        "step1": {
856          "title": "Install the Taho extension",
857          "description": "We recommend pinning Taho to your taskbar for quicker access to your wallet."
858        },
859        "step2": {
860          "title": "Create or Import a Wallet",
861          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
862        },
863        "step3": {
864          "title": "Refresh your browser",
865          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
866        }
867      }
868    },
869
870    "talisman": {
871      "extension": {
872        "step1": {
873          "title": "Install the Talisman extension",
874          "description": "We recommend pinning Talisman to your taskbar for quicker access to your wallet."
875        },
876        "step2": {
877          "title": "Create or Import an Ethereum Wallet",
878          "description": "Be sure to back up your wallet using a secure method. Never share your recovery phrase with anyone."
879        },
880        "step3": {
881          "title": "Refresh your browser",
882          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
883        }
884      }
885    },
886
887    "xdefi": {
888      "extension": {
889        "step1": {
890          "title": "Install the XDEFI Wallet extension",
891          "description": "We recommend pinning XDEFI Wallet to your taskbar for quicker access to your wallet."
892        },
893        "step2": {
894          "title": "Create or Import a Wallet",
895          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
896        },
897        "step3": {
898          "title": "Refresh your browser",
899          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
900        }
901      }
902    },
903
904    "zeal": {
905      "extension": {
906        "step1": {
907          "title": "Install the Zeal extension",
908          "description": "We recommend pinning Zeal to your taskbar for quicker access to your wallet."
909        },
910        "step2": {
911          "title": "Create or Import a Wallet",
912          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
913        },
914        "step3": {
915          "title": "Refresh your browser",
916          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
917        }
918      }
919    },
920
921    "safepal": {
922      "extension": {
923        "step1": {
924          "title": "Install the SafePal Wallet extension",
925          "description": "Click at the top right of your browser and pin SafePal Wallet for easy access."
926        },
927        "step2": {
928          "title": "Create or Import a wallet",
929          "description": "Create a new wallet or import an existing one."
930        },
931        "step3": {
932          "title": "Refresh your browser",
933          "description": "Once you set up SafePal Wallet, click below to refresh the browser and load up the extension."
934        }
935      },
936      "qr_code": {
937        "step1": {
938          "title": "Open the SafePal Wallet app",
939          "description": "Put SafePal Wallet on your home screen for faster access to your wallet."
940        },
941        "step2": {
942          "title": "Create or Import a Wallet",
943          "description": "Create a new wallet or import an existing one."
944        },
945        "step3": {
946          "title": "Tap WalletConnect in Settings",
947          "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
948        }
949      }
950    },
951
952    "desig": {
953      "extension": {
954        "step1": {
955          "title": "Install the Desig extension",
956          "description": "We recommend pinning Desig to your taskbar for easier access to your wallet."
957        },
958        "step2": {
959          "title": "Create a Wallet",
960          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
961        },
962        "step3": {
963          "title": "Refresh your browser",
964          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
965        }
966      }
967    },
968
969    "subwallet": {
970      "extension": {
971        "step1": {
972          "title": "Install the SubWallet extension",
973          "description": "We recommend pinning SubWallet to your taskbar for quicker access to your wallet."
974        },
975        "step2": {
976          "title": "Create or Import a Wallet",
977          "description": "Be sure to back up your wallet using a secure method. Never share your recovery phrase with anyone."
978        },
979        "step3": {
980          "title": "Refresh your browser",
981          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
982        }
983      },
984      "qr_code": {
985        "step1": {
986          "title": "Open the SubWallet app",
987          "description": "We recommend putting SubWallet on your home screen for quicker access."
988        },
989        "step2": {
990          "title": "Create or Import a Wallet",
991          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
992        },
993        "step3": {
994          "title": "Tap the scan button",
995          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
996        }
997      }
998    },
999
1000    "clv": {
1001      "extension": {
1002        "step1": {
1003          "title": "Install the CLV Wallet extension",
1004          "description": "We recommend pinning CLV Wallet to your taskbar for quicker access to your wallet."
1005        },
1006        "step2": {
1007          "title": "Create or Import a Wallet",
1008          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1009        },
1010        "step3": {
1011          "title": "Refresh your browser",
1012          "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1013        }
1014      },
1015      "qr_code": {
1016        "step1": {
1017          "title": "Open the CLV Wallet app",
1018          "description": "We recommend putting CLV Wallet on your home screen for quicker access."
1019        },
1020        "step2": {
1021          "title": "Create or Import a Wallet",
1022          "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1023        },
1024        "step3": {
1025          "title": "Tap the scan button",
1026          "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1027        }
1028      }
1029    },
1030
1031    "okto": {
1032      "qr_code": {
1033        "step1": {
1034          "title": "Open the Okto app",
1035          "description": "Add Okto to your home screen for quick access"
1036        },
1037        "step2": {
1038          "title": "Create an MPC Wallet",
1039          "description": "Create an account and generate a wallet"
1040        },
1041        "step3": {
1042          "title": "Tap WalletConnect in Settings",
1043          "description": "Tap the Scan QR icon at the top right and confirm the prompt to connect."
1044        }
1045      }
1046    },
1047
1048    "ledger": {
1049      "desktop": {
1050        "step1": {
1051          "title": "Open the Ledger Live app",
1052          "description": "We recommend putting Ledger Live on your home screen for quicker access."
1053        },
1054        "step2": {
1055          "title": "Set up your Ledger",
1056          "description": "Set up a new Ledger or connect to an existing one."
1057        },
1058        "step3": {
1059          "title": "Connect",
1060          "description": "A connection prompt will appear for you to connect your wallet."
1061        }
1062      },
1063      "qr_code": {
1064        "step1": {
1065          "title": "Open the Ledger Live app",
1066          "description": "We recommend putting Ledger Live on your home screen for quicker access."
1067        },
1068        "step2": {
1069          "title": "Set up your Ledger",
1070          "description": "You can either sync with the desktop app or connect your Ledger."
1071        },
1072        "step3": {
1073          "title": "Scan the code",
1074          "description": "Tap WalletConnect then Switch to Scanner. After you scan, a connection prompt will appear for you to connect your wallet."
1075        }
1076      }
1077    }
1078  }
1079}
1080`},87403:function(e,t,n){"use strict";n.d(t,{W:function(){return lightTheme}});var o='-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',i={rounded:`SFRounded, ui-rounded, "SF Pro Rounded", ${o}`,system:o},s={large:{actionButton:"9999px",connectButton:"12px",modal:"24px",modalMobile:"28px"},medium:{actionButton:"10px",connectButton:"8px",modal:"16px",modalMobile:"18px"},none:{actionButton:"0px",connectButton:"0px",modal:"0px",modalMobile:"0px"},small:{actionButton:"4px",connectButton:"4px",modal:"8px",modalMobile:"8px"}},c={large:{modalOverlay:"blur(20px)"},none:{modalOverlay:"blur(0px)"},small:{modalOverlay:"blur(4px)"}},baseTheme=({borderRadius:e="large",fontStack:t="rounded",overlayBlur:n="none"})=>({blurs:{modalOverlay:c[n].modalOverlay},fonts:{body:i[t]},radii:{actionButton:s[e].actionButton,connectButton:s[e].connectButton,menuButton:s[e].connectButton,modal:s[e].modal,modalMobile:s[e].modalMobile}}),l={blue:{accentColor:"#0E76FD",accentColorForeground:"#FFF"},green:{accentColor:"#1DB847",accentColorForeground:"#FFF"},orange:{accentColor:"#FF801F",accentColorForeground:"#FFF"},pink:{accentColor:"#FF5CA0",accentColorForeground:"#FFF"},purple:{accentColor:"#5F5AFA",accentColorForeground:"#FFF"},red:{accentColor:"#FA423C",accentColorForeground:"#FFF"}},u=l.blue,lightTheme=({accentColor:e=u.accentColor,accentColorForeground:t=u.accentColorForeground,...n}={})=>({...baseTheme(n),colors:{accentColor:e,accentColorForeground:t,actionButtonBorder:"rgba(0, 0, 0, 0.04)",actionButtonBorderMobile:"rgba(0, 0, 0, 0.06)",actionButtonSecondaryBackground:"rgba(0, 0, 0, 0.06)",closeButton:"rgba(60, 66, 66, 0.8)",closeButtonBackground:"rgba(0, 0, 0, 0.06)",connectButtonBackground:"#FFF",connectButtonBackgroundError:"#FF494A",connectButtonInnerBackground:"linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.06))",connectButtonText:"#25292E",connectButtonTextError:"#FFF",connectionIndicator:"#30E000",downloadBottomCardBackground:"linear-gradient(126deg, rgba(255, 255, 255, 0) 9.49%, rgba(171, 171, 171, 0.04) 71.04%), #FFFFFF",downloadTopCardBackground:"linear-gradient(126deg, rgba(171, 171, 171, 0.2) 9.49%, rgba(255, 255, 255, 0) 71.04%), #FFFFFF",error:"#FF494A",generalBorder:"rgba(0, 0, 0, 0.06)",generalBorderDim:"rgba(0, 0, 0, 0.03)",menuItemBackgroun
1080d:"rgba(60, 66, 66, 0.1)",modalBackdrop:"rgba(0, 0, 0, 0.3)",modalBackground:"#FFF",modalBorder:"transparent",modalText:"#25292E",modalTextDim:"rgba(60, 66, 66, 0.3)",modalTextSecondary:"rgba(60, 66, 66, 0.6)",profileAction:"#FFF",profileActionHover:"rgba(255, 255, 255, 0.5)",profileForeground:"rgba(60, 66, 66, 0.06)",selectedOptionBorder:"rgba(60, 66, 66, 0.1)",standby:"#FFD641"},shadows:{connectButton:"0px 4px 12px rgba(0, 0, 0, 0.1)",dialog:"0px 8px 32px rgba(0, 0, 0, 0.32)",profileDetailsAction:"0px 2px 6px rgba(37, 41, 46, 0.04)",selectedOption:"0px 2px 6px rgba(0, 0, 0, 0.24)",selectedWallet:"0px 2px 6px rgba(0, 0, 0, 0.12)",walletLogo:"0px 2px 16px rgba(0, 0, 0, 0.16)"}});lightTheme.accentColors=l},91547:function(e,t,n){"use strict";n.d(t,{NL:function(){return ConnectButton},pj:function(){return RainbowKitProvider},wo:function(){return getDefaultWallets}});var o,i,s,c,l,u,d,p,m,b,g,y,v,E,x,P,_,I,j,R,M,F,q,H,z,W,K,Q,Z,X=n(87403),Y=n(95016),J=n(67294),addRecipe=function(e,t){return Object.defineProperty(e,"__recipe__",{value:t,writable:!1}),e};function createNormalizeValueFn(e){var{conditions:t}=e;if(!t)throw Error("Styles have no conditions");return addRecipe(function(e){if("string"==typeof e||"number"==typeof e||"boolean"==typeof e){if(!t.defaultCondition)throw Error("No default condition");return{[t.defaultCondition]:e}}if(Array.isArray(e)){if(!("responsiveArray"in t))throw Error("Responsive arrays are not supported");var n={};for(var o in t.responsiveArray)null!=e[o]&&(n[t.responsiveArray[o]]=e[o]);return n}return e},{importPath:"@vanilla-extract/sprinkles/createUtils",importName:"createNormalizeValueFn",args:[{conditions:e.conditions}]})}function ownKeys(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,o)}return n}function _objectSpread2(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(n),!0).forEach(function(t){!function(e,t,n){var o;(t="symbol"==typeof(o=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=typeof o)return o;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?o:String(o))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ownKeys(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var createSprinkles_c8550e00_esm_createSprinkles=e=>function(){for(var t=arguments.length,n=Array(t),o=0;o<t;o++)n[o]=arguments[o];var i=Object.assign({},...n.map(e=>e.styles)),s=Object.keys(i),c=s.filter(e=>"mappings"in i[e]);return Object.assign(t=>{var n=[],o={},s=_objectSpread2({},t),l=!1;for(var u of c){var d=t[u];if(null!=d)for(var p of(l=!0,i[u].mappings))o[p]=d,null==s[p]&&delete s[p]}var m=l?_objectSpread2(_objectSpread2({},o),s):t;for(var b in m)if("continue"===function(){var e=m[b],t=i[b];try{if(t.mappings)return"continue";if("string"==typeof e||"number"==typeof e)n.push(t.values[e].defaultClass);else if(Array.isArray(e))for(var o=0;o<e.length;o++){var s=e[o];if(null!=s){var c=t.responsiveArray[o];n.push(t.values[s].conditions[c])}}else for(var l in e){var u=e[l];null!=u&&n.push(t.values[u].conditions[l])}}catch(e){throw e}}())continue;return e(n.join(" "))},{properties:new Set(s)})},composeStyles=e=>e,et=n(69077),eo=n(90512),ea=n(81782),ei=n(73935),es=n(97582),ec=n(71642),el=n(99495),eu=(0,n(87122)._)(),nothing=function(){},ed=J.forwardRef(function(e,t){var n=J.useRef(null),o=J.useState({onScrollCapture:nothing,onWheelCapture:nothing,onTouchMoveCapture:nothing}),i=o[0],s=o[1],c=e.forwardProps,l=e.children,u=e.className,d=e.removeScrollBar,p=e.enabled,m=e.shards,b=e.sideCar,g=e.noIsolation,y=e.inert,v=e.allowPinchZoom,E=e.as,x=void 0===E?"div":E,P=e.gapMode,_=(0,es.__rest)(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),I=(0,el.q)([n,t]),j=(0,es.__assign)((0,es.__assign)({},_),i);return J.createElement(J.Fragment,null,p&&J.createElement(b,{sideCar:eu,removeScrollBar:d,shards:m,noIsolation:g,inert:y,setCallbacks:s,allowPinchZoom:!!v,lockRef:n,gapMode:P}),c?J.cloneElement(J.Children.only(l),(0,es.__assign)((0,es.__assign)({},j),{ref:I})):J.createElement(x,(0,es.__assign)({},j,{className:u,ref:I}),l))});ed.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},ed.classNames={fullWidth:ec.zi,zeroRight:ec.pF};var ef=n(66781),ep=n(37087),eh=n(6525),em=!1;if("undefined"!=typeof window)try{var eb=Object.defineProperty({},"passive",{get:function(){return em=!0,!0}});window.addEventListener("test",eb,eb),window.removeEventListener("test",eb,eb)}catch(e){em=!1}var eg=!!em&&{passive:!1},elementCanBeScrolled=function(e,t){var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&"TEXTAREA"!==e.tagName&&"visible"===n[t])},locationCouldBeScrolled=function(e,t){var n=t.ownerDocument,o=t;do{if("undefined"!=typeof ShadowRoot&&o instanceof ShadowRoot&&(o=o.host),elementCouldBeScrolled(e,o)){var i=getScrollVariables(e,o);if(i[1]>i[2])return!0}o=o.parentNode}while(o&&o!==n.body);return!1},elementCouldBeScrolled=function(e,t){return"v"===e?elementCanBeScrolled(t,"overflowY"):elementCanBeScrolled(t,"overflowX")},getScrollVariables=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},handleScroll=function(e,t,n,o,i){var s,c=(s=window.getComputedStyle(t).direction,"h"===e&&"rtl"===s?-1:1),l=c*o,u=n.target,d=t.contains(u),p=!1,m=l>0,b=0,g=0;do{var y=getScrollVariables(e,u),v=y[0],E=y[1]-y[2]-c*v;(v||E)&&elementCouldBeScrolled(e,u)&&(b+=E,g+=v),u=u instanceof ShadowRoot?u.host:u.parentNode}while(!d&&u!==document.body||d&&(t.contains(u)||t===u));return m&&(i&&1>Math.abs(b)||!i&&l>b)?p=!0:!m&&(i&&1>Math.abs(g)||!i&&-l>g)&&(p=!0),p},getTouchXY=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},getDeltaXY=function(e){return[e.deltaX,e.deltaY]},extractRef=function(e){return e&&"current"in e?e.current:e},ey=0,ev=[],ew=(0,ef.L)(eu,function(e){var t=J.useRef([]),n=J.useRef([0,0]),o=J.useRef(),i=J.useState(ey++)[0],s=J.useState(eh.Ws)[0],c=J.useRef(e);J.useEffect(function(){c.current=e},[e]),J.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var t=(0,es.__spreadArray)([e.lockRef.current],(e.shards||[]).map(extractRef),!0).filter(
1080Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var l=J.useCallback(function(e,t){if("touches"in e&&2===e.touches.length)return!c.current.allowPinchZoom;var i,s=getTouchXY(e),l=n.current,u="deltaX"in e?e.deltaX:l[0]-s[0],d="deltaY"in e?e.deltaY:l[1]-s[1],p=e.target,m=Math.abs(u)>Math.abs(d)?"h":"v";if("touches"in e&&"h"===m&&"range"===p.type)return!1;var b=locationCouldBeScrolled(m,p);if(!b)return!0;if(b?i=m:(i="v"===m?"h":"v",b=locationCouldBeScrolled(m,p)),!b)return!1;if(!o.current&&"changedTouches"in e&&(u||d)&&(o.current=i),!i)return!0;var g=o.current||i;return handleScroll(g,t,e,"h"===g?u:d,!0)},[]),u=J.useCallback(function(e){if(ev.length&&ev[ev.length-1]===s){var n="deltaY"in e?getDeltaXY(e):getTouchXY(e),o=t.current.filter(function(t){var o;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(o=t.delta)[0]===n[0]&&o[1]===n[1]})[0];if(o&&o.should){e.cancelable&&e.preventDefault();return}if(!o){var i=(c.current.shards||[]).map(extractRef).filter(Boolean).filter(function(t){return t.contains(e.target)});(i.length>0?l(e,i[0]):!c.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),d=J.useCallback(function(e,n,o,i){var s={name:e,delta:n,target:o,should:i,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(o)};t.current.push(s),setTimeout(function(){t.current=t.current.filter(function(e){return e!==s})},1)},[]),p=J.useCallback(function(e){n.current=getTouchXY(e),o.current=void 0},[]),m=J.useCallback(function(t){d(t.type,getDeltaXY(t),t.target,l(t,e.lockRef.current))},[]),b=J.useCallback(function(t){d(t.type,getTouchXY(t),t.target,l(t,e.lockRef.current))},[]);J.useEffect(function(){return ev.push(s),e.setCallbacks({onScrollCapture:m,onWheelCapture:m,onTouchMoveCapture:b}),document.addEventListener("wheel",u,eg),document.addEventListener("touchmove",u,eg),document.addEventListener("touchstart",p,eg),function(){ev=ev.filter(function(e){return e!==s}),document.removeEventListener("wheel",u,eg),document.removeEventListener("touchmove",u,eg),document.removeEventListener("touchstart",p,eg)}},[]);var g=e.removeScrollBar,y=e.inert;return J.createElement(J.Fragment,null,y?J.createElement(s,{styles:"\n  .block-interactivity-".concat(i," {pointer-events: none;}\n  .allow-interactivity-").concat(i," {pointer-events: all;}\n")}):null,g?J.createElement(ep.jp,{gapMode:e.gapMode}):null)}),eE=J.forwardRef(function(e,t){return J.createElement(ed,(0,es.__assign)({},e,{ref:t,sideCar:ew}))});function vanilla_extract_private_esm_getVarName(e){var t=e.match(/^var\((.*)\)$/);return t?t[1]:e}function assignInlineVars(e,t){var n={};if("object"==typeof t)!function vanilla_extract_private_esm_walkObject(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],o={};for(var i in e){var s=e[i],c=[...n,i];"string"==typeof s||"number"==typeof s||null==s?o[i]=t(s,c):"object"!=typeof s||Array.isArray(s)?console.warn('Skipping invalid key "'.concat(c.join("."),'". Should be a string, number, null or object. Received: "').concat(Array.isArray(s)?"Array":typeof s,'"')):o[i]=vanilla_extract_private_esm_walkObject(s,t,c)}return o}(t,(t,o)=>{null!=t&&(n[vanilla_extract_private_esm_getVarName(function(e,t){var n=e;for(var o of t){if(!(o in n))throw Error("Path ".concat(t.join(" -> ")," does not exist in object"));n=n[o]}return n}(e,o))]=String(t))});else for(var o in e){var i=e[o];null!=i&&(n[vanilla_extract_private_esm_getVarName(o)]=i)}return Object.defineProperty(n,"toString",{value:function(){return Object.keys(this).map(e=>"".concat(e,":").concat(this[e])).join(";")},writable:!1}),n}eE.classNames=ed.classNames;var ex=n(42238),eC=n(34723),eP=n(92592),eT=n(53324),eA=n(50778),eS="eip155",e_="requestedChains",eI="wallet_addEthereumChain",ek=class extends eT.wR{constructor(e){super({...e,options:{isNewChainsStale:!0,...e.options}}),(0,eT.Ko)(this,s),(0,eT.Ko)(this,l),(0,eT.Ko)(this,d),(0,eT.Ko)(this,m),(0,eT.Ko)(this,g),(0,eT.Ko)(this,v),(0,eT.Ko)(this,x),(0,eT.Ko)(this,_),(0,eT.Ko)(this,j),this.id="walletConnect",this.name="WalletConnect",this.ready=!0,(0,eT.Ko)(this,o,void 0),(0,eT.Ko)(this,i,void 0),this.onAccountsChanged=e=>
1080{0===e.length?this.emit("disconnect"):this.emit("change",{account:(0,eC.Kn9)(e[0])})},this.onChainChanged=e=>{let t=Number(e),n=this.isChainUnsupported(t);this.emit("change",{chain:{id:t,unsupported:n}})},this.onDisconnect=()=>{(0,eT.U9)(this,v,E).call(this,[]),this.emit("disconnect")},this.onDisplayUri=e=>{this.emit("message",{type:"display_uri",data:e})},this.onConnect=()=>{this.emit("connect",{})},(0,eT.U9)(this,s,c).call(this)}async connect({chainId:e,pairingTopic:t}={}){try{let n=e;if(!n){let e=this.storage?.getItem("store"),t=e?.state?.data?.chain?.id;n=t&&!this.isChainUnsupported(t)?t:this.chains[0]?.id}if(!n)throw Error("No chains found on connector.");let o=await this.getProvider();(0,eT.U9)(this,m,b).call(this);let i=(0,eT.U9)(this,d,p).call(this);if(o.session&&i&&await o.disconnect(),!o.session||i){let e=this.chains.filter(e=>e.id!==n).map(e=>e.id);this.emit("message",{type:"connecting"}),await o.connect({pairingTopic:t,optionalChains:[n,...e]}),(0,eT.U9)(this,v,E).call(this,this.chains.map(({id:e})=>e))}let s=await o.enable(),c=(0,eC.Kn9)(s[0]),l=await this.getChainId(),u=this.isChainUnsupported(l);return{account:c,chain:{id:l,unsupported:u}}}catch(e){if(/user rejected/i.test(e?.message))throw new eC.abR(e);throw e}}async disconnect(){let e=await this.getProvider();try{await e.disconnect()}catch(e){if(!/No matching key/i.test(e.message))throw e}finally{(0,eT.U9)(this,g,y).call(this),(0,eT.U9)(this,v,E).call(this,[])}}async getAccount(){let{accounts:e}=await this.getProvider();return(0,eC.Kn9)(e[0])}async getChainId(){let{chainId:e}=await this.getProvider();return e}async getProvider({chainId:e}={}){return(0,eT.ac)(this,o)||await (0,eT.U9)(this,s,c).call(this),e&&await this.switchChain(e),(0,eT.ac)(this,o)}async getWalletClient({chainId:e}={}){let[t,n]=await Promise.all([this.getProvider({chainId:e}),this.getAccount()]),o=this.chains.find(t=>t.id===e);if(!t)throw Error("provider is required.");return(0,eC.Kwp)({account:n,chain:o,transport:(0,eC.PGm)(t)})}async isAuthorized(){try{let[e,t]=await Promise.all([this.getAccount(),this.getProvider()]),n=(0,eT.U9)(this,d,p).call(this);if(!e)return!1;if(n&&t.session){try{await t.disconnect()}catch{}return!1}return!0}catch{return!1}}async switchChain(e){let t=this.chains.find(t=>t.id===e);if(!t)throw new eC.x3p(Error("chain not found on connector."));try{let n=await this.getProvider(),o=(0,eT.U9)(this,_,I).call(this),i=(0,eT.U9)(this,j,R).call(this),s=o.includes(e);if(!s&&i.includes(eI)){await n.request({method:eI,params:[{chainId:(0,eC.eCs)(t.id),blockExplorerUrls:[t.blockExplorers?.default?.url],chainName:t.name,nativeCurrency:t.nativeCurrency,rpcUrls:[...t.rpcUrls.default.http]}]});let o=(0,eT.U9)(this,x,P).call(this);o.push(e),(0,eT.U9)(this,v,E).call(this,o)}return await n.request({method:"wallet_switchEthereumChain",params:[{chainId:(0,eC.eCs)(e)}]}),t}catch(t){let e="string"==typeof t?t:t?.message;if(/user rejected request/i.test(e))throw new eC.abR(t);throw new eC.x3p(t)}}};o=new WeakMap,i=new WeakMap,s=new WeakSet,c=async function(){return(0,eT.ac)(this,i)||"undefined"==typeof window||(0,eT.qx)(this,i,(0,eT.U9)(this,l,u).call(this)),(0,eT.ac)(this,i)},l=new WeakSet,u=async function(){let{EthereumProvider:e}=await Promise.all([n.e(8764),n.e(1894),n.e(490)]).then(n.bind(n,70490)),t=this.chains.map(({id:e})=>e);if(t.length){let{projectId:n,showQrModal:i=!0,qrModalOptions:s,metadata:c,relayUrl:l}=this.options;(0,eT.qx)(this,o,await e.init({showQrModal:i,qrModalOptions:s,projectId:n,optionalChains:t,rpcMap:Object.fromEntries(this.chains.map(e=>[e.id,e.rpcUrls.default.http[0]])),metadata:c,relayUrl:l}))}},d=new WeakSet,p=function(){let e=(0,eT.U9)(this,j,R).call(this);if(e.includes(eI)||!this.options.isNewChainsStale)return!1;let t=(0,eT.U9)(this,x,P).call(this),n=this.chains.map(({id:e})=>e),o=(0,eT.U9)(this,_,I).call(this);return(!o.length||!!o.some(e=>n.includes(e)))&&!n.every(e=>t.includes(e))},m=new WeakSet,b=function(){(0,eT.ac)(this,o)&&((0,eT.U9)(this,g,y).call(this),(0,eT.ac)(this,o).on("accountsChanged",this.onAccountsChanged),(0,eT.ac)(this,o).on("chainChanged",this.onChainChanged),(0,eT.ac)(this,o).on("disconnect",this.onDisconnect),(0,eT.ac)(this,o).on("session_delete",this.onDisconnect),(0,eT.ac)(this,o).on("display_uri",this.onDisplayUri),(0,eT.ac)(this,o).on("connect",this.onConnect))},g=new WeakSet,y=function(){(0,eT.ac)(this,o)&&((0,eT.ac)(this,o).removeListener("accountsChanged",this.onAccountsChanged),(0,eT.ac)(this,o).removeListener("chainChanged",this.onChainChanged),(0,eT.ac)(this,o).removeListener("disconnect",this.onDisconnect),(0,eT.ac)(this,o).removeListener("session_delete",this.onDisconnect),(0,eT.ac)(this,o).removeListener("display_uri",this.onDisplayUri),(0,eT.ac)(this,o).removeListener("connect",this.onConnect))},v=new WeakSet,E=function(e){this.storage?.setItem(e_,e)},x=new WeakSet,P=function(){return this.storage?.getItem(e_)??[]},_=new WeakSet,I=function(){if(!(0,eT.ac)(this,o))return[];let e=eT.ac(this,o).session?.namespaces;if(!e)return[];let t=(0,eA.fK)(e),n=t[eS]?.chains?.map(e=>parseInt(e.split(":")[1]||""));return n??[]},j=new WeakSet,R=function(){if(!(0,eT.ac)(this,o))return[];let e=eT.ac(this,o).session?.namespaces;if(!e)return[];let t=(0,eA.fK)(e),n=t[eS]?.methods;return n??[]};var eO=n(92219),ej=n(57858),eB=n(53516),eD=class extends eT.wR{constructor({chains:e,options:t}){super({chains:e,options:{reloadOnDisconnect:!1,...t}}),this.id="coinbaseWallet",this.name="Coinbase Wallet",this.ready=!0,(0,eT.Ko)(this,M,void 0),(0,eT.Ko)(this,F,void 0),this.onAccountsChanged=e=>
1080{0===e.length?this.emit("disconnect"):this.emit("change",{account:(0,eC.Kn9)(e[0])})},this.onChainChanged=e=>{let t=(0,eB.J)(e),n=this.isChainUnsupported(t);this.emit("change",{chain:{id:t,unsupported:n}})},this.onDisconnect=()=>{this.emit("disconnect")}}async connect({chainId:e}={}){try{let t=await this.getProvider();t.on("accountsChanged",this.onAccountsChanged),t.on("chainChanged",this.onChainChanged),t.on("disconnect",this.onDisconnect),this.emit("message",{type:"connecting"});let n=await t.enable(),o=(0,eC.Kn9)(n[0]),i=await this.getChainId(),s=this.isChainUnsupported(i);if(e&&i!==e){let t=await this.switchChain(e);i=t.id,s=this.isChainUnsupported(i)}return{account:o,chain:{id:i,unsupported:s}}}catch(e){if(/(user closed modal|accounts received is empty)/i.test(e.message))throw new eC.abR(e);throw e}}async disconnect(){if(!(0,eT.ac)(this,F))return;let e=await this.getProvider();e.removeListener("accountsChanged",this.onAccountsChanged),e.removeListener("chainChanged",this.onChainChanged),e.removeListener("disconnect",this.onDisconnect),e.disconnect(),e.close()}async getAccount(){let e=await this.getProvider(),t=await e.request({method:"eth_accounts"});return(0,eC.Kn9)(t[0])}async getChainId(){let e=await this.getProvider(),t=(0,eB.J)(e.chainId);return t}
1080async getProvider(){if(!(0,eT.ac)(this,F)){let e=(await Promise.all([n.e(8764),n.e(3695),n.e(5811),n.e(5439)]).then(n.t.bind(n,45811,19))).default;"function"!=typeof e&&"function"==typeof e.default&&(e=e.default),(0,eT.qx)(this,M,new e(this.options));let t=eT.ac(this,M).walletExtension?.getChainId(),o=this.chains.find(e=>this.options.chainId?e.id===this.options.chainId:e.id===t)||this.chains[0],i=this.options.chainId||o?.id,s=this.options.jsonRpcUrl||o?.rpcUrls.default.http[0];(0,eT.qx)(this,F,(0,eT.ac)(this,M).makeWeb3Provider(s,i))}return(0,eT.ac)(this,F)}async getWalletClient({chainId:e}={}){let[t,n]=await Promise.all([this.getProvider(),this.getAccount()]),o=this.chains.find(t=>t.id===e);if(!t)throw Error("provider is required.");return(0,eC.Kwp)({account:n,chain:o,transport:(0,eC.PGm)(t)})}async isAuthorized(){try{let e=await this.getAccount();return!!e}catch{return!1}}async switchChain(e){let t=await this.getProvider(),n=(0,eC.eCs)(e);try{return await t.request({method:"wallet_switchEthereumChain",params:[{chainId:n}]}),this.chains.find(t=>t.id===e)??{id:e,name:`Chain ${n}`,network:`${n}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}}}catch(i){let o=this.chains.find(t=>t.id===e);if(!o)throw new ej.B({chainId:e,connectorId:this.id});if(4902===i.code)try{return await t.request({method:"wallet_addEthereumChain",params:[{chainId:n,chainName:o.name,nativeCurrency:o.nativeCurrency,rpcUrls:[o.rpcUrls.public?.http[0]??""],blockExplorerUrls:this.getBlockExplorerUrls(o)}]}),o}catch(e){throw new eC.abR(e)}throw new eC.x3p(i)}}async watchAsset({address:e,decimals:t=18,image:n,symbol:o}){let i=await this.getProvider();return i.request({method:"wallet_watchAsset",params:{type:"ERC20",options:{address:e,decimals:t,image:n,symbol:o}}})}};M=new WeakMap,F=new WeakMap;var eR=class extends eO._{constructor({chains:e,options:t}={}){let n={name:"MetaMask",shimDisconnect:!0,getProvider(){function getReady(e){let t=!!e?.isMetaMask;if(t&&(!e.isBraveWallet||e._events||e._state)&&!e.isApexWallet&&!e.isAvalanche&&!e.isBitKeep&&!e.isBlockWallet&&!e.isCoin98&&!e.isFordefi&&!e.isMathWallet&&!e.isOkxWallet&&!e.isOKExWallet&&!e.isOneInchIOSWallet&&!e.isOneInchAndroidWallet&&!e.isOpera&&!e.isPortal&&!e.isRabby&&!e.isDefiant&&!e.isTokenPocket&&!e.isTokenary&&!e.isZeal&&!e.isZerion)return e}if("undefined"==typeof window)return;let e=window.ethereum;return e?.providers?e.providers.find(getReady):getReady(e)},...t};super({chains:e,options:n}),this.id="metaMask",this.shimDisconnectKey=`${this.id}.shimDisconnect`,(0,eT.Ko)(this,q,void 0),(0,eT.qx)(this,q,n.UNSTABLE_shimOnConnectSelectAccount)}async connect({chainId:e}={}){try{let t=await this.getProvider();if(!t)throw new ej.N;t.on&&(t.on("accountsChanged",this.onAccountsChanged),t.on("chainChanged",this.onChainChanged),t.on("disconnect",this.onDisconnect)),this.emit("message",{type:"connecting"});let n=null;if((0,eT.ac)(this,q)&&this.options?.shimDisconnect&&!this.storage?.getItem(this.shimDisconnectKey)){n=await this.getAccount().catch(()=>null);let e=!!n;if(e)try{await t.request({method:"wallet_requestPermissions",params:[{eth_accounts:{}}]}),n=await this.getAccount()}catch(e){if(this.isUserRejectedRequestError(e))throw new eC.abR(e);if(e.code===new eC.pTd(e).code)throw e}}if(!n){let e=await t.request({method:"eth_requestAccounts"});n=(0,eC.Kn9)(e[0])}let o=await this.getChainId(),i=this.isChainUnsupported(o);if(e&&o!==e){let t=await this.switchChain(e);o=t.id,i=this.isChainUnsupported(o)}return this.options?.shimDisconnect&&this.storage?.setItem(this.shimDisconnectKey,!0),{account:n,chain:{id:o,unsupported:i},provider:t}}catch(e){if(this.isUserRejectedRequestError(e))throw new eC.abR(e);if(-32002===e.code)throw new eC.pTd(e);throw e}}};q=new WeakMap;var eM=/(imtoken|metamask|rainbow|trust wallet|uniswap wallet|ledger)/i,eN=class extends eT.wR{constructor(){super(...arguments),(0,eT.Ko)(this,z),this.id="walletConnectLegacy",this.name="WalletConnectLegacy",this.ready=!0,(0,eT.Ko)(this,H,void 0),this.onAccountsChanged=e=>
1080{0===e.length?this.emit("disconnect"):this.emit("change",{account:(0,eC.Kn9)(e[0])})},this.onChainChanged=e=>{let t=(0,eB.J)(e),n=this.isChainUnsupported(t);this.emit("change",{chain:{id:t,unsupported:n}})},this.onDisconnect=()=>{this.emit("disconnect")}}async connect({chainId:e}={}){try{let t=e;if(!t){let e=this.storage?.getItem("store"),n=e?.state?.data?.chain?.id;n&&!this.isChainUnsupported(n)&&(t=n)}let n=await this.getProvider({chainId:t,create:!0});n.on("accountsChanged",this.onAccountsChanged),n.on("chainChanged",this.onChainChanged),n.on("disconnect",this.onDisconnect),setTimeout(()=>this.emit("message",{type:"connecting"}),0);let o=await n.enable(),i=(0,eC.Kn9)(o[0]),s=await this.getChainId(),c=this.isChainUnsupported(s),l=n.connector?.peerMeta?.name??"";return eM.test(l)&&(this.switchChain=(0,eT.U9)(this,z,W)),{account:i,chain:{id:s,unsupported:c}}}catch(e){if(/user closed modal/i.test(e.message))throw new eC.abR(e);throw e}}async disconnect(){let e=await this.getProvider();await e.disconnect(),e.removeListener("accountsChanged",this.onAccountsChanged),e.removeListener("chainChanged",this.onChainChanged),e.removeListener("disconnect",this.onDisconnect),"undefined"!=typeof localStorage&&localStorage.removeItem("walletconnect")}async getAccount(){let e=await this.getProvider(),t=e.accounts;return(0,eC.Kn9)(t[0])}async getChainId(){let e=await this.getProvider(),t=(0,eB.J)(e.chainId);return t}async getProvider({chainId:e,create:t}={}){if(!(0,eT.ac)(this,H)||e||t){let t=this.options?.infuraId?{}:this.chains.reduce((e,t)=>({...e,[t.id]:t.rpcUrls.default.http[0]}),{}),o=(await Promise.all([n.e(8764),n.e(1894),n.e(7619)]).then(n.bind(n,17619))).default;(0,eT.qx)(this,H,new o({...this.options,chainId:e,rpc:{...t,...this.options?.rpc}})),(0,eT.ac)(this,H).http=await (0,eT.ac)(this,H).setHttpProvider(e)}return(0,eT.ac)(this,H)}async getWalletClient({chainId:e}={}){let[t,n]=await Promise.all([this.getProvider({chainId:e}),this.getAccount()]),o=this.chains.find(t=>t.id===e);if(!t)throw Error("provider is required.");return(0,eC.Kwp)({account:n,chain:o,transport:(0,eC.PGm)(t)})}async isAuthorized(){try{let e=await this.getAccount();return!!e}catch{return!1}}};H=new WeakMap,z=new WeakSet,W=async function(e){let t=await this.getProvider(),n=(0,eC.eCs)(e);try{return await Promise.race([t.request({method:"wallet_switchEthereumChain",params:[{chainId:n}]}),new Promise(t=>this.on("change",({chain:n})=>{n?.id===e&&t(e)}))]),this.chains.find(t=>t.id===e)??{id:e,name:`Chain ${n}`,network:`${n}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}}}catch(t){let e="string"==typeof t?t:t?.message;if(/user rejected request/i.test(e))throw new eC.abR(t);throw new eC.x3p(t)}};var eF=n(77777),eU=n(40936),eL=class extends eT.wR{constructor({chains:e,options:t}){let n={shimDisconnect:!1,...t};super({chains:e,options:n}),this.id="safe",this.name="Safe",this.ready="undefined"!=typeof window&&window?.parent!==window,(0,eT.Ko)(this,K,void 0),(0,eT.Ko)(this,Q,void 0),this.shimDisconnectKey=`${this.id}.shimDisconnect`;let o=eU;"function"!=typeof eU&&"function"==typeof eU.default&&(o=eU.default),(0,eT.qx)(this,Q,new o(n))}async connect(){let e=await this.getProvider();if(!e)throw new ej.N;e.on&&(e.on("accountsChanged",this.onAccountsChanged),e.on("chainChanged",this.onChainChanged),e.on("disconnect",this.onDisconnect)),this.emit("message",{type:"connecting"});let t=await this.getAccount(),n=await this.getChainId();return this.options.shimDisconnect&&this.storage?.setItem(this.shimDisconnectKey,!0),{account:t,chain:{id:n,unsupported:this.isChainUnsupported(n)}}}async disconnect(){let e=await this.getProvider();e?.removeListener&&(e.removeListener("accountsChanged",this.onAccountsChanged),e.removeListener("chainChanged",this.onChainChanged),e.removeListener("disconnect",this.onDisconnect),this.options.shimDisconnect&&this.storage?.removeItem(this.shimDisconnectKey))}async getAccount(){let e=await this.getProvider();if(!e)throw new ej.N;let t=await e.request({method:"eth_accounts"});return(0,eC.Kn9)(t[0])}async getChainId(){let e=await this.getProvider();if(!e)throw new ej.N;return(0,eB.J)(e.chainId)}
1080async getProvider(){if(!(0,eT.ac)(this,K)){let e=await (0,eT.ac)(this,Q).safe.getInfo();if(!e)throw Error("Could not load Safe information");(0,eT.qx)(this,K,new eF.N(e,(0,eT.ac)(this,Q)))}return(0,eT.ac)(this,K)}async getWalletClient({chainId:e}={}){let t=await this.getProvider(),n=await this.getAccount(),o=this.chains.find(t=>t.id===e);if(!t)throw Error("provider is required.");return(0,eC.Kwp)({account:n,chain:o,transport:(0,eC.PGm)(t)})}async isAuthorized(){try{if(this.options.shimDisconnect&&!this.storage?.getItem(this.shimDisconnectKey))return!1;let e=await this.getAccount();return!!e}catch{return!1}}onAccountsChanged(e){}onChainChanged(e){}onDisconnect(){this.emit("disconnect")}};K=new WeakMap,Q=new WeakMap;var e$=function(e){var{conditions:t}=e;if(!t)throw Error("Styles have no conditions");var n=createNormalizeValueFn(e);return addRecipe(function(e,o){if("string"==typeof e||"number"==typeof e||"boolean"==typeof e){if(!t.defaultCondition)throw Error("No default condition");return o(e,t.defaultCondition)}var i=Array.isArray(e)?n(e):e,s={};for(var c in i)null!=i[c]&&(s[c]=o(i[c],c));return s},{importPath:"@vanilla-extract/sprinkles/createUtils",importName:"createMapValueFn",args:[{conditions:e.conditions}]})}({conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0}}),eq=createNormalizeValueFn({conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0}}),eH=function(){return createSprinkles_c8550e00_esm_createSprinkles(composeStyles)(...arguments)}({conditions:{defaultCondition:"base",conditionNames:["base","hover","active"],responsiveArray:void 0},styles:{background:{values:{accentColor:{conditions:{base:"ju367v9i",hover:"ju367v9j",active:"ju367v9k"},defaultClass:"ju367v9i"},accentColorForeground:{conditions:{base:"ju367v9l",hover:"ju367v9m",active:"ju367v9n"},defaultClass:"ju367v9l"},actionButtonBorder:{conditions:{base:"ju367v9o",hover:"ju367v9p",active:"ju367v9q"},defaultClass:"ju367v9o"},actionButtonBorderMobile:{conditions:{base:"ju367v9r",hover:"ju367v9s",active:"ju367v9t"},defaultClass:"ju367v9r"},actionButtonSecondaryBackground:{conditions:{base:"ju367v9u",hover:"ju367v9v",active:"ju367v9w"},defaultClass:"ju367v9u"},closeButton:{conditions:{base:"ju367v9x",hover:"ju367v9y",active:"ju367v9z"},defaultClass:"ju367v9x"},closeButtonBackground:{conditions:{base:"ju367va0",hover:"ju367va1",active:"ju367va2"},defaultClass:"ju367va0"},connectButtonBackground:{conditions:{base:"ju367va3",hover:"ju367va4",active:"ju367va5"},defaultClass:"ju367va3"},connectButtonBackgroundError:{conditions:{base:"ju367va6",hover:"ju367va7",active:"ju367va8"},defaultClass:"ju367va6"},connectButtonInnerBackground:{conditions:{base:"ju367va9",hover:"ju367vaa",active:"ju367vab"},defaultClass:"ju367va9"},connectButtonText:{conditions:{base:"ju367vac",hover:"ju367vad",active:"ju367vae"},defaultClass:"ju367vac"},connectButtonTextError:{conditions:{base:"ju367vaf",hover:"ju367vag",active:"ju367vah"},defaultClass:"ju367vaf"},connectionIndicator:{conditions:{base:"ju367vai",hover:"ju367vaj",active:"ju367vak"},defaultClass:"ju367vai"},downloadBottomCardBackground:{conditions:{base:"ju367val",hover:"ju367vam",active:"ju367van"},defaultClass:"ju367val"},downloadTopCardBackground:{conditions:{base:"ju367vao",hover:"ju367vap",active:"ju367vaq"},defaultClass:"ju367vao"},error:{conditions:{base:"ju367var",hover:"ju367vas",active:"ju367vat"},defaultClass:"ju367var"},generalBorder:{conditions:{base:"ju367vau",hover:"ju367vav",active:"ju367vaw"},defaultClass:"ju367vau"},generalBorderDim:{conditions:{base:"ju367vax",hover:"ju367vay",active:"ju367vaz"},defaultClass:"ju367vax"}
1080,menuItemBackground:{conditions:{base:"ju367vb0",hover:"ju367vb1",active:"ju367vb2"},defaultClass:"ju367vb0"},modalBackdrop:{conditions:{base:"ju367vb3",hover:"ju367vb4",active:"ju367vb5"},defaultClass:"ju367vb3"},modalBackground:{conditions:{base:"ju367vb6",hover:"ju367vb7",active:"ju367vb8"},defaultClass:"ju367vb6"},modalBorder:{conditions:{base:"ju367vb9",hover:"ju367vba",active:"ju367vbb"},defaultClass:"ju367vb9"},modalText:{conditions:{base:"ju367vbc",hover:"ju367vbd",active:"ju367vbe"},defaultClass:"ju367vbc"},modalTextDim:{conditions:{base:"ju367vbf",hover:"ju367vbg",active:"ju367vbh"},defaultClass:"ju367vbf"},modalTextSecondary:{conditions:{base:"ju367vbi",hover:"ju367vbj",active:"ju367vbk"},defaultClass:"ju367vbi"},profileAction:{conditions:{base:"ju367vbl",hover:"ju367vbm",active:"ju367vbn"},defaultClass:"ju367vbl"},profileActionHover:{conditions:{base:"ju367vbo",hover:"ju367vbp",active:"ju367vbq"},defaultClass:"ju367vbo"},profileForeground:{conditions:{base:"ju367vbr",hover:"ju367vbs",active:"ju367vbt"},defaultClass:"ju367vbr"},selectedOptionBorder:{conditions:{base:"ju367vbu",hover:"ju367vbv",active:"ju367vbw"},defaultClass:"ju367vbu"},standby:{conditions:{base:"ju367vbx",hover:"ju367vby",active:"ju367vbz"},defaultClass:"ju367vbx"}}},borderColor:{values:{accentColor:{conditions:{base:"ju367vc0",hover:"ju367vc1",active:"ju367vc2"},defaultClass:"ju367vc0"},accentColorForeground:{conditions:{base:"ju367vc3",hover:"ju367vc4",active:"ju367vc5"},defaultClass:"ju367vc3"},actionButtonBorder:{conditions:{base:"ju367vc6",hover:"ju367vc7",active:"ju367vc8"},defaultClass:"ju367vc6"},actionButtonBorderMobile:{conditions:{base:"ju367vc9",hover:"ju367vca",active:"ju367vcb"},defaultClass:"ju367vc9"},actionButtonSecondaryBackground:{conditions:{base:"ju367vcc",hover:"ju367vcd",active:"ju367vce"},defaultClass:"ju367vcc"},closeButton:{conditions:{base:"ju367vcf",hover:"ju367vcg",active:"ju367vch"},defaultClass:"ju367vcf"},closeButtonBackground:{conditions:{base:"ju367vci",hover:"ju367vcj",active:"ju367vck"},defaultClass:"ju367vci"},connectButtonBackground:{conditions:{base:"ju367vcl",hover:"ju367vcm",active:"ju367vcn"},defaultClass:"ju367vcl"},connectButtonBackgroundError:{conditions:{base:"ju367vco",hover:"ju367vcp",active:"ju367vcq"},defaultClass:"ju367vco"},connectButtonInnerBackground:{conditions:{base:"ju367vcr",hover:"ju367vcs",active:"ju367vct"},defaultClass:"ju367vcr"},connectButtonText:{conditions:{base:"ju367vcu",hover:"ju367vcv",active:"ju367vcw"},defaultClass:"ju367vcu"},connectButtonTextError:{conditions:{base:"ju367vcx",hover:"ju367vcy",active:"ju367vcz"},defaultClass:"ju367vcx"},connectionIndicator:{conditions:{base:"ju367vd0",hover:"ju367vd1",active:"ju367vd2"},defaultClass:"ju367vd0"},downloadBottomCardBackground:{conditions:{base:"ju367vd3",hover:"ju367vd4",active:"ju367vd5"},defaultClass:"ju367vd3"},downloadTopCardBackground:{conditions:{base:"ju367vd6",hover:"ju367vd7",active:"ju367vd8"},defaultClass:"ju367vd6"},error:{conditions:{base:"ju367vd9",hover:"ju367vda",active:"ju367vdb"},defaultClass:"ju367vd9"},generalBorder:{conditions:{base:"ju367vdc",hover:"ju367vdd",active:"ju367vde"},defaultClass:"ju367vdc"},generalBorderDim:{conditions:{base:"ju367vdf",hover:"ju367vdg",active:"ju367vdh"},defaultClass:"ju367vdf"}
1080,menuItemBackground:{conditions:{base:"ju367vdi",hover:"ju367vdj",active:"ju367vdk"},defaultClass:"ju367vdi"},modalBackdrop:{conditions:{base:"ju367vdl",hover:"ju367vdm",active:"ju367vdn"},defaultClass:"ju367vdl"},modalBackground:{conditions:{base:"ju367vdo",hover:"ju367vdp",active:"ju367vdq"},defaultClass:"ju367vdo"},modalBorder:{conditions:{base:"ju367vdr",hover:"ju367vds",active:"ju367vdt"},defaultClass:"ju367vdr"},modalText:{conditions:{base:"ju367vdu",hover:"ju367vdv",active:"ju367vdw"},defaultClass:"ju367vdu"},modalTextDim:{conditions:{base:"ju367vdx",hover:"ju367vdy",active:"ju367vdz"},defaultClass:"ju367vdx"},modalTextSecondary:{conditions:{base:"ju367ve0",hover:"ju367ve1",active:"ju367ve2"},defaultClass:"ju367ve0"},profileAction:{conditions:{base:"ju367ve3",hover:"ju367ve4",active:"ju367ve5"},defaultClass:"ju367ve3"},profileActionHover:{conditions:{base:"ju367ve6",hover:"ju367ve7",active:"ju367ve8"},defaultClass:"ju367ve6"},profileForeground:{conditions:{base:"ju367ve9",hover:"ju367vea",active:"ju367veb"},defaultClass:"ju367ve9"},selectedOptionBorder:{conditions:{base:"ju367vec",hover:"ju367ved",active:"ju367vee"},defaultClass:"ju367vec"},standby:{conditions:{base:"ju367vef",hover:"ju367veg",active:"ju367veh"},defaultClass:"ju367vef"}}},boxShadow:{values:{connectButton:{conditions:{base:"ju367vei",hover:"ju367vej",active:"ju367vek"},defaultClass:"ju367vei"},dialog:{conditions:{base:"ju367vel",hover:"ju367vem",active:"ju367ven"},defaultClass:"ju367vel"},profileDetailsAction:{conditions:{base:"ju367veo",hover:"ju367vep",active:"ju367veq"},defaultClass:"ju367veo"},selectedOption:{conditions:{base:"ju367ver",hover:"ju367ves",active:"ju367vet"},defaultClass:"ju367ver"},selectedWallet:{conditions:{base:"ju367veu",hover:"ju367vev",active:"ju367vew"},defaultClass:"ju367veu"},walletLogo:{conditions:{base:"ju367vex",hover:"ju367vey",active:"ju367vez"},defaultClass:"ju367vex"}}},color:{values:{accentColor:{conditions:{base:"ju367vf0",hover:"ju367vf1",active:"ju367vf2"},defaultClass:"ju367vf0"},accentColorForeground:{conditions:{base:"ju367vf3",hover:"ju367vf4",active:"ju367vf5"},defaultClass:"ju367vf3"},actionButtonBorder:{conditions:{base:"ju367vf6",hover:"ju367vf7",active:"ju367vf8"},defaultClass:"ju367vf6"},actionButtonBorderMobile:{conditions:{base:"ju367vf9",hover:"ju367vfa",active:"ju367vfb"},defaultClass:"ju367vf9"},actionButtonSecondaryBackground:{conditions:{base:"ju367vfc",hover:"ju367vfd",active:"ju367vfe"},defaultClass:"ju367vfc"},closeButton:{conditions:{base:"ju367vff",hover:"ju367vfg",active:"ju367vfh"},defaultClass:"ju367vff"},closeButtonBackground:{conditions:{base:"ju367vfi",hover:"ju367vfj",active:"ju367vfk"},defaultClass:"ju367vfi"},connectButtonBackground:{conditions:{base:"ju367vfl",hover:"ju367vfm",active:"ju367vfn"},defaultClass:"ju367vfl"},connectButtonBackgroundError:{conditions:{base:"ju367vfo",hover:"ju367vfp",active:"ju367vfq"},defaultClass:"ju367vfo"},connectButtonInnerBackground:{conditions:{base:"ju367vfr",hover:"ju367vfs",active:"ju367vft"},defaultClass:"ju367vfr"},connectButtonText:{conditions:{base:"ju367vfu",hover:"ju367vfv",active:"ju367vfw"},defaultClass:"ju367vfu"},connectButtonTextError:{conditions:{base:"ju367vfx",hover:"ju367vfy",active:"ju367vfz"},defaultClass:"ju367vfx"},connectionIndicator:{conditions:{base:"ju367vg0",hover:"ju367vg1",active:"ju367vg2"},defaultClass:"ju367vg0"},downloadBottomCardBackground:{conditions:{base:"ju367vg3",hover:"ju367vg4",active:"ju367vg5"},defaultClass:"ju367vg3"},downloadTopCardBackground:{conditions:{base:"ju367vg6",hover:"ju367vg7",active:"ju367vg8"},defaultClass:"ju367vg6"},error:{conditions:{base:"ju367vg9",hover:"ju367vga",active:"ju367vgb"},defaultClass:"ju367vg9"},generalBorder:{conditions:{base:"ju367vgc",hover:"ju367vgd",active:"ju367vge"},defaultClass:"ju367vgc"},generalBorderDim:{conditions:{base:"ju367vgf",hover:"ju367vgg",active:"ju367vgh"},defaultClass:"ju367vgf"}
1080,menuItemBackground:{conditions:{base:"ju367vgi",hover:"ju367vgj",active:"ju367vgk"},defaultClass:"ju367vgi"},modalBackdrop:{conditions:{base:"ju367vgl",hover:"ju367vgm",active:"ju367vgn"},defaultClass:"ju367vgl"},modalBackground:{conditions:{base:"ju367vgo",hover:"ju367vgp",active:"ju367vgq"},defaultClass:"ju367vgo"},modalBorder:{conditions:{base:"ju367vgr",hover:"ju367vgs",active:"ju367vgt"},defaultClass:"ju367vgr"},modalText:{conditions:{base:"ju367vgu",hover:"ju367vgv",active:"ju367vgw"},defaultClass:"ju367vgu"},modalTextDim:{conditions:{base:"ju367vgx",hover:"ju367vgy",active:"ju367vgz"},defaultClass:"ju367vgx"},modalTextSecondary:{conditions:{base:"ju367vh0",hover:"ju367vh1",active:"ju367vh2"},defaultClass:"ju367vh0"},profileAction:{conditions:{base:"ju367vh3",hover:"ju367vh4",active:"ju367vh5"},defaultClass:"ju367vh3"},profileActionHover:{conditions:{base:"ju367vh6",hover:"ju367vh7",active:"ju367vh8"},defaultClass:"ju367vh6"},profileForeground:{conditions:{base:"ju367vh9",hover:"ju367vha",active:"ju367vhb"},defaultClass:"ju367vh9"},selectedOptionBorder:{conditions:{base:"ju367vhc",hover:"ju367vhd",active:"ju367vhe"},defaultClass:"ju367vhc"},standby:{conditions:{base:"ju367vhf",hover:"ju367vhg",active:"ju367vhh"},defaultClass:"ju367vhf"}}}}},{conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0},styles:{alignItems:{values:{"flex-start":{conditions:{smallScreen:"ju367v0",largeScreen:"ju367v1"},defaultClass:"ju367v0"},"flex-end":{conditions:{smallScreen:"ju367v2",largeScreen:"ju367v3"},defaultClass:"ju367v2"},center:{conditions:{smallScreen:"ju367v4",largeScreen:"ju367v5"},defaultClass:"ju367v4"}}},display:{values:{none:{conditions:{smallScreen:"ju367v6",largeScreen:"ju367v7"},defaultClass:"ju367v6"},block:{conditions:{smallScreen:"ju367v8",largeScreen:"ju367v9"},defaultClass:"ju367v8"},flex:{conditions:{smallScreen:"ju367va",largeScreen:"ju367vb"},defaultClass:"ju367va"},inline:{conditions:{smallScreen:"ju367vc",largeScreen:"ju367vd"},defaultClass:"ju367vc"}}}}},{conditions:void 0,styles:{margin:{mappings:["marginTop","marginBottom","marginLeft","marginRight"]},marginX:{mappings:["marginLeft","marginRight"]},marginY:{mappings:["marginTop","marginBottom"]},padding:{mappings:["paddingTop","paddingBottom","paddingLeft","paddingRight"]},paddingX:{mappings:["paddingLeft","paddingRight"]},paddingY:{mappings:["paddingTop","paddingBottom"]},alignSelf:{values:{"flex-start":{defaultClass:"ju367ve"},"flex-end":{defaultClass:"ju367vf"},center:{defaultClass:"ju367vg"}}},backgroundSize:{values:{cover:{defaultClass:"ju367vh"}}},borderRadius:{values:{1:{defaultClass:"ju367vi"},6:{defaultClass:"ju367vj"},10:{defaultClass:"ju367vk"},13:{defaultClass:"ju367vl"},actionButton:{defaultClass:"ju367vm"},connectButton:{defaultClass:"ju367vn"},menuButton:{defaultClass:"ju367vo"},modal:{defaultClass:"ju367vp"},modalMobile:{defaultClass:"ju367vq"},"25%":{defaultClass:"ju367vr"},full:{defaultClass:"ju367vs"}}},borderStyle:{values:{solid:{defaultClass:"ju367vt"}}},borderWidth:{values:{0:{defaultClass:"ju367vu"},1:{defaultClass:"ju367vv"},2:{defaultClass:"ju367vw"},4:{defaultClass:"ju367vx"}}},cursor:{values:{pointer:{defaultClass:"ju367vy"},none:{defaultClass:"ju367vz"}}},pointerEvents:{values:{none:{defaultClass:"ju367v10"},all:{defaultClass:"ju367v11"}}},minHeight:{values:{8:{defaultClass:"ju367v12"},44:{defaultClass:"ju367v13"}}},flexDirection:{values:{row:{defaultClass:"ju367v14"},column:{defaultClass:"ju367v15"}}},fontFamily:{values:{body:{defaultClass:"ju367v16"}}},fontSize:{values:{12:{defaultClass:"ju367v17"},13:{defaultClass:"ju367v18"},14:{defaultClass:"ju367v19"},16:{defaultClass:"ju367v1a"},18:{defaultClass:"ju367v1b"},20:{defaultClass:"ju367v1c"},23:{defaultClass:"ju367v1d"}}},fontWeight:{values:{regular:{defaultClass:"ju367v1e"},medium:{defaultClass:"ju367v1f"},semibold:{defaultClass:"ju367v1g"},bold:{defaultClass:"ju367v1h"},heavy:{defaultClass:"ju367v1i"}}},gap:{values:{0:{defaultClass:"ju367v1j"},1:{defaultClass:"ju367v1k"},2:{defaultClass:"ju367v1l"},3:{defaultClass:"ju367v1m"},4:{defaultClass:"ju367v1n"},5:{defaultClass:"ju367v1o"},6:{defaultClass:"ju367v1p"},8:{defaultClass:"ju367v1q"},10:{defaultClass:"ju367v1r"},12:{defaultClass:"ju367v1s"},14:{defaultClass:"ju367v1t"},16:{defaultClass:"ju367v1u"},18:{defaultClass:"ju367v1v"},20:{defaultClass:"ju367v1w"},24:{defaultClass:"ju367v1x"},28:{defaultClass:"ju367v1y"},32:{defaultClass:"ju367v1z"},36:{defaultClass:"ju367v20"},44:{defaultClass:"ju367v21"},64:{defaultClass:"ju367v22"},"-1":{defaultClass:"ju367v23"}}},height:{values:{1:{defaultClass:"ju367v24"},2:{defaultClass:"ju367v25"},4:{defaultClass:"ju367v26"},8:{defaultClass:"ju367v27"},12:{defaultClass:"ju367v28"},20:{defaultClass:"ju367v29"},24:{defaultClass:"ju367v2a"},28:{defaultClass:"ju367v2b"},30:{defaultClass:"ju367v2c"},32:{defaultClass:"ju367v2d"},34:{defaultClass:"ju367v2e"},36:{defaultClass:"ju367v2f"},40:{defaultClass:"ju367v2g"},44:{defaultClass:"ju367v2h"},48:{defaultClass:"ju367v2i"},54:{defaultClass:"ju367v2j"},60:{defaultClass:"ju367v2k"},200:{defaultClass:"ju367v2l"},full:{defaultClass:"ju367v2m"},max:{defaultClass:"ju367v2n"}}},justifyContent:{values:{"flex-start":{defaultClass:"ju367v2o"},"flex-end":{defaultClass:"ju367v2p"},center:{defaultClass:"ju367v2q"},"space-between":{defaultClass:"ju367v2r"},"space-around":{defaultClass:"ju367v2s"}}},textAlign:{values:{left:{defaultClass:"ju367v2t"},center:{defaultClass:"ju367v2u"},inherit:{defaultClass:"ju367v2v"}}},marginBottom:{values:{0:{defaultClass:"ju367v2w"},1:{defaultClass:"ju367v2x"},2:{defaultClass:"ju367v2y"},3:{defaultClass:"ju367v2z"},4:{defaultClass:"ju367v30"},5:{defaultClass:"ju367v31"},6:{defaultClass:"ju367v32"},8:{defaultClass:"ju367v33"},10:{defaultClass:"ju367v34"},12:{defaultClass:"ju367v35"},14:{defaultClass:"ju367v36"},16:{defaultClass:"ju367v37"},18:{defaultClass:"ju367v38"},20:{defaultClass:"ju367v39"},24:{defaultClass:"ju367v3a"},28:{defaultClass:"ju367v3b"},32:{defaultClass:"ju367v3c"},36:{defaultClass:"ju367v3d"},44:{defaultClass:"ju367v3e"},64:{defaultClass:"ju367v3f"},"-1":{defaultClass:"ju367v3g"}}},marginLeft:{values:{0:{defaultClass:"ju367v3h"},1:{defaultClass:"ju367v3i"},2:{defaultClass:"ju367v3j"},3:{defaultClass:"ju367v3k"},4:{defaultClass:"ju367v3l"},5:{defaultClass:"ju367v3m"},6:{defaultClass:"ju367v3n"},8:{defaultClass:"ju367v3o"},10:{defaultClass:"ju367v3p"},12:{defaultClass:"ju367v3q"},14:{defaultClass:"ju367v3r"},16:{defaultClass:"ju367v3s"},18:{defaultClass:"ju367v3t"},20:{defaultClass:"ju367v3u"},24:{defaultClass:"ju367v3v"},28:{defaultClass:"ju367v3w"},32:{defaultClass:"ju367v3x"},36:{defaultClass:"ju367v3y"},44:{defaultClass:"ju367v3z"},64:{defaultClass:"ju367v40"},"-1":{defaultClass:"ju367v41"}}},marginRight:{values:{0:{defaultClass:"ju367v42"},1:{defaultClass:"ju367v43"},2:{defaultClass:"ju367v44"},3:{defaultClass:"ju367v45"},4:{defaultClass:"ju367v46"},5:{defaultClass:"ju367v47"},6:{defaultClass:"ju367v48"},8:{defaultClass:"ju367v49"},10:{defaultClass:"ju367v4a"},12:{defaultClass:"ju367v4b"},14:{defaultClass:"ju367v4c"},16:{defaultClass:"ju367v4d"},18:{defaultClass:"ju367v4e"},20:{defaultClass:"ju367v4f"},24:{defaultClass:"ju367v4g"},28:{defaultClass:"ju367v4h"},32:{defaultClass:"ju367v4i"},36:{defaultClass:"ju367v4j"},44:{defaultClass:"ju367v4k"},64:{defaultClass:"ju367v4l"},"-1":{defaultClass:"ju367v4m"}}},marginTop:{values:{0:{defaultClass:"ju367v4n"},1:{defaultClass:"ju367v4o"},2:{defaultClass:"ju367v4p"},3:{defaultClass:"ju367v4q"},4:{defaultClass:"ju367v4r"},5:{defaultClass:"ju367v4s"},6:{defaultClass:"ju367v4t"},8:{defaultClass:"ju367v4u"},10:{defaultClass:"ju367v4v"},12:{defaultClass:"ju367v4w"},14:{defaultClass:"ju367v4x"},16:{defaultClass:"ju367v4y"},18:{defaultClass:"ju367v4z"},20:{defaultClass:"ju367v50"},24:{defaultClass:"ju367v51"},28:{defaultClass:"ju367v52"},32:{defaultClass:"ju367v53"},36:{defaultClass:"ju367v54"},44:{defaultClass:"ju367v55"},64:{defaultClass:"ju367v56"},"-1":{defaultClass:"ju367v57"}}},maxWidth:{values:{1:{defaultClass:"ju367v58"},2:{defaultClass:"ju367v59"},4:{defaultClass:"ju367v5a"},8:{defaultClass:"ju367v5b"},12:{defaultClass:"ju367v5c"},20:{defaultClass:"ju367v5d"},24:{defaultClass:"ju367v5e"},28:{defaultClass:"ju367v5f"},30:{defaultClass:"ju367v5g"},32:{defaultClass:"ju367v5h"},34:{defaultClass:"ju367v5i"},36:{defaultClass:"ju367v5j"},40:{defaultClass:"ju367v5k"},44:{defaultClass:"ju367v5l"},48:{defaultClass:"ju367v5m"},54:{defaultClass:"ju367v5n"},60:{defaultClass:"ju367v5o"},200:{defaultClass:"ju367v5p"},full:{defaultClass:"ju367v5q"},max:{defaultClass:"ju367v5r"}}
1080},minWidth:{values:{1:{defaultClass:"ju367v5s"},2:{defaultClass:"ju367v5t"},4:{defaultClass:"ju367v5u"},8:{defaultClass:"ju367v5v"},12:{defaultClass:"ju367v5w"},20:{defaultClass:"ju367v5x"},24:{defaultClass:"ju367v5y"},28:{defaultClass:"ju367v5z"},30:{defaultClass:"ju367v60"},32:{defaultClass:"ju367v61"},34:{defaultClass:"ju367v62"},36:{defaultClass:"ju367v63"},40:{defaultClass:"ju367v64"},44:{defaultClass:"ju367v65"},48:{defaultClass:"ju367v66"},54:{defaultClass:"ju367v67"},60:{defaultClass:"ju367v68"},200:{defaultClass:"ju367v69"},full:{defaultClass:"ju367v6a"},max:{defaultClass:"ju367v6b"}}},overflow:{values:{hidden:{defaultClass:"ju367v6c"}}},paddingBottom:{values:{0:{defaultClass:"ju367v6d"},1:{defaultClass:"ju367v6e"},2:{defaultClass:"ju367v6f"},3:{defaultClass:"ju367v6g"},4:{defaultClass:"ju367v6h"},5:{defaultClass:"ju367v6i"},6:{defaultClass:"ju367v6j"},8:{defaultClass:"ju367v6k"},10:{defaultClass:"ju367v6l"},12:{defaultClass:"ju367v6m"},14:{defaultClass:"ju367v6n"},16:{defaultClass:"ju367v6o"},18:{defaultClass:"ju367v6p"},20:{defaultClass:"ju367v6q"},24:{defaultClass:"ju367v6r"},28:{defaultClass:"ju367v6s"},32:{defaultClass:"ju367v6t"},36:{defaultClass:"ju367v6u"},44:{defaultClass:"ju367v6v"},64:{defaultClass:"ju367v6w"},"-1":{defaultClass:"ju367v6x"}}},paddingLeft:{values:{0:{defaultClass:"ju367v6y"},1:{defaultClass:"ju367v6z"},2:{defaultClass:"ju367v70"},3:{defaultClass:"ju367v71"},4:{defaultClass:"ju367v72"},5:{defaultClass:"ju367v73"},6:{defaultClass:"ju367v74"},8:{defaultClass:"ju367v75"},10:{defaultClass:"ju367v76"},12:{defaultClass:"ju367v77"},14:{defaultClass:"ju367v78"},16:{defaultClass:"ju367v79"},18:{defaultClass:"ju367v7a"},20:{defaultClass:"ju367v7b"},24:{defaultClass:"ju367v7c"},28:{defaultClass:"ju367v7d"},32:{defaultClass:"ju367v7e"},36:{defaultClass:"ju367v7f"},44:{defaultClass:"ju367v7g"},64:{defaultClass:"ju367v7h"},"-1":{defaultClass:"ju367v7i"}}},paddingRight:{values:{0:{defaultClass:"ju367v7j"},1:{defaultClass:"ju367v7k"},2:{defaultClass:"ju367v7l"},3:{defaultClass:"ju367v7m"},4:{defaultClass:"ju367v7n"},5:{defaultClass:"ju367v7o"},6:{defaultClass:"ju367v7p"},8:{defaultClass:"ju367v7q"},10:{defaultClass:"ju367v7r"},12:{defaultClass:"ju367v7s"},14:{defaultClass:"ju367v7t"},16:{defaultClass:"ju367v7u"},18:{defaultClass:"ju367v7v"},20:{defaultClass:"ju367v7w"},24:{defaultClass:"ju367v7x"},28:{defaultClass:"ju367v7y"},32:{defaultClass:"ju367v7z"},36:{defaultClass:"ju367v80"},44:{defaultClass:"ju367v81"},64:{defaultClass:"ju367v82"},"-1":{defaultClass:"ju367v83"}}},paddingTop:{values:{0:{defaultClass:"ju367v84"},1:{defaultClass:"ju367v85"},2:{defaultClass:"ju367v86"},3:{defaultClass:"ju367v87"},4:{defaultClass:"ju367v88"},5:{defaultClass:"ju367v89"},6:{defaultClass:"ju367v8a"},8:{defaultClass:"ju367v8b"},10:{defaultClass:"ju367v8c"},12:{defaultClass:"ju367v8d"},14:{defaultClass:"ju367v8e"},16:{defaultClass:"ju367v8f"},18:{defaultClass:"ju367v8g"},20:{defaultClass:"ju367v8h"},24:{defaultClass:"ju367v8i"},28:{defaultClass:"ju367v8j"},32:{defaultClass:"ju367v8k"},36:{defaultClass:"ju367v8l"},44:{defaultClass:"ju367v8m"},64:{defaultClass:"ju367v8n"},"-1":{defaultClass:"ju367v8o"}}},position:{values:{absolute:{defaultClass:"ju367v8p"},fixed:{defaultClass:"ju367v8q"},relative:{defaultClass:"ju367v8r"}}},WebkitUserSelect:{values:{none:{defaultClass:"ju367v8s"}}},right:{values:{0:{defaultClass:"ju367v8t"}}},transition:{values:{default:{defaultClass:"ju367v8u"},transform:{defaultClass:"ju367v8v"}}},userSelect:{values:{none:{defaultClass:"ju367v8w"}}},width:{values:{1:{defaultClass:"ju367v8x"},2:{defaultClass:"ju367v8y"},4:{defaultClass:"ju367v8z"},8:{defaultClass:"ju367v90"},12:{defaultClass:"ju367v91"},20:{defaultClass:"ju367v92"},24:{defaultClass:"ju367v93"},28:{defaultClass:"ju367v94"},30:{defaultClass:"ju367v95"},32:{defaultClass:"ju367v96"},34:{defaultClass:"ju367v97"},36:{defaultClass:"ju367v98"},40:{defaultClass:"ju367v99"},44:{defaultClass:"ju367v9a"},48:{defaultClass:"ju367v9b"},54:{defaultClass:"ju367v9c"},60:{defaultClass:"ju367v9d"},200:{defaultClass:"ju367v9e"},full:{defaultClass:"ju367v9f"},max:{defaultClass:"ju367v9g"}}},backdropFilter:{values:{modalOverlay:{defaultClass:"ju367v9h"}}}}}),ez={colors:{accentColor:"var(--rk-colors-accentColor)",accentColorForeground:"var(--rk-colors-accentColorForeground)",actionButtonBorder:"var(--rk-colors-actionButtonBorder)",actionButtonBorderMobile:"var(--rk-colors-actionButtonBorderMobile)",actionButtonSecondaryBackgroun
1080d:"var(--rk-colors-actionButtonSecondaryBackground)",closeButton:"var(--rk-colors-closeButton)",closeButtonBackground:"var(--rk-colors-closeButtonBackground)",connectButtonBackground:"var(--rk-colors-connectButtonBackground)",connectButtonBackgroundError:"var(--rk-colors-connectButtonBackgroundError)",connectButtonInnerBackground:"var(--rk-colors-connectButtonInnerBackground)",connectButtonText:"var(--rk-colors-connectButtonText)",connectButtonTextError:"var(--rk-colors-connectButtonTextError)",connectionIndicator:"var(--rk-colors-connectionIndicator)",downloadBottomCardBackground:"var(--rk-colors-downloadBottomCardBackground)",downloadTopCardBackground:"var(--rk-colors-downloadTopCardBackground)",error:"var(--rk-colors-error)",generalBorder:"var(--rk-colors-generalBorder)",generalBorderDim:"var(--rk-colors-generalBorderDim)",menuItemBackground:"var(--rk-colors-menuItemBackground)",modalBackdrop:"var(--rk-colors-modalBackdrop)",modalBackground:"var(--rk-colors-modalBackground)",modalBorder:"var(--rk-colors-modalBorder)",modalText:"var(--rk-colors-modalText)",modalTextDim:"var(--rk-colors-modalTextDim)",modalTextSecondary:"var(--rk-colors-modalTextSecondary)",profileAction:"var(--rk-colors-profileAction)",profileActionHover:"var(--rk-colors-profileActionHover)",profileForeground:"var(--rk-colors-profileForeground)",selectedOptionBorder:"var(--rk-colors-selectedOptionBorder)",standby:"var(--rk-colors-standby)"},fonts:{body:"var(--rk-fonts-body)"},radii:{actionButton:"var(--rk-radii-actionButton)",connectButton:"var(--rk-radii-connectButton)",menuButton:"var(--rk-radii-menuButton)",modal:"var(--rk-radii-modal)",modalMobile:"var(--rk-radii-modalMobile)"},shadows:{connectButton:"var(--rk-shadows-connectButton)",dialog:"var(--rk-shadows-dialog)",profileDetailsAction:"var(--rk-shadows-profileDetailsAction)",selectedOption:"var(--rk-shadows-selectedOption)",selectedWallet:"var(--rk-shadows-selectedWallet)",walletLogo:"var(--rk-shadows-walletLogo)"},blurs:{modalOverlay:"var(--rk-blurs-modalOverlay)"}},eW={shrink:"_12cbo8i6",shrinkSm:"_12cbo8i7"},eG={grow:"_12cbo8i4",growLg:"_12cbo8i5"};function touchableStyles({active:e,hover:t}){return["_12cbo8i3 ju367v8r",t&&eG[t],eW[e]]}var eK=(0,J.createContext)(null);function useAuthenticationStatus(){var e;let t=(0,J.useContext)(eK);return null!=(e=null==t?void 0:t.status)?e:null}function useConnectionStatus(){let e=useAuthenticationStatus(),{isConnected:t}=(0,et.mA)();return t?e&&("loading"===e||"unauthenticated"===e)?e:"connected":"disconnected"}function isAndroid(){return"undefined"!=typeof navigator&&/android/i.test(navigator.userAgent)}function isIOS(){return"undefined"!=typeof navigator&&/iPhone|iPod/.test(navigator.userAgent)||"undefined"!=typeof navigator&&(/iPad/.test(navigator.userAgent)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1)}function isMobile(){return isAndroid()||isIOS()}var eV={a:"iekbcca",blockquote:"iekbcc2",button:"iekbcc9",input:"iekbcc8 iekbcc5 iekbcc4",mark:"iekbcc6",ol:"iekbcc1",q:"iekbcc2",select:"iekbcc7 iekbcc5 iekbcc4",table:"iekbcc3",textarea:"iekbcc5 iekbcc4",ul:"iekbcc1"},atoms=({reset:e,...t})=>{if(!e)return eH(t);let n=eV[e],o=eH(t);return(0,eo.Z)("iekbcc0",n,o)},eQ=J.forwardRef(({as:e="div",className:t,testId:n,...o},i)=>{let s={},c={};for(let e in o)eH.properties.has(e)?s[e]=o[e]:c[e]=o[e];let l=atoms({reset:"string"==typeof e?e:"div",...s});return J.createElement(e,{className:(0,eo.Z)(l,t),...c,"data-testid":n?`rk-${n.replace(/^rk-/,"")}`:void 0,ref:i})});eQ.displayName="Box";var eZ=new Map,eX=new Map;async function loadAsyncImage(e){let t=eX.get(e);if(t)return t;let load=async()=>e().then(async t=>(eZ.set(e,t),t)),n=load().catch(t=>load().catch(t=>{eX.delete(e)}));return eX.set(e,n),n}async function loadImages(...e){return await Promise.all(e.map(e=>"function"==typeof e?loadAsyncImage(e):e))}function useAsyncImage(e){let t="function"==typeof e?eZ.get(e):void 0,n=function(){let[,e]=(0,J.useReducer)(e=>e+1,0);return e}();return(0,J.useEffect)(()=>{"function"!=typeof e||t||loadAsyncImage(e).then(n)},[e,t,n]),"function"==typeof e?t:e}function AsyncImage({alt:e,background:t,borderColor:n,borderRadius:o,boxShadow:i,height:s,src:c,width:l,testId:u}){let d=isIOS(),p=useAsyncImage(c),m=p&&/^http/.test(p),[b,g]=(0,J.useReducer)(()=>!0,!1);return J.createElement(eQ,{"aria-label":e,borderRadius:o,boxShadow:i,height:"string"==typeof s?s:void 0,overflow:"hidden",position:"relative",role:"img",style:{background:t,height:"number"==typeof s?s:void 0,width:"number"==typeof l?l:void 0}
1080,width:"string"==typeof l?l:void 0,testId:u},J.createElement(eQ,{...m?{"aria-hidden":!0,as:"img",onLoad:g,src:p}:{backgroundSize:"cover"},height:"full",position:"absolute",...d?{WebkitUserSelect:"none"}:{},style:{touchCallout:"none",transition:"opacity .15s linear",userSelect:"none",...m?{opacity:b?1:0}:{backgroundImage:p?`url(${p})`:void 0,backgroundRepeat:"no-repeat",opacity:p?1:0}},width:"full"}),n?J.createElement(eQ,{..."object"==typeof n&&"custom"in n?{style:{borderColor:n.custom}}:{borderColor:n},borderRadius:o,borderStyle:"solid",borderWidth:"1",height:"full",position:"relative",width:"full"}):null)}var useRandomId=e=>(0,J.useMemo)(()=>`${e}_${Math.round(1e9*Math.random())}`,[e]),SpinnerIcon=({height:e=21,width:t=21})=>{let n=useRandomId("spinner");return J.createElement("svg",{className:"_1luule42",fill:"none",height:e,viewBox:"0 0 21 21",width:t,xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Loading"),J.createElement("clipPath",{id:n},J.createElement("path",{d:"M10.5 3C6.35786 3 3 6.35786 3 10.5C3 14.6421 6.35786 18 10.5 18C11.3284 18 12 18.6716 12 19.5C12 20.3284 11.3284 21 10.5 21C4.70101 21 0 16.299 0 10.5C0 4.70101 4.70101 0 10.5 0C16.299 0 21 4.70101 21 10.5C21 11.3284 20.3284 12 19.5 12C18.6716 12 18 11.3284 18 10.5C18 6.35786 14.6421 3 10.5 3Z"})),J.createElement("foreignObject",{clipPath:`url(#${n})`,height:"21",width:"21",x:"0",y:"0"},J.createElement("div",{className:"_1luule43"})))},eY=[{color:"#FC5C54",emoji:"\uD83C\uDF36"},{color:"#FFD95A",emoji:"\uD83E\uDD11"},{color:"#E95D72",emoji:"\uD83D\uDC19"},{color:"#6A87C8",emoji:"\uD83E\uDED0"},{color:"#5FD0F3",emoji:"\uD83D\uDC33"},{color:"#FC5C54",emoji:"\uD83E\uDD36"},{color:"#75C06B",emoji:"\uD83C\uDF32"},{color:"#FFDD86",emoji:"\uD83C\uDF1E"},{color:"#5FC6D4",emoji:"\uD83D\uDC12"},{color:"#FF949A",emoji:"\uD83D\uDC35"},{color:"#FF8024",emoji:"\uD83E\uDD8A"},{color:"#9BA1A4",emoji:"\uD83D\uDC3C"},{color:"#EC66FF",emoji:"\uD83E\uDD84"},{color:"#FF8CBC",emoji:"\uD83D\uDC37"},{color:"#FF9A23",emoji:"\uD83D\uDC27"},{color:"#FF949A",emoji:"\uD83E\uDDA9"},{color:"#C5DADB",emoji:"\uD83D\uDC7D"},{color:"#FC5C54",emoji:"\uD83C\uDF88"},{color:"#FF949A",emoji:"\uD83C\uDF49"},{color:"#FFD95A",emoji:"\uD83C\uDF89"},{color:"#A8CE63",emoji:"\uD83D\uDC32"},{color:"#71ABFF",emoji:"\uD83C\uDF0E"},{color:"#FFE279",emoji:"\uD83C\uDF4A"},{color:"#B6B1B6",emoji:"\uD83D\uDC2D"},{color:"#FF6780",emoji:"\uD83C\uDF63"},{color:"#FFD95A",emoji:"\uD83D\uDC25"},{color:"#A575FF",emoji:"\uD83D\uDC7E"},{color:"#A8CE63",emoji:"\uD83E\uDD66"},{color:"#FC5C54",emoji:"\uD83D\uDC79"},{color:"#FFE279",emoji:"\uD83D\uDE40"},{color:"#5FD0F3",emoji:"⛱"},{color:"#4D82FF",emoji:"⛵️"},{color:"#FFE279",emoji:"\uD83E\uDD73"},{color:"#FF949A",emoji:"\uD83E\uDD2F"},{color:"#FFB35A",emoji:"\uD83E\uDD20"}],defaultAvatar=({address:e,ensImage:t,size:n})=>{let[o,i]=(0,J.useState)(!1);(0,J.useEffect)(()=>{if(t){let e=new Image;e.src=t,e.onload=()=>i(!0)}},[t]);
1080let{color:s,emoji:c}=(0,J.useMemo)(()=>(function(e){let t=Math.abs(function(e){let t=0;if(0===e.length)return t;for(let n=0;n<e.length;n++){let o=e.charCodeAt(n);t=(t<<5)-t+o|0}return t}(("string"==typeof e?e:"").toLowerCase())%eY.length);return eY[null!=t?t:0]})(e),[e]);return t?o?J.createElement(eQ,{backgroundSize:"cover",borderRadius:"full",position:"absolute",style:{backgroundImage:`url(${t})`,backgroundPosition:"center",height:n,width:n}}):J.createElement(eQ,{alignItems:"center",backgroundSize:"cover",borderRadius:"full",color:"modalText",display:"flex",justifyContent:"center",position:"absolute",style:{height:n,width:n}},J.createElement(SpinnerIcon,null)):J.createElement(eQ,{alignItems:"center",display:"flex",justifyContent:"center",overflow:"hidden",style:{...!t&&{backgroundColor:s},height:n,width:n}},c)},eJ=(0,J.createContext)(defaultAvatar);function Avatar({address:e,imageUrl:t,loading:n,size:o}){let i=(0,J.useContext)(eJ);return J.createElement(eQ,{"aria-hidden":!0,borderRadius:"full",overflow:"hidden",position:"relative",style:{height:`${o}px`,width:`${o}px`},userSelect:"none"},J.createElement(eQ,{alignItems:"center",borderRadius:"full",display:"flex",justifyContent:"center",overflow:"hidden",position:"absolute",style:{fontSize:`${Math.round(.55*o)}px`,height:`${o}px`,transform:n?"scale(0.72)":void 0,transition:".25s ease",transitionDelay:n?void 0:".1s",width:`${o}px`,willChange:"transform"},userSelect:"none"},J.createElement(i,{address:e,ensImage:t,size:o})),n&&J.createElement(eQ,{color:"accentColor",display:"flex",height:"full",position:"absolute",width:"full"},J.createElement(SpinnerIcon,{height:"100%",width:"100%"})))}var DropdownIcon=()=>J.createElement("svg",{fill:"none",height:"7",width:"14",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Dropdown"),J.createElement("path",{d:"M12.75 1.54001L8.51647 5.0038C7.77974 5.60658 6.72026 5.60658 5.98352 5.0038L1.75 1.54001",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2.5",xmlns:"http://www.w3.org/2000/svg"})),e0=new class{constructor(e){for(let[t,n]of(this.listeners=new Set,this.defaultLocale="en",this.enableFallback=!1,this.locale="en",this.cachedLocales=[],this.translations={},Object.entries(e)))this.cachedLocales=[...this.cachedLocales,t],this.translations={...this.translations,...this.flattenTranslation(n,t)}}missingMessage(e){return`[missing: "${this.locale}.${e}" translation]`}flattenTranslation(e,t){let n={},flatten2=(e,t)=>{for(let o of Object.keys(e)){let i=`${t}.${o}`,s=e[o];"object"==typeof s&&null!==s?flatten2(s,i):n[i]=s}};return flatten2(e,t),n}translateWithReplacements(e,t={}){let n=e;for(let e in t){let o=t[e];n=n.replace(`%{${e}}`,o)}return n}t(e,t){let n=`${this.locale}.${e}`,o=this.translations[n];if(!o){if(this.enableFallback){let n=`${this.defaultLocale}.${e}`,o=this.translations[n];if(o)return this.translateWithReplacements(o,t)}return this.missingMessage(e)}return this.translateWithReplacements(o,t)}isLocaleCached(e){return this.cachedLocales.includes(e)}updateLocale(e){this.locale=e,this.notifyListeners()}setTranslations(e,t){let n=this.isLocaleCached(e);n||(this.cachedLocales=[...this.cachedLocales,e],this.translations={...this.translations,...this.flattenTranslation(t,e)}),this.locale=e,this.notifyListeners()}notifyListeners(){for(let e of this.listeners)e()}onChange(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}}({en:JSON.parse(Y.I),"en-US":JSON.parse(Y.I)});e0.defaultLocale="en-US",e0.locale="en-US",e0.enableFallback=!0;var fetchTranslations=async e=>{switch(e){case"ar":case"ar-AR":return(await n.e(5953).then(n.bind(n,55953))).default;case"en":case"en-US":default:return(await n.e(4680).then(n.bind(n,64680))).default;case"es":case"es-419":return(await n.e(3437).then(n.bind(n,53437))).default;case"fr":case"fr-FR":return(await n.e(653).then(n.bind(n,80653))).default;case"hi":case"hi-IN":return(await n.e(4963).then(n.bind(n,84963))).default;case"id":case"id-ID":return(await n.e(9813).then(n.bind(n,69813))).default;case"ja":case"ja-JP":return(await n.e(1520).then(n.bind(n,51520))).default;case"ko":case"ko-KR":return(await n.e(2296).then(n.bind(n,62296))).default;case"pt":case"pt-BR":return(await n.e(2755).then(n.bind(n,82755))).default;case"ru":case"ru-RU":return(await n.e(5133).then(n.bind(n,95133))).default;case"th":case"th-TH":return(await n.e(6981).then(n.bind(n,96981))).default;case"tr":case"tr-TR":return(await n.e(6548).then(n.bind(n,36548))).default;case"ua":case"uk-UA":return(await n.e(314).then(n.bind(n,50314))).default;case"zh":case"zh-CN":return(await n.e(1719).then(n.bind(n,51719))).default}};async function setLocale(e){let t=e0.isLocaleCached(e);if(t){e0.updateLocale(e);return}let n=await fetchTranslations(e);e0.setTranslations(e,JSON.parse(n))}var detectedBrowserLocale=()=>{var e;if("undefined"!=typeof window&&"undefined"!=typeof navigator){if(null==(e=navigator.languages)?void 0:e.length)return navigator.languages[0];if(navigator.language)return navigator.language}},e1=(0,J.createContext)({i18n:e0}),I18nProvider=({children:e,locale:t})=>{let[n,o]=(0,J.useState)(0),i=(0,J.useMemo)(()=>detectedBrowserLocale(),[]);(0,J.useEffect)(()=>{let e=e0.onChange(()=>{o(e=>e+1)});return e},[]),(0,J.useEffect)(()=>{t&&t!==e0.locale?setLocale(t):!t&&i&&i!==e0.locale&&setLocale(i)},[t,i]);let s=(0,J.useMemo)(()=>({t:(e,t)=>e0.t(e,t),i18n:e0}),[n]);return J.createElement(e1.Provider,{value:s},e)};function isNotNullish(e){return null!=e}
1080var e2={iconBackground:"#96bedc",iconUrl:async()=>(await n.e(1727).then(n.bind(n,1727))).default},e6={iconBackground:"#e84141",iconUrl:async()=>(await n.e(6237).then(n.bind(n,36237))).default},e3={iconBackground:"#0052ff",iconUrl:async()=>(await n.e(1711).then(n.bind(n,41711))).default},e5={iconBackground:"#ebac0e",iconUrl:async()=>(await n.e(4253).then(n.bind(n,84253))).default},e8={iconBackground:"#002D74",iconUrl:async()=>(await n.e(5939).then(n.bind(n,95939))).default},e4={iconBackground:"#484c50",iconUrl:async()=>(await n.e(5488).then(n.bind(n,85488))).default},e7={iconBackground:"#ff5a57",iconUrl:async()=>(await n.e(704).then(n.bind(n,60704))).default},e9={iconBackground:"#9f71ec",iconUrl:async()=>(await n.e(8881).then(n.bind(n,48881))).default},tt={iconBackground:"#f9f7ec",iconUrl:async()=>(await n.e(135).then(n.bind(n,70135))).default},tn={iconBackground:"#f9f7ec",iconUrl:async()=>(await n.e(4583).then(n.bind(n,94583))).default},to={iconBackground:"#000000",iconUrl:async()=>(await n.e(5119).then(n.bind(n,65119))).default},ta=Object.fromEntries(Object.values({arbitrum:{chainId:42161,name:"Arbitrum",...e2},arbitrumGoerli:{chainId:421613,...e2},arbitrumSepolia:{chainId:421614,...e2},avalanche:{chainId:43114,...e6},avalancheFuji:{chainId:43113,...e6},base:{chainId:8453,name:"Base",...e3},baseGoerli:{chainId:84531,...e3},baseSepolia:{chainId:84532,...e3},bsc:{chainId:56,name:"BSC",...e5},bscTestnet:{chainId:97,...e5},cronos:{chainId:25,...e8},cronosTestnet:{chainId:338,...e8},goerli:{chainId:5,...e4},hardhat:{chainId:31337,iconBackground:"#f9f7ec",iconUrl:async()=>(await n.e(6253).then(n.bind(n,26253))).default},holesky:{chainId:17e3,...e4},kovan:{chainId:42,...e4},localhost:{chainId:1337,...e4},mainnet:{chainId:1,name:"Ethereum",...e4},optimism:{chainId:10,name:"Optimism",...e7},optimismGoerli:{chainId:420,...e7},optimismKovan:{chainId:69,...e7},optimismSepolia:{chainId:11155420,...e7},polygon:{chainId:137,name:"Polygon",...e9},polygonMumbai:{chainId:80001,...e9},rinkeby:{chainId:4,...e4},ropsten:{chainId:3,...e4},sepolia:{chainId:11155111,...e4},xdc:{chainId:50,name:"XinFin",...tt},xdcTestnet:{chainId:51,...tt},zkSync:{chainId:324,name:"zkSync",...tn},zkSyncTestnet:{chainId:280,...tn},zora:{chainId:7777777,name:"Zora",...to},zoraSepolia:{chainId:999999999,...to},zoraTestnet:{chainId:999,...to}}).filter(isNotNullish).map(({chainId:e,...t})=>[e,t])),provideRainbowKitChains=e=>e.map(e=>{var t,n,o,i;let s=null!=(t=ta[e.id])?t:{};return{...e,name:null!=(n=s.name)?n:e.name,iconUrl:null!=(o=e.iconUrl)?o:s.iconUrl,iconBackground:null!=(i=e.iconBackground)?i:s.iconBackground}}),ti=(0,J.createContext)({chains:[]});function RainbowKitChainProvider({chains:e,children:t,initialChain:n}){return J.createElement(ti.Provider,{value:(0,J.useMemo)(()=>({chains:provideRainbowKitChains(e),initialChainId:"number"==typeof n?n:null==n?void 0:n.id}),[e,n])},t)}var useRainbowKitChains=()=>(0,J.useContext)(ti).chains,useInitialChainId=()=>(0,J.useContext)(ti).initialChainId,useRainbowKitChainsById=()=>{let e=useRainbowKitChains();return(0,J.useMemo)(()=>{let t={};for(let n of e)t[n.id]=n;return t},[e])},ts=(0,J.createContext)({showBalance:void 0,setShowBalance:()=>{}});function ShowBalanceProvider({children:e}){let[t,n]=(0,J.useState)();return J.createElement(ts.Provider,{value:{showBalance:t,setShowBalance:n}},e)}var useShowBalance=()=>(0,J.useContext)(ts);function useMainnet(){let e=ea.RJ.id,t=(0,et.t_)(),n=Array.isArray(t.chains)?t.chains:[],o=null==n?void 0:n.some(t=>(null==t?void 0:t.id)===e);return{chainId:e,enabled:o}}function useMainnetEnsAvatar(e){let{chainId:t,enabled:n}=useMainnet(),{data:o}=(0,et.c9)({chainId:t,enabled:n,name:e});return o}function useMainnetEnsName(e){let{chainId:t,enabled:n}=useMainnet(),{data:o}=(0,et.F6)({address:e,chainId:t,enabled:n});return o}function useChainId(){var e;let{chain:t}=(0,et.LN)();return null!=(e=null==t?void 0:t.id)?e:null}var tc="rk-transactions";function loadData(){return function(e){try{let t=e?JSON.parse(e):{};return"object"==typeof t?t:{}}catch{return{}}}("undefined"!=typeof localStorage?localStorage.getItem(tc):null)}var tl=/^0x([A-Fa-f0-9]{64})$/,tu=(0,J.createContext)(null);function TransactionStoreProvider({children:e}){let t=(0,et.t_)(),{address:n}=(0,et.mA)(),o=useChainId(),[i]=(0,J.useState)(()=>null!=Z?Z:Z=function({provider:e}){let t=loadData(),n=e,o=new Set,i=new Map;function getTransactions(e,n){var o,i;return null!=(i=null==(o=t[e])?void 0:o[n])?i:[]}function setTransactionStatus(e,t,n,o){updateTransactions(e,t,e=>e.map(e=>e.hash===n?{...e,status:o}:e))}async function waitForPendingTransactions(e,t){await Promise.all(getTransactions(e,t).filter(e=>"pending"===e.status).map(async o=>{let{confirmations:s,hash:c}=o,l=i.get(c);if(l)return await l;let u=n.waitForTransactionReceipt({confirmations:s,hash:c,timeout:3e5}).then(({status:n})=>{i.delete(c),void 0!==n&&setTransactionStatus(e,t,c,0===n||"reverted"===n?"failed":"confirmed")}
1080).catch(()=>{setTransactionStatus(e,t,c,"failed")});return i.set(c,u),await u}))}function updateTransactions(e,n,i){var s,c;(t=loadData())[e]=null!=(s=t[e])?s:{};let l=0,u=i(null!=(c=t[e][n])?c:[]).filter(({status:e})=>"pending"===e||l++<=10);t[e][n]=u.length>0?u:void 0,localStorage.setItem(tc,JSON.stringify(t)),function(){for(let e of o)e()}(),waitForPendingTransactions(e,n)}return{addTransaction:function(e,t,n){let o=function(e){let t=[];return tl.test(e.hash)||t.push("Invalid transaction hash"),"string"!=typeof e.description&&t.push("Transaction must have a description"),void 0!==e.confirmations&&(!Number.isInteger(e.confirmations)||e.confirmations<1)&&t.push("Transaction confirmations must be a positiver integer"),t}(n);if(o.length>0)throw Error(["Unable to add transaction",...o].join("\n"));updateTransactions(e,t,e=>[{...n,status:"pending"},...e.filter(({hash:e})=>e!==n.hash)])},clearTransactions:function(e,t){updateTransactions(e,t,()=>[])},getTransactions,onChange:function(e){return o.add(e),()=>{o.delete(e)}},setProvider:function(e){n=e},waitForPendingTransactions}}({provider:t}));return(0,J.useEffect)(()=>{i.setProvider(t)},[i,t]),(0,J.useEffect)(()=>{n&&o&&i.waitForPendingTransactions(n,o)},[i,n,o]),J.createElement(tu.Provider,{value:i},e)}function useTransactionStore(){let e=(0,J.useContext)(tu);if(!e)throw Error("Transaction hooks must be used within RainbowKitProvider");return e}function useRecentTransactions(){let e=useTransactionStore(),{address:t}=(0,et.mA)(),n=useChainId(),[o,i]=(0,J.useState)(()=>e&&t&&n?e.getTransactions(t,n):[]);return(0,J.useEffect)(()=>{if(e&&t&&n)return i(e.getTransactions(t,n)),e.onChange(()=>{i(e.getTransactions(t,n))})},[e,t,n]),o}var resolveThemeVars=e=>"function"==typeof e?e():e;function cssStringFromTheme(e,t={}){return Object.entries(function(e,{extends:t}={}){let n={...assignInlineVars(ez,resolveThemeVars(e))};if(!t)return n;let o=assignInlineVars(ez,resolveThemeVars(t)),i=Object.fromEntries(Object.entries(n).filter(([e,t])=>t!==o[e]));return i}(e,t)).map(([e,t])=>`${e}:${t.replace(/[:;{}</>]/g,"")};`).join("")}var td={appName:void 0,disclaimer:void 0,learnMoreUrl:"https://learn.rainbow.me/understanding-web3?utm_source=rainbowkit&utm_campaign=learnmore"},tf=(0,J.createContext)(td),tp=(0,J.createContext)(!1),useWindowSize=()=>{let[e,t]=(0,J.useState)({height:void 0,width:void 0});return(0,J.useEffect)(()=>{var e;let n;let o=(e=()=>{t({height:window.innerHeight,width:window.innerWidth})},()=>{n&&clearTimeout(n),n=setTimeout(()=>{n=null,e()},500)});return window.addEventListener("resize",o),o(),()=>window.removeEventListener("resize",o)},[]),e},th=(0,J.createContext)({connector:null,setConnector:()=>{}});function WalletButtonProvider({children:e}){let[t,n]=(0,J.useState)(null);return J.createElement(th.Provider,{value:(0,J.useMemo)(()=>({connector:t,setConnector:n}),[t])},e)}var tm={COMPACT:"compact",WIDE:"wide"},tb=(0,J.createContext)(tm.WIDE);function ModalSizeProvider({children:e,modalSize:t}){let{width:n}=useWindowSize(),{connector:o}=(0,J.useContext)(th);return J.createElement(tb.Provider,{value:n&&n<768||o?tm.COMPACT:t},e)}var tg=(0,J.createContext)(!1);function isSafari(){return"undefined"!=typeof navigator&&/Version\/([0-9._]+).*Safari/.test(navigator.userAgent)}function getBrowser(){var e;if("undefined"==typeof navigator)return"Browser";let t=navigator.userAgent.toLowerCase();return(null==(e=navigator.brave)?void 0:e.isBrave)?"Brave":t.indexOf("edg/")>-1?"Edge":t.indexOf("op")>-1?"Opera":"undefined"!=typeof document&&""!==getComputedStyle(document.body).getPropertyValue("--arc-palette-focus")?"Arc":t.indexOf("chrome")>-1?"Chrome":t.indexOf("firefox")>-1?"Firefox":isSafari()?"Safari":"Browser"}var{os:ty}=(0,ex.UAParser)();function getPlatform(){return"Windows"===ty.name?"Windows":"Mac OS"===ty.name?"macOS":["Ubuntu","Mint","Fedora","Debian","Arch","Linux"].includes(ty.name)?"Linux":"Desktop"}var getExtensionDownloadUrl=e=>{var t,n,o,i,s,c,l,u,d,p,m,b;let g=getBrowser();return null!=(b=({Arc:null==(t=null==e?void 0:e.downloadUrls)?void 0:t.chrome,Brave:null==(n=null==e?void 0:e.downloadUrls)?void 0:n.chrome,Chrome:null==(o=null==e?void 0:e.downloadUrls)?void 0:o.chrome,Edge:(null==(i=null==e?void 0:e.downloadUrls)?void 0:i.edge)||(null==(s=null==e?void 0:e.downloadUrls)?void 0:s.chrome),Firefox:null==(c=null==e?void 0:e.downloadUrls)?void 0:c.firefox,Opera:(null==(l=null==e?void 0:e.downloadUrls)?void 0:l.opera)||(null==(u=null==e?void 0:e.downloadUrls)?void 0:u.chrome),Safari:null==(d=null==e?void 0:e.downloadUrls)?void 0:d.safari,Browser:null==(p=null==e?void 0:e.downloadUrls)?void 0:p.browserExtension})[g])?b:null==(m=null==e?void 0:e.downloadUrls)?void 0:m.browserExtension},getMobileDownloadUrl=e=>{var t,n,o,i;let s=isIOS();return null!=(i=s?null==(t=null==e?void 0:e.downloadUrls)?void 0:t.ios:null==(n=null==e?void 0:e.downloadUrls)?void 0:n.android)?i:null==(o=null==e?void 0:e.downloadUrls)?void 0:o.mobile},getDesktopDownloadUrl=e=>{var t,n,o,i,s,c;let l=getPlatform();return null!=(c=({Windows:null==(t=null==e?void 0:e.downloadUrls)?void 0:t.windows,macOS:null==(n=null==e?void 0:e.downloadUrls)?void 0:n.macos,Linux:null==(o=null==e?void 0:e.downloadUrls)?void 0:o.linux,Desktop:null==(i=null==e?void 0:e.downloadUrls)?void 0:i.desktop})[l])?c:null==(s=null==e?void 0:e.downloadUrls)?void 0:s.desktop},tv="rk-recent";function getRecentWalletIds(){return"undefined"!=typeof localStorage?function(e){try{let t=e?JSON.parse(e):[];return Array.isArray(t)?t:[]}catch{return[]}}(localStorage.getItem(tv)):[]}function useWalletConnectors(){var e;let t=useRainbowKitChains(),n=useInitialChainId(),{connectAsync:o,connectors:i}=(0,et.$4)();async function connectWallet(e,i){var s,c,l;let u=await i.getChainId(),d=await o({chainId:null!=(l=null!=n?n:null==(s=t.find(({id:e})=>e===u))?void 0:s.id)?l:null==(c=t[0])?void 0:c.id,connector:i});return d&&function(e){var t;let n=(t=[e,...getRecentWalletIds()],[...new Set(t)]);localStorage.setItem(tv,JSON.stringify(n))}(e),d}
1080async function connectToWalletConnectModal(e,t){try{return await connectWallet(e,t)}catch(t){let e="UserRejectedRequestError"===t.name||"Connection request reset. Please try again."===t.message;if(!e)throw t}}let s=(function(e){let t=[];for(let n of e)t.push(...n);return t})(i.map(e=>{var t;return null!=(t=e._wallets)?t:[]})).sort((e,t)=>e.index-t.index),c=function(e,t){let n={};for(let o of e){let e=t(o);e&&(n[e]=o)}return n}(s,e=>e.id),l=getRecentWalletIds().map(e=>c[e]).filter(isNotNullish).slice(0,3),u=[...l,...s.filter(e=>!l.includes(e))],d=[];for(let t of u){if(!t)continue;let n=l.includes(t);d.push({...t,connect:()=>t.connector.showQrModal?connectToWalletConnectModal(t.id,t.connector):connectWallet(t.id,t.connector),desktopDownloadUrl:getDesktopDownloadUrl(t),extensionDownloadUrl:getExtensionDownloadUrl(t),groupName:t.groupName,mobileDownloadUrl:getMobileDownloadUrl(t),onConnecting:e=>t.connector.on("message",({type:t})=>"connecting"===t?e():void 0),ready:(null==(e=t.installed)||e)&&t.connector.ready,recent:n,showWalletConnectModal:t.walletConnectModalConnector?()=>connectToWalletConnectModal(t.id,t.walletConnectModalConnector):void 0})}return d}var dist_src=async()=>(await n.e(794).then(n.bind(n,33648))).default,preloadAssetsIcon=()=>loadImages(dist_src),AssetsIcon=()=>J.createElement(AsyncImage,{background:"#d0d5de",borderRadius:"10",height:"48",src:dist_src,width:"48"}),src2=async()=>(await n.e(3200).then(n.bind(n,3200))).default,preloadLoginIcon=()=>loadImages(src2),LoginIcon=()=>J.createElement(AsyncImage,{background:"#d0d5de",borderRadius:"10",height:"48",src:src2,width:"48"}),tw=J.forwardRef(({as:e="div",children:t,className:n,color:o,display:i,font:s="body",id:c,size:l="16",style:u,tabIndex:d,textAlign:p="inherit",weight:m="regular",testId:b},g)=>J.createElement(eQ,{as:e,className:n,color:o,display:i,fontFamily:s,fontSize:l,fontWeight:m,id:c,ref:g,style:u,tabIndex:d,textAlign:p,testId:b},t));tw.displayName="Text";var tE={large:{fontSize:"16",paddingX:"24",paddingY:"10"},medium:{fontSize:"14",height:"28",paddingX:"12",paddingY:"4"},small:{fontSize:"14",paddingX:"10",paddingY:"5"}};function ActionButton({disabled:e=!1,href:t,label:n,onClick:o,rel:i="noreferrer noopener",size:s="medium",target:c="_blank",testId:l,type:u="primary"}){let d="primary"===u,p="large"!==s,m=isMobile(),b=e?"actionButtonSecondaryBackground":d?"accentColor":p?"actionButtonSecondaryBackground":null,{fontSize:g,height:y,paddingX:v,paddingY:E}=tE[s];return J.createElement(eQ,{...t?e?{}:{as:"a",href:t,rel:i,target:c}:{as:"button",type:"button"},onClick:e?void 0:o,...m&&p?{}:{borderColor:!m||p||d?"actionButtonBorder":"actionButtonBorderMobile",borderStyle:"solid",borderWidth:"1"},borderRadius:"actionButton",className:!e&&touchableStyles({active:"shrinkSm",hover:"grow"}),display:"block",paddingX:v,paddingY:E,style:{willChange:"transform"},testId:l,textAlign:"center",transition:"transform",...b?{background:b}:{},...y?{height:y}:{}},J.createElement(tw,{color:e?"modalTextSecondary":d?"accentColorForeground":"accentColor",size:g,weight:"bold"},n))}var CloseIcon=()=>isMobile()?J.createElement("svg",{"aria-hidden":!0,fill:"none",height:"11.5",viewBox:"0 0 11.5 11.5",width:"11.5",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Close"),J.createElement("path",{d:"M2.13388 0.366117C1.64573 -0.122039 0.854272 -0.122039 0.366117 0.366117C-0.122039 0.854272 -0.122039 1.64573 0.366117 2.13388L3.98223 5.75L0.366117 9.36612C-0.122039 9.85427 -0.122039 10.6457 0.366117 11.1339C0.854272 11.622 1.64573 11.622 2.13388 11.1339L5.75 7.51777L9.36612 11.1339C9.85427 11.622 10.6457 11.622 11.1339 11.1339C11.622 10.6457 11.622 9.85427 11.1339 9.36612L7.51777 5.75L11.1339 2.13388C11.622 1.64573 11.622 0.854272 11.1339 0.366117C10.6457 -0.122039 9.85427 -0.122039 9.36612 0.366117L5.75 3.98223L2.13388 0.366117Z",fill:"currentColor"})):J.createElement("svg",{"aria-hidden":!0,fill:"none",height:"10",viewBox:"0 0 10 10",width:"10",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Close"),J.createElement("path",{d:"M1.70711 0.292893C1.31658 -0.0976311 0.683417 -0.0976311 0.292893 0.292893
1080C-0.0976311 0.683417 -0.0976311 1.31658 0.292893 1.70711L3.58579 5L0.292893 8.29289C-0.0976311 8.68342 -0.0976311 9.31658 0.292893 9.70711C0.683417 10.0976 1.31658 10.0976 1.70711 9.70711L5 6.41421L8.29289 9.70711C8.68342 10.0976 9.31658 10.0976 9.70711 9.70711C10.0976 9.31658 10.0976 8.68342 9.70711 8.29289L6.41421 5L9.70711 1.70711C10.0976 1.31658 10.0976 0.683417 9.70711 0.292893C9.31658 -0.0976311 8.68342 -0.0976311 8.29289 0.292893L5 3.58579L1.70711 0.292893Z",fill:"currentColor"})),CloseButton=({"aria-label":e="Close",onClose:t})=>{let n=isMobile();return J.createElement(eQ,{alignItems:"center","aria-label":e,as:"button",background:"closeButtonBackground",borderColor:"actionButtonBorder",borderRadius:"full",borderStyle:"solid",borderWidth:n?"0":"1",className:touchableStyles({active:"shrinkSm",hover:"growLg"}),color:"closeButton",display:"flex",height:n?"30":"28",justifyContent:"center",onClick:t,style:{willChange:"transform"},transition:"default",type:"button",width:n?"30":"28"},J.createElement(CloseIcon,null))},signInIcon=async()=>(await n.e(2898).then(n.bind(n,92898))).default;function SignIn({onClose:e,onCloseModal:t}){let{i18n:n}=(0,J.useContext)(e1),[{status:o,...i},s]=J.useState({status:"idle"}),c=function(){var e;let{adapter:t}=null!=(e=(0,J.useContext)(eK))?e:{};if(!t)throw Error("No authentication adapter found");return t}(),l=(0,J.useCallback)(async()=>{try{let e=await c.getNonce();s(t=>({...t,nonce:e}))}catch{s(e=>({...e,errorMessage:n.t("sign_in.message.preparing_error"),status:"idle"}))}},[c,n.t]),u=(0,J.useRef)(!1);J.useEffect(()=>{u.current||(u.current=!0,l())},[l]);let d=isMobile(),{address:p}=(0,et.mA)(),{chain:m}=(0,et.LN)(),{signMessageAsync:b}=(0,et.QW)(),signIn=async()=>{try{let e;let o=null==m?void 0:m.id,{nonce:l}=i;if(!p||!o||!l)return;s(e=>({...e,errorMessage:void 0,status:"signing"}));let u=c.createMessage({address:p,chainId:o,nonce:l});try{e=await b({message:c.getMessageBody({message:u})})}catch(e){if(e instanceof eC.abR)return s(e=>({...e,status:"idle"}));return s(e=>({...e,errorMessage:n.t("sign_in.signature.signing_error"),status:"idle"}))}s(e=>({...e,status:"verifying"}));try{let n=await c.verify({message:u,signature:e});if(n){t();return}throw Error()}catch{return s(e=>({...e,errorMessage:n.t("sign_in.signature.verifying_error"),status:"idle"}))}}catch{s({errorMessage:n.t("sign_in.signature.oops_error"),status:"idle"})}};return J.createElement(eQ,{position:"relative"},J.createElement(eQ,{display:"flex",paddingRight:"16",paddingTop:"16",position:"absolute",right:"0"},J.createElement(CloseButton,{onClose:e})),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:d?"32":"24",padding:"24",paddingX:"18",style:{paddingTop:d?"60px":"36px"}},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:d?"6":"4",style:{maxWidth:d?320:280}},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:d?"32":"16"},J.createElement(AsyncImage,{height:40,src:signInIcon,width:40}),J.createElement(tw,{color:"modalText",size:d?"20":"18",textAlign:"center",weight:"heavy"},n.t("sign_in.label"))),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:d?"16":"12"},J.createElement(tw,{color:"modalTextSecondary",size:d?"16":"14",textAlign:"center"},n.t("sign_in.description")),"idle"===o&&i.errorMessage?J.createElement(tw,{color:"error",size:d?"16":"14",textAlign:"center",weight:"bold"},i.errorMessage):null)),J.createElement(eQ,{alignItems:d?void 0:"center",display:"flex",flexDirection:"column",gap:"8",width:"full"},J.createElement(ActionButton,{disabled:!i.nonce||"signing"===o||"verifying"===o,label:i.nonce?"signing"===o?n.t("sign_in.signature.waiting"):"verifying"===o?n.t("sign_in.signature.verifying"):n.t("sign_in.message.send"):n.t("sign_in.message.preparing"),onClick:signIn,size:d?"large":"medium",testId:"auth-message-button"}),d?J.createElement(ActionButton,{label:"Cancel",onClick:e,size:"large",type:"secondary"}):J.createElement(eQ,{as:"button",borderRadius:"full",className:touchableStyles({active:"shrink",hover:"grow"}),display:"block",onClick:e,paddingX:"10",paddingY:"5",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},J.createElement(tw,{color:"closeButton",size:d?"16":"14",weight:"bold"},n.t("sign_in.message.cancel"))))))}var tx="WALLETCONNECT_DEEPLINK_CHOICE";function clearWalletConnectDeepLink(){localStorage.removeItem(tx)}var tC=(0,J.createContext)(void 0),tP="data-rk",createThemeRootProps=e=>({[tP]:e||""}),createThemeRootSelector=e=>{if(e&&!/^[a-zA-Z0-9_]+$/.test(e))throw Error(`Invalid ID: ${e}`);return e?`[${tP}="${e}"]`:`[${tP}]`},useThemeRootProps=()=>{let e=(0,J.useContext)(tC);return createThemeRootProps(e)},tT=(0,X.W)();function RainbowKitProvider({appInfo:e,avatar:t,chains:n,children:o,coolMode:i=!1,id:s,initialChain:c,locale:l,modalSize:u=tm.WIDE,showRecentTransactions:d=!1,theme:p=tT}){if(!function(){let e=useRainbowKitChains(),t=useWalletConnectors(),n="unauthenticated"===useAuthenticationStatus(),o=(0,J.useCallback)(()=>{loadImages(...t.map(e=>e.iconUrl),...e.map(e=>e.iconUrl).filter(isNotNullish)),isMobile()||(preloadAssetsIcon(),preloadLoginIcon()),n&&loadImages(signInIcon)},[t,e,n]);(0,J.useEffect)(()=>{o()},[o])}(),!function(){let e=(0,J.useCallback)(()=>{!function({version:e}){localStorage.setItem("rk-version",e)}({version:"1.3.6"})},[]);(0,J.useEffect)(()=>{e()},[e])}(),(0,et.mA)({onDisconnect:clearWalletConnectDeepLink}),"function"==typeof p)throw Error('A theme function was provided to the "theme" prop instead of a theme object. You must execute this function to get the resulting theme object.');let m=createThemeRootSelector(s),b={...td,...e},g=null!=t?t:defaultAvatar;return J.createElement(RainbowKitChainProvider,{chains:n,initialChain:c},J.createElement(WalletButtonProvider,null,J.createElement(I18nProvider,{locale:l},J.createElement(tp.Provider,{value:i},J.createElement(ModalSizeProvider,{modalSize:u},J.createElement(tg.Provider,{value:d},J.createElement(TransactionStoreProvider,null,J.createElement(eJ.Provider,{value:g},J.createElement(tf.Provider,{value:b},J.createElement(tC.Provider,{value:s},J.createElement(ShowBalanceProvider,null,J.createElement(ModalProvider,null,p?J.createElement("div",{...createThemeRootProps(s)},J.createElement("style",{dangerouslySetInnerHTML:{__html:[`${m}{${cssStringFromTheme("lightMode"in p?p.lightMode:p)}}`,"darkMode"in p?`@media(prefers-color-scheme:dark){${m}{${cssStringFromTheme(p.darkMode,{extends:p.lightMode})}}}`:null].join("")}}),o):o))))))))))))}var moveFocusWithin=(e,t)=>{let n=e.querySelectorAll("button:not(:disabled), a[href]");0!==n.length&&n["end"===t?n.length-1:0].focus()};function FocusTrap(e){let t=(0,J.useRef)(null);return(0,J.useEffect)(()=>{let e=document.activeElement;return()=>{var t;
1080null==(t=e.focus)||t.call(e)}},[]),(0,J.useEffect)(()=>{if(t.current){let e=t.current.querySelector("[data-auto-focus]");e?e.focus():t.current.focus()}},[]),J.createElement(J.Fragment,null,J.createElement("div",{onFocus:(0,J.useCallback)(()=>t.current&&moveFocusWithin(t.current,"end"),[]),tabIndex:0}),J.createElement("div",{ref:t,style:{outline:"none"},tabIndex:-1,...e}),J.createElement("div",{onFocus:(0,J.useCallback)(()=>t.current&&moveFocusWithin(t.current,"start"),[]),tabIndex:0}))}var stopPropagation=e=>e.stopPropagation();function Dialog({children:e,onClose:t,open:n,titleId:o}){(0,J.useEffect)(()=>{let handleEscape=e=>n&&"Escape"===e.key&&t();return document.addEventListener("keydown",handleEscape),()=>document.removeEventListener("keydown",handleEscape)},[n,t]);let[i,s]=(0,J.useState)(!0);(0,J.useEffect)(()=>{s("hidden"!==getComputedStyle(window.document.body).overflow)},[]);let c=(0,J.useCallback)(()=>t(),[t]),l=useThemeRootProps(),u=isMobile();return J.createElement(J.Fragment,null,n?(0,ei.createPortal)(J.createElement(eE,{enabled:i},J.createElement(eQ,{...l},J.createElement(eQ,{...l,alignItems:u?"flex-end":"center","aria-labelledby":o,"aria-modal":!0,className:"_9pm4ki3 ju367v9h ju367vb3 ju367va ju367v2q ju367v8q",onClick:c,position:"fixed",role:"dialog"},J.createElement(FocusTrap,{className:"_9pm4ki5 ju367va ju367v15 ju367v8r",onClick:stopPropagation,role:"document"},e)))),document.body):null)}function DialogContent({bottomSheetOnMobile:e=!1,children:t,marginTop:n,padding:o="16",paddingBottom:i,wide:s=!1}){let c=isMobile(),l=(0,J.useContext)(tb),u=l===tm.COMPACT;return J.createElement(eQ,{marginTop:n},J.createElement(eQ,{className:[s?c?"_1ckjpok2 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r":u?"_1ckjpok4 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r":"_1ckjpok3 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r":"_1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r",c?"_1ckjpok6 ju367vq":null,c&&e?"_1ckjpok7":null].join(" ")},J.createElement(eQ,{padding:o,paddingBottom:null!=i?i:o},t)))}var tA=["k","m","b","t"];function toPrecision(e,t=1){return e.toString().replace(RegExp(`(.+\\.\\d{${t}})\\d+`),"$1").replace(/(\.[1-9]*)0+$/,"$1").replace(/\.$/,"")}function abbreviateETHBalance(e){if(e<1)return toPrecision(e,3);if(e<100)return toPrecision(e,2);if(e<1e4)return new Intl.NumberFormat().format(parseFloat(toPrecision(e,1)));let t=String(e);for(let n=tA.length-1;n>=0;n--){let o=10**((n+1)*3);if(o<=e){t=toPrecision(e=10*e/o/10,1)+tA[n];break}}return t}function formatAddress(e){return e.length<8?e:`${e.substring(0,4)}\u2026${e.substring(e.length-4)}`}function formatENS(e){let t=e.split("."),n=t.pop();return t.join(".").length>24?`${t.join(".").substring(0,24)}...`:`${t.join(".")}.${n}`}var CopiedIcon=()=>J.createElement("svg",{fill:"none",height:"13",viewBox:"0 0 13 13",width:"13",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Copied"),J.createElement("path",{d:"M4.94568 12.2646C5.41052 12.2646 5.77283 12.0869 6.01892 11.7109L12.39 1.96973C12.5677 1.69629 12.6429 1.44336 12.6429 1.2041C12.6429 0.561523 12.1644 0.0966797 11.5082 0.0966797C11.057 0.0966797 10.7767 0.260742 10.5033 0.691406L4.9115 9.50977L2.07458 5.98926C1.82166 5.68848 1.54822 5.55176 1.16541 5.55176C0.502319 5.55176 0.0238037 6.02344 0.0238037 6.66602C0.0238037 6.95312 0.112671 7.20605 0.358765 7.48633L3.88611 11.7588C4.18005 12.1074 4.50818 12.2646 4.94568 12.2646Z",fill:"currentColor"})),CopyIcon=()=>J.createElement("svg",{fill:"none",height:"16",viewBox:"0 0 17 16",width:"17",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Copy"),J.createElement("path",{d:"M3.04236 12.3027H4.18396V13.3008C4.18396 14.8525 5.03845 15.7002 6.59705 15.7002H13.6244C15.183 15.7002 16.0375 14.8525 16.0375 13.3008V6.24609C16.0375 4.69434 15.183 3.84668 13.6244 3.84668H12.4828V2.8418C12.4828 1.29688 11.6283 0.442383 10.0697 0.442383H3.04236C1.48376 0.442383 0.629272 1.29004 0.629272 2.8418V9.90332C0.629272 11.4551 1.48376 12.3027 3.04236 12.3027ZM3.23376 10.5391C2.68689 10.5391 2.39294 10.2656 2.39294 9.68457V3.06055C2.39294 2.47949 2.68689 2.21289 3.23376 2.21289H9.8783C10.4252 2.21289 10.7191 2.47949 10.7191 3.06055V3.84668H6.59705C5.03845 3.84668 4.18396 4.69434 4.18396 6.24609V10.5391H3.23376ZM6.78845 13.9365C6.24158 13.9365 5.94763 13.6699 5.94763 13.0889V6.45801C5.94763 5.87695 6.24158 5.61035 6.78845 5.61035H13.433C13.9799 5.61035 14.2738 5.87695 14.2738 6.45801V13.0889C14.2738 13.6699 13.9799 13.9365 13.433 13.9365H6.78845Z",fill:"currentColor"})),DisconnectIcon=()=>J.createElement("svg",{fill:"none",height:"16",viewBox:"0 0 18 16",width:"18",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Disconnect"),J.createElement("path",{d:"M2.67834 15.5908H9.99963C11.5514 15.5908 12.399 14.7432 12.399 13.1777V10.2656H10.6354V12.9863C10.
10806354 13.5332 10.3688 13.8271 9.78772 13.8271H2.89026C2.3092 13.8271 2.0426 13.5332 2.0426 12.9863V3.15625C2.0426 2.60254 2.3092 2.30859 2.89026 2.30859H9.78772C10.3688 2.30859 10.6354 2.60254 10.6354 3.15625V5.89746H12.399V2.95801C12.399 1.39941 11.5514 0.544922 9.99963 0.544922H2.67834C1.12659 0.544922 0.278931 1.39941 0.278931 2.95801V13.1777C0.278931 14.7432 1.12659 15.5908 2.67834 15.5908ZM7.43616 8.85059H14.0875L15.0924 8.78906L14.566 9.14453L13.6842 9.96484C13.5406 10.1016 13.4586 10.2861 13.4586 10.4844C13.4586 10.8398 13.7321 11.168 14.1217 11.168C14.3199 11.168 14.4635 11.0928 14.6002 10.9561L16.7809 8.68652C16.986 8.48145 17.0543 8.27637 17.0543 8.06445C17.0543 7.85254 16.986 7.64746 16.7809 7.43555L14.6002 5.17285C14.4635 5.03613 14.3199 4.9541 14.1217 4.9541C13.7321 4.9541 13.4586 5.27539 13.4586 5.6377C13.4586 5.83594 13.5406 6.02734 13.6842 6.15723L14.566 6.98438L15.0924 7.33984L14.0875 7.27148H7.43616C7.01917 7.27148 6.65686 7.62012 6.65686 8.06445C6.65686 8.50195 7.01917 8.85059 7.43616 8.85059Z",fill:"currentColor"})),chainToExplorerUrl=e=>{var t,n;return null==(n=null==(t=null==e?void 0:e.blockExplorers)?void 0:t.default)?void 0:n.url},ExternalLinkIcon=()=>J.createElement("svg",{fill:"none",height:"19",viewBox:"0 0 20 19",width:"20",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Link"),J.createElement("path",{d:"M10 18.9443C15.0977 18.9443 19.2812 14.752 19.2812 9.6543C19.2812 4.56543 15.0889 0.373047 10 0.373047C4.90234 0.373047 0.71875 4.56543 0.71875 9.6543C0.71875 14.752 4.91113 18.9443 10 18.9443ZM10 16.6328C6.1416 16.6328 3.03906 13.5215 3.03906 9.6543C3.03906 5.7959 6.13281 2.68457 10 2.68457C13.8584 2.68457 16.9697 5.7959 16.9697 9.6543C16.9785 13.5215 13.8672 16.6328 10 16.6328ZM12.7158 12.1416C13.2432 12.1416 13.5684 11.7549 13.5684 11.1836V7.19336C13.5684 6.44629 13.1377 6.05957 12.417 6.05957H8.40918C7.8291 6.05957 7.45117 6.38477 7.45117 6.91211C7.45117 7.43945 7.8291 7.77344 8.40918 7.77344H9.69238L10.7207 7.63281L9.53418 8.67871L6.73047 11.4912C6.53711 11.6758 6.41406 11.9395 6.41406 12.2031C6.41406 12.7832 6.85352 13.1699 7.39844 13.1699C7.68848 13.1699 7.92578 13.0732 8.1543 12.8623L10.9316 10.0762L11.9775 8.89844L11.8545 9.98828V11.1836C11.8545 11.7725 12.1885 12.1416 12.7158 12.1416Z",fill:"currentColor"})),CancelIcon=()=>J.createElement("svg",{fill:"none",height:"19",viewBox:"0 0 20 19",width:"20",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Cancel"),J.createElement("path",{d:"M10 18.9443C15.0977 18.9443 19.2812 14.752 19.2812 9.6543C19.2812 4.56543 15.0889 0.373047 10 0.373047C4.90234 0.373047 0.71875 4.56543 0.71875 9.6543C0.71875 14.752 4.91113 18.9443 10 18.9443ZM10 16.6328C6.1416 16.6328 3.03906 13.5215 3.03906 9.6543C3.03906 5.7959 6.13281 2.68457 10 2.68457C13.8584 2.68457 16.9697 5.7959 16.9697 9.6543C16.9785 13.5215 13.8672 16.6328 10 16.6328ZM7.29297 13.3018C7.58301 13.3018 7.81152 13.2139 7.99609 13.0205L10 11.0166L12.0127 13.0205C12.1973 13.2051 12.4258 13.3018 12.707 13.3018C13.2432 13.3018 13.6562 12.8887 13.6562 12.3525C13.6562 12.0977 13.5508 11.8691 13.3662 11.6934L11.3535 9.67188L13.375 7.6416C13.5596 7.44824 13.6562 7.22852 13.6562 6.98242C13.6562 6.44629 13.2432 6.0332 12.7158 6.0332C12.4346 6.0332 12.2148 6.12109 12.0215 6.31445L10 8.32715L7.9873 6.32324C7.80273 6.12988 7.58301 6.04199 7.29297 6.04199C6.76562 6.04199 6.35254 6.45508 6.35254 6.99121C6.35254 7.2373 6.44922 7.46582 6.63379 7.6416L8.65527 9.67188L6.63379 11.6934C6.44922 11.8691 6.35254 12.1064 6.35254 12.3525C6.35254 12.8887 6.76562 13.3018 7.29297 13.3018Z",fill:"currentColor"})),SuccessIcon=()=>J.createElement("svg",{fill:"none",height:"20",viewBox:"0 0 20 20",width:"20",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Success"),J.createElement("path",{d:"M10 19.4443C15.0977 19.4443 19.2812 15.252 19.2812 10.1543C19.2812 5.06543 15.0889 0.873047 10 0.873047C4.90234 0.873047 0.71875 5.06543 0.71875 10.1543C0.71875 15.252 4.91113 19.4443 10 19.4443ZM10 17.1328C6.1416 17.1328 3.03906 14.0215 3.03906 10.1543C3.03906 6.2959 6.13281 3.18457 10 3.18457C13.8584 3.18457 16.9697 6.2959 16.9697 10.1543C16.9785 14.0215 13.8672 17.1328 10 17.1328ZM9.07715 14.3379C9.4375 14.3379 9.7627 14.1533 9.97363 13.8369L13.7441 8.00977C13.8848 7.79883 13.9814 7.5791 13.9814 7.36816C13.9814 6.84961 13.5244 6.48926 13.0322 6.48926C12.707 6.48926 12.4258 6.66504 12.2148 7.0166L9.05957 12.0967L7.5918 10.2949C7.37207 10.0225 7.13477 9.9082 6.84473 9.9082C6.33496 9.9082 5.92188 10.3125 5.92188 10.8223C5.92188 11.0684 6.00098 11.2793 6.18555 11.5078L8.1543 13.8545C8.40918 14.1709 8.70801 14.3379 9.07715 14.3379Z",fill:"currentColor"})),getTxStatusIcon=e=>
1080{switch(e){case"pending":default:return SpinnerIcon;case"confirmed":return SuccessIcon;case"failed":return CancelIcon}};function TxItem({tx:e}){let t=isMobile(),n=getTxStatusIcon(e.status),o="failed"===e.status?"error":"accentColor",{chain:i}=(0,et.LN)(),s="confirmed"===e.status?"Confirmed":"failed"===e.status?"Failed":"Pending",c=chainToExplorerUrl(i);return J.createElement(J.Fragment,null,J.createElement(eQ,{...c?{as:"a",background:{hover:"profileForeground"},borderRadius:"menuButton",className:touchableStyles({active:"shrink"}),href:`${c}/tx/${e.hash}`,rel:"noreferrer noopener",target:"_blank",transition:"default"}:{},color:"modalText",display:"flex",flexDirection:"row",justifyContent:"space-between",padding:"8",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:t?"16":"14"},J.createElement(eQ,{color:o},J.createElement(n,null)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:t?"3":"1"},J.createElement(eQ,null,J.createElement(tw,{color:"modalText",font:"body",size:t?"16":"14",weight:"bold"},null==e?void 0:e.description)),J.createElement(eQ,null,J.createElement(tw,{color:"pending"===e.status?"modalTextSecondary":o,font:"body",
1080size:"14",weight:t?"medium":"regular"},s)))),c&&J.createElement(eQ,{alignItems:"center",color:"modalTextDim",display:"flex"},J.createElement(ExternalLinkIcon,null))))}function TxList({address:e}){let t=useRecentTransactions(),n=function(){let e=useTransactionStore(),{address:t}=(0,et.mA)(),n=useChainId();return(0,J.useCallback)(()=>{if(!t||!n)throw Error("No address or chain ID found");e.clearTransactions(t,n)},[e,t,n])}(),{chain:o}=(0,et.LN)(),i=chainToExplorerUrl(o),s=t.slice(0,3),c=s.length>0,l=isMobile(),{appName:u}=(0,J.useContext)(tf),{i18n:d}=(0,J.useContext)(e1);return J.createElement(J.Fragment,null,J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"10",paddingBottom:"2",paddingTop:"16",paddingX:l?"8":"18"},c&&J.createElement(eQ,{paddingBottom:l?"4":"0",paddingTop:"8",paddingX:l?"12":"6"},J.createElement(eQ,{display:"flex",justifyContent:"space-between"},J.createElement(tw,{color:"modalTextSecondary",size:l?"16":"14",weight:"semibold"},d.t("profile.transactions.recent.title")),J.createElement(eQ,{style:{marginBottom:-6,marginLeft:-10,marginRight:-10,marginTop:-6}},J.createElement(eQ,{as:"button",background:{hover:"profileForeground"},borderRadius:"actionButton",className:touchableStyles({active:"shrink"}),onClick:n,paddingX:l?"8":"12",paddingY:l?"4":"5",transition:"default",type:"button"},J.createElement(tw,{color:"modalTextSecondary",size:l?"16":"14",weight:"semibold"},d.t("profile.transactions.clear.label")))))),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},c?s.map(e=>J.createElement(TxItem,{key:e.hash,tx:e})):J.createElement(J.Fragment,null,J.createElement(eQ,{padding:l?"12":"8"},J.createElement(tw,{color:"modalTextDim",size:l?"16":"14",weight:l?"medium":"bold"},u?d.t("profile.transactions.description",{appName:u}):d.t("profile.transactions.description_fallback"))),l&&J.createElement(eQ,{background:"generalBorderDim",height:"1",marginX:"12",marginY:"8"})))),i&&J.createElement(eQ,{paddingBottom:"18",paddingX:l?"8":"18"},J.createElement(eQ,{alignItems:"center",as:"a",background:{hover:"profileForeground"},borderRadius:"menuButton",className:touchableStyles({active:"shrink"}),color:"modalTextDim",display:"flex",flexDirection:"row",href:`${i}/address/${e}`,justifyContent:"space-between",paddingX:"8",paddingY:"12",rel:"noreferrer noopener",style:{willChange:"transform"},target:"_blank",transition:"default",width:"full",...l?{paddingLeft:"12"}:{}}
1080,J.createElement(tw,{color:"modalText",font:"body",size:l?"16":"14",weight:l?"semibold":"bold"},d.t("profile.explorer.label")),J.createElement(ExternalLinkIcon,null))))}function ProfileDetailsAction({action:e,icon:t,label:n,testId:o,url:i}){let s=isMobile();return J.createElement(eQ,{...i?{as:"a",href:i,rel:"noreferrer noopener",target:"_blank"}:{as:"button",type:"button"},background:{base:"profileAction",...s?{}:{hover:"profileActionHover"}},borderRadius:"menuButton",boxShadow:"profileDetailsAction",className:touchableStyles({active:"shrinkSm",hover:s?void 0:"grow"}),display:"flex",onClick:e,padding:s?"6":"8",style:{willChange:"transform"},testId:o,transition:"default",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"1",justifyContent:"center",paddingTop:"2",width:"full"},J.createElement(eQ,{color:"modalText",height:"max"},t),J.createElement(eQ,null,J.createElement(tw,{color:"modalText",size:s?"12":"13",weight:"semibold"},n))))}function ProfileDetails({address:e,ensAvatar:t,ensName:n,onClose:o,onDisconnect:i}){let s=(0,J.useContext)(tg),{data:c}=(0,et.KQ)({address:e}),[l,u]=(0,J.useState)(!1),d=(0,J.useCallback)(()=>{e&&(navigator.clipboard.writeText(e),u(!0))},[e]);if((0,J.useEffect)(()=>{if(l){let e=setTimeout(()=>{u(!1)},1500);return()=>clearTimeout(e)}},[l]),!e)return null;let p=n?formatENS(n):formatAddress(e),m=null==c?void 0:c.formatted,b=m?abbreviateETHBalance(parseFloat(m)):void 0,g="rk_profile_title",y=isMobile(),{i18n:v}=(0,J.useContext)(e1);return J.createElement(J.Fragment,null,J.createElement(eQ,{display:"flex",flexDirection:"column"},J.createElement(eQ,{background:"profileForeground",padding:"16"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:y?"16":"12",justifyContent:"center",margin:"8",style:{textAlign:"center"}},J.createElement(eQ,{style:{position:"absolute",right:16,top:16,willChange:"transform"}},J.createElement(CloseButton,{onClose:o}))," ",J.createElement(eQ,{marginTop:y?"24":"0"},J.createElement(Avatar,{address:e,imageUrl:t,size:y?82:74})),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:y?"4":"0",textAlign:"center"},J.createElement(eQ,{textAlign:"center"},J.createElement(tw,{as:"h1",color:"modalText",id:g,size:y?"20":"18",weight:"heavy"},p)),c&&J.createElement(eQ,{textAlign:"center"},J.createElement(tw,{as:"h1",color:"modalTextSecondary",id:g,size:y?"16":"14",weight:"semibold"},b," ",c.symbol)))),J.createElement(eQ,{display:"flex",flexDirection:"row",gap:"8",margin:"2",marginTop:"16"},J.createElement(ProfileDetailsAction,{action:d,icon:l?J.createElement(CopiedIcon,null):J.createElement(CopyIcon,null),label:l?v.t("profile.copy_address.copied"):v.t("profile.copy_address.label")}),J.createElement(ProfileDetailsAction,{action:i,icon:J.createElement(DisconnectIcon,null),label:v.t("profile.disconnect.label"),testId:"disconnect-button"}))),s&&J.createElement(J.Fragment,null,J.createElement(eQ,{background:"generalBorder",height:"1",marginTop:"-1"}),J.createElement(eQ,null,J.createElement(TxList,{address:e})))))}function AccountModal({onClose:e,open:t}){let{address:n}=(0,et.mA)(),o=useMainnetEnsName(n),i=useMainnetEnsAvatar(o),{disconnect:s}=(0,et.qL)();return n?J.createElement(J.Fragment,null,n&&J.createElement(Dialog,{onClose:e,open:t,titleId:"rk_account_modal_title"},J.createElement(DialogContent,{bottomSheetOnMobile:!0,padding:"0"},J.createElement(ProfileDetails,{address:n,ensAvatar:i,ensName:o,onClose:e,onDisconnect:s})))):null}var DisconnectSqIcon=({size:e})=>J.createElement("svg",{fill:"none",height:e,viewBox:"0 0 28 28",width:e,xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Disconnect"),J.createElement("path",{d:"M6.742 22.195h8.367c1.774 0 2.743-.968 2.743-2.758V16.11h-2.016v3.11c0 .625-.305.96-.969.96H6.984c-.664 0-.968-.335-.968-.96V7.984c0-.632.304-.968.968-.968h7.883c.664 0 .969.336.969.968v3.133h2.016v-3.36c0-1.78-.97-2.757-2.743-2.757H6.742C4.97 5 4 5.977 4 7.758v11.68c0 1.789.969 2.757 2.742 2.757Zm5.438-7.703h7.601l1.149-.07-.602.406-1.008.938a.816.816 0 0 0-.258.593c0 .407.313.782.758.782.227 0 .39-.086.547-.243l2.492-2.593c.235-.235.313-.47.313-.711 0-.242-.078-.477-.313-.719l-2.492
1080-2.586c-.156-.156-.32-.25-.547-.25-.445 0-.758.367-.758.781 0 .227.094.446.258.594l1.008.945.602.407-1.149-.079H12.18a.904.904 0 0 0 0 1.805Z",fill:"currentColor"})),tS=J.forwardRef(({children:e,currentlySelected:t=!1,onClick:n,testId:o,...i},s)=>{let c=isMobile();return J.createElement(eQ,{as:"button",borderRadius:"menuButton",disabled:t,display:"flex",onClick:n,ref:s,testId:o,type:"button"},J.createElement(eQ,{borderRadius:"menuButton",className:[c?"v9horb0":void 0,!t&&touchableStyles({active:"shrink"})],padding:c?"8":"6",transition:"default",width:"full",...t?{background:"accentColor",borderColor:"selectedOptionBorder",borderStyle:"solid",borderWidth:"1",boxShadow:"selectedOption",color:"accentColorForeground"}:{background:{hover:"menuItemBackground"},color:"modalText",transition:"default"},...i},e))});function ChainModal({onClose:e,open:t}){var n;let{chain:o}=(0,et.LN)(),{chains:i,pendingChainId:s,reset:c,switchNetwork:l}=(0,et.g0)({onSettled:()=>{c(),e()}}),{i18n:u}=(0,J.useContext)(e1),{disconnect:d}=(0,et.qL)(),p="rk_chain_modal_title",m=isMobile(),b=null!=(n=null==o?void 0:o.unsupported)&&n,g=m?"36":"28",{appName:y}=(0,J.useContext)(tf),v=useRainbowKitChains();return o&&(null==o?void 0:o.id)?J.createElement(Dialog,{onClose:e,open:t,titleId:p},J.createElement(DialogContent,{bottomSheetOnMobile:!0,paddingBottom:"0"},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"14"},J.createElement(eQ,{display:"flex",flexDirection:"row",justifyContent:"space-between"},m&&J.createElement(eQ,{width:"30"}),J.createElement(eQ,{paddingBottom:"0",paddingLeft:"8",paddingTop:"4"},J.createElement(tw,{as:"h1",color:"modalText",id:p,size:m?"20":"18",weight:"heavy"},u.t("chains.title"))),J.createElement(CloseButton,{onClose:e})),b&&J.createElement(eQ,{marginX:"8",textAlign:m?"center":"left"},J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},u.t("chains.wrong_network"))),J.createElement(eQ,{className:m?"_18dqw9x1":"_18dqw9x0",display:"flex",flexDirection:"column",gap:"4",padding:"2",paddingBottom:"16"},l?v.map(({iconBackground:e,iconUrl:t,id:n,name:c},d)=>{let p=i.find(e=>e.id===n);if(!p)return null;let b=p.id===(null==o?void 0:o.id),y=!b&&p.id===s;return J.createElement(J.Fragment,{key:p.id},J.createElement(tS,{currentlySelected:b,onClick:b?void 0:()=>l(p.id),testId:`chain-option-${p.id}`},J.createElement(eQ,{fontFamily:"body",fontSize:"16",fontWeight:"bold"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",justifyContent:"space-between"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",height:g},t&&J.createElement(eQ,{height:"full",marginRight:"8"},J.createElement(AsyncImage,{alt:null!=c?c:p.name,background:e,borderRadius:"full",height:g,src:t,width:g,testId:`chain-option-${p.id}-icon`})),J.createElement("div",null,null!=c?c:p.name)),b&&J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",marginRight:"6"},J.createElement(tw,{color:"accentColorForeground",size:"14",weight:"medium"},u.t("chains.connected")),J.createElement(eQ,{background:"connectionIndicator",borderColor:"selectedOptionBorder",borderRadius:"full",borderStyle:"solid",borderWidth:"1",height:"8",marginLeft:"8",width:"8"})),y&&J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",marginRight:"6"},J.createElement(tw,{color:"modalText",size:"14",weight:"medium"},u.t("chains.confirm")),J.createElement(eQ,{background:"standby",borderRadius:"full",height:"8",marginLeft:"8",width:"8"}))))),m&&d<v.length-1&&J.createElement(eQ,{background:"generalBorderDim",height:"1",marginX:"8"}))}):J.createElement(eQ,{background:"generalBorder",borderRadius:"menuButton",paddingX:"18",paddingY:"12"},J.createElement(tw,{color:"modalText",size:"14",weight:"medium"},y?u.t("chains.switching_not_supported",{appName:y}):u.t("chains.switching_not_supported_fallback"))),b&&J.createElement(J.Fragment,null,J.createElement(eQ,{background:"generalBorderDim",height:"1",marginX:"8"}),J.createElement(tS,{onClick:()=>d(),testId:"chain-option-disconnect"},J.createElement(eQ,{color:"error",fontFamily:"body",fontSize:"16",fontWeight:"bold"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",justifyContent:"space-between"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",height:g},J.createElement(eQ,{alignItems:"center",color:"error",height:g,justifyContent:"center",marginRight:"8"},J.createElement(DisconnectSqIcon,{size:Number(g)})),J.createElement("div",null,u.t("chains.disconnect"))))))))))):null}tS.displayName="MenuButton";var t_="rk-latest-id",DisclaimerLink=({children:e,href:t})=>J.createElement(eQ,{as:"a",color:"accentColor",href:t,rel:"noreferrer",target:"_blank"},e),DisclaimerText=({children:e})=>J.createElement(tw,{color:"modalTextSecondary",size:"12",weight:"medium"},e);
1080function ConnectModalIntro({compactModeEnabled:e=!1,getWallet:t}){let{disclaimer:n,learnMoreUrl:o}=(0,J.useContext)(tf),{i18n:i}=(0,J.useContext)(e1);return J.createElement(J.Fragment,null,J.createElement(eQ,{alignItems:"center",color:"accentColor",display:"flex",flexDirection:"column",height:"full",justifyContent:"space-around"},J.createElement(eQ,{marginBottom:"10"},!e&&J.createElement(tw,{color:"modalText",size:"18",weight:"heavy"},i.t("intro.title"))),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"32",justifyContent:"center",marginY:"20",style:{maxWidth:312}},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},J.createElement(eQ,{borderRadius:"6",height:"48",minWidth:"48",width:"48"},J.createElement(AssetsIcon,null)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},i.t("intro.digital_asset.title")),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},i.t("intro.digital_asset.description")))),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},J.createElement(eQ,{borderRadius:"6",height:"48",minWidth:"48",width:"48"},J.createElement(LoginIcon,null)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},i.t("intro.login.title")),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},i.t("intro.login.description"))))),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",margin:"10"},J.createElement(ActionButton,{label:i.t("intro.get.label"),onClick:t}),J.createElement(eQ,{as:"a",className:touchableStyles({active:"shrink",hover:"grow"}),display:"block",href:o,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},J.createElement(tw,{color:"accentColor",size:"14",weight:"bold"},i.t("intro.learn_more.label")))),n&&!e&&J.createElement(eQ,{marginBottom:"8",marginTop:"12",textAlign:"center"},J.createElement(n,{Link:DisclaimerLink,Text:DisclaimerText}))))}var BackIcon=()=>J.createElement("svg",{fill:"none",height:"17",viewBox:"0 0 11 17",width:"11",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Back"),J.createElement("path",{d:"M0.99707 8.6543C0.99707 9.08496 1.15527 9.44531 1.51562 9.79688L8.16016 16.3096C8.43262 16.5732 8.74902 16.7051 9.13574 16.7051C9.90918 16.7051 10.5508 16.0811 10.5508 15.3076C10.5508 14.9121 10.3838 14.5605 10.0938 14.2705L4.30176 8.64551L10.0938 3.0293C10.3838 2.74805 10.5508 2.3877 10.5508 2.00098C10.5508 1.23633 9.90918 0.603516 9.13574 0.603516C8.74902 0.603516 8.43262 0.735352 8.16016 0.999023L1.51562 7.51172C1.15527 7.85449 1.00586 8.21484 0.99707 8.6543Z",fill:"currentColor"})),InfoIcon=()=>J.createElement("svg",{fill:"none",height:"12",viewBox:"0 0 8 12",width:"8",xmlns:"http://www.w3.org/2000/svg"},J.createElement("title",null,"Info"),J.createElement("path",{d:"M3.64258 7.99609C4.19336 7.99609 4.5625 7.73828 4.68555 7.24609C4.69141 7.21094 4.70312 7.16406 4.70898 7.13477C4.80859 6.60742 5.05469 6.35547 6.04492 5.76367C7.14648 5.10156 7.67969 4.3457 7.67969 3.24414C7.67969 1.39844 6.17383 0.255859 3.95898 0.255859C2.32422 0.255859 1.05859 0.894531 0.548828 1.86719C0.396484 2.14844 0.320312 2.44727 0.320312 2.74023C0.314453 3.37305 0.742188 3.79492 1.42188 3.79492C1.91406 3.79492 2.33594 3.54883 2.53516 3.11523
1080C2.78711 2.47656 3.23242 2.21289 3.83594 2.21289C4.55664 2.21289 5.10742 2.65234 5.10742 3.29102C5.10742 3.9707 4.7793 4.29883 3.81836 4.87891C3.02148 5.36523 2.50586 5.92773 2.50586 6.76562V6.90039C2.50586 7.55664 2.96289 7.99609 3.64258 7.99609ZM3.67188 11.4473C4.42773 11.4473 5.04297 10.8672 5.04297 10.1406C5.04297 9.41406 4.42773 8.83984 3.67188 8.83984C2.91602 8.83984 2.30664 9.41406 2.30664 10.1406C2.30664 10.8672 2.91602 11.4473 3.67188 11.4473Z",fill:"currentColor"})),InfoButton=({"aria-label":e="Info",onClick:t})=>{let n=isMobile();return J.createElement(eQ,{alignItems:"center","aria-label":e,as:"button",background:"closeButtonBackground",borderColor:"actionButtonBorder",borderRadius:"full",borderStyle:"solid",borderWidth:n?"0":"1",className:touchableStyles({active:"shrinkSm",hover:"growLg"}),color:"closeButton",display:"flex",height:n?"30":"28",justifyContent:"center",onClick:t,style:{willChange:"transform"},transition:"default",type:"button",width:n?"30":"28"},J.createElement(InfoIcon,null))},useCoolMode=e=>{let t=(0,J.useRef)(null),n=(0,J.useContext)(tp),o=useAsyncImage(e);return(0,J.useEffect)(()=>{if(n&&t.current&&o)return function(e,t){let n;tI++;let o=[15,20,25,35,45],i=[],s=!1,c=0,l=0,u=getContainer();!function loop(){s&&i.length<35&&function(){let e=o[Math.floor(Math.random()*o.length)],n=360*Math.random(),s=l-e/2,d=c-e/2,p=document.createElement("div");p.innerHTML=`<img src="${t}" width="${e}" height="${e}" style="border-radius: 25%">`,p.setAttribute("style",`position:absolute;will-change:transform;top:${s}px;left:${d}px;transform:rotate(${n}deg)`),u.appendChild(p),i.push({direction:.5>=Math.random()?-1:1,element:p,left:d,size:e,speedHorz:10*Math.random(),speedUp:25*Math.random(),spinSpeed:35*Math.random()*(.5>=Math.random()?-1:1),spinVal:n,top:s})}(),function(){for(let e of i)e.left=e.left-e.speedHorz*e.direction,e.top=e.top-e.speedUp,e.speedUp=Math.min(e.size,e.speedUp-1),e.spinVal=e.spinVal+e.spinSpeed,e.top>=Math.max(window.innerHeight,document.body.clientHeight)+e.size&&(i=i.filter(t=>t!==e),e.element.remove()),e.element.setAttribute("style",`position:absolute;will-change:transform;top:${e.top}px;left:${e.left}px;transform:rotate(${e.spinVal}deg)`)}(),n=requestAnimationFrame(loop)}();let d="ontouchstart"in window||navigator.msMaxTouchPoints,p=d?"touchstart":"mousedown",m=d?"touchend":"mouseup",b=d?"touchmove":"mousemove",updateMousePosition=e=>{var t,n;"touches"in e?(c=null==(t=e.touches)?void 0:t[0].clientX,l=null==(n=e.touches)?void 0:n[0].clientY):(c=e.clientX,l=e.clientY)},tapHandler=e=>{updateMousePosition(e),s=!0},disableAutoAddParticle=()=>{s=!1};return e.addEventListener(b,updateMousePosition,{passive:!1}),e.addEventListener(p,tapHandler),e.addEventListener(m,disableAutoAddParticle),e.addEventListener("mouseleave",disableAutoAddParticle),()=>{e.removeEventListener(b,updateMousePosition),e.removeEventListener(p,tapHandler),e.removeEventListener(m,disableAutoAddParticle),e.removeEventListener("mouseleave",disableAutoAddParticle);let t=setInterval(()=>{n&&0===i.length&&(cancelAnimationFrame(n),clearInterval(t),0==--tI&&u.remove())},500)}}(t.current,o)},[n,o]),t},getContainer=()=>{let e="_rk_coolMode",t=document.getElementById(e);if(t)return t;let n=document.createElement("div");return n.setAttribute("id",e),n.setAttribute("style","overflow:hidden;position:fixed;height:100%;top:0;left:0;right:0;bottom:0;pointer-events:none;z-index:2147483647"),document.body.appendChild(n),n},tI=0,ModalSelection=({as:e="button",currentlySelected:t=!1,iconBackground:n,iconUrl:o,name:i,onClick:s,ready:c,recent:l,testId:u,...d})=>{let p=useCoolMode(o),[m,b]=(0,J.useState)(!1),{i18n:g}=(0,J.useContext)(e1);return J.createElement(eQ,{display:"flex",flexDirection:"column",onMouseEnter:()=>b(!0),onMouseLeave:()=>b(!1),ref:p},J.createElement(eQ,{as:e,borderRadius:"menuButton",borderStyle:"solid",borderWidth:"1",className:t?void 0:["g5kl0l0",touchableStyles({active:"shrink"})],disabled:t,onClick:s,padding:"5",style:{willChange:"transform"},testId:u,transition:"default",width:"full",...t?{background:"accentColor",borderColor:"selectedOptionBorder",boxShadow:"selectedWallet"}
1080:{background:{hover:"menuItemBackground"}},...d},J.createElement(eQ,{color:t?"accentColorForeground":"modalText",disabled:!c,fontFamily:"body",fontSize:"16",fontWeight:"bold",transition:"default"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"12"},J.createElement(AsyncImage,{background:n,...m?{}:{borderColor:"actionButtonBorder"},borderRadius:"6",height:"28",src:o,width:"28"}),J.createElement(eQ,null,J.createElement(eQ,{style:{marginTop:l?-2:void 0}},i),l&&J.createElement(tw,{color:t?"accentColorForeground":"accentColor",size:"12",style:{lineHeight:1,marginTop:-1},weight:"medium"},g.t("connect.recent")))))))};ModalSelection.displayName="ModalSelection";var convertHexToRGBA=(e,t=1)=>{let n=e.replace("#","");3===n.length&&(n=`${n[0]}${n[0]}${n[1]}${n[1]}${n[2]}${n[2]}`);let o=parseInt(n.substring(0,2),16),i=parseInt(n.substring(2,4),16),s=parseInt(n.substring(4,6),16);return t>1&&t<=100&&(t/=100),`rgba(${o},${i},${s},${t})`},getGradientRGBAs=e=>e?[convertHexToRGBA(e,.2),convertHexToRGBA(e,.14),convertHexToRGBA(e,.1)]:null,isHexString=e=>/^#([0-9a-f]{3}){1,2}$/i.test(e),src3=async()=>(await n.e(9600).then(n.bind(n,99600))).default,preloadConnectIcon=()=>loadImages(src3),ConnectIcon=()=>J.createElement(AsyncImage,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:src3,width:"48"}),src4=async()=>(await n.e(8137).then(n.bind(n,68137))).default,preloadCreateIcon=()=>loadImages(src4),CreateIcon=()=>J.createElement(AsyncImage,{background:"#e3a5e8",borderColor:"generalBorder",borderRadius:"10",height:"48",src:src4,width:"48"}),src5=async()=>(await n.e(1748).then(n.bind(n,31748))).default,preloadRefreshIcon=()=>loadImages(src5),RefreshIcon=()=>J.createElement(AsyncImage,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:src5,width:"48"}),src6=async()=>(await n.e(5806).then(n.bind(n,75806))).default,preloadScanIcon=()=>loadImages(src6),ScanIcon=()=>J.createElement(AsyncImage,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:src6,width:"48"}),generateMatrix=(e,t)=>{let n=Array.prototype.slice.call(eP.create(e,{errorCorrectionLevel:t}).modules.data,0),o=Math.sqrt(n.length);return n.reduce((e,t,n)=>(n%o==0?e.push([t]):e[e.length-1].push(t))&&e,[])};function QRCode({ecl:e="M",logoBackground:t,logoMargin:n=10,logoSize:o=50,logoUrl:i,size:s=200,uri:c}){let l=s-2*parseInt("20",10),u=(0,J.useMemo)(()=>{let t=[],n=generateMatrix(c,e),i=l/n.length;[{x:0,y:0},{x:1,y:0},{x:0,y:1}].forEach(({x:e,y:o})=>{let s=(n.length-7)*i*e,c=(n.length-7)*i*o;for(let n=0;n<3;n++)t.push(J.createElement("rect",{fill:n%2!=0?"white":"black",height:i*(7-2*n),key:`${n}-${e}-${o}`,rx:-((n-2)*5)+(0===n?2:0),ry:-((n-2)*5)+(0===n?2:0),width:i*(7-2*n),x:s+i*n,y:c+i*n}))});let s=Math.floor((o+25)/i),u=n.length/2-s/2,d=n.length/2+s/2-1;return n.forEach((e,o)=>{e.forEach((e,s)=>{!n[o][s]||o<7&&s<7||o>n.length-8&&s<7||o<7&&s>n.length-8||o>u&&o<d&&s>u&&s<d||t.push(J.createElement("circle",{cx:o*i+i/2,cy:s*i+i/2,fill:"black",key:`circle-${o}-${s}`,r:i/3}))})}),t},[e,o,l,c]),d=l/2-o/2,p=o+2*n;return J.createElement(eQ,{borderColor:"generalBorder",borderRadius:"menuButton",borderStyle:"solid",borderWidth:"1",className:"_1vwt0cg0",padding:"20",width:"max"},J.createElement(eQ,{style:{height:l,userSelect:"none",width:l},userSelect:"none"},J.createElement(eQ,{display:"flex",justifyContent:"center",position:"relative",style:{height:0,top:d,width:l},width:"full"},J.createElement(AsyncImage,{background:t,borderColor:{custom:"rgba(0, 0, 0, 0.06)"},borderRadius:"13",height:o,src:i,width:o})),J.createElement("svg",{height:l,style:{all:"revert"},width:l},J.createElement("title",null,"QR Code"),J.createElement("defs",null,J.createElement("clipPath",{id:"clip-wrapper"},J.createElement("rect",{height:p,width:p})),J.createElement("clipPath",{id:"clip-logo"},J.createElement("rect",{height:o,width:o}))),J.createElement("rect",{fill:"transparent",height:l,width:l}),u)))}var getBrowserSrc=async()=>{let e=getBrowser();switch(e){case"Arc":return(await n.e(6328).then(n.bind(n,76328))).default;case"Brave":return(await n.e(6551).then(n.bind(n,86551))).default;case"Chrome":return(await n.e(7682).then(n.bind(n,57682))).default;case"Edge":return(await n.e(934).then(n.bind(n,60934))).default;case"Firefox":return(await n.e(9223).then(n.bind(n,99223))).default;case"Opera":return(await n.e(9941).then(n.bind(n,89941))).default;case"Safari":return(await n.e(2604).then(n.bind(n,62604))).default;default:return(await n.e(2746).then(n.bind(n,92746))).default}},preloadBrowserIcon=()=>loadImages(getBrowserSrc),getPlatformSrc=async()=>{let e=getPlatform();switch(e){case"Windows":return(await n.e(5710).then(n.bind(n,35710))).default;case"macOS":return(await n.e(8906).then(n.bind(n,8906))).default;default:return(await n.e(8366).then(n.bind(n,78366))).default}},preloadPlatformIcon=()=>loadImages(getPlatformSrc);function GetDetail({getWalletDownload:e,compactModeEnabled:t}){let n=useWalletConnectors(),o=n.splice(0,5),{i18n:i}=(0,J.useContext)(e1);return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",marginTop:"18",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"28",height:"full",width:"full"},null==o?void 0:o.filter(e=>{var t;return e.extensionDownloadUrl||e.desktopDownloadUrl||e.qrCode&&(null==(t=e.downloadUrls)?void 0:t.qrCode)}).map(t=>
1080{let{downloadUrls:n,iconBackground:o,iconUrl:s,id:c,name:l,qrCode:u}=t,d=(null==n?void 0:n.qrCode)&&u,p=!!t.extensionDownloadUrl,m=(null==n?void 0:n.qrCode)&&p,b=(null==n?void 0:n.qrCode)&&!!t.desktopDownloadUrl;return J.createElement(eQ,{alignItems:"center",display:"flex",gap:"16",justifyContent:"space-between",key:t.id,width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},J.createElement(AsyncImage,{background:o,borderColor:"actionButtonBorder",borderRadius:"10",height:"48",src:s,width:"48"}),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"2"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},l),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},m?i.t("get.mobile_and_extension.description"):b?i.t("get.mobile_and_desktop.description"):d?i.t("get.mobile.description"):p?i.t("get.extension.description"):null))),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(ActionButton,{label:i.t("get.action.label"),onClick:()=>e(c),type:"secondary"})))})),J.createElement(eQ,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"column",gap:"8",justifyContent:"space-between",marginBottom:"4",paddingY:"8",style:{maxWidth:275,textAlign:"center"}},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},i.t("get.looking_for.title")),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},t?i.t("get.looking_for.desktop.compact_description"):i.t("get.looking_for.desktop.wide_description"))))}function ConnectDetail({changeWalletStep:e,compactModeEnabled:t,connectionError:n,onClose:o,qrCodeUri:i,reconnect:s,wallet:c}){var l;let{downloadUrls:u,iconBackground:d,iconUrl:p,name:m,qrCode:b,ready:g,showWalletConnectModal:y}=c,v=null==(l=c.desktop)?void 0:l.getUri,E=isSafari(),{i18n:x}=(0,J.useContext)(e1),P=!!c.extensionDownloadUrl,_=(null==u?void 0:u.qrCode)&&P,I=(null==u?void 0:u.qrCode)&&!!c.desktopDownloadUrl,j=b&&i,R=y?{description:t?x.t("connect.walletconnect.description.compact"):x.t("connect.walletconnect.description.full"),label:x.t("connect.walletconnect.open.label"),onClick:()=>{o(),y()}}:j?{description:x.t("connect.secondary_action.get.description",{wallet:m}),label:x.t("connect.secondary_action.get.label"),onClick:()=>e(_||I?"DOWNLOAD_OPTIONS":"DOWNLOAD")}:null,{width:M}=useWindowSize();return(0,J.useEffect)(()=>{preloadBrowserIcon(),preloadPlatformIcon()},[]),J.createElement(eQ,{display:"flex",flexDirection:"column",height:"full",width:"full"},j?J.createElement(eQ,{alignItems:"center",display:"flex",height:"full",justifyContent:"center"},J.createElement(QRCode,{logoBackground:d,logoSize:t?60:72,logoUrl:p,size:t?318:M&&M<768?Math.max(280,Math.min(M-308,382)):382,uri:i})):J.createElement(eQ,{alignItems:"center",display:"flex",justifyContent:"center",style:{flexGrow:1}},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"8"},J.createElement(eQ,{borderRadius:"10",height:"44",overflow:"hidden"},J.createElement(AsyncImage,{height:"44",src:p,width:"44"})),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"4",paddingX:"32",style:{textAlign:"center"}},J.createElement(tw,{color:"modalText",size:"18",weight:"bold"},g?x.t("connect.status.opening",{wallet:m}):P?x.t("connect.status.not_installed",{wallet:m}):x.t("connect.status.not_available",{wallet:m})),!g&&P?J.createElement(eQ,{paddingTop:"20"},J.createElement(ActionButton,{href:c.extensionDownloadUrl,label:x.t("connect.secondary_action.install.label"),type:"secondary"})):null,g&&!j&&J.createElement(J.Fragment,null,J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",justifyContent:"center"},J.createElement(tw,{color:"modalTextSecondary",size:"14",textAlign:"center",weight:"medium"},x.t("connect.status.confirm"))),J.createElement(eQ,{alignItems:"center",color:"modalText",display:"flex",flexDirection:"row",height:"32",marginTop:"8"},n?J.createElement(ActionButton,{label:x.t("connect.secondary_action.retry.label"),onClick:v?async()=>{let e=await v();window.open(e,E?"_blank":"_self")}:()=>{s(c)}}):J.createElement(eQ,{color:"modalTextSecondary"},J.createElement(SpinnerIcon,null))))))),J.createElement(eQ,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"row",gap:"8",height:"28",justifyContent:"space-between",marginTop:"12"},g&&R&&J.createElement(J.Fragment,null,J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},R.description),J.createElement(ActionButton,{label:R.label,onClick:R.onClick,type:"secondary"}))))}var DownloadOptionsBox=({actionLabel:e,description:t,iconAccent:n,iconBackgroun
1080d:o,iconUrl:i,isCompact:s,onAction:c,title:l,url:u,variant:d})=>{let p="browser"===d,m=!p&&n&&getGradientRGBAs(n);return J.createElement(eQ,{alignItems:"center",borderRadius:"13",display:"flex",justifyContent:"center",overflow:"hidden",paddingX:s?"18":"44",position:"relative",style:{flex:1,isolation:"isolate"},width:"full"},J.createElement(eQ,{borderColor:"actionButtonBorder",borderRadius:"13",borderStyle:"solid",borderWidth:"1",style:{bottom:"0",left:"0",position:"absolute",right:"0",top:"0",zIndex:1}}),p&&J.createElement(eQ,{background:"downloadTopCardBackground",height:"full",position:"absolute",style:{zIndex:0},width:"full"},J.createElement(eQ,{display:"flex",flexDirection:"row",justifyContent:"space-between",style:{bottom:"0",filter:"blur(20px)",left:"0",position:"absolute",right:"0",top:"0",transform:"translate3d(0, 0, 0)"}},J.createElement(eQ,{style:{filter:"blur(100px)",marginLeft:-27,marginTop:-20,opacity:.6,transform:"translate3d(0, 0, 0)"}},J.createElement(AsyncImage,{borderRadius:"full",height:"200",src:i,width:"200"})),J.createElement(eQ,{style:{filter:"blur(100px)",marginRight:0,marginTop:105,opacity:.6,overflow:"auto",transform:"translate3d(0, 0, 0)"}},J.createElement(AsyncImage,{borderRadius:"full",height:"200",src:i,width:"200"})))),!p&&m&&J.createElement(eQ,{background:"downloadBottomCardBackground",style:{bottom:"0",left:"0",position:"absolute",right:"0",top:"0"}},J.createElement(eQ,{position:"absolute",style:{background:`radial-gradient(50% 50% at 50% 50%, ${m[0]} 0%, ${m[1]} 25%, rgba(0,0,0,0) 100%)`,height:564,left:-215,top:-197,transform:"translate3d(0, 0, 0)",width:564}}),J.createElement(eQ,{position:"absolute",style:{background:`radial-gradient(50% 50% at 50% 50%, ${m[2]} 0%, rgba(0, 0, 0, 0) 100%)`,height:564,left:-1,top:-76,transform:"translate3d(0, 0, 0)",width:564}})),J.createElement(eQ,{alignItems:"flex-start",display:"flex",flexDirection:"row",gap:"24",height:"max",justifyContent:"center",style:{zIndex:1}},J.createElement(eQ,null,J.createElement(AsyncImage,{height:"60",src:i,width:"60",...o?{background:o,borderColor:"generalBorder",borderRadius:"10"}:null})),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4",style:{flex:1},width:"full"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},l),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},t),J.createElement(eQ,{marginTop:"14",width:"max"},J.createElement(ActionButton,{href:u,label:e,onClick:c,size:"medium"})))))};function DownloadOptionsDetail({changeWalletStep:e,wallet:t}){let n=getBrowser(),o=getPlatform(),i=(0,J.useContext)(tb),s="compact"===i,{desktop:c,desktopDownloadUrl:l,extension:u,extensionDownloadUrl:d,mobileDownloadUrl:p}=t,{i18n:m}=(0,J.useContext)(e1);return(0,J.useEffect)(()=>{preloadCreateIcon(),preloadScanIcon(),preloadRefreshIcon(),preloadConnectIcon()},[]),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"24",height:"full",marginBottom:"8",marginTop:"4",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"8",height:"full",justifyContent:"center",width:"full"},d&&J.createElement(DownloadOptionsBox,{actionLabel:m.t("get_options.extension.download.label",{browser:n}),description:m.t("get_options.extension.description"),iconUrl:getBrowserSrc,isCompact:s,onAction:()=>e((null==u?void 0:u.instructions)?"INSTRUCTIONS_EXTENSION":"CONNECT"),title:m.t("get_options.extension.title",{wallet:t.name,browser:n}),url:d,variant:"browser"}),l&&J.createElement(DownloadOptionsBox,{actionLabel:m.t("get_options.desktop.download.label",{platform:o}),description:m.t("get_options.desktop.description"),iconUrl:getPlatformSrc,isCompact:s,onAction:()=>e((null==c?void 0:c.instructions)?"INSTRUCTIONS_DESKTOP":"CONNECT"),title:m.t("get_options.desktop.title",{wallet:t.name,platform:o}),url:l,variant:"desktop"}),p&&J.createElement(DownloadOptionsBox,{actionLabel:m.t("get_options.mobile.download.label",{wallet:t.name}),description:m.t("get_options.mobile.description"),iconAccent:t.iconAccent,iconBackground:t.iconBackground,iconUrl:t.iconUrl,isCompact:s,onAction:()=>{e("DOWNLOAD")},title:m.t("get_options.mobile.title",{wallet:t.name}),variant:"app"})))}function DownloadDetail({changeWalletStep:e,wallet:t}){let{downloadUrls:n,qrCode:o}=t,{i18n:i}=(0,J.useContext)(e1);return(0,J.useEffect)(()=>{preloadCreateIcon(),preloadScanIcon()},[]),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"24",height:"full",width:"full"},J.createElement(eQ,{style:{maxWidth:220,textAlign:"center"}},J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"semibold"},i.t("get_mobile.description"))),J.createElement(eQ,{height:"full"},(null==n?void 0:n.qrCode)?J.createElement(QRCode,{logoSize:0,size:268,uri:n.qrCode}):null),J.createElement(eQ,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"row",gap:"8",height:"34",justifyContent:"space-between",marginBottom:"12",paddingY:"8"},J.createElement(ActionButton,{label:i.t("get_mobile.continue.label"),onClick:()=>e((null==o?void 0:o.instructions)?"INSTRUCTIONS_MOBILE":"CONNECT")})))}var tk={connect:()=>
1080J.createElement(ConnectIcon,null),create:()=>J.createElement(CreateIcon,null),install:e=>J.createElement(AsyncImage,{background:e.iconBackground,borderColor:"generalBorder",borderRadius:"10",height:"48",src:e.iconUrl,width:"48"}),refresh:()=>J.createElement(RefreshIcon,null),scan:()=>J.createElement(ScanIcon,null)};function InstructionMobileDetail({connectWallet:e,wallet:t}){var n,o,i,s;let{i18n:c}=(0,J.useContext)(e1);return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},null==(o=null==(n=null==t?void 0:t.qrCode)?void 0:n.instructions)?void 0:o.steps.map((e,n)=>{var o;return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:n},J.createElement(eQ,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},null==(o=tk[e.step])?void 0:o.call(tk,t)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},c.t(e.title)),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},c.t(e.description))))})),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},J.createElement(ActionButton,{label:c.t("get_instructions.mobile.connect.label"),onClick:()=>e(t)}),J.createElement(eQ,{as:"a",className:touchableStyles({active:"shrink",hover:"grow"}),display:"block",href:null==(s=null==(i=null==t?void 0:t.qrCode)?void 0:i.instructions)?void 0:s.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},J.createElement(tw,{color:"accentColor",size:"14",weight:"bold"},c.t("get_instructions.mobile.learn_more.label")))))}function InstructionExtensionDetail({wallet:e}){var t,n,o,i;let{i18n:s}=(0,J.useContext)(e1);return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},null==(n=null==(t=null==e?void 0:e.extension)?void 0:t.instructions)?void 0:n.steps.map((t,n)=>{var o;return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:n},J.createElement(eQ,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},null==(o=tk[t.step])?void 0:o.call(tk,e)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},s.t(t.title)),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},s.t(t.description))))})),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},J.createElement(ActionButton,{label:s.t("get_instructions.extension.refresh.label"),onClick:window.location.reload.bind(window.location)}),J.createElement(eQ,{as:"a",className:touchableStyles({active:"shrink",hover:"grow"}),display:"block",href:null==(i=null==(o=null==e?void 0:e.extension)?void 0:o.instructions)?void 0:i.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},J.createElement(tw,{color:"accentColor",size:"14",weight:"bold"},s.t("get_instructions.extension.learn_more.label")))))}function InstructionDesktopDetail({connectWallet:e,wallet:t}){var n,o,i,s;let{i18n:c}=(0,J.useContext)(e1);return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},null==(o=null==(n=null==t?void 0:t.desktop)?void 0:n.instructions)?void 0:o.steps.map((e,n)=>{var o;return J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:n},J.createElement(eQ,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},null==(o=tk[e.step])?void 0:o.call(tk,t)),J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},J.createElement(tw,{color:"modalText",size:"14",weight:"bold"},c.t(e.title)),J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},c.t(e.description))))})),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},J.createElement(ActionButton,{label:c.t("get_instructions.desktop.connect.label"),onClick:()=>e(t)}),J.createElement(eQ,{as:"a",className:touchableStyles({active:"shrink",hover:"grow"}),display:"block",href:null==(s=null==(i=null==t?void 0:t.desktop)?void 0:i.instructions)?void 0:s.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},J.createElement(tw,{color:"accentColor",size:"14",weight:"bold"},c.t("get_instructions.desktop.learn_more.label")))))}function DesktopOptions({onClose:e}){let t;let n=isSafari(),[o,i]=(0,J.useState)(),[s,c]=(0,J.useState)(),[l,u]=(0,J.useState)(),d=!!(null==s?void 0:s.qrCode)&&l,[p,m]=(0,J.useState)(!1),b=(0,J.useContext)(tb),g=b===tm.COMPACT,{disclaimer:y}=(0,J.useContext)(tf),{i18n:v}=(0,J.useContext)(e1),E=(0,J.useRef)(!1),{connector:x}=(0,J.useContext)(th),P=useWalletConnectors().filter(e=>e.ready||!!e.extensionDownloadUrl).sort((e,t)=>
1080e.groupIndex-t.groupIndex),_=function(e,t){let n={};for(let o of e){let e=t(o);e&&(n[e]||(n[e]=[]),n[e].push(o))}return n}(P,e=>e.groupName),I=["Recommended","Other","Popular","More","Others"];(0,J.useEffect)(()=>{x&&!E.current&&(changeWalletStep("CONNECT"),selectWallet(x),E.current=!0)},[x]);let connectToWallet=e=>{var t,o,i;if(m(!1),e.ready){null==(o=null==(t=null==e?void 0:e.connect)?void 0:t.call(e))||o.catch(()=>{m(!0)});let s=null==(i=e.desktop)?void 0:i.getUri;s&&setTimeout(async()=>{let e=await s();window.open(e,n?"_blank":"_self")},0)}},selectWallet=e=>{var t,n;if(n=e.id,localStorage.setItem(t_,n),connectToWallet(e),i(e.id),e.ready){let n=!1;null==(t=null==e?void 0:e.onConnecting)||t.call(e,async()=>{var t,o;if(n)return;n=!0;let i=P.find(t=>e.id===t.id),s=await (null==(t=null==i?void 0:i.qrCode)?void 0:t.getUri());u(s),setTimeout(()=>{c(i),changeWalletStep("CONNECT")},s?0:50);let l=await (null==i?void 0:i.connector.getProvider()),d=null==(o=null==l?void 0:l.signer)?void 0:o.connection;if((null==d?void 0:d.on)&&(null==d?void 0:d.off)){let handleConnectionClose=()=>{removeHandlers(),selectWallet(e)},removeHandlers=()=>{d.off("close",handleConnectionClose),d.off("open",removeHandlers)};d.on("close",handleConnectionClose),d.on("open",removeHandlers)}})}else c(e),changeWalletStep((null==e?void 0:e.extensionDownloadUrl)?"DOWNLOAD_OPTIONS":"CONNECT")},clearSelectedWallet=()=>{i(void 0),c(void 0),u(void 0)},changeWalletStep=(e,t=!1)=>{t&&"GET"===e&&"GET"===j?clearSelectedWallet():t||"GET"!==e?t||"CONNECT"!==e||R("CONNECT"):R("GET"),F(e)},[j,R]=(0,J.useState)("NONE"),[M,F]=(0,J.useState)("NONE"),q=null,H=null,z=null;(0,J.useEffect)(()=>{m(!1)},[M,s]);let W=!!(null==s?void 0:s.extensionDownloadUrl),K=!!(W&&(null==s?void 0:s.mobileDownloadUrl));switch(M){case"NONE":q=J.createElement(ConnectModalIntro,{getWallet:()=>changeWalletStep("GET")});break;case"LEARN_COMPACT":q=J.createElement(ConnectModalIntro,{compactModeEnabled:g,getWallet:()=>changeWalletStep("GET")}),H=v.t("intro.title"),z="NONE";break;case"GET":q=J.createElement(GetDetail,{getWalletDownload:e=>{var t;i(e);let n=P.find(t=>e===t.id),o=null==(t=null==n?void 0:n.downloadUrls)?void 0:t.qrCode,s=!!(null==n?void 0:n.desktopDownloadUrl),l=!!(null==n?void 0:n.extensionDownloadUrl);c(n),o&&(l||s)?changeWalletStep("DOWNLOAD_OPTIONS"):o?changeWalletStep("DOWNLOAD"):s?changeWalletStep("INSTRUCTIONS_DESKTOP"):changeWalletStep("INSTRUCTIONS_EXTENSION")},compactModeEnabled:g}),H=v.t("get.title"),z=g?"LEARN_COMPACT":"NONE";break;case"CONNECT":q=s&&J.createElement(ConnectDetail,{changeWalletStep,compactModeEnabled:g,connectionError:p,onClose:e,qrCodeUri:l,reconnect:connectToWallet,wallet:s}),H=d&&("WalletConnect"===s.name?v.t("connect_scan.fallback_title"):v.t("connect_scan.title",{wallet:s.name})),z=g?x?null:"NONE":null,t=g?x?()=>{}:clearSelectedWallet:()=>{};break;case"DOWNLOAD_OPTIONS":q=s&&J.createElement(DownloadOptionsDetail,{changeWalletStep,wallet:s}),H=s&&v.t("get_options.short_title",{wallet:s.name}),z=x?"CONNECT":g?"NONE":null;break;case"DOWNLOAD":q=s&&J.createElement(DownloadDetail,{changeWalletStep,wallet:s}),H=s&&v.t("get_mobile.title",{wallet:s.name}),z=K?"DOWNLOAD_OPTIONS":j;break;case"INSTRUCTIONS_MOBILE":q=s&&J.createElement(InstructionMobileDetail,{connectWallet:selectWallet,wallet:s}),H=s&&v.t("get_options.title",{wallet:g&&s.shortName||s.name}),z="DOWNLOAD";break;case"INSTRUCTIONS_EXTENSION":q=s&&J.createElement(InstructionExtensionDetail,{wallet:s}),H=s&&v.t("get_options.title",{wallet:g&&s.shortName||s.name}),z="DOWNLOAD_OPTIONS";break;
1080case"INSTRUCTIONS_DESKTOP":q=s&&J.createElement(InstructionDesktopDetail,{connectWallet:selectWallet,wallet:s}),H=s&&v.t("get_options.title",{wallet:g&&s.shortName||s.name}),z="DOWNLOAD_OPTIONS"}return J.createElement(eQ,{display:"flex",flexDirection:"row",style:{maxHeight:g?468:504}},(!g||"NONE"===M)&&J.createElement(eQ,{className:g?"_1vwt0cg4":"_1vwt0cg3",display:"flex",flexDirection:"column",marginTop:"16"},J.createElement(eQ,{display:"flex",justifyContent:"space-between"},g&&y&&J.createElement(eQ,{marginLeft:"16",width:"28"},J.createElement(InfoButton,{onClick:()=>changeWalletStep("LEARN_COMPACT")})),g&&!y&&J.createElement(eQ,{marginLeft:"16",width:"28"}),J.createElement(eQ,{marginLeft:g?"0":"6",paddingBottom:"8",paddingTop:"2",paddingX:"18"},J.createElement(tw,{as:"h1",color:"modalText",id:"rk_connect_title",size:"18",weight:"heavy",testId:"connect-header-label"},v.t("connect.title"))),g&&J.createElement(eQ,{marginRight:"16"},J.createElement(CloseButton,{onClose:e}))),J.createElement(eQ,{className:"_1vwt0cg2 ju367v7a ju367v7v",paddingBottom:"18"},Object.entries(_).map(([e,t],n)=>t.length>0&&J.createElement(J.Fragment,{key:n},e?J.createElement(eQ,{marginBottom:"8",marginTop:"16",marginX:"6"},J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"bold"},I.includes(e)?v.t(`connector_group.${e.toLowerCase()}`):e)):null,J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"4"},t.map(e=>J.createElement(ModalSelection,{currentlySelected:e.id===o,iconBackground:e.iconBackground,iconUrl:e.iconUrl,key:e.id,name:e.name,onClick:()=>selectWallet(e),ready:e.ready,recent:e.recent,testId:`wallet-option-${e.id}`})))))),g&&J.createElement(J.Fragment,null,J.createElement(eQ,{background:"generalBorder",height:"1",marginTop:"-1"}),y?J.createElement(eQ,{paddingX:"24",paddingY:"16",textAlign:"center"},J.createElement(y,{Link:DisclaimerLink,Text:DisclaimerText})):J.createElement(eQ,{alignItems:"center",display:"flex",justifyContent:"space-between",paddingX:"24",paddingY:"16"},J.createElement(eQ,{paddingY:"4"},J.createElement(tw,{color:"modalTextSecondary",size:"14",weight:"medium"},v.t("connect.new_to_ethereum.description"))),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",justifyContent:"center"},J.createElement(eQ,{className:touchableStyles({active:"shrink",hover:"grow"}),cursor:"pointer",onClick:()=>changeWalletStep("LEARN_COMPACT"),paddingY:"4",style:{willChange:"transform"},transition:"default"},J.createElement(tw,{color:"accentColor",size:"14",weight:"bold"},v.t("connect.new_to_ethereum.learn_more.label"))))))),(!g||"NONE"!==M)&&J.createElement(J.Fragment,null,!g&&J.createElement(eQ,{background:"generalBorder",minWidth:"1",width:"1"}),J.createElement(eQ,{display:"flex",flexDirection:"column",margin:"16",style:{flexGrow:1}},J.createElement(eQ,{alignItems:"center",display:"flex",justifyContent:"space-between",marginBottom:"12"},J.createElement(eQ,{width:"28"},z&&J.createElement(eQ,{as:"button",className:touchableStyles({active:"shrinkSm",hover:"growLg"}),color:"accentColor",onClick:()=>{z&&changeWalletStep(z,!0),null==t||t()},paddingX:"8",paddingY:"4",style:{boxSizing:"content-box",height:17,willChange:"transform"},transition:"default",type:"button"},J.createElement(BackIcon,null))),J.createElement(eQ,{display:"flex",justifyContent:"center",style:{flexGrow:1}},H&&J.createElement(tw,{color:"modalText",size:"18",textAlign:"center",weight:"heavy"},H)),J.createElement(CloseButton,{onClose:e})),J.createElement(eQ,{display:"flex",flexDirection:"column",style:{minHeight:g?396:432}},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"6",height:"full",justifyContent:"center",marginX:"8"},q)))))}var LoadingSpinner=({wallet:e})=>J.createElement("svg",{className:"_1am14413",viewBox:"0 0 86 86",width:"86",height:"86"}
1080,J.createElement("title",null,"Loading"),J.createElement("rect",{x:"3",y:"3",width:80,height:80,rx:20,ry:20,strokeDasharray:"53.333333333333336 "+320/3,strokeDashoffset:160,className:"_1am14412",style:{stroke:(null==e?void 0:e.iconAccent)||"#0D3887"}}));function WalletButton({onClose:e,wallet:t,connecting:n}){let{connect:o,connector:i,iconBackground:s,iconUrl:c,id:l,mobile:u,name:d,onConnecting:p,ready:m,shortName:b}=t,g=null==u?void 0:u.getUri,y=useCoolMode(c),v=(0,J.useRef)(!1),{i18n:E}=(0,J.useContext)(e1),x=(0,J.useCallback)(async()=>{var t;"walletConnect"===l&&(null==e||e()),null==(t=null==o?void 0:o())||t.catch(()=>{});let n=!1;null==p||p(async()=>{if(!n&&(n=!0,g)){let e=await g();if(("walletConnect"===i.id||"walletConnectLegacy"===i.id)&&function({mobileUri:e,name:t}){localStorage.setItem(tx,JSON.stringify({href:e.split("?")[0],name:t}))}({mobileUri:e,name:d}),e.startsWith("http")){let t=document.createElement("a");t.href=e,t.target="_blank",t.rel="noreferrer noopener",t.click()}else window.location.href=e}})},[i,o,g,p,e,d,l]);return(0,J.useEffect)(()=>{n&&!v.current&&(x(),v.current=!0)},[n,x]),J.createElement(eQ,{as:"button",color:m?"modalText":"modalTextSecondary",disabled:!m,fontFamily:"body",key:l,onClick:x,ref:y,style:{overflow:"visible",textAlign:"center"},testId:`wallet-option-${l}`,type:"button",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",justifyContent:"center"},J.createElement(eQ,{display:"flex",alignItems:"center",justifyContent:"center",paddingBottom:"8",paddingTop:"10",position:"relative"},n?J.createElement(LoadingSpinner,{wallet:t}):null,J.createElement(AsyncImage,{background:s,borderRadius:"13",boxShadow:"walletLogo",height:"60",src:c,width:"60"})),n?null:J.createElement(eQ,{display:"flex",flexDirection:"column",textAlign:"center"},J.createElement(tw,{as:"h2",color:t.ready?"modalText":"modalTextSecondary",size:"13",weight:"medium"},J.createElement(eQ,{as:"span",position:"relative"},null!=b?b:d,!t.ready&&" (unsupported)")),t.recent&&J.createElement(tw,{color:"accentColor",size:"12",weight:"medium"},E.t("connect.recent")))))}function MobileOptions({onClose:e}){var t;let n=useWalletConnectors(),{disclaimer:o,learnMoreUrl:i}=(0,J.useContext)(tf),s=null,c=null,l=!1,u=null,[d,p]=(0,J.useState)("CONNECT"),{i18n:m}=(0,J.useContext)(e1),b=isIOS();switch(d){case"CONNECT":s=m.t("connect.title"),l=!0,c=J.createElement(eQ,null,J.createElement(eQ,{background:"profileForeground",className:"_1am14410",display:"flex",paddingBottom:"20",paddingTop:"6"},J.createElement(eQ,{display:"flex",style:{margin:"0 auto"}},n.filter(e=>e.ready).map(t=>J.createElement(eQ,{key:t.id,paddingX:"20"},J.createElement(eQ,{width:"60"},J.createElement(WalletButton,{onClose:e,wallet:t})))))),J.createElement(eQ,{background:"generalBorder",height:"1",marginBottom:"32",marginTop:"-1"}),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"32",paddingX:"32",style:{textAlign:"center"}},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"8",textAlign:"center"},J.createElement(tw,{color:"modalText",size:"16",weight:"bold"},m.t("intro.title")),J.createElement(tw,{color:"modalTextSecondary",size:"16"},m.t("intro.description")))),J.createElement(eQ,{paddingTop:"32",paddingX:"20"},J.createElement(eQ,{display:"flex",gap:"14",justifyContent:"center"},J.createElement(ActionButton,{label:m.t("intro.get.label"),onClick:()=>p("GET"),size:"large",type:"secondary"}),J.createElement(ActionButton,{href:i,label:m.t("intro.learn_more.label"),size:"large",type:"secondary"}))),o&&J.createElement(eQ,{marginTop:"28",marginX:"32",textAlign:"center"},J.createElement(o,{Link:DisclaimerLink,Text:DisclaimerText})));break;case"GET":{s=m.t("get.title"),u="CONNECT";let e=null==(t=null==n?void 0:n.filter(e=>{var t,n,o;return(null==(t=e.downloadUrls)?void 0:t.ios)||(null==(n=e.downloadUrls)?void 0:n.android)||(null==(o=e.downloadUrls)?void 0:o.mobile)}))?void 0:t.splice(0,3);c=J.createElement(eQ,null,J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",marginBottom:"36",marginTop:"5",paddingTop:"12",width:"full"},e.map((t,n)=>
1080{let{downloadUrls:o,iconBackground:i,iconUrl:s,name:c}=t;return(null==o?void 0:o.ios)||(null==o?void 0:o.android)||(null==o?void 0:o.mobile)?J.createElement(eQ,{display:"flex",gap:"16",key:t.id,paddingX:"20",width:"full"},J.createElement(eQ,{style:{minHeight:48,minWidth:48}},J.createElement(AsyncImage,{background:i,borderColor:"generalBorder",borderRadius:"10",height:"48",src:s,width:"48"})),J.createElement(eQ,{display:"flex",flexDirection:"column",width:"full"},J.createElement(eQ,{alignItems:"center",display:"flex",height:"48"},J.createElement(eQ,{width:"full"},J.createElement(tw,{color:"modalText",size:"18",weight:"bold"},c)),J.createElement(ActionButton,{href:(b?null==o?void 0:o.ios:null==o?void 0:o.android)||(null==o?void 0:o.mobile),label:m.t("get.action.label"),size:"small",type:"secondary"})),n<e.length-1&&J.createElement(eQ,{background:"generalBorderDim",height:"1",marginY:"10",width:"full"}))):null})),J.createElement(eQ,{style:{marginBottom:"42px"}}),J.createElement(eQ,{alignItems:"center",display:"flex",flexDirection:"column",gap:"36",paddingX:"36",style:{textAlign:"center"}},J.createElement(eQ,{display:"flex",flexDirection:"column",gap:"12",textAlign:"center"},J.createElement(tw,{color:"modalText",size:"16",weight:"bold"},m.t("get.looking_for.title")),J.createElement(tw,{color:"modalTextSecondary",size:"16"},m.t("get.looking_for.mobile.description")))))}}return J.createElement(eQ,{display:"flex",flexDirection:"column",paddingBottom:"36"},J.createElement(eQ,{background:l?"profileForeground":"modalBackground",display:"flex",flexDirection:"column",paddingBottom:"4",paddingTop:"14"},J.createElement(eQ,{display:"flex",justifyContent:"center",paddingBottom:"6",paddingX:"20",position:"relative"},u&&J.createElement(eQ,{display:"flex",position:"absolute",style:{left:0,marginBottom:-20,marginTop:-20}},J.createElement(eQ,{alignItems:"center",as:"button",className:touchableStyles({active:"shrinkSm",hover:"growLg"}),color:"accentColor",display:"flex",marginLeft:"4",marginTop:"20",onClick:()=>p(u),padding:"16",style:{height:17,willChange:"transform"},transition:"default",type:"button"},J.createElement(BackIcon,null))),J.createElement(eQ,{marginTop:"4",textAlign:"center",width:"full"},J.createElement(tw,{as:"h1",color:"modalText",id:"rk_connect_title",size:"20",weight:"bold"},s)),J.createElement(eQ,{alignItems:"center",display:"flex",height:"32",paddingRight:"14",position:"absolute",right:"0"},J.createElement(eQ,{style:{marginBottom:-20,marginTop:-20}},J.createElement(CloseButton,{onClose:e}))))),J.createElement(eQ,{display:"flex",flexDirection:"column"},c))}var MobileStatus=({onClose:e})=>{let{connector:t}=(0,J.useContext)(th),{i18n:n}=(0,J.useContext)(e1),o=(null==t?void 0:t.name)||"";return J.createElement(eQ,null,J.createElement(eQ,{display:"flex",paddingBottom:"32",justifyContent:"center",alignItems:"center",background:"profileForeground",flexDirection:"column"},J.createElement(eQ,{width:"full",display:"flex",justifyContent:"flex-end",marginTop:"18",marginRight:"24"},J.createElement(CloseButton,{onClose:e})),J.createElement(eQ,{width:"60"},J.createElement(WalletButton,{onClose:e,wallet:t,connecting:!0})),J.createElement(eQ,{marginTop:"20"},J.createElement(tw,{textAlign:"center",color:"modalText",size:"18",weight:"semibold"},n.t("connect.status.connect_mobile",{wallet:o}))),J.createElement(eQ,{maxWidth:"full",marginTop:"8"},J.createElement(tw,{textAlign:"center",color:"modalText",size:"16",weight:"medium"},n.t("connect.status.confirm_mobile",{wallet:o})))))};function ConnectOptions({onClose:e}){let{connector:t}=(0,J.useContext)(th);return isMobile()?t?J.createElement(MobileStatus,{onClose:e}):J.createElement(MobileOptions,{onClose:e}):J.createElement(DesktopOptions,{onClose:e})}function ConnectModal({onClose:e,open:t}){let n="rk_connect_title",o=useConnectionStatus(),{disconnect:i}=(0,et.qL)(),{isConnecting:s}=(0,et.mA)(),c=J.useCallback(()=>{e(),i()},[e,i]),l=J.useCallback(()=>{s&&i(),e()},[e,i,s]);return"disconnected"===o?J.createElement(Dialog,{onClose:l,open:t,titleId:n},J.createElement(DialogContent,{bottomSheetOnMobile:!0,padding:"0",wide:!0},J.createElement(ConnectOptions,{onClose:l}))):"unauthenticated"===o?J.createElement(Dialog,{onClose:c,open:t,titleId:n},J.createElement(DialogContent,{bottomSheetOnMobile:!0,padding:"0"},J.createElement(SignIn,{onClose:c,onCloseModal:e}))):null}function useModalStateValue(){let[e,t]=(0,J.useState)(!1);return{closeModal:(0,J.useCallback)(()=>t(!1),[]),isModalOpen:e,openModal:(0,J.useCallback)(()=>t(!0),[])}}var tO=(0,J.createContext)({accountModalOpen:!1,chainModalOpen:!1,connectMod
1080alOpen:!1});function ModalProvider({children:e}){let{closeModal:t,isModalOpen:n,openModal:o}=useModalStateValue(),{closeModal:i,isModalOpen:s,openModal:c}=useModalStateValue(),{closeModal:l,isModalOpen:u,openModal:d}=useModalStateValue(),p=useConnectionStatus(),{chain:m}=(0,et.LN)(),b=!(null==m?void 0:m.unsupported);function closeModals({keepConnectModalOpen:e=!1}={}){e||t(),i(),l()}let g="unauthenticated"===useAuthenticationStatus();return(0,et.mA)({onConnect:()=>closeModals({keepConnectModalOpen:g}),onDisconnect:()=>closeModals()}),J.createElement(tO.Provider,{value:(0,J.useMemo)(()=>({accountModalOpen:s,chainModalOpen:u,connectModalOpen:n,openAccountModal:b&&"connected"===p?c:void 0,openChainModal:"connected"===p?d:void 0,openConnectModal:"disconnected"===p||"unauthenticated"===p?o:void 0}),[p,b,s,u,n,c,d,o])},e,J.createElement(ConnectModal,{onClose:t,open:n}),J.createElement(AccountModal,{onClose:i,open:s}),J.createElement(ChainModal,{onClose:l,open:u}))}var noop=()=>{};function ConnectButtonRenderer({children:e}){var t,n,o,i;let s=function(){let[e,t]=(0,J.useState)(!1);return(0,J.useEffect)(()=>(t(!0),()=>{t(!1)}),[]),(0,J.useCallback)(()=>e,[e])}(),{address:c}=(0,et.mA)(),l=useMainnetEnsName(c),u=useMainnetEnsAvatar(l),d=useRainbowKitChainsById(),p=null!=(t=useAuthenticationStatus())?t:void 0,{chain:m}=(0,et.LN)(),b=m?d[m.id]:void 0,g=null!=(n=null==b?void 0:b.name)?n:void 0,y=null!=(o=null==b?void 0:b.iconUrl)?o:void 0,v=null!=(i=null==b?void 0:b.iconBackground)?i:void 0,E=useAsyncImage(y),x=(0,J.useContext)(tg),P=useRecentTransactions().some(({status:e})=>"pending"===e)&&x,{showBalance:_}=useShowBalance(),I=!_||eq(_)[isMobile()?"smallScreen":"largeScreen"],{data:j}=(0,et.KQ)({address:I?c:void 0}),R=j?`${abbreviateETHBalance(parseFloat(j.formatted))} ${j.symbol}`:void 0,{openConnectModal:M}=function(){let{connectModalOpen:e,openConnectModal:t}=(0,J.useContext)(tO);return{connectModalOpen:e,openConnectModal:t}}(),{openChainModal:F}=function(){let{chainModalOpen:e,openChainModal:t}=(0,J.useContext)(tO);return{chainModalOpen:e,openChainModal:t}}(),{openAccountModal:q}=function(){let{accountModalOpen:e,openAccountModal:t}=(0,J.useContext)(tO);return{accountModalOpen:e,openAccountModal:t}}(),{accountModalOpen:H,chainModalOpen:z,connectModalOpen:W}=function(){let{accountModalOpen:e,chainModalOpen:t,connectModalOpen:n}=(0,J.useContext)(tO);return{accountModalOpen:e,chainModalOpen:t,connectModalOpen:n}}();return J.createElement(J.Fragment,null,e({account:c?{address:c,balanceDecimals:null==j?void 0:j.decimals,balanceFormatted:null==j?void 0:j.formatted,balanceSymbol:null==j?void 0:j.symbol,displayBalance:R,displayName:l?formatENS(l):formatAddress(c),ensAvatar:null!=u?u:void 0,ensName:null!=l?l:void 0,hasPendingTransactions:P}:void 0,accountModalOpen:H,authenticationStatus:p,chain:m?{hasIcon:!!y,iconBackground:v,iconUrl:E,id:m.id,name:null!=g?g:m.name,unsupported:m.unsupported}:void 0,chainModalOpen:z,connectModalOpen:W,mounted:s(),openAccountModal:null!=q?q:noop,openChainModal:null!=F?F:noop,openConnectModal:null!=M?M:noop}))}ConnectButtonRenderer.displayName="ConnectButton.Custom";var tj={accountStatus:"full",chainStatus:{largeScreen:"full",smallScreen:"icon"},label:"Connect Wallet",showBalance:{largeScreen:!0,smallScreen:!1}};function ConnectButton({accountStatus:e=tj.accountStatus,chainStatus:t=tj.chainStatus,label:n=tj.label,showBalance:o=tj.showBalance}){let i=useRainbowKitChains(),s=useConnectionStatus(),{setShowBalance:c}=useShowBalance(),[l,u]=(0,J.useState)(!1),{i18n:d}=(0,J.useContext)(e1);return(0,J.useEffect)(()=>{c(o),l||u(!0)},[o,c]),l?J.createElement(ConnectButtonRenderer,null,({account:c,chain:l,mounted:u,openAccountModal:p,openChainModal:m,openConnectModal:b})=>{var g,y,v;let E=u&&"loading"!==s,x=null!=(g=null==l?void 0:l.unsupported)&&g;return J.createElement(eQ,{display:"flex",gap:"12",...!E&&{"aria-hidden":!0,style:{opacity:0,pointerEvents:"none",userSelect:"none"}}},E&&c&&"connected"===s?J.createElement(J.Fragment,null,l&&(i.length>1||x)&&J.createElement(eQ,{alignItems:"center","aria-label":"Chain Selector",as:"button",background:x?"connectButtonBackgroun
1080dError":"connectButtonBackground",borderRadius:"connectButton",boxShadow:"connectButton",className:touchableStyles({active:"shrink",hover:"grow"}),color:x?"connectButtonTextError":"connectButtonText",display:e$(t,e=>"none"===e?"none":"flex"),fontFamily:"body",fontWeight:"bold",gap:"6",key:x?"unsupported":"supported",onClick:m,paddingX:"10",paddingY:"8",testId:x?"wrong-network-button":"chain-button",transition:"default",type:"button"},x?J.createElement(eQ,{alignItems:"center",display:"flex",height:"24",paddingX:"4"},d.t("connect_wallet.wrong_network.label")):J.createElement(eQ,{alignItems:"center",display:"flex",gap:"6"},l.hasIcon?J.createElement(eQ,{display:e$(t,e=>"full"===e||"icon"===e?"block":"none"),height:"24",width:"24"},J.createElement(AsyncImage,{alt:null!=(y=l.name)?y:"Chain icon",background:l.iconBackground,borderRadius:"full",height:"24",src:l.iconUrl,width:"24"})):null,J.createElement(eQ,{display:e$(t,e=>"icon"!==e||l.iconUrl?"full"===e||"name"===e?"block":"none":"block")},null!=(v=l.name)?v:l.id)),J.createElement(DropdownIcon,null)),!x&&J.createElement(eQ,{alignItems:"center",as:"button",background:"connectButtonBackground",borderRadius:"connectButton",boxShadow:"connectButton",className:touchableStyles({active:"shrink",hover:"grow"}),color:"connectButtonText",display:"flex",fontFamily:"body",fontWeight:"bold",onClick:p,testId:"account-button",transition:"default",type:"button"},c.displayBalance&&J.createElement(eQ,{display:e$(o,e=>e?"block":"none"),padding:"8",paddingLeft:"12"},c.displayBalance),J.createElement(eQ,{background:eq(o)[isMobile()?"smallScreen":"largeScreen"]?"connectButtonInnerBackground":"connectButtonBackground",borderColor:"connectButtonBackground",borderRadius:"connectButton",borderStyle:"solid",borderWidth:"2",color:"connectButtonText",fontFamily:"body",fontWeight:"bold",paddingX:"8",paddingY:"6",transition:"default"},J.createElement(eQ,{alignItems:"center",display:"flex",gap:"6",height:"24"},J.createElement(eQ,{display:e$(e,e=>"full"===e||"avatar"===e?"block":"none")},J.createElement(Avatar,{address:c.address,imageUrl:c.ensAvatar,loading:c.hasPendingTransactions,size:24})),J.createElement(eQ,{alignItems:"center",display:"flex",gap:"6"},J.createElement(eQ,{display:e$(e,e=>"full"===e||"address"===e?"block":"none")},c.displayName),J.createElement(DropdownIcon,null)))))):J.createElement(eQ,{as:"button",background:"accentColor",borderRadius:"connectButton",boxShadow:"connectButton",className:touchableStyles({active:"shrink",hover:"grow"}),color:"accentColorForeground",fontFamily:"body",fontWeight:"bold",height:"40",key:"connect",onClick:b,paddingX:"14",testId:"connect-button",transition:"default",type:"button"},u&&"Connect Wallet"===n?d.t("connect_wallet.label"):n))}):J.createElement(J.Fragment,null)}ConnectButton.__defaultProps=tj,ConnectButton.Custom=ConnectButtonRenderer;var _connectorsForWallets=e=>()=>{let t=-1,n=[],o=[],i=[],s=[];e.forEach(({groupName:e,wallets:n},s)=>{n.forEach(n=>{if(t++,(null==n?void 0:n.iconAccent)&&!isHexString(null==n?void 0:n.iconAccent))throw Error(`Property \`iconAccent\` is not a hex value for wallet: ${n.name}`);let c={...n,groupIndex:s,groupName:e,index:t};"function"==typeof n.hidden?i.push(c):o.push(c)})});let c=[...o,...i];return c.forEach(({createConnector:e,groupIndex:t,groupName:o,hidden:i,index:c,...l})=>{let u;if("function"==typeof i){let e=i({wallets:[...s.map(({connector:e,id:t,installed:n,name:o})=>({connector:e,id:t,installed:n,name:o}))]});if(e)return}let{connector:d,...p}=Object.fromEntries(Object.entries(e()).filter(([e,t])=>void 0!==t));if("walletConnect"===l.id&&p.qrCode&&!isMobile()){let{chains:e,options:t}=d;u=new ek({chains:e,options:{...t,showQrModal:!0}}),n.push(u)}let m={connector:d,groupIndex:t,groupName:o,index:c,walletConnectModalConnector:u,...l,...p};s.push(m),n.includes(d)||(n.push(d),d._wallets=[]),d._wallets.push(m)}),n},braveWallet=({chains:e,...t})=>{var o;return{id:"brave",name:"Brave Wallet",iconUrl:async()=>(await n.e(6847).then(n.bind(n,86847))).default,iconBackground:"#fff",installed:"undefined"!=typeof window&&(null==(o=window.ethereum)?void 0:o.isBraveWallet)===!0,downloadUrls:{},createConnector:()=>({connector:new eO._({chains:e,options:t})})}};function getExplicitInjectedProvider(e){if("undefined"==typeof window||void 0===window.ethereum)return;let t=window.ethereum.providers;return t?t.find(t=>t[e]):window.ethereum[e]?window.ethereum:void 0}var coinbaseWallet=({appName:e,chains:t,...o})=>{let i=!!getExplicitInjectedProvider("isCoinbaseWallet");return{id:"coinbase",name:"Coinbase Wallet",shortName:"Coinbase",iconUrl:async()=>(await n.e(1950).then(n.bind(n,41950))).default,iconAccent:"#2c5ff6",iconBackgroun
1080d:"#2c5ff6",installed:i||void 0,downloadUrls:{android:"https://play.google.com/store/apps/details?id=org.toshi",ios:"https://apps.apple.com/us/app/coinbase-wallet-store-crypto/id1278383455",mobile:"https://coinbase.com/wallet/downloads",qrCode:"https://coinbase-wallet.onelink.me/q5Sx/fdb9b250",chrome:"https://chrome.google.com/webstore/detail/coinbase-wallet-extension/hnfanknocfeofbddgcijnmhnfnkdnaad",browserExtension:"https://coinbase.com/wallet"},createConnector:()=>{let n=isIOS(),i=new eD({chains:t,options:{appName:e,headlessMode:!0,...o}}),getUri=async()=>(await i.getProvider()).qrUrl;return{connector:i,...n?{}:{qrCode:{getUri,instructions:{learnMoreUrl:"https://coinbase.com/wallet/articles/getting-started-mobile",steps:[{description:"wallet_connectors.coinbase.qr_code.step1.description",step:"install",title:"wallet_connectors.coinbase.qr_code.step1.title"},{description:"wallet_connectors.coinbase.qr_code.step2.description",step:"create",title:"wallet_connectors.coinbase.qr_code.step2.title"},{description:"wallet_connectors.coinbase.qr_code.step3.description",step:"scan",title:"wallet_connectors.coinbase.qr_code.step3.title"}]}},extension:{instructions:{learnMoreUrl:"https://coinbase.com/wallet/articles/getting-started-extension",steps:[{description:"wallet_connectors.coinbase.extension.step1.description",step:"install",title:"wallet_connectors.coinbase.extension.step1.title"},{description:"wallet_connectors.coinbase.extension.step2.description",step:"create",title:"wallet_connectors.coinbase.extension.step2.title"},{description:"wallet_connectors.coinbase.extension.step3.description",step:"refresh",title:"wallet_connectors.coinbase.extension.step3.title"}]}}}}}}},injectedWallet=({chains:e,...t})=>({id:"injected",name:"Browser Wallet",iconUrl:async()=>(await n.e(1088).then(n.bind(n,81088))).default,iconBackground:"#fff",hidden:({wallets:e})=>e.some(e=>e.installed&&e.name===e.connector.name&&(e.connector instanceof eO._||"coinbase"===e.id)),createConnector:()=>({connector:new eO._({chains:e,options:t})})});async function getWalletConnectUri(e,t){let n=await e.getProvider();return"2"===t?new Promise(e=>n.once("display_uri",e)):n.connector.uri}var tB=new Map;function getWalletConnectConnector({chains:e,options:t={},projectId:n,version:o="2"}){let i="21fef48091f12692cad574a6f7753643";if("2"===o){if(!n||""===n)throw Error("No projectId found. Every dApp must now provide a WalletConnect Cloud projectId to enable WalletConnect v2 https://www.rainbowkit.com/docs/installation#configure");("YOUR_PROJECT_ID"===n||n===i)&&console.warn("Invalid projectId. Please create a unique WalletConnect Cloud projectId for your dApp https://www.rainbowkit.com/docs/installation#configure")}let s={chains:e,options:"1"===o?{qrcode:!1,...t}:{projectId:"YOUR_PROJECT_ID"===n?i:n,showQrModal:!1,...t}},c=JSON.stringify(s),l=tB.get(c);return null!=l?l:function(e,t){let n="1"===e?new eN(t):new ek(t);return tB.set(JSON.stringify(t),n),n}(o,s)}function isMetaMask(e){return!!(null==e?void 0:e.isMetaMask)&&(!e.isBraveWallet||!!e._events||!!e._state)&&!e.isApexWallet&&!e.isAvalanche&&!e.isBackpack&&!e.isBifrost&&!e.isBitKeep&&!e.isBitski&&!e.isBlockWallet&&!e.isCoinbaseWallet&&!e.isDawn&&!e.isEnkrypt&&!e.isExodus&&!e.isFrame&&!e.isFrontier&&!e.isGamestop&&!e.isHyperPay&&!e.isImToken&&!e.isKuCoinWallet&&!e.isMathWallet&&!e.isOkxWallet&&!e.isOKExWallet&&!e.isOneInchIOSWallet&&!e.isOneInchAndroidWallet&&!e.isOpera&&!e.isPhantom&&!e.isPortal&&!e.isRabby&&!e.isRainbow&&!e.isStatus&&!e.isTalisman&&!e.isTally&&!e.isTokenPocket&&!e.isTokenary&&!e.isTrust&&!e.isTrustWallet&&!e.isXDEFI&&!e.isZeal&&!e.isZerion}var metaMaskWallet=({chains:e,projectId:t,walletConnectOptions:o,walletConnectVersion:i="2",...s})=>{var c,l;let u="undefined"!=typeof window&&(null==(c=window.ethereum)?void 0:c.providers),d="undefined"!=typeof window&&void 0!==window.ethereum&&((null==(l=window.ethereum.providers)?void 0:l.some(isMetaMask))||window.ethereum.isMetaMask),p=!d;return{id:"metaMask",name:"MetaMask",iconUrl:async()=>(await n.e(4419).then(n.bind(n,84419))).default,iconAccent:"#f6851a",iconBackgroun
1080d:"#fff",installed:p?void 0:d,downloadUrls:{android:"https://play.google.com/store/apps/details?id=io.metamask",ios:"https://apps.apple.com/us/app/metamask/id1438144202",mobile:"https://metamask.io/download",qrCode:"https://metamask.io/download",chrome:"https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn",edge:"https://microsoftedge.microsoft.com/addons/detail/metamask/ejbalbakoplchlghecdalmeeeajnimhm",firefox:"https://addons.mozilla.org/firefox/addon/ether-metamask",opera:"https://addons.opera.com/extensions/details/metamask-10",browserExtension:"https://metamask.io/download"},createConnector:()=>{let n=p?getWalletConnectConnector({projectId:t,chains:e,version:i,options:o}):new eR({chains:e,options:{getProvider:()=>u?u.find(isMetaMask):"undefined"!=typeof window?window.ethereum:void 0,...s}}),getUri=async()=>{let e=await getWalletConnectUri(n,i);return isAndroid()?e:isIOS()?`metamask://wc?uri=${encodeURIComponent(e)}`:`https://metamask.app.link/wc?uri=${encodeURIComponent(e)}`};return{connector:n,mobile:{getUri:p?getUri:void 0},qrCode:p?{getUri,instructions:{learnMoreUrl:"https://metamask.io/faqs/",steps:[{description:"wallet_connectors.metamask.qr_code.step1.description",step:"install",title:"wallet_connectors.metamask.qr_code.step1.title"},{description:"wallet_connectors.metamask.qr_code.step2.description",step:"create",title:"wallet_connectors.metamask.qr_code.step2.title"},{description:"wallet_connectors.metamask.qr_code.step3.description",step:"refresh",title:"wallet_connectors.metamask.qr_code.step3.title"}]}}:void 0,extension:{instructions:{learnMoreUrl:"https://metamask.io/faqs/",steps:[{description:"wallet_connectors.metamask.extension.step1.description",step:"install",title:"wallet_connectors.metamask.extension.step1.title"},{description:"wallet_connectors.metamask.extension.step2.description",step:"create",title:"wallet_connectors.metamask.extension.step2.title"},{description:"wallet_connectors.metamask.extension.step3.description",step:"refresh",title:"wallet_connectors.metamask.extension.step3.title"}]}}}}}},rainbowWallet=({chains:e,projectId:t,walletConnectOptions:o,walletConnectVersion:i="2",...s})=>{let c=!!getExplicitInjectedProvider("isRainbow"),l=!c;return{id:"rainbow",name:"Rainbow",iconUrl:async()=>(await n.e(1608).then(n.bind(n,31608))).default,iconBackground:"#0c2f78",installed:l?void 0:c,downloadUrls:{android:"https://play.google.com/store/apps/details?id=me.rainbow&referrer=utm_source%3Drainbowkit&utm_source=rainbowkit",ios:"https://apps.apple.com/app/apple-store/id1457119021?pt=119997837&ct=rainbowkit&mt=8",mobile:"https://rainbow.download?utm_source=rainbowkit",qrCode:"https://rainbow.download?utm_source=rainbowkit&utm_medium=qrcode",browserExtension:"https://rainbow.me/extension?utm_source=rainbowkit"},createConnector:()=>{let n=l?getWalletConnectConnector({projectId:t,chains:e,version:i,options:o}):function({chains:e,flag:t,options:n}){return new eO._({chains:e,options:{getProvider:()=>(function(e){if("undefined"==typeof window||void 0===window.ethereum)return;let t=window.ethereum.providers,n=getExplicitInjectedProvider(e);return n||(void 0!==t&&t.length>0?t[0]:window.ethereum)})(t),...n}})}({flag:"isRainbow",chains:e,options:s}),getUri=async()=>{let e=await getWalletConnectUri(n,i);return isAndroid()?e:isIOS()?`rainbow://wc?uri=${encodeURIComponent(e)}&connector=rainbowkit`:`https://rnbwapp.com/wc?uri=${encodeURIComponent(e)}&connector=rainbowkit`};return{connector:n,mobile:{getUri:l?getUri:void 0},qrCode:l?{getUri,instructions:{learnMoreUrl:"https://learn.rainbow.me/connect-to-a-website-or-app?utm_source=rainbowkit&utm_medium=connector&utm_campaign=learnmore",steps:[{description:"wallet_connectors.rainbow.qr_code.step1.description",step:"install",title:"wallet_connectors.rainbow.qr_code.step1.title"},{description:"wallet_connectors.rainbow.qr_code.step2.description",step:"create",title:"wallet_connectors.rainbow.qr_code.step2.title"},{description:"wallet_connectors.rainbow.qr_code.step3.description",step:"scan",title:"wallet_connectors.rainbow.qr_code.step3.title"}]}}:void 0}}}},safeWallet=({chains:e,...t})=>
1080({id:"safe",name:"Safe",iconAccent:"#12ff80",iconBackground:"#fff",iconUrl:async()=>(await n.e(514).then(n.bind(n,60514))).default,installed:"undefined"!=typeof window&&(null==window?void 0:window.parent)!==window,downloadUrls:{},createConnector:()=>({connector:new eL({chains:e,options:t})})}),walletConnectWallet=({chains:e,options:t,projectId:o,version:i="2"})=>({id:"walletConnect",name:"WalletConnect",iconUrl:async()=>(await n.e(3525).then(n.bind(n,33525))).default,iconBackground:"#3b99fc",createConnector:()=>{let n=isIOS(),s="1"===i?getWalletConnectConnector({version:"1",chains:e,options:{qrcode:n,...t}}):getWalletConnectConnector({version:"2",chains:e,projectId:o,options:{showQrModal:n,...t}}),getUri=async()=>getWalletConnectUri(s,i);return{connector:s,...n?{}:{mobile:{getUri},qrCode:{getUri}}}}}),getDefaultWallets=({appName:e,chains:t,projectId:n})=>{let o=[{groupName:"Popular",wallets:[injectedWallet({chains:t}),safeWallet({chains:t}),rainbowWallet({chains:t,projectId:n}),coinbaseWallet({appName:e,chains:t}),metaMaskWallet({chains:t,projectId:n}),walletConnectWallet({chains:t,projectId:n}),braveWallet({chains:t})]}];return{connectors:"groupName"in o[0]?_connectorsForWallets(o):_connectorsForWallets([{groupName:"",wallets:o}])(),wallets:o}}},53516:function(e,t,n){"use strict";function normalizeChainId(e){return"string"==typeof e?Number.parseInt(e,"0x"===e.trim().substring(0,2)?16:10):"bigint"==typeof e?Number(e):e}n.d(t,{J:function(){return normalizeChainId}})},92219:function(e,t,n){"use strict";n.d(t,{_:function(){return u}});var o,i=n(57858),s=n(53516),c=n(53324),l=n(34723),u=class extends c.wR{constructor({chains:e,options:t}={}
1080){let n={shimDisconnect:!0,getProvider(){if("undefined"==typeof window)return;let e=window.ethereum;return e?.providers&&e.providers.length>0?e.providers[0]:e},...t};super({chains:e,options:n}),this.id="injected",(0,c.Ko)(this,o,void 0),this.shimDisconnectKey=`${this.id}.shimDisconnect`,this.onAccountsChanged=e=>{0===e.length?this.emit("disconnect"):this.emit("change",{account:(0,l.Kn9)(e[0])})},this.onChainChanged=e=>{let t=(0,s.J)(e),n=this.isChainUnsupported(t);this.emit("change",{chain:{id:t,unsupported:n}})},this.onDisconnect=async e=>{if(1013===e.code){let e=await this.getProvider();if(e){let e=await this.getAccount();if(e)return}}this.emit("disconnect"),this.options.shimDisconnect&&this.storage?.removeItem(this.shimDisconnectKey)};let i=n.getProvider();if("string"==typeof n.name)this.name=n.name;else if(i){let e=function(e){if(!e)return"Injected";let getName=e=>e.isApexWallet?"Apex Wallet":e.isAvalanche?"Core Wallet":e.isBackpack?"Backpack":e.isBifrost?"Bifrost Wallet":e.isBitKeep?"BitKeep":e.isBitski?"Bitski":e.isBlockWallet?"BlockWallet":e.isBraveWallet?"Brave Wallet":e.isCoin98?"Coin98 Wallet":e.isCoinbaseWallet?"Coinbase Wallet":e.isDawn?"Dawn Wallet":e.isDefiant?"Defiant":e.isDesig?"Desig Wallet":e.isEnkrypt?"Enkrypt":e.isExodus?"Exodus":e.isFordefi?"Fordefi":e.isFrame?"Frame":e.isFrontier?"Frontier Wallet":e.isGamestop?"GameStop Wallet":e.isHaqqWallet?"HAQQ Wallet":e.isHyperPay?"HyperPay Wallet":e.isImToken?"ImToken":e.isHaloWallet?"Halo Wallet":e.isKuCoinWallet?"KuCoin Wallet":e.isMathWallet?"MathWallet":e.isNovaWallet?"Nova Wallet":e.isOkxWallet||e.isOKExWallet?"OKX Wallet":e.isOktoWallet?"Okto Wallet":e.isOneInchIOSWallet||e.isOneInchAndroidWallet?"1inch Wallet":e.isOneKey?"OneKey Wallet":e.isOpera?"Opera":e.isPhantom?"Phantom":e.isPortal?"Ripio Portal":e.isRabby?"Rabby Wallet":e.isRainbow?"Rainbow":e.isSafePal?"SafePal Wallet":e.isStatus?"Status":e.isSubWallet?"SubWallet":e.isTalisman?"Talisman":e.isTally?"Taho":e.isTokenPocket?"TokenPocket":e.isTokenary?"Tokenary":e.isTrust||e.isTrustWallet?"Trust Wallet":e.isTTWallet?"TTWallet":e.isXDEFI?"XDEFI Wallet":e.isZeal?"Zeal":e.isZerion?"Zerion":e.isMetaMask?"MetaMask":void 0;if(e.providers?.length){let t=new Set,n=1;for(let o of e.providers){let e=getName(o);e||(e=`Unknown Wallet #${n}`,n+=1),t.add(e)}let o=[...t];return o.length?o:o[0]??"Injected"}return getName(e)??"Injected"}(i);n.name?this.name=n.name(e):"string"==typeof e?this.name=e:this.name=e[0]}else this.name="Injected";this.ready=!!i}async connect({chainId:e}={}){try{let t=await this.getProvider();if(!t)throw new i.N;t.on&&(t.on("accountsChanged",this.onAccountsChanged),t.on("chainChanged",this.onChainChanged),t.on("disconnect",this.onDisconnect)),this.emit("message",{type:"connecting"});let n=await t.request({method:"eth_requestAccounts"}),o=(0,l.Kn9)(n[0]),s=await this.getChainId(),c=this.isChainUnsupported(s);if(e&&s!==e){let t=await this.switchChain(e);s=t.id,c=this.isChainUnsupported(s)}return this.options.shimDisconnect&&this.storage?.setItem(this.shimDisconnectKey,!0),{account:o,chain:{id:s,unsupported:c}}}catch(e){if(this.isUserRejectedRequestError(e))throw new l.abR(e);if(-32002===e.code)throw new l.pTd(e);throw e}}async disconnect(){let e=await this.getProvider();e?.removeListener&&(e.removeListener("accountsChanged",this.onAccountsChanged),e.removeListener("chainChanged",this.onChainChanged),e.removeListener("disconnect",this.onDisconnect),this.options.shimDisconnect&&this.storage?.removeItem(this.shimDisconnectKey))}async getAccount(){let e=await this.getProvider();if(!e)throw new i.N;let t=await e.request({method:"eth_accounts"});return(0,l.Kn9)(t[0])}async getChainId(){let e=await this.getProvider();if(!e)throw new i.N;return e.request({method:"eth_chainId"}).then(s.J)}async getProvider(){let e=this.options.getProvider();return e&&(0,c.qx)(this,o,e),(0,c.ac)(this,o)}async getWalletClient({chainId:e}={}){let[t,n]=await Promise.all([this.getProvider(),this.getAccount()]),o=this.chains.find(t=>t.id===e);if(!t)throw Error("provider is required.");return(0,l.Kwp)({account:n,chain:o,transport:(0,l.PGm)(t)})}async isAuthorized(){try{if(this.options.shimDisconnect&&!this.storage?.getItem(this.shimDisconnectKey))return!1;let e=await this.getProvider();if(!e)throw new i.N;let t=await this.getAccount();return!!t}catch{return!1}}async switchChain(e){let t=await this.getProvider();if(!t)throw new i.N;let n=(0,l.eCs)(e);try{return await Promise.all([t.request({method:"wallet_switchEthereumChain",params:[{chainId:n}]}),new Promise(t=>this.on("change",({chain:n})=>{n?.id===e&&t()}))]),this.chains.find(t=>
1080t.id===e)??{id:e,name:`Chain ${n}`,network:`${n}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}}}catch(s){let o=this.chains.find(t=>t.id===e);if(!o)throw new i.B({chainId:e,connectorId:this.id});if(4902===s.code||s?.data?.originalError?.code===4902)try{await t.request({method:"wallet_addEthereumChain",params:[{chainId:n,chainName:o.name,nativeCurrency:o.nativeCurrency,rpcUrls:[o.rpcUrls.public?.http[0]??""],blockExplorerUrls:this.getBlockExplorerUrls(o)}]});let i=await this.getChainId();if(i!==e)throw new l.abR(Error("User rejected switch after adding network."));return o}catch(e){throw new l.abR(e)}if(this.isUserRejectedRequestError(s))throw new l.abR(s);throw new l.x3p(s)}}async watchAsset({address:e,decimals:t=18,image:n,symbol:o}){let s=await this.getProvider();if(!s)throw new i.N;return s.request({method:"wallet_watchAsset",params:{type:"ERC20",options:{address:e,decimals:t,image:n,symbol:o}}})}isUserRejectedRequestError(e){return 4001===e.code}};o=new WeakMap},57858:function(e,t,n){"use strict";n.d(t,{B:function(){return o},N:function(){return i}});var o=class extends Error{constructor({chainId:e,connectorId:t}){super(`Chain "${e}" not configured for connector "${t}".`),this.name="ChainNotConfiguredForConnectorError"}},i=class extends Error{constructor(){super(...arguments),this.name="ConnectorNotFoundError",this.message="Connector not found"}}},53324:function(e,t,n){"use strict";n.d(t,{Ko:function(){return __privateAdd},U9:function(){return __privateMethod},ac:function(){return __privateGet},qx:function(){return __privateSet},wR:function(){return s}});var o=n(26729),i=n(81782),__accessCheck=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},__privateGet=(e,t,n)=>(__accessCheck(e,t,"read from private field"),n?n.call(e):t.get(e)),__privateAdd=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},__privateSet=(e,t,n,o)=>(__accessCheck(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),__privateMethod=(e,t,n)=>(__accessCheck(e,t,"access private method"),n),s=class extends o{constructor({chains:e=[i.RJ,i.ws],options:t}){super(),this.chains=e,this.options=t}getBlockExplorerUrls(e){let{default:t,...n}=e.blockExplorers??{};if(t)return[t.url,...Object.values(n).map(e=>e.url)]}isChainUnsupported(e){return!this.chains.some(t=>t.id===e)}setStorage(e){this.storage=e}}},60481:function(e,t,n){"use strict";n.d(t,{QB:function(){return configureChains},$j:function(){return connect},_g:function(){return createConfig},o6:function(){return createStorage},vZ:function(){return function deepEqual(e,t){if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){let n,o;if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)&&Array.isArray(t)){if((n=e.length)!=t.length)return!1;for(o=n;0!=o--;)if(!deepEqual(e[o],t[o]))return!1;return!0}if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();let i=Object.keys(e);if((n=i.length)!==Object.keys(t).length)return!1;for(o=n;0!=o--;)if(!Object.prototype.hasOwnProperty.call(t,i[o]))return!1;for(o=n;0!=o--;){let n=i[o];if(n&&!deepEqual(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}},zP:function(){return disconnect},em:function(){return _},EG:function(){return fetchBalance},RQ:function(){return fetchBlockNumber},w6:function(){return fetchEnsAvatar},Lk:function(){return fetchEnsName},D0:function(){return getAccount},Hy:function(){return getNetwork},uV:function(){return getPublicClient},gY:function(){return getSendTransactionParameters},jr:function(){return getWebSocketPublicClient},wp:function(){return E},a4:function(){return readContract},l:function(){return signMessage},If:function(){return switchNetwork},Mn:function(){return waitForTransaction},uH:function(){return watchAccount},QC:function(){return watchNetwork},pC:function(){return watchPublicClient},fq:function(){return watchWebSocketPublicClient},n9:function(){return writeContract}});var o,i,s,c,l,u=n(92219),__accessCheck=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},__privateGet=(e,t,n)=>(__accessCheck(e,t,"read from private field"),n?n.call(e):t.get(e)),__privateAdd=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},__privateSet=(e,t,n,o)=>(__accessCheck(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),__privateMethod=(e,t,n)=>(__accessCheck(e,t,"access private method"),n),d=n(34723),p=n(57858);let subscribeWithSelector=e=>(t,n,o)=>{let i=o.subscribe;
1080o.subscribe=(e,t,n)=>{let s=e;if(t){let i=(null==n?void 0:n.equalityFn)||Object.is,c=e(o.getState());s=n=>{let o=e(n);if(!i(c,o)){let e=c;t(c=o,e)}},(null==n?void 0:n.fireImmediately)&&t(c,c)}return i(s)};let s=e(t,n,o);return s},toThenable=e=>t=>{try{let n=e(t);if(n instanceof Promise)return n;return{then:e=>toThenable(e)(n),catch(e){return this}}}catch(e){return{then(e){return this},catch:t=>toThenable(t)(e)}}},oldImpl=(e,t)=>(n,o,i)=>{let s,c,l={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},u=!1,d=new Set,p=new Set;try{s=l.getStorage()}catch(e){}if(!s)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${l.name}', the given storage is currently unavailable.`),n(...e)},o,i);let m=toThenable(l.serialize),setItem=()=>{let e;let t=l.partialize({...o()}),n=m({state:t,version:l.version}).then(e=>s.setItem(l.name,e)).catch(t=>{e=t});if(e)throw e;return n},b=i.setState;i.setState=(e,t)=>{b(e,t),setItem()};let g=e((...e)=>{n(...e),setItem()},o,i),hydrate=()=>{var e;if(!s)return;u=!1,d.forEach(e=>e(o()));let t=(null==(e=l.onRehydrateStorage)?void 0:e.call(l,o()))||void 0;return toThenable(s.getItem.bind(s))(l.name).then(e=>{if(e)return l.deserialize(e)}).then(e=>{if(e){if("number"!=typeof e.version||e.version===l.version)return e.state;if(l.migrate)return l.migrate(e.state,e.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}}).then(e=>{var t;return n(c=l.merge(e,null!=(t=o())?t:g),!0),setItem()}).then(()=>{null==t||t(c,void 0),u=!0,p.forEach(e=>e(c))}).catch(e=>{null==t||t(void 0,e)})};return i.persist={setOptions:e=>{l={...l,...e},e.getStorage&&(s=e.getStorage())},clearStorage:()=>{null==s||s.removeItem(l.name)},getOptions:()=>l,rehydrate:()=>hydrate(),hasHydrated:()=>u,onHydrate:e=>(d.add(e),()=>{d.delete(e)}),onFinishHydration:e=>(p.add(e),()=>{p.delete(e)})},hydrate(),c||g},newImpl=(e,t)=>(n,o,i)=>{let s,c={storage:function(e,t){let n;try{n=e()}catch(e){return}return{getItem:e=>{var o;let parse=e=>null===e?null:JSON.parse(e,null==t?void 0:t.reviver),i=null!=(o=n.getItem(e))?o:null;return i instanceof Promise?i.then(parse):parse(i)},setItem:(e,o)=>n.setItem(e,JSON.stringify(o,null==t?void 0:t.replacer)),removeItem:e=>n.removeItem(e)}}(()=>localStorage),partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},l=!1,u=new Set,d=new Set,p=c.storage;if(!p)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${c.name}', the given storage is currently unavailable.`),n(...e)},o,i);let setItem=()=>{let e=c.partialize({...o()});return p.setItem(c.name,{state:e,version:c.version})},m=i.setState;i.setState=(e,t)=>{m(e,t),setItem()};let b=e((...e)=>{n(...e),setItem()},o,i);i.getInitialState=()=>b;let hydrate=()=>{var e,t;if(!p)return;l=!1,u.forEach(e=>{var t;return e(null!=(t=o())?t:b)});let i=(null==(t=c.onRehydrateStorage)?void 0:t.call(c,null!=(e=o())?e:b))||void 0;return toThenable(p.getItem.bind(p))(c.name).then(e=>{if(e){if("number"!=typeof e.version||e.version===c.version)return e.state;if(c.migrate)return c.migrate(e.state,e.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}}).then(e=>{var t;return n(s=c.merge(e,null!=(t=o())?t:b),!0),setItem()}).then(()=>{null==i||i(s,void 0),s=o(),l=!0,d.forEach(e=>e(s))}).catch(e=>{null==i||i(void 0,e)})};return i.persist={setOptions:e=>{c={...c,...e},e.storage&&(p=e.storage)},clearStorage:()=>{null==p||p.removeItem(c.name)},getOptions:()=>c,rehydrate:()=>hydrate(),hasHydrated:()=>l,onHydrate:e=>(u.add(e),()=>{u.delete(e)}),onFinishHydration:e=>(d.add(e),()=>{d.delete(e)})},c.skipHydration||hydrate(),s||b},persist=(e,t)=>"getStorage"in t||"serialize"in t||"deserialize"in t?(console.warn("[DEPRECATED] `getStorage`, `serialize` and `deserialize` options are deprecated. Use `storage` option instead."),oldImpl(e,t)):newImpl(e,t),createStoreImpl=e=>{let t;let n=new Set,setState=(e,o)=>{let i="function"==typeof e?e(t):e;if(!Object.is(i,t)){let e=t;t=(null!=o?o:"object"!=typeof i||null===i)?i:Object.assign({}
1080,t,i),n.forEach(n=>n(t,e))}},getState=()=>t,o={setState,getState,getInitialState:()=>i,subscribe:e=>(n.add(e),()=>n.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},i=t=e(setState,getState,o);return o},createStore=e=>e?createStoreImpl(e):createStoreImpl;function shallow$1(e,t){if(Object.is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(let[n,o]of e)if(!Object.is(o,t.get(n)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let o of n)if(!Object.prototype.hasOwnProperty.call(t,o)||!Object.is(e[o],t[o]))return!1;return!0}function configureChains(e,t,{batch:n={multicall:{wait:32}},pollingInterval:o=4e3,rank:i,retryCount:s,retryDelay:c,stallTimeout:l}={}){if(!e.length)throw Error("must have at least one chain");let u=[],p={},m={};for(let n of e){let e=!1;for(let o of t){let t=o(n);t&&(e=!0,u.some(({id:e})=>e===n.id)||(u=[...u,t.chain]),p[n.id]=[...p[n.id]||[],...t.rpcUrls.http],t.rpcUrls.webSocket&&(m[n.id]=[...m[n.id]||[],...t.rpcUrls.webSocket]))}if(!e)throw Error(`Could not find valid provider configuration for chain "${n.name}".
1081
1082You may need to add \`jsonRpcProvider\` to \`configureChains\` with the chain's RPC URLs.
1083Read more: https://wagmi.sh/core/providers/jsonRpc`)}return{chains:u,publicClient:({chainId:t})=>{let m=u.find(e=>e.id===t)??e[0],b=p[m.id];if(!b||!b[0])throw Error(`No providers configured for chain "${m.id}"`);let g=(0,d.vvc)({batch:n,chain:m,transport:(0,d.tvc)(b.map(e=>(0,d.dJM)(e,{timeout:l})),{rank:i,retryCount:s,retryDelay:c}),pollingInterval:o});return Object.assign(g,{chains:u})},webSocketPublicClient:({chainId:t})=>{let p=u.find(e=>e.id===t)??e[0],b=m[p.id];if(!b||!b[0])return;let g=(0,d.vvc)({batch:n,chain:p,transport:(0,d.tvc)(b.map(e=>(0,d.jZ)(e,{timeout:l})),{rank:i,retryCount:s,retryDelay:c}),pollingInterval:o});return Object.assign(g,{chains:u})}}}var m=class extends Error{constructor({activeChain:e,targetChain:t}){super(`Chain mismatch: Expected "${t}", received "${e}".`),this.name="ChainMismatchError"}},b=class extends Error{constructor({chainId:e,connectorId:t}){super(`Chain "${e}" not configured${t?` for connector "${t}"`:""}.`),this.name="ChainNotConfigured"}},g=class extends Error{constructor(){super(...arguments),this.name="ConnectorAlreadyConnectedError",this.message="Connector already connected"}},y=class extends Error{constructor(){super(...arguments),this.name="ConfigChainsNotFound",this.message="No chains were found on the wagmi config. Some functions that require a chain may not work."}},v=class extends Error{constructor({connector:e}){super(`"${e.name}" does not support programmatic chain switching.`),this.name="SwitchChainNotSupportedError"}},findAndReplace=(e,{find:t,replace:n})=>e&&t(e)?n(e):"object"!=typeof e?e:Array.isArray(e)?e.map(e=>findAndReplace(e,{find:t,replace:n})):e instanceof Object?Object.entries(e).reduce((e,[o,i])=>({...e,[o]:findAndReplace(i,{find:t,replace:n})}),{}):e;function deserialize(e){let t=JSON.parse(e),n=findAndReplace(t,{find:e=>"string"==typeof e&&e.startsWith("#bigint."),replace:e=>BigInt(e.replace("#bigint.",""))});return n}function getSendTransactionParameters(e){return{accessList:e.accessList,account:e.account,data:e.data,gas:e.gas,gasPrice:e.gasPrice,maxFeePerGas:e.maxFeePerGas,maxPriorityFeePerGas:e.maxPriorityFeePerGas,nonce:e.nonce,to:e.to,value:e.value}}function getUnit(e){return"number"==typeof e?e:"wei"===e?0:Math.abs(d.Bd4[e])}function getReferenceKey(e,t){return e.slice(0,t).join(".")||"."}function getCutoff(e,t){let{length:n}=e;for(let o=0;o<n;++o)if(e[o]===t)return o+1;return 0}function serialize(e,t,n,o){return JSON.stringify(e,function(e,t){let n="function"==typeof e,o="function"==typeof t,i=[],s=[];return function(c,l){if("object"==typeof l){if(i.length){let e=getCutoff(i,this);0===e?i[i.length]=this:(i.splice(e),s.splice(e)),s[s.length]=c;let n=getCutoff(i,l);if(0!==n)return o?t.call(this,c,l,getReferenceKey(s,n)):`[ref=${getReferenceKey(s,n)}]`}else i[0]=l,s[0]=c}return n?e.call(this,c,l):l}}((e,n)=>{let o="bigint"==typeof n?`#bigint.${n.toString()}`:n;return t?.(e,o)||o},o),n??void 0)}var E={getItem:e=>"",setItem:(e,t)=>
1083null,removeItem:e=>null};function createStorage({deserialize:e=deserialize,key:t="wagmi",serialize:n=serialize,storage:o}){return{...o,getItem:(n,i=null)=>{let s=o.getItem(`${t}.${n}`);try{return s?e(s):i}catch(e){return console.warn(e),i}},setItem:(e,i)=>{if(null===i)o.removeItem(`${t}.${e}`);else try{o.setItem(`${t}.${e}`,n(i))}catch(e){console.error(e)}},removeItem:e=>o.removeItem(`${t}.${e}`)}}var x="store",P=class{constructor({autoConnect:e=!1,connectors:t=[new u._],publicClient:n,storage:l=createStorage({storage:"undefined"!=typeof window?window.localStorage:E}),logger:d={warn:console.warn},webSocketPublicClient:p}){let m;__privateAdd(this,s),this.publicClients=new Map,this.webSocketPublicClients=new Map,__privateAdd(this,o,void 0),__privateAdd(this,i,void 0),this.args={autoConnect:e,connectors:t,logger:d,publicClient:n,storage:l,webSocketPublicClient:p};let b="disconnected";if(e)try{let e=l.getItem(x),t=e?.state?.data;b=t?.account?"reconnecting":"connecting",m=t?.chain?.id}catch(e){}let g="function"==typeof t?t():t;g.forEach(e=>e.setStorage(l)),this.store=createStore(subscribeWithSelector(persist(()=>({connectors:g,publicClient:this.getPublicClient({chainId:m}),status:b,webSocketPublicClient:this.getWebSocketPublicClient({chainId:m})}),{name:x,storage:l,partialize:t=>({...e&&{data:{account:t?.data?.account,chain:t?.data?.chain}},chains:t?.chains}),version:2}))),this.storage=l,__privateSet(this,i,l?.getItem("wallet")),__privateMethod(this,s,c).call(this),e&&"undefined"!=typeof window&&setTimeout(async()=>await this.autoConnect(),0)}get chains(){return this.store.getState().chains}get connectors(){return this.store.getState().connectors}get connector(){return this.store.getState().connector}get data(){return this.store.getState().data}get error(){return this.store.getState().error}get lastUsedChainId(){return this.data?.chain?.id}get publicClient(){return this.store.getState().publicClient}get status(){return this.store.getState().status}get subscribe(){return this.store.subscribe}get webSocketPublicClient(){return this.store.getState().webSocketPublicClient}setState(e){let t="function"==typeof e?e(this.store.getState()):e;this.store.setState(t,!0)}clearState(){this.setState(e=>({...e,chains:void 0,connector:void 0,data:void 0,error:void 0,status:"disconnected"}))}async destroy(){this.connector&&await this.connector.disconnect?.(),__privateSet(this,o,!1),this.clearState(),this.store.destroy()}async autoConnect(){if(__privateGet(this,o))return;__privateSet(this,o,!0),this.setState(e=>({...e,status:e.data?.account?"reconnecting":"connecting"}));let e=__privateGet(this,i)?[...this.connectors].sort(e=>e.id===__privateGet(this,i)?-1:1):this.connectors,t=!1;for(let n of e){if(!n.ready||!n.isAuthorized)continue;let e=await n.isAuthorized();if(!e)continue;let o=await n.connect();this.setState(e=>({...e,connector:n,chains:n?.chains,data:o,status:"connected"})),t=!0;break}return t||this.setState(e=>({...e,data:void 0,status:"disconnected"})),__privateSet(this,o,!1),this.data}setConnectors(e){this.args={...this.args,connectors:e};let t="function"==typeof e?e():e;t.forEach(e=>e.setStorage(this.args.storage)),this.setState(e=>({...e,connectors:t}))}getPublicClient({chainId:e}={}){let t=this.publicClients.get(-1);if(t&&t?.chain.id===e||(t=this.publicClients.get(e??-1)))return t;let{publicClient:n}=this.args;return t="function"==typeof n?n({chainId:e}):n,this.publicClients.set(e??-1,t),t}setPublicClient(e){let t=this.data?.chain?.id;this.args={...this.args,publicClient:e},this.publicClients.clear(),this.setState(e=>({...e,publicClient:this.getPublicClient({chainId:t})}))}getWebSocketPublicClient({chainId:e}={}){let t=this.webSocketPublicClients.get(-1);if(t&&t?.chain.id===e||(t=this.webSocketPublicClients.get(e??-1)))return t;let{webSocketPublicClient:n}=this.args;return(t="function"==typeof n?n({chainId:e}):n)&&this.webSocketPublicClients.set(e??-1,t),t}setWebSocketPublicClient(e){let t=this.data?.chain?.id;this.args={...this.args,webSocketPublicClient:e},this.webSocketPublicClients.clear(),this.setState(e=>({...e,webSocketPublicClient:this.getWebSocketPublicClient({chainId:t})}))}setLastUsedConnector(e=null){this.storage?.setItem("wallet",e)}};function createConfig(e){let t=new P(e);return l=t,t}function getConfig(){if(!l)throw Error("No wagmi config found. Ensure you have set up a config: https://wagmi.sh/react/config");return l}async function connect({chainId:e,connector:t}){let n=getConfig(),o=n.connector;if(o&&t.id===o.id)throw new g;try{n.setState(e=>({...e,status:"connecting"}));let o=await t.connect({chainId:e});return n.setLastUsedConnector(t.id),n.setState(e=>({...e,connector:t,chains:t?.chains,data:o,status:"connected"})),n.storage.setItem("connected",!0),{...o,connector:t}}catch(e){throw n.setState(e=>({...e,status:e.connector?"connected":"disconnected"})),e}}async function disconnect(){let e=getConfig();e.connector&&await e.connector.disconnect(),e.clearState(),e.storage.removeItem("connected")}o=new WeakMap,i=new WeakMap,s=new WeakSet,c=function(){let onChange=e=>{this.setState(t=>({...t,data:{...t.data,...e}}))},onDisconnect=()=>{this.clearState()},onError=e=>{this.setState(t=>({...t,error:e}))};this.store.subscribe(({connector:e})=>e,(e,t)=>
1083{t?.off?.("change",onChange),t?.off?.("disconnect",onDisconnect),t?.off?.("error",onError),e&&(e.on?.("change",onChange),e.on?.("disconnect",onDisconnect),e.on?.("error",onError))});let{publicClient:e,webSocketPublicClient:t}=this.args;("function"==typeof e||"function"==typeof t)&&this.store.subscribe(({data:e})=>e?.chain?.id,e=>{this.setState(t=>({...t,publicClient:this.getPublicClient({chainId:e}),webSocketPublicClient:this.getWebSocketPublicClient({chainId:e})}))})};var _=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"function",name:"allowance",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"approve",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{name:"",type:"uint8"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{name:"",type:"string"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{name:"",type:"string"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"transfer",stateMutability:"nonpayable",inputs:[{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]},{type:"function",name:"transferFrom",stateMutability:"nonpayable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]}],I=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"function",name:"allowance",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"approve",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{name:"",type:"uint8"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{name:"",type:"bytes32"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{name:"",type:"bytes32"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{name:"",type:"uint256"}]},{type:"function",name:"transfer",stateMutability:"nonpayable",inputs:[{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]},{type:"function",name:"transferFrom",stateMutability:"nonpayable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]}];function getPublicClient({chainId:e}={}){let t=getConfig();return e&&t.getPublicClient({chainId:e})||t.publicClient}async function getWalletClient({chainId:e}={}){let t=getConfig(),n=await t.connector?.getWalletClient?.({chainId:e})||null;return n}function getWebSocketPublicClient({chainId:e}={}){let t=getConfig();return e&&t.getWebSocketPublicClient({chainId:e})||t.webSocketPublicClient}function watchPublicClient(e,t){let n=getConfig(),handleChange=async()=>t(getPublicClient(e)),o=n.subscribe(({publicClient:e})=>e,handleChange);return o}function watchWebSocketPublicClient(e,t){let n=getConfig(),handleChange=async()=>t(getWebSocketPublicClient(e)),o=n.subscribe(({webSocketPublicClient:e})=>e,handleChange);return o}async function prepareWriteContract({abi:e,address:t,args:n,chainId:o,dataSuffix:i,functionName:s,walletClient:c,...l}){let u=getPublicClient({chainId:o}),d=c??await getWalletClient({chainId:o});if(!d)throw new p.N;o&&assertActiveChain({chainId:o});let{account:m,accessList:b,blockNumber:g,blockTag:y,gas:v,gasPrice:E,maxFeePerGas:x,maxPriorityFeePerGas:P,nonce:_,value:I}={accessList:l.accessList,account:l.account,blockNumber:l.blockNumber,blockTag:l.blockTag,data:l.data,gas:l.gas,gasPrice:l.gasPrice,maxFeePerGas:l.maxFeePerGas,maxPriorityFeePerGas:l.maxPriorityFeePerGas,nonce:l.nonce,to:l.to,value:l.value},{result:j,request:R}=await u.simulateContract({abi:e,address:t,functionName:s,args:n,account:m||d.account,accessList:b,blockNumber:g,blockTag:y,dataSuffix:i,gas:v,gasPrice:E,maxFeePerGas:x,maxPriorityFeePerGas:P,nonce:_,value:I}),M=e.filter(e=>"name"in e&&e.name===s);return{mode:"prepared",request:{...R,abi:M,chainId:o},result:j}}async function multicall({chainId:e,contracts:t,blockNumber:n,blockTag:o,...i}){let s=getPublicClient({chainId:e});if(!s.chains)throw new y;if(e&&s.chain.id!==e)throw new b({chainId:e});
1083return s.multicall({allowFailure:i.allowFailure??!0,blockNumber:n,blockTag:o,contracts:t})}async function readContract({address:e,account:t,chainId:n,abi:o,args:i,functionName:s,blockNumber:c,blockTag:l}){let u=getPublicClient({chainId:n});return u.readContract({abi:o,address:e,account:t,functionName:s,args:i,blockNumber:c,blockTag:l})}async function readContracts({contracts:e,blockNumber:t,blockTag:n,...o}){let{allowFailure:i=!0}=o;try{let o=getPublicClient(),s=e.reduce((e,t,n)=>{let i=t.chainId??o.chain.id;return{...e,[i]:[...e[i]||[],{contract:t,index:n}]}},{}),c=(await Promise.all(Object.entries(s).map(([e,o])=>multicall({allowFailure:i,chainId:parseInt(e),contracts:o.map(({contract:e})=>e),blockNumber:t,blockTag:n})))).flat(),l=Object.values(s).flatMap(e=>e.map(({index:e})=>e));return c.reduce((e,t,n)=>(e&&(e[l[n]]=t),e),[])}catch(o){if(o instanceof d.uqH)throw o;let promises=()=>e.map(e=>readContract({...e,blockNumber:t,blockTag:n}));if(i)return(await Promise.allSettled(promises())).map(e=>"fulfilled"===e.status?{result:e.value,status:"success"}:{error:e.reason,result:void 0,status:"failure"});return await Promise.all(promises())}}async function writeContract(e){let t;let n=await getWalletClient({chainId:e.chainId});if(!n)throw new p.N;if(e.chainId&&assertActiveChain({chainId:e.chainId}),"prepared"===e.mode)t=e.request;else{let{chainId:n,mode:o,...i}=e,s=await prepareWriteContract(i);t=s.request}let o=await n.writeContract({...t,chain:e.chainId?{id:e.chainId}:null});return{hash:o}}async function fetchBalance({address:e,chainId:t,formatUnits:n,token:o}){let i=getConfig(),s=getPublicClient({chainId:t});if(o){let fetchContractBalance=async({abi:i})=>{let s={abi:i,address:o,chainId:t},[c,l,u]=await readContracts({allowFailure:!1,contracts:[{...s,functionName:"balanceOf",args:[e]},{...s,functionName:"decimals"},{...s,functionName:"symbol"}]});return{decimals:l,formatted:(0,d.bMU)(c??"0",getUnit(n??l)),symbol:u,value:c}};try{return await fetchContractBalance({abi:_})}catch(e){if(e instanceof d.uqH){let{symbol:e,...t}=await fetchContractBalance({abi:I});return{symbol:(0,d.rRt)((0,d.fyY)(e,{dir:"right"})),...t}}throw e}}let c=[...i.publicClient.chains||[],...i.chains??[]],l=await s.getBalance({address:e}),u=c.find(e=>e.id===s.chain.id);return{decimals:u?.nativeCurrency.decimals??18,formatted:(0,d.bMU)(l??"0",getUnit(n??18)),symbol:u?.nativeCurrency.symbol??"ETH",value:l}}function getAccount(){let{data:e,connector:t,status:n}=getConfig();switch(n){case"connected":return{address:e?.account,connector:t,isConnected:!0,isConnecting:!1,isDisconnected:!1,isReconnecting:!1,status:n};case"reconnecting":return{address:e?.account,connector:t,isConnected:!!e?.account,isConnecting:!1,isDisconnected:!1,isReconnecting:!0,status:n};case"connecting":return{address:e?.account,connector:t,isConnected:!1,isConnecting:!0,isDisconnected:!1,isReconnecting:!1,status:n};case"disconnected":return{address:void 0,connector:void 0,isConnected:!1,isConnecting:!1,isDisconnected:!0,isReconnecting:!1,status:n}}}function getNetwork(){let e=getConfig(),t=e.data?.chain?.id,n=e.chains??[],o=[...e.publicClient?.chains||[],...n].find(e=>e.id===t)??{id:t,name:`Chain ${t}`,network:`${t}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}};return{chain:t?{...o,...e.data?.chain,id:t}:void 0,chains:n}}async function signMessage(e){let t=await getWalletClient();if(!t)throw new p.N;return await t.signMessage({message:e.message})}async function switchNetwork({chainId:e}){let{connector:t}=getConfig();if(!t)throw new p.N;if(!t.switchChain)throw new v({connector:t});return t.switchChain(e)}function watchAccount(e,{selector:t=e=>e}={}){let n=getConfig(),o=n.subscribe(({data:e,connector:n,status:o})=>t({address:e?.account,connector:n,status:o}),()=>e(getAccount()),{equalityFn:shallow$1});return o}function watchNetwork(e,{selector:t=e=>e}={}){let n=getConfig(),o=n.subscribe(({data:e,chains:n})=>t({chainId:e?.chain?.id,chains:n}),()=>e(getNetwork()),{equalityFn:shallow$1});return o}async function fetchEnsAvatar({name:e,chainId:t}){let{normalize:o}=await n.e(1582).then(n.bind(n,61582)),i=getPublicClient({chainId:t}),s=await i.getEnsAvatar({name:o(e)});return s}async function fetchEnsName({address:e,chainId:t}){let n=getPublicClient({chainId:t});return n.getEnsName({address:(0,d.Kn9)(e)})}async function fetchBlockNumber({chainId:e}={}){let t=getPublicClient({chainId:e}),n=await t.getBlockNumber();return n}async function waitForTransaction({chainId:e,confirmations:t=1,hash:n,onReplaced:o,timeout:i=0}){let s=getPublicClient({chainId:e}),c=await s.waitForTransactionReceipt({hash:n,confirmations:t,onReplaced:o,timeout:i});if("reverted"===c.status){let e=await s.getTransaction({hash:c.transactionHash}
1083),t=await s.call({...e,gasPrice:"eip1559"!==e.type?e.gasPrice:void 0,maxFeePerGas:"eip1559"===e.type?e.maxFeePerGas:void 0,maxPriorityFeePerGas:"eip1559"===e.type?e.maxPriorityFeePerGas:void 0}),n=(0,d.rRt)(`0x${t.substring(138)}`);throw Error(n)}return c}function assertActiveChain({chainId:e}){let{chain:t,chains:n}=getNetwork(),o=t?.id;if(o&&e!==o)throw new m({activeChain:n.find(e=>e.id===o)?.name??`Chain ${o}`,targetChain:n.find(t=>t.id===e)?.name??`Chain ${e}`})}},45139:function(e,t,n){"use strict";n.d(t,{j:function(){return cva}});let falsyToString=e=>"boolean"==typeof e?"".concat(e):0===e?"0":e,cx=function(){for(var e,t,n=0,o="";n<arguments.length;)(e=arguments[n++])&&(t=function r(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e){if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=r(e[t]))&&(o&&(o+=" "),o+=n);else for(t in e)e[t]&&(o&&(o+=" "),o+=t)}return o}(e))&&(o&&(o+=" "),o+=t);return o},cva=(e,t)=>n=>{var o;if((null==t?void 0:t.variants)==null)return cx(e,null==n?void 0:n.class,null==n?void 0:n.className);let{variants:i,defaultVariants:s}=t,c=Object.keys(i).map(e=>{let t=null==n?void 0:n[e],o=null==s?void 0:s[e];if(null===t)return null;let c=falsyToString(t)||falsyToString(o);return i[e][c]}),l=n&&Object.entries(n).reduce((e,t)=>{let[n,o]=t;return void 0===o||(e[n]=o),e},{}),u=null==t?void 0:null===(o=t.compoundVariants)||void 0===o?void 0:o.reduce((e,t)=>{let{class:n,className:o,...i}=t;return Object.entries(i).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...s,...l}[t]):({...s,...l})[t]===n})?[...e,n,o]:e},[]);return cx(e,c,u,null==n?void 0:n.class,null==n?void 0:n.className)}},90512:function(e,t,n){"use strict";function clsx(){for(var e,t,n=0,o="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=function r(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e){if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=r(e[t]))&&(o&&(o+=" "),o+=n)}else for(n in e)e[n]&&(o&&(o+=" "),o+=n)}return o}(e))&&(o&&(o+=" "),o+=t);return o}n.d(t,{W:function(){return clsx}}),t.Z=clsx},54943:function(e,t,n){"use strict";n.r(t),n.d(t,{WebSocket:function(){return o}});let o=function(){if("undefined"!=typeof WebSocket)return WebSocket;if(void 0!==global.WebSocket)return global.WebSocket;if(void 0!==window.WebSocket)return window.WebSocket;if(void 0!==self.WebSocket)return self.WebSocket;throw Error("`WebSocket` is not supported in this environment")}()},97582:function(e,t,n){"use strict";n.r(t),n.d(t,{__addDisposableResource:function(){return __addDisposableResource},__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldIn:function(){return __classPrivateFieldIn},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return o},__decorate:function(){return __decorate},__disposeResources:function(){return __disposeResources},__esDecorate:function(){return __esDecorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar}
vendor: 10,384 bytes, line 1083
1083,__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__propKey:function(){return __propKey},__read:function(){return __read},__rest:function(){return __rest},__runInitializers:function(){return __runInitializers},__setFunctionName:function(){return __setFunctionName},__spread:function(){return __spread},__spreadArray:function(){return __spreadArray},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});var extendStatics=function(e,t){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function __extends(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function __(){this.constructor=e}extendStatics(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __rest(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&0>t.indexOf(o)&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,o=Object.getOwnPropertySymbols(e);i<o.length;i++)0>t.indexOf(o[i])&&Object.prototype.propertyIsEnumerable.call(e,o[i])&&(n[o[i]]=e[o[i]]);return n}function __decorate(e,t,n,o){var i,s=arguments.length,c=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)c=Reflect.decorate(e,t,n,o);else for(var l=e.length-1;l>=0;l--)(i=e[l])&&(c=(s<3?i(c):s>3?i(t,n,c):i(t,n))||c);return s>3&&c&&Object.defineProperty(t,n,c),c}function __param(e,t){return function(n,o){t(n,o,e)}}function __esDecorate(e,t,n,o,i,s){function accept(e){if(void 0!==e&&"function"!=typeof e)throw TypeError("Function expected");return e}for(var c,l=o.kind,u="getter"===l?"get":"setter"===l?"set":"value",d=!t&&e?o.static?e:e.prototype:null,p=t||(d?Object.getOwnPropertyDescriptor(d,o.name):{}),m=!1,b=n.length-1;b>=0;b--){var g={};for(var y in o)g[y]="access"===y?{}:o[y];for(var y in o.access)g.access[y]=o.access[y];g.addInitializer=function(e){if(m)throw TypeError("Cannot add initializers after decoration has completed");s.push(accept(e||null))};var v=(0,n[b])("accessor"===l?{get:p.get,set:p.set}:p[u],g);if("accessor"===l){if(void 0===v)continue;if(null===v||"object"!=typeof v)throw TypeError("Object expected");(c=accept(v.get))&&(p.get=c),(c=accept(v.set))&&(p.set=c),(c=accept(v.init))&&i.unshift(c)}else(c=accept(v))&&("field"===l?i.unshift(c):p[u]=c)}d&&Object.defineProperty(d,o.name,p),m=!0}function __runInitializers(e,t,n){for(var o=arguments.length>2,i=0;i<t.length;i++)n=o?t[i].call(e,n):t[i].call(e);return o?n:void 0}function __propKey(e){return"symbol"==typeof e?e:"".concat(e)}function __setFunctionName(e,t,n){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:n?"".concat(n," ",t):t})}function __metadata(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function __awaiter(e,t,n,o){return new(n||(n=Promise))(function(i,s){function fulfilled(e){try{step(o.next(e))}catch(e){s(e)}}function rejected(e){try{step(o.throw(e))}catch(e){s(e)}}function step(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(fulfilled,rejected)}step((o=o.apply(e,t||[])).next())})}function __generator(e,t){var n,o,i,s,c={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return s={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function verb(l){return function(u){return function(l){if(n)throw TypeError("Generator is already executing.");for(;s&&(s=0,l[0]&&(c=0)),c;)try{if(n=1,o&&(i=2&l[0]?o.return:l[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,l[1])).done)return i;switch(o=0,i&&(l=[2&l[0],i.value]),l[0]){case 0:case 1:i=l;break;case 4:return c.label++,{value:l[1],done:!1};case 5:c.label++,o=l[1],l=[0];continue;case 7:l=c.ops.pop(),c.trys.pop();continue;default:if(!(i=(i=c.trys).length>0&&i[i.length-1])&&(6===l[0]||2===l[0])){c=0;continue}if(3===l[0]&&(!i||l[1]>i[0]&&l[1]<i[3])){c.label=l[1];break}if(6===l[0]&&c.label<i[1]){c.label=i[1],i=l;break}if(i&&c.label<i[2]){c.label=i[2],c.ops.push(l);break}i[2]&&c.ops.pop(),c.trys.pop();continue}l=t.call(e,c)}catch(e){l=[6,e],o=0}finally{n=i=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,u])}}}var o=Object.create?function(e,t,n,o){void 0===o&&(o=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,o,i)}:function(e,t,n,o){void 0===o&&(o=n),e[o]=t[n]};function __exportStar(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||o(t,e,n)}function __values(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],o=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&o>=e.length&&(e=void 0),{value:e&&e[o++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var o,i,s=n.call(e),c=[];try{for(;(void 0===t||t-- >0)&&!(o=s.next()).done;)c.push(o.value)}catch(e){i={error:e}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}finally{if(i)throw i.error}}return c}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}function __spreadArrays(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var o=Array(e),i=0,t=0;t<n;t++)for(var s=arguments[t],c=0,l=s.length;c<l;c++,i++)o[i]=s[c];return o}function __spreadArray(e,t,n){if(n||2==arguments.length)for(var o,i=0,s=t.length;i<s;i++)!o&&i in t||(o||(o=Array.prototype.slice.call(t,0,i)),o[i]=t[i]);return e.concat(o||Array.prototype.slice.call(t))}function __await(e){return this instanceof __await?(this.v=e,this):new __await(e)}function __asyncGenerator(e,t,n){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var o,i=n.apply(e,t||[]),s=[];return o={},verb("next"),verb("throw"),verb("return"),o[Symbol.asyncIterator]=function(){return this},o;function verb(e){i[e]&&(o[e]=function(t){return new Promise(function(n,o){s.push([e,t,n,o])>1||resume(e,t)})})}function resume(e,t){try{var n;(n=i[e](t)).value instanceof __await?Promise.resolve(n.value.v).then(fulfill,reject):settle(s[0][2],n)}catch(e){settle(s[0][3],e)}}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){e(t),s.shift(),s.length&&resume(s[0][0],s[0][1])}}function __asyncDelegator(e){var t,n;return t={},verb("next"),verb("throw",function(e){throw e}),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(o,i){t[o]=e[o]?function(t){return(n=!n)?{value:__await(e[o](t)),done:!1}:i?i(t):t}:i}}function __asyncValues(e){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=__values(e),t={},verb("next"),verb("throw"),verb("return"),t[Symbol.asyncIterator]=function(){return this},t);function verb(n){t[n]=e[n]&&function(t){return new Promise(function(o,i){!function(e,t,n,o){Promise.resolve(o).then(function(t){e({value:t,done:n})},t)}(o,i,(t=e[n](t)).done,t.value)})}}}function __makeTemplateObject(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function __importStar(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return i(t,e),t}function __importDefault(e){return e&&e.__esModule?e:{default:e}}function __classPrivateFieldGet(e,t,n,o){if("a"===n&&!o)throw TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!o:!t.has(e))throw TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?o:"a"===n?o.call(e):o?o.value:t.get(e)}function __classPrivateFieldSet(e,t,n,o,i){if("m"===o)throw TypeError("Private method is not writable");if("a"===o&&!i)throw TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw TypeError("Cannot write private member to an object whose class did not declare it");return"a"===o?i.call(e,n):i?i.value=n:t.set(e,n),n}function __classPrivateFieldIn(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}function __addDisposableResource(e,t,n){if(null!=t){var o;if("object"!=typeof t&&"function"!=typeof t)throw TypeError("Object expected.");if(n){if(!Symbol.asyncDispose)throw TypeError("Symbol.asyncDispose is not defined.");o=t[Symbol.asyncDispose]}if(void 0===o){if(!Symbol.dispose)throw TypeError("Symbol.dispose is not defined.");o=t[Symbol.dispose]}if("function"!=typeof o)throw TypeError("Object not disposable.");e.stack.push({value:t,dispose:o,async:n})}else n&&e.stack.push({async:!0});return t}var s="function"==typeof SuppressedError?SuppressedError:function(e,t,n){var o=Error(n);return o.name="SuppressedError",o.error=e,o.suppressed=t,o};function __disposeResources(e){function fail(t){e.error=e.hasError?new s(t,e.error,"An error was suppressed during disposal."):t,e.hasError=!0}return function next(){for(;e.stack.length;){var t=e.stack.pop();try{var n=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(n).then(next,function(e){return fail(e),next()})}catch(e){fail(e)}}if(e.hasError)throw e.error}()}t.default={__extends,__assign,__rest,__decorate,__param,__metadata,__awaiter,__generator,__createBinding:o,__exportStar,__values,__read,__spread,__spreadArrays,__spreadArray,__await,__asyncGenerator,__asyncDelegator,__asyncValues,__makeTemplateOb
1083ject,__importStar,__importDefault,__classPrivateFieldGet,__classPrivateFieldSet,__classPrivateFieldIn,__addDisposableResource,__disposeResources}},53160:function(e,t,n){"use strict";n.d(t,{E:function(){return allocUnsafe}});var o=n(16867);function allocUnsafe(e=0){return null!=globalThis.Buffer&&null!=globalThis.Buffer.allocUnsafe?(0,o.P)(globalThis.Buffer.allocUnsafe(e)):new Uint8Array(e)}},20605:function(e,t,n){"use strict";n.d(t,{z:function(){return concat}});var o=n(53160),i=n(16867);function concat(e,t){t||(t=e.reduce((e,t)=>e+t.length,0));let n=(0,o.E)(t),s=0;for(let t of e)n.set(t,s),s+=t.length;return(0,i.P)(n)}},52217:function(e,t,n){"use strict";n.d(t,{m:function(){return fromString}});var o=n(73149),i=n(16867);function fromString(e,t="utf8"){let n=o.Z[t];if(!n)throw Error(`Unsupported encoding "${t}"`);return("utf8"===t||"utf-8"===t)&&null!=globalThis.Buffer&&null!=globalThis.Buffer.from?(0,i.P)(globalThis.Buffer.from(e,"utf-8")):n.decoder.decode(`${n.prefix}${e}`)}},37466:function(e,t,n){"use strict";n.d(t,{BB:function(){return s.B},mL:function(){return i.m},zo:function(){return o.z}});var o=n(20605),i=n(52217),s=n(92263)},92263:function(e,t,n){"use strict";n.d(t,{B:function(){return toString}});var o=n(73149);function toString(e,t="utf8"){let n=o.Z[t];if(!n)throw Error(`Unsupported encoding "${t}"`);return("utf8"===t||"utf-8"===t)&&null!=globalThis.Buffer&&null!=globalThis.Buffer.from?globalThis.Buffer.from(e.buffer,e.byteOffset,e.byteLength).toString("utf8"):n.encoder.encode(e).substring(1)}},16867:function(e,t,n){"use strict";function asUint8Array(e){return null!=globalThis.Buffer?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):e}n.d(t,{P:function(){return asUint8Array}})},73149:function(e,t,n){"use strict";n.d(t,{Z:function(){return eB}});var o={};n.r(o),n.d(o,{identity:function(){return x}});var i={};n.r(i),n.d(i,{base2:function(){return P}});var s={};n.r(s),n.d(s,{base8:function(){return _}});var c={};n.r(c),n.d(c,{base10:function(){return I}});var l={};n.r(l),n.d(l,{base16:function(){return j},base16upper:function(){return R}});var u={};n.r(u),n.d(u,{base32:function(){return M},base32hex:function(){return z},base32hexpad:function(){return K},base32hexpadupper:function(){return Q},base32hexupper:function(){return W},base32pad:function(){return q},base32padupper:function(){return H},base32upper:function(){return F},base32z:function(){return Z}});var d={};n.r(d),n.d(d,{base36:function(){return X},base36upper:function(){return Y}});var p={};n.r(p),n.d(p,{base58btc:function(){return J},base58flickr:function(){return et}});var m={};n.r(m),n.d(m,{base64:function(){return eo},base64pad:function(){return ea},base64url:function(){return ei},base64urlpad:function(){return es}});var b={};n.r(b),n.d(b,{base256emoji:function(){return ed}});var g={};n.r(g),n.d(g,{sha256:function(){return ep},sha512:function(){return eh}});var y={};n.r(y),n.d(y,{identity:function(){return em}});var v={};n.r(v),n.d(v,{code:function(){return eg},decode:function(){return raw_decode},encode:function(){return raw_encode},name:function(){return eb}});var E={};n.r(E),n.d(E,{code:function(){return eE},decode:function(){return json_decode},encode:function(){return json_encode},name:function(){return ew}});var base_x=function(e,t){if(e.length>=255)throw TypeError("Alphabet too long");for(var n=new Uint8Array(256),o=0;o<n.length;o++)n[o]=255;for(var i=0;i<e.length;i++){var s=e.charAt(i),c=s.charCodeAt(0);if(255!==n[c])throw TypeError(s+" is ambiguous");n[c]=i}var l=e.length,u=e.charAt(0),d=Math.log(l)/Math.log(256),p=Math.log(256)/Math.log(l);function decodeUnsafe(e){if("string"!=typeof e)throw TypeError("Expected String");if(0===e.length)return new Uint8Array;var t=0;if(" "!==e[0]){for(var o=0,i=0;e[t]===u;)o++,t++;for(var s=(e.length-t)*d+1>>>0,c=new Uint8Array(s);e[t];){var p=n[e.charCodeAt(t)];if(255===p)return;for(var m=0,b=s-1;(0!==p||m<i)&&-1!==b;b--,m++)p+=l*c[b]>>>0,c[b]=p%256>>>0,p=p/256>>>0;if(0!==p)throw Error("Non-zero carry");i=m,t++}if(" "!==e[t]){for(var g=s-i;g!==s&&0===c[g];)g++;for(var y=new Uint8Array(o+(s-g)),v=o;g!==s;)y[v++]=c[g++];return y}}}return{encode:function(t){if(t instanceof Uint8Array||(ArrayBuffer.isView(t)?t=new Uint8Array(t.buffer,t.byteOffset,t.byteLength):Array.isArray(t)&&(t=Uint8Array.from(t))),!(t instanceof Uint8Array))throw TypeError("Expected Uint8Array");if(0===t.length)return"";for(var n=0,o=0,i=0,s=t.length;i!==s&&0===t[i];)i++,n++;for(var c=(s-i)*p+1>>>0,d=new Uint8Array(c);i!==s;){for(var m=t[i],b=0,g=c-1;(0!==m||b<o)&&-1!==g;g--,b++)m+=256*d[g]>>>0,d[g]=m%l>>>0,m=m/l>>>0;
1083if(0!==m)throw Error("Non-zero carry");o=b,i++}for(var y=c-o;y!==c&&0===d[y];)y++;for(var v=u.repeat(n);y<c;++y)v+=e.charAt(d[y]);return v},decodeUnsafe:decodeUnsafe,decode:function(e){var n=decodeUnsafe(e);if(n)return n;throw Error(`Non-${t} character`)}}};new Uint8Array(0);let equals=(e,t)=>{if(e===t)return!0;if(e.byteLength!==t.byteLength)return!1;for(let n=0;n<e.byteLength;n++)if(e[n]!==t[n])return!1;return!0},coerce=e=>{if(e instanceof Uint8Array&&"Uint8Array"===e.constructor.name)return e;if(e instanceof ArrayBuffer)return new Uint8Array(e);if(ArrayBuffer.isView(e))return new Uint8Array(e.buffer,e.byteOffset,e.byteLength);throw Error("Unknown type, must be binary type")},fromString=e=>new TextEncoder().encode(e),bytes_toString=e=>new TextDecoder().decode(e);let Encoder=class Encoder{constructor(e,t,n){this.name=e,this.prefix=t,this.baseEncode=n}encode(e){if(e instanceof Uint8Array)return`${this.prefix}${this.baseEncode(e)}`;throw Error("Unknown type, must be binary type")}};let Decoder=class Decoder{constructor(e,t,n){if(this.name=e,this.prefix=t,void 0===t.codePointAt(0))throw Error("Invalid prefix character");this.prefixCodePoint=t.codePointAt(0),this.baseDecode=n}decode(e){if("string"==typeof e){if(e.codePointAt(0)!==this.prefixCodePoint)throw Error(`Unable to decode multibase string ${JSON.stringify(e)}, ${this.name} decoder only supports inputs prefixed with ${this.prefix}`);return this.baseDecode(e.slice(this.prefix.length))}throw Error("Can only multibase decode strings")}or(e){return or(this,e)}};let ComposedDecoder=class ComposedDecoder{constructor(e){this.decoders=e}or(e){return or(this,e)}decode(e){let t=e[0],n=this.decoders[t];if(n)return n.decode(e);throw RangeError(`Unable to decode multibase string ${JSON.stringify(e)}, only inputs prefixed with ${Object.keys(this.decoders)} are supported`)}};let or=(e,t)=>new ComposedDecoder({...e.decoders||{[e.prefix]:e},...t.decoders||{[t.prefix]:t}});let Codec=class Codec{constructor(e,t,n,o){this.name=e,this.prefix=t,this.baseEncode=n,this.baseDecode=o,this.encoder=new Encoder(e,t,n),this.decoder=new Decoder(e,t,o)}encode(e){return this.encoder.encode(e)}decode(e){return this.decoder.decode(e)}};let from=({name:e,prefix:t,encode:n,decode:o})=>new Codec(e,t,n,o),baseX=({prefix:e,name:t,alphabet:n})=>{let{encode:o,decode:i}=base_x(n,t);return from({prefix:e,name:t,encode:o,decode:e=>coerce(i(e))})},decode=(e,t,n,o)=>{let i={};for(let e=0;e<t.length;++e)i[t[e]]=e;let s=e.length;for(;"="===e[s-1];)--s;let c=new Uint8Array(s*n/8|0),l=0,u=0,d=0;for(let t=0;t<s;++t){let s=i[e[t]];if(void 0===s)throw SyntaxError(`Non-${o} character`);u=u<<n|s,(l+=n)>=8&&(l-=8,c[d++]=255&u>>l)}if(l>=n||255&u<<8-l)throw SyntaxError("Unexpected end of data");return c},encode=(e,t,n)=>{let o="="===t[t.length-1],i=(1<<n)-1,s="",c=0,l=0;for(let o=0;o<e.length;++o)for(l=l<<8|e[o],c+=8;c>n;)c-=n,s+=t[i&l>>c];if(c&&(s+=t[i&l<<n-c]),o)for(;s.length*n&7;)s+="=";return s},rfc4648=({name:e,prefix:t,bitsPerChar:n,alphabet:o})=>from({prefix:t,name:e,encode:e=>encode(e,o,n),decode:t=>decode(t,o,n,e)}),x=from({prefix:"\x00",name:"identity",encode:e=>bytes_toString(e),decode:e=>fromString(e)}),P=rfc4648({prefix:"0",name:"base2",alphabet:"01",bitsPerChar:1}),_=rfc4648({prefix:"7",name:"base8",alphabet:"01234567",bitsPerChar:3}),I=baseX({prefix:"9",name:"base10",alphabet:"0123456789"}),j=rfc4648({prefix:"f",name:"base16",alphabet:"0123456789abcdef",bitsPerChar:4}),R=rfc4648({prefix:"F",name:"base16upper",alphabet:"0123456789ABCDEF",bitsPerChar:4}),M=rfc4648({prefix:"b",name:"base32",alphabet:"abcdefghijklmnopqrstuvwxyz234567",bitsPerChar:5}),F=rfc4648({prefix:"B",name:"base32upper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",bitsPerChar:5}),q=rfc4648({prefix:"c",name:"base32pad",alphabet:"abcdefghijklmnopqrstuvwxyz234567=",bitsPerChar:5}),H=rfc4648({prefix:"C",name:"base32padupper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=",bitsPerChar:5}),z=rfc4648({prefix:"v",name:"base32hex",alphabet:"0123456789abcdefghijklmnopqrstuv",bitsPerChar:5}),W=rfc4648({prefix:"V",name:"base32hexupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",bitsPerChar:5}),K=rfc4648({prefix:"t",name:"base32hexpad",alphabet:"0123456789abcdefghijklmnopqrstuv=",bitsPerChar:5}),Q=rfc4648({prefix:"T",name:"base32hexpadupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV=",bitsPerChar:5}),Z=rfc4648({prefix:"h",name:"base32z",alphabet:"ybndrfg8ejkmcpqxot1uwisza345h769",bitsPerChar:5}),X=baseX({prefix:"k",name:"base36",alphabet:"0123456789abcdefghijklmnopqrstuvwxyz"}),Y=baseX({prefix:"K",name:"base36upper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"}),J=baseX({name:"base58btc",prefix:"z",alphabet:"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"}),et=baseX({name:"base58flickr",prefix:"Z",alphabet:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"}),eo=rfc4648({prefix:"m",name:"base64",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789
1083+/",bitsPerChar:6}),ea=rfc4648({prefix:"M",name:"base64pad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",bitsPerChar:6}),ei=rfc4648({prefix:"u",name:"base64url",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",bitsPerChar:6}),es=rfc4648({prefix:"U",name:"base64urlpad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_=",bitsPerChar:6}),ec=Array.from("\uD83D\uDE80\uD83E\uDE90☄\uD83D\uDEF0\uD83C\uDF0C\uD83C\uDF11\uD83C\uDF12\uD83C\uDF13\uD83C\uDF14\uD83C\uDF15\uD83C\uDF16\uD83C\uDF17\uD83C\uDF18\uD83C\uDF0D\uD83C\uDF0F\uD83C\uDF0E\uD83D\uDC09☀\uD83D\uDCBB\uD83D\uDDA5\uD83D\uDCBE\uD83D\uDCBF\uD83D\uDE02❤\uD83D\uDE0D\uD83E\uDD23\uD83D\uDE0A\uD83D\uDE4F\uD83D\uDC95\uD83D\uDE2D\uD83D\uDE18\uD83D\uDC4D\uD83D\uDE05\uD83D\uDC4F\uD83D\uDE01\uD83D\uDD25\uD83E\uDD70\uD83D\uDC94\uD83D\uDC96\uD83D\uDC99\uD83D\uDE22\uD83E\uDD14\uD83D\uDE06\uD83D\uDE44\uD83D\uDCAA\uD83D\uDE09☺\uD83D\uDC4C\uD83E\uDD17\uD83D\uDC9C\uD83D\uDE14\uD83D\uDE0E\uD83D\uDE07\uD83C\uDF39\uD83E\uDD26\uD83C\uDF89\uD83D\uDC9E✌✨\uD83E\uDD37\uD83D\uDE31\uD83D\uDE0C\uD83C\uDF38\uD83D\uDE4C\uD83D\uDE0B\uD83D\uDC97\uD83D\uDC9A\uD83D\uDE0F\uD83D\uDC9B\uD83D\uDE42\uD83D\uDC93\uD83E\uDD29\uD83D\uDE04\uD83D\uDE00\uD83D\uDDA4\uD83D\uDE03\uD83D\uDCAF\uD83D\uDE48\uD83D\uDC47\uD83C\uDFB6\uD83D\uDE12\uD83E\uDD2D❣\uD83D\uDE1C\uD83D\uDC8B\uD83D\uDC40\uD83D\uDE2A\uD83D\uDE11\uD83D\uDCA5\uD83D\uDE4B\uD83D\uDE1E\uD83D\uDE29\uD83D\uDE21\uD83E\uDD2A\uD83D\uDC4A\uD83E\uDD73\uD83D\uDE25\uD83E\uDD24\uD83D\uDC49\uD83D\uDC83\uD83D\uDE33✋\uD83D\uDE1A\uD83D\uDE1D\uD83D\uDE34\uD83C\uDF1F\uD83D\uDE2C\uD83D\uDE43\uD83C\uDF40\uD83C\uDF37\uD83D\uDE3B\uD83D\uDE13⭐✅\uD83E\uDD7A\uD83C\uDF08\uD83D\uDE08\uD83E\uDD18\uD83D\uDCA6✔\uD83D\uDE23\uD83C\uDFC3\uD83D\uDC90☹\uD83C\uDF8A\uD83D\uDC98\uD83D\uDE20☝\uD83D\uDE15\uD83C\uDF3A\uD83C\uDF82\uD83C\uDF3B\uD83D\uDE10\uD83D\uDD95\uD83D\uDC9D\uD83D\uDE4A\uD83D\uDE39\uD83D\uDDE3\uD83D\uDCAB\uD83D\uDC80\uD83D\uDC51\uD83C\uDFB5\uD83E\uDD1E\uD83D\uDE1B\uD83D\uDD34\uD83D\uDE24\uD83C\uDF3C\uD83D\uDE2B⚽\uD83E\uDD19☕\uD83C\uDFC6\uD83E\uDD2B\uD83D\uDC48\uD83D\uDE2E\uD83D\uDE46\uD83C\uDF7B\uD83C\uDF43\uD83D\uDC36\uD83D\uDC81\uD83D\uDE32\uD83C\uDF3F\uD83E\uDDE1\uD83C\uDF81⚡\uD83C\uDF1E\uD83C\uDF88❌✊\uD83D\uDC4B\uD83D\uDE30\uD83E\uDD28\uD83D\uDE36\uD83E\uDD1D\uD83D\uDEB6\uD83D\uDCB0\uD83C\uDF53\uD83D\uDCA2\uD83E\uDD1F\uD83D\uDE41\uD83D\uDEA8\uD83D\uDCA8\uD83E\uDD2C✈\uD83C\uDF80\uD83C\uDF7A\uD83E\uDD13\uD83D\uDE19\uD83D\uDC9F\uD83C\uDF31\uD83D\uDE16\uD83D\uDC76\uD83E\uDD74▶➡❓\uD83D\uDC8E\uD83D\uDCB8⬇\uD83D\uDE28\uD83C\uDF1A\uD83E\uDD8B\uD83D\uDE37\uD83D\uDD7A⚠\uD83D\uDE45\uD83D\uDE1F\uD83D\uDE35\uD83D\uDC4E\uD83E\uDD32\uD83E\uDD20\uD83E\uDD27\uD83D\uDCCC\uD83D\uDD35\uD83D\uDC85\uD83E\uDDD0\uD83D\uDC3E\uD83C\uDF52\uD83D\uDE17\uD83E\uDD11\uD83C\uDF0A\uD83E\uDD2F\uD83D\uDC37☎\uD83D\uDCA7\uD83D\uDE2F\uD83D\uDC86\uD83D\uDC46\uD83C\uDFA4\uD83D\uDE47\uD83C\uDF51❄\uD83C\uDF34\uD83D\uDCA3\uD83D\uDC38\uD83D\uDC8C\uD83D\uDCCD\uD83E\uDD40\uD83E\uDD22\uD83D\uDC45\uD83D\uDCA1\uD83D\uDCA9\uD83D\uDC50\uD83D\uDCF8\uD83D\uDC7B\uD83E\uDD10\uD83E\uDD2E\uD83C\uDFBC\uD83E\uDD75\uD83D\uDEA9\uD83C\uDF4E\uD83C\uDF4A\uD83D\uDC7C\uD83D\uDC8D\uD83D\uDCE3\uD83E\uDD42"),el=ec.reduce((e,t,n)=>(e[n]=t,e),[]),eu=ec.reduce((e,t,n)=>(e[t.codePointAt(0)]=n,e),[]),ed=from({prefix:"\uD83D\uDE80",name:"base256emoji",encode:function(e){return e.reduce((e,t)=>e+=el[t],"")},decode:function(e){let t=[];for(let n of e){let e=eu[n.codePointAt(0)];if(void 0===e)throw Error(`Non-base256emoji character: ${n}`);t.push(e)}return new Uint8Array(t)}});function varint_encode(e,t,n){t=t||[];for(var o=n=n||0;e>=2147483648;)t[n++]=255&e|128,e/=128;for(;-128&e;)t[n++]=255&e|128,e>>>=7;return t[n]=0|e,varint_encode.bytes=n-o+1,t}function read(e,t){var n,o=0,t=t||0,i=0,s=t,c=e.length;do{if(s>=c)throw read.bytes=0,RangeError("Could not decode varint");n=e[s++],o+=i<28?(127&n)<<i:(127&n)*Math.pow(2,i),i+=7}while(n>=128);return read.bytes=s-t,o}var ef={encode:varint_encode,decode:read,encodingLength:function(e){return e<128?1:e<16384?2:e<2097152?3:e<268435456?4:e<34359738368?5:e<4398046511104?6:e<562949953421312?7:e<72057594037927940?8:e<0x7fffffffffffffff?9:10}};let src_varint_decode=(e,t=0)=>{let n=ef.decode(e,t);return[n,ef.decode.bytes]},encodeTo=(e,t,n=0)=>(ef.encode(e,t,n),t),encodingLength=e=>ef.encodingLength(e),create=(e,t)=>
1083{let n=t.byteLength,o=encodingLength(e),i=o+encodingLength(n),s=new Uint8Array(i+n);return encodeTo(e,s,0),encodeTo(n,s,o),s.set(t,i),new Digest(e,n,t,s)},digest_decode=e=>{let t=coerce(e),[n,o]=src_varint_decode(t),[i,s]=src_varint_decode(t.subarray(o)),c=t.subarray(o+s);if(c.byteLength!==i)throw Error("Incorrect length");return new Digest(n,i,c,t)},digest_equals=(e,t)=>e===t||e.code===t.code&&e.size===t.size&&equals(e.bytes,t.bytes);let Digest=class Digest{constructor(e,t,n,o){this.code=e,this.size=t,this.digest=n,this.bytes=o}};let hasher_from=({name:e,code:t,encode:n})=>new Hasher(e,t,n);let Hasher=class Hasher{constructor(e,t,n){this.name=e,this.code=t,this.encode=n}digest(e){if(e instanceof Uint8Array){let t=this.encode(e);return t instanceof Uint8Array?create(this.code,t):t.then(e=>create(this.code,e))}throw Error("Unknown type, must be binary type")}};let sha=e=>async t=>new Uint8Array(await crypto.subtle.digest(e,t)),ep=hasher_from({name:"sha2-256",code:18,encode:sha("SHA-256")}),eh=hasher_from({name:"sha2-512",code:19,encode:sha("SHA-512")}),em={code:0,name:"identity",encode:coerce,digest:e=>create(0,coerce(e))},eb="raw",eg=85,raw_encode=e=>coerce(e),raw_decode=e=>coerce(e),ey=new TextEncoder,ev=new TextDecoder,ew="json",eE=512,json_encode=e=>ey.encode(JSON.stringify(e)),json_decode=e=>JSON.parse(ev.decode(e));let CID=class CID{constructor(e,t,n,o){this.code=t,this.version=e,this.multihash=n,this.bytes=o,this.byteOffset=o.byteOffset,this.byteLength=o.byteLength,this.asCID=this,this._baseCache=new Map,Object.defineProperties(this,{byteOffset:eA,byteLength:eA,code:eT,version:eT,multihash:eT,bytes:eT,_baseCache:eA,asCID:eA})}toV0(){if(0===this.version)return this;{let{code:e,multihash:t}=this;if(e!==ex)throw Error("Cannot convert a non dag-pb CID to CIDv0");if(t.code!==eC)throw Error("Cannot convert non sha2-256 multihash CID to CIDv0");return CID.createV0(t)}}toV1(){switch(this.version){case 0:{let{code:e,digest:t}=this.multihash,n=create(e,t);return CID.createV1(this.code,n)}case 1:return this;default:throw Error(`Can not convert CID version ${this.version} to version 0. This is a bug please report`)}}equals(e){return e&&this.code===e.code&&this.version===e.version&&digest_equals(this.multihash,e.multihash)}toString(e){let{bytes:t,version:n,_baseCache:o}=this;return 0===n?toStringV0(t,o,e||J.encoder):toStringV1(t,o,e||M.encoder)}toJSON(){return{code:this.code,version:this.version,hash:this.multihash.bytes}}get[Symbol.toStringTag](){return"CID"}[Symbol.for("nodejs.util.inspect.custom")](){return"CID("+this.toString()+")"}static isCID(e){return deprecate(/^0\.0/,eS),!!(e&&(e[eP]||e.asCID===e))}get toBaseEncodedString(){throw Error("Deprecated, use .toString()")}get codec(){throw Error('"codec" property is deprecated, use integer "code" property instead')}get buffer(){throw Error("Deprecated .buffer property, use .bytes to get Uint8Array instead")}get multibaseName(){throw Error('"multibaseName" property is deprecated')}get prefix(){throw Error('"prefix" property is deprecated')}static asCID(e){if(e instanceof CID)return e;if(null!=e&&e.asCID===e){let{version:t,code:n,multihash:o,bytes:i}=e;return new CID(t,n,o,i||encodeCID(t,n,o.bytes))}if(null==e||!0!==e[eP])return null;{let{version:t,multihash:n,code:o}=e,i=digest_decode(n);return CID.create(t,o,i)}}static create(e,t,n){if("number"!=typeof t)throw Error("String codecs are no longer supported");switch(e){case 0:if(t===ex)return new CID(e,t,n,n.bytes);throw Error(`Version 0 CID must use dag-pb (code: ${ex}) block encoding`);case 1:{let o=encodeCID(e,t,n.bytes);return new CID(e,t,n,o)}default:throw Error("Invalid version")}}static createV0(e){return CID.create(0,ex,e)}static createV1(e,t){return CID.create(1,e,t)}static decode(e){let[t,n]=CID.decodeFirst(e);if(n.length)throw Error("Incorrect length");return t}static decodeFirst(e){let t=CID.inspectBytes(e),n=t.size-t.multihashSize,o=coerce(e.subarray(n,n+t.multihashSize));if(o.byteLength!==t.multihashSize)throw Error("Incorrect length");let i=o.subarray(t.multihashSize-t.digestSize),s=new Digest(t.multihashCode,t.digestSize,i,o),c=0===t.version?CID.createV0(s):CID.createV1(t.codec,s);return[c,e.subarray(t.size)]}static inspectBytes(e){let t=0,next=()=>{let[n,o]=src_varint_decode(e.subarray(t));return t+=o,n},n=next(),o=ex;if(18===n?(n=0,t=0):1===n&&(o=next()),0!==n&&1!==n)throw RangeError(`Invalid CID version ${n}`);let i=t,s=next(),c=next(),l=t+c;return{version:n,codec:o,multihashCode:s,digestSize:c,multihashSize:l-i,size:l}}static parse(e,t){let[n,o]=parseCIDtoBytes(e,t),i=CID.decode(o);return i._baseCache.set(n,e),i}};let parseCIDtoBytes=(e,t)=>{switch(e[0]){case"Q":return[J.prefix,(t||J).decode(`${J.prefix}${e}`)];case J.prefix:return[J.prefix,(t||J).decode(e)];case M.prefix:return[M.prefix,(t||M).decode(e)];default:if(null==t)throw Error("To parse non base32 or base58btc encoded CID multibase decoder must be provided");return[e[0],t.decode(e)]}},toStringV0=(e,t,n)=>{let{prefix:o}=n;if(o!==J.prefix)throw Error(`Cannot string encode V0 in ${n.name} encoding`);let i=t.get(o);if(null!=i)return i;{let i=n.encode(e).slice(1);return t.set(o,i),i}},toStringV1=(e,t,n)=>{let{prefix:o}=n,i=t.get(o);if(null!=i)return i;{let i=n.encode(e);return t.set(o,i),i}},ex=112,eC=18,encodeCID=(e,t,n)=>{let o=encodingLength(e),i=o+encodingLength(t),s=new Uint8Array(i+n.byteLength);return encodeTo(e,s,0),encodeTo(t,s,o),s.set(n,i),s}
1083,eP=Symbol.for("@ipld/js-cid/CID"),eT={writable:!1,configurable:!1,enumerable:!0},eA={writable:!1,enumerable:!1,configurable:!1},deprecate=(e,t)=>{if(e.test("0.0.0-dev"))console.warn(t);else throw Error(t)},eS=`CID.isCID(v) is deprecated and will be removed in the next major release.
1084Following code pattern:
1085
1086if (CID.isCID(value)) {
1087  doSomethingWithCID(value)
1088}
1089
1090Is replaced with:
1091
1092const cid = CID.asCID(value)
1093if (cid) {
1094  // Make sure to use cid instead of value
1095  doSomethingWithCID(cid)
1096}
1097`,e_={...o,...i,...s,...c,...l,...u,...d,...p,...m,...b};({...g,...y});var eI=n(53160);function createCodec(e,t,n,o){return{name:e,prefix:t,encoder:{name:e,prefix:t,encode:n},decoder:{decode:o}}}let ek=createCodec("utf8","u",e=>{let t=new TextDecoder("utf8");return"u"+t.decode(e)},e=>{let t=new TextEncoder;return t.encode(e.substring(1))}),eO=createCodec("ascii","a",e=>{let t="a";for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t},e=>{e=e.substring(1);let t=(0,eI.E)(e.length);for(let n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}),ej={utf8:ek,"utf-8":ek,hex:e_.base16,latin1:eO,ascii:eO,binary:eO,...e_};var eB=ej},21431:function(e,t,n){"use strict";function parseAccount(e){return"string"==typeof e?{address:e,type:"json-rpc"}:e}n.d(t,{T:function(){return parseAccount}})},93613:function(e,t,n){"use strict";n.d(t,{O:function(){return getEnsAddress}});var o=n(1920),i=n(31826),s=n(96606),c=n(61786),l=n(26873),u=n(46872),d=n(3492),p=n(89683),m=n(91024);async function getEnsAddress(e,{blockNumber:t,blockTag:n,name:b,universalResolverAddress:g}){let y=g;if(!y){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");y=(0,c.LI)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}let v=await (0,m.L)(e,{address:y,abi:o.lD,functionName:"resolve",args:[(0,u.NC)((0,p.T)(b)),(0,s.R)({abi:o.Ei,functionName:"addr",args:[(0,d.V)(b)]})],blockNumber:t,blockTag:n});if("0x"===v[0])return null;let E=(0,i.k)({abi:o.Ei,functionName:"addr",data:v[0]});return"0x00"===(0,l.f)(E)?null:E}},55573:function(e,t,n){"use strict";n.d(t,{r:function(){return getEnsAvatar}});var o=n(91024),i=n(64282);let s=/(?<protocol>https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?<root>\/)?(?<subpath>ipfs\/|ipns\/)?(?<target>[\w\-.]+)(?<subtarget>\/.*)?/,c=/^(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,})(\/(?<target>[\w\-.]+))?(?<subtarget>\/.*)?$/,l=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,u=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function isImageUri(e){try{let t=await fetch(e,{method:"HEAD"});if(200===t.status){let e=t.headers.get("content-type");return e?.startsWith("image/")}return!1}catch(t){if("object"==typeof t&&void 0!==t.response||!globalThis.hasOwnProperty("Image"))return!1;return new Promise(t=>{let n=new Image;n.onload=()=>{t(!0)},n.onerror=()=>{t(!1)},n.src=e})}}function getGateway(e,t){return e?e.endsWith("/")?e.slice(0,-1):e:t}function resolveAvatarUri({uri:e,gatewayUrls:t}){let n=l.test(e);if(n)return{uri:e,isOnChain:!0,isEncoded:n};let o=getGateway(t?.ipfs,"https://ipfs.io"),d=getGateway(t?.arweave,"https://arweave.net"),p=e.match(s),{protocol:m,subpath:b,target:g,subtarget:y=""}=p?.groups||{},v="ipns:/"===m||"ipns/"===b,E="ipfs:/"===m||"ipfs/"===b||c.test(e);if(e.startsWith("http")&&!v&&!E){let n=e;return t?.arweave&&(n=e.replace(/https:\/\/arweave.net/g,t?.arweave)),{uri:n,isOnChain:!1,isEncoded:!1}}if((v||E)&&g)return{uri:`${o}/${v?"ipns":"ipfs"}/${g}${y}`,isOnChain:!1,isEncoded:!1};if("ar:/"===m&&g)return{uri:`${d}/${g}${y||""}`,isOnChain:!1,isEncoded:!1};let x=e.replace(u,"");if(x.startsWith("<svg")&&(x=`data:image/svg+xml;base64,${btoa(x)}`),x.startsWith("data:")||x.startsWith("{"))return{uri:x,isOnChain:!0,isEncoded:!1};throw new i.FK({uri:e})}function getJsonImage(e){if("object"!=typeof e||!("image"in e)&&!("image_url"in e)&&!("image_data"in e))throw new i.rO({data:e});return e.image||e.image_url||e.image_data}async function getMetadataAvatarUri({gatewayUrls:e,uri:t}){try{let n=await fetch(t).then(e=>e.json()),o=await parseAvatarUri({gatewayUrls:e,uri:getJsonImage(n)});return o}catch{throw new i.FK({uri:t})}}async function parseAvatarUri({gatewayUrls:e,uri:t}){let{uri:n,isOnChain:o}=resolveAvatarUri({uri:t,gatewayUrls:e});if(o)return n;let s=await isImageUri(n);if(s)return n;throw new i.FK({uri:t})}async function getNftTokenUri(e,{nft:t}){if("erc721"===t.namespace)return(0,o.L)(e,{address:t.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}
1097],functionName:"tokenURI",args:[BigInt(t.tokenID)]});if("erc1155"===t.namespace)return(0,o.L)(e,{address:t.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(t.tokenID)]});throw new i.sR({namespace:t.namespace})}async function parseAvatarRecord(e,{gatewayUrls:t,record:n}){return/eip155:/i.test(n)?parseNftAvatarUri(e,{gatewayUrls:t,record:n}):parseAvatarUri({uri:n,gatewayUrls:t})}async function parseNftAvatarUri(e,{gatewayUrls:t,record:n}){let o=function(e){e.startsWith("did:nft:")&&(e=e.replace("did:nft:","").replace(/_/g,"/"));let[t,n,o]=e.split("/"),[s,c]=t.split(":"),[l,u]=n.split(":");if(!s||"eip155"!==s.toLowerCase())throw new i.Pm({reason:"Only EIP-155 supported"});if(!c)throw new i.Pm({reason:"Chain ID not found"});if(!u)throw new i.Pm({reason:"Contract address not found"});if(!o)throw new i.Pm({reason:"Token ID not found"});if(!l)throw new i.Pm({reason:"ERC namespace not found"});return{chainID:parseInt(c),namespace:l.toLowerCase(),contractAddress:u,tokenID:o}}(n),s=await getNftTokenUri(e,{nft:o}),{uri:c,isOnChain:l,isEncoded:u}=resolveAvatarUri({uri:s,gatewayUrls:t});if(l&&(c.includes("data:application/json;base64,")||c.startsWith("{"))){let e=u?atob(c.replace("data:application/json;base64,","")):c,n=JSON.parse(e);return parseAvatarUri({uri:getJsonImage(n),gatewayUrls:t})}let d=o.tokenID;return"erc1155"===o.namespace&&(d=d.replace("0x","").padStart(64,"0")),getMetadataAvatarUri({gatewayUrls:t,uri:c.replace(/(?:0x)?{id}/,d)})}var d=n(11738);async function getEnsAvatar(e,{blockNumber:t,blockTag:n,gatewayUrls:o,name:i,universalResolverAddress:s}){let c=await (0,d.g)(e,{blockNumber:t,blockTag:n,key:"avatar",name:i,universalResolverAddress:s});if(!c)return null;try{return await parseAvatarRecord(e,{record:c,gatewayUrls:o})}catch{return null}}},28314:function(e,t,n){"use strict";n.d(t,{w:function(){return getEnsName}});var o=n(35554),i=n(90722),s=n(61786),c=n(46872),l=n(89683),u=n(91024);async function getEnsName(e,{address:t,blockNumber:n,blockTag:d,universalResolverAddress:p}){let m=p;if(!m){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");m=(0,s.LI)({blockNumber:n,chain:e.chain,contract:"ensUniversalResolver"})}let b=`${t.toLowerCase().substring(2)}.addr.reverse`;try{let t=await (0,u.L)(e,{address:m,abi:[{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"}]}],functionName:"reverse",args:[(0,c.NC)((0,l.T)(b))],blockNumber:n,blockTag:d});return t[0]}catch(e){if(e instanceof i.uq&&e.cause.reason===o.$[50])return null;throw e}}},39873:function(e,t,n){"use strict";n.d(t,{S:function(){return getEnsResolver}});var o=n(61786),i=n(46872),s=n(89683),c=n(91024);async function getEnsResolver(e,{blockNumber:t,blockTag:n,name:l,universalResolverAddress:u}){let d=u;if(!d){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");d=(0,o.LI)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}let[p]=await (0,c.L)(e,{address:d,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[(0,i.NC)((0,s.T)(l))],blockNumber:t,blockTag:n});return p}},11738:function(e,t,n){"use strict";n.d(t,{g:function(){return getEnsText}});var o=n(1920),i=n(31826),s=n(96606),c=n(61786),l=n(46872),u=n(3492),d=n(89683),p=n(91024);async function getEnsText(e,{blockNumber:t,blockTag:n,name:m,key:b,universalResolverAddress:g}){let y=g;if(!y){if(!e.chain)throw Error("client chain not configured. universalResolverAddress is required.");y=(0,c.LI)({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}let v=await (0,p.L)(e,{address:y,abi:o.lD,functionName:"resolve",args:[(0,l.NC)((0,d.T)(m)),(0,s.R)({abi:o.nZ,functionName:"text",args:[(0,u.V)(m),b]})],blockNumber:t,blockTag:n});if("0x"===v[0])return null;let E=(0,i.k)({abi:o.nZ,functionName:"text",data:v[0]});return""===E?null:E}},425:function(e,t,n){"use strict";n.d(t,{R:function(){return call}});
1097var o=n(21431),i=n(1920),s=n(69977),c=n(21973),l=n(90722),u=n(31826),d=n(96606),p=n(61786),m=n(46872),b=n(71721),g=n(91019),y=n(95417),v=n(23822),E=n(68583),x=n(13134);async function call(e,t){let{account:i,batch:l=!!e.batch?.multicall,blockNumber:u,blockTag:d="latest",accessList:p,data:E,gas:P,gasPrice:_,maxFeePerGas:I,maxPriorityFeePerGas:j,nonce:R,to:M,value:F,...q}=t,H=i?(0,o.T)(i):void 0;try{(0,x.F)(t);let n=u?(0,m.eC)(u):void 0,o=n||d,i=e.chain?.formatters?.transactionRequest,s=(0,y.W)({from:H?.address,accessList:p,data:E,gas:P,gasPrice:_,maxFeePerGas:I,maxPriorityFeePerGas:j,nonce:R,to:M,value:F,...(0,g.K)(q,{formatter:i})},{formatter:i||v.t});if(l&&function({request:e}){let{data:t,to:n,...o}=e;return!(!t||t.startsWith("0x82ad56cb"))&&!!n&&!(Object.values(o).filter(e=>void 0!==e).length>0)}({request:s}))try{return await scheduleMulticall(e,{...s,blockNumber:u,blockTag:d})}catch(e){if(!(e instanceof c.pZ)&&!(e instanceof c.mm))throw e}let b=await e.request({method:"eth_call",params:o?[s,o]:[s]});if("0x"===b)return{data:void 0};return{data:b}}catch(l){let o=function(e){if(!(e instanceof s.G))return;let t=e.walk();return"object"==typeof t.data?t.data.data:t.data}(l),{offchainLookup:i,offchainLookupSignature:c}=await Promise.resolve().then(n.bind(n,25178));if(o?.slice(0,10)===c&&M)return{data:await i(e,{data:o,to:M})};throw(0,b.P)(l,{...t,account:H,chain:e.chain})}}async function scheduleMulticall(e,t){let{batchSize:n=1024,wait:o=0}="object"==typeof e.batch?.multicall?e.batch?.multicall:{},{blockNumber:s,blockTag:b="latest",data:g,multicallAddress:y,to:v}=t,x=y;if(!x){if(!e.chain)throw new c.pZ;x=(0,p.LI)({blockNumber:s,chain:e.chain,contract:"multicall3"})}let P=s?(0,m.eC)(s):void 0,_=P||b,{schedule:I}=(0,E.S)({id:`${e.uid}.${_}`,wait:o,shouldSplitBatch(e){let t=e.reduce((e,{data:t})=>e+(t.length-2),0);return t>2*n},fn:async t=>{let n=t.map(e=>({allowFailure:!0,callData:e.data,target:e.to})),o=(0,d.R)({abi:i.F8,args:[n],functionName:"aggregate3"}),s=await e.request({method:"eth_call",params:[{data:o,to:x},_]});return(0,u.k)({abi:i.F8,args:[n],functionName:"aggregate3",data:s||"0x"})}}),[{returnData:j,success:R}]=await I({data:g,to:v});if(!R)throw new l.VQ({data:j});return"0x"===j?{data:void 0}:{data:j}}},91024:function(e,t,n){"use strict";n.d(t,{L:function(){return readContract}});var o=n(31826),i=n(96606),s=n(30826),c=n(425);async function readContract(e,{abi:t,address:n,args:l,functionName:u,...d}){let p=(0,i.R)({abi:t,args:l,functionName:u});try{let{data:i}=await (0,c.R)(e,{data:p,to:n,...d});return(0,o.k)({abi:t,args:l,functionName:u,data:i||"0x"})}catch(e){throw(0,s.S)(e,{abi:t,address:n,args:l,docsPath:"/docs/contract/readContract",functionName:u})}}},81782:function(e,t,n){"use strict";n.d(t,{P7:function(){return d},ws:function(){return p},RJ:function(){return m},v8:function(){return b}});var o=n(61786),i=n(86101),s=n(94216),c=n(4656),l=n(23822);let u={block:(0,i.G)({exclude:["difficulty","gasLimit","mixHash","nonce","uncles"],format:e=>({randomness:e.randomness})}),transaction:(0,s.y_)({format:e=>({feeCurrency:e.feeCurrency,gatewayFee:e.gatewayFee?BigInt(e.gatewayFee):null,gatewayFeeRecipient:e.gatewayFeeRecipient})}),transactionReceipt:(0,c.d)({format:e=>({feeCurrency:e.feeCurrency,gatewayFee:e.gatewayFee?BigInt(e.gatewayFee):null,gatewayFeeRecipient:e.gatewayFeeRecipient})}),transactionRequest:(0,l.i)({format:e=>({feeCurrency:e.feeCurrency,gatewayFee:e.gatewayFee,gatewayFeeRecipient:e.gatewayFeeRecipient})})};(0,o.ax)({id:42161,name:"Arbitrum One",network:"arbitrum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://arb-mainnet.g.alchemy.com/v2"],webSocket:["wss://arb-mainnet.g.alchemy.com/v2"]},infura:{http:["https://arbitrum-mainnet.infura.io/v3"],webSocket:["wss://arbitrum-mainnet.infura.io/ws/v3"]},default:{http:["https://arb1.arbitrum.io/rpc"]},public:{http:["https://arb1.arbitrum.io/rpc"]}},blockExplorers:{etherscan:{name:"Arbiscan",url:"https://arbiscan.io"},default:{name:"Arbiscan",url:"https://arbiscan.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:7654707}}}),(0,o.ax)({id:421613,name:"Arbitrum Goerli",network:"arbitrum-goerli",nativeCurrency:{name:"Arbitrum Goerli Ether",symbol
1097:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://arb-goerli.g.alchemy.com/v2"],webSocket:["wss://arb-goerli.g.alchemy.com/v2"]},infura:{http:["https://arbitrum-goerli.infura.io/v3"],webSocket:["wss://arbitrum-goerli.infura.io/ws/v3"]},default:{http:["https://goerli-rollup.arbitrum.io/rpc"]},public:{http:["https://goerli-rollup.arbitrum.io/rpc"]}},blockExplorers:{etherscan:{name:"Arbiscan",url:"https://goerli.arbiscan.io/"},default:{name:"Arbiscan",url:"https://goerli.arbiscan.io/"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:88114}},testnet:!0}),(0,o.ax)({id:1313161554,name:"Aurora",network:"aurora",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{infura:{http:["https://aurora-mainnet.infura.io/v3"]},default:{http:["https://mainnet.aurora.dev"]},public:{http:["https://mainnet.aurora.dev"]}},blockExplorers:{etherscan:{name:"Aurorascan",url:"https://aurorascan.dev"},default:{name:"Aurorascan",url:"https://aurorascan.dev"}}}),(0,o.ax)({id:1313161555,name:"Aurora Testnet",network:"aurora-testnet",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{infura:{http:["https://aurora-testnet.infura.io/v3"]},default:{http:["https://testnet.aurora.dev"]},public:{http:["https://testnet.aurora.dev"]}},blockExplorers:{etherscan:{name:"Aurorascan",url:"https://testnet.aurorascan.dev"},default:{name:"Aurorascan",url:"https://testnet.aurorascan.dev"}},testnet:!0}),(0,o.ax)({id:43114,name:"Avalanche",network:"avalanche",nativeCurrency:{decimals:18,name:"Avalanche",symbol:"AVAX"},rpcUrls:{default:{http:["https://api.avax.network/ext/bc/C/rpc"]},public:{http:["https://api.avax.network/ext/bc/C/rpc"]}},blockExplorers:{etherscan:{name:"SnowTrace",url:"https://snowtrace.io"},default:{name:"SnowTrace",url:"https://snowtrace.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:11907934}}}),(0,o.ax)({id:43113,name:"Avalanche Fuji",network:"avalanche-fuji",nativeCurrency:{decimals:18,name:"Avalanche Fuji",symbol:"AVAX"},rpcUrls:{default:{http:["https://api.avax-test.network/ext/bc/C/rpc"]},public:{http:["https://api.avax-test.network/ext/bc/C/rpc"]}},blockExplorers:{etherscan:{name:"SnowTrace",url:"https://testnet.snowtrace.io"},default:{name:"SnowTrace",url:"https://testnet.snowtrace.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:7096959}},testnet:!0}),(0,o.ax)({id:84531,network:"base-goerli",name:"Base Goerli",nativeCurrency:{name:"Base Goerli",symbol:"ETH",decimals:18},rpcUrls:{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"}},testnet:!0}),(0,o.ax)({id:288,name:"Boba Network",network:"boba",nativeCurrency:{decimals:18,name:"Boba",symbol:"BOBA"},rpcUrls:{default:{http:["https://mainnet.boba.network"]},public:{http:["https://mainnet.boba.network"]}},blockExplorers:{etherscan:{name:"BOBAScan",url:"https://bobascan.com"},default:{name:"BOBAScan",url:"https://bobascan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:446859}}}),(0,o.ax)({id:1039,name:"Bronos",network:"bronos",nativeCurrency:{decimals:18,name:"BRO",symbol:"BRO"},rpcUrls:{default:{http:["https://evm.bronos.org"]},public:{http:["https://evm.bronos.org"]}},blockExplorers:{default:{name:"BronoScan",url:"https://broscan.bronos.org"}}}),(0,o.ax)({id:1038,name:"Bronos Testnet",network:"bronos-testnet",nativeCurrency:{decimals:18,name:"Bronos Coin",symbol:"tBRO"},rpcUrls:{default:{http:["https://evm-testnet.bronos.org"]},public:{http:["https://evm-testnet.bronos.org"]}},blockExplorers:{default:{name:"BronoScan",url:"https://tbroscan.bronos.org"}},testnet:!0}),(0,o.ax)({id:56,name:"BNB Smart Chain",network:"bsc",nativeCurrency:{decimals:18,name:"BNB",symbol:"BNB"},rpcUrls:{default:{http:["https://rpc.ankr.com/bsc"]},public:{http:["https://rpc.ankr.com/bsc"]}},blockExplorers:{etherscan:{name:"BscScan",url:"https://bscscan.com"},default:{name:"BscScan",url:"https://bscscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:15921452}}}),(0,o.ax)({id:97,name:"Binance Smart Chain Testnet",network:"bsc-testnet",n
1097ativeCurrency:{decimals:18,name:"BNB",symbol:"tBNB"},rpcUrls:{default:{http:["https://data-seed-prebsc-1-s1.binance.org:8545"]},public:{http:["https://data-seed-prebsc-1-s1.binance.org:8545"]}},blockExplorers:{etherscan:{name:"BscScan",url:"https://testnet.bscscan.com"},default:{name:"BscScan",url:"https://testnet.bscscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:17422483}},testnet:!0}),(0,o.ax)({id:7700,name:"Canto",network:"canto",nativeCurrency:{decimals:18,name:"Canto",symbol:"CANTO"},rpcUrls:{default:{http:["https://canto.slingshot.finance"]},public:{http:["https://canto.slingshot.finance"]}},blockExplorers:{default:{name:"Canto EVM Explorer (Blockscout)",url:"https://evm.explorer.canto.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:2905789}}}),(0,o.ax)({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:u}),(0,o.ax)({id:44787,name:"Alfajores",network:"celo-alfajores",nativeCurrency:{decimals:18,name:"CELO",symbol:"A-CELO"},rpcUrls:{default:{http:["https://alfajores-forno.celo-testnet.org"]},infura:{http:["https://celo-alfajores.infura.io/v3"]},public:{http:["https://alfajores-forno.celo-testnet.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/alfajores"},etherscan:{name:"CeloScan",url:"https://alfajores.celoscan.io/"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:14569001}},testnet:!0,formatters:u}),(0,o.ax)({id:17323,name:"Cannoli",network:"celo-cannoli",nativeCurrency:{decimals:18,name:"CELO",symbol:"C-CELO"},rpcUrls:{default:{http:["https://forno.cannoli.celo-testnet.org"]},public:{http:["https://forno.cannoli.celo-testnet.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/cannoli"}},contracts:{multicall3:{address:"0x5Acb0aa8BF4E8Ff0d882Ee187140713C12BF9718",blockCreated:87429}},testnet:!0,formatters:u}),(0,o.ax)({id:25,name:"Cronos",network:"cronos",nativeCurrency:{decimals:18,name:"Cronos",symbol:"CRO"},rpcUrls:{default:{http:["https://node.croswap.com/rpc"]},public:{http:["https://node.croswap.com/rpc"]}},blockExplorers:{etherscan:{name:"CronosScan",url:"https://cronoscan.com"},default:{name:"CronosScan",url:"https://cronoscan.com"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:1963112}}}),(0,o.ax)({id:3737,network:"crossbell",name:"Crossbell",nativeCurrency:{decimals:18,name:"CSB",symbol:"CSB"},rpcUrls:{default:{http:["https://rpc.crossbell.io"]},public:{http:["https://rpc.crossbell.io"]}},blockExplorers:{default:{name:"CrossScan",url:"https://scan.crossbell.io"}},contracts:{multicall3:{address:"0xBB9759009cDaC82774EfC84D94cD9F7440f75Fcf",blockCreated:23499787}}}),(0,o.ax)({id:53935,name:"DFK Chain",network:"dfk",nativeCurrency:{decimals:18,name:"Jewel",symbol:"JEWEL"},rpcUrls:{default:{http:["https://subnets.avax.network/defi-kingdoms/dfk-chain/rpc"]},public:{http:["https://subnets.avax.network/defi-kingdoms/dfk-chain/rpc"]}},blockExplorers:{etherscan:{name:"DFKSubnetScan",url:"https://subnets.avax.network/defi-kingdoms"},default:{name:"DFKSubnetScan",url:"https://subnets.avax.network/defi-kingdoms"}}}),(0,o.ax)({id:2e3,name:"Dogechain",network:"dogechain",nativeCurrency:{decimals:18,name:"Dogechain",symbol:"DC"},rpcUrls:{default:{http:["https://rpc.dogechain.dog"]},public:{http:["https://rpc.dogechain.dog"]}},blockExplorers:{etherscan:{name:"DogeChainExplorer",url:"https://explorer.dogechain.dog"},default:{name:"DogeChainExplorer",url:"https://explorer.dogechain.dog"}}}),(0,o.ax)({id:9001,name:"Evmos",network:"evmos",nativeCurrency:{decimals:18,name:"Evmos",symbol:"EVMOS"},rpcUrls:{default:{http:["https://eth.bd.evmos.org:8545"]},public:{http:["https://eth.bd.evmos.org:8545"]}},blockExplorers:{default:{name:"Evmos Block Explorer",url:"https://escan.live/"}}}
1097),(0,o.ax)({id:9e3,name:"Evmos Testnet",network:"evmos-testnet",nativeCurrency:{decimals:18,name:"Evmos",symbol:"EVMOS"},rpcUrls:{default:{http:["https://eth.bd.evmos.dev:8545"]},public:{http:["https://eth.bd.evmos.dev:8545"]}},blockExplorers:{default:{name:"Evmos Testnet Block Explorer",url:"https://evm.evmos.dev/"}}}),(0,o.ax)({id:250,name:"Fantom",network:"fantom",nativeCurrency:{decimals:18,name:"Fantom",symbol:"FTM"},rpcUrls:{default:{http:["https://rpc.ankr.com/fantom"]},public:{http:["https://rpc.ankr.com/fantom"]}},blockExplorers:{etherscan:{name:"FTMScan",url:"https://ftmscan.com"},default:{name:"FTMScan",url:"https://ftmscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:33001987}}});let d=(0,o.ax)({id:4002,name:"Fantom Testnet",network:"fantom-testnet",nativeCurrency:{decimals:18,name:"Fantom",symbol:"FTM"},rpcUrls:{default:{http:["https://rpc.testnet.fantom.network"]},public:{http:["https://rpc.testnet.fantom.network"]}},blockExplorers:{etherscan:{name:"FTMScan",url:"https://testnet.ftmscan.com"},default:{name:"FTMScan",url:"https://testnet.ftmscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:8328688}}});(0,o.ax)({id:314,name:"Filecoin Mainnet",network:"filecoin-mainnet",nativeCurrency:{decimals:18,name:"filecoin",symbol:"FIL"},rpcUrls:{default:{http:["https://api.node.glif.io/rpc/v1"]},public:{http:["https://api.node.glif.io/rpc/v1"]}},blockExplorers:{default:{name:"Filfox",url:"https://filfox.info/en"},filscan:{name:"Filscan",url:"https://filscan.io"},filscout:{name:"Filscout",url:"https://filscout.io/en"},glif:{name:"Glif",url:"https://explorer.glif.io"}}}),(0,o.ax)({id:314159,name:"Filecoin Calibration",network:"filecoin-calibration",nativeCurrency:{decimals:18,name:"testnet filecoin",symbol:"tFIL"},rpcUrls:{default:{http:["https://api.calibration.node.glif.io/rpc/v1"]},public:{http:["https://api.calibration.node.glif.io/rpc/v1"]}},blockExplorers:{default:{name:"Filscan",url:"https://calibration.filscan.io"}}}),(0,o.ax)({id:3141,name:"Filecoin Hyperspace",network:"filecoin-hyperspace",nativeCurrency:{decimals:18,name:"testnet filecoin",symbol:"tFIL"},rpcUrls:{default:{http:["https://api.hyperspace.node.glif.io/rpc/v1"]},public:{http:["https://api.hyperspace.node.glif.io/rpc/v1"]}},blockExplorers:{default:{name:"Filfox",url:"https://hyperspace.filfox.info/en"},filscan:{name:"Filscan",url:"https://hyperspace.filscan.io"}}}),(0,o.ax)({id:14,name:"Flare Mainnet",network:"flare-mainnet",nativeCurrency:{decimals:18,name:"flare",symbol:"FLR"},rpcUrls:{default:{http:["https://flare-api.flare.network/ext/C/rpc"]},public:{http:["https://flare-api.flare.network/ext/C/rpc"]}},blockExplorers:{default:{name:"Flare Explorer",url:"https://flare-explorer.flare.network"}}}
1097),(0,o.ax)({id:114,name:"Coston2",network:"coston2",nativeCurrency:{decimals:18,name:"coston2flare",symbol:"C2FLR"},rpcUrls:{default:{http:["https://coston2-api.flare.network/ext/C/rpc"]},public:{http:["https://coston2-api.flare.network/ext/C/rpc"]}},blockExplorers:{default:{name:"Coston2 Explorer",url:"https://coston2-explorer.flare.network"}},testnet:!0}),(0,o.ax)({id:31337,name:"Foundry",network:"foundry",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{default:{http:["http://127.0.0.1:8545"],webSocket:["ws://127.0.0.1:8545"]},public:{http:["http://127.0.0.1:8545"],webSocket:["ws://127.0.0.1:8545"]}}}),(0,o.ax)({id:4689,name:"IoTeX",network:"iotex",nativeCurrency:{decimals:18,name:"IoTeX",symbol:"IOTX"},rpcUrls:{default:{http:["https://babel-api.mainnet.iotex.io"],webSocket:["wss://babel-api.mainnet.iotex.io"]},public:{http:["https://babel-api.mainnet.iotex.io"],webSocket:["wss://babel-api.mainnet.iotex.io"]}},blockExplorers:{default:{name:"IoTeXScan",url:"https://iotexscan.io"}}}),(0,o.ax)({id:4690,name:"IoTeX Testnet",network:"iotex-testnet",nativeCurrency:{decimals:18,name:"IoTeX",symbol:"IOTX"},rpcUrls:{default:{http:["https://babel-api.testnet.iotex.io"],webSocket:["wss://babel-api.testnet.iotex.io"]},public:{http:["https://babel-api.testnet.iotex.io"],webSocket:["wss://babel-api.testnet.iotex.io"]}},blockExplorers:{default:{name:"IoTeXScan",url:"https://testnet.iotexscan.io"}}});let p=(0,o.ax)({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:"0xA292E2E58d4ddEb29C33c63173d0E8B7a2A4c62e",blockCreated:8610406},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:6507670}},testnet:!0});(0,o.ax)({id:100,name:"Gnosis",network:"gnosis",nativeCurrency:{decimals:18,name:"Gnosis",symbol:"xDAI"},rpcUrls:{default:{http:["https://rpc.gnosischain.com"]},public:{http:["https://rpc.gnosischain.com"]}},blockExplorers:{etherscan:{name:"Gnosisscan",url:"https://gnosisscan.io/"},default:{name:"Gnosis Chain Explorer",url:"https://blockscout.com/xdai/mainnet/"}}}),(0,o.ax)({id:10200,name:"Gnosis Chiado",network:"chiado",nativeCurrency:{decimals:18,name:"Gnosis",symbol:"xDAI"},rpcUrls:{default:{http:["https://rpc.chiadochain.net"]},public:{http:["https://rpc.chiadochain.net"]}},blockExplorers:{default:{name:"Blockscout",url:"https://blockscout.chiadochain.net"}}}),(0,o.ax)({id:11235,name:"HAQQ Mainnet",network:"haqq-mainnet",nativeCurrency:{decimals:18,name:"Islamic Coin",symbol:"ISLM"},rpcUrls:{default:{http:["https://rpc.eth.haqq.network"]},public:{http:["https://rpc.eth.haqq.network"]}},blockExplorers:{default:{name:"HAQQ Explorer",url:"https://explorer.haqq.network"}}}),(0,o.ax)({id:54211,name:"HAQQ Testedge 2",network:"haqq-testedge-2",nativeCurrency:{decimals:18,name:"Islamic Coin",symbol:"ISLMT"},rpcUrls:{default:{http:["https://rpc.eth.testedge2.haqq.network"]},public:{http:["https://rpc.eth.testedge2.haqq.network"]}},blockExplorers:{default:{name:"HAQQ Explorer",url:"https://explorer.testedge2.haqq.network"}}}),(0,o.ax)({id:31337,name:"Hardhat",network:"hardhat",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{default:{http:["http://127.0.0.1:8545"]},public:{http:["http://127.0.0.1:8545"]}}}),(0,o.ax)({id:16666e5,name:"Harmony One",network:"harmony",nativeCurrency:{name:"Harmony",symbol:"ONE",decimals:18},rpcUrls:{public:{http:["https://rpc.ankr.com/harmony"]},default:{http:["https://rpc.ankr.com/harmony"]}},blockExplorers:{default:{name:"Harmony Explorer",url:"https://explorer.harmony.one"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:24185753}}}),(0,o.ax)({id:8217,name:"Klaytn",network:"klaytn",nativeCurrency:{decimals:18,name:"Klaytn",symbol:"KLAY"},rpcUrls:{default:{http:["https://cypress.fautor.app/archive"]},public:{http:["https://cypress.fautor.app/archive"]}},blockExplorers:{etherscan:{name:"KlaytnScope",url:"https://scope.klaytn.com"},default:{name:"KlaytnScope",url:"https://scope.klaytn.com"}}}),(0,o.ax)({id:59140,name:"Linea Goerli Testnet",network:"linea-testnet",n
1097ativeCurrency:{name:"Linea Ether",symbol:"ETH",decimals:18},rpcUrls:{infura:{http:["https://consensys-zkevm-goerli-prealpha.infura.io/v3"],webSocket:["wss://consensys-zkevm-goerli-prealpha.infura.io/ws/v3"]},default:{http:["https://rpc.goerli.linea.build"],webSocket:["wss://rpc.goerli.linea.build"]},public:{http:["https://rpc.goerli.linea.build"],webSocket:["wss://rpc.goerli.linea.build"]}},blockExplorers:{default:{name:"BlockScout",url:"https://explorer.goerli.linea.build"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:498623}},testnet:!0}),(0,o.ax)({id:1337,name:"Localhost",network:"localhost",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{default:{http:["http://127.0.0.1:8545"]},public:{http:["http://127.0.0.1:8545"]}}});let m=(0,o.ax)({id:1,network:"homestead",name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-mainnet.g.alchemy.com/v2"],webSocket:["wss://eth-mainnet.g.alchemy.com/v2"]},infura:{http:["https://mainnet.infura.io/v3"],webSocket:["wss://mainnet.infura.io/ws/v3"]},default:{http:["https://cloudflare-eth.com"]},public:{http:["https://cloudflare-eth.com"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://etherscan.io"},default:{name:"Etherscan",url:"https://etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xE4Acdd618deED4e6d2f03b9bf62dc6118FC9A4da",blockCreated:16773775},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}});(0,o.ax)({id:1088,name:"Metis",network:"andromeda",nativeCurrency:{decimals:18,name:"Metis",symbol:"METIS"},rpcUrls:{default:{http:["https://andromeda.metis.io/?owner=1088"]},public:{http:["https://andromeda.metis.io/?owner=1088"]}},blockExplorers:{default:{name:"Andromeda Explorer",url:"https://andromeda-explorer.metis.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:2338552}}}),(0,o.ax)({id:599,name:"Metis Goerli",network:"metis-goerli",nativeCurrency:{decimals:18,name:"Metis Goerli",symbol:"METIS"},rpcUrls:{default:{http:["https://goerli.gateway.metisdevops.link"]},public:{http:["https://goerli.gateway.metisdevops.link"]}},blockExplorers:{default:{name:"Metis Goerli Explorer",url:"https://goerli.explorer.metisdevops.link"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:1006207}}}),(0,o.ax)({id:1287,name:"Moonbase Alpha",network:"moonbase-alpha",nativeCurrency:{decimals:18,name:"DEV",symbol:"DEV"},rpcUrls:{default:{http:["https://rpc.api.moonbase.moonbeam.network"],webSocket:["wss://wss.api.moonbase.moonbeam.network"]},public:{http:["https://rpc.api.moonbase.moonbeam.network"],webSocket:["wss://wss.api.moonbase.moonbeam.network"]}},blockExplorers:{default:{name:"Moonscan",url:"https://moonbase.moonscan.io"},etherscan:{name:"Moonscan",url:"https://moonbase.moonscan.io"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:1850686}},testnet:!0}),(0,o.ax)({id:1284,name:"Moonbeam",network:"moonbeam",nativeCurrency:{decimals:18,name:"GLMR",symbol:"GLMR"},rpcUrls:{public:{http:["https://moonbeam.public.blastapi.io"],webSocket:["wss://moonbeam.public.blastapi.io"]},default:{http:["https://moonbeam.public.blastapi.io"],webSocket:["wss://moonbeam.public.blastapi.io"]}},blockExplorers:{default:{name:"Moonscan",url:"https://moonscan.io"},etherscan:{name:"Moonscan",url:"https://moonscan.io"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:609002}},testnet:!1}),(0,o.ax)({id:1285,name:"Moonriver",network:"moonriver",nativeCurrency:{decimals:18,name:"MOVR",symbol:"MOVR"},rpcUrls:{public:{http:["https://moonriver.public.blastapi.io"],webSocket:["wss://moonriver.public.blastapi.io"]},default:{http:["https://moonriver.public.blastapi.io"],webSocket:["wss://moonriver.public.blastapi.io"]}},blockExplorers:{default:{name:"Moonscan",url:"https://moonriver.moonscan.io"},etherscan:{name:"Moonscan",url:"https://moonriver.moonscan.io"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:1597904}},testnet:!1}),(0,o.ax)({id:4242,name:"Nexi",network:"nexi",nativeCurrency:{name:"Nexi",symbol:"NEXI",decimals:18},rpcUrls:{default:{http:["https://rpc.chain.nexi.technology"]},public:{http:["https://rpc.chain.nexi.technology"]}},blockExplorers:{etherscan:{name:"NexiScan",url:"https://www.nexiscan.com"},default:{name:"NexiScan",url:"https://www.nexiscan.com"}},contracts:{multicall3:{address:"0x0277A46Cc69A57eE3A6C8c158bA874832F718B8E",blockCreated:25770160}}}),(0,o.ax)({id:66,name:"OKC",network:"okc",nativeCurrency:{decimals:18,name:"OKT",symbol
1097:"OKT"},rpcUrls:{default:{http:["https://exchainrpc.okex.org"]},public:{http:["https://exchainrpc.okex.org"]}},blockExplorers:{default:{name:"oklink",url:"https://www.oklink.com/okc"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:10364792}}}),(0,o.ax)({id:10,name:"Optimism",network:"optimism",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://opt-mainnet.g.alchemy.com/v2"],webSocket:["wss://opt-mainnet.g.alchemy.com/v2"]},infura:{http:["https://optimism-mainnet.infura.io/v3"],webSocket:["wss://optimism-mainnet.infura.io/ws/v3"]},default:{http:["https://mainnet.optimism.io"]},public:{http:["https://mainnet.optimism.io"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://optimistic.etherscan.io"},default:{name:"Optimism Explorer",url:"https://explorer.optimism.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:4286263}}}),(0,o.ax)({id:420,name:"Optimism Goerli",network:"optimism-goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://opt-goerli.g.alchemy.com/v2"],webSocket:["wss://opt-goerli.g.alchemy.com/v2"]},infura:{http:["https://optimism-goerli.infura.io/v3"],webSocket:["wss://optimism-goerli.infura.io/ws/v3"]},default:{http:["https://goerli.optimism.io"]},public:{http:["https://goerli.optimism.io"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli-optimism.etherscan.io"},default:{name:"Etherscan",url:"https://goerli-optimism.etherscan.io"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:49461}},testnet:!0}),(0,o.ax)({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}}});let b=(0,o.ax)({id:80001,name:"Polygon Mumbai",network:"maticmum",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mumbai.g.alchemy.com/v2"],webSocket:["wss://polygon-mumbai.g.alchemy.com/v2"]},infura:{http:["https://polygon-mumbai.infura.io/v3"],webSocket:["wss://polygon-mumbai.infura.io/ws/v3"]},default:{http:["https://matic-mumbai.chainstacklabs.com"]},public:{http:["https://matic-mumbai.chainstacklabs.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"},default:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:25770160}},testnet:!0});(0,o.ax)({id:1101,name:"Polygon zkEVM",network:"polygon-zkevm",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://zkevm-rpc.com"]},public:{http:["https://zkevm-rpc.com"]}},blockExplorers:{default:{name:"PolygonScan",url:"https://zkevm.polygonscan.com"}}}),(0,o.ax)({id:1442,name:"Polygon zkEVM Testnet",network:"polygon-zkevm-testnet",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://rpc.public.zkevm-test.net"]},public:{http:["https://rpc.public.zkevm-test.net"]}},blockExplorers:{default:{name:"Blockscout",url:"https://explorer.public.zkevm-test.net"}},testnet:!0}),(0,o.ax)({id:369,network:"pulsechain",name:"Pulsechain",nativeCurrency:{name:"Pulse",symbol
1097:"PLS",decimals:18},rpcUrls:{default:{http:["https://rpc.pulsechain.com"],webSocket:["wss://ws.pulsechain.com"]},public:{http:["https://rpc.pulsechain.com"],webSocket:["wss://ws.pulsechain.com"]}},blockExplorers:{default:{name:"Etherscan",url:"https://scan.pulsechain.com"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}}),(0,o.ax)({id:943,network:"pulsechainV4",name:"Pulsechain V4",testnet:!0,nativeCurrency:{name:"Pulse",symbol:"PLS",decimals:18},rpcUrls:{default:{http:["https://rpc.v4.testnet.pulsechain.com"],webSocket:["wss://ws.v4.testnet.pulsechain.com"]},public:{http:["https://rpc.v4.testnet.pulsechain.com"],webSocket:["wss://ws.v4.testnet.pulsechain.com"]}},blockExplorers:{default:{name:"Blockscout",url:"https://scan.v4.testnet.pulsechain.com"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}}),(0,o.ax)({id:534353,name:"Scroll Testnet",network:"scroll-testnet",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://alpha-rpc.scroll.io/l2"],webSocket:["wss://alpha-rpc.scroll.io/l2/ws"]},public:{http:["https://alpha-rpc.scroll.io/l2"],webSocket:["wss://alpha-rpc.scroll.io/l2/ws"]}},blockExplorers:{default:{name:"Blockscout",url:"https://blockscout.scroll.io"}},testnet:!0}),(0,o.ax)({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:6507670}},testnet:!0}),(0,o.ax)({id:391845894,name:"SKALE | Block Brawlers",network:"skale-brawl",nativeCurrency:{name:"BRAWL",symbol:"BRAWL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/frayed-decent-antares"]},public:{http:["https://mainnet.skalenodes.com/v1/frayed-decent-antares"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://frayed-decent-antares.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://frayed-decent-antares.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:1564830818,name:"SKALE | Calypso NFT Hub",network:"skale-calypso",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/honorable-steel-rasalhague"]},public:{http:["https://mainnet.skalenodes.com/v1/honorable-steel-rasalhague"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://honorable-steel-rasalhague.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://honorable-steel-rasalhague.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:344106930,name:"SKALE | Calypso NFT Hub Testnet",network:"skale-calypso-testnet",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://staging-v3.skalenodes.com/v1/staging-utter-unripe-menkar"]},public:{http:["https://staging-v3.skalenodes.com/v1/staging-utter-unripe-menkar"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://staging-utter-unripe-menkar.explorer.staging-v3.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://staging-utter-unripe-menkar.explorer.staging-v3.skalenodes.com"}},contracts:{},testnet:!0}),(0,o.ax)({id:1351057110,name:"SKALE | Chaos Testnet",network:"skale-chaos-testnet",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://staging-v3.skalenodes.com/v1/staging-fast-active-bellatrix"]},public:{http:["https://staging-v3.skalenodes.com/v1/staging-fast-active-bellatrix"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://staging-fast-active-bellatrix.explorer.staging-v3.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://staging-fast-active-bellatrix.explorer.staging-v3.skalenodes.com"}},contracts:{},testnet:!0}),(0,o.ax)({id:1026062157,name:"SKALE | CryptoBlades",network:"skale-cryptoblades",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/affectionate-immediate-pollux"]},public:{http:["https://mainnet.skalenodes.com/v1/affectionate-immediate-pollux"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://affectionate-immediate-pollux.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://affectionate-immediate-pollux.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:2046399126,name:"SKALE | Crypto Colosseum",network:"skale-crypto-coloseeum",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/haunting-devoted-deneb"]},public:{http:["https://mainnet.skalenodes.com/v1/haunting-devoted-deneb"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://haunting-devoted-deneb.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://haunting-devoted-deneb.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:2046399126,name:"SKALE | Europa Liquidity Hub",network:"skale-europa",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/elated-tan-skat"]},public:{http:["https://mainnet.skalenodes.com/v1/elated-tan-skat"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://elated-tan-skat.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://elated-tan-skat.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:476158412,name:"SKALE | Europa Liquidity Hub Testnet",network:"skale-europa-testnet",n
1097ativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://staging-v3.skalenodes.com/v1/staging-legal-crazy-castor"]},public:{http:["https://staging-v3.skalenodes.com/v1/staging-legal-crazy-castor"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://staging-legal-crazy-castor.explorer.staging-v3.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://staging-legal-crazy-castor.explorer.staging-v3.skalenodes.com"}},contracts:{},testnet:!0}),(0,o.ax)({id:2139927552,name:"SKALE | Exorde",network:"skale-exorde",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/light-vast-diphda"]},public:{http:["https://mainnet.skalenodes.com/v1/light-vast-diphda"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://light-vast-diphda.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://light-vast-diphda.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:1273227453,name:"SKALE | Human Protocol",network:"skale-human-protocol",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/wan-red-ain"]},public:{http:["https://mainnet.skalenodes.com/v1/wan-red-ain"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://wan-red-ain.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://wan-red-ain.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:1482601649,name:"SKALE | Nebula Gaming Hub",network:"skale-nebula",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/green-giddy-denebola"]},public:{http:["https://mainnet.skalenodes.com/v1/green-giddy-denebola"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://green-giddy-denebola.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://green-giddy-denebola.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:503129905,name:"SKALE | Nebula Gaming Hub Testnet",network:"skale-nebula-testnet",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://staging-v3.skalenodes.com/v1/staging-faint-slimy-achird"]},public:{http:["https://staging-v3.skalenodes.com/v1/staging-faint-slimy-achird"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://staging-faint-slimy-achird.explorer.staging-v3.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://staging-faint-slimy-achird.explorer.staging-v3.skalenodes.com"}},contracts:{},testnet:!0}),(0,o.ax)({id:278611351,name:"SKALE | Razor Network",network:"skale-razor",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/turbulent-unique-scheat"]},public:{http:["https://mainnet.skalenodes.com/v1/turbulent-unique-scheat"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://turbulent-unique-scheat.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://turbulent-unique-scheat.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:1350216234,name:"SKALE | Titan Community Hub",network:"skale-titan",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://mainnet.skalenodes.com/v1/parallel-stormy-spica"]},public:{http:["https://mainnet.skalenodes.com/v1/parallel-stormy-spica"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://parallel-stormy-spica.explorer.mainnet.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://parallel-stormy-spica.explorer.mainnet.skalenodes.com"}},contracts:{}}),(0,o.ax)({id:1517929550,name:"SKALE | Titan Community Hub Testnet",network:"skale-titan-testnet",nativeCurrency:{name:"sFUEL",symbol:"sFUEL",decimals:18},rpcUrls:{default:{http:["https://staging-v3.skalenodes.com/v1/staging-aware-chief-gianfar"]},public:{http:["https://staging-v3.skalenodes.com/v1/staging-aware-chief-gianfar"]}},blockExplorers:{etherscan:{name:"SKALE Explorer",url:"https://staging-aware-chief-gianfar.explorer.staging-v3.skalenodes.com"},default:{name:"SKALE Explorer",url:"https://staging-aware-chief-gianfar.explorer.staging-v3.skalenodes.com"}},contracts:{},testnet:!0}),(0,o.ax)({id:19,name:"Songbird Mainnet",network:"songbird-mainnet",nativeCurrency:{decimals:18,name:"songbird",symbol:"SGB"},rpcUrls:{default:{http:["https://songbird-api.flare.network/ext/C/rpc"]},public:{http:["https://songbird-api.flare.network/ext/C/rpc"]}},blockExplorers:{default:{name:"Songbird Explorer",url:"https://songbird-explorer.flare.network"}}}
1097),(0,o.ax)({id:16,name:"Coston",network:"coston",nativeCurrency:{decimals:18,name:"costonflare",symbol:"CFLR"},rpcUrls:{default:{http:["https://coston-api.flare.network/ext/C/rpc"]},public:{http:["https://coston-api.flare.network/ext/C/rpc"]}},blockExplorers:{default:{name:"Coston Explorer",url:"https://coston-explorer.flare.network"}},testnet:!0}),(0,o.ax)({id:8082,name:"Shardeum Sphinx",network:"shmSphinx",nativeCurrency:{name:"SHARDEUM",symbol:"SHM",decimals:18},rpcUrls:{default:{http:["https://sphinx.shardeum.org"]},public:{http:["https://sphinx.shardeum.org"]}},blockExplorers:{default:{name:"Shardeum Explorer",url:"https://explorer-sphinx.shardeum.org"}},testnet:!0}),(0,o.ax)({id:57,name:"Syscoin Mainnet",network:"syscoin",nativeCurrency:{decimals:8,name:"Syscoin",symbol:"SYS"},rpcUrls:{default:{http:["https://rpc.syscoin.org"]},public:{http:["https://rpc.syscoin.org"]}},blockExplorers:{default:{name:"SyscoinExplorer",url:"https://explorer.syscoin.org"}},contracts:{multicall3:{address:"0x000562033783B1136159E10d976B519C929cdE8e",blockCreated:80637}}}),(0,o.ax)({id:841,name:"Taraxa Mainnet",network:"taraxa",nativeCurrency:{name:"Tara",symbol:"TARA",decimals:18},rpcUrls:{default:{http:["https://rpc.mainnet.taraxa.io"]},public:{http:["https://rpc.mainnet.taraxa.io"]}},blockExplorers:{default:{name:"Taraxa Explorer",url:"https://explorer.mainnet.taraxa.io"}}}),(0,o.ax)({id:842,name:"Taraxa Testnet",network:"taraxa-testnet",nativeCurrency:{name:"Tara",symbol:"TARA",decimals:18},rpcUrls:{default:{http:["https://rpc.testnet.taraxa.io"]},public:{http:["https://rpc.testnet.taraxa.io"]}},blockExplorers:{default:{name:"Taraxa Explorer",url:"https://explorer.testnet.taraxa.io"}},testnet:!0}),(0,o.ax)({id:40,name:"Telos",network:"telos",nativeCurrency:{decimals:18,name:"Telos",symbol:"TLOS"},rpcUrls:{default:{http:["https://mainnet.telos.net/evm"]},public:{http:["https://mainnet.telos.net/evm"]}},blockExplorers:{default:{name:"Teloscan",url:"https://www.teloscan.io/"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:246530709}}}),(0,o.ax)({id:41,name:"Telos",network:"telosTestnet",nativeCurrency:{decimals:18,name:"Telos",symbol:"TLOS"},rpcUrls:{default:{http:["https://testnet.telos.net/evm"]},public:{http:["https://testnet.telos.net/evm"]}},blockExplorers:{default:{name:"Teloscan (testnet)",url:"https://testnet.teloscan.io/"}},testnet:!0}),(0,o.ax)({id:997,name:"5ireChain Thunder Testnet",network:"5ireChain",nativeCurrency:{name:"5ire Token",symbol:"5IRE",decimals:18},rpcUrls:{default:{http:["https://rpc-testnet.5ire.network"]},public:{http:["https://rpc-testnet.5ire.network"]}},blockExplorers:{default:{name:"5ireChain Explorer",url:"https://explorer.5ire.network"}},testnet:!0}),(0,o.ax)({id:888,name:"Wanchain",network:"wanchain",nativeCurrency:{name:"WANCHAIN",symbol:"WAN",decimals:18},rpcUrls:{default:{http:["https://gwan-ssl.wandevs.org:56891","https://gwan2-ssl.wandevs.org"]},public:{http:["https://gwan-ssl.wandevs.org:56891","https://gwan2-ssl.wandevs.org"]}},blockExplorers:{etherscan:{name:"WanScan",url:"https://wanscan.org"},default:{name:"WanScan",url:"https://wanscan.org"}},contracts:{multicall3:{address:"0xcDF6A1566e78EB4594c86Fe73Fcdc82429e97fbB",blockCreated:25312390}}}),(0,o.ax)({id:999,name:"Wanchain Testnet",network:"wanchainTestnet",nativeCurrency:{name:"WANCHAIN",symbol:"WANt",decimals:18},rpcUrls:{default:{http:["https://gwan-ssl.wandevs.org:46891"]},public:{http:["https://gwan-ssl.wandevs.org:46891"]}},blockExplorers:{etherscan:{name:"WanScanTest",url:"https://wanscan.org"},default:{name:"WanScanTest",url:"https://wanscan.org"}},contracts:{multicall3:{address:"0x11c89bF4496c39FB80535Ffb4c92715839CC5324",blockCreated:24743448}},testnet:!0}),(0,o.ax)({id:50,name:"XinFin Network",network:"xdc",nativeCurrency:{decimals:18,name:"XDC",symbol:"XDC"},rpcUrls:{default:{http:["https://rpc.xinfin.network"]},public:{http:["https://rpc.xinfin.network"]}},blockExplorers:{xinfin:{name:"XinFin",url:"https://explorer.xinfin.network"},default:{name:"Blocksscan",url:"https://xdc.blocksscan.io"}}}),(0,o.ax)({id:51,name:"Apothem Network",network:"xdc-testnet",n
1097ativeCurrency:{decimals:18,name:"TXDC",symbol:"TXDC"},rpcUrls:{default:{http:["https://erpc.apothem.network"]},public:{http:["https://erpc.apothem.network"]}},blockExplorers:{xinfin:{name:"XinFin",url:"https://explorer.apothem.network"},default:{name:"Blocksscan",url:"https://apothem.blocksscan.io"}}}),(0,o.ax)({id:1337803,network:"zhejiang",name:"Zhejiang",nativeCurrency:{name:"Zhejiang Ether",symbol:"ZhejETH",decimals:18},rpcUrls:{default:{http:["https://rpc.zhejiang.ethpandaops.io"]},public:{http:["https://rpc.zhejiang.ethpandaops.io"]}},blockExplorers:{beaconchain:{name:"Etherscan",url:"https://zhejiang.beaconcha.in"},blockscout:{name:"Blockscout",url:"https://blockscout.com/eth/zhejiang-testnet"},default:{name:"Beaconchain",url:"https://zhejiang.beaconcha.in"}},testnet:!0}),(0,o.ax)({id:324,name:"zkSync Era",network:"zksync-era",nativeCurrency:{decimals:18,name:"Ether",symbol:"ETH"},rpcUrls:{default:{http:["https://mainnet.era.zksync.io"],webSocket:["wss://mainnet.era.zksync.io/ws"]},public:{http:["https://mainnet.era.zksync.io"],webSocket:["wss://mainnet.era.zksync.io/ws"]}},blockExplorers:{default:{name:"zkExplorer",url:"https://explorer.zksync.io"}},contracts:{multicall3:{address:"0xF9cda624FBC7e059355ce98a31693d299FACd963"}}}),(0,o.ax)({id:280,name:"zkSync Era Testnet",network:"zksync-era-testnet",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://testnet.era.zksync.dev"],webSocket:["wss://testnet.era.zksync.dev/ws"]},public:{http:["https://testnet.era.zksync.dev"],webSocket:["wss://testnet.era.zksync.dev/ws"]}},blockExplorers:{default:{name:"zkExplorer",url:"https://goerli.explorer.zksync.io"}},contracts:{multicall3:{address:"0xF9cda624FBC7e059355ce98a31693d299FACd963"}},testnet:!0}),(0,o.ax)({id:999,name:"ZORA Goerli Testnet",network:"zora-testnet",nativeCurrency:{decimals:18,name:"ZORA Goerli",symbol:"ETH"},rpcUrls:{default:{http:["https://testnet.rpc.zora.co"],webSocket:["wss://testnet.rpc.zora.co"]},public:{http:["https://testnet.rpc.zora.co"],webSocket:["wss://testnet.rpc.zora.co"]}},blockExplorers:{etherscan:{name:"ZORA",url:"https://testnet.explorer.zora.co"},default:{name:"ZORA",url:"https://testnet.explorer.zora.co"}},contracts:{multicall3:{address:"0xcA11bde05977b3631167028862bE2a173976CA11",blockCreated:189123}},testnet:!0})},1920:function(e,t,n){"use strict";n.d(t,{$o:function(){return l},Ei:function(){return c},F8:function(){return o},lD:function(){return i},nZ:function(){return s}});let o=[{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"}],i=[{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],s=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],c=[{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"}],outputs:[{name:"",type:"address"}]}],l=[{inputs:[{internalType:"address",name:"_signer",type:"address"},{internalType:"bytes32",name:"_hash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"}]},35554:function(e,t,n){"use strict";n.d(t,{$:function(){return o},Up:function(){return i},hZ:function(){return s}});let o={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."}
1097,i={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},s={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"}},58617:function(e,t,n){"use strict";n.d(t,{Bd:function(){return s},Zn:function(){return i},ez:function(){return o}});let o={gwei:9,wei:18},i={ether:-9,wei:9},s={ether:-18,gwei:-9}},5555:function(e,t,n){"use strict";n.d(t,{CI:function(){return InvalidAbiDecodingTypeError},FM:function(){return AbiEventSignatureEmptyTopicsError},Gy:function(){return DecodeLogTopicsMismatch},KY:function(){return BytesSizeMismatchError},M4:function(){return AbiEncodingBytesSizeMismatchError},MX:function(){return AbiFunctionOutputsNotFoundError},SM:function(){return DecodeLogDataMismatch},cO:function(){return AbiConstructorParamsNotFoundError},dh:function(){return InvalidAbiEncodingTypeError},fM:function(){return AbiConstructorNotFoundError},fs:function(){return AbiEncodingLengthMismatchError},gr:function(){return AbiEncodingArrayLengthMismatchError},hn:function(){return InvalidArrayError},lC:function(){return AbiEventSignatureNotFoundError},mv:function(){return AbiEventNotFoundError},wM:function(){return InvalidDefinitionTypeError},wb:function(){return AbiDecodingZeroDataError},xB:function(){return AbiDecodingDataSizeTooSmallError},xL:function(){return AbiFunctionNotFoundError},yP:function(){return AbiErrorSignatureNotFoundError}});var o=n(21494),i=n(51756),s=n(69977);let AbiConstructorNotFoundError=class AbiConstructorNotFoundError extends s.G{constructor({docsPath:e}){super("A constructor was not found on the ABI.\nMake sure you are using the correct ABI and that the constructor exists on it.",{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorNotFoundError"})}};let AbiConstructorParamsNotFoundError=class AbiConstructorParamsNotFoundError extends s.G{constructor({docsPath:e}){super("Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.\nMake sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists.",{docsPath:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorParamsNotFoundError"})}};let AbiDecodingDataSizeTooSmallError=class AbiDecodingDataSizeTooSmallError extends s.G{constructor({data:e,params:t,size:n}){super(`Data size of ${n} bytes is too small for given parameters.`,{metaMessages:[`Params: (${(0,o.h)(t,{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=t,this.size=n}};let AbiDecodingZeroDataError=class AbiDecodingZeroDataError extends s.G{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingZeroDataError"})}};let AbiEncodingArrayLengthMismatchError=class AbiEncodingArrayLengthMismatchError extends s.G{constructor({expectedLength:e,givenLength:t,type:n}){super(`ABI encoding array length mismatch for type ${n}.
1098Expected length: ${e}
1099Given length: ${t}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}};let AbiEncodingBytesSizeMismatchError=class AbiEncodingBytesSizeMismatchError extends s.G{constructor({expectedSize:e,value:t}){super(`Size of bytes "${t}" (bytes${(0,i.d)(t)}) does not match expected size (bytes${e}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}};let AbiEncodingLengthMismatchError=class AbiEncodingLengthMismatchError extends s.G{constructor({expectedLength:e,givenLength:t}){super(`ABI encoding params/values length mismatch.
1100Expected length (params): ${e}
1101Given length (values): ${t}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}};let AbiErrorSignatureNotFoundError=class AbiErrorSignatureNotFoundError extends s.G{constructor(e,{docsPath:t}){super(`Encoded error signature "${e}" not found on ABI.
1102Make sure you are using the correct ABI and that the error exists on it.
1103You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorSignatureNotFoundError"})}};let AbiEventSignatureEmptyTopicsError=class AbiEventSignatureEmptyTopicsError extends s.G{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"})}};let AbiEventSignatureNotFoundError=class AbiEventSignatureNotFoundError extends s.G{constructor(e,{docsPath:t}){super(`Encoded event signature "${e}" not found on ABI.
1104Make sure you are using the correct ABI and that the event exists on it.
1105You can look up the signature here: https://openchain.xyz/signatures?query=${e}.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureNotFoundError"})}};let AbiEventNotFoundError=class AbiEventNotFoundError extends s.G{constructor(e,{docsPath:t}={}){super(`Event ${e?`"${e}" `:""}not found on ABI.
1106Make sure you are using the correct ABI and that the event exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventNotFoundError"})}};let AbiFunctionNotFoundError=class AbiFunctionNotFoundError extends s.G{constructor(e,{docsPath:t}={}){super(`Function ${e?`"${e}" `:""}not found on ABI.
1107Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}};let AbiFunctionOutputsNotFoundError=class AbiFunctionOutputsNotFoundError extends s.G{constructor(e,{docsPath:t}){super(`Function "${e}" does not contain any \`outputs\` on ABI.
1108Cannot decode function result without knowing what the parameter types are.
1109Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionOutputsNotFoundError"})}};let BytesSizeMismatchError=class BytesSizeMismatchError extends s.G{constructor({expectedSize:e,givenSize:t}){super(`Expected bytes${e}, got bytes${t}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}};let DecodeLogDataMismatch=class DecodeLogDataMismatch extends s.G{constructor({data:e,params:t,size:n}){super(`Data size of ${n} bytes is too small for non-indexed event parameters.`,{metaMessages:[`Params: (${(0,o.h)(t,{includeName:!0})})`,`Data:   ${e} (${n} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogDataMismatch"}),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=t,this.size=n}};let DecodeLogTopicsMismatch=class DecodeLogTopicsMismatch extends s.G{constructor({abiItem:e,param:t}){super(`Expected a topic for indexed event parameter${t.name?` "${t.name}"`:""} on event "${(0,o.t)(e,{includeName:!0})}".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogTopicsMismatch"})}};let InvalidAbiEncodingTypeError=class InvalidAbiEncodingTypeError extends s.G{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid encoding type.
1110Please provide a valid ABI type.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}};let InvalidAbiDecodingTypeError=class InvalidAbiDecodingTypeError extends s.G{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid decoding type.
1111Please provide a valid ABI type.`,{docsPath:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiDecodingType"})}};let InvalidArrayError=class InvalidArrayError extends s.G{constructor(e){super(`Value "${e}" is not a valid array.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}};let InvalidDefinitionTypeError=class InvalidDefinitionTypeError extends s.G{constructor(e){super(`"${e}" is not a valid definition type.
1112Valid types: "function", "event", "error"`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}}},92960:function(e,t,n){"use strict";n.d(t,{b:function(){return InvalidAddressError}});var o=n(69977);let InvalidAddressError=class InvalidAddressError extends o.G{constructor({address:e}){super(`Address "${e}
1112" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}}},69977:function(e,t,n){"use strict";n.d(t,{G:function(){return BaseError}});var o,i,s=n(20966),__classPrivateFieldGet=function(e,t,n,o){if("a"===n&&!o)throw TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!o:!t.has(e))throw TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?o:"a"===n?o.call(e):o?o.value:t.get(e)};let BaseError=class BaseError extends Error{constructor(e,t={}){super(),o.add(this),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:(0,s.bo)()});let n=t.cause instanceof BaseError?t.cause.details:t.cause?.message?t.cause.message:t.details,i=t.cause instanceof BaseError&&t.cause.docsPath||t.docsPath;this.message=[e||"An error occurred.","",...t.metaMessages?[...t.metaMessages,""]:[],...i?[`Docs: https://viem.sh${i}.html${t.docsSlug?`#${t.docsSlug}`:""}`]:[],...n?[`Details: ${n}`]:[],`Version: ${this.version}`].join("\n"),t.cause&&(this.cause=t.cause),this.details=n,this.docsPath=i,this.metaMessages=t.metaMessages,this.shortMessage=e}walk(e){return __classPrivateFieldGet(this,o,"m",i).call(this,this,e)}};o=new WeakSet,i=function _BaseError_walk(e,t){return t?.(e)?e:e.cause?__classPrivateFieldGet(this,o,"m",_BaseError_walk).call(this,e.cause,t):e}},21973:function(e,t,n){"use strict";n.d(t,{Bk:function(){return ChainNotFoundError},Yl:function(){return ChainMismatchError},mm:function(){return ChainDoesNotSupportContract},pZ:function(){return ClientChainNotConfiguredError}});var o=n(69977);let ChainDoesNotSupportContract=class ChainDoesNotSupportContract extends o.G{constructor({blockNumber:e,chain:t,contract:n}){super(`Chain "${t.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"})}};let ChainMismatchError=class ChainMismatchError extends o.G{constructor({chain:e,currentChainId:t}){super(`The current chain of the wallet (id: ${t}) does not match the target chain for the transaction (id: ${e.id} – ${e.name}).`,{metaMessages:[`Current Chain ID:  ${t}`,`Expected Chain ID: ${e.id} – ${e.name}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainMismatchError"})}};let ChainNotFoundError=class ChainNotFoundError extends o.G{constructor(){super("No chain was provided to the request.\nPlease provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotFoundError"})}};let ClientChainNotConfiguredError=class ClientChainNotConfiguredError extends o.G{constructor(){super("No chain was provided to the Client."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ClientChainNotConfiguredError"})}}},90722:function(e,t,n){"use strict";n.d(t,{cg:function(){return CallExecutionError},uq:function(){return ContractFunctionExecutionError},Lu:function(){return ContractFunctionRevertedError},Dk:function(){return ContractFunctionZeroDataError},VQ:function(){return RawContractError}});var o=n(21431),i=n(35554),s=n(11856),c=n(21494),l=n(61344);function formatAbiItemWithArgs({abiItem:e,args:t,includeFunctionName:n=!0,includeName:o=!1}
1112){if("name"in e&&"inputs"in e&&e.inputs)return`${n?e.name:""}(${e.inputs.map((e,n)=>`${o&&e.name?`${e.name}: `:""}${"object"==typeof t[n]?(0,l.P)(t[n]):t[n]}`).join(", ")})`}var u=n(28604),d=n(6665),p=n(56283),m=n(69977),b=n(54574),g=n(20966);let CallExecutionError=class CallExecutionError extends m.G{constructor(e,{account:t,docsPath:n,chain:i,data:s,gas:c,gasPrice:l,maxFeePerGas:u,maxPriorityFeePerGas:m,nonce:g,to:y,value:v}){let E=t?(0,o.T)(t):void 0,x=(0,b.xr)({from:E?.address,to:y,value:void 0!==v&&`${(0,d.d)(v)} ${i?.nativeCurrency.symbol||"ETH"}`,data:s,gas:c,gasPrice:void 0!==l&&`${(0,p.o)(l)} gwei`,maxFeePerGas:void 0!==u&&`${(0,p.o)(u)} gwei`,maxPriorityFeePerGas:void 0!==m&&`${(0,p.o)(m)} gwei`,nonce:g});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Raw Call Arguments:",x].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}};let ContractFunctionExecutionError=class ContractFunctionExecutionError extends m.G{constructor(e,{abi:t,args:n,contractAddress:o,docsPath:i,functionName:s,sender:l}){let d=(0,u.m)({abi:t,args:n,name:s}),p=d?formatAbiItemWithArgs({abiItem:d,args:n,includeFunctionName:!1,includeName:!1}):void 0,m=d?(0,c.t)(d,{includeName:!0}):void 0,y=(0,b.xr)({address:o&&(0,g.CR)(o),function:m,args:p&&"()"!==p&&`${[...Array(s?.length??0).keys()].map(()=>" ").join("")}${p}`,sender:l});super(e.shortMessage||`An unknown error occurred while executing the contract function "${s}".`,{cause:e,docsPath:i,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Contract Call:",y].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=t,this.args=n,this.cause=e,this.contractAddress=o,this.functionName=s,this.sender=l}};let ContractFunctionRevertedError=class ContractFunctionRevertedError extends m.G{constructor({abi:e,data:t,functionName:n,message:o}){let l,u,d;if(t&&"0x"!==t){d=(0,s.p)({abi:e,data:t});let{abiItem:n,errorName:o,args:p}=d;if("Error"===o)u=p[0];else if("Panic"===o){let[e]=p;u=i.$[e]}else{let e=n?(0,c.t)(n,{includeName:!0}):void 0,t=n&&p?formatAbiItemWithArgs({abiItem:n,args:p,includeFunctionName:!1,includeName:!1}):void 0;l=[e?`Error: ${e}`:"",t&&"()"!==t?`       ${[...Array(o?.length??0).keys()].map(()=>" ").join("")}${t}`:""]}}else o&&(u=o);super(u&&"execution reverted"!==u?[`The contract function "${n}" reverted with the following reason:`,u].join("\n"):`The contract function "${n}" reverted.`,{metaMessages:l}),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}),this.reason=u,this.data=d}};let ContractFunctionZeroDataError=class ContractFunctionZeroDataError extends m.G{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"})}};let RawContractError=class RawContractError extends m.G{constructor({data:e,message:t}){super(t||""),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}}},98309:function(e,t,n){"use strict";n.d(t,{$:function(){return SizeExceedsPaddingSizeError},m:function(){return SliceOffsetOutOfBoundsError}});var o=n(69977);let SliceOffsetOutOfBoundsError=class SliceOffsetOutOfBoundsError extends o.G{constructor({offset:e,position:t,size:n}){super(`Slice ${"start"===t?"starting":"ending"} at offset "${e}" is out-of-bounds (size: ${n}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}};let SizeExceedsPaddingSizeError=class SizeExceedsPaddingSizeError extends o.G{constructor({size:e,targetSize:t,type:n}){super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} size (${e}) exceeds padding size (${t}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}}},89466:function(e,t,n){"use strict";
1112n.d(t,{Cd:function(){return InvalidHexBooleanError},J5:function(){return IntegerOutOfRangeError},M6:function(){return SizeOverflowError}});var o=n(69977);let IntegerOutOfRangeError=class IntegerOutOfRangeError extends o.G{constructor({max:e,min:t,signed:n,size:o,value:i}){super(`Number "${i}" is not in safe ${o?`${8*o}-bit ${n?"signed":"unsigned"} `:""}integer range ${e?`(${t} to ${e})`:`(above ${t})`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntegerOutOfRangeError"})}};let InvalidHexBooleanError=class InvalidHexBooleanError extends o.G{constructor(e){super(`Hex value "${e}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidHexBooleanError"})}};let SizeOverflowError=class SizeOverflowError extends o.G{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed ${t} bytes. Given size: ${e} bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeOverflowError"})}}},64282:function(e,t,n){"use strict";n.d(t,{FK:function(){return EnsAvatarUriResolutionError},Pm:function(){return EnsAvatarInvalidNftUriError},rO:function(){return EnsAvatarInvalidMetadataError},sR:function(){return EnsAvatarUnsupportedNamespaceError}});var o=n(69977);let EnsAvatarInvalidMetadataError=class EnsAvatarInvalidMetadataError extends o.G{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"})}};let EnsAvatarInvalidNftUriError=class EnsAvatarInvalidNftUriError extends o.G{constructor({reason:e}){super(`ENS NFT avatar URI is invalid. ${e}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidNftUriError"})}};let EnsAvatarUriResolutionError=class EnsAvatarUriResolutionError extends o.G{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"})}};let EnsAvatarUnsupportedNamespaceError=class EnsAvatarUnsupportedNamespaceError extends o.G{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"})}}},66054:function(e,t,n){"use strict";n.d(t,{C_:function(){return InsufficientFundsError},G$:function(){return FeeCapTooLowError},Hh:function(){return FeeCapTooHighError},M_:function(){return ExecutionRevertedError},WF:function(){return IntrinsicGasTooHighError},ZI:function(){return NonceTooHighError},cj:function(){return UnknownNodeError},cs:function(){return TipAboveFeeCapError},dR:function(){return IntrinsicGasTooLowError},pZ:function(){return TransactionTypeNotSupportedError},se:function(){return NonceMaxValueError},vU:function(){return NonceTooLowError}});var o=n(56283),i=n(69977);let ExecutionRevertedError=class ExecutionRevertedError extends i.G{constructor({cause:e,message:t}={}){let n=t?.replace("execution reverted: ","")?.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(ExecutionRevertedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(ExecutionRevertedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/});let FeeCapTooHighError=class FeeCapTooHighError extends i.G{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,o.o)(t)} 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"})}};
1112Object.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/});let FeeCapTooLowError=class FeeCapTooLowError extends i.G{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,o.o)(t)}`:""} 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(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/});let NonceTooHighError=class NonceTooHighError extends i.G{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is higher than the next one expected.`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooHighError"})}};Object.defineProperty(NonceTooHighError,"no
1112deMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});let NonceTooLowError=class NonceTooLowError extends i.G{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is lower than the current nonce of the account.
1113Try increasing the nonce or find the latest nonce with \`getTransactionCount\`.`,{cause:e}),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/});let NonceMaxValueError=class NonceMaxValueError extends i.G{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}exceeds the maximum allowed nonce.`,{cause:e}),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/});let InsufficientFundsError=class InsufficientFundsError extends i.G{constructor({cause:e}={}){super("The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account.",{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(InsufficientFundsError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds/});let IntrinsicGasTooHighError=class IntrinsicGasTooHighError extends i.G{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}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"})}};
1113Object.defineProperty(IntrinsicGasTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});let IntrinsicGasTooLowError=class IntrinsicGasTooLowError extends i.G{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}provided for the transaction is too low.`,{cause:e}),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/});let TransactionTypeNotSupportedError=class TransactionTypeNotSupportedError extends i.G{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(TransactionTypeNotSupportedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});let TipAboveFeeCapError=class TipAboveFeeCapError extends i.G{constructor({cause:e,maxPriorityFeePerGas:t,maxFeePerGas:n}={}){super(`The provided tip (\`maxPriorityFeePerGas\`${t?` = ${(0,o.o)(t)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${n?` = ${(0,o.o)(n)} gwei`:""}).`,{cause:e}),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/});let UnknownNodeError=class UnknownNodeError extends i.G{constructor({cause:e}){super(`An error occurred while executing: ${e?.message}`,{cause:e}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownNodeError"})}}},88822:function(e,t,n){"use strict";n.d(t,{Gg:function(){return HttpRequestError},W5:function(){return TimeoutError},bs:function(){return RpcRequestError},c9:function(){return WebSocketRequestError}});var o=n(61344),i=n(69977),s=n(20966);let HttpRequestError=class HttpRequestError extends i.G{constructor({body:e,details:t,headers:n,status:i,url:c}){super("HTTP request failed.",{details:t,metaMessages:[i&&`Status: ${i}`,`URL: ${(0,s.Gr)(c)}`,e&&`Request body: ${(0,o.P)(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=i,this.url=c}};let WebSocketRequestError=class WebSocketRequestError extends i.G{constructor({body:e,details:t,url:n}){super("WebSocket request failed.",{details:t,metaMessages:[`URL: ${(0,s.Gr)(n)}`,`Request body: ${(0,o.P)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WebSocketRequestError"})}};let RpcRequestError=class RpcRequestError extends i.G{constructor({body:e,error:t,url:n}){super("RPC Request failed.",{cause:t,details:t.message,metaMessages:[`URL: ${(0,s.Gr)(n)}`,`Request body: ${(0,o.P)(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=t.code}};let TimeoutError=class TimeoutError extends i.G{constructor({body:e,url:t}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${(0,s.Gr)(t)}`,`Request body: ${(0,o.P)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TimeoutError"})}}},42455:function(e,t,n){"use strict";n.d(t,{B:function(){return InvalidRequestRpcError},GD:function(){return JsonRpcVersionUnsupportedError},I0:function(){return ChainDisconnectedError},KB:function(){return TransactionRejectedRpcError},LX:function(){return MethodNotFoundRpcError},Og:function(){return ResourceNotFoundRpcError},PE:function(){return UnauthorizedProviderError},Pv:function(){return LimitExceededRpcError},Ts:function(){return UnsupportedProviderMethodError},XS:function(){return InternalRpcError},ab:function(){return UserRejectedRequestError},gS:function(){return MethodNotSupportedRpcError},ir:function(){return UnknownRpcError},nY:function(){return InvalidParamsRpcError},pT:function(){return ResourceUnavailableRpcError},s7:function(){return ParseRpcError},u5:function(){return ProviderDisconnectedError},x3:function(){return SwitchChainError},yR:function(){return InvalidInputRpcError}});var o=n(69977),i=n(88822);let RpcError=class RpcError extends o.G{constructor(e,{code:t,docsPath:n,metaMessages:o,shortMessage:s}){super(s,{cause:e,docsPath:n,metaMessages:o||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}
1113),this.name=e.name,this.code=e instanceof i.bs?e.code:t??-1}};let ProviderRpcError=class ProviderRpcError extends RpcError{constructor(e,t){super(e,t),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=t.data}};let ParseRpcError=class ParseRpcError extends RpcError{constructor(e){super(e,{code:-32700,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"})}};let InvalidRequestRpcError=class InvalidRequestRpcError extends RpcError{constructor(e){super(e,{code:-32600,shortMessage:"JSON is not a valid request object."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidRequestRpcError"})}};let MethodNotFoundRpcError=class MethodNotFoundRpcError extends RpcError{constructor(e){super(e,{code:-32601,shortMessage:"The method does not exist / is not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotFoundRpcError"})}};let InvalidParamsRpcError=class InvalidParamsRpcError extends RpcError{constructor(e){super(e,{code:-32602,shortMessage:"Invalid parameters were provided to the RPC method.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParamsRpcError"})}};let InternalRpcError=class InternalRpcError extends RpcError{constructor(e){super(e,{code:-32603,shortMessage:"An internal error was received."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InternalRpcError"})}};let InvalidInputRpcError=class InvalidInputRpcError extends RpcError{constructor(e){super(e,{code:-32e3,shortMessage:"Missing or invalid parameters.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidInputRpcError"})}};let ResourceNotFoundRpcError=class ResourceNotFoundRpcError extends RpcError{constructor(e){super(e,{code:-32001,shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}};let ResourceUnavailableRpcError=class ResourceUnavailableRpcError extends RpcError{constructor(e){super(e,{code:-32002,shortMessage:"Requested resource not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceUnavailableRpcError"})}};let TransactionRejectedRpcError=class TransactionRejectedRpcError extends RpcError{constructor(e){super(e,{code:-32003,shortMessage:"Transaction creation failed."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionRejectedRpcError"})}};let MethodNotSupportedRpcError=class MethodNotSupportedRpcError extends RpcError{constructor(e){super(e,{code:-32004,shortMessage:"Method is not implemented."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotSupportedRpcError"})}};let LimitExceededRpcError=class LimitExceededRpcError extends RpcError{constructor(e){super(e,{code:-32005,shortMessage:"Request exceeds defined limit."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"LimitExceededRpcError"})}};let JsonRpcVersionUnsupportedError=class JsonRpcVersionUnsupportedError extends RpcError{constructor(e){super(e,{code:-32006,shortMessage:"Version of JSON-RPC protocol is not supported."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"JsonRpcVersionUnsupportedError"})}};let UserRejectedRequestError=class UserRejectedRequestError extends ProviderRpcError{constructor(e){super(e,{code:4001,shortMessage:"User rejected the request."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UserRejectedRequestError"})}};let UnauthorizedProviderError=class UnauthorizedProviderError extends ProviderRpcError{constructor(e){super(e,{code:4100,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"})}};let UnsupportedProviderMethodError=class UnsupportedProviderMethodError extends ProviderRpcError{constructor(e){super(e,{code:4200,shortMessage:"The Provider does not support the requested method."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedProviderMethodError"})}};let ProviderDisconnectedError=class ProviderDisconnectedError extends ProviderRpcError{constructor(e){super(e,{code:4900,shortMessage:"The Provider is disconnected from all chains."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderDisconnectedError"})}};let ChainDisconnectedError=class ChainDisconnectedError extends ProviderRpcError{constructor(e){super(e,{code:4901,shortMessage:"The Provider is not connected to the requested chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDisconnectedError"})}};let SwitchChainError=class SwitchChainError extends ProviderRpcError{constructor(e){super(e,{code:4902,shortMessage:"An error occurred when attempting to switch chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SwitchChainError"})}};let UnknownRpcError=class UnknownRpcError extends RpcError{constructor(e){super(e,{shortMessage:"An unknown RPC error occurred."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownRpcError"})}}},54574:function(e,t,n){"use strict";n.d(t,{Bh:function(){return TransactionNotFoundError},Yb:function(){return TransactionReceiptNotFoundError},mc:function(){return WaitForTransactionReceiptTimeoutError},mk:function(){return TransactionExecutionError},xY:function(){return FeeConflictError},xr:function(){return prettyPrint}});
1113var o=n(6665),i=n(56283),s=n(69977);function prettyPrint(e){let t=Object.entries(e).map(([e,t])=>void 0===t||!1===t?null:[e,t]).filter(Boolean),n=t.reduce((e,[t])=>Math.max(e,t.length),0);return t.map(([e,t])=>`  ${`${e}:`.padEnd(n+1)}  ${t}`).join("\n")}let FeeConflictError=class FeeConflictError extends s.G{constructor(){super("Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.\nUse `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeConflictError"})}};let TransactionExecutionError=class TransactionExecutionError extends s.G{constructor(e,{account:t,docsPath:n,chain:s,data:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:b,value:g}){let y=prettyPrint({chain:s&&`${s?.name} (id: ${s?.id})`,from:t?.address,to:b,value:void 0!==g&&`${(0,o.d)(g)} ${s?.nativeCurrency.symbol||"ETH"}`,data:c,gas:l,gasPrice:void 0!==u&&`${(0,i.o)(u)} gwei`,maxFeePerGas:void 0!==d&&`${(0,i.o)(d)} gwei`,maxPriorityFeePerGas:void 0!==p&&`${(0,i.o)(p)} gwei`,nonce:m});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Request Arguments:",y].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}};let TransactionNotFoundError=class TransactionNotFoundError extends s.G{constructor({blockHash:e,blockNumber:t,blockTag:n,hash:o,index:i}){let s="Transaction";n&&void 0!==i&&(s=`Transaction at block time "${n}" at index "${i}"`),e&&void 0!==i&&(s=`Transaction at block hash "${e}" at index "${i}"`),t&&void 0!==i&&(s=`Transaction at block number "${t}" at index "${i}"`),o&&(s=`Transaction with hash "${o}"`),super(`${s} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionNotFoundError"})}};let TransactionReceiptNotFoundError=class TransactionReceiptNotFoundError extends s.G{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"})}};let WaitForTransactionReceiptTimeoutError=class WaitForTransactionReceiptTimeoutError extends s.G{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"})}}},20966:function(e,t,n){"use strict";n.d(t,{CR:function(){return getContractAddress},Gr:function(){return getUrl},bo:function(){return getVersion}});let getContractAddress=e=>e,getUrl=e=>e,getVersion=()=>"[email protected]"},34723:function(e,t,n){"use strict";let o;n.d(t,{uqH:function(){return em.uq},pTd:function(){return eC.pT},x3p:function(){return eC.x3},abR:function(){return eC.ab},vvc:function(){return createPublicClient},Kwp:function(){return createWalletClient},PGm:function(){return custom},tvc:function(){return fallback},dFs:function(){return E.d},bMU:function(){return eD.b},Kn9:function(){return eO.K},rRt:function(){return q.rR},dJM:function(){return http_http},UJv:function(){return ey.U},vqc:function(){return eb.v},eCs:function(){return b.eC},vzr:function(){return parseUnits_parseUnits},O0N:function(){return c.O0},NCw:function(){return b.NC},fyY:function(){return eR.f},jZ:function(){return webSocket_webSocket},Bd4:function(){return ej.Bd}});var i=n(5555),s=n(69977);let FilterTypeNotSupportedError=class FilterTypeNotSupportedError extends s.G{constructor(e){super(`Filter type "${e}" is not supported.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FilterTypeNotSupportedError"})}};var c=n(41327),l=n(56143);let getEventSelector=e=>(0,l.F)(e);var u=n(90707),d=n(62546),p=n(21494),m=n(28604);function encodeEventTopics({abi:e,eventName:t,args:n}){let o=e[0];if(t&&!(o=(0,m.m)({abi:e,args:n,name:t})))throw new i.mv(t,{docsPath:"/docs/contract/encodeEventTopics"});if("event"!==o.type)throw new i.mv(void 0,{docsPath:"/docs/contract/encodeEventTopics"});let s=(0,p.t)(o),c=getEventSelector(s),l=[];
1113if(n&&"inputs"in o){let e=o.inputs?.filter(e=>"indexed"in e&&e.indexed),t=Array.isArray(n)?n:e?.map(e=>n[e.name])??[];l=e?.map((e,n)=>Array.isArray(t[n])?t[n].map((o,i)=>encodeArg({param:e,value:t[n][i]})):t[n]?encodeArg({param:e,value:t[n]}):null)??[]}return[c,...l]}function encodeArg({param:e,value:t}){if("string"===e.type||"bytes"===e.type)return(0,u.w)((0,c.O0)(t));if("tuple"===e.type||e.type.match(/^(.*)\[(\d+)?\]$/))throw new FilterTypeNotSupportedError(e.type);return(0,d.E)([e],[t])}var b=n(46872);function createFilterRequestScope(e,{method:t}){let n={};return"fallback"===e.transport.type&&e.transport.onResponse?.(({method:e,response:o,status:i,transport:s})=>{"success"===i&&t===e&&(n[o]=s.request)}),t=>n[t]||e.request}async function createContractEventFilter_createContractEventFilter(e,{address:t,abi:n,args:o,eventName:i,fromBlock:s,toBlock:c}){let l=createFilterRequestScope(e,{method:"eth_newFilter"}),u=i?encodeEventTopics({abi:n,args:o,eventName:i}):void 0,d=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:"bigint"==typeof s?(0,b.eC)(s):s,toBlock:"bigint"==typeof c?(0,b.eC)(c):c,topics:u}]});return{abi:n,args:o,eventName:i,id:d,request:l(d),type:"event"}}var g=n(21431),y=n(96606),v=n(30826);let AccountNotFoundError=class AccountNotFoundError extends s.G{constructor({docsPath:e}={}){super("Could not find an Account to execute with this Action.\nPlease provide an Account with the `account` argument on the Action, or by supplying an `account` to the WalletClient.",{docsPath:e,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountNotFoundError"})}};var E=n(6665),x=n(56283),P=n(54574);let EstimateGasExecutionError=class EstimateGasExecutionError extends s.G{constructor(e,{account:t,docsPath:n,chain:o,data:i,gas:s,gasPrice:c,maxFeePerGas:l,maxPriorityFeePerGas:u,nonce:d,to:p,value:m}){let b=(0,P.xr)({from:t?.address,to:p,value:void 0!==m&&`${(0,E.d)(m)} ${o?.nativeCurrency.symbol||"ETH"}`,data:i,gas:s,gasPrice:void 0!==c&&`${(0,x.o)(c)} gwei`,maxFeePerGas:void 0!==l&&`${(0,x.o)(l)} gwei`,maxPriorityFeePerGas:void 0!==u&&`${(0,x.o)(u)} gwei`,nonce:d});super(e.shortMessage,{cause:e,docsPath:n,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Estimate Gas Arguments:",b].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}};var _=n(90968),I=n(91019),j=n(95417),R=n(23822),M=n(13134);let BlockNotFoundError=class BlockNotFoundError extends s.G{constructor({blockHash:e,blockNumber:t}){let n="Block";e&&(n=`Block at hash "${e}"`),t&&(n=`Block at number "${t}"`),super(`${n} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlockNotFoundError"})}};var F=n(86101);async function getBlock(e,{blockHash:t,blockNumber:n,blockTag:o="latest",includeTransactions:i=!1}={}){let s=void 0!==n?(0,b.eC)(n):void 0,c=null;if(!(c=t?await e.request({method:"eth_getBlockByHash",params:[t,i]}):await e.request({method:"eth_getBlockByNumber",params:[s||o,i]})))throw new BlockNotFoundError({blockHash:t,blockNumber:n});return(0,j.W)(c,{formatter:e.chain?.formatters?.block||F.Z})}async function getGasPrice(e){let t=await e.request({method:"eth_gasPrice"});return BigInt(t)}var q=n(90169);async function getTransactionCount(e,{address:t,blockTag:n="latest",blockNumber:o}){let i=await e.request({method:"eth_getTransactionCount",params:[t,o?(0,b.eC)(o):n]});return(0,q.ly)(i)}async function prepareRequest(e,t){let{account:n,gas:o,gasPrice:i,maxFeePerGas:c,maxPriorityFeePerGas:l,nonce:u}=t;if(!n)throw new AccountNotFoundError;let d=(0,g.T)(n),p=await getBlock(e,{blockTag:"latest"}),m={...t,from:d.address};if(void 0===u&&(m.nonce=await getTransactionCount(e,{address:d.address,blockTag:"pending"})),p.baseFeePerGas){if(void 0!==i)throw new s.G("Chain does not support legacy `gasPrice`.");if(void 0===c)m.maxPriorityFeePerGas=l??1500000000n,m.maxFeePerGas=120n*p.baseFeePerGas/100n+m.maxPriorityFeePerGas;else{if(void 0===l&&c<1500000000n)throw new s.G("`maxFeePerGas` cannot be less than the default `maxPriorityFeePerGas` (1.5 gwei).");m.maxFeePerGas=c,m.maxPriorityFeePerGas=l??1500000000n}}else{if(void 0!==c||void 0!==l)throw new s.G("Chain does not support EIP-1559 fees.");void 0===i&&(m.gasPrice=await getGasPrice(e)*120n/100n)}return void 0===o&&(m.gas=await estimateGas(e,{...m,account:{address:d.address,type:"json-rpc"}})),(0,M.F)(m),m}async function estimateGas(e,t){let n=t.account??e.account;if(!n)throw new AccountNotFoundError({docsPath:"/docs/actions/public/estimateGas"});let o=(0,g.T)(n);try{let{accessList:n,blockNumber:i,blockTag:s,data:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:g,value:y,...v}="local"===o.type?await prepareRequest(e,t):t,E=i?(0,b.eC)(i):void 0,x=E||s;(0,M.F)(t);let P=e.chain?.formatters?.transactionRequest,_=(0,j.W)({from:o.address,accessList:n,data:c,gas:l,gasPrice:u,maxFeePerGas:d,maxPriorityFeePerGas:p,nonce:m,to:g,value:y,...(0,I.K)(v,{formatter:P})},{formatter:P||R.t}),F=await e.request({method:"eth_estimateGas",params:x?[_,x]:[_]});return BigInt(F)}catch(n){throw function(e,{docsPath:t,...n}){let o=e;return(0,_.B)(e)&&(o=(0,_.k)(e,n)),new EstimateGasExecutionError(o,{docsPath:t,...n})}(n,{...t,account:o,chain:e.chain})}}async function estimateContractGas_estimateContractGas(e,{abi:t,address:n,args:o,functionName:i,...s}){let c=(0,y.R)({abi:t,args:o,functionName:i});try{let t=await estimateGas(e,{data:c,to:n,...s});return t}catch(c){let e=s.account?(0,g.T)(s.account):void 0;throw(0,v.S)(c,{abi:t,address:n,args:o,docsPath:"/docs/contract/simulateContract",functionName:i,sender:e?.address})}}var H=n(91024),z=n(31826),W=n(425);async function simulateContract_simulateContract(e,{abi:t,address:n,args:o,dataSuffix:i,functionName:s,...c}){let l=c.account?(0,g.T)(c.account):void 0,u=(0,y.R)({abi:t,args:o,functionName:s});try{let{data:l}=await (0,W.R)(e,{batch:!1,data:`${u}${i?i.replace("0x",""):""}`,to:n,...c}),d=(0,z.k)({abi:t,args:o,functionName:s,data:l||"0x"});return{result:d,request:{abi:t,address:n,args:o,functionName:s,...c}}}catch(e){throw(0,v.S)(e,{abi:t,address:n,args:o,docsPath:"/docs/contract/simulateContract",functionName:s,sender:l?.address})}}let K=new Map,Q=new Map,Z=0;function observe(e,t,n){let o=++Z,getListeners=()=>K.get(e)||[],unsubscribe=()=>{let t=getListeners();K.set(e,t.filter(e=>e.id!==o))},unwatch=()=>{let t=Q.get(e);1===getListeners().length&&t&&t(),unsubscribe()},i=getListeners();if(K.set(e,[...i,{id:o,fns:t}]),i&&i.length>0)return unwatch;let s={};for(let e in t)s[e]=(...t)=>{let n=getListeners();
11130!==n.length&&n.forEach(n=>n.fns[e]?.(...t))};let c=n(s);return"function"==typeof c&&Q.set(e,c),unwatch}async function wait(e){return new Promise(t=>setTimeout(t,e))}function poll(e,{emitOnBegin:t,initialWaitTime:n,interval:o}){let i=!0,unwatch=()=>i=!1,watch=async()=>{let s;t&&(s=await e({unpoll:unwatch}));let c=await n?.(s)??o;await wait(c);let poll=async()=>{i&&(await e({unpoll:unwatch}),await wait(o),poll())};poll()};return watch(),unwatch}var X=n(61344);let Y=new Map,J=new Map;async function withCache(e,{cacheKey:t,maxAge:n=1/0}){let o=function(e){let buildCache=(e,t)=>({clear:()=>t.delete(e),get:()=>t.get(e),set:n=>t.set(e,n)}),t=buildCache(e,Y),n=buildCache(e,J);return{clear:()=>{t.clear(),n.clear()},promise:t,response:n}}(t),i=o.response.get();if(i&&n>0){let e=new Date().getTime()-i.created.getTime();if(e<n)return i.data}let s=o.promise.get();s||(s=e(),o.promise.set(s));try{let e=await s;return o.response.set({created:new Date,data:e}),e}finally{o.promise.clear()}}let cacheKey=e=>`blockNumber.${e}`;async function getBlockNumber(e,{maxAge:t=e.pollingInterval}={}){let n=await withCache(()=>e.request({method:"eth_blockNumber"}),{cacheKey:cacheKey(e.uid),maxAge:t});return BigInt(n)}var et=n(70558);let eo="/docs/contract/decodeEventLog";function decodeEventLog({abi:e,data:t,topics:n}){let[o,...s]=n;if(!o)throw new i.FM({docsPath:eo});let c=e.find(e=>"event"===e.type&&o===getEventSelector((0,p.t)(e)));if(!(c&&"name"in c))throw new i.lC(o,{docsPath:eo});let{name:l,inputs:u}=c,d=u?.some(e=>!("name"in e&&e.name)),m=d?[]:{},b=u.filter(e=>"indexed"in e&&e.indexed);if(s.length>0)for(let e=0;e<b.length;e++){let t=b[e],n=s[e];if(!n)throw new i.Gy({abiItem:c,param:t});m[t.name||e]=function({param:e,value:t}){if("string"===e.type||"bytes"===e.type||"tuple"===e.type||e.type.match(/^(.*)\[(\d+)?\]$/))return t;let n=(0,et.r)([e],t)||[];return n[0]}({param:t,value:n})}let g=u.filter(e=>!("indexed"in e&&e.indexed));if(t&&"0x"!==t)try{let e=(0,et.r)(g,t);if(e){if(d)m=[...m,...e];else for(let t=0;t<g.length;t++)m[g[t].name]=e[t]}}catch(e){if(e instanceof i.xB)throw new i.SM({data:e.data,params:e.params,size:e.size});throw e}return{eventName:l,args:Object.values(m).length>0?m:void 0}}var ea=n(18829);async function getFilterChanges(e,{filter:t}){let n=await t.request({method:"eth_getFilterChanges",params:[t.id]});return n.map(e=>{if("string"==typeof e)return e;try{let{eventName:n,args:o}="abi"in t&&t.abi?decodeEventLog({abi:t.abi,data:e.data,topics:e.topics}):{eventName:void 0,args:void 0};return(0,ea.U)(e,{args:o,eventName:n})}catch{return}}).filter(Boolean)}async function getLogs(e,{address:t,blockHash:n,fromBlock:o,toBlock:i,event:s,args:c}={}){let l=[];return s&&(l=encodeEventTopics({abi:[s],eventName:s.name,args:c})),(n?await e.request({method:"eth_getLogs",params:[{address:t,topics:l,blockHash:n}]}):await e.request({method:"eth_getLogs",params:[{address:t,topics:l,fromBlock:"bigint"==typeof o?(0,b.eC)(o):o,toBlock:"bigint"==typeof i?(0,b.eC)(i):i}]})).map(e=>{try{let{eventName:t,args:n}=s?decodeEventLog({abi:[s],data:e.data,topics:e.topics}):{eventName:void 0,args:void 0};return(0,ea.U)(e,{args:n,eventName:t})}catch{return}}).filter(Boolean)}async function uninstallFilter(e,{filter:t}){return t.request({method:"eth_uninstallFilter",params:[t.id]})}var ei=n(61786);async function getChainId(e){let t=await e.request({method:"eth_chainId"});return(0,q.ly)(t)}async function sendTransaction(e,t){let{account:n=e.account,chain:o=e.chain,accessList:i,data:s,gas:c,gasPrice:l,maxFeePerGas:u,maxPriorityFeePerGas:d,nonce:p,to:m,value:b,...y}=t;if(!n)throw new AccountNotFoundError({docsPath:"/docs/actions/wallet/sendTransaction"});let v=(0,g.T)(n);try{let n;if((0,M.F)(t),null!==o&&(n=await getChainId(e),(0,ei.qg)({currentChainId:n,chain:o})),"local"===v.type){let t=await prepareRequest(e,{account:v,accessList:i,chain:o,data:s,gas:c,gasPrice:l,maxFeePerGas:u,maxPriorityFeePerGas:d,nonce:p,to:m,value:b,...y});n||(n=await getChainId(e));let g=await v.signTransaction({chainId:n,...t});return await e.request({method:"eth_sendRawTransaction",params:[g]})}let g=o?.formatters?.transactionRequest,E=(0,j.W)({accessList:i,data:s,from:v.address,gas:c,gasPrice:l,maxFeePerGas:u,maxPriorityFeePerGas:d,nonce:p,to:m,value:b,...(0,I.K)(y,{formatter:g})},{formatter:g||R.t});return await e.request({method:"eth_sendTransaction",params:[E]})}catch(e){throw function(e,{docsPath:t,...n}){let o=e;return(0,_.B)(e)&&(o=(0,_.k)(e,n)),new P.mk(o,{docsPath:t,...n})}(e,{...t,account:v,chain:t.chain||void 0})}}async function writeContract_writeContract(e,{abi:t,address:n,args:o,dataSuffix:i,functionName:s,...c}){let l=(0,y.R)({abi:t,args:o,functionName:s}),u=await sendTransaction(e,{data:`${l}${i?i.replace("0x",""):""}`,to:n,...c});return u}async function createEventFilter(e,{address:t,args:n,event:o,fromBlock:i,toBlock:s}={}){let c=createFilterRequestScope(e,{method:"eth_newFilter"}),l=[];o&&(l=encodeEventTopics({abi:[o],eventName:o.name,args:n}));let u=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:"bigint"==typeof i?(0,b.eC)(i):i,toBlock:"bigint"==typeof s?(0,b.eC)(s):s,...l.length?{topics:l}:{}}]});return{abi:o?[o]:void 0,args:n,eventName:o?o.name:void 0,id:u,request:c(u),type:"event"}}var es=n(9040);let ec="/docs/contract/encodeDeployData";function encodeDeployData({abi:e,args:t,bytecode:n}){if(!t||0===t.length)return n;let o=e.find(e=>"type"in e&&"constructor"===e.type);if(!o)throw new i.fM({docsPath:ec});if(!("inputs"in o)||!o.inputs||0===o.inputs.length)throw new i.cO({docsPath:ec});let s=(0,d.E)(o.inputs,t);return(0,es.SM)([n,s])}async function getBalance(e,{address:t,blockNumber:n,blockTag:o="latest"}){let i=n?(0,b.eC)(n):void 0,s=await e.request({method:"eth_getBalance",params:[t,i||o]});return BigInt(s)}async function getBlockTransactionCount(e,{blockHash:t,blockNumber:n,blockTag:o="latest"}={}){let i=void 0!==n?(0,b.eC)(n):void 0,s=null;return s=t?await e.request({method:"eth_getBlockTransactionCountByHash",params:[t]}):await e.request({method:"eth_getBlockTransactionCountByNumber",params:[i||o]}),(0,q.ly)(s)}async function getBytecode(e,{address:t,blockNumber:n,blockTag:o="latest"}){let i=void 0!==n?(0,b.eC)(n):void 0,s=await e.request({method:"eth_getCode",params:[t,i||o]});if("0x"!==s)return s}var el=n(93613),eu=n(28314),ed=n(39873);async function getFeeHistory(e,{blockCount:t,blockNumber:n,blockTag:o="latest",rewardPercentiles:i}){let s=n?(0,b.eC)(n):void 0,c=await e.request({method:"eth_feeHistory",params:[(0,b.eC)(t),s||o,i]});return{baseFeePerGas:c.baseFeePerGas.map(e=>BigInt(e)),gasUsedRatio:c.gasUsedRatio,oldestBlock:BigInt(c.oldestBlock),reward:c.reward?.map(e=>e.map(e=>BigInt(e)))}}async function getFilterLogs(e,{filter:t}){let n=await t.request({method:"eth_getFilterLogs",params:[t.id]});return n.map(e=>{try{let{eventName:n,args:o}="abi"in t&&t.abi?decodeEventLog({abi:t.abi,data:e.data,topics:e.topics}):{eventName:void 0,args:void 0};return(0,ea.U)(e,{args:o,eventName:n})}catch{return}}
1113).filter(Boolean)}async function getStorageAt(e,{address:t,blockNumber:n,blockTag:o="latest",slot:i}){let s=void 0!==n?(0,b.eC)(n):void 0,c=await e.request({method:"eth_getStorageAt",params:[t,i,s||o]});return c}var ef=n(94216);async function getTransaction(e,{blockHash:t,blockNumber:n,blockTag:o="latest",hash:i,index:s}){let c=void 0!==n?(0,b.eC)(n):void 0,l=null;if(i?l=await e.request({method:"eth_getTransactionByHash",params:[i]}):t?l=await e.request({method:"eth_getTransactionByBlockHashAndIndex",params:[t,(0,b.eC)(s)]}):(c||o)&&(l=await e.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[c||o,(0,b.eC)(s)]})),!l)throw new P.Bh({blockHash:t,blockNumber:n,blockTag:o,hash:i,index:s});return(0,j.W)(l,{formatter:e.chain?.formatters?.transaction||ef.Tr})}async function getTransactionConfirmations(e,{hash:t,transactionReceipt:n}){let[o,i]=await Promise.all([getBlockNumber(e),t?getTransaction(e,{hash:t}):void 0]),s=n?.blockNumber||i?.blockNumber;return s?o-s+1n:0n}var ep=n(4656);async function getTransactionReceipt(e,{hash:t}){let n=await e.request({method:"eth_getTransactionReceipt",params:[t]});if(!n)throw new P.Yb({hash:t});return(0,j.W)(n,{formatter:e.chain?.formatters?.transactionReceipt||ep.f})}var eh=n(1920),em=n(90722);async function multicall(e,t){let{allowFailure:n=!0,batchSize:o,blockNumber:s,blockTag:c,contracts:l,multicallAddress:u}=t,d=o??("object"==typeof e.batch?.multicall&&e.batch.multicall.batchSize||1024),p=u;if(!p){if(!e.chain)throw Error("client chain not configured. multicallAddress is required.");p=(0,ei.LI)({blockNumber:s,chain:e.chain,contract:"multicall3"})}let m=[[]],b=0,g=0;for(let e=0;e<l.length;e++){let{abi:t,address:o,args:i,functionName:s}=l[e];try{let e=(0,y.R)({abi:t,args:i,functionName:s});g+=e.length,d>0&&g>d&&(b++,g=(e.length-2)/2,m[b]=[]),m[b]=[...m[b],{allowFailure:!0,callData:e,target:o}]}catch(c){let e=(0,v.S)(c,{abi:t,address:o,args:i,docsPath:"/docs/contract/multicall",functionName:s});if(!n)throw e;m[b]=[...m[b],{allowFailure:!0,callData:"0x",target:o}]}}let E=await Promise.all(m.map(t=>(0,H.L)(e,{abi:eh.F8,address:p,args:[t],blockNumber:s,blockTag:c,functionName:"aggregate3"})));return E.flat().map(({returnData:e,success:t},o)=>{let s=m.flat(),{callData:c}=s[o],{abi:u,address:d,functionName:p,args:b}=l[o];try{if("0x"===c)throw new i.wb;if(!t)throw new em.VQ({data:e});let o=(0,z.k)({abi:u,data:e,functionName:p});return n?{result:o,status:"success"}:o}catch(t){let e=(0,v.S)(t,{abi:u,address:d,args:b,docsPath:"/docs/contract/multicall",functionName:p});if(!n)throw e;return{error:e,result:void 0,status:"failure"}}})}function watchBlockNumber(e,{emitOnBegin:t=!1,emitMissed:n=!1,onBlockNumber:o,onError:i,poll:s,pollingInterval:c=e.pollingInterval}){let l,u,d;let p=void 0!==s?s:"webSocket"!==e.transport.type;return p?(()=>{let s=(0,X.P)(["watchBlockNumber",e.uid,t,n,c]);return observe(s,{onBlockNumber:o,onError:i},o=>poll(async()=>{try{let t=await getBlockNumber(e,{maxAge:0});if(l){if(t===l)return;if(t-l>1&&n)for(let e=l+1n;e<t;e++)o.onBlockNumber(e,l),l=e}(!l||t>l)&&(o.onBlockNumber(t,l),l=t)}catch(e){o.onError?.(e)}},{emitOnBegin:t,interval:c}))})():(u=!0,d=()=>u=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newHeads"],onData(e){if(!u)return;let t=(0,q.y_)(e.result?.number);o(t,l),l=t},onError(e){i?.(e)}});d=t,u||d()}catch(e){i?.(e)}})(),d)}async function createPendingTransactionFilter(e){let t=createFilterRequestScope(e,{method:"eth_newPendingTransactionFilter"}),n=await e.request({method:"eth_newPendingTransactionFilter"});return{id:n,request:t(n),type:"transaction"}}function withRetry(e,{delay:t=100,retryCount:n=2,shouldRetry:o=()=>!0}={}){return new Promise((i,s)=>{let attemptRetry=async({count:c=0}={})=>{let retry=async({error:e})=>{let n="function"==typeof t?t({count:c,error:e}):t;n&&await wait(n),attemptRetry({count:c+1})};try{let t=await e();i(t)}catch(e){if(c<n&&await o({count:c,error:e}))return retry({error:e});s(e)}};attemptRetry()})}async function waitForTransactionReceipt(e,{confirmations:t=1,hash:n,onReplaced:o,pollingInterval:i=e.pollingInterval,timeout:s}
1113){let c,l,u;let d=(0,X.P)(["waitForTransactionReceipt",e.uid,n]),p=!1;return new Promise((m,b)=>{s&&setTimeout(()=>b(new P.mc({hash:n})),s);let g=observe(d,{onReplaced:o,resolve:m,reject:b},o=>{let s=watchBlockNumber(e,{emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:i,async onBlockNumber(i){if(p)return;let d=i,done=async e=>{s(),e(),g()};try{if(u){if(d-u.blockNumber+1n<t)return;done(()=>o.resolve(u));return}if(c||(p=!0,await withRetry(async()=>{(c=await getTransaction(e,{hash:n})).blockNumber&&(d=c.blockNumber)},{delay:({count:e})=>200*~~(1<<e),retryCount:6}),p=!1),u=await getTransactionReceipt(e,{hash:n}),t>0&&d-u.blockNumber+1n<t)return;done(()=>o.resolve(u))}catch(n){if(c&&(n instanceof P.Bh||n instanceof P.Yb)){l=c;let n=await getBlock(e,{blockNumber:d,includeTransactions:!0}),i=n.transactions.find(({from:e,nonce:t})=>e===l.from&&t===l.nonce);if(!i||(u=await getTransactionReceipt(e,{hash:i.hash}),d-u.blockNumber+1n<t))return;let s="replaced";i.to===l.to&&i.value===l.value?s="repriced":i.from===i.to&&0n===i.value&&(s="cancelled"),done(()=>{o.onReplaced?.({reason:s,replacedTransaction:l,transaction:i,transactionReceipt:u}),o.resolve(u)})}else done(()=>
1113o.reject(n))}}});return s})})}async function signMessage(e,{account:t=e.account,message:n}){if(!t)throw new AccountNotFoundError({docsPath:"/docs/actions/wallet/signMessage"});let o=(0,g.T)(t);if("local"===o.type)return o.signMessage({message:n});let i="string"==typeof n?(0,b.$G)(n):n.raw instanceof Uint8Array?(0,b.NC)(n.raw):n.raw;return e.request({method:"personal_sign",params:[i,o.address]})}var eb=n(25493),eg=n(92960),ey=n(97451),ev=n(51756);let ew=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,eE=/^(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 validateTypedData({domain:e,message:t,primaryType:n,types:o}){let validateData=(e,t)=>{for(let n of e){let{name:e,type:s}=n,c=t[e],l=s.match(eE);if(l&&("number"==typeof c||"bigint"==typeof c)){let[e,t,n]=l;(0,b.eC)(c,{signed:"int"===t,size:parseInt(n)/8})}if("address"===s&&"string"==typeof c&&!(0,ey.U)(c))throw new eg.b({address:c});let u=s.match(ew);if(u){let[e,t]=u;if(t&&(0,ev.d)(c)!==parseInt(t))throw new i.KY({expectedSize:parseInt(t),givenSize:(0,ev.d)(c)})}let d=o[s];d&&validateData(d,c)}};if(o.EIP712Domain&&e&&validateData(o.EIP712Domain,e),"EIP712Domain"!==n){let e=o[n];validateData(e,t)}}async function signTypedData(e,{account:t=e.account,domain:n,message:o,primaryType:i,types:s}){if(!t)throw new AccountNotFoundError({docsPath:"/docs/actions/wallet/signTypedData"});let c=(0,g.T)(t),l={EIP712Domain:[n?.name&&{name:"name",type:"string"},n?.version&&{name:"version",type:"string"},n?.chainId&&{name:"chainId",type:"uint256"},n?.verifyingContract&&{name:"verifyingContract",type:"address"},n?.salt&&{name:"salt",type:"bytes32"}].filter(Boolean),...s};if(validateTypedData({domain:n,message:o,primaryType:i,types:l}),"local"===c.type)return c.signTypedData({domain:n,primaryType:i,types:l,message:o});let u=(0,X.P)({domain:n??{},primaryType:i,types:l,message:o},(e,t)=>(0,eb.v)(t)?t.toLowerCase():t);return e.request({method:"eth_signTypedData_v4",params:[c.address,u]})}var ex=n(88822),eC=n(42455);let isDeterministicError=e=>"code"in e?-1!==e.code&&-32004!==e.code&&-32005!==e.code&&-32042!==e.code&&-32603!==e.code:e instanceof ex.Gg&&!!e.status&&403!==e.status&&408!==e.status&&413!==e.status&&429!==e.status&&500!==e.status&&502!==e.status&&503!==e.status&&504!==e.status;function createTransport({key:e,name:t,request:n,retryCount:o=3,retryDelay:i=150,timeout:c,type:l},u){return{config:{key:e,name:t,request:n,retryCount:o,retryDelay:i,timeout:c,type:l},request:function(e,{retryDelay:t=150,retryCount:n=3}={}){return async o=>withRetry(async()=>{try{return await e(o)}catch(e){if(-32700===e.code)throw new eC.s7(e);if(-32600===e.code)throw new eC.B(e);if(-32601===e.code)throw new eC.LX(e);if(-32602===e.code)throw new eC.nY(e);if(-32603===e.code)throw new eC.XS(e);if(-32e3===e.code)throw new eC.yR(e);if(-32001===e.code)throw new eC.Og(e);if(-32002===e.code)throw new eC.pT(e);if(-32003===e.code)throw new eC.KB(e);if(-32004===e.code)throw new eC.gS(e);if(-32005===e.code)throw new eC.Pv(e);if(-32006===e.code)throw new eC.GD(e);if(-32042===e.code)throw new eC.gS(e);if(4001===e.code)throw new eC.ab(e);if(4100===e.code)throw new eC.PE(e);if(4200===e.code)throw new eC.Ts(e);if(4900===e.code)throw new eC.u5(e);if(4901===e.code)throw new eC.I0(e);if(4902===e.code)throw new eC.x3(e);if(e instanceof s.G)throw e;throw new eC.ir(e)}},{delay:({count:e,error:n})=>{if(n&&n instanceof ex.Gg){let e=n?.headers?.get("Retry-After");if(e?.match(/\d/))return 1e3*parseInt(e)}return~~(1<<e)*t},retryCount:n,shouldRetry:({error:e})=>!isDeterministicError(e)})}(n,{retryCount:o,retryDelay:i}),value:u}}function custom(e,t={}){let{key:n="custom",name:o="Custom Provider",retryDelay:i}=t;return({retryCount:s})=>createTransport({key:n,name:o,request:e.request.bind(e),retryCount:t.retryCount??s,retryDelay:i,type:"custom"})}function fallback(e,t={}){let{key:n="fallback",name:o="Fallback",rank:i=!1,retryCount:s,retryDelay:c}=t;return({chain:t,pollingInterval:l=4e3,timeout:u})=>{let d=e,onResponse=()=>{},p=createTransport({key:n,name:o,async request({method:e,params:n}){let fetch=async(o=0)=>{let i=d[o]({chain:t,retryCount:0,timeout:u});try{let t=await i.request({method:e,params:n});return onResponse({method:e,params:n,response:t,transport:i,status:"success"}),t}catch(t){if(onResponse({error:t,method:e,params:n,transport:i,status:"error"}),isDeterministicError(t)||o===d.length-1)throw t;return fetch(o+1)}};return fetch()},retryCount:s,retryDelay:c,type:"fallback"},{onResponse:e=>onResponse=e,transports:d.map(e=>e({chain:t,retryCount:0}))});if(i){let e="object"==typeof i?i:{};!function({chain:e,interval:t=4e3,onTransports:n,sampleCount:o=10,timeout:i=1e3,transports:s,weights:c={}}){let{stability:l=.7,latency:u=.3}=c,d=[],rankTransports_=async()=>{let c=await Promise.all(s.map(async t=>{let n,o;let s=t({chain:e,retryCount:0,timeout:i}),c=Date.now();try{await s.request({method:"net_listening"}),o=1}catch{o=0}finally{n=Date.now()}let l=n-c;return{latency:l,success:o}}));d.push(c),d.length>o&&d.shift();let p=Math.max(...d.map(e=>Math.max(...e.map(({latency:e})=>e)))),m=s.map((e,t)=>{let n=d.map(e=>e[t].latency),o=n.reduce((e,t)=>
1113e+t,0)/n.length,i=d.map(e=>e[t].success),s=i.reduce((e,t)=>e+t,0)/i.length;return 0===s?[0,t]:[u*(1-o/p)+l*s,t]}).sort((e,t)=>t[0]-e[0]);n(m.map(([,e])=>s[e])),await wait(t),rankTransports_()};rankTransports_()}({chain:t,interval:e.interval??l,onTransports:e=>d=e,sampleCount:e.sampleCount,timeout:e.timeout,transports:d,weights:e.weights})}return p}}let UrlRequiredError=class UrlRequiredError extends s.G{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro"})}};var eP=n(68583);function withTimeout(e,{errorInstance:t,timeout:n,signal:o}){return new Promise((i,s)=>{(async()=>{let c;try{let l=new AbortController;n>0&&(c=setTimeout(()=>{o?l.abort():s(t)},n)),i(await e({signal:l?.signal}))}catch(e){"AbortError"===e.name&&s(t),s(e)}finally{clearTimeout(c)}})()})}let eT=0;async function http(e,{body:t,fetchOptions:n={},timeout:o=1e4}){let{headers:i,method:s,signal:c}=n;try{let l;let u=await withTimeout(async({signal:l})=>{let u=await fetch(e,{...n,body:(0,X.P)({jsonrpc:"2.0",id:eT++,...t}),headers:{...i,"Content-Type":"application/json"},method:s||"POST",signal:c||(o>0?l:void 0)});return u},{errorInstance:new ex.W5({body:t,url:e}),timeout:o,signal:!0});if(l=u.headers.get("Content-Type")?.startsWith("application/json")?await u.json():await u.text(),!u.ok)throw new ex.Gg({body:t,details:(0,
1113X.P)(l.error)||u.statusText,headers:u.headers,status:u.status,url:e});if(l.error)throw new ex.bs({body:t,error:l.error,url:e});return l}catch(n){if(n instanceof ex.Gg||n instanceof ex.bs||n instanceof ex.W5)throw n;throw new ex.Gg({body:t,details:n.message,url:e})}}let eA=new Map;async function getSocket(e){let t=new URL(e),o=t.toString(),i=eA.get(o);if(i)return i;let{schedule:s}=(0,eP.S)({id:o,fn:async()=>{let e=await n.e(5289).then(n.bind(n,55289));e=e.default?.constructor?e.default:e.WebSocket;let s=new e(t),c=new Map,l=new Map,onMessage=({data:e})=>{let t=JSON.parse(e),n="eth_subscription"===t.method,o=n?t.params.subscription:t.id,i=n?l:c,s=i.get(o);s&&s({data:e}),n||i.delete(o)},onClose=()=>{eA.delete(o),s.removeEventListener("close",onClose),s.removeEventListener("message",onMessage)};return s.addEventListener("close",onClose),s.addEventListener("message",onMessage),s.readyState===e.CONNECTING&&await new Promise((e,t)=>{s&&(s.onopen=e,s.onerror=t)}),i=Object.assign(s,{requests:c,subscriptions:l}),eA.set(o,i),[i]}}),[c,[l]]=await s();return l}async function webSocketAsync(e,{body:t,timeout:n=1e4}){return withTimeout(()=>new Promise((n,o)=>eS.webSocket(e,{body:t,onData:n,onError:o})),{errorInstance:new ex.W5({body:t,url:e.url}),timeout:n})}let eS={http,webSocket:function(e,{body:t,onData:n,onError:o}){if(e.readyState===e.CLOSED||e.readyState===e.CLOSING)throw new ex.c9({body:t,url:e.url,details:"Socket is closed."});let i=eT++,callback=({data:s})=>{let c=JSON.parse(s);("number"!=typeof c.id||i===c.id)&&(c.error?o?.(new ex.bs({body:t,error:c.error,url:e.url})):n?.(c),"eth_subscribe"===t.method&&"string"==typeof c.result&&e.subscriptions.set(c.result,callback),"eth_unsubscribe"===t.method&&e.subscriptions.delete(t.params?.[0]))};return e.requests.set(i,callback),e.send(JSON.stringify({jsonrpc:"2.0",...t,id:i})),e},webSocketAsync};function http_http(e,t={}){let{fetchOptions:n,key:o="http",name:i="HTTP JSON-RPC",retryDelay:s}=t;return({chain:c,retryCount:l,timeout:u})=>{let d=t.retryCount??l,p=u??t.timeout??1e4,m=e||c?.rpcUrls.default.http[0];if(!m)throw new UrlRequiredError;return createTransport({key:o,name:i,async request({method:e,params:t}){let{result:o}=await eS.http(m,{body:{method:e,params:t},fetchOptions:n,timeout:p});return o},retryCount:d,retryDelay:s,timeout:p,type:"http"},{url:e})}}let e_=256;function createClient_createClient({chain:e,key:t="base",name:n="Base Client",pollingInterval:i=4e3,transport:s,type:c="base"}){let{config:l,request:u,value:d}=s({chain:e,pollingInterval:i});return{chain:e,key:t,name:n,pollingInterval:i,request:u,transport:{...l,...d},type:c,uid:function(e=11){if(!o||e_+e>512){o="",e_=0;for(let e=0;e<256;e++)o+=(256+256*Math.random()|0).toString(16).substring(1)}return o.substring(e_,e_+++e)}()}}var eI=n(55573),ek=n(11738);async function createBlockFilter(e){let t=createFilterRequestScope(e,{method:"eth_newBlockFilter"}),n=await e.request({method:"eth_newBlockFilter"});return{id:n,request:t(n),type:"block"}}n(25178),n(11856),n(33283),n(80507),n(28795);var eO=n(92221);function hashStruct({data:e,primaryType:t,types:n}){let o=function encodeData({data:e,primaryType:t,types:n}){let o=[{type:"bytes32"}],i=[function({primaryType:e,types:t}){let n=(0,b.NC)(function({primaryType:e,types:t}){let n="",o=function findTypeDependencies({primaryType:e,types:t},n=new Set){let o=e.match(/^\w*/u),i=o?.[0];if(n.has(i)||void 0===t[i])return n;for(let e of(n.add(i),t[i]))findTypeDependencies({primaryType:e.type,types:t},n);return n}({primaryType:e,types:t});o.delete(e);let i=[e,...Array.from(o).sort()];for(let e of i)n+=`${e}(${t[e].map(({name:e,type:t})=>`${t} ${e}`).join(",")})`;return n}({primaryType:e,types:t}));return(0,u.w)(n)}({primaryType:t,types:n})];for(let s of n[t]){let[t,c]=function encodeField({types:e,name:t,type:n,value:o}){if(void 0!==e[n])return[{type:"bytes32"},(0,u.w)(encodeData({data:o,primaryType:n,types:e}))];if("bytes"===n){let e=o.length%2?"0":"";return o=`0x${e+o.slice(2)}`,[{type:"bytes32"},(0,u.w)(o)]}if("string"===n)return[{type:"bytes32"},(0,u.w)((0,b.NC)(o))];if(n.lastIndexOf("]")===n.length-1){let i=n.slice(0,n.lastIndexOf("[")),s=o.map(n=>encodeField({name:t,type:i,types:e,value:n}));return[{type:"bytes32"},(0,u.w)((0,d.E)(s.map(([e])=>e),s.map(([,e])=>e)))]}return[{type:n},o]}({types:n,name:s.name,type:s.type,value:e[s.name]});o.push(t),i.push(c)}return(0,d.E)(o,i)}({data:e,primaryType:t,types:n});return(0,u.w)(o)}n(7835),n(89466),n(71721),n(21973),n(66054);var ej=n(58617),eB=n(27499);async function verifyHash(e,{address:t,hash:n,signature:o,...i}){let s=(0,eb.v)(o)?o:(0,b.NC)(o);try{let{data:o}=await (0,W.R)(e,{data:encodeDeployData({abi:eh.$o,args:[t,n,s],bytecode:
vendor: 3,588 bytes, line 1113
1113"0x60806040523480156200001157600080fd5b50604051620007003803806200070083398101604081905262000034916200056f565b6000620000438484846200004f565b9050806000526001601ff35b600080846001600160a01b0316803b806020016040519081016040528181526000908060200190933c90507f6492649264926492649264926492649264926492649264926492649264926492620000a68462000451565b036200021f57600060608085806020019051810190620000c79190620005ce565b8651929550909350915060000362000192576000836001600160a01b031683604051620000f5919062000643565b6000604051808303816000865af19150503d806000811462000134576040519150601f19603f3d011682016040523d82523d6000602084013e62000139565b606091505b5050905080620001905760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b505b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90620001c4908b90869060040162000661565b602060405180830381865afa158015620001e2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200020891906200069d565b6001600160e01b031916149450505050506200044a565b805115620002b157604051630b135d3f60e11b808252906001600160a01b03871690631626ba7e9062000259908890889060040162000661565b602060405180830381865afa15801562000277573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200029d91906200069d565b6001600160e01b031916149150506200044a565b8251604114620003195760405162461bcd60e51b815260206004820152603a6024820152600080516020620006e083398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e677468000000000000606482015260840162000187565b620003236200046b565b506020830151604080850151855186939260009185919081106200034b576200034b620006c9565b016020015160f81c9050601b81148015906200036b57508060ff16601c14155b15620003cf5760405162461bcd60e51b815260206004820152603b6024820152600080516020620006e083398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c75650000000000606482015260840162000187565b6040805160008152602081018083528a905260ff83169181019190915260608101849052608081018390526001600160a01b038a169060019060a0016020604051602081039080840390855afa1580156200042e573d6000803e3d6000fd5b505050602060405103516001600160a01b031614955050505050505b9392505050565b60006020825110156200046357600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b03811681146200049f57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b83811015620004d5578181015183820152602001620004bb565b50506000910152565b600082601f830112620004f057600080fd5b81516001600160401b03808211156200050d576200050d620004a2565b604051601f8301601f19908116603f01168101908282118183101715620005385762000538620004a2565b816040528381528660208588010111156200055257600080fd5b62000565846020830160208901620004b8565b9695505050505050565b6000806000606084860312156200058557600080fd5b8351620005928162000489565b6020850151604086015191945092506001600160401b03811115620005b657600080fd5b620005c486828701620004de565b9150509250925092565b600080600060608486031215620005e457600080fd5b8351620005f18162000489565b60208501519093506001600160401b03808211156200060f57600080fd5b6200061d87838801620004de565b935060408601519150808211156200063457600080fd5b50620005c486828701620004de565b6000825162000657818460208701620004b8565b9190910192915050565b828152604060208201526000825180604084015262000688816060850160208701620004b8565b601f01601f1916919091016060019392505050565b600060208284031215620006b057600080fd5b81516001600160e01b0319811681146200044a57600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572"
1113}),...i});return function(e,t){let n=(0,eb.v)(e)?(0,c.O0)(e):e,o=(0,eb.v)(t)?(0,c.O0)(t):t;return(0,eB.Wd)(n,o)}(o??"0x0","0x1")}catch(e){if(e instanceof em.cg)return!1;throw e}}async function verifyMessage_verifyMessage(e,{address:t,message:n,signature:o,...i}){let s=function(e,t){let n="string"==typeof e?(0,c.qX)(e):e.raw instanceof Uint8Array?e.raw:(0,c.O0)(e.raw),o=(0,c.qX)(`\x19Ethereum Signed Message:
1114${n.length}`);return(0,u.w)((0,es.zo)([o,n]),void 0)}(n);return verifyHash(e,{address:t,hash:s,signature:o,...i})}async function verifyTypedData_verifyTypedData(e,{address:t,signature:n,message:o,primaryType:i,types:s,domain:c,...l}){let d=function({domain:e,message:t,primaryType:n,types:o}){let i=void 0===e?{}:e,s={EIP712Domain:[i?.name&&{name:"name",type:"string"},i?.version&&{name:"version",type:"string"},i?.chainId&&{name:"chainId",type:"uint256"},i?.verifyingContract&&{name:"verifyingContract",type:"address"},i?.salt&&{name:"salt",type:"bytes32"}].filter(Boolean),...o};validateTypedData({domain:i,message:t,primaryType:n,types:s});let c=["0x1901"];return i&&c.push(function({domain:e,types:t}){return hashStruct({data:e,primaryType:"EIP712Domain",types:t})}({domain:i,types:s})),"EIP712Domain"!==n&&c.push(hashStruct({data:t,primaryType:n,types:s})),(0,u.w)((0,es.zo)(c))}({message:o,primaryType:i,types:s,domain:c});return verifyHash(e,{address:t,hash:d,signature:n,...l})}let publicActions=e=>({call:t=>(0,W.R)(e,t),createBlockFilter:()=>createBlockFilter(e),createContractEventFilter:t=>createContractEventFilter_createContractEventFilter(e,t),createEventFilter:t=>createEventFilter(e,t),createPendingTransactionFilter:()=>createPendingTransactionFilter(e),estimateContractGas:t=>estimateContractGas_estimateContractGas(e,t),estimateGas:t=>estimateGas(e,t),getBalance:t=>getBalance(e,t),getBlock:t=>getBlock(e,t),getBlockNumber:t=>getBlockNumber(e,t),getBlockTransactionCount:t=>getBlockTransactionCount(e,t),getBytecode:t=>getBytecode(e,t),getChainId:()=>getChainId(e),getEnsAddress:t=>(0,el.O)(e,t),getEnsAvatar:t=>(0,eI.r)(e,t),getEnsName:t=>(0,eu.w)(e,t),getEnsResolver:t=>(0,ed.S)(e,t),getEnsText:t=>(0,ek.g)(e,t),getFeeHistory:t=>getFeeHistory(e,t),getFilterChanges:t=>getFilterChanges(e,t),getFilterLogs:t=>getFilterLogs(e,t),getGasPrice:()=>getGasPrice(e),getLogs:t=>getLogs(e,t),getStorageAt:t=>getStorageAt(e,t),getTransaction:t=>getTransaction(e,t),getTransactionConfirmations:t=>getTransactionConfirmations(e,t),getTransactionCount:t=>getTransactionCount(e,t),getTransactionReceipt:t=>getTransactionReceipt(e,t),multicall:t=>multicall(e,t),readContract:t=>(0,H.L)(e,t),simulateContract:t=>simulateContract_simulateContract(e,t),verifyMessage:t=>verifyMessage_verifyMessage(e,t),verifyTypedData:t=>verifyTypedData_verifyTypedData(e,t),uninstallFilter:t=>uninstallFilter(e,t),waitForTransactionReceipt:t=>waitForTransactionReceipt(e,t),watchBlocks:t=>(function(e,{blockTag:t="latest",emitMissed:n=!1,emitOnBegin:o=!1,onBlock:i,onError:s,includeTransactions:c=!1,poll:l,pollingInterval:u=e.pollingInterval}){let d,p,m;let b=void 0!==l?l:"webSocket"!==e.transport.type;return b?(()=>{let l=(0,X.P)(["watchBlocks",e.uid,n,o,c,u]);return observe(l,{onBlock:i,onError:s},i=>poll(async()=>{try{let o=await getBlock(e,{blockTag:t,includeTransactions:c});if(o.number&&d?.number){if(o.number===d.number)return;if(o.number-d.number>1&&n)for(let t=d?.number+1n;t<o.number;t++){let n=await getBlock(e,{blockNumber:t,includeTransactions:c});i.onBlock(n,d),d=n}}(!d?.number||"pending"===t&&!o?.number||o.number&&o.number>d.number)&&(i.onBlock(o,d),d=o)}catch(e){i.onError?.(e)}},{emitOnBegin:o,interval:u}))})():(p=!0,m=()=>p=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newHeads"],onData(e){if(!p)return;let t=e.result;i(t,d),d=t},onError(e){s?.(e)}});m=t,p||m()}catch(e){s?.(e)}})(),m)})(e,t),watchBlockNumber:t=>watchBlockNumber(e,t),watchContractEvent:t=>(function(e,{abi:t,address:n,args:o,batch:i=!0,eventName:s,onError:c,onLogs:l,pollingInterval:u=e.pollingInterval}){let d=(0,X.P)(["watchContractEvent",n,o,i,e.uid,s,u]);return observe(d,{onLogs:l,onError:c},c=>{let l,d;let p=!1,b=poll(async()=>
1114{if(!p){try{d=await createContractEventFilter_createContractEventFilter(e,{abi:t,address:n,args:o,eventName:s})}catch{}p=!0;return}try{let u;if(d)u=await getFilterChanges(e,{filter:d});else{let i=await getBlockNumber(e);u=l&&l!==i?await getLogs(e,{address:n,args:o,fromBlock:l+1n,toBlock:i,event:(0,m.m)({abi:t,name:s})}):[],l=i}if(0===u.length)return;i?c.onLogs(u):u.forEach(e=>c.onLogs([e]))}catch(e){c.onError?.(e)}},{emitOnBegin:!0,interval:u});return async()=>{d&&await uninstallFilter(e,{filter:d}),b()}})})(e,t),watchEvent:t=>(function(e,{address:t,args:n,batch:o=!0,event:i,onError:s,onLogs:c,pollingInterval:l=e.pollingInterval}){let u=(0,X.P)(["watchEvent",t,n,o,e.uid,i,l]);return observe(u,{onLogs:c,onError:s},s=>{let c,u;let d=!1,p=poll(async()=>{if(!d){try{u=await createEventFilter(e,{address:t,args:n,event:i})}catch{}d=!0;return}try{let l;if(u)l=await getFilterChanges(e,{filter:u});else{let o=await getBlockNumber(e);l=c&&c!==o?await getLogs(e,{address:t,args:n,fromBlock:c+1n,toBlock:o,event:i}):[],c=o}if(0===l.length)return;o?s.onLogs(l):l.forEach(e=>s.onLogs([e]))}catch(e){s.onError?.(e)}},{emitOnBegin:!0,interval:l});return async()=>{u&&await uninstallFilter(e,{filter:u}),p()}})})(e,t),watchPendingTransactions:t=>(function(e,{batch:t=!0,onError:n,onTransactions:o,poll:i,pollingInterval:s=e.pollingInterval}){let c,l;let u=void 0!==i?i:"webSocket"!==e.transport.type;return u?(()=>{let i=(0,X.P)(["watchPendingTransactions",e.uid,t,s]);return observe(i,{onTransactions:o,onError:n},n=>{let o;let i=poll(async()=>{try{if(!o)try{o=await createPendingTransactionFilter(e);return}catch(e){throw i(),e}let s=await getFilterChanges(e,{filter:o});if(0===s.length)return;t?n.onTransactions(s):s.forEach(e=>n.onTransactions([e]))}catch(e){n.onError?.(e)}},{emitOnBegin:!0,interval:s});return async()=>{o&&await uninstallFilter(e,{filter:o}),i()}})})():(c=!0,l=()=>c=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newPendingTransactions"],onData(e){if(!c)return;let t=e.result;o([t])},onError(e){n?.(e)}});l=t,c||l()}catch(e){n?.(e)}})(),l)})(e,t)});function createPublicClient({batch:e,chain:t,key:n="public",name:o="Public Client",transport:i,pollingInterval:s}){let c={batch:e,...createClient_createClient({chain:t,key:n,name:o,pollingInterval:s,transport:i,type:"publicClient"})};return{...c,...publicActions(c)}}async function addChain(e,{chain:t}){let{id:n,name:o,nativeCurrency:i,rpcUrls:s,blockExplorers:c}=t;await e.request({method:"wallet_addEthereumChain",params:[{chainId:(0,b.eC)(n),chainName:o,nativeCurrency:i,rpcUrls:s.default.http,blockExplorerUrls:c?Object.values(c).map(({url:e})=>e):void 0}]})}async function getAddresses(e){let t=await e.request({method:"eth_accounts"});return t.map(e=>(0,eO.x)(e))}async function getPermissions(e){let t=await e.request({method:"wallet_getPermissions"});return t}async function requestAddresses(e){let t=await e.request({method:"eth_requestAccounts"});return t.map(e=>(0,eO.K)(e))}async function requestPermissions(e,t){return e.request({method:"wallet_requestPermissions",params:[t]})}async function switchChain(e,{id:t}){await e.request({method:"wallet_switchEthereumChain",params:[{chainId:(0,b.eC)(t)}]})}async function watchAsset(e,t){let n=await e.request({method:"wallet_watchAsset",params:t});return n}let walletActions=e=>({addChain:t=>addChain(e,t),deployContract:t=>(function(e,{abi:t,args:n,bytecode:o,...i}){let s=encodeDeployData({abi:t,args:n,bytecode:o});return sendTransaction(e,{...i,data:s})})(e,t),getAddresses:()=>getAddresses(e),getChainId:()=>getChainId(e),getPermissions:()=>getPermissions(e),requestAddresses:()=>requestAddresses(e),requestPermissions:t=>requestPermissions(e,t),sendTransaction:t=>sendTransaction(e,t),signMessage:t=>signMessage(e,t),signTypedData:t=>signTypedData(e,t),switchChain:t=>switchChain(e,t),watchAsset:t=>watchAsset(e,t),writeContract:t=>writeContract_writeContract(e,t)});function createWalletClient({account:e,chain:t,transport:n,key:o="wallet",name:i="Wallet Client",pollingInterval:s}){let c={...createClient_createClient({chain:t,key:o,name:i,pollingInterval:s,transport:e=>n({...e,retryCount:0}),type:"walletClient"}),account:e?(0,g.T)(e):void 0};return{...c,...walletActions(c)}}function webSocket_webSocket(e,t={}){let{key:n="webSocket",name:o="WebSocket JSON-RPC",retryDelay:i}=t;return({chain:s,retryCount:c,timeout:l})=>{let u=t.retryCount??c,d=l??t.timeout??1e4,p=e||s?.rpcUrls.default.webSocket?.[0];if(!p)throw new UrlRequiredError;return createTransport({key:n,name:o,async request({method:e,params:t}){let n=await getSocket(p),{result:o}=await eS.webSocketAsync(n,{body:{method:e,params:t},timeout:d});return o},retryCount:u,retryDelay:i,timeout:d,type:"webSocket"},{getSocket:()=>getSocket(p),async subscribe({params:e,onData:t,onError:n}){let o=await getSocket(p),{result:i}=await new Promise((i,s)=>eS.webSocket(o,{body:{method:"eth_subscribe",params:e},onData:e=>{if("number"==typeof e.id){i(e);return}"eth_subscription"===e.method&&t(e.params)},onError:e=>{s(e),n?.(e)}}));return{subscriptionId:i,unsubscribe:async()=>new Promise((e,t)=>
1114eS.webSocket(o,{body:{method:"eth_unsubscribe",params:[i]},onData:e,onError:t}))}}})}}n(64282),n(98309),n(30514),n(3492);var eD=n(60263);function parseUnits_parseUnits(e,t){let[n,o="0"]=e.split("."),i=n.startsWith("-");if(i&&(n=n.slice(1)),o=o.replace(/(0+)$/,""),0===t)n=`${Math.round(Number(`${n}.${o}`))}`,o="";else if(o.length>t){let[e,i,s]=[o.slice(0,t-1),o.slice(t-1,t),o.slice(t)],c=e.match(/^0+/)?.[0].length??0,l=Math.round(Number(`${i}.${s}`));(o=l>9?`${c?e.slice(0,c-1):""}${BigInt(e)+1n}0`:`${e}${l}`).length>t&&(o=o.slice(1),n=`${BigInt(n)+1n}`),o=o.slice(0,t)}else o=o.padEnd(t,"0");return BigInt(`${i?"-":""}${n}${o}`)}var eR=n(26873)},70558:function(e,t,n){"use strict";n.d(t,{r:function(){return decodeAbiParameters}});var o=n(5555),i=n(92221),s=n(51756),c=n(33283),l=n(26873),u=n(90169),d=n(62546);function decodeAbiParameters(e,t){if("0x"===t&&e.length>0)throw new o.wb;if((0,s.d)(t)&&32>(0,s.d)(t))throw new o.xB({data:t,params:e,size:(0,s.d)(t)});return function({data:e,params:t}){let n=[],p=0;for(let m=0;m<t.length;m++){if(p>=(0,s.d)(e))throw new o.xB({data:e,params:t,size:(0,s.d)(e)});let b=t[m],{consumed:g,value:y}=function decodeParam({data:e,param:t,position:n}){let s=(0,d.S)(t.type);if(s){let[o,i]=s;return function(e,{param:t,length:n,position:o}){if(!n){let n=(0,u.ly)((0,c.tP)(e,o,o+32,{strict:!0})),i=(0,u.ly)((0,c.tP)(e,n,n+32,{strict:!0})),s=0,l=[];for(let o=0;o<i;++o){let o=decodeParam({data:(0,c.tP)(e,n+32),param:t,position:s});s+=o.consumed,l.push(o.value)}return{value:l,consumed:32}}if(hasDynamicChild(t)){let i=(0,d.S)(t.type),s=!i?.[0],l=0,p=[];for(let i=0;i<n;++i){let n=(0,u.ly)((0,c.tP)(e,o,o+32,{strict:!0})),d=decodeParam({data:(0,c.tP)(e,n),param:t,position:s?l:32*i});l+=d.consumed,p.push(d.value)}return{value:p,consumed:32}}let i=0,s=[];for(let c=0;c<n;++c){let n=decodeParam({data:e,param:t,position:o+i});i+=n.consumed,s.push(n.value)}return{value:s,consumed:i}}(e,{length:o,param:{...t,type:i},position:n})}if("tuple"===t.type)return function(e,{param:t,position:n}){let o=0===t.components.length||t.components.some(({name:e})=>!e),i=o?[]:{},s=0;if(hasDynamicChild(t)){let l=(0,u.ly)((0,c.tP)(e,n,n+32,{strict:!0}));for(let n=0;n<t.components.length;++n){let u=t.components[n],d=decodeParam({data:(0,c.tP)(e,l),param:u,position:s});s+=d.consumed,i[o?n:u?.name]=d.value}return{consumed:32,value:i}}for(let c=0;c<t.components.length;++c){let l=t.components[c],u=decodeParam({data:e,param:l,position:n+s});s+=u.consumed,i[o?c:l?.name]=u.value}return{consumed:s,value:i}}(e,{param:t,position:n});if("string"===t.type)return function(e,{position:t}){let n=(0,u.ly)((0,c.tP)(e,t,t+32,{strict:!0})),o=(0,u.ly)((0,c.tP)(e,n,n+32,{strict:!0}));if(0===o)return{consumed:32,value:""};let i=(0,u.rR)((0,l.f)((0,c.tP)(e,n+32,n+32+o,{strict:!0})));return{consumed:32,value:i}}(e,{position:n});if(t.type.startsWith("bytes"))return function(e,{param:t,position:n}){let[o,i]=t.type.split("bytes");if(!i){let t=(0,u.ly)((0,c.tP)(e,n,n+32,{strict:!0})),o=(0,u.ly)((0,c.tP)(e,t,t+32,{strict:!0}));if(0===o)return{consumed:32,value:"0x"};let i=(0,c.tP)(e,t+32,t+32+o,{strict:!0});return{consumed:32,value:i}}let s=(0,c.tP)(e,n,n+parseInt(i),{strict:!0});return{consumed:32,value:s}}(e,{param:t,position:n});let p=(0,c.tP)(e,n,n+32,{strict:!0});if(t.type.startsWith("uint")||t.type.startsWith("int"))return function(e,{param:t}){let n=t.type.startsWith("int"),o=parseInt(t.type.split("int")[1]||"256");return{consumed:32,value:o>48?(0,u.y_)(e,{signed:n}):(0,u.ly)(e,{signed:n})}}(p,{param:t});if("address"===t.type)return{consumed:32,value:(0,i.x)((0,c.tP)(p,-20))};if("bool"===t.type)return{consumed:32,value:(0,u.XA)(p)};throw new o.CI(t.type,{docsPath:"/docs/contract/decodeAbiParameters"})}({data:e,param:b,position:p});n.push(y),p+=g}return n}({data:t,params:e})}function hasDynamicChild(e){let{type:t}=e;if("string"===t||"bytes"===t||t.endsWith("[]"))return!0;if("tuple"===t)return e.components?.some(hasDynamicChild);let n=(0,d.S)(e.type);return!!(n&&hasDynamicChild({...e,type:n[1]}))}},11856:function(e,t,n){"use strict";n.d(t,{p:function(){return decodeErrorResult}});var o=n(35554),i=n(5555),s=n(33283),c=n(80507),l=n(70558),u=n(21494);function decodeErrorResult({abi:e,data:t}){let n=(0,s.tP)(t,0,4);if("0x"===n)throw new i.wb;let d=[...e||[],o.Up,o.hZ],p=d.find(e=>"error"===e.type&&n===(0,c.o)((0,u.t)(e)));if(!p)throw new i.yP(n,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:p,args:"inputs"in p&&p.inputs&&p.inputs.length>0?(0,l.r)(p.inputs,(0,s.tP)(t,4)):void 0,errorName:p.name}}},31826:function(e,t,n){"use strict";n.d(t,{k:function(){return decodeFunctionResult}});var o=n(5555),i=n(70558),s=n(28604);let c="/docs/contract/decodeFunctionResult";function decodeFunctionResult({abi:e,args:t,functionName:n,data:l}){let u=e[0];if(n&&!(u=(0,s.m)({abi:e,args:t,name:n})))throw new o.xL(n,{docsPath:c});if("function"!==u.type)throw new o.xL(void 0,{docsPath:c});if(!u.outputs)throw new o.MX(u.name,{docsPath:c});let d=(0,i.r)(u.outputs,l);return d&&d.length>1?d:d&&1===d.length?d[0]:void 0}},62546:function(e,t,n){"use strict";n.d(t,{E:function(){return encodeAbiParameters},S:function(){return getArrayComponents}});var o=n(5555),i=n(92960),s=n(97451),c=n(9040),l=n(28795),u=n(51756),d=n(33283),p=n(46872);function encodeAbiParameters(e,t){if(e.length!==t.length)throw new o.fs({expectedLength:e.length,givenLength:t.length});let n=function({params:e,values:t}){let n=[];for(let m=0;m<e.length;m++)n.push(function prepareParam({param:e,value:t}){let n=getArrayComponents(e.type);if(n){let[i,s]=n;return function(e,{length:t,param:n}){let i=null===t;if(!Array.isArray(e))throw new o.hn(e);if(!i&&e.length!==t)throw new o.gr({expectedLength:t,givenLength:e.length,type:`${n.type}[${t}]`});let s=!1,l=[];for(let t=0;t<e.length;t++){let o=prepareParam({param:n,value:e[t]});o.dynamic&&(s=!0),l.push(o)}if(i||s){let e=encodeParams(l);
1114if(i){let t=(0,p.eC)(l.length,{size:32});return{dynamic:!0,encoded:l.length>0?(0,c.zo)([t,e]):t}}if(s)return{dynamic:!0,encoded:e}}return{dynamic:!1,encoded:(0,c.zo)(l.map(({encoded:e})=>e))}}(t,{length:i,param:{...e,type:s}})}if("tuple"===e.type)return function(e,{param:t}){let n=!1,o=[];for(let i=0;i<t.components.length;i++){let s=t.components[i],c=Array.isArray(e)?i:s.name,l=prepareParam({param:s,value:e[c]});o.push(l),l.dynamic&&(n=!0)}return{dynamic:n,encoded:n?encodeParams(o):(0,c.zo)(o.map(({encoded:e})=>e))}}(t,{param:e});if("address"===e.type)return function(e){if(!(0,s.U)(e))throw new i.b({address:e});return{dynamic:!1,encoded:(0,l.gc)(e.toLowerCase())}}(t);if("bool"===e.type)return{dynamic:!1,encoded:(0,l.gc)((0,p.C4)(t))};if(e.type.startsWith("uint")||e.type.startsWith("int")){let n=e.type.startsWith("int");return function(e,{signed:t}){return{dynamic:!1,encoded:(0,p.eC)(e,{size:32,signed:t})}}(t,{signed:n})}if(e.type.startsWith("bytes"))return function(e,{param:t}){let[n,i]=t.type.split("bytes");if(!i){let t=Math.ceil((0,u.d)(e)/32),n=[];for(let o=0;o<t;o++)n.push((0,l.gc)((0,d.tP)(e,32*o,(o+1)*32),{dir:"right"}));return{dynamic:!0,encoded:(0,c.zo)([(0,l.gc)((0,p.eC)((0,u.d)(e),{size:32})),...n])}}if((0,u.d)(e)!==parseInt(i))throw new o.M4({expectedSize:parseInt(i),value:e});return{dynamic:!1,encoded:(0,l.gc)(e,{dir:"right"})}}(t,{param:e});if("string"===e.type)return function(e){let t=(0,p.$G)(e),n=Math.ceil((0,u.d)(t)/32),o=[];for(let e=0;e<n;e++)o.push((0,l.gc)((0,d.tP)(t,32*e,(e+1)*32),{dir:"right"}));return{dynamic:!0,encoded:(0,c.zo)([(0,l.gc)((0,p.eC)((0,u.d)(t),{size:32})),...o])}}(t);throw new o.dh(e.type,{docsPath:"/docs/contract/encodeAbiParameters"})}({param:e[m],value:t[m]}));return n}({params:e,values:t}),m=encodeParams(n);return 0===m.length?"0x":m}function encodeParams(e){let t=0;for(let n=0;n<e.length;n++){let{dynamic:o,encoded:i}=e[n];o?t+=32:t+=(0,u.d)(i)}let n=[],o=[],i=0;for(let s=0;s<e.length;s++){let{dynamic:c,encoded:l}=e[s];c?(n.push((0,p.eC)(t+i,{size:32})),o.push(l),i+=(0,u.d)(l)):n.push(l)}return(0,c.zo)([...n,...o])}function getArrayComponents(e){let t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}},96606:function(e,t,n){"use strict";n.d(t,{R:function(){return encodeFunctionData}});var o=n(5555),i=n(9040),s=n(80507),c=n(62546),l=n(21494),u=n(28604);function encodeFunctionData({abi:e,args:t,functionName:n}){let d=e[0];if(n&&!(d=(0,u.m)({abi:e,args:t,name:n})))throw new o.xL(n,{docsPath:"/docs/contract/encodeFunctionData"});if("function"!==d.type)throw new o.xL(void 0,{docsPath:"/docs/contract/encodeFunctionData"});let p=(0,l.t)(d),m=(0,s.o)(p),b="inputs"in d&&d.inputs?(0,c.E)(d.inputs,t??[]):void 0;return(0,i.SM)([m,b??"0x"])}},21494:function(e,t,n){"use strict";n.d(t,{h:function(){return formatAbiParams},t:function(){return formatAbiItem}});var o=n(5555);function formatAbiItem(e,{includeName:t=!1}={}){if("function"!==e.type&&"event"!==e.type&&"error"!==e.type)throw new o.wM(e.type);return`${e.name}(${formatAbiParams(e.inputs,{includeName:t})})`}function formatAbiParams(e,{includeName:t=!1}={}){return e?e.map(e=>(function(e,{includeName:t}){return e.type.startsWith("tuple")?`(${formatAbiParams(e.components,{includeName:t})})${e.type.slice(5)}`:e.type+(t&&e.name?` ${e.name}`:"")})(e,{includeName:t})).join(t?", ":","):""}},28604:function(e,t,n){"use strict";n.d(t,{m:function(){return getAbiItem}});var o=n(97451);function getAbiItem({abi:e,args:t=[],name:n}){let i=e.filter(e=>"name"in e&&e.name===n);if(0!==i.length){if(1===i.length)return i[0];for(let e of i){if(!("inputs"in e))continue;if(!t||0===t.length){if(!e.inputs||0===e.inputs.length)return e;continue}if(!e.inputs||0===e.inputs.length)continue;let n=t.every((t,n)=>{let i="inputs"in e&&e.inputs[n];return!!i&&function isArgOfType(e,t){let n=typeof e,i=t.type;switch(i){case"address":return(0,o.U)(e);case"bool":return"boolean"===n;case"function":case"string":return"string"===n;default:if("tuple"===i&&"components"in t)return Object.values(t.components).every((t,n)=>isArgOfType(Object.values(e)[n],t));if(/^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(i))return"number"===n||"bigint"===n;if(/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(i))return"string"===n||e instanceof Uint8Array;
1114if(/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(i))return Array.isArray(e)&&e.every(e=>isArgOfType(e,{...t,type:i.replace(/(\[[0-9]{0,}\])$/,"")}));return!1}}(t,i)});if(n)return e}return i[0]}}},92221:function(e,t,n){"use strict";n.d(t,{K:function(){return getAddress},x:function(){return checksumAddress}});var o=n(92960),i=n(41327),s=n(90707),c=n(97451);function checksumAddress(e,t){let n=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),o=(0,s.w)((0,i.qX)(n),"bytes"),c=(t?n.substring(`${t}0x`.length):n).split("");for(let e=0;e<40;e+=2)o[e>>1]>>4>=8&&c[e]&&(c[e]=c[e].toUpperCase()),(15&o[e>>1])>=8&&c[e+1]&&(c[e+1]=c[e+1].toUpperCase());return`0x${c.join("")}`}function getAddress(e,t){if(!(0,c.U)(e))throw new o.b({address:e});return checksumAddress(e,t)}},97451:function(e,t,n){"use strict";n.d(t,{U:function(){return isAddress}});let o=/^0x[a-fA-F0-9]{40}$/;function isAddress(e){return o.test(e)}},7835:function(e,t,n){"use strict";n.d(t,{E:function(){return isAddressEqual}});var o=n(92960),i=n(97451);function isAddressEqual(e,t){if(!(0,i.U)(e))throw new o.b({address:e});if(!(0,i.U)(t))throw new o.b({address:t});return e.toLowerCase()===t.toLowerCase()}},25178:function(e,t,n){"use strict";n.d(t,{offchainLookup:function(){return offchainLookup},offchainLookupSignature:function(){return g}});var o=n(425),i=n(69977),s=n(61344),c=n(20966);let OffchainLookupError=class OffchainLookupError extends i.G{constructor({callbackSelector:e,cause:t,data:n,extraData:o,sender:i,urls:s}){super(t.shortMessage||"An error occurred while fetching for an offchain result.",{cause:t,metaMessages:[...t.metaMessages||[],t.metaMessages?.length?"":[],"Offchain Gateway Call:",s&&["  Gateway URL(s):",...s.map(e=>`    ${(0,c.Gr)(e)}`)],`  Sender: ${i}`,`  Data: ${n}`,`  Callback selector: ${e}`,`  Extra data: ${o}`].flat()}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupError"})}};let OffchainLookupResponseMalformedError=class OffchainLookupResponseMalformedError extends i.G{constructor({result:e,url:t}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${(0,c.Gr)(t)}`,`Response: ${(0,s.P)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupResponseMalformedError"})}};let OffchainLookupSenderMismatchError=class OffchainLookupSenderMismatchError extends i.G{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"})}};var l=n(88822),u=n(11856),d=n(62546),p=n(7835),m=n(9040),b=n(25493);let g="0x556f1830",y={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 offchainLookup(e,{blockNumber:t,blockTag:n,data:i,to:s}){let{args:c}=(0,u.p)({data:i,abi:[y]}),[l,b,g,v,E]=c;try{if(!(0,p.E)(s,l))throw new OffchainLookupSenderMismatchError({sender:l,to:s});let i=await ccipFetch({data:g,sender:l,urls:b}),{data:c}=await (0,o.R)(e,{blockNumber:t,blockTag:n,data:(0,m.zo)([v,(0,d.E)([{type:"bytes"},{type:"bytes"}],[i,E])]),to:s});return c}catch(e){throw new OffchainLookupError({callbackSelector:v,cause:e,data:i,extraData:E,sender:l,urls:b})}}async function ccipFetch({data:e,sender:t,urls:n}){let o=Error("An unknown error occurred.");for(let i=0;i<n.length;i++){let c=n[i],u=c.includes("{sender}")||c.includes("{data}")?"GET":"POST",d="POST"===u?{data:e,sender:t}:void 0;try{let n;let i=await fetch(c.replace("{sender}",t).replace("{data}",e),{body:JSON.stringify(d),method:u});if(n=i.headers.get("Content-Type")?.startsWith("application/json")?(await i.json()).data:await i.text(),!i.ok){o=new l.Gg({body:d,details:(0,s.P)(n.error)||i.statusText,headers:i.headers,status:i.status,url:c});continue}if(!(0,b.v)(n)){o=new OffchainLookupResponseMalformedError({result:n,url:c});continue}return n}catch(e){o=new l.Gg({body:d,details:e.message,url:c})}}throw o}},61786:function(e,t,n){"use strict";n.d(t,{LI:function(){return getChainContractAddress},ax:function(){return defineChain},qg:function(){return assertCurrentChain}});var o=n(21973);function assertCurrentChain({chain:e,currentChainId:t}){if(!e)throw new o.Bk;if(t!==e.id)throw new o.Yl({chain:e,currentChainId:t})}function defineChain(e){return e}function getChainContractAddress({blockNumber:e,chain:t,contract:n}){let i=t?.contracts?.[n];if(!i)throw new o.mm({chain:t,contract:{name:n}});if(e&&i.blockCreated&&i.blockCreated>e)throw new o.mm({blockNumber:e,chain:t,contract:{name:n,blockCreated:i.blockCreated}});return i.address}},9040:function(e,t,n){"use strict";function concat(e){return"string"==typeof e[0]?concatHex(e):function(e){let t=0;for(let n of e)t+=n.length;let n=new Uint8Array(t),o=0;for(let t of e)n.set(t,o),o+=t.length;return n}(e)}function concatHex(e){return`0x${e.reduce((e,t)=>
1114e+t.replace("0x",""),"")}`}n.d(t,{SM:function(){return concatHex},zo:function(){return concat}})},25493:function(e,t,n){"use strict";function isHex(e,{strict:t=!0}={}){return!!e&&"string"==typeof e&&(t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x"))}n.d(t,{v:function(){return isHex}})},28795:function(e,t,n){"use strict";n.d(t,{gc:function(){return padHex},vk:function(){return pad}});var o=n(98309);function pad(e,{dir:t,size:n=32}={}){return"string"==typeof e?padHex(e,{dir:t,size:n}):function(e,{dir:t,size:n=32}={}){if(null===n)return e;if(e.length>n)throw new o.$({size:e.length,targetSize:n,type:"bytes"});let i=new Uint8Array(n);for(let o=0;o<n;o++){let s="right"===t;i[s?o:n-o-1]=e[s?o:e.length-o-1]}return i}(e,{dir:t,size:n})}function padHex(e,{dir:t,size:n=32}={}){if(null===n)return e;let i=e.replace("0x","");if(i.length>2*n)throw new o.$({size:Math.ceil(i.length/2),targetSize:n,type:"hex"});return`0x${i["right"===t?"padEnd":"padStart"](2*n,"0")}`}},51756:function(e,t,n){"use strict";n.d(t,{d:function(){return size}});var o=n(25493);function size(e){return(0,o.v)(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length}},33283:function(e,t,n){"use strict";n.d(t,{tP:function(){return slice}});var o=n(98309),i=n(25493),s=n(51756);function slice(e,t,n,{strict:o}={}){return(0,i.v)(e,{strict:!1})?function(e,t,n,{strict:o}={}){assertStartOffset(e,t);let i=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return o&&assertEndOffset(i,t,n),i}(e,t,n,{strict:o}):function(e,t,n,{strict:o}={}){assertStartOffset(e,t);let i=e.slice(t,n);return o&&assertEndOffset(i,t,n),i}(e,t,n,{strict:o})}function assertStartOffset(e,t){if("number"==typeof t&&t>0&&t>(0,s.d)(e)-1)throw new o.m({offset:t,position:"start",size:(0,s.d)(e)})}function assertEndOffset(e,t,n){if("number"==typeof t&&"number"==typeof n&&(0,s.d)(e)!==n-t)throw new o.m({offset:n,position:"end",size:(0,s.d)(e)})}},26873:function(e,t,n){"use strict";function trim(e,{dir:t="left"}={}){let n="string"==typeof e?e.replace("0x",""):e,o=0;for(let e=0;e<n.length-1&&"0"===n["left"===t?e:n.length-e-1].toString();e++)o++;return(n="left"===t?n.slice(o):n.slice(0,n.length-o),"string"==typeof e)?(1===n.length&&"right"===t&&(n=`${n}0`),`0x${n.length%2==1?`0${n}`:n}`):n}n.d(t,{f:function(){return trim}})},90169:function(e,t,n){"use strict";n.d(t,{XA:function(){return hexToBool},Yf:function(){return assertSize},ly:function(){return hexToNumber},rR:function(){return hexToString},y_:function(){return hexToBigInt}});var o=n(89466),i=n(51756),s=n(26873),c=n(41327);function assertSize(e,{size:t}){if((0,i.d)(e)>t)throw new o.M6({givenSize:(0,i.d)(e),maxSize:t})}function hexToBigInt(e,t={}){let{signed:n}=t;t.size&&assertSize(e,{size:t.size});let o=BigInt(e);if(!n)return o;let i=(e.length-2)/2,s=(1n<<8n*BigInt(i)-1n)-1n;return o<=s?o:o-BigInt(`0x${"f".padStart(2*i,"f")}`)-1n}function hexToBool(e,t={}){let n=e;if(t.size&&(assertSize(n,{size:t.size}),n=(0,s.f)(n)),"0x00"===(0,s.f)(n))return!1;if("0x01"===(0,s.f)(n))return!0;throw new o.Cd(n)}function hexToNumber(e,t={}){return Number(hexToBigInt(e,t))}function hexToString(e,t={}){let n=(0,c.nr)(e);return t.size&&(assertSize(n,{size:t.size}),n=(0,s.f)(n,{dir:"right"})),new TextDecoder().decode(n)}},41327:function(e,t,n){"use strict";n.d(t,{O0:function(){return toBytes},nr:function(){return hexToBytes},qX:function(){return stringToBytes}});var o=n(69977),i=n(25493),s=n(28795),c=n(90169),l=n(46872);let u=new TextEncoder;function toBytes(e,t={}){return"number"==typeof e||"bigint"==typeof e?function(e,t){let n=(0,l.eC)(e,t);return hexToBytes(n)}(e,t):"boolean"==typeof e?function(e,t={}){let n=new Uint8Array(1);return(n[0]=Number(e),"number"==typeof t.size)?((0,c.Yf)(n,{size:t.size}),(0,s.vk)(n,{size:t.size})):n}(e,t):(0,i.v)(e)?hexToBytes(e,t):stringToBytes(e,t)}function hexToBytes(e,t={}){let n=e;t.size&&((0,c.Yf)(n,{size:t.size}),n=(0,s.vk)(n,{dir:"right",size:t.size}));let i=n.slice(2);i.length%2&&(i=`0${i}`);let l=new Uint8Array(i.length/2);for(let e=0;e<l.length;e++){let t=2*e,n=i.slice(t,t+2),s=Number.parseInt(n,16);if(Number.isNaN(s)||s<0)throw new o.G(`Invalid byte sequence ("${n}" in "${i}").`);l[e]=s}return l}function stringToBytes(e,t={}){let n=u.encode(e);return"number"==typeof t.size?((0,c.Yf)(n,{size:t.size}),(0,s.vk)(n,{dir:"right",size:t.size})):n}},46872:function(e,t,n){"use strict";n.d(t,{$G:function(){return stringToHex},C4:function(){return boolToHex},NC:function(){return toHex},ci:function(){return bytesToHex},eC:function(){return numberToHex}});var o=n(89466),i=n(28795),s=n(90169);let c=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function toHex(e,t={}){return"number"==typeof e||"bigint"==typeof e?numberToHex(e,t):"string"==typeof e?stringToHex(e,t):"boolean"==typeof e?boolToHex(e,t):bytesToHex(e,t)}function boolToHex(e,t={}){let n=`0x${Number(e)}`;return"number"==typeof t.size?((0,s.Yf)(n,{size:t.size}),(0,i.vk)(n,{size:t.size})):n}function bytesToHex(e,t={}){let n="";for(let t=0;t<e.length;t++)n+=c[e[t]];let o=`0x${n}`;return"number"==typeof t.size?((0,s.Yf)(o,{size:t.size}),(0,i.vk)(o,{dir:"right",size:t.size})):o}function numberToHex(e,t={}){let n;let{signed:s,size:c}=t,l=BigInt(e);c?n=s?(1n<<8n*BigInt(c)-1n)-1n:2n**(8n*BigInt(c))-1n:"number"==typeof e&&(n=BigInt(Number.MAX_SAFE_INTEGER));let u="bigint"==typeof n&&s?-n-1n:0;if(n&&l>n||l<u){let t="bigint"==typeof e?"n":"";throw new o.J5({max:n?`${n}${t}`:void 0,min:`${u}${t}`,signed:s,size:c,value:`${e}${t}`})}let d=`0x${(s&&l<0?(1n<<BigInt(8*c))+BigInt(l):l).toString(16)}`;return c?(0,i.vk)(d,{size:c}):d}let l=new TextEncoder;function stringToHex(e,t={}){let n=l.encode(e);return bytesToHex(n,t)}},30514:function(e,t,n){"use strict";n(41327),n(46872),n(90707)},3492:function(e,t,n){"use strict";n.d(t,{V:function(){return namehash}});var o=n(9040),i=n(41327),s=n(46872),c=n(90707);function namehash(e){let t=new Uint8Array(32).fill(0);if(!e)return(0,s.ci)(t);let n=e.split(".");for(let e=n.length-1;e>=0;e-=1){let s=(0,c.w)((0,i.qX)(n[e]),"bytes");t=(0,c.w)((0,o.zo)([t,s]),"bytes")}return(0,s.ci)(t)}},89683:function(e,t,n){"use strict";n.d(t,{T:function(){return packetToBytes}});var o=n(41327);function packetToBytes(e){let t=new Uint8Array("."===e||".."===e?1:(0,o.qX)(e.replace(/^\.|\.$/gm,"")).length+2),n=e.replace(/^\.|\.$/gm,"");if(!n.length)return t;let i=0,s=n.split(".");for(let e=0;e<s.length;e++){let n=(0,o.qX)(s[e]);t[i]=n.length,t.set(n,i+1),i+=n.length+1}return t}},71721:function(e,t,n){"use strict";n.d(t,{P:function(){return getCallError}});var o=n(90722),i=n(90968);function getCallError(e,{docsPath:t,...n}){let s=e;return(0,i.B)(e)&&(s=(0,i.k)(e,n)),new o.cg(s,{docsPath:t,...n})}},30826:function(e,t,n){"use strict";n.d(t,{S:function(){return getContractError}});
1114var o=n(5555),i=n(69977),s=n(90722);function getContractError(e,{abi:t,address:n,args:c,docsPath:l,functionName:u,sender:d}){let{code:p,data:m,message:b,shortMessage:g}=e instanceof s.VQ?e:e instanceof i.G?e.walk(e=>"data"in e):{},y=e;return e instanceof o.wb?y=new s.Dk({functionName:u}):3===p&&(m||b||g)&&(y=new s.Lu({abi:t,data:"object"==typeof m?m.data:m,functionName:u,message:g??b})),new s.uq(y,{abi:t,args:c,contractAddress:n,docsPath:l,functionName:u,sender:d})}},90968:function(e,t,n){"use strict";n.d(t,{B:function(){return containsNodeError},k:function(){return getNodeError}});var o=n(66054),i=n(88822),s=n(42455);function containsNodeError(e){return e instanceof s.KB||e instanceof s.yR||e instanceof i.bs&&e.code===o.M_.code}function getNodeError(e,t){let n=e.details.toLowerCase();if(o.Hh.nodeMessage.test(n))return new o.Hh({cause:e,maxFeePerGas:t?.maxFeePerGas});if(o.G$.nodeMessage.test(n))return new o.G$({cause:e,maxFeePerGas:t?.maxFeePerGas});if(o.ZI.nodeMessage.test(n))return new o.ZI({cause:e,nonce:t?.nonce});if(o.vU.nodeMessage.test(n))return new o.vU({cause:e,nonce:t?.nonce});if(o.se.nodeMessage.test(n))return new o.se({cause:e,nonce:t?.nonce});if(o.C_.nodeMessage.test(n))return new o.C_({cause:e});if(o.WF.nodeMessage.test(n))return new o.WF({cause:e,gas:t?.gas});else if(o.dR.nodeMessage.test(n))return new o.dR({cause:e,gas:t?.gas});else if(o.pZ.nodeMessage.test(n))return new o.pZ({cause:e});else if(o.cs.nodeMessage.test(n))return new o.cs({cause:e,maxFeePerGas:t?.maxFeePerGas,maxPriorityFeePerGas:t?.maxPriorityFeePerGas});else if(n.match(o.M_.nodeMessage)||"code"in e.cause&&e.cause?.code===o.M_.code)return new o.M_({cause:e,message:e.cause.details||e.details});return new o.cj({cause:e.cause.cause})}},86101:function(e,t,n){"use strict";n.d(t,{G:function(){return s},Z:function(){return formatBlock}});var o=n(95417),i=n(94216);function formatBlock(e){let t=e.transactions?.map(e=>"string"==typeof e?e:i.Tr(e));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,difficulty:e.difficulty?BigInt(e.difficulty):void 0,gasLimit:e.gasLimit?BigInt(e.gasLimit):void 0,gasUsed:e.gasUsed?BigInt(e.gasUsed):void 0,hash:e.hash?e.hash:null,logsBloom:e.logsBloom?e.logsBloom:null,nonce:e.nonce?e.nonce:null,number:e.number?BigInt(e.number):null,size:e.size?BigInt(e.size):void 0,timestamp:e.timestamp?BigInt(e.timestamp):void 0,transactions:t,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}let s=(0,o.$)({format:formatBlock})},91019:function(e,t,n){"use strict";function extract(e,{formatter:t}){if(!t)return{};let n=Object.keys(t({}));return n.reduce((t,n)=>(e?.hasOwnProperty(n)&&(t[n]=e[n]),t),{})}n.d(t,{K:function(){return extract}})},95417:function(e,t,n){"use strict";function format(e,{formatter:t}){return t(e)}function defineFormatter({format:e}){return({exclude:t,format:n})=>o=>{let i=e(o);if(t)for(let e of t)delete i[e];return{...i,...n?.(o)}}}n.d(t,{$:function(){return defineFormatter},W:function(){return format}})},18829:function(e,t,n){"use strict";function formatLog(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,logIndex:e.logIndex?BigInt(e.logIndex):null,transactionHash:e.transactionHash?e.transactionHash:null,transactionIndex:e.transactionIndex?BigInt(e.transactionIndex):null,...n?{args:t,eventName:n}:{}}}n.d(t,{U:function(){return formatLog}})},94216:function(e,t,n){"use strict";n.d(t,{Tr:function(){return formatTransaction},c8:function(){return s},y_:function(){return c}});var o=n(90169),i=n(95417);let s={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559"};function formatTransaction(e){let t={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,chainId:e.chainId?(0,o.ly)(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?(0,o.ly)(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?s[e.type]:void 0,value:e.value?BigInt(e.value):void 0,v:e.v?BigInt(e.v):void 0};return"legacy"===t.type&&(delete t.accessList,delete t.maxFeePerGas,delete t.maxPriorityFeePerGas),"eip2930"===t.type&&(delete t.maxFeePerGas,delete t.maxPriorityFeePerGas),t}let c=(0,i.$)({format:formatTransaction})},4656:function(e,t,n){"use strict";n.d(t,{d:function(){return u},f:function(){return formatTransactionReceipt}});var o=n(90169),i=n(95417),s=n(18829),c=n(94216);let l={"0x0":"reverted","0x1":"success"};function formatTransactionReceipt(e){return{...e,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,contractAddress:e.contractAddress?e.contractAddress:null,cumulativeGasUsed:e.cumulativeGasUsed?BigInt(e.cumulativeGasUsed):null,effectiveGasPrice:e.effectiveGasPrice?BigInt(e.effectiveGasPrice):null,gasUsed:e.gasUsed?BigInt(e.gasUsed):null,logs:e.logs?e.logs.map(e=>(0,s.U)(e)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?(0,o.ly)(e.transactionIndex):null,status:e.status?l[e.status]:null,type:e.type?c.c8[e.type]:null}}let u=(0,i.$)({format:formatTransactionReceipt})},23822:function(e,t,n){"use strict";n.d(t,{i:function(){return s},t:function(){return formatTransactionRequest}});var o=n(46872),i=n(95417);function formatTransactionRequest(e){return{...e,gas:void 0!==e.gas?(0,o.eC)(e.gas):void 0,gasPrice:void 0!==e.gasPrice?(0,o.eC)(e.gasPrice):void 0,maxFeePerGas:void 0!==e.maxFeePerGas?(0,o.eC)(e.maxFeePerGas):void 0,maxPriorityFeePerGas:void 0!==e.maxPriorityFeePerGas?(0,o.eC)(e.maxPriorityFeePerGas):void 0,nonce:void 0!==e.nonce?(0,o.eC)(e.nonce):void 0,value:void 0!==e.value?(0,o.eC)(e.value):void 0}}let s=(0,i.$)({format:formatTransactionRequest})},80507:function(e,t,n){"use strict";n.d(t,{o:function(){return getFunctionSelector}});var o=n(33283),i=n(56143);let getFunctionSelector=e=>(0,o.tP)((0,i.F)(e),0,4)},56143:function(e,t,n){"use strict";n.d(t,{F:function(){return hashFunction}});let o=/((function|event)\s)?(.*)(\((.*)\))/;function extractFunctionParts(e){let t=e.match(o),n=t?.[2]||void 0,i=t?.[3],s=t?.[5]||void 0;return{type:n,name:i,params:s}}var i=n(41327),s=n(90707);let hash=e=>(0,s.w)((0,i.O0)(e));function hashFunction(e){let t=extractFunctionParts(e).name,n=function(e){let t=extractFunctionParts(e).params,n=t?.split(",").map(e=>e.trim().split(" "));return n?.map(e=>({type:e[0],name:"indexed"===e[1]?e[2]:e[1],..."indexed"===e[1]?{indexed:!0}:{}}))}(e)||[];return hash(`${t}(${n.map(({type:e})=>e).join(",")})`)}},90707:function(e,t,n){"use strict";function number(e){if(!Number.isSafeInteger(e)||e<0)throw Error(`Wrong positive integer: ${e}`)}function bytes(e,...t){if(!(e instanceof Uint8Array))throw TypeError("Expected Uint8Array");if(t.length>0&&!t.includes(e.length))throw TypeError(`Expected Uint8Array of length ${t}, not of length=${e.length}`)}n.d(t,{w:function(){return keccak256}});var o={number,bool:function(e){if("boolean"!=typeof e)throw Error(`Expected boolean, not ${e}`)},bytes,hash:function(e){if("function"!=typeof e||"function"!=typeof e.create)throw Error("Hash should be wrapped by utils.wrapConstructor");number(e.outputLen),number(e.blockLen)},exists:function(e,t=!0){if(e.destroyed)throw Error("Hash instance has been destroyed");if(t&&e.finished)throw Error("Hash#digest() has already been called")},output:function(e,t){bytes(e);let n=t.outputLen;if(e.length<n)throw Error(`digestInto() expects output buffer of length at least ${n}`)}};let i=BigInt(4294967296-1),s=BigInt(32);function fromBig(e,t=!1){return t?{h:Number(e&i),l:Number(e>>s&i)}:{h:0|Number(e>>s&i),l:0|Number(e&i)}}var c={fromBig,split:function(e,t=!1){let n=new Uint32Array(e.length),o=new Uint32Array(e.length);for(let i=0;i<e.length;i++){let{h:s,l:c}=fromBig(e[i],t);[n[i],o[i]]=[s,c]}return[n,o]},toBig:(e,t)=>
1114BigInt(e>>>0)<<s|BigInt(t>>>0),shrSH:(e,t,n)=>e>>>n,shrSL:(e,t,n)=>e<<32-n|t>>>n,rotrSH:(e,t,n)=>e>>>n|t<<32-n,rotrSL:(e,t,n)=>e<<32-n|t>>>n,rotrBH:(e,t,n)=>e<<64-n|t>>>n-32,rotrBL:(e,t,n)=>e>>>n-32|t<<64-n,rotr32H:(e,t)=>t,rotr32L:(e,t)=>e,rotlSH:(e,t,n)=>e<<n|t>>>32-n,rotlSL:(e,t,n)=>t<<n|e>>>32-n,rotlBH:(e,t,n)=>t<<n-32|e>>>64-n,rotlBL:(e,t,n)=>e<<n-32|t>>>64-n,add:function(e,t,n,o){let i=(t>>>0)+(o>>>0);return{h:e+n+(i/4294967296|0)|0,l:0|i}},add3L:(e,t,n)=>(e>>>0)+(t>>>0)+(n>>>0),add3H:(e,t,n,o)=>t+n+o+(e/4294967296|0)|0,add4L:(e,t,n,o)=>(e>>>0)+(t>>>0)+(n>>>0)+(o>>>0),add4H:(e,t,n,o,i)=>t+n+o+i+(e/4294967296|0)|0,add5H:(e,t,n,o,i,s)=>t+n+o+i+s+(e/4294967296|0)|0,add5L:(e,t,n,o,i)=>(e>>>0)+(t>>>0)+(n>>>0)+(o>>>0)+(i>>>0)};let u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4)),l=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!l)throw Error("Non little-endian hardware is not supported");function toBytes(e){if("string"==typeof e&&(e=function(e){if("string"!=typeof e)throw TypeError(`utf8ToBytes expected string, got ${typeof e}`);return new TextEncoder().encode(e)}(e)),!(e instanceof Uint8Array))throw TypeError(`Expected input type is Uint8Array (got ${typeof e})`);return e}Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));let Hash=class Hash{clone(){return this._cloneInto()}};let[u,d,p]=[[],[],[]],m=BigInt(0),b=BigInt(1),g=BigInt(2),y=BigInt(7),v=BigInt(256),E=BigInt(113);for(let e=0,t=b,n=1,o=0;e<24;e++){[n,o]=[o,(2*n+3*o)%5],u.push(2*(5*o+n)),d.push((e+1)*(e+2)/2%64);let i=m;for(let e=0;e<7;e++)(t=(t<<b^(t>>y)*E)%v)&g&&(i^=b<<(b<<BigInt(e))-b);p.push(i)}let[x,P]=c.split(p,!0),rotlH=(e,t,n)=>n>32?c.rotlBH(e,t,n):c.rotlSH(e,t,n),rotlL=(e,t,n)=>n>32?c.rotlBL(e,t,n):c.rotlSL(e,t,n);let Keccak=class Keccak extends Hash{constructor(e,t,n,i=!1,s=24){if(super(),this.blockLen=e,this.suffix=t,this.outputLen=n,this.enableXOF=i,this.rounds=s,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,o.number(n),0>=this.blockLen||this.blockLen>=200)throw Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=u32(this.state)}keccak(){!function(e,t=24){let n=new Uint32Array(10);for(let o=24-t;o<24;o++){for(let t=0;t<10;t++)n[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){let o=(t+8)%10,i=(t+2)%10,s=n[i],c=n[i+1],l=rotlH(s,c,1)^n[o],u=rotlL(s,c,1)^n[o+1];for(let n=0;n<50;n+=10)e[t+n]^=l,e[t+n+1]^=u}let t=e[2],i=e[3];for(let n=0;n<24;n++){let o=d[n],s=rotlH(t,i,o),c=rotlL(t,i,o),l=u[n];t=e[l],i=e[l+1],e[l]=s,e[l+1]=c}for(let t=0;t<50;t+=10){for(let o=0;o<10;o++)n[o]=e[t+o];for(let o=0;o<10;o++)e[t+o]^=~n[(o+2)%10]&n[(o+4)%10]}e[0]^=x[o],e[1]^=P[o]}n.fill(0)}(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){o.exists(this);let{blockLen:t,state:n}=this;e=toBytes(e);let i=e.length;for(let o=0;o<i;){let s=Math.min(t-this.pos,i-o);for(let t=0;t<s;t++)n[this.pos++]^=e[o++];this.pos===t&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;let{state:e,suffix:t,pos:n,blockLen:o}=this;e[n]^=t,(128&t)!=0&&n===o-1&&this.keccak(),e[o-1]^=128,this.keccak()}writeInto(e){o.exists(this,!1),o.bytes(e),this.finish();let t=this.state,{blockLen:n}=this;for(let o=0,i=e.length;o<i;){this.posOut>=n&&this.keccak();let s=Math.min(n-this.posOut,i-o);e.set(t.subarray(this.posOut,this.posOut+s),o),this.posOut+=s,o+=s}return e}xofInto(e){if(!this.enableXOF)throw Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return o.number(e),this.xofInto(new Uint8Array(e))}digestInto(e){if(o.output(e,this),this.finished)throw 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){let{blockLen:t,suffix:n,outputLen:o,rounds:i,enableXOF:s}=this;return e||(e=new Keccak(t,n,o,s,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=o,e.enableXOF=s,e.destroyed=this.destroyed,e}};let gen=(e,t,n)=>(function(e){let hashC=t=>e().update(toBytes(t)).digest(),t=e();return hashC.outputLen=t.outputLen,hashC.blockLen=t.blockLen,hashC.create=()=>e(),hashC})(()=>new Keccak(t,e,n));gen(6,144,28),gen(6,136,32),gen(6,104,48),gen(6,72,64),gen(1,144,28);let _=gen(1,136,32);gen(1,104,48),gen(1,72,64);let genShake=(e,t,n)=>(function(e){let hashC=(t,n)=>e(n).update(toBytes(t)).digest(),t=e({});return hashC.outputLen=t.outputLen,hashC.blockLen=t.blockLen,hashC.create=t=>e(t),hashC})((o={})=>new Keccak(t,e,void 0===o.dkLen?n:o.dkLen,!0));genShake(31,168,16),genShake(31,136,32);var I=n(25493),j=n(41327),R=n(46872);function keccak256(e,t){let n=_((0,I.v)(e,{strict:!1})?(0,j.O0)(e):e);return"bytes"===(t||"hex")?n:(0,R.NC)(n)}},68583:function(e,t,n){"use strict";n.d(t,{S:function(){return createBatchScheduler}});let o=new Map;function createBatchScheduler({fn:e,id:t,shouldSplitBatch:n,wait:i=0}){let exec=async()=>{let t=getScheduler();flush();let n=t.map(({args:e})=>e);0!==n.length&&e(n).then(e=>{t.forEach(({pendingPromise:t},n)=>t.resolve?.([e[n],e]))}).catch(e=>{t.forEach(({pendingPromise:t})=>t.reject?.(e))})},flush=()=>o.delete(t),getBatchedArgs=()=>getScheduler().map(({args:e})=>
1114e),getScheduler=()=>o.get(t)||[],setScheduler=e=>o.set(t,[...getScheduler(),e]);return{flush,async schedule(e){let t={},o=new Promise((e,n)=>{t.resolve=e,t.reject=n}),s=n?.([...getBatchedArgs(),e]);s&&exec();let c=getScheduler().length>0;return c?setScheduler({args:e,pendingPromise:t}):(setScheduler({args:e,pendingPromise:t}),setTimeout(exec,i)),o}}}},61344:function(e,t,n){"use strict";n.d(t,{P:function(){return stringify}});let stringify=(e,t,n)=>JSON.stringify(e,(e,n)=>{let o="bigint"==typeof n?n.toString():n;return"function"==typeof t?t(e,o):o},n)},13134:function(e,t,n){"use strict";n.d(t,{F:function(){return assertRequest}});var o=n(21431),i=n(92960),s=n(66054),c=n(54574),l=n(97451);function assertRequest(e){let{account:t,gasPrice:n,maxFeePerGas:u,maxPriorityFeePerGas:d,to:p}=e,m=t?(0,o.T)(t):void 0;if(m&&!(0,l.U)(m.address))throw new i.b({address:m.address});if(p&&!(0,l.U)(p))throw new i.b({address:p});if(void 0!==n&&(void 0!==u||void 0!==d))throw new c.xY;if(u&&u>2n**256n-1n)throw new s.Hh({maxFeePerGas:u});if(d&&u&&d>u)throw new s.cs({maxFeePerGas:u,maxPriorityFeePerGas:d})}},6665:function(e,t,n){"use strict";n.d(t,{d:function(){return formatEther}});var o=n(58617),i=n(60263);function formatEther(e,t="wei"){return(0,i.b)(e,o.ez[t])}},56283:function(e,t,n){"use strict";n.d(t,{o:function(){return formatGwei}});var o=n(58617),i=n(60263);function formatGwei(e,t="wei"){return(0,i.b)(e,o.Zn[t])}},60263:function(e,t,n){"use strict";function formatUnits(e,t){let n=e.toString(),o=n.startsWith("-");o&&(n=n.slice(1));let[i,s]=[(n=n.padStart(t,"0")).slice(0,n.length-t),n.slice(n.length-t)];return s=s.replace(/(0+)$/,""),`${o?"-":""}${i||"0"}${s?`.${s}`:""}`}n.d(t,{b:function(){return formatUnits}})},69077:function(e,t,n){"use strict";let o;function noop(){}n.d(t,{eM:function(){return WagmiConfig},_g:function(){return createConfig},mA:function(){return useAccount},KQ:function(){return useBalance},$4:function(){return useConnect},do:function(){return useContractRead},GG:function(){return useContractWrite},qL:function(){return useDisconnect},c9:function(){return useEnsAvatar},F6:function(){return useEnsName},LN:function(){return useNetwork},t_:function(){return usePublicClient},QW:function(){return useSignMessage},g0:function(){return useSwitchNetwork},BX:function(){return useWaitForTransaction}});let i="undefined"==typeof window||"Deno"in window;function utils_noop(){}function isValidTimeout(e){return"number"==typeof e&&e>=0&&e!==1/0}function timeUntilStale(e,t){return Math.max(e+(t||0)-Date.now(),0)}function parseQueryArgs(e,t,n){return isQueryKey(e)?"function"==typeof t?{...n,queryKey:e,queryFn:t}:{...t,queryKey:e}:e}function parseMutationArgs(e,t,n){return isQueryKey(e)?"function"==typeof t?{...n,mutationKey:e,mutationFn:t}:{...t,mutationKey:e}:"function"==typeof e?{...t,mutationFn:e}:{...e}}function parseFilterArgs(e,t,n){return isQueryKey(e)?[{...t,queryKey:e},n]:[e||{},t]}function matchQuery(e,t){let{type:n="all",exact:o,fetchStatus:i,predicate:s,queryKey:c,stale:l}=e;if(isQueryKey(c)){if(o){if(t.queryHash!==hashQueryKeyByOptions(c,t.options))return!1}else{if(!partialDeepEqual(t.queryKey,c))return!1}}if("all"!==n){let e=t.isActive();if("active"===n&&!e||"inactive"===n&&e)return!1}return("boolean"!=typeof l||t.isStale()===l)&&(void 0===i||i===t.state.fetchStatus)&&(!s||!!s(t))}function matchMutation(e,t){let{exact:n,fetching:o,predicate:i,mutationKey:s}=e;if(isQueryKey(s)){if(!t.options.mutationKey)return!1;if(n){if(hashQueryKey(t.options.mutationKey)!==hashQueryKey(s))return!1}else{if(!partialDeepEqual(t.options.mutationKey,s))return!1}}return("boolean"!=typeof o||"loading"===t.state.status===o)&&(!i||!!i(t))}function hashQueryKeyByOptions(e,t){let n=(null==t?void 0:t.queryKeyHashFn)||hashQueryKey;return n(e)}function hashQueryKey(e){return JSON.stringify(e,(e,t)=>isPlainObject(t)?Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}):t)}function partialDeepEqual(e,t){return e===t||typeof e==typeof t&&!!e&&!!t&&"object"==typeof e&&"object"==typeof t&&!Object.keys(t).some(n=>!partialDeepEqual(e[n],t[n]))}function utils_replaceEqualDeep(e,t){if(e===t)return e;let n=isPlainArray(e)&&isPlainArray(t);if(n||isPlainObject(e)&&isPlainObject(t)){let o=n?e.length:Object.keys(e).length,i=n?t:Object.keys(t),s=i.length,c=n?[]:{},l=0;for(let o=0;o<s;o++){let s=n?o:i[o];c[s]=utils_replaceEqualDeep(e[s],t[s]),c[s]===e[s]&&l++}return o===s&&l===o?e:c}return t}function shallowEqualObjects(e,t){if(e&&!t||t&&!e)return!1;for(let n in e)if(e[n]!==t[n])return!1;return!0}function isPlainArray(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function isPlainObject(e){if(!hasObjectPrototype(e))return!1;let t=e.constructor;if(void 0===t)return!0;let n=t.prototype;return!!(hasObjectPrototype(n)&&n.hasOwnProperty("isPrototypeOf"))}function hasObjectPrototype(e){return"[object Object]"===Object.prototype.toString.call(e)}function isQueryKey(e){return Array.isArray(e)}function sleep(e){return new Promise(t=>{setTimeout(t,e)})}function scheduleMicrotask(e){sleep(0).then(e)}function replaceData(e,t,n){return null!=n.isDataEqual&&n.isDataEqual(e,t)?e:"function"==typeof n.structuralSharing?n.structuralSharing(e,t):!1!==n.structuralSharing?utils_replaceEqualDeep(e,t):t}let s=console,c=function(){let e=[],t=0,notifyFn=e=>{e()},batchNotifyFn=e=>{e()},schedule=n=>{t?e.push(n):scheduleMicrotask(()=>{notifyFn(n)})},flush=()=>{let t=e;e=[],t.length&&scheduleMicrotask(()=>{batchNotifyFn(()=>
1114{t.forEach(e=>{notifyFn(e)})})})};return{batch:e=>{let n;t++;try{n=e()}finally{--t||flush()}return n},batchCalls:e=>(...t)=>{schedule(()=>{e(...t)})},schedule,setNotifyFunction:e=>{notifyFn=e},setBatchNotifyFunction:e=>{batchNotifyFn=e}}}();let Subscribable=class Subscribable{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){let t={listener:e};return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}};let l=new class extends Subscribable{constructor(){super(),this.setup=e=>{if(!i&&window.addEventListener){let listener=()=>e();return window.addEventListener("visibilitychange",listener,!1),window.addEventListener("focus",listener,!1),()=>{window.removeEventListener("visibilitychange",listener),window.removeEventListener("focus",listener)}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.cleanup)||e.call(this),this.cleanup=void 0}}setEventListener(e){var t;this.setup=e,null==(t=this.cleanup)||t.call(this),this.cleanup=e(e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()})}setFocused(e){let t=this.focused!==e;t&&(this.focused=e,this.onFocus())}onFocus(){this.listeners.forEach(({listener:e})=>{e()})}isFocused(){return"boolean"==typeof this.focused?this.focused:"undefined"==typeof document||[void 0,"visible","prerender"].includes(document.visibilityState)}},u=["online","offline"],d=new class extends Subscribable{constructor(){super(),this.setup=e=>{if(!i&&window.addEventListener){let listener=()=>e();return u.forEach(e=>{window.addEventListener(e,listener,!1)}),()=>{u.forEach(e=>{window.removeEventListener(e,listener)})}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.cleanup)||e.call(this),this.cleanup=void 0}}setEventListener(e){var t;this.setup=e,null==(t=this.cleanup)||t.call(this),this.cleanup=e(e=>{"boolean"==typeof e?this.setOnline(e):this.onOnline()})}setOnline(e){let t=this.online!==e;t&&(this.online=e,this.onOnline())}onOnline(){this.listeners.forEach(({listener:e})=>{e()})}isOnline(){return"boolean"==typeof this.online?this.online:"undefined"==typeof navigator||void 0===navigator.onLine||navigator.onLine}};function defaultRetryDelay(e){return Math.min(1e3*2**e,3e4)}function canFetch(e){return(null!=e?e:"online")!=="online"||d.isOnline()}let CancelledError=class CancelledError{constructor(e){this.revert=null==e?void 0:e.revert,this.silent=null==e?void 0:e.silent}};function isCancelledError(e){return e instanceof CancelledError}function createRetryer(e){let t,n,o,i=!1,s=0,c=!1,u=new Promise((e,t)=>{n=e,o=t}),shouldPause=()=>!l.isFocused()||"always"!==e.networkMode&&!d.isOnline(),resolve=o=>{c||(c=!0,null==e.onSuccess||e.onSuccess(o),null==t||t(),n(o))},reject=n=>{c||(c=!0,null==e.onError||e.onError(n),null==t||t(),o(n))},pause=()=>new Promise(n=>{t=e=>{let t=c||!shouldPause();return t&&n(e),t},null==e.onPause||e.onPause()}).then(()=>{t=void 0,c||null==e.onContinue||e.onContinue()}),run=()=>{let t;if(!c){try{t=e.fn()}catch(e){t=Promise.reject(e)}Promise.resolve(t).then(resolve).catch(t=>{var n,o;if(c)return;let l=null!=(n=e.retry)?n:3,u=null!=(o=e.retryDelay)?o:defaultRetryDelay,d="function"==typeof u?u(s,t):u,p=!0===l||"number"==typeof l&&s<l||"function"==typeof l&&l(s,t);if(i||!p){reject(t);return}s++,null==e.onFail||e.onFail(s,t),sleep(d).then(()=>{if(shouldPause())return pause()}).then(()=>{i?reject(t):run()})})}};return canFetch(e.networkMode)?run():pause().then(run),{promise:u,cancel:t=>{c||(reject(new CancelledError(t)),null==e.abort||e.abort())},continue:()=>{let e=null==t?void 0:t();return e?u:Promise.resolve()},cancelRetry:()=>{i=!0},continueRetry:()=>{i=!1}}}let Removable=class Removable{destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),isValidTimeout(this.cacheTime)&&(this.gcTimeout=setTimeout(()=>{this.optionalRemove()},this.cacheTime))}updateCacheTime(e){this.cacheTime=Math.max(this.cacheTime||0,null!=e?e:i?1/0:3e5)}clearGcTimeout(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)}};let Query=class Query extends Removable{constructor(e){super(),this.abort
1114SignalConsumed=!1,this.defaultOptions=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.cache=e.cache,this.logger=e.logger||s,this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.initialState=e.state||function(e){let t="function"==typeof e.initialData?e.initialData():e.initialData,n=void 0!==t,o=n?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?null!=o?o:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"loading",fetchStatus:"idle"}}(this.options),this.state=this.initialState,this.scheduleGc()}get meta(){return this.options.meta}setOptions(e){this.options={...this.defaultOptions,...e},this.updateCacheTime(this.options.cacheTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||this.cache.remove(this)}setData(e,t){let n=replaceData(this.state.data,e,this.options);return this.dispatch({data:n,type:"success",dataUpdatedAt:null==t?void 0:t.updatedAt,manual:null==t?void 0:t.manual}),n}setState(e,t){this.dispatch({type:"setState",state:e,setStateOptions:t})}cancel(e){var t;let n=this.promise;return null==(t=this.retryer)||t.cancel(e),n?n.then(utils_noop).catch(utils_noop):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.initialState)}isActive(){return this.observers.some(e=>!1!==e.options.enabled)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(e=>e.getCurrentResult().isStale)}isStaleByTime(e=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!timeUntilStale(this.state.dataUpdatedAt,e)}onFocus(){var e;let t=this.observers.find(e=>e.shouldFetchOnWindowFocus());t&&t.refetch({cancelRefetch:!1}),null==(e=this.retryer)||e.continue()}onOnline(){var e;let t=this.observers.find(e=>e.shouldFetchOnReconnect());t&&t.refetch({cancelRefetch:!1}),null==(e=this.retryer)||e.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.retryer&&(this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.scheduleGc()),this.cache.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.dispatch({type:"invalidate"})}fetch(e,t){var n,o,i,s;if("idle"!==this.state.fetchStatus){if(this.state.dataUpdatedAt&&null!=t&&t.cancelRefetch)this.cancel({silent:!0});else if(this.promise)return null==(i=this.retryer)||i.continueRetry(),this.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let c=function(){if("function"==typeof AbortController)return new AbortController}(),l={queryKey:this.queryKey,pageParam:void 0,meta:this.meta},addSignalProperty=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>{if(c)return this.abortSignalConsumed=!0,c.signal}})};addSignalProperty(l);let u={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>this.options.queryFn?(this.abortSignalConsumed=!1,this.options.queryFn(l)):Promise.reject("Missing queryFn for queryKey '"+this.options.queryHash+"'")};addSignalProperty(u),null==(n=this.options.behavior)||n.onFetch(u),this.revertState=this.state,("idle"===this.state.fetchStatus||this.state.fetchMeta!==(null==(o=u.fetchOptions)?void 0:o.meta))&&this.dispatch({type:"fetch",meta:null==(s=u.fetchOptions)?void 0:s.meta});let onError=e=>{if(isCancelledError(e)&&e.silent||this.dispatch({type:"error",error:e}),!isCancelledError(e)){var t,n,o,i;null==(t=(n=this.cache.config).onError)||t.call(n,e,this),null==(o=(i=this.cache.config).onSettled)||o.call(i,this.state.data,e,this)}this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.retryer=createRetryer({fn:u.fetchFn,abort:null==c?void 0:c.abort.bind(c),onSuccess:e=>{var t,n,o,i;if(void 0===e){onError(Error(this.queryHash+" data is undefined"));return}this.setData(e),null==(t=(n=this.cache.config).onSuccess)||t.call(n,e,this),null==(o=(i=this.cache.config).onSettled)||o.call(i,e,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError,onFail:(e,t)=>{this.dispatch({type:"failed",failureCount:e,error:t})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:u.options.retry,retryDelay:u.options.retryDelay,networkMode:u.options.networkMode}),this.promise=this.retryer.promise,this.promise}dispatch(e){this.state=(t=>{var n,o;switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null!=(n=e.meta)?n:null,fetchStatus:canFetch(this.options.networkMode)?"fetching":"paused",...!t.dataUpdatedAt&&{error:null,status:"loading"}};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:null!=(o=e.dataUpdatedAt)?o:Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":let i=e.error;if(isCancelledError(i)&&i.revert&&this.revertState)return{...this.revertState,fetchStatus:"idle"};
1114return{...t,error:i,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),c.batch(()=>{this.observers.forEach(t=>{t.onQueryUpdate(e)}),this.cache.notify({query:this,type:"updated",action:e})})}};let QueryCache=class QueryCache extends Subscribable{constructor(e){super(),this.config=e||{},this.queries=[],this.queriesMap={}}build(e,t,n){var o;let i=t.queryKey,s=null!=(o=t.queryHash)?o:hashQueryKeyByOptions(i,t),c=this.get(s);return c||(c=new Query({cache:this,logger:e.getLogger(),queryKey:i,queryHash:s,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(i)}),this.add(c)),c}add(e){this.queriesMap[e.queryHash]||(this.queriesMap[e.queryHash]=e,this.queries.push(e),this.notify({type:"added",query:e}))}remove(e){let t=this.queriesMap[e.queryHash];t&&(e.destroy(),this.queries=this.queries.filter(t=>t!==e),t===e&&delete this.queriesMap[e.queryHash],this.notify({type:"removed",query:e}))}clear(){c.batch(()=>{this.queries.forEach(e=>{this.remove(e)})})}get(e){return this.queriesMap[e]}getAll(){return this.queries}find(e,t){let[n]=parseFilterArgs(e,t);return void 0===n.exact&&(n.exact=!0),this.queries.find(e=>matchQuery(n,e))}findAll(e,t){let[n]=parseFilterArgs(e,t);return Object.keys(n).length>0?this.queries.filter(e=>matchQuery(n,e)):this.queries}notify(e){c.batch(()=>{this.listeners.forEach(({listener:t})=>{t(e)})})}onFocus(){c.batch(()=>{this.queries.forEach(e=>{e.onFocus()})})}onOnline(){c.batch(()=>{this.queries.forEach(e=>{e.onOnline()})})}};let Mutation=class Mutation extends Removable{constructor(e){super(),this.defaultOptions=e.defaultOptions,this.mutationId=e.mutationId,this.mutationCache=e.mutationCache,this.logger=e.logger||s,this.observers=[],this.state=e.state||mutation_getDefaultState(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options={...this.defaultOptions,...e},this.updateCacheTime(this.options.cacheTime)}get meta(){return this.options.meta}setState(e){this.dispatch({type:"setState",state:e})}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.mutationCache.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.observers=this.observers.filter(t=>t!==e),this.scheduleGc(),this.mutationCache.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.observers.length||("loading"===this.state.status?this.scheduleGc():this.mutationCache.remove(this))}continue(){var e,t;return null!=(e=null==(t=this.retryer)?void 0:t.continue())?e:this.execute()}async execute(){var e,t,n,o,i,s,c,l,u,d,p,m,b,g,y,v,E,x,P,_;let I="loading"===this.state.status;try{if(!I){this.dispatch({type:"loading",variables:this.options.variables}),await (null==(u=(d=this.mutationCache.config).onMutate)?void 0:u.call(d,this.state.variables,this));let e=await (null==(p=(m=this.options).onMutate)?void 0:p.call(m,this.state.variables));e!==this.state.context&&this.dispatch({type:"loading",context:e,variables:this.state.variables})}let b=await (()=>{var e;return this.retryer=createRetryer({fn:()=>this.options.mutationFn?this.options.mutationFn(this.state.variables):Promise.reject("No mutationFn found"),onFail:(e,t)=>{this.dispatch({type:"failed",failureCount:e,error:t})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:null!=(e=this.options.retry)?e:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.retryer.promise})();return await (null==(e=(t=this.mutationCache.config).onSuccess)?void 0:e.call(t,b,this.state.variables,this.state.context,this)),await (null==(n=(o=this.options).onSuccess)?void 0:n.call(o,b,this.state.variables,this.state.context)),await (null==(i=(s=this.mutationCache.config).onSettled)?void 0:i.call(s,b,null,this.state.variables,this.state.context,this)),await (null==(c=(l=this.options).onSettled)?void 0:c.call(l,b,null,this.state.variables,this.state.context)),this.dispatch({type:"success",data:b}),b}catch(e){try{throw await (null==(b=(g=this.mutationCache.config).onError)?void 0:b.call(g,e,this.state.variables,this.state.context,this)),await (null==(y=(v=this.options).onError)?void 0:y.call(v,e,this.state.variables,this.state.context)),await (null==(E=(x=this.mutationCache.config).onSettled)?void 0:E.
1114call(x,void 0,e,this.state.variables,this.state.context,this)),await (null==(P=(_=this.options).onSettled)?void 0:P.call(_,void 0,e,this.state.variables,this.state.context)),e}finally{this.dispatch({type:"error",error:e})}}}dispatch(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"loading":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!canFetch(this.options.networkMode),status:"loading",variables:e.variables};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"};case"setState":return{...t,...e.state}}})(this.state),c.batch(()=>{this.observers.forEach(t=>{t.onMutationUpdate(e)}),this.mutationCache.notify({mutation:this,type:"updated",action:e})})}};function mutation_getDefaultState(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0}}let MutationCache=class MutationCache extends Subscribable{constructor(e){super(),this.config=e||{},this.mutations=[],this.mutationId=0}build(e,t,n){let o=new Mutation({mutationCache:this,logger:e.getLogger(),mutationId:++this.mutationId,options:e.defaultMutationOptions(t),state:n,defaultOptions:t.mutationKey?e.getMutationDefaults(t.mutationKey):void 0});return this.add(o),o}add(e){this.mutations.push(e),this.notify({type:"added",mutation:e})}remove(e){this.mutations=this.mutations.filter(t=>t!==e),this.notify({type:"removed",mutation:e})}clear(){c.batch(()=>{this.mutations.forEach(e=>{this.remove(e)})})}getAll(){return this.mutations}find(e){return void 0===e.exact&&(e.exact=!0),this.mutations.find(t=>matchMutation(e,t))}findAll(e){return this.mutations.filter(t=>matchMutation(e,t))}notify(e){c.batch(()=>{this.listeners.forEach(({listener:t})=>{t(e)})})}resumePausedMutations(){var e;return this.resuming=(null!=(e=this.resuming)?e:Promise.resolve()).then(()=>{let e=this.mutations.filter(e=>
1114e.state.isPaused);return c.batch(()=>e.reduce((e,t)=>e.then(()=>t.continue().catch(utils_noop)),Promise.resolve()))}).then(()=>{this.resuming=void 0}),this.resuming}};function getNextPageParam(e,t){return null==e.getNextPageParam?void 0:e.getNextPageParam(t[t.length-1],t)}let QueryClient=class QueryClient{constructor(e={}){this.queryCache=e.queryCache||new QueryCache,this.mutationCache=e.mutationCache||new MutationCache,this.logger=e.logger||s,this.defaultOptions=e.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[],this.mountCount=0}mount(){this.mountCount++,1===this.mountCount&&(this.unsubscribeFocus=l.subscribe(()=>{l.isFocused()&&(this.resumePausedMutations(),this.queryCache.onFocus())}),this.unsubscribeOnline=d.subscribe(()=>{d.isOnline()&&(this.resumePausedMutations(),this.queryCache.onOnline())}))}unmount(){var e,t;this.mountCount--,0===this.mountCount&&(null==(e=this.unsubscribeFocus)||e.call(this),this.unsubscribeFocus=void 0,null==(t=this.unsubscribeOnline)||t.call(this),this.unsubscribeOnline=void 0)}isFetching(e,t){let[n]=parseFilterArgs(e,t);return n.fetchStatus="fetching",this.queryCache.findAll(n).length}isMutating(e){return this.mutationCache.findAll({...e,fetching:!0}).length}getQueryData(e,t){var n;return null==(n=this.queryCache.find(e,t))?void 0:n.state.data}ensureQueryData(e,t,n){let o=parseQueryArgs(e,t,n),i=this.getQueryData(o.queryKey);return i?Promise.resolve(i):this.fetchQuery(o)}getQueriesData(e){return this.getQueryCache().findAll(e).map(({queryKey:e,state:t})=>{let n=t.data;return[e,n]})}setQueryData(e,t,n){let o=this.queryCache.find(e),i=null==o?void 0:o.state.data,s="function"==typeof t?t(i):t;if(void 0===s)return;let c=parseQueryArgs(e),l=this.defaultQueryOptions(c);return this.queryCache.build(this,l).setData(s,{...n,manual:!0})}setQueriesData(e,t,n){return c.batch(()=>this.getQueryCache().findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e,t){var n;return null==(n=this.queryCache.find(e,t))?void 0:n.state}removeQueries(e,t){let[n]=parseFilterArgs(e,t),o=this.queryCache;c.batch(()=>{o.findAll(n).forEach(e=>{o.remove(e)})})}resetQueries(e,t,n){let[o,i]=parseFilterArgs(e,t,n),s=this.queryCache,l={type:"active",...o};return c.batch(()=>(s.findAll(o).forEach(e=>{e.reset()}),this.refetchQueries(l,i)))}cancelQueries(e,t,n){let[o,i={}]=parseFilterArgs(e,t,n);void 0===i.revert&&(i.revert=!0);let s=c.batch(()=>this.queryCache.findAll(o).map(e=>e.cancel(i)));return Promise.all(s).then(utils_noop).catch(utils_noop)}invalidateQueries(e,t,n){let[o,i]=parseFilterArgs(e,t,n);return c.batch(()=>{var e,t;if(this.queryCache.findAll(o).forEach(e=>{e.invalidate()}),"none"===o.refetchType)return Promise.resolve();let n={...o,type:null!=(e=null!=(t=o.refetchType)?t:o.type)?e:"active"};return this.refetchQueries(n,i)})}refetchQueries(e,t,n){let[o,i]=parseFilterArgs(e,t,n),s=c.batch(()=>this.queryCache.findAll(o).filter(e=>!e.isDisabled()).map(e=>{var t;return e.fetch(void 0,{...i,cancelRefetch:null==(t=null==i?void 0:i.cancelRefetch)||t,meta:{refetchPage:o.refetchPage}})})),l=Promise.all(s).then(utils_noop);return null!=i&&i.throwOnError||(l=l.catch(utils_noop)),l}fetchQuery(e,t,n){let o=parseQueryArgs(e,t,n),i=this.defaultQueryOptions(o);void 0===i.retry&&(i.retry=!1);let s=this.queryCache.build(this,i);return s.isStaleByTime(i.staleTime)?s.fetch(i):Promise.resolve(s.state.data)}prefetchQuery(e,t,n){return this.fetchQuery(e,t,n).then(utils_noop).catch(utils_noop)}fetchInfiniteQuery(e,t,n){let o=parseQueryArgs(e,t,n);return o.behavior={onFetch:e=>{e.fetchFn=()=>{var t,n,o,i,s,c,l;let u;let d=null==(t=e.fetchOptions)?void 0:null==(n=t.meta)?void 0:n.refetchPage,p=null==(o=e.fetchOptions)?void 0:null==(i=o.meta)?void 0:i.fetchMore,m=null==p?void 0:p.pageParam,b=(null==p?void 0:p.direction)==="forward",g=(null==p?void 0:p.direction)==="backward",y=(null==(s=e.state.data)?void 0:s.pages)||[],v=(null==(c=e.state.data)?void 0:c.pageParams)||[],E=v,x=!1,addSignalProperty=t=>{Object.defineProperty(t,"signal",{enumerable:!0,get:()=>{var t,n;return null!=(t=e.signal)&&t.aborted?x=!0:null==(n=e.signal)||n.addEventListener("abort",()=>{x=!0}),e.signal}})},P=e.options.queryFn||(()=>Promise.reject("Missing queryFn for queryKey '"+e.options.queryHash+"'")),buildNewPages=(e,t,n,o)=>(E=o?[t,...E]:[...E,t],o?[n,...e]:[...e,n]),fetchPage=(t,n,o,i)=>{if(x)return Promise.reject("Cancelled");if(void 0===o&&!n&&t.length)return Promise.resolve(t);let s={queryKey:e.queryKey,pageParam:o,meta:e.options.meta};addSignalProperty(s);let c=P(s),l=Promise.resolve(c).then(e=>buildNewPages(t,o,e,i));return l};if(y.length){if(b){let t=void 0!==m,n=t?m:getNextPageParam(e.options,y);u=fetchPage(y,t,n)}else if(g){let t=void 0!==m,n=t?m:null==(l=e.options).getPreviousPageParam?void 0:l.getPreviousPageParam(y[0],y);u=fetchPage(y,t,n,!0)}else{E=[];let t=void 0===e.options.getNextPageParam,n=!d||!y[0]||d(y[0],0,y);u=n?fetchPage([],t,v[0]):Promise.resolve(buildNewPages([],v[0],y[0]));for(let n=1;n<y.length;n++)u=u.then(o=>{let i=!d||!y[n]||d(y[n],n,y);if(i){let i=t?v[n]:getNextPageParam(e.options,o);return fetchPage(o,t,i)}return Promise.resolve(buildNewPages(o,v[n],y[n]))})}}else u=fetchPage([]);let _=u.then(e=>({pages:e,pageParams:E}));return _}}},this.fetchQuery(o)}prefetchInfiniteQuery(e,t,n){return this.fetchInfiniteQuery(e,t,n).then(utils_noop).catch(utils_noop)}resumePausedMutations(){return this.mutationCache.resumePausedMutations()}getQueryCache(){return this.queryCache}getMutationCache(){return this.mutationCache}getLogger(){return this.logger}getDefaultOptions(){return this.defaultOptions}setDefaultOptions(e){this.defaultOptions=e}setQueryDefaults(e,t){let n=this.queryDefaults.find(t=>hashQueryKey(e)===hashQueryKey(t.queryKey));n?n.defaultOptions=t:this.queryDefaults.push({queryKey:e,defaultOptions:t})}getQueryDefaults(e){if(!e)return;let t=this.queryDefaults.find(t=>partialDeepEqual(e,t.queryKey));return null==t?void 0:t.defaultOptions}setMutationDefaults(e,t){let n=this.mutationDefaults.find(t=>hashQueryKey(e)===hashQueryKey(t.mutationKey));n?n.defaultOptions=t:this.mutationDefaults.push({mutationKey:e,defaultOptions:t})}getMutationDefaults(e){if(!e)return;let t=this.mutationDefaults.find(t=>partialDeepEqual(e,t.mutationKey));return null==t?void 0:t.defaultOptions}defaultQueryOptions(e){if(null!=e&&e._defaulted)return e;let t={...this.defaultOptions.queries,...this.getQueryDefaults(null==e?void 0:e.queryKey),...e,_defaulted:!0};return!t.queryHash&&t.queryKey&&(t.queryHash=hashQueryKeyByOptions(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.useErrorBoundary&&(t.useErrorBoundary=!!t.suspense),t}defaultMutationOptions(e){return null!=e&&e._defaulted?e:{...this.defaultOptions.mutations,...this.getMutationDefaults(null==e?void 0:e.mutationKey),...e,_defaulted:!0}}clear(){this.queryCache.clear(),this.mutationCache.clear()}};
1114function defaultShouldDehydrateMutation(e){return e.state.isPaused}function defaultShouldDehydrateQuery(e){return"success"===e.state.status}let p=["added","removed","updated"];function isCacheableEventType(e){return p.includes(e)}async function persistQueryClientRestore({queryClient:e,persister:t,maxAge:n=864e5,buster:o="",hydrateOptions:i}){try{let s=await t.restoreClient();if(s){if(s.timestamp){let c=Date.now()-s.timestamp>n,l=s.buster!==o;c||l?t.removeClient():function(e,t,n){if("object"!=typeof t||null===t)return;let o=e.getMutationCache(),i=e.getQueryCache(),s=t.mutations||[],c=t.queries||[];s.forEach(t=>{var i;o.build(e,{...null==n?void 0:null==(i=n.defaultOptions)?void 0:i.mutations,mutationKey:t.mutationKey},t.state)}),c.forEach(({queryKey:t,state:o,queryHash:s})=>{var c;let l=i.get(s);if(l){if(l.state.dataUpdatedAt<o.dataUpdatedAt){let{fetchStatus:e,...t}=o;l.setState(t)}return}i.build(e,{...null==n?void 0:null==(c=n.defaultOptions)?void 0:c.queries,queryKey:t,queryHash:s},{...o,fetchStatus:"idle"})})}(e,s.clientState,i)}else t.removeClient()}}catch(e){t.removeClient()}}async function persistQueryClientSave({queryClient:e,persister:t,buster:n="",dehydrateOptions:o}){let i={buster:n,timestamp:Date.now(),clientState:function(e,t={}){let n=[],o=[];if(!1!==t.dehydrateMutations){let o=t.shouldDehydrateMutation||defaultShouldDehydrateMutation;e.getMutationCache().getAll().forEach(e=>{o(e)&&n.push({mutationKey:e.options.mutationKey,state:e.state})})}if(!1!==t.dehydrateQueries){let n=t.shouldDehydrateQuery||defaultShouldDehydrateQuery;e.getQueryCache().getAll().forEach(e=>{n(e)&&o.push({state:e.state,queryKey:e.queryKey,queryHash:e.queryHash})})}return{mutations:n,queries:o}}(e,o)};await t.persistClient(i)}var m=n(60481),b=n(67294);let g=b.createContext(void 0),y=b.createContext(!1);function getQueryClientContext(e,t){return e||(t&&"undefined"!=typeof window?(window.ReactQueryClientContext||(window.ReactQueryClientContext=g),window.ReactQueryClientContext):g)}let useQueryClient=({context:e}={})=>{let t=b.useContext(getQueryClientContext(e,b.useContext(y)));if(!t)throw Error("No QueryClient set, use QueryClientProvider to set one");return t},QueryClientProvider=({client:e,children:t,context:n,contextSharing:o=!1})=>{b.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]);let i=getQueryClientContext(n,o);return b.createElement(y.Provider,{value:!n&&o},b.createElement(i.Provider,{value:e},t))},v=b.createContext(!1),useIsRestoring=()=>b.useContext(v);v.Provider;let E=b.createContext((o=!1,{clearReset:()=>{o=!1},reset:()=>{o=!0},isReset:()=>o})),useQueryErrorResetBoundary=()=>b.useContext(E);var x=n(61688);let MutationObserver=class MutationObserver extends Subscribable{constructor(e,t){super(),this.client=e,this.setOptions(t),this.bindMethods(),this.updateResult()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){var t;let n=this.options;this.options=this.client.defaultMutationOptions(e),shallowEqualObjects(n,this.options)||this.client.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.currentMutation,observer:this}),null==(t=this.currentMutation)||t.setOptions(this.options)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.currentMutation)||e.removeObserver(this)}}onMutationUpdate(e){this.updateResult();let t={listeners:!0};"success"===e.type?t.onSuccess=!0:"error"===e.type&&(t.onError=!0),this.notify(t)}getCurrentResult(){return this.currentResult}reset(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})}mutate(e,t){return this.mutateOptions=t,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,{...this.options,variables:void 0!==e?e:this.options.variables}),this.currentMutation.addObserver(this),this.currentMutation.execute()}updateResult(){let e=this.currentMutation?this.currentMutation.state:mutation_getDefaultState(),t={...e,isLoading:"loading"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset};this.currentResult=t}notify(e){c.batch(()=>
1114{if(this.mutateOptions&&this.hasListeners()){var t,n,o,i,s,c,l,u;e.onSuccess?(null==(t=(n=this.mutateOptions).onSuccess)||t.call(n,this.currentResult.data,this.currentResult.variables,this.currentResult.context),null==(o=(i=this.mutateOptions).onSettled)||o.call(i,this.currentResult.data,null,this.currentResult.variables,this.currentResult.context)):e.onError&&(null==(s=(c=this.mutateOptions).onError)||s.call(c,this.currentResult.error,this.currentResult.variables,this.currentResult.context),null==(l=(u=this.mutateOptions).onSettled)||l.call(u,void 0,this.currentResult.error,this.currentResult.variables,this.currentResult.context))}e.listeners&&this.listeners.forEach(({listener:e})=>{e(this.currentResult)})})}};let P=x.useSyncExternalStore;function useMutation_noop(){}let QueryObserver=class QueryObserver extends Subscribable{constructor(e,t){super(),this.client=e,this.options=t,this.trackedProps=new Set,this.selectError=null,this.bindMethods(),this.setOptions(t)}bindMethods(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(this.currentQuery.addObserver(this),shouldFetchOnMount(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return shouldFetchOn(this.currentQuery,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return shouldFetchOn(this.currentQuery,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.clearStaleTimeout(),this.clearRefetchInterval(),this.currentQuery.removeObserver(this)}setOptions(e,t){let n=this.options,o=this.currentQuery;if(this.options=this.client.defaultQueryOptions(e),shallowEqualObjects(n,this.options)||this.client.getQueryCache().notify({type:"observerOptionsUpdated",query:this.currentQuery,observer:this}),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled)throw Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=n.queryKey),this.updateQuery();let i=this.hasListeners();i&&shouldFetchOptionally(this.currentQuery,o,this.options,n)&&this.executeFetch(),this.updateResult(t),i&&(this.currentQuery!==o||this.options.enabled!==n.enabled||this.options.staleTime!==n.staleTime)&&this.updateStaleTimeout();let s=this.computeRefetchInterval();i&&(this.currentQuery!==o||this.options.enabled!==n.enabled||s!==this.currentRefetchInterval)&&this.updateRefetchInterval(s)}getOptimisticResult(e){let t=this.client.getQueryCache().build(this.client,e),n=this.createResult(t,e);return e.keepPreviousData||(void 0!==e.placeholderData?!n.isPlaceholderData:shallowEqualObjects(this.getCurrentResult(),n))||(this.currentResult=n,this.currentResultOptions=this.options,this.currentResultState=this.currentQuery.state),n}getCurrentResult(){return this.currentResult}trackResult(e){let t={};return Object.keys(e).forEach(n=>{Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:()=>(this.trackedProps.add(n),e[n])})}),t}getCurrentQuery(){return this.currentQuery}remove(){this.client.getQueryCache().remove(this.currentQuery)}refetch({refetchPage:e,...t}={}){return this.fetch({...t,meta:{refetchPage:e}})}fetchOptimistic(e){let t=this.client.defaultQueryOptions(e),n=this.client.getQueryCache().build(this.client,t);return n.isFetchingOptimistic=!0,n.fetch().then(()=>this.createResult(n,t))}fetch(e){var t;return this.executeFetch({...e,cancelRefetch:null==(t=e.cancelRefetch)||t}).then(()=>(this.updateResult(),this.currentResult))}executeFetch(e){this.updateQuery();let t=this.currentQuery.fetch(this.options,e);return null!=e&&e.throwOnError||(t=t.catch(utils_noop)),t}updateStaleTimeout(){if(this.clearStaleTimeout(),i||this.currentResult.isStale||!isValidTimeout(this.options.staleTime))return;let e=timeUntilStale(this.currentResult.dataUpdatedAt,this.options.staleTime);this.staleTimeoutId=setTimeout(()=>{this.currentResult.isStale||this.updateResult()},e+1)}computeRefetchInterval(){var e;return"function"==typeof this.options.refetchInterval?this.options.refetchInterval(this.currentResult.data,this.currentQuery):null!=(e=this.options.refetchInterval)&&e}updateRefetchInterval(e){this.clearRefetchInterval(),this.currentRefetchInterval=e,!i&&!1!==this.options.enabled&&isValidTimeout(this.currentRefetchInterval)&&0!==this.currentRefetchInterval&&(this.refetchIntervalId=setInterval(()=>
1114{(this.options.refetchIntervalInBackground||l.isFocused())&&this.executeFetch()},this.currentRefetchInterval))}updateTimers(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())}clearStaleTimeout(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)}clearRefetchInterval(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)}createResult(e,t){let n;let o=this.currentQuery,i=this.options,s=this.currentResult,c=this.currentResultState,l=this.currentResultOptions,u=e!==o,d=u?e.state:this.currentQueryInitialState,p=u?this.currentResult:this.previousQueryResult,{state:m}=e,{dataUpdatedAt:b,error:g,errorUpdatedAt:y,fetchStatus:v,status:E}=m,x=!1,P=!1;if(t._optimisticResults){let n=this.hasListeners(),s=!n&&shouldFetchOnMount(e,t),c=n&&shouldFetchOptionally(e,o,t,i);(s||c)&&(v=canFetch(e.options.networkMode)?"fetching":"paused",b||(E="loading")),"isRestoring"===t._optimisticResults&&(v="idle")}if(t.keepPreviousData&&!m.dataUpdatedAt&&null!=p&&p.isSuccess&&"error"!==E)n=p.data,b=p.dataUpdatedAt,E=p.status,x=!0;else if(t.select&&void 0!==m.data){if(s&&m.data===(null==c?void 0:c.data)&&t.select===this.selectFn)n=this.selectResult;else try{this.selectFn=t.select,n=t.select(m.data),n=replaceData(null==s?void 0:s.data,n,t),this.selectResult=n,this.selectError=null}catch(e){this.selectError=e}}else n=m.data;if(void 0!==t.placeholderData&&void 0===n&&"loading"===E){let e;if(null!=s&&s.isPlaceholderData&&t.placeholderData===(null==l?void 0:l.placeholderData))e=s.data;else if(e="function"==typeof t.placeholderData?t.placeholderData():t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),this.selectError=null}catch(e){this.selectError=e}void 0!==e&&(E="success",n=replaceData(null==s?void 0:s.data,e,t),P=!0)}this.selectError&&(g=this.selectError,n=this.selectResult,y=Date.now(),E="error");let _="fetching"===v,I="loading"===E,j="error"===E,R={status:E,fetchStatus:v,isLoading:I,isSuccess:"success"===E,isError:j,isInitialLoading:I&&_,data:n,dataUpdatedAt:b,error:g,errorUpdatedAt:y,failureCount:m.fetchFailureCount,failureReason:m.fetchFailureReason,errorUpdateCount:m.errorUpdateCount,isFetched:m.dataUpdateCount>0||m.errorUpdateCount>0,isFetchedAfterMount:m.dataUpdateCount>d.dataUpdateCount||m.errorUpdateCount>d.errorUpdateCount,isFetching:_,isRefetching:_&&!I,isLoadingError:j&&0===m.dataUpdatedAt,isPaused:"paused"===v,isPlaceholderData:P,isPreviousData:x,isRefetchError:j&&0!==m.dataUpdatedAt,isStale:isStale(e,t),refetch:this.refetch,remove:this.remove};return R}updateResult(e){let t=this.currentResult,n=this.createResult(this.currentQuery,this.options);if(this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,shallowEqualObjects(n,t))return;this.currentResult=n;let o={cache:!0};(null==e?void 0:e.listeners)!==!1&&(()=>{if(!t)return!0;let{notifyOnChangeProps:e}=this.options,n="function"==typeof e?e():e;if("all"===n||!n&&!this.trackedProps.size)return!0;let o=new Set(null!=n?n:this.trackedProps);return this.options.useErrorBoundary&&o.add("error"),Object.keys(this.currentResult).some(e=>{let n=this.currentResult[e]!==t[e];return n&&o.has(e)})})()&&(o.listeners=!0),this.notify({...o,...e})}updateQuery(){let e=this.client.getQueryCache().build(this.client,this.options);if(e===this.currentQuery)return;let t=this.currentQuery;this.currentQuery=e,this.currentQueryInitialState=e.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(null==t||t.removeObserver(this),e.addObserver(this))}onQueryUpdate(e){let t={};"success"===e.type?t.onSuccess=!e.manual:"error"!==e.type||isCancelledError(e.error)||(t.onError=!0),this.updateResult(t),this.hasListeners()&&this.updateTimers()}notify(e){c.batch(()=>{var t,n,o,i,s,c,l,u;e.onSuccess?(null==(t=(n=this.options).onSuccess)||t.call(n,this.currentResult.data),null==(o=(i=this.options).onSettled)||o.call(i,this.currentResult.data,null)):e.onError&&(null==(s=(c=this.options).onError)||s.call(c,this.currentResult.error),null==(l=(u=this.options).onSettled)||l.call(u,void 0,this.currentResult.error)),e.listeners&&this.listeners.forEac
1114h(({listener:e})=>{e(this.currentResult)}),e.cache&&this.client.getQueryCache().notify({query:this.currentQuery,type:"observerResultsUpdated"})})}};function shouldFetchOnMount(e,t){return!1!==t.enabled&&!e.state.dataUpdatedAt&&!("error"===e.state.status&&!1===t.retryOnMount)||e.state.dataUpdatedAt>0&&shouldFetchOn(e,t,t.refetchOnMount)}function shouldFetchOn(e,t,n){if(!1!==t.enabled){let o="function"==typeof n?n(e):n;return"always"===o||!1!==o&&isStale(e,t)}return!1}function shouldFetchOptionally(e,t,n,o){return!1!==n.enabled&&(e!==t||!1===o.enabled)&&(!n.suspense||"error"!==e.state.status)&&isStale(e,n)}function isStale(e,t){return e.isStaleByTime(t.staleTime)}var _=n(52798);function createConfig({queryClient:e=new QueryClient({defaultOptions:{queries:{cacheTime:864e5,networkMode:"offlineFirst",refetchOnWindowFocus:!1,retry:0},mutations:{networkMode:"offlineFirst"}}}),storage:t=(0,m.o6)({storage:"undefined"!=typeof window&&window.localStorage?window.localStorage:m.wp}),persister:n="undefined"!=typeof window?function({storage:e,key:t="REACT_QUERY_OFFLINE_CACHE",throttleTime:n=1e3,serialize:o=JSON.stringify,deserialize:i=JSON.parse,retry:s}){if(e){let trySave=n=>{try{e.setItem(t,o(n));return}catch(e){return e}};return{persistClient:function(e,t=100){let n,o=null;return function(...i){n=i,null===o&&(o=setTimeout(()=>{e(...n),o=null},t))}}(e=>{let t=e,n=trySave(t),o=0;for(;n&&t;)o++,(t=null==s?void 0:s({persistedClient:t,error:n,errorCount:o}))&&(n=trySave(t))},n),restoreClient:()=>{let n=e.getItem(t);if(n)return i(n)},removeClient:()=>{e.removeItem(t)}}}return{persistClient:noop,restoreClient:()=>void 0,removeClient:noop}}({key:"cache",storage:t,serialize:e=>e,deserialize:e=>e}):void 0,...o}){let i=(0,m._g)({...o,storage:t});return n&&function(e){persistQueryClientRestore(e).then(()=>{(function(e){let t=e.queryClient.getQueryCache().subscribe(t=>{isCacheableEventType(t.type)&&persistQueryClientSave(e)}),n=e.queryClient.getMutationCache().subscribe(t=>{isCacheableEventType(t.type)&&persistQueryClientSave(e)})})(e)})}({queryClient:e,persister:n,dehydrateOptions:{shouldDehydrateQuery:e=>0!==e.cacheTime&&!1!==e.queryKey[0].persist}}),Object.assign(i,{queryClient:e})}n(81782);var I=b.createContext(void 0),j=b.createContext(void 0);function WagmiConfig({children:e,config:t}){return b.createElement(I.Provider,{children:b.createElement(QueryClientProvider,{children:e,client:t.queryClient,context:j}),value:t})}function useConfig(){let e=b.useContext(I);if(!e)throw Error("`useConfig` must be used within `WagmiConfig`.\n\nRead more: https://wagmi.sh/react/WagmiConfig");return e}var R=x.useSyncExternalStore;function dist_hasObjectPrototype(e){return"[object Object]"===Object.prototype.toString.call(e)}function queryKeyHashFn(e){return JSON.stringify(e,(e,t)=>!function(e){if(!dist_hasObjectPrototype(e))return!1;let t=e.constructor;if(void 0===t)return!0;let n=t.prototype;return!!(dist_hasObjectPrototype(n)&&n.hasOwnProperty("isPrototypeOf"))}(t)?"bigint"==typeof t?t.toString():t:Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}))}function dist_useMutation(e,t,n){let o=parseMutationArgs(e,t,n);return function(e,t,n){var o,i;let s=parseMutationArgs(e,void 0,void 0),l=useQueryClient({context:s.context}),[u]=b.useState(()=>new MutationObserver(l,s));b.useEffect(()=>{u.setOptions(s)},[u,s]);let d=P(b.useCallback(e=>u.subscribe(c.batchCalls(e)),[u]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),p=b.useCallback((e,t)=>{u.mutate(e,t).catch(useMutation_noop)},[u]);if(d.error&&(o=u.options.useErrorBoundary,i=[d.error],"function"==typeof o?o(...i):!!o))throw d.error;return{...d,mutate:p,mutateAsync:d.mutate}}({context:j,...o})}function useQuery(e,t,n){let o=Array.isArray(e)?"function"==typeof t?{...n,queryKey:e,queryFn:t}:{...t,queryKey:e}:e,i=function(e,t){var n,o;let i=useQueryClient({context:e.context}),s=useIsRestoring(),l=useQueryErrorResetBoundary(),u=i.defaultQueryOptions({...e,queryKeyHashFn});u._optimisticResults=s?"isRestoring":"optimistic",u.onError&&(u.onError=c.batchCalls(u.onError)),u.onSuccess&&(u.onSuccess=c.batchCalls(u.onSuccess)),u.onSettled&&(u.onSettled=c.batchCalls(u.onSettled)),u.suspense&&"number"!=typeof u.staleTime&&(u.staleTime=1e3),(u.suspense||u.useErrorBoundary)&&!l.isReset()&&(u.retryOn
1114Mount=!1);let[d]=b.useState(()=>new t(i,u)),p=d.getOptimisticResult(u);if(R(b.useCallback(e=>s?()=>void 0:d.subscribe(c.batchCalls(e)),[d,s]),()=>d.getCurrentResult(),()=>d.getCurrentResult()),b.useEffect(()=>{l.clearReset()},[l]),b.useEffect(()=>{d.setOptions(u,{listeners:!1})},[u,d]),u.suspense&&p.isLoading&&p.isFetching&&!s)throw d.fetchOptimistic(u).then(({data:e})=>{u.onSuccess?.(e),u.onSettled?.(e,null)}).catch(e=>{l.clearReset(),u.onError?.(e),u.onSettled?.(void 0,e)});if(p.isError&&!l.isReset()&&!p.isFetching&&(n=u.useErrorBoundary,o=[p.error,d.getCurrentQuery()],"function"==typeof n?n(...o):!!n))throw p.error;let m="loading"===p.status&&"idle"===p.fetchStatus?"idle":p.status,g="loading"===m&&"fetching"===p.fetchStatus;return{...p,defaultedOptions:u,isIdle:"idle"===m,isLoading:g,observer:d,status:m}}({context:j,...o},QueryObserver),s={data:i.data,error:i.error,fetchStatus:i.fetchStatus,isError:i.isError,isFetched:i.isFetched,isFetchedAfterMount:i.isFetchedAfterMount,isFetching:i.isFetching,isIdle:i.isIdle,isLoading:i.isLoading,isRefetching:i.isRefetching,isSuccess:i.isSuccess,refetch:i.refetch,status:i.status,internal:{dataUpdatedAt:i.dataUpdatedAt,errorUpdatedAt:i.errorUpdatedAt,failureCount:i.failureCount,isFetchedAfterMount:i.isFetchedAfterMount,isLoadingError:i.isLoadingError,isPaused:i.isPaused,isPlaceholderData:i.isPlaceholderData,isPreviousData:i.isPreviousData,isRefetchError:i.isRefetchError,isStale:i.isStale,remove:i.remove}};return i.defaultedOptions.notifyOnChangeProps?s:function(e,t){let n={};return Object.keys(e).forEach(o=>{Object.defineProperty(n,o,{configurable:!1,enumerable:!0,get:()=>(t.trackedProps.add(o),e[o])})}),n}(s,i.observer)}var useQueryClient2=()=>useQueryClient({context:j});function usePublicClient({chainId:e}={}){return(0,_.useSyncExternalStoreWithSelector)(t=>(0,m.pC)({chainId:e},t),()=>(0,m.uV)({chainId:e}),()=>(0,m.uV)({chainId:e}),e=>e,(e,t)=>e.uid===t.uid)}function useChainId({chainId:e}={}){let t=usePublicClient({chainId:e});return t.chain.id}function queryKey2({chainId:e,scopeKey:t}){return[{entity:"blockNumber",chainId:e,scopeKey:t}]}function queryFn2({queryKey:[{chainId:e}]}){return(0,m.RQ)({chainId:e})}function useBlockNumber({cacheTime:e=0,chainId:t,enabled:n=!0,scopeKey:o,staleTime:i,suspense:s,watch:c=!1,onBlock:l,onError:u,onSettled:d,onSuccess:p}={}){let g=useChainId({chainId:t}),y=usePublicClient({chainId:g}),v=function({chainId:e}={}){return(0,_.useSyncExternalStoreWithSelector)(t=>(0,m.fq)({chainId:e},t),()=>(0,m.jr)({chainId:e}),()=>(0,m.jr)({chainId:e}),e=>e,(e,t)=>e?.uid===t?.uid)}({chainId:g}),E=useQueryClient2();return b.useEffect(()=>{if(!n||!c&&!l)return;let e=v??y,t=e.watchBlockNumber({onBlockNumber:e=>{c&&E.setQueryData(queryKey2({chainId:g,scopeKey:o}),e),l&&l(e)},emitOnBegin:!0});return t},[g,o,l,y,E,c,v,n]),useQuery(queryKey2({scopeKey:o,chainId:g}),queryFn2,{cacheTime:e,enabled:n,staleTime:i,suspense:s,onError:u,onSettled:d,onSuccess:p})}function useInvalidateOnBlock({chainId:e,enabled:t,queryKey:n}){let o=useQueryClient2(),i=b.useCallback(()=>o.invalidateQueries({queryKey:n},{cancelRefetch:!1}),[o,n]);useBlockNumber({chainId:e,enabled:t,onBlock:t?i:void 0,scopeKey:t?void 0:"idle"})}var isPlainObject2=e=>"object"==typeof e&&!Array.isArray(e);function useSyncExternalStoreWithTracked(e,t,n=t,o=m.vZ){let i=b.useRef([]),s=(0,_.useSyncExternalStoreWithSelector)(e,t,n,e=>e,(e,t)=>{if(isPlainObject2(e)&&isPlainObject2(t)&&i.current.length){for(let n of i.current){let i=o(e[n],t[n]);if(!i)return!1}return!0}return o(e,t)});if(isPlainObject2(s)){let e={...s};return Object.defineProperties(e,Object.entries(e).reduce((e,[t,n])=>({...e,[t]:{configurable:!1,enumerable:!0,get:()=>(i.current.includes(t)||i.current.push(t),n)}}),{})),e}return s}function useAccount({onConnect:e,onDisconnect:t}={}){let n=useConfig(),o=b.useCallback(e=>(0,m.uH)(e),[n]),i=useSyncExternalStoreWithTracked(o,m.D0),s=b.useRef(),c=s.current;return b.useEffect(()=>{c?.status!=="connected"&&"connected"===i.status&&e?.({address:i.address,connector:i.connector,isReconnected:c?.status==="reconnecting"||c?.status===void 0}),c?.status==="connected"&&"disconnected"===i.status&&t?.(),s.current=i},[e,t,c,i]),i}function queryFn4({queryKey:[{address:e,chainId:t,formatUnits:n,token:o}]}
1114){if(!e)throw Error("address is required");return(0,m.EG)({address:e,chainId:t,formatUnits:n,token:o})}function useBalance({address:e,cacheTime:t,chainId:n,enabled:o=!0,formatUnits:i,scopeKey:s,staleTime:c,suspense:l,token:u,watch:d,onError:p,onSettled:m,onSuccess:g}={}){let y=useChainId({chainId:n}),v=b.useMemo(()=>(function({address:e,chainId:t,formatUnits:n,scopeKey:o,token:i}){return[{entity:"balance",address:e,chainId:t,formatUnits:n,scopeKey:o,token:i}]})({address:e,chainId:y,formatUnits:i,scopeKey:s,token:u}),[e,y,i,s,u]),E=useQuery(v,queryFn4,{cacheTime:t,enabled:!!(o&&e),staleTime:c,suspense:l,onError:p,onSettled:m,onSuccess:g});return useInvalidateOnBlock({chainId:y,enabled:!!(o&&d&&e),queryKey:v}),E}var mutationKey=e=>[{entity:"connect",...e}],mutationFn=e=>{let{connector:t,chainId:n}=e;if(!t)throw Error("connector is required");return(0,m.$j)({connector:t,chainId:n})};function useConnect({chainId:e,connector:t,onError:n,onMutate:o,onSettled:i,onSuccess:s}={}){let c=useConfig(),{data:l,error:u,isError:d,isIdle:p,isLoading:m,isSuccess:g,mutate:y,mutateAsync:v,reset:E,status:x,variables:P}=dist_useMutation(mutationKey({connector:t,chainId:e}),mutationFn,{onError:n,onMutate:o,onSettled:i,onSuccess:s}),_=b.useCallback(n=>y({chainId:n?.chainId??e,connector:n?.connector??t}),[e,t,y]),I=b.useCallback(n=>v({chainId:n?.chainId??e,connector:n?.connector??t}),[e,t,v]);return{connect:_,connectAsync:I,connectors:c.connectors,data:l,error:u,isError:d,isIdle:p,isLoading:m,isSuccess:g,pendingConnector:P?.connector,reset:E,status:x,variables:P}}var M=[{entity:"disconnect"}],mutationFn2=()=>(0,m.zP)();function useDisconnect({onError:e,onMutate:t,onSettled:n,onSuccess:o}={}){let{error:i,isError:s,isIdle:c,isLoading:l,isSuccess:u,mutate:d,mutateAsync:p,reset:m,status:b}=dist_useMutation(M,mutationFn2,{...e?{onError(t,n,o){e(t,o)}}:{},onMutate:t,...n?{onSettled(e,t,o,i){n(t,i)}}:{},...o?{onSuccess(e,t,n){o(n)}}:{}});return{disconnect:d,disconnectAsync:p,error:i,isError:s,isIdle:c,isLoading:l,isSuccess:u,reset:m,status:b}}function useNetwork(){let e=useConfig(),t=(0,b.useCallback)(e=>(0,m.QC)(e),[e]);return useSyncExternalStoreWithTracked(t,m.Hy)}var mutationKey3=e=>[{entity:"signMessage",...e}],mutationFn3=e=>{let{message:t}=e;if(!t)throw Error("message is required");return(0,m.l)({message:t})};function useSignMessage({message:e,onError:t,onMutate:n,onSettled:o,onSuccess:i}={}){let{data:s,error:c,isError:l,isIdle:u,isLoading:d,isSuccess:p,mutate:m,mutateAsync:g,reset:y,status:v,variables:E}=dist_useMutation(mutationKey3({message:e}),mutationFn3,{onError:t,onMutate:n,onSettled:o,onSuccess:i}),x=b.useCallback(t=>m(t||{message:e}),[e,m]),P=b.useCallback(t=>g(t||{message:e}),[e,g]);return{data:s,error:c,isError:l,isIdle:u,isLoading:d,isSuccess:p,reset:y,signMessage:x,signMessageAsync:P,status:v,variables:E}}var mutationKey5=e=>[{entity:"switchNetwork",...e}],mutationFn5=e=>{let{chainId:t}=e;if(!t)throw Error("chainId is required");return(0,m.If)({chainId:t})};function useSwitchNetwork({chainId:e,throwForSwitchChainNotSupported:t,onError:n,onMutate:o,onSettled:i,onSuccess:s}={}){let c,l;let u=useConfig(),d=function(){let[,e]=b.useReducer(e=>e+1,0);return e}(),{data:p,error:m,isError:g,isIdle:y,isLoading:v,isSuccess:E,mutate:x,mutateAsync:P,reset:_,status:I,variables:j}=dist_useMutation(mutationKey5({chainId:e}),mutationFn5,{onError:n,onMutate:o,onSettled:i,onSuccess:s}),R=b.useCallback(t=>x({chainId:t??e}),[e,x]),M=b.useCallback(t=>P({chainId:t??e}),[e,P]);b.useEffect(()=>{let e=u.subscribe(({chains:e,connector:t})=>({chains:e,connector:t}),d);return e},[u,d]);let F=!!u.connector?.switchChain;return(t||F)&&(c=R,l=M),{chains:u.chains??[],data:p,error:m,isError:g,isIdle:y,isLoading:v,isSuccess:E,pendingChainId:j?.chainId,reset:_,status:I,switchNetwork:c,switchNetworkAsync:l,variables:j}}function useContractRead({abi:e,address:t,account:n,args:o,blockNumber:i,blockTag:s,cacheOnBlock:c=!1,cacheTime:l,chainId:u,enabled:d=!0,functionName:p,isDataEqual:g,keepPreviousData:y,onError:v,onSettled:E,onSuccess:x,scopeKey:P,select:_,staleTime:I,structuralSharing:j=(e,t)=>(0,m.vZ)(e,t)?e:utils_replaceEqualDeep(e,t),suspense:R,watch:M}={}){let F=useChainId({chainId:u}),{data:q}=useBlockNumber({chainId:F,enabled:M||c,scopeKey:M||c?void 0:"idle",watch:M}),H=i??q,z=b.useMemo(()=>(function({account:e,address:t,args:n,blockNumber:o,blockTag:i,chainId:s,functionName:c,scopeKey:l}){return[{entity:"readContract",account:e,address:t,args:n,blockNumber:o,blockTag:i,chainId:s,functionName:c,scopeKey:l}]})({account:n,address:t,args:o,blockNumber:c?H:void 0,blockTag:s,chainId:F,functionName:p,scopeKey:P}),[n,t,o,H,s,c,F,p,P]),W=b.useMemo(()=>{let n=!!(d&&e&&t&&p);return c&&(n=!!(n&&H)),n},[e,t,H,c,d,p]);return useInvalidateOnBlock({chainId:F,enabled:!!(W&&M&&!c),queryKey:z}),useQuery(z,function({abi:e}){return async({queryKey:[{account:t,address:n,args:o,blockNumber:i,blockTag:s,chainId:c,functionName:l}]})=>{if(!e)throw Error("abi is required");if(!n)throw Error("address is required");return await (0,m.a4)({account:t,address:n,args:o,blockNumber:i,blockTag:s,chainId:c,abi:e,functionName:l})??null}}({abi:e}),{cacheTime:l,enabled:W,isDataEqual:g,keepPreviousData:y,select:_,staleTime:I,structuralSharing:j,suspense:R,onError:v,onSettled:E,onSuccess:x})}function mutationFn6(e){if("prepared"===e.mode){if(!e.request)throw Error("request is required");return(0,m.n9)({mode:"prepared",request:e.request})}if(!e.address)throw Error("address is required");if(!e.abi)throw Error("abi is required");if(!e.functionName)throw Error("functionName is required");return(0,m.n9)({address:e.address,args:e.args,chainId:e.chainId,abi:e.abi,functionName:e.functionName,accessList:e.accessList,account:e.account,dataSuffix:e.dataSuffix,gas:e.gas,gasPrice:e.gasPrice,maxFeePerGas:e.maxFeePerGas,maxPriorityFeePerGas:e.maxPriorityFeePerGas,nonce:e.nonce,value:e.value})}function useContractWrite(e){let{address:t,abi:n,args:o,chainId:i,functionName:s,mode:c,request:l,dataSuffix:u}=e,{accessList:d,account:p,gas:g,gasPrice:y,maxFeePerGas:v,maxPriorityFeePerGas:E,nonce:x,value:P}=(0,m.gY)(e),{data:_,error:I,isError:j,isIdle:R,isLoading:M,isSuccess:F,mutate:q,mutateAsync:H,reset:z,status:W,variables:K}=dist_useMutation(function({address:e,abi:t,functionName:n,...o}){let{args:i,accessList:s,account:c,dataSuffix:l,gas:u,gasPrice:d,maxFeePerGas:p,maxPriorityFeePerGas:m,nonce:b,request:g,value:y}=o;return[{entity:"writeContract",address:e,args:i,abi:t,accessList:s,account:c,dataSuffix:l,functionName:n,gas:u,gasPrice:d,maxFeePerGas:p,maxPriorityFeePerGas:m,nonce:b,request:g,value:y}]}({address:t,abi:n,functionName:s,chainId:i,mode:c,args:o,accessList:d,account:p,dataSuffix:u,gas:g,gasPrice:y,maxFeePerGas:v,maxPriorityFeePerGas:E,nonce:x,request:l,value:P}),mutationFn6,{onError:e.onError,onMutate:e.onMutate,onSettled:e.onSettled,onSuccess:e.onSuccess}),Q=b.useMemo(()=>
1114{if("prepared"===e.mode){if(!l)return;return()=>q({mode:"prepared",request:e.request,chainId:e.chainId})}return e=>q({address:t,args:o,abi:n,functionName:s,chainId:i,accessList:d,account:p,dataSuffix:u,gas:g,gasPrice:y,maxFeePerGas:v,maxPriorityFeePerGas:E,nonce:x,value:P,...e})},[d,p,n,t,o,i,e.chainId,e.mode,e.request,u,s,g,y,v,E,q,x,l,P]),Z=b.useMemo(()=>{if("prepared"===e.mode){if(!l)return;return()=>H({mode:"prepared",request:e.request})}return e=>H({address:t,args:o,abi:n,chainId:i,functionName:s,accessList:d,account:p,dataSuffix:u,gas:g,gasPrice:y,maxFeePerGas:v,maxPriorityFeePerGas:E,nonce:x,value:P,...e})},[d,p,n,t,o,i,e.mode,e.request,u,s,g,y,v,E,H,x,l,P]);return{data:_,error:I,isError:j,isIdle:R,isLoading:M,isSuccess:F,reset:z,status:W,variables:K,write:Q,writeAsync:Z}}function queryFn11({queryKey:[{name:e,chainId:t}]}){if(!e)throw Error("name is required");return(0,m.w6)({name:e,chainId:t})}function useEnsAvatar({cacheTime:e,chainId:t,enabled:n=!0,name:o,scopeKey:i,staleTime:s=864e5,suspense:c,onError:l,onSettled:u,onSuccess:d}={}){let p=useChainId({chainId:t});return useQuery(function({name:e,chainId:t,scopeKey:n}){return[{entity:"ensAvatar",name:e,chainId:t,scopeKey:n}]}({name:o,chainId:p,scopeKey:i}),queryFn11,{cacheTime:e,enabled:!!(n&&o&&p),staleTime:s,suspense:c,onError:l,onSettled:u,onSuccess:d})}function queryFn12({queryKey:[{address:e,chainId:t}]}){if(!e)throw Error("address is required");return(0,m.Lk)({address:e,chainId:t})}function useEnsName({address:e,cacheTime:t,chainId:n,enabled:o=!0,scopeKey:i,staleTime:s=864e5,suspense:c,onError:l,onSettled:u,onSuccess:d}={}){let p=useChainId({chainId:n});return useQuery(function({address:e,chainId:t,scopeKey:n}){return[{entity:"ensName",address:e,chainId:t,scopeKey:n}]}({address:e,chainId:p,scopeKey:i}),queryFn12,{cacheTime:t,enabled:!!(o&&e&&p),staleTime:s,suspense:c,onError:l,onSettled:u,onSuccess:d})}function useWaitForTransaction({chainId:e,confirmations:t,hash:n,timeout:o,cacheTime:i,enabled:s=!0,scopeKey:c,staleTime:l,suspense:u,onError:d,onReplaced:p,onSettled:b,onSuccess:g}={}){let y=useChainId({chainId:e});return useQuery(function({confirmations:e,chainId:t,hash:n,scopeKey:o,timeout:i}){return[{entity:"waitForTransaction",confirmations:e,chainId:t,hash:n,scopeKey:o,timeout:i}]}({chainId:y,confirmations:t,hash:n,scopeKey:c,timeout:o}),function({onReplaced:e}){return({queryKey:[{chainId:t,confirmations:n,hash:o,timeout:i}]})=>{if(!o)throw Error("hash is required");return(0,m.Mn)({chainId:t,confirmations:n,hash:o,onReplaced:e,timeout:i})}}({onReplaced:p}),{cacheTime:i,enabled:!!(s&&n),staleTime:l,suspense:u,onError:d,onSettled:b,onSuccess:g})}},29242:function(e){"use strict";e.exports=JSON.parse('{"name":"@safe-global/safe-apps-sdk","version":"8.1.0","description":"SDK developed to integrate third-party apps with Safe app.","main":"dist/src/index.js","typings":"dist/src/index.d.ts","_files":["dist/**/*","src/**/*","CHANGELOG.md","README.md"],"sideEffects":false,"keywords":["Safe","sdk","apps"],"scripts":{"test":"jest","format-dist":"sed -i \'\' \'s/\\"files\\":/\\"_files\\":/\' dist/package.json","build":"yarn rimraf dist && tsc && yarn format-dist"},"author":"Safe (https://safe.global)","license":"MIT","dependencies":{"@safe-global/safe-gateway-typescript-sdk":"^3.5.3","viem":"^1.0.0"},"repository":{"type":"git","url":"git+https://github.com/safe-global/safe-apps-sdk.git"},"bugs":{"url":"https://github.com/safe-global/safe-apps-sdk/issues"},"homepage":"https://github.com/safe-global/safe-apps-sdk#readme","publishConfig":{"access":"public"}}')}},function(e){var __webpack_exec__=function(t){return e(e.s=t)};e.O(0,[9774,179],function(){return __webpack_exec__(6840),__webpack_exec__(59974)}),_N_E=e.O()}]);

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