@dcl/account-site 6.4.3-23021761892.commit-95cb21d → 6.5.0

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 (170) hide show
  1. package/assets/{CoinbaseSDKConnection-0Z70hEdE.js → CoinbaseSDKConnection-CiR0PwqB.js} +1 -1
  2. package/assets/{ConstantsUtil-IfUBwsBT.js → ConstantsUtil-DcNlA0yI.js} +1 -1
  3. package/assets/{ExchangeController-DePb1GFL.js → ExchangeController-Cf_wJ3Nl.js} +1 -1
  4. package/assets/{HelpersUtil-C84DgUhp.js → HelpersUtil-BWBhmsgN.js} +1 -1
  5. package/assets/{InAppWalletConnectUI-DUi7oMdq.js → InAppWalletConnectUI-BuAEUS1U.js} +1 -1
  6. package/assets/{NetworkUtil-Bgt2ITuu.js → NetworkUtil-gfyNTzc8.js} +1 -1
  7. package/assets/{QRCodeRenderer-dTVEF8IB.js → QRCodeRenderer-D_FB6yym.js} +1 -1
  8. package/assets/{SwapController-UYZQN7tl.js → SwapController-BbBIyQny.js} +1 -1
  9. package/assets/{ThirdwebWalletManager-Dz4m7qO_.js → ThirdwebWalletManager-sHuZxDtE.js} +14 -14
  10. package/assets/{biconomy-LixggspG.js → biconomy-Bhd5Lp75.js} +1 -1
  11. package/assets/{biconomy-C4KjX8zf.js → biconomy-C-un_Gyi.js} +1 -1
  12. package/assets/{ccip-CPEo6pFI.js → ccip-B5UMVfiU.js} +1 -1
  13. package/assets/{ccip-BM_vcm7R.js → ccip-DUxiFaFf.js} +1 -1
  14. package/assets/{ccip-Dar4BgqF.js → ccip-WNZOoXTS.js} +1 -1
  15. package/assets/{chains-BDyPLjuo.js → chains-CgHd4aCT.js} +1 -1
  16. package/assets/{common-CqAIBo6K.js → common-DodZPN6N.js} +1 -1
  17. package/assets/{common-Q4hcJSiz.js → common-XptO6oZI.js} +1 -1
  18. package/assets/concat-hex-CwvcDfZD.js +1 -0
  19. package/assets/{controller-Czxst7w9.js → controller-CQRFcmyn.js} +2 -2
  20. package/assets/{controller-CcgJ61Ea.js → controller-CoRW2p_u.js} +2 -2
  21. package/assets/{data-capture-BuKEn85Z.js → data-capture-nbtoFjY7.js} +1 -1
  22. package/assets/decimals-CItF1rPx.js +1 -0
  23. package/assets/{decimals-CVPnxmh7.js → decimals-CbUMNcOK.js} +1 -1
  24. package/assets/{detectExtension-DXdFDVgv.js → detectExtension-DFu0aGm_.js} +1 -1
  25. package/assets/{detectExtension-Dz1kVH7_.js → detectExtension-DK9JKVq9.js} +1 -1
  26. package/assets/{email-DURckrbq.js → email-DrSSRuRF.js} +1 -1
  27. package/assets/{embedded-wallet-BIUcDVNf.js → embedded-wallet-DIwpNYkt.js} +1 -1
  28. package/assets/{engine-DHtQmgio.js → engine-CmbjLyT9.js} +1 -1
  29. package/assets/{engine-DpU8cZCi.js → engine-CsiEs7dq.js} +1 -1
  30. package/assets/{estimate-l1-fee-BkW_txp7.js → estimate-l1-fee-COdWv4Jk.js} +1 -1
  31. package/assets/{estimate-l1-fee-CU3YnFil.js → estimate-l1-fee-DRb4L4LK.js} +1 -1
  32. package/assets/eth_estimateGas-CP8SmIqM.js +1 -0
  33. package/assets/eth_estimateGas-C_uzxoE5.js +1 -0
  34. package/assets/{eth_getStorageAt-VsQtq0Uz.js → eth_getStorageAt-CI_uuphl.js} +1 -1
  35. package/assets/eth_getTransactionCount-B4jNGF8K.js +1 -0
  36. package/assets/{eth_getTransactionCount-PcXWvj1j.js → eth_getTransactionCount-Ul8pztCO.js} +1 -1
  37. package/assets/{ethereum-dihBYRnT.js → ethereum-CtFXgj3Q.js} +1 -1
  38. package/assets/{extractIPFS-JN46N2o7.js → extractIPFS-BK8CMSqM.js} +1 -1
  39. package/assets/{extractIPFS-DklwHe-O.js → extractIPFS-Cgl_kFpG.js} +1 -1
  40. package/assets/{features-_wzOnFY-.js → features-B-HW36dP.js} +1 -1
  41. package/assets/{fetchTokenMetadata-C2LpxJUF.js → fetchTokenMetadata-CqOXA2sB.js} +2 -2
  42. package/assets/{fetchTokenMetadata-B9BbNcLj.js → fetchTokenMetadata-D7czUfYX.js} +2 -2
  43. package/assets/{fortmatic-DBwa9kBS.js → fortmatic-vUENyYEL.js} +1 -1
  44. package/assets/{get-ecosystem-wallet-info-Dw7REpCN.js → get-ecosystem-wallet-info--e4yZ1xz.js} +1 -1
  45. package/assets/{get-ecosystem-wallet-info-B4GMaUQL.js → get-ecosystem-wallet-info-XLnpl1D1.js} +1 -1
  46. package/assets/{getBalance-JHGD-cET.js → getBalance-B77DlxKm.js} +2 -2
  47. package/assets/{getBalance-cs-XLy8M.js → getBalance-Dj7T8f_C.js} +1 -1
  48. package/assets/{getCurrencyMetadata-xziMh2zt.js → getCurrencyMetadata-Bcmna8eL.js} +2 -2
  49. package/assets/{getInstalledModules-BflLi-Ze.js → getInstalledModules-Beyhv7g5.js} +1 -1
  50. package/assets/{getInstalledModules-DQg0aCv5.js → getInstalledModules-Ds27rHln.js} +1 -1
  51. package/assets/{getNFT-DetmgL-D.js → getNFT-C8tAtVl7.js} +2 -2
  52. package/assets/{getNFT-buPGFTfQ.js → getNFT-CALahICS.js} +1 -1
  53. package/assets/{getNFT-BHbjbl1M.js → getNFT-CU-texcs.js} +2 -2
  54. package/assets/{getNFT-BOH0M19a.js → getNFT-ad44vvf9.js} +1 -1
  55. package/assets/{hashTypedData-DE5BevgH.js → hashTypedData-DxeKxIfM.js} +1 -1
  56. package/assets/{if-defined-C9rr67g8.js → if-defined-C2RtN4pg.js} +1 -1
  57. package/assets/{in-app-wallet-calls-hmGpEqXh.js → in-app-wallet-calls-C3VkMSaS.js} +1 -1
  58. package/assets/{in-app-wallet-calls-Dhx0WdY-.js → in-app-wallet-calls-q5_-u32e.js} +1 -1
  59. package/assets/{index-Beysbmyx.js → index-2KcQm31s.js} +2 -2
  60. package/assets/{index-C4kxCSEw.js → index-92Pd_isd.js} +1 -1
  61. package/assets/{index-D7Vm1lDs.js → index-B47xsnQM.js} +1 -1
  62. package/assets/{index-JfBdHn0q.js → index-BAUgCbRi.js} +4 -4
  63. package/assets/{index-CiiICg0u.js → index-BBubfq4L.js} +1 -1
  64. package/assets/{index-RNtaCqcC.js → index-BDp259ID.js} +1 -1
  65. package/assets/{index-DXVbOK22.js → index-BEgVtodh.js} +1 -1
  66. package/assets/{index-DfA8vzD1.js → index-BGJPBtK0.js} +1 -1
  67. package/assets/{index-C1VvoXRq.js → index-BO3yht-9.js} +1 -1
  68. package/assets/{index-Bc4mvSuq.js → index-BSux0Zc0.js} +1 -1
  69. package/assets/{index-CmahChMJ.js → index-Bb2lRedF.js} +1 -1
  70. package/assets/{index-B5dYTApw.js → index-CB-puYx1.js} +1 -1
  71. package/assets/{index-1dvjnqEQ.js → index-CCHG9V4_.js} +1 -1
  72. package/assets/{index-BzArFYlw.js → index-CK1nrqdD.js} +1 -1
  73. package/assets/{index-CSLYlLzb.js → index-CUAmbYIN.js} +1 -1
  74. package/assets/{index-B8W1B15Q.js → index-CYKxW4EG.js} +1 -1
  75. package/assets/{index-BZRwFbHL.js → index-C_qmfaxy.js} +1 -1
  76. package/assets/{index-C6lO61o8.js → index-CgP9VA98.js} +1 -1
  77. package/assets/{index-Z67jmPfi.js → index-CkEYsmH0.js} +1 -1
  78. package/assets/{index-DPowawyA.js → index-Cn9Np4yH.js} +1 -1
  79. package/assets/{index-BTGGjpkN.css → index-Cwuvd1gZ.css} +3 -3
  80. package/assets/{index-BBEYFb0K.js → index-D-2eEQMq.js} +1 -1
  81. package/assets/{index-CTMN1OiK.js → index-D5ETM4f9.js} +1 -1
  82. package/assets/{index-BBjyHWpu.js → index-D5UO3RSb.js} +2 -2
  83. package/assets/{index-DrWK5GwZ.js → index-D7jXd9sr.js} +2 -2
  84. package/assets/{index-7RWfUOm9.js → index-DBgVVPX0.js} +1 -1
  85. package/assets/{index-DO1z5D8-.js → index-DHZAwDBr.js} +1 -1
  86. package/assets/{index-DWNmSOig.js → index-DM5z5s2K.js} +17 -17
  87. package/assets/{index-BJB6bQRp.js → index-DMttqFi1.js} +1 -1
  88. package/assets/{index-CoFTFukW.js → index-DNMazuz8.js} +1 -1
  89. package/assets/{index-Cz8fLqSm.js → index-DNYd2J4Q.js} +1 -1
  90. package/assets/{index-BKQlQfxz.js → index-DR7LXlCp.js} +1 -1
  91. package/assets/{index-BHHvUivu.js → index-DWefGRTR.js} +1 -1
  92. package/assets/{index-DAxajamR.js → index-DXRXDYrO.js} +1 -1
  93. package/assets/{index-DWCZRA7n.js → index-Df8VOZqY.js} +1 -1
  94. package/assets/{index-DqDeelBC.js → index-DhtrTL3B.js} +1 -1
  95. package/assets/{index-C-_SQA8J.js → index-DlEhVPXQ.js} +1 -1
  96. package/assets/{index-DvxHgpeA.js → index-Drh7aFVV.js} +1 -1
  97. package/assets/{index-CR8uPp6r.js → index-DtP6pJnR.js} +1 -1
  98. package/assets/{index-DOL0GnIq.js → index-Du7tUoAV.js} +1 -1
  99. package/assets/{index-B9RtPRFB.js → index-DwyF-5GA.js} +1 -1
  100. package/assets/{index-vLEo3QS7.js → index-DzLdbden.js} +2 -2
  101. package/assets/{index-KHR-k9OK.js → index-GaT-A7yY.js} +1 -1
  102. package/assets/{index-BS0_vd44.js → index-L6oZUQG9.js} +1 -1
  103. package/assets/{index-CdxpK6eg.js → index-MbU_dTSf.js} +1 -1
  104. package/assets/{index-yosKnFoR.js → index-r5bwsfYK.js} +1 -1
  105. package/assets/{index-0nTzO_qt.js → index-rAsFQ2me.js} +1 -1
  106. package/assets/{index-nsb2Kk7z.js → index-vt2UAroy.js} +1 -1
  107. package/assets/{index.es-CJCjj4D5.js → index.es-B3tbOtA4.js} +1 -1
  108. package/assets/{index.es-s8EqqLvH.js → index.es-CzL-ASTZ.js} +1 -1
  109. package/assets/{index.es-CcfXudt8.js → index.es-D_uyZw01.js} +1 -1
  110. package/assets/{index.es-DjT_e1lJ.js → index.es-Dbdr5xE8.js} +1 -1
  111. package/assets/{native-B2Hyw1I8.js → native-X7B4RWbX.js} +1 -1
  112. package/assets/{networks-BJaWSBT-.js → networks-zj0zpNGR.js} +1 -1
  113. package/assets/{onramp-DtPBVTAX.js → onramp-D8bQkAeO.js} +1 -1
  114. package/assets/{openzeppelin-DinUnglE.js → openzeppelin-B0yXMvvz.js} +1 -1
  115. package/assets/{openzeppelin-2loxNe8p.js → openzeppelin-CdblevY7.js} +1 -1
  116. package/assets/{ownerOf-C_iy29-Y.js → ownerOf-CvOgUc6G.js} +1 -1
  117. package/assets/{ownerOf-ZgPNH7fU.js → ownerOf-n9uSVyQY.js} +1 -1
  118. package/assets/{parseNft-Bx8LYMQi.js → parseNft-Dmhm-qFg.js} +2 -2
  119. package/assets/{parseSignature-Bj6kIf2F.js → parseSignature-NqYmEwT3.js} +3 -3
  120. package/assets/{parseSignature-BuNt5p3s.js → parseSignature-Q_2VpUgt.js} +3 -3
  121. package/assets/{pay-with-exchange-Bnt8addE.js → pay-with-exchange-CRV4flNp.js} +1 -1
  122. package/assets/{qr-overlay-CmPeXbUF.js → qr-overlay-CuIP-C5q.js} +1 -1
  123. package/assets/{qr-overlay-DXzL7fWi.js → qr-overlay-DYmVQTZa.js} +1 -1
  124. package/assets/{receive-bimmaEqx.js → receive-BMnawZH0.js} +1 -1
  125. package/assets/{ref-BqQZiIC6.js → ref-NF6snhSR.js} +1 -1
  126. package/assets/{resolveImplementation-I40X9wTp.js → resolveImplementation-BM9hsKDo.js} +1 -1
  127. package/assets/{resolveImplementation-GIw27GK7.js → resolveImplementation-BnrswDof.js} +1 -1
  128. package/assets/{rpc-D0EopFXw.js → rpc-BX7MPNIy.js} +1 -1
  129. package/assets/{rpc-BG0Pk4UR.js → rpc-CaxNQm_O.js} +1 -1
  130. package/assets/{secp256k1-MOORasZn.js → secp256k1-CZHcoxOP.js} +1 -1
  131. package/assets/{secp256k1-r5tEV53R.js → secp256k1-DCLYd7GE.js} +1 -1
  132. package/assets/{send-bIYI4awX.js → send-CGfdsfre.js} +1 -1
  133. package/assets/{send-batch-transaction-n-ui8-LI.js → send-batch-transaction-CCdx9cQg.js} +1 -1
  134. package/assets/{send-batch-transaction-C1RDZpKq.js → send-batch-transaction-DcKA9_qQ.js} +1 -1
  135. package/assets/{send-eip712-transaction-D88fU9U2.js → send-eip712-transaction-l-3ZceyC.js} +2 -2
  136. package/assets/{send-eip712-transaction-DRu8yo6d.js → send-eip712-transaction-m9mLOoGS.js} +2 -2
  137. package/assets/{send-gasless-transaction-BCU2Zrfm.js → send-gasless-transaction-3t5J7foZ.js} +2 -2
  138. package/assets/{send-gasless-transaction-DULqTN5p.js → send-gasless-transaction-PFH7ReFf.js} +2 -2
  139. package/assets/{session-proposal-CgSgZiFG.js → session-proposal-CancAFLJ.js} +1 -1
  140. package/assets/{session-proposal-DpLYOZnc.js → session-proposal-Cwr74rEj.js} +1 -1
  141. package/assets/{session-request-D9OBe44U.js → session-request-Bkq8BoSp.js} +2 -2
  142. package/assets/{session-request-BOw5DN3t.js → session-request-Ompvi0xn.js} +2 -2
  143. package/assets/{sha256-BDhUJM1b.js → sha256-BZpJpgVR.js} +1 -1
  144. package/assets/{sha256-7fBhmRUn.js → sha256-BhaPwDLP.js} +1 -1
  145. package/assets/{signing-BTssaCk0.js → signing-BjuWXh-s.js} +5 -5
  146. package/assets/{signing-D2rOFgrP.js → signing-C82vP_E6.js} +1 -1
  147. package/assets/{socials-BB9j0tMw.js → socials-DJSNC0jv.js} +1 -1
  148. package/assets/{swaps-B1HFXP9m.js → swaps-Da64eJ1W.js} +1 -1
  149. package/assets/switch-chain-B2ZXEOC5.js +1 -0
  150. package/assets/{thirdweb-CsQBcecB.js → thirdweb-CmlpthMz.js} +3 -3
  151. package/assets/{totalSupply-DTUooqpt.js → totalSupply-DNzCsxIk.js} +1 -1
  152. package/assets/{totalSupply-BDJ-8q2H.js → totalSupply-tNfsZHkZ.js} +1 -1
  153. package/assets/{transactionReceipt-HPWYUddy.js → transactionReceipt-YtxArqKq.js} +1 -1
  154. package/assets/{transactions-CDY0CpFM.js → transactions-CEnYovnb.js} +1 -1
  155. package/assets/{utils-Dvpw9MD5.js → utils-Cu8X0YkV.js} +1 -1
  156. package/assets/{verifyHash-DD9wdoLy.js → verifyHash-CTPHjWlD.js} +3 -3
  157. package/assets/{w3m-modal-CnW3Paz2.js → w3m-modal-BMxKJ4ec.js} +1 -1
  158. package/assets/{wait-for-tx-receipt-ByEwSjsF.js → wait-for-tx-receipt-CtBINcID.js} +1 -1
  159. package/assets/{wallets-C6uJfx_m.js → wallets-DiIkUMdI.js} +6 -6
  160. package/assets/{web-connector-DDEmzUHA.js → web-connector-BWIM3K9z.js} +2 -2
  161. package/assets/{web-connector-BVPZhMLu.js → web-connector-DH3CYU1J.js} +3 -3
  162. package/assets/{zora-sepolia-Bl3ucROa.js → zora-sepolia-B-4vX2U7.js} +1 -1
  163. package/index.html +2 -3
  164. package/package.json +3 -3
  165. package/assets/concat-hex-lIlH2McC.js +0 -1
  166. package/assets/decimals-zuJ3wlEU.js +0 -1
  167. package/assets/eth_estimateGas-G_xcfVsZ.js +0 -1
  168. package/assets/eth_estimateGas-m2_--02H.js +0 -1
  169. package/assets/eth_getTransactionCount-CEP3s4C1.js +0 -1
  170. package/assets/switch-chain-1RJMEuL3.js +0 -1
@@ -1,4 +1,4 @@
1
- import{c as x,o as Xr,B as O,i as tr,p as $a,w as Ql,q as Kl,t as Xl,s as Yl,u as Pt,v as rr,x as Ha,e as Ua,y as eu,b as tu,z as ru,g as nu}from"./index-DWNmSOig.js";import{E as Eo}from"./index-CiiICg0u.js";function su(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const s in n)if(s!=="default"&&!(s in e)){const i=Object.getOwnPropertyDescriptor(n,s);i&&Object.defineProperty(e,s,i.get?i:{enumerable:!0,get:()=>n[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var wi={},Kt={},Yr={};Object.defineProperty(Yr,"__esModule",{value:!0});Yr.walletLogo=void 0;const iu=(e,t)=>{let r;switch(e){case"standard":return r=t,`data:image/svg+xml,%3Csvg width='${t}' height='${r}' viewBox='0 0 1024 1024' fill='none' xmlns='http://www.w3.org/2000/svg'%3E %3Crect width='1024' height='1024' fill='%230052FF'/%3E %3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z' fill='white'/%3E %3C/svg%3E `;case"circle":return r=t,`data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='${t}' height='${r}' viewBox='0 0 999.81 999.81'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052fe;%7D.cls-2%7Bfill:%23fefefe;%7D.cls-3%7Bfill:%230152fe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M655-115.9h56c.83,1.59,2.36.88,3.56,1a478,478,0,0,1,75.06,10.42C891.4-81.76,978.33-32.58,1049.19,44q116.7,126,131.94,297.61c.38,4.14-.34,8.53,1.78,12.45v59c-1.58.84-.91,2.35-1,3.56a482.05,482.05,0,0,1-10.38,74.05c-24,106.72-76.64,196.76-158.83,268.93s-178.18,112.82-287.2,122.6c-4.83.43-9.86-.25-14.51,1.77H654c-1-1.68-2.69-.91-4.06-1a496.89,496.89,0,0,1-105.9-18.59c-93.54-27.42-172.78-77.59-236.91-150.94Q199.34,590.1,184.87,426.58c-.47-5.19.25-10.56-1.77-15.59V355c1.68-1,.91-2.7,1-4.06a498.12,498.12,0,0,1,18.58-105.9c26-88.75,72.64-164.9,140.6-227.57q126-116.27,297.21-131.61C645.32-114.57,650.35-113.88,655-115.9Zm377.92,500c0-192.44-156.31-349.49-347.56-350.15-194.13-.68-350.94,155.13-352.29,347.42-1.37,194.55,155.51,352.1,348.56,352.47C876.15,734.23,1032.93,577.84,1032.93,384.11Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-2' d='M1032.93,384.11c0,193.73-156.78,350.12-351.29,349.74-193-.37-349.93-157.92-348.56-352.47C334.43,189.09,491.24,33.28,685.37,34,876.62,34.62,1032.94,191.67,1032.93,384.11ZM683,496.81q43.74,0,87.48,0c15.55,0,25.32-9.72,25.33-25.21q0-87.48,0-175c0-15.83-9.68-25.46-25.59-25.46H595.77c-15.88,0-25.57,9.64-25.58,25.46q0,87.23,0,174.45c0,16.18,9.59,25.7,25.84,25.71Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-3' d='M683,496.81H596c-16.25,0-25.84-9.53-25.84-25.71q0-87.23,0-174.45c0-15.82,9.7-25.46,25.58-25.46H770.22c15.91,0,25.59,9.63,25.59,25.46q0,87.47,0,175c0,15.49-9.78,25.2-25.33,25.21Q726.74,496.84,683,496.81Z' transform='translate(-183.1 115.9)'/%3E%3C/svg%3E`;case"text":return r=(.1*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogo":return r=(.25*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`;case"textLight":return r=(.1*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogoLight":return r=(.25*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`;default:return r=t,`data:image/svg+xml,%3Csvg width='${t}' height='${r}' viewBox='0 0 1024 1024' fill='none' xmlns='http://www.w3.org/2000/svg'%3E %3Crect width='1024' height='1024' fill='%230052FF'/%3E %3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z' fill='white'/%3E %3C/svg%3E `}};Yr.walletLogo=iu;var en={};Object.defineProperty(en,"__esModule",{value:!0});en.LINK_API_URL=void 0;en.LINK_API_URL="https://www.walletlink.org";var S={},nr={},We={};Object.defineProperty(We,"__esModule",{value:!0});We.errorValues=We.standardErrorCodes=void 0;We.standardErrorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901,unsupportedChain:4902}};We.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."},4902:{standard:"EIP-3085",message:"Unrecognized chain ID."}};var tn={},rn={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.serialize=e.getErrorCode=e.isValidCode=e.getMessageFromCode=e.JSON_RPC_SERVER_ERROR_MESSAGE=void 0;const t=We,r="Unspecified error message.";e.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.";function n(h,f=r){if(h&&Number.isInteger(h)){const b=h.toString();if(u(t.errorValues,b))return t.errorValues[b].message;if(c(h))return e.JSON_RPC_SERVER_ERROR_MESSAGE}return f}e.getMessageFromCode=n;function s(h){if(!Number.isInteger(h))return!1;const f=h.toString();return!!(t.errorValues[f]||c(h))}e.isValidCode=s;function i(h){var f;if(typeof h=="number")return h;if(o(h))return(f=h.code)!==null&&f!==void 0?f:h.errorCode}e.getErrorCode=i;function o(h){return typeof h=="object"&&h!==null&&(typeof h.code=="number"||typeof h.errorCode=="number")}function a(h,{shouldIncludeStack:f=!1}={}){const b={};if(h&&typeof h=="object"&&!Array.isArray(h)&&u(h,"code")&&s(h.code)){const g=h;b.code=g.code,g.message&&typeof g.message=="string"?(b.message=g.message,u(g,"data")&&(b.data=g.data)):(b.message=n(b.code),b.data={originalError:l(h)})}else b.code=t.standardErrorCodes.rpc.internal,b.message=d(h,"message")?h.message:r,b.data={originalError:l(h)};return f&&(b.stack=d(h,"stack")?h.stack:void 0),b}e.serialize=a;function c(h){return h>=-32099&&h<=-32e3}function l(h){return h&&typeof h=="object"&&!Array.isArray(h)?Object.assign({},h):h}function u(h,f){return Object.prototype.hasOwnProperty.call(h,f)}function d(h,f){return typeof h=="object"&&h!==null&&f in h&&typeof h[f]=="string"}})(rn);Object.defineProperty(tn,"__esModule",{value:!0});tn.standardErrors=void 0;const ue=We,Va=rn;tn.standardErrors={rpc:{parse:e=>ve(ue.standardErrorCodes.rpc.parse,e),invalidRequest:e=>ve(ue.standardErrorCodes.rpc.invalidRequest,e),invalidParams:e=>ve(ue.standardErrorCodes.rpc.invalidParams,e),methodNotFound:e=>ve(ue.standardErrorCodes.rpc.methodNotFound,e),internal:e=>ve(ue.standardErrorCodes.rpc.internal,e),server:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum RPC Server errors must provide single object argument.");const{code:t}=e;if(!Number.isInteger(t)||t>-32005||t<-32099)throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');return ve(t,e)},invalidInput:e=>ve(ue.standardErrorCodes.rpc.invalidInput,e),resourceNotFound:e=>ve(ue.standardErrorCodes.rpc.resourceNotFound,e),resourceUnavailable:e=>ve(ue.standardErrorCodes.rpc.resourceUnavailable,e),transactionRejected:e=>ve(ue.standardErrorCodes.rpc.transactionRejected,e),methodNotSupported:e=>ve(ue.standardErrorCodes.rpc.methodNotSupported,e),limitExceeded:e=>ve(ue.standardErrorCodes.rpc.limitExceeded,e)},provider:{userRejectedRequest:e=>pt(ue.standardErrorCodes.provider.userRejectedRequest,e),unauthorized:e=>pt(ue.standardErrorCodes.provider.unauthorized,e),unsupportedMethod:e=>pt(ue.standardErrorCodes.provider.unsupportedMethod,e),disconnected:e=>pt(ue.standardErrorCodes.provider.disconnected,e),chainDisconnected:e=>pt(ue.standardErrorCodes.provider.chainDisconnected,e),unsupportedChain:e=>pt(ue.standardErrorCodes.provider.unsupportedChain,e),custom:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum Provider custom errors must provide single object argument.");const{code:t,message:r,data:n}=e;if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string');return new qa(t,r,n)}}};function ve(e,t){const[r,n]=Wa(t);return new za(e,r||(0,Va.getMessageFromCode)(e),n)}function pt(e,t){const[r,n]=Wa(t);return new qa(e,r||(0,Va.getMessageFromCode)(e),n)}function Wa(e){if(e){if(typeof e=="string")return[e];if(typeof e=="object"&&!Array.isArray(e)){const{message:t,data:r}=e;if(t&&typeof t!="string")throw new Error("Must specify string message.");return[t||void 0,r]}}return[]}let za=class extends Error{constructor(t,r,n){if(!Number.isInteger(t))throw new Error('"code" must be an integer.');if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string.');super(r),this.code=t,n!==void 0&&(this.data=n)}},qa=class extends za{constructor(t,r,n){if(!ou(t))throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');super(t,r,n)}};function ou(e){return Number.isInteger(e)&&e>=1e3&&e<=4999}var nn={},Ot={};Object.defineProperty(Ot,"__esModule",{value:!0});Ot.isErrorResponse=void 0;function au(e){return e.errorMessage!==void 0}Ot.isErrorResponse=au;var Bt={};Object.defineProperty(Bt,"__esModule",{value:!0});Bt.LIB_VERSION=void 0;Bt.LIB_VERSION="3.9.3";Object.defineProperty(nn,"__esModule",{value:!0});nn.serializeError=void 0;const cu=Ot,lu=Bt,uu=We,du=rn;function hu(e,t){const r=(0,du.serialize)(fu(e),{shouldIncludeStack:!0}),n=new URL("https://docs.cloud.coinbase.com/wallet-sdk/docs/errors");n.searchParams.set("version",lu.LIB_VERSION),n.searchParams.set("code",r.code.toString());const s=gu(r.data,t);return s&&n.searchParams.set("method",s),n.searchParams.set("message",r.message),Object.assign(Object.assign({},r),{docUrl:n.href})}nn.serializeError=hu;function fu(e){return typeof e=="string"?{message:e,code:uu.standardErrorCodes.rpc.internal}:(0,cu.isErrorResponse)(e)?Object.assign(Object.assign({},e),{message:e.errorMessage,code:e.errorCode,data:{method:e.method}}):e}function gu(e,t){const r=e==null?void 0:e.method;if(r)return r;if(t!==void 0){if(typeof t=="string")return t;if(Array.isArray(t)){if(t.length>0)return t[0].method}else return t.method}}(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.standardErrors=e.standardErrorCodes=e.serializeError=e.getMessageFromCode=e.getErrorCode=void 0;const t=We;Object.defineProperty(e,"standardErrorCodes",{enumerable:!0,get:function(){return t.standardErrorCodes}});const r=tn;Object.defineProperty(e,"standardErrors",{enumerable:!0,get:function(){return r.standardErrors}});const n=nn;Object.defineProperty(e,"serializeError",{enumerable:!0,get:function(){return n.serializeError}});const s=rn;Object.defineProperty(e,"getErrorCode",{enumerable:!0,get:function(){return s.getErrorCode}}),Object.defineProperty(e,"getMessageFromCode",{enumerable:!0,get:function(){return s.getMessageFromCode}})})(nr);var ie={};Object.defineProperty(ie,"__esModule",{value:!0});ie.ProviderType=ie.RegExpString=ie.IntNumber=ie.BigIntString=ie.AddressString=ie.HexString=ie.OpaqueType=void 0;function sr(){return e=>e}ie.OpaqueType=sr;ie.HexString=sr();ie.AddressString=sr();ie.BigIntString=sr();function pu(e){return Math.floor(e)}ie.IntNumber=pu;ie.RegExpString=sr();var So;(function(e){e.CoinbaseWallet="CoinbaseWallet",e.MetaMask="MetaMask",e.Unselected=""})(So||(ie.ProviderType=So={}));var _u=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(S,"__esModule",{value:!0});S.isMobileWeb=S.getLocation=S.isInIFrame=S.createQrUrl=S.getFavicon=S.range=S.isBigNumber=S.ensureParsedJSONObject=S.ensureBN=S.ensureRegExpString=S.ensureIntNumber=S.ensureBuffer=S.ensureAddressString=S.ensureEvenLengthHexString=S.ensureHexString=S.isHexString=S.prepend0x=S.strip0x=S.has0xPrefix=S.hexStringFromIntNumber=S.intNumberFromHexString=S.bigIntStringFromBN=S.hexStringFromBuffer=S.hexStringToUint8Array=S.uint8ArrayToHex=S.randomBytesHex=void 0;const Ge=_u(Xr),ut=nr,Ce=ie,Ja=/^[0-9]*$/,Ga=/^[a-f0-9]*$/;function mu(e){return Za(crypto.getRandomValues(new Uint8Array(e)))}S.randomBytesHex=mu;function Za(e){return[...e].map(t=>t.toString(16).padStart(2,"0")).join("")}S.uint8ArrayToHex=Za;function bu(e){return new Uint8Array(e.match(/.{1,2}/g).map(t=>parseInt(t,16)))}S.hexStringToUint8Array=bu;function yu(e,t=!1){const r=e.toString("hex");return(0,Ce.HexString)(t?`0x${r}`:r)}S.hexStringFromBuffer=yu;function wu(e){return(0,Ce.BigIntString)(e.toString(10))}S.bigIntStringFromBN=wu;function vu(e){return(0,Ce.IntNumber)(new Ge.default(or(e,!1),16).toNumber())}S.intNumberFromHexString=vu;function Eu(e){return(0,Ce.HexString)(`0x${new Ge.default(e).toString(16)}`)}S.hexStringFromIntNumber=Eu;function vi(e){return e.startsWith("0x")||e.startsWith("0X")}S.has0xPrefix=vi;function sn(e){return vi(e)?e.slice(2):e}S.strip0x=sn;function Qa(e){return vi(e)?`0x${e.slice(2)}`:`0x${e}`}S.prepend0x=Qa;function ir(e){if(typeof e!="string")return!1;const t=sn(e).toLowerCase();return Ga.test(t)}S.isHexString=ir;function Ka(e,t=!1){if(typeof e=="string"){const r=sn(e).toLowerCase();if(Ga.test(r))return(0,Ce.HexString)(t?`0x${r}`:r)}throw ut.standardErrors.rpc.invalidParams(`"${String(e)}" is not a hexadecimal string`)}S.ensureHexString=Ka;function or(e,t=!1){let r=Ka(e,!1);return r.length%2===1&&(r=(0,Ce.HexString)(`0${r}`)),t?(0,Ce.HexString)(`0x${r}`):r}S.ensureEvenLengthHexString=or;function Su(e){if(typeof e=="string"){const t=sn(e).toLowerCase();if(ir(t)&&t.length===40)return(0,Ce.AddressString)(Qa(t))}throw ut.standardErrors.rpc.invalidParams(`Invalid Ethereum address: ${String(e)}`)}S.ensureAddressString=Su;function ku(e){if(O.isBuffer(e))return e;if(typeof e=="string"){if(ir(e)){const t=or(e,!1);return O.from(t,"hex")}return O.from(e,"utf8")}throw ut.standardErrors.rpc.invalidParams(`Not binary data: ${String(e)}`)}S.ensureBuffer=ku;function Xa(e){if(typeof e=="number"&&Number.isInteger(e))return(0,Ce.IntNumber)(e);if(typeof e=="string"){if(Ja.test(e))return(0,Ce.IntNumber)(Number(e));if(ir(e))return(0,Ce.IntNumber)(new Ge.default(or(e,!1),16).toNumber())}throw ut.standardErrors.rpc.invalidParams(`Not an integer: ${String(e)}`)}S.ensureIntNumber=Xa;function Cu(e){if(e instanceof RegExp)return(0,Ce.RegExpString)(e.toString());throw ut.standardErrors.rpc.invalidParams(`Not a RegExp: ${String(e)}`)}S.ensureRegExpString=Cu;function Ru(e){if(e!==null&&(Ge.default.isBN(e)||Ya(e)))return new Ge.default(e.toString(10),10);if(typeof e=="number")return new Ge.default(Xa(e));if(typeof e=="string"){if(Ja.test(e))return new Ge.default(e,10);if(ir(e))return new Ge.default(or(e,!1),16)}throw ut.standardErrors.rpc.invalidParams(`Not an integer: ${String(e)}`)}S.ensureBN=Ru;function Iu(e){if(typeof e=="string")return JSON.parse(e);if(typeof e=="object")return e;throw ut.standardErrors.rpc.invalidParams(`Not a JSON string or an object: ${String(e)}`)}S.ensureParsedJSONObject=Iu;function Ya(e){if(e==null||typeof e.constructor!="function")return!1;const{constructor:t}=e;return typeof t.config=="function"&&typeof t.EUCLID=="number"}S.isBigNumber=Ya;function Au(e,t){return Array.from({length:t-e},(r,n)=>e+n)}S.range=Au;function xu(){const e=document.querySelector('link[sizes="192x192"]')||document.querySelector('link[sizes="180x180"]')||document.querySelector('link[rel="icon"]')||document.querySelector('link[rel="shortcut icon"]'),{protocol:t,host:r}=document.location,n=e?e.getAttribute("href"):null;return!n||n.startsWith("javascript:")||n.startsWith("vbscript:")?null:n.startsWith("http://")||n.startsWith("https://")||n.startsWith("data:")?n:n.startsWith("//")?t+n:`${t}//${r}${n}`}S.getFavicon=xu;function Nu(e,t,r,n,s,i){const o=n?"parent-id":"id",a=new URLSearchParams({[o]:e,secret:t,server:r,v:s,chainId:i.toString()}).toString();return`${r}/#/link?${a}`}S.createQrUrl=Nu;function ec(){try{return window.frameElement!==null}catch{return!1}}S.isInIFrame=ec;function Lu(){try{return ec()&&window.top?window.top.location:window.location}catch{return window.location}}S.getLocation=Lu;function Mu(){var e;return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test((e=window==null?void 0:window.navigator)===null||e===void 0?void 0:e.userAgent)}S.isMobileWeb=Mu;var on={};Object.defineProperty(on,"__esModule",{value:!0});on.ScopedLocalStorage=void 0;class Tu{constructor(t){this.scope=t}setItem(t,r){localStorage.setItem(this.scopedKey(t),r)}getItem(t){return localStorage.getItem(this.scopedKey(t))}removeItem(t){localStorage.removeItem(this.scopedKey(t))}clear(){const t=this.scopedKey(""),r=[];for(let n=0;n<localStorage.length;n++){const s=localStorage.key(n);typeof s=="string"&&s.startsWith(t)&&r.push(s)}r.forEach(n=>localStorage.removeItem(n))}scopedKey(t){return`${this.scope}:${t}`}}on.ScopedLocalStorage=Tu;var Rt={};const Pu=Object.freeze(Object.defineProperty({__proto__:null,EventEmitter:Eo,default:Eo},Symbol.toStringTag,{value:"Module"})),Ou=tr(Pu);var ar={},cr={},Dt={};Object.defineProperty(Dt,"__esModule",{value:!0});Dt.EVENTS=void 0;Dt.EVENTS={STARTED_CONNECTING:"walletlink_sdk.started.connecting",CONNECTED_STATE_CHANGE:"walletlink_sdk.connected",DISCONNECTED:"walletlink_sdk.disconnected",METADATA_DESTROYED:"walletlink_sdk_metadata_destroyed",LINKED:"walletlink_sdk.linked",FAILURE:"walletlink_sdk.generic_failure",SESSION_CONFIG_RECEIVED:"walletlink_sdk.session_config_event_received",ETH_ACCOUNTS_STATE:"walletlink_sdk.eth_accounts_state",SESSION_STATE_CHANGE:"walletlink_sdk.session_state_change",UNLINKED_ERROR_STATE:"walletlink_sdk.unlinked_error_state",SKIPPED_CLEARING_SESSION:"walletlink_sdk.skipped_clearing_session",GENERAL_ERROR:"walletlink_sdk.general_error",WEB3_REQUEST:"walletlink_sdk.web3.request",WEB3_REQUEST_PUBLISHED:"walletlink_sdk.web3.request_published",WEB3_RESPONSE:"walletlink_sdk.web3.response",METHOD_NOT_IMPLEMENTED:"walletlink_sdk.method_not_implemented",UNKNOWN_ADDRESS_ENCOUNTERED:"walletlink_sdk.unknown_address_encountered"};var ke={};Object.defineProperty(ke,"__esModule",{value:!0});ke.RelayAbstract=ke.APP_VERSION_KEY=ke.LOCAL_STORAGE_ADDRESSES_KEY=ke.WALLET_USER_NAME_KEY=void 0;const ko=nr;ke.WALLET_USER_NAME_KEY="walletUsername";ke.LOCAL_STORAGE_ADDRESSES_KEY="Addresses";ke.APP_VERSION_KEY="AppVersion";class Bu{async makeEthereumJSONRPCRequest(t,r){if(!r)throw new Error("Error: No jsonRpcUrl provided");return window.fetch(r,{method:"POST",body:JSON.stringify(t),mode:"cors",headers:{"Content-Type":"application/json"}}).then(n=>n.json()).then(n=>{if(!n)throw ko.standardErrors.rpc.parse({});const s=n,{error:i}=s;if(i)throw(0,ko.serializeError)(i,t.method);return s})}}ke.RelayAbstract=Bu;var Ft={},tc={exports:{}},ai={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(e,t){var r=$a(),n=r.Buffer;function s(o,a){for(var c in o)a[c]=o[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(s(r,t),t.Buffer=i);function i(o,a,c){return n(o,a,c)}i.prototype=Object.create(n.prototype),s(n,i),i.from=function(o,a,c){if(typeof o=="number")throw new TypeError("Argument must not be a number");return n(o,a,c)},i.alloc=function(o,a,c){if(typeof o!="number")throw new TypeError("Argument must be a number");var l=n(o);return a!==void 0?typeof c=="string"?l.fill(a,c):l.fill(a):l.fill(0),l},i.allocUnsafe=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return n(o)},i.allocUnsafeSlow=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(o)}})(ai,ai.exports);var dt=ai.exports,ci={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(e,t){var r=$a(),n=r.Buffer;function s(o,a){for(var c in o)a[c]=o[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(s(r,t),t.Buffer=i);function i(o,a,c){return n(o,a,c)}i.prototype=Object.create(n.prototype),s(n,i),i.from=function(o,a,c){if(typeof o=="number")throw new TypeError("Argument must not be a number");return n(o,a,c)},i.alloc=function(o,a,c){if(typeof o!="number")throw new TypeError("Argument must be a number");var l=n(o);return a!==void 0?typeof c=="string"?l.fill(a,c):l.fill(a):l.fill(0),l},i.allocUnsafe=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return n(o)},i.allocUnsafeSlow=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(o)}})(ci,ci.exports);var Du=ci.exports,Hs,Co;function Fu(){if(Co)return Hs;Co=1;var e=Ql;return Hs=function(r){return!!e(r)},Hs}var ju=Xl,$u=Kl,Hu=$u("TypedArray.prototype.buffer",!0),Uu=Fu(),Vu=Hu||function(t){if(!Uu(t))throw new ju("Not a Typed Array");return t.buffer},Ne=Du.Buffer,Wu=Yl,zu=Vu,qu=ArrayBuffer.isView||function(t){try{return zu(t),!0}catch{return!1}},Ju=typeof Uint8Array<"u",rc=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",Gu=rc&&(Ne.prototype instanceof Uint8Array||Ne.TYPED_ARRAY_SUPPORT),Zu=function(t,r){if(Ne.isBuffer(t))return t.constructor&&!("isBuffer"in t)?Ne.from(t):t;if(typeof t=="string")return Ne.from(t,r);if(rc&&qu(t)){if(t.byteLength===0)return Ne.alloc(0);if(Gu){var n=Ne.from(t.buffer,t.byteOffset,t.byteLength);if(n.byteLength===t.byteLength)return n}var s=t instanceof Uint8Array?t:new Uint8Array(t.buffer,t.byteOffset,t.byteLength),i=Ne.from(s);if(i.length===t.byteLength)return i}if(Ju&&t instanceof Uint8Array)return Ne.from(t);var o=Wu(t);if(o)for(var a=0;a<t.length;a+=1){var c=t[a];if(typeof c!="number"||c<0||c>255||~~c!==c)throw new RangeError("Array items must be numbers in the range 0-255.")}if(o||Ne.isBuffer(t)&&t.constructor&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t))return Ne.from(t);throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')},Qu=dt.Buffer,Ku=Zu;function an(e,t){this._block=Qu.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}an.prototype.update=function(e,t){e=Ku(e,t||"utf8");for(var r=this._block,n=this._blockSize,s=e.length,i=this._len,o=0;o<s;){for(var a=i%n,c=Math.min(s-o,n-a),l=0;l<c;l++)r[a+l]=e[o+l];i+=c,o+=c,i%n===0&&this._update(r)}return this._len+=s,this};an.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=this._len*8;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(r&4294967295)>>>0,s=(r-n)/4294967296;this._block.writeUInt32BE(s,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var i=this._hash();return e?i.toString(e):i};an.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var jt=an,Xu=Pt,nc=jt,Yu=dt.Buffer,ed=[1518500249,1859775393,-1894007588,-899497514],td=new Array(80);function lr(){this.init(),this._w=td,nc.call(this,64,56)}Xu(lr,nc);lr.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rd(e){return e<<5|e>>>27}function nd(e){return e<<30|e>>>2}function sd(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}lr.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=0;a<16;++a)t[a]=e.readInt32BE(a*4);for(;a<80;++a)t[a]=t[a-3]^t[a-8]^t[a-14]^t[a-16];for(var c=0;c<80;++c){var l=~~(c/20),u=rd(r)+sd(l,n,s,i)+o+t[c]+ed[l]|0;o=i,i=s,s=nd(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};lr.prototype._hash=function(){var e=Yu.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var id=lr,od=Pt,sc=jt,ad=dt.Buffer,cd=[1518500249,1859775393,-1894007588,-899497514],ld=new Array(80);function ur(){this.init(),this._w=ld,sc.call(this,64,56)}od(ur,sc);ur.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function ud(e){return e<<1|e>>>31}function dd(e){return e<<5|e>>>27}function hd(e){return e<<30|e>>>2}function fd(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}ur.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=0;a<16;++a)t[a]=e.readInt32BE(a*4);for(;a<80;++a)t[a]=ud(t[a-3]^t[a-8]^t[a-14]^t[a-16]);for(var c=0;c<80;++c){var l=~~(c/20),u=dd(r)+fd(l,n,s,i)+o+t[c]+cd[l]|0;o=i,i=s,s=hd(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};ur.prototype._hash=function(){var e=ad.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var gd=ur,pd=Pt,ic=jt,_d=dt.Buffer,md=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],bd=new Array(64);function dr(){this.init(),this._w=bd,ic.call(this,64,56)}pd(dr,ic);dr.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function yd(e,t,r){return r^e&(t^r)}function wd(e,t,r){return e&t|r&(e|t)}function vd(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function Ed(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function Sd(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function kd(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}dr.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=this._f|0,c=this._g|0,l=this._h|0,u=0;u<16;++u)t[u]=e.readInt32BE(u*4);for(;u<64;++u)t[u]=kd(t[u-2])+t[u-7]+Sd(t[u-15])+t[u-16]|0;for(var d=0;d<64;++d){var h=l+Ed(o)+yd(o,a,c)+md[d]+t[d]|0,f=vd(r)+wd(r,n,s)|0;l=c,c=a,a=o,o=i+h|0,i=s,s=n,n=r,r=h+f|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0,this._f=a+this._f|0,this._g=c+this._g|0,this._h=l+this._h|0};dr.prototype._hash=function(){var e=_d.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e};var oc=dr,Cd=Pt,Rd=oc,Id=jt,Ad=dt.Buffer,xd=new Array(64);function cn(){this.init(),this._w=xd,Id.call(this,64,56)}Cd(cn,Rd);cn.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this};cn.prototype._hash=function(){var e=Ad.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e};var Nd=cn,Ld=Pt,ac=jt,Md=dt.Buffer,Ro=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],Td=new Array(160);function hr(){this.init(),this._w=Td,ac.call(this,128,112)}Ld(hr,ac);hr.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function Io(e,t,r){return r^e&(t^r)}function Ao(e,t,r){return e&t|r&(e|t)}function xo(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function No(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function Pd(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function Od(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function Bd(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function Dd(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function ce(e,t){return e>>>0<t>>>0?1:0}hr.prototype._update=function(e){for(var t=this._w,r=this._ah|0,n=this._bh|0,s=this._ch|0,i=this._dh|0,o=this._eh|0,a=this._fh|0,c=this._gh|0,l=this._hh|0,u=this._al|0,d=this._bl|0,h=this._cl|0,f=this._dl|0,b=this._el|0,g=this._fl|0,E=this._gl|0,y=this._hl|0,p=0;p<32;p+=2)t[p]=e.readInt32BE(p*4),t[p+1]=e.readInt32BE(p*4+4);for(;p<160;p+=2){var _=t[p-30],A=t[p-15*2+1],v=Pd(_,A),N=Od(A,_);_=t[p-2*2],A=t[p-2*2+1];var V=Bd(_,A),Z=Dd(A,_),ee=t[p-7*2],z=t[p-7*2+1],W=t[p-16*2],H=t[p-16*2+1],se=N+z|0,w=v+ee+ce(se,N)|0;se=se+Z|0,w=w+V+ce(se,Z)|0,se=se+H|0,w=w+W+ce(se,H)|0,t[p]=w,t[p+1]=se}for(var m=0;m<160;m+=2){w=t[m],se=t[m+1];var R=Ao(r,n,s),C=Ao(u,d,h),I=xo(r,u),k=xo(u,r),L=No(o,b),D=No(b,o),T=Ro[m],U=Ro[m+1],ae=Io(o,a,c),J=Io(b,g,E),te=y+D|0,Ie=l+L+ce(te,y)|0;te=te+J|0,Ie=Ie+ae+ce(te,J)|0,te=te+U|0,Ie=Ie+T+ce(te,U)|0,te=te+se|0,Ie=Ie+w+ce(te,se)|0;var Wt=k+C|0,Lr=I+R+ce(Wt,k)|0;l=c,y=E,c=a,E=g,a=o,g=b,b=f+te|0,o=i+Ie+ce(b,f)|0,i=s,f=h,s=n,h=d,n=r,d=u,u=te+Wt|0,r=Ie+Lr+ce(u,te)|0}this._al=this._al+u|0,this._bl=this._bl+d|0,this._cl=this._cl+h|0,this._dl=this._dl+f|0,this._el=this._el+b|0,this._fl=this._fl+g|0,this._gl=this._gl+E|0,this._hl=this._hl+y|0,this._ah=this._ah+r+ce(this._al,u)|0,this._bh=this._bh+n+ce(this._bl,d)|0,this._ch=this._ch+s+ce(this._cl,h)|0,this._dh=this._dh+i+ce(this._dl,f)|0,this._eh=this._eh+o+ce(this._el,b)|0,this._fh=this._fh+a+ce(this._fl,g)|0,this._gh=this._gh+c+ce(this._gl,E)|0,this._hh=this._hh+l+ce(this._hl,y)|0};hr.prototype._hash=function(){var e=Md.allocUnsafe(64);function t(r,n,s){e.writeInt32BE(r,s),e.writeInt32BE(n,s+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e};var cc=hr,Fd=Pt,jd=cc,$d=jt,Hd=dt.Buffer,Ud=new Array(160);function ln(){this.init(),this._w=Ud,$d.call(this,128,112)}Fd(ln,jd);ln.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this};ln.prototype._hash=function(){var e=Hd.allocUnsafe(48);function t(r,n,s){e.writeInt32BE(r,s),e.writeInt32BE(n,s+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e};var Vd=ln;(function(e){e.exports=function(r){var n=r.toLowerCase(),s=e.exports[n];if(!s)throw new Error(n+" is not supported (we accept pull requests)");return new s},e.exports.sha=id,e.exports.sha1=gd,e.exports.sha224=Nd,e.exports.sha256=oc,e.exports.sha384=Vd,e.exports.sha512=cc})(tc);var Wd=tc.exports;Object.defineProperty(Ft,"__esModule",{value:!0});Ft.Session=void 0;const Lo=Wd,Mo=S,To="session:id",Po="session:secret",Oo="session:linked";class Ei{constructor(t,r,n,s){this._storage=t,this._id=r||(0,Mo.randomBytesHex)(16),this._secret=n||(0,Mo.randomBytesHex)(32),this._key=new Lo.sha256().update(`${this._id}, ${this._secret} WalletLink`).digest("hex"),this._linked=!!s}static load(t){const r=t.getItem(To),n=t.getItem(Oo),s=t.getItem(Po);return r&&s?new Ei(t,r,s,n==="1"):null}static hash(t){return new Lo.sha256().update(t).digest("hex")}get id(){return this._id}get secret(){return this._secret}get key(){return this._key}get linked(){return this._linked}set linked(t){this._linked=t,this.persistLinked()}save(){return this._storage.setItem(To,this._id),this._storage.setItem(Po,this._secret),this.persistLinked(),this}persistLinked(){this._storage.setItem(Oo,this._linked?"1":"0")}}Ft.Session=Ei;var un={},dn={};Object.defineProperty(dn,"__esModule",{value:!0});dn.Cipher=void 0;const Mr=S;class zd{constructor(t){this.secret=t}async encrypt(t){const r=this.secret;if(r.length!==64)throw Error("secret must be 256 bits");const n=crypto.getRandomValues(new Uint8Array(12)),s=await crypto.subtle.importKey("raw",(0,Mr.hexStringToUint8Array)(r),{name:"aes-gcm"},!1,["encrypt","decrypt"]),i=new TextEncoder,o=await window.crypto.subtle.encrypt({name:"AES-GCM",iv:n},s,i.encode(t)),a=16,c=o.slice(o.byteLength-a),l=o.slice(0,o.byteLength-a),u=new Uint8Array(c),d=new Uint8Array(l),h=new Uint8Array([...n,...u,...d]);return(0,Mr.uint8ArrayToHex)(h)}async decrypt(t){const r=this.secret;if(r.length!==64)throw Error("secret must be 256 bits");return new Promise((n,s)=>{(async function(){const i=await crypto.subtle.importKey("raw",(0,Mr.hexStringToUint8Array)(r),{name:"aes-gcm"},!1,["encrypt","decrypt"]),o=(0,Mr.hexStringToUint8Array)(t),a=o.slice(0,12),c=o.slice(12,28),l=o.slice(28),u=new Uint8Array([...l,...c]),d={name:"AES-GCM",iv:new Uint8Array(a)};try{const h=await window.crypto.subtle.decrypt(d,i,u),f=new TextDecoder;n(f.decode(h))}catch(h){s(h)}})()})}}dn.Cipher=zd;var hn={};Object.defineProperty(hn,"__esModule",{value:!0});hn.WalletLinkHTTP=void 0;class qd{constructor(t,r,n){this.linkAPIUrl=t,this.sessionId=r;const s=`${r}:${n}`;this.auth=`Basic ${btoa(s)}`}async markUnseenEventsAsSeen(t){return Promise.all(t.map(r=>fetch(`${this.linkAPIUrl}/events/${r.eventId}/seen`,{method:"POST",headers:{Authorization:this.auth}}))).catch(r=>console.error("Unabled to mark event as failed:",r))}async fetchUnseenEvents(){var t;const r=await fetch(`${this.linkAPIUrl}/events?unseen=true`,{headers:{Authorization:this.auth}});if(r.ok){const{events:n,error:s}=await r.json();if(s)throw new Error(`Check unseen events failed: ${s}`);const i=(t=n==null?void 0:n.filter(o=>o.event==="Web3Response").map(o=>({type:"Event",sessionId:this.sessionId,eventId:o.id,event:o.event,data:o.data})))!==null&&t!==void 0?t:[];return this.markUnseenEventsAsSeen(i),i}throw new Error(`Check unseen events failed: ${r.status}`)}}hn.WalletLinkHTTP=qd;var It={};Object.defineProperty(It,"__esModule",{value:!0});It.WalletLinkWebSocket=It.ConnectionState=void 0;var vt;(function(e){e[e.DISCONNECTED=0]="DISCONNECTED",e[e.CONNECTING=1]="CONNECTING",e[e.CONNECTED=2]="CONNECTED"})(vt||(It.ConnectionState=vt={}));class Jd{setConnectionStateListener(t){this.connectionStateListener=t}setIncomingDataListener(t){this.incomingDataListener=t}constructor(t,r=WebSocket){this.WebSocketClass=r,this.webSocket=null,this.pendingData=[],this.url=t.replace(/^http/,"ws")}async connect(){if(this.webSocket)throw new Error("webSocket object is not null");return new Promise((t,r)=>{var n;let s;try{this.webSocket=s=new this.WebSocketClass(this.url)}catch(i){r(i);return}(n=this.connectionStateListener)===null||n===void 0||n.call(this,vt.CONNECTING),s.onclose=i=>{var o;this.clearWebSocket(),r(new Error(`websocket error ${i.code}: ${i.reason}`)),(o=this.connectionStateListener)===null||o===void 0||o.call(this,vt.DISCONNECTED)},s.onopen=i=>{var o;t(),(o=this.connectionStateListener)===null||o===void 0||o.call(this,vt.CONNECTED),this.pendingData.length>0&&([...this.pendingData].forEach(c=>this.sendData(c)),this.pendingData=[])},s.onmessage=i=>{var o,a;if(i.data==="h")(o=this.incomingDataListener)===null||o===void 0||o.call(this,{type:"Heartbeat"});else try{const c=JSON.parse(i.data);(a=this.incomingDataListener)===null||a===void 0||a.call(this,c)}catch{}}})}disconnect(){var t;const{webSocket:r}=this;if(r){this.clearWebSocket(),(t=this.connectionStateListener)===null||t===void 0||t.call(this,vt.DISCONNECTED),this.connectionStateListener=void 0,this.incomingDataListener=void 0;try{r.close()}catch{}}}sendData(t){const{webSocket:r}=this;if(!r){this.pendingData.push(t),this.connect();return}r.send(t)}clearWebSocket(){const{webSocket:t}=this;t&&(this.webSocket=null,t.onclose=null,t.onerror=null,t.onmessage=null,t.onopen=null)}}It.WalletLinkWebSocket=Jd;Object.defineProperty(un,"__esModule",{value:!0});un.WalletLinkConnection=void 0;const _t=ie,Gd=dn,Me=Dt,Bo=ke,mt=Ft,Zd=hn,Tr=It,Do=1e4,Qd=6e4;class Kd{constructor({session:t,linkAPIUrl:r,listener:n,diagnostic:s,WebSocketClass:i=WebSocket}){this.destroyed=!1,this.lastHeartbeatResponse=0,this.nextReqId=(0,_t.IntNumber)(1),this._connected=!1,this._linked=!1,this.shouldFetchUnseenEventsOnConnect=!1,this.requestResolutions=new Map,this.handleSessionMetadataUpdated=a=>{if(!a)return;new Map([["__destroyed",this.handleDestroyed],["EthereumAddress",this.handleAccountUpdated],["WalletUsername",this.handleWalletUsernameUpdated],["AppVersion",this.handleAppVersionUpdated],["ChainId",l=>a.JsonRpcUrl&&this.handleChainUpdated(l,a.JsonRpcUrl)]]).forEach((l,u)=>{const d=a[u];d!==void 0&&l(d)})},this.handleDestroyed=a=>{var c,l;a==="1"&&((c=this.listener)===null||c===void 0||c.resetAndReload(),(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.METADATA_DESTROYED,{alreadyDestroyed:this.isDestroyed,sessionIdHash:mt.Session.hash(this.session.id)}))},this.handleAccountUpdated=async a=>{var c,l;try{const u=await this.cipher.decrypt(a);(c=this.listener)===null||c===void 0||c.accountUpdated(u)}catch{(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"selectedAddress"})}},this.handleMetadataUpdated=async(a,c)=>{var l,u;try{const d=await this.cipher.decrypt(c);(l=this.listener)===null||l===void 0||l.metadataUpdated(a,d)}catch{(u=this.diagnostic)===null||u===void 0||u.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:a})}},this.handleWalletUsernameUpdated=async a=>{this.handleMetadataUpdated(Bo.WALLET_USER_NAME_KEY,a)},this.handleAppVersionUpdated=async a=>{this.handleMetadataUpdated(Bo.APP_VERSION_KEY,a)},this.handleChainUpdated=async(a,c)=>{var l,u;try{const d=await this.cipher.decrypt(a),h=await this.cipher.decrypt(c);(l=this.listener)===null||l===void 0||l.chainUpdated(d,h)}catch{(u=this.diagnostic)===null||u===void 0||u.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"chainId|jsonRpcUrl"})}},this.session=t,this.cipher=new Gd.Cipher(t.secret),this.diagnostic=s,this.listener=n;const o=new Tr.WalletLinkWebSocket(`${r}/rpc`,i);o.setConnectionStateListener(async a=>{var c;(c=this.diagnostic)===null||c===void 0||c.log(Me.EVENTS.CONNECTED_STATE_CHANGE,{state:a,sessionIdHash:mt.Session.hash(t.id)});let l=!1;switch(a){case Tr.ConnectionState.DISCONNECTED:if(!this.destroyed){const u=async()=>{await new Promise(d=>setTimeout(d,5e3)),this.destroyed||o.connect().catch(()=>{u()})};u()}break;case Tr.ConnectionState.CONNECTED:try{await this.authenticate(),this.sendIsLinked(),this.sendGetSessionConfig(),l=!0}catch{}this.updateLastHeartbeat(),setInterval(()=>{this.heartbeat()},Do),this.shouldFetchUnseenEventsOnConnect&&this.fetchUnseenEventsAPI();break;case Tr.ConnectionState.CONNECTING:break}this.connected!==l&&(this.connected=l)}),o.setIncomingDataListener(a=>{var c,l,u;switch(a.type){case"Heartbeat":this.updateLastHeartbeat();return;case"IsLinkedOK":case"Linked":{const d=a.type==="IsLinkedOK"?a.linked:void 0;(c=this.diagnostic)===null||c===void 0||c.log(Me.EVENTS.LINKED,{sessionIdHash:mt.Session.hash(t.id),linked:d,type:a.type,onlineGuests:a.onlineGuests}),this.linked=d||a.onlineGuests>0;break}case"GetSessionConfigOK":case"SessionConfigUpdated":{(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.SESSION_CONFIG_RECEIVED,{sessionIdHash:mt.Session.hash(t.id),metadata_keys:a&&a.metadata?Object.keys(a.metadata):void 0}),this.handleSessionMetadataUpdated(a.metadata);break}case"Event":{this.handleIncomingEvent(a);break}}a.id!==void 0&&((u=this.requestResolutions.get(a.id))===null||u===void 0||u(a))}),this.ws=o,this.http=new Zd.WalletLinkHTTP(r,t.id,t.key)}connect(){var t;if(this.destroyed)throw new Error("instance is destroyed");(t=this.diagnostic)===null||t===void 0||t.log(Me.EVENTS.STARTED_CONNECTING,{sessionIdHash:mt.Session.hash(this.session.id)}),this.ws.connect()}destroy(){var t;this.destroyed=!0,this.ws.disconnect(),(t=this.diagnostic)===null||t===void 0||t.log(Me.EVENTS.DISCONNECTED,{sessionIdHash:mt.Session.hash(this.session.id)}),this.listener=void 0}get isDestroyed(){return this.destroyed}get connected(){return this._connected}set connected(t){var r,n;this._connected=t,t&&((r=this.onceConnected)===null||r===void 0||r.call(this)),(n=this.listener)===null||n===void 0||n.connectedUpdated(t)}setOnceConnected(t){return new Promise(r=>{this.connected?t().then(r):this.onceConnected=()=>{t().then(r),this.onceConnected=void 0}})}get linked(){return this._linked}set linked(t){var r,n;this._linked=t,t&&((r=this.onceLinked)===null||r===void 0||r.call(this)),(n=this.listener)===null||n===void 0||n.linkedUpdated(t)}setOnceLinked(t){return new Promise(r=>{this.linked?t().then(r):this.onceLinked=()=>{t().then(r),this.onceLinked=void 0}})}async handleIncomingEvent(t){var r,n;if(!(t.type!=="Event"||t.event!=="Web3Response"))try{const s=await this.cipher.decrypt(t.data),i=JSON.parse(s);if(i.type!=="WEB3_RESPONSE")return;(r=this.listener)===null||r===void 0||r.handleWeb3ResponseMessage(i)}catch{(n=this.diagnostic)===null||n===void 0||n.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"incomingEvent"})}}async checkUnseenEvents(){if(!this.connected){this.shouldFetchUnseenEventsOnConnect=!0;return}await new Promise(t=>setTimeout(t,250));try{await this.fetchUnseenEventsAPI()}catch(t){console.error("Unable to check for unseen events",t)}}async fetchUnseenEventsAPI(){this.shouldFetchUnseenEventsOnConnect=!1,(await this.http.fetchUnseenEvents()).forEach(r=>this.handleIncomingEvent(r))}async setSessionMetadata(t,r){const n={type:"SetSessionConfig",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,metadata:{[t]:r}};return this.setOnceConnected(async()=>{const s=await this.makeRequest(n);if(s.type==="Fail")throw new Error(s.error||"failed to set session metadata")})}async publishEvent(t,r,n=!1){const s=await this.cipher.encrypt(JSON.stringify(Object.assign(Object.assign({},r),{origin:location.origin,relaySource:window.coinbaseWalletExtension?"injected_sdk":"sdk"}))),i={type:"PublishEvent",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,event:t,data:s,callWebhook:n};return this.setOnceLinked(async()=>{const o=await this.makeRequest(i);if(o.type==="Fail")throw new Error(o.error||"failed to publish event");return o.eventId})}sendData(t){this.ws.sendData(JSON.stringify(t))}updateLastHeartbeat(){this.lastHeartbeatResponse=Date.now()}heartbeat(){if(Date.now()-this.lastHeartbeatResponse>Do*2){this.ws.disconnect();return}try{this.ws.sendData("h")}catch{}}async makeRequest(t,r=Qd){const n=t.id;this.sendData(t);let s;return Promise.race([new Promise((i,o)=>{s=window.setTimeout(()=>{o(new Error(`request ${n} timed out`))},r)}),new Promise(i=>{this.requestResolutions.set(n,o=>{clearTimeout(s),i(o),this.requestResolutions.delete(n)})})])}async authenticate(){const t={type:"HostSession",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,sessionKey:this.session.key},r=await this.makeRequest(t);if(r.type==="Fail")throw new Error(r.error||"failed to authentcate")}sendIsLinked(){const t={type:"IsLinked",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id};this.sendData(t)}sendGetSessionConfig(){const t={type:"GetSessionConfig",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id};this.sendData(t)}}un.WalletLinkConnection=Kd;var fr={},gr={},Si={};Object.defineProperty(Si,"__esModule",{value:!0});Si.default='@namespace svg "http://www.w3.org/2000/svg";.-cbwsdk-css-reset,.-cbwsdk-css-reset *{animation:none;animation-delay:0;animation-direction:normal;animation-duration:0;animation-fill-mode:none;animation-iteration-count:1;animation-name:none;animation-play-state:running;animation-timing-function:ease;backface-visibility:visible;background:0;background-attachment:scroll;background-clip:border-box;background-color:rgba(0,0,0,0);background-image:none;background-origin:padding-box;background-position:0 0;background-position-x:0;background-position-y:0;background-repeat:repeat;background-size:auto auto;border:0;border-style:none;border-width:medium;border-color:inherit;border-bottom:0;border-bottom-color:inherit;border-bottom-left-radius:0;border-bottom-right-radius:0;border-bottom-style:none;border-bottom-width:medium;border-collapse:separate;border-image:none;border-left:0;border-left-color:inherit;border-left-style:none;border-left-width:medium;border-radius:0;border-right:0;border-right-color:inherit;border-right-style:none;border-right-width:medium;border-spacing:0;border-top:0;border-top-color:inherit;border-top-left-radius:0;border-top-right-radius:0;border-top-style:none;border-top-width:medium;box-shadow:none;box-sizing:border-box;caption-side:top;clear:none;clip:auto;color:inherit;columns:auto;column-count:auto;column-fill:balance;column-gap:normal;column-rule:medium none currentColor;column-rule-color:currentColor;column-rule-style:none;column-rule-width:none;column-span:1;column-width:auto;counter-increment:none;counter-reset:none;direction:ltr;empty-cells:show;float:none;font:normal;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;height:auto;hyphens:none;letter-spacing:normal;line-height:normal;list-style:none;list-style-image:none;list-style-position:outside;list-style-type:disc;margin:0;margin-bottom:0;margin-left:0;margin-right:0;margin-top:0;opacity:1;orphans:0;outline:0;outline-color:invert;outline-style:none;outline-width:medium;overflow:visible;overflow-x:visible;overflow-y:visible;padding:0;padding-bottom:0;padding-left:0;padding-right:0;padding-top:0;page-break-after:auto;page-break-before:auto;page-break-inside:auto;perspective:none;perspective-origin:50% 50%;pointer-events:auto;position:static;quotes:"\\201C" "\\201D" "\\2018" "\\2019";tab-size:8;table-layout:auto;text-align:inherit;text-align-last:auto;text-decoration:none;text-decoration-color:inherit;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-shadow:none;text-transform:none;transform:none;transform-style:flat;transition:none;transition-delay:0s;transition-duration:0s;transition-property:none;transition-timing-function:ease;unicode-bidi:normal;vertical-align:baseline;visibility:visible;white-space:normal;widows:0;word-spacing:normal;z-index:auto}.-cbwsdk-css-reset strong{font-weight:bold}.-cbwsdk-css-reset *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;line-height:1}.-cbwsdk-css-reset [class*=container]{margin:0;padding:0}.-cbwsdk-css-reset style{display:none}';var Xd=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(gr,"__esModule",{value:!0});gr.injectCssReset=void 0;const Yd=Xd(Si);function eh(){const e=document.createElement("style");e.type="text/css",e.appendChild(document.createTextNode(Yd.default)),document.documentElement.appendChild(e)}gr.injectCssReset=eh;var fn={},pr,G,lc,uc,rt,Fo,dc,hc,fc,ki,li,ui,gc,Xt={},pc=[],th=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,_r=Array.isArray;function Fe(e,t){for(var r in t)e[r]=t[r];return e}function Ci(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function di(e,t,r){var n,s,i,o={};for(i in t)i=="key"?n=t[i]:i=="ref"?s=t[i]:o[i]=t[i];if(arguments.length>2&&(o.children=arguments.length>3?pr.call(arguments,2):r),typeof e=="function"&&e.defaultProps!=null)for(i in e.defaultProps)o[i]===void 0&&(o[i]=e.defaultProps[i]);return Gt(e,o,n,s,null)}function Gt(e,t,r,n,s){var i={type:e,props:t,key:r,ref:n,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:s??++lc,__i:-1,__u:0};return s==null&&G.vnode!=null&&G.vnode(i),i}function rh(){return{current:null}}function mr(e){return e.children}function Zt(e,t){this.props=e,this.context=t}function At(e,t){if(t==null)return e.__?At(e.__,e.__i+1):null;for(var r;t<e.__k.length;t++)if((r=e.__k[t])!=null&&r.__e!=null)return r.__e;return typeof e.type=="function"?At(e):null}function _c(e){var t,r;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((r=e.__k[t])!=null&&r.__e!=null){e.__e=e.__c.base=r.__e;break}return _c(e)}}function hi(e){(!e.__d&&(e.__d=!0)&&rt.push(e)&&!Gr.__r++||Fo!=G.debounceRendering)&&((Fo=G.debounceRendering)||dc)(Gr)}function Gr(){for(var e,t,r,n,s,i,o,a=1;rt.length;)rt.length>a&&rt.sort(hc),e=rt.shift(),a=rt.length,e.__d&&(r=void 0,n=void 0,s=(n=(t=e).__v).__e,i=[],o=[],t.__P&&((r=Fe({},n)).__v=n.__v+1,G.vnode&&G.vnode(r),Ri(t.__P,r,n,t.__n,t.__P.namespaceURI,32&n.__u?[s]:null,i,s??At(n),!!(32&n.__u),o),r.__v=n.__v,r.__.__k[r.__i]=r,wc(i,r,o),n.__e=n.__=null,r.__e!=s&&_c(r)));Gr.__r=0}function mc(e,t,r,n,s,i,o,a,c,l,u){var d,h,f,b,g,E,y,p=n&&n.__k||pc,_=t.length;for(c=nh(r,t,p,c,_),d=0;d<_;d++)(f=r.__k[d])!=null&&(h=f.__i==-1?Xt:p[f.__i]||Xt,f.__i=d,E=Ri(e,f,h,s,i,o,a,c,l,u),b=f.__e,f.ref&&h.ref!=f.ref&&(h.ref&&Ii(h.ref,null,f),u.push(f.ref,f.__c||b,f)),g==null&&b!=null&&(g=b),(y=!!(4&f.__u))||h.__k===f.__k?c=bc(f,c,e,y):typeof f.type=="function"&&E!==void 0?c=E:b&&(c=b.nextSibling),f.__u&=-7);return r.__e=g,c}function nh(e,t,r,n,s){var i,o,a,c,l,u=r.length,d=u,h=0;for(e.__k=new Array(s),i=0;i<s;i++)(o=t[i])!=null&&typeof o!="boolean"&&typeof o!="function"?(typeof o=="string"||typeof o=="number"||typeof o=="bigint"||o.constructor==String?o=e.__k[i]=Gt(null,o,null,null,null):_r(o)?o=e.__k[i]=Gt(mr,{children:o},null,null,null):o.constructor==null&&o.__b>0?o=e.__k[i]=Gt(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):e.__k[i]=o,c=i+h,o.__=e,o.__b=e.__b+1,(l=o.__i=sh(o,r,c,d))!=-1&&(d--,(a=r[l])&&(a.__u|=2)),a==null||a.__v==null?(l==-1&&(s>u?h--:s<u&&h++),typeof o.type!="function"&&(o.__u|=4)):l!=c&&(l==c-1?h--:l==c+1?h++:(l>c?h--:h++,o.__u|=4))):e.__k[i]=null;if(d)for(i=0;i<u;i++)(a=r[i])!=null&&!(2&a.__u)&&(a.__e==n&&(n=At(a)),Ec(a,a));return n}function bc(e,t,r,n){var s,i;if(typeof e.type=="function"){for(s=e.__k,i=0;s&&i<s.length;i++)s[i]&&(s[i].__=e,t=bc(s[i],t,r,n));return t}e.__e!=t&&(n&&(t&&e.type&&!t.parentNode&&(t=At(e)),r.insertBefore(e.__e,t||null)),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function yc(e,t){return t=t||[],e==null||typeof e=="boolean"||(_r(e)?e.some(function(r){yc(r,t)}):t.push(e)),t}function sh(e,t,r,n){var s,i,o,a=e.key,c=e.type,l=t[r],u=l!=null&&(2&l.__u)==0;if(l===null&&a==null||u&&a==l.key&&c==l.type)return r;if(n>(u?1:0)){for(s=r-1,i=r+1;s>=0||i<t.length;)if((l=t[o=s>=0?s--:i++])!=null&&!(2&l.__u)&&a==l.key&&c==l.type)return o}return-1}function jo(e,t,r){t[0]=="-"?e.setProperty(t,r??""):e[t]=r==null?"":typeof r!="number"||th.test(t)?r:r+"px"}function Pr(e,t,r,n,s){var i,o;e:if(t=="style")if(typeof r=="string")e.style.cssText=r;else{if(typeof n=="string"&&(e.style.cssText=n=""),n)for(t in n)r&&t in r||jo(e.style,t,"");if(r)for(t in r)n&&r[t]==n[t]||jo(e.style,t,r[t])}else if(t[0]=="o"&&t[1]=="n")i=t!=(t=t.replace(fc,"$1")),o=t.toLowerCase(),t=o in e||t=="onFocusOut"||t=="onFocusIn"?o.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=r,r?n?r.u=n.u:(r.u=ki,e.addEventListener(t,i?ui:li,i)):e.removeEventListener(t,i?ui:li,i);else{if(s=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=r??"";break e}catch{}typeof r=="function"||(r==null||r===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&r==1?"":r))}}function $o(e){return function(t){if(this.l){var r=this.l[t.type+e];if(t.t==null)t.t=ki++;else if(t.t<r.u)return;return r(G.event?G.event(t):t)}}}function Ri(e,t,r,n,s,i,o,a,c,l){var u,d,h,f,b,g,E,y,p,_,A,v,N,V,Z,ee,z,W=t.type;if(t.constructor!=null)return null;128&r.__u&&(c=!!(32&r.__u),i=[a=t.__e=r.__e]),(u=G.__b)&&u(t);e:if(typeof W=="function")try{if(y=t.props,p="prototype"in W&&W.prototype.render,_=(u=W.contextType)&&n[u.__c],A=u?_?_.props.value:u.__:n,r.__c?E=(d=t.__c=r.__c).__=d.__E:(p?t.__c=d=new W(y,A):(t.__c=d=new Zt(y,A),d.constructor=W,d.render=oh),_&&_.sub(d),d.state||(d.state={}),d.__n=n,h=d.__d=!0,d.__h=[],d._sb=[]),p&&d.__s==null&&(d.__s=d.state),p&&W.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=Fe({},d.__s)),Fe(d.__s,W.getDerivedStateFromProps(y,d.__s))),f=d.props,b=d.state,d.__v=t,h)p&&W.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),p&&d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(p&&W.getDerivedStateFromProps==null&&y!==f&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(y,A),t.__v==r.__v||!d.__e&&d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(y,d.__s,A)===!1){for(t.__v!=r.__v&&(d.props=y,d.state=d.__s,d.__d=!1),t.__e=r.__e,t.__k=r.__k,t.__k.some(function(H){H&&(H.__=t)}),v=0;v<d._sb.length;v++)d.__h.push(d._sb[v]);d._sb=[],d.__h.length&&o.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(y,d.__s,A),p&&d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(f,b,g)})}if(d.context=A,d.props=y,d.__P=e,d.__e=!1,N=G.__r,V=0,p){for(d.state=d.__s,d.__d=!1,N&&N(t),u=d.render(d.props,d.state,d.context),Z=0;Z<d._sb.length;Z++)d.__h.push(d._sb[Z]);d._sb=[]}else do d.__d=!1,N&&N(t),u=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++V<25);d.state=d.__s,d.getChildContext!=null&&(n=Fe(Fe({},n),d.getChildContext())),p&&!h&&d.getSnapshotBeforeUpdate!=null&&(g=d.getSnapshotBeforeUpdate(f,b)),ee=u,u!=null&&u.type===mr&&u.key==null&&(ee=vc(u.props.children)),a=mc(e,_r(ee)?ee:[ee],t,r,n,s,i,o,a,c,l),d.base=t.__e,t.__u&=-161,d.__h.length&&o.push(d),E&&(d.__E=d.__=null)}catch(H){if(t.__v=null,c||i!=null)if(H.then){for(t.__u|=c?160:128;a&&a.nodeType==8&&a.nextSibling;)a=a.nextSibling;i[i.indexOf(a)]=null,t.__e=a}else{for(z=i.length;z--;)Ci(i[z]);fi(t)}else t.__e=r.__e,t.__k=r.__k,H.then||fi(t);G.__e(H,t,r)}else i==null&&t.__v==r.__v?(t.__k=r.__k,t.__e=r.__e):a=t.__e=ih(r.__e,t,r,n,s,i,o,c,l);return(u=G.diffed)&&u(t),128&t.__u?void 0:a}function fi(e){e&&e.__c&&(e.__c.__e=!0),e&&e.__k&&e.__k.forEach(fi)}function wc(e,t,r){for(var n=0;n<r.length;n++)Ii(r[n],r[++n],r[++n]);G.__c&&G.__c(t,e),e.some(function(s){try{e=s.__h,s.__h=[],e.some(function(i){i.call(s)})}catch(i){G.__e(i,s.__v)}})}function vc(e){return typeof e!="object"||e==null||e.__b&&e.__b>0?e:_r(e)?e.map(vc):Fe({},e)}function ih(e,t,r,n,s,i,o,a,c){var l,u,d,h,f,b,g,E=r.props||Xt,y=t.props,p=t.type;if(p=="svg"?s="http://www.w3.org/2000/svg":p=="math"?s="http://www.w3.org/1998/Math/MathML":s||(s="http://www.w3.org/1999/xhtml"),i!=null){for(l=0;l<i.length;l++)if((f=i[l])&&"setAttribute"in f==!!p&&(p?f.localName==p:f.nodeType==3)){e=f,i[l]=null;break}}if(e==null){if(p==null)return document.createTextNode(y);e=document.createElementNS(s,p,y.is&&y),a&&(G.__m&&G.__m(t,i),a=!1),i=null}if(p==null)E===y||a&&e.data==y||(e.data=y);else{if(i=i&&pr.call(e.childNodes),!a&&i!=null)for(E={},l=0;l<e.attributes.length;l++)E[(f=e.attributes[l]).name]=f.value;for(l in E)if(f=E[l],l!="children"){if(l=="dangerouslySetInnerHTML")d=f;else if(!(l in y)){if(l=="value"&&"defaultValue"in y||l=="checked"&&"defaultChecked"in y)continue;Pr(e,l,null,f,s)}}for(l in y)f=y[l],l=="children"?h=f:l=="dangerouslySetInnerHTML"?u=f:l=="value"?b=f:l=="checked"?g=f:a&&typeof f!="function"||E[l]===f||Pr(e,l,f,E[l],s);if(u)a||d&&(u.__html==d.__html||u.__html==e.innerHTML)||(e.innerHTML=u.__html),t.__k=[];else if(d&&(e.innerHTML=""),mc(t.type=="template"?e.content:e,_r(h)?h:[h],t,r,n,p=="foreignObject"?"http://www.w3.org/1999/xhtml":s,i,o,i?i[0]:r.__k&&At(r,0),a,c),i!=null)for(l=i.length;l--;)Ci(i[l]);a||(l="value",p=="progress"&&b==null?e.removeAttribute("value"):b!=null&&(b!==e[l]||p=="progress"&&!b||p=="option"&&b!=E[l])&&Pr(e,l,b,E[l],s),l="checked",g!=null&&g!=e[l]&&Pr(e,l,g,E[l],s))}return e}function Ii(e,t,r){try{if(typeof e=="function"){var n=typeof e.__u=="function";n&&e.__u(),n&&t==null||(e.__u=e(t))}else e.current=t}catch(s){G.__e(s,r)}}function Ec(e,t,r){var n,s;if(G.unmount&&G.unmount(e),(n=e.ref)&&(n.current&&n.current!=e.__e||Ii(n,null,t)),(n=e.__c)!=null){if(n.componentWillUnmount)try{n.componentWillUnmount()}catch(i){G.__e(i,t)}n.base=n.__P=null}if(n=e.__k)for(s=0;s<n.length;s++)n[s]&&Ec(n[s],t,r||typeof e.type!="function");r||Ci(e.__e),e.__c=e.__=e.__e=void 0}function oh(e,t,r){return this.constructor(e,r)}function Sc(e,t,r){var n,s,i,o;t==document&&(t=document.documentElement),G.__&&G.__(e,t),s=(n=typeof r=="function")?null:r&&r.__k||t.__k,i=[],o=[],Ri(t,e=(!n&&r||t).__k=di(mr,null,[e]),s||Xt,Xt,t.namespaceURI,!n&&r?[r]:s?null:t.firstChild?pr.call(t.childNodes):null,i,!n&&r?r:s?s.__e:t.firstChild,n,o),wc(i,e,o)}function kc(e,t){Sc(e,t,kc)}function ah(e,t,r){var n,s,i,o,a=Fe({},e.props);for(i in e.type&&e.type.defaultProps&&(o=e.type.defaultProps),t)i=="key"?n=t[i]:i=="ref"?s=t[i]:a[i]=t[i]===void 0&&o!=null?o[i]:t[i];return arguments.length>2&&(a.children=arguments.length>3?pr.call(arguments,2):r),Gt(e.type,a,n||e.key,s||e.ref,null)}function ch(e){function t(r){var n,s;return this.getChildContext||(n=new Set,(s={})[t.__c]=this,this.getChildContext=function(){return s},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(i){this.props.value!=i.value&&n.forEach(function(o){o.__e=!0,hi(o)})},this.sub=function(i){n.add(i);var o=i.componentWillUnmount;i.componentWillUnmount=function(){n&&n.delete(i),o&&o.call(i)}}),r.children}return t.__c="__cC"+gc++,t.__=e,t.Provider=t.__l=(t.Consumer=function(r,n){return r.children(n)}).contextType=t,t}pr=pc.slice,G={__e:function(e,t,r,n){for(var s,i,o;t=t.__;)if((s=t.__c)&&!s.__)try{if((i=s.constructor)&&i.getDerivedStateFromError!=null&&(s.setState(i.getDerivedStateFromError(e)),o=s.__d),s.componentDidCatch!=null&&(s.componentDidCatch(e,n||{}),o=s.__d),o)return s.__E=s}catch(a){e=a}throw e}},lc=0,uc=function(e){return e!=null&&e.constructor==null},Zt.prototype.setState=function(e,t){var r;r=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=Fe({},this.state),typeof e=="function"&&(e=e(Fe({},r),this.props)),e&&Fe(r,e),e!=null&&this.__v&&(t&&this._sb.push(t),hi(this))},Zt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),hi(this))},Zt.prototype.render=mr,rt=[],dc=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,hc=function(e,t){return e.__v.__b-t.__v.__b},Gr.__r=0,fc=/(PointerCapture)$|Capture$/i,ki=0,li=$o(!1),ui=$o(!0),gc=0;const lh=Object.freeze(Object.defineProperty({__proto__:null,Component:Zt,Fragment:mr,cloneElement:ah,createContext:ch,createElement:di,createRef:rh,h:di,hydrate:kc,get isValidElement(){return uc},get options(){return G},render:Sc,toChildArray:yc},Symbol.toStringTag,{value:"Module"})),_e=tr(lh);var gn={},ze,q,Us,Ho,xt=0,Cc=[],X=G,Uo=X.__b,Vo=X.__r,Wo=X.diffed,zo=X.__c,qo=X.unmount,Jo=X.__;function ht(e,t){X.__h&&X.__h(q,e,xt||t),xt=0;var r=q.__H||(q.__H={__:[],__h:[]});return e>=r.__.length&&r.__.push({}),r.__[e]}function Rc(e){return xt=1,Ic(xc,e)}function Ic(e,t,r){var n=ht(ze++,2);if(n.t=e,!n.__c&&(n.__=[r?r(t):xc(void 0,t),function(a){var c=n.__N?n.__N[0]:n.__[0],l=n.t(c,a);c!==l&&(n.__N=[l,n.__[1]],n.__c.setState({}))}],n.__c=q,!q.__f)){var s=function(a,c,l){if(!n.__c.__H)return!0;var u=n.__c.__H.__.filter(function(h){return!!h.__c});if(u.every(function(h){return!h.__N}))return!i||i.call(this,a,c,l);var d=n.__c.props!==a;return u.forEach(function(h){if(h.__N){var f=h.__[0];h.__=h.__N,h.__N=void 0,f!==h.__[0]&&(d=!0)}}),i&&i.call(this,a,c,l)||d};q.__f=!0;var i=q.shouldComponentUpdate,o=q.componentWillUpdate;q.componentWillUpdate=function(a,c,l){if(this.__e){var u=i;i=void 0,s(a,c,l),i=u}o&&o.call(this,a,c,l)},q.shouldComponentUpdate=s}return n.__N||n.__}function uh(e,t){var r=ht(ze++,3);!X.__s&&xi(r.__H,t)&&(r.__=e,r.u=t,q.__H.__h.push(r))}function Ac(e,t){var r=ht(ze++,4);!X.__s&&xi(r.__H,t)&&(r.__=e,r.u=t,q.__h.push(r))}function dh(e){return xt=5,Ai(function(){return{current:e}},[])}function hh(e,t,r){xt=6,Ac(function(){if(typeof e=="function"){var n=e(t());return function(){e(null),n&&typeof n=="function"&&n()}}if(e)return e.current=t(),function(){return e.current=null}},r==null?r:r.concat(e))}function Ai(e,t){var r=ht(ze++,7);return xi(r.__H,t)&&(r.__=e(),r.__H=t,r.__h=e),r.__}function fh(e,t){return xt=8,Ai(function(){return e},t)}function gh(e){var t=q.context[e.__c],r=ht(ze++,9);return r.c=e,t?(r.__==null&&(r.__=!0,t.sub(q)),t.props.value):e.__}function ph(e,t){X.useDebugValue&&X.useDebugValue(t?t(e):e)}function _h(e){var t=ht(ze++,10),r=Rc();return t.__=e,q.componentDidCatch||(q.componentDidCatch=function(n,s){t.__&&t.__(n,s),r[1](n)}),[r[0],function(){r[1](void 0)}]}function mh(){var e=ht(ze++,11);if(!e.__){for(var t=q.__v;t!==null&&!t.__m&&t.__!==null;)t=t.__;var r=t.__m||(t.__m=[0,0]);e.__="P"+r[0]+"-"+r[1]++}return e.__}function bh(){for(var e;e=Cc.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(qr),e.__H.__h.forEach(gi),e.__H.__h=[]}catch(t){e.__H.__h=[],X.__e(t,e.__v)}}X.__b=function(e){q=null,Uo&&Uo(e)},X.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Jo&&Jo(e,t)},X.__r=function(e){Vo&&Vo(e),ze=0;var t=(q=e.__c).__H;t&&(Us===q?(t.__h=[],q.__h=[],t.__.forEach(function(r){r.__N&&(r.__=r.__N),r.u=r.__N=void 0})):(t.__h.forEach(qr),t.__h.forEach(gi),t.__h=[],ze=0)),Us=q},X.diffed=function(e){Wo&&Wo(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Cc.push(t)!==1&&Ho===X.requestAnimationFrame||((Ho=X.requestAnimationFrame)||yh)(bh)),t.__H.__.forEach(function(r){r.u&&(r.__H=r.u),r.u=void 0})),Us=q=null},X.__c=function(e,t){t.some(function(r){try{r.__h.forEach(qr),r.__h=r.__h.filter(function(n){return!n.__||gi(n)})}catch(n){t.some(function(s){s.__h&&(s.__h=[])}),t=[],X.__e(n,r.__v)}}),zo&&zo(e,t)},X.unmount=function(e){qo&&qo(e);var t,r=e.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{qr(n)}catch(s){t=s}}),r.__H=void 0,t&&X.__e(t,r.__v))};var Go=typeof requestAnimationFrame=="function";function yh(e){var t,r=function(){clearTimeout(n),Go&&cancelAnimationFrame(t),setTimeout(e)},n=setTimeout(r,35);Go&&(t=requestAnimationFrame(r))}function qr(e){var t=q,r=e.__c;typeof r=="function"&&(e.__c=void 0,r()),q=t}function gi(e){var t=q;e.__c=e.__(),q=t}function xi(e,t){return!e||e.length!==t.length||t.some(function(r,n){return r!==e[n]})}function xc(e,t){return typeof t=="function"?t(e):t}const wh=Object.freeze(Object.defineProperty({__proto__:null,useCallback:fh,useContext:gh,useDebugValue:ph,useEffect:uh,useErrorBoundary:_h,useId:mh,useImperativeHandle:hh,useLayoutEffect:Ac,useMemo:Ai,useReducer:Ic,useRef:dh,useState:Rc},Symbol.toStringTag,{value:"Module"})),pn=tr(wh);var Nt={},_n={};Object.defineProperty(_n,"__esModule",{value:!0});_n.CloseIcon=void 0;const Zo=_e;function vh(e){return(0,Zo.h)("svg",Object.assign({width:"40",height:"40",viewBox:"0 0 40 40",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),(0,Zo.h)("path",{d:"M13.7677 13L12.3535 14.4142L18.3535 20.4142L12.3535 26.4142L13.7677 27.8284L19.7677 21.8284L25.7677 27.8284L27.1819 26.4142L21.1819 20.4142L27.1819 14.4142L25.7677 13L19.7677 19L13.7677 13Z"}))}_n.CloseIcon=vh;var mn={};Object.defineProperty(mn,"__esModule",{value:!0});mn.CoinbaseWalletRound=void 0;const Or=_e;function Eh(e){return(0,Or.h)("svg",Object.assign({width:"28",height:"28",viewBox:"0 0 28 28",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),(0,Or.h)("circle",{cx:"14",cy:"14",r:"14",fill:"#0052FF"}),(0,Or.h)("path",{d:"M23.8521 14.0003C23.8521 19.455 19.455 23.8521 14.0003 23.8521C8.54559 23.8521 4.14844 19.455 4.14844 14.0003C4.14844 8.54559 8.54559 4.14844 14.0003 4.14844C19.455 4.14844 23.8521 8.54559 23.8521 14.0003Z",fill:"white"}),(0,Or.h)("path",{d:"M11.1855 12.5042C11.1855 12.0477 11.1855 11.7942 11.2835 11.642C11.3814 11.4899 11.4793 11.3377 11.6261 11.287C11.8219 11.1855 12.0178 11.1855 12.5073 11.1855H15.4934C15.983 11.1855 16.1788 11.1855 16.3746 11.287C16.5215 11.3884 16.6683 11.4899 16.7173 11.642C16.8152 11.8449 16.8152 12.0477 16.8152 12.5042V15.4965C16.8152 15.953 16.8152 16.2066 16.7173 16.3587C16.6194 16.5109 16.5215 16.663 16.3746 16.7137C16.1788 16.8152 15.983 16.8152 15.4934 16.8152H12.5073C12.0178 16.8152 11.8219 16.8152 11.6261 16.7137C11.4793 16.6123 11.3324 16.5109 11.2835 16.3587C11.1855 16.1558 11.1855 15.953 11.1855 15.4965V12.5042Z",fill:"#0052FF"}))}mn.CoinbaseWalletRound=Eh;var bn={};Object.defineProperty(bn,"__esModule",{value:!0});bn.QRCodeIcon=void 0;const zt=_e;function Sh(e){return(0,zt.h)("svg",Object.assign({width:"18",height:"18",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),(0,zt.h)("path",{d:"M3 3V8.99939L5 8.99996V5H9V3H3Z"}),(0,zt.h)("path",{d:"M15 21L21 21V15.0006L19 15V19L15 19V21Z"}),(0,zt.h)("path",{d:"M21 9H19V5H15.0006L15 3H21V9Z"}),(0,zt.h)("path",{d:"M3 15V21H8.99939L8.99996 19H5L5 15H3Z"}))}bn.QRCodeIcon=Sh;var yn={};function Nc(e){this.mode=ye.MODE_8BIT_BYTE,this.data=e,this.parsedData=[];for(var t=0,r=this.data.length;t<r;t++){var n=[],s=this.data.charCodeAt(t);s>65536?(n[0]=240|(s&1835008)>>>18,n[1]=128|(s&258048)>>>12,n[2]=128|(s&4032)>>>6,n[3]=128|s&63):s>2048?(n[0]=224|(s&61440)>>>12,n[1]=128|(s&4032)>>>6,n[2]=128|s&63):s>128?(n[0]=192|(s&1984)>>>6,n[1]=128|s&63):n[0]=s,this.parsedData.push(n)}this.parsedData=Array.prototype.concat.apply([],this.parsedData),this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}Nc.prototype={getLength:function(e){return this.parsedData.length},write:function(e){for(var t=0,r=this.parsedData.length;t<r;t++)e.put(this.parsedData[t],8)}};function je(e,t){this.typeNumber=e,this.errorCorrectLevel=t,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}je.prototype={addData:function(e){var t=new Nc(e);this.dataList.push(t),this.dataCache=null},isDark:function(e,t){if(e<0||this.moduleCount<=e||t<0||this.moduleCount<=t)throw new Error(e+","+t);return this.modules[e][t]},getModuleCount:function(){return this.moduleCount},make:function(){this.makeImpl(!1,this.getBestMaskPattern())},makeImpl:function(e,t){this.moduleCount=this.typeNumber*4+17,this.modules=new Array(this.moduleCount);for(var r=0;r<this.moduleCount;r++){this.modules[r]=new Array(this.moduleCount);for(var n=0;n<this.moduleCount;n++)this.modules[r][n]=null}this.setupPositionProbePattern(0,0),this.setupPositionProbePattern(this.moduleCount-7,0),this.setupPositionProbePattern(0,this.moduleCount-7),this.setupPositionAdjustPattern(),this.setupTimingPattern(),this.setupTypeInfo(e,t),this.typeNumber>=7&&this.setupTypeNumber(e),this.dataCache==null&&(this.dataCache=je.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,t)},setupPositionProbePattern:function(e,t){for(var r=-1;r<=7;r++)if(!(e+r<=-1||this.moduleCount<=e+r))for(var n=-1;n<=7;n++)t+n<=-1||this.moduleCount<=t+n||(0<=r&&r<=6&&(n==0||n==6)||0<=n&&n<=6&&(r==0||r==6)||2<=r&&r<=4&&2<=n&&n<=4?this.modules[e+r][t+n]=!0:this.modules[e+r][t+n]=!1)},getBestMaskPattern:function(){for(var e=0,t=0,r=0;r<8;r++){this.makeImpl(!0,r);var n=K.getLostPoint(this);(r==0||e>n)&&(e=n,t=r)}return t},createMovieClip:function(e,t,r){var n=e.createEmptyMovieClip(t,r),s=1;this.make();for(var i=0;i<this.modules.length;i++)for(var o=i*s,a=0;a<this.modules[i].length;a++){var c=a*s,l=this.modules[i][a];l&&(n.beginFill(0,100),n.moveTo(c,o),n.lineTo(c+s,o),n.lineTo(c+s,o+s),n.lineTo(c,o+s),n.endFill())}return n},setupTimingPattern:function(){for(var e=8;e<this.moduleCount-8;e++)this.modules[e][6]==null&&(this.modules[e][6]=e%2==0);for(var t=8;t<this.moduleCount-8;t++)this.modules[6][t]==null&&(this.modules[6][t]=t%2==0)},setupPositionAdjustPattern:function(){for(var e=K.getPatternPosition(this.typeNumber),t=0;t<e.length;t++)for(var r=0;r<e.length;r++){var n=e[t],s=e[r];if(this.modules[n][s]==null)for(var i=-2;i<=2;i++)for(var o=-2;o<=2;o++)i==-2||i==2||o==-2||o==2||i==0&&o==0?this.modules[n+i][s+o]=!0:this.modules[n+i][s+o]=!1}},setupTypeNumber:function(e){for(var t=K.getBCHTypeNumber(this.typeNumber),r=0;r<18;r++){var n=!e&&(t>>r&1)==1;this.modules[Math.floor(r/3)][r%3+this.moduleCount-8-3]=n}for(var r=0;r<18;r++){var n=!e&&(t>>r&1)==1;this.modules[r%3+this.moduleCount-8-3][Math.floor(r/3)]=n}},setupTypeInfo:function(e,t){for(var r=this.errorCorrectLevel<<3|t,n=K.getBCHTypeInfo(r),s=0;s<15;s++){var i=!e&&(n>>s&1)==1;s<6?this.modules[s][8]=i:s<8?this.modules[s+1][8]=i:this.modules[this.moduleCount-15+s][8]=i}for(var s=0;s<15;s++){var i=!e&&(n>>s&1)==1;s<8?this.modules[8][this.moduleCount-s-1]=i:s<9?this.modules[8][15-s-1+1]=i:this.modules[8][15-s-1]=i}this.modules[this.moduleCount-8][8]=!e},mapData:function(e,t){for(var r=-1,n=this.moduleCount-1,s=7,i=0,o=this.moduleCount-1;o>0;o-=2)for(o==6&&o--;;){for(var a=0;a<2;a++)if(this.modules[n][o-a]==null){var c=!1;i<e.length&&(c=(e[i]>>>s&1)==1);var l=K.getMask(t,n,o-a);l&&(c=!c),this.modules[n][o-a]=c,s--,s==-1&&(i++,s=7)}if(n+=r,n<0||this.moduleCount<=n){n-=r,r=-r;break}}}};je.PAD0=236;je.PAD1=17;je.createData=function(e,t,r){for(var n=De.getRSBlocks(e,t),s=new Lc,i=0;i<r.length;i++){var o=r[i];s.put(o.mode,4),s.put(o.getLength(),K.getLengthInBits(o.mode,e)),o.write(s)}for(var a=0,i=0;i<n.length;i++)a+=n[i].dataCount;if(s.getLengthInBits()>a*8)throw new Error("code length overflow. ("+s.getLengthInBits()+">"+a*8+")");for(s.getLengthInBits()+4<=a*8&&s.put(0,4);s.getLengthInBits()%8!=0;)s.putBit(!1);for(;!(s.getLengthInBits()>=a*8||(s.put(je.PAD0,8),s.getLengthInBits()>=a*8));)s.put(je.PAD1,8);return je.createBytes(s,n)};je.createBytes=function(e,t){for(var r=0,n=0,s=0,i=new Array(t.length),o=new Array(t.length),a=0;a<t.length;a++){var c=t[a].dataCount,l=t[a].totalCount-c;n=Math.max(n,c),s=Math.max(s,l),i[a]=new Array(c);for(var u=0;u<i[a].length;u++)i[a][u]=255&e.buffer[u+r];r+=c;var d=K.getErrorCorrectPolynomial(l),h=new Et(i[a],d.getLength()-1),f=h.mod(d);o[a]=new Array(d.getLength()-1);for(var u=0;u<o[a].length;u++){var b=u+f.getLength()-o[a].length;o[a][u]=b>=0?f.get(b):0}}for(var g=0,u=0;u<t.length;u++)g+=t[u].totalCount;for(var E=new Array(g),y=0,u=0;u<n;u++)for(var a=0;a<t.length;a++)u<i[a].length&&(E[y++]=i[a][u]);for(var u=0;u<s;u++)for(var a=0;a<t.length;a++)u<o[a].length&&(E[y++]=o[a][u]);return E};var ye={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8},Ze={L:1,M:0,Q:3,H:2},qe={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7},K={PATTERN_POSITION_TABLE:[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],G15:1335,G18:7973,G15_MASK:21522,getBCHTypeInfo:function(e){for(var t=e<<10;K.getBCHDigit(t)-K.getBCHDigit(K.G15)>=0;)t^=K.G15<<K.getBCHDigit(t)-K.getBCHDigit(K.G15);return(e<<10|t)^K.G15_MASK},getBCHTypeNumber:function(e){for(var t=e<<12;K.getBCHDigit(t)-K.getBCHDigit(K.G18)>=0;)t^=K.G18<<K.getBCHDigit(t)-K.getBCHDigit(K.G18);return e<<12|t},getBCHDigit:function(e){for(var t=0;e!=0;)t++,e>>>=1;return t},getPatternPosition:function(e){return K.PATTERN_POSITION_TABLE[e-1]},getMask:function(e,t,r){switch(e){case qe.PATTERN000:return(t+r)%2==0;case qe.PATTERN001:return t%2==0;case qe.PATTERN010:return r%3==0;case qe.PATTERN011:return(t+r)%3==0;case qe.PATTERN100:return(Math.floor(t/2)+Math.floor(r/3))%2==0;case qe.PATTERN101:return t*r%2+t*r%3==0;case qe.PATTERN110:return(t*r%2+t*r%3)%2==0;case qe.PATTERN111:return(t*r%3+(t+r)%2)%2==0;default:throw new Error("bad maskPattern:"+e)}},getErrorCorrectPolynomial:function(e){for(var t=new Et([1],0),r=0;r<e;r++)t=t.multiply(new Et([1,le.gexp(r)],0));return t},getLengthInBits:function(e,t){if(1<=t&&t<10)switch(e){case ye.MODE_NUMBER:return 10;case ye.MODE_ALPHA_NUM:return 9;case ye.MODE_8BIT_BYTE:return 8;case ye.MODE_KANJI:return 8;default:throw new Error("mode:"+e)}else if(t<27)switch(e){case ye.MODE_NUMBER:return 12;case ye.MODE_ALPHA_NUM:return 11;case ye.MODE_8BIT_BYTE:return 16;case ye.MODE_KANJI:return 10;default:throw new Error("mode:"+e)}else if(t<41)switch(e){case ye.MODE_NUMBER:return 14;case ye.MODE_ALPHA_NUM:return 13;case ye.MODE_8BIT_BYTE:return 16;case ye.MODE_KANJI:return 12;default:throw new Error("mode:"+e)}else throw new Error("type:"+t)},getLostPoint:function(e){for(var t=e.getModuleCount(),r=0,n=0;n<t;n++)for(var s=0;s<t;s++){for(var i=0,o=e.isDark(n,s),a=-1;a<=1;a++)if(!(n+a<0||t<=n+a))for(var c=-1;c<=1;c++)s+c<0||t<=s+c||a==0&&c==0||o==e.isDark(n+a,s+c)&&i++;i>5&&(r+=3+i-5)}for(var n=0;n<t-1;n++)for(var s=0;s<t-1;s++){var l=0;e.isDark(n,s)&&l++,e.isDark(n+1,s)&&l++,e.isDark(n,s+1)&&l++,e.isDark(n+1,s+1)&&l++,(l==0||l==4)&&(r+=3)}for(var n=0;n<t;n++)for(var s=0;s<t-6;s++)e.isDark(n,s)&&!e.isDark(n,s+1)&&e.isDark(n,s+2)&&e.isDark(n,s+3)&&e.isDark(n,s+4)&&!e.isDark(n,s+5)&&e.isDark(n,s+6)&&(r+=40);for(var s=0;s<t;s++)for(var n=0;n<t-6;n++)e.isDark(n,s)&&!e.isDark(n+1,s)&&e.isDark(n+2,s)&&e.isDark(n+3,s)&&e.isDark(n+4,s)&&!e.isDark(n+5,s)&&e.isDark(n+6,s)&&(r+=40);for(var u=0,s=0;s<t;s++)for(var n=0;n<t;n++)e.isDark(n,s)&&u++;var d=Math.abs(100*u/t/t-50)/5;return r+=d*10,r}},le={glog:function(e){if(e<1)throw new Error("glog("+e+")");return le.LOG_TABLE[e]},gexp:function(e){for(;e<0;)e+=255;for(;e>=256;)e-=255;return le.EXP_TABLE[e]},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)};for(var de=0;de<8;de++)le.EXP_TABLE[de]=1<<de;for(var de=8;de<256;de++)le.EXP_TABLE[de]=le.EXP_TABLE[de-4]^le.EXP_TABLE[de-5]^le.EXP_TABLE[de-6]^le.EXP_TABLE[de-8];for(var de=0;de<255;de++)le.LOG_TABLE[le.EXP_TABLE[de]]=de;function Et(e,t){if(e.length==null)throw new Error(e.length+"/"+t);for(var r=0;r<e.length&&e[r]==0;)r++;this.num=new Array(e.length-r+t);for(var n=0;n<e.length-r;n++)this.num[n]=e[n+r]}Et.prototype={get:function(e){return this.num[e]},getLength:function(){return this.num.length},multiply:function(e){for(var t=new Array(this.getLength()+e.getLength()-1),r=0;r<this.getLength();r++)for(var n=0;n<e.getLength();n++)t[r+n]^=le.gexp(le.glog(this.get(r))+le.glog(e.get(n)));return new Et(t,0)},mod:function(e){if(this.getLength()-e.getLength()<0)return this;for(var t=le.glog(this.get(0))-le.glog(e.get(0)),r=new Array(this.getLength()),n=0;n<this.getLength();n++)r[n]=this.get(n);for(var n=0;n<e.getLength();n++)r[n]^=le.gexp(le.glog(e.get(n))+t);return new Et(r,0).mod(e)}};function De(e,t){this.totalCount=e,this.dataCount=t}De.RS_BLOCK_TABLE=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]];De.getRSBlocks=function(e,t){var r=De.getRsBlockTable(e,t);if(r==null)throw new Error("bad rs block @ typeNumber:"+e+"/errorCorrectLevel:"+t);for(var n=r.length/3,s=[],i=0;i<n;i++)for(var o=r[i*3+0],a=r[i*3+1],c=r[i*3+2],l=0;l<o;l++)s.push(new De(a,c));return s};De.getRsBlockTable=function(e,t){switch(t){case Ze.L:return De.RS_BLOCK_TABLE[(e-1)*4+0];case Ze.M:return De.RS_BLOCK_TABLE[(e-1)*4+1];case Ze.Q:return De.RS_BLOCK_TABLE[(e-1)*4+2];case Ze.H:return De.RS_BLOCK_TABLE[(e-1)*4+3];default:return}};function Lc(){this.buffer=[],this.length=0}Lc.prototype={get:function(e){var t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)==1},put:function(e,t){for(var r=0;r<t;r++)this.putBit((e>>>t-r-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(e){var t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var Vs=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]];function Mc(e){if(this.options={padding:4,width:256,height:256,typeNumber:4,color:"#000000",background:"#ffffff",ecl:"M",image:{svg:"",width:0,height:0}},typeof e=="string"&&(e={content:e}),e)for(var t in e)this.options[t]=e[t];if(typeof this.options.content!="string")throw new Error("Expected 'content' as string!");if(this.options.content.length===0)throw new Error("Expected 'content' to be non-empty!");if(!(this.options.padding>=0))throw new Error("Expected 'padding' value to be non-negative!");if(!(this.options.width>0)||!(this.options.height>0))throw new Error("Expected 'width' or 'height' value to be higher than zero!");function r(c){switch(c){case"L":return Ze.L;case"M":return Ze.M;case"Q":return Ze.Q;case"H":return Ze.H;default:throw new Error("Unknwon error correction level: "+c)}}function n(c,l){for(var u=s(c),d=1,h=0,f=0,b=Vs.length;f<=b;f++){var g=Vs[f];if(!g)throw new Error("Content too long: expected "+h+" but got "+u);switch(l){case"L":h=g[0];break;case"M":h=g[1];break;case"Q":h=g[2];break;case"H":h=g[3];break;default:throw new Error("Unknwon error correction level: "+l)}if(u<=h)break;d++}if(d>Vs.length)throw new Error("Content too long");return d}function s(c){var l=encodeURI(c).toString().replace(/\%[0-9a-fA-F]{2}/g,"a");return l.length+(l.length!=c?3:0)}var i=this.options.content,o=n(i,this.options.ecl),a=r(this.options.ecl);this.qrcode=new je(o,a),this.qrcode.addData(i),this.qrcode.make()}Mc.prototype.svg=function(e){var t=this.options||{},r=this.qrcode.modules;typeof e>"u"&&(e={container:t.container||"svg"});for(var n=typeof t.pretty<"u"?!!t.pretty:!0,s=n?" ":"",i=n?`\r
1
+ import{c as x,o as Xr,B as O,i as tr,p as $a,w as Ql,q as Kl,t as Xl,s as Yl,u as Pt,v as rr,x as Ha,e as Ua,y as eu,b as tu,z as ru,g as nu}from"./index-DM5z5s2K.js";import{E as Eo}from"./index-BBubfq4L.js";function su(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const s in n)if(s!=="default"&&!(s in e)){const i=Object.getOwnPropertyDescriptor(n,s);i&&Object.defineProperty(e,s,i.get?i:{enumerable:!0,get:()=>n[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var wi={},Kt={},Yr={};Object.defineProperty(Yr,"__esModule",{value:!0});Yr.walletLogo=void 0;const iu=(e,t)=>{let r;switch(e){case"standard":return r=t,`data:image/svg+xml,%3Csvg width='${t}' height='${r}' viewBox='0 0 1024 1024' fill='none' xmlns='http://www.w3.org/2000/svg'%3E %3Crect width='1024' height='1024' fill='%230052FF'/%3E %3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z' fill='white'/%3E %3C/svg%3E `;case"circle":return r=t,`data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='${t}' height='${r}' viewBox='0 0 999.81 999.81'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052fe;%7D.cls-2%7Bfill:%23fefefe;%7D.cls-3%7Bfill:%230152fe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M655-115.9h56c.83,1.59,2.36.88,3.56,1a478,478,0,0,1,75.06,10.42C891.4-81.76,978.33-32.58,1049.19,44q116.7,126,131.94,297.61c.38,4.14-.34,8.53,1.78,12.45v59c-1.58.84-.91,2.35-1,3.56a482.05,482.05,0,0,1-10.38,74.05c-24,106.72-76.64,196.76-158.83,268.93s-178.18,112.82-287.2,122.6c-4.83.43-9.86-.25-14.51,1.77H654c-1-1.68-2.69-.91-4.06-1a496.89,496.89,0,0,1-105.9-18.59c-93.54-27.42-172.78-77.59-236.91-150.94Q199.34,590.1,184.87,426.58c-.47-5.19.25-10.56-1.77-15.59V355c1.68-1,.91-2.7,1-4.06a498.12,498.12,0,0,1,18.58-105.9c26-88.75,72.64-164.9,140.6-227.57q126-116.27,297.21-131.61C645.32-114.57,650.35-113.88,655-115.9Zm377.92,500c0-192.44-156.31-349.49-347.56-350.15-194.13-.68-350.94,155.13-352.29,347.42-1.37,194.55,155.51,352.1,348.56,352.47C876.15,734.23,1032.93,577.84,1032.93,384.11Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-2' d='M1032.93,384.11c0,193.73-156.78,350.12-351.29,349.74-193-.37-349.93-157.92-348.56-352.47C334.43,189.09,491.24,33.28,685.37,34,876.62,34.62,1032.94,191.67,1032.93,384.11ZM683,496.81q43.74,0,87.48,0c15.55,0,25.32-9.72,25.33-25.21q0-87.48,0-175c0-15.83-9.68-25.46-25.59-25.46H595.77c-15.88,0-25.57,9.64-25.58,25.46q0,87.23,0,174.45c0,16.18,9.59,25.7,25.84,25.71Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-3' d='M683,496.81H596c-16.25,0-25.84-9.53-25.84-25.71q0-87.23,0-174.45c0-15.82,9.7-25.46,25.58-25.46H770.22c15.91,0,25.59,9.63,25.59,25.46q0,87.47,0,175c0,15.49-9.78,25.2-25.33,25.21Q726.74,496.84,683,496.81Z' transform='translate(-183.1 115.9)'/%3E%3C/svg%3E`;case"text":return r=(.1*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogo":return r=(.25*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`;case"textLight":return r=(.1*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogoLight":return r=(.25*t).toFixed(2),`data:image/svg+xml,%3Csvg width='${t}' height='${r}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`;default:return r=t,`data:image/svg+xml,%3Csvg width='${t}' height='${r}' viewBox='0 0 1024 1024' fill='none' xmlns='http://www.w3.org/2000/svg'%3E %3Crect width='1024' height='1024' fill='%230052FF'/%3E %3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z' fill='white'/%3E %3C/svg%3E `}};Yr.walletLogo=iu;var en={};Object.defineProperty(en,"__esModule",{value:!0});en.LINK_API_URL=void 0;en.LINK_API_URL="https://www.walletlink.org";var S={},nr={},We={};Object.defineProperty(We,"__esModule",{value:!0});We.errorValues=We.standardErrorCodes=void 0;We.standardErrorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901,unsupportedChain:4902}};We.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."},4902:{standard:"EIP-3085",message:"Unrecognized chain ID."}};var tn={},rn={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.serialize=e.getErrorCode=e.isValidCode=e.getMessageFromCode=e.JSON_RPC_SERVER_ERROR_MESSAGE=void 0;const t=We,r="Unspecified error message.";e.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.";function n(h,f=r){if(h&&Number.isInteger(h)){const b=h.toString();if(u(t.errorValues,b))return t.errorValues[b].message;if(c(h))return e.JSON_RPC_SERVER_ERROR_MESSAGE}return f}e.getMessageFromCode=n;function s(h){if(!Number.isInteger(h))return!1;const f=h.toString();return!!(t.errorValues[f]||c(h))}e.isValidCode=s;function i(h){var f;if(typeof h=="number")return h;if(o(h))return(f=h.code)!==null&&f!==void 0?f:h.errorCode}e.getErrorCode=i;function o(h){return typeof h=="object"&&h!==null&&(typeof h.code=="number"||typeof h.errorCode=="number")}function a(h,{shouldIncludeStack:f=!1}={}){const b={};if(h&&typeof h=="object"&&!Array.isArray(h)&&u(h,"code")&&s(h.code)){const g=h;b.code=g.code,g.message&&typeof g.message=="string"?(b.message=g.message,u(g,"data")&&(b.data=g.data)):(b.message=n(b.code),b.data={originalError:l(h)})}else b.code=t.standardErrorCodes.rpc.internal,b.message=d(h,"message")?h.message:r,b.data={originalError:l(h)};return f&&(b.stack=d(h,"stack")?h.stack:void 0),b}e.serialize=a;function c(h){return h>=-32099&&h<=-32e3}function l(h){return h&&typeof h=="object"&&!Array.isArray(h)?Object.assign({},h):h}function u(h,f){return Object.prototype.hasOwnProperty.call(h,f)}function d(h,f){return typeof h=="object"&&h!==null&&f in h&&typeof h[f]=="string"}})(rn);Object.defineProperty(tn,"__esModule",{value:!0});tn.standardErrors=void 0;const ue=We,Va=rn;tn.standardErrors={rpc:{parse:e=>ve(ue.standardErrorCodes.rpc.parse,e),invalidRequest:e=>ve(ue.standardErrorCodes.rpc.invalidRequest,e),invalidParams:e=>ve(ue.standardErrorCodes.rpc.invalidParams,e),methodNotFound:e=>ve(ue.standardErrorCodes.rpc.methodNotFound,e),internal:e=>ve(ue.standardErrorCodes.rpc.internal,e),server:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum RPC Server errors must provide single object argument.");const{code:t}=e;if(!Number.isInteger(t)||t>-32005||t<-32099)throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');return ve(t,e)},invalidInput:e=>ve(ue.standardErrorCodes.rpc.invalidInput,e),resourceNotFound:e=>ve(ue.standardErrorCodes.rpc.resourceNotFound,e),resourceUnavailable:e=>ve(ue.standardErrorCodes.rpc.resourceUnavailable,e),transactionRejected:e=>ve(ue.standardErrorCodes.rpc.transactionRejected,e),methodNotSupported:e=>ve(ue.standardErrorCodes.rpc.methodNotSupported,e),limitExceeded:e=>ve(ue.standardErrorCodes.rpc.limitExceeded,e)},provider:{userRejectedRequest:e=>pt(ue.standardErrorCodes.provider.userRejectedRequest,e),unauthorized:e=>pt(ue.standardErrorCodes.provider.unauthorized,e),unsupportedMethod:e=>pt(ue.standardErrorCodes.provider.unsupportedMethod,e),disconnected:e=>pt(ue.standardErrorCodes.provider.disconnected,e),chainDisconnected:e=>pt(ue.standardErrorCodes.provider.chainDisconnected,e),unsupportedChain:e=>pt(ue.standardErrorCodes.provider.unsupportedChain,e),custom:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum Provider custom errors must provide single object argument.");const{code:t,message:r,data:n}=e;if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string');return new qa(t,r,n)}}};function ve(e,t){const[r,n]=Wa(t);return new za(e,r||(0,Va.getMessageFromCode)(e),n)}function pt(e,t){const[r,n]=Wa(t);return new qa(e,r||(0,Va.getMessageFromCode)(e),n)}function Wa(e){if(e){if(typeof e=="string")return[e];if(typeof e=="object"&&!Array.isArray(e)){const{message:t,data:r}=e;if(t&&typeof t!="string")throw new Error("Must specify string message.");return[t||void 0,r]}}return[]}let za=class extends Error{constructor(t,r,n){if(!Number.isInteger(t))throw new Error('"code" must be an integer.');if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string.');super(r),this.code=t,n!==void 0&&(this.data=n)}},qa=class extends za{constructor(t,r,n){if(!ou(t))throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');super(t,r,n)}};function ou(e){return Number.isInteger(e)&&e>=1e3&&e<=4999}var nn={},Ot={};Object.defineProperty(Ot,"__esModule",{value:!0});Ot.isErrorResponse=void 0;function au(e){return e.errorMessage!==void 0}Ot.isErrorResponse=au;var Bt={};Object.defineProperty(Bt,"__esModule",{value:!0});Bt.LIB_VERSION=void 0;Bt.LIB_VERSION="3.9.3";Object.defineProperty(nn,"__esModule",{value:!0});nn.serializeError=void 0;const cu=Ot,lu=Bt,uu=We,du=rn;function hu(e,t){const r=(0,du.serialize)(fu(e),{shouldIncludeStack:!0}),n=new URL("https://docs.cloud.coinbase.com/wallet-sdk/docs/errors");n.searchParams.set("version",lu.LIB_VERSION),n.searchParams.set("code",r.code.toString());const s=gu(r.data,t);return s&&n.searchParams.set("method",s),n.searchParams.set("message",r.message),Object.assign(Object.assign({},r),{docUrl:n.href})}nn.serializeError=hu;function fu(e){return typeof e=="string"?{message:e,code:uu.standardErrorCodes.rpc.internal}:(0,cu.isErrorResponse)(e)?Object.assign(Object.assign({},e),{message:e.errorMessage,code:e.errorCode,data:{method:e.method}}):e}function gu(e,t){const r=e==null?void 0:e.method;if(r)return r;if(t!==void 0){if(typeof t=="string")return t;if(Array.isArray(t)){if(t.length>0)return t[0].method}else return t.method}}(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.standardErrors=e.standardErrorCodes=e.serializeError=e.getMessageFromCode=e.getErrorCode=void 0;const t=We;Object.defineProperty(e,"standardErrorCodes",{enumerable:!0,get:function(){return t.standardErrorCodes}});const r=tn;Object.defineProperty(e,"standardErrors",{enumerable:!0,get:function(){return r.standardErrors}});const n=nn;Object.defineProperty(e,"serializeError",{enumerable:!0,get:function(){return n.serializeError}});const s=rn;Object.defineProperty(e,"getErrorCode",{enumerable:!0,get:function(){return s.getErrorCode}}),Object.defineProperty(e,"getMessageFromCode",{enumerable:!0,get:function(){return s.getMessageFromCode}})})(nr);var ie={};Object.defineProperty(ie,"__esModule",{value:!0});ie.ProviderType=ie.RegExpString=ie.IntNumber=ie.BigIntString=ie.AddressString=ie.HexString=ie.OpaqueType=void 0;function sr(){return e=>e}ie.OpaqueType=sr;ie.HexString=sr();ie.AddressString=sr();ie.BigIntString=sr();function pu(e){return Math.floor(e)}ie.IntNumber=pu;ie.RegExpString=sr();var So;(function(e){e.CoinbaseWallet="CoinbaseWallet",e.MetaMask="MetaMask",e.Unselected=""})(So||(ie.ProviderType=So={}));var _u=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(S,"__esModule",{value:!0});S.isMobileWeb=S.getLocation=S.isInIFrame=S.createQrUrl=S.getFavicon=S.range=S.isBigNumber=S.ensureParsedJSONObject=S.ensureBN=S.ensureRegExpString=S.ensureIntNumber=S.ensureBuffer=S.ensureAddressString=S.ensureEvenLengthHexString=S.ensureHexString=S.isHexString=S.prepend0x=S.strip0x=S.has0xPrefix=S.hexStringFromIntNumber=S.intNumberFromHexString=S.bigIntStringFromBN=S.hexStringFromBuffer=S.hexStringToUint8Array=S.uint8ArrayToHex=S.randomBytesHex=void 0;const Ge=_u(Xr),ut=nr,Ce=ie,Ja=/^[0-9]*$/,Ga=/^[a-f0-9]*$/;function mu(e){return Za(crypto.getRandomValues(new Uint8Array(e)))}S.randomBytesHex=mu;function Za(e){return[...e].map(t=>t.toString(16).padStart(2,"0")).join("")}S.uint8ArrayToHex=Za;function bu(e){return new Uint8Array(e.match(/.{1,2}/g).map(t=>parseInt(t,16)))}S.hexStringToUint8Array=bu;function yu(e,t=!1){const r=e.toString("hex");return(0,Ce.HexString)(t?`0x${r}`:r)}S.hexStringFromBuffer=yu;function wu(e){return(0,Ce.BigIntString)(e.toString(10))}S.bigIntStringFromBN=wu;function vu(e){return(0,Ce.IntNumber)(new Ge.default(or(e,!1),16).toNumber())}S.intNumberFromHexString=vu;function Eu(e){return(0,Ce.HexString)(`0x${new Ge.default(e).toString(16)}`)}S.hexStringFromIntNumber=Eu;function vi(e){return e.startsWith("0x")||e.startsWith("0X")}S.has0xPrefix=vi;function sn(e){return vi(e)?e.slice(2):e}S.strip0x=sn;function Qa(e){return vi(e)?`0x${e.slice(2)}`:`0x${e}`}S.prepend0x=Qa;function ir(e){if(typeof e!="string")return!1;const t=sn(e).toLowerCase();return Ga.test(t)}S.isHexString=ir;function Ka(e,t=!1){if(typeof e=="string"){const r=sn(e).toLowerCase();if(Ga.test(r))return(0,Ce.HexString)(t?`0x${r}`:r)}throw ut.standardErrors.rpc.invalidParams(`"${String(e)}" is not a hexadecimal string`)}S.ensureHexString=Ka;function or(e,t=!1){let r=Ka(e,!1);return r.length%2===1&&(r=(0,Ce.HexString)(`0${r}`)),t?(0,Ce.HexString)(`0x${r}`):r}S.ensureEvenLengthHexString=or;function Su(e){if(typeof e=="string"){const t=sn(e).toLowerCase();if(ir(t)&&t.length===40)return(0,Ce.AddressString)(Qa(t))}throw ut.standardErrors.rpc.invalidParams(`Invalid Ethereum address: ${String(e)}`)}S.ensureAddressString=Su;function ku(e){if(O.isBuffer(e))return e;if(typeof e=="string"){if(ir(e)){const t=or(e,!1);return O.from(t,"hex")}return O.from(e,"utf8")}throw ut.standardErrors.rpc.invalidParams(`Not binary data: ${String(e)}`)}S.ensureBuffer=ku;function Xa(e){if(typeof e=="number"&&Number.isInteger(e))return(0,Ce.IntNumber)(e);if(typeof e=="string"){if(Ja.test(e))return(0,Ce.IntNumber)(Number(e));if(ir(e))return(0,Ce.IntNumber)(new Ge.default(or(e,!1),16).toNumber())}throw ut.standardErrors.rpc.invalidParams(`Not an integer: ${String(e)}`)}S.ensureIntNumber=Xa;function Cu(e){if(e instanceof RegExp)return(0,Ce.RegExpString)(e.toString());throw ut.standardErrors.rpc.invalidParams(`Not a RegExp: ${String(e)}`)}S.ensureRegExpString=Cu;function Ru(e){if(e!==null&&(Ge.default.isBN(e)||Ya(e)))return new Ge.default(e.toString(10),10);if(typeof e=="number")return new Ge.default(Xa(e));if(typeof e=="string"){if(Ja.test(e))return new Ge.default(e,10);if(ir(e))return new Ge.default(or(e,!1),16)}throw ut.standardErrors.rpc.invalidParams(`Not an integer: ${String(e)}`)}S.ensureBN=Ru;function Iu(e){if(typeof e=="string")return JSON.parse(e);if(typeof e=="object")return e;throw ut.standardErrors.rpc.invalidParams(`Not a JSON string or an object: ${String(e)}`)}S.ensureParsedJSONObject=Iu;function Ya(e){if(e==null||typeof e.constructor!="function")return!1;const{constructor:t}=e;return typeof t.config=="function"&&typeof t.EUCLID=="number"}S.isBigNumber=Ya;function Au(e,t){return Array.from({length:t-e},(r,n)=>e+n)}S.range=Au;function xu(){const e=document.querySelector('link[sizes="192x192"]')||document.querySelector('link[sizes="180x180"]')||document.querySelector('link[rel="icon"]')||document.querySelector('link[rel="shortcut icon"]'),{protocol:t,host:r}=document.location,n=e?e.getAttribute("href"):null;return!n||n.startsWith("javascript:")||n.startsWith("vbscript:")?null:n.startsWith("http://")||n.startsWith("https://")||n.startsWith("data:")?n:n.startsWith("//")?t+n:`${t}//${r}${n}`}S.getFavicon=xu;function Nu(e,t,r,n,s,i){const o=n?"parent-id":"id",a=new URLSearchParams({[o]:e,secret:t,server:r,v:s,chainId:i.toString()}).toString();return`${r}/#/link?${a}`}S.createQrUrl=Nu;function ec(){try{return window.frameElement!==null}catch{return!1}}S.isInIFrame=ec;function Lu(){try{return ec()&&window.top?window.top.location:window.location}catch{return window.location}}S.getLocation=Lu;function Mu(){var e;return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test((e=window==null?void 0:window.navigator)===null||e===void 0?void 0:e.userAgent)}S.isMobileWeb=Mu;var on={};Object.defineProperty(on,"__esModule",{value:!0});on.ScopedLocalStorage=void 0;class Tu{constructor(t){this.scope=t}setItem(t,r){localStorage.setItem(this.scopedKey(t),r)}getItem(t){return localStorage.getItem(this.scopedKey(t))}removeItem(t){localStorage.removeItem(this.scopedKey(t))}clear(){const t=this.scopedKey(""),r=[];for(let n=0;n<localStorage.length;n++){const s=localStorage.key(n);typeof s=="string"&&s.startsWith(t)&&r.push(s)}r.forEach(n=>localStorage.removeItem(n))}scopedKey(t){return`${this.scope}:${t}`}}on.ScopedLocalStorage=Tu;var Rt={};const Pu=Object.freeze(Object.defineProperty({__proto__:null,EventEmitter:Eo,default:Eo},Symbol.toStringTag,{value:"Module"})),Ou=tr(Pu);var ar={},cr={},Dt={};Object.defineProperty(Dt,"__esModule",{value:!0});Dt.EVENTS=void 0;Dt.EVENTS={STARTED_CONNECTING:"walletlink_sdk.started.connecting",CONNECTED_STATE_CHANGE:"walletlink_sdk.connected",DISCONNECTED:"walletlink_sdk.disconnected",METADATA_DESTROYED:"walletlink_sdk_metadata_destroyed",LINKED:"walletlink_sdk.linked",FAILURE:"walletlink_sdk.generic_failure",SESSION_CONFIG_RECEIVED:"walletlink_sdk.session_config_event_received",ETH_ACCOUNTS_STATE:"walletlink_sdk.eth_accounts_state",SESSION_STATE_CHANGE:"walletlink_sdk.session_state_change",UNLINKED_ERROR_STATE:"walletlink_sdk.unlinked_error_state",SKIPPED_CLEARING_SESSION:"walletlink_sdk.skipped_clearing_session",GENERAL_ERROR:"walletlink_sdk.general_error",WEB3_REQUEST:"walletlink_sdk.web3.request",WEB3_REQUEST_PUBLISHED:"walletlink_sdk.web3.request_published",WEB3_RESPONSE:"walletlink_sdk.web3.response",METHOD_NOT_IMPLEMENTED:"walletlink_sdk.method_not_implemented",UNKNOWN_ADDRESS_ENCOUNTERED:"walletlink_sdk.unknown_address_encountered"};var ke={};Object.defineProperty(ke,"__esModule",{value:!0});ke.RelayAbstract=ke.APP_VERSION_KEY=ke.LOCAL_STORAGE_ADDRESSES_KEY=ke.WALLET_USER_NAME_KEY=void 0;const ko=nr;ke.WALLET_USER_NAME_KEY="walletUsername";ke.LOCAL_STORAGE_ADDRESSES_KEY="Addresses";ke.APP_VERSION_KEY="AppVersion";class Bu{async makeEthereumJSONRPCRequest(t,r){if(!r)throw new Error("Error: No jsonRpcUrl provided");return window.fetch(r,{method:"POST",body:JSON.stringify(t),mode:"cors",headers:{"Content-Type":"application/json"}}).then(n=>n.json()).then(n=>{if(!n)throw ko.standardErrors.rpc.parse({});const s=n,{error:i}=s;if(i)throw(0,ko.serializeError)(i,t.method);return s})}}ke.RelayAbstract=Bu;var Ft={},tc={exports:{}},ai={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(e,t){var r=$a(),n=r.Buffer;function s(o,a){for(var c in o)a[c]=o[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(s(r,t),t.Buffer=i);function i(o,a,c){return n(o,a,c)}i.prototype=Object.create(n.prototype),s(n,i),i.from=function(o,a,c){if(typeof o=="number")throw new TypeError("Argument must not be a number");return n(o,a,c)},i.alloc=function(o,a,c){if(typeof o!="number")throw new TypeError("Argument must be a number");var l=n(o);return a!==void 0?typeof c=="string"?l.fill(a,c):l.fill(a):l.fill(0),l},i.allocUnsafe=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return n(o)},i.allocUnsafeSlow=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(o)}})(ai,ai.exports);var dt=ai.exports,ci={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(e,t){var r=$a(),n=r.Buffer;function s(o,a){for(var c in o)a[c]=o[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(s(r,t),t.Buffer=i);function i(o,a,c){return n(o,a,c)}i.prototype=Object.create(n.prototype),s(n,i),i.from=function(o,a,c){if(typeof o=="number")throw new TypeError("Argument must not be a number");return n(o,a,c)},i.alloc=function(o,a,c){if(typeof o!="number")throw new TypeError("Argument must be a number");var l=n(o);return a!==void 0?typeof c=="string"?l.fill(a,c):l.fill(a):l.fill(0),l},i.allocUnsafe=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return n(o)},i.allocUnsafeSlow=function(o){if(typeof o!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(o)}})(ci,ci.exports);var Du=ci.exports,Hs,Co;function Fu(){if(Co)return Hs;Co=1;var e=Ql;return Hs=function(r){return!!e(r)},Hs}var ju=Xl,$u=Kl,Hu=$u("TypedArray.prototype.buffer",!0),Uu=Fu(),Vu=Hu||function(t){if(!Uu(t))throw new ju("Not a Typed Array");return t.buffer},Ne=Du.Buffer,Wu=Yl,zu=Vu,qu=ArrayBuffer.isView||function(t){try{return zu(t),!0}catch{return!1}},Ju=typeof Uint8Array<"u",rc=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",Gu=rc&&(Ne.prototype instanceof Uint8Array||Ne.TYPED_ARRAY_SUPPORT),Zu=function(t,r){if(Ne.isBuffer(t))return t.constructor&&!("isBuffer"in t)?Ne.from(t):t;if(typeof t=="string")return Ne.from(t,r);if(rc&&qu(t)){if(t.byteLength===0)return Ne.alloc(0);if(Gu){var n=Ne.from(t.buffer,t.byteOffset,t.byteLength);if(n.byteLength===t.byteLength)return n}var s=t instanceof Uint8Array?t:new Uint8Array(t.buffer,t.byteOffset,t.byteLength),i=Ne.from(s);if(i.length===t.byteLength)return i}if(Ju&&t instanceof Uint8Array)return Ne.from(t);var o=Wu(t);if(o)for(var a=0;a<t.length;a+=1){var c=t[a];if(typeof c!="number"||c<0||c>255||~~c!==c)throw new RangeError("Array items must be numbers in the range 0-255.")}if(o||Ne.isBuffer(t)&&t.constructor&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t))return Ne.from(t);throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')},Qu=dt.Buffer,Ku=Zu;function an(e,t){this._block=Qu.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}an.prototype.update=function(e,t){e=Ku(e,t||"utf8");for(var r=this._block,n=this._blockSize,s=e.length,i=this._len,o=0;o<s;){for(var a=i%n,c=Math.min(s-o,n-a),l=0;l<c;l++)r[a+l]=e[o+l];i+=c,o+=c,i%n===0&&this._update(r)}return this._len+=s,this};an.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=this._len*8;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(r&4294967295)>>>0,s=(r-n)/4294967296;this._block.writeUInt32BE(s,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var i=this._hash();return e?i.toString(e):i};an.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var jt=an,Xu=Pt,nc=jt,Yu=dt.Buffer,ed=[1518500249,1859775393,-1894007588,-899497514],td=new Array(80);function lr(){this.init(),this._w=td,nc.call(this,64,56)}Xu(lr,nc);lr.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function rd(e){return e<<5|e>>>27}function nd(e){return e<<30|e>>>2}function sd(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}lr.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=0;a<16;++a)t[a]=e.readInt32BE(a*4);for(;a<80;++a)t[a]=t[a-3]^t[a-8]^t[a-14]^t[a-16];for(var c=0;c<80;++c){var l=~~(c/20),u=rd(r)+sd(l,n,s,i)+o+t[c]+ed[l]|0;o=i,i=s,s=nd(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};lr.prototype._hash=function(){var e=Yu.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var id=lr,od=Pt,sc=jt,ad=dt.Buffer,cd=[1518500249,1859775393,-1894007588,-899497514],ld=new Array(80);function ur(){this.init(),this._w=ld,sc.call(this,64,56)}od(ur,sc);ur.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function ud(e){return e<<1|e>>>31}function dd(e){return e<<5|e>>>27}function hd(e){return e<<30|e>>>2}function fd(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}ur.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=0;a<16;++a)t[a]=e.readInt32BE(a*4);for(;a<80;++a)t[a]=ud(t[a-3]^t[a-8]^t[a-14]^t[a-16]);for(var c=0;c<80;++c){var l=~~(c/20),u=dd(r)+fd(l,n,s,i)+o+t[c]+cd[l]|0;o=i,i=s,s=hd(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0};ur.prototype._hash=function(){var e=ad.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var gd=ur,pd=Pt,ic=jt,_d=dt.Buffer,md=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],bd=new Array(64);function dr(){this.init(),this._w=bd,ic.call(this,64,56)}pd(dr,ic);dr.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function yd(e,t,r){return r^e&(t^r)}function wd(e,t,r){return e&t|r&(e|t)}function vd(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function Ed(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function Sd(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function kd(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}dr.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,s=this._c|0,i=this._d|0,o=this._e|0,a=this._f|0,c=this._g|0,l=this._h|0,u=0;u<16;++u)t[u]=e.readInt32BE(u*4);for(;u<64;++u)t[u]=kd(t[u-2])+t[u-7]+Sd(t[u-15])+t[u-16]|0;for(var d=0;d<64;++d){var h=l+Ed(o)+yd(o,a,c)+md[d]+t[d]|0,f=vd(r)+wd(r,n,s)|0;l=c,c=a,a=o,o=i+h|0,i=s,s=n,n=r,r=h+f|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=i+this._d|0,this._e=o+this._e|0,this._f=a+this._f|0,this._g=c+this._g|0,this._h=l+this._h|0};dr.prototype._hash=function(){var e=_d.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e};var oc=dr,Cd=Pt,Rd=oc,Id=jt,Ad=dt.Buffer,xd=new Array(64);function cn(){this.init(),this._w=xd,Id.call(this,64,56)}Cd(cn,Rd);cn.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this};cn.prototype._hash=function(){var e=Ad.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e};var Nd=cn,Ld=Pt,ac=jt,Md=dt.Buffer,Ro=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],Td=new Array(160);function hr(){this.init(),this._w=Td,ac.call(this,128,112)}Ld(hr,ac);hr.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function Io(e,t,r){return r^e&(t^r)}function Ao(e,t,r){return e&t|r&(e|t)}function xo(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function No(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function Pd(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function Od(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function Bd(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function Dd(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function ce(e,t){return e>>>0<t>>>0?1:0}hr.prototype._update=function(e){for(var t=this._w,r=this._ah|0,n=this._bh|0,s=this._ch|0,i=this._dh|0,o=this._eh|0,a=this._fh|0,c=this._gh|0,l=this._hh|0,u=this._al|0,d=this._bl|0,h=this._cl|0,f=this._dl|0,b=this._el|0,g=this._fl|0,E=this._gl|0,y=this._hl|0,p=0;p<32;p+=2)t[p]=e.readInt32BE(p*4),t[p+1]=e.readInt32BE(p*4+4);for(;p<160;p+=2){var _=t[p-30],A=t[p-15*2+1],v=Pd(_,A),N=Od(A,_);_=t[p-2*2],A=t[p-2*2+1];var V=Bd(_,A),Z=Dd(A,_),ee=t[p-7*2],z=t[p-7*2+1],W=t[p-16*2],H=t[p-16*2+1],se=N+z|0,w=v+ee+ce(se,N)|0;se=se+Z|0,w=w+V+ce(se,Z)|0,se=se+H|0,w=w+W+ce(se,H)|0,t[p]=w,t[p+1]=se}for(var m=0;m<160;m+=2){w=t[m],se=t[m+1];var R=Ao(r,n,s),C=Ao(u,d,h),I=xo(r,u),k=xo(u,r),L=No(o,b),D=No(b,o),T=Ro[m],U=Ro[m+1],ae=Io(o,a,c),J=Io(b,g,E),te=y+D|0,Ie=l+L+ce(te,y)|0;te=te+J|0,Ie=Ie+ae+ce(te,J)|0,te=te+U|0,Ie=Ie+T+ce(te,U)|0,te=te+se|0,Ie=Ie+w+ce(te,se)|0;var Wt=k+C|0,Lr=I+R+ce(Wt,k)|0;l=c,y=E,c=a,E=g,a=o,g=b,b=f+te|0,o=i+Ie+ce(b,f)|0,i=s,f=h,s=n,h=d,n=r,d=u,u=te+Wt|0,r=Ie+Lr+ce(u,te)|0}this._al=this._al+u|0,this._bl=this._bl+d|0,this._cl=this._cl+h|0,this._dl=this._dl+f|0,this._el=this._el+b|0,this._fl=this._fl+g|0,this._gl=this._gl+E|0,this._hl=this._hl+y|0,this._ah=this._ah+r+ce(this._al,u)|0,this._bh=this._bh+n+ce(this._bl,d)|0,this._ch=this._ch+s+ce(this._cl,h)|0,this._dh=this._dh+i+ce(this._dl,f)|0,this._eh=this._eh+o+ce(this._el,b)|0,this._fh=this._fh+a+ce(this._fl,g)|0,this._gh=this._gh+c+ce(this._gl,E)|0,this._hh=this._hh+l+ce(this._hl,y)|0};hr.prototype._hash=function(){var e=Md.allocUnsafe(64);function t(r,n,s){e.writeInt32BE(r,s),e.writeInt32BE(n,s+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e};var cc=hr,Fd=Pt,jd=cc,$d=jt,Hd=dt.Buffer,Ud=new Array(160);function ln(){this.init(),this._w=Ud,$d.call(this,128,112)}Fd(ln,jd);ln.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this};ln.prototype._hash=function(){var e=Hd.allocUnsafe(48);function t(r,n,s){e.writeInt32BE(r,s),e.writeInt32BE(n,s+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e};var Vd=ln;(function(e){e.exports=function(r){var n=r.toLowerCase(),s=e.exports[n];if(!s)throw new Error(n+" is not supported (we accept pull requests)");return new s},e.exports.sha=id,e.exports.sha1=gd,e.exports.sha224=Nd,e.exports.sha256=oc,e.exports.sha384=Vd,e.exports.sha512=cc})(tc);var Wd=tc.exports;Object.defineProperty(Ft,"__esModule",{value:!0});Ft.Session=void 0;const Lo=Wd,Mo=S,To="session:id",Po="session:secret",Oo="session:linked";class Ei{constructor(t,r,n,s){this._storage=t,this._id=r||(0,Mo.randomBytesHex)(16),this._secret=n||(0,Mo.randomBytesHex)(32),this._key=new Lo.sha256().update(`${this._id}, ${this._secret} WalletLink`).digest("hex"),this._linked=!!s}static load(t){const r=t.getItem(To),n=t.getItem(Oo),s=t.getItem(Po);return r&&s?new Ei(t,r,s,n==="1"):null}static hash(t){return new Lo.sha256().update(t).digest("hex")}get id(){return this._id}get secret(){return this._secret}get key(){return this._key}get linked(){return this._linked}set linked(t){this._linked=t,this.persistLinked()}save(){return this._storage.setItem(To,this._id),this._storage.setItem(Po,this._secret),this.persistLinked(),this}persistLinked(){this._storage.setItem(Oo,this._linked?"1":"0")}}Ft.Session=Ei;var un={},dn={};Object.defineProperty(dn,"__esModule",{value:!0});dn.Cipher=void 0;const Mr=S;class zd{constructor(t){this.secret=t}async encrypt(t){const r=this.secret;if(r.length!==64)throw Error("secret must be 256 bits");const n=crypto.getRandomValues(new Uint8Array(12)),s=await crypto.subtle.importKey("raw",(0,Mr.hexStringToUint8Array)(r),{name:"aes-gcm"},!1,["encrypt","decrypt"]),i=new TextEncoder,o=await window.crypto.subtle.encrypt({name:"AES-GCM",iv:n},s,i.encode(t)),a=16,c=o.slice(o.byteLength-a),l=o.slice(0,o.byteLength-a),u=new Uint8Array(c),d=new Uint8Array(l),h=new Uint8Array([...n,...u,...d]);return(0,Mr.uint8ArrayToHex)(h)}async decrypt(t){const r=this.secret;if(r.length!==64)throw Error("secret must be 256 bits");return new Promise((n,s)=>{(async function(){const i=await crypto.subtle.importKey("raw",(0,Mr.hexStringToUint8Array)(r),{name:"aes-gcm"},!1,["encrypt","decrypt"]),o=(0,Mr.hexStringToUint8Array)(t),a=o.slice(0,12),c=o.slice(12,28),l=o.slice(28),u=new Uint8Array([...l,...c]),d={name:"AES-GCM",iv:new Uint8Array(a)};try{const h=await window.crypto.subtle.decrypt(d,i,u),f=new TextDecoder;n(f.decode(h))}catch(h){s(h)}})()})}}dn.Cipher=zd;var hn={};Object.defineProperty(hn,"__esModule",{value:!0});hn.WalletLinkHTTP=void 0;class qd{constructor(t,r,n){this.linkAPIUrl=t,this.sessionId=r;const s=`${r}:${n}`;this.auth=`Basic ${btoa(s)}`}async markUnseenEventsAsSeen(t){return Promise.all(t.map(r=>fetch(`${this.linkAPIUrl}/events/${r.eventId}/seen`,{method:"POST",headers:{Authorization:this.auth}}))).catch(r=>console.error("Unabled to mark event as failed:",r))}async fetchUnseenEvents(){var t;const r=await fetch(`${this.linkAPIUrl}/events?unseen=true`,{headers:{Authorization:this.auth}});if(r.ok){const{events:n,error:s}=await r.json();if(s)throw new Error(`Check unseen events failed: ${s}`);const i=(t=n==null?void 0:n.filter(o=>o.event==="Web3Response").map(o=>({type:"Event",sessionId:this.sessionId,eventId:o.id,event:o.event,data:o.data})))!==null&&t!==void 0?t:[];return this.markUnseenEventsAsSeen(i),i}throw new Error(`Check unseen events failed: ${r.status}`)}}hn.WalletLinkHTTP=qd;var It={};Object.defineProperty(It,"__esModule",{value:!0});It.WalletLinkWebSocket=It.ConnectionState=void 0;var vt;(function(e){e[e.DISCONNECTED=0]="DISCONNECTED",e[e.CONNECTING=1]="CONNECTING",e[e.CONNECTED=2]="CONNECTED"})(vt||(It.ConnectionState=vt={}));class Jd{setConnectionStateListener(t){this.connectionStateListener=t}setIncomingDataListener(t){this.incomingDataListener=t}constructor(t,r=WebSocket){this.WebSocketClass=r,this.webSocket=null,this.pendingData=[],this.url=t.replace(/^http/,"ws")}async connect(){if(this.webSocket)throw new Error("webSocket object is not null");return new Promise((t,r)=>{var n;let s;try{this.webSocket=s=new this.WebSocketClass(this.url)}catch(i){r(i);return}(n=this.connectionStateListener)===null||n===void 0||n.call(this,vt.CONNECTING),s.onclose=i=>{var o;this.clearWebSocket(),r(new Error(`websocket error ${i.code}: ${i.reason}`)),(o=this.connectionStateListener)===null||o===void 0||o.call(this,vt.DISCONNECTED)},s.onopen=i=>{var o;t(),(o=this.connectionStateListener)===null||o===void 0||o.call(this,vt.CONNECTED),this.pendingData.length>0&&([...this.pendingData].forEach(c=>this.sendData(c)),this.pendingData=[])},s.onmessage=i=>{var o,a;if(i.data==="h")(o=this.incomingDataListener)===null||o===void 0||o.call(this,{type:"Heartbeat"});else try{const c=JSON.parse(i.data);(a=this.incomingDataListener)===null||a===void 0||a.call(this,c)}catch{}}})}disconnect(){var t;const{webSocket:r}=this;if(r){this.clearWebSocket(),(t=this.connectionStateListener)===null||t===void 0||t.call(this,vt.DISCONNECTED),this.connectionStateListener=void 0,this.incomingDataListener=void 0;try{r.close()}catch{}}}sendData(t){const{webSocket:r}=this;if(!r){this.pendingData.push(t),this.connect();return}r.send(t)}clearWebSocket(){const{webSocket:t}=this;t&&(this.webSocket=null,t.onclose=null,t.onerror=null,t.onmessage=null,t.onopen=null)}}It.WalletLinkWebSocket=Jd;Object.defineProperty(un,"__esModule",{value:!0});un.WalletLinkConnection=void 0;const _t=ie,Gd=dn,Me=Dt,Bo=ke,mt=Ft,Zd=hn,Tr=It,Do=1e4,Qd=6e4;class Kd{constructor({session:t,linkAPIUrl:r,listener:n,diagnostic:s,WebSocketClass:i=WebSocket}){this.destroyed=!1,this.lastHeartbeatResponse=0,this.nextReqId=(0,_t.IntNumber)(1),this._connected=!1,this._linked=!1,this.shouldFetchUnseenEventsOnConnect=!1,this.requestResolutions=new Map,this.handleSessionMetadataUpdated=a=>{if(!a)return;new Map([["__destroyed",this.handleDestroyed],["EthereumAddress",this.handleAccountUpdated],["WalletUsername",this.handleWalletUsernameUpdated],["AppVersion",this.handleAppVersionUpdated],["ChainId",l=>a.JsonRpcUrl&&this.handleChainUpdated(l,a.JsonRpcUrl)]]).forEach((l,u)=>{const d=a[u];d!==void 0&&l(d)})},this.handleDestroyed=a=>{var c,l;a==="1"&&((c=this.listener)===null||c===void 0||c.resetAndReload(),(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.METADATA_DESTROYED,{alreadyDestroyed:this.isDestroyed,sessionIdHash:mt.Session.hash(this.session.id)}))},this.handleAccountUpdated=async a=>{var c,l;try{const u=await this.cipher.decrypt(a);(c=this.listener)===null||c===void 0||c.accountUpdated(u)}catch{(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"selectedAddress"})}},this.handleMetadataUpdated=async(a,c)=>{var l,u;try{const d=await this.cipher.decrypt(c);(l=this.listener)===null||l===void 0||l.metadataUpdated(a,d)}catch{(u=this.diagnostic)===null||u===void 0||u.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:a})}},this.handleWalletUsernameUpdated=async a=>{this.handleMetadataUpdated(Bo.WALLET_USER_NAME_KEY,a)},this.handleAppVersionUpdated=async a=>{this.handleMetadataUpdated(Bo.APP_VERSION_KEY,a)},this.handleChainUpdated=async(a,c)=>{var l,u;try{const d=await this.cipher.decrypt(a),h=await this.cipher.decrypt(c);(l=this.listener)===null||l===void 0||l.chainUpdated(d,h)}catch{(u=this.diagnostic)===null||u===void 0||u.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"chainId|jsonRpcUrl"})}},this.session=t,this.cipher=new Gd.Cipher(t.secret),this.diagnostic=s,this.listener=n;const o=new Tr.WalletLinkWebSocket(`${r}/rpc`,i);o.setConnectionStateListener(async a=>{var c;(c=this.diagnostic)===null||c===void 0||c.log(Me.EVENTS.CONNECTED_STATE_CHANGE,{state:a,sessionIdHash:mt.Session.hash(t.id)});let l=!1;switch(a){case Tr.ConnectionState.DISCONNECTED:if(!this.destroyed){const u=async()=>{await new Promise(d=>setTimeout(d,5e3)),this.destroyed||o.connect().catch(()=>{u()})};u()}break;case Tr.ConnectionState.CONNECTED:try{await this.authenticate(),this.sendIsLinked(),this.sendGetSessionConfig(),l=!0}catch{}this.updateLastHeartbeat(),setInterval(()=>{this.heartbeat()},Do),this.shouldFetchUnseenEventsOnConnect&&this.fetchUnseenEventsAPI();break;case Tr.ConnectionState.CONNECTING:break}this.connected!==l&&(this.connected=l)}),o.setIncomingDataListener(a=>{var c,l,u;switch(a.type){case"Heartbeat":this.updateLastHeartbeat();return;case"IsLinkedOK":case"Linked":{const d=a.type==="IsLinkedOK"?a.linked:void 0;(c=this.diagnostic)===null||c===void 0||c.log(Me.EVENTS.LINKED,{sessionIdHash:mt.Session.hash(t.id),linked:d,type:a.type,onlineGuests:a.onlineGuests}),this.linked=d||a.onlineGuests>0;break}case"GetSessionConfigOK":case"SessionConfigUpdated":{(l=this.diagnostic)===null||l===void 0||l.log(Me.EVENTS.SESSION_CONFIG_RECEIVED,{sessionIdHash:mt.Session.hash(t.id),metadata_keys:a&&a.metadata?Object.keys(a.metadata):void 0}),this.handleSessionMetadataUpdated(a.metadata);break}case"Event":{this.handleIncomingEvent(a);break}}a.id!==void 0&&((u=this.requestResolutions.get(a.id))===null||u===void 0||u(a))}),this.ws=o,this.http=new Zd.WalletLinkHTTP(r,t.id,t.key)}connect(){var t;if(this.destroyed)throw new Error("instance is destroyed");(t=this.diagnostic)===null||t===void 0||t.log(Me.EVENTS.STARTED_CONNECTING,{sessionIdHash:mt.Session.hash(this.session.id)}),this.ws.connect()}destroy(){var t;this.destroyed=!0,this.ws.disconnect(),(t=this.diagnostic)===null||t===void 0||t.log(Me.EVENTS.DISCONNECTED,{sessionIdHash:mt.Session.hash(this.session.id)}),this.listener=void 0}get isDestroyed(){return this.destroyed}get connected(){return this._connected}set connected(t){var r,n;this._connected=t,t&&((r=this.onceConnected)===null||r===void 0||r.call(this)),(n=this.listener)===null||n===void 0||n.connectedUpdated(t)}setOnceConnected(t){return new Promise(r=>{this.connected?t().then(r):this.onceConnected=()=>{t().then(r),this.onceConnected=void 0}})}get linked(){return this._linked}set linked(t){var r,n;this._linked=t,t&&((r=this.onceLinked)===null||r===void 0||r.call(this)),(n=this.listener)===null||n===void 0||n.linkedUpdated(t)}setOnceLinked(t){return new Promise(r=>{this.linked?t().then(r):this.onceLinked=()=>{t().then(r),this.onceLinked=void 0}})}async handleIncomingEvent(t){var r,n;if(!(t.type!=="Event"||t.event!=="Web3Response"))try{const s=await this.cipher.decrypt(t.data),i=JSON.parse(s);if(i.type!=="WEB3_RESPONSE")return;(r=this.listener)===null||r===void 0||r.handleWeb3ResponseMessage(i)}catch{(n=this.diagnostic)===null||n===void 0||n.log(Me.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"incomingEvent"})}}async checkUnseenEvents(){if(!this.connected){this.shouldFetchUnseenEventsOnConnect=!0;return}await new Promise(t=>setTimeout(t,250));try{await this.fetchUnseenEventsAPI()}catch(t){console.error("Unable to check for unseen events",t)}}async fetchUnseenEventsAPI(){this.shouldFetchUnseenEventsOnConnect=!1,(await this.http.fetchUnseenEvents()).forEach(r=>this.handleIncomingEvent(r))}async setSessionMetadata(t,r){const n={type:"SetSessionConfig",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,metadata:{[t]:r}};return this.setOnceConnected(async()=>{const s=await this.makeRequest(n);if(s.type==="Fail")throw new Error(s.error||"failed to set session metadata")})}async publishEvent(t,r,n=!1){const s=await this.cipher.encrypt(JSON.stringify(Object.assign(Object.assign({},r),{origin:location.origin,relaySource:window.coinbaseWalletExtension?"injected_sdk":"sdk"}))),i={type:"PublishEvent",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,event:t,data:s,callWebhook:n};return this.setOnceLinked(async()=>{const o=await this.makeRequest(i);if(o.type==="Fail")throw new Error(o.error||"failed to publish event");return o.eventId})}sendData(t){this.ws.sendData(JSON.stringify(t))}updateLastHeartbeat(){this.lastHeartbeatResponse=Date.now()}heartbeat(){if(Date.now()-this.lastHeartbeatResponse>Do*2){this.ws.disconnect();return}try{this.ws.sendData("h")}catch{}}async makeRequest(t,r=Qd){const n=t.id;this.sendData(t);let s;return Promise.race([new Promise((i,o)=>{s=window.setTimeout(()=>{o(new Error(`request ${n} timed out`))},r)}),new Promise(i=>{this.requestResolutions.set(n,o=>{clearTimeout(s),i(o),this.requestResolutions.delete(n)})})])}async authenticate(){const t={type:"HostSession",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id,sessionKey:this.session.key},r=await this.makeRequest(t);if(r.type==="Fail")throw new Error(r.error||"failed to authentcate")}sendIsLinked(){const t={type:"IsLinked",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id};this.sendData(t)}sendGetSessionConfig(){const t={type:"GetSessionConfig",id:(0,_t.IntNumber)(this.nextReqId++),sessionId:this.session.id};this.sendData(t)}}un.WalletLinkConnection=Kd;var fr={},gr={},Si={};Object.defineProperty(Si,"__esModule",{value:!0});Si.default='@namespace svg "http://www.w3.org/2000/svg";.-cbwsdk-css-reset,.-cbwsdk-css-reset *{animation:none;animation-delay:0;animation-direction:normal;animation-duration:0;animation-fill-mode:none;animation-iteration-count:1;animation-name:none;animation-play-state:running;animation-timing-function:ease;backface-visibility:visible;background:0;background-attachment:scroll;background-clip:border-box;background-color:rgba(0,0,0,0);background-image:none;background-origin:padding-box;background-position:0 0;background-position-x:0;background-position-y:0;background-repeat:repeat;background-size:auto auto;border:0;border-style:none;border-width:medium;border-color:inherit;border-bottom:0;border-bottom-color:inherit;border-bottom-left-radius:0;border-bottom-right-radius:0;border-bottom-style:none;border-bottom-width:medium;border-collapse:separate;border-image:none;border-left:0;border-left-color:inherit;border-left-style:none;border-left-width:medium;border-radius:0;border-right:0;border-right-color:inherit;border-right-style:none;border-right-width:medium;border-spacing:0;border-top:0;border-top-color:inherit;border-top-left-radius:0;border-top-right-radius:0;border-top-style:none;border-top-width:medium;box-shadow:none;box-sizing:border-box;caption-side:top;clear:none;clip:auto;color:inherit;columns:auto;column-count:auto;column-fill:balance;column-gap:normal;column-rule:medium none currentColor;column-rule-color:currentColor;column-rule-style:none;column-rule-width:none;column-span:1;column-width:auto;counter-increment:none;counter-reset:none;direction:ltr;empty-cells:show;float:none;font:normal;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;height:auto;hyphens:none;letter-spacing:normal;line-height:normal;list-style:none;list-style-image:none;list-style-position:outside;list-style-type:disc;margin:0;margin-bottom:0;margin-left:0;margin-right:0;margin-top:0;opacity:1;orphans:0;outline:0;outline-color:invert;outline-style:none;outline-width:medium;overflow:visible;overflow-x:visible;overflow-y:visible;padding:0;padding-bottom:0;padding-left:0;padding-right:0;padding-top:0;page-break-after:auto;page-break-before:auto;page-break-inside:auto;perspective:none;perspective-origin:50% 50%;pointer-events:auto;position:static;quotes:"\\201C" "\\201D" "\\2018" "\\2019";tab-size:8;table-layout:auto;text-align:inherit;text-align-last:auto;text-decoration:none;text-decoration-color:inherit;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-shadow:none;text-transform:none;transform:none;transform-style:flat;transition:none;transition-delay:0s;transition-duration:0s;transition-property:none;transition-timing-function:ease;unicode-bidi:normal;vertical-align:baseline;visibility:visible;white-space:normal;widows:0;word-spacing:normal;z-index:auto}.-cbwsdk-css-reset strong{font-weight:bold}.-cbwsdk-css-reset *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;line-height:1}.-cbwsdk-css-reset [class*=container]{margin:0;padding:0}.-cbwsdk-css-reset style{display:none}';var Xd=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(gr,"__esModule",{value:!0});gr.injectCssReset=void 0;const Yd=Xd(Si);function eh(){const e=document.createElement("style");e.type="text/css",e.appendChild(document.createTextNode(Yd.default)),document.documentElement.appendChild(e)}gr.injectCssReset=eh;var fn={},pr,G,lc,uc,rt,Fo,dc,hc,fc,ki,li,ui,gc,Xt={},pc=[],th=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,_r=Array.isArray;function Fe(e,t){for(var r in t)e[r]=t[r];return e}function Ci(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function di(e,t,r){var n,s,i,o={};for(i in t)i=="key"?n=t[i]:i=="ref"?s=t[i]:o[i]=t[i];if(arguments.length>2&&(o.children=arguments.length>3?pr.call(arguments,2):r),typeof e=="function"&&e.defaultProps!=null)for(i in e.defaultProps)o[i]===void 0&&(o[i]=e.defaultProps[i]);return Gt(e,o,n,s,null)}function Gt(e,t,r,n,s){var i={type:e,props:t,key:r,ref:n,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:s??++lc,__i:-1,__u:0};return s==null&&G.vnode!=null&&G.vnode(i),i}function rh(){return{current:null}}function mr(e){return e.children}function Zt(e,t){this.props=e,this.context=t}function At(e,t){if(t==null)return e.__?At(e.__,e.__i+1):null;for(var r;t<e.__k.length;t++)if((r=e.__k[t])!=null&&r.__e!=null)return r.__e;return typeof e.type=="function"?At(e):null}function _c(e){var t,r;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((r=e.__k[t])!=null&&r.__e!=null){e.__e=e.__c.base=r.__e;break}return _c(e)}}function hi(e){(!e.__d&&(e.__d=!0)&&rt.push(e)&&!Gr.__r++||Fo!=G.debounceRendering)&&((Fo=G.debounceRendering)||dc)(Gr)}function Gr(){for(var e,t,r,n,s,i,o,a=1;rt.length;)rt.length>a&&rt.sort(hc),e=rt.shift(),a=rt.length,e.__d&&(r=void 0,n=void 0,s=(n=(t=e).__v).__e,i=[],o=[],t.__P&&((r=Fe({},n)).__v=n.__v+1,G.vnode&&G.vnode(r),Ri(t.__P,r,n,t.__n,t.__P.namespaceURI,32&n.__u?[s]:null,i,s??At(n),!!(32&n.__u),o),r.__v=n.__v,r.__.__k[r.__i]=r,wc(i,r,o),n.__e=n.__=null,r.__e!=s&&_c(r)));Gr.__r=0}function mc(e,t,r,n,s,i,o,a,c,l,u){var d,h,f,b,g,E,y,p=n&&n.__k||pc,_=t.length;for(c=nh(r,t,p,c,_),d=0;d<_;d++)(f=r.__k[d])!=null&&(h=f.__i==-1?Xt:p[f.__i]||Xt,f.__i=d,E=Ri(e,f,h,s,i,o,a,c,l,u),b=f.__e,f.ref&&h.ref!=f.ref&&(h.ref&&Ii(h.ref,null,f),u.push(f.ref,f.__c||b,f)),g==null&&b!=null&&(g=b),(y=!!(4&f.__u))||h.__k===f.__k?c=bc(f,c,e,y):typeof f.type=="function"&&E!==void 0?c=E:b&&(c=b.nextSibling),f.__u&=-7);return r.__e=g,c}function nh(e,t,r,n,s){var i,o,a,c,l,u=r.length,d=u,h=0;for(e.__k=new Array(s),i=0;i<s;i++)(o=t[i])!=null&&typeof o!="boolean"&&typeof o!="function"?(typeof o=="string"||typeof o=="number"||typeof o=="bigint"||o.constructor==String?o=e.__k[i]=Gt(null,o,null,null,null):_r(o)?o=e.__k[i]=Gt(mr,{children:o},null,null,null):o.constructor==null&&o.__b>0?o=e.__k[i]=Gt(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):e.__k[i]=o,c=i+h,o.__=e,o.__b=e.__b+1,(l=o.__i=sh(o,r,c,d))!=-1&&(d--,(a=r[l])&&(a.__u|=2)),a==null||a.__v==null?(l==-1&&(s>u?h--:s<u&&h++),typeof o.type!="function"&&(o.__u|=4)):l!=c&&(l==c-1?h--:l==c+1?h++:(l>c?h--:h++,o.__u|=4))):e.__k[i]=null;if(d)for(i=0;i<u;i++)(a=r[i])!=null&&!(2&a.__u)&&(a.__e==n&&(n=At(a)),Ec(a,a));return n}function bc(e,t,r,n){var s,i;if(typeof e.type=="function"){for(s=e.__k,i=0;s&&i<s.length;i++)s[i]&&(s[i].__=e,t=bc(s[i],t,r,n));return t}e.__e!=t&&(n&&(t&&e.type&&!t.parentNode&&(t=At(e)),r.insertBefore(e.__e,t||null)),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function yc(e,t){return t=t||[],e==null||typeof e=="boolean"||(_r(e)?e.some(function(r){yc(r,t)}):t.push(e)),t}function sh(e,t,r,n){var s,i,o,a=e.key,c=e.type,l=t[r],u=l!=null&&(2&l.__u)==0;if(l===null&&a==null||u&&a==l.key&&c==l.type)return r;if(n>(u?1:0)){for(s=r-1,i=r+1;s>=0||i<t.length;)if((l=t[o=s>=0?s--:i++])!=null&&!(2&l.__u)&&a==l.key&&c==l.type)return o}return-1}function jo(e,t,r){t[0]=="-"?e.setProperty(t,r??""):e[t]=r==null?"":typeof r!="number"||th.test(t)?r:r+"px"}function Pr(e,t,r,n,s){var i,o;e:if(t=="style")if(typeof r=="string")e.style.cssText=r;else{if(typeof n=="string"&&(e.style.cssText=n=""),n)for(t in n)r&&t in r||jo(e.style,t,"");if(r)for(t in r)n&&r[t]==n[t]||jo(e.style,t,r[t])}else if(t[0]=="o"&&t[1]=="n")i=t!=(t=t.replace(fc,"$1")),o=t.toLowerCase(),t=o in e||t=="onFocusOut"||t=="onFocusIn"?o.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=r,r?n?r.u=n.u:(r.u=ki,e.addEventListener(t,i?ui:li,i)):e.removeEventListener(t,i?ui:li,i);else{if(s=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=r??"";break e}catch{}typeof r=="function"||(r==null||r===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&r==1?"":r))}}function $o(e){return function(t){if(this.l){var r=this.l[t.type+e];if(t.t==null)t.t=ki++;else if(t.t<r.u)return;return r(G.event?G.event(t):t)}}}function Ri(e,t,r,n,s,i,o,a,c,l){var u,d,h,f,b,g,E,y,p,_,A,v,N,V,Z,ee,z,W=t.type;if(t.constructor!=null)return null;128&r.__u&&(c=!!(32&r.__u),i=[a=t.__e=r.__e]),(u=G.__b)&&u(t);e:if(typeof W=="function")try{if(y=t.props,p="prototype"in W&&W.prototype.render,_=(u=W.contextType)&&n[u.__c],A=u?_?_.props.value:u.__:n,r.__c?E=(d=t.__c=r.__c).__=d.__E:(p?t.__c=d=new W(y,A):(t.__c=d=new Zt(y,A),d.constructor=W,d.render=oh),_&&_.sub(d),d.state||(d.state={}),d.__n=n,h=d.__d=!0,d.__h=[],d._sb=[]),p&&d.__s==null&&(d.__s=d.state),p&&W.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=Fe({},d.__s)),Fe(d.__s,W.getDerivedStateFromProps(y,d.__s))),f=d.props,b=d.state,d.__v=t,h)p&&W.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),p&&d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(p&&W.getDerivedStateFromProps==null&&y!==f&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(y,A),t.__v==r.__v||!d.__e&&d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(y,d.__s,A)===!1){for(t.__v!=r.__v&&(d.props=y,d.state=d.__s,d.__d=!1),t.__e=r.__e,t.__k=r.__k,t.__k.some(function(H){H&&(H.__=t)}),v=0;v<d._sb.length;v++)d.__h.push(d._sb[v]);d._sb=[],d.__h.length&&o.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(y,d.__s,A),p&&d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(f,b,g)})}if(d.context=A,d.props=y,d.__P=e,d.__e=!1,N=G.__r,V=0,p){for(d.state=d.__s,d.__d=!1,N&&N(t),u=d.render(d.props,d.state,d.context),Z=0;Z<d._sb.length;Z++)d.__h.push(d._sb[Z]);d._sb=[]}else do d.__d=!1,N&&N(t),u=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++V<25);d.state=d.__s,d.getChildContext!=null&&(n=Fe(Fe({},n),d.getChildContext())),p&&!h&&d.getSnapshotBeforeUpdate!=null&&(g=d.getSnapshotBeforeUpdate(f,b)),ee=u,u!=null&&u.type===mr&&u.key==null&&(ee=vc(u.props.children)),a=mc(e,_r(ee)?ee:[ee],t,r,n,s,i,o,a,c,l),d.base=t.__e,t.__u&=-161,d.__h.length&&o.push(d),E&&(d.__E=d.__=null)}catch(H){if(t.__v=null,c||i!=null)if(H.then){for(t.__u|=c?160:128;a&&a.nodeType==8&&a.nextSibling;)a=a.nextSibling;i[i.indexOf(a)]=null,t.__e=a}else{for(z=i.length;z--;)Ci(i[z]);fi(t)}else t.__e=r.__e,t.__k=r.__k,H.then||fi(t);G.__e(H,t,r)}else i==null&&t.__v==r.__v?(t.__k=r.__k,t.__e=r.__e):a=t.__e=ih(r.__e,t,r,n,s,i,o,c,l);return(u=G.diffed)&&u(t),128&t.__u?void 0:a}function fi(e){e&&e.__c&&(e.__c.__e=!0),e&&e.__k&&e.__k.forEach(fi)}function wc(e,t,r){for(var n=0;n<r.length;n++)Ii(r[n],r[++n],r[++n]);G.__c&&G.__c(t,e),e.some(function(s){try{e=s.__h,s.__h=[],e.some(function(i){i.call(s)})}catch(i){G.__e(i,s.__v)}})}function vc(e){return typeof e!="object"||e==null||e.__b&&e.__b>0?e:_r(e)?e.map(vc):Fe({},e)}function ih(e,t,r,n,s,i,o,a,c){var l,u,d,h,f,b,g,E=r.props||Xt,y=t.props,p=t.type;if(p=="svg"?s="http://www.w3.org/2000/svg":p=="math"?s="http://www.w3.org/1998/Math/MathML":s||(s="http://www.w3.org/1999/xhtml"),i!=null){for(l=0;l<i.length;l++)if((f=i[l])&&"setAttribute"in f==!!p&&(p?f.localName==p:f.nodeType==3)){e=f,i[l]=null;break}}if(e==null){if(p==null)return document.createTextNode(y);e=document.createElementNS(s,p,y.is&&y),a&&(G.__m&&G.__m(t,i),a=!1),i=null}if(p==null)E===y||a&&e.data==y||(e.data=y);else{if(i=i&&pr.call(e.childNodes),!a&&i!=null)for(E={},l=0;l<e.attributes.length;l++)E[(f=e.attributes[l]).name]=f.value;for(l in E)if(f=E[l],l!="children"){if(l=="dangerouslySetInnerHTML")d=f;else if(!(l in y)){if(l=="value"&&"defaultValue"in y||l=="checked"&&"defaultChecked"in y)continue;Pr(e,l,null,f,s)}}for(l in y)f=y[l],l=="children"?h=f:l=="dangerouslySetInnerHTML"?u=f:l=="value"?b=f:l=="checked"?g=f:a&&typeof f!="function"||E[l]===f||Pr(e,l,f,E[l],s);if(u)a||d&&(u.__html==d.__html||u.__html==e.innerHTML)||(e.innerHTML=u.__html),t.__k=[];else if(d&&(e.innerHTML=""),mc(t.type=="template"?e.content:e,_r(h)?h:[h],t,r,n,p=="foreignObject"?"http://www.w3.org/1999/xhtml":s,i,o,i?i[0]:r.__k&&At(r,0),a,c),i!=null)for(l=i.length;l--;)Ci(i[l]);a||(l="value",p=="progress"&&b==null?e.removeAttribute("value"):b!=null&&(b!==e[l]||p=="progress"&&!b||p=="option"&&b!=E[l])&&Pr(e,l,b,E[l],s),l="checked",g!=null&&g!=e[l]&&Pr(e,l,g,E[l],s))}return e}function Ii(e,t,r){try{if(typeof e=="function"){var n=typeof e.__u=="function";n&&e.__u(),n&&t==null||(e.__u=e(t))}else e.current=t}catch(s){G.__e(s,r)}}function Ec(e,t,r){var n,s;if(G.unmount&&G.unmount(e),(n=e.ref)&&(n.current&&n.current!=e.__e||Ii(n,null,t)),(n=e.__c)!=null){if(n.componentWillUnmount)try{n.componentWillUnmount()}catch(i){G.__e(i,t)}n.base=n.__P=null}if(n=e.__k)for(s=0;s<n.length;s++)n[s]&&Ec(n[s],t,r||typeof e.type!="function");r||Ci(e.__e),e.__c=e.__=e.__e=void 0}function oh(e,t,r){return this.constructor(e,r)}function Sc(e,t,r){var n,s,i,o;t==document&&(t=document.documentElement),G.__&&G.__(e,t),s=(n=typeof r=="function")?null:r&&r.__k||t.__k,i=[],o=[],Ri(t,e=(!n&&r||t).__k=di(mr,null,[e]),s||Xt,Xt,t.namespaceURI,!n&&r?[r]:s?null:t.firstChild?pr.call(t.childNodes):null,i,!n&&r?r:s?s.__e:t.firstChild,n,o),wc(i,e,o)}function kc(e,t){Sc(e,t,kc)}function ah(e,t,r){var n,s,i,o,a=Fe({},e.props);for(i in e.type&&e.type.defaultProps&&(o=e.type.defaultProps),t)i=="key"?n=t[i]:i=="ref"?s=t[i]:a[i]=t[i]===void 0&&o!=null?o[i]:t[i];return arguments.length>2&&(a.children=arguments.length>3?pr.call(arguments,2):r),Gt(e.type,a,n||e.key,s||e.ref,null)}function ch(e){function t(r){var n,s;return this.getChildContext||(n=new Set,(s={})[t.__c]=this,this.getChildContext=function(){return s},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(i){this.props.value!=i.value&&n.forEach(function(o){o.__e=!0,hi(o)})},this.sub=function(i){n.add(i);var o=i.componentWillUnmount;i.componentWillUnmount=function(){n&&n.delete(i),o&&o.call(i)}}),r.children}return t.__c="__cC"+gc++,t.__=e,t.Provider=t.__l=(t.Consumer=function(r,n){return r.children(n)}).contextType=t,t}pr=pc.slice,G={__e:function(e,t,r,n){for(var s,i,o;t=t.__;)if((s=t.__c)&&!s.__)try{if((i=s.constructor)&&i.getDerivedStateFromError!=null&&(s.setState(i.getDerivedStateFromError(e)),o=s.__d),s.componentDidCatch!=null&&(s.componentDidCatch(e,n||{}),o=s.__d),o)return s.__E=s}catch(a){e=a}throw e}},lc=0,uc=function(e){return e!=null&&e.constructor==null},Zt.prototype.setState=function(e,t){var r;r=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=Fe({},this.state),typeof e=="function"&&(e=e(Fe({},r),this.props)),e&&Fe(r,e),e!=null&&this.__v&&(t&&this._sb.push(t),hi(this))},Zt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),hi(this))},Zt.prototype.render=mr,rt=[],dc=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,hc=function(e,t){return e.__v.__b-t.__v.__b},Gr.__r=0,fc=/(PointerCapture)$|Capture$/i,ki=0,li=$o(!1),ui=$o(!0),gc=0;const lh=Object.freeze(Object.defineProperty({__proto__:null,Component:Zt,Fragment:mr,cloneElement:ah,createContext:ch,createElement:di,createRef:rh,h:di,hydrate:kc,get isValidElement(){return uc},get options(){return G},render:Sc,toChildArray:yc},Symbol.toStringTag,{value:"Module"})),_e=tr(lh);var gn={},ze,q,Us,Ho,xt=0,Cc=[],X=G,Uo=X.__b,Vo=X.__r,Wo=X.diffed,zo=X.__c,qo=X.unmount,Jo=X.__;function ht(e,t){X.__h&&X.__h(q,e,xt||t),xt=0;var r=q.__H||(q.__H={__:[],__h:[]});return e>=r.__.length&&r.__.push({}),r.__[e]}function Rc(e){return xt=1,Ic(xc,e)}function Ic(e,t,r){var n=ht(ze++,2);if(n.t=e,!n.__c&&(n.__=[r?r(t):xc(void 0,t),function(a){var c=n.__N?n.__N[0]:n.__[0],l=n.t(c,a);c!==l&&(n.__N=[l,n.__[1]],n.__c.setState({}))}],n.__c=q,!q.__f)){var s=function(a,c,l){if(!n.__c.__H)return!0;var u=n.__c.__H.__.filter(function(h){return!!h.__c});if(u.every(function(h){return!h.__N}))return!i||i.call(this,a,c,l);var d=n.__c.props!==a;return u.forEach(function(h){if(h.__N){var f=h.__[0];h.__=h.__N,h.__N=void 0,f!==h.__[0]&&(d=!0)}}),i&&i.call(this,a,c,l)||d};q.__f=!0;var i=q.shouldComponentUpdate,o=q.componentWillUpdate;q.componentWillUpdate=function(a,c,l){if(this.__e){var u=i;i=void 0,s(a,c,l),i=u}o&&o.call(this,a,c,l)},q.shouldComponentUpdate=s}return n.__N||n.__}function uh(e,t){var r=ht(ze++,3);!X.__s&&xi(r.__H,t)&&(r.__=e,r.u=t,q.__H.__h.push(r))}function Ac(e,t){var r=ht(ze++,4);!X.__s&&xi(r.__H,t)&&(r.__=e,r.u=t,q.__h.push(r))}function dh(e){return xt=5,Ai(function(){return{current:e}},[])}function hh(e,t,r){xt=6,Ac(function(){if(typeof e=="function"){var n=e(t());return function(){e(null),n&&typeof n=="function"&&n()}}if(e)return e.current=t(),function(){return e.current=null}},r==null?r:r.concat(e))}function Ai(e,t){var r=ht(ze++,7);return xi(r.__H,t)&&(r.__=e(),r.__H=t,r.__h=e),r.__}function fh(e,t){return xt=8,Ai(function(){return e},t)}function gh(e){var t=q.context[e.__c],r=ht(ze++,9);return r.c=e,t?(r.__==null&&(r.__=!0,t.sub(q)),t.props.value):e.__}function ph(e,t){X.useDebugValue&&X.useDebugValue(t?t(e):e)}function _h(e){var t=ht(ze++,10),r=Rc();return t.__=e,q.componentDidCatch||(q.componentDidCatch=function(n,s){t.__&&t.__(n,s),r[1](n)}),[r[0],function(){r[1](void 0)}]}function mh(){var e=ht(ze++,11);if(!e.__){for(var t=q.__v;t!==null&&!t.__m&&t.__!==null;)t=t.__;var r=t.__m||(t.__m=[0,0]);e.__="P"+r[0]+"-"+r[1]++}return e.__}function bh(){for(var e;e=Cc.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(qr),e.__H.__h.forEach(gi),e.__H.__h=[]}catch(t){e.__H.__h=[],X.__e(t,e.__v)}}X.__b=function(e){q=null,Uo&&Uo(e)},X.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Jo&&Jo(e,t)},X.__r=function(e){Vo&&Vo(e),ze=0;var t=(q=e.__c).__H;t&&(Us===q?(t.__h=[],q.__h=[],t.__.forEach(function(r){r.__N&&(r.__=r.__N),r.u=r.__N=void 0})):(t.__h.forEach(qr),t.__h.forEach(gi),t.__h=[],ze=0)),Us=q},X.diffed=function(e){Wo&&Wo(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Cc.push(t)!==1&&Ho===X.requestAnimationFrame||((Ho=X.requestAnimationFrame)||yh)(bh)),t.__H.__.forEach(function(r){r.u&&(r.__H=r.u),r.u=void 0})),Us=q=null},X.__c=function(e,t){t.some(function(r){try{r.__h.forEach(qr),r.__h=r.__h.filter(function(n){return!n.__||gi(n)})}catch(n){t.some(function(s){s.__h&&(s.__h=[])}),t=[],X.__e(n,r.__v)}}),zo&&zo(e,t)},X.unmount=function(e){qo&&qo(e);var t,r=e.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{qr(n)}catch(s){t=s}}),r.__H=void 0,t&&X.__e(t,r.__v))};var Go=typeof requestAnimationFrame=="function";function yh(e){var t,r=function(){clearTimeout(n),Go&&cancelAnimationFrame(t),setTimeout(e)},n=setTimeout(r,35);Go&&(t=requestAnimationFrame(r))}function qr(e){var t=q,r=e.__c;typeof r=="function"&&(e.__c=void 0,r()),q=t}function gi(e){var t=q;e.__c=e.__(),q=t}function xi(e,t){return!e||e.length!==t.length||t.some(function(r,n){return r!==e[n]})}function xc(e,t){return typeof t=="function"?t(e):t}const wh=Object.freeze(Object.defineProperty({__proto__:null,useCallback:fh,useContext:gh,useDebugValue:ph,useEffect:uh,useErrorBoundary:_h,useId:mh,useImperativeHandle:hh,useLayoutEffect:Ac,useMemo:Ai,useReducer:Ic,useRef:dh,useState:Rc},Symbol.toStringTag,{value:"Module"})),pn=tr(wh);var Nt={},_n={};Object.defineProperty(_n,"__esModule",{value:!0});_n.CloseIcon=void 0;const Zo=_e;function vh(e){return(0,Zo.h)("svg",Object.assign({width:"40",height:"40",viewBox:"0 0 40 40",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),(0,Zo.h)("path",{d:"M13.7677 13L12.3535 14.4142L18.3535 20.4142L12.3535 26.4142L13.7677 27.8284L19.7677 21.8284L25.7677 27.8284L27.1819 26.4142L21.1819 20.4142L27.1819 14.4142L25.7677 13L19.7677 19L13.7677 13Z"}))}_n.CloseIcon=vh;var mn={};Object.defineProperty(mn,"__esModule",{value:!0});mn.CoinbaseWalletRound=void 0;const Or=_e;function Eh(e){return(0,Or.h)("svg",Object.assign({width:"28",height:"28",viewBox:"0 0 28 28",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),(0,Or.h)("circle",{cx:"14",cy:"14",r:"14",fill:"#0052FF"}),(0,Or.h)("path",{d:"M23.8521 14.0003C23.8521 19.455 19.455 23.8521 14.0003 23.8521C8.54559 23.8521 4.14844 19.455 4.14844 14.0003C4.14844 8.54559 8.54559 4.14844 14.0003 4.14844C19.455 4.14844 23.8521 8.54559 23.8521 14.0003Z",fill:"white"}),(0,Or.h)("path",{d:"M11.1855 12.5042C11.1855 12.0477 11.1855 11.7942 11.2835 11.642C11.3814 11.4899 11.4793 11.3377 11.6261 11.287C11.8219 11.1855 12.0178 11.1855 12.5073 11.1855H15.4934C15.983 11.1855 16.1788 11.1855 16.3746 11.287C16.5215 11.3884 16.6683 11.4899 16.7173 11.642C16.8152 11.8449 16.8152 12.0477 16.8152 12.5042V15.4965C16.8152 15.953 16.8152 16.2066 16.7173 16.3587C16.6194 16.5109 16.5215 16.663 16.3746 16.7137C16.1788 16.8152 15.983 16.8152 15.4934 16.8152H12.5073C12.0178 16.8152 11.8219 16.8152 11.6261 16.7137C11.4793 16.6123 11.3324 16.5109 11.2835 16.3587C11.1855 16.1558 11.1855 15.953 11.1855 15.4965V12.5042Z",fill:"#0052FF"}))}mn.CoinbaseWalletRound=Eh;var bn={};Object.defineProperty(bn,"__esModule",{value:!0});bn.QRCodeIcon=void 0;const zt=_e;function Sh(e){return(0,zt.h)("svg",Object.assign({width:"18",height:"18",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e),(0,zt.h)("path",{d:"M3 3V8.99939L5 8.99996V5H9V3H3Z"}),(0,zt.h)("path",{d:"M15 21L21 21V15.0006L19 15V19L15 19V21Z"}),(0,zt.h)("path",{d:"M21 9H19V5H15.0006L15 3H21V9Z"}),(0,zt.h)("path",{d:"M3 15V21H8.99939L8.99996 19H5L5 15H3Z"}))}bn.QRCodeIcon=Sh;var yn={};function Nc(e){this.mode=ye.MODE_8BIT_BYTE,this.data=e,this.parsedData=[];for(var t=0,r=this.data.length;t<r;t++){var n=[],s=this.data.charCodeAt(t);s>65536?(n[0]=240|(s&1835008)>>>18,n[1]=128|(s&258048)>>>12,n[2]=128|(s&4032)>>>6,n[3]=128|s&63):s>2048?(n[0]=224|(s&61440)>>>12,n[1]=128|(s&4032)>>>6,n[2]=128|s&63):s>128?(n[0]=192|(s&1984)>>>6,n[1]=128|s&63):n[0]=s,this.parsedData.push(n)}this.parsedData=Array.prototype.concat.apply([],this.parsedData),this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}Nc.prototype={getLength:function(e){return this.parsedData.length},write:function(e){for(var t=0,r=this.parsedData.length;t<r;t++)e.put(this.parsedData[t],8)}};function je(e,t){this.typeNumber=e,this.errorCorrectLevel=t,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}je.prototype={addData:function(e){var t=new Nc(e);this.dataList.push(t),this.dataCache=null},isDark:function(e,t){if(e<0||this.moduleCount<=e||t<0||this.moduleCount<=t)throw new Error(e+","+t);return this.modules[e][t]},getModuleCount:function(){return this.moduleCount},make:function(){this.makeImpl(!1,this.getBestMaskPattern())},makeImpl:function(e,t){this.moduleCount=this.typeNumber*4+17,this.modules=new Array(this.moduleCount);for(var r=0;r<this.moduleCount;r++){this.modules[r]=new Array(this.moduleCount);for(var n=0;n<this.moduleCount;n++)this.modules[r][n]=null}this.setupPositionProbePattern(0,0),this.setupPositionProbePattern(this.moduleCount-7,0),this.setupPositionProbePattern(0,this.moduleCount-7),this.setupPositionAdjustPattern(),this.setupTimingPattern(),this.setupTypeInfo(e,t),this.typeNumber>=7&&this.setupTypeNumber(e),this.dataCache==null&&(this.dataCache=je.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,t)},setupPositionProbePattern:function(e,t){for(var r=-1;r<=7;r++)if(!(e+r<=-1||this.moduleCount<=e+r))for(var n=-1;n<=7;n++)t+n<=-1||this.moduleCount<=t+n||(0<=r&&r<=6&&(n==0||n==6)||0<=n&&n<=6&&(r==0||r==6)||2<=r&&r<=4&&2<=n&&n<=4?this.modules[e+r][t+n]=!0:this.modules[e+r][t+n]=!1)},getBestMaskPattern:function(){for(var e=0,t=0,r=0;r<8;r++){this.makeImpl(!0,r);var n=K.getLostPoint(this);(r==0||e>n)&&(e=n,t=r)}return t},createMovieClip:function(e,t,r){var n=e.createEmptyMovieClip(t,r),s=1;this.make();for(var i=0;i<this.modules.length;i++)for(var o=i*s,a=0;a<this.modules[i].length;a++){var c=a*s,l=this.modules[i][a];l&&(n.beginFill(0,100),n.moveTo(c,o),n.lineTo(c+s,o),n.lineTo(c+s,o+s),n.lineTo(c,o+s),n.endFill())}return n},setupTimingPattern:function(){for(var e=8;e<this.moduleCount-8;e++)this.modules[e][6]==null&&(this.modules[e][6]=e%2==0);for(var t=8;t<this.moduleCount-8;t++)this.modules[6][t]==null&&(this.modules[6][t]=t%2==0)},setupPositionAdjustPattern:function(){for(var e=K.getPatternPosition(this.typeNumber),t=0;t<e.length;t++)for(var r=0;r<e.length;r++){var n=e[t],s=e[r];if(this.modules[n][s]==null)for(var i=-2;i<=2;i++)for(var o=-2;o<=2;o++)i==-2||i==2||o==-2||o==2||i==0&&o==0?this.modules[n+i][s+o]=!0:this.modules[n+i][s+o]=!1}},setupTypeNumber:function(e){for(var t=K.getBCHTypeNumber(this.typeNumber),r=0;r<18;r++){var n=!e&&(t>>r&1)==1;this.modules[Math.floor(r/3)][r%3+this.moduleCount-8-3]=n}for(var r=0;r<18;r++){var n=!e&&(t>>r&1)==1;this.modules[r%3+this.moduleCount-8-3][Math.floor(r/3)]=n}},setupTypeInfo:function(e,t){for(var r=this.errorCorrectLevel<<3|t,n=K.getBCHTypeInfo(r),s=0;s<15;s++){var i=!e&&(n>>s&1)==1;s<6?this.modules[s][8]=i:s<8?this.modules[s+1][8]=i:this.modules[this.moduleCount-15+s][8]=i}for(var s=0;s<15;s++){var i=!e&&(n>>s&1)==1;s<8?this.modules[8][this.moduleCount-s-1]=i:s<9?this.modules[8][15-s-1+1]=i:this.modules[8][15-s-1]=i}this.modules[this.moduleCount-8][8]=!e},mapData:function(e,t){for(var r=-1,n=this.moduleCount-1,s=7,i=0,o=this.moduleCount-1;o>0;o-=2)for(o==6&&o--;;){for(var a=0;a<2;a++)if(this.modules[n][o-a]==null){var c=!1;i<e.length&&(c=(e[i]>>>s&1)==1);var l=K.getMask(t,n,o-a);l&&(c=!c),this.modules[n][o-a]=c,s--,s==-1&&(i++,s=7)}if(n+=r,n<0||this.moduleCount<=n){n-=r,r=-r;break}}}};je.PAD0=236;je.PAD1=17;je.createData=function(e,t,r){for(var n=De.getRSBlocks(e,t),s=new Lc,i=0;i<r.length;i++){var o=r[i];s.put(o.mode,4),s.put(o.getLength(),K.getLengthInBits(o.mode,e)),o.write(s)}for(var a=0,i=0;i<n.length;i++)a+=n[i].dataCount;if(s.getLengthInBits()>a*8)throw new Error("code length overflow. ("+s.getLengthInBits()+">"+a*8+")");for(s.getLengthInBits()+4<=a*8&&s.put(0,4);s.getLengthInBits()%8!=0;)s.putBit(!1);for(;!(s.getLengthInBits()>=a*8||(s.put(je.PAD0,8),s.getLengthInBits()>=a*8));)s.put(je.PAD1,8);return je.createBytes(s,n)};je.createBytes=function(e,t){for(var r=0,n=0,s=0,i=new Array(t.length),o=new Array(t.length),a=0;a<t.length;a++){var c=t[a].dataCount,l=t[a].totalCount-c;n=Math.max(n,c),s=Math.max(s,l),i[a]=new Array(c);for(var u=0;u<i[a].length;u++)i[a][u]=255&e.buffer[u+r];r+=c;var d=K.getErrorCorrectPolynomial(l),h=new Et(i[a],d.getLength()-1),f=h.mod(d);o[a]=new Array(d.getLength()-1);for(var u=0;u<o[a].length;u++){var b=u+f.getLength()-o[a].length;o[a][u]=b>=0?f.get(b):0}}for(var g=0,u=0;u<t.length;u++)g+=t[u].totalCount;for(var E=new Array(g),y=0,u=0;u<n;u++)for(var a=0;a<t.length;a++)u<i[a].length&&(E[y++]=i[a][u]);for(var u=0;u<s;u++)for(var a=0;a<t.length;a++)u<o[a].length&&(E[y++]=o[a][u]);return E};var ye={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8},Ze={L:1,M:0,Q:3,H:2},qe={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7},K={PATTERN_POSITION_TABLE:[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],G15:1335,G18:7973,G15_MASK:21522,getBCHTypeInfo:function(e){for(var t=e<<10;K.getBCHDigit(t)-K.getBCHDigit(K.G15)>=0;)t^=K.G15<<K.getBCHDigit(t)-K.getBCHDigit(K.G15);return(e<<10|t)^K.G15_MASK},getBCHTypeNumber:function(e){for(var t=e<<12;K.getBCHDigit(t)-K.getBCHDigit(K.G18)>=0;)t^=K.G18<<K.getBCHDigit(t)-K.getBCHDigit(K.G18);return e<<12|t},getBCHDigit:function(e){for(var t=0;e!=0;)t++,e>>>=1;return t},getPatternPosition:function(e){return K.PATTERN_POSITION_TABLE[e-1]},getMask:function(e,t,r){switch(e){case qe.PATTERN000:return(t+r)%2==0;case qe.PATTERN001:return t%2==0;case qe.PATTERN010:return r%3==0;case qe.PATTERN011:return(t+r)%3==0;case qe.PATTERN100:return(Math.floor(t/2)+Math.floor(r/3))%2==0;case qe.PATTERN101:return t*r%2+t*r%3==0;case qe.PATTERN110:return(t*r%2+t*r%3)%2==0;case qe.PATTERN111:return(t*r%3+(t+r)%2)%2==0;default:throw new Error("bad maskPattern:"+e)}},getErrorCorrectPolynomial:function(e){for(var t=new Et([1],0),r=0;r<e;r++)t=t.multiply(new Et([1,le.gexp(r)],0));return t},getLengthInBits:function(e,t){if(1<=t&&t<10)switch(e){case ye.MODE_NUMBER:return 10;case ye.MODE_ALPHA_NUM:return 9;case ye.MODE_8BIT_BYTE:return 8;case ye.MODE_KANJI:return 8;default:throw new Error("mode:"+e)}else if(t<27)switch(e){case ye.MODE_NUMBER:return 12;case ye.MODE_ALPHA_NUM:return 11;case ye.MODE_8BIT_BYTE:return 16;case ye.MODE_KANJI:return 10;default:throw new Error("mode:"+e)}else if(t<41)switch(e){case ye.MODE_NUMBER:return 14;case ye.MODE_ALPHA_NUM:return 13;case ye.MODE_8BIT_BYTE:return 16;case ye.MODE_KANJI:return 12;default:throw new Error("mode:"+e)}else throw new Error("type:"+t)},getLostPoint:function(e){for(var t=e.getModuleCount(),r=0,n=0;n<t;n++)for(var s=0;s<t;s++){for(var i=0,o=e.isDark(n,s),a=-1;a<=1;a++)if(!(n+a<0||t<=n+a))for(var c=-1;c<=1;c++)s+c<0||t<=s+c||a==0&&c==0||o==e.isDark(n+a,s+c)&&i++;i>5&&(r+=3+i-5)}for(var n=0;n<t-1;n++)for(var s=0;s<t-1;s++){var l=0;e.isDark(n,s)&&l++,e.isDark(n+1,s)&&l++,e.isDark(n,s+1)&&l++,e.isDark(n+1,s+1)&&l++,(l==0||l==4)&&(r+=3)}for(var n=0;n<t;n++)for(var s=0;s<t-6;s++)e.isDark(n,s)&&!e.isDark(n,s+1)&&e.isDark(n,s+2)&&e.isDark(n,s+3)&&e.isDark(n,s+4)&&!e.isDark(n,s+5)&&e.isDark(n,s+6)&&(r+=40);for(var s=0;s<t;s++)for(var n=0;n<t-6;n++)e.isDark(n,s)&&!e.isDark(n+1,s)&&e.isDark(n+2,s)&&e.isDark(n+3,s)&&e.isDark(n+4,s)&&!e.isDark(n+5,s)&&e.isDark(n+6,s)&&(r+=40);for(var u=0,s=0;s<t;s++)for(var n=0;n<t;n++)e.isDark(n,s)&&u++;var d=Math.abs(100*u/t/t-50)/5;return r+=d*10,r}},le={glog:function(e){if(e<1)throw new Error("glog("+e+")");return le.LOG_TABLE[e]},gexp:function(e){for(;e<0;)e+=255;for(;e>=256;)e-=255;return le.EXP_TABLE[e]},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)};for(var de=0;de<8;de++)le.EXP_TABLE[de]=1<<de;for(var de=8;de<256;de++)le.EXP_TABLE[de]=le.EXP_TABLE[de-4]^le.EXP_TABLE[de-5]^le.EXP_TABLE[de-6]^le.EXP_TABLE[de-8];for(var de=0;de<255;de++)le.LOG_TABLE[le.EXP_TABLE[de]]=de;function Et(e,t){if(e.length==null)throw new Error(e.length+"/"+t);for(var r=0;r<e.length&&e[r]==0;)r++;this.num=new Array(e.length-r+t);for(var n=0;n<e.length-r;n++)this.num[n]=e[n+r]}Et.prototype={get:function(e){return this.num[e]},getLength:function(){return this.num.length},multiply:function(e){for(var t=new Array(this.getLength()+e.getLength()-1),r=0;r<this.getLength();r++)for(var n=0;n<e.getLength();n++)t[r+n]^=le.gexp(le.glog(this.get(r))+le.glog(e.get(n)));return new Et(t,0)},mod:function(e){if(this.getLength()-e.getLength()<0)return this;for(var t=le.glog(this.get(0))-le.glog(e.get(0)),r=new Array(this.getLength()),n=0;n<this.getLength();n++)r[n]=this.get(n);for(var n=0;n<e.getLength();n++)r[n]^=le.gexp(le.glog(e.get(n))+t);return new Et(r,0).mod(e)}};function De(e,t){this.totalCount=e,this.dataCount=t}De.RS_BLOCK_TABLE=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]];De.getRSBlocks=function(e,t){var r=De.getRsBlockTable(e,t);if(r==null)throw new Error("bad rs block @ typeNumber:"+e+"/errorCorrectLevel:"+t);for(var n=r.length/3,s=[],i=0;i<n;i++)for(var o=r[i*3+0],a=r[i*3+1],c=r[i*3+2],l=0;l<o;l++)s.push(new De(a,c));return s};De.getRsBlockTable=function(e,t){switch(t){case Ze.L:return De.RS_BLOCK_TABLE[(e-1)*4+0];case Ze.M:return De.RS_BLOCK_TABLE[(e-1)*4+1];case Ze.Q:return De.RS_BLOCK_TABLE[(e-1)*4+2];case Ze.H:return De.RS_BLOCK_TABLE[(e-1)*4+3];default:return}};function Lc(){this.buffer=[],this.length=0}Lc.prototype={get:function(e){var t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)==1},put:function(e,t){for(var r=0;r<t;r++)this.putBit((e>>>t-r-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(e){var t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var Vs=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]];function Mc(e){if(this.options={padding:4,width:256,height:256,typeNumber:4,color:"#000000",background:"#ffffff",ecl:"M",image:{svg:"",width:0,height:0}},typeof e=="string"&&(e={content:e}),e)for(var t in e)this.options[t]=e[t];if(typeof this.options.content!="string")throw new Error("Expected 'content' as string!");if(this.options.content.length===0)throw new Error("Expected 'content' to be non-empty!");if(!(this.options.padding>=0))throw new Error("Expected 'padding' value to be non-negative!");if(!(this.options.width>0)||!(this.options.height>0))throw new Error("Expected 'width' or 'height' value to be higher than zero!");function r(c){switch(c){case"L":return Ze.L;case"M":return Ze.M;case"Q":return Ze.Q;case"H":return Ze.H;default:throw new Error("Unknwon error correction level: "+c)}}function n(c,l){for(var u=s(c),d=1,h=0,f=0,b=Vs.length;f<=b;f++){var g=Vs[f];if(!g)throw new Error("Content too long: expected "+h+" but got "+u);switch(l){case"L":h=g[0];break;case"M":h=g[1];break;case"Q":h=g[2];break;case"H":h=g[3];break;default:throw new Error("Unknwon error correction level: "+l)}if(u<=h)break;d++}if(d>Vs.length)throw new Error("Content too long");return d}function s(c){var l=encodeURI(c).toString().replace(/\%[0-9a-fA-F]{2}/g,"a");return l.length+(l.length!=c?3:0)}var i=this.options.content,o=n(i,this.options.ecl),a=r(this.options.ecl);this.qrcode=new je(o,a),this.qrcode.addData(i),this.qrcode.make()}Mc.prototype.svg=function(e){var t=this.options||{},r=this.qrcode.modules;typeof e>"u"&&(e={container:t.container||"svg"});for(var n=typeof t.pretty<"u"?!!t.pretty:!0,s=n?" ":"",i=n?`\r
2
2
  `:"",o=t.width,a=t.height,c=r.length,l=o/(c+2*t.padding),u=a/(c+2*t.padding),d=typeof t.join<"u"?!!t.join:!1,h=typeof t.swap<"u"?!!t.swap:!1,f=typeof t.xmlDeclaration<"u"?!!t.xmlDeclaration:!0,b=typeof t.predefined<"u"?!!t.predefined:!1,g=b?s+'<defs><path id="qrmodule" d="M0 0 h'+u+" v"+l+' H0 z" style="fill:'+t.color+';shape-rendering:crispEdges;" /></defs>'+i:"",E=s+'<rect x="0" y="0" width="'+o+'" height="'+a+'" style="fill:'+t.background+';shape-rendering:crispEdges;"/>'+i,y="",p="",_=0;_<c;_++)for(var A=0;A<c;A++){var v=r[A][_];if(v){var N=A*l+t.padding*l,V=_*u+t.padding*u;if(h){var Z=N;N=V,V=Z}if(d){var ee=l+N,z=u+V;N=Number.isInteger(N)?Number(N):N.toFixed(2),V=Number.isInteger(V)?Number(V):V.toFixed(2),ee=Number.isInteger(ee)?Number(ee):ee.toFixed(2),z=Number.isInteger(z)?Number(z):z.toFixed(2),p+="M"+N+","+V+" V"+z+" H"+ee+" V"+V+" H"+N+" Z "}else b?y+=s+'<use x="'+N.toString()+'" y="'+V.toString()+'" href="#qrmodule" />'+i:y+=s+'<rect x="'+N.toString()+'" y="'+V.toString()+'" width="'+l+'" height="'+u+'" style="fill:'+t.color+';shape-rendering:crispEdges;"/>'+i}}d&&(y=s+'<path x="0" y="0" style="fill:'+t.color+';shape-rendering:crispEdges;" d="'+p+'" />');let W="";if(this.options.image!==void 0&&this.options.image.svg){const se=o*this.options.image.width/100,w=a*this.options.image.height/100,m=o/2-se/2,R=a/2-w/2;W+=`<svg x="${m}" y="${R}" width="${se}" height="${w}" viewBox="0 0 100 100" preserveAspectRatio="xMinYMin meet">`,W+=this.options.image.svg+i,W+="</svg>"}var H="";switch(e.container){case"svg":f&&(H+='<?xml version="1.0" standalone="yes"?>'+i),H+='<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="'+o+'" height="'+a+'">'+i,H+=g+E+y,H+=W,H+="</svg>";break;case"svg-viewbox":f&&(H+='<?xml version="1.0" standalone="yes"?>'+i),H+='<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 '+o+" "+a+'">'+i,H+=g+E+y,H+=W,H+="</svg>";break;case"g":H+='<g width="'+o+'" height="'+a+'">'+i,H+=g+E+y,H+=W,H+="</g>";break;default:H+=(g+E+y+W).replace(/^\s+/,"");break}return H};var kh=Mc,Ch=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(yn,"__esModule",{value:!0});yn.QRCode=void 0;const Rh=_e,Qo=pn,Ih=Ch(kh),Ah=e=>{const[t,r]=(0,Qo.useState)("");return(0,Qo.useEffect)(()=>{var n,s;const i=new Ih.default({content:e.content,background:e.bgColor||"#ffffff",color:e.fgColor||"#000000",container:"svg",ecl:"M",width:(n=e.width)!==null&&n!==void 0?n:256,height:(s=e.height)!==null&&s!==void 0?s:256,padding:0,image:e.image}),o=O.from(i.svg(),"utf8").toString("base64");r(`data:image/svg+xml;base64,${o}`)},[e.bgColor,e.content,e.fgColor,e.height,e.image,e.width]),t?(0,Rh.h)("img",{src:t,alt:"QR Code"}):null};yn.QRCode=Ah;var wn={},Ni={};Object.defineProperty(Ni,"__esModule",{value:!0});Ni.default=".-cbwsdk-css-reset .-cbwsdk-spinner{display:inline-block}.-cbwsdk-css-reset .-cbwsdk-spinner svg{display:inline-block;animation:2s linear infinite -cbwsdk-spinner-svg}.-cbwsdk-css-reset .-cbwsdk-spinner svg circle{animation:1.9s ease-in-out infinite both -cbwsdk-spinner-circle;display:block;fill:rgba(0,0,0,0);stroke-dasharray:283;stroke-dashoffset:280;stroke-linecap:round;stroke-width:10px;transform-origin:50% 50%}@keyframes -cbwsdk-spinner-svg{0%{transform:rotateZ(0deg)}100%{transform:rotateZ(360deg)}}@keyframes -cbwsdk-spinner-circle{0%,25%{stroke-dashoffset:280;transform:rotate(0)}50%,75%{stroke-dashoffset:75;transform:rotate(45deg)}100%{stroke-dashoffset:280;transform:rotate(360deg)}}";var xh=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(wn,"__esModule",{value:!0});wn.Spinner=void 0;const Br=_e,Nh=xh(Ni),Lh=e=>{var t;const r=(t=e.size)!==null&&t!==void 0?t:64,n=e.color||"#000";return(0,Br.h)("div",{class:"-cbwsdk-spinner"},(0,Br.h)("style",null,Nh.default),(0,Br.h)("svg",{viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg",style:{width:r,height:r}},(0,Br.h)("circle",{style:{cx:50,cy:50,r:45,stroke:n}})))};wn.Spinner=Lh;var Li={};Object.defineProperty(Li,"__esModule",{value:!0});Li.default=".-cbwsdk-css-reset .-cbwsdk-connect-content{height:430px;width:700px;border-radius:12px;padding:30px}.-cbwsdk-css-reset .-cbwsdk-connect-content.light{background:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content.dark{background:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-header{display:flex;align-items:center;justify-content:space-between;margin:0 0 30px}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading{font-style:normal;font-weight:500;font-size:28px;line-height:36px;margin:0}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-layout{display:flex;flex-direction:row}.-cbwsdk-css-reset .-cbwsdk-connect-content-column-left{margin-right:30px;display:flex;flex-direction:column;justify-content:space-between}.-cbwsdk-css-reset .-cbwsdk-connect-content-column-right{flex:25%;margin-right:34px}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-wrapper{width:220px;height:220px;border-radius:12px;display:flex;justify-content:center;align-items:center;background:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting{position:absolute;top:0;bottom:0;left:0;right:0;display:flex;flex-direction:column;align-items:center;justify-content:center}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.light{background-color:rgba(255,255,255,.95)}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.light>p{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.dark{background-color:rgba(10,11,13,.9)}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.dark>p{color:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting>p{font-size:12px;font-weight:bold;margin-top:16px}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app{border-radius:8px;font-size:14px;line-height:20px;padding:12px;width:339px}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app.light{background:#eef0f3;color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app.dark{background:#1e2025;color:#8a919e}.-cbwsdk-css-reset .-cbwsdk-cancel-button{-webkit-appearance:none;border:none;background:none;cursor:pointer;padding:0;margin:0}.-cbwsdk-css-reset .-cbwsdk-cancel-button-x{position:relative;display:block;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-wallet-steps{padding:0 0 0 16px;margin:0;width:100%;list-style:decimal}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item{list-style-type:decimal;display:list-item;font-style:normal;font-weight:400;font-size:16px;line-height:24px;margin-top:20px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item-wrapper{display:flex;align-items:center}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-pad-left{margin-left:6px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon{display:flex;border-radius:50%;height:24px;width:24px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon svg{margin:auto;display:block}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon.light{background:#0052ff}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon.dark{background:#588af5}.-cbwsdk-css-reset .-cbwsdk-connect-item{align-items:center;display:flex;flex-direction:row;padding:16px 24px;gap:12px;cursor:pointer;border-radius:100px;font-weight:600}.-cbwsdk-css-reset .-cbwsdk-connect-item.light{background:#f5f8ff;color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-connect-item.dark{background:#001033;color:#588af5}.-cbwsdk-css-reset .-cbwsdk-connect-item-copy-wrapper{margin:0 4px 0 8px}.-cbwsdk-css-reset .-cbwsdk-connect-item-title{margin:0 0 0;font-size:16px;line-height:24px;font-weight:500}.-cbwsdk-css-reset .-cbwsdk-connect-item-description{font-weight:400;font-size:14px;line-height:20px;margin:0}";var Tc=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Nt,"__esModule",{value:!0});Nt.CoinbaseWalletSteps=Nt.ConnectContent=void 0;const at=Tc(rr),j=_e,Mh=S,Th=Bt,Ph=_n,Oh=mn,Bh=bn,Dh=yn,Fh=wn,jh=Tc(Li),Ws={title:"Coinbase Wallet app",description:"Connect with your self-custody wallet",steps:Pc},$h=e=>e==="light"?"#FFFFFF":"#0A0B0D";function Hh(e){const{theme:t}=e,r=(0,Mh.createQrUrl)(e.sessionId,e.sessionSecret,e.linkAPIUrl,e.isParentConnection,e.version,e.chainId),n=Ws.steps;return(0,j.h)("div",{"data-testid":"connect-content",className:(0,at.default)("-cbwsdk-connect-content",t)},(0,j.h)("style",null,jh.default),(0,j.h)("div",{className:"-cbwsdk-connect-content-header"},(0,j.h)("h2",{className:(0,at.default)("-cbwsdk-connect-content-heading",t)},"Scan to connect with our mobile app"),e.onCancel&&(0,j.h)("button",{type:"button",className:"-cbwsdk-cancel-button",onClick:e.onCancel},(0,j.h)(Ph.CloseIcon,{fill:t==="light"?"#0A0B0D":"#FFFFFF"}))),(0,j.h)("div",{className:"-cbwsdk-connect-content-layout"},(0,j.h)("div",{className:"-cbwsdk-connect-content-column-left"},(0,j.h)(Uh,{title:Ws.title,description:Ws.description,theme:t})),(0,j.h)("div",{className:"-cbwsdk-connect-content-column-right"},(0,j.h)("div",{className:"-cbwsdk-connect-content-qr-wrapper"},(0,j.h)(Dh.QRCode,{content:r,width:200,height:200,fgColor:"#000",bgColor:"transparent"}),(0,j.h)("input",{type:"hidden",name:"cbw-cbwsdk-version",value:Th.LIB_VERSION}),(0,j.h)("input",{type:"hidden",value:r})),(0,j.h)(n,{theme:t}),!e.isConnected&&(0,j.h)("div",{"data-testid":"connecting-spinner",className:(0,at.default)("-cbwsdk-connect-content-qr-connecting",t)},(0,j.h)(Fh.Spinner,{size:36,color:t==="dark"?"#FFF":"#000"}),(0,j.h)("p",null,"Connecting...")))))}Nt.ConnectContent=Hh;function Uh({title:e,description:t,theme:r}){return(0,j.h)("div",{className:(0,at.default)("-cbwsdk-connect-item",r)},(0,j.h)("div",null,(0,j.h)(Oh.CoinbaseWalletRound,null)),(0,j.h)("div",{className:"-cbwsdk-connect-item-copy-wrapper"},(0,j.h)("h3",{className:"-cbwsdk-connect-item-title"},e),(0,j.h)("p",{className:"-cbwsdk-connect-item-description"},t)))}function Pc({theme:e}){return(0,j.h)("ol",{className:"-cbwsdk-wallet-steps"},(0,j.h)("li",{className:(0,at.default)("-cbwsdk-wallet-steps-item",e)},(0,j.h)("div",{className:"-cbwsdk-wallet-steps-item-wrapper"},"Open Coinbase Wallet app")),(0,j.h)("li",{className:(0,at.default)("-cbwsdk-wallet-steps-item",e)},(0,j.h)("div",{className:"-cbwsdk-wallet-steps-item-wrapper"},(0,j.h)("span",null,"Tap ",(0,j.h)("strong",null,"Scan")," "),(0,j.h)("span",{className:(0,at.default)("-cbwsdk-wallet-steps-pad-left","-cbwsdk-wallet-steps-icon",e)},(0,j.h)(Bh.QRCodeIcon,{fill:$h(e)})))))}Nt.CoinbaseWalletSteps=Pc;var vn={},En={};Object.defineProperty(En,"__esModule",{value:!0});En.ArrowLeftIcon=void 0;const Ko=_e;function Vh(e){return(0,Ko.h)("svg",Object.assign({width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg"},e),(0,Ko.h)("path",{d:"M8.60675 0.155884L7.37816 1.28209L12.7723 7.16662H0V8.83328H12.6548L6.82149 14.6666L8 15.8451L15.8201 8.02501L8.60675 0.155884Z"}))}En.ArrowLeftIcon=Vh;var Sn={};Object.defineProperty(Sn,"__esModule",{value:!0});Sn.LaptopIcon=void 0;const zs=_e;function Wh(e){return(0,zs.h)("svg",Object.assign({width:"14",height:"14",viewBox:"0 0 14 14",xmlns:"http://www.w3.org/2000/svg"},e),(0,zs.h)("path",{d:"M1.8001 2.2002H12.2001V9.40019H1.8001V2.2002ZM3.4001 3.8002V7.80019H10.6001V3.8002H3.4001Z"}),(0,zs.h)("path",{d:"M13.4001 10.2002H0.600098C0.600098 11.0838 1.31644 11.8002 2.2001 11.8002H11.8001C12.6838 11.8002 13.4001 11.0838 13.4001 10.2002Z"}))}Sn.LaptopIcon=Wh;var kn={};Object.defineProperty(kn,"__esModule",{value:!0});kn.SafeIcon=void 0;const Xo=_e;function zh(e){return(0,Xo.h)("svg",Object.assign({width:"14",height:"14",viewBox:"0 0 14 14",xmlns:"http://www.w3.org/2000/svg"},e),(0,Xo.h)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0.600098 0.600098V11.8001H13.4001V0.600098H0.600098ZM7.0001 9.2001C5.3441 9.2001 4.0001 7.8561 4.0001 6.2001C4.0001 4.5441 5.3441 3.2001 7.0001 3.2001C8.6561 3.2001 10.0001 4.5441 10.0001 6.2001C10.0001 7.8561 8.6561 9.2001 7.0001 9.2001ZM0.600098 12.6001H3.8001V13.4001H0.600098V12.6001ZM10.2001 12.6001H13.4001V13.4001H10.2001V12.6001ZM8.8001 6.2001C8.8001 7.19421 7.99421 8.0001 7.0001 8.0001C6.00598 8.0001 5.2001 7.19421 5.2001 6.2001C5.2001 5.20598 6.00598 4.4001 7.0001 4.4001C7.99421 4.4001 8.8001 5.20598 8.8001 6.2001Z"}))}kn.SafeIcon=zh;var Mi={};Object.defineProperty(Mi,"__esModule",{value:!0});Mi.default=".-cbwsdk-css-reset .-cbwsdk-try-extension{display:flex;margin-top:12px;height:202px;width:700px;border-radius:12px;padding:30px}.-cbwsdk-css-reset .-cbwsdk-try-extension.light{background:#fff}.-cbwsdk-css-reset .-cbwsdk-try-extension.dark{background:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-try-extension-column-half{flex:50%}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading{font-style:normal;font-weight:500;font-size:25px;line-height:32px;margin:0;max-width:204px}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta{appearance:none;border:none;background:none;color:#0052ff;cursor:pointer;padding:0;text-decoration:none;display:block;font-weight:600;font-size:16px;line-height:24px}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta.light{color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta.dark{color:#588af5}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta-wrapper{display:flex;align-items:center;margin-top:12px}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta-icon{display:block;margin-left:4px;height:14px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list{display:flex;flex-direction:column;justify-content:center;align-items:center;margin:0;padding:0;list-style:none;height:100%}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item{display:flex;align-items:center;flex-flow:nowrap;margin-top:24px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item:first-of-type{margin-top:0}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon-wrapper{display:block}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon{display:flex;height:32px;width:32px;border-radius:50%}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon svg{margin:auto;display:block}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon.light{background:#eef0f3}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon.dark{background:#1e2025}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy{display:block;font-weight:400;font-size:14px;line-height:20px;padding-left:12px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy.light{color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy.dark{color:#8a919e}";var Oc=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(vn,"__esModule",{value:!0});vn.TryExtensionContent=void 0;const Xe=Oc(rr),ne=_e,qs=pn,qh=En,Jh=Sn,Gh=kn,Zh=Oc(Mi);function Qh({theme:e}){const[t,r]=(0,qs.useState)(!1),n=(0,qs.useCallback)(()=>{window.open("https://api.wallet.coinbase.com/rpc/v2/desktop/chrome","_blank")},[]),s=(0,qs.useCallback)(()=>{t?window.location.reload():(n(),r(!0))},[n,t]);return(0,ne.h)("div",{class:(0,Xe.default)("-cbwsdk-try-extension",e)},(0,ne.h)("style",null,Zh.default),(0,ne.h)("div",{class:"-cbwsdk-try-extension-column-half"},(0,ne.h)("h3",{class:(0,Xe.default)("-cbwsdk-try-extension-heading",e)},"Or try the Coinbase Wallet browser extension"),(0,ne.h)("div",{class:"-cbwsdk-try-extension-cta-wrapper"},(0,ne.h)("button",{class:(0,Xe.default)("-cbwsdk-try-extension-cta",e),onClick:s},t?"Refresh":"Install"),(0,ne.h)("div",null,!t&&(0,ne.h)(qh.ArrowLeftIcon,{class:"-cbwsdk-try-extension-cta-icon",fill:e==="light"?"#0052FF":"#588AF5"})))),(0,ne.h)("div",{class:"-cbwsdk-try-extension-column-half"},(0,ne.h)("ul",{class:"-cbwsdk-try-extension-list"},(0,ne.h)("li",{class:"-cbwsdk-try-extension-list-item"},(0,ne.h)("div",{class:"-cbwsdk-try-extension-list-item-icon-wrapper"},(0,ne.h)("span",{class:(0,Xe.default)("-cbwsdk-try-extension-list-item-icon",e)},(0,ne.h)(Jh.LaptopIcon,{fill:e==="light"?"#0A0B0D":"#FFFFFF"}))),(0,ne.h)("div",{class:(0,Xe.default)("-cbwsdk-try-extension-list-item-copy",e)},"Connect with dapps with just one click on your desktop browser")),(0,ne.h)("li",{class:"-cbwsdk-try-extension-list-item"},(0,ne.h)("div",{class:"-cbwsdk-try-extension-list-item-icon-wrapper"},(0,ne.h)("span",{class:(0,Xe.default)("-cbwsdk-try-extension-list-item-icon",e)},(0,ne.h)(Gh.SafeIcon,{fill:e==="light"?"#0A0B0D":"#FFFFFF"}))),(0,ne.h)("div",{class:(0,Xe.default)("-cbwsdk-try-extension-list-item-copy",e)},"Add an additional layer of security by using a supported Ledger hardware wallet")))))}vn.TryExtensionContent=Qh;var Ti={};Object.defineProperty(Ti,"__esModule",{value:!0});Ti.default=".-cbwsdk-css-reset .-cbwsdk-connect-dialog{z-index:2147483647;position:fixed;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop{z-index:2147483647;position:fixed;top:0;left:0;right:0;bottom:0;transition:opacity .25s}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop.light{background-color:rgba(0,0,0,.5)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop.dark{background-color:rgba(50,53,61,.4)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop-hidden{opacity:0}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-box{display:flex;position:relative;flex-direction:column;transform:scale(1);transition:opacity .25s,transform .25s}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-box-hidden{opacity:0;transform:scale(0.85)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-container{display:block}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-container-hidden{display:none}";var Bc=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(gn,"__esModule",{value:!0});gn.ConnectDialog=void 0;const Js=Bc(rr),Ye=_e,Gs=pn,Kh=Nt,Xh=vn,Yh=Bc(Ti),ef=e=>{const{isOpen:t,darkMode:r}=e,[n,s]=(0,Gs.useState)(!t),[i,o]=(0,Gs.useState)(!t);(0,Gs.useEffect)(()=>{const c=[window.setTimeout(()=>{o(!t)},10)];return t?s(!1):c.push(window.setTimeout(()=>{s(!0)},360)),()=>{c.forEach(window.clearTimeout)}},[t]);const a=r?"dark":"light";return(0,Ye.h)("div",{class:(0,Js.default)("-cbwsdk-connect-dialog-container",n&&"-cbwsdk-connect-dialog-container-hidden")},(0,Ye.h)("style",null,Yh.default),(0,Ye.h)("div",{class:(0,Js.default)("-cbwsdk-connect-dialog-backdrop",a,i&&"-cbwsdk-connect-dialog-backdrop-hidden")}),(0,Ye.h)("div",{class:"-cbwsdk-connect-dialog"},(0,Ye.h)("div",{class:(0,Js.default)("-cbwsdk-connect-dialog-box",i&&"-cbwsdk-connect-dialog-box-hidden")},e.connectDisabled?null:(0,Ye.h)(Kh.ConnectContent,{theme:a,version:e.version,sessionId:e.sessionId,sessionSecret:e.sessionSecret,linkAPIUrl:e.linkAPIUrl,isConnected:e.isConnected,isParentConnection:e.isParentConnection,chainId:e.chainId,onCancel:e.onCancel}),(0,Ye.h)(Xh.TryExtensionContent,{theme:a}))))};gn.ConnectDialog=ef;Object.defineProperty(fn,"__esModule",{value:!0});fn.LinkFlow=void 0;const Zs=_e,tf=gn;class rf{constructor(t){this.connected=!1,this.chainId=1,this.isOpen=!1,this.onCancel=null,this.root=null,this.connectDisabled=!1,this.darkMode=t.darkMode,this.version=t.version,this.sessionId=t.sessionId,this.sessionSecret=t.sessionSecret,this.linkAPIUrl=t.linkAPIUrl,this.isParentConnection=t.isParentConnection}attach(t){this.root=document.createElement("div"),this.root.className="-cbwsdk-link-flow-root",t.appendChild(this.root),this.render()}setConnected(t){this.connected!==t&&(this.connected=t,this.render())}setChainId(t){this.chainId!==t&&(this.chainId=t,this.render())}detach(){var t;this.root&&((0,Zs.render)(null,this.root),(t=this.root.parentElement)===null||t===void 0||t.removeChild(this.root))}setConnectDisabled(t){this.connectDisabled=t}open(t){this.isOpen=!0,this.onCancel=t.onCancel,this.render()}close(){this.isOpen=!1,this.onCancel=null,this.render()}render(){this.root&&(0,Zs.render)((0,Zs.h)(tf.ConnectDialog,{darkMode:this.darkMode,version:this.version,sessionId:this.sessionId,sessionSecret:this.sessionSecret,linkAPIUrl:this.linkAPIUrl,isOpen:this.isOpen,isConnected:this.connected,isParentConnection:this.isParentConnection,chainId:this.chainId,onCancel:this.onCancel,connectDisabled:this.connectDisabled}),this.root)}}fn.LinkFlow=rf;var Pi={},Oi={};Object.defineProperty(Oi,"__esModule",{value:!0});Oi.default=".-cbwsdk-css-reset .-gear-container{margin-left:16px !important;margin-right:9px !important;display:flex;align-items:center;justify-content:center;width:24px;height:24px;transition:opacity .25s}.-cbwsdk-css-reset .-gear-container *{user-select:none}.-cbwsdk-css-reset .-gear-container svg{opacity:0;position:absolute}.-cbwsdk-css-reset .-gear-icon{height:12px;width:12px;z-index:10000}.-cbwsdk-css-reset .-cbwsdk-snackbar{align-items:flex-end;display:flex;flex-direction:column;position:fixed;right:0;top:0;z-index:2147483647}.-cbwsdk-css-reset .-cbwsdk-snackbar *{user-select:none}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance{display:flex;flex-direction:column;margin:8px 16px 0 16px;overflow:visible;text-align:left;transform:translateX(0);transition:opacity .25s,transform .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header:hover .-gear-container svg{opacity:1}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header{display:flex;align-items:center;background:#fff;overflow:hidden;border:1px solid #e7ebee;box-sizing:border-box;border-radius:8px;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header-cblogo{margin:8px 8px 8px 8px}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header *{cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header-message{color:#000;font-size:13px;line-height:1.5;user-select:none}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu{background:#fff;transition:opacity .25s ease-in-out,transform .25s linear,visibility 0s;visibility:hidden;border:1px solid #e7ebee;box-sizing:border-box;border-radius:8px;opacity:0;flex-direction:column;padding-left:8px;padding-right:8px}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:last-child{margin-bottom:8px !important}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover{background:#f5f7f8;border-radius:6px;transition:background .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover span{color:#050f19;transition:color .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover svg path{fill:#000;transition:fill .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item{visibility:inherit;height:35px;margin-top:8px;margin-bottom:0;display:flex;flex-direction:row;align-items:center;padding:8px;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item *{visibility:inherit;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover{background:rgba(223,95,103,.2);transition:background .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover *{cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover svg path{fill:#df5f67;transition:fill .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover span{color:#df5f67;transition:color .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-info{color:#aaa;font-size:13px;margin:0 8px 0 32px;position:absolute}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-hidden{opacity:0;text-align:left;transform:translateX(25%);transition:opacity .5s linear}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-expanded .-cbwsdk-snackbar-instance-menu{opacity:1;display:flex;transform:translateY(8px);visibility:visible}";(function(e){var t=x&&x.__importDefault||function(d){return d&&d.__esModule?d:{default:d}};Object.defineProperty(e,"__esModule",{value:!0}),e.SnackbarInstance=e.SnackbarContainer=e.Snackbar=void 0;const r=t(rr),n=_e,s=pn,i=t(Oi),o="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEuNDkyIDEwLjQxOWE4LjkzIDguOTMgMCAwMTguOTMtOC45M2gxMS4xNjNhOC45MyA4LjkzIDAgMDE4LjkzIDguOTN2MTEuMTYzYTguOTMgOC45MyAwIDAxLTguOTMgOC45M0gxMC40MjJhOC45MyA4LjkzIDAgMDEtOC45My04LjkzVjEwLjQxOXoiIGZpbGw9IiMxNjUyRjAiLz48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTEwLjQxOSAwSDIxLjU4QzI3LjMzNSAwIDMyIDQuNjY1IDMyIDEwLjQxOVYyMS41OEMzMiAyNy4zMzUgMjcuMzM1IDMyIDIxLjU4MSAzMkgxMC40MkM0LjY2NSAzMiAwIDI3LjMzNSAwIDIxLjU4MVYxMC40MkMwIDQuNjY1IDQuNjY1IDAgMTAuNDE5IDB6bTAgMS40ODhhOC45MyA4LjkzIDAgMDAtOC45MyA4LjkzdjExLjE2M2E4LjkzIDguOTMgMCAwMDguOTMgOC45M0gyMS41OGE4LjkzIDguOTMgMCAwMDguOTMtOC45M1YxMC40MmE4LjkzIDguOTMgMCAwMC04LjkzLTguOTNIMTAuNDJ6IiBmaWxsPSIjZmZmIi8+PHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNS45OTggMjYuMDQ5Yy01LjU0OSAwLTEwLjA0Ny00LjQ5OC0xMC4wNDctMTAuMDQ3IDAtNS41NDggNC40OTgtMTAuMDQ2IDEwLjA0Ny0xMC4wNDYgNS41NDggMCAxMC4wNDYgNC40OTggMTAuMDQ2IDEwLjA0NiAwIDUuNTQ5LTQuNDk4IDEwLjA0Ny0xMC4wNDYgMTAuMDQ3eiIgZmlsbD0iI2ZmZiIvPjxwYXRoIGQ9Ik0xMi43NjIgMTQuMjU0YzAtLjgyMi42NjctMS40ODkgMS40ODktMS40ODloMy40OTdjLjgyMiAwIDEuNDg4LjY2NiAxLjQ4OCAxLjQ4OXYzLjQ5N2MwIC44MjItLjY2NiAxLjQ4OC0xLjQ4OCAxLjQ4OGgtMy40OTdhMS40ODggMS40ODggMCAwMS0xLjQ4OS0xLjQ4OHYtMy40OTh6IiBmaWxsPSIjMTY1MkYwIi8+PC9zdmc+",a="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iMTIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEyIDYuNzV2LTEuNWwtMS43Mi0uNTdjLS4wOC0uMjctLjE5LS41Mi0uMzItLjc3bC44MS0xLjYyLTEuMDYtMS4wNi0xLjYyLjgxYy0uMjQtLjEzLS41LS4yNC0uNzctLjMyTDYuNzUgMGgtMS41bC0uNTcgMS43MmMtLjI3LjA4LS41My4xOS0uNzcuMzJsLTEuNjItLjgxLTEuMDYgMS4wNi44MSAxLjYyYy0uMTMuMjQtLjI0LjUtLjMyLjc3TDAgNS4yNXYxLjVsMS43Mi41N2MuMDguMjcuMTkuNTMuMzIuNzdsLS44MSAxLjYyIDEuMDYgMS4wNiAxLjYyLS44MWMuMjQuMTMuNS4yMy43Ny4zMkw1LjI1IDEyaDEuNWwuNTctMS43MmMuMjctLjA4LjUyLS4xOS43Ny0uMzJsMS42Mi44MSAxLjA2LTEuMDYtLjgxLTEuNjJjLjEzLS4yNC4yMy0uNS4zMi0uNzdMMTIgNi43NXpNNiA4LjVhMi41IDIuNSAwIDAxMC01IDIuNSAyLjUgMCAwMTAgNXoiIGZpbGw9IiMwNTBGMTkiLz48L3N2Zz4=";class c{constructor(h){this.items=new Map,this.nextItemKey=0,this.root=null,this.darkMode=h.darkMode}attach(h){this.root=document.createElement("div"),this.root.className="-cbwsdk-snackbar-root",h.appendChild(this.root),this.render()}presentItem(h){const f=this.nextItemKey++;return this.items.set(f,h),this.render(),()=>{this.items.delete(f),this.render()}}clear(){this.items.clear(),this.render()}render(){this.root&&(0,n.render)((0,n.h)("div",null,(0,n.h)(e.SnackbarContainer,{darkMode:this.darkMode},Array.from(this.items.entries()).map(([h,f])=>(0,n.h)(e.SnackbarInstance,Object.assign({},f,{key:h}))))),this.root)}}e.Snackbar=c;const l=d=>(0,n.h)("div",{class:(0,r.default)("-cbwsdk-snackbar-container")},(0,n.h)("style",null,i.default),(0,n.h)("div",{class:"-cbwsdk-snackbar"},d.children));e.SnackbarContainer=l;const u=({autoExpand:d,message:h,menuItems:f})=>{const[b,g]=(0,s.useState)(!0),[E,y]=(0,s.useState)(d??!1);(0,s.useEffect)(()=>{const _=[window.setTimeout(()=>{g(!1)},1),window.setTimeout(()=>{y(!0)},1e4)];return()=>{_.forEach(window.clearTimeout)}});const p=()=>{y(!E)};return(0,n.h)("div",{class:(0,r.default)("-cbwsdk-snackbar-instance",b&&"-cbwsdk-snackbar-instance-hidden",E&&"-cbwsdk-snackbar-instance-expanded")},(0,n.h)("div",{class:"-cbwsdk-snackbar-instance-header",onClick:p},(0,n.h)("img",{src:o,class:"-cbwsdk-snackbar-instance-header-cblogo"})," ",(0,n.h)("div",{class:"-cbwsdk-snackbar-instance-header-message"},h),(0,n.h)("div",{class:"-gear-container"},!E&&(0,n.h)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,n.h)("circle",{cx:"12",cy:"12",r:"12",fill:"#F5F7F8"})),(0,n.h)("img",{src:a,class:"-gear-icon",title:"Expand"}))),f&&f.length>0&&(0,n.h)("div",{class:"-cbwsdk-snackbar-instance-menu"},f.map((_,A)=>(0,n.h)("div",{class:(0,r.default)("-cbwsdk-snackbar-instance-menu-item",_.isRed&&"-cbwsdk-snackbar-instance-menu-item-is-red"),onClick:_.onClick,key:A},(0,n.h)("svg",{width:_.svgWidth,height:_.svgHeight,viewBox:"0 0 10 11",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,n.h)("path",{"fill-rule":_.defaultFillRule,"clip-rule":_.defaultClipRule,d:_.path,fill:"#AAAAAA"})),(0,n.h)("span",{class:(0,r.default)("-cbwsdk-snackbar-instance-menu-item-info",_.isRed&&"-cbwsdk-snackbar-instance-menu-item-info-is-red")},_.info)))))};e.SnackbarInstance=u})(Pi);Object.defineProperty(fr,"__esModule",{value:!0});fr.WalletLinkRelayUI=void 0;const nf=gr,sf=fn,of=Pi;class af{constructor(t){this.standalone=null,this.attached=!1,this.snackbar=new of.Snackbar({darkMode:t.darkMode}),this.linkFlow=new sf.LinkFlow({darkMode:t.darkMode,version:t.version,sessionId:t.session.id,sessionSecret:t.session.secret,linkAPIUrl:t.linkAPIUrl,isParentConnection:!1})}attach(){if(this.attached)throw new Error("Coinbase Wallet SDK UI is already attached");const t=document.documentElement,r=document.createElement("div");r.className="-cbwsdk-css-reset",t.appendChild(r),this.linkFlow.attach(r),this.snackbar.attach(r),this.attached=!0,(0,nf.injectCssReset)()}setConnected(t){this.linkFlow.setConnected(t)}setChainId(t){this.linkFlow.setChainId(t)}setConnectDisabled(t){this.linkFlow.setConnectDisabled(t)}addEthereumChain(){}watchAsset(){}switchEthereumChain(){}requestEthereumAccounts(t){this.linkFlow.open({onCancel:t.onCancel})}hideRequestEthereumAccounts(){this.linkFlow.close()}signEthereumMessage(){}signEthereumTransaction(){}submitEthereumTransaction(){}ethereumAddressFromSignedMessage(){}showConnecting(t){let r;return t.isUnlinkedErrorState?r={autoExpand:!0,message:"Connection lost",menuItems:[{isRed:!1,info:"Reset connection",svgWidth:"10",svgHeight:"11",path:"M5.00008 0.96875C6.73133 0.96875 8.23758 1.94375 9.00008 3.375L10.0001 2.375V5.5H9.53133H7.96883H6.87508L7.80633 4.56875C7.41258 3.3875 6.31258 2.53125 5.00008 2.53125C3.76258 2.53125 2.70633 3.2875 2.25633 4.36875L0.812576 3.76875C1.50008 2.125 3.11258 0.96875 5.00008 0.96875ZM2.19375 6.43125C2.5875 7.6125 3.6875 8.46875 5 8.46875C6.2375 8.46875 7.29375 7.7125 7.74375 6.63125L9.1875 7.23125C8.5 8.875 6.8875 10.0312 5 10.0312C3.26875 10.0312 1.7625 9.05625 1 7.625L0 8.625V5.5H0.46875H2.03125H3.125L2.19375 6.43125Z",defaultFillRule:"evenodd",defaultClipRule:"evenodd",onClick:t.onResetConnection}]}:r={message:"Confirm on phone",menuItems:[{isRed:!0,info:"Cancel transaction",svgWidth:"11",svgHeight:"11",path:"M10.3711 1.52346L9.21775 0.370117L5.37109 4.21022L1.52444 0.370117L0.371094 1.52346L4.2112 5.37012L0.371094 9.21677L1.52444 10.3701L5.37109 6.53001L9.21775 10.3701L10.3711 9.21677L6.53099 5.37012L10.3711 1.52346Z",defaultFillRule:"inherit",defaultClipRule:"inherit",onClick:t.onCancel},{isRed:!1,info:"Reset connection",svgWidth:"10",svgHeight:"11",path:"M5.00008 0.96875C6.73133 0.96875 8.23758 1.94375 9.00008 3.375L10.0001 2.375V5.5H9.53133H7.96883H6.87508L7.80633 4.56875C7.41258 3.3875 6.31258 2.53125 5.00008 2.53125C3.76258 2.53125 2.70633 3.2875 2.25633 4.36875L0.812576 3.76875C1.50008 2.125 3.11258 0.96875 5.00008 0.96875ZM2.19375 6.43125C2.5875 7.6125 3.6875 8.46875 5 8.46875C6.2375 8.46875 7.29375 7.7125 7.74375 6.63125L9.1875 7.23125C8.5 8.875 6.8875 10.0312 5 10.0312C3.26875 10.0312 1.7625 9.05625 1 7.625L0 8.625V5.5H0.46875H2.03125H3.125L2.19375 6.43125Z",defaultFillRule:"evenodd",defaultClipRule:"evenodd",onClick:t.onResetConnection}]},this.snackbar.presentItem(r)}reloadUI(){document.location.reload()}inlineAccountsResponse(){return!1}inlineAddEthereumChain(){return!1}inlineWatchAsset(){return!1}inlineSwitchEthereumChain(){return!1}setStandalone(t){this.standalone=t}isStandalone(){var t;return(t=this.standalone)!==null&&t!==void 0?t:!1}}fr.WalletLinkRelayUI=af;Object.defineProperty(cr,"__esModule",{value:!0});cr.WalletLinkRelay=void 0;const bt=nr,cf=ie,Q=S,et=Dt,Yo=ke,Je=Ft,lf=un,tt=Ot,uf=fr;class Ve extends Yo.RelayAbstract{constructor(t){var r;super(),this.accountsCallback=null,this.chainCallbackParams={chainId:"",jsonRpcUrl:""},this.chainCallback=null,this.dappDefaultChain=1,this.appName="",this.appLogoUrl=null,this.linkedUpdated=o=>{var a;this.isLinked=o;const c=this.storage.getItem(Yo.LOCAL_STORAGE_ADDRESSES_KEY);if(o&&(this.session.linked=o),this.isUnlinkedErrorState=!1,c){const l=c.split(" "),u=this.storage.getItem("IsStandaloneSigning")==="true";if(l[0]!==""&&!o&&this.session.linked&&!u){this.isUnlinkedErrorState=!0;const d=this.getSessionIdHash();(a=this.diagnostic)===null||a===void 0||a.log(et.EVENTS.UNLINKED_ERROR_STATE,{sessionIdHash:d})}}},this.metadataUpdated=(o,a)=>{this.storage.setItem(o,a)},this.chainUpdated=(o,a)=>{this.chainCallbackParams.chainId===o&&this.chainCallbackParams.jsonRpcUrl===a||(this.chainCallbackParams={chainId:o,jsonRpcUrl:a},this.chainCallback&&this.chainCallback(o,a))},this.accountUpdated=o=>{this.accountsCallback&&this.accountsCallback([o]),Ve.accountRequestCallbackIds.size>0&&(Array.from(Ve.accountRequestCallbackIds.values()).forEach(a=>{const c={type:"WEB3_RESPONSE",id:a,response:{method:"requestEthereumAccounts",result:[o]}};this.invokeCallback(Object.assign(Object.assign({},c),{id:a}))}),Ve.accountRequestCallbackIds.clear())},this.connectedUpdated=o=>{this.ui.setConnected(o)},this.resetAndReload=this.resetAndReload.bind(this),this.linkAPIUrl=t.linkAPIUrl,this.storage=t.storage,this.options=t;const{session:n,ui:s,connection:i}=this.subscribe();this._session=n,this.connection=i,this.relayEventManager=t.relayEventManager,this.diagnostic=t.diagnosticLogger,this._reloadOnDisconnect=(r=t.reloadOnDisconnect)!==null&&r!==void 0?r:!0,this.ui=s}subscribe(){const t=Je.Session.load(this.storage)||new Je.Session(this.storage).save(),{linkAPIUrl:r,diagnostic:n}=this,s=new lf.WalletLinkConnection({session:t,linkAPIUrl:r,diagnostic:n,listener:this}),{version:i,darkMode:o}=this.options,a=this.options.uiConstructor({linkAPIUrl:r,version:i,darkMode:o,session:t});return s.connect(),{session:t,ui:a,connection:s}}attachUI(){this.ui.attach()}resetAndReload(){Promise.race([this.connection.setSessionMetadata("__destroyed","1"),new Promise(t=>setTimeout(()=>t(null),1e3))]).then(()=>{var t,r;const n=this.ui.isStandalone();(t=this.diagnostic)===null||t===void 0||t.log(et.EVENTS.SESSION_STATE_CHANGE,{method:"relay::resetAndReload",sessionMetadataChange:"__destroyed, 1",sessionIdHash:this.getSessionIdHash()}),this.connection.destroy();const s=Je.Session.load(this.storage);if((s==null?void 0:s.id)===this._session.id?this.storage.clear():s&&((r=this.diagnostic)===null||r===void 0||r.log(et.EVENTS.SKIPPED_CLEARING_SESSION,{sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:Je.Session.hash(s.id)})),this._reloadOnDisconnect){this.ui.reloadUI();return}this.accountsCallback&&this.accountsCallback([],!0);const{session:i,ui:o,connection:a}=this.subscribe();this._session=i,this.connection=a,this.ui=o,n&&this.ui.setStandalone&&this.ui.setStandalone(!0),this.options.headlessMode||this.attachUI()}).catch(t=>{var r;(r=this.diagnostic)===null||r===void 0||r.log(et.EVENTS.FAILURE,{method:"relay::resetAndReload",message:`failed to reset and reload with ${t}`,sessionIdHash:this.getSessionIdHash()})})}setAppInfo(t,r){this.appName=t,this.appLogoUrl=r}getStorageItem(t){return this.storage.getItem(t)}get session(){return this._session}setStorageItem(t,r){this.storage.setItem(t,r)}signEthereumMessage(t,r,n,s){return this.sendRequest({method:"signEthereumMessage",params:{message:(0,Q.hexStringFromBuffer)(t,!0),address:r,addPrefix:n,typedDataJson:s||null}})}ethereumAddressFromSignedMessage(t,r,n){return this.sendRequest({method:"ethereumAddressFromSignedMessage",params:{message:(0,Q.hexStringFromBuffer)(t,!0),signature:(0,Q.hexStringFromBuffer)(r,!0),addPrefix:n}})}signEthereumTransaction(t){return this.sendRequest({method:"signEthereumTransaction",params:{fromAddress:t.fromAddress,toAddress:t.toAddress,weiValue:(0,Q.bigIntStringFromBN)(t.weiValue),data:(0,Q.hexStringFromBuffer)(t.data,!0),nonce:t.nonce,gasPriceInWei:t.gasPriceInWei?(0,Q.bigIntStringFromBN)(t.gasPriceInWei):null,maxFeePerGas:t.gasPriceInWei?(0,Q.bigIntStringFromBN)(t.gasPriceInWei):null,maxPriorityFeePerGas:t.gasPriceInWei?(0,Q.bigIntStringFromBN)(t.gasPriceInWei):null,gasLimit:t.gasLimit?(0,Q.bigIntStringFromBN)(t.gasLimit):null,chainId:t.chainId,shouldSubmit:!1}})}signAndSubmitEthereumTransaction(t){return this.sendRequest({method:"signEthereumTransaction",params:{fromAddress:t.fromAddress,toAddress:t.toAddress,weiValue:(0,Q.bigIntStringFromBN)(t.weiValue),data:(0,Q.hexStringFromBuffer)(t.data,!0),nonce:t.nonce,gasPriceInWei:t.gasPriceInWei?(0,Q.bigIntStringFromBN)(t.gasPriceInWei):null,maxFeePerGas:t.maxFeePerGas?(0,Q.bigIntStringFromBN)(t.maxFeePerGas):null,maxPriorityFeePerGas:t.maxPriorityFeePerGas?(0,Q.bigIntStringFromBN)(t.maxPriorityFeePerGas):null,gasLimit:t.gasLimit?(0,Q.bigIntStringFromBN)(t.gasLimit):null,chainId:t.chainId,shouldSubmit:!0}})}submitEthereumTransaction(t,r){return this.sendRequest({method:"submitEthereumTransaction",params:{signedTransaction:(0,Q.hexStringFromBuffer)(t,!0),chainId:r}})}scanQRCode(t){return this.sendRequest({method:"scanQRCode",params:{regExp:t}})}getQRCodeUrl(){return(0,Q.createQrUrl)(this._session.id,this._session.secret,this.linkAPIUrl,!1,this.options.version,this.dappDefaultChain)}genericRequest(t,r){return this.sendRequest({method:"generic",params:{action:r,data:t}})}sendGenericMessage(t){return this.sendRequest(t)}sendRequest(t){let r=null;const n=(0,Q.randomBytesHex)(8),s=o=>{this.publishWeb3RequestCanceledEvent(n),this.handleErrorResponse(n,t.method,o),r==null||r()};return{promise:new Promise((o,a)=>{this.ui.isStandalone()||(r=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:s,onResetConnection:this.resetAndReload})),this.relayEventManager.callbacks.set(n,c=>{if(r==null||r(),(0,tt.isErrorResponse)(c))return a(new Error(c.errorMessage));o(c)}),this.ui.isStandalone()?this.sendRequestStandalone(n,t):this.publishWeb3RequestEvent(n,t)}),cancel:s}}setConnectDisabled(t){this.ui.setConnectDisabled(t)}setAccountsCallback(t){this.accountsCallback=t}setChainCallback(t){this.chainCallback=t}setDappDefaultChainCallback(t){this.dappDefaultChain=t,this.ui instanceof uf.WalletLinkRelayUI&&this.ui.setChainId(t)}publishWeb3RequestEvent(t,r){var n;const s={type:"WEB3_REQUEST",id:t,request:r},i=Je.Session.load(this.storage);(n=this.diagnostic)===null||n===void 0||n.log(et.EVENTS.WEB3_REQUEST,{eventId:s.id,method:`relay::${r.method}`,sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:i?Je.Session.hash(i.id):"",isSessionMismatched:((i==null?void 0:i.id)!==this._session.id).toString()}),this.publishEvent("Web3Request",s,!0).then(o=>{var a;(a=this.diagnostic)===null||a===void 0||a.log(et.EVENTS.WEB3_REQUEST_PUBLISHED,{eventId:s.id,method:`relay::${r.method}`,sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:i?Je.Session.hash(i.id):"",isSessionMismatched:((i==null?void 0:i.id)!==this._session.id).toString()})}).catch(o=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:s.id,response:{method:r.method,errorMessage:o.message}})})}publishWeb3RequestCanceledEvent(t){const r={type:"WEB3_REQUEST_CANCELED",id:t};this.publishEvent("Web3RequestCanceled",r,!1).then()}publishEvent(t,r,n){return this.connection.publishEvent(t,r,n)}handleWeb3ResponseMessage(t){var r;const{response:n}=t;if((r=this.diagnostic)===null||r===void 0||r.log(et.EVENTS.WEB3_RESPONSE,{eventId:t.id,method:`relay::${n.method}`,sessionIdHash:this.getSessionIdHash()}),n.method==="requestEthereumAccounts"){Ve.accountRequestCallbackIds.forEach(s=>this.invokeCallback(Object.assign(Object.assign({},t),{id:s}))),Ve.accountRequestCallbackIds.clear();return}this.invokeCallback(t)}handleErrorResponse(t,r,n,s){var i;const o=(i=n==null?void 0:n.message)!==null&&i!==void 0?i:(0,bt.getMessageFromCode)(s);this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:t,response:{method:r,errorMessage:o,errorCode:s}})}invokeCallback(t){const r=this.relayEventManager.callbacks.get(t.id);r&&(r(t.response),this.relayEventManager.callbacks.delete(t.id))}requestEthereumAccounts(){const t={method:"requestEthereumAccounts",params:{appName:this.appName,appLogoUrl:this.appLogoUrl||null}},r=(0,Q.randomBytesHex)(8),n=i=>{this.publishWeb3RequestCanceledEvent(r),this.handleErrorResponse(r,t.method,i)};return{promise:new Promise((i,o)=>{if(this.relayEventManager.callbacks.set(r,a=>{if(this.ui.hideRequestEthereumAccounts(),(0,tt.isErrorResponse)(a))return o(new Error(a.errorMessage));i(a)}),this.ui.inlineAccountsResponse()){const a=c=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:r,response:{method:"requestEthereumAccounts",result:c}})};this.ui.requestEthereumAccounts({onCancel:n,onAccounts:a})}else{const a=bt.standardErrors.provider.userRejectedRequest("User denied account authorization");this.ui.requestEthereumAccounts({onCancel:()=>n(a)})}Ve.accountRequestCallbackIds.add(r),!this.ui.inlineAccountsResponse()&&!this.ui.isStandalone()&&this.publishWeb3RequestEvent(r,t)}),cancel:n}}selectProvider(t){const r={method:"selectProvider"},n=(0,Q.randomBytesHex)(8),s=o=>{this.publishWeb3RequestCanceledEvent(n),this.handleErrorResponse(n,r.method,o)},i=new Promise((o,a)=>{this.relayEventManager.callbacks.set(n,u=>{if((0,tt.isErrorResponse)(u))return a(new Error(u.errorMessage));o(u)});const c=u=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:n,response:{method:"selectProvider",result:cf.ProviderType.Unselected}})},l=u=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:n,response:{method:"selectProvider",result:u}})};this.ui.selectProvider&&this.ui.selectProvider({onApprove:l,onCancel:c,providerOptions:t})});return{cancel:s,promise:i}}watchAsset(t,r,n,s,i,o){const a={method:"watchAsset",params:{type:t,options:{address:r,symbol:n,decimals:s,image:i},chainId:o}};let c=null;const l=(0,Q.randomBytesHex)(8),u=h=>{this.publishWeb3RequestCanceledEvent(l),this.handleErrorResponse(l,a.method,h),c==null||c()};this.ui.inlineWatchAsset()||(c=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:u,onResetConnection:this.resetAndReload}));const d=new Promise((h,f)=>{this.relayEventManager.callbacks.set(l,E=>{if(c==null||c(),(0,tt.isErrorResponse)(E))return f(new Error(E.errorMessage));h(E)});const b=E=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:l,response:{method:"watchAsset",result:!1}})},g=()=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:l,response:{method:"watchAsset",result:!0}})};this.ui.inlineWatchAsset()&&this.ui.watchAsset({onApprove:g,onCancel:b,type:t,address:r,symbol:n,decimals:s,image:i,chainId:o}),!this.ui.inlineWatchAsset()&&!this.ui.isStandalone()&&this.publishWeb3RequestEvent(l,a)});return{cancel:u,promise:d}}addEthereumChain(t,r,n,s,i,o){const a={method:"addEthereumChain",params:{chainId:t,rpcUrls:r,blockExplorerUrls:s,chainName:i,iconUrls:n,nativeCurrency:o}};let c=null;const l=(0,Q.randomBytesHex)(8),u=h=>{this.publishWeb3RequestCanceledEvent(l),this.handleErrorResponse(l,a.method,h),c==null||c()};return this.ui.inlineAddEthereumChain(t)||(c=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:u,onResetConnection:this.resetAndReload})),{promise:new Promise((h,f)=>{this.relayEventManager.callbacks.set(l,E=>{if(c==null||c(),(0,tt.isErrorResponse)(E))return f(new Error(E.errorMessage));h(E)});const b=E=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:l,response:{method:"addEthereumChain",result:{isApproved:!1,rpcUrl:""}}})},g=E=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:l,response:{method:"addEthereumChain",result:{isApproved:!0,rpcUrl:E}}})};this.ui.inlineAddEthereumChain(t)&&this.ui.addEthereumChain({onCancel:b,onApprove:g,chainId:a.params.chainId,rpcUrls:a.params.rpcUrls,blockExplorerUrls:a.params.blockExplorerUrls,chainName:a.params.chainName,iconUrls:a.params.iconUrls,nativeCurrency:a.params.nativeCurrency}),!this.ui.inlineAddEthereumChain(t)&&!this.ui.isStandalone()&&this.publishWeb3RequestEvent(l,a)}),cancel:u}}switchEthereumChain(t,r){const n={method:"switchEthereumChain",params:Object.assign({chainId:t},{address:r})},s=(0,Q.randomBytesHex)(8),i=a=>{this.publishWeb3RequestCanceledEvent(s),this.handleErrorResponse(s,n.method,a)};return{promise:new Promise((a,c)=>{this.relayEventManager.callbacks.set(s,d=>{if((0,tt.isErrorResponse)(d)&&d.errorCode)return c(bt.standardErrors.provider.custom({code:d.errorCode,message:"Unrecognized chain ID. Try adding the chain using addEthereumChain first."}));if((0,tt.isErrorResponse)(d))return c(new Error(d.errorMessage));a(d)});const l=d=>{var h;if(d){const f=(h=(0,bt.getErrorCode)(d))!==null&&h!==void 0?h:bt.standardErrorCodes.provider.unsupportedChain;this.handleErrorResponse(s,"switchEthereumChain",d instanceof Error?d:bt.standardErrors.provider.unsupportedChain(t),f)}else this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:s,response:{method:"switchEthereumChain",result:{isApproved:!1,rpcUrl:""}}})},u=d=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:s,response:{method:"switchEthereumChain",result:{isApproved:!0,rpcUrl:d}}})};this.ui.switchEthereumChain({onCancel:l,onApprove:u,chainId:n.params.chainId,address:n.params.address}),!this.ui.inlineSwitchEthereumChain()&&!this.ui.isStandalone()&&this.publishWeb3RequestEvent(s,n)}),cancel:i}}inlineAddEthereumChain(t){return this.ui.inlineAddEthereumChain(t)}getSessionIdHash(){return Je.Session.hash(this._session.id)}sendRequestStandalone(t,r){const n=i=>{this.handleErrorResponse(t,r.method,i)},s=i=>{this.handleWeb3ResponseMessage({type:"WEB3_RESPONSE",id:t,response:i})};switch(r.method){case"signEthereumMessage":this.ui.signEthereumMessage({request:r,onSuccess:s,onCancel:n});break;case"signEthereumTransaction":this.ui.signEthereumTransaction({request:r,onSuccess:s,onCancel:n});break;case"submitEthereumTransaction":this.ui.submitEthereumTransaction({request:r,onSuccess:s,onCancel:n});break;case"ethereumAddressFromSignedMessage":this.ui.ethereumAddressFromSignedMessage({request:r,onSuccess:s});break;default:n();break}}}cr.WalletLinkRelay=Ve;Ve.accountRequestCallbackIds=new Set;var br={},Cn={},Dc={};(function(e){var t=x&&x.__createBinding||(Object.create?function(n,s,i,o){o===void 0&&(o=i);var a=Object.getOwnPropertyDescriptor(s,i);(!a||("get"in a?!s.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return s[i]}}),Object.defineProperty(n,o,a)}:function(n,s,i,o){o===void 0&&(o=i),n[o]=s[i]}),r=x&&x.__exportStar||function(n,s){for(var i in n)i!=="default"&&!Object.prototype.hasOwnProperty.call(s,i)&&t(s,n,i)};Object.defineProperty(e,"__esModule",{value:!0}),r(Pi,e)})(Dc);var Bi={};Object.defineProperty(Bi,"__esModule",{value:!0});Bi.default=".-cbwsdk-css-reset .-cbwsdk-redirect-dialog-backdrop{position:fixed;top:0;left:0;right:0;bottom:0;transition:opacity .25s;background-color:rgba(10,11,13,.5)}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-backdrop-hidden{opacity:0}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box{display:block;position:fixed;top:50%;left:50%;transform:translate(-50%, -50%);padding:20px;border-radius:8px;background-color:#fff;color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box p{display:block;font-weight:400;font-size:14px;line-height:20px;padding-bottom:12px;color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box button{appearance:none;border:none;background:none;color:#0052ff;padding:0;text-decoration:none;display:block;font-weight:600;font-size:16px;line-height:24px}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.dark{background-color:#0a0b0d;color:#fff}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.dark button{color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.light{background-color:#fff;color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.light button{color:#0052ff}";var Fc=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Cn,"__esModule",{value:!0});Cn.RedirectDialog=void 0;const df=Fc(rr),Be=_e,hf=gr,ff=Dc,gf=Fc(Bi);class pf{constructor(){this.root=null}attach(){const t=document.documentElement;this.root=document.createElement("div"),this.root.className="-cbwsdk-css-reset",t.appendChild(this.root),(0,hf.injectCssReset)()}present(t){this.render(t)}clear(){this.render(null)}render(t){this.root&&((0,Be.render)(null,this.root),t&&(0,Be.render)((0,Be.h)(_f,Object.assign({},t,{onDismiss:()=>{this.clear()}})),this.root))}}Cn.RedirectDialog=pf;const _f=({title:e,buttonText:t,darkMode:r,onButtonClick:n,onDismiss:s})=>{const i=r?"dark":"light";return(0,Be.h)(ff.SnackbarContainer,{darkMode:r},(0,Be.h)("div",{class:"-cbwsdk-redirect-dialog"},(0,Be.h)("style",null,gf.default),(0,Be.h)("div",{class:"-cbwsdk-redirect-dialog-backdrop",onClick:s}),(0,Be.h)("div",{class:(0,df.default)("-cbwsdk-redirect-dialog-box",i)},(0,Be.h)("p",null,e),(0,Be.h)("button",{onClick:n},t))))};Object.defineProperty(br,"__esModule",{value:!0});br.MobileRelayUI=void 0;const mf=Cn;class bf{constructor(t){this.attached=!1,this.darkMode=!1,this.redirectDialog=new mf.RedirectDialog,this.darkMode=t.darkMode}attach(){if(this.attached)throw new Error("Coinbase Wallet SDK UI is already attached");this.redirectDialog.attach(),this.attached=!0}setConnected(t){}redirectToCoinbaseWallet(t){const r=new URL("https://go.cb-w.com/walletlink");r.searchParams.append("redirect_url",window.location.href),t&&r.searchParams.append("wl_url",t);const n=document.createElement("a");n.target="cbw-opener",n.href=r.href,n.rel="noreferrer noopener",n.click()}openCoinbaseWalletDeeplink(t){this.redirectDialog.present({title:"Redirecting to Coinbase Wallet...",buttonText:"Open",darkMode:this.darkMode,onButtonClick:()=>{this.redirectToCoinbaseWallet(t)}}),setTimeout(()=>{this.redirectToCoinbaseWallet(t)},99)}showConnecting(t){return()=>{this.redirectDialog.clear()}}hideRequestEthereumAccounts(){this.redirectDialog.clear()}requestEthereumAccounts(){}addEthereumChain(){}watchAsset(){}selectProvider(){}switchEthereumChain(){}signEthereumMessage(){}signEthereumTransaction(){}submitEthereumTransaction(){}ethereumAddressFromSignedMessage(){}reloadUI(){}setStandalone(){}setConnectDisabled(){}inlineAccountsResponse(){return!1}inlineAddEthereumChain(){return!1}inlineWatchAsset(){return!1}inlineSwitchEthereumChain(){return!1}isStandalone(){return!1}}br.MobileRelayUI=bf;Object.defineProperty(ar,"__esModule",{value:!0});ar.MobileRelay=void 0;const yf=S,wf=cr,vf=br;class Ef extends wf.WalletLinkRelay{constructor(t){var r;super(t),this._enableMobileWalletLink=(r=t.enableMobileWalletLink)!==null&&r!==void 0?r:!1}requestEthereumAccounts(){return this._enableMobileWalletLink?super.requestEthereumAccounts():{promise:new Promise(()=>{const t=(0,yf.getLocation)();t.href=`https://go.cb-w.com/dapp?cb_url=${encodeURIComponent(t.href)}`}),cancel:()=>{}}}publishWeb3RequestEvent(t,r){if(super.publishWeb3RequestEvent(t,r),!(this._enableMobileWalletLink&&this.ui instanceof vf.MobileRelayUI))return;let n=!1;switch(r.method){case"requestEthereumAccounts":case"connectAndSignIn":n=!0,this.ui.openCoinbaseWalletDeeplink(this.getQRCodeUrl());break;case"switchEthereumChain":return;default:n=!0,this.ui.openCoinbaseWalletDeeplink();break}n&&window.addEventListener("blur",()=>{window.addEventListener("focus",()=>{this.connection.checkUnseenEvents()},{once:!0})},{once:!0})}handleWeb3ResponseMessage(t){super.handleWeb3ResponseMessage(t)}connectAndSignIn(t){if(!this._enableMobileWalletLink)throw new Error("connectAndSignIn is supported only when enableMobileWalletLink is on");return this.sendRequest({method:"connectAndSignIn",params:{appName:this.appName,appLogoUrl:this.appLogoUrl,domain:window.location.hostname,aud:window.location.href,version:"1",type:"eip4361",nonce:t.nonce,iat:new Date().toISOString(),chainId:`eip155:${this.dappDefaultChain}`,statement:t.statement,resources:t.resources}})}}ar.MobileRelay=Ef;const{Transform:Sf}=Ha();var kf=e=>class jc extends Sf{constructor(r,n,s,i,o){super(o),this._rate=r,this._capacity=n,this._delimitedSuffix=s,this._hashBitLength=i,this._options=o,this._state=new e,this._state.initialize(r,n),this._finalized=!1}_transform(r,n,s){let i=null;try{this.update(r,n)}catch(o){i=o}s(i)}_flush(r){let n=null;try{this.push(this.digest())}catch(s){n=s}r(n)}update(r,n){if(!O.isBuffer(r)&&typeof r!="string")throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Digest already called");return O.isBuffer(r)||(r=O.from(r,n)),this._state.absorb(r),this}digest(r){if(this._finalized)throw new Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);let n=this._state.squeeze(this._hashBitLength/8);return r!==void 0&&(n=n.toString(r)),this._resetState(),n}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){const r=new jc(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(r._state),r._finalized=this._finalized,r}};const{Transform:Cf}=Ha();var Rf=e=>class $c extends Cf{constructor(r,n,s,i){super(i),this._rate=r,this._capacity=n,this._delimitedSuffix=s,this._options=i,this._state=new e,this._state.initialize(r,n),this._finalized=!1}_transform(r,n,s){let i=null;try{this.update(r,n)}catch(o){i=o}s(i)}_flush(){}_read(r){this.push(this.squeeze(r))}update(r,n){if(!O.isBuffer(r)&&typeof r!="string")throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Squeeze already called");return O.isBuffer(r)||(r=O.from(r,n)),this._state.absorb(r),this}squeeze(r,n){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));let s=this._state.squeeze(r);return n!==void 0&&(s=s.toString(n)),s}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){const r=new $c(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(r._state),r._finalized=this._finalized,r}};const If=kf,Af=Rf;var xf=function(e){const t=If(e),r=Af(e);return function(n,s){switch(typeof n=="string"?n.toLowerCase():n){case"keccak224":return new t(1152,448,null,224,s);case"keccak256":return new t(1088,512,null,256,s);case"keccak384":return new t(832,768,null,384,s);case"keccak512":return new t(576,1024,null,512,s);case"sha3-224":return new t(1152,448,6,224,s);case"sha3-256":return new t(1088,512,6,256,s);case"sha3-384":return new t(832,768,6,384,s);case"sha3-512":return new t(576,1024,6,512,s);case"shake128":return new r(1344,256,31,s);case"shake256":return new r(1088,512,31,s);default:throw new Error("Invald algorithm: "+n)}}},Hc={};const ea=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648];Hc.p1600=function(e){for(let t=0;t<24;++t){const r=e[0]^e[10]^e[20]^e[30]^e[40],n=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],i=e[3]^e[13]^e[23]^e[33]^e[43],o=e[4]^e[14]^e[24]^e[34]^e[44],a=e[5]^e[15]^e[25]^e[35]^e[45],c=e[6]^e[16]^e[26]^e[36]^e[46],l=e[7]^e[17]^e[27]^e[37]^e[47],u=e[8]^e[18]^e[28]^e[38]^e[48],d=e[9]^e[19]^e[29]^e[39]^e[49];let h=u^(s<<1|i>>>31),f=d^(i<<1|s>>>31);const b=e[0]^h,g=e[1]^f,E=e[10]^h,y=e[11]^f,p=e[20]^h,_=e[21]^f,A=e[30]^h,v=e[31]^f,N=e[40]^h,V=e[41]^f;h=r^(o<<1|a>>>31),f=n^(a<<1|o>>>31);const Z=e[2]^h,ee=e[3]^f,z=e[12]^h,W=e[13]^f,H=e[22]^h,se=e[23]^f,w=e[32]^h,m=e[33]^f,R=e[42]^h,C=e[43]^f;h=s^(c<<1|l>>>31),f=i^(l<<1|c>>>31);const I=e[4]^h,k=e[5]^f,L=e[14]^h,D=e[15]^f,T=e[24]^h,U=e[25]^f,ae=e[34]^h,J=e[35]^f,te=e[44]^h,Ie=e[45]^f;h=o^(u<<1|d>>>31),f=a^(d<<1|u>>>31);const Wt=e[6]^h,Lr=e[7]^f,no=e[16]^h,so=e[17]^f,io=e[26]^h,oo=e[27]^f,ao=e[36]^h,co=e[37]^f,lo=e[46]^h,uo=e[47]^f;h=c^(r<<1|n>>>31),f=l^(n<<1|r>>>31);const ho=e[8]^h,fo=e[9]^f,go=e[18]^h,po=e[19]^f,_o=e[28]^h,mo=e[29]^f,bo=e[38]^h,yo=e[39]^f,wo=e[48]^h,vo=e[49]^f,zn=b,qn=g,Jn=y<<4|E>>>28,Gn=E<<4|y>>>28,Zn=p<<3|_>>>29,Qn=_<<3|p>>>29,Kn=v<<9|A>>>23,Xn=A<<9|v>>>23,Yn=N<<18|V>>>14,es=V<<18|N>>>14,ts=Z<<1|ee>>>31,rs=ee<<1|Z>>>31,ns=W<<12|z>>>20,ss=z<<12|W>>>20,is=H<<10|se>>>22,os=se<<10|H>>>22,as=m<<13|w>>>19,cs=w<<13|m>>>19,ls=R<<2|C>>>30,us=C<<2|R>>>30,ds=k<<30|I>>>2,hs=I<<30|k>>>2,fs=L<<6|D>>>26,gs=D<<6|L>>>26,ps=U<<11|T>>>21,_s=T<<11|U>>>21,ms=ae<<15|J>>>17,bs=J<<15|ae>>>17,ys=Ie<<29|te>>>3,ws=te<<29|Ie>>>3,vs=Wt<<28|Lr>>>4,Es=Lr<<28|Wt>>>4,Ss=so<<23|no>>>9,ks=no<<23|so>>>9,Cs=io<<25|oo>>>7,Rs=oo<<25|io>>>7,Is=ao<<21|co>>>11,As=co<<21|ao>>>11,xs=uo<<24|lo>>>8,Ns=lo<<24|uo>>>8,Ls=ho<<27|fo>>>5,Ms=fo<<27|ho>>>5,Ts=go<<20|po>>>12,Ps=po<<20|go>>>12,Os=mo<<7|_o>>>25,Bs=_o<<7|mo>>>25,Ds=bo<<8|yo>>>24,Fs=yo<<8|bo>>>24,js=wo<<14|vo>>>18,$s=vo<<14|wo>>>18;e[0]=zn^~ns&ps,e[1]=qn^~ss&_s,e[10]=vs^~Ts&Zn,e[11]=Es^~Ps&Qn,e[20]=ts^~fs&Cs,e[21]=rs^~gs&Rs,e[30]=Ls^~Jn&is,e[31]=Ms^~Gn&os,e[40]=ds^~Ss&Os,e[41]=hs^~ks&Bs,e[2]=ns^~ps&Is,e[3]=ss^~_s&As,e[12]=Ts^~Zn&as,e[13]=Ps^~Qn&cs,e[22]=fs^~Cs&Ds,e[23]=gs^~Rs&Fs,e[32]=Jn^~is&ms,e[33]=Gn^~os&bs,e[42]=Ss^~Os&Kn,e[43]=ks^~Bs&Xn,e[4]=ps^~Is&js,e[5]=_s^~As&$s,e[14]=Zn^~as&ys,e[15]=Qn^~cs&ws,e[24]=Cs^~Ds&Yn,e[25]=Rs^~Fs&es,e[34]=is^~ms&xs,e[35]=os^~bs&Ns,e[44]=Os^~Kn&ls,e[45]=Bs^~Xn&us,e[6]=Is^~js&zn,e[7]=As^~$s&qn,e[16]=as^~ys&vs,e[17]=cs^~ws&Es,e[26]=Ds^~Yn&ts,e[27]=Fs^~es&rs,e[36]=ms^~xs&Ls,e[37]=bs^~Ns&Ms,e[46]=Kn^~ls&ds,e[47]=Xn^~us&hs,e[8]=js^~zn&ns,e[9]=$s^~qn&ss,e[18]=ys^~vs&Ts,e[19]=ws^~Es&Ps,e[28]=Yn^~ts&fs,e[29]=es^~rs&gs,e[38]=xs^~Ls&Jn,e[39]=Ns^~Ms&Gn,e[48]=ls^~ds&Ss,e[49]=us^~hs&ks,e[0]^=ea[t*2],e[1]^=ea[t*2+1]}};const Zr=Hc;function $t(){this.state=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],this.blockSize=null,this.count=0,this.squeezing=!1}$t.prototype.initialize=function(e,t){for(let r=0;r<50;++r)this.state[r]=0;this.blockSize=e/8,this.count=0,this.squeezing=!1};$t.prototype.absorb=function(e){for(let t=0;t<e.length;++t)this.state[~~(this.count/4)]^=e[t]<<8*(this.count%4),this.count+=1,this.count===this.blockSize&&(Zr.p1600(this.state),this.count=0)};$t.prototype.absorbLastFewBits=function(e){this.state[~~(this.count/4)]^=e<<8*(this.count%4),e&128&&this.count===this.blockSize-1&&Zr.p1600(this.state),this.state[~~((this.blockSize-1)/4)]^=128<<8*((this.blockSize-1)%4),Zr.p1600(this.state),this.count=0,this.squeezing=!0};$t.prototype.squeeze=function(e){this.squeezing||this.absorbLastFewBits(1);const t=O.alloc(e);for(let r=0;r<e;++r)t[r]=this.state[~~(this.count/4)]>>>8*(this.count%4)&255,this.count+=1,this.count===this.blockSize&&(Zr.p1600(this.state),this.count=0);return t};$t.prototype.copy=function(e){for(let t=0;t<50;++t)e.state[t]=this.state[t];e.blockSize=this.blockSize,e.count=this.count,e.squeezing=this.squeezing};var Nf=$t,Lf=xf(Nf);const Mf=Lf,Tf=Xr;function Uc(e){return O.allocUnsafe(e).fill(0)}function Vc(e,t,r){const n=Uc(t);return e=Rn(e),r?e.length<t?(e.copy(n),n):e.slice(0,t):e.length<t?(e.copy(n,t-e.length),n):e.slice(-t)}function Pf(e,t){return Vc(e,t,!0)}function Rn(e){if(!O.isBuffer(e))if(Array.isArray(e))e=O.from(e);else if(typeof e=="string")Wc(e)?e=O.from(Df(zc(e)),"hex"):e=O.from(e);else if(typeof e=="number")e=intToBuffer(e);else if(e==null)e=O.allocUnsafe(0);else if(Tf.isBN(e))e=e.toArrayLike(O);else if(e.toArray)e=O.from(e.toArray());else throw new Error("invalid type");return e}function Of(e){return e=Rn(e),"0x"+e.toString("hex")}function Bf(e,t){return e=Rn(e),t||(t=256),Mf("keccak"+t).update(e).digest()}function Df(e){return e.length%2?"0"+e:e}function Wc(e){return typeof e=="string"&&e.match(/^0x[0-9A-Fa-f]*$/)}function zc(e){return typeof e=="string"&&e.startsWith("0x")?e.slice(2):e}var qc={zeros:Uc,setLength:Vc,setLengthRight:Pf,isHexString:Wc,stripHexPrefix:zc,toBuffer:Rn,bufferToHex:Of,keccak:Bf};const ct=qc,it=Xr;function Jc(e){return e.startsWith("int[")?"int256"+e.slice(3):e==="int"?"int256":e.startsWith("uint[")?"uint256"+e.slice(4):e==="uint"?"uint256":e.startsWith("fixed[")?"fixed128x128"+e.slice(5):e==="fixed"?"fixed128x128":e.startsWith("ufixed[")?"ufixed128x128"+e.slice(6):e==="ufixed"?"ufixed128x128":e}function St(e){return parseInt(/^\D+(\d+)$/.exec(e)[1],10)}function ta(e){var t=/^\D+(\d+)x(\d+)$/.exec(e);return[parseInt(t[1],10),parseInt(t[2],10)]}function Gc(e){var t=e.match(/(.*)\[(.*?)\]$/);return t?t[2]===""?"dynamic":parseInt(t[2],10):null}function nt(e){var t=typeof e;if(t==="string")return ct.isHexString(e)?new it(ct.stripHexPrefix(e),16):new it(e,10);if(t==="number")return new it(e);if(e.toArray)return e;throw new Error("Argument is not a number")}function Oe(e,t){var r,n,s,i;if(e==="address")return Oe("uint160",nt(t));if(e==="bool")return Oe("uint8",t?1:0);if(e==="string")return Oe("bytes",new O(t,"utf8"));if(jf(e)){if(typeof t.length>"u")throw new Error("Not an array?");if(r=Gc(e),r!=="dynamic"&&r!==0&&t.length>r)throw new Error("Elements exceed array size: "+r);s=[],e=e.slice(0,e.lastIndexOf("[")),typeof t=="string"&&(t=JSON.parse(t));for(i in t)s.push(Oe(e,t[i]));if(r==="dynamic"){var o=Oe("uint256",t.length);s.unshift(o)}return O.concat(s)}else{if(e==="bytes")return t=new O(t),s=O.concat([Oe("uint256",t.length),t]),t.length%32!==0&&(s=O.concat([s,ct.zeros(32-t.length%32)])),s;if(e.startsWith("bytes")){if(r=St(e),r<1||r>32)throw new Error("Invalid bytes<N> width: "+r);return ct.setLengthRight(t,32)}else if(e.startsWith("uint")){if(r=St(e),r%8||r<8||r>256)throw new Error("Invalid uint<N> width: "+r);if(n=nt(t),n.bitLength()>r)throw new Error("Supplied uint exceeds width: "+r+" vs "+n.bitLength());if(n<0)throw new Error("Supplied uint is negative");return n.toArrayLike(O,"be",32)}else if(e.startsWith("int")){if(r=St(e),r%8||r<8||r>256)throw new Error("Invalid int<N> width: "+r);if(n=nt(t),n.bitLength()>r)throw new Error("Supplied int exceeds width: "+r+" vs "+n.bitLength());return n.toTwos(256).toArrayLike(O,"be",32)}else if(e.startsWith("ufixed")){if(r=ta(e),n=nt(t),n<0)throw new Error("Supplied ufixed is negative");return Oe("uint256",n.mul(new it(2).pow(new it(r[1]))))}else if(e.startsWith("fixed"))return r=ta(e),Oe("int256",nt(t).mul(new it(2).pow(new it(r[1]))))}throw new Error("Unsupported or invalid type: "+e)}function Ff(e){return e==="string"||e==="bytes"||Gc(e)==="dynamic"}function jf(e){return e.lastIndexOf("]")===e.length-1}function $f(e,t){var r=[],n=[],s=32*e.length;for(var i in e){var o=Jc(e[i]),a=t[i],c=Oe(o,a);Ff(o)?(r.push(Oe("uint256",s)),n.push(c),s+=c.length):r.push(c)}return O.concat(r.concat(n))}function Zc(e,t){if(e.length!==t.length)throw new Error("Number of types are not matching the values");for(var r,n,s=[],i=0;i<e.length;i++){var o=Jc(e[i]),a=t[i];if(o==="bytes")s.push(a);else if(o==="string")s.push(new O(a,"utf8"));else if(o==="bool")s.push(new O(a?"01":"00","hex"));else if(o==="address")s.push(ct.setLength(a,20));else if(o.startsWith("bytes")){if(r=St(o),r<1||r>32)throw new Error("Invalid bytes<N> width: "+r);s.push(ct.setLengthRight(a,r))}else if(o.startsWith("uint")){if(r=St(o),r%8||r<8||r>256)throw new Error("Invalid uint<N> width: "+r);if(n=nt(a),n.bitLength()>r)throw new Error("Supplied uint exceeds width: "+r+" vs "+n.bitLength());s.push(n.toArrayLike(O,"be",r/8))}else if(o.startsWith("int")){if(r=St(o),r%8||r<8||r>256)throw new Error("Invalid int<N> width: "+r);if(n=nt(a),n.bitLength()>r)throw new Error("Supplied int exceeds width: "+r+" vs "+n.bitLength());s.push(n.toTwos(r).toArrayLike(O,"be",r/8))}else throw new Error("Unsupported or invalid type: "+o)}return O.concat(s)}function Hf(e,t){return ct.keccak(Zc(e,t))}var Uf={rawEncode:$f,solidityPack:Zc,soliditySHA3:Hf};const xe=qc,Qt=Uf,Qc={type:"object",properties:{types:{type:"object",additionalProperties:{type:"array",items:{type:"object",properties:{name:{type:"string"},type:{type:"string"}},required:["name","type"]}}},primaryType:{type:"string"},domain:{type:"object"},message:{type:"object"}},required:["types","primaryType","domain","message"]},Qs={encodeData(e,t,r,n=!0){const s=["bytes32"],i=[this.hashType(e,r)];if(n){const o=(a,c,l)=>{if(r[c]!==void 0)return["bytes32",l==null?"0x0000000000000000000000000000000000000000000000000000000000000000":xe.keccak(this.encodeData(c,l,r,n))];if(l===void 0)throw new Error(`missing value for field ${a} of type ${c}`);if(c==="bytes")return["bytes32",xe.keccak(l)];if(c==="string")return typeof l=="string"&&(l=O.from(l,"utf8")),["bytes32",xe.keccak(l)];if(c.lastIndexOf("]")===c.length-1){const u=c.slice(0,c.lastIndexOf("[")),d=l.map(h=>o(a,u,h));return["bytes32",xe.keccak(Qt.rawEncode(d.map(([h])=>h),d.map(([,h])=>h)))]}return[c,l]};for(const a of r[e]){const[c,l]=o(a.name,a.type,t[a.name]);s.push(c),i.push(l)}}else for(const o of r[e]){let a=t[o.name];if(a!==void 0)if(o.type==="bytes")s.push("bytes32"),a=xe.keccak(a),i.push(a);else if(o.type==="string")s.push("bytes32"),typeof a=="string"&&(a=O.from(a,"utf8")),a=xe.keccak(a),i.push(a);else if(r[o.type]!==void 0)s.push("bytes32"),a=xe.keccak(this.encodeData(o.type,a,r,n)),i.push(a);else{if(o.type.lastIndexOf("]")===o.type.length-1)throw new Error("Arrays currently unimplemented in encodeData");s.push(o.type),i.push(a)}}return Qt.rawEncode(s,i)},encodeType(e,t){let r="",n=this.findTypeDependencies(e,t).filter(s=>s!==e);n=[e].concat(n.sort());for(const s of n){if(!t[s])throw new Error("No type definition specified: "+s);r+=s+"("+t[s].map(({name:o,type:a})=>a+" "+o).join(",")+")"}return r},findTypeDependencies(e,t,r=[]){if(e=e.match(/^\w*/)[0],r.includes(e)||t[e]===void 0)return r;r.push(e);for(const n of t[e])for(const s of this.findTypeDependencies(n.type,t,r))!r.includes(s)&&r.push(s);return r},hashStruct(e,t,r,n=!0){return xe.keccak(this.encodeData(e,t,r,n))},hashType(e,t){return xe.keccak(this.encodeType(e,t))},sanitizeData(e){const t={};for(const r in Qc.properties)e[r]&&(t[r]=e[r]);return t.types&&(t.types=Object.assign({EIP712Domain:[]},t.types)),t},hash(e,t=!0){const r=this.sanitizeData(e),n=[O.from("1901","hex")];return n.push(this.hashStruct("EIP712Domain",r.domain,r.types,t)),r.primaryType!=="EIP712Domain"&&n.push(this.hashStruct(r.primaryType,r.message,r.types,t)),xe.keccak(O.concat(n))}};var Vf={TYPED_MESSAGE_SCHEMA:Qc,TypedDataUtils:Qs,hashForSignTypedDataLegacy:function(e){return Wf(e.data)},hashForSignTypedData_v3:function(e){return Qs.hash(e.data,!1)},hashForSignTypedData_v4:function(e){return Qs.hash(e.data)}};function Wf(e){const t=new Error("Expect argument to be non-empty array");if(typeof e!="object"||!e.length)throw t;const r=e.map(function(i){return i.type==="bytes"?xe.toBuffer(i.value):i.value}),n=e.map(function(i){return i.type}),s=e.map(function(i){if(!i.name)throw t;return i.type+" "+i.name});return Qt.soliditySHA3(["bytes32","bytes32"],[Qt.soliditySHA3(new Array(e.length).fill("string"),s),Qt.soliditySHA3(n,r)])}var Lt={};Object.defineProperty(Lt,"__esModule",{value:!0});Lt.filterFromParam=Lt.FilterPolyfill=void 0;const wt=ie,ge=S,zf=5*60*1e3,st={jsonrpc:"2.0",id:0};class qf{constructor(t){this.logFilters=new Map,this.blockFilters=new Set,this.pendingTransactionFilters=new Set,this.cursors=new Map,this.timeouts=new Map,this.nextFilterId=(0,wt.IntNumber)(1),this.REQUEST_THROTTLE_INTERVAL=1e3,this.lastFetchTimestamp=new Date(0),this.resolvers=[],this.provider=t}async newFilter(t){const r=Kc(t),n=this.makeFilterId(),s=await this.setInitialCursorPosition(n,r.fromBlock);return console.info(`Installing new log filter(${n}):`,r,"initial cursor position:",s),this.logFilters.set(n,r),this.setFilterTimeout(n),(0,ge.hexStringFromIntNumber)(n)}async newBlockFilter(){const t=this.makeFilterId(),r=await this.setInitialCursorPosition(t,"latest");return console.info(`Installing new block filter (${t}) with initial cursor position:`,r),this.blockFilters.add(t),this.setFilterTimeout(t),(0,ge.hexStringFromIntNumber)(t)}async newPendingTransactionFilter(){const t=this.makeFilterId(),r=await this.setInitialCursorPosition(t,"latest");return console.info(`Installing new block filter (${t}) with initial cursor position:`,r),this.pendingTransactionFilters.add(t),this.setFilterTimeout(t),(0,ge.hexStringFromIntNumber)(t)}uninstallFilter(t){const r=(0,ge.intNumberFromHexString)(t);return console.info(`Uninstalling filter (${r})`),this.deleteFilter(r),!0}getFilterChanges(t){const r=(0,ge.intNumberFromHexString)(t);return this.timeouts.has(r)&&this.setFilterTimeout(r),this.logFilters.has(r)?this.getLogFilterChanges(r):this.blockFilters.has(r)?this.getBlockFilterChanges(r):this.pendingTransactionFilters.has(r)?this.getPendingTransactionFilterChanges(r):Promise.resolve(Dr())}async getFilterLogs(t){const r=(0,ge.intNumberFromHexString)(t),n=this.logFilters.get(r);return n?this.sendAsyncPromise(Object.assign(Object.assign({},st),{method:"eth_getLogs",params:[ra(n)]})):Dr()}makeFilterId(){return(0,wt.IntNumber)(++this.nextFilterId)}sendAsyncPromise(t){return new Promise((r,n)=>{this.provider.sendAsync(t,(s,i)=>{if(s)return n(s);if(Array.isArray(i)||i==null)return n(new Error(`unexpected response received: ${JSON.stringify(i)}`));r(i)})})}deleteFilter(t){console.info(`Deleting filter (${t})`),this.logFilters.delete(t),this.blockFilters.delete(t),this.pendingTransactionFilters.delete(t),this.cursors.delete(t),this.timeouts.delete(t)}async getLogFilterChanges(t){const r=this.logFilters.get(t),n=this.cursors.get(t);if(!n||!r)return Dr();const s=await this.getCurrentBlockHeight(),i=r.toBlock==="latest"?s:r.toBlock;if(n>s||n>Number(r.toBlock))return Fr();console.info(`Fetching logs from ${n} to ${i} for filter ${t}`);const o=await this.sendAsyncPromise(Object.assign(Object.assign({},st),{method:"eth_getLogs",params:[ra(Object.assign(Object.assign({},r),{fromBlock:n,toBlock:i}))]}));if(Array.isArray(o.result)){const a=o.result.map(l=>(0,ge.intNumberFromHexString)(l.blockNumber||"0x0")),c=Math.max(...a);if(c&&c>n){const l=(0,wt.IntNumber)(c+1);console.info(`Moving cursor position for filter (${t}) from ${n} to ${l}`),this.cursors.set(t,l)}}return o}async getBlockFilterChanges(t){const r=this.cursors.get(t);if(!r)return Dr();const n=await this.getCurrentBlockHeight();if(r>n)return Fr();console.info(`Fetching blocks from ${r} to ${n} for filter (${t})`);const s=(await Promise.all((0,ge.range)(r,n+1).map(o=>this.getBlockHashByNumber((0,wt.IntNumber)(o))))).filter(o=>!!o),i=(0,wt.IntNumber)(r+s.length);return console.info(`Moving cursor position for filter (${t}) from ${r} to ${i}`),this.cursors.set(t,i),Object.assign(Object.assign({},st),{result:s})}async getPendingTransactionFilterChanges(t){return Promise.resolve(Fr())}async setInitialCursorPosition(t,r){const n=await this.getCurrentBlockHeight(),s=typeof r=="number"&&r>n?r:n;return this.cursors.set(t,s),s}setFilterTimeout(t){const r=this.timeouts.get(t);r&&window.clearTimeout(r);const n=window.setTimeout(()=>{console.info(`Filter (${t}) timed out`),this.deleteFilter(t)},zf);this.timeouts.set(t,n)}async getCurrentBlockHeight(){const t=new Date;if(t.getTime()-this.lastFetchTimestamp.getTime()>this.REQUEST_THROTTLE_INTERVAL){this.lastFetchTimestamp=t;const r=await this._getCurrentBlockHeight();this.currentBlockHeight=r,this.resolvers.forEach(n=>n(r)),this.resolvers=[]}return this.currentBlockHeight?this.currentBlockHeight:new Promise(r=>this.resolvers.push(r))}async _getCurrentBlockHeight(){const{result:t}=await this.sendAsyncPromise(Object.assign(Object.assign({},st),{method:"eth_blockNumber",params:[]}));return(0,ge.intNumberFromHexString)((0,ge.ensureHexString)(t))}async getBlockHashByNumber(t){const r=await this.sendAsyncPromise(Object.assign(Object.assign({},st),{method:"eth_getBlockByNumber",params:[(0,ge.hexStringFromIntNumber)(t),!1]}));return r.result&&typeof r.result.hash=="string"?(0,ge.ensureHexString)(r.result.hash):null}}Lt.FilterPolyfill=qf;function Kc(e){return{fromBlock:na(e.fromBlock),toBlock:na(e.toBlock),addresses:e.address===void 0?null:Array.isArray(e.address)?e.address:[e.address],topics:e.topics||[]}}Lt.filterFromParam=Kc;function ra(e){const t={fromBlock:sa(e.fromBlock),toBlock:sa(e.toBlock),topics:e.topics};return e.addresses!==null&&(t.address=e.addresses),t}function na(e){if(e===void 0||e==="latest"||e==="pending")return"latest";if(e==="earliest")return(0,wt.IntNumber)(0);if((0,ge.isHexString)(e))return(0,ge.intNumberFromHexString)(e);throw new Error(`Invalid block option: ${String(e)}`)}function sa(e){return e==="latest"?e:(0,ge.hexStringFromIntNumber)(e)}function Dr(){return Object.assign(Object.assign({},st),{error:{code:-32e3,message:"filter not found"}})}function Fr(){return Object.assign(Object.assign({},st),{result:[]})}var In={},Xc={},An={},Di=Jf;function Jf(e){e=e||{};var t=e.max||Number.MAX_SAFE_INTEGER,r=typeof e.start<"u"?e.start:Math.floor(Math.random()*t);return function(){return r=r%t,r++}}const ia=(e,t)=>function(){const r=t.promiseModule,n=new Array(arguments.length);for(let s=0;s<arguments.length;s++)n[s]=arguments[s];return new r((s,i)=>{t.errorFirst?n.push(function(o,a){if(t.multiArgs){const c=new Array(arguments.length-1);for(let l=1;l<arguments.length;l++)c[l-1]=arguments[l];o?(c.unshift(o),i(c)):s(c)}else o?i(o):s(a)}):n.push(function(o){if(t.multiArgs){const a=new Array(arguments.length-1);for(let c=0;c<arguments.length;c++)a[c]=arguments[c];s(a)}else s(o)}),e.apply(this,n)})};var Gf=(e,t)=>{t=Object.assign({exclude:[/.+(Sync|Stream)$/],errorFirst:!0,promiseModule:Promise},t);const r=s=>{const i=o=>typeof o=="string"?s===o:o.test(s);return t.include?t.include.some(i):!t.exclude.some(i)};let n;typeof e=="function"?n=function(){return t.excludeMain?e.apply(this,arguments):ia(e,t).apply(this,arguments)}:n=Object.create(Object.getPrototypeOf(e));for(const s in e){const i=e[s];n[s]=typeof i=="function"&&r(s)?ia(i,t):i}return n},yr={},wr={};Object.defineProperty(wr,"__esModule",{value:!0});const Zf=Ua;function oa(e,t,r){try{Reflect.apply(e,t,r)}catch(n){setTimeout(()=>{throw n})}}function Qf(e){const t=e.length,r=new Array(t);for(let n=0;n<t;n+=1)r[n]=e[n];return r}let Kf=class extends Zf.EventEmitter{emit(t,...r){let n=t==="error";const s=this._events;if(s!==void 0)n=n&&s.error===void 0;else if(!n)return!1;if(n){let o;if(r.length>0&&([o]=r),o instanceof Error)throw o;const a=new Error(`Unhandled error.${o?` (${o.message})`:""}`);throw a.context=o,a}const i=s[t];if(i===void 0)return!1;if(typeof i=="function")oa(i,this,r);else{const o=i.length,a=Qf(i);for(let c=0;c<o;c+=1)oa(a[c],this,r)}return!0}};wr.default=Kf;var Xf=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(yr,"__esModule",{value:!0});yr.BaseBlockTracker=void 0;const Yf=Xf(wr),e0=1e3,t0=(e,t)=>e+t,aa=["sync","latest"];class r0 extends Yf.default{constructor(t){super(),this._blockResetDuration=t.blockResetDuration||20*e0,this._usePastBlocks=t.usePastBlocks||!1,this._currentBlock=null,this._isRunning=!1,this._onNewListener=this._onNewListener.bind(this),this._onRemoveListener=this._onRemoveListener.bind(this),this._resetCurrentBlock=this._resetCurrentBlock.bind(this),this._setupInternalEvents()}async destroy(){this._cancelBlockResetTimeout(),await this._maybeEnd(),super.removeAllListeners()}isRunning(){return this._isRunning}getCurrentBlock(){return this._currentBlock}async getLatestBlock(){return this._currentBlock?this._currentBlock:await new Promise(r=>this.once("latest",r))}removeAllListeners(t){return t?super.removeAllListeners(t):super.removeAllListeners(),this._setupInternalEvents(),this._onRemoveListener(),this}_setupInternalEvents(){this.removeListener("newListener",this._onNewListener),this.removeListener("removeListener",this._onRemoveListener),this.on("newListener",this._onNewListener),this.on("removeListener",this._onRemoveListener)}_onNewListener(t){aa.includes(t)&&this._maybeStart()}_onRemoveListener(){this._getBlockTrackerEventCount()>0||this._maybeEnd()}async _maybeStart(){this._isRunning||(this._isRunning=!0,this._cancelBlockResetTimeout(),await this._start(),this.emit("_started"))}async _maybeEnd(){this._isRunning&&(this._isRunning=!1,this._setupBlockResetTimeout(),await this._end(),this.emit("_ended"))}_getBlockTrackerEventCount(){return aa.map(t=>this.listenerCount(t)).reduce(t0)}_shouldUseNewBlock(t){const r=this._currentBlock;if(!r)return!0;const n=ca(t),s=ca(r);return this._usePastBlocks&&n<s||n>s}_newPotentialLatest(t){this._shouldUseNewBlock(t)&&this._setCurrentBlock(t)}_setCurrentBlock(t){const r=this._currentBlock;this._currentBlock=t,this.emit("latest",t),this.emit("sync",{oldBlock:r,newBlock:t})}_setupBlockResetTimeout(){this._cancelBlockResetTimeout(),this._blockResetTimeout=setTimeout(this._resetCurrentBlock,this._blockResetDuration),this._blockResetTimeout.unref&&this._blockResetTimeout.unref()}_cancelBlockResetTimeout(){this._blockResetTimeout&&clearTimeout(this._blockResetTimeout)}_resetCurrentBlock(){this._currentBlock=null}}yr.BaseBlockTracker=r0;function ca(e){return Number.parseInt(e,16)}var Yc={},el={},he={};class tl extends TypeError{constructor(t,r){let n;const{message:s,explanation:i,...o}=t,{path:a}=t,c=a.length===0?s:`At path: ${a.join(".")} -- ${s}`;super(i??c),i!=null&&(this.cause=c),Object.assign(this,o),this.name=this.constructor.name,this.failures=()=>n??(n=[t,...r()])}}function n0(e){return Re(e)&&typeof e[Symbol.iterator]=="function"}function Re(e){return typeof e=="object"&&e!=null}function la(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function oe(e){return typeof e=="symbol"?e.toString():typeof e=="string"?JSON.stringify(e):`${e}`}function s0(e){const{done:t,value:r}=e.next();return t?void 0:r}function i0(e,t,r,n){if(e===!0)return;e===!1?e={}:typeof e=="string"&&(e={message:e});const{path:s,branch:i}=t,{type:o}=r,{refinement:a,message:c=`Expected a value of type \`${o}\`${a?` with refinement \`${a}\``:""}, but received: \`${oe(n)}\``}=e;return{value:n,type:o,refinement:a,key:s[s.length-1],path:s,branch:i,...e,message:c}}function*pi(e,t,r,n){n0(e)||(e=[e]);for(const s of e){const i=i0(s,t,r,n);i&&(yield i)}}function*Fi(e,t,r={}){const{path:n=[],branch:s=[e],coerce:i=!1,mask:o=!1}=r,a={path:n,branch:s};if(i&&(e=t.coercer(e,a),o&&t.type!=="type"&&Re(t.schema)&&Re(e)&&!Array.isArray(e)))for(const l in e)t.schema[l]===void 0&&delete e[l];let c="valid";for(const l of t.validator(e,a))l.explanation=r.message,c="not_valid",yield[l,void 0];for(let[l,u,d]of t.entries(e,a)){const h=Fi(u,d,{path:l===void 0?n:[...n,l],branch:l===void 0?s:[...s,u],coerce:i,mask:o,message:r.message});for(const f of h)f[0]?(c=f[0].refinement!=null?"not_refined":"not_valid",yield[f[0],void 0]):i&&(u=f[1],l===void 0?e=u:e instanceof Map?e.set(l,u):e instanceof Set?e.add(u):Re(e)&&(u!==void 0||l in e)&&(e[l]=u))}if(c!=="not_valid")for(const l of t.refiner(e,a))l.explanation=r.message,c="not_refined",yield[l,void 0];c==="valid"&&(yield[void 0,e])}class re{constructor(t){const{type:r,schema:n,validator:s,refiner:i,coercer:o=c=>c,entries:a=function*(){}}=t;this.type=r,this.schema=n,this.entries=a,this.coercer=o,s?this.validator=(c,l)=>{const u=s(c,l);return pi(u,l,this,c)}:this.validator=()=>[],i?this.refiner=(c,l)=>{const u=i(c,l);return pi(u,l,this,c)}:this.refiner=()=>[]}assert(t,r){return rl(t,this,r)}create(t,r){return nl(t,this,r)}is(t){return ji(t,this)}mask(t,r){return sl(t,this,r)}validate(t,r={}){return Ht(t,this,r)}}function rl(e,t,r){const n=Ht(e,t,{message:r});if(n[0])throw n[0]}function nl(e,t,r){const n=Ht(e,t,{coerce:!0,message:r});if(n[0])throw n[0];return n[1]}function sl(e,t,r){const n=Ht(e,t,{coerce:!0,mask:!0,message:r});if(n[0])throw n[0];return n[1]}function ji(e,t){return!Ht(e,t)[0]}function Ht(e,t,r={}){const n=Fi(e,t,r),s=s0(n);return s[0]?[new tl(s[0],function*(){for(const o of n)o[0]&&(yield o[0])}),void 0]:[void 0,s[1]]}function o0(...e){const t=e[0].type==="type",r=e.map(s=>s.schema),n=Object.assign({},...r);return t?Er(n):vr(n)}function me(e,t){return new re({type:e,schema:null,validator:t})}function a0(e,t){return new re({...e,refiner:(r,n)=>r===void 0||e.refiner(r,n),validator(r,n){return r===void 0?!0:(t(r,n),e.validator(r,n))}})}function c0(e){return new re({type:"dynamic",schema:null,*entries(t,r){yield*e(t,r).entries(t,r)},validator(t,r){return e(t,r).validator(t,r)},coercer(t,r){return e(t,r).coercer(t,r)},refiner(t,r){return e(t,r).refiner(t,r)}})}function l0(e){let t;return new re({type:"lazy",schema:null,*entries(r,n){t??(t=e()),yield*t.entries(r,n)},validator(r,n){return t??(t=e()),t.validator(r,n)},coercer(r,n){return t??(t=e()),t.coercer(r,n)},refiner(r,n){return t??(t=e()),t.refiner(r,n)}})}function u0(e,t){const{schema:r}=e,n={...r};for(const s of t)delete n[s];switch(e.type){case"type":return Er(n);default:return vr(n)}}function d0(e){const t=e instanceof re,r=t?{...e.schema}:{...e};for(const n in r)r[n]=il(r[n]);return t&&e.type==="type"?Er(r):vr(r)}function h0(e,t){const{schema:r}=e,n={};for(const s of t)n[s]=r[s];switch(e.type){case"type":return Er(n);default:return vr(n)}}function f0(e,t){return console.warn("superstruct@0.11 - The `struct` helper has been renamed to `define`."),me(e,t)}function g0(){return me("any",()=>!0)}function p0(e){return new re({type:"array",schema:e,*entries(t){if(e&&Array.isArray(t))for(const[r,n]of t.entries())yield[r,n,e]},coercer(t){return Array.isArray(t)?t.slice():t},validator(t){return Array.isArray(t)||`Expected an array value, but received: ${oe(t)}`}})}function _0(){return me("bigint",e=>typeof e=="bigint")}function m0(){return me("boolean",e=>typeof e=="boolean")}function b0(){return me("date",e=>e instanceof Date&&!isNaN(e.getTime())||`Expected a valid \`Date\` object, but received: ${oe(e)}`)}function y0(e){const t={},r=e.map(n=>oe(n)).join();for(const n of e)t[n]=n;return new re({type:"enums",schema:t,validator(n){return e.includes(n)||`Expected one of \`${r}\`, but received: ${oe(n)}`}})}function w0(){return me("func",e=>typeof e=="function"||`Expected a function, but received: ${oe(e)}`)}function v0(e){return me("instance",t=>t instanceof e||`Expected a \`${e.name}\` instance, but received: ${oe(t)}`)}function E0(){return me("integer",e=>typeof e=="number"&&!isNaN(e)&&Number.isInteger(e)||`Expected an integer, but received: ${oe(e)}`)}function S0(e){return new re({type:"intersection",schema:null,*entries(t,r){for(const n of e)yield*n.entries(t,r)},*validator(t,r){for(const n of e)yield*n.validator(t,r)},*refiner(t,r){for(const n of e)yield*n.refiner(t,r)}})}function k0(e){const t=oe(e),r=typeof e;return new re({type:"literal",schema:r==="string"||r==="number"||r==="boolean"?e:null,validator(n){return n===e||`Expected the literal \`${t}\`, but received: ${oe(n)}`}})}function C0(e,t){return new re({type:"map",schema:null,*entries(r){if(e&&t&&r instanceof Map)for(const[n,s]of r.entries())yield[n,n,e],yield[n,s,t]},coercer(r){return r instanceof Map?new Map(r):r},validator(r){return r instanceof Map||`Expected a \`Map\` object, but received: ${oe(r)}`}})}function $i(){return me("never",()=>!1)}function R0(e){return new re({...e,validator:(t,r)=>t===null||e.validator(t,r),refiner:(t,r)=>t===null||e.refiner(t,r)})}function I0(){return me("number",e=>typeof e=="number"&&!isNaN(e)||`Expected a number, but received: ${oe(e)}`)}function vr(e){const t=e?Object.keys(e):[],r=$i();return new re({type:"object",schema:e||null,*entries(n){if(e&&Re(n)){const s=new Set(Object.keys(n));for(const i of t)s.delete(i),yield[i,n[i],e[i]];for(const i of s)yield[i,n[i],r]}},validator(n){return Re(n)||`Expected an object, but received: ${oe(n)}`},coercer(n){return Re(n)?{...n}:n}})}function il(e){return new re({...e,validator:(t,r)=>t===void 0||e.validator(t,r),refiner:(t,r)=>t===void 0||e.refiner(t,r)})}function A0(e,t){return new re({type:"record",schema:null,*entries(r){if(Re(r))for(const n in r){const s=r[n];yield[n,n,e],yield[n,s,t]}},validator(r){return Re(r)||`Expected an object, but received: ${oe(r)}`}})}function x0(){return me("regexp",e=>e instanceof RegExp)}function N0(e){return new re({type:"set",schema:null,*entries(t){if(e&&t instanceof Set)for(const r of t)yield[r,r,e]},coercer(t){return t instanceof Set?new Set(t):t},validator(t){return t instanceof Set||`Expected a \`Set\` object, but received: ${oe(t)}`}})}function ol(){return me("string",e=>typeof e=="string"||`Expected a string, but received: ${oe(e)}`)}function L0(e){const t=$i();return new re({type:"tuple",schema:null,*entries(r){if(Array.isArray(r)){const n=Math.max(e.length,r.length);for(let s=0;s<n;s++)yield[s,r[s],e[s]||t]}},validator(r){return Array.isArray(r)||`Expected an array, but received: ${oe(r)}`}})}function Er(e){const t=Object.keys(e);return new re({type:"type",schema:e,*entries(r){if(Re(r))for(const n of t)yield[n,r[n],e[n]]},validator(r){return Re(r)||`Expected an object, but received: ${oe(r)}`},coercer(r){return Re(r)?{...r}:r}})}function M0(e){const t=e.map(r=>r.type).join(" | ");return new re({type:"union",schema:null,coercer(r){for(const n of e){const[s,i]=n.validate(r,{coerce:!0});if(!s)return i}return r},validator(r,n){const s=[];for(const i of e){const[...o]=Fi(r,i,n),[a]=o;if(a[0])for(const[c]of o)c&&s.push(c);else return[]}return[`Expected the value to satisfy a union of \`${t}\`, but received: ${oe(r)}`,...s]}})}function al(){return me("unknown",()=>!0)}function Hi(e,t,r){return new re({...e,coercer:(n,s)=>ji(n,t)?e.coercer(r(n,s),s):e.coercer(n,s)})}function T0(e,t,r={}){return Hi(e,al(),n=>{const s=typeof t=="function"?t():t;if(n===void 0)return s;if(!r.strict&&la(n)&&la(s)){const i={...n};let o=!1;for(const a in s)i[a]===void 0&&(i[a]=s[a],o=!0);if(o)return i}return n})}function P0(e){return Hi(e,ol(),t=>t.trim())}function O0(e){return ft(e,"empty",t=>{const r=cl(t);return r===0||`Expected an empty ${e.type} but received one with a size of \`${r}\``})}function cl(e){return e instanceof Map||e instanceof Set?e.size:e.length}function B0(e,t,r={}){const{exclusive:n}=r;return ft(e,"max",s=>n?s<t:s<=t||`Expected a ${e.type} less than ${n?"":"or equal to "}${t} but received \`${s}\``)}function D0(e,t,r={}){const{exclusive:n}=r;return ft(e,"min",s=>n?s>t:s>=t||`Expected a ${e.type} greater than ${n?"":"or equal to "}${t} but received \`${s}\``)}function F0(e){return ft(e,"nonempty",t=>cl(t)>0||`Expected a nonempty ${e.type} but received an empty one`)}function j0(e,t){return ft(e,"pattern",r=>t.test(r)||`Expected a ${e.type} matching \`/${t.source}/\` but received "${r}"`)}function $0(e,t,r=t){const n=`Expected a ${e.type}`,s=t===r?`of \`${t}\``:`between \`${t}\` and \`${r}\``;return ft(e,"size",i=>{if(typeof i=="number"||i instanceof Date)return t<=i&&i<=r||`${n} ${s} but received \`${i}\``;if(i instanceof Map||i instanceof Set){const{size:o}=i;return t<=o&&o<=r||`${n} with a size ${s} but received one with a size of \`${o}\``}else{const{length:o}=i;return t<=o&&o<=r||`${n} with a length ${s} but received one with a length of \`${o}\``}})}function ft(e,t,r){return new re({...e,*refiner(n,s){yield*e.refiner(n,s);const i=r(n,s),o=pi(i,s,e,n);for(const a of o)yield{...a,refinement:t}}})}const H0=Object.freeze(Object.defineProperty({__proto__:null,Struct:re,StructError:tl,any:g0,array:p0,assert:rl,assign:o0,bigint:_0,boolean:m0,coerce:Hi,create:nl,date:b0,defaulted:T0,define:me,deprecated:a0,dynamic:c0,empty:O0,enums:y0,func:w0,instance:v0,integer:E0,intersection:S0,is:ji,lazy:l0,literal:k0,map:C0,mask:sl,max:B0,min:D0,never:$i,nonempty:F0,nullable:R0,number:I0,object:vr,omit:u0,optional:il,partial:d0,pattern:j0,pick:h0,record:A0,refine:ft,regexp:x0,set:N0,size:$0,string:ol,struct:f0,trimmed:P0,tuple:L0,type:Er,union:M0,unknown:al,validate:Ht},Symbol.toStringTag,{value:"Module"})),gt=tr(H0);Object.defineProperty(he,"__esModule",{value:!0});he.assertExhaustive=he.assertStruct=he.assert=he.AssertionError=void 0;const U0=gt;function V0(e){return typeof e=="object"&&e!==null&&"message"in e}function W0(e){var t,r;return typeof((r=(t=e==null?void 0:e.prototype)===null||t===void 0?void 0:t.constructor)===null||r===void 0?void 0:r.name)=="string"}function z0(e){const t=V0(e)?e.message:String(e);return t.endsWith(".")?t.slice(0,-1):t}function ll(e,t){return W0(e)?new e({message:t}):e({message:t})}class Ui extends Error{constructor(t){super(t.message),this.code="ERR_ASSERTION"}}he.AssertionError=Ui;function q0(e,t="Assertion failed.",r=Ui){if(!e)throw t instanceof Error?t:ll(r,t)}he.assert=q0;function J0(e,t,r="Assertion failed",n=Ui){try{(0,U0.assert)(e,t)}catch(s){throw ll(n,`${r}: ${z0(s)}.`)}}he.assertStruct=J0;function G0(e){throw new Error("Invalid branch reached. Should be detected during compilation.")}he.assertExhaustive=G0;var Sr={};Object.defineProperty(Sr,"__esModule",{value:!0});Sr.base64=void 0;const Z0=gt,Q0=he,K0=(e,t={})=>{var r,n;const s=(r=t.paddingRequired)!==null&&r!==void 0?r:!1,i=(n=t.characterSet)!==null&&n!==void 0?n:"base64";let o;i==="base64"?o=String.raw`[A-Za-z0-9+\/]`:((0,Q0.assert)(i==="base64url"),o=String.raw`[-_A-Za-z0-9]`);let a;return s?a=new RegExp(`^(?:${o}{4})*(?:${o}{3}=|${o}{2}==)?$`,"u"):a=new RegExp(`^(?:${o}{4})*(?:${o}{2,3}|${o}{3}=|${o}{2}==)?$`,"u"),(0,Z0.pattern)(e,a)};Sr.base64=K0;var $={},kr={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.remove0x=e.add0x=e.assertIsStrictHexString=e.assertIsHexString=e.isStrictHexString=e.isHexString=e.StrictHexStruct=e.HexStruct=void 0;const t=gt,r=he;e.HexStruct=(0,t.pattern)((0,t.string)(),/^(?:0x)?[0-9a-f]+$/iu),e.StrictHexStruct=(0,t.pattern)((0,t.string)(),/^0x[0-9a-f]+$/iu);function n(l){return(0,t.is)(l,e.HexStruct)}e.isHexString=n;function s(l){return(0,t.is)(l,e.StrictHexStruct)}e.isStrictHexString=s;function i(l){(0,r.assert)(n(l),"Value must be a hexadecimal string.")}e.assertIsHexString=i;function o(l){(0,r.assert)(s(l),'Value must be a hexadecimal string, starting with "0x".')}e.assertIsStrictHexString=o;function a(l){return l.startsWith("0x")?l:l.startsWith("0X")?`0x${l.substring(2)}`:`0x${l}`}e.add0x=a;function c(l){return l.startsWith("0x")||l.startsWith("0X")?l.substring(2):l}e.remove0x=c})(kr);Object.defineProperty($,"__esModule",{value:!0});$.createDataView=$.concatBytes=$.valueToBytes=$.stringToBytes=$.numberToBytes=$.signedBigIntToBytes=$.bigIntToBytes=$.hexToBytes=$.bytesToString=$.bytesToNumber=$.bytesToSignedBigInt=$.bytesToBigInt=$.bytesToHex=$.assertIsBytes=$.isBytes=void 0;const we=he,_i=kr,ua=48,da=58,ha=87;function X0(){const e=[];return()=>{if(e.length===0)for(let t=0;t<256;t++)e.push(t.toString(16).padStart(2,"0"));return e}}const Y0=X0();function Vi(e){return e instanceof Uint8Array}$.isBytes=Vi;function Ut(e){(0,we.assert)(Vi(e),"Value must be a Uint8Array.")}$.assertIsBytes=Ut;function ul(e){if(Ut(e),e.length===0)return"0x";const t=Y0(),r=new Array(e.length);for(let n=0;n<e.length;n++)r[n]=t[e[n]];return(0,_i.add0x)(r.join(""))}$.bytesToHex=ul;function dl(e){Ut(e);const t=ul(e);return BigInt(t)}$.bytesToBigInt=dl;function e1(e){Ut(e);let t=BigInt(0);for(const r of e)t=(t<<BigInt(8))+BigInt(r);return BigInt.asIntN(e.length*8,t)}$.bytesToSignedBigInt=e1;function t1(e){Ut(e);const t=dl(e);return(0,we.assert)(t<=BigInt(Number.MAX_SAFE_INTEGER),"Number is not a safe integer. Use `bytesToBigInt` instead."),Number(t)}$.bytesToNumber=t1;function r1(e){return Ut(e),new TextDecoder().decode(e)}$.bytesToString=r1;function xn(e){var t;if(((t=e==null?void 0:e.toLowerCase)===null||t===void 0?void 0:t.call(e))==="0x")return new Uint8Array;(0,_i.assertIsHexString)(e);const r=(0,_i.remove0x)(e).toLowerCase(),n=r.length%2===0?r:`0${r}`,s=new Uint8Array(n.length/2);for(let i=0;i<s.length;i++){const o=n.charCodeAt(i*2),a=n.charCodeAt(i*2+1),c=o-(o<da?ua:ha),l=a-(a<da?ua:ha);s[i]=c*16+l}return s}$.hexToBytes=xn;function hl(e){(0,we.assert)(typeof e=="bigint","Value must be a bigint."),(0,we.assert)(e>=BigInt(0),"Value must be a non-negative bigint.");const t=e.toString(16);return xn(t)}$.bigIntToBytes=hl;function n1(e,t){(0,we.assert)(t>0);const r=e>>BigInt(31);return!((~e&r)+(e&~r)>>BigInt(t*8+-1))}function s1(e,t){(0,we.assert)(typeof e=="bigint","Value must be a bigint."),(0,we.assert)(typeof t=="number","Byte length must be a number."),(0,we.assert)(t>0,"Byte length must be greater than 0."),(0,we.assert)(n1(e,t),"Byte length is too small to represent the given value.");let r=e;const n=new Uint8Array(t);for(let s=0;s<n.length;s++)n[s]=Number(BigInt.asUintN(8,r)),r>>=BigInt(8);return n.reverse()}$.signedBigIntToBytes=s1;function fl(e){(0,we.assert)(typeof e=="number","Value must be a number."),(0,we.assert)(e>=0,"Value must be a non-negative number."),(0,we.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToBytes` instead.");const t=e.toString(16);return xn(t)}$.numberToBytes=fl;function gl(e){return(0,we.assert)(typeof e=="string","Value must be a string."),new TextEncoder().encode(e)}$.stringToBytes=gl;function pl(e){if(typeof e=="bigint")return hl(e);if(typeof e=="number")return fl(e);if(typeof e=="string")return e.startsWith("0x")?xn(e):gl(e);if(Vi(e))return e;throw new TypeError(`Unsupported value type: "${typeof e}".`)}$.valueToBytes=pl;function i1(e){const t=new Array(e.length);let r=0;for(let s=0;s<e.length;s++){const i=pl(e[s]);t[s]=i,r+=i.length}const n=new Uint8Array(r);for(let s=0,i=0;s<t.length;s++)n.set(t[s],i),i+=t[s].length;return n}$.concatBytes=i1;function o1(e){if(typeof O<"u"&&e instanceof O){const t=e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength);return new DataView(t)}return new DataView(e.buffer,e.byteOffset,e.byteLength)}$.createDataView=o1;var Nn={};Object.defineProperty(Nn,"__esModule",{value:!0});Nn.ChecksumStruct=void 0;const fa=gt,a1=Sr;Nn.ChecksumStruct=(0,fa.size)((0,a1.base64)((0,fa.string)(),{paddingRequired:!0}),44,44);var $e={};Object.defineProperty($e,"__esModule",{value:!0});$e.createHex=$e.createBytes=$e.createBigInt=$e.createNumber=void 0;const Y=gt,c1=he,_l=$,Ln=kr,ml=(0,Y.union)([(0,Y.number)(),(0,Y.bigint)(),(0,Y.string)(),Ln.StrictHexStruct]),l1=(0,Y.coerce)((0,Y.number)(),ml,Number),u1=(0,Y.coerce)((0,Y.bigint)(),ml,BigInt);(0,Y.union)([Ln.StrictHexStruct,(0,Y.instance)(Uint8Array)]);const d1=(0,Y.coerce)((0,Y.instance)(Uint8Array),(0,Y.union)([Ln.StrictHexStruct]),_l.hexToBytes),h1=(0,Y.coerce)(Ln.StrictHexStruct,(0,Y.instance)(Uint8Array),_l.bytesToHex);function f1(e){try{const t=(0,Y.create)(e,l1);return(0,c1.assert)(Number.isFinite(t),`Expected a number-like value, got "${e}".`),t}catch(t){throw t instanceof Y.StructError?new Error(`Expected a number-like value, got "${e}".`):t}}$e.createNumber=f1;function g1(e){try{return(0,Y.create)(e,u1)}catch(t){throw t instanceof Y.StructError?new Error(`Expected a number-like value, got "${String(t.value)}".`):t}}$e.createBigInt=g1;function p1(e){if(typeof e=="string"&&e.toLowerCase()==="0x")return new Uint8Array;try{return(0,Y.create)(e,d1)}catch(t){throw t instanceof Y.StructError?new Error(`Expected a bytes-like value, got "${String(t.value)}".`):t}}$e.createBytes=p1;function _1(e){if(e instanceof Uint8Array&&e.length===0||typeof e=="string"&&e.toLowerCase()==="0x")return"0x";try{return(0,Y.create)(e,h1)}catch(t){throw t instanceof Y.StructError?new Error(`Expected a bytes-like value, got "${String(t.value)}".`):t}}$e.createHex=_1;var Mt={},bl=x&&x.__classPrivateFieldSet||function(e,t,r,n,s){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!s:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?s.call(e,r):s?s.value=r:t.set(e,r),r},pe=x&&x.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)},Ae,Te;Object.defineProperty(Mt,"__esModule",{value:!0});Mt.FrozenSet=Mt.FrozenMap=void 0;class Wi{constructor(t){Ae.set(this,void 0),bl(this,Ae,new Map(t),"f"),Object.freeze(this)}get size(){return pe(this,Ae,"f").size}[(Ae=new WeakMap,Symbol.iterator)](){return pe(this,Ae,"f")[Symbol.iterator]()}entries(){return pe(this,Ae,"f").entries()}forEach(t,r){return pe(this,Ae,"f").forEach((n,s,i)=>t.call(r,n,s,this))}get(t){return pe(this,Ae,"f").get(t)}has(t){return pe(this,Ae,"f").has(t)}keys(){return pe(this,Ae,"f").keys()}values(){return pe(this,Ae,"f").values()}toString(){return`FrozenMap(${this.size}) {${this.size>0?` ${[...this.entries()].map(([t,r])=>`${String(t)} => ${String(r)}`).join(", ")} `:""}}`}}Mt.FrozenMap=Wi;class zi{constructor(t){Te.set(this,void 0),bl(this,Te,new Set(t),"f"),Object.freeze(this)}get size(){return pe(this,Te,"f").size}[(Te=new WeakMap,Symbol.iterator)](){return pe(this,Te,"f")[Symbol.iterator]()}entries(){return pe(this,Te,"f").entries()}forEach(t,r){return pe(this,Te,"f").forEach((n,s,i)=>t.call(r,n,s,this))}has(t){return pe(this,Te,"f").has(t)}keys(){return pe(this,Te,"f").keys()}values(){return pe(this,Te,"f").values()}toString(){return`FrozenSet(${this.size}) {${this.size>0?` ${[...this.values()].map(t=>String(t)).join(", ")} `:""}}`}}Mt.FrozenSet=zi;Object.freeze(Wi);Object.freeze(Wi.prototype);Object.freeze(zi);Object.freeze(zi.prototype);var yl={};Object.defineProperty(yl,"__esModule",{value:!0});var wl={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getJsonRpcIdValidator=e.assertIsJsonRpcError=e.isJsonRpcError=e.assertIsJsonRpcFailure=e.isJsonRpcFailure=e.assertIsJsonRpcSuccess=e.isJsonRpcSuccess=e.assertIsJsonRpcResponse=e.isJsonRpcResponse=e.assertIsPendingJsonRpcResponse=e.isPendingJsonRpcResponse=e.JsonRpcResponseStruct=e.JsonRpcFailureStruct=e.JsonRpcSuccessStruct=e.PendingJsonRpcResponseStruct=e.assertIsJsonRpcRequest=e.isJsonRpcRequest=e.assertIsJsonRpcNotification=e.isJsonRpcNotification=e.JsonRpcNotificationStruct=e.JsonRpcRequestStruct=e.JsonRpcParamsStruct=e.JsonRpcErrorStruct=e.JsonRpcIdStruct=e.JsonRpcVersionStruct=e.jsonrpc2=e.getJsonSize=e.isValidJson=e.JsonStruct=e.UnsafeJsonStruct=void 0;const t=gt,r=he,n=()=>(0,t.define)("finite number",v=>(0,t.is)(v,(0,t.number)())&&Number.isFinite(v));e.UnsafeJsonStruct=(0,t.union)([(0,t.literal)(null),(0,t.boolean)(),n(),(0,t.string)(),(0,t.array)((0,t.lazy)(()=>e.UnsafeJsonStruct)),(0,t.record)((0,t.string)(),(0,t.lazy)(()=>e.UnsafeJsonStruct))]),e.JsonStruct=(0,t.define)("Json",(v,N)=>{function V(Z,ee){const W=[...ee.validator(Z,N)];return W.length>0?W:!0}try{const Z=V(v,e.UnsafeJsonStruct);return Z!==!0?Z:V(JSON.parse(JSON.stringify(v)),e.UnsafeJsonStruct)}catch(Z){return Z instanceof RangeError?"Circular reference detected":!1}});function s(v){return(0,t.is)(v,e.JsonStruct)}e.isValidJson=s;function i(v){(0,r.assertStruct)(v,e.JsonStruct,"Invalid JSON value");const N=JSON.stringify(v);return new TextEncoder().encode(N).byteLength}e.getJsonSize=i,e.jsonrpc2="2.0",e.JsonRpcVersionStruct=(0,t.literal)(e.jsonrpc2),e.JsonRpcIdStruct=(0,t.nullable)((0,t.union)([(0,t.number)(),(0,t.string)()])),e.JsonRpcErrorStruct=(0,t.object)({code:(0,t.integer)(),message:(0,t.string)(),data:(0,t.optional)(e.JsonStruct),stack:(0,t.optional)((0,t.string)())}),e.JsonRpcParamsStruct=(0,t.optional)((0,t.union)([(0,t.record)((0,t.string)(),e.JsonStruct),(0,t.array)(e.JsonStruct)])),e.JsonRpcRequestStruct=(0,t.object)({id:e.JsonRpcIdStruct,jsonrpc:e.JsonRpcVersionStruct,method:(0,t.string)(),params:e.JsonRpcParamsStruct}),e.JsonRpcNotificationStruct=(0,t.omit)(e.JsonRpcRequestStruct,["id"]);function o(v){return(0,t.is)(v,e.JsonRpcNotificationStruct)}e.isJsonRpcNotification=o;function a(v,N){(0,r.assertStruct)(v,e.JsonRpcNotificationStruct,"Invalid JSON-RPC notification",N)}e.assertIsJsonRpcNotification=a;function c(v){return(0,t.is)(v,e.JsonRpcRequestStruct)}e.isJsonRpcRequest=c;function l(v,N){(0,r.assertStruct)(v,e.JsonRpcRequestStruct,"Invalid JSON-RPC request",N)}e.assertIsJsonRpcRequest=l,e.PendingJsonRpcResponseStruct=(0,t.object)({id:e.JsonRpcIdStruct,jsonrpc:e.JsonRpcVersionStruct,result:(0,t.optional)((0,t.unknown)()),error:(0,t.optional)(e.JsonRpcErrorStruct)}),e.JsonRpcSuccessStruct=(0,t.object)({id:e.JsonRpcIdStruct,jsonrpc:e.JsonRpcVersionStruct,result:e.JsonStruct}),e.JsonRpcFailureStruct=(0,t.object)({id:e.JsonRpcIdStruct,jsonrpc:e.JsonRpcVersionStruct,error:e.JsonRpcErrorStruct}),e.JsonRpcResponseStruct=(0,t.union)([e.JsonRpcSuccessStruct,e.JsonRpcFailureStruct]);function u(v){return(0,t.is)(v,e.PendingJsonRpcResponseStruct)}e.isPendingJsonRpcResponse=u;function d(v,N){(0,r.assertStruct)(v,e.PendingJsonRpcResponseStruct,"Invalid pending JSON-RPC response",N)}e.assertIsPendingJsonRpcResponse=d;function h(v){return(0,t.is)(v,e.JsonRpcResponseStruct)}e.isJsonRpcResponse=h;function f(v,N){(0,r.assertStruct)(v,e.JsonRpcResponseStruct,"Invalid JSON-RPC response",N)}e.assertIsJsonRpcResponse=f;function b(v){return(0,t.is)(v,e.JsonRpcSuccessStruct)}e.isJsonRpcSuccess=b;function g(v,N){(0,r.assertStruct)(v,e.JsonRpcSuccessStruct,"Invalid JSON-RPC success response",N)}e.assertIsJsonRpcSuccess=g;function E(v){return(0,t.is)(v,e.JsonRpcFailureStruct)}e.isJsonRpcFailure=E;function y(v,N){(0,r.assertStruct)(v,e.JsonRpcFailureStruct,"Invalid JSON-RPC failure response",N)}e.assertIsJsonRpcFailure=y;function p(v){return(0,t.is)(v,e.JsonRpcErrorStruct)}e.isJsonRpcError=p;function _(v,N){(0,r.assertStruct)(v,e.JsonRpcErrorStruct,"Invalid JSON-RPC error",N)}e.assertIsJsonRpcError=_;function A(v){const{permitEmptyString:N,permitFractions:V,permitNull:Z}=Object.assign({permitEmptyString:!0,permitFractions:!1,permitNull:!0},v);return z=>!!(typeof z=="number"&&(V||Number.isInteger(z))||typeof z=="string"&&(N||z.length>0)||Z&&z===null)}e.getJsonRpcIdValidator=A})(wl);var vl={};Object.defineProperty(vl,"__esModule",{value:!0});var Tt={},m1=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Tt,"__esModule",{value:!0});Tt.createModuleLogger=Tt.createProjectLogger=void 0;const b1=m1(eu()),y1=(0,b1.default)("metamask");function w1(e){return y1.extend(e)}Tt.createProjectLogger=w1;function v1(e,t){return e.extend(t)}Tt.createModuleLogger=v1;var El={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.calculateNumberSize=e.calculateStringSize=e.isASCII=e.isPlainObject=e.ESCAPE_CHARACTERS_REGEXP=e.JsonSize=e.hasProperty=e.isObject=e.isNullOrUndefined=e.isNonEmptyArray=void 0;function t(l){return Array.isArray(l)&&l.length>0}e.isNonEmptyArray=t;function r(l){return l==null}e.isNullOrUndefined=r;function n(l){return!!l&&typeof l=="object"&&!Array.isArray(l)}e.isObject=n;const s=(l,u)=>Object.hasOwnProperty.call(l,u);e.hasProperty=s,function(l){l[l.Null=4]="Null",l[l.Comma=1]="Comma",l[l.Wrapper=1]="Wrapper",l[l.True=4]="True",l[l.False=5]="False",l[l.Quote=1]="Quote",l[l.Colon=1]="Colon",l[l.Date=24]="Date"}(e.JsonSize||(e.JsonSize={})),e.ESCAPE_CHARACTERS_REGEXP=/"|\\|\n|\r|\t/gu;function i(l){if(typeof l!="object"||l===null)return!1;try{let u=l;for(;Object.getPrototypeOf(u)!==null;)u=Object.getPrototypeOf(u);return Object.getPrototypeOf(l)===u}catch{return!1}}e.isPlainObject=i;function o(l){return l.charCodeAt(0)<=127}e.isASCII=o;function a(l){var u;return l.split("").reduce((h,f)=>o(f)?h+1:h+2,0)+((u=l.match(e.ESCAPE_CHARACTERS_REGEXP))!==null&&u!==void 0?u:[]).length}e.calculateStringSize=a;function c(l){return l.toString().length}e.calculateNumberSize=c})(El);var He={};Object.defineProperty(He,"__esModule",{value:!0});He.hexToBigInt=He.hexToNumber=He.bigIntToHex=He.numberToHex=void 0;const kt=he,Yt=kr,E1=e=>((0,kt.assert)(typeof e=="number","Value must be a number."),(0,kt.assert)(e>=0,"Value must be a non-negative number."),(0,kt.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToHex` instead."),(0,Yt.add0x)(e.toString(16)));He.numberToHex=E1;const S1=e=>((0,kt.assert)(typeof e=="bigint","Value must be a bigint."),(0,kt.assert)(e>=0,"Value must be a non-negative bigint."),(0,Yt.add0x)(e.toString(16)));He.bigIntToHex=S1;const k1=e=>{(0,Yt.assertIsHexString)(e);const t=parseInt(e,16);return(0,kt.assert)(Number.isSafeInteger(t),"Value is not a safe integer. Use `hexToBigInt` instead."),t};He.hexToNumber=k1;const C1=e=>((0,Yt.assertIsHexString)(e),BigInt((0,Yt.add0x)(e)));He.hexToBigInt=C1;var Sl={};Object.defineProperty(Sl,"__esModule",{value:!0});var kl={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.timeSince=e.inMilliseconds=e.Duration=void 0,function(i){i[i.Millisecond=1]="Millisecond",i[i.Second=1e3]="Second",i[i.Minute=6e4]="Minute",i[i.Hour=36e5]="Hour",i[i.Day=864e5]="Day",i[i.Week=6048e5]="Week",i[i.Year=31536e6]="Year"}(e.Duration||(e.Duration={}));const t=i=>Number.isInteger(i)&&i>=0,r=(i,o)=>{if(!t(i))throw new Error(`"${o}" must be a non-negative integer. Received: "${i}".`)};function n(i,o){return r(i,"count"),i*o}e.inMilliseconds=n;function s(i){return r(i,"timestamp"),Date.now()-i}e.timeSince=s})(kl);var Cl={};Object.defineProperty(Cl,"__esModule",{value:!0});var Rl={},mi={exports:{}};const R1="2.0.0",Il=256,I1=Number.MAX_SAFE_INTEGER||9007199254740991,A1=16,x1=Il-6,N1=["major","premajor","minor","preminor","patch","prepatch","prerelease"];var Mn={MAX_LENGTH:Il,MAX_SAFE_COMPONENT_LENGTH:A1,MAX_SAFE_BUILD_LENGTH:x1,MAX_SAFE_INTEGER:I1,RELEASE_TYPES:N1,SEMVER_SPEC_VERSION:R1,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},Ks={};const L1=typeof tu=="object"&&Ks&&Ks.NODE_DEBUG&&/\bsemver\b/i.test(Ks.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};var Tn=L1;(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:r,MAX_SAFE_BUILD_LENGTH:n,MAX_LENGTH:s}=Mn,i=Tn;t=e.exports={};const o=t.re=[],a=t.safeRe=[],c=t.src=[],l=t.safeSrc=[],u=t.t={};let d=0;const h="[a-zA-Z0-9-]",f=[["\\s",1],["\\d",s],[h,n]],b=E=>{for(const[y,p]of f)E=E.split(`${y}*`).join(`${y}{0,${p}}`).split(`${y}+`).join(`${y}{1,${p}}`);return E},g=(E,y,p)=>{const _=b(y),A=d++;i(E,A,y),u[E]=A,c[A]=y,l[A]=_,o[A]=new RegExp(y,p?"g":void 0),a[A]=new RegExp(_,p?"g":void 0)};g("NUMERICIDENTIFIER","0|[1-9]\\d*"),g("NUMERICIDENTIFIERLOOSE","\\d+"),g("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${h}*`),g("MAINVERSION",`(${c[u.NUMERICIDENTIFIER]})\\.(${c[u.NUMERICIDENTIFIER]})\\.(${c[u.NUMERICIDENTIFIER]})`),g("MAINVERSIONLOOSE",`(${c[u.NUMERICIDENTIFIERLOOSE]})\\.(${c[u.NUMERICIDENTIFIERLOOSE]})\\.(${c[u.NUMERICIDENTIFIERLOOSE]})`),g("PRERELEASEIDENTIFIER",`(?:${c[u.NONNUMERICIDENTIFIER]}|${c[u.NUMERICIDENTIFIER]})`),g("PRERELEASEIDENTIFIERLOOSE",`(?:${c[u.NONNUMERICIDENTIFIER]}|${c[u.NUMERICIDENTIFIERLOOSE]})`),g("PRERELEASE",`(?:-(${c[u.PRERELEASEIDENTIFIER]}(?:\\.${c[u.PRERELEASEIDENTIFIER]})*))`),g("PRERELEASELOOSE",`(?:-?(${c[u.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${c[u.PRERELEASEIDENTIFIERLOOSE]})*))`),g("BUILDIDENTIFIER",`${h}+`),g("BUILD",`(?:\\+(${c[u.BUILDIDENTIFIER]}(?:\\.${c[u.BUILDIDENTIFIER]})*))`),g("FULLPLAIN",`v?${c[u.MAINVERSION]}${c[u.PRERELEASE]}?${c[u.BUILD]}?`),g("FULL",`^${c[u.FULLPLAIN]}$`),g("LOOSEPLAIN",`[v=\\s]*${c[u.MAINVERSIONLOOSE]}${c[u.PRERELEASELOOSE]}?${c[u.BUILD]}?`),g("LOOSE",`^${c[u.LOOSEPLAIN]}$`),g("GTLT","((?:<|>)?=?)"),g("XRANGEIDENTIFIERLOOSE",`${c[u.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),g("XRANGEIDENTIFIER",`${c[u.NUMERICIDENTIFIER]}|x|X|\\*`),g("XRANGEPLAIN",`[v=\\s]*(${c[u.XRANGEIDENTIFIER]})(?:\\.(${c[u.XRANGEIDENTIFIER]})(?:\\.(${c[u.XRANGEIDENTIFIER]})(?:${c[u.PRERELEASE]})?${c[u.BUILD]}?)?)?`),g("XRANGEPLAINLOOSE",`[v=\\s]*(${c[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[u.XRANGEIDENTIFIERLOOSE]})(?:${c[u.PRERELEASELOOSE]})?${c[u.BUILD]}?)?)?`),g("XRANGE",`^${c[u.GTLT]}\\s*${c[u.XRANGEPLAIN]}$`),g("XRANGELOOSE",`^${c[u.GTLT]}\\s*${c[u.XRANGEPLAINLOOSE]}$`),g("COERCEPLAIN",`(^|[^\\d])(\\d{1,${r}})(?:\\.(\\d{1,${r}}))?(?:\\.(\\d{1,${r}}))?`),g("COERCE",`${c[u.COERCEPLAIN]}(?:$|[^\\d])`),g("COERCEFULL",c[u.COERCEPLAIN]+`(?:${c[u.PRERELEASE]})?(?:${c[u.BUILD]})?(?:$|[^\\d])`),g("COERCERTL",c[u.COERCE],!0),g("COERCERTLFULL",c[u.COERCEFULL],!0),g("LONETILDE","(?:~>?)"),g("TILDETRIM",`(\\s*)${c[u.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",g("TILDE",`^${c[u.LONETILDE]}${c[u.XRANGEPLAIN]}$`),g("TILDELOOSE",`^${c[u.LONETILDE]}${c[u.XRANGEPLAINLOOSE]}$`),g("LONECARET","(?:\\^)"),g("CARETTRIM",`(\\s*)${c[u.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",g("CARET",`^${c[u.LONECARET]}${c[u.XRANGEPLAIN]}$`),g("CARETLOOSE",`^${c[u.LONECARET]}${c[u.XRANGEPLAINLOOSE]}$`),g("COMPARATORLOOSE",`^${c[u.GTLT]}\\s*(${c[u.LOOSEPLAIN]})$|^$`),g("COMPARATOR",`^${c[u.GTLT]}\\s*(${c[u.FULLPLAIN]})$|^$`),g("COMPARATORTRIM",`(\\s*)${c[u.GTLT]}\\s*(${c[u.LOOSEPLAIN]}|${c[u.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",g("HYPHENRANGE",`^\\s*(${c[u.XRANGEPLAIN]})\\s+-\\s+(${c[u.XRANGEPLAIN]})\\s*$`),g("HYPHENRANGELOOSE",`^\\s*(${c[u.XRANGEPLAINLOOSE]})\\s+-\\s+(${c[u.XRANGEPLAINLOOSE]})\\s*$`),g("STAR","(<|>)?=?\\s*\\*"),g("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),g("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(mi,mi.exports);var Cr=mi.exports;const M1=Object.freeze({loose:!0}),T1=Object.freeze({}),P1=e=>e?typeof e!="object"?M1:e:T1;var qi=P1;const ga=/^[0-9]+$/,Al=(e,t)=>{if(typeof e=="number"&&typeof t=="number")return e===t?0:e<t?-1:1;const r=ga.test(e),n=ga.test(t);return r&&n&&(e=+e,t=+t),e===t?0:r&&!n?-1:n&&!r?1:e<t?-1:1},O1=(e,t)=>Al(t,e);var xl={compareIdentifiers:Al,rcompareIdentifiers:O1};const jr=Tn,{MAX_LENGTH:pa,MAX_SAFE_INTEGER:$r}=Mn,{safeRe:Hr,t:Ur}=Cr,B1=qi,{compareIdentifiers:Xs}=xl;let D1=class Pe{constructor(t,r){if(r=B1(r),t instanceof Pe){if(t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof t}".`);if(t.length>pa)throw new TypeError(`version is longer than ${pa} characters`);jr("SemVer",t,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;const n=t.trim().match(r.loose?Hr[Ur.LOOSE]:Hr[Ur.FULL]);if(!n)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>$r||this.major<0)throw new TypeError("Invalid major version");if(this.minor>$r||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>$r||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(s=>{if(/^[0-9]+$/.test(s)){const i=+s;if(i>=0&&i<$r)return i}return s}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(t){if(jr("SemVer.compare",this.version,this.options,t),!(t instanceof Pe)){if(typeof t=="string"&&t===this.version)return 0;t=new Pe(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof Pe||(t=new Pe(t,this.options)),this.major<t.major?-1:this.major>t.major?1:this.minor<t.minor?-1:this.minor>t.minor?1:this.patch<t.patch?-1:this.patch>t.patch?1:0}comparePre(t){if(t instanceof Pe||(t=new Pe(t,this.options)),this.prerelease.length&&!t.prerelease.length)return-1;if(!this.prerelease.length&&t.prerelease.length)return 1;if(!this.prerelease.length&&!t.prerelease.length)return 0;let r=0;do{const n=this.prerelease[r],s=t.prerelease[r];if(jr("prerelease compare",r,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return Xs(n,s)}while(++r)}compareBuild(t){t instanceof Pe||(t=new Pe(t,this.options));let r=0;do{const n=this.build[r],s=t.build[r];if(jr("build compare",r,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return Xs(n,s)}while(++r)}inc(t,r,n){if(t.startsWith("pre")){if(!r&&n===!1)throw new Error("invalid increment argument: identifier is empty");if(r){const s=`-${r}`.match(this.options.loose?Hr[Ur.PRERELEASELOOSE]:Hr[Ur.PRERELEASE]);if(!s||s[1]!==r)throw new Error(`invalid identifier: ${r}`)}}switch(t){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,n);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,n);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,n),this.inc("pre",r,n);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r,n),this.inc("pre",r,n);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const s=Number(n)?1:0;if(this.prerelease.length===0)this.prerelease=[s];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);if(i===-1){if(r===this.prerelease.join(".")&&n===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(s)}}if(r){let i=[r,s];n===!1&&(i=[r]),Xs(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=i):this.prerelease=i}break}default:throw new Error(`invalid increment argument: ${t}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};var Rr=D1;const _a=Rr,F1=(e,t,r=!1)=>{if(e instanceof _a)return e;try{return new _a(e,t)}catch(n){if(!r)return null;throw n}};var j1=F1;const $1=j1,H1=(e,t)=>{const r=$1(e,t);return r?r.version:null};var U1=H1;const ma=Rr,V1=(e,t,r)=>new ma(e,r).compare(new ma(t,r));var Vt=V1;const W1=Vt,z1=(e,t,r)=>W1(e,t,r)>0;var Ji=z1;const q1=Vt,J1=(e,t,r)=>q1(e,t,r)<0;var Nl=J1;const G1=Vt,Z1=(e,t,r)=>G1(e,t,r)===0;var Q1=Z1;const K1=Vt,X1=(e,t,r)=>K1(e,t,r)!==0;var Y1=X1;const eg=Vt,tg=(e,t,r)=>eg(e,t,r)>=0;var Ll=tg;const rg=Vt,ng=(e,t,r)=>rg(e,t,r)<=0;var Ml=ng;const sg=Q1,ig=Y1,og=Ji,ag=Ll,cg=Nl,lg=Ml,ug=(e,t,r,n)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e===r;case"!==":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e!==r;case"":case"=":case"==":return sg(e,r,n);case"!=":return ig(e,r,n);case">":return og(e,r,n);case">=":return ag(e,r,n);case"<":return cg(e,r,n);case"<=":return lg(e,r,n);default:throw new TypeError(`Invalid operator: ${t}`)}};var dg=ug;const{safeRe:q_,t:J_}=Cr;class hg{constructor(){this.max=1e3,this.map=new Map}get(t){const r=this.map.get(t);if(r!==void 0)return this.map.delete(t),this.map.set(t,r),r}delete(t){return this.map.delete(t)}set(t,r){if(!this.delete(t)&&r!==void 0){if(this.map.size>=this.max){const s=this.map.keys().next().value;this.delete(s)}this.map.set(t,r)}return this}}var fg=hg,Ys,ba;function Le(){if(ba)return Ys;ba=1;const e=/\s+/g;class t{constructor(m,R){if(R=s(R),m instanceof t)return m.loose===!!R.loose&&m.includePrerelease===!!R.includePrerelease?m:new t(m.raw,R);if(m instanceof i)return this.raw=m.value,this.set=[[m]],this.formatted=void 0,this;if(this.options=R,this.loose=!!R.loose,this.includePrerelease=!!R.includePrerelease,this.raw=m.trim().replace(e," "),this.set=this.raw.split("||").map(C=>this.parseRange(C.trim())).filter(C=>C.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const C=this.set[0];if(this.set=this.set.filter(I=>!g(I[0])),this.set.length===0)this.set=[C];else if(this.set.length>1){for(const I of this.set)if(I.length===1&&E(I[0])){this.set=[I];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let m=0;m<this.set.length;m++){m>0&&(this.formatted+="||");const R=this.set[m];for(let C=0;C<R.length;C++)C>0&&(this.formatted+=" "),this.formatted+=R[C].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(m){const C=((this.options.includePrerelease&&f)|(this.options.loose&&b))+":"+m,I=n.get(C);if(I)return I;const k=this.options.loose,L=k?c[l.HYPHENRANGELOOSE]:c[l.HYPHENRANGE];m=m.replace(L,H(this.options.includePrerelease)),o("hyphen replace",m),m=m.replace(c[l.COMPARATORTRIM],u),o("comparator trim",m),m=m.replace(c[l.TILDETRIM],d),o("tilde trim",m),m=m.replace(c[l.CARETTRIM],h),o("caret trim",m);let D=m.split(" ").map(J=>p(J,this.options)).join(" ").split(/\s+/).map(J=>W(J,this.options));k&&(D=D.filter(J=>(o("loose invalid filter",J,this.options),!!J.match(c[l.COMPARATORLOOSE])))),o("range list",D);const T=new Map,U=D.map(J=>new i(J,this.options));for(const J of U){if(g(J))return[J];T.set(J.value,J)}T.size>1&&T.has("")&&T.delete("");const ae=[...T.values()];return n.set(C,ae),ae}intersects(m,R){if(!(m instanceof t))throw new TypeError("a Range is required");return this.set.some(C=>y(C,R)&&m.set.some(I=>y(I,R)&&C.every(k=>I.every(L=>k.intersects(L,R)))))}test(m){if(!m)return!1;if(typeof m=="string")try{m=new a(m,this.options)}catch{return!1}for(let R=0;R<this.set.length;R++)if(se(this.set[R],m,this.options))return!0;return!1}}Ys=t;const r=fg,n=new r,s=qi,i=Pn(),o=Tn,a=Rr,{safeRe:c,t:l,comparatorTrimReplace:u,tildeTrimReplace:d,caretTrimReplace:h}=Cr,{FLAG_INCLUDE_PRERELEASE:f,FLAG_LOOSE:b}=Mn,g=w=>w.value==="<0.0.0-0",E=w=>w.value==="",y=(w,m)=>{let R=!0;const C=w.slice();let I=C.pop();for(;R&&C.length;)R=C.every(k=>I.intersects(k,m)),I=C.pop();return R},p=(w,m)=>(w=w.replace(c[l.BUILD],""),o("comp",w,m),w=N(w,m),o("caret",w),w=A(w,m),o("tildes",w),w=Z(w,m),o("xrange",w),w=z(w,m),o("stars",w),w),_=w=>!w||w.toLowerCase()==="x"||w==="*",A=(w,m)=>w.trim().split(/\s+/).map(R=>v(R,m)).join(" "),v=(w,m)=>{const R=m.loose?c[l.TILDELOOSE]:c[l.TILDE];return w.replace(R,(C,I,k,L,D)=>{o("tilde",w,C,I,k,L,D);let T;return _(I)?T="":_(k)?T=`>=${I}.0.0 <${+I+1}.0.0-0`:_(L)?T=`>=${I}.${k}.0 <${I}.${+k+1}.0-0`:D?(o("replaceTilde pr",D),T=`>=${I}.${k}.${L}-${D} <${I}.${+k+1}.0-0`):T=`>=${I}.${k}.${L} <${I}.${+k+1}.0-0`,o("tilde return",T),T})},N=(w,m)=>w.trim().split(/\s+/).map(R=>V(R,m)).join(" "),V=(w,m)=>{o("caret",w,m);const R=m.loose?c[l.CARETLOOSE]:c[l.CARET],C=m.includePrerelease?"-0":"";return w.replace(R,(I,k,L,D,T)=>{o("caret",w,I,k,L,D,T);let U;return _(k)?U="":_(L)?U=`>=${k}.0.0${C} <${+k+1}.0.0-0`:_(D)?k==="0"?U=`>=${k}.${L}.0${C} <${k}.${+L+1}.0-0`:U=`>=${k}.${L}.0${C} <${+k+1}.0.0-0`:T?(o("replaceCaret pr",T),k==="0"?L==="0"?U=`>=${k}.${L}.${D}-${T} <${k}.${L}.${+D+1}-0`:U=`>=${k}.${L}.${D}-${T} <${k}.${+L+1}.0-0`:U=`>=${k}.${L}.${D}-${T} <${+k+1}.0.0-0`):(o("no pr"),k==="0"?L==="0"?U=`>=${k}.${L}.${D}${C} <${k}.${L}.${+D+1}-0`:U=`>=${k}.${L}.${D}${C} <${k}.${+L+1}.0-0`:U=`>=${k}.${L}.${D} <${+k+1}.0.0-0`),o("caret return",U),U})},Z=(w,m)=>(o("replaceXRanges",w,m),w.split(/\s+/).map(R=>ee(R,m)).join(" ")),ee=(w,m)=>{w=w.trim();const R=m.loose?c[l.XRANGELOOSE]:c[l.XRANGE];return w.replace(R,(C,I,k,L,D,T)=>{o("xRange",w,C,I,k,L,D,T);const U=_(k),ae=U||_(L),J=ae||_(D),te=J;return I==="="&&te&&(I=""),T=m.includePrerelease?"-0":"",U?I===">"||I==="<"?C="<0.0.0-0":C="*":I&&te?(ae&&(L=0),D=0,I===">"?(I=">=",ae?(k=+k+1,L=0,D=0):(L=+L+1,D=0)):I==="<="&&(I="<",ae?k=+k+1:L=+L+1),I==="<"&&(T="-0"),C=`${I+k}.${L}.${D}${T}`):ae?C=`>=${k}.0.0${T} <${+k+1}.0.0-0`:J&&(C=`>=${k}.${L}.0${T} <${k}.${+L+1}.0-0`),o("xRange return",C),C})},z=(w,m)=>(o("replaceStars",w,m),w.trim().replace(c[l.STAR],"")),W=(w,m)=>(o("replaceGTE0",w,m),w.trim().replace(c[m.includePrerelease?l.GTE0PRE:l.GTE0],"")),H=w=>(m,R,C,I,k,L,D,T,U,ae,J,te)=>(_(C)?R="":_(I)?R=`>=${C}.0.0${w?"-0":""}`:_(k)?R=`>=${C}.${I}.0${w?"-0":""}`:L?R=`>=${R}`:R=`>=${R}${w?"-0":""}`,_(U)?T="":_(ae)?T=`<${+U+1}.0.0-0`:_(J)?T=`<${U}.${+ae+1}.0-0`:te?T=`<=${U}.${ae}.${J}-${te}`:w?T=`<${U}.${ae}.${+J+1}-0`:T=`<=${T}`,`${R} ${T}`.trim()),se=(w,m,R)=>{for(let C=0;C<w.length;C++)if(!w[C].test(m))return!1;if(m.prerelease.length&&!R.includePrerelease){for(let C=0;C<w.length;C++)if(o(w[C].semver),w[C].semver!==i.ANY&&w[C].semver.prerelease.length>0){const I=w[C].semver;if(I.major===m.major&&I.minor===m.minor&&I.patch===m.patch)return!0}return!1}return!0};return Ys}var ei,ya;function Pn(){if(ya)return ei;ya=1;const e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(u,d){if(d=r(d),u instanceof t){if(u.loose===!!d.loose)return u;u=u.value}u=u.trim().split(/\s+/).join(" "),o("comparator",u,d),this.options=d,this.loose=!!d.loose,this.parse(u),this.semver===e?this.value="":this.value=this.operator+this.semver.version,o("comp",this)}parse(u){const d=this.options.loose?n[s.COMPARATORLOOSE]:n[s.COMPARATOR],h=u.match(d);if(!h)throw new TypeError(`Invalid comparator: ${u}`);this.operator=h[1]!==void 0?h[1]:"",this.operator==="="&&(this.operator=""),h[2]?this.semver=new a(h[2],this.options.loose):this.semver=e}toString(){return this.value}test(u){if(o("Comparator.test",u,this.options.loose),this.semver===e||u===e)return!0;if(typeof u=="string")try{u=new a(u,this.options)}catch{return!1}return i(u,this.operator,this.semver,this.options)}intersects(u,d){if(!(u instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new c(u.value,d).test(this.value):u.operator===""?u.value===""?!0:new c(this.value,d).test(u.semver):(d=r(d),d.includePrerelease&&(this.value==="<0.0.0-0"||u.value==="<0.0.0-0")||!d.includePrerelease&&(this.value.startsWith("<0.0.0")||u.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&u.operator.startsWith(">")||this.operator.startsWith("<")&&u.operator.startsWith("<")||this.semver.version===u.semver.version&&this.operator.includes("=")&&u.operator.includes("=")||i(this.semver,"<",u.semver,d)&&this.operator.startsWith(">")&&u.operator.startsWith("<")||i(this.semver,">",u.semver,d)&&this.operator.startsWith("<")&&u.operator.startsWith(">")))}}ei=t;const r=qi,{safeRe:n,t:s}=Cr,i=dg,o=Tn,a=Rr,c=Le();return ei}const gg=Le(),pg=(e,t,r)=>{try{t=new gg(t,r)}catch{return!1}return t.test(e)};var Tl=pg;Le();Le();Le();Le();const _g=Le(),mg=(e,t)=>{try{return new _g(e,t).range||"*"}catch{return null}};var bg=mg;const yg=Rr,Pl=Pn(),{ANY:wg}=Pl,vg=Le(),Eg=Tl,wa=Ji,va=Nl,Sg=Ml,kg=Ll,Cg=(e,t,r,n)=>{e=new yg(e,n),t=new vg(t,n);let s,i,o,a,c;switch(r){case">":s=wa,i=Sg,o=va,a=">",c=">=";break;case"<":s=va,i=kg,o=wa,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Eg(e,t,n))return!1;for(let l=0;l<t.set.length;++l){const u=t.set[l];let d=null,h=null;if(u.forEach(f=>{f.semver===wg&&(f=new Pl(">=0.0.0")),d=d||f,h=h||f,s(f.semver,d.semver,n)?d=f:o(f.semver,h.semver,n)&&(h=f)}),d.operator===a||d.operator===c||(!h.operator||h.operator===a)&&i(e,h.semver))return!1;if(h.operator===c&&o(e,h.semver))return!1}return!0};var Rg=Cg;const Ig=Rg,Ag=(e,t,r)=>Ig(e,t,">",r);var xg=Ag;Le();Le();const Gi=Pn(),{ANY:G_}=Gi;new Gi(">=0.0.0-0");new Gi(">=0.0.0");const ti=Cr,Ea=Mn,Sa=xl,Ng=U1,Lg=Ji;Pn();Le();const Mg=Tl,Tg=bg,Pg=xg;var Og={valid:Ng,gt:Lg,satisfies:Mg,validRange:Tg,gtr:Pg,re:ti.re,src:ti.src,tokens:ti.t,SEMVER_SPEC_VERSION:Ea.SEMVER_SPEC_VERSION,RELEASE_TYPES:Ea.RELEASE_TYPES,compareIdentifiers:Sa.compareIdentifiers,rcompareIdentifiers:Sa.rcompareIdentifiers};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.satisfiesVersionRange=e.gtRange=e.gtVersion=e.assertIsSemVerRange=e.assertIsSemVerVersion=e.isValidSemVerRange=e.isValidSemVerVersion=e.VersionRangeStruct=e.VersionStruct=void 0;const t=Og,r=gt,n=he;e.VersionStruct=(0,r.refine)((0,r.string)(),"Version",d=>(0,t.valid)(d)===null?`Expected SemVer version, got "${d}"`:!0),e.VersionRangeStruct=(0,r.refine)((0,r.string)(),"Version range",d=>(0,t.validRange)(d)===null?`Expected SemVer range, got "${d}"`:!0);function s(d){return(0,r.is)(d,e.VersionStruct)}e.isValidSemVerVersion=s;function i(d){return(0,r.is)(d,e.VersionRangeStruct)}e.isValidSemVerRange=i;function o(d){(0,n.assertStruct)(d,e.VersionStruct)}e.assertIsSemVerVersion=o;function a(d){(0,n.assertStruct)(d,e.VersionRangeStruct)}e.assertIsSemVerRange=a;function c(d,h){return(0,t.gt)(d,h)}e.gtVersion=c;function l(d,h){return(0,t.gtr)(d,h)}e.gtRange=l;function u(d,h){return(0,t.satisfies)(d,h,{includePrerelease:!0})}e.satisfiesVersionRange=u})(Rl);(function(e){var t=x&&x.__createBinding||(Object.create?function(n,s,i,o){o===void 0&&(o=i);var a=Object.getOwnPropertyDescriptor(s,i);(!a||("get"in a?!s.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return s[i]}}),Object.defineProperty(n,o,a)}:function(n,s,i,o){o===void 0&&(o=i),n[o]=s[i]}),r=x&&x.__exportStar||function(n,s){for(var i in n)i!=="default"&&!Object.prototype.hasOwnProperty.call(s,i)&&t(s,n,i)};Object.defineProperty(e,"__esModule",{value:!0}),r(he,e),r(Sr,e),r($,e),r(Nn,e),r($e,e),r(Mt,e),r(yl,e),r(kr,e),r(wl,e),r(vl,e),r(Tt,e),r(El,e),r(He,e),r(Sl,e),r(kl,e),r(Cl,e),r(Rl,e)})(el);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createModuleLogger=e.projectLogger=void 0;const t=el;Object.defineProperty(e,"createModuleLogger",{enumerable:!0,get:function(){return t.createModuleLogger}}),e.projectLogger=(0,t.createProjectLogger)("eth-block-tracker")})(Yc);var Ol=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(An,"__esModule",{value:!0});An.PollingBlockTracker=void 0;const Bg=Ol(Di),Dg=Ol(Gf),Fg=yr,ka=Yc,Ca=(0,ka.createModuleLogger)(ka.projectLogger,"polling-block-tracker"),jg=(0,Bg.default)(),$g=1e3;class Hg extends Fg.BaseBlockTracker{constructor(t={}){var r;if(!t.provider)throw new Error("PollingBlockTracker - no provider specified.");super(Object.assign(Object.assign({},t),{blockResetDuration:(r=t.blockResetDuration)!==null&&r!==void 0?r:t.pollingInterval})),this._provider=t.provider,this._pollingInterval=t.pollingInterval||20*$g,this._retryTimeout=t.retryTimeout||this._pollingInterval/10,this._keepEventLoopActive=t.keepEventLoopActive===void 0?!0:t.keepEventLoopActive,this._setSkipCacheFlag=t.setSkipCacheFlag||!1}async checkForLatestBlock(){return await this._updateLatestBlock(),await this.getLatestBlock()}async _start(){this._synchronize()}async _end(){}async _synchronize(){for(var t;this._isRunning;)try{await this._updateLatestBlock();const r=Ra(this._pollingInterval,!this._keepEventLoopActive);this.emit("_waitingForNextIteration"),await r}catch(r){const n=new Error(`PollingBlockTracker - encountered an error while attempting to update latest block:
3
3
  ${(t=r.stack)!==null&&t!==void 0?t:r}`);try{this.emit("error",n)}catch{console.error(n)}const s=Ra(this._retryTimeout,!this._keepEventLoopActive);this.emit("_waitingForNextIteration"),await s}}async _updateLatestBlock(){const t=await this._fetchLatestBlock();this._newPotentialLatest(t)}async _fetchLatestBlock(){const t={jsonrpc:"2.0",id:jg(),method:"eth_blockNumber",params:[]};this._setSkipCacheFlag&&(t.skipCache=!0),Ca("Making request",t);const r=await(0,Dg.default)(n=>this._provider.sendAsync(t,n))();if(Ca("Got response",r),r.error)throw new Error(`PollingBlockTracker - encountered error fetching block:
4
4
  ${r.error.message}`);return r.result}}An.PollingBlockTracker=Hg;function Ra(e,t){return new Promise(r=>{const n=setTimeout(r,e);n.unref&&t&&n.unref()})}var On={},Ug=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(On,"__esModule",{value:!0});On.SubscribeBlockTracker=void 0;const Vg=Ug(Di),Wg=yr,zg=(0,Vg.default)();class qg extends Wg.BaseBlockTracker{constructor(t={}){if(!t.provider)throw new Error("SubscribeBlockTracker - no provider specified.");super(t),this._provider=t.provider,this._subscriptionId=null}async checkForLatestBlock(){return await this.getLatestBlock()}async _start(){if(this._subscriptionId===void 0||this._subscriptionId===null)try{const t=await this._call("eth_blockNumber");this._subscriptionId=await this._call("eth_subscribe","newHeads"),this._provider.on("data",this._handleSubData.bind(this)),this._newPotentialLatest(t)}catch(t){this.emit("error",t)}}async _end(){if(this._subscriptionId!==null&&this._subscriptionId!==void 0)try{await this._call("eth_unsubscribe",this._subscriptionId),this._subscriptionId=null}catch(t){this.emit("error",t)}}_call(t,...r){return new Promise((n,s)=>{this._provider.sendAsync({id:zg(),method:t,params:r,jsonrpc:"2.0"},(i,o)=>{i?s(i):n(o.result)})})}_handleSubData(t,r){var n;r.method==="eth_subscription"&&((n=r.params)===null||n===void 0?void 0:n.subscription)===this._subscriptionId&&this._newPotentialLatest(r.params.result.number)}}On.SubscribeBlockTracker=qg;(function(e){var t=x&&x.__createBinding||(Object.create?function(n,s,i,o){o===void 0&&(o=i),Object.defineProperty(n,o,{enumerable:!0,get:function(){return s[i]}})}:function(n,s,i,o){o===void 0&&(o=i),n[o]=s[i]}),r=x&&x.__exportStar||function(n,s){for(var i in n)i!=="default"&&!Object.prototype.hasOwnProperty.call(s,i)&&t(s,n,i)};Object.defineProperty(e,"__esModule",{value:!0}),r(An,e),r(On,e)})(Xc);var Zi={},Bn={},Ir={};Object.defineProperty(Ir,"__esModule",{value:!0});Ir.getUniqueId=void 0;const Bl=4294967295;let ri=Math.floor(Math.random()*Bl);function Jg(){return ri=(ri+1)%Bl,ri}Ir.getUniqueId=Jg;Object.defineProperty(Bn,"__esModule",{value:!0});Bn.createIdRemapMiddleware=void 0;const Gg=Ir;function Zg(){return(e,t,r,n)=>{const s=e.id,i=Gg.getUniqueId();e.id=i,t.id=i,r(o=>{e.id=s,t.id=s,o()})}}Bn.createIdRemapMiddleware=Zg;var Dn={};Object.defineProperty(Dn,"__esModule",{value:!0});Dn.createAsyncMiddleware=void 0;function Qg(e){return async(t,r,n,s)=>{let i;const o=new Promise(u=>{i=u});let a=null,c=!1;const l=async()=>{c=!0,n(u=>{a=u,i()}),await o};try{await e(t,r,l),c?(await o,a(null)):s(null)}catch(u){a?a(u):s(u)}}}Dn.createAsyncMiddleware=Qg;var Fn={};Object.defineProperty(Fn,"__esModule",{value:!0});Fn.createScaffoldMiddleware=void 0;function Kg(e){return(t,r,n,s)=>{const i=e[t.method];return i===void 0?n():typeof i=="function"?i(t,r,n,s):(r.result=i,s())}}Fn.createScaffoldMiddleware=Kg;var Ar={},Qi={};Object.defineProperty(Qi,"__esModule",{value:!0});const Xg=Ua;function Ia(e,t,r){try{Reflect.apply(e,t,r)}catch(n){setTimeout(()=>{throw n})}}function Yg(e){const t=e.length,r=new Array(t);for(let n=0;n<t;n+=1)r[n]=e[n];return r}let ep=class extends Xg.EventEmitter{emit(t,...r){let n=t==="error";const s=this._events;if(s!==void 0)n=n&&s.error===void 0;else if(!n)return!1;if(n){let o;if(r.length>0&&([o]=r),o instanceof Error)throw o;const a=new Error(`Unhandled error.${o?` (${o.message})`:""}`);throw a.context=o,a}const i=s[t];if(i===void 0)return!1;if(typeof i=="function")Ia(i,this,r);else{const o=i.length,a=Yg(i);for(let c=0;c<o;c+=1)Ia(a[c],this,r)}return!0}};Qi.default=ep;var Dl={},Qe={},tp=er;er.default=er;er.stable=$l;er.stableStringify=$l;var Qr="[...]",Fl="[Circular]",lt=[],ot=[];function jl(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function er(e,t,r,n){typeof n>"u"&&(n=jl()),bi(e,"",0,[],void 0,0,n);var s;try{ot.length===0?s=JSON.stringify(e,t,r):s=JSON.stringify(e,Hl(t),r)}catch{return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;lt.length!==0;){var i=lt.pop();i.length===4?Object.defineProperty(i[0],i[1],i[3]):i[0][i[1]]=i[2]}}return s}function Ct(e,t,r,n){var s=Object.getOwnPropertyDescriptor(n,r);s.get!==void 0?s.configurable?(Object.defineProperty(n,r,{value:e}),lt.push([n,r,t,s])):ot.push([t,r,e]):(n[r]=e,lt.push([n,r,t]))}function bi(e,t,r,n,s,i,o){i+=1;var a;if(typeof e=="object"&&e!==null){for(a=0;a<n.length;a++)if(n[a]===e){Ct(Fl,e,t,s);return}if(typeof o.depthLimit<"u"&&i>o.depthLimit){Ct(Qr,e,t,s);return}if(typeof o.edgesLimit<"u"&&r+1>o.edgesLimit){Ct(Qr,e,t,s);return}if(n.push(e),Array.isArray(e))for(a=0;a<e.length;a++)bi(e[a],a,a,n,e,i,o);else{var c=Object.keys(e);for(a=0;a<c.length;a++){var l=c[a];bi(e[l],l,a,n,e,i,o)}}n.pop()}}function rp(e,t){return e<t?-1:e>t?1:0}function $l(e,t,r,n){typeof n>"u"&&(n=jl());var s=yi(e,"",0,[],void 0,0,n)||e,i;try{ot.length===0?i=JSON.stringify(s,t,r):i=JSON.stringify(s,Hl(t),r)}catch{return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;lt.length!==0;){var o=lt.pop();o.length===4?Object.defineProperty(o[0],o[1],o[3]):o[0][o[1]]=o[2]}}return i}function yi(e,t,r,n,s,i,o){i+=1;var a;if(typeof e=="object"&&e!==null){for(a=0;a<n.length;a++)if(n[a]===e){Ct(Fl,e,t,s);return}try{if(typeof e.toJSON=="function")return}catch{return}if(typeof o.depthLimit<"u"&&i>o.depthLimit){Ct(Qr,e,t,s);return}if(typeof o.edgesLimit<"u"&&r+1>o.edgesLimit){Ct(Qr,e,t,s);return}if(n.push(e),Array.isArray(e))for(a=0;a<e.length;a++)yi(e[a],a,a,n,e,i,o);else{var c={},l=Object.keys(e).sort(rp);for(a=0;a<l.length;a++){var u=l[a];yi(e[u],u,a,n,e,i,o),c[u]=e[u]}if(typeof s<"u")lt.push([s,t,e]),s[t]=c;else return c}n.pop()}}function Hl(e){return e=typeof e<"u"?e:function(t,r){return r},function(t,r){if(ot.length>0)for(var n=0;n<ot.length;n++){var s=ot[n];if(s[1]===t&&s[0]===r){r=s[2],ot.splice(n,1);break}}return e.call(this,t,r)}}Object.defineProperty(Qe,"__esModule",{value:!0});Qe.EthereumProviderError=Qe.EthereumRpcError=void 0;const np=tp;class Ul extends Error{constructor(t,r,n){if(!Number.isInteger(t))throw new Error('"code" must be an integer.');if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string.');super(r),this.code=t,n!==void 0&&(this.data=n)}serialize(){const t={code:this.code,message:this.message};return this.data!==void 0&&(t.data=this.data),this.stack&&(t.stack=this.stack),t}toString(){return np.default(this.serialize(),op,2)}}Qe.EthereumRpcError=Ul;class sp extends Ul{constructor(t,r,n){if(!ip(t))throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');super(t,r,n)}}Qe.EthereumProviderError=sp;function ip(e){return Number.isInteger(e)&&e>=1e3&&e<=4999}function op(e,t){if(t!=="[Circular]")return t}var Ki={},Ke={};Object.defineProperty(Ke,"__esModule",{value:!0});Ke.errorValues=Ke.errorCodes=void 0;Ke.errorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901}};Ke.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."}};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.serializeError=e.isValidCode=e.getMessageFromCode=e.JSON_RPC_SERVER_ERROR_MESSAGE=void 0;const t=Ke,r=Qe,n=t.errorCodes.rpc.internal,s="Unspecified error message. This is a bug, please report it.",i={code:n,message:o(n)};e.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.";function o(h,f=s){if(Number.isInteger(h)){const b=h.toString();if(d(t.errorValues,b))return t.errorValues[b].message;if(l(h))return e.JSON_RPC_SERVER_ERROR_MESSAGE}return f}e.getMessageFromCode=o;function a(h){if(!Number.isInteger(h))return!1;const f=h.toString();return!!(t.errorValues[f]||l(h))}e.isValidCode=a;function c(h,{fallbackError:f=i,shouldIncludeStack:b=!1}={}){var g,E;if(!f||!Number.isInteger(f.code)||typeof f.message!="string")throw new Error("Must provide fallback error with integer number code and string message.");if(h instanceof r.EthereumRpcError)return h.serialize();const y={};if(h&&typeof h=="object"&&!Array.isArray(h)&&d(h,"code")&&a(h.code)){const _=h;y.code=_.code,_.message&&typeof _.message=="string"?(y.message=_.message,d(_,"data")&&(y.data=_.data)):(y.message=o(y.code),y.data={originalError:u(h)})}else{y.code=f.code;const _=(g=h)===null||g===void 0?void 0:g.message;y.message=_&&typeof _=="string"?_:f.message,y.data={originalError:u(h)}}const p=(E=h)===null||E===void 0?void 0:E.stack;return b&&h&&p&&typeof p=="string"&&(y.stack=p),y}e.serializeError=c;function l(h){return h>=-32099&&h<=-32e3}function u(h){return h&&typeof h=="object"&&!Array.isArray(h)?Object.assign({},h):h}function d(h,f){return Object.prototype.hasOwnProperty.call(h,f)}})(Ki);var jn={};Object.defineProperty(jn,"__esModule",{value:!0});jn.ethErrors=void 0;const Xi=Qe,Vl=Ki,fe=Ke;jn.ethErrors={rpc:{parse:e=>Ee(fe.errorCodes.rpc.parse,e),invalidRequest:e=>Ee(fe.errorCodes.rpc.invalidRequest,e),invalidParams:e=>Ee(fe.errorCodes.rpc.invalidParams,e),methodNotFound:e=>Ee(fe.errorCodes.rpc.methodNotFound,e),internal:e=>Ee(fe.errorCodes.rpc.internal,e),server:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum RPC Server errors must provide single object argument.");const{code:t}=e;if(!Number.isInteger(t)||t>-32005||t<-32099)throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');return Ee(t,e)},invalidInput:e=>Ee(fe.errorCodes.rpc.invalidInput,e),resourceNotFound:e=>Ee(fe.errorCodes.rpc.resourceNotFound,e),resourceUnavailable:e=>Ee(fe.errorCodes.rpc.resourceUnavailable,e),transactionRejected:e=>Ee(fe.errorCodes.rpc.transactionRejected,e),methodNotSupported:e=>Ee(fe.errorCodes.rpc.methodNotSupported,e),limitExceeded:e=>Ee(fe.errorCodes.rpc.limitExceeded,e)},provider:{userRejectedRequest:e=>qt(fe.errorCodes.provider.userRejectedRequest,e),unauthorized:e=>qt(fe.errorCodes.provider.unauthorized,e),unsupportedMethod:e=>qt(fe.errorCodes.provider.unsupportedMethod,e),disconnected:e=>qt(fe.errorCodes.provider.disconnected,e),chainDisconnected:e=>qt(fe.errorCodes.provider.chainDisconnected,e),custom:e=>{if(!e||typeof e!="object"||Array.isArray(e))throw new Error("Ethereum Provider custom errors must provide single object argument.");const{code:t,message:r,data:n}=e;if(!r||typeof r!="string")throw new Error('"message" must be a nonempty string');return new Xi.EthereumProviderError(t,r,n)}}};function Ee(e,t){const[r,n]=Wl(t);return new Xi.EthereumRpcError(e,r||Vl.getMessageFromCode(e),n)}function qt(e,t){const[r,n]=Wl(t);return new Xi.EthereumProviderError(e,r||Vl.getMessageFromCode(e),n)}function Wl(e){if(e){if(typeof e=="string")return[e];if(typeof e=="object"&&!Array.isArray(e)){const{message:t,data:r}=e;if(t&&typeof t!="string")throw new Error("Must specify string message.");return[t||void 0,r]}}return[]}(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getMessageFromCode=e.serializeError=e.EthereumProviderError=e.EthereumRpcError=e.ethErrors=e.errorCodes=void 0;const t=Qe;Object.defineProperty(e,"EthereumRpcError",{enumerable:!0,get:function(){return t.EthereumRpcError}}),Object.defineProperty(e,"EthereumProviderError",{enumerable:!0,get:function(){return t.EthereumProviderError}});const r=Ki;Object.defineProperty(e,"serializeError",{enumerable:!0,get:function(){return r.serializeError}}),Object.defineProperty(e,"getMessageFromCode",{enumerable:!0,get:function(){return r.getMessageFromCode}});const n=jn;Object.defineProperty(e,"ethErrors",{enumerable:!0,get:function(){return n.ethErrors}});const s=Ke;Object.defineProperty(e,"errorCodes",{enumerable:!0,get:function(){return s.errorCodes}})})(Dl);var ap=x&&x.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ar,"__esModule",{value:!0});Ar.JsonRpcEngine=void 0;const cp=ap(Qi),Se=Dl;class Ue extends cp.default{constructor(){super(),this._middleware=[]}push(t){this._middleware.push(t)}handle(t,r){if(r&&typeof r!="function")throw new Error('"callback" must be a function if provided.');return Array.isArray(t)?r?this._handleBatch(t,r):this._handleBatch(t):r?this._handle(t,r):this._promiseHandle(t)}asMiddleware(){return async(t,r,n,s)=>{try{const[i,o,a]=await Ue._runAllMiddleware(t,r,this._middleware);return o?(await Ue._runReturnHandlers(a),s(i)):n(async c=>{try{await Ue._runReturnHandlers(a)}catch(l){return c(l)}return c()})}catch(i){return s(i)}}}async _handleBatch(t,r){try{const n=await Promise.all(t.map(this._promiseHandle.bind(this)));return r?r(null,n):n}catch(n){if(r)return r(n);throw n}}_promiseHandle(t){return new Promise(r=>{this._handle(t,(n,s)=>{r(s)})})}async _handle(t,r){if(!t||Array.isArray(t)||typeof t!="object"){const o=new Se.EthereumRpcError(Se.errorCodes.rpc.invalidRequest,`Requests must be plain objects. Received: ${typeof t}`,{request:t});return r(o,{id:void 0,jsonrpc:"2.0",error:o})}if(typeof t.method!="string"){const o=new Se.EthereumRpcError(Se.errorCodes.rpc.invalidRequest,`Must specify a string method. Received: ${typeof t.method}`,{request:t});return r(o,{id:t.id,jsonrpc:"2.0",error:o})}const n=Object.assign({},t),s={id:n.id,jsonrpc:n.jsonrpc};let i=null;try{await this._processRequest(n,s)}catch(o){i=o}return i&&(delete s.result,s.error||(s.error=Se.serializeError(i))),r(i,s)}async _processRequest(t,r){const[n,s,i]=await Ue._runAllMiddleware(t,r,this._middleware);if(Ue._checkForCompletion(t,r,s),await Ue._runReturnHandlers(i),n)throw n}static async _runAllMiddleware(t,r,n){const s=[];let i=null,o=!1;for(const a of n)if([i,o]=await Ue._runMiddleware(t,r,a,s),o)break;return[i,o,s.reverse()]}static _runMiddleware(t,r,n,s){return new Promise(i=>{const o=c=>{const l=c||r.error;l&&(r.error=Se.serializeError(l)),i([l,!0])},a=c=>{r.error?o(r.error):(c&&(typeof c!="function"&&o(new Se.EthereumRpcError(Se.errorCodes.rpc.internal,`JsonRpcEngine: "next" return handlers must be functions. Received "${typeof c}" for request: