@dcl/explorer-website 2.6.1-25865517797.commit-b7a7cba → 2.6.1-25877826901.commit-3465800

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (140) hide show
  1. package/assets/{ConstantsUtil-ByjAYmvC.js → ConstantsUtil-C4lJZ9QJ.js} +1 -1
  2. package/assets/{ExchangeController-Bp8ztJrX.js → ExchangeController-BSoHrJkH.js} +1 -1
  3. package/assets/{HelpersUtil-Dp4e1zvd.js → HelpersUtil-COJM8Fma.js} +1 -1
  4. package/assets/{NetworkUtil-DqGcuBfF.js → NetworkUtil-XsBaDkTf.js} +1 -1
  5. package/assets/{SwapController-DUCq2f7d.js → SwapController-CykJEtRW.js} +1 -1
  6. package/assets/{W3MFrameProviderSingleton-9eitOT0j.js → W3MFrameProviderSingleton-eYQGtm7P.js} +3 -3
  7. package/assets/{basic-C7tUDecp.js → basic-OoSQYHEk.js} +1 -1
  8. package/assets/{biconomy-plHCR2Qq.js → biconomy-PKn4tIKl.js} +1 -1
  9. package/assets/{browser-VYI7gorG.js → browser-DoJWAFam.js} +1 -1
  10. package/assets/browser-ponyfill-CqiVi-O8.js +1 -0
  11. package/assets/{ccip-CrAifiNa.js → ccip-BvTmJITs.js} +1 -1
  12. package/assets/{ccip-Bldffu31.js → ccip-ByLIoOC6.js} +1 -1
  13. package/assets/{chains-DTVDhUwv.js → chains-icJ3HR5v.js} +1 -1
  14. package/assets/{common-BEf2T7Hi.js → common-DMnogLd5.js} +1 -1
  15. package/assets/{controller-B8Iy-6V9.js → controller-BXwg_bJl.js} +2 -2
  16. package/assets/{core-XFvzSI58.js → core-DOL3gnfb.js} +4 -4
  17. package/assets/{custom-cPmISGcH.js → custom-CZYipZz1.js} +1 -1
  18. package/assets/{data-capture-DnvAEYWK.js → data-capture-CRDSEIY_.js} +1 -1
  19. package/assets/{decimals-8g2-fBFa.js → decimals-DNQm_OiO.js} +1 -1
  20. package/assets/decimals-DnutWGXb.js +1 -0
  21. package/assets/{detectExtension-yvI5WWZb.js → detectExtension-BfmE7TOs.js} +1 -1
  22. package/assets/{email-C8DRQjTT.js → email-CvS0g63O.js} +1 -1
  23. package/assets/{embedded-wallet-BxgtT1uV.js → embedded-wallet-BH2dkm4W.js} +1 -1
  24. package/assets/{engine-BERe87yT.js → engine-Di9rAbBn.js} +1 -1
  25. package/assets/{estimate-l1-fee-BTeKvFv5.js → estimate-l1-fee-D5Yk5K_j.js} +1 -1
  26. package/assets/eth_estimateGas-BmOR31h-.js +1 -0
  27. package/assets/{eth_getStorageAt-SbVMAQY-.js → eth_getStorageAt-7xIaoYHZ.js} +1 -1
  28. package/assets/{eth_getTransactionCount-qv0oO1Md.js → eth_getTransactionCount-DrnF23O4.js} +1 -1
  29. package/assets/{ethereum-BP59xYBe.js → ethereum-2kM2S7dx.js} +1 -1
  30. package/assets/{extractIPFS-BOFlZk7U.js → extractIPFS-C9Vdpa9n.js} +1 -1
  31. package/assets/{features-DVWd8_kC.js → features-DRiKivpi.js} +1 -1
  32. package/assets/{fetchTokenMetadata-BaJXN6RH.js → fetchTokenMetadata-DZl1qOjc.js} +2 -2
  33. package/assets/{fortmatic-DARkeYTE.js → fortmatic-6-9Hxtzg.js} +1 -1
  34. package/assets/get-ecosystem-wallet-info-DQQrfAsE.js +1 -0
  35. package/assets/{getBalance-D6wpo61w.js → getBalance-BfwFhtAu.js} +2 -2
  36. package/assets/{getInstalledModules-Dkj379ys.js → getInstalledModules-Dlcyw_6V.js} +1 -1
  37. package/assets/{getNFT-HMkoXD7L.js → getNFT-CkUzlgLt.js} +2 -2
  38. package/assets/{getNFT-Drn4rxrk.js → getNFT-DIu1VS3y.js} +1 -1
  39. package/assets/{hashTypedData-B5shS-rs.js → hashTypedData-CM_9VEoH.js} +1 -1
  40. package/assets/{hashTypedData-CMDSWYgs.js → hashTypedData-DrZol7nF.js} +1 -1
  41. package/assets/{in-app-wallet-calls-l9-2W_Em.js → in-app-wallet-calls-BABhagi9.js} +1 -1
  42. package/assets/{index-CH0zI801.js → index--SuwY_Sr.js} +1 -1
  43. package/assets/{index-B9U0GcYk.js → index-3gZjXx6v.js} +1 -1
  44. package/assets/{index-BXAxcybX.js → index-3jhEomSV.js} +1 -1
  45. package/assets/{index-D0LvjNIX.js → index-8eDD30Uv.js} +1 -1
  46. package/assets/{index-DfWsAOhN.js → index-B26CWJm4.js} +3 -3
  47. package/assets/{index-8M7OkBFm.js → index-B3Bk-Bdi.js} +1 -1
  48. package/assets/{index-DPxCDCvr.js → index-B7_b_SxX.js} +1 -1
  49. package/assets/{index-DK-ZMNLh.js → index-BI0nsxQ1.js} +1 -1
  50. package/assets/{index-BKL7nv1p.js → index-BPxeLdJF.js} +1 -1
  51. package/assets/{index-CWnFK_-0.js → index-BQJscq8u.js} +1 -1
  52. package/assets/{index-B5ECjSS9.js → index-BSmpP1mK.js} +1 -1
  53. package/assets/{index-JfVynEph.js → index-BUjSLaXy.js} +1 -1
  54. package/assets/{index-aoxVkzFE.js → index-BVL3WVs3.js} +1 -1
  55. package/assets/{index-829Uxa3Y.css → index-BXaGpRRD.css} +1 -1
  56. package/assets/{index-TBthDmkl.js → index-BYwd36WC.js} +1 -1
  57. package/assets/{index-0ShVRzxt.js → index-BlANYCHN.js} +1 -1
  58. package/assets/{index-BaGjqMte.js → index-BxZwJKty.js} +2 -2
  59. package/assets/{index-DOnRCLNP.js → index-C68kxEIB.js} +2 -2
  60. package/assets/{index-okvlQSs2.js → index-CEE50lK9.js} +1 -1
  61. package/assets/{index-BxdNwV86.js → index-CFn3Q12F.js} +1 -1
  62. package/assets/{index-DP1DuCnR.js → index-CNR7tadx.js} +1 -1
  63. package/assets/{index-CWGeCZBJ.js → index-CNttLYqM.js} +1 -1
  64. package/assets/{index-B-vyBZw9.js → index-CPCCdjXg.js} +1 -1
  65. package/assets/{index-C8NSq3HK.js → index-CQx7Nvt8.js} +1 -1
  66. package/assets/{index-I68folnJ.js → index-CUqVNGI9.js} +1 -1
  67. package/assets/{index-wds8TuUm.js → index-CYGUludi.js} +1 -1
  68. package/assets/{index-DS2Lm9tG.js → index-CcHsPndE.js} +1 -1
  69. package/assets/{index-DFE6t65x.js → index-CdCaVlZ8.js} +1 -1
  70. package/assets/{index-r_1z0VI_.js → index-CpGStcFm.js} +1 -1
  71. package/assets/{index-i4VBSYqA.js → index-CzGhZ9cz.js} +1 -1
  72. package/assets/{index-kXKMGszW.js → index-D2eOGoyM.js} +1 -1
  73. package/assets/{index-DIlwNfpB.js → index-D4_P_6_0.js} +1 -1
  74. package/assets/{index-D2ZBQG8w.js → index-D4h65XPa.js} +1 -1
  75. package/assets/{index-CE5G6IEJ.js → index-D6EwKnFm.js} +1 -1
  76. package/assets/{index-BDgZ3gDE.js → index-DD7htze-.js} +1 -1
  77. package/assets/{index-CjiwjbqL.js → index-DErCc5s3.js} +1 -1
  78. package/assets/{index-DvJmANzU.js → index-DIZhmTRA.js} +1 -1
  79. package/assets/{index-Cp7mdTuR.js → index-DNf75mcI.js} +1 -1
  80. package/assets/{index-BIPd_vR5.js → index-DVWnrfKr.js} +1 -1
  81. package/assets/{index-C5ciuua_.js → index-DcSeumRb.js} +1 -1
  82. package/assets/{index-DWRq2SN_.js → index-Dh25pQLC.js} +1 -1
  83. package/assets/{index-mZa0UiRt.js → index-DhJ5PMMP.js} +1 -1
  84. package/assets/{index-C51HwlD0.js → index-DvBfOXXL.js} +1 -1
  85. package/assets/{index-C-uqursN.js → index-ZSDK0Ila.js} +1 -1
  86. package/assets/{index-Cu4ZjLNb.js → index-a-a2MqTK.js} +5 -5
  87. package/assets/{index-B7Jt3b4d.js → index-jd0SXoNg.js} +1 -1
  88. package/assets/{index-BlykZ8Gp.js → index-kYi3llt9.js} +1 -1
  89. package/assets/{index-DbAu4Peg.js → index-mUrlue57.js} +3 -3
  90. package/assets/{index-Cy1X3n_C.js → index-vqWCp_18.js} +1 -1
  91. package/assets/{index.es-cEGj7JU0.js → index.es-B6W15sA5.js} +4 -4
  92. package/assets/{index.es-YpI01v2I.js → index.es-BpysnXQX.js} +1 -1
  93. package/assets/{index.es-CkxUaFYS.js → index.es-CjcoN6we.js} +1 -1
  94. package/assets/{localBatchGatewayRequest-CNIOIq-Z.js → localBatchGatewayRequest-BH_HSMtg.js} +1 -1
  95. package/assets/{networks-DJ72puSk.js → networks-xuo_6MCS.js} +1 -1
  96. package/assets/{onramp--l5ZLxWE.js → onramp-CYabKBjQ.js} +1 -1
  97. package/assets/{openzeppelin-CqtRqxtF.js → openzeppelin-ChIJtXh7.js} +1 -1
  98. package/assets/{ownerOf-cWkgEtd8.js → ownerOf-CpA7K1ak.js} +1 -1
  99. package/assets/{parseEventLogs-D1xiFnCH.js → parseEventLogs-DTRl5YJ_.js} +3 -3
  100. package/assets/{parseNft-DH5KlHPI.js → parseNft-BmgScKdM.js} +2 -2
  101. package/assets/{parseSignature-BYhcrVdX.js → parseSignature-On3IHrnn.js} +1 -1
  102. package/assets/{parseSignature-HAlgOHnm.js → parseSignature-XxRbPHFh.js} +3 -3
  103. package/assets/{pay-with-exchange-CiXPJJ6-.js → pay-with-exchange-DehF3o8r.js} +1 -1
  104. package/assets/{qr-overlay-CmFgwJBd.js → qr-overlay-BEl3x4xw.js} +3 -3
  105. package/assets/{receive-t2TxUItI.js → receive-C_KTgg4c.js} +1 -1
  106. package/assets/{resolveImplementation-iG9WRRnW.js → resolveImplementation-LbazawSf.js} +1 -1
  107. package/assets/{rpc-sIdV4wiJ.js → rpc-BVFdxD_n.js} +1 -1
  108. package/assets/{secp256k1-Co_Jve4c.js → secp256k1-6WLSeO2i.js} +1 -1
  109. package/assets/{secp256k1-Rk5k9i7o.js → secp256k1-CUFDPHqP.js} +1 -1
  110. package/assets/{secp256k1-Bg2aUJRs.js → secp256k1-DjijwK4n.js} +1 -1
  111. package/assets/{send-ByB5fOtm.js → send-BvXhUAZg.js} +1 -1
  112. package/assets/{send-batch-transaction-D79MC_wr.js → send-batch-transaction-PvOdFKh_.js} +1 -1
  113. package/assets/{send-eip712-transaction-CB6qLgks.js → send-eip712-transaction-DW2Z39R_.js} +2 -2
  114. package/assets/{send-gasless-transaction-Dt1qtUR8.js → send-gasless-transaction-DZNXePZn.js} +2 -2
  115. package/assets/{session-proposal-CY0k9Jnm.js → session-proposal-BDKOEjOS.js} +1 -1
  116. package/assets/{session-request-B_2glC9e.js → session-request-C6gEdmiF.js} +2 -2
  117. package/assets/{sha256-Dy8KQE_5.js → sha256-DOODwtIM.js} +1 -1
  118. package/assets/{signing-gNn6SJWz.js → signing-lyeTiv6v.js} +5 -5
  119. package/assets/{socials-Dx84-PrV.js → socials-J163g-WS.js} +1 -1
  120. package/assets/{swaps-CK9Sfcew.js → swaps-DhRGH4D_.js} +1 -1
  121. package/assets/{thirdweb-Bx5V_C1s.js → thirdweb-Dqspr20y.js} +3 -3
  122. package/assets/{totalSupply-O-VFDoRO.js → totalSupply-C4K7aOAr.js} +1 -1
  123. package/assets/{transactionReceipt-BqEjx5q-.js → transactionReceipt-DIRSM0gr.js} +1 -1
  124. package/assets/{transactions-BLOC2qYE.js → transactions-CIkqFxc1.js} +1 -1
  125. package/assets/{utils-h8VUSGPW.js → utils-Cj9H0gW-.js} +1 -1
  126. package/assets/{verifyHash-CNJ6t8Wp.js → verifyHash-CoWeO2NB.js} +1 -1
  127. package/assets/{w3m-modal-CCQuGDus.js → w3m-modal-BkrZujFe.js} +1 -1
  128. package/assets/{w3m-modal-nzPxg0Fr.js → w3m-modal-Cam7s-1S.js} +1 -1
  129. package/assets/{wait-for-tx-receipt-5pSBMNe2.js → wait-for-tx-receipt-CN6uf72q.js} +1 -1
  130. package/assets/{wallets-Bz03-Btm.js → wallets-HiUhftO5.js} +6 -6
  131. package/assets/{web-connector-CAOe_uvv.js → web-connector-Dq2kV8N4.js} +3 -3
  132. package/assets/{writeContract-CCar3Ocq.js → writeContract-jh5z7q6H.js} +1 -1
  133. package/assets/{zora-sepolia-D6mjhB5j.js → zora-sepolia-CS_uSNQg.js} +1 -1
  134. package/assets/{zoraTestnet-WLSFziQl.js → zoraTestnet-CvoUlJGq.js} +1 -1
  135. package/index.html +4 -4
  136. package/package.json +3 -3
  137. package/assets/browser-ponyfill-BmgQyNz0.js +0 -1
  138. package/assets/decimals-DR6jraOc.js +0 -1
  139. package/assets/eth_estimateGas-DKKwG-Ue.js +0 -1
  140. package/assets/get-ecosystem-wallet-info-Cvjz8DFX.js +0 -1
@@ -1,5 +1,5 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/secp256k1-Bg2aUJRs.js","assets/sha2-D3ryOfi3.js","assets/hmac-BMnSt9Ou.js","assets/ccip-Bldffu31.js","assets/NetworkUtil-DqGcuBfF.js","assets/index-Cu4ZjLNb.js","assets/index-829Uxa3Y.css","assets/localBatchGatewayRequest-CNIOIq-Z.js","assets/sha256-D33fGSQc.js"])))=>i.map(i=>d[i]);
2
- import{a9 as J,_ as M,ae as P,B as l,a8 as X,a3 as Qn,a1 as e0,a2 as j,ab as re,am as Pe,an as me,ai as F,av as t0,ar as Je,aj as n0,v as Zt,aE as ve,ao as Xe,h as r0,a6 as ge,ah as Y,Z as s0,d as i0,ak as o0,al as a0,aF as c0,E as ye,F as Ue,c as gt,n as wt,o as xt,N as Pt,I as vt,f as $t,g as Et,z as At,x as _e,K as $e,aG as Bt,aD as f0,ac as It,e as u0,j as d0,t as l0}from"./NetworkUtil-DqGcuBfF.js";import{_ as qt}from"./index-Cu4ZjLNb.js";import{s as b0}from"./sha256-D33fGSQc.js";function Ee(e,t){return({exclude:n,format:r})=>({exclude:n,format:(s,i)=>{const o=t(s,i);if(n)for(const a of n)delete o[a];return{...o,...r(s,i)}},type:e})}const Yt={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844","0x4":"eip7702"};function Qe(e,t){const n={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,...e.blockTimestamp!=null&&{blockTimestamp:BigInt(e.blockTimestamp)},chainId:e.chainId?J(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerBlobGas:e.maxFeePerBlobGas?BigInt(e.maxFeePerBlobGas):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?J(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?Yt[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 e.authorizationList&&(n.authorizationList=p0(e.authorizationList)),n.yParity=(()=>{if(e.yParity)return Number(e.yParity);if(typeof n.v=="bigint"){if(n.v===0n||n.v===27n)return 0;if(n.v===1n||n.v===28n)return 1;if(n.v>=35n)return n.v%2n===0n?1:0}})(),n.type==="legacy"&&(delete n.accessList,delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas,delete n.yParity),n.type==="eip2930"&&(delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas),n.type==="eip1559"&&delete n.maxFeePerBlobGas,n}const Ni=Ee("transaction",Qe);function p0(e){return e.map(t=>({address:t.address,chainId:Number(t.chainId),nonce:Number(t.nonce),r:t.r,s:t.s,yParity:Number(t.yParity)}))}function Jt(e,t){const n=(e.transactions??[]).map(r=>typeof r=="string"?r:Qe(r));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,blobGasUsed:e.blobGasUsed?BigInt(e.blobGasUsed):void 0,difficulty:e.difficulty?BigInt(e.difficulty):void 0,excessBlobGas:e.excessBlobGas?BigInt(e.excessBlobGas):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:n,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}const Ri=Ee("block",Jt);function Xt(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,blockTimestamp:e.blockTimestamp?BigInt(e.blockTimestamp):e.blockTimestamp===null?null:void 0,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}:{}}}const y0={"0x0":"reverted","0x1":"success"};function h0(e,t){const n={...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(r=>Xt(r)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?J(e.transactionIndex):null,status:e.status?y0[e.status]:null,type:e.type?Yt[e.type]||e.type:null};return e.blobGasPrice&&(n.blobGasPrice=BigInt(e.blobGasPrice)),e.blobGasUsed&&(n.blobGasUsed=BigInt(e.blobGasUsed)),n}const Li=Ee("transactionReceipt",h0),m0={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3",eip7702:"0x4"};function Ae(e,t){const n={};return typeof e.authorizationList<"u"&&(n.authorizationList=g0(e.authorizationList)),typeof e.accessList<"u"&&(n.accessList=e.accessList),typeof e.blobVersionedHashes<"u"&&(n.blobVersionedHashes=e.blobVersionedHashes),typeof e.blobs<"u"&&(typeof e.blobs[0]!="string"?n.blobs=e.blobs.map(r=>M(r)):n.blobs=e.blobs),typeof e.data<"u"&&(n.data=e.data),e.account&&(n.from=e.account.address),typeof e.from<"u"&&(n.from=e.from),typeof e.gas<"u"&&(n.gas=P(e.gas)),typeof e.gasPrice<"u"&&(n.gasPrice=P(e.gasPrice)),typeof e.maxFeePerBlobGas<"u"&&(n.maxFeePerBlobGas=P(e.maxFeePerBlobGas)),typeof e.maxFeePerGas<"u"&&(n.maxFeePerGas=P(e.maxFeePerGas)),typeof e.maxPriorityFeePerGas<"u"&&(n.maxPriorityFeePerGas=P(e.maxPriorityFeePerGas)),typeof e.nonce<"u"&&(n.nonce=P(e.nonce)),typeof e.to<"u"&&(n.to=e.to),typeof e.type<"u"&&(n.type=m0[e.type]),typeof e.value<"u"&&(n.value=P(e.value)),n}const Ui=Ee("transactionRequest",Ae);function g0(e){return e.map(t=>({address:t.address,r:t.r?P(BigInt(t.r)):t.r,s:t.s?P(BigInt(t.s)):t.s,chainId:P(t.chainId),nonce:P(t.nonce),...typeof t.yParity<"u"?{yParity:P(t.yParity)}:{},...typeof t.v<"u"&&typeof t.yParity>"u"?{v:P(t.v)}:{}}))}const _i=2n**16n-1n,w0=2n**256n-1n;function se(e){return typeof e[0]=="string"?Be(e):x0(e)}function x0(e){let t=0;for(const s of e)t+=s.length;const n=new Uint8Array(t);let r=0;for(const s of e)n.set(s,r),r+=s.length;return n}function Be(e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}class Ft extends l{constructor({offset:t}){super(`Offset \`${t}\` cannot be negative.`,{name:"NegativeOffsetError"})}}class Qt extends l{constructor({length:t,position:n}){super(`Position \`${n}\` is out of bounds (\`0 < position < ${t}\`).`,{name:"PositionOutOfBoundsError"})}}class P0 extends l{constructor({count:t,limit:n}){super(`Recursive read limit of \`${n}\` exceeded (recursive read count: \`${t}\`).`,{name:"RecursiveReadLimitExceededError"})}}const v0={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:Number.POSITIVE_INFINITY,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new P0({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new Qt({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new Ft({offset:e});const t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new Ft({offset:e});const t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){const n=t??this.position;return this.assertPosition(n+e-1),this.bytes.subarray(n,n+e)},inspectUint8(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){const t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){const t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){const 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,e&255),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();const e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();const n=this.inspectBytes(e);return this.position+=t??e,n},readUint8(){this.assertReadLimit(),this._touch();const e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();const e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();const e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();const e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){const t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===Number.POSITIVE_INFINITY)return;const e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}};function et(e,{recursiveReadLimit:t=8192}={}){const n=Object.create(v0);return n.bytes=e,n.dataView=new DataView(e.buffer??e,e.byteOffset,e.byteLength),n.positionReadCount=new Map,n.recursiveReadLimit=t,n}function $0(e,t="hex"){const n=en(e),r=et(new Uint8Array(n.length));return n.encode(r),t==="hex"?M(r.bytes):r.bytes}function en(e){return Array.isArray(e)?E0(e.map(t=>en(t))):A0(e)}function E0(e){const t=e.reduce((s,i)=>s+i.length,0),n=tn(t);return{length:t<=55?1+t:1+n+t,encode(s){t<=55?s.pushByte(192+t):(s.pushByte(247+n),n===1?s.pushUint8(t):n===2?s.pushUint16(t):n===3?s.pushUint24(t):s.pushUint32(t));for(const{encode:i}of e)i(s)}}}function A0(e){const t=typeof e=="string"?X(e):e,n=tn(t.length);return{length:t.length===1&&t[0]<128?1:t.length<=55?1+t.length:1+n+t.length,encode(s){t.length===1&&t[0]<128?s.pushBytes(t):t.length<=55?(s.pushByte(128+t.length),s.pushBytes(t)):(s.pushByte(183+n),n===1?s.pushUint8(t.length):n===2?s.pushUint16(t.length):n===3?s.pushUint24(t.length):s.pushUint32(t.length),s.pushBytes(t))}}}function tn(e){if(e<2**8)return 1;if(e<2**16)return 2;if(e<2**24)return 3;if(e<2**32)return 4;throw new l("Length is too large.")}function tt(e,t="wei"){return Qn(e,e0[t])}function le(e){const t=Object.entries(e).map(([r,s])=>s===void 0||s===!1?null:[r,s]).filter(Boolean),n=t.reduce((r,[s])=>Math.max(r,s.length),0);return t.map(([r,s])=>` ${`${r}:`.padEnd(n+1)} ${s}`).join(`
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/secp256k1-DjijwK4n.js","assets/sha2-D3ryOfi3.js","assets/hmac-BMnSt9Ou.js","assets/ccip-ByLIoOC6.js","assets/NetworkUtil-XsBaDkTf.js","assets/index-a-a2MqTK.js","assets/index-BXaGpRRD.css","assets/localBatchGatewayRequest-BH_HSMtg.js","assets/sha256-D33fGSQc.js"])))=>i.map(i=>d[i]);
2
+ import{a9 as J,_ as M,ae as P,B as l,a8 as X,a3 as Qn,a1 as e0,a2 as j,ab as re,am as Pe,an as me,ai as F,av as t0,ar as Je,aj as n0,v as Zt,aE as ve,ao as Xe,h as r0,a6 as ge,ah as Y,Z as s0,d as i0,ak as o0,al as a0,aF as c0,E as ye,F as Ue,c as gt,n as wt,o as xt,N as Pt,I as vt,f as $t,g as Et,z as At,x as _e,K as $e,aG as Bt,aD as f0,ac as It,e as u0,j as d0,t as l0}from"./NetworkUtil-XsBaDkTf.js";import{_ as qt}from"./index-a-a2MqTK.js";import{s as b0}from"./sha256-D33fGSQc.js";function Ee(e,t){return({exclude:n,format:r})=>({exclude:n,format:(s,i)=>{const o=t(s,i);if(n)for(const a of n)delete o[a];return{...o,...r(s,i)}},type:e})}const Yt={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844","0x4":"eip7702"};function Qe(e,t){const n={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,...e.blockTimestamp!=null&&{blockTimestamp:BigInt(e.blockTimestamp)},chainId:e.chainId?J(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerBlobGas:e.maxFeePerBlobGas?BigInt(e.maxFeePerBlobGas):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?J(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?Yt[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 e.authorizationList&&(n.authorizationList=p0(e.authorizationList)),n.yParity=(()=>{if(e.yParity)return Number(e.yParity);if(typeof n.v=="bigint"){if(n.v===0n||n.v===27n)return 0;if(n.v===1n||n.v===28n)return 1;if(n.v>=35n)return n.v%2n===0n?1:0}})(),n.type==="legacy"&&(delete n.accessList,delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas,delete n.yParity),n.type==="eip2930"&&(delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas),n.type==="eip1559"&&delete n.maxFeePerBlobGas,n}const Ni=Ee("transaction",Qe);function p0(e){return e.map(t=>({address:t.address,chainId:Number(t.chainId),nonce:Number(t.nonce),r:t.r,s:t.s,yParity:Number(t.yParity)}))}function Jt(e,t){const n=(e.transactions??[]).map(r=>typeof r=="string"?r:Qe(r));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,blobGasUsed:e.blobGasUsed?BigInt(e.blobGasUsed):void 0,difficulty:e.difficulty?BigInt(e.difficulty):void 0,excessBlobGas:e.excessBlobGas?BigInt(e.excessBlobGas):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:n,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}const Ri=Ee("block",Jt);function Xt(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,blockTimestamp:e.blockTimestamp?BigInt(e.blockTimestamp):e.blockTimestamp===null?null:void 0,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}:{}}}const y0={"0x0":"reverted","0x1":"success"};function h0(e,t){const n={...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(r=>Xt(r)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?J(e.transactionIndex):null,status:e.status?y0[e.status]:null,type:e.type?Yt[e.type]||e.type:null};return e.blobGasPrice&&(n.blobGasPrice=BigInt(e.blobGasPrice)),e.blobGasUsed&&(n.blobGasUsed=BigInt(e.blobGasUsed)),n}const Li=Ee("transactionReceipt",h0),m0={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3",eip7702:"0x4"};function Ae(e,t){const n={};return typeof e.authorizationList<"u"&&(n.authorizationList=g0(e.authorizationList)),typeof e.accessList<"u"&&(n.accessList=e.accessList),typeof e.blobVersionedHashes<"u"&&(n.blobVersionedHashes=e.blobVersionedHashes),typeof e.blobs<"u"&&(typeof e.blobs[0]!="string"?n.blobs=e.blobs.map(r=>M(r)):n.blobs=e.blobs),typeof e.data<"u"&&(n.data=e.data),e.account&&(n.from=e.account.address),typeof e.from<"u"&&(n.from=e.from),typeof e.gas<"u"&&(n.gas=P(e.gas)),typeof e.gasPrice<"u"&&(n.gasPrice=P(e.gasPrice)),typeof e.maxFeePerBlobGas<"u"&&(n.maxFeePerBlobGas=P(e.maxFeePerBlobGas)),typeof e.maxFeePerGas<"u"&&(n.maxFeePerGas=P(e.maxFeePerGas)),typeof e.maxPriorityFeePerGas<"u"&&(n.maxPriorityFeePerGas=P(e.maxPriorityFeePerGas)),typeof e.nonce<"u"&&(n.nonce=P(e.nonce)),typeof e.to<"u"&&(n.to=e.to),typeof e.type<"u"&&(n.type=m0[e.type]),typeof e.value<"u"&&(n.value=P(e.value)),n}const Ui=Ee("transactionRequest",Ae);function g0(e){return e.map(t=>({address:t.address,r:t.r?P(BigInt(t.r)):t.r,s:t.s?P(BigInt(t.s)):t.s,chainId:P(t.chainId),nonce:P(t.nonce),...typeof t.yParity<"u"?{yParity:P(t.yParity)}:{},...typeof t.v<"u"&&typeof t.yParity>"u"?{v:P(t.v)}:{}}))}const _i=2n**16n-1n,w0=2n**256n-1n;function se(e){return typeof e[0]=="string"?Be(e):x0(e)}function x0(e){let t=0;for(const s of e)t+=s.length;const n=new Uint8Array(t);let r=0;for(const s of e)n.set(s,r),r+=s.length;return n}function Be(e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}class Ft extends l{constructor({offset:t}){super(`Offset \`${t}\` cannot be negative.`,{name:"NegativeOffsetError"})}}class Qt extends l{constructor({length:t,position:n}){super(`Position \`${n}\` is out of bounds (\`0 < position < ${t}\`).`,{name:"PositionOutOfBoundsError"})}}class P0 extends l{constructor({count:t,limit:n}){super(`Recursive read limit of \`${n}\` exceeded (recursive read count: \`${t}\`).`,{name:"RecursiveReadLimitExceededError"})}}const v0={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:Number.POSITIVE_INFINITY,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new P0({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new Qt({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new Ft({offset:e});const t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new Ft({offset:e});const t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){const n=t??this.position;return this.assertPosition(n+e-1),this.bytes.subarray(n,n+e)},inspectUint8(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){const t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){const t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){const 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,e&255),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();const e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();const n=this.inspectBytes(e);return this.position+=t??e,n},readUint8(){this.assertReadLimit(),this._touch();const e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();const e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();const e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();const e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){const t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===Number.POSITIVE_INFINITY)return;const e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}};function et(e,{recursiveReadLimit:t=8192}={}){const n=Object.create(v0);return n.bytes=e,n.dataView=new DataView(e.buffer??e,e.byteOffset,e.byteLength),n.positionReadCount=new Map,n.recursiveReadLimit=t,n}function $0(e,t="hex"){const n=en(e),r=et(new Uint8Array(n.length));return n.encode(r),t==="hex"?M(r.bytes):r.bytes}function en(e){return Array.isArray(e)?E0(e.map(t=>en(t))):A0(e)}function E0(e){const t=e.reduce((s,i)=>s+i.length,0),n=tn(t);return{length:t<=55?1+t:1+n+t,encode(s){t<=55?s.pushByte(192+t):(s.pushByte(247+n),n===1?s.pushUint8(t):n===2?s.pushUint16(t):n===3?s.pushUint24(t):s.pushUint32(t));for(const{encode:i}of e)i(s)}}}function A0(e){const t=typeof e=="string"?X(e):e,n=tn(t.length);return{length:t.length===1&&t[0]<128?1:t.length<=55?1+t.length:1+n+t.length,encode(s){t.length===1&&t[0]<128?s.pushBytes(t):t.length<=55?(s.pushByte(128+t.length),s.pushBytes(t)):(s.pushByte(183+n),n===1?s.pushUint8(t.length):n===2?s.pushUint16(t.length):n===3?s.pushUint24(t.length):s.pushUint32(t.length),s.pushBytes(t))}}}function tn(e){if(e<2**8)return 1;if(e<2**16)return 2;if(e<2**24)return 3;if(e<2**32)return 4;throw new l("Length is too large.")}function tt(e,t="wei"){return Qn(e,e0[t])}function le(e){const t=Object.entries(e).map(([r,s])=>s===void 0||s===!1?null:[r,s]).filter(Boolean),n=t.reduce((r,[s])=>Math.max(r,s.length),0);return t.map(([r,s])=>` ${`${r}:`.padEnd(n+1)} ${s}`).join(`
3
3
  `)}class Di extends l{constructor({v:t}){super(`Invalid \`v\` value "${t}". Expected 27 or 28.`,{name:"InvalidLegacyVError"})}}class B0 extends l{constructor({transaction:t}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",le(t),"}","","To infer the type, either provide:","- a `type` to the Transaction, or","- an EIP-1559 Transaction with `maxFeePerGas`, or","- an EIP-2930 Transaction with `gasPrice` & `accessList`, or","- an EIP-4844 Transaction with `blobs`, `blobVersionedHashes`, `sidecars`, or","- an EIP-7702 Transaction with `authorizationList`, or","- a Legacy Transaction with `gasPrice`"],name:"InvalidSerializableTransactionError"})}}class Hi extends l{constructor({storageKey:t}){super(`Size for storage key "${t}" is invalid. Expected 32 bytes. Got ${Math.floor((t.length-2)/2)} bytes.`,{name:"InvalidStorageKeySizeError"})}}class I0 extends l{constructor(t,{account:n,docsPath:r,chain:s,data:i,gas:o,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:f,nonce:u,to:d,value:b}){const p=le({chain:s&&`${s?.name} (id: ${s?.id})`,from:n?.address,to:d,value:typeof b<"u"&&`${tt(b)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:i,gas:o,gasPrice:typeof a<"u"&&`${j(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${j(c)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${j(f)} gwei`,nonce:u});super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Request Arguments:",p].filter(Boolean),name:"TransactionExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class Vi extends l{constructor({blockHash:t,blockNumber:n,blockTag:r,hash:s,index:i}){let o="Transaction";r&&i!==void 0&&(o=`Transaction at block time "${r}" at index "${i}"`),t&&i!==void 0&&(o=`Transaction at block hash "${t}" at index "${i}"`),n&&i!==void 0&&(o=`Transaction at block number "${n}" at index "${i}"`),s&&(o=`Transaction with hash "${s}"`),super(`${o} could not be found.`,{name:"TransactionNotFoundError"})}}class Ki extends l{constructor({hash:t}){super(`Transaction receipt with hash "${t}" could not be found. The Transaction may not be processed on a block yet.`,{name:"TransactionReceiptNotFoundError"})}}class Wi extends l{constructor({receipt:t}){super(`Transaction with hash "${t.transactionHash}" reverted.`,{metaMessages:['The receipt marked the transaction as "reverted". This could mean that the function on the contract you are trying to call threw an error.'," ","You can attempt to extract the revert reason by:","- calling the `simulateContract` or `simulateCalls` Action with the `abi` and `functionName` of the contract","- using the `call` Action with raw `data`"],name:"TransactionReceiptRevertedError"}),Object.defineProperty(this,"receipt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.receipt=t}}class Zi extends l{constructor({hash:t}){super(`Timed out while waiting for transaction with hash "${t}" to be confirmed.`,{name:"WaitForTransactionReceiptTimeoutError"})}}function nn(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),r=typeof e.blobs[0]=="string"?e.blobs.map(i=>X(i)):e.blobs,s=[];for(const i of r)s.push(Uint8Array.from(t.blobToKzgCommitment(i)));return n==="bytes"?s:s.map(i=>M(i))}function rn(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),r=typeof e.blobs[0]=="string"?e.blobs.map(o=>X(o)):e.blobs,s=typeof e.commitments[0]=="string"?e.commitments.map(o=>X(o)):e.commitments,i=[];for(let o=0;o<r.length;o++){const a=r[o],c=s[o];i.push(Uint8Array.from(t.computeBlobKzgProof(a,c)))}return n==="bytes"?i:i.map(o=>M(o))}function F0(e,t){const n=t||"hex",r=b0(re(e,{strict:!1})?Pe(e):e);return n==="bytes"?r:me(r)}function T0(e){const{commitment:t,version:n=1}=e,r=e.to??(typeof t=="string"?"hex":"bytes"),s=F0(t,"bytes");return s.set([n],0),r==="bytes"?s:M(s)}function S0(e){const{commitments:t,version:n}=e,r=e.to??(typeof t[0]=="string"?"hex":"bytes"),s=[];for(const i of t)s.push(T0({commitment:i,to:r,version:n}));return s}const Tt=6,sn=32,nt=4096,on=sn*nt,St=on*Tt-1-1*nt*Tt,z0=1;class k0 extends l{constructor({maxSize:t,size:n}){super("Blob size is too large.",{metaMessages:[`Max: ${t} bytes`,`Given: ${n} bytes`],name:"BlobSizeTooLargeError"})}}class M0 extends l{constructor(){super("Blob data must not be empty.",{name:"EmptyBlobError"})}}class qi extends l{constructor({hash:t,size:n}){super(`Versioned hash "${t}" size is invalid.`,{metaMessages:["Expected: 32",`Received: ${n}`],name:"InvalidVersionedHashSizeError"})}}class Yi extends l{constructor({hash:t,version:n}){super(`Versioned hash "${t}" version is invalid.`,{metaMessages:[`Expected: ${z0}`,`Received: ${n}`],name:"InvalidVersionedHashVersionError"})}}function G0(e){const t=e.to??(typeof e.data=="string"?"hex":"bytes"),n=typeof e.data=="string"?X(e.data):e.data,r=F(n);if(!r)throw new M0;if(r>St)throw new k0({maxSize:St,size:r});const s=[];let i=!0,o=0;for(;i;){const a=et(new Uint8Array(on));let c=0;for(;c<nt;){const f=n.slice(o,o+(sn-1));if(a.pushByte(0),a.pushBytes(f),f.length<31){a.pushByte(128),i=!1;break}c++,o+=31}s.push(a)}return t==="bytes"?s.map(a=>a.bytes):s.map(a=>M(a.bytes))}function C0(e){const{data:t,kzg:n,to:r}=e,s=e.blobs??G0({data:t,to:r}),i=e.commitments??nn({blobs:s,kzg:n,to:r}),o=e.proofs??rn({blobs:s,commitments:i,kzg:n,to:r}),a=[];for(let c=0;c<s.length;c++)a.push({blob:s[c],commitment:i[c],proof:o[c]});return a}class Q extends l{constructor({address:t}){super(`Address "${t}" is invalid.`,{metaMessages:["- Address must be a hex value of 20 bytes (40 hex characters).","- Address must match its checksum counterpart."],name:"InvalidAddressError"})}}class De extends l{constructor({blockNumber:t,chain:n,contract:r}){super(`Chain "${n.name}" does not support contract "${r.name}".`,{metaMessages:["This could be due to any of the following:",...t&&r.blockCreated&&r.blockCreated>t?[`- The contract "${r.name}" was not deployed until block ${r.blockCreated} (current block ${t}).`]:[`- The chain does not have the contract "${r.name}" configured.`]],name:"ChainDoesNotSupportContract"})}}class O0 extends l{constructor({chain:t,currentChainId:n}){super(`The current chain of the wallet (id: ${n}) does not match the target chain for the transaction (id: ${t.id} – ${t.name}).`,{metaMessages:[`Current Chain ID: ${n}`,`Expected Chain ID: ${t.id} – ${t.name}`],name:"ChainMismatchError"})}}class j0 extends l{constructor(){super(["No chain was provided to the request.","Please provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."].join(`
4
4
  `),{name:"ChainNotFoundError"})}}class an extends l{constructor(){super("No chain was provided to the Client.",{name:"ClientChainNotConfiguredError"})}}class Ji extends l{constructor({chainId:t}){super(typeof t=="number"?`Chain ID "${t}" is invalid.`:"Chain ID is invalid.",{name:"InvalidChainIdError"})}}function be(e,t){const n=t||"hex",r=t0(re(e,{strict:!1})?Pe(e):e);return n==="bytes"?r:me(r)}const Me=new Je(8192);function Ie(e,t){if(Me.has(`${e}.${t}`))return Me.get(`${e}.${t}`);const n=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),r=be(n0(n),"bytes"),s=(t?n.substring(`${t}0x`.length):n).split("");for(let o=0;o<40;o+=2)r[o>>1]>>4>=8&&s[o]&&(s[o]=s[o].toUpperCase()),(r[o>>1]&15)>=8&&s[o+1]&&(s[o+1]=s[o+1].toUpperCase());const i=`0x${s.join("")}`;return Me.set(`${e}.${t}`,i),i}function Xi(e,t){if(!N(e,{strict:!1}))throw new Q({address:e});return Ie(e,t)}const N0=/^0x[a-fA-F0-9]{40}$/,Ge=new Je(8192);function N(e,t){const{strict:n=!0}=t??{},r=`${e}.${n}`;if(Ge.has(r))return Ge.get(r);const s=N0.test(e)?e.toLowerCase()===e?!0:n?Ie(e)===e:!0:!1;return Ge.set(r,s),s}function we(e,t,n,{strict:r}={}){return re(e,{strict:!1})?R0(e,t,n,{strict:r}):un(e,t,n,{strict:r})}function cn(e,t){if(typeof t=="number"&&t>0&&t>F(e)-1)throw new Zt({offset:t,position:"start",size:F(e)})}function fn(e,t,n){if(typeof t=="number"&&typeof n=="number"&&F(e)!==n-t)throw new Zt({offset:n,position:"end",size:F(e)})}function un(e,t,n,{strict:r}={}){cn(e,t);const s=e.slice(t,n);return r&&fn(s,t,n),s}function R0(e,t,n,{strict:r}={}){cn(e,t);const s=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return r&&fn(s,t,n),s}function L0(e){if(e.type)return e.type;if(typeof e.authorizationList<"u")return"eip7702";if(typeof e.blobs<"u"||typeof e.blobVersionedHashes<"u"||typeof e.maxFeePerBlobGas<"u"||typeof e.sidecars<"u")return"eip4844";if(typeof e.maxFeePerGas<"u"||typeof e.maxPriorityFeePerGas<"u")return"eip1559";if(typeof e.gasPrice<"u")return typeof e.accessList<"u"?"eip2930":"legacy";throw new B0({transaction:e})}function Qi({chain:e,currentChainId:t}){if(!e)throw new j0;if(t!==e.id)throw new O0({chain:e,currentChainId:t})}function U0({blockNumber:e,chain:t,contract:n}){const r=t?.contracts?.[n];if(!r)throw new De({chain:t,contract:{name:n}});if(e&&r.blockCreated&&r.blockCreated>e)throw new De({blockNumber:e,chain:t,contract:{name:n,blockCreated:r.blockCreated}});return r.address}function ee(e){return typeof e=="string"?{address:e,type:"json-rpc"}:e}const _0={1:"An `assert` condition failed.",17:"Arithmetic operation resulted in underflow or overflow.",18:"Division or modulo by zero (e.g. `5 / 0` or `23 % 0`).",33:"Attempted to convert to an invalid type.",34:"Attempted to access a storage byte array that is incorrectly encoded.",49:"Performed `.pop()` on an empty array",50:"Array index is out of bounds.",65:"Allocated too much memory or created an array which is too large.",81:"Attempted to call a zero-initialized variable of internal function type."},D0={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},H0={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"};function Z(e,{includeName:t=!1}={}){if(e.type!=="function"&&e.type!=="event"&&e.type!=="error")throw new sr(e.type);return`${e.name}(${Fe(e.inputs,{includeName:t})})`}function Fe(e,{includeName:t=!1}={}){return e?e.map(n=>V0(n,{includeName:t})).join(t?", ":","):""}function V0(e,{includeName:t}){return e.type.startsWith("tuple")?`(${Fe(e.components,{includeName:t})})${e.type.slice(5)}`:e.type+(t&&e.name?` ${e.name}`:"")}class K0 extends l{constructor({docsPath:t}){super(["A constructor was not found on the ABI.","Make sure you are using the correct ABI and that the constructor exists on it."].join(`
5
5
  `),{docsPath:t,name:"AbiConstructorNotFoundError"})}}class zt extends l{constructor({docsPath:t}){super(["Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.","Make sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists."].join(`
@@ -32,4 +32,4 @@ import{a9 as J,_ as M,ae as P,B as l,a8 as X,a3 as Qn,a1 as e0,a2 as j,ab as re,
32
32
  `).slice(0,-1)}class xs extends l{constructor(t,{account:n,docsPath:r,chain:s,data:i,gas:o,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:f,nonce:u,to:d,value:b,stateOverride:p}){const m=n?ee(n):void 0;let w=le({from:m?.address,to:d,value:typeof b<"u"&&`${tt(b)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:i,gas:o,gasPrice:typeof a<"u"&&`${j(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${j(c)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${j(f)} gwei`,nonce:u});p&&(w+=`
33
33
  ${ws(p)}`),super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Raw Call Arguments:",w].filter(Boolean),name:"CallExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class Ps extends l{constructor(t,{abi:n,args:r,contractAddress:s,docsPath:i,functionName:o,sender:a}){const c=ft({abi:n,args:r,name:o}),f=c?Fn({abiItem:c,args:r,includeFunctionName:!1,includeName:!1}):void 0,u=c?Z(c,{includeName:!0}):void 0,d=le({address:s&&c0(s),function:u,args:f&&f!=="()"&&`${[...Array(o?.length??0).keys()].map(()=>" ").join("")}${f}`,sender:a});super(t.shortMessage||`An unknown error occurred while executing the contract function "${o}".`,{cause:t,docsPath:i,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],d&&"Contract Call:",d].filter(Boolean),name:"ContractFunctionExecutionError"}),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}),this.abi=n,this.args=r,this.cause=t,this.contractAddress=s,this.functionName=o,this.sender=a}}class vs extends l{constructor({abi:t,data:n,functionName:r,message:s,cause:i}){let o,a,c,f;if(n&&n!=="0x")try{a=hs({abi:t,data:n,cause:i});const{abiItem:d,errorName:b,args:p}=a;if(b==="Error")f=p[0];else if(b==="Panic"){const[m]=p;f=_0[m]}else{const m=d?Z(d,{includeName:!0}):void 0,w=d&&p?Fn({abiItem:d,args:p,includeFunctionName:!1,includeName:!1}):void 0;c=[m?`Error: ${m}`:"",w&&w!=="()"?` ${[...Array(b?.length??0).keys()].map(()=>" ").join("")}${w}`:""]}}catch(d){o=d}else s&&(f=s);let u;o instanceof ln&&(u=o.signature,c=[`Unable to decode signature "${u}" 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://4byte.sourcify.dev/?q=${u}.`]),super(f&&f!=="execution reverted"||u?[`The contract function "${r}" reverted with the following ${u?"signature":"reason"}:`,f||u].join(`
34
34
  `):`The contract function "${r}" reverted.`,{cause:o??i,metaMessages:c,name:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"raw",{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=a,this.raw=n,this.reason=f,this.signature=u}}class $s extends l{constructor({functionName:t,cause:n}){super(`The contract function "${t}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",` - The contract does not have the function "${t}",`," - The parameters passed to the contract function may be invalid, or"," - The address is not a contract."],name:"ContractFunctionZeroDataError",cause:n})}}class Es extends l{constructor({factory:t}){super(`Deployment for counterfactual contract call failed${t?` for factory "${t}".`:""}`,{metaMessages:["Please ensure:","- The `factory` is a valid contract deployment factory (ie. Create2 Factory, ERC-4337 Factory, etc).","- The `factoryData` is a valid encoded function call for contract deployment function on the factory."],name:"CounterfactualDeploymentFailedError"})}}class Sn extends l{constructor({data:t,message:n}){super(n||"",{name:"RawContractError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=t}}function ut(e,t){const n=(e.details||"").toLowerCase(),r=e instanceof l?e.walk(s=>s?.code===ye.code):e;return r instanceof l?new ye({cause:e,message:r.details}):ye.nodeMessage.test(n)?new ye({cause:e,message:e.details}):Ue.nodeMessage.test(n)?new Ue({cause:e,maxFeePerGas:t?.maxFeePerGas}):gt.nodeMessage.test(n)?new gt({cause:e,maxFeePerGas:t?.maxFeePerGas}):wt.nodeMessage.test(n)?new wt({cause:e,nonce:t?.nonce}):xt.nodeMessage.test(n)?new xt({cause:e,nonce:t?.nonce}):Pt.nodeMessage.test(n)?new Pt({cause:e,nonce:t?.nonce}):vt.nodeMessage.test(n)?new vt({cause:e}):$t.nodeMessage.test(n)?new $t({cause:e,gas:t?.gas}):Et.nodeMessage.test(n)?new Et({cause:e,gas:t?.gas}):At.nodeMessage.test(n)?new At({cause:e}):_e.nodeMessage.test(n)?new _e({cause:e,maxFeePerGas:t?.maxFeePerGas,maxPriorityFeePerGas:t?.maxPriorityFeePerGas}):new $e({cause:e})}function As(e,{docsPath:t,...n}){const r=(()=>{const s=ut(e,n);return s instanceof $e?e:s})();return new xs(r,{docsPath:t,...n})}function dt(e,{format:t}){if(!t)return{};const n={};function r(i){const o=Object.keys(i);for(const a of o)a in e&&(n[a]=e[a]),i[a]&&typeof i[a]=="object"&&!Array.isArray(i[a])&&r(i[a])}const s=t(e||{});return r(s),n}function Se(e){const{account:t,maxFeePerGas:n,maxPriorityFeePerGas:r,to:s}=e,i=t?ee(t):void 0;if(i&&!N(i.address))throw new Q({address:i.address});if(s&&!N(s))throw new Q({address:s});if(n&&n>w0)throw new Ue({maxFeePerGas:n});if(r&&n&&r>n)throw new _e({maxFeePerGas:n,maxPriorityFeePerGas:r})}const lt=BigInt(0),qe=BigInt(1);function bt(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function pt(e){if(!bt(e))throw new Error("Uint8Array expected")}function lo(e,t){if(typeof t!="boolean")throw new Error(e+" boolean expected, got "+t)}function bo(e){const t=e.toString(16);return t.length&1?"0"+t:t}function zn(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);return e===""?lt:BigInt("0x"+e)}const kn=typeof Uint8Array.from([]).toHex=="function"&&typeof Uint8Array.fromHex=="function",Bs=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function Mn(e){if(pt(e),kn)return e.toHex();let t="";for(let n=0;n<e.length;n++)t+=Bs[e[n]];return t}const _={_0:48,_9:57,A:65,F:70,a:97,f:102};function Ot(e){if(e>=_._0&&e<=_._9)return e-_._0;if(e>=_.A&&e<=_.F)return e-(_.A-10);if(e>=_.a&&e<=_.f)return e-(_.a-10)}function Gn(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);if(kn)return Uint8Array.fromHex(e);const t=e.length,n=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const r=new Uint8Array(n);for(let s=0,i=0;s<n;s++,i+=2){const o=Ot(e.charCodeAt(i)),a=Ot(e.charCodeAt(i+1));if(o===void 0||a===void 0){const c=e[i]+e[i+1];throw new Error('hex string expected, got non-hex character "'+c+'" at index '+i)}r[s]=o*16+a}return r}function po(e){return zn(Mn(e))}function yo(e){return pt(e),zn(Mn(Uint8Array.from(e).reverse()))}function Is(e,t){return Gn(e.toString(16).padStart(t*2,"0"))}function ho(e,t){return Is(e,t).reverse()}function mo(e,t,n){let r;if(typeof t=="string")try{r=Gn(t)}catch(i){throw new Error(e+" must be hex string or Uint8Array, cause: "+i)}else if(bt(t))r=Uint8Array.from(t);else throw new Error(e+" must be hex string or Uint8Array");const s=r.length;if(typeof n=="number"&&s!==n)throw new Error(e+" of length "+n+" expected, got "+s);return r}function Fs(...e){let t=0;for(let r=0;r<e.length;r++){const s=e[r];pt(s),t+=s.length}const n=new Uint8Array(t);for(let r=0,s=0;r<e.length;r++){const i=e[r];n.set(i,s),s+=i.length}return n}function Ts(e,t){if(e.length!==t.length)return!1;let n=0;for(let r=0;r<e.length;r++)n|=e[r]^t[r];return n===0}const Oe=e=>typeof e=="bigint"&&lt<=e;function Ss(e,t,n){return Oe(e)&&Oe(t)&&Oe(n)&&t<=e&&e<n}function go(e,t,n,r){if(!Ss(t,n,r))throw new Error("expected valid "+e+": "+n+" <= n < "+r+", got "+t)}function wo(e){let t;for(t=0;e>lt;e>>=qe,t+=1);return t}const xo=e=>(qe<<BigInt(e))-qe,je=e=>new Uint8Array(e),jt=e=>Uint8Array.from(e);function Po(e,t,n){if(typeof e!="number"||e<2)throw new Error("hashLen must be a number");if(typeof t!="number"||t<2)throw new Error("qByteLen must be a number");if(typeof n!="function")throw new Error("hmacFn must be a function");let r=je(e),s=je(e),i=0;const o=()=>{r.fill(1),s.fill(0),i=0},a=(...d)=>n(s,r,...d),c=(d=je(0))=>{s=a(jt([0]),d),r=a(),d.length!==0&&(s=a(jt([1]),d),r=a())},f=()=>{if(i++>=1e3)throw new Error("drbg: tried 1000 values");let d=0;const b=[];for(;d<t;){r=a();const p=r.slice();b.push(p),d+=r.length}return Fs(...b)};return(d,b)=>{o(),c(d);let p;for(;!(p=b(f()));)c();return o(),p}}const zs={bigint:e=>typeof e=="bigint",function:e=>typeof e=="function",boolean:e=>typeof e=="boolean",string:e=>typeof e=="string",stringOrUint8Array:e=>typeof e=="string"||bt(e),isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>typeof e=="function"&&Number.isSafeInteger(e.outputLen)};function vo(e,t,n={}){const r=(s,i,o)=>{const a=zs[i];if(typeof a!="function")throw new Error("invalid validator function");const c=e[s];if(!(o&&c===void 0)&&!a(c,e))throw new Error("param "+String(s)+" is invalid. Expected "+i+", got "+c)};for(const[s,i]of Object.entries(t))r(s,i,!1);for(const[s,i]of Object.entries(n))r(s,i,!0);return e}function $o(e){const t=new WeakMap;return(n,...r)=>{const s=t.get(n);if(s!==void 0)return s;const i=e(n,...r);return t.set(n,i),i}}const ks="0.1.1";function Ms(){return ks}class A extends Error{static setStaticOptions(t){A.prototype.docsOrigin=t.docsOrigin,A.prototype.showVersion=t.showVersion,A.prototype.version=t.version}constructor(t,n={}){const r=(()=>{if(n.cause instanceof A){if(n.cause.details)return n.cause.details;if(n.cause.shortMessage)return n.cause.shortMessage}return n.cause&&"details"in n.cause&&typeof n.cause.details=="string"?n.cause.details:n.cause?.message?n.cause.message:n.details})(),s=n.cause instanceof A&&n.cause.docsPath||n.docsPath,i=n.docsOrigin??A.prototype.docsOrigin,o=`${i}${s??""}`,a=!!(n.version??A.prototype.showVersion),c=n.version??A.prototype.version,f=[t||"An error occurred.",...n.metaMessages?["",...n.metaMessages]:[],...r||s||a?["",r?`Details: ${r}`:void 0,s?`See: ${o}`:void 0,a?`Version: ${c}`:void 0]:[]].filter(u=>typeof u=="string").join(`
35
- `);super(f,n.cause?{cause:n.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsOrigin",{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,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showVersion",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{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,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.cause=n.cause,this.details=r,this.docs=o,this.docsOrigin=i,this.docsPath=s,this.shortMessage=t,this.showVersion=a,this.version=c}walk(t){return Cn(this,t)}}Object.defineProperty(A,"defaultStaticOptions",{enumerable:!0,configurable:!0,writable:!0,value:{docsOrigin:"https://oxlib.sh",showVersion:!1,version:`ox@${Ms()}`}});A.setStaticOptions(A.defaultStaticOptions);function Cn(e,t){return t?.(e)?e:e&&typeof e=="object"&&"cause"in e&&e.cause?Cn(e.cause,t):t?null:e}function ce(e,t){if(Ut(e)>t)throw new ei({givenSize:Ut(e),maxSize:t})}const D={zero:48,nine:57,A:65,F:70,a:97,f:102};function Nt(e){if(e>=D.zero&&e<=D.nine)return e-D.zero;if(e>=D.A&&e<=D.F)return e-(D.A-10);if(e>=D.a&&e<=D.f)return e-(D.a-10)}function Gs(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;if(e.length>r)throw new ti({size:e.length,targetSize:r,type:"Bytes"});const s=new Uint8Array(r);for(let i=0;i<r;i++){const o=n==="right";s[o?i:r-i-1]=e[o?i:e.length-i-1]}return s}function On(e,t={}){const{dir:n="left"}=t;let r=e,s=0;for(let i=0;i<r.length-1&&r[n==="left"?i:r.length-i-1].toString()==="0";i++)s++;return r=n==="left"?r.slice(s):r.slice(0,r.length-s),r}function ze(e,t){if(oe(e)>t)throw new Hs({givenSize:oe(e),maxSize:t})}function Cs(e,t){if(typeof t=="number"&&t>0&&t>oe(e)-1)throw new _n({offset:t,position:"start",size:oe(e)})}function Os(e,t,n){if(typeof t=="number"&&typeof n=="number"&&oe(e)!==n-t)throw new _n({offset:n,position:"end",size:oe(e)})}function jn(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;const s=e.replace("0x","");if(s.length>r*2)throw new Vs({size:Math.ceil(s.length/2),targetSize:r,type:"Hex"});return`0x${s[n==="right"?"padEnd":"padStart"](r*2,"0")}`}function js(e,t={}){const{dir:n="left"}=t;let r=e.replace("0x",""),s=0;for(let i=0;i<r.length-1&&r[n==="left"?i:r.length-i-1].toString()==="0";i++)s++;return r=n==="left"?r.slice(s):r.slice(0,r.length-s),r==="0"?"0x":n==="right"&&r.length%2===1?`0x${r}0`:`0x${r}`}const Ns="#__bigint";function Nn(e,t,n){return JSON.stringify(e,(r,s)=>typeof s=="bigint"?s.toString()+Ns:s,n)}const Rs=new TextEncoder,Ls=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function Us(e,t={}){const{strict:n=!1}=t;if(!e)throw new Rt(e);if(typeof e!="string")throw new Rt(e);if(n&&!/^0x[0-9a-fA-F]*$/.test(e))throw new Lt(e);if(!e.startsWith("0x"))throw new Lt(e)}function Eo(...e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}function Ao(e){return e instanceof Uint8Array?ie(e):Array.isArray(e)?ie(new Uint8Array(e)):e}function Bo(e,t={}){const n=`0x${Number(e)}`;return typeof t.size=="number"?(ze(n,t.size),Rn(n,t.size)):n}function ie(e,t={}){let n="";for(let s=0;s<e.length;s++)n+=Ls[e[s]];const r=`0x${n}`;return typeof t.size=="number"?(ze(r,t.size),Ln(r,t.size)):r}function H(e,t={}){const{signed:n,size:r}=t,s=BigInt(e);let i;r?n?i=(1n<<BigInt(r)*8n-1n)-1n:i=2n**(BigInt(r)*8n)-1n:typeof e=="number"&&(i=BigInt(Number.MAX_SAFE_INTEGER));const o=typeof i=="bigint"&&n?-i-1n:0;if(i&&s>i||s<o){const f=typeof e=="bigint"?"n":"";throw new Ds({max:i?`${i}${f}`:void 0,min:`${o}${f}`,signed:n,size:r,value:`${e}${f}`})}const c=`0x${(n&&s<0?BigInt.asUintN(r*8,BigInt(s)):s).toString(16)}`;return r?Rn(c,r):c}function Io(e,t={}){return ie(Rs.encode(e),t)}function Rn(e,t){return jn(e,{dir:"left",size:t})}function Ln(e,t){return jn(e,{dir:"right",size:t})}function Fo(e){return ie(Js(e))}function To(e,t,n,r={}){const{strict:s}=r;Cs(e,t);const i=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return s&&Os(i,t,n),i}function oe(e){return Math.ceil((e.length-2)/2)}function So(e){return js(e,{dir:"left"})}function Un(e,t={}){const{signed:n}=t;t.size&&ze(e,t.size);const r=BigInt(e);if(!n)return r;const s=(e.length-2)/2,i=(1n<<BigInt(s)*8n)-1n,o=i>>1n;return r<=o?r:r-i-1n}function _s(e,t={}){const{signed:n,size:r}=t;return Number(!n&&!r?e:Un(e,t))}function zo(e,t={}){const{size:n}=t;let r=Dn(e);return n&&(ce(r,n),r=Hn(r)),new TextDecoder().decode(r)}function ko(e,t={}){const{strict:n=!1}=t;try{return Us(e,{strict:n}),!0}catch{return!1}}class Ds extends A{constructor({max:t,min:n,signed:r,size:s,value:i}){super(`Number \`${i}\` is not in safe${s?` ${s*8}-bit`:""}${r?" signed":" unsigned"} integer range ${t?`(\`${n}\` to \`${t}\`)`:`(above \`${n}\`)`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.IntegerOutOfRangeError"})}}class Rt extends A{constructor(t){super(`Value \`${typeof t=="object"?Nn(t):t}\` of type \`${typeof t}\` is an invalid hex type.`,{metaMessages:['Hex types must be represented as `"0x${string}"`.']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexTypeError"})}}class Lt extends A{constructor(t){super(`Value \`${t}\` is an invalid hex value.`,{metaMessages:['Hex values must start with `"0x"` and contain only hexadecimal characters (0-9, a-f, A-F).']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexValueError"})}}class Mo extends A{constructor(t){super(`Hex value \`"${t}"\` is an odd length (${t.length-2} nibbles).`,{metaMessages:["It must be an even length."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidLengthError"})}}let Hs=class extends A{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeOverflowError"})}};class _n extends A{constructor({offset:t,position:n,size:r}){super(`Slice ${n==="start"?"starting":"ending"} at offset \`${t}\` is out-of-bounds (size: \`${r}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SliceOffsetOutOfBoundsError"})}}let Vs=class extends A{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeExceedsPaddingSizeError"})}};const Ks=new TextDecoder,Ws=new TextEncoder;function Zs(e){if(!(e instanceof Uint8Array)){if(!e)throw new he(e);if(typeof e!="object")throw new he(e);if(!("BYTES_PER_ELEMENT"in e))throw new he(e);if(e.BYTES_PER_ELEMENT!==1||e.constructor.name!=="Uint8Array")throw new he(e)}}function Oo(...e){let t=0;for(const r of e)t+=r.length;const n=new Uint8Array(t);for(let r=0,s=0;r<e.length;r++){const i=e[r];n.set(i,s),s+=i.length}return n}function jo(e){return e instanceof Uint8Array?e:typeof e=="string"?Dn(e):qs(e)}function qs(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function Dn(e,t={}){const{size:n}=t;let r=e;n&&(ze(e,n),r=Ln(e,n));let s=r.slice(2);s.length%2&&(s=`0${s}`);const i=s.length/2,o=new Uint8Array(i);for(let a=0,c=0;a<i;a++){const f=Nt(s.charCodeAt(c++)),u=Nt(s.charCodeAt(c++));if(f===void 0||u===void 0)throw new A(`Invalid byte sequence ("${s[c-2]}${s[c-1]}" in "${s}").`);o[a]=f<<4|u}return o}function No(e,t={}){const{size:n}=t,r=Ws.encode(e);return typeof n=="number"?(ce(r,n),Ys(r,n)):r}function Ro(e,t){return Ts(e,t)}function Ys(e,t){return Gs(e,{dir:"right",size:t})}function Js(e){return crypto.getRandomValues(new Uint8Array(e))}function Ut(e){return e.length}function Lo(e,t,n,r={}){const{strict:s}=r;return e.slice(t,n)}function Uo(e,t={}){const{size:n}=t;typeof n<"u"&&ce(e,n);const r=ie(e,t);return Un(r,t)}function _o(e,t={}){const{size:n}=t;let r=e;if(typeof n<"u"&&(ce(r,n),r=Xs(r)),r.length>1||r[0]>1)throw new Qs(r);return!!r[0]}function Do(e,t={}){const{size:n}=t;typeof n<"u"&&ce(e,n);const r=ie(e,t);return _s(r,t)}function Ho(e,t={}){const{size:n}=t;let r=e;return typeof n<"u"&&(ce(r,n),r=Hn(r)),Ks.decode(r)}function Xs(e){return On(e,{dir:"left"})}function Hn(e){return On(e,{dir:"right"})}function Vo(e){try{return Zs(e),!0}catch{return!1}}class Qs extends A{constructor(t){super(`Bytes value \`${t}\` is not a valid boolean.`,{metaMessages:["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:"Bytes.InvalidBytesBooleanError"})}}class he extends A{constructor(t){super(`Value \`${typeof t=="object"?Nn(t):t}\` of type \`${typeof t}\` is an invalid Bytes value.`,{metaMessages:["Bytes values must be of type `Bytes`."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.InvalidBytesTypeError"})}}class ei extends A{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeOverflowError"})}}class ti extends A{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeExceedsPaddingSizeError"})}}const ni="0x608060405234801561001057600080fd5b5060405161018e38038061018e83398101604081905261002f91610124565b6000808351602085016000f59050803b61004857600080fd5b6000808351602085016000855af16040513d6000823e81610067573d81fd5b3d81f35b634e487b7160e01b600052604160045260246000fd5b600082601f83011261009257600080fd5b81516001600160401b038111156100ab576100ab61006b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156100d9576100d961006b565b6040528181528382016020018510156100f157600080fd5b60005b82811015610110576020818601810151838301820152016100f4565b506000918101602001919091529392505050565b6000806040838503121561013757600080fd5b82516001600160401b0381111561014d57600080fd5b61015985828601610081565b602085015190935090506001600160401b0381111561017757600080fd5b61018385828601610081565b915050925092905056fe",ri="0x608060405234801561001057600080fd5b506040516102c03803806102c083398101604081905261002f916101e6565b836001600160a01b03163b6000036100e457600080836001600160a01b03168360405161005c9190610270565b6000604051808303816000865af19150503d8060008114610099576040519150601f19603f3d011682016040523d82523d6000602084013e61009e565b606091505b50915091508115806100b857506001600160a01b0386163b155b156100e1578060405163101bb98d60e01b81526004016100d8919061028c565b60405180910390fd5b50505b6000808451602086016000885af16040513d6000823e81610103573d81fd5b3d81f35b80516001600160a01b038116811461011e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561015457818101518382015260200161013c565b50506000910152565b600082601f83011261016e57600080fd5b81516001600160401b0381111561018757610187610123565b604051601f8201601f19908116603f011681016001600160401b03811182821017156101b5576101b5610123565b6040528181528382016020018510156101cd57600080fd5b6101de826020830160208701610139565b949350505050565b600080600080608085870312156101fc57600080fd5b61020585610107565b60208601519094506001600160401b0381111561022157600080fd5b61022d8782880161015d565b93505061023c60408601610107565b60608601519092506001600160401b0381111561025857600080fd5b6102648782880161015d565b91505092959194509250565b60008251610282818460208701610139565b9190910192915050565b60208152600082518060208401526102ab816040850160208701610139565b601f01601f1916919091016040019291505056fe",Ko="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b815260206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b815260206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572",si="0x608060405234801561001057600080fd5b506115b9806100206000396000f3fe6080604052600436106100f35760003560e01c80634d2301cc1161008a578063a8b0574e11610059578063a8b0574e14610325578063bce38bd714610350578063c3077fa914610380578063ee82ac5e146103b2576100f3565b80634d2301cc1461026257806372425d9d1461029f57806382ad56cb146102ca57806386d516e8146102fa576100f3565b80633408e470116100c65780633408e470146101af578063399542e9146101da5780633e64a6961461020c57806342cbb15c14610237576100f3565b80630f28c97d146100f8578063174dea7114610123578063252dba421461015357806327e86d6e14610184575b600080fd5b34801561010457600080fd5b5061010d6103ef565b60405161011a9190610c0a565b60405180910390f35b61013d60048036038101906101389190610c94565b6103f7565b60405161014a9190610e94565b60405180910390f35b61016d60048036038101906101689190610f0c565b610615565b60405161017b92919061101b565b60405180910390f35b34801561019057600080fd5b506101996107ab565b6040516101a69190611064565b60405180910390f35b3480156101bb57600080fd5b506101c46107b7565b6040516101d19190610c0a565b60405180910390f35b6101f460048036038101906101ef91906110ab565b6107bf565b6040516102039392919061110b565b60405180910390f35b34801561021857600080fd5b506102216107e1565b60405161022e9190610c0a565b60405180910390f35b34801561024357600080fd5b5061024c6107e9565b6040516102599190610c0a565b60405180910390f35b34801561026e57600080fd5b50610289600480360381019061028491906111a7565b6107f1565b6040516102969190610c0a565b60405180910390f35b3480156102ab57600080fd5b506102b4610812565b6040516102c19190610c0a565b60405180910390f35b6102e460048036038101906102df919061122a565b61081a565b6040516102f19190610e94565b60405180910390f35b34801561030657600080fd5b5061030f6109e4565b60405161031c9190610c0a565b60405180910390f35b34801561033157600080fd5b5061033a6109ec565b6040516103479190611286565b60405180910390f35b61036a600480360381019061036591906110ab565b6109f4565b6040516103779190610e94565b60405180910390f35b61039a60048036038101906103959190610f0c565b610ba6565b6040516103a99392919061110b565b60405180910390f35b3480156103be57600080fd5b506103d960048036038101906103d491906112cd565b610bca565b6040516103e69190611064565b60405180910390f35b600042905090565b60606000808484905090508067ffffffffffffffff81111561041c5761041b6112fa565b5b60405190808252806020026020018201604052801561045557816020015b610442610bd5565b81526020019060019003908161043a5790505b5092503660005b828110156105c957600085828151811061047957610478611329565b5b6020026020010151905087878381811061049657610495611329565b5b90506020028101906104a89190611367565b925060008360400135905080860195508360000160208101906104cb91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16818580606001906104f2919061138f565b604051610500929190611431565b60006040518083038185875af1925050503d806000811461053d576040519150601f19603f3d011682016040523d82523d6000602084013e610542565b606091505b5083600001846020018290528215151515815250505081516020850135176105bc577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260846000fd5b826001019250505061045c565b5082341461060c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610603906114a7565b60405180910390fd5b50505092915050565b6000606043915060008484905090508067ffffffffffffffff81111561063e5761063d6112fa565b5b60405190808252806020026020018201604052801561067157816020015b606081526020019060019003908161065c5790505b5091503660005b828110156107a157600087878381811061069557610694611329565b5b90506020028101906106a791906114c7565b92508260000160208101906106bc91906111a7565b73ffffffffffffffffffffffffffffffffffffffff168380602001906106e2919061138f565b6040516106f0929190611431565b6000604051808303816000865af19150503d806000811461072d576040519150601f19603f3d011682016040523d82523d6000602084013e610732565b606091505b5086848151811061074657610745611329565b5b60200260200101819052819250505080610795576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161078c9061153b565b60405180910390fd5b81600101915050610678565b5050509250929050565b60006001430340905090565b600046905090565b6000806060439250434091506107d68686866109f4565b905093509350939050565b600048905090565b600043905090565b60008173ffffffffffffffffffffffffffffffffffffffff16319050919050565b600044905090565b606060008383905090508067ffffffffffffffff81111561083e5761083d6112fa565b5b60405190808252806020026020018201604052801561087757816020015b610864610bd5565b81526020019060019003908161085c5790505b5091503660005b828110156109db57600084828151811061089b5761089a611329565b5b602002602001015190508686838181106108b8576108b7611329565b5b90506020028101906108ca919061155b565b92508260000160208101906108df91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060400190610905919061138f565b604051610913929190611431565b6000604051808303816000865af19150503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b5082600001836020018290528215151515815250505080516020840135176109cf577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260646000fd5b8160010191505061087e565b50505092915050565b600045905090565b600041905090565b606060008383905090508067ffffffffffffffff811115610a1857610a176112fa565b5b604051908082528060200260200182016040528015610a5157816020015b610a3e610bd5565b815260200190600190039081610a365790505b5091503660005b82811015610b9c576000848281518110610a7557610a74611329565b5b60200260200101519050868683818110610a9257610a91611329565b5b9050602002810190610aa491906114c7565b9250826000016020810190610ab991906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060200190610adf919061138f565b604051610aed929190611431565b6000604051808303816000865af19150503d8060008114610b2a576040519150601f19603f3d011682016040523d82523d6000602084013e610b2f565b606091505b508260000183602001829052821515151581525050508715610b90578060000151610b8f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b869061153b565b60405180910390fd5b5b81600101915050610a58565b5050509392505050565b6000806060610bb7600186866107bf565b8093508194508295505050509250925092565b600081409050919050565b6040518060400160405280600015158152602001606081525090565b6000819050919050565b610c0481610bf1565b82525050565b6000602082019050610c1f6000830184610bfb565b92915050565b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008083601f840112610c5457610c53610c2f565b5b8235905067ffffffffffffffff811115610c7157610c70610c34565b5b602083019150836020820283011115610c8d57610c8c610c39565b5b9250929050565b60008060208385031215610cab57610caa610c25565b5b600083013567ffffffffffffffff811115610cc957610cc8610c2a565b5b610cd585828601610c3e565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60008115159050919050565b610d2281610d0d565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610d62578082015181840152602081019050610d47565b83811115610d71576000848401525b50505050565b6000601f19601f8301169050919050565b6000610d9382610d28565b610d9d8185610d33565b9350610dad818560208601610d44565b610db681610d77565b840191505092915050565b6000604083016000830151610dd96000860182610d19565b5060208301518482036020860152610df18282610d88565b9150508091505092915050565b6000610e0a8383610dc1565b905092915050565b6000602082019050919050565b6000610e2a82610ce1565b610e348185610cec565b935083602082028501610e4685610cfd565b8060005b85811015610e825784840389528151610e638582610dfe565b9450610e6e83610e12565b925060208a01995050600181019050610e4a565b50829750879550505050505092915050565b60006020820190508181036000830152610eae8184610e1f565b905092915050565b60008083601f840112610ecc57610ecb610c2f565b5b8235905067ffffffffffffffff811115610ee957610ee8610c34565b5b602083019150836020820283011115610f0557610f04610c39565b5b9250929050565b60008060208385031215610f2357610f22610c25565b5b600083013567ffffffffffffffff811115610f4157610f40610c2a565b5b610f4d85828601610eb6565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000610f918383610d88565b905092915050565b6000602082019050919050565b6000610fb182610f59565b610fbb8185610f64565b935083602082028501610fcd85610f75565b8060005b858110156110095784840389528151610fea8582610f85565b9450610ff583610f99565b925060208a01995050600181019050610fd1565b50829750879550505050505092915050565b60006040820190506110306000830185610bfb565b81810360208301526110428184610fa6565b90509392505050565b6000819050919050565b61105e8161104b565b82525050565b60006020820190506110796000830184611055565b92915050565b61108881610d0d565b811461109357600080fd5b50565b6000813590506110a58161107f565b92915050565b6000806000604084860312156110c4576110c3610c25565b5b60006110d286828701611096565b935050602084013567ffffffffffffffff8111156110f3576110f2610c2a565b5b6110ff86828701610eb6565b92509250509250925092565b60006060820190506111206000830186610bfb565b61112d6020830185611055565b818103604083015261113f8184610e1f565b9050949350505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061117482611149565b9050919050565b61118481611169565b811461118f57600080fd5b50565b6000813590506111a18161117b565b92915050565b6000602082840312156111bd576111bc610c25565b5b60006111cb84828501611192565b91505092915050565b60008083601f8401126111ea576111e9610c2f565b5b8235905067ffffffffffffffff81111561120757611206610c34565b5b60208301915083602082028301111561122357611222610c39565b5b9250929050565b6000806020838503121561124157611240610c25565b5b600083013567ffffffffffffffff81111561125f5761125e610c2a565b5b61126b858286016111d4565b92509250509250929050565b61128081611169565b82525050565b600060208201905061129b6000830184611277565b92915050565b6112aa81610bf1565b81146112b557600080fd5b50565b6000813590506112c7816112a1565b92915050565b6000602082840312156112e3576112e2610c25565b5b60006112f1848285016112b8565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b60008235600160800383360303811261138357611382611358565b5b80830191505092915050565b600080833560016020038436030381126113ac576113ab611358565b5b80840192508235915067ffffffffffffffff8211156113ce576113cd61135d565b5b6020830192506001820236038313156113ea576113e9611362565b5b509250929050565b600081905092915050565b82818337600083830152505050565b600061141883856113f2565b93506114258385846113fd565b82840190509392505050565b600061143e82848661140c565b91508190509392505050565b600082825260208201905092915050565b7f4d756c746963616c6c333a2076616c7565206d69736d61746368000000000000600082015250565b6000611491601a8361144a565b915061149c8261145b565b602082019050919050565b600060208201905081810360008301526114c081611484565b9050919050565b6000823560016040038336030381126114e3576114e2611358565b5b80830191505092915050565b7f4d756c746963616c6c333a2063616c6c206661696c6564000000000000000000600082015250565b600061152560178361144a565b9150611530826114ef565b602082019050919050565b6000602082019050818103600083015261155481611518565b9050919050565b60008235600160600383360303811261157757611576611358565b5b8083019150509291505056fea264697066735822122020c1bc9aacf8e4a6507193432a895a8e77094f45a1395583f07b24e860ef06cd64736f6c634300080c0033",Ne="/docs/contract/encodeDeployData";function Vn(e){const{abi:t,args:n,bytecode:r}=e;if(!n||n.length===0)return r;const s=t.find(o=>"type"in o&&o.type==="constructor");if(!s)throw new K0({docsPath:Ne});if(!("inputs"in s))throw new zt({docsPath:Ne});if(!s.inputs||s.inputs.length===0)throw new zt({docsPath:Ne});const i=In(s.inputs,n);return Be([r,i])}const _t="/docs/contract/encodeFunctionData";function ii(e){const{abi:t,args:n,functionName:r}=e;let s=t[0];if(r){const i=ft({abi:t,args:n,name:r});if(!i)throw new xe(r,{docsPath:_t});s=i}if(s.type!=="function")throw new xe(void 0,{docsPath:_t});return{abi:[s],functionName:st(Z(s))}}function oi(e){const{args:t}=e,{abi:n,functionName:r}=e.abi.length===1&&e.functionName?.startsWith("0x")?e:ii(e),s=n[0],i=r,o="inputs"in s&&s.inputs?In(s.inputs,t??[]):void 0;return Be([i,o??"0x"])}function ai(e,t){if(!N(e,{strict:!1}))throw new Q({address:e});if(!N(t,{strict:!1}))throw new Q({address:t});return e.toLowerCase()===t.toLowerCase()}function ci(e){const t=be(`0x${e.substring(4)}`).substring(26);return Ie(`0x${t}`)}async function fi({hash:e,signature:t}){const n=re(e)?e:me(e),{secp256k1:r}=await qt(async()=>{const{secp256k1:o}=await import("./secp256k1-Bg2aUJRs.js").then(a=>a.a);return{secp256k1:o}},__vite__mapDeps([0,1,2]));return`0x${(()=>{if(typeof t=="object"&&"r"in t&&"s"in t){const{r:f,s:u,v:d,yParity:b}=t,p=Number(b??d),m=Dt(p);return new r.Signature(ge(f),ge(u)).addRecoveryBit(m)}const o=re(t)?t:me(t);if(F(o)!==65)throw new Error("invalid signature length");const a=J(`0x${o.slice(130)}`),c=Dt(a);return r.Signature.fromCompact(o.substring(2,130)).addRecoveryBit(c)})().recoverPublicKey(n.substring(2)).toHex(!1)}`}function Dt(e){if(e===0||e===1)return e;if(e===27)return 0;if(e===28)return 1;throw new Error("Invalid yParityOrV value")}async function ui({hash:e,signature:t}){return ci(await fi({hash:e,signature:t}))}function di(e){const{chainId:t,nonce:n,to:r}=e,s=e.contractAddress??e.address,i=be(Be(["0x05",$0([t?P(t):"0x",s,n?P(n):"0x"])]));return r==="bytes"?X(i):i}async function li(e){const{authorization:t,signature:n}=e;return ui({hash:di(t),signature:n??t})}function k(e,t,n){const r=e[t.name];if(typeof r=="function")return r;const s=e[n];return typeof s=="function"?s:i=>t(e,i)}function bi(e){return{address:e.address,amount:H(e.amount),index:H(e.index),validatorIndex:H(e.validatorIndex)}}function pi(e){return{...typeof e.baseFeePerGas=="bigint"&&{baseFeePerGas:H(e.baseFeePerGas)},...typeof e.blobBaseFee=="bigint"&&{blobBaseFee:H(e.blobBaseFee)},...typeof e.feeRecipient=="string"&&{feeRecipient:e.feeRecipient},...typeof e.gasLimit=="bigint"&&{gasLimit:H(e.gasLimit)},...typeof e.number=="bigint"&&{number:H(e.number)},...typeof e.prevRandao=="bigint"&&{prevRandao:H(e.prevRandao)},...typeof e.time=="bigint"&&{time:H(e.time)},...e.withdrawals&&{withdrawals:e.withdrawals.map(bi)}}}const yi="0x82ad56cb",Re="/docs/contract/decodeFunctionResult";function hi(e){const{abi:t,args:n,functionName:r,data:s}=e;let i=t[0];if(r){const a=ft({abi:t,args:n,name:r});if(!a)throw new xe(r,{docsPath:Re});i=a}if(i.type!=="function")throw new xe(void 0,{docsPath:Re});if(!i.outputs)throw new X0(i.name,{docsPath:Re});const o=Te(i.outputs,s);if(o&&o.length>1)return o;if(o&&o.length===1)return o[0]}function Ht(e){if(!(!e||e.length===0))return e.reduce((t,{slot:n,value:r})=>{if(n.length!==66)throw new Bt({size:n.length,targetSize:66,type:"hex"});if(r.length!==66)throw new Bt({size:r.length,targetSize:66,type:"hex"});return t[n]=r,t},{})}function mi(e){const{balance:t,nonce:n,state:r,stateDiff:s,code:i}=e,o={};if(i!==void 0&&(o.code=i),t!==void 0&&(o.balance=P(t)),n!==void 0&&(o.nonce=P(n)),r!==void 0&&(o.state=Ht(r)),s!==void 0){if(o.state)throw new gs;o.stateDiff=Ht(s)}return o}function Kn(e){if(!e)return;const t={};for(const{address:n,...r}of e){if(!N(n,{strict:!1}))throw new Q({address:n});if(t[n])throw new ms({address:n});t[n]=mi(r)}return t}async function Wo(e,t){const{account:n=e.account,authorizationList:r,batch:s=!!e.batch?.multicall,blockNumber:i,blockTag:o=e.experimental_blockTag??"latest",accessList:a,blobs:c,blockOverrides:f,code:u,data:d,factory:b,factoryData:p,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:g,value:$,stateOverride:S,...R}=t,B=n?ee(n):void 0;if(u&&(b||p))throw new l("Cannot provide both `code` & `factory`/`factoryData` as parameters.");if(u&&g)throw new l("Cannot provide both `code` & `to` as parameters.");const T=u&&d,y=b&&p&&g&&d,O=T||y,L=T?Wn({code:u,data:d}):y?xi({data:d,factory:b,factoryData:p,to:g}):d;try{Se(t);const E=(typeof i=="bigint"?P(i):void 0)||o,G=f?pi(f):void 0,q=Kn(S),pe=e.chain?.formatters?.transactionRequest?.format,ke=(pe||Ae)({...dt(R,{format:pe}),accessList:a,account:B,authorizationList:r,blobs:c,data:L,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:O?void 0:g,value:$},"call");if(s&&gi({request:ke})&&!q&&!G)try{return await wi(e,{...ke,blockNumber:i,blockTag:o})}catch(W){if(!(W instanceof an)&&!(W instanceof De))throw W}const Xn=(()=>{const W=[ke,E];return q&&G?[...W,q,G]:q?[...W,q]:G?[...W,{},G]:W})(),mt=await e.request({method:"eth_call",params:Xn});return mt==="0x"?{data:void 0}:{data:mt}}catch(U){const E=Pi(U),{offchainLookup:G,offchainLookupSignature:q}=await qt(async()=>{const{offchainLookup:pe,offchainLookupSignature:ht}=await import("./ccip-Bldffu31.js");return{offchainLookup:pe,offchainLookupSignature:ht}},__vite__mapDeps([3,4,1,5,6,7,8]));if(e.ccipRead!==!1&&E?.slice(0,10)===q&&g)return{data:await G(e,{data:E,to:g})};throw O&&E?.slice(0,10)==="0x101bb98d"?new Es({factory:b}):As(U,{...t,account:B,chain:e.chain})}}function gi({request:e}){const{data:t,to:n,...r}=e;return!(!t||t.startsWith(yi)||!n||Object.values(r).filter(s=>typeof s<"u").length>0)}async function wi(e,t){const{batchSize:n=1024,deployless:r=!1,wait:s=0}=typeof e.batch?.multicall=="object"?e.batch.multicall:{},{blockNumber:i,blockTag:o=e.experimental_blockTag??"latest",data:a,to:c}=t,f=(()=>{if(r)return null;if(t.multicallAddress)return t.multicallAddress;if(e.chain)return U0({blockNumber:i,chain:e.chain,contract:"multicall3"});throw new an})(),d=(typeof i=="bigint"?P(i):void 0)||o,{schedule:b}=f0({id:`${e.uid}.${d}`,wait:s,shouldSplitBatch(w){return w.reduce((h,{data:v})=>h+(v.length-2),0)>n*2},fn:async w=>{const I=w.map(x=>({allowFailure:!0,callData:x.data,target:x.to})),h=oi({abi:It,args:[I],functionName:"aggregate3"}),v=await e.request({method:"eth_call",params:[{...f===null?{data:Wn({code:si,data:h})}:{to:f,data:h}},d]});return hi({abi:It,args:[I],functionName:"aggregate3",data:v||"0x"})}}),[{returnData:p,success:m}]=await b({data:a,to:c});if(!m)throw new Sn({data:p});return p==="0x"?{data:void 0}:{data:p}}function Wn(e){const{code:t,data:n}=e;return Vn({abi:An(["constructor(bytes, bytes)"]),bytecode:ni,args:[t,n]})}function xi(e){const{data:t,factory:n,factoryData:r,to:s}=e;return Vn({abi:An(["constructor(address, bytes, address, bytes)"]),bytecode:ri,args:[s,t,n,r]})}function Pi(e){if(!(e instanceof l))return;const t=e.walk();return typeof t?.data=="object"?t.data?.data:t.data}const vi=3;function Zo(e,{abi:t,address:n,args:r,docsPath:s,functionName:i,sender:o}){const a=e instanceof Sn?e:e instanceof l?e.walk(m=>"data"in m)||e.walk():{},{code:c,data:f,details:u,message:d,shortMessage:b}=a,p=e instanceof rt?new $s({functionName:i,cause:e}):[vi,u0.code].includes(c)&&(f||u||d||b)||c===d0.code&&u==="execution reverted"&&f?new vs({abi:t,data:typeof f=="object"?f.data:f,functionName:i,message:a instanceof l0?u:b??d,cause:e}):e;return new Ps(p,{abi:t,args:r,contractAddress:n,docsPath:s,functionName:i,sender:o})}function $i(e,{docsPath:t,...n}){const r=(()=>{const s=ut(e,n);return s instanceof $e?e:s})();return new I0(r,{docsPath:t,...n})}async function Zn(e){const t=await e.request({method:"eth_chainId"},{dedupe:!0});return J(t)}class qn extends l{constructor(){super("`baseFeeMultiplier` must be greater than 1.",{name:"BaseFeeScalarError"})}}class yt extends l{constructor(){super("Chain does not support EIP-1559 fees.",{name:"Eip1559FeesNotSupportedError"})}}class Ei extends l{constructor({maxPriorityFeePerGas:t}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${j(t)} gwei).`,{name:"MaxFeePerGasTooLowError"})}}class Ai extends l{constructor({blockHash:t,blockNumber:n}){let r="Block";t&&(r=`Block at hash "${t}"`),n&&(r=`Block at number "${n}"`),super(`${r} could not be found.`,{name:"BlockNotFoundError"})}}async function de(e,{blockHash:t,blockNumber:n,blockTag:r=e.experimental_blockTag??"latest",includeTransactions:s}={}){const i=s??!1,o=n!==void 0?P(n):void 0;let a=null;if(t?a=await e.request({method:"eth_getBlockByHash",params:[t,i]},{dedupe:!0}):a=await e.request({method:"eth_getBlockByNumber",params:[o||r,i]},{dedupe:!!o}),!a)throw new Ai({blockHash:t,blockNumber:n});return(e.chain?.formatters?.block?.format||Jt)(a,"getBlock")}async function Yn(e){const t=await e.request({method:"eth_gasPrice"});return BigInt(t)}async function qo(e,t){return Jn(e,t)}async function Jn(e,t){const{block:n,chain:r=e.chain,request:s}=t||{};try{const i=r?.fees?.maxPriorityFeePerGas??r?.fees?.defaultPriorityFee;if(typeof i=="function"){const a=n||await k(e,de,"getBlock")({}),c=await i({block:a,client:e,request:s});if(c===null)throw new Error;return c}if(typeof i<"u")return i;const o=await e.request({method:"eth_maxPriorityFeePerGas"});return ge(o)}catch{const[i,o]=await Promise.all([n?Promise.resolve(n):k(e,de,"getBlock")({}),k(e,Yn,"getGasPrice")({})]);if(typeof i.baseFeePerGas!="bigint")throw new yt;const a=o-i.baseFeePerGas;return a<0n?0n:a}}async function Yo(e,t){return Ye(e,t)}async function Ye(e,t){const{block:n,chain:r=e.chain,request:s,type:i="eip1559"}=t||{},o=await(async()=>typeof r?.fees?.baseFeeMultiplier=="function"?r.fees.baseFeeMultiplier({block:n,client:e,request:s}):r?.fees?.baseFeeMultiplier??1.2)();if(o<1)throw new qn;const c=10**(o.toString().split(".")[1]?.length??0),f=b=>b*BigInt(Math.ceil(o*c))/BigInt(c),u=n||await k(e,de,"getBlock")({});if(typeof r?.fees?.estimateFeesPerGas=="function"){const b=await r.fees.estimateFeesPerGas({block:n,client:e,multiply:f,request:s,type:i});if(b!==null)return b}if(i==="eip1559"){if(typeof u.baseFeePerGas!="bigint")throw new yt;const b=typeof s?.maxPriorityFeePerGas=="bigint"?s.maxPriorityFeePerGas:await Jn(e,{block:u,chain:r,request:s}),p=f(u.baseFeePerGas);return{maxFeePerGas:s?.maxFeePerGas??p+b,maxPriorityFeePerGas:b}}return{gasPrice:s?.gasPrice??f(await k(e,Yn,"getGasPrice")({}))}}class Bi extends l{constructor(t,{account:n,docsPath:r,chain:s,data:i,gas:o,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:f,nonce:u,to:d,value:b}){const p=le({from:n?.address,to:d,value:typeof b<"u"&&`${tt(b)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:i,gas:o,gasPrice:typeof a<"u"&&`${j(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${j(c)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${j(f)} gwei`,nonce:u});super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Estimate Gas Arguments:",p].filter(Boolean),name:"EstimateGasExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}function Ii(e,{docsPath:t,...n}){const r=(()=>{const s=ut(e,n);return s instanceof $e?e:s})();return new Bi(r,{docsPath:t,...n})}async function Fi(e,t){const{account:n=e.account,prepare:r=!0}=t,s=n?ee(n):void 0,i=(()=>{if(Array.isArray(r))return r;if(s?.type!=="local")return["blobVersionedHashes"]})();try{const o=await(async()=>{if(t.to)return t.to;if(t.authorizationList&&t.authorizationList.length>0)return await li({authorization:t.authorizationList[0]}).catch(()=>{throw new l("`to` is required. Could not infer from `authorizationList`")})})(),{accessList:a,authorizationList:c,blobs:f,blobVersionedHashes:u,blockNumber:d,blockTag:b,data:p,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,value:g,stateOverride:$,...S}=r?await ki(e,{...t,parameters:i,to:o}):t;if(m&&t.gas!==m)return m;const B=(typeof d=="bigint"?P(d):void 0)||b,T=Kn($);Se(t);const y=e.chain?.formatters?.transactionRequest?.format,L=(y||Ae)({...dt(S,{format:y}),account:s,accessList:a,authorizationList:c,blobs:f,blobVersionedHashes:u,data:p,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:o,value:g},"estimateGas");return BigInt(await e.request({method:"eth_estimateGas",params:T?[L,B??e.experimental_blockTag??"latest",T]:B?[L,B]:[L]}))}catch(o){throw Ii(o,{...t,account:s,chain:e.chain})}}async function Ti(e,{address:t,blockTag:n="latest",blockNumber:r}){const s=await e.request({method:"eth_getTransactionCount",params:[t,typeof r=="bigint"?P(r):n]},{dedupe:!!r});return J(s)}async function Si(e,t){const{account:n=e.account,accessList:r,authorizationList:s,chain:i=e.chain,blobVersionedHashes:o,blobs:a,data:c,gas:f,gasPrice:u,maxFeePerBlobGas:d,maxFeePerGas:b,maxPriorityFeePerGas:p,nonce:m,nonceManager:w,to:I,type:h,value:v,...x}=t,g=await(async()=>{if(!n||!w||typeof m<"u")return m;const B=ee(n),T=i?i.id:await k(e,Zn,"getChainId")({});return await w.consume({address:B.address,chainId:T,client:e})})();Se(t);const $=i?.formatters?.transactionRequest?.format,R=($||Ae)({...dt(x,{format:$}),account:n?ee(n):void 0,accessList:r,authorizationList:s,blobs:a,blobVersionedHashes:o,data:c,gas:f,gasPrice:u,maxFeePerBlobGas:d,maxFeePerGas:b,maxPriorityFeePerGas:p,nonce:g,to:I,type:h,value:v},"fillTransaction");try{const B=await e.request({method:"eth_fillTransaction",params:[R]}),y=(i?.formatters?.transaction?.format||Qe)(B.tx);delete y.blockHash,delete y.blockNumber,delete y.r,delete y.s,delete y.transactionIndex,delete y.v,delete y.yParity,y.data=y.input,y.gas&&(y.gas=t.gas??y.gas),y.gasPrice&&(y.gasPrice=t.gasPrice??y.gasPrice),y.maxFeePerBlobGas&&(y.maxFeePerBlobGas=t.maxFeePerBlobGas??y.maxFeePerBlobGas),y.maxFeePerGas&&(y.maxFeePerGas=t.maxFeePerGas??y.maxFeePerGas),y.maxPriorityFeePerGas&&(y.maxPriorityFeePerGas=t.maxPriorityFeePerGas??y.maxPriorityFeePerGas),typeof y.nonce<"u"&&(y.nonce=t.nonce??y.nonce);const O=await(async()=>{if(typeof i?.fees?.baseFeeMultiplier=="function"){const G=await k(e,de,"getBlock")({});return i.fees.baseFeeMultiplier({block:G,client:e,request:t})}return i?.fees?.baseFeeMultiplier??1.2})();if(O<1)throw new qn;const U=10**(O.toString().split(".")[1]?.length??0),E=G=>G*BigInt(Math.ceil(O*U))/BigInt(U);return y.feePayerSignature||(y.maxFeePerGas&&!t.maxFeePerGas&&(y.maxFeePerGas=E(y.maxFeePerGas)),y.gasPrice&&!t.gasPrice&&(y.gasPrice=E(y.gasPrice))),{raw:B.raw,transaction:{from:R.from,...y},...B.capabilities?{capabilities:B.capabilities}:{}}}catch(B){throw $i(B,{...t,chain:e.chain})}}const zi=["blobVersionedHashes","chainId","fees","gas","nonce","type"],Vt=new Map,Le=new Je(128);async function ki(e,t){let n=t;n.account??=e.account,n.parameters??=zi;const{account:r,chain:s=e.chain,nonceManager:i,parameters:o}=n,a=(()=>{if(typeof s?.prepareTransactionRequest=="function")return{fn:s.prepareTransactionRequest,runAt:["beforeFillTransaction"]};if(Array.isArray(s?.prepareTransactionRequest))return{fn:s.prepareTransactionRequest[0],runAt:s.prepareTransactionRequest[1].runAt}})();let c;async function f(){return c||(typeof n.chainId<"u"?n.chainId:s?s.id:(c=await k(e,Zn,"getChainId")({}),c))}const u=r&&ee(r);let d=n.nonce;if(o.includes("nonce")&&typeof d>"u"&&u&&i){const g=await f();d=await i.consume({address:u.address,chainId:g,client:e})}a?.fn&&a.runAt?.includes("beforeFillTransaction")&&(n=await a.fn({...n,chain:s},{phase:"beforeFillTransaction"}),d??=n.nonce);const p=((o.includes("blobVersionedHashes")||o.includes("sidecars"))&&n.kzg&&n.blobs||Le.get(e.uid)===!1||!["fees","gas"].some($=>o.includes($))?!1:!!(o.includes("chainId")&&typeof n.chainId!="number"||o.includes("nonce")&&typeof d!="number"||o.includes("fees")&&typeof n.gasPrice!="bigint"&&(typeof n.maxFeePerGas!="bigint"||typeof n.maxPriorityFeePerGas!="bigint")||o.includes("gas")&&typeof n.gas!="bigint"))?await k(e,Si,"fillTransaction")({...n,nonce:d}).then(g=>{const{chainId:$,from:S,gas:R,gasPrice:B,nonce:T,maxFeePerBlobGas:y,maxFeePerGas:O,maxPriorityFeePerGas:L,type:U,...E}=g.transaction;return Le.set(e.uid,!0),{...n,...S?{from:S}:{},...U&&!n.type?{type:U}:{},...typeof $<"u"?{chainId:$}:{},...typeof R<"u"?{gas:R}:{},...typeof B<"u"?{gasPrice:B}:{},...typeof T<"u"?{nonce:T}:{},...typeof y<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerBlobGas:y}:{},...typeof O<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerGas:O}:{},...typeof L<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxPriorityFeePerGas:L}:{},..."nonceKey"in E&&typeof E.nonceKey<"u"?{nonceKey:E.nonceKey}:{},..."keyAuthorization"in E&&typeof E.keyAuthorization<"u"&&E.keyAuthorization!==null&&!("keyAuthorization"in n)?{keyAuthorization:E.keyAuthorization}:{},..."feePayerSignature"in E&&typeof E.feePayerSignature<"u"&&E.feePayerSignature!==null?{feePayerSignature:E.feePayerSignature}:{},..."feeToken"in E&&typeof E.feeToken<"u"&&E.feeToken!==null&&!("feeToken"in n)?{feeToken:E.feeToken}:{},...g.capabilities?{_capabilities:g.capabilities}:{}}}).catch(g=>{const $=g;if($.name!=="TransactionExecutionError")return n;if($.walk?.(B=>B.name==="ExecutionRevertedError"))throw g;return $.walk?.(B=>{const T=B;return T.name==="MethodNotFoundRpcError"||T.name==="MethodNotSupportedRpcError"||T.message?.includes("eth_fillTransaction is not available")})&&Le.set(e.uid,!1),n}):n;d??=p.nonce,n={...p,...u?{from:u?.address}:{},...typeof d<"u"?{nonce:d}:{}};const{blobs:m,gas:w,kzg:I,type:h}=n;a?.fn&&a.runAt?.includes("beforeFillParameters")&&(n=await a.fn({...n,chain:s},{phase:"beforeFillParameters"}));let v;async function x(){return v||(v=await k(e,de,"getBlock")({blockTag:"latest"}),v)}if(o.includes("nonce")&&typeof d>"u"&&u&&!i&&(n.nonce=await k(e,Ti,"getTransactionCount")({address:u.address,blockTag:"pending"})),(o.includes("blobVersionedHashes")||o.includes("sidecars"))&&m&&I){const g=nn({blobs:m,kzg:I});if(o.includes("blobVersionedHashes")){const $=S0({commitments:g,to:"hex"});n.blobVersionedHashes=$}if(o.includes("sidecars")){const $=rn({blobs:m,commitments:g,kzg:I}),S=C0({blobs:m,commitments:g,proofs:$,to:"hex"});n.sidecars=S}}if(o.includes("chainId")&&(n.chainId=await f()),(o.includes("fees")||o.includes("type"))&&typeof h>"u")try{n.type=L0(n)}catch{let g=Vt.get(e.uid);typeof g>"u"&&(g=typeof(await x())?.baseFeePerGas=="bigint",Vt.set(e.uid,g)),n.type=g?"eip1559":"legacy"}if(o.includes("fees"))if(n.type!=="legacy"&&n.type!=="eip2930"){if(typeof n.maxFeePerGas>"u"||typeof n.maxPriorityFeePerGas>"u"){const g=await x(),{maxFeePerGas:$,maxPriorityFeePerGas:S}=await Ye(e,{block:g,chain:s,request:n});if(typeof n.maxPriorityFeePerGas>"u"&&n.maxFeePerGas&&n.maxFeePerGas<S)throw new Ei({maxPriorityFeePerGas:S});n.maxPriorityFeePerGas=S,n.maxFeePerGas=$}}else{if(typeof n.maxFeePerGas<"u"||typeof n.maxPriorityFeePerGas<"u")throw new yt;if(typeof n.gasPrice>"u"){const g=await x(),{gasPrice:$}=await Ye(e,{block:g,chain:s,request:n,type:"legacy"});n.gasPrice=$}}return o.includes("gas")&&typeof w>"u"&&(n.gas=await k(e,Fi,"estimateGas")({...n,account:u,prepare:u?.type==="local"?[]:["blobVersionedHashes"]})),a?.fn&&a.runAt?.includes("afterFillParameters")&&(n=await a.fn({...n,chain:s},{phase:"afterFillParameters"})),Se(n),delete n.parameters,n}async function Jo(e,{serializedTransaction:t}){return e.request({method:"eth_sendRawTransaction",params:[t]},{retryCount:0})}const Kt="/docs/contract/decodeEventLog";function Wt(e){const{abi:t,data:n,strict:r,topics:s}=e,i=r??!0,[o,...a]=s;if(!o)throw new Y0({docsPath:Kt});const c=t.find(h=>h.type==="event"&&o===ct(Z(h)));if(!(c&&"name"in c)||c.type!=="event")throw new J0(o,{docsPath:Kt});const{name:f,inputs:u}=c,d=u?.some(h=>!("name"in h&&h.name)),b=d?[]:{},p=u.map((h,v)=>[h,v]).filter(([h])=>"indexed"in h&&h.indexed),m=[];for(let h=0;h<p.length;h++){const[v,x]=p[h],g=a[h];if(!g){if(i)throw new er({abiItem:c,param:v});m.push([v,x]);continue}b[d?x:v.name||x]=Mi({param:v,value:g})}const w=u.filter(h=>!("indexed"in h&&h.indexed)),I=i?w:[...m.map(([h])=>h),...w];if(I.length>0){if(n&&n!=="0x")try{const h=Te(I,n);if(h){let v=0;if(!i)for(const[x,g]of m)b[d?g:x.name||g]=h[v++];if(d)for(let x=0;x<u.length;x++)b[x]===void 0&&v<h.length&&(b[x]=h[v++]);else for(let x=0;x<w.length;x++)b[w[x].name]=h[v++]}}catch(h){if(i)throw h instanceof dn||h instanceof Qt?new kt({abiItem:c,data:n,params:I,size:F(n)}):h}else if(i)throw new kt({abiItem:c,data:"0x",params:I,size:0})}return{eventName:f,args:Object.values(b).length>0?b:void 0}}function Mi({param:e,value:t}){return e.type==="string"||e.type==="bytes"||e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/)?t:(Te([e],t)||[])[0]}function Xo(e){const{abi:t,args:n,logs:r,strict:s=!0}=e,i=(()=>{if(e.eventName)return Array.isArray(e.eventName)?e.eventName:[e.eventName]})(),o=t.filter(a=>a.type==="event").map(a=>({abi:a,selector:ct(a)}));return r.map(a=>{const c=typeof a.blockNumber=="string"?Xt(a):a,f=o.filter(b=>c.topics[0]===b.selector);if(f.length===0)return null;let u,d;for(const b of f)try{u=Wt({...c,abi:[b.abi],strict:!0}),d=b;break}catch{}if(!u&&!s){d=f[0];try{u=Wt({data:c.data,topics:c.topics,abi:[d.abi],strict:!1})}catch{const b=d.abi.inputs?.some(p=>!("name"in p&&p.name));return{...c,args:b?[]:{},eventName:d.abi.name}}}return!u||!d||i&&!i.includes(u.eventName)||!Gi({args:u.args,inputs:d.abi.inputs,matchArgs:n})?null:{...u,...c}}).filter(Boolean)}function Gi(e){const{args:t,inputs:n,matchArgs:r}=e;if(!r)return!0;if(!t)return!1;function s(i,o,a){try{return i.type==="address"?ai(o,a):i.type==="string"||i.type==="bytes"?be(Pe(o))===a:o===a}catch{return!1}}return Array.isArray(t)&&Array.isArray(r)?r.every((i,o)=>{if(i==null)return!0;const a=n[o];return a?(Array.isArray(i)?i:[i]).some(f=>s(a,f,t[o])):!1}):typeof t=="object"&&!Array.isArray(t)&&typeof r=="object"&&!Array.isArray(r)?Object.entries(r).every(([i,o])=>{if(o==null)return!0;const a=n.find(f=>f.name===i);return a?(Array.isArray(o)?o:[o]).some(f=>s(a,f,t[i])):!1}):!1}export{Sn as $,K0 as A,qn as B,xs as C,Es as D,kt as E,er as F,yt as G,Bi as H,nr as I,tr as J,ao as K,co as L,Tr as M,Q as N,rr as O,Ji as P,sr as Q,Fr as R,Di as S,Ir as T,Ar as U,Mr as V,B0 as W,ae as X,Hi as Y,zr as Z,Ei as _,zt as a,we as a$,Br as a0,gs as a1,I0 as a2,Vi as a3,Ki as a4,Sr as a5,$r as a6,io as a7,Zi as a8,Qi as a9,Ko as aA,Jt as aB,tt as aC,Xt as aD,Qe as aE,h0 as aF,Ae as aG,ft as aH,Xi as aI,U0 as aJ,Zo as aK,ct as aL,Yr as aM,st as aN,L0 as aO,N as aP,ai as aQ,be as aR,_i as aS,w0 as aT,An as aU,Xo as aV,ii as aW,ui as aX,fi as aY,m0 as aZ,F0 as a_,Se as aa,nn as ab,rn as ac,Jr as ad,Xr as ae,V as af,Qr as ag,Ie as ah,T0 as ai,S0 as aj,se as ak,x0 as al,Be as am,Te as an,hs as ao,Wt as ap,hi as aq,Ri as ar,Ni as as,Li as at,Ui as au,ni as av,ri as aw,In as ax,Vn as ay,oi as az,dn as b,So as b$,un as b0,R0 as b1,C0 as b2,G0 as b3,Bn as b4,$0 as b5,Yt as b6,Wo as b7,li as b8,k as b9,$o as bA,es as bB,uo as bC,de as bD,M0 as bE,qi as bF,z0 as bG,Yi as bH,Cr as bI,Wr as bJ,xn as bK,C as bL,te as bM,oo as bN,jo as bO,ie as bP,ko as bQ,oe as bR,Vo as bS,Eo as bT,H as bU,To as bV,A as bW,Ao as bX,Nn as bY,Dn as bZ,No as b_,Zn as ba,dt as bb,ki as bc,zi as bd,Jo as be,$i as bf,ee as bg,Z as bh,D0 as bi,yo as bj,po as bk,ho as bl,Is as bm,xo as bn,vo as bo,wo as bp,Fs as bq,go as br,mo as bs,Gn as bt,bt as bu,Po as bv,lo as bw,Mn as bx,Ss as by,bo as bz,rt as c,Io as c0,cr as c1,Do as c2,Lo as c3,_o as c4,Uo as c5,Ho as c6,Xs as c7,Rn as c8,Bo as c9,Fo as cA,Ds as ca,Ln as cb,Ut as cc,fe as cd,_s as ce,si as cf,Fi as cg,Wi as ch,fo as ci,y0 as cj,As as ck,pi as cl,Kn as cm,ut as cn,Ti as co,Si as cp,qo as cq,Yn as cr,Yo as cs,le as ct,Mo as cu,Ro as cv,Oo as cw,Un as cx,zo as cy,Us as cz,W0 as d,Z0 as e,q0 as f,eo as g,to as h,ln as i,no as j,Y0 as k,J0 as l,xe as m,X0 as n,ro as o,ms as p,Ai as q,so as r,De as s,O0 as t,j0 as u,kr as v,an as w,Ps as x,vs as y,$s as z};
35
+ `);super(f,n.cause?{cause:n.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsOrigin",{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,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showVersion",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{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,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.cause=n.cause,this.details=r,this.docs=o,this.docsOrigin=i,this.docsPath=s,this.shortMessage=t,this.showVersion=a,this.version=c}walk(t){return Cn(this,t)}}Object.defineProperty(A,"defaultStaticOptions",{enumerable:!0,configurable:!0,writable:!0,value:{docsOrigin:"https://oxlib.sh",showVersion:!1,version:`ox@${Ms()}`}});A.setStaticOptions(A.defaultStaticOptions);function Cn(e,t){return t?.(e)?e:e&&typeof e=="object"&&"cause"in e&&e.cause?Cn(e.cause,t):t?null:e}function ce(e,t){if(Ut(e)>t)throw new ei({givenSize:Ut(e),maxSize:t})}const D={zero:48,nine:57,A:65,F:70,a:97,f:102};function Nt(e){if(e>=D.zero&&e<=D.nine)return e-D.zero;if(e>=D.A&&e<=D.F)return e-(D.A-10);if(e>=D.a&&e<=D.f)return e-(D.a-10)}function Gs(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;if(e.length>r)throw new ti({size:e.length,targetSize:r,type:"Bytes"});const s=new Uint8Array(r);for(let i=0;i<r;i++){const o=n==="right";s[o?i:r-i-1]=e[o?i:e.length-i-1]}return s}function On(e,t={}){const{dir:n="left"}=t;let r=e,s=0;for(let i=0;i<r.length-1&&r[n==="left"?i:r.length-i-1].toString()==="0";i++)s++;return r=n==="left"?r.slice(s):r.slice(0,r.length-s),r}function ze(e,t){if(oe(e)>t)throw new Hs({givenSize:oe(e),maxSize:t})}function Cs(e,t){if(typeof t=="number"&&t>0&&t>oe(e)-1)throw new _n({offset:t,position:"start",size:oe(e)})}function Os(e,t,n){if(typeof t=="number"&&typeof n=="number"&&oe(e)!==n-t)throw new _n({offset:n,position:"end",size:oe(e)})}function jn(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;const s=e.replace("0x","");if(s.length>r*2)throw new Vs({size:Math.ceil(s.length/2),targetSize:r,type:"Hex"});return`0x${s[n==="right"?"padEnd":"padStart"](r*2,"0")}`}function js(e,t={}){const{dir:n="left"}=t;let r=e.replace("0x",""),s=0;for(let i=0;i<r.length-1&&r[n==="left"?i:r.length-i-1].toString()==="0";i++)s++;return r=n==="left"?r.slice(s):r.slice(0,r.length-s),r==="0"?"0x":n==="right"&&r.length%2===1?`0x${r}0`:`0x${r}`}const Ns="#__bigint";function Nn(e,t,n){return JSON.stringify(e,(r,s)=>typeof s=="bigint"?s.toString()+Ns:s,n)}const Rs=new TextEncoder,Ls=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function Us(e,t={}){const{strict:n=!1}=t;if(!e)throw new Rt(e);if(typeof e!="string")throw new Rt(e);if(n&&!/^0x[0-9a-fA-F]*$/.test(e))throw new Lt(e);if(!e.startsWith("0x"))throw new Lt(e)}function Eo(...e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}function Ao(e){return e instanceof Uint8Array?ie(e):Array.isArray(e)?ie(new Uint8Array(e)):e}function Bo(e,t={}){const n=`0x${Number(e)}`;return typeof t.size=="number"?(ze(n,t.size),Rn(n,t.size)):n}function ie(e,t={}){let n="";for(let s=0;s<e.length;s++)n+=Ls[e[s]];const r=`0x${n}`;return typeof t.size=="number"?(ze(r,t.size),Ln(r,t.size)):r}function H(e,t={}){const{signed:n,size:r}=t,s=BigInt(e);let i;r?n?i=(1n<<BigInt(r)*8n-1n)-1n:i=2n**(BigInt(r)*8n)-1n:typeof e=="number"&&(i=BigInt(Number.MAX_SAFE_INTEGER));const o=typeof i=="bigint"&&n?-i-1n:0;if(i&&s>i||s<o){const f=typeof e=="bigint"?"n":"";throw new Ds({max:i?`${i}${f}`:void 0,min:`${o}${f}`,signed:n,size:r,value:`${e}${f}`})}const c=`0x${(n&&s<0?BigInt.asUintN(r*8,BigInt(s)):s).toString(16)}`;return r?Rn(c,r):c}function Io(e,t={}){return ie(Rs.encode(e),t)}function Rn(e,t){return jn(e,{dir:"left",size:t})}function Ln(e,t){return jn(e,{dir:"right",size:t})}function Fo(e){return ie(Js(e))}function To(e,t,n,r={}){const{strict:s}=r;Cs(e,t);const i=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return s&&Os(i,t,n),i}function oe(e){return Math.ceil((e.length-2)/2)}function So(e){return js(e,{dir:"left"})}function Un(e,t={}){const{signed:n}=t;t.size&&ze(e,t.size);const r=BigInt(e);if(!n)return r;const s=(e.length-2)/2,i=(1n<<BigInt(s)*8n)-1n,o=i>>1n;return r<=o?r:r-i-1n}function _s(e,t={}){const{signed:n,size:r}=t;return Number(!n&&!r?e:Un(e,t))}function zo(e,t={}){const{size:n}=t;let r=Dn(e);return n&&(ce(r,n),r=Hn(r)),new TextDecoder().decode(r)}function ko(e,t={}){const{strict:n=!1}=t;try{return Us(e,{strict:n}),!0}catch{return!1}}class Ds extends A{constructor({max:t,min:n,signed:r,size:s,value:i}){super(`Number \`${i}\` is not in safe${s?` ${s*8}-bit`:""}${r?" signed":" unsigned"} integer range ${t?`(\`${n}\` to \`${t}\`)`:`(above \`${n}\`)`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.IntegerOutOfRangeError"})}}class Rt extends A{constructor(t){super(`Value \`${typeof t=="object"?Nn(t):t}\` of type \`${typeof t}\` is an invalid hex type.`,{metaMessages:['Hex types must be represented as `"0x${string}"`.']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexTypeError"})}}class Lt extends A{constructor(t){super(`Value \`${t}\` is an invalid hex value.`,{metaMessages:['Hex values must start with `"0x"` and contain only hexadecimal characters (0-9, a-f, A-F).']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexValueError"})}}class Mo extends A{constructor(t){super(`Hex value \`"${t}"\` is an odd length (${t.length-2} nibbles).`,{metaMessages:["It must be an even length."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidLengthError"})}}let Hs=class extends A{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeOverflowError"})}};class _n extends A{constructor({offset:t,position:n,size:r}){super(`Slice ${n==="start"?"starting":"ending"} at offset \`${t}\` is out-of-bounds (size: \`${r}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SliceOffsetOutOfBoundsError"})}}let Vs=class extends A{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeExceedsPaddingSizeError"})}};const Ks=new TextDecoder,Ws=new TextEncoder;function Zs(e){if(!(e instanceof Uint8Array)){if(!e)throw new he(e);if(typeof e!="object")throw new he(e);if(!("BYTES_PER_ELEMENT"in e))throw new he(e);if(e.BYTES_PER_ELEMENT!==1||e.constructor.name!=="Uint8Array")throw new he(e)}}function Oo(...e){let t=0;for(const r of e)t+=r.length;const n=new Uint8Array(t);for(let r=0,s=0;r<e.length;r++){const i=e[r];n.set(i,s),s+=i.length}return n}function jo(e){return e instanceof Uint8Array?e:typeof e=="string"?Dn(e):qs(e)}function qs(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function Dn(e,t={}){const{size:n}=t;let r=e;n&&(ze(e,n),r=Ln(e,n));let s=r.slice(2);s.length%2&&(s=`0${s}`);const i=s.length/2,o=new Uint8Array(i);for(let a=0,c=0;a<i;a++){const f=Nt(s.charCodeAt(c++)),u=Nt(s.charCodeAt(c++));if(f===void 0||u===void 0)throw new A(`Invalid byte sequence ("${s[c-2]}${s[c-1]}" in "${s}").`);o[a]=f<<4|u}return o}function No(e,t={}){const{size:n}=t,r=Ws.encode(e);return typeof n=="number"?(ce(r,n),Ys(r,n)):r}function Ro(e,t){return Ts(e,t)}function Ys(e,t){return Gs(e,{dir:"right",size:t})}function Js(e){return crypto.getRandomValues(new Uint8Array(e))}function Ut(e){return e.length}function Lo(e,t,n,r={}){const{strict:s}=r;return e.slice(t,n)}function Uo(e,t={}){const{size:n}=t;typeof n<"u"&&ce(e,n);const r=ie(e,t);return Un(r,t)}function _o(e,t={}){const{size:n}=t;let r=e;if(typeof n<"u"&&(ce(r,n),r=Xs(r)),r.length>1||r[0]>1)throw new Qs(r);return!!r[0]}function Do(e,t={}){const{size:n}=t;typeof n<"u"&&ce(e,n);const r=ie(e,t);return _s(r,t)}function Ho(e,t={}){const{size:n}=t;let r=e;return typeof n<"u"&&(ce(r,n),r=Hn(r)),Ks.decode(r)}function Xs(e){return On(e,{dir:"left"})}function Hn(e){return On(e,{dir:"right"})}function Vo(e){try{return Zs(e),!0}catch{return!1}}class Qs extends A{constructor(t){super(`Bytes value \`${t}\` is not a valid boolean.`,{metaMessages:["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:"Bytes.InvalidBytesBooleanError"})}}class he extends A{constructor(t){super(`Value \`${typeof t=="object"?Nn(t):t}\` of type \`${typeof t}\` is an invalid Bytes value.`,{metaMessages:["Bytes values must be of type `Bytes`."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.InvalidBytesTypeError"})}}class ei extends A{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeOverflowError"})}}class ti extends A{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeExceedsPaddingSizeError"})}}const ni="0x608060405234801561001057600080fd5b5060405161018e38038061018e83398101604081905261002f91610124565b6000808351602085016000f59050803b61004857600080fd5b6000808351602085016000855af16040513d6000823e81610067573d81fd5b3d81f35b634e487b7160e01b600052604160045260246000fd5b600082601f83011261009257600080fd5b81516001600160401b038111156100ab576100ab61006b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156100d9576100d961006b565b6040528181528382016020018510156100f157600080fd5b60005b82811015610110576020818601810151838301820152016100f4565b506000918101602001919091529392505050565b6000806040838503121561013757600080fd5b82516001600160401b0381111561014d57600080fd5b61015985828601610081565b602085015190935090506001600160401b0381111561017757600080fd5b61018385828601610081565b915050925092905056fe",ri="0x608060405234801561001057600080fd5b506040516102c03803806102c083398101604081905261002f916101e6565b836001600160a01b03163b6000036100e457600080836001600160a01b03168360405161005c9190610270565b6000604051808303816000865af19150503d8060008114610099576040519150601f19603f3d011682016040523d82523d6000602084013e61009e565b606091505b50915091508115806100b857506001600160a01b0386163b155b156100e1578060405163101bb98d60e01b81526004016100d8919061028c565b60405180910390fd5b50505b6000808451602086016000885af16040513d6000823e81610103573d81fd5b3d81f35b80516001600160a01b038116811461011e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561015457818101518382015260200161013c565b50506000910152565b600082601f83011261016e57600080fd5b81516001600160401b0381111561018757610187610123565b604051601f8201601f19908116603f011681016001600160401b03811182821017156101b5576101b5610123565b6040528181528382016020018510156101cd57600080fd5b6101de826020830160208701610139565b949350505050565b600080600080608085870312156101fc57600080fd5b61020585610107565b60208601519094506001600160401b0381111561022157600080fd5b61022d8782880161015d565b93505061023c60408601610107565b60608601519092506001600160401b0381111561025857600080fd5b6102648782880161015d565b91505092959194509250565b60008251610282818460208701610139565b9190910192915050565b60208152600082518060208401526102ab816040850160208701610139565b601f01601f1916919091016040019291505056fe",Ko="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b815260206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b815260206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572",si="0x608060405234801561001057600080fd5b506115b9806100206000396000f3fe6080604052600436106100f35760003560e01c80634d2301cc1161008a578063a8b0574e11610059578063a8b0574e14610325578063bce38bd714610350578063c3077fa914610380578063ee82ac5e146103b2576100f3565b80634d2301cc1461026257806372425d9d1461029f57806382ad56cb146102ca57806386d516e8146102fa576100f3565b80633408e470116100c65780633408e470146101af578063399542e9146101da5780633e64a6961461020c57806342cbb15c14610237576100f3565b80630f28c97d146100f8578063174dea7114610123578063252dba421461015357806327e86d6e14610184575b600080fd5b34801561010457600080fd5b5061010d6103ef565b60405161011a9190610c0a565b60405180910390f35b61013d60048036038101906101389190610c94565b6103f7565b60405161014a9190610e94565b60405180910390f35b61016d60048036038101906101689190610f0c565b610615565b60405161017b92919061101b565b60405180910390f35b34801561019057600080fd5b506101996107ab565b6040516101a69190611064565b60405180910390f35b3480156101bb57600080fd5b506101c46107b7565b6040516101d19190610c0a565b60405180910390f35b6101f460048036038101906101ef91906110ab565b6107bf565b6040516102039392919061110b565b60405180910390f35b34801561021857600080fd5b506102216107e1565b60405161022e9190610c0a565b60405180910390f35b34801561024357600080fd5b5061024c6107e9565b6040516102599190610c0a565b60405180910390f35b34801561026e57600080fd5b50610289600480360381019061028491906111a7565b6107f1565b6040516102969190610c0a565b60405180910390f35b3480156102ab57600080fd5b506102b4610812565b6040516102c19190610c0a565b60405180910390f35b6102e460048036038101906102df919061122a565b61081a565b6040516102f19190610e94565b60405180910390f35b34801561030657600080fd5b5061030f6109e4565b60405161031c9190610c0a565b60405180910390f35b34801561033157600080fd5b5061033a6109ec565b6040516103479190611286565b60405180910390f35b61036a600480360381019061036591906110ab565b6109f4565b6040516103779190610e94565b60405180910390f35b61039a60048036038101906103959190610f0c565b610ba6565b6040516103a99392919061110b565b60405180910390f35b3480156103be57600080fd5b506103d960048036038101906103d491906112cd565b610bca565b6040516103e69190611064565b60405180910390f35b600042905090565b60606000808484905090508067ffffffffffffffff81111561041c5761041b6112fa565b5b60405190808252806020026020018201604052801561045557816020015b610442610bd5565b81526020019060019003908161043a5790505b5092503660005b828110156105c957600085828151811061047957610478611329565b5b6020026020010151905087878381811061049657610495611329565b5b90506020028101906104a89190611367565b925060008360400135905080860195508360000160208101906104cb91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16818580606001906104f2919061138f565b604051610500929190611431565b60006040518083038185875af1925050503d806000811461053d576040519150601f19603f3d011682016040523d82523d6000602084013e610542565b606091505b5083600001846020018290528215151515815250505081516020850135176105bc577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260846000fd5b826001019250505061045c565b5082341461060c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610603906114a7565b60405180910390fd5b50505092915050565b6000606043915060008484905090508067ffffffffffffffff81111561063e5761063d6112fa565b5b60405190808252806020026020018201604052801561067157816020015b606081526020019060019003908161065c5790505b5091503660005b828110156107a157600087878381811061069557610694611329565b5b90506020028101906106a791906114c7565b92508260000160208101906106bc91906111a7565b73ffffffffffffffffffffffffffffffffffffffff168380602001906106e2919061138f565b6040516106f0929190611431565b6000604051808303816000865af19150503d806000811461072d576040519150601f19603f3d011682016040523d82523d6000602084013e610732565b606091505b5086848151811061074657610745611329565b5b60200260200101819052819250505080610795576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161078c9061153b565b60405180910390fd5b81600101915050610678565b5050509250929050565b60006001430340905090565b600046905090565b6000806060439250434091506107d68686866109f4565b905093509350939050565b600048905090565b600043905090565b60008173ffffffffffffffffffffffffffffffffffffffff16319050919050565b600044905090565b606060008383905090508067ffffffffffffffff81111561083e5761083d6112fa565b5b60405190808252806020026020018201604052801561087757816020015b610864610bd5565b81526020019060019003908161085c5790505b5091503660005b828110156109db57600084828151811061089b5761089a611329565b5b602002602001015190508686838181106108b8576108b7611329565b5b90506020028101906108ca919061155b565b92508260000160208101906108df91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060400190610905919061138f565b604051610913929190611431565b6000604051808303816000865af19150503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b5082600001836020018290528215151515815250505080516020840135176109cf577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260646000fd5b8160010191505061087e565b50505092915050565b600045905090565b600041905090565b606060008383905090508067ffffffffffffffff811115610a1857610a176112fa565b5b604051908082528060200260200182016040528015610a5157816020015b610a3e610bd5565b815260200190600190039081610a365790505b5091503660005b82811015610b9c576000848281518110610a7557610a74611329565b5b60200260200101519050868683818110610a9257610a91611329565b5b9050602002810190610aa491906114c7565b9250826000016020810190610ab991906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060200190610adf919061138f565b604051610aed929190611431565b6000604051808303816000865af19150503d8060008114610b2a576040519150601f19603f3d011682016040523d82523d6000602084013e610b2f565b606091505b508260000183602001829052821515151581525050508715610b90578060000151610b8f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b869061153b565b60405180910390fd5b5b81600101915050610a58565b5050509392505050565b6000806060610bb7600186866107bf565b8093508194508295505050509250925092565b600081409050919050565b6040518060400160405280600015158152602001606081525090565b6000819050919050565b610c0481610bf1565b82525050565b6000602082019050610c1f6000830184610bfb565b92915050565b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008083601f840112610c5457610c53610c2f565b5b8235905067ffffffffffffffff811115610c7157610c70610c34565b5b602083019150836020820283011115610c8d57610c8c610c39565b5b9250929050565b60008060208385031215610cab57610caa610c25565b5b600083013567ffffffffffffffff811115610cc957610cc8610c2a565b5b610cd585828601610c3e565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60008115159050919050565b610d2281610d0d565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610d62578082015181840152602081019050610d47565b83811115610d71576000848401525b50505050565b6000601f19601f8301169050919050565b6000610d9382610d28565b610d9d8185610d33565b9350610dad818560208601610d44565b610db681610d77565b840191505092915050565b6000604083016000830151610dd96000860182610d19565b5060208301518482036020860152610df18282610d88565b9150508091505092915050565b6000610e0a8383610dc1565b905092915050565b6000602082019050919050565b6000610e2a82610ce1565b610e348185610cec565b935083602082028501610e4685610cfd565b8060005b85811015610e825784840389528151610e638582610dfe565b9450610e6e83610e12565b925060208a01995050600181019050610e4a565b50829750879550505050505092915050565b60006020820190508181036000830152610eae8184610e1f565b905092915050565b60008083601f840112610ecc57610ecb610c2f565b5b8235905067ffffffffffffffff811115610ee957610ee8610c34565b5b602083019150836020820283011115610f0557610f04610c39565b5b9250929050565b60008060208385031215610f2357610f22610c25565b5b600083013567ffffffffffffffff811115610f4157610f40610c2a565b5b610f4d85828601610eb6565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000610f918383610d88565b905092915050565b6000602082019050919050565b6000610fb182610f59565b610fbb8185610f64565b935083602082028501610fcd85610f75565b8060005b858110156110095784840389528151610fea8582610f85565b9450610ff583610f99565b925060208a01995050600181019050610fd1565b50829750879550505050505092915050565b60006040820190506110306000830185610bfb565b81810360208301526110428184610fa6565b90509392505050565b6000819050919050565b61105e8161104b565b82525050565b60006020820190506110796000830184611055565b92915050565b61108881610d0d565b811461109357600080fd5b50565b6000813590506110a58161107f565b92915050565b6000806000604084860312156110c4576110c3610c25565b5b60006110d286828701611096565b935050602084013567ffffffffffffffff8111156110f3576110f2610c2a565b5b6110ff86828701610eb6565b92509250509250925092565b60006060820190506111206000830186610bfb565b61112d6020830185611055565b818103604083015261113f8184610e1f565b9050949350505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061117482611149565b9050919050565b61118481611169565b811461118f57600080fd5b50565b6000813590506111a18161117b565b92915050565b6000602082840312156111bd576111bc610c25565b5b60006111cb84828501611192565b91505092915050565b60008083601f8401126111ea576111e9610c2f565b5b8235905067ffffffffffffffff81111561120757611206610c34565b5b60208301915083602082028301111561122357611222610c39565b5b9250929050565b6000806020838503121561124157611240610c25565b5b600083013567ffffffffffffffff81111561125f5761125e610c2a565b5b61126b858286016111d4565b92509250509250929050565b61128081611169565b82525050565b600060208201905061129b6000830184611277565b92915050565b6112aa81610bf1565b81146112b557600080fd5b50565b6000813590506112c7816112a1565b92915050565b6000602082840312156112e3576112e2610c25565b5b60006112f1848285016112b8565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b60008235600160800383360303811261138357611382611358565b5b80830191505092915050565b600080833560016020038436030381126113ac576113ab611358565b5b80840192508235915067ffffffffffffffff8211156113ce576113cd61135d565b5b6020830192506001820236038313156113ea576113e9611362565b5b509250929050565b600081905092915050565b82818337600083830152505050565b600061141883856113f2565b93506114258385846113fd565b82840190509392505050565b600061143e82848661140c565b91508190509392505050565b600082825260208201905092915050565b7f4d756c746963616c6c333a2076616c7565206d69736d61746368000000000000600082015250565b6000611491601a8361144a565b915061149c8261145b565b602082019050919050565b600060208201905081810360008301526114c081611484565b9050919050565b6000823560016040038336030381126114e3576114e2611358565b5b80830191505092915050565b7f4d756c746963616c6c333a2063616c6c206661696c6564000000000000000000600082015250565b600061152560178361144a565b9150611530826114ef565b602082019050919050565b6000602082019050818103600083015261155481611518565b9050919050565b60008235600160600383360303811261157757611576611358565b5b8083019150509291505056fea264697066735822122020c1bc9aacf8e4a6507193432a895a8e77094f45a1395583f07b24e860ef06cd64736f6c634300080c0033",Ne="/docs/contract/encodeDeployData";function Vn(e){const{abi:t,args:n,bytecode:r}=e;if(!n||n.length===0)return r;const s=t.find(o=>"type"in o&&o.type==="constructor");if(!s)throw new K0({docsPath:Ne});if(!("inputs"in s))throw new zt({docsPath:Ne});if(!s.inputs||s.inputs.length===0)throw new zt({docsPath:Ne});const i=In(s.inputs,n);return Be([r,i])}const _t="/docs/contract/encodeFunctionData";function ii(e){const{abi:t,args:n,functionName:r}=e;let s=t[0];if(r){const i=ft({abi:t,args:n,name:r});if(!i)throw new xe(r,{docsPath:_t});s=i}if(s.type!=="function")throw new xe(void 0,{docsPath:_t});return{abi:[s],functionName:st(Z(s))}}function oi(e){const{args:t}=e,{abi:n,functionName:r}=e.abi.length===1&&e.functionName?.startsWith("0x")?e:ii(e),s=n[0],i=r,o="inputs"in s&&s.inputs?In(s.inputs,t??[]):void 0;return Be([i,o??"0x"])}function ai(e,t){if(!N(e,{strict:!1}))throw new Q({address:e});if(!N(t,{strict:!1}))throw new Q({address:t});return e.toLowerCase()===t.toLowerCase()}function ci(e){const t=be(`0x${e.substring(4)}`).substring(26);return Ie(`0x${t}`)}async function fi({hash:e,signature:t}){const n=re(e)?e:me(e),{secp256k1:r}=await qt(async()=>{const{secp256k1:o}=await import("./secp256k1-DjijwK4n.js").then(a=>a.a);return{secp256k1:o}},__vite__mapDeps([0,1,2]));return`0x${(()=>{if(typeof t=="object"&&"r"in t&&"s"in t){const{r:f,s:u,v:d,yParity:b}=t,p=Number(b??d),m=Dt(p);return new r.Signature(ge(f),ge(u)).addRecoveryBit(m)}const o=re(t)?t:me(t);if(F(o)!==65)throw new Error("invalid signature length");const a=J(`0x${o.slice(130)}`),c=Dt(a);return r.Signature.fromCompact(o.substring(2,130)).addRecoveryBit(c)})().recoverPublicKey(n.substring(2)).toHex(!1)}`}function Dt(e){if(e===0||e===1)return e;if(e===27)return 0;if(e===28)return 1;throw new Error("Invalid yParityOrV value")}async function ui({hash:e,signature:t}){return ci(await fi({hash:e,signature:t}))}function di(e){const{chainId:t,nonce:n,to:r}=e,s=e.contractAddress??e.address,i=be(Be(["0x05",$0([t?P(t):"0x",s,n?P(n):"0x"])]));return r==="bytes"?X(i):i}async function li(e){const{authorization:t,signature:n}=e;return ui({hash:di(t),signature:n??t})}function k(e,t,n){const r=e[t.name];if(typeof r=="function")return r;const s=e[n];return typeof s=="function"?s:i=>t(e,i)}function bi(e){return{address:e.address,amount:H(e.amount),index:H(e.index),validatorIndex:H(e.validatorIndex)}}function pi(e){return{...typeof e.baseFeePerGas=="bigint"&&{baseFeePerGas:H(e.baseFeePerGas)},...typeof e.blobBaseFee=="bigint"&&{blobBaseFee:H(e.blobBaseFee)},...typeof e.feeRecipient=="string"&&{feeRecipient:e.feeRecipient},...typeof e.gasLimit=="bigint"&&{gasLimit:H(e.gasLimit)},...typeof e.number=="bigint"&&{number:H(e.number)},...typeof e.prevRandao=="bigint"&&{prevRandao:H(e.prevRandao)},...typeof e.time=="bigint"&&{time:H(e.time)},...e.withdrawals&&{withdrawals:e.withdrawals.map(bi)}}}const yi="0x82ad56cb",Re="/docs/contract/decodeFunctionResult";function hi(e){const{abi:t,args:n,functionName:r,data:s}=e;let i=t[0];if(r){const a=ft({abi:t,args:n,name:r});if(!a)throw new xe(r,{docsPath:Re});i=a}if(i.type!=="function")throw new xe(void 0,{docsPath:Re});if(!i.outputs)throw new X0(i.name,{docsPath:Re});const o=Te(i.outputs,s);if(o&&o.length>1)return o;if(o&&o.length===1)return o[0]}function Ht(e){if(!(!e||e.length===0))return e.reduce((t,{slot:n,value:r})=>{if(n.length!==66)throw new Bt({size:n.length,targetSize:66,type:"hex"});if(r.length!==66)throw new Bt({size:r.length,targetSize:66,type:"hex"});return t[n]=r,t},{})}function mi(e){const{balance:t,nonce:n,state:r,stateDiff:s,code:i}=e,o={};if(i!==void 0&&(o.code=i),t!==void 0&&(o.balance=P(t)),n!==void 0&&(o.nonce=P(n)),r!==void 0&&(o.state=Ht(r)),s!==void 0){if(o.state)throw new gs;o.stateDiff=Ht(s)}return o}function Kn(e){if(!e)return;const t={};for(const{address:n,...r}of e){if(!N(n,{strict:!1}))throw new Q({address:n});if(t[n])throw new ms({address:n});t[n]=mi(r)}return t}async function Wo(e,t){const{account:n=e.account,authorizationList:r,batch:s=!!e.batch?.multicall,blockNumber:i,blockTag:o=e.experimental_blockTag??"latest",accessList:a,blobs:c,blockOverrides:f,code:u,data:d,factory:b,factoryData:p,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:g,value:$,stateOverride:S,...R}=t,B=n?ee(n):void 0;if(u&&(b||p))throw new l("Cannot provide both `code` & `factory`/`factoryData` as parameters.");if(u&&g)throw new l("Cannot provide both `code` & `to` as parameters.");const T=u&&d,y=b&&p&&g&&d,O=T||y,L=T?Wn({code:u,data:d}):y?xi({data:d,factory:b,factoryData:p,to:g}):d;try{Se(t);const E=(typeof i=="bigint"?P(i):void 0)||o,G=f?pi(f):void 0,q=Kn(S),pe=e.chain?.formatters?.transactionRequest?.format,ke=(pe||Ae)({...dt(R,{format:pe}),accessList:a,account:B,authorizationList:r,blobs:c,data:L,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:O?void 0:g,value:$},"call");if(s&&gi({request:ke})&&!q&&!G)try{return await wi(e,{...ke,blockNumber:i,blockTag:o})}catch(W){if(!(W instanceof an)&&!(W instanceof De))throw W}const Xn=(()=>{const W=[ke,E];return q&&G?[...W,q,G]:q?[...W,q]:G?[...W,{},G]:W})(),mt=await e.request({method:"eth_call",params:Xn});return mt==="0x"?{data:void 0}:{data:mt}}catch(U){const E=Pi(U),{offchainLookup:G,offchainLookupSignature:q}=await qt(async()=>{const{offchainLookup:pe,offchainLookupSignature:ht}=await import("./ccip-ByLIoOC6.js");return{offchainLookup:pe,offchainLookupSignature:ht}},__vite__mapDeps([3,4,1,5,6,7,8]));if(e.ccipRead!==!1&&E?.slice(0,10)===q&&g)return{data:await G(e,{data:E,to:g})};throw O&&E?.slice(0,10)==="0x101bb98d"?new Es({factory:b}):As(U,{...t,account:B,chain:e.chain})}}function gi({request:e}){const{data:t,to:n,...r}=e;return!(!t||t.startsWith(yi)||!n||Object.values(r).filter(s=>typeof s<"u").length>0)}async function wi(e,t){const{batchSize:n=1024,deployless:r=!1,wait:s=0}=typeof e.batch?.multicall=="object"?e.batch.multicall:{},{blockNumber:i,blockTag:o=e.experimental_blockTag??"latest",data:a,to:c}=t,f=(()=>{if(r)return null;if(t.multicallAddress)return t.multicallAddress;if(e.chain)return U0({blockNumber:i,chain:e.chain,contract:"multicall3"});throw new an})(),d=(typeof i=="bigint"?P(i):void 0)||o,{schedule:b}=f0({id:`${e.uid}.${d}`,wait:s,shouldSplitBatch(w){return w.reduce((h,{data:v})=>h+(v.length-2),0)>n*2},fn:async w=>{const I=w.map(x=>({allowFailure:!0,callData:x.data,target:x.to})),h=oi({abi:It,args:[I],functionName:"aggregate3"}),v=await e.request({method:"eth_call",params:[{...f===null?{data:Wn({code:si,data:h})}:{to:f,data:h}},d]});return hi({abi:It,args:[I],functionName:"aggregate3",data:v||"0x"})}}),[{returnData:p,success:m}]=await b({data:a,to:c});if(!m)throw new Sn({data:p});return p==="0x"?{data:void 0}:{data:p}}function Wn(e){const{code:t,data:n}=e;return Vn({abi:An(["constructor(bytes, bytes)"]),bytecode:ni,args:[t,n]})}function xi(e){const{data:t,factory:n,factoryData:r,to:s}=e;return Vn({abi:An(["constructor(address, bytes, address, bytes)"]),bytecode:ri,args:[s,t,n,r]})}function Pi(e){if(!(e instanceof l))return;const t=e.walk();return typeof t?.data=="object"?t.data?.data:t.data}const vi=3;function Zo(e,{abi:t,address:n,args:r,docsPath:s,functionName:i,sender:o}){const a=e instanceof Sn?e:e instanceof l?e.walk(m=>"data"in m)||e.walk():{},{code:c,data:f,details:u,message:d,shortMessage:b}=a,p=e instanceof rt?new $s({functionName:i,cause:e}):[vi,u0.code].includes(c)&&(f||u||d||b)||c===d0.code&&u==="execution reverted"&&f?new vs({abi:t,data:typeof f=="object"?f.data:f,functionName:i,message:a instanceof l0?u:b??d,cause:e}):e;return new Ps(p,{abi:t,args:r,contractAddress:n,docsPath:s,functionName:i,sender:o})}function $i(e,{docsPath:t,...n}){const r=(()=>{const s=ut(e,n);return s instanceof $e?e:s})();return new I0(r,{docsPath:t,...n})}async function Zn(e){const t=await e.request({method:"eth_chainId"},{dedupe:!0});return J(t)}class qn extends l{constructor(){super("`baseFeeMultiplier` must be greater than 1.",{name:"BaseFeeScalarError"})}}class yt extends l{constructor(){super("Chain does not support EIP-1559 fees.",{name:"Eip1559FeesNotSupportedError"})}}class Ei extends l{constructor({maxPriorityFeePerGas:t}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${j(t)} gwei).`,{name:"MaxFeePerGasTooLowError"})}}class Ai extends l{constructor({blockHash:t,blockNumber:n}){let r="Block";t&&(r=`Block at hash "${t}"`),n&&(r=`Block at number "${n}"`),super(`${r} could not be found.`,{name:"BlockNotFoundError"})}}async function de(e,{blockHash:t,blockNumber:n,blockTag:r=e.experimental_blockTag??"latest",includeTransactions:s}={}){const i=s??!1,o=n!==void 0?P(n):void 0;let a=null;if(t?a=await e.request({method:"eth_getBlockByHash",params:[t,i]},{dedupe:!0}):a=await e.request({method:"eth_getBlockByNumber",params:[o||r,i]},{dedupe:!!o}),!a)throw new Ai({blockHash:t,blockNumber:n});return(e.chain?.formatters?.block?.format||Jt)(a,"getBlock")}async function Yn(e){const t=await e.request({method:"eth_gasPrice"});return BigInt(t)}async function qo(e,t){return Jn(e,t)}async function Jn(e,t){const{block:n,chain:r=e.chain,request:s}=t||{};try{const i=r?.fees?.maxPriorityFeePerGas??r?.fees?.defaultPriorityFee;if(typeof i=="function"){const a=n||await k(e,de,"getBlock")({}),c=await i({block:a,client:e,request:s});if(c===null)throw new Error;return c}if(typeof i<"u")return i;const o=await e.request({method:"eth_maxPriorityFeePerGas"});return ge(o)}catch{const[i,o]=await Promise.all([n?Promise.resolve(n):k(e,de,"getBlock")({}),k(e,Yn,"getGasPrice")({})]);if(typeof i.baseFeePerGas!="bigint")throw new yt;const a=o-i.baseFeePerGas;return a<0n?0n:a}}async function Yo(e,t){return Ye(e,t)}async function Ye(e,t){const{block:n,chain:r=e.chain,request:s,type:i="eip1559"}=t||{},o=await(async()=>typeof r?.fees?.baseFeeMultiplier=="function"?r.fees.baseFeeMultiplier({block:n,client:e,request:s}):r?.fees?.baseFeeMultiplier??1.2)();if(o<1)throw new qn;const c=10**(o.toString().split(".")[1]?.length??0),f=b=>b*BigInt(Math.ceil(o*c))/BigInt(c),u=n||await k(e,de,"getBlock")({});if(typeof r?.fees?.estimateFeesPerGas=="function"){const b=await r.fees.estimateFeesPerGas({block:n,client:e,multiply:f,request:s,type:i});if(b!==null)return b}if(i==="eip1559"){if(typeof u.baseFeePerGas!="bigint")throw new yt;const b=typeof s?.maxPriorityFeePerGas=="bigint"?s.maxPriorityFeePerGas:await Jn(e,{block:u,chain:r,request:s}),p=f(u.baseFeePerGas);return{maxFeePerGas:s?.maxFeePerGas??p+b,maxPriorityFeePerGas:b}}return{gasPrice:s?.gasPrice??f(await k(e,Yn,"getGasPrice")({}))}}class Bi extends l{constructor(t,{account:n,docsPath:r,chain:s,data:i,gas:o,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:f,nonce:u,to:d,value:b}){const p=le({from:n?.address,to:d,value:typeof b<"u"&&`${tt(b)} ${s?.nativeCurrency?.symbol||"ETH"}`,data:i,gas:o,gasPrice:typeof a<"u"&&`${j(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${j(c)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${j(f)} gwei`,nonce:u});super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Estimate Gas Arguments:",p].filter(Boolean),name:"EstimateGasExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}function Ii(e,{docsPath:t,...n}){const r=(()=>{const s=ut(e,n);return s instanceof $e?e:s})();return new Bi(r,{docsPath:t,...n})}async function Fi(e,t){const{account:n=e.account,prepare:r=!0}=t,s=n?ee(n):void 0,i=(()=>{if(Array.isArray(r))return r;if(s?.type!=="local")return["blobVersionedHashes"]})();try{const o=await(async()=>{if(t.to)return t.to;if(t.authorizationList&&t.authorizationList.length>0)return await li({authorization:t.authorizationList[0]}).catch(()=>{throw new l("`to` is required. Could not infer from `authorizationList`")})})(),{accessList:a,authorizationList:c,blobs:f,blobVersionedHashes:u,blockNumber:d,blockTag:b,data:p,gas:m,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,value:g,stateOverride:$,...S}=r?await ki(e,{...t,parameters:i,to:o}):t;if(m&&t.gas!==m)return m;const B=(typeof d=="bigint"?P(d):void 0)||b,T=Kn($);Se(t);const y=e.chain?.formatters?.transactionRequest?.format,L=(y||Ae)({...dt(S,{format:y}),account:s,accessList:a,authorizationList:c,blobs:f,blobVersionedHashes:u,data:p,gasPrice:w,maxFeePerBlobGas:I,maxFeePerGas:h,maxPriorityFeePerGas:v,nonce:x,to:o,value:g},"estimateGas");return BigInt(await e.request({method:"eth_estimateGas",params:T?[L,B??e.experimental_blockTag??"latest",T]:B?[L,B]:[L]}))}catch(o){throw Ii(o,{...t,account:s,chain:e.chain})}}async function Ti(e,{address:t,blockTag:n="latest",blockNumber:r}){const s=await e.request({method:"eth_getTransactionCount",params:[t,typeof r=="bigint"?P(r):n]},{dedupe:!!r});return J(s)}async function Si(e,t){const{account:n=e.account,accessList:r,authorizationList:s,chain:i=e.chain,blobVersionedHashes:o,blobs:a,data:c,gas:f,gasPrice:u,maxFeePerBlobGas:d,maxFeePerGas:b,maxPriorityFeePerGas:p,nonce:m,nonceManager:w,to:I,type:h,value:v,...x}=t,g=await(async()=>{if(!n||!w||typeof m<"u")return m;const B=ee(n),T=i?i.id:await k(e,Zn,"getChainId")({});return await w.consume({address:B.address,chainId:T,client:e})})();Se(t);const $=i?.formatters?.transactionRequest?.format,R=($||Ae)({...dt(x,{format:$}),account:n?ee(n):void 0,accessList:r,authorizationList:s,blobs:a,blobVersionedHashes:o,data:c,gas:f,gasPrice:u,maxFeePerBlobGas:d,maxFeePerGas:b,maxPriorityFeePerGas:p,nonce:g,to:I,type:h,value:v},"fillTransaction");try{const B=await e.request({method:"eth_fillTransaction",params:[R]}),y=(i?.formatters?.transaction?.format||Qe)(B.tx);delete y.blockHash,delete y.blockNumber,delete y.r,delete y.s,delete y.transactionIndex,delete y.v,delete y.yParity,y.data=y.input,y.gas&&(y.gas=t.gas??y.gas),y.gasPrice&&(y.gasPrice=t.gasPrice??y.gasPrice),y.maxFeePerBlobGas&&(y.maxFeePerBlobGas=t.maxFeePerBlobGas??y.maxFeePerBlobGas),y.maxFeePerGas&&(y.maxFeePerGas=t.maxFeePerGas??y.maxFeePerGas),y.maxPriorityFeePerGas&&(y.maxPriorityFeePerGas=t.maxPriorityFeePerGas??y.maxPriorityFeePerGas),typeof y.nonce<"u"&&(y.nonce=t.nonce??y.nonce);const O=await(async()=>{if(typeof i?.fees?.baseFeeMultiplier=="function"){const G=await k(e,de,"getBlock")({});return i.fees.baseFeeMultiplier({block:G,client:e,request:t})}return i?.fees?.baseFeeMultiplier??1.2})();if(O<1)throw new qn;const U=10**(O.toString().split(".")[1]?.length??0),E=G=>G*BigInt(Math.ceil(O*U))/BigInt(U);return y.feePayerSignature||(y.maxFeePerGas&&!t.maxFeePerGas&&(y.maxFeePerGas=E(y.maxFeePerGas)),y.gasPrice&&!t.gasPrice&&(y.gasPrice=E(y.gasPrice))),{raw:B.raw,transaction:{from:R.from,...y},...B.capabilities?{capabilities:B.capabilities}:{}}}catch(B){throw $i(B,{...t,chain:e.chain})}}const zi=["blobVersionedHashes","chainId","fees","gas","nonce","type"],Vt=new Map,Le=new Je(128);async function ki(e,t){let n=t;n.account??=e.account,n.parameters??=zi;const{account:r,chain:s=e.chain,nonceManager:i,parameters:o}=n,a=(()=>{if(typeof s?.prepareTransactionRequest=="function")return{fn:s.prepareTransactionRequest,runAt:["beforeFillTransaction"]};if(Array.isArray(s?.prepareTransactionRequest))return{fn:s.prepareTransactionRequest[0],runAt:s.prepareTransactionRequest[1].runAt}})();let c;async function f(){return c||(typeof n.chainId<"u"?n.chainId:s?s.id:(c=await k(e,Zn,"getChainId")({}),c))}const u=r&&ee(r);let d=n.nonce;if(o.includes("nonce")&&typeof d>"u"&&u&&i){const g=await f();d=await i.consume({address:u.address,chainId:g,client:e})}a?.fn&&a.runAt?.includes("beforeFillTransaction")&&(n=await a.fn({...n,chain:s},{phase:"beforeFillTransaction"}),d??=n.nonce);const p=((o.includes("blobVersionedHashes")||o.includes("sidecars"))&&n.kzg&&n.blobs||Le.get(e.uid)===!1||!["fees","gas"].some($=>o.includes($))?!1:!!(o.includes("chainId")&&typeof n.chainId!="number"||o.includes("nonce")&&typeof d!="number"||o.includes("fees")&&typeof n.gasPrice!="bigint"&&(typeof n.maxFeePerGas!="bigint"||typeof n.maxPriorityFeePerGas!="bigint")||o.includes("gas")&&typeof n.gas!="bigint"))?await k(e,Si,"fillTransaction")({...n,nonce:d}).then(g=>{const{chainId:$,from:S,gas:R,gasPrice:B,nonce:T,maxFeePerBlobGas:y,maxFeePerGas:O,maxPriorityFeePerGas:L,type:U,...E}=g.transaction;return Le.set(e.uid,!0),{...n,...S?{from:S}:{},...U&&!n.type?{type:U}:{},...typeof $<"u"?{chainId:$}:{},...typeof R<"u"?{gas:R}:{},...typeof B<"u"?{gasPrice:B}:{},...typeof T<"u"?{nonce:T}:{},...typeof y<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerBlobGas:y}:{},...typeof O<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerGas:O}:{},...typeof L<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxPriorityFeePerGas:L}:{},..."nonceKey"in E&&typeof E.nonceKey<"u"?{nonceKey:E.nonceKey}:{},..."keyAuthorization"in E&&typeof E.keyAuthorization<"u"&&E.keyAuthorization!==null&&!("keyAuthorization"in n)?{keyAuthorization:E.keyAuthorization}:{},..."feePayerSignature"in E&&typeof E.feePayerSignature<"u"&&E.feePayerSignature!==null?{feePayerSignature:E.feePayerSignature}:{},..."feeToken"in E&&typeof E.feeToken<"u"&&E.feeToken!==null&&!("feeToken"in n)?{feeToken:E.feeToken}:{},...g.capabilities?{_capabilities:g.capabilities}:{}}}).catch(g=>{const $=g;if($.name!=="TransactionExecutionError")return n;if($.walk?.(B=>B.name==="ExecutionRevertedError"))throw g;return $.walk?.(B=>{const T=B;return T.name==="MethodNotFoundRpcError"||T.name==="MethodNotSupportedRpcError"||T.message?.includes("eth_fillTransaction is not available")})&&Le.set(e.uid,!1),n}):n;d??=p.nonce,n={...p,...u?{from:u?.address}:{},...typeof d<"u"?{nonce:d}:{}};const{blobs:m,gas:w,kzg:I,type:h}=n;a?.fn&&a.runAt?.includes("beforeFillParameters")&&(n=await a.fn({...n,chain:s},{phase:"beforeFillParameters"}));let v;async function x(){return v||(v=await k(e,de,"getBlock")({blockTag:"latest"}),v)}if(o.includes("nonce")&&typeof d>"u"&&u&&!i&&(n.nonce=await k(e,Ti,"getTransactionCount")({address:u.address,blockTag:"pending"})),(o.includes("blobVersionedHashes")||o.includes("sidecars"))&&m&&I){const g=nn({blobs:m,kzg:I});if(o.includes("blobVersionedHashes")){const $=S0({commitments:g,to:"hex"});n.blobVersionedHashes=$}if(o.includes("sidecars")){const $=rn({blobs:m,commitments:g,kzg:I}),S=C0({blobs:m,commitments:g,proofs:$,to:"hex"});n.sidecars=S}}if(o.includes("chainId")&&(n.chainId=await f()),(o.includes("fees")||o.includes("type"))&&typeof h>"u")try{n.type=L0(n)}catch{let g=Vt.get(e.uid);typeof g>"u"&&(g=typeof(await x())?.baseFeePerGas=="bigint",Vt.set(e.uid,g)),n.type=g?"eip1559":"legacy"}if(o.includes("fees"))if(n.type!=="legacy"&&n.type!=="eip2930"){if(typeof n.maxFeePerGas>"u"||typeof n.maxPriorityFeePerGas>"u"){const g=await x(),{maxFeePerGas:$,maxPriorityFeePerGas:S}=await Ye(e,{block:g,chain:s,request:n});if(typeof n.maxPriorityFeePerGas>"u"&&n.maxFeePerGas&&n.maxFeePerGas<S)throw new Ei({maxPriorityFeePerGas:S});n.maxPriorityFeePerGas=S,n.maxFeePerGas=$}}else{if(typeof n.maxFeePerGas<"u"||typeof n.maxPriorityFeePerGas<"u")throw new yt;if(typeof n.gasPrice>"u"){const g=await x(),{gasPrice:$}=await Ye(e,{block:g,chain:s,request:n,type:"legacy"});n.gasPrice=$}}return o.includes("gas")&&typeof w>"u"&&(n.gas=await k(e,Fi,"estimateGas")({...n,account:u,prepare:u?.type==="local"?[]:["blobVersionedHashes"]})),a?.fn&&a.runAt?.includes("afterFillParameters")&&(n=await a.fn({...n,chain:s},{phase:"afterFillParameters"})),Se(n),delete n.parameters,n}async function Jo(e,{serializedTransaction:t}){return e.request({method:"eth_sendRawTransaction",params:[t]},{retryCount:0})}const Kt="/docs/contract/decodeEventLog";function Wt(e){const{abi:t,data:n,strict:r,topics:s}=e,i=r??!0,[o,...a]=s;if(!o)throw new Y0({docsPath:Kt});const c=t.find(h=>h.type==="event"&&o===ct(Z(h)));if(!(c&&"name"in c)||c.type!=="event")throw new J0(o,{docsPath:Kt});const{name:f,inputs:u}=c,d=u?.some(h=>!("name"in h&&h.name)),b=d?[]:{},p=u.map((h,v)=>[h,v]).filter(([h])=>"indexed"in h&&h.indexed),m=[];for(let h=0;h<p.length;h++){const[v,x]=p[h],g=a[h];if(!g){if(i)throw new er({abiItem:c,param:v});m.push([v,x]);continue}b[d?x:v.name||x]=Mi({param:v,value:g})}const w=u.filter(h=>!("indexed"in h&&h.indexed)),I=i?w:[...m.map(([h])=>h),...w];if(I.length>0){if(n&&n!=="0x")try{const h=Te(I,n);if(h){let v=0;if(!i)for(const[x,g]of m)b[d?g:x.name||g]=h[v++];if(d)for(let x=0;x<u.length;x++)b[x]===void 0&&v<h.length&&(b[x]=h[v++]);else for(let x=0;x<w.length;x++)b[w[x].name]=h[v++]}}catch(h){if(i)throw h instanceof dn||h instanceof Qt?new kt({abiItem:c,data:n,params:I,size:F(n)}):h}else if(i)throw new kt({abiItem:c,data:"0x",params:I,size:0})}return{eventName:f,args:Object.values(b).length>0?b:void 0}}function Mi({param:e,value:t}){return e.type==="string"||e.type==="bytes"||e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/)?t:(Te([e],t)||[])[0]}function Xo(e){const{abi:t,args:n,logs:r,strict:s=!0}=e,i=(()=>{if(e.eventName)return Array.isArray(e.eventName)?e.eventName:[e.eventName]})(),o=t.filter(a=>a.type==="event").map(a=>({abi:a,selector:ct(a)}));return r.map(a=>{const c=typeof a.blockNumber=="string"?Xt(a):a,f=o.filter(b=>c.topics[0]===b.selector);if(f.length===0)return null;let u,d;for(const b of f)try{u=Wt({...c,abi:[b.abi],strict:!0}),d=b;break}catch{}if(!u&&!s){d=f[0];try{u=Wt({data:c.data,topics:c.topics,abi:[d.abi],strict:!1})}catch{const b=d.abi.inputs?.some(p=>!("name"in p&&p.name));return{...c,args:b?[]:{},eventName:d.abi.name}}}return!u||!d||i&&!i.includes(u.eventName)||!Gi({args:u.args,inputs:d.abi.inputs,matchArgs:n})?null:{...u,...c}}).filter(Boolean)}function Gi(e){const{args:t,inputs:n,matchArgs:r}=e;if(!r)return!0;if(!t)return!1;function s(i,o,a){try{return i.type==="address"?ai(o,a):i.type==="string"||i.type==="bytes"?be(Pe(o))===a:o===a}catch{return!1}}return Array.isArray(t)&&Array.isArray(r)?r.every((i,o)=>{if(i==null)return!0;const a=n[o];return a?(Array.isArray(i)?i:[i]).some(f=>s(a,f,t[o])):!1}):typeof t=="object"&&!Array.isArray(t)&&typeof r=="object"&&!Array.isArray(r)?Object.entries(r).every(([i,o])=>{if(o==null)return!0;const a=n.find(f=>f.name===i);return a?(Array.isArray(o)?o:[o]).some(f=>s(a,f,t[i])):!1}):!1}export{Sn as $,K0 as A,qn as B,xs as C,Es as D,kt as E,er as F,yt as G,Bi as H,nr as I,tr as J,ao as K,co as L,Tr as M,Q as N,rr as O,Ji as P,sr as Q,Fr as R,Di as S,Ir as T,Ar as U,Mr as V,B0 as W,ae as X,Hi as Y,zr as Z,Ei as _,zt as a,we as a$,Br as a0,gs as a1,I0 as a2,Vi as a3,Ki as a4,Sr as a5,$r as a6,io as a7,Zi as a8,Qi as a9,Ko as aA,Jt as aB,tt as aC,Xt as aD,Qe as aE,h0 as aF,Ae as aG,ft as aH,Xi as aI,U0 as aJ,Zo as aK,ct as aL,Yr as aM,st as aN,L0 as aO,N as aP,ai as aQ,be as aR,_i as aS,w0 as aT,An as aU,Xo as aV,ii as aW,ui as aX,fi as aY,m0 as aZ,F0 as a_,Se as aa,nn as ab,rn as ac,Jr as ad,Xr as ae,V as af,Qr as ag,Ie as ah,T0 as ai,S0 as aj,se as ak,x0 as al,Be as am,Te as an,hs as ao,Wt as ap,hi as aq,Ri as ar,Ni as as,Li as at,Ui as au,ni as av,ri as aw,In as ax,Vn as ay,oi as az,dn as b,So as b$,un as b0,R0 as b1,C0 as b2,G0 as b3,Bn as b4,$0 as b5,Yt as b6,Wo as b7,li as b8,k as b9,$o as bA,es as bB,uo as bC,de as bD,M0 as bE,qi as bF,z0 as bG,Yi as bH,Cr as bI,Wr as bJ,xn as bK,C as bL,te as bM,oo as bN,jo as bO,ie as bP,ko as bQ,oe as bR,Vo as bS,Eo as bT,H as bU,To as bV,A as bW,Ao as bX,Nn as bY,Dn as bZ,No as b_,Zn as ba,dt as bb,ki as bc,zi as bd,Jo as be,$i as bf,ee as bg,Z as bh,D0 as bi,yo as bj,po as bk,ho as bl,Is as bm,xo as bn,vo as bo,wo as bp,Fs as bq,go as br,mo as bs,Gn as bt,bt as bu,Po as bv,lo as bw,Mn as bx,Ss as by,bo as bz,rt as c,Io as c0,cr as c1,Do as c2,Lo as c3,_o as c4,Uo as c5,Ho as c6,Xs as c7,Rn as c8,Bo as c9,Fo as cA,Ds as ca,Ln as cb,Ut as cc,fe as cd,_s as ce,si as cf,Fi as cg,Wi as ch,fo as ci,y0 as cj,As as ck,pi as cl,Kn as cm,ut as cn,Ti as co,Si as cp,qo as cq,Yn as cr,Yo as cs,le as ct,Mo as cu,Ro as cv,Oo as cw,Un as cx,zo as cy,Us as cz,W0 as d,Z0 as e,q0 as f,eo as g,to as h,ln as i,no as j,Y0 as k,J0 as l,xe as m,X0 as n,ro as o,ms as p,Ai as q,so as r,De as s,O0 as t,j0 as u,kr as v,an as w,Ps as x,vs as y,$s as z};
@@ -1,2 +1,2 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/getNFT-HMkoXD7L.js","assets/index-Cu4ZjLNb.js","assets/index-829Uxa3Y.css","assets/fetchTokenMetadata-BaJXN6RH.js","assets/uint8-array-DZKEMhA1.js","assets/signing-gNn6SJWz.js","assets/utils-h8VUSGPW.js","assets/thirdweb-Bx5V_C1s.js","assets/wait-for-tx-receipt-5pSBMNe2.js","assets/transactionReceipt-BqEjx5q-.js","assets/sleep-mAKpSMLY.js","assets/eth_estimateGas-DKKwG-Ue.js","assets/eth_getStorageAt-SbVMAQY-.js","assets/eth_getTransactionCount-qv0oO1Md.js","assets/decimals-DR6jraOc.js","assets/decimals-8g2-fBFa.js","assets/zora-sepolia-D6mjhB5j.js","assets/send-batch-transaction-D79MC_wr.js","assets/getNFT-Drn4rxrk.js","assets/totalSupply-O-VFDoRO.js","assets/detectExtension-yvI5WWZb.js"])))=>i.map(i=>d[i]);
2
- import{_ as w}from"./index-Cu4ZjLNb.js";import{a as m}from"./utils-h8VUSGPW.js";import{i as h,b as p}from"./signing-gNn6SJWz.js";function g(t,e){switch(e.type){case"ERC721":return{chainId:e.chainId,id:e.tokenId,metadata:t,owner:e?.owner??null,tokenAddress:e.tokenAddress,tokenURI:e.tokenUri,type:e.type};case"ERC1155":return{chainId:e.chainId,id:e.tokenId,metadata:t,owner:e?.owner??null,supply:e.supply,tokenAddress:e.tokenAddress,tokenURI:e.tokenUri,type:e.type};default:throw new Error("Invalid NFT type")}}async function y(t){let e=t.uri;e.startsWith("did:nft:")&&(e=e.replace("did:nft:","").replace(/_/g,"/"));const[l="",u="",r=""]=e.split("/"),[a,i]=l.split(":"),[s,n]=u.split(":");if(!a||a.toLowerCase()!=="eip155")throw new Error(`Invalid EIP namespace, expected EIP155, got: "${a}"`);if(!i)throw new Error("Chain ID not found");if(!n||!h(n))throw new Error("Contract address not found");if(!r)throw new Error("Token ID not found");const f=m(Number(i)),o=p({address:n,chain:f,client:t.client});switch(s){case"erc721":{const{getNFT:c}=await w(async()=>{const{getNFT:d}=await import("./getNFT-HMkoXD7L.js");return{getNFT:d}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17]));return(await c({contract:o,tokenId:BigInt(r)})).metadata.image??null}case"erc1155":{const{getNFT:c}=await w(async()=>{const{getNFT:d}=await import("./getNFT-Drn4rxrk.js");return{getNFT:d}},__vite__mapDeps([18,7,6,1,2,5,8,9,10,11,12,13,14,15,16,17,3,4,19,20]));return(await c({contract:o,tokenId:BigInt(r)})).metadata.image??null}default:throw new Error(`Invalid ERC namespace, expected ERC721 or ERC1155, got: "${s}"`)}}export{g as parseNFT,y as parseNftUri};
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/getNFT-CkUzlgLt.js","assets/index-a-a2MqTK.js","assets/index-BXaGpRRD.css","assets/fetchTokenMetadata-DZl1qOjc.js","assets/uint8-array-DZKEMhA1.js","assets/signing-lyeTiv6v.js","assets/utils-Cj9H0gW-.js","assets/thirdweb-Dqspr20y.js","assets/wait-for-tx-receipt-CN6uf72q.js","assets/transactionReceipt-DIRSM0gr.js","assets/sleep-mAKpSMLY.js","assets/eth_estimateGas-BmOR31h-.js","assets/eth_getStorageAt-7xIaoYHZ.js","assets/eth_getTransactionCount-DrnF23O4.js","assets/decimals-DnutWGXb.js","assets/decimals-DNQm_OiO.js","assets/zora-sepolia-CS_uSNQg.js","assets/send-batch-transaction-PvOdFKh_.js","assets/getNFT-DIu1VS3y.js","assets/totalSupply-C4K7aOAr.js","assets/detectExtension-BfmE7TOs.js"])))=>i.map(i=>d[i]);
2
+ import{_ as w}from"./index-a-a2MqTK.js";import{a as m}from"./utils-Cj9H0gW-.js";import{i as h,b as p}from"./signing-lyeTiv6v.js";function g(t,e){switch(e.type){case"ERC721":return{chainId:e.chainId,id:e.tokenId,metadata:t,owner:e?.owner??null,tokenAddress:e.tokenAddress,tokenURI:e.tokenUri,type:e.type};case"ERC1155":return{chainId:e.chainId,id:e.tokenId,metadata:t,owner:e?.owner??null,supply:e.supply,tokenAddress:e.tokenAddress,tokenURI:e.tokenUri,type:e.type};default:throw new Error("Invalid NFT type")}}async function y(t){let e=t.uri;e.startsWith("did:nft:")&&(e=e.replace("did:nft:","").replace(/_/g,"/"));const[l="",u="",r=""]=e.split("/"),[a,i]=l.split(":"),[s,n]=u.split(":");if(!a||a.toLowerCase()!=="eip155")throw new Error(`Invalid EIP namespace, expected EIP155, got: "${a}"`);if(!i)throw new Error("Chain ID not found");if(!n||!h(n))throw new Error("Contract address not found");if(!r)throw new Error("Token ID not found");const f=m(Number(i)),o=p({address:n,chain:f,client:t.client});switch(s){case"erc721":{const{getNFT:c}=await w(async()=>{const{getNFT:d}=await import("./getNFT-CkUzlgLt.js");return{getNFT:d}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17]));return(await c({contract:o,tokenId:BigInt(r)})).metadata.image??null}case"erc1155":{const{getNFT:c}=await w(async()=>{const{getNFT:d}=await import("./getNFT-DIu1VS3y.js");return{getNFT:d}},__vite__mapDeps([18,7,6,1,2,5,8,9,10,11,12,13,14,15,16,17,3,4,19,20]));return(await c({contract:o,tokenId:BigInt(r)})).metadata.image??null}default:throw new Error(`Invalid ERC namespace, expected ERC721 or ERC1155, got: "${s}"`)}}export{g as parseNFT,y as parseNftUri};