@dev.sail.money/sailor 1.3.0-98 → 1.4.0-244

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 (233) hide show
  1. package/AGENTS.md +7 -7
  2. package/LICENSE +1 -1
  3. package/README.md +64 -472
  4. package/package.json +5 -6
  5. package/packages/cli/README.md +1 -1
  6. package/packages/cli/dist/index.cjs +1481 -463
  7. package/packages/cli/dist/server.cjs +16088 -17900
  8. package/packages/sdk/README.md +1 -1
  9. package/packages/sdk/dist/abis/ConfigurablePermission.d.ts +130 -0
  10. package/packages/sdk/dist/abis/ConfigurablePermission.d.ts.map +1 -0
  11. package/packages/sdk/dist/abis/ConfigurablePermission.js +79 -0
  12. package/packages/sdk/dist/abis/ConfigurablePermission.js.map +1 -0
  13. package/packages/sdk/dist/abis/SailKernel.d.ts +42 -0
  14. package/packages/sdk/dist/abis/SailKernel.d.ts.map +1 -1
  15. package/packages/sdk/dist/abis/SailKernel.js +34 -0
  16. package/packages/sdk/dist/abis/SailKernel.js.map +1 -1
  17. package/packages/sdk/dist/abis/index.d.ts +1 -0
  18. package/packages/sdk/dist/abis/index.d.ts.map +1 -1
  19. package/packages/sdk/dist/abis/index.js +1 -0
  20. package/packages/sdk/dist/abis/index.js.map +1 -1
  21. package/packages/sdk/dist/chains.d.ts +9 -7
  22. package/packages/sdk/dist/chains.d.ts.map +1 -1
  23. package/packages/sdk/dist/chains.js +103 -32
  24. package/packages/sdk/dist/chains.js.map +1 -1
  25. package/packages/sdk/dist/client.d.ts +1 -1
  26. package/packages/sdk/dist/client.d.ts.map +1 -1
  27. package/packages/sdk/dist/client.js +137 -16
  28. package/packages/sdk/dist/client.js.map +1 -1
  29. package/packages/sdk/dist/deployments.d.ts +6 -4
  30. package/packages/sdk/dist/deployments.d.ts.map +1 -1
  31. package/packages/sdk/dist/deployments.js +120 -118
  32. package/packages/sdk/dist/deployments.js.map +1 -1
  33. package/packages/sdk/dist/eip712.d.ts +84 -0
  34. package/packages/sdk/dist/eip712.d.ts.map +1 -1
  35. package/packages/sdk/dist/eip712.js +148 -0
  36. package/packages/sdk/dist/eip712.js.map +1 -1
  37. package/packages/sdk/dist/fees.d.ts +2 -1
  38. package/packages/sdk/dist/fees.d.ts.map +1 -1
  39. package/packages/sdk/dist/fees.js +2 -1
  40. package/packages/sdk/dist/fees.js.map +1 -1
  41. package/packages/sdk/dist/index.d.ts +4 -3
  42. package/packages/sdk/dist/index.d.ts.map +1 -1
  43. package/packages/sdk/dist/index.js +4 -3
  44. package/packages/sdk/dist/index.js.map +1 -1
  45. package/packages/sdk/dist/intelligence.d.ts +1 -1
  46. package/packages/sdk/dist/intelligence.js +1 -1
  47. package/packages/sdk/dist/safe.d.ts +49 -0
  48. package/packages/sdk/dist/safe.d.ts.map +1 -1
  49. package/packages/sdk/dist/safe.js +74 -0
  50. package/packages/sdk/dist/safe.js.map +1 -1
  51. package/packages/sdk/dist/types.d.ts +7 -0
  52. package/packages/sdk/dist/types.d.ts.map +1 -1
  53. package/packages/sdk/package.json +6 -2
  54. package/packages/ui/dist/assets/{add-BX5reKtK.js → add-sHg4oAtj.js} +2 -2
  55. package/packages/ui/dist/assets/{all-wallets-IZ3PlVF-.js → all-wallets-BhPcqrMm.js} +2 -2
  56. package/packages/ui/dist/assets/{app-store-ARgRdMdF.js → app-store-B_PQMwCf.js} +1 -1
  57. package/packages/ui/dist/assets/{apple-VCaqsI9w.js → apple-CqAFK7Fj.js} +2 -2
  58. package/packages/ui/dist/assets/arrow-bottom-CbxIflTv.js +8 -0
  59. package/packages/ui/dist/assets/{arrow-bottom-circle-h5vFiZ2I.js → arrow-bottom-circle-BFgY35YA.js} +2 -2
  60. package/packages/ui/dist/assets/arrow-left-DCG2m2BY.js +8 -0
  61. package/packages/ui/dist/assets/arrow-right-NrPOhG6W.js +8 -0
  62. package/packages/ui/dist/assets/arrow-top-BHTmGsDP.js +8 -0
  63. package/packages/ui/dist/assets/{bank-6c28yOM9.js → bank-BqDvUazs.js} +2 -2
  64. package/packages/ui/dist/assets/{basic-CJnbTfSd.js → basic-CHFjQMod.js} +177 -177
  65. package/packages/ui/dist/assets/{browser-CDKlxM3D.js → browser-C_VdKE7p.js} +2 -2
  66. package/packages/ui/dist/assets/{card-DQdED02q.js → card-w-1brQoV.js} +2 -2
  67. package/packages/ui/dist/assets/ccip-jvDTeGaI.js +1 -0
  68. package/packages/ui/dist/assets/{checkmark-JoRNVoFV.js → checkmark-CLBmxdAF.js} +2 -2
  69. package/packages/ui/dist/assets/{checkmark-bold-B6bGHVIs.js → checkmark-bold-Ca_e1PMs.js} +2 -2
  70. package/packages/ui/dist/assets/chevron-bottom-BhvFRdSL.js +8 -0
  71. package/packages/ui/dist/assets/chevron-left-cjMaNbHC.js +8 -0
  72. package/packages/ui/dist/assets/chevron-right-CRuHR0b-.js +8 -0
  73. package/packages/ui/dist/assets/chevron-top-Bq0a2jj-.js +8 -0
  74. package/packages/ui/dist/assets/{chrome-store-D-fiJ9qJ.js → chrome-store-Cieq6j7x.js} +2 -2
  75. package/packages/ui/dist/assets/{clock-xCPkzwjj.js → clock-Dkj5WbVg.js} +2 -2
  76. package/packages/ui/dist/assets/{close-BkqmPpWG.js → close-C8eE6Dfz.js} +2 -2
  77. package/packages/ui/dist/assets/{coinPlaceholder-PIvN9oq_.js → coinPlaceholder-DndKH-8C.js} +2 -2
  78. package/packages/ui/dist/assets/{compass-CW5kWcxW.js → compass-DzoLByzm.js} +2 -2
  79. package/packages/ui/dist/assets/{copy-DUZlAQJJ.js → copy-Y7UMmVLt.js} +2 -2
  80. package/packages/ui/dist/assets/core-BkWdAWjX.js +907 -0
  81. package/packages/ui/dist/assets/cursor-BAQNxqYB.js +3 -0
  82. package/packages/ui/dist/assets/{cursor-transparent-BUAMB0G1.js → cursor-transparent-BUHY29Re.js} +2 -2
  83. package/packages/ui/dist/assets/{desktop-BxdlwV8P.js → desktop-DkZLCs5P.js} +2 -2
  84. package/packages/ui/dist/assets/{disconnect-GelNh3mn.js → disconnect-CphsO-wg.js} +2 -2
  85. package/packages/ui/dist/assets/{discord-N0jnxkzC.js → discord-CYH46bgt.js} +2 -2
  86. package/packages/ui/dist/assets/{etherscan-B41u7wF4.js → etherscan-2-3-Icbx.js} +2 -2
  87. package/packages/ui/dist/assets/events-DQ172AOg.js +1 -0
  88. package/packages/ui/dist/assets/{exclamation-triangle-BWJC56FC.js → exclamation-triangle-Bx9-1mpn.js} +2 -2
  89. package/packages/ui/dist/assets/{extension-G6I6oogw.js → extension-BuDZDNPV.js} +2 -2
  90. package/packages/ui/dist/assets/external-link-k6oTiNch.js +8 -0
  91. package/packages/ui/dist/assets/{facebook-47twy32b.js → facebook-BVB4qCju.js} +2 -2
  92. package/packages/ui/dist/assets/{farcaster-DYqnqCqs.js → farcaster-CxfWmDK3.js} +2 -2
  93. package/packages/ui/dist/assets/{filters-dF6xeJnE.js → filters-CXyIzkBz.js} +2 -2
  94. package/packages/ui/dist/assets/{github-DbW4Ihz2.js → github-Bga1HQTm.js} +2 -2
  95. package/packages/ui/dist/assets/{google-TKm7G8LF.js → google-CKLjkN5t.js} +2 -2
  96. package/packages/ui/dist/assets/{help-circle-CY3qTmsG.js → help-circle-CW4A601v.js} +1 -1
  97. package/packages/ui/dist/assets/{id-JpHW4q14.js → id-BaRFLHqy.js} +2 -2
  98. package/packages/ui/dist/assets/{image-Dip2fG98.js → image-4pE_c0pP.js} +2 -2
  99. package/packages/ui/dist/assets/index-B07bCKJ8.css +1 -0
  100. package/packages/ui/dist/assets/index-BKPTb_0U.js +1 -0
  101. package/packages/ui/dist/assets/index-BV8s6ez1.js +1 -0
  102. package/packages/ui/dist/assets/index-BaLMTrx4.js +47 -0
  103. package/packages/ui/dist/assets/index-CguqCMNp.js +16 -0
  104. package/packages/ui/dist/assets/index-RMrT9ktE.js +1780 -0
  105. package/packages/ui/dist/assets/{index-q0mGElxZ.js → index-_n5fH6AD.js} +3 -3
  106. package/packages/ui/dist/assets/index.es-rQvUXQTw.js +26 -0
  107. package/packages/ui/dist/assets/{info-B1enFsqh.js → info-UMAWEFh_.js} +2 -2
  108. package/packages/ui/dist/assets/{info-circle-D4j3FISs.js → info-circle-DuTp8NTC.js} +2 -2
  109. package/packages/ui/dist/assets/{lightbulb-DZbKr-vS.js → lightbulb-CkYYJbAa.js} +2 -2
  110. package/packages/ui/dist/assets/{mail-D-TO_uVQ.js → mail-CntZNMWz.js} +2 -2
  111. package/packages/ui/dist/assets/metamask-sdk-DIj7UxWU.js +542 -0
  112. package/packages/ui/dist/assets/{mobile-Bkmwzav2.js → mobile-DdyrzTfW.js} +2 -2
  113. package/packages/ui/dist/assets/{more-D1_I_jiB.js → more-DpZ1Bqpv.js} +2 -2
  114. package/packages/ui/dist/assets/{network-placeholder-DUaFjoXh.js → network-placeholder-B8yy8U56.js} +2 -2
  115. package/packages/ui/dist/assets/{nftPlaceholder-Cc0iUryh.js → nftPlaceholder-BXFbCJ-Z.js} +2 -2
  116. package/packages/ui/dist/assets/{off-BvX71sse.js → off-DavoQSqH.js} +2 -2
  117. package/packages/ui/dist/assets/{play-store-XzLbtbTd.js → play-store-BJeHSxBp.js} +2 -2
  118. package/packages/ui/dist/assets/{plus-B77_RmYR.js → plus-B-L3uTWl.js} +2 -2
  119. package/packages/ui/dist/assets/{qr-code-BNeIhB1d.js → qr-code-CcQBy6o3.js} +1 -1
  120. package/packages/ui/dist/assets/{recycle-horizontal-B9sX-yty.js → recycle-horizontal-BLC3_x1m.js} +2 -2
  121. package/packages/ui/dist/assets/{refresh-BWRygnjm.js → refresh-78cbzBlS.js} +2 -2
  122. package/packages/ui/dist/assets/{reown-logo-DCAEsGFm.js → reown-logo-Bx5RmN6G.js} +2 -2
  123. package/packages/ui/dist/assets/{search-ZXIqrawS.js → search-XWB8l5E2.js} +2 -2
  124. package/packages/ui/dist/assets/{secp256k1-Doz05h4g.js → secp256k1-u9EmDRXd.js} +1 -1
  125. package/packages/ui/dist/assets/{send-BQcO0jNC.js → send-BjGwACTt.js} +2 -2
  126. package/packages/ui/dist/assets/{swapHorizontal-4yZEzz2K.js → swapHorizontal-DJWcWn3A.js} +2 -2
  127. package/packages/ui/dist/assets/{swapHorizontalBold-DxBKu3sl.js → swapHorizontalBold-CG930oAl.js} +2 -2
  128. package/packages/ui/dist/assets/{swapHorizontalMedium-DAQYJ2JK.js → swapHorizontalMedium-CHIdtnCI.js} +2 -2
  129. package/packages/ui/dist/assets/{swapHorizontalRoundedBold-CUlZzFJ6.js → swapHorizontalRoundedBold-B2oGt4O4.js} +2 -2
  130. package/packages/ui/dist/assets/{swapVertical-CjWHAaDM.js → swapVertical-CnjOFXH3.js} +2 -2
  131. package/packages/ui/dist/assets/{telegram-JBeabiJP.js → telegram-BtOilYdH.js} +2 -2
  132. package/packages/ui/dist/assets/{three-dots-D3R8OjSx.js → three-dots-D_VsAJlo.js} +2 -2
  133. package/packages/ui/dist/assets/{twitch-1f9z7xVO.js → twitch-BIX3n7hL.js} +2 -2
  134. package/packages/ui/dist/assets/{twitterIcon-BW7n2xnp.js → twitterIcon-C3DDaPem.js} +2 -2
  135. package/packages/ui/dist/assets/{verify-Cs5owI38.js → verify-CtzMScZy.js} +2 -2
  136. package/packages/ui/dist/assets/{verify-filled-Ci5sx5qS.js → verify-filled-CVjdmBEW.js} +2 -2
  137. package/packages/ui/dist/assets/{w3m-modal-DnWtss8u.js → w3m-modal-BZ3BUhSD.js} +1 -1
  138. package/packages/ui/dist/assets/{wallet-MaGNqaW-.js → wallet-hURaFgJp.js} +2 -2
  139. package/packages/ui/dist/assets/{wallet-placeholder-kTOy12_L.js → wallet-placeholder-BcF2KreB.js} +2 -2
  140. package/packages/ui/dist/assets/{walletconnect-CyuP92jg.js → walletconnect-C8XCABRo.js} +3 -3
  141. package/packages/ui/dist/assets/{warning-circle-BImUCdpG.js → warning-circle-BMz6LCU4.js} +2 -2
  142. package/packages/ui/dist/assets/{x-II45JHpV.js → x-deAHZeLU.js} +2 -2
  143. package/packages/ui/dist/index.html +2 -2
  144. package/templates/default/.agents/skills/sail-mandates/SKILL.md +1 -1
  145. package/templates/default/.agents/skills/sail-mandates/references/approvals.md +3 -3
  146. package/templates/default/.agents/skills/sail-mandates/references/examples-index.md +3 -3
  147. package/templates/default/.agents/skills/sail-onboarding/SKILL.md +34 -33
  148. package/templates/default/.agents/skills/sail-servers/SKILL.md +1 -0
  149. package/templates/default/.agents/skills/sail-swap-quote/SKILL.md +76 -0
  150. package/templates/default/.agents/skills/sail-template-approve-batch/SKILL.md +98 -0
  151. package/templates/default/.agents/skills/sail-template-borrow/SKILL.md +68 -0
  152. package/templates/default/.agents/skills/sail-template-deposit/SKILL.md +61 -0
  153. package/templates/default/.agents/skills/sail-template-swap/SKILL.md +207 -0
  154. package/templates/default/.agents/skills/sail-template-swap-no-oracle/SKILL.md +100 -0
  155. package/templates/default/.agents/skills/sail-template-transfer/SKILL.md +52 -0
  156. package/templates/default/.agents/skills/sail-template-withdraw/SKILL.md +50 -0
  157. package/templates/default/.agents/skills/sail-templates/SKILL.md +142 -0
  158. package/templates/default/.agents/skills/sail-templates/catalog.mjs +200 -0
  159. package/templates/default/.agents/skills/sail-templates/deployed.json +133 -0
  160. package/templates/default/.agents/skills/sail-templates/oracles/IOracle.sol +13 -0
  161. package/templates/default/.agents/skills/sail-templates/oracles/UniV3TwapOracle.sol +114 -0
  162. package/templates/default/.agents/skills/sail-templates/oracles/libs/FullMath.sol +62 -0
  163. package/templates/default/.agents/skills/sail-templates/oracles/libs/TickMath.sol +44 -0
  164. package/templates/default/.agents/skills/sail-templates/references/config-schemas.md +139 -0
  165. package/templates/default/.agents/skills/sail-templates/references/reuse-flow.md +139 -0
  166. package/templates/default/.agents/skills/sail-token-resolve/SKILL.md +174 -0
  167. package/templates/default/.env.example +9 -0
  168. package/templates/default/AGENTS.md +107 -13
  169. package/templates/default/docs/PERMISSION_MODEL.md +2 -2
  170. package/{examples → templates/default/examples}/custom-mandate/.sail/contracts/interfaces/IPermission.sol +4 -0
  171. package/{examples → templates/default/examples}/custom-mandate/README.md +4 -1
  172. package/{examples → templates/default/examples}/permissions/interfaces/IBatchPermission.sol +2 -0
  173. package/{examples → templates/default/examples}/permissions/interfaces/IPermission.sol +4 -0
  174. package/templates/default/scripts/quote-swap.mjs +211 -0
  175. package/templates/default/scripts/resolve-token.mjs +992 -0
  176. package/templates/default/scripts/shared-template-addr.mjs +110 -0
  177. package/templates/default/test/BoundedCallPermission.t.sol +2 -1
  178. package/docs/PERMISSION_MODEL.md +0 -93
  179. package/examples/README.md +0 -24
  180. package/examples/lifi-permissions/LifiBoundedApprovePermissionCloneable.sol +0 -84
  181. package/examples/lifi-permissions/LifiDiamondSwapPermissionCloneable.sol +0 -97
  182. package/examples/lifi-permissions/README.md +0 -53
  183. package/packages/ui/dist/assets/arrow-bottom-Cwptw8fW.js +0 -8
  184. package/packages/ui/dist/assets/arrow-left-bM1TRcV9.js +0 -8
  185. package/packages/ui/dist/assets/arrow-right-BYd_N4Jr.js +0 -8
  186. package/packages/ui/dist/assets/arrow-top-CLUnwVE2.js +0 -8
  187. package/packages/ui/dist/assets/ccip-BL7RIPfY.js +0 -1
  188. package/packages/ui/dist/assets/chevron-bottom-BMCelIEu.js +0 -8
  189. package/packages/ui/dist/assets/chevron-left-ryPLhHCc.js +0 -8
  190. package/packages/ui/dist/assets/chevron-right-CdDNRv7f.js +0 -8
  191. package/packages/ui/dist/assets/chevron-top-BxWIjjGk.js +0 -8
  192. package/packages/ui/dist/assets/core-von2c1sc.js +0 -907
  193. package/packages/ui/dist/assets/cursor-BzRVY7BD.js +0 -3
  194. package/packages/ui/dist/assets/events-C9icG2YB.js +0 -1
  195. package/packages/ui/dist/assets/external-link-BPaGQf4a.js +0 -8
  196. package/packages/ui/dist/assets/fallback-BTfJeGjh.js +0 -1
  197. package/packages/ui/dist/assets/index-BGJ_8fMk.js +0 -1
  198. package/packages/ui/dist/assets/index-Bq3PAopp.js +0 -16
  199. package/packages/ui/dist/assets/index-C4_cA5XW.js +0 -1
  200. package/packages/ui/dist/assets/index-CaDN0gL4.js +0 -1
  201. package/packages/ui/dist/assets/index-DLElIcBr.js +0 -1789
  202. package/packages/ui/dist/assets/index-lhNfD4jA.css +0 -1
  203. package/packages/ui/dist/assets/index.es-BaCKS_tW.js +0 -26
  204. package/packages/ui/dist/assets/metamask-sdk-DljW3QD1.js +0 -542
  205. package/packages/ui/dist/assets/native-CJ5et6AR.js +0 -1
  206. package/packages/ui/dist/assets/parseSignature-BAS-wKoj.js +0 -1
  207. package/scripts/check-docs.mjs +0 -309
  208. package/scripts/check-init.mjs +0 -123
  209. package/scripts/check-update.mjs +0 -177
  210. package/scripts/clean.mjs +0 -17
  211. package/scripts/pack.mjs +0 -21
  212. package/templates/default/.agents/skills/sail-overview/SKILL.md +0 -100
  213. package/templates/default/.agents/skills/sail-sailor/SKILL.md +0 -190
  214. package/templates/default/.agents/skills/sail-setup/SKILL.md +0 -38
  215. package/templates/default/.gitlab-ci.yml +0 -58
  216. /package/{examples → templates/default/examples}/custom-mandate/foundry.toml +0 -0
  217. /package/{examples → templates/default/examples}/custom-mandate/mandates/BoundedCallPermission.sol +0 -0
  218. /package/{examples → templates/default/examples}/custom-mandate/mandates/README.md +0 -0
  219. /package/{examples → templates/default/examples}/custom-mandate/mandates/SailCalldata.sol +0 -0
  220. /package/{examples → templates/default/examples}/permissions/BoundedApproveAndCallBatch.sol +0 -0
  221. /package/{examples → templates/default/examples}/permissions/BoundedBorrow_AaveV3_Arbitrum.sol +0 -0
  222. /package/{examples → templates/default/examples}/permissions/BoundedLimitless_Base.sol +0 -0
  223. /package/{examples → templates/default/examples}/permissions/BoundedPerp_GMXv2_Arbitrum.sol +0 -0
  224. /package/{examples → templates/default/examples}/permissions/BoundedStake_Venice_Base.sol +0 -0
  225. /package/{examples → templates/default/examples}/permissions/BoundedSupply_AaveV3_Arbitrum.sol +0 -0
  226. /package/{examples → templates/default/examples}/permissions/BoundedSwapNative_UniswapV3_Base.sol +0 -0
  227. /package/{examples → templates/default/examples}/permissions/BoundedSwap_UniswapV3_Base.sol +0 -0
  228. /package/{examples → templates/default/examples}/permissions/BoundedSwap_UniswapV4_Unichain.sol +0 -0
  229. /package/{examples → templates/default/examples}/permissions/BoundedTransfer_ERC20_Ethereum.sol +0 -0
  230. /package/{examples → templates/default/examples}/permissions/BoundedVault_ERC4626_Base.sol +0 -0
  231. /package/{examples → templates/default/examples}/permissions/README.md +0 -0
  232. /package/{examples → templates/default/examples}/permissions/SailCalldata.sol +0 -0
  233. /package/{examples → templates/default/examples}/permissions/foundry.toml +0 -0
@@ -1,4 +1,4 @@
1
- import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R as O,h as ke,e as D,f as S,o as ft,j as Hi,W as gt,C as jt,d as si,T as kt,n as Qe,M as vi,k as yi,F as Ae,A as li,q as Ki}from"./core-von2c1sc.js";import{n as u,c as C,o as y,r as v,U as se,e as Gi,f as Yi,a as Ji}from"./index-q0mGElxZ.js";import"./index-DLElIcBr.js";import"./events-C9icG2YB.js";import"./index.es-BaCKS_tW.js";import"./fallback-BTfJeGjh.js";const Qi=P`
1
+ import{u as N,s as G,y as q,v as O,p as c,g as M,c as z,O as ee,l as k,m as te,R as U,h as Me,e as K,f as j,o as ft,j as Cn,W as pt,C as Zt,d as vi,T as ei,n as Xe,M as on,k as rn,F as Ne,A as yi,q as $n}from"./core-BkWdAWjX.js";import{n as u,c as B,o as E,r as _,U as he,e as Rn,f as _n,a as In}from"./index-_n5fH6AD.js";import{Q as En}from"./index-RMrT9ktE.js";import"./index.es-rQvUXQTw.js";import"./events-DQ172AOg.js";const Wn=N`
2
2
  :host {
3
3
  position: relative;
4
4
  background-color: var(--wui-color-gray-glass-002);
@@ -76,7 +76,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
76
76
  border: 2px solid var(--wui-color-bg-150, #1e1f1f);
77
77
  padding: 1px;
78
78
  }
79
- `;var xe=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let le=class extends I{constructor(){super(...arguments),this.size="md",this.name="",this.installed=!1,this.badgeSize="xs"}render(){let e="xxs";return this.size==="lg"?e="m":this.size==="md"?e="xs":e="xxs",this.style.cssText=`
79
+ `;var _e=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let fe=class extends O{constructor(){super(...arguments),this.size="md",this.name="",this.installed=!1,this.badgeSize="xs"}render(){let e="xxs";return this.size==="lg"?e="m":this.size==="md"?e="xs":e="xxs",this.style.cssText=`
80
80
  --local-border-radius: var(--wui-border-radius-${e});
81
81
  --local-size: var(--wui-wallet-image-size-${this.size});
82
82
  `,this.walletIcon&&(this.dataset.walletIcon=this.walletIcon),c`
@@ -91,7 +91,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
91
91
  size="inherit"
92
92
  color="inherit"
93
93
  name="walletPlaceholder"
94
- ></wui-icon>`}};le.styles=[M,A,Qi];xe([u()],le.prototype,"size",void 0);xe([u()],le.prototype,"name",void 0);xe([u()],le.prototype,"imageSrc",void 0);xe([u()],le.prototype,"walletIcon",void 0);xe([u({type:Boolean})],le.prototype,"installed",void 0);xe([u()],le.prototype,"badgeSize",void 0);le=xe([C("wui-wallet-image")],le);const Xi=P`
94
+ ></wui-icon>`}};fe.styles=[G,q,Wn];_e([u()],fe.prototype,"size",void 0);_e([u()],fe.prototype,"name",void 0);_e([u()],fe.prototype,"imageSrc",void 0);_e([u()],fe.prototype,"walletIcon",void 0);_e([u({type:Boolean})],fe.prototype,"installed",void 0);_e([u()],fe.prototype,"badgeSize",void 0);fe=_e([B("wui-wallet-image")],fe);const Sn=N`
95
95
  :host {
96
96
  position: relative;
97
97
  border-radius: var(--wui-border-radius-xxs);
@@ -136,14 +136,14 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
136
136
  z-index: 2;
137
137
  display: flex;
138
138
  }
139
- `;var xi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const Wt=4;let Xe=class extends I{constructor(){super(...arguments),this.walletImages=[]}render(){const e=this.walletImages.length<Wt;return c`${this.walletImages.slice(0,Wt).map(({src:i,walletName:n})=>c`
139
+ `;var an=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const It=4;let Ze=class extends O{constructor(){super(...arguments),this.walletImages=[]}render(){const e=this.walletImages.length<It;return c`${this.walletImages.slice(0,It).map(({src:i,walletName:n})=>c`
140
140
  <wui-wallet-image
141
141
  size="inherit"
142
142
  imageSrc=${i}
143
- name=${y(n)}
143
+ name=${E(n)}
144
144
  ></wui-wallet-image>
145
145
  `)}
146
- ${e?[...Array(Wt-this.walletImages.length)].map(()=>c` <wui-wallet-image size="inherit" name=""></wui-wallet-image>`):null}
146
+ ${e?[...Array(It-this.walletImages.length)].map(()=>c` <wui-wallet-image size="inherit" name=""></wui-wallet-image>`):null}
147
147
  <wui-flex>
148
148
  <wui-icon-box
149
149
  size="xxs"
@@ -153,7 +153,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
153
153
  icon="checkmark"
154
154
  background="opaque"
155
155
  ></wui-icon-box>
156
- </wui-flex>`}};Xe.styles=[A,Xi];xi([u({type:Array})],Xe.prototype,"walletImages",void 0);Xe=xi([C("wui-all-wallets-image")],Xe);const Zi=P`
156
+ </wui-flex>`}};Ze.styles=[q,Sn];an([u({type:Array})],Ze.prototype,"walletImages",void 0);Ze=an([B("wui-all-wallets-image")],Ze);const Tn=N`
157
157
  button {
158
158
  column-gap: var(--wui-spacing-s);
159
159
  padding: 7px var(--wui-spacing-l) 7px var(--wui-spacing-xs);
@@ -181,8 +181,8 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
181
181
  wui-icon {
182
182
  color: var(--wui-color-fg-200) !important;
183
183
  }
184
- `;var U=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let k=class extends I{constructor(){super(...arguments),this.walletImages=[],this.imageSrc="",this.name="",this.tabIdx=void 0,this.installed=!1,this.disabled=!1,this.showAllWallets=!1,this.loading=!1,this.loadingSpinnerColor="accent-100"}render(){return c`
185
- <button ?disabled=${this.disabled} tabindex=${y(this.tabIdx)}>
184
+ `;var Y=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let F=class extends O{constructor(){super(...arguments),this.walletImages=[],this.imageSrc="",this.name="",this.tabIdx=void 0,this.installed=!1,this.disabled=!1,this.showAllWallets=!1,this.loading=!1,this.loadingSpinnerColor="accent-100"}render(){return c`
185
+ <button ?disabled=${this.disabled} tabindex=${E(this.tabIdx)}>
186
186
  ${this.templateAllWallets()} ${this.templateWalletImage()}
187
187
  <wui-text variant="paragraph-500" color="inherit">${this.name}</wui-text>
188
188
  ${this.templateStatus()}
@@ -195,7 +195,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
195
195
  ></wui-wallet-image>`:!this.showAllWallets&&!this.imageSrc?c`<wui-wallet-image size="sm" name=${this.name}></wui-wallet-image>`:null}templateStatus(){return this.loading?c`<wui-loading-spinner
196
196
  size="lg"
197
197
  color=${this.loadingSpinnerColor}
198
- ></wui-loading-spinner>`:this.tagLabel&&this.tagVariant?c`<wui-tag variant=${this.tagVariant}>${this.tagLabel}</wui-tag>`:this.icon?c`<wui-icon color="inherit" size="sm" name=${this.icon}></wui-icon>`:null}};k.styles=[A,M,Zi];U([u({type:Array})],k.prototype,"walletImages",void 0);U([u()],k.prototype,"imageSrc",void 0);U([u()],k.prototype,"name",void 0);U([u()],k.prototype,"tagLabel",void 0);U([u()],k.prototype,"tagVariant",void 0);U([u()],k.prototype,"icon",void 0);U([u()],k.prototype,"walletIcon",void 0);U([u()],k.prototype,"tabIdx",void 0);U([u({type:Boolean})],k.prototype,"installed",void 0);U([u({type:Boolean})],k.prototype,"disabled",void 0);U([u({type:Boolean})],k.prototype,"showAllWallets",void 0);U([u({type:Boolean})],k.prototype,"loading",void 0);U([u({type:String})],k.prototype,"loadingSpinnerColor",void 0);k=U([C("wui-list-wallet")],k);var Pe=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let we=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.count=T.state.count,this.filteredCount=T.state.filteredWallets.length,this.isFetchingRecommendedWallets=T.state.isFetchingRecommendedWallets,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e),T.subscribeKey("count",e=>this.count=e),T.subscribeKey("filteredWallets",e=>this.filteredCount=e.length),T.subscribeKey("isFetchingRecommendedWallets",e=>this.isFetchingRecommendedWallets=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.find(l=>l.id==="walletConnect"),{allWallets:i}=Y.state;if(!e||i==="HIDE"||i==="ONLY_MOBILE"&&!E.isMobile())return null;const n=T.state.featured.length,o=this.count+n,t=o<10?o:Math.floor(o/10)*10,a=this.filteredCount>0?this.filteredCount:t;let s=`${a}`;return this.filteredCount>0?s=`${this.filteredCount}`:a<o&&(s=`${a}+`),c`
198
+ ></wui-loading-spinner>`:this.tagLabel&&this.tagVariant?c`<wui-tag variant=${this.tagVariant}>${this.tagLabel}</wui-tag>`:this.icon?c`<wui-icon color="inherit" size="sm" name=${this.icon}></wui-icon>`:null}};F.styles=[q,G,Tn];Y([u({type:Array})],F.prototype,"walletImages",void 0);Y([u()],F.prototype,"imageSrc",void 0);Y([u()],F.prototype,"name",void 0);Y([u()],F.prototype,"tagLabel",void 0);Y([u()],F.prototype,"tagVariant",void 0);Y([u()],F.prototype,"icon",void 0);Y([u()],F.prototype,"walletIcon",void 0);Y([u()],F.prototype,"tabIdx",void 0);Y([u({type:Boolean})],F.prototype,"installed",void 0);Y([u({type:Boolean})],F.prototype,"disabled",void 0);Y([u({type:Boolean})],F.prototype,"showAllWallets",void 0);Y([u({type:Boolean})],F.prototype,"loading",void 0);Y([u({type:String})],F.prototype,"loadingSpinnerColor",void 0);F=Y([B("wui-list-wallet")],F);var Ae=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ye=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.count=z.state.count,this.filteredCount=z.state.filteredWallets.length,this.isFetchingRecommendedWallets=z.state.isFetchingRecommendedWallets,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e),z.subscribeKey("count",e=>this.count=e),z.subscribeKey("filteredWallets",e=>this.filteredCount=e.length),z.subscribeKey("isFetchingRecommendedWallets",e=>this.isFetchingRecommendedWallets=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.find(l=>l.id==="walletConnect"),{allWallets:i}=ee.state;if(!e||i==="HIDE"||i==="ONLY_MOBILE"&&!k.isMobile())return null;const n=z.state.featured.length,o=this.count+n,t=o<10?o:Math.floor(o/10)*10,a=this.filteredCount>0?this.filteredCount:t;let s=`${a}`;return this.filteredCount>0?s=`${this.filteredCount}`:a<o&&(s=`${a}+`),c`
199
199
  <wui-list-wallet
200
200
  name="All Wallets"
201
201
  walletIcon="allWallets"
@@ -204,137 +204,137 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
204
204
  tagLabel=${s}
205
205
  tagVariant="shade"
206
206
  data-testid="all-wallets"
207
- tabIdx=${y(this.tabIdx)}
207
+ tabIdx=${E(this.tabIdx)}
208
208
  .loading=${this.isFetchingRecommendedWallets}
209
209
  loadingSpinnerColor=${this.isFetchingRecommendedWallets?"fg-300":"accent-100"}
210
210
  ></wui-list-wallet>
211
- `}onAllWallets(){J.sendEvent({type:"track",event:"CLICK_ALL_WALLETS"}),O.push("AllWallets")}};Pe([u()],we.prototype,"tabIdx",void 0);Pe([v()],we.prototype,"connectors",void 0);Pe([v()],we.prototype,"count",void 0);Pe([v()],we.prototype,"filteredCount",void 0);Pe([v()],we.prototype,"isFetchingRecommendedWallets",void 0);we=Pe([C("w3m-all-wallets-widget")],we);var Kt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ze=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.filter(i=>i.type==="ANNOUNCED");return e!=null&&e.length?c`
211
+ `}onAllWallets(){te.sendEvent({type:"track",event:"CLICK_ALL_WALLETS"}),U.push("AllWallets")}};Ae([u()],ye.prototype,"tabIdx",void 0);Ae([_()],ye.prototype,"connectors",void 0);Ae([_()],ye.prototype,"count",void 0);Ae([_()],ye.prototype,"filteredCount",void 0);Ae([_()],ye.prototype,"isFetchingRecommendedWallets",void 0);ye=Ae([B("w3m-all-wallets-widget")],ye);var ai=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let et=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.filter(i=>i.type==="ANNOUNCED");return e!=null&&e.length?c`
212
212
  <wui-flex flexDirection="column" gap="xs">
213
- ${e.filter(ke.showConnector).map(i=>c`
213
+ ${e.filter(Me.showConnector).map(i=>c`
214
214
  <wui-list-wallet
215
- imageSrc=${y(D.getConnectorImage(i))}
215
+ imageSrc=${E(K.getConnectorImage(i))}
216
216
  name=${i.name??"Unknown"}
217
217
  @click=${()=>this.onConnector(i)}
218
218
  tagVariant="success"
219
219
  tagLabel="installed"
220
220
  data-testid=${`wallet-selector-${i.id}`}
221
221
  .installed=${!0}
222
- tabIdx=${y(this.tabIdx)}
222
+ tabIdx=${E(this.tabIdx)}
223
223
  >
224
224
  </wui-list-wallet>
225
225
  `)}
226
226
  </wui-flex>
227
- `:(this.style.cssText="display: none",null)}onConnector(e){e.id==="walletConnect"?E.isMobile()?O.push("AllWallets"):O.push("ConnectingWalletConnect"):O.push("ConnectingExternal",{connector:e})}};Kt([u()],Ze.prototype,"tabIdx",void 0);Kt([v()],Ze.prototype,"connectors",void 0);Ze=Kt([C("w3m-connect-announced-widget")],Ze);var wt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ze=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.loading=!1,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e)),E.isTelegram()&&E.isIos()&&(this.loading=!S.state.wcUri,this.unsubscribe.push(S.subscribeKey("wcUri",e=>this.loading=!e)))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const{customWallets:e}=Y.state;if(!(e!=null&&e.length))return this.style.cssText="display: none",null;const i=this.filterOutDuplicateWallets(e);return c`<wui-flex flexDirection="column" gap="xs">
227
+ `:(this.style.cssText="display: none",null)}onConnector(e){e.id==="walletConnect"?k.isMobile()?U.push("AllWallets"):U.push("ConnectingWalletConnect"):U.push("ConnectingExternal",{connector:e})}};ai([u()],et.prototype,"tabIdx",void 0);ai([_()],et.prototype,"connectors",void 0);et=ai([B("w3m-connect-announced-widget")],et);var gt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ue=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.loading=!1,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e)),k.isTelegram()&&k.isIos()&&(this.loading=!j.state.wcUri,this.unsubscribe.push(j.subscribeKey("wcUri",e=>this.loading=!e)))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const{customWallets:e}=ee.state;if(!(e!=null&&e.length))return this.style.cssText="display: none",null;const i=this.filterOutDuplicateWallets(e);return c`<wui-flex flexDirection="column" gap="xs">
228
228
  ${i.map(n=>c`
229
229
  <wui-list-wallet
230
- imageSrc=${y(D.getWalletImage(n))}
230
+ imageSrc=${E(K.getWalletImage(n))}
231
231
  name=${n.name??"Unknown"}
232
232
  @click=${()=>this.onConnectWallet(n)}
233
233
  data-testid=${`wallet-selector-${n.id}`}
234
- tabIdx=${y(this.tabIdx)}
234
+ tabIdx=${E(this.tabIdx)}
235
235
  ?loading=${this.loading}
236
236
  >
237
237
  </wui-list-wallet>
238
238
  `)}
239
- </wui-flex>`}filterOutDuplicateWallets(e){const i=ft.getRecentWallets(),n=this.connectors.map(s=>{var l;return(l=s.info)==null?void 0:l.rdns}).filter(Boolean),o=i.map(s=>s.rdns).filter(Boolean),t=n.concat(o);if(t.includes("io.metamask.mobile")&&E.isMobile()){const s=t.indexOf("io.metamask.mobile");t[s]="io.metamask"}return e.filter(s=>!t.includes(String(s==null?void 0:s.rdns)))}onConnectWallet(e){this.loading||O.push("ConnectingWalletConnect",{wallet:e})}};wt([u()],ze.prototype,"tabIdx",void 0);wt([v()],ze.prototype,"connectors",void 0);wt([v()],ze.prototype,"loading",void 0);ze=wt([C("w3m-connect-custom-widget")],ze);var Gt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let et=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const n=this.connectors.filter(o=>o.type==="EXTERNAL").filter(ke.showConnector).filter(o=>o.id!==Hi.CONNECTOR_ID.COINBASE_SDK);return n!=null&&n.length?c`
239
+ </wui-flex>`}filterOutDuplicateWallets(e){const i=ft.getRecentWallets(),n=this.connectors.map(s=>{var l;return(l=s.info)==null?void 0:l.rdns}).filter(Boolean),o=i.map(s=>s.rdns).filter(Boolean),t=n.concat(o);if(t.includes("io.metamask.mobile")&&k.isMobile()){const s=t.indexOf("io.metamask.mobile");t[s]="io.metamask"}return e.filter(s=>!t.includes(String(s==null?void 0:s.rdns)))}onConnectWallet(e){this.loading||U.push("ConnectingWalletConnect",{wallet:e})}};gt([u()],Ue.prototype,"tabIdx",void 0);gt([_()],Ue.prototype,"connectors",void 0);gt([_()],Ue.prototype,"loading",void 0);Ue=gt([B("w3m-connect-custom-widget")],Ue);var si=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let tt=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const n=this.connectors.filter(o=>o.type==="EXTERNAL").filter(Me.showConnector).filter(o=>o.id!==Cn.CONNECTOR_ID.COINBASE_SDK);return n!=null&&n.length?c`
240
240
  <wui-flex flexDirection="column" gap="xs">
241
241
  ${n.map(o=>c`
242
242
  <wui-list-wallet
243
- imageSrc=${y(D.getConnectorImage(o))}
243
+ imageSrc=${E(K.getConnectorImage(o))}
244
244
  .installed=${!0}
245
245
  name=${o.name??"Unknown"}
246
246
  data-testid=${`wallet-selector-external-${o.id}`}
247
247
  @click=${()=>this.onConnector(o)}
248
- tabIdx=${y(this.tabIdx)}
248
+ tabIdx=${E(this.tabIdx)}
249
249
  >
250
250
  </wui-list-wallet>
251
251
  `)}
252
252
  </wui-flex>
253
- `:(this.style.cssText="display: none",null)}onConnector(e){O.push("ConnectingExternal",{connector:e})}};Gt([u()],et.prototype,"tabIdx",void 0);Gt([v()],et.prototype,"connectors",void 0);et=Gt([C("w3m-connect-external-widget")],et);var Yt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let tt=class extends I{constructor(){super(...arguments),this.tabIdx=void 0,this.wallets=[]}render(){return this.wallets.length?c`
253
+ `:(this.style.cssText="display: none",null)}onConnector(e){U.push("ConnectingExternal",{connector:e})}};si([u()],tt.prototype,"tabIdx",void 0);si([_()],tt.prototype,"connectors",void 0);tt=si([B("w3m-connect-external-widget")],tt);var li=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let it=class extends O{constructor(){super(...arguments),this.tabIdx=void 0,this.wallets=[]}render(){return this.wallets.length?c`
254
254
  <wui-flex flexDirection="column" gap="xs">
255
255
  ${this.wallets.map(e=>c`
256
256
  <wui-list-wallet
257
257
  data-testid=${`wallet-selector-featured-${e.id}`}
258
- imageSrc=${y(D.getWalletImage(e))}
258
+ imageSrc=${E(K.getWalletImage(e))}
259
259
  name=${e.name??"Unknown"}
260
260
  @click=${()=>this.onConnectWallet(e)}
261
- tabIdx=${y(this.tabIdx)}
261
+ tabIdx=${E(this.tabIdx)}
262
262
  >
263
263
  </wui-list-wallet>
264
264
  `)}
265
265
  </wui-flex>
266
- `:(this.style.cssText="display: none",null)}onConnectWallet(e){L.selectWalletConnector(e)}};Yt([u()],tt.prototype,"tabIdx",void 0);Yt([u()],tt.prototype,"wallets",void 0);tt=Yt([C("w3m-connect-featured-widget")],tt);var Jt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let it=class extends I{constructor(){super(...arguments),this.tabIdx=void 0,this.connectors=[]}render(){const e=this.connectors.filter(ke.showConnector);return e.length===0?(this.style.cssText="display: none",null):c`
266
+ `:(this.style.cssText="display: none",null)}onConnectWallet(e){M.selectWalletConnector(e)}};li([u()],it.prototype,"tabIdx",void 0);li([u()],it.prototype,"wallets",void 0);it=li([B("w3m-connect-featured-widget")],it);var ci=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let nt=class extends O{constructor(){super(...arguments),this.tabIdx=void 0,this.connectors=[]}render(){const e=this.connectors.filter(Me.showConnector);return e.length===0?(this.style.cssText="display: none",null):c`
267
267
  <wui-flex flexDirection="column" gap="xs">
268
268
  ${e.map(i=>c`
269
269
  <wui-list-wallet
270
- imageSrc=${y(D.getConnectorImage(i))}
270
+ imageSrc=${E(K.getConnectorImage(i))}
271
271
  .installed=${!0}
272
272
  name=${i.name??"Unknown"}
273
273
  tagVariant="success"
274
274
  tagLabel="installed"
275
275
  data-testid=${`wallet-selector-${i.id}`}
276
276
  @click=${()=>this.onConnector(i)}
277
- tabIdx=${y(this.tabIdx)}
277
+ tabIdx=${E(this.tabIdx)}
278
278
  >
279
279
  </wui-list-wallet>
280
280
  `)}
281
281
  </wui-flex>
282
- `}onConnector(e){L.setActiveConnector(e),O.push("ConnectingExternal",{connector:e})}};Jt([u()],it.prototype,"tabIdx",void 0);Jt([u()],it.prototype,"connectors",void 0);it=Jt([C("w3m-connect-injected-widget")],it);var Qt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let nt=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.filter(i=>i.type==="MULTI_CHAIN"&&i.name!=="WalletConnect");return e!=null&&e.length?c`
282
+ `}onConnector(e){M.setActiveConnector(e),U.push("ConnectingExternal",{connector:e})}};ci([u()],nt.prototype,"tabIdx",void 0);ci([u()],nt.prototype,"connectors",void 0);nt=ci([B("w3m-connect-injected-widget")],nt);var ui=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ot=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.connectors.filter(i=>i.type==="MULTI_CHAIN"&&i.name!=="WalletConnect");return e!=null&&e.length?c`
283
283
  <wui-flex flexDirection="column" gap="xs">
284
284
  ${e.map(i=>c`
285
285
  <wui-list-wallet
286
- imageSrc=${y(D.getConnectorImage(i))}
286
+ imageSrc=${E(K.getConnectorImage(i))}
287
287
  .installed=${!0}
288
288
  name=${i.name??"Unknown"}
289
289
  tagVariant="shade"
290
290
  tagLabel="multichain"
291
291
  data-testid=${`wallet-selector-${i.id}`}
292
292
  @click=${()=>this.onConnector(i)}
293
- tabIdx=${y(this.tabIdx)}
293
+ tabIdx=${E(this.tabIdx)}
294
294
  >
295
295
  </wui-list-wallet>
296
296
  `)}
297
297
  </wui-flex>
298
- `:(this.style.cssText="display: none",null)}onConnector(e){L.setActiveConnector(e),O.push("ConnectingMultiChain")}};Qt([u()],nt.prototype,"tabIdx",void 0);Qt([v()],nt.prototype,"connectors",void 0);nt=Qt([C("w3m-connect-multi-chain-widget")],nt);var bt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let De=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.loading=!1,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e)),E.isTelegram()&&E.isIos()&&(this.loading=!S.state.wcUri,this.unsubscribe.push(S.subscribeKey("wcUri",e=>this.loading=!e)))}render(){const i=ft.getRecentWallets().filter(n=>!gt.isExcluded(n)).filter(n=>!this.hasWalletConnector(n)).filter(n=>this.isWalletCompatibleWithCurrentChain(n));return i.length?c`
298
+ `:(this.style.cssText="display: none",null)}onConnector(e){M.setActiveConnector(e),U.push("ConnectingMultiChain")}};ui([u()],ot.prototype,"tabIdx",void 0);ui([_()],ot.prototype,"connectors",void 0);ot=ui([B("w3m-connect-multi-chain-widget")],ot);var wt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let qe=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.loading=!1,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e)),k.isTelegram()&&k.isIos()&&(this.loading=!j.state.wcUri,this.unsubscribe.push(j.subscribeKey("wcUri",e=>this.loading=!e)))}render(){const i=ft.getRecentWallets().filter(n=>!pt.isExcluded(n)).filter(n=>!this.hasWalletConnector(n)).filter(n=>this.isWalletCompatibleWithCurrentChain(n));return i.length?c`
299
299
  <wui-flex flexDirection="column" gap="xs">
300
300
  ${i.map(n=>c`
301
301
  <wui-list-wallet
302
- imageSrc=${y(D.getWalletImage(n))}
302
+ imageSrc=${E(K.getWalletImage(n))}
303
303
  name=${n.name??"Unknown"}
304
304
  @click=${()=>this.onConnectWallet(n)}
305
305
  tagLabel="recent"
306
306
  tagVariant="shade"
307
- tabIdx=${y(this.tabIdx)}
307
+ tabIdx=${E(this.tabIdx)}
308
308
  ?loading=${this.loading}
309
309
  >
310
310
  </wui-list-wallet>
311
311
  `)}
312
312
  </wui-flex>
313
- `:(this.style.cssText="display: none",null)}onConnectWallet(e){this.loading||L.selectWalletConnector(e)}hasWalletConnector(e){return this.connectors.some(i=>i.id===e.id||i.name===e.name)}isWalletCompatibleWithCurrentChain(e){const i=jt.state.activeChain;return i&&e.chains?e.chains.some(n=>{const o=n.split(":")[0];return i===o}):!0}};bt([u()],De.prototype,"tabIdx",void 0);bt([v()],De.prototype,"connectors",void 0);bt([v()],De.prototype,"loading",void 0);De=bt([C("w3m-connect-recent-widget")],De);var mt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ne=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.wallets=[],this.loading=!1,E.isTelegram()&&E.isIos()&&(this.loading=!S.state.wcUri,this.unsubscribe.push(S.subscribeKey("wcUri",e=>this.loading=!e)))}render(){const{connectors:e}=L.state,{customWallets:i,featuredWalletIds:n}=Y.state,o=ft.getRecentWallets(),t=e.find(_=>_.id==="walletConnect"),s=e.filter(_=>_.type==="INJECTED"||_.type==="ANNOUNCED"||_.type==="MULTI_CHAIN").filter(_=>_.name!=="Browser Wallet");if(!t)return null;if(n||i||!this.wallets.length)return this.style.cssText="display: none",null;const l=s.length+o.length,h=Math.max(0,2-l),d=gt.filterOutDuplicateWallets(this.wallets).slice(0,h);return d.length?c`
313
+ `:(this.style.cssText="display: none",null)}onConnectWallet(e){this.loading||M.selectWalletConnector(e)}hasWalletConnector(e){return this.connectors.some(i=>i.id===e.id||i.name===e.name)}isWalletCompatibleWithCurrentChain(e){const i=Zt.state.activeChain;return i&&e.chains?e.chains.some(n=>{const o=n.split(":")[0];return i===o}):!0}};wt([u()],qe.prototype,"tabIdx",void 0);wt([_()],qe.prototype,"connectors",void 0);wt([_()],qe.prototype,"loading",void 0);qe=wt([B("w3m-connect-recent-widget")],qe);var bt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Fe=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.wallets=[],this.loading=!1,k.isTelegram()&&k.isIos()&&(this.loading=!j.state.wcUri,this.unsubscribe.push(j.subscribeKey("wcUri",e=>this.loading=!e)))}render(){const{connectors:e}=M.state,{customWallets:i,featuredWalletIds:n}=ee.state,o=ft.getRecentWallets(),t=e.find(p=>p.id==="walletConnect"),s=e.filter(p=>p.type==="INJECTED"||p.type==="ANNOUNCED"||p.type==="MULTI_CHAIN").filter(p=>p.name!=="Browser Wallet");if(!t)return null;if(n||i||!this.wallets.length)return this.style.cssText="display: none",null;const l=s.length+o.length,d=Math.max(0,2-l),h=pt.filterOutDuplicateWallets(this.wallets).slice(0,d);return h.length?c`
314
314
  <wui-flex flexDirection="column" gap="xs">
315
- ${d.map(_=>c`
315
+ ${h.map(p=>c`
316
316
  <wui-list-wallet
317
- imageSrc=${y(D.getWalletImage(_))}
318
- name=${(_==null?void 0:_.name)??"Unknown"}
319
- @click=${()=>this.onConnectWallet(_)}
320
- tabIdx=${y(this.tabIdx)}
317
+ imageSrc=${E(K.getWalletImage(p))}
318
+ name=${(p==null?void 0:p.name)??"Unknown"}
319
+ @click=${()=>this.onConnectWallet(p)}
320
+ tabIdx=${E(this.tabIdx)}
321
321
  ?loading=${this.loading}
322
322
  >
323
323
  </wui-list-wallet>
324
324
  `)}
325
325
  </wui-flex>
326
- `:(this.style.cssText="display: none",null)}onConnectWallet(e){if(this.loading)return;const i=L.getConnector(e.id,e.rdns);i?O.push("ConnectingExternal",{connector:i}):O.push("ConnectingWalletConnect",{wallet:e})}};mt([u()],Ne.prototype,"tabIdx",void 0);mt([u()],Ne.prototype,"wallets",void 0);mt([v()],Ne.prototype,"loading",void 0);Ne=mt([C("w3m-connect-recommended-widget")],Ne);var vt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Me=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.connectorImages=si.state.connectorImages,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e),si.subscribeKey("connectorImages",e=>this.connectorImages=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){if(E.isMobile())return this.style.cssText="display: none",null;const e=this.connectors.find(n=>n.id==="walletConnect");if(!e)return this.style.cssText="display: none",null;const i=e.imageUrl||this.connectorImages[(e==null?void 0:e.imageId)??""];return c`
326
+ `:(this.style.cssText="display: none",null)}onConnectWallet(e){if(this.loading)return;const i=M.getConnector(e.id,e.rdns);i?U.push("ConnectingExternal",{connector:i}):U.push("ConnectingWalletConnect",{wallet:e})}};bt([u()],Fe.prototype,"tabIdx",void 0);bt([u()],Fe.prototype,"wallets",void 0);bt([_()],Fe.prototype,"loading",void 0);Fe=bt([B("w3m-connect-recommended-widget")],Fe);var mt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ve=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.connectorImages=vi.state.connectorImages,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e),vi.subscribeKey("connectorImages",e=>this.connectorImages=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){if(k.isMobile())return this.style.cssText="display: none",null;const e=this.connectors.find(n=>n.id==="walletConnect");if(!e)return this.style.cssText="display: none",null;const i=e.imageUrl||this.connectorImages[(e==null?void 0:e.imageId)??""];return c`
327
327
  <wui-list-wallet
328
- imageSrc=${y(i)}
328
+ imageSrc=${E(i)}
329
329
  name=${e.name??"Unknown"}
330
330
  @click=${()=>this.onConnector(e)}
331
331
  tagLabel="qr code"
332
332
  tagVariant="main"
333
- tabIdx=${y(this.tabIdx)}
333
+ tabIdx=${E(this.tabIdx)}
334
334
  data-testid="wallet-selector-walletconnect"
335
335
  >
336
336
  </wui-list-wallet>
337
- `}onConnector(e){L.setActiveConnector(e),O.push("ConnectingWalletConnect")}};vt([u()],Me.prototype,"tabIdx",void 0);vt([v()],Me.prototype,"connectors",void 0);vt([v()],Me.prototype,"connectorImages",void 0);Me=vt([C("w3m-connect-walletconnect-widget")],Me);const en=P`
337
+ `}onConnector(e){M.setActiveConnector(e),U.push("ConnectingWalletConnect")}};mt([u()],Ve.prototype,"tabIdx",void 0);mt([_()],Ve.prototype,"connectors",void 0);mt([_()],Ve.prototype,"connectorImages",void 0);Ve=mt([B("w3m-connect-walletconnect-widget")],Ve);const Pn=N`
338
338
  :host {
339
339
  margin-top: var(--wui-spacing-3xs);
340
340
  }
@@ -343,34 +343,34 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
343
343
  calc(var(--wui-spacing-m) * -1);
344
344
  width: calc(100% + var(--wui-spacing-s) * 2);
345
345
  }
346
- `;var Fe=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let be=class extends I{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=L.state.connectors,this.recommended=T.state.recommended,this.featured=T.state.featured,this.unsubscribe.push(L.subscribeKey("connectors",e=>this.connectors=e),T.subscribeKey("recommended",e=>this.recommended=e),T.subscribeKey("featured",e=>this.featured=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){return c`
346
+ `;var Ke=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let xe=class extends O{constructor(){super(),this.unsubscribe=[],this.tabIdx=void 0,this.connectors=M.state.connectors,this.recommended=z.state.recommended,this.featured=z.state.featured,this.unsubscribe.push(M.subscribeKey("connectors",e=>this.connectors=e),z.subscribeKey("recommended",e=>this.recommended=e),z.subscribeKey("featured",e=>this.featured=e))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){return c`
347
347
  <wui-flex flexDirection="column" gap="xs"> ${this.connectorListTemplate()} </wui-flex>
348
- `}connectorListTemplate(){const{custom:e,recent:i,announced:n,injected:o,multiChain:t,recommended:a,featured:s,external:l}=ke.getConnectorsByType(this.connectors,this.recommended,this.featured);return ke.getConnectorTypeOrder({custom:e,recent:i,announced:n,injected:o,multiChain:t,recommended:a,featured:s,external:l}).map(d=>{switch(d){case"injected":return c`
348
+ `}connectorListTemplate(){const{custom:e,recent:i,announced:n,injected:o,multiChain:t,recommended:a,featured:s,external:l}=Me.getConnectorsByType(this.connectors,this.recommended,this.featured);return Me.getConnectorTypeOrder({custom:e,recent:i,announced:n,injected:o,multiChain:t,recommended:a,featured:s,external:l}).map(h=>{switch(h){case"injected":return c`
349
349
  ${t.length?c`<w3m-connect-multi-chain-widget
350
- tabIdx=${y(this.tabIdx)}
350
+ tabIdx=${E(this.tabIdx)}
351
351
  ></w3m-connect-multi-chain-widget>`:null}
352
352
  ${n.length?c`<w3m-connect-announced-widget
353
- tabIdx=${y(this.tabIdx)}
353
+ tabIdx=${E(this.tabIdx)}
354
354
  ></w3m-connect-announced-widget>`:null}
355
355
  ${o.length?c`<w3m-connect-injected-widget
356
356
  .connectors=${o}
357
- tabIdx=${y(this.tabIdx)}
357
+ tabIdx=${E(this.tabIdx)}
358
358
  ></w3m-connect-injected-widget>`:null}
359
359
  `;case"walletConnect":return c`<w3m-connect-walletconnect-widget
360
- tabIdx=${y(this.tabIdx)}
360
+ tabIdx=${E(this.tabIdx)}
361
361
  ></w3m-connect-walletconnect-widget>`;case"recent":return c`<w3m-connect-recent-widget
362
- tabIdx=${y(this.tabIdx)}
362
+ tabIdx=${E(this.tabIdx)}
363
363
  ></w3m-connect-recent-widget>`;case"featured":return c`<w3m-connect-featured-widget
364
364
  .wallets=${s}
365
- tabIdx=${y(this.tabIdx)}
365
+ tabIdx=${E(this.tabIdx)}
366
366
  ></w3m-connect-featured-widget>`;case"custom":return c`<w3m-connect-custom-widget
367
- tabIdx=${y(this.tabIdx)}
367
+ tabIdx=${E(this.tabIdx)}
368
368
  ></w3m-connect-custom-widget>`;case"external":return c`<w3m-connect-external-widget
369
- tabIdx=${y(this.tabIdx)}
369
+ tabIdx=${E(this.tabIdx)}
370
370
  ></w3m-connect-external-widget>`;case"recommended":return c`<w3m-connect-recommended-widget
371
371
  .wallets=${a}
372
- tabIdx=${y(this.tabIdx)}
373
- ></w3m-connect-recommended-widget>`;default:return console.warn(`Unknown connector type: ${d}`),null}})}};be.styles=en;Fe([u()],be.prototype,"tabIdx",void 0);Fe([v()],be.prototype,"connectors",void 0);Fe([v()],be.prototype,"recommended",void 0);Fe([v()],be.prototype,"featured",void 0);be=Fe([C("w3m-connector-list")],be);const tn=P`
372
+ tabIdx=${E(this.tabIdx)}
373
+ ></w3m-connect-recommended-widget>`;default:return console.warn(`Unknown connector type: ${h}`),null}})}};xe.styles=Pn;Ke([u()],xe.prototype,"tabIdx",void 0);Ke([_()],xe.prototype,"connectors",void 0);Ke([_()],xe.prototype,"recommended",void 0);Ke([_()],xe.prototype,"featured",void 0);xe=Ke([B("w3m-connector-list")],xe);const Bn=N`
374
374
  :host {
375
375
  display: inline-flex;
376
376
  background-color: var(--wui-color-gray-glass-002);
@@ -481,7 +481,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
481
481
  button {
482
482
  border-radius: var(--wui-border-radius-3xl);
483
483
  }
484
- `;var fe=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ee=class extends I{constructor(){super(...arguments),this.tabs=[],this.onTabChange=()=>null,this.buttons=[],this.disabled=!1,this.localTabWidth="100px",this.activeTab=0,this.isDense=!1}render(){return this.isDense=this.tabs.length>3,this.style.cssText=`
484
+ `;var ve=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let re=class extends O{constructor(){super(...arguments),this.tabs=[],this.onTabChange=()=>null,this.buttons=[],this.disabled=!1,this.localTabWidth="100px",this.activeTab=0,this.isDense=!1}render(){return this.isDense=this.tabs.length>3,this.style.cssText=`
485
485
  --local-tab: ${this.activeTab};
486
486
  --local-tab-width: ${this.localTabWidth};
487
487
  `,this.dataset.type=this.isDense?"flex":"block",this.tabs.map((e,i)=>{var o;const n=i===this.activeTab;return c`
@@ -494,11 +494,11 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
494
494
  ${this.iconTemplate(e)}
495
495
  <wui-text variant="small-600" color="inherit"> ${e.label} </wui-text>
496
496
  </button>
497
- `})}firstUpdated(){this.shadowRoot&&this.isDense&&(this.buttons=[...this.shadowRoot.querySelectorAll("button")],setTimeout(()=>{this.animateTabs(0,!0)},0))}iconTemplate(e){return e.icon?c`<wui-icon size="xs" color="inherit" name=${e.icon}></wui-icon>`:null}onTabClick(e){this.buttons&&this.animateTabs(e,!1),this.activeTab=e,this.onTabChange(e)}animateTabs(e,i){const n=this.buttons[this.activeTab],o=this.buttons[e],t=n==null?void 0:n.querySelector("wui-text"),a=o==null?void 0:o.querySelector("wui-text"),s=o==null?void 0:o.getBoundingClientRect(),l=a==null?void 0:a.getBoundingClientRect();n&&t&&!i&&e!==this.activeTab&&(t.animate([{opacity:0}],{duration:50,easing:"ease",fill:"forwards"}),n.animate([{width:"34px"}],{duration:500,easing:"ease",fill:"forwards"})),o&&s&&l&&a&&(e!==this.activeTab||i)&&(this.localTabWidth=`${Math.round(s.width+l.width)+6}px`,o.animate([{width:`${s.width+l.width}px`}],{duration:i?0:500,fill:"forwards",easing:"ease"}),a.animate([{opacity:1}],{duration:i?0:125,delay:i?0:200,fill:"forwards",easing:"ease"}))}};ee.styles=[A,M,tn];fe([u({type:Array})],ee.prototype,"tabs",void 0);fe([u()],ee.prototype,"onTabChange",void 0);fe([u({type:Array})],ee.prototype,"buttons",void 0);fe([u({type:Boolean})],ee.prototype,"disabled",void 0);fe([u()],ee.prototype,"localTabWidth",void 0);fe([v()],ee.prototype,"activeTab",void 0);fe([v()],ee.prototype,"isDense",void 0);ee=fe([C("wui-tabs")],ee);var Xt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ot=class extends I{constructor(){super(...arguments),this.platformTabs=[],this.unsubscribe=[],this.platforms=[],this.onSelectPlatfrom=void 0}disconnectCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.generateTabs();return c`
497
+ `})}firstUpdated(){this.shadowRoot&&this.isDense&&(this.buttons=[...this.shadowRoot.querySelectorAll("button")],setTimeout(()=>{this.animateTabs(0,!0)},0))}iconTemplate(e){return e.icon?c`<wui-icon size="xs" color="inherit" name=${e.icon}></wui-icon>`:null}onTabClick(e){this.buttons&&this.animateTabs(e,!1),this.activeTab=e,this.onTabChange(e)}animateTabs(e,i){const n=this.buttons[this.activeTab],o=this.buttons[e],t=n==null?void 0:n.querySelector("wui-text"),a=o==null?void 0:o.querySelector("wui-text"),s=o==null?void 0:o.getBoundingClientRect(),l=a==null?void 0:a.getBoundingClientRect();n&&t&&!i&&e!==this.activeTab&&(t.animate([{opacity:0}],{duration:50,easing:"ease",fill:"forwards"}),n.animate([{width:"34px"}],{duration:500,easing:"ease",fill:"forwards"})),o&&s&&l&&a&&(e!==this.activeTab||i)&&(this.localTabWidth=`${Math.round(s.width+l.width)+6}px`,o.animate([{width:`${s.width+l.width}px`}],{duration:i?0:500,fill:"forwards",easing:"ease"}),a.animate([{opacity:1}],{duration:i?0:125,delay:i?0:200,fill:"forwards",easing:"ease"}))}};re.styles=[q,G,Bn];ve([u({type:Array})],re.prototype,"tabs",void 0);ve([u()],re.prototype,"onTabChange",void 0);ve([u({type:Array})],re.prototype,"buttons",void 0);ve([u({type:Boolean})],re.prototype,"disabled",void 0);ve([u()],re.prototype,"localTabWidth",void 0);ve([_()],re.prototype,"activeTab",void 0);ve([_()],re.prototype,"isDense",void 0);re=ve([B("wui-tabs")],re);var di=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let rt=class extends O{constructor(){super(...arguments),this.platformTabs=[],this.unsubscribe=[],this.platforms=[],this.onSelectPlatfrom=void 0}disconnectCallback(){this.unsubscribe.forEach(e=>e())}render(){const e=this.generateTabs();return c`
498
498
  <wui-flex justifyContent="center" .padding=${["0","0","l","0"]}>
499
499
  <wui-tabs .tabs=${e} .onTabChange=${this.onTabChange.bind(this)}></wui-tabs>
500
500
  </wui-flex>
501
- `}generateTabs(){const e=this.platforms.map(i=>i==="browser"?{label:"Browser",icon:"extension",platform:"browser"}:i==="mobile"?{label:"Mobile",icon:"mobile",platform:"mobile"}:i==="qrcode"?{label:"Mobile",icon:"mobile",platform:"qrcode"}:i==="web"?{label:"Webapp",icon:"browser",platform:"web"}:i==="desktop"?{label:"Desktop",icon:"desktop",platform:"desktop"}:{label:"Browser",icon:"extension",platform:"unsupported"});return this.platformTabs=e.map(({platform:i})=>i),e}onTabChange(e){var n;const i=this.platformTabs[e];i&&((n=this.onSelectPlatfrom)==null||n.call(this,i))}};Xt([u({type:Array})],ot.prototype,"platforms",void 0);Xt([u()],ot.prototype,"onSelectPlatfrom",void 0);ot=Xt([C("w3m-connecting-header")],ot);const nn=P`
501
+ `}generateTabs(){const e=this.platforms.map(i=>i==="browser"?{label:"Browser",icon:"extension",platform:"browser"}:i==="mobile"?{label:"Mobile",icon:"mobile",platform:"mobile"}:i==="qrcode"?{label:"Mobile",icon:"mobile",platform:"qrcode"}:i==="web"?{label:"Webapp",icon:"browser",platform:"web"}:i==="desktop"?{label:"Desktop",icon:"desktop",platform:"desktop"}:{label:"Browser",icon:"extension",platform:"unsupported"});return this.platformTabs=e.map(({platform:i})=>i),e}onTabChange(e){var n;const i=this.platformTabs[e];i&&((n=this.onSelectPlatfrom)==null||n.call(this,i))}};di([u({type:Array})],rt.prototype,"platforms",void 0);di([u()],rt.prototype,"onSelectPlatfrom",void 0);rt=di([B("w3m-connecting-header")],rt);const Ln=N`
502
502
  :host {
503
503
  width: var(--local-width);
504
504
  position: relative;
@@ -693,12 +693,12 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
693
693
  transform: translate(-50%, -50%);
694
694
  opacity: var(--local-opacity-000);
695
695
  }
696
- `;var te=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const ci={main:"inverse-100",inverse:"inverse-000",accent:"accent-100","accent-error":"error-100","accent-success":"success-100",neutral:"fg-100",disabled:"gray-glass-020"},on={lg:"paragraph-600",md:"small-600"},rn={lg:"md",md:"md"};let q=class extends I{constructor(){super(...arguments),this.size="lg",this.disabled=!1,this.fullWidth=!1,this.loading=!1,this.variant="main",this.hasIconLeft=!1,this.hasIconRight=!1,this.borderRadius="m"}render(){this.style.cssText=`
696
+ `;var ae=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const xi={main:"inverse-100",inverse:"inverse-000",accent:"accent-100","accent-error":"error-100","accent-success":"success-100",neutral:"fg-100",disabled:"gray-glass-020"},On={lg:"paragraph-600",md:"small-600"},An={lg:"md",md:"md"};let Q=class extends O{constructor(){super(...arguments),this.size="lg",this.disabled=!1,this.fullWidth=!1,this.loading=!1,this.variant="main",this.hasIconLeft=!1,this.hasIconRight=!1,this.borderRadius="m"}render(){this.style.cssText=`
697
697
  --local-width: ${this.fullWidth?"100%":"auto"};
698
698
  --local-opacity-100: ${this.loading?0:1};
699
699
  --local-opacity-000: ${this.loading?1:0};
700
700
  --local-border-radius: var(--wui-border-radius-${this.borderRadius});
701
- `;const e=this.textVariant??on[this.size];return c`
701
+ `;const e=this.textVariant??On[this.size];return c`
702
702
  <button
703
703
  data-variant=${this.variant}
704
704
  data-icon-left=${this.hasIconLeft}
@@ -713,7 +713,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
713
713
  </wui-text>
714
714
  <slot name="iconRight" @slotchange=${()=>this.handleSlotRightChange()}></slot>
715
715
  </button>
716
- `}handleSlotLeftChange(){this.hasIconLeft=!0}handleSlotRightChange(){this.hasIconRight=!0}loadingTemplate(){if(this.loading){const e=rn[this.size],i=this.disabled?ci.disabled:ci[this.variant];return c`<wui-loading-spinner color=${i} size=${e}></wui-loading-spinner>`}return c``}};q.styles=[A,M,nn];te([u()],q.prototype,"size",void 0);te([u({type:Boolean})],q.prototype,"disabled",void 0);te([u({type:Boolean})],q.prototype,"fullWidth",void 0);te([u({type:Boolean})],q.prototype,"loading",void 0);te([u()],q.prototype,"variant",void 0);te([u({type:Boolean})],q.prototype,"hasIconLeft",void 0);te([u({type:Boolean})],q.prototype,"hasIconRight",void 0);te([u()],q.prototype,"borderRadius",void 0);te([u()],q.prototype,"textVariant",void 0);q=te([C("wui-button")],q);const an=P`
716
+ `}handleSlotLeftChange(){this.hasIconLeft=!0}handleSlotRightChange(){this.hasIconRight=!0}loadingTemplate(){if(this.loading){const e=An[this.size],i=this.disabled?xi.disabled:xi[this.variant];return c`<wui-loading-spinner color=${i} size=${e}></wui-loading-spinner>`}return c``}};Q.styles=[q,G,Ln];ae([u()],Q.prototype,"size",void 0);ae([u({type:Boolean})],Q.prototype,"disabled",void 0);ae([u({type:Boolean})],Q.prototype,"fullWidth",void 0);ae([u({type:Boolean})],Q.prototype,"loading",void 0);ae([u()],Q.prototype,"variant",void 0);ae([u({type:Boolean})],Q.prototype,"hasIconLeft",void 0);ae([u({type:Boolean})],Q.prototype,"hasIconRight",void 0);ae([u()],Q.prototype,"borderRadius",void 0);ae([u()],Q.prototype,"textVariant",void 0);Q=ae([B("wui-button")],Q);const kn=N`
717
717
  button {
718
718
  padding: var(--wui-spacing-4xs) var(--wui-spacing-xxs);
719
719
  border-radius: var(--wui-border-radius-3xs);
@@ -729,15 +729,15 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
729
729
  button:hover {
730
730
  background-color: var(--wui-color-gray-glass-005);
731
731
  }
732
- `;var yt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let $e=class extends I{constructor(){super(...arguments),this.tabIdx=void 0,this.disabled=!1,this.color="inherit"}render(){return c`
733
- <button ?disabled=${this.disabled} tabindex=${y(this.tabIdx)}>
732
+ `;var vt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Pe=class extends O{constructor(){super(...arguments),this.tabIdx=void 0,this.disabled=!1,this.color="inherit"}render(){return c`
733
+ <button ?disabled=${this.disabled} tabindex=${E(this.tabIdx)}>
734
734
  <slot name="iconLeft"></slot>
735
735
  <wui-text variant="small-600" color=${this.color}>
736
736
  <slot></slot>
737
737
  </wui-text>
738
738
  <slot name="iconRight"></slot>
739
739
  </button>
740
- `}};$e.styles=[A,M,an];yt([u()],$e.prototype,"tabIdx",void 0);yt([u({type:Boolean})],$e.prototype,"disabled",void 0);yt([u()],$e.prototype,"color",void 0);$e=yt([C("wui-link")],$e);const sn=P`
740
+ `}};Pe.styles=[q,G,kn];vt([u()],Pe.prototype,"tabIdx",void 0);vt([u({type:Boolean})],Pe.prototype,"disabled",void 0);vt([u()],Pe.prototype,"color",void 0);Pe=vt([B("wui-link")],Pe);const jn=N`
741
741
  :host {
742
742
  display: block;
743
743
  width: var(--wui-box-size-md);
@@ -762,7 +762,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
762
762
  stroke-dashoffset: 0px;
763
763
  }
764
764
  }
765
- `;var Ci=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let rt=class extends I{constructor(){super(...arguments),this.radius=36}render(){return this.svgLoaderTemplate()}svgLoaderTemplate(){const e=this.radius>50?50:this.radius,n=36-e,o=116+n,t=245+n,a=360+n*1.75;return c`
765
+ `;var sn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let at=class extends O{constructor(){super(...arguments),this.radius=36}render(){return this.svgLoaderTemplate()}svgLoaderTemplate(){const e=this.radius>50?50:this.radius,n=36-e,o=116+n,t=245+n,a=360+n*1.75;return c`
766
766
  <svg viewBox="0 0 110 110" width="110" height="110">
767
767
  <rect
768
768
  x="2"
@@ -774,7 +774,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
774
774
  stroke-dashoffset=${a}
775
775
  />
776
776
  </svg>
777
- `}};rt.styles=[A,sn];Ci([u({type:Number})],rt.prototype,"radius",void 0);rt=Ci([C("wui-loading-thumbnail")],rt);const ln=P`
777
+ `}};at.styles=[q,jn];sn([u({type:Number})],at.prototype,"radius",void 0);at=sn([B("wui-loading-thumbnail")],at);const Dn=N`
778
778
  button {
779
779
  border: none;
780
780
  border-radius: var(--wui-border-radius-3xl);
@@ -893,7 +893,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
893
893
  box-shadow: inset 0 0 0 1px var(--wui-color-gray-glass-002);
894
894
  pointer-events: none;
895
895
  }
896
- `;var Ce=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ce=class extends I{constructor(){super(...arguments),this.variant="accent",this.imageSrc="",this.disabled=!1,this.icon="externalLink",this.size="md",this.text=""}render(){const e=this.size==="sm"?"small-600":"paragraph-600";return c`
896
+ `;var Ie=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let pe=class extends O{constructor(){super(...arguments),this.variant="accent",this.imageSrc="",this.disabled=!1,this.icon="externalLink",this.size="md",this.text=""}render(){const e=this.size==="sm"?"small-600":"paragraph-600";return c`
897
897
  <button
898
898
  class=${this.disabled?"disabled":""}
899
899
  data-variant=${this.variant}
@@ -903,13 +903,13 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
903
903
  <wui-text variant=${e} color="inherit"> ${this.text} </wui-text>
904
904
  <wui-icon name=${this.icon} color="inherit" size="inherit"></wui-icon>
905
905
  </button>
906
- `}};ce.styles=[A,M,ln];Ce([u()],ce.prototype,"variant",void 0);Ce([u()],ce.prototype,"imageSrc",void 0);Ce([u({type:Boolean})],ce.prototype,"disabled",void 0);Ce([u()],ce.prototype,"icon",void 0);Ce([u()],ce.prototype,"size",void 0);Ce([u()],ce.prototype,"text",void 0);ce=Ce([C("wui-chip-button")],ce);const cn=P`
906
+ `}};pe.styles=[q,G,Dn];Ie([u()],pe.prototype,"variant",void 0);Ie([u()],pe.prototype,"imageSrc",void 0);Ie([u({type:Boolean})],pe.prototype,"disabled",void 0);Ie([u()],pe.prototype,"icon",void 0);Ie([u()],pe.prototype,"size",void 0);Ie([u()],pe.prototype,"text",void 0);pe=Ie([B("wui-chip-button")],pe);const zn=N`
907
907
  wui-flex {
908
908
  width: 100%;
909
909
  background-color: var(--wui-color-gray-glass-002);
910
910
  border-radius: var(--wui-border-radius-xs);
911
911
  }
912
- `;var xt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Re=class extends I{constructor(){super(...arguments),this.disabled=!1,this.label="",this.buttonLabel=""}render(){return c`
912
+ `;var yt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Be=class extends O{constructor(){super(...arguments),this.disabled=!1,this.label="",this.buttonLabel=""}render(){return c`
913
913
  <wui-flex
914
914
  justifyContent="space-between"
915
915
  alignItems="center"
@@ -919,36 +919,36 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
919
919
  <wui-chip-button size="sm" variant="shade" text=${this.buttonLabel} icon="chevronRight">
920
920
  </wui-chip-button>
921
921
  </wui-flex>
922
- `}};Re.styles=[A,M,cn];xt([u({type:Boolean})],Re.prototype,"disabled",void 0);xt([u()],Re.prototype,"label",void 0);xt([u()],Re.prototype,"buttonLabel",void 0);Re=xt([C("wui-cta-button")],Re);const un=P`
922
+ `}};Be.styles=[q,G,zn];yt([u({type:Boolean})],Be.prototype,"disabled",void 0);yt([u()],Be.prototype,"label",void 0);yt([u()],Be.prototype,"buttonLabel",void 0);Be=yt([B("wui-cta-button")],Be);const Nn=N`
923
923
  :host {
924
924
  display: block;
925
925
  padding: 0 var(--wui-spacing-xl) var(--wui-spacing-xl);
926
926
  }
927
- `;var $i=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let at=class extends I{constructor(){super(...arguments),this.wallet=void 0}render(){if(!this.wallet)return this.style.display="none",null;const{name:e,app_store:i,play_store:n,chrome_store:o,homepage:t}=this.wallet,a=E.isMobile(),s=E.isIos(),l=E.isAndroid(),h=[i,n,t,o].filter(Boolean).length>1,d=se.getTruncateString({string:e,charsStart:12,charsEnd:0,truncate:"end"});return h&&!a?c`
927
+ `;var ln=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let st=class extends O{constructor(){super(...arguments),this.wallet=void 0}render(){if(!this.wallet)return this.style.display="none",null;const{name:e,app_store:i,play_store:n,chrome_store:o,homepage:t}=this.wallet,a=k.isMobile(),s=k.isIos(),l=k.isAndroid(),d=[i,n,t,o].filter(Boolean).length>1,h=he.getTruncateString({string:e,charsStart:12,charsEnd:0,truncate:"end"});return d&&!a?c`
928
928
  <wui-cta-button
929
- label=${`Don't have ${d}?`}
929
+ label=${`Don't have ${h}?`}
930
930
  buttonLabel="Get"
931
- @click=${()=>O.push("Downloads",{wallet:this.wallet})}
931
+ @click=${()=>U.push("Downloads",{wallet:this.wallet})}
932
932
  ></wui-cta-button>
933
- `:!h&&t?c`
933
+ `:!d&&t?c`
934
934
  <wui-cta-button
935
- label=${`Don't have ${d}?`}
935
+ label=${`Don't have ${h}?`}
936
936
  buttonLabel="Get"
937
937
  @click=${this.onHomePage.bind(this)}
938
938
  ></wui-cta-button>
939
939
  `:i&&s?c`
940
940
  <wui-cta-button
941
- label=${`Don't have ${d}?`}
941
+ label=${`Don't have ${h}?`}
942
942
  buttonLabel="Get"
943
943
  @click=${this.onAppStore.bind(this)}
944
944
  ></wui-cta-button>
945
945
  `:n&&l?c`
946
946
  <wui-cta-button
947
- label=${`Don't have ${d}?`}
947
+ label=${`Don't have ${h}?`}
948
948
  buttonLabel="Get"
949
949
  @click=${this.onPlayStore.bind(this)}
950
950
  ></wui-cta-button>
951
- `:(this.style.display="none",null)}onAppStore(){var e;(e=this.wallet)!=null&&e.app_store&&E.openHref(this.wallet.app_store,"_blank")}onPlayStore(){var e;(e=this.wallet)!=null&&e.play_store&&E.openHref(this.wallet.play_store,"_blank")}onHomePage(){var e;(e=this.wallet)!=null&&e.homepage&&E.openHref(this.wallet.homepage,"_blank")}};at.styles=[un];$i([u({type:Object})],at.prototype,"wallet",void 0);at=$i([C("w3m-mobile-download-links")],at);const dn=P`
951
+ `:(this.style.display="none",null)}onAppStore(){var e;(e=this.wallet)!=null&&e.app_store&&k.openHref(this.wallet.app_store,"_blank")}onPlayStore(){var e;(e=this.wallet)!=null&&e.play_store&&k.openHref(this.wallet.play_store,"_blank")}onHomePage(){var e;(e=this.wallet)!=null&&e.homepage&&k.openHref(this.wallet.homepage,"_blank")}};st.styles=[Nn];ln([u({type:Object})],st.prototype,"wallet",void 0);st=ln([B("w3m-mobile-download-links")],st);const Mn=N`
952
952
  @keyframes shake {
953
953
  0% {
954
954
  transform: translateX(0);
@@ -1009,9 +1009,9 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
1009
1009
  display: block;
1010
1010
  opacity: 1;
1011
1011
  }
1012
- `;var ie=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};class z extends I{constructor(){var e,i,n,o,t;super(),this.wallet=(e=O.state.data)==null?void 0:e.wallet,this.connector=(i=O.state.data)==null?void 0:i.connector,this.timeout=void 0,this.secondaryBtnIcon="refresh",this.onConnect=void 0,this.onRender=void 0,this.onAutoConnect=void 0,this.isWalletConnect=!0,this.unsubscribe=[],this.imageSrc=D.getWalletImage(this.wallet)??D.getConnectorImage(this.connector),this.name=((n=this.wallet)==null?void 0:n.name)??((o=this.connector)==null?void 0:o.name)??"Wallet",this.isRetrying=!1,this.uri=S.state.wcUri,this.error=S.state.wcError,this.ready=!1,this.showRetry=!1,this.secondaryBtnLabel="Try again",this.secondaryLabel="Accept connection request in the wallet",this.isLoading=!1,this.isMobile=!1,this.onRetry=void 0,this.unsubscribe.push(S.subscribeKey("wcUri",a=>{var s;this.uri=a,this.isRetrying&&this.onRetry&&(this.isRetrying=!1,(s=this.onConnect)==null||s.call(this))}),S.subscribeKey("wcError",a=>this.error=a)),(E.isTelegram()||E.isSafari())&&E.isIos()&&S.state.wcUri&&((t=this.onConnect)==null||t.call(this))}firstUpdated(){var e;(e=this.onAutoConnect)==null||e.call(this),this.showRetry=!this.onAutoConnect}disconnectedCallback(){this.unsubscribe.forEach(e=>e()),S.setWcError(!1),clearTimeout(this.timeout)}render(){var n;(n=this.onRender)==null||n.call(this),this.onShowRetry();const e=this.error?"Connection can be declined if a previous request is still active":this.secondaryLabel;let i=`Continue in ${this.name}`;return this.error&&(i="Connection declined"),c`
1012
+ `;var se=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};class V extends O{constructor(){var e,i,n,o,t;super(),this.wallet=(e=U.state.data)==null?void 0:e.wallet,this.connector=(i=U.state.data)==null?void 0:i.connector,this.timeout=void 0,this.secondaryBtnIcon="refresh",this.onConnect=void 0,this.onRender=void 0,this.onAutoConnect=void 0,this.isWalletConnect=!0,this.unsubscribe=[],this.imageSrc=K.getWalletImage(this.wallet)??K.getConnectorImage(this.connector),this.name=((n=this.wallet)==null?void 0:n.name)??((o=this.connector)==null?void 0:o.name)??"Wallet",this.isRetrying=!1,this.uri=j.state.wcUri,this.error=j.state.wcError,this.ready=!1,this.showRetry=!1,this.secondaryBtnLabel="Try again",this.secondaryLabel="Accept connection request in the wallet",this.isLoading=!1,this.isMobile=!1,this.onRetry=void 0,this.unsubscribe.push(j.subscribeKey("wcUri",a=>{var s;this.uri=a,this.isRetrying&&this.onRetry&&(this.isRetrying=!1,(s=this.onConnect)==null||s.call(this))}),j.subscribeKey("wcError",a=>this.error=a)),(k.isTelegram()||k.isSafari())&&k.isIos()&&j.state.wcUri&&((t=this.onConnect)==null||t.call(this))}firstUpdated(){var e;(e=this.onAutoConnect)==null||e.call(this),this.showRetry=!this.onAutoConnect}disconnectedCallback(){this.unsubscribe.forEach(e=>e()),j.setWcError(!1),clearTimeout(this.timeout)}render(){var n;(n=this.onRender)==null||n.call(this),this.onShowRetry();const e=this.error?"Connection can be declined if a previous request is still active":this.secondaryLabel;let i=`Continue in ${this.name}`;return this.error&&(i="Connection declined"),c`
1013
1013
  <wui-flex
1014
- data-error=${y(this.error)}
1014
+ data-error=${E(this.error)}
1015
1015
  data-retry=${this.showRetry}
1016
1016
  flexDirection="column"
1017
1017
  alignItems="center"
@@ -1019,7 +1019,7 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
1019
1019
  gap="xl"
1020
1020
  >
1021
1021
  <wui-flex justifyContent="center" alignItems="center">
1022
- <wui-wallet-image size="lg" imageSrc=${y(this.imageSrc)}></wui-wallet-image>
1022
+ <wui-wallet-image size="lg" imageSrc=${E(this.imageSrc)}></wui-wallet-image>
1023
1023
 
1024
1024
  ${this.error?null:this.loaderTemplate()}
1025
1025
 
@@ -1065,36 +1065,36 @@ import{u as P,s as M,y as A,v as I,p as c,g as L,c as T,O as Y,l as E,m as J,R a
1065
1065
  `:null}
1066
1066
 
1067
1067
  <w3m-mobile-download-links .wallet=${this.wallet}></w3m-mobile-download-links>
1068
- `}onShowRetry(){var e;if(this.error&&!this.showRetry){this.showRetry=!0;const i=(e=this.shadowRoot)==null?void 0:e.querySelector("wui-button");i==null||i.animate([{opacity:0},{opacity:1}],{fill:"forwards",easing:"ease"})}}onTryAgain(){var e,i;S.setWcError(!1),this.onRetry?(this.isRetrying=!0,(e=this.onRetry)==null||e.call(this)):(i=this.onConnect)==null||i.call(this)}loaderTemplate(){const e=kt.state.themeVariables["--w3m-border-radius-master"],i=e?parseInt(e.replace("px",""),10):4;return c`<wui-loading-thumbnail radius=${i*9}></wui-loading-thumbnail>`}onCopyUri(){try{this.uri&&(E.copyToClopboard(this.uri),Qe.showSuccess("Link copied"))}catch{Qe.showError("Failed to copy")}}}z.styles=dn;ie([v()],z.prototype,"isRetrying",void 0);ie([v()],z.prototype,"uri",void 0);ie([v()],z.prototype,"error",void 0);ie([v()],z.prototype,"ready",void 0);ie([v()],z.prototype,"showRetry",void 0);ie([v()],z.prototype,"secondaryBtnLabel",void 0);ie([v()],z.prototype,"secondaryLabel",void 0);ie([v()],z.prototype,"isLoading",void 0);ie([u({type:Boolean})],z.prototype,"isMobile",void 0);ie([u()],z.prototype,"onRetry",void 0);var hn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ui=class extends z{constructor(){if(super(),!this.wallet)throw new Error("w3m-connecting-wc-browser: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.onAutoConnect=this.onConnectProxy.bind(this),J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"browser"}})}async onConnectProxy(){var e;try{this.error=!1;const{connectors:i}=L.state,n=i.find(o=>{var t,a,s;return o.type==="ANNOUNCED"&&((t=o.info)==null?void 0:t.rdns)===((a=this.wallet)==null?void 0:a.rdns)||o.type==="INJECTED"||o.name===((s=this.wallet)==null?void 0:s.name)});if(n)await S.connectExternal(n,n.chain);else throw new Error("w3m-connecting-wc-browser: No connector found");vi.close(),J.sendEvent({type:"track",event:"CONNECT_SUCCESS",properties:{method:"browser",name:((e=this.wallet)==null?void 0:e.name)||"Unknown"}})}catch(i){J.sendEvent({type:"track",event:"CONNECT_ERROR",properties:{message:(i==null?void 0:i.message)??"Unknown"}}),this.error=!0}}};ui=hn([C("w3m-connecting-wc-browser")],ui);var pn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let di=class extends z{constructor(){if(super(),!this.wallet)throw new Error("w3m-connecting-wc-desktop: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.onRender=this.onRenderProxy.bind(this),J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"desktop"}})}onRenderProxy(){var e;!this.ready&&this.uri&&(this.ready=!0,(e=this.onConnect)==null||e.call(this))}onConnectProxy(){var e;if((e=this.wallet)!=null&&e.desktop_link&&this.uri)try{this.error=!1;const{desktop_link:i,name:n}=this.wallet,{redirect:o,href:t}=E.formatNativeUrl(i,this.uri);S.setWcLinking({name:n,href:t}),S.setRecentWallet(this.wallet),E.openHref(o,"_blank")}catch{this.error=!0}}};di=pn([C("w3m-connecting-wc-desktop")],di);var Le=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let me=class extends z{constructor(){if(super(),this.btnLabelTimeout=void 0,this.redirectDeeplink=void 0,this.redirectUniversalLink=void 0,this.target=void 0,this.preferUniversalLinks=Y.state.experimental_preferUniversalLinks,this.isLoading=!0,this.onConnect=()=>{var e;if((e=this.wallet)!=null&&e.mobile_link&&this.uri)try{this.error=!1;const{mobile_link:i,link_mode:n,name:o}=this.wallet,{redirect:t,redirectUniversalLink:a,href:s}=E.formatNativeUrl(i,this.uri,n);this.redirectDeeplink=t,this.redirectUniversalLink=a,this.target=E.isIframe()?"_top":"_self",S.setWcLinking({name:o,href:s}),S.setRecentWallet(this.wallet),this.preferUniversalLinks&&this.redirectUniversalLink?E.openHref(this.redirectUniversalLink,this.target):E.openHref(this.redirectDeeplink,this.target)}catch(i){J.sendEvent({type:"track",event:"CONNECT_PROXY_ERROR",properties:{message:i instanceof Error?i.message:"Error parsing the deeplink",uri:this.uri,mobile_link:this.wallet.mobile_link,name:this.wallet.name}}),this.error=!0}},!this.wallet)throw new Error("w3m-connecting-wc-mobile: No wallet provided");this.secondaryBtnLabel="Open",this.secondaryLabel=yi.CONNECT_LABELS.MOBILE,this.secondaryBtnIcon="externalLink",this.onHandleURI(),this.unsubscribe.push(S.subscribeKey("wcUri",()=>{this.onHandleURI()})),J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"mobile"}})}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.btnLabelTimeout)}onHandleURI(){var e;this.isLoading=!this.uri,!this.ready&&this.uri&&(this.ready=!0,(e=this.onConnect)==null||e.call(this))}onTryAgain(){var e;S.setWcError(!1),(e=this.onConnect)==null||e.call(this)}};Le([v()],me.prototype,"redirectDeeplink",void 0);Le([v()],me.prototype,"redirectUniversalLink",void 0);Le([v()],me.prototype,"target",void 0);Le([v()],me.prototype,"preferUniversalLinks",void 0);Le([v()],me.prototype,"isLoading",void 0);me=Le([C("w3m-connecting-wc-mobile")],me);var Ve={},fn=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},Ri={},V={};let Zt;const gn=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];V.getSymbolSize=function(e){if(!e)throw new Error('"version" cannot be null or undefined');if(e<1||e>40)throw new Error('"version" should be in range from 1 to 40');return e*4+17};V.getSymbolTotalCodewords=function(e){return gn[e]};V.getBCHDigit=function(r){let e=0;for(;r!==0;)e++,r>>>=1;return e};V.setToSJISFunction=function(e){if(typeof e!="function")throw new Error('"toSJISFunc" is not a valid function.');Zt=e};V.isKanjiModeEnabled=function(){return typeof Zt<"u"};V.toSJIS=function(e){return Zt(e)};var Ct={};(function(r){r.L={bit:1},r.M={bit:0},r.Q={bit:3},r.H={bit:2};function e(i){if(typeof i!="string")throw new Error("Param is not a string");switch(i.toLowerCase()){case"l":case"low":return r.L;case"m":case"medium":return r.M;case"q":case"quartile":return r.Q;case"h":case"high":return r.H;default:throw new Error("Unknown EC Level: "+i)}}r.isValid=function(n){return n&&typeof n.bit<"u"&&n.bit>=0&&n.bit<4},r.from=function(n,o){if(r.isValid(n))return n;try{return e(n)}catch{return o}}})(Ct);function _i(){this.buffer=[],this.length=0}_i.prototype={get:function(r){const e=Math.floor(r/8);return(this.buffer[e]>>>7-r%8&1)===1},put:function(r,e){for(let i=0;i<e;i++)this.putBit((r>>>e-i-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(r){const e=Math.floor(this.length/8);this.buffer.length<=e&&this.buffer.push(0),r&&(this.buffer[e]|=128>>>this.length%8),this.length++}};var wn=_i;function qe(r){if(!r||r<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=r,this.data=new Uint8Array(r*r),this.reservedBit=new Uint8Array(r*r)}qe.prototype.set=function(r,e,i,n){const o=r*this.size+e;this.data[o]=i,n&&(this.reservedBit[o]=!0)};qe.prototype.get=function(r,e){return this.data[r*this.size+e]};qe.prototype.xor=function(r,e,i){this.data[r*this.size+e]^=i};qe.prototype.isReserved=function(r,e){return this.reservedBit[r*this.size+e]};var bn=qe,Ii={};(function(r){const e=V.getSymbolSize;r.getRowColCoords=function(n){if(n===1)return[];const o=Math.floor(n/7)+2,t=e(n),a=t===145?26:Math.ceil((t-13)/(2*o-2))*2,s=[t-7];for(let l=1;l<o-1;l++)s[l]=s[l-1]-a;return s.push(6),s.reverse()},r.getPositions=function(n){const o=[],t=r.getRowColCoords(n),a=t.length;for(let s=0;s<a;s++)for(let l=0;l<a;l++)s===0&&l===0||s===0&&l===a-1||s===a-1&&l===0||o.push([t[s],t[l]]);return o}})(Ii);var Ei={};const mn=V.getSymbolSize,hi=7;Ei.getPositions=function(e){const i=mn(e);return[[0,0],[i-hi,0],[0,i-hi]]};var Wi={};(function(r){r.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const e={N1:3,N2:3,N3:40,N4:10};r.isValid=function(o){return o!=null&&o!==""&&!isNaN(o)&&o>=0&&o<=7},r.from=function(o){return r.isValid(o)?parseInt(o,10):void 0},r.getPenaltyN1=function(o){const t=o.size;let a=0,s=0,l=0,h=null,d=null;for(let _=0;_<t;_++){s=l=0,h=d=null;for(let x=0;x<t;x++){let m=o.get(_,x);m===h?s++:(s>=5&&(a+=e.N1+(s-5)),h=m,s=1),m=o.get(x,_),m===d?l++:(l>=5&&(a+=e.N1+(l-5)),d=m,l=1)}s>=5&&(a+=e.N1+(s-5)),l>=5&&(a+=e.N1+(l-5))}return a},r.getPenaltyN2=function(o){const t=o.size;let a=0;for(let s=0;s<t-1;s++)for(let l=0;l<t-1;l++){const h=o.get(s,l)+o.get(s,l+1)+o.get(s+1,l)+o.get(s+1,l+1);(h===4||h===0)&&a++}return a*e.N2},r.getPenaltyN3=function(o){const t=o.size;let a=0,s=0,l=0;for(let h=0;h<t;h++){s=l=0;for(let d=0;d<t;d++)s=s<<1&2047|o.get(h,d),d>=10&&(s===1488||s===93)&&a++,l=l<<1&2047|o.get(d,h),d>=10&&(l===1488||l===93)&&a++}return a*e.N3},r.getPenaltyN4=function(o){let t=0;const a=o.data.length;for(let l=0;l<a;l++)t+=o.data[l];return Math.abs(Math.ceil(t*100/a/5)-10)*e.N4};function i(n,o,t){switch(n){case r.Patterns.PATTERN000:return(o+t)%2===0;case r.Patterns.PATTERN001:return o%2===0;case r.Patterns.PATTERN010:return t%3===0;case r.Patterns.PATTERN011:return(o+t)%3===0;case r.Patterns.PATTERN100:return(Math.floor(o/2)+Math.floor(t/3))%2===0;case r.Patterns.PATTERN101:return o*t%2+o*t%3===0;case r.Patterns.PATTERN110:return(o*t%2+o*t%3)%2===0;case r.Patterns.PATTERN111:return(o*t%3+(o+t)%2)%2===0;default:throw new Error("bad maskPattern:"+n)}}r.applyMask=function(o,t){const a=t.size;for(let s=0;s<a;s++)for(let l=0;l<a;l++)t.isReserved(l,s)||t.xor(l,s,i(o,l,s))},r.getBestMask=function(o,t){const a=Object.keys(r.Patterns).length;let s=0,l=1/0;for(let h=0;h<a;h++){t(h),r.applyMask(h,o);const d=r.getPenaltyN1(o)+r.getPenaltyN2(o)+r.getPenaltyN3(o)+r.getPenaltyN4(o);r.applyMask(h,o),d<l&&(l=d,s=h)}return s}})(Wi);var $t={};const he=Ct,Ye=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],Je=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];$t.getBlocksCount=function(e,i){switch(i){case he.L:return Ye[(e-1)*4+0];case he.M:return Ye[(e-1)*4+1];case he.Q:return Ye[(e-1)*4+2];case he.H:return Ye[(e-1)*4+3];default:return}};$t.getTotalCodewordsCount=function(e,i){switch(i){case he.L:return Je[(e-1)*4+0];case he.M:return Je[(e-1)*4+1];case he.Q:return Je[(e-1)*4+2];case he.H:return Je[(e-1)*4+3];default:return}};var Si={},Rt={};const je=new Uint8Array(512),st=new Uint8Array(256);(function(){let e=1;for(let i=0;i<255;i++)je[i]=e,st[e]=i,e<<=1,e&256&&(e^=285);for(let i=255;i<512;i++)je[i]=je[i-255]})();Rt.log=function(e){if(e<1)throw new Error("log("+e+")");return st[e]};Rt.exp=function(e){return je[e]};Rt.mul=function(e,i){return e===0||i===0?0:je[st[e]+st[i]]};(function(r){const e=Rt;r.mul=function(n,o){const t=new Uint8Array(n.length+o.length-1);for(let a=0;a<n.length;a++)for(let s=0;s<o.length;s++)t[a+s]^=e.mul(n[a],o[s]);return t},r.mod=function(n,o){let t=new Uint8Array(n);for(;t.length-o.length>=0;){const a=t[0];for(let l=0;l<o.length;l++)t[l]^=e.mul(o[l],a);let s=0;for(;s<t.length&&t[s]===0;)s++;t=t.slice(s)}return t},r.generateECPolynomial=function(n){let o=new Uint8Array([1]);for(let t=0;t<n;t++)o=r.mul(o,new Uint8Array([1,e.exp(t)]));return o}})(Si);const Ti=Si;function ei(r){this.genPoly=void 0,this.degree=r,this.degree&&this.initialize(this.degree)}ei.prototype.initialize=function(e){this.degree=e,this.genPoly=Ti.generateECPolynomial(this.degree)};ei.prototype.encode=function(e){if(!this.genPoly)throw new Error("Encoder not initialized");const i=new Uint8Array(e.length+this.degree);i.set(e);const n=Ti.mod(i,this.genPoly),o=this.degree-n.length;if(o>0){const t=new Uint8Array(this.degree);return t.set(n,o),t}return n};var vn=ei,Pi={},ge={},ti={};ti.isValid=function(e){return!isNaN(e)&&e>=1&&e<=40};var ne={};const Li="[0-9]+",yn="[A-Z $%*+\\-./:]+";let Ue="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";Ue=Ue.replace(/u/g,"\\u");const xn="(?:(?![A-Z0-9 $%*+\\-./:]|"+Ue+`)(?:.|[\r
1069
- ]))+`;ne.KANJI=new RegExp(Ue,"g");ne.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g");ne.BYTE=new RegExp(xn,"g");ne.NUMERIC=new RegExp(Li,"g");ne.ALPHANUMERIC=new RegExp(yn,"g");const Cn=new RegExp("^"+Ue+"$"),$n=new RegExp("^"+Li+"$"),Rn=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");ne.testKanji=function(e){return Cn.test(e)};ne.testNumeric=function(e){return $n.test(e)};ne.testAlphanumeric=function(e){return Rn.test(e)};(function(r){const e=ti,i=ne;r.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},r.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},r.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},r.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},r.MIXED={bit:-1},r.getCharCountIndicator=function(t,a){if(!t.ccBits)throw new Error("Invalid mode: "+t);if(!e.isValid(a))throw new Error("Invalid version: "+a);return a>=1&&a<10?t.ccBits[0]:a<27?t.ccBits[1]:t.ccBits[2]},r.getBestModeForData=function(t){return i.testNumeric(t)?r.NUMERIC:i.testAlphanumeric(t)?r.ALPHANUMERIC:i.testKanji(t)?r.KANJI:r.BYTE},r.toString=function(t){if(t&&t.id)return t.id;throw new Error("Invalid mode")},r.isValid=function(t){return t&&t.bit&&t.ccBits};function n(o){if(typeof o!="string")throw new Error("Param is not a string");switch(o.toLowerCase()){case"numeric":return r.NUMERIC;case"alphanumeric":return r.ALPHANUMERIC;case"kanji":return r.KANJI;case"byte":return r.BYTE;default:throw new Error("Unknown mode: "+o)}}r.from=function(t,a){if(r.isValid(t))return t;try{return n(t)}catch{return a}}})(ge);(function(r){const e=V,i=$t,n=Ct,o=ge,t=ti,a=7973,s=e.getBCHDigit(a);function l(x,m,$){for(let b=1;b<=40;b++)if(m<=r.getCapacity(b,$,x))return b}function h(x,m){return o.getCharCountIndicator(x,m)+4}function d(x,m){let $=0;return x.forEach(function(b){const R=h(b.mode,m);$+=R+b.getBitsLength()}),$}function _(x,m){for(let $=1;$<=40;$++)if(d(x,$)<=r.getCapacity($,m,o.MIXED))return $}r.from=function(m,$){return t.isValid(m)?parseInt(m,10):$},r.getCapacity=function(m,$,b){if(!t.isValid(m))throw new Error("Invalid QR Code version");typeof b>"u"&&(b=o.BYTE);const R=e.getSymbolTotalCodewords(m),g=i.getTotalCodewordsCount(m,$),f=(R-g)*8;if(b===o.MIXED)return f;const w=f-h(b,m);switch(b){case o.NUMERIC:return Math.floor(w/10*3);case o.ALPHANUMERIC:return Math.floor(w/11*2);case o.KANJI:return Math.floor(w/13);case o.BYTE:default:return Math.floor(w/8)}},r.getBestVersionForData=function(m,$){let b;const R=n.from($,n.M);if(Array.isArray(m)){if(m.length>1)return _(m,R);if(m.length===0)return 1;b=m[0]}else b=m;return l(b.mode,b.getLength(),R)},r.getEncodedBits=function(m){if(!t.isValid(m)||m<7)throw new Error("Invalid QR Code version");let $=m<<12;for(;e.getBCHDigit($)-s>=0;)$^=a<<e.getBCHDigit($)-s;return m<<12|$}})(Pi);var Bi={};const zt=V,Oi=1335,_n=21522,pi=zt.getBCHDigit(Oi);Bi.getEncodedBits=function(e,i){const n=e.bit<<3|i;let o=n<<10;for(;zt.getBCHDigit(o)-pi>=0;)o^=Oi<<zt.getBCHDigit(o)-pi;return(n<<10|o)^_n};var Ai={};const In=ge;function _e(r){this.mode=In.NUMERIC,this.data=r.toString()}_e.getBitsLength=function(e){return 10*Math.floor(e/3)+(e%3?e%3*3+1:0)};_e.prototype.getLength=function(){return this.data.length};_e.prototype.getBitsLength=function(){return _e.getBitsLength(this.data.length)};_e.prototype.write=function(e){let i,n,o;for(i=0;i+3<=this.data.length;i+=3)n=this.data.substr(i,3),o=parseInt(n,10),e.put(o,10);const t=this.data.length-i;t>0&&(n=this.data.substr(i),o=parseInt(n,10),e.put(o,t*3+1))};var En=_e;const Wn=ge,St=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function Ie(r){this.mode=Wn.ALPHANUMERIC,this.data=r}Ie.getBitsLength=function(e){return 11*Math.floor(e/2)+6*(e%2)};Ie.prototype.getLength=function(){return this.data.length};Ie.prototype.getBitsLength=function(){return Ie.getBitsLength(this.data.length)};Ie.prototype.write=function(e){let i;for(i=0;i+2<=this.data.length;i+=2){let n=St.indexOf(this.data[i])*45;n+=St.indexOf(this.data[i+1]),e.put(n,11)}this.data.length%2&&e.put(St.indexOf(this.data[i]),6)};var Sn=Ie,Tn=function(e){for(var i=[],n=e.length,o=0;o<n;o++){var t=e.charCodeAt(o);if(t>=55296&&t<=56319&&n>o+1){var a=e.charCodeAt(o+1);a>=56320&&a<=57343&&(t=(t-55296)*1024+a-56320+65536,o+=1)}if(t<128){i.push(t);continue}if(t<2048){i.push(t>>6|192),i.push(t&63|128);continue}if(t<55296||t>=57344&&t<65536){i.push(t>>12|224),i.push(t>>6&63|128),i.push(t&63|128);continue}if(t>=65536&&t<=1114111){i.push(t>>18|240),i.push(t>>12&63|128),i.push(t>>6&63|128),i.push(t&63|128);continue}i.push(239,191,189)}return new Uint8Array(i).buffer};const Pn=Tn,Ln=ge;function Ee(r){this.mode=Ln.BYTE,typeof r=="string"&&(r=Pn(r)),this.data=new Uint8Array(r)}Ee.getBitsLength=function(e){return e*8};Ee.prototype.getLength=function(){return this.data.length};Ee.prototype.getBitsLength=function(){return Ee.getBitsLength(this.data.length)};Ee.prototype.write=function(r){for(let e=0,i=this.data.length;e<i;e++)r.put(this.data[e],8)};var Bn=Ee;const On=ge,An=V;function We(r){this.mode=On.KANJI,this.data=r}We.getBitsLength=function(e){return e*13};We.prototype.getLength=function(){return this.data.length};We.prototype.getBitsLength=function(){return We.getBitsLength(this.data.length)};We.prototype.write=function(r){let e;for(e=0;e<this.data.length;e++){let i=An.toSJIS(this.data[e]);if(i>=33088&&i<=40956)i-=33088;else if(i>=57408&&i<=60351)i-=49472;else throw new Error("Invalid SJIS character: "+this.data[e]+`
1070
- Make sure your charset is UTF-8`);i=(i>>>8&255)*192+(i&255),r.put(i,13)}};var jn=We,ji={exports:{}};(function(r){var e={single_source_shortest_paths:function(i,n,o){var t={},a={};a[n]=0;var s=e.PriorityQueue.make();s.push(n,0);for(var l,h,d,_,x,m,$,b,R;!s.empty();){l=s.pop(),h=l.value,_=l.cost,x=i[h]||{};for(d in x)x.hasOwnProperty(d)&&(m=x[d],$=_+m,b=a[d],R=typeof a[d]>"u",(R||b>$)&&(a[d]=$,s.push(d,$),t[d]=h))}if(typeof o<"u"&&typeof a[o]>"u"){var g=["Could not find a path from ",n," to ",o,"."].join("");throw new Error(g)}return t},extract_shortest_path_from_predecessor_list:function(i,n){for(var o=[],t=n;t;)o.push(t),i[t],t=i[t];return o.reverse(),o},find_path:function(i,n,o){var t=e.single_source_shortest_paths(i,n,o);return e.extract_shortest_path_from_predecessor_list(t,o)},PriorityQueue:{make:function(i){var n=e.PriorityQueue,o={},t;i=i||{};for(t in n)n.hasOwnProperty(t)&&(o[t]=n[t]);return o.queue=[],o.sorter=i.sorter||n.default_sorter,o},default_sorter:function(i,n){return i.cost-n.cost},push:function(i,n){var o={value:i,cost:n};this.queue.push(o),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};r.exports=e})(ji);var kn=ji.exports;(function(r){const e=ge,i=En,n=Sn,o=Bn,t=jn,a=ne,s=V,l=kn;function h(g){return unescape(encodeURIComponent(g)).length}function d(g,f,w){const p=[];let W;for(;(W=g.exec(w))!==null;)p.push({data:W[0],index:W.index,mode:f,length:W[0].length});return p}function _(g){const f=d(a.NUMERIC,e.NUMERIC,g),w=d(a.ALPHANUMERIC,e.ALPHANUMERIC,g);let p,W;return s.isKanjiModeEnabled()?(p=d(a.BYTE,e.BYTE,g),W=d(a.KANJI,e.KANJI,g)):(p=d(a.BYTE_KANJI,e.BYTE,g),W=[]),f.concat(w,p,W).sort(function(j,G){return j.index-G.index}).map(function(j){return{data:j.data,mode:j.mode,length:j.length}})}function x(g,f){switch(f){case e.NUMERIC:return i.getBitsLength(g);case e.ALPHANUMERIC:return n.getBitsLength(g);case e.KANJI:return t.getBitsLength(g);case e.BYTE:return o.getBitsLength(g)}}function m(g){return g.reduce(function(f,w){const p=f.length-1>=0?f[f.length-1]:null;return p&&p.mode===w.mode?(f[f.length-1].data+=w.data,f):(f.push(w),f)},[])}function $(g){const f=[];for(let w=0;w<g.length;w++){const p=g[w];switch(p.mode){case e.NUMERIC:f.push([p,{data:p.data,mode:e.ALPHANUMERIC,length:p.length},{data:p.data,mode:e.BYTE,length:p.length}]);break;case e.ALPHANUMERIC:f.push([p,{data:p.data,mode:e.BYTE,length:p.length}]);break;case e.KANJI:f.push([p,{data:p.data,mode:e.BYTE,length:h(p.data)}]);break;case e.BYTE:f.push([{data:p.data,mode:e.BYTE,length:h(p.data)}])}}return f}function b(g,f){const w={},p={start:{}};let W=["start"];for(let B=0;B<g.length;B++){const j=g[B],G=[];for(let de=0;de<j.length;de++){const Z=j[de],Oe=""+B+de;G.push(Oe),w[Oe]={node:Z,lastCount:0},p[Oe]={};for(let Et=0;Et<W.length;Et++){const re=W[Et];w[re]&&w[re].node.mode===Z.mode?(p[re][Oe]=x(w[re].lastCount+Z.length,Z.mode)-x(w[re].lastCount,Z.mode),w[re].lastCount+=Z.length):(w[re]&&(w[re].lastCount=Z.length),p[re][Oe]=x(Z.length,Z.mode)+4+e.getCharCountIndicator(Z.mode,f))}}W=G}for(let B=0;B<W.length;B++)p[W[B]].end=0;return{map:p,table:w}}function R(g,f){let w;const p=e.getBestModeForData(g);if(w=e.from(f,p),w!==e.BYTE&&w.bit<p.bit)throw new Error('"'+g+'" cannot be encoded with mode '+e.toString(w)+`.
1071
- Suggested mode is: `+e.toString(p));switch(w===e.KANJI&&!s.isKanjiModeEnabled()&&(w=e.BYTE),w){case e.NUMERIC:return new i(g);case e.ALPHANUMERIC:return new n(g);case e.KANJI:return new t(g);case e.BYTE:return new o(g)}}r.fromArray=function(f){return f.reduce(function(w,p){return typeof p=="string"?w.push(R(p,null)):p.data&&w.push(R(p.data,p.mode)),w},[])},r.fromString=function(f,w){const p=_(f,s.isKanjiModeEnabled()),W=$(p),B=b(W,w),j=l.find_path(B.map,"start","end"),G=[];for(let de=1;de<j.length-1;de++)G.push(B.table[j[de]].node);return r.fromArray(m(G))},r.rawSplit=function(f){return r.fromArray(_(f,s.isKanjiModeEnabled()))}})(Ai);const _t=V,Tt=Ct,zn=wn,Dn=bn,Nn=Ii,Mn=Ei,Dt=Wi,Nt=$t,Un=vn,lt=Pi,Fn=Bi,Vn=ge,Pt=Ai;function qn(r,e){const i=r.size,n=Mn.getPositions(e);for(let o=0;o<n.length;o++){const t=n[o][0],a=n[o][1];for(let s=-1;s<=7;s++)if(!(t+s<=-1||i<=t+s))for(let l=-1;l<=7;l++)a+l<=-1||i<=a+l||(s>=0&&s<=6&&(l===0||l===6)||l>=0&&l<=6&&(s===0||s===6)||s>=2&&s<=4&&l>=2&&l<=4?r.set(t+s,a+l,!0,!0):r.set(t+s,a+l,!1,!0))}}function Hn(r){const e=r.size;for(let i=8;i<e-8;i++){const n=i%2===0;r.set(i,6,n,!0),r.set(6,i,n,!0)}}function Kn(r,e){const i=Nn.getPositions(e);for(let n=0;n<i.length;n++){const o=i[n][0],t=i[n][1];for(let a=-2;a<=2;a++)for(let s=-2;s<=2;s++)a===-2||a===2||s===-2||s===2||a===0&&s===0?r.set(o+a,t+s,!0,!0):r.set(o+a,t+s,!1,!0)}}function Gn(r,e){const i=r.size,n=lt.getEncodedBits(e);let o,t,a;for(let s=0;s<18;s++)o=Math.floor(s/3),t=s%3+i-8-3,a=(n>>s&1)===1,r.set(o,t,a,!0),r.set(t,o,a,!0)}function Lt(r,e,i){const n=r.size,o=Fn.getEncodedBits(e,i);let t,a;for(t=0;t<15;t++)a=(o>>t&1)===1,t<6?r.set(t,8,a,!0):t<8?r.set(t+1,8,a,!0):r.set(n-15+t,8,a,!0),t<8?r.set(8,n-t-1,a,!0):t<9?r.set(8,15-t-1+1,a,!0):r.set(8,15-t-1,a,!0);r.set(n-8,8,1,!0)}function Yn(r,e){const i=r.size;let n=-1,o=i-1,t=7,a=0;for(let s=i-1;s>0;s-=2)for(s===6&&s--;;){for(let l=0;l<2;l++)if(!r.isReserved(o,s-l)){let h=!1;a<e.length&&(h=(e[a]>>>t&1)===1),r.set(o,s-l,h),t--,t===-1&&(a++,t=7)}if(o+=n,o<0||i<=o){o-=n,n=-n;break}}}function Jn(r,e,i){const n=new zn;i.forEach(function(l){n.put(l.mode.bit,4),n.put(l.getLength(),Vn.getCharCountIndicator(l.mode,r)),l.write(n)});const o=_t.getSymbolTotalCodewords(r),t=Nt.getTotalCodewordsCount(r,e),a=(o-t)*8;for(n.getLengthInBits()+4<=a&&n.put(0,4);n.getLengthInBits()%8!==0;)n.putBit(0);const s=(a-n.getLengthInBits())/8;for(let l=0;l<s;l++)n.put(l%2?17:236,8);return Qn(n,r,e)}function Qn(r,e,i){const n=_t.getSymbolTotalCodewords(e),o=Nt.getTotalCodewordsCount(e,i),t=n-o,a=Nt.getBlocksCount(e,i),s=n%a,l=a-s,h=Math.floor(n/a),d=Math.floor(t/a),_=d+1,x=h-d,m=new Un(x);let $=0;const b=new Array(a),R=new Array(a);let g=0;const f=new Uint8Array(r.buffer);for(let j=0;j<a;j++){const G=j<l?d:_;b[j]=f.slice($,$+G),R[j]=m.encode(b[j]),$+=G,g=Math.max(g,G)}const w=new Uint8Array(n);let p=0,W,B;for(W=0;W<g;W++)for(B=0;B<a;B++)W<b[B].length&&(w[p++]=b[B][W]);for(W=0;W<x;W++)for(B=0;B<a;B++)w[p++]=R[B][W];return w}function Xn(r,e,i,n){let o;if(Array.isArray(r))o=Pt.fromArray(r);else if(typeof r=="string"){let h=e;if(!h){const d=Pt.rawSplit(r);h=lt.getBestVersionForData(d,i)}o=Pt.fromString(r,h||40)}else throw new Error("Invalid data");const t=lt.getBestVersionForData(o,i);if(!t)throw new Error("The amount of data is too big to be stored in a QR Code");if(!e)e=t;else if(e<t)throw new Error(`
1068
+ `}onShowRetry(){var e;if(this.error&&!this.showRetry){this.showRetry=!0;const i=(e=this.shadowRoot)==null?void 0:e.querySelector("wui-button");i==null||i.animate([{opacity:0},{opacity:1}],{fill:"forwards",easing:"ease"})}}onTryAgain(){var e,i;j.setWcError(!1),this.onRetry?(this.isRetrying=!0,(e=this.onRetry)==null||e.call(this)):(i=this.onConnect)==null||i.call(this)}loaderTemplate(){const e=ei.state.themeVariables["--w3m-border-radius-master"],i=e?parseInt(e.replace("px",""),10):4;return c`<wui-loading-thumbnail radius=${i*9}></wui-loading-thumbnail>`}onCopyUri(){try{this.uri&&(k.copyToClopboard(this.uri),Xe.showSuccess("Link copied"))}catch{Xe.showError("Failed to copy")}}}V.styles=Mn;se([_()],V.prototype,"isRetrying",void 0);se([_()],V.prototype,"uri",void 0);se([_()],V.prototype,"error",void 0);se([_()],V.prototype,"ready",void 0);se([_()],V.prototype,"showRetry",void 0);se([_()],V.prototype,"secondaryBtnLabel",void 0);se([_()],V.prototype,"secondaryLabel",void 0);se([_()],V.prototype,"isLoading",void 0);se([u({type:Boolean})],V.prototype,"isMobile",void 0);se([u()],V.prototype,"onRetry",void 0);var Un=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ci=class extends V{constructor(){if(super(),!this.wallet)throw new Error("w3m-connecting-wc-browser: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.onAutoConnect=this.onConnectProxy.bind(this),te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"browser"}})}async onConnectProxy(){var e;try{this.error=!1;const{connectors:i}=M.state,n=i.find(o=>{var t,a,s;return o.type==="ANNOUNCED"&&((t=o.info)==null?void 0:t.rdns)===((a=this.wallet)==null?void 0:a.rdns)||o.type==="INJECTED"||o.name===((s=this.wallet)==null?void 0:s.name)});if(n)await j.connectExternal(n,n.chain);else throw new Error("w3m-connecting-wc-browser: No connector found");on.close(),te.sendEvent({type:"track",event:"CONNECT_SUCCESS",properties:{method:"browser",name:((e=this.wallet)==null?void 0:e.name)||"Unknown"}})}catch(i){te.sendEvent({type:"track",event:"CONNECT_ERROR",properties:{message:(i==null?void 0:i.message)??"Unknown"}}),this.error=!0}}};Ci=Un([B("w3m-connecting-wc-browser")],Ci);var qn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let $i=class extends V{constructor(){if(super(),!this.wallet)throw new Error("w3m-connecting-wc-desktop: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.onRender=this.onRenderProxy.bind(this),te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"desktop"}})}onRenderProxy(){var e;!this.ready&&this.uri&&(this.ready=!0,(e=this.onConnect)==null||e.call(this))}onConnectProxy(){var e;if((e=this.wallet)!=null&&e.desktop_link&&this.uri)try{this.error=!1;const{desktop_link:i,name:n}=this.wallet,{redirect:o,href:t}=k.formatNativeUrl(i,this.uri);j.setWcLinking({name:n,href:t}),j.setRecentWallet(this.wallet),k.openHref(o,"_blank")}catch{this.error=!0}}};$i=qn([B("w3m-connecting-wc-desktop")],$i);var ke=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ce=class extends V{constructor(){if(super(),this.btnLabelTimeout=void 0,this.redirectDeeplink=void 0,this.redirectUniversalLink=void 0,this.target=void 0,this.preferUniversalLinks=ee.state.experimental_preferUniversalLinks,this.isLoading=!0,this.onConnect=()=>{var e;if((e=this.wallet)!=null&&e.mobile_link&&this.uri)try{this.error=!1;const{mobile_link:i,link_mode:n,name:o}=this.wallet,{redirect:t,redirectUniversalLink:a,href:s}=k.formatNativeUrl(i,this.uri,n);this.redirectDeeplink=t,this.redirectUniversalLink=a,this.target=k.isIframe()?"_top":"_self",j.setWcLinking({name:o,href:s}),j.setRecentWallet(this.wallet),this.preferUniversalLinks&&this.redirectUniversalLink?k.openHref(this.redirectUniversalLink,this.target):k.openHref(this.redirectDeeplink,this.target)}catch(i){te.sendEvent({type:"track",event:"CONNECT_PROXY_ERROR",properties:{message:i instanceof Error?i.message:"Error parsing the deeplink",uri:this.uri,mobile_link:this.wallet.mobile_link,name:this.wallet.name}}),this.error=!0}},!this.wallet)throw new Error("w3m-connecting-wc-mobile: No wallet provided");this.secondaryBtnLabel="Open",this.secondaryLabel=rn.CONNECT_LABELS.MOBILE,this.secondaryBtnIcon="externalLink",this.onHandleURI(),this.unsubscribe.push(j.subscribeKey("wcUri",()=>{this.onHandleURI()})),te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"mobile"}})}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.btnLabelTimeout)}onHandleURI(){var e;this.isLoading=!this.uri,!this.ready&&this.uri&&(this.ready=!0,(e=this.onConnect)==null||e.call(this))}onTryAgain(){var e;j.setWcError(!1),(e=this.onConnect)==null||e.call(this)}};ke([_()],Ce.prototype,"redirectDeeplink",void 0);ke([_()],Ce.prototype,"redirectUniversalLink",void 0);ke([_()],Ce.prototype,"target",void 0);ke([_()],Ce.prototype,"preferUniversalLinks",void 0);ke([_()],Ce.prototype,"isLoading",void 0);Ce=ke([B("w3m-connecting-wc-mobile")],Ce);var Te={},Et,Ri;function Fn(){return Ri||(Ri=1,Et=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then}),Et}var Wt={},be={},_i;function Ee(){if(_i)return be;_i=1;let r;const e=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];return be.getSymbolSize=function(n){if(!n)throw new Error('"version" cannot be null or undefined');if(n<1||n>40)throw new Error('"version" should be in range from 1 to 40');return n*4+17},be.getSymbolTotalCodewords=function(n){return e[n]},be.getBCHDigit=function(i){let n=0;for(;i!==0;)n++,i>>>=1;return n},be.setToSJISFunction=function(n){if(typeof n!="function")throw new Error('"toSJISFunc" is not a valid function.');r=n},be.isKanjiModeEnabled=function(){return typeof r<"u"},be.toSJIS=function(n){return r(n)},be}var St={},Ii;function hi(){return Ii||(Ii=1,(function(r){r.L={bit:1},r.M={bit:0},r.Q={bit:3},r.H={bit:2};function e(i){if(typeof i!="string")throw new Error("Param is not a string");switch(i.toLowerCase()){case"l":case"low":return r.L;case"m":case"medium":return r.M;case"q":case"quartile":return r.Q;case"h":case"high":return r.H;default:throw new Error("Unknown EC Level: "+i)}}r.isValid=function(n){return n&&typeof n.bit<"u"&&n.bit>=0&&n.bit<4},r.from=function(n,o){if(r.isValid(n))return n;try{return e(n)}catch{return o}}})(St)),St}var Tt,Ei;function Vn(){if(Ei)return Tt;Ei=1;function r(){this.buffer=[],this.length=0}return r.prototype={get:function(e){const i=Math.floor(e/8);return(this.buffer[i]>>>7-e%8&1)===1},put:function(e,i){for(let n=0;n<i;n++)this.putBit((e>>>i-n-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const i=Math.floor(this.length/8);this.buffer.length<=i&&this.buffer.push(0),e&&(this.buffer[i]|=128>>>this.length%8),this.length++}},Tt=r,Tt}var Pt,Wi;function Kn(){if(Wi)return Pt;Wi=1;function r(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}return r.prototype.set=function(e,i,n,o){const t=e*this.size+i;this.data[t]=n,o&&(this.reservedBit[t]=!0)},r.prototype.get=function(e,i){return this.data[e*this.size+i]},r.prototype.xor=function(e,i,n){this.data[e*this.size+i]^=n},r.prototype.isReserved=function(e,i){return this.reservedBit[e*this.size+i]},Pt=r,Pt}var Bt={},Si;function Hn(){return Si||(Si=1,(function(r){const e=Ee().getSymbolSize;r.getRowColCoords=function(n){if(n===1)return[];const o=Math.floor(n/7)+2,t=e(n),a=t===145?26:Math.ceil((t-13)/(2*o-2))*2,s=[t-7];for(let l=1;l<o-1;l++)s[l]=s[l-1]-a;return s.push(6),s.reverse()},r.getPositions=function(n){const o=[],t=r.getRowColCoords(n),a=t.length;for(let s=0;s<a;s++)for(let l=0;l<a;l++)s===0&&l===0||s===0&&l===a-1||s===a-1&&l===0||o.push([t[s],t[l]]);return o}})(Bt)),Bt}var Lt={},Ti;function Gn(){if(Ti)return Lt;Ti=1;const r=Ee().getSymbolSize,e=7;return Lt.getPositions=function(n){const o=r(n);return[[0,0],[o-e,0],[0,o-e]]},Lt}var Ot={},Pi;function Yn(){return Pi||(Pi=1,(function(r){r.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const e={N1:3,N2:3,N3:40,N4:10};r.isValid=function(o){return o!=null&&o!==""&&!isNaN(o)&&o>=0&&o<=7},r.from=function(o){return r.isValid(o)?parseInt(o,10):void 0},r.getPenaltyN1=function(o){const t=o.size;let a=0,s=0,l=0,d=null,h=null;for(let p=0;p<t;p++){s=l=0,d=h=null;for(let x=0;x<t;x++){let g=o.get(p,x);g===d?s++:(s>=5&&(a+=e.N1+(s-5)),d=g,s=1),g=o.get(x,p),g===h?l++:(l>=5&&(a+=e.N1+(l-5)),h=g,l=1)}s>=5&&(a+=e.N1+(s-5)),l>=5&&(a+=e.N1+(l-5))}return a},r.getPenaltyN2=function(o){const t=o.size;let a=0;for(let s=0;s<t-1;s++)for(let l=0;l<t-1;l++){const d=o.get(s,l)+o.get(s,l+1)+o.get(s+1,l)+o.get(s+1,l+1);(d===4||d===0)&&a++}return a*e.N2},r.getPenaltyN3=function(o){const t=o.size;let a=0,s=0,l=0;for(let d=0;d<t;d++){s=l=0;for(let h=0;h<t;h++)s=s<<1&2047|o.get(d,h),h>=10&&(s===1488||s===93)&&a++,l=l<<1&2047|o.get(h,d),h>=10&&(l===1488||l===93)&&a++}return a*e.N3},r.getPenaltyN4=function(o){let t=0;const a=o.data.length;for(let l=0;l<a;l++)t+=o.data[l];return Math.abs(Math.ceil(t*100/a/5)-10)*e.N4};function i(n,o,t){switch(n){case r.Patterns.PATTERN000:return(o+t)%2===0;case r.Patterns.PATTERN001:return o%2===0;case r.Patterns.PATTERN010:return t%3===0;case r.Patterns.PATTERN011:return(o+t)%3===0;case r.Patterns.PATTERN100:return(Math.floor(o/2)+Math.floor(t/3))%2===0;case r.Patterns.PATTERN101:return o*t%2+o*t%3===0;case r.Patterns.PATTERN110:return(o*t%2+o*t%3)%2===0;case r.Patterns.PATTERN111:return(o*t%3+(o+t)%2)%2===0;default:throw new Error("bad maskPattern:"+n)}}r.applyMask=function(o,t){const a=t.size;for(let s=0;s<a;s++)for(let l=0;l<a;l++)t.isReserved(l,s)||t.xor(l,s,i(o,l,s))},r.getBestMask=function(o,t){const a=Object.keys(r.Patterns).length;let s=0,l=1/0;for(let d=0;d<a;d++){t(d),r.applyMask(d,o);const h=r.getPenaltyN1(o)+r.getPenaltyN2(o)+r.getPenaltyN3(o)+r.getPenaltyN4(o);r.applyMask(d,o),h<l&&(l=h,s=d)}return s}})(Ot)),Ot}var Qe={},Bi;function cn(){if(Bi)return Qe;Bi=1;const r=hi(),e=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],i=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];return Qe.getBlocksCount=function(o,t){switch(t){case r.L:return e[(o-1)*4+0];case r.M:return e[(o-1)*4+1];case r.Q:return e[(o-1)*4+2];case r.H:return e[(o-1)*4+3];default:return}},Qe.getTotalCodewordsCount=function(o,t){switch(t){case r.L:return i[(o-1)*4+0];case r.M:return i[(o-1)*4+1];case r.Q:return i[(o-1)*4+2];case r.H:return i[(o-1)*4+3];default:return}},Qe}var At={},ze={},Li;function Jn(){if(Li)return ze;Li=1;const r=new Uint8Array(512),e=new Uint8Array(256);return(function(){let n=1;for(let o=0;o<255;o++)r[o]=n,e[n]=o,n<<=1,n&256&&(n^=285);for(let o=255;o<512;o++)r[o]=r[o-255]})(),ze.log=function(n){if(n<1)throw new Error("log("+n+")");return e[n]},ze.exp=function(n){return r[n]},ze.mul=function(n,o){return n===0||o===0?0:r[e[n]+e[o]]},ze}var Oi;function Qn(){return Oi||(Oi=1,(function(r){const e=Jn();r.mul=function(n,o){const t=new Uint8Array(n.length+o.length-1);for(let a=0;a<n.length;a++)for(let s=0;s<o.length;s++)t[a+s]^=e.mul(n[a],o[s]);return t},r.mod=function(n,o){let t=new Uint8Array(n);for(;t.length-o.length>=0;){const a=t[0];for(let l=0;l<o.length;l++)t[l]^=e.mul(o[l],a);let s=0;for(;s<t.length&&t[s]===0;)s++;t=t.slice(s)}return t},r.generateECPolynomial=function(n){let o=new Uint8Array([1]);for(let t=0;t<n;t++)o=r.mul(o,new Uint8Array([1,e.exp(t)]));return o}})(At)),At}var kt,Ai;function Xn(){if(Ai)return kt;Ai=1;const r=Qn();function e(i){this.genPoly=void 0,this.degree=i,this.degree&&this.initialize(this.degree)}return e.prototype.initialize=function(n){this.degree=n,this.genPoly=r.generateECPolynomial(this.degree)},e.prototype.encode=function(n){if(!this.genPoly)throw new Error("Encoder not initialized");const o=new Uint8Array(n.length+this.degree);o.set(n);const t=r.mod(o,this.genPoly),a=this.degree-t.length;if(a>0){const s=new Uint8Array(this.degree);return s.set(t,a),s}return t},kt=e,kt}var jt={},Dt={},zt={},ki;function un(){return ki||(ki=1,zt.isValid=function(e){return!isNaN(e)&&e>=1&&e<=40}),zt}var oe={},ji;function dn(){if(ji)return oe;ji=1;const r="[0-9]+",e="[A-Z $%*+\\-./:]+";let i="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";i=i.replace(/u/g,"\\u");const n="(?:(?![A-Z0-9 $%*+\\-./:]|"+i+`)(?:.|[\r
1069
+ ]))+`;oe.KANJI=new RegExp(i,"g"),oe.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),oe.BYTE=new RegExp(n,"g"),oe.NUMERIC=new RegExp(r,"g"),oe.ALPHANUMERIC=new RegExp(e,"g");const o=new RegExp("^"+i+"$"),t=new RegExp("^"+r+"$"),a=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");return oe.testKanji=function(l){return o.test(l)},oe.testNumeric=function(l){return t.test(l)},oe.testAlphanumeric=function(l){return a.test(l)},oe}var Di;function We(){return Di||(Di=1,(function(r){const e=un(),i=dn();r.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},r.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},r.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},r.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},r.MIXED={bit:-1},r.getCharCountIndicator=function(t,a){if(!t.ccBits)throw new Error("Invalid mode: "+t);if(!e.isValid(a))throw new Error("Invalid version: "+a);return a>=1&&a<10?t.ccBits[0]:a<27?t.ccBits[1]:t.ccBits[2]},r.getBestModeForData=function(t){return i.testNumeric(t)?r.NUMERIC:i.testAlphanumeric(t)?r.ALPHANUMERIC:i.testKanji(t)?r.KANJI:r.BYTE},r.toString=function(t){if(t&&t.id)return t.id;throw new Error("Invalid mode")},r.isValid=function(t){return t&&t.bit&&t.ccBits};function n(o){if(typeof o!="string")throw new Error("Param is not a string");switch(o.toLowerCase()){case"numeric":return r.NUMERIC;case"alphanumeric":return r.ALPHANUMERIC;case"kanji":return r.KANJI;case"byte":return r.BYTE;default:throw new Error("Unknown mode: "+o)}}r.from=function(t,a){if(r.isValid(t))return t;try{return n(t)}catch{return a}}})(Dt)),Dt}var zi;function Zn(){return zi||(zi=1,(function(r){const e=Ee(),i=cn(),n=hi(),o=We(),t=un(),a=7973,s=e.getBCHDigit(a);function l(x,g,W){for(let v=1;v<=40;v++)if(g<=r.getCapacity(v,W,x))return v}function d(x,g){return o.getCharCountIndicator(x,g)+4}function h(x,g){let W=0;return x.forEach(function(v){const S=d(v.mode,g);W+=S+v.getBitsLength()}),W}function p(x,g){for(let W=1;W<=40;W++)if(h(x,W)<=r.getCapacity(W,g,o.MIXED))return W}r.from=function(g,W){return t.isValid(g)?parseInt(g,10):W},r.getCapacity=function(g,W,v){if(!t.isValid(g))throw new Error("Invalid QR Code version");typeof v>"u"&&(v=o.BYTE);const S=e.getSymbolTotalCodewords(g),b=i.getTotalCodewordsCount(g,W),w=(S-b)*8;if(v===o.MIXED)return w;const m=w-d(v,g);switch(v){case o.NUMERIC:return Math.floor(m/10*3);case o.ALPHANUMERIC:return Math.floor(m/11*2);case o.KANJI:return Math.floor(m/13);case o.BYTE:default:return Math.floor(m/8)}},r.getBestVersionForData=function(g,W){let v;const S=n.from(W,n.M);if(Array.isArray(g)){if(g.length>1)return p(g,S);if(g.length===0)return 1;v=g[0]}else v=g;return l(v.mode,v.getLength(),S)},r.getEncodedBits=function(g){if(!t.isValid(g)||g<7)throw new Error("Invalid QR Code version");let W=g<<12;for(;e.getBCHDigit(W)-s>=0;)W^=a<<e.getBCHDigit(W)-s;return g<<12|W}})(jt)),jt}var Nt={},Ni;function eo(){if(Ni)return Nt;Ni=1;const r=Ee(),e=1335,i=21522,n=r.getBCHDigit(e);return Nt.getEncodedBits=function(t,a){const s=t.bit<<3|a;let l=s<<10;for(;r.getBCHDigit(l)-n>=0;)l^=e<<r.getBCHDigit(l)-n;return(s<<10|l)^i},Nt}var Mt={},Ut,Mi;function to(){if(Mi)return Ut;Mi=1;const r=We();function e(i){this.mode=r.NUMERIC,this.data=i.toString()}return e.getBitsLength=function(n){return 10*Math.floor(n/3)+(n%3?n%3*3+1:0)},e.prototype.getLength=function(){return this.data.length},e.prototype.getBitsLength=function(){return e.getBitsLength(this.data.length)},e.prototype.write=function(n){let o,t,a;for(o=0;o+3<=this.data.length;o+=3)t=this.data.substr(o,3),a=parseInt(t,10),n.put(a,10);const s=this.data.length-o;s>0&&(t=this.data.substr(o),a=parseInt(t,10),n.put(a,s*3+1))},Ut=e,Ut}var qt,Ui;function io(){if(Ui)return qt;Ui=1;const r=We(),e=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function i(n){this.mode=r.ALPHANUMERIC,this.data=n}return i.getBitsLength=function(o){return 11*Math.floor(o/2)+6*(o%2)},i.prototype.getLength=function(){return this.data.length},i.prototype.getBitsLength=function(){return i.getBitsLength(this.data.length)},i.prototype.write=function(o){let t;for(t=0;t+2<=this.data.length;t+=2){let a=e.indexOf(this.data[t])*45;a+=e.indexOf(this.data[t+1]),o.put(a,11)}this.data.length%2&&o.put(e.indexOf(this.data[t]),6)},qt=i,qt}var Ft,qi;function no(){return qi||(qi=1,Ft=function(e){for(var i=[],n=e.length,o=0;o<n;o++){var t=e.charCodeAt(o);if(t>=55296&&t<=56319&&n>o+1){var a=e.charCodeAt(o+1);a>=56320&&a<=57343&&(t=(t-55296)*1024+a-56320+65536,o+=1)}if(t<128){i.push(t);continue}if(t<2048){i.push(t>>6|192),i.push(t&63|128);continue}if(t<55296||t>=57344&&t<65536){i.push(t>>12|224),i.push(t>>6&63|128),i.push(t&63|128);continue}if(t>=65536&&t<=1114111){i.push(t>>18|240),i.push(t>>12&63|128),i.push(t>>6&63|128),i.push(t&63|128);continue}i.push(239,191,189)}return new Uint8Array(i).buffer}),Ft}var Vt,Fi;function oo(){if(Fi)return Vt;Fi=1;const r=no(),e=We();function i(n){this.mode=e.BYTE,typeof n=="string"&&(n=r(n)),this.data=new Uint8Array(n)}return i.getBitsLength=function(o){return o*8},i.prototype.getLength=function(){return this.data.length},i.prototype.getBitsLength=function(){return i.getBitsLength(this.data.length)},i.prototype.write=function(n){for(let o=0,t=this.data.length;o<t;o++)n.put(this.data[o],8)},Vt=i,Vt}var Kt,Vi;function ro(){if(Vi)return Kt;Vi=1;const r=We(),e=Ee();function i(n){this.mode=r.KANJI,this.data=n}return i.getBitsLength=function(o){return o*13},i.prototype.getLength=function(){return this.data.length},i.prototype.getBitsLength=function(){return i.getBitsLength(this.data.length)},i.prototype.write=function(n){let o;for(o=0;o<this.data.length;o++){let t=e.toSJIS(this.data[o]);if(t>=33088&&t<=40956)t-=33088;else if(t>=57408&&t<=60351)t-=49472;else throw new Error("Invalid SJIS character: "+this.data[o]+`
1070
+ Make sure your charset is UTF-8`);t=(t>>>8&255)*192+(t&255),n.put(t,13)}},Kt=i,Kt}var Ht={exports:{}},Ki;function ao(){return Ki||(Ki=1,(function(r){var e={single_source_shortest_paths:function(i,n,o){var t={},a={};a[n]=0;var s=e.PriorityQueue.make();s.push(n,0);for(var l,d,h,p,x,g,W,v,S;!s.empty();){l=s.pop(),d=l.value,p=l.cost,x=i[d]||{};for(h in x)x.hasOwnProperty(h)&&(g=x[h],W=p+g,v=a[h],S=typeof a[h]>"u",(S||v>W)&&(a[h]=W,s.push(h,W),t[h]=d))}if(typeof o<"u"&&typeof a[o]>"u"){var b=["Could not find a path from ",n," to ",o,"."].join("");throw new Error(b)}return t},extract_shortest_path_from_predecessor_list:function(i,n){for(var o=[],t=n;t;)o.push(t),i[t],t=i[t];return o.reverse(),o},find_path:function(i,n,o){var t=e.single_source_shortest_paths(i,n,o);return e.extract_shortest_path_from_predecessor_list(t,o)},PriorityQueue:{make:function(i){var n=e.PriorityQueue,o={},t;i=i||{};for(t in n)n.hasOwnProperty(t)&&(o[t]=n[t]);return o.queue=[],o.sorter=i.sorter||n.default_sorter,o},default_sorter:function(i,n){return i.cost-n.cost},push:function(i,n){var o={value:i,cost:n};this.queue.push(o),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};r.exports=e})(Ht)),Ht.exports}var Hi;function so(){return Hi||(Hi=1,(function(r){const e=We(),i=to(),n=io(),o=oo(),t=ro(),a=dn(),s=Ee(),l=ao();function d(b){return unescape(encodeURIComponent(b)).length}function h(b,w,m){const f=[];let D;for(;(D=b.exec(m))!==null;)f.push({data:D[0],index:D.index,mode:w,length:D[0].length});return f}function p(b){const w=h(a.NUMERIC,e.NUMERIC,b),m=h(a.ALPHANUMERIC,e.ALPHANUMERIC,b);let f,D;return s.isKanjiModeEnabled()?(f=h(a.BYTE,e.BYTE,b),D=h(a.KANJI,e.KANJI,b)):(f=h(a.BYTE_KANJI,e.BYTE,b),D=[]),w.concat(m,f,D).sort(function(T,I){return T.index-I.index}).map(function(T){return{data:T.data,mode:T.mode,length:T.length}})}function x(b,w){switch(w){case e.NUMERIC:return i.getBitsLength(b);case e.ALPHANUMERIC:return n.getBitsLength(b);case e.KANJI:return t.getBitsLength(b);case e.BYTE:return o.getBitsLength(b)}}function g(b){return b.reduce(function(w,m){const f=w.length-1>=0?w[w.length-1]:null;return f&&f.mode===m.mode?(w[w.length-1].data+=m.data,w):(w.push(m),w)},[])}function W(b){const w=[];for(let m=0;m<b.length;m++){const f=b[m];switch(f.mode){case e.NUMERIC:w.push([f,{data:f.data,mode:e.ALPHANUMERIC,length:f.length},{data:f.data,mode:e.BYTE,length:f.length}]);break;case e.ALPHANUMERIC:w.push([f,{data:f.data,mode:e.BYTE,length:f.length}]);break;case e.KANJI:w.push([f,{data:f.data,mode:e.BYTE,length:d(f.data)}]);break;case e.BYTE:w.push([{data:f.data,mode:e.BYTE,length:d(f.data)}])}}return w}function v(b,w){const m={},f={start:{}};let D=["start"];for(let C=0;C<b.length;C++){const T=b[C],I=[];for(let y=0;y<T.length;y++){const L=T[y],$=""+C+y;I.push($),m[$]={node:L,lastCount:0},f[$]={};for(let P=0;P<D.length;P++){const R=D[P];m[R]&&m[R].node.mode===L.mode?(f[R][$]=x(m[R].lastCount+L.length,L.mode)-x(m[R].lastCount,L.mode),m[R].lastCount+=L.length):(m[R]&&(m[R].lastCount=L.length),f[R][$]=x(L.length,L.mode)+4+e.getCharCountIndicator(L.mode,w))}}D=I}for(let C=0;C<D.length;C++)f[D[C]].end=0;return{map:f,table:m}}function S(b,w){let m;const f=e.getBestModeForData(b);if(m=e.from(w,f),m!==e.BYTE&&m.bit<f.bit)throw new Error('"'+b+'" cannot be encoded with mode '+e.toString(m)+`.
1071
+ Suggested mode is: `+e.toString(f));switch(m===e.KANJI&&!s.isKanjiModeEnabled()&&(m=e.BYTE),m){case e.NUMERIC:return new i(b);case e.ALPHANUMERIC:return new n(b);case e.KANJI:return new t(b);case e.BYTE:return new o(b)}}r.fromArray=function(w){return w.reduce(function(m,f){return typeof f=="string"?m.push(S(f,null)):f.data&&m.push(S(f.data,f.mode)),m},[])},r.fromString=function(w,m){const f=p(w,s.isKanjiModeEnabled()),D=W(f),C=v(D,m),T=l.find_path(C.map,"start","end"),I=[];for(let y=1;y<T.length-1;y++)I.push(C.table[T[y]].node);return r.fromArray(g(I))},r.rawSplit=function(w){return r.fromArray(p(w,s.isKanjiModeEnabled()))}})(Mt)),Mt}var Gi;function lo(){if(Gi)return Wt;Gi=1;const r=Ee(),e=hi(),i=Vn(),n=Kn(),o=Hn(),t=Gn(),a=Yn(),s=cn(),l=Xn(),d=Zn(),h=eo(),p=We(),x=so();function g(C,T){const I=C.size,y=t.getPositions(T);for(let L=0;L<y.length;L++){const $=y[L][0],P=y[L][1];for(let R=-1;R<=7;R++)if(!($+R<=-1||I<=$+R))for(let A=-1;A<=7;A++)P+A<=-1||I<=P+A||(R>=0&&R<=6&&(A===0||A===6)||A>=0&&A<=6&&(R===0||R===6)||R>=2&&R<=4&&A>=2&&A<=4?C.set($+R,P+A,!0,!0):C.set($+R,P+A,!1,!0))}}function W(C){const T=C.size;for(let I=8;I<T-8;I++){const y=I%2===0;C.set(I,6,y,!0),C.set(6,I,y,!0)}}function v(C,T){const I=o.getPositions(T);for(let y=0;y<I.length;y++){const L=I[y][0],$=I[y][1];for(let P=-2;P<=2;P++)for(let R=-2;R<=2;R++)P===-2||P===2||R===-2||R===2||P===0&&R===0?C.set(L+P,$+R,!0,!0):C.set(L+P,$+R,!1,!0)}}function S(C,T){const I=C.size,y=d.getEncodedBits(T);let L,$,P;for(let R=0;R<18;R++)L=Math.floor(R/3),$=R%3+I-8-3,P=(y>>R&1)===1,C.set(L,$,P,!0),C.set($,L,P,!0)}function b(C,T,I){const y=C.size,L=h.getEncodedBits(T,I);let $,P;for($=0;$<15;$++)P=(L>>$&1)===1,$<6?C.set($,8,P,!0):$<8?C.set($+1,8,P,!0):C.set(y-15+$,8,P,!0),$<8?C.set(8,y-$-1,P,!0):$<9?C.set(8,15-$-1+1,P,!0):C.set(8,15-$-1,P,!0);C.set(y-8,8,1,!0)}function w(C,T){const I=C.size;let y=-1,L=I-1,$=7,P=0;for(let R=I-1;R>0;R-=2)for(R===6&&R--;;){for(let A=0;A<2;A++)if(!C.isReserved(L,R-A)){let we=!1;P<T.length&&(we=(T[P]>>>$&1)===1),C.set(L,R-A,we),$--,$===-1&&(P++,$=7)}if(L+=y,L<0||I<=L){L-=y,y=-y;break}}}function m(C,T,I){const y=new i;I.forEach(function(A){y.put(A.mode.bit,4),y.put(A.getLength(),p.getCharCountIndicator(A.mode,C)),A.write(y)});const L=r.getSymbolTotalCodewords(C),$=s.getTotalCodewordsCount(C,T),P=(L-$)*8;for(y.getLengthInBits()+4<=P&&y.put(0,4);y.getLengthInBits()%8!==0;)y.putBit(0);const R=(P-y.getLengthInBits())/8;for(let A=0;A<R;A++)y.put(A%2?17:236,8);return f(y,C,T)}function f(C,T,I){const y=r.getSymbolTotalCodewords(T),L=s.getTotalCodewordsCount(T,I),$=y-L,P=s.getBlocksCount(T,I),R=y%P,A=P-R,we=Math.floor(y/P),De=Math.floor($/P),vn=De+1,wi=we-De,yn=new l(wi);let Ct=0;const Je=new Array(P),bi=new Array(P);let $t=0;const xn=new Uint8Array(C.buffer);for(let Se=0;Se<P;Se++){const _t=Se<A?De:vn;Je[Se]=xn.slice(Ct,Ct+_t),bi[Se]=yn.encode(Je[Se]),Ct+=_t,$t=Math.max($t,_t)}const Rt=new Uint8Array(y);let mi=0,ce,ue;for(ce=0;ce<$t;ce++)for(ue=0;ue<P;ue++)ce<Je[ue].length&&(Rt[mi++]=Je[ue][ce]);for(ce=0;ce<wi;ce++)for(ue=0;ue<P;ue++)Rt[mi++]=bi[ue][ce];return Rt}function D(C,T,I,y){let L;if(Array.isArray(C))L=x.fromArray(C);else if(typeof C=="string"){let we=T;if(!we){const De=x.rawSplit(C);we=d.getBestVersionForData(De,I)}L=x.fromString(C,we||40)}else throw new Error("Invalid data");const $=d.getBestVersionForData(L,I);if(!$)throw new Error("The amount of data is too big to be stored in a QR Code");if(!T)T=$;else if(T<$)throw new Error(`
1072
1072
  The chosen QR Code version cannot contain this amount of data.
1073
- Minimum version required to store current data is: `+t+`.
1074
- `);const a=Jn(e,i,o),s=_t.getSymbolSize(e),l=new Dn(s);return qn(l,e),Hn(l),Kn(l,e),Lt(l,i,0),e>=7&&Gn(l,e),Yn(l,a),isNaN(n)&&(n=Dt.getBestMask(l,Lt.bind(null,l,i))),Dt.applyMask(n,l),Lt(l,i,n),{modules:l,version:e,errorCorrectionLevel:i,maskPattern:n,segments:o}}Ri.create=function(e,i){if(typeof e>"u"||e==="")throw new Error("No input text");let n=Tt.M,o,t;return typeof i<"u"&&(n=Tt.from(i.errorCorrectionLevel,Tt.M),o=lt.from(i.version),t=Dt.from(i.maskPattern),i.toSJISFunc&&_t.setToSJISFunction(i.toSJISFunc)),Xn(e,o,n,t)};var ki={},ii={};(function(r){function e(i){if(typeof i=="number"&&(i=i.toString()),typeof i!="string")throw new Error("Color should be defined as hex string");let n=i.slice().replace("#","").split("");if(n.length<3||n.length===5||n.length>8)throw new Error("Invalid hex color: "+i);(n.length===3||n.length===4)&&(n=Array.prototype.concat.apply([],n.map(function(t){return[t,t]}))),n.length===6&&n.push("F","F");const o=parseInt(n.join(""),16);return{r:o>>24&255,g:o>>16&255,b:o>>8&255,a:o&255,hex:"#"+n.slice(0,6).join("")}}r.getOptions=function(n){n||(n={}),n.color||(n.color={});const o=typeof n.margin>"u"||n.margin===null||n.margin<0?4:n.margin,t=n.width&&n.width>=21?n.width:void 0,a=n.scale||4;return{width:t,scale:t?4:a,margin:o,color:{dark:e(n.color.dark||"#000000ff"),light:e(n.color.light||"#ffffffff")},type:n.type,rendererOpts:n.rendererOpts||{}}},r.getScale=function(n,o){return o.width&&o.width>=n+o.margin*2?o.width/(n+o.margin*2):o.scale},r.getImageWidth=function(n,o){const t=r.getScale(n,o);return Math.floor((n+o.margin*2)*t)},r.qrToImageData=function(n,o,t){const a=o.modules.size,s=o.modules.data,l=r.getScale(a,t),h=Math.floor((a+t.margin*2)*l),d=t.margin*l,_=[t.color.light,t.color.dark];for(let x=0;x<h;x++)for(let m=0;m<h;m++){let $=(x*h+m)*4,b=t.color.light;if(x>=d&&m>=d&&x<h-d&&m<h-d){const R=Math.floor((x-d)/l),g=Math.floor((m-d)/l);b=_[s[R*a+g]?1:0]}n[$++]=b.r,n[$++]=b.g,n[$++]=b.b,n[$]=b.a}}})(ii);(function(r){const e=ii;function i(o,t,a){o.clearRect(0,0,t.width,t.height),t.style||(t.style={}),t.height=a,t.width=a,t.style.height=a+"px",t.style.width=a+"px"}function n(){try{return document.createElement("canvas")}catch{throw new Error("You need to specify a canvas element")}}r.render=function(t,a,s){let l=s,h=a;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),a||(h=n()),l=e.getOptions(l);const d=e.getImageWidth(t.modules.size,l),_=h.getContext("2d"),x=_.createImageData(d,d);return e.qrToImageData(x.data,t,l),i(_,h,d),_.putImageData(x,0,0),h},r.renderToDataURL=function(t,a,s){let l=s;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),l||(l={});const h=r.render(t,a,l),d=l.type||"image/png",_=l.rendererOpts||{};return h.toDataURL(d,_.quality)}})(ki);var zi={};const Zn=ii;function fi(r,e){const i=r.a/255,n=e+'="'+r.hex+'"';return i<1?n+" "+e+'-opacity="'+i.toFixed(2).slice(1)+'"':n}function Bt(r,e,i){let n=r+e;return typeof i<"u"&&(n+=" "+i),n}function eo(r,e,i){let n="",o=0,t=!1,a=0;for(let s=0;s<r.length;s++){const l=Math.floor(s%e),h=Math.floor(s/e);!l&&!t&&(t=!0),r[s]?(a++,s>0&&l>0&&r[s-1]||(n+=t?Bt("M",l+i,.5+h+i):Bt("m",o,0),o=0,t=!1),l+1<e&&r[s+1]||(n+=Bt("h",a),a=0)):o++}return n}zi.render=function(e,i,n){const o=Zn.getOptions(i),t=e.modules.size,a=e.modules.data,s=t+o.margin*2,l=o.color.light.a?"<path "+fi(o.color.light,"fill")+' d="M0 0h'+s+"v"+s+'H0z"/>':"",h="<path "+fi(o.color.dark,"stroke")+' d="'+eo(a,t,o.margin)+'"/>',d='viewBox="0 0 '+s+" "+s+'"',x='<svg xmlns="http://www.w3.org/2000/svg" '+(o.width?'width="'+o.width+'" height="'+o.width+'" ':"")+d+' shape-rendering="crispEdges">'+l+h+`</svg>
1075
- `;return typeof n=="function"&&n(null,x),x};const to=fn,Mt=Ri,Di=ki,io=zi;function ni(r,e,i,n,o){const t=[].slice.call(arguments,1),a=t.length,s=typeof t[a-1]=="function";if(!s&&!to())throw new Error("Callback required as last argument");if(s){if(a<2)throw new Error("Too few arguments provided");a===2?(o=i,i=e,e=n=void 0):a===3&&(e.getContext&&typeof o>"u"?(o=n,n=void 0):(o=n,n=i,i=e,e=void 0))}else{if(a<1)throw new Error("Too few arguments provided");return a===1?(i=e,e=n=void 0):a===2&&!e.getContext&&(n=i,i=e,e=void 0),new Promise(function(l,h){try{const d=Mt.create(i,n);l(r(d,e,n))}catch(d){h(d)}})}try{const l=Mt.create(i,n);o(null,r(l,e,n))}catch(l){o(l)}}Ve.create=Mt.create;Ve.toCanvas=ni.bind(null,Di.render);Ve.toDataURL=ni.bind(null,Di.renderToDataURL);Ve.toString=ni.bind(null,function(r,e,i){return io.render(r,i)});const no=.1,gi=2.5,ae=7;function Ot(r,e,i){return r===e?!1:(r-e<0?e-r:r-e)<=i+no}function oo(r,e){const i=Array.prototype.slice.call(Ve.create(r,{errorCorrectionLevel:e}).modules.data,0),n=Math.sqrt(i.length);return i.reduce((o,t,a)=>(a%n===0?o.push([t]):o[o.length-1].push(t))&&o,[])}const ro={generate({uri:r,size:e,logoSize:i,dotColor:n="#141414"}){const o="transparent",a=[],s=oo(r,"Q"),l=e/s.length,h=[{x:0,y:0},{x:1,y:0},{x:0,y:1}];h.forEach(({x:b,y:R})=>{const g=(s.length-ae)*l*b,f=(s.length-ae)*l*R,w=.45;for(let p=0;p<h.length;p+=1){const W=l*(ae-p*2);a.push(Ae`
1073
+ Minimum version required to store current data is: `+$+`.
1074
+ `);const P=m(T,I,L),R=r.getSymbolSize(T),A=new n(R);return g(A,T),W(A),v(A,T),b(A,I,0),T>=7&&S(A,T),w(A,P),isNaN(y)&&(y=a.getBestMask(A,b.bind(null,A,I))),a.applyMask(y,A),b(A,I,y),{modules:A,version:T,errorCorrectionLevel:I,maskPattern:y,segments:L}}return Wt.create=function(T,I){if(typeof T>"u"||T==="")throw new Error("No input text");let y=e.M,L,$;return typeof I<"u"&&(y=e.from(I.errorCorrectionLevel,e.M),L=d.from(I.version),$=a.from(I.maskPattern),I.toSJISFunc&&r.setToSJISFunction(I.toSJISFunc)),D(T,L,y,$)},Wt}var Gt={},Yt={},Yi;function hn(){return Yi||(Yi=1,(function(r){function e(i){if(typeof i=="number"&&(i=i.toString()),typeof i!="string")throw new Error("Color should be defined as hex string");let n=i.slice().replace("#","").split("");if(n.length<3||n.length===5||n.length>8)throw new Error("Invalid hex color: "+i);(n.length===3||n.length===4)&&(n=Array.prototype.concat.apply([],n.map(function(t){return[t,t]}))),n.length===6&&n.push("F","F");const o=parseInt(n.join(""),16);return{r:o>>24&255,g:o>>16&255,b:o>>8&255,a:o&255,hex:"#"+n.slice(0,6).join("")}}r.getOptions=function(n){n||(n={}),n.color||(n.color={});const o=typeof n.margin>"u"||n.margin===null||n.margin<0?4:n.margin,t=n.width&&n.width>=21?n.width:void 0,a=n.scale||4;return{width:t,scale:t?4:a,margin:o,color:{dark:e(n.color.dark||"#000000ff"),light:e(n.color.light||"#ffffffff")},type:n.type,rendererOpts:n.rendererOpts||{}}},r.getScale=function(n,o){return o.width&&o.width>=n+o.margin*2?o.width/(n+o.margin*2):o.scale},r.getImageWidth=function(n,o){const t=r.getScale(n,o);return Math.floor((n+o.margin*2)*t)},r.qrToImageData=function(n,o,t){const a=o.modules.size,s=o.modules.data,l=r.getScale(a,t),d=Math.floor((a+t.margin*2)*l),h=t.margin*l,p=[t.color.light,t.color.dark];for(let x=0;x<d;x++)for(let g=0;g<d;g++){let W=(x*d+g)*4,v=t.color.light;if(x>=h&&g>=h&&x<d-h&&g<d-h){const S=Math.floor((x-h)/l),b=Math.floor((g-h)/l);v=p[s[S*a+b]?1:0]}n[W++]=v.r,n[W++]=v.g,n[W++]=v.b,n[W]=v.a}}})(Yt)),Yt}var Ji;function co(){return Ji||(Ji=1,(function(r){const e=hn();function i(o,t,a){o.clearRect(0,0,t.width,t.height),t.style||(t.style={}),t.height=a,t.width=a,t.style.height=a+"px",t.style.width=a+"px"}function n(){try{return document.createElement("canvas")}catch{throw new Error("You need to specify a canvas element")}}r.render=function(t,a,s){let l=s,d=a;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),a||(d=n()),l=e.getOptions(l);const h=e.getImageWidth(t.modules.size,l),p=d.getContext("2d"),x=p.createImageData(h,h);return e.qrToImageData(x.data,t,l),i(p,d,h),p.putImageData(x,0,0),d},r.renderToDataURL=function(t,a,s){let l=s;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),l||(l={});const d=r.render(t,a,l),h=l.type||"image/png",p=l.rendererOpts||{};return d.toDataURL(h,p.quality)}})(Gt)),Gt}var Jt={},Qi;function uo(){if(Qi)return Jt;Qi=1;const r=hn();function e(o,t){const a=o.a/255,s=t+'="'+o.hex+'"';return a<1?s+" "+t+'-opacity="'+a.toFixed(2).slice(1)+'"':s}function i(o,t,a){let s=o+t;return typeof a<"u"&&(s+=" "+a),s}function n(o,t,a){let s="",l=0,d=!1,h=0;for(let p=0;p<o.length;p++){const x=Math.floor(p%t),g=Math.floor(p/t);!x&&!d&&(d=!0),o[p]?(h++,p>0&&x>0&&o[p-1]||(s+=d?i("M",x+a,.5+g+a):i("m",l,0),l=0,d=!1),x+1<t&&o[p+1]||(s+=i("h",h),h=0)):l++}return s}return Jt.render=function(t,a,s){const l=r.getOptions(a),d=t.modules.size,h=t.modules.data,p=d+l.margin*2,x=l.color.light.a?"<path "+e(l.color.light,"fill")+' d="M0 0h'+p+"v"+p+'H0z"/>':"",g="<path "+e(l.color.dark,"stroke")+' d="'+n(h,d,l.margin)+'"/>',W='viewBox="0 0 '+p+" "+p+'"',S='<svg xmlns="http://www.w3.org/2000/svg" '+(l.width?'width="'+l.width+'" height="'+l.width+'" ':"")+W+' shape-rendering="crispEdges">'+x+g+`</svg>
1075
+ `;return typeof s=="function"&&s(null,S),S},Jt}var Xi;function ho(){if(Xi)return Te;Xi=1;const r=Fn(),e=lo(),i=co(),n=uo();function o(t,a,s,l,d){const h=[].slice.call(arguments,1),p=h.length,x=typeof h[p-1]=="function";if(!x&&!r())throw new Error("Callback required as last argument");if(x){if(p<2)throw new Error("Too few arguments provided");p===2?(d=s,s=a,a=l=void 0):p===3&&(a.getContext&&typeof d>"u"?(d=l,l=void 0):(d=l,l=s,s=a,a=void 0))}else{if(p<1)throw new Error("Too few arguments provided");return p===1?(s=a,a=l=void 0):p===2&&!a.getContext&&(l=s,s=a,a=void 0),new Promise(function(g,W){try{const v=e.create(s,l);g(t(v,a,l))}catch(v){W(v)}})}try{const g=e.create(s,l);d(null,t(g,a,l))}catch(g){d(g)}}return Te.create=e.create,Te.toCanvas=o.bind(null,i.render),Te.toDataURL=o.bind(null,i.renderToDataURL),Te.toString=o.bind(null,function(t,a,s){return n.render(t,s)}),Te}var fo=ho();const po=En(fo),go=.1,Zi=2.5,de=7;function Qt(r,e,i){return r===e?!1:(r-e<0?e-r:r-e)<=i+go}function wo(r,e){const i=Array.prototype.slice.call(po.create(r,{errorCorrectionLevel:e}).modules.data,0),n=Math.sqrt(i.length);return i.reduce((o,t,a)=>(a%n===0?o.push([t]):o[o.length-1].push(t))&&o,[])}const bo={generate({uri:r,size:e,logoSize:i,dotColor:n="#141414"}){const o="transparent",a=[],s=wo(r,"Q"),l=e/s.length,d=[{x:0,y:0},{x:1,y:0},{x:0,y:1}];d.forEach(({x:v,y:S})=>{const b=(s.length-de)*l*v,w=(s.length-de)*l*S,m=.45;for(let f=0;f<d.length;f+=1){const D=l*(de-f*2);a.push(Ne`
1076
1076
  <rect
1077
- fill=${p===2?n:o}
1078
- width=${p===0?W-5:W}
1079
- rx= ${p===0?(W-5)*w:W*w}
1080
- ry= ${p===0?(W-5)*w:W*w}
1077
+ fill=${f===2?n:o}
1078
+ width=${f===0?D-5:D}
1079
+ rx= ${f===0?(D-5)*m:D*m}
1080
+ ry= ${f===0?(D-5)*m:D*m}
1081
1081
  stroke=${n}
1082
- stroke-width=${p===0?5:0}
1083
- height=${p===0?W-5:W}
1084
- x= ${p===0?f+l*p+5/2:f+l*p}
1085
- y= ${p===0?g+l*p+5/2:g+l*p}
1082
+ stroke-width=${f===0?5:0}
1083
+ height=${f===0?D-5:D}
1084
+ x= ${f===0?w+l*f+5/2:w+l*f}
1085
+ y= ${f===0?b+l*f+5/2:b+l*f}
1086
1086
  />
1087
- `)}});const d=Math.floor((i+25)/l),_=s.length/2-d/2,x=s.length/2+d/2-1,m=[];s.forEach((b,R)=>{b.forEach((g,f)=>{if(s[R][f]&&!(R<ae&&f<ae||R>s.length-(ae+1)&&f<ae||R<ae&&f>s.length-(ae+1))&&!(R>_&&R<x&&f>_&&f<x)){const w=R*l+l/2,p=f*l+l/2;m.push([w,p])}})});const $={};return m.forEach(([b,R])=>{var g;$[b]?(g=$[b])==null||g.push(R):$[b]=[R]}),Object.entries($).map(([b,R])=>{const g=R.filter(f=>R.every(w=>!Ot(f,w,l)));return[Number(b),g]}).forEach(([b,R])=>{R.forEach(g=>{a.push(Ae`<circle cx=${b} cy=${g} fill=${n} r=${l/gi} />`)})}),Object.entries($).filter(([b,R])=>R.length>1).map(([b,R])=>{const g=R.filter(f=>R.some(w=>Ot(f,w,l)));return[Number(b),g]}).map(([b,R])=>{R.sort((f,w)=>f<w?-1:1);const g=[];for(const f of R){const w=g.find(p=>p.some(W=>Ot(f,W,l)));w?w.push(f):g.push([f])}return[b,g.map(f=>[f[0],f[f.length-1]])]}).forEach(([b,R])=>{R.forEach(([g,f])=>{a.push(Ae`
1087
+ `)}});const h=Math.floor((i+25)/l),p=s.length/2-h/2,x=s.length/2+h/2-1,g=[];s.forEach((v,S)=>{v.forEach((b,w)=>{if(s[S][w]&&!(S<de&&w<de||S>s.length-(de+1)&&w<de||S<de&&w>s.length-(de+1))&&!(S>p&&S<x&&w>p&&w<x)){const m=S*l+l/2,f=w*l+l/2;g.push([m,f])}})});const W={};return g.forEach(([v,S])=>{var b;W[v]?(b=W[v])==null||b.push(S):W[v]=[S]}),Object.entries(W).map(([v,S])=>{const b=S.filter(w=>S.every(m=>!Qt(w,m,l)));return[Number(v),b]}).forEach(([v,S])=>{S.forEach(b=>{a.push(Ne`<circle cx=${v} cy=${b} fill=${n} r=${l/Zi} />`)})}),Object.entries(W).filter(([v,S])=>S.length>1).map(([v,S])=>{const b=S.filter(w=>S.some(m=>Qt(w,m,l)));return[Number(v),b]}).map(([v,S])=>{S.sort((w,m)=>w<m?-1:1);const b=[];for(const w of S){const m=b.find(f=>f.some(D=>Qt(w,D,l)));m?m.push(w):b.push([w])}return[v,b.map(w=>[w[0],w[w.length-1]])]}).forEach(([v,S])=>{S.forEach(([b,w])=>{a.push(Ne`
1088
1088
  <line
1089
- x1=${b}
1090
- x2=${b}
1091
- y1=${g}
1092
- y2=${f}
1089
+ x1=${v}
1090
+ x2=${v}
1091
+ y1=${b}
1092
+ y2=${w}
1093
1093
  stroke=${n}
1094
- stroke-width=${l/(gi/2)}
1094
+ stroke-width=${l/(Zi/2)}
1095
1095
  stroke-linecap="round"
1096
1096
  />
1097
- `)})}),a}},ao=P`
1097
+ `)})}),a}},mo=N`
1098
1098
  :host {
1099
1099
  position: relative;
1100
1100
  user-select: none;
@@ -1140,19 +1140,19 @@ Minimum version required to store current data is: `+t+`.
1140
1140
  color: var(--local-icon-color) !important;
1141
1141
  transform: translateY(-50%) translateX(-50%) scale(0.25);
1142
1142
  }
1143
- `;var ue=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const so="#3396ff";let Q=class extends I{constructor(){super(...arguments),this.uri="",this.size=0,this.theme="dark",this.imageSrc=void 0,this.alt=void 0,this.arenaClear=void 0,this.farcaster=void 0}render(){return this.dataset.theme=this.theme,this.dataset.clear=String(this.arenaClear),this.style.cssText=`
1143
+ `;var ge=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const vo="#3396ff";let ie=class extends O{constructor(){super(...arguments),this.uri="",this.size=0,this.theme="dark",this.imageSrc=void 0,this.alt=void 0,this.arenaClear=void 0,this.farcaster=void 0}render(){return this.dataset.theme=this.theme,this.dataset.clear=String(this.arenaClear),this.style.cssText=`
1144
1144
  --local-size: ${this.size}px;
1145
- --local-icon-color: ${this.color??so}
1146
- `,c`${this.templateVisual()} ${this.templateSvg()}`}templateSvg(){const e=this.theme==="light"?this.size:this.size-32;return Ae`
1145
+ --local-icon-color: ${this.color??vo}
1146
+ `,c`${this.templateVisual()} ${this.templateSvg()}`}templateSvg(){const e=this.theme==="light"?this.size:this.size-32;return Ne`
1147
1147
  <svg height=${e} width=${e}>
1148
- ${ro.generate({uri:this.uri,size:e,logoSize:this.arenaClear?0:e/4,dotColor:this.color})}
1148
+ ${bo.generate({uri:this.uri,size:e,logoSize:this.arenaClear?0:e/4,dotColor:this.color})}
1149
1149
  </svg>
1150
1150
  `}templateVisual(){return this.imageSrc?c`<wui-image src=${this.imageSrc} alt=${this.alt??"logo"}></wui-image>`:this.farcaster?c`<wui-icon
1151
1151
  class="farcaster"
1152
1152
  size="inherit"
1153
1153
  color="inherit"
1154
1154
  name="farcaster"
1155
- ></wui-icon>`:c`<wui-icon size="inherit" color="inherit" name="walletConnect"></wui-icon>`}};Q.styles=[A,ao];ue([u()],Q.prototype,"uri",void 0);ue([u({type:Number})],Q.prototype,"size",void 0);ue([u()],Q.prototype,"theme",void 0);ue([u()],Q.prototype,"imageSrc",void 0);ue([u()],Q.prototype,"alt",void 0);ue([u()],Q.prototype,"color",void 0);ue([u({type:Boolean})],Q.prototype,"arenaClear",void 0);ue([u({type:Boolean})],Q.prototype,"farcaster",void 0);Q=ue([C("wui-qr-code")],Q);const lo=P`
1155
+ ></wui-icon>`:c`<wui-icon size="inherit" color="inherit" name="walletConnect"></wui-icon>`}};ie.styles=[q,mo];ge([u()],ie.prototype,"uri",void 0);ge([u({type:Number})],ie.prototype,"size",void 0);ge([u()],ie.prototype,"theme",void 0);ge([u()],ie.prototype,"imageSrc",void 0);ge([u()],ie.prototype,"alt",void 0);ge([u()],ie.prototype,"color",void 0);ge([u({type:Boolean})],ie.prototype,"arenaClear",void 0);ge([u({type:Boolean})],ie.prototype,"farcaster",void 0);ie=ge([B("wui-qr-code")],ie);const yo=N`
1156
1156
  :host {
1157
1157
  display: block;
1158
1158
  box-shadow: inset 0 0 0 1px var(--wui-color-gray-glass-005);
@@ -1192,11 +1192,11 @@ Minimum version required to store current data is: `+t+`.
1192
1192
  background-position: 250% 0;
1193
1193
  }
1194
1194
  }
1195
- `;var He=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ve=class extends I{constructor(){super(...arguments),this.width="",this.height="",this.borderRadius="m",this.variant="default"}render(){return this.style.cssText=`
1195
+ `;var He=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let $e=class extends O{constructor(){super(...arguments),this.width="",this.height="",this.borderRadius="m",this.variant="default"}render(){return this.style.cssText=`
1196
1196
  width: ${this.width};
1197
1197
  height: ${this.height};
1198
1198
  border-radius: ${`clamp(0px,var(--wui-border-radius-${this.borderRadius}), 40px)`};
1199
- `,c`<slot></slot>`}};ve.styles=[lo];He([u()],ve.prototype,"width",void 0);He([u()],ve.prototype,"height",void 0);He([u()],ve.prototype,"borderRadius",void 0);He([u()],ve.prototype,"variant",void 0);ve=He([C("wui-shimmer")],ve);const co="https://reown.com",uo=P`
1199
+ `,c`<slot></slot>`}};$e.styles=[yo];He([u()],$e.prototype,"width",void 0);He([u()],$e.prototype,"height",void 0);He([u()],$e.prototype,"borderRadius",void 0);He([u()],$e.prototype,"variant",void 0);$e=He([B("wui-shimmer")],$e);const xo="https://reown.com",Co=N`
1200
1200
  .reown-logo {
1201
1201
  height: var(--wui-spacing-xxl);
1202
1202
  }
@@ -1209,10 +1209,10 @@ Minimum version required to store current data is: `+t+`.
1209
1209
  a:hover {
1210
1210
  opacity: 0.9;
1211
1211
  }
1212
- `;var ho=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ut=class extends I{render(){return c`
1212
+ `;var $o=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ti=class extends O{render(){return c`
1213
1213
  <a
1214
1214
  data-testid="ux-branding-reown"
1215
- href=${co}
1215
+ href=${xo}
1216
1216
  rel="noreferrer"
1217
1217
  target="_blank"
1218
1218
  style="text-decoration: none;"
@@ -1227,7 +1227,7 @@ Minimum version required to store current data is: `+t+`.
1227
1227
  <wui-icon name="reown" size="xxxl" class="reown-logo"></wui-icon>
1228
1228
  </wui-flex>
1229
1229
  </a>
1230
- `}};Ut.styles=[A,M,uo];Ut=ho([C("wui-ux-by-reown")],Ut);const po=P`
1230
+ `}};ti.styles=[q,G,Co];ti=$o([B("wui-ux-by-reown")],ti);const Ro=N`
1231
1231
  @keyframes fadein {
1232
1232
  from {
1233
1233
  opacity: 0;
@@ -1250,7 +1250,7 @@ Minimum version required to store current data is: `+t+`.
1250
1250
  animation-name: fadein;
1251
1251
  animation-fill-mode: forwards;
1252
1252
  }
1253
- `;var fo=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ft=class extends z{constructor(){var e;super(),this.forceUpdate=()=>{this.requestUpdate()},window.addEventListener("resize",this.forceUpdate),J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:((e=this.wallet)==null?void 0:e.name)??"WalletConnect",platform:"qrcode"}})}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.unsubscribe)==null||e.forEach(i=>i()),window.removeEventListener("resize",this.forceUpdate)}render(){return this.onRenderProxy(),c`
1253
+ `;var _o=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ii=class extends V{constructor(){var e;super(),this.forceUpdate=()=>{this.requestUpdate()},window.addEventListener("resize",this.forceUpdate),te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:((e=this.wallet)==null?void 0:e.name)??"WalletConnect",platform:"qrcode"}})}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this.unsubscribe)==null||e.forEach(i=>i()),window.removeEventListener("resize",this.forceUpdate)}render(){return this.onRenderProxy(),c`
1254
1254
  <wui-flex
1255
1255
  flexDirection="column"
1256
1256
  alignItems="center"
@@ -1265,13 +1265,13 @@ Minimum version required to store current data is: `+t+`.
1265
1265
  ${this.copyTemplate()}
1266
1266
  </wui-flex>
1267
1267
  <w3m-mobile-download-links .wallet=${this.wallet}></w3m-mobile-download-links>
1268
- `}onRenderProxy(){!this.ready&&this.uri&&(this.timeout=setTimeout(()=>{this.ready=!0},200))}qrCodeTemplate(){if(!this.uri||!this.ready)return null;const e=this.getBoundingClientRect().width-40,i=this.wallet?this.wallet.name:void 0;return S.setWcLinking(void 0),S.setRecentWallet(this.wallet),c` <wui-qr-code
1268
+ `}onRenderProxy(){!this.ready&&this.uri&&(this.timeout=setTimeout(()=>{this.ready=!0},200))}qrCodeTemplate(){if(!this.uri||!this.ready)return null;const e=this.getBoundingClientRect().width-40,i=this.wallet?this.wallet.name:void 0;return j.setWcLinking(void 0),j.setRecentWallet(this.wallet),c` <wui-qr-code
1269
1269
  size=${e}
1270
- theme=${kt.state.themeMode}
1270
+ theme=${ei.state.themeMode}
1271
1271
  uri=${this.uri}
1272
- imageSrc=${y(D.getWalletImage(this.wallet))}
1273
- color=${y(kt.state.themeVariables["--w3m-qr-color"])}
1274
- alt=${y(i)}
1272
+ imageSrc=${E(K.getWalletImage(this.wallet))}
1273
+ color=${E(ei.state.themeVariables["--w3m-qr-color"])}
1274
+ alt=${E(i)}
1275
1275
  data-testid="wui-qr-code"
1276
1276
  ></wui-qr-code>`}copyTemplate(){const e=!this.uri||!this.ready;return c`<wui-link
1277
1277
  .disabled=${e}
@@ -1281,7 +1281,7 @@ Minimum version required to store current data is: `+t+`.
1281
1281
  >
1282
1282
  <wui-icon size="xs" color="fg-200" slot="iconLeft" name="copy"></wui-icon>
1283
1283
  Copy link
1284
- </wui-link>`}};Ft.styles=po;Ft=fo([C("w3m-connecting-wc-qrcode")],Ft);var go=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let wi=class extends I{constructor(){var e;if(super(),this.wallet=(e=O.state.data)==null?void 0:e.wallet,!this.wallet)throw new Error("w3m-connecting-wc-unsupported: No wallet provided");J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"browser"}})}render(){return c`
1284
+ </wui-link>`}};ii.styles=Ro;ii=_o([B("w3m-connecting-wc-qrcode")],ii);var Io=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let en=class extends O{constructor(){var e;if(super(),this.wallet=(e=U.state.data)==null?void 0:e.wallet,!this.wallet)throw new Error("w3m-connecting-wc-unsupported: No wallet provided");te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"browser"}})}render(){return c`
1285
1285
  <wui-flex
1286
1286
  flexDirection="column"
1287
1287
  alignItems="center"
@@ -1290,18 +1290,18 @@ Minimum version required to store current data is: `+t+`.
1290
1290
  >
1291
1291
  <wui-wallet-image
1292
1292
  size="lg"
1293
- imageSrc=${y(D.getWalletImage(this.wallet))}
1293
+ imageSrc=${E(K.getWalletImage(this.wallet))}
1294
1294
  ></wui-wallet-image>
1295
1295
 
1296
1296
  <wui-text variant="paragraph-500" color="fg-100">Not Detected</wui-text>
1297
1297
  </wui-flex>
1298
1298
 
1299
1299
  <w3m-mobile-download-links .wallet=${this.wallet}></w3m-mobile-download-links>
1300
- `}};wi=go([C("w3m-connecting-wc-unsupported")],wi);var Ni=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Vt=class extends z{constructor(){if(super(),this.isLoading=!0,!this.wallet)throw new Error("w3m-connecting-wc-web: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.secondaryBtnLabel="Open",this.secondaryLabel=yi.CONNECT_LABELS.MOBILE,this.secondaryBtnIcon="externalLink",this.updateLoadingState(),this.unsubscribe.push(S.subscribeKey("wcUri",()=>{this.updateLoadingState()})),J.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"web"}})}updateLoadingState(){this.isLoading=!this.uri}onConnectProxy(){var e;if((e=this.wallet)!=null&&e.webapp_link&&this.uri)try{this.error=!1;const{webapp_link:i,name:n}=this.wallet,{redirect:o,href:t}=E.formatUniversalUrl(i,this.uri);S.setWcLinking({name:n,href:t}),S.setRecentWallet(this.wallet),E.openHref(o,"_blank")}catch{this.error=!0}}};Ni([v()],Vt.prototype,"isLoading",void 0);Vt=Ni([C("w3m-connecting-wc-web")],Vt);var Ke=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Se=class extends I{constructor(){var e;super(),this.wallet=(e=O.state.data)==null?void 0:e.wallet,this.unsubscribe=[],this.platform=void 0,this.platforms=[],this.isSiwxEnabled=!!Y.state.siwx,this.remoteFeatures=Y.state.remoteFeatures,this.determinePlatforms(),this.initializeConnection(),this.unsubscribe.push(Y.subscribeKey("remoteFeatures",i=>this.remoteFeatures=i))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){return c`
1300
+ `}};en=Io([B("w3m-connecting-wc-unsupported")],en);var fn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ni=class extends V{constructor(){if(super(),this.isLoading=!0,!this.wallet)throw new Error("w3m-connecting-wc-web: No wallet provided");this.onConnect=this.onConnectProxy.bind(this),this.secondaryBtnLabel="Open",this.secondaryLabel=rn.CONNECT_LABELS.MOBILE,this.secondaryBtnIcon="externalLink",this.updateLoadingState(),this.unsubscribe.push(j.subscribeKey("wcUri",()=>{this.updateLoadingState()})),te.sendEvent({type:"track",event:"SELECT_WALLET",properties:{name:this.wallet.name,platform:"web"}})}updateLoadingState(){this.isLoading=!this.uri}onConnectProxy(){var e;if((e=this.wallet)!=null&&e.webapp_link&&this.uri)try{this.error=!1;const{webapp_link:i,name:n}=this.wallet,{redirect:o,href:t}=k.formatUniversalUrl(i,this.uri);j.setWcLinking({name:n,href:t}),j.setRecentWallet(this.wallet),k.openHref(o,"_blank")}catch{this.error=!0}}};fn([_()],ni.prototype,"isLoading",void 0);ni=fn([B("w3m-connecting-wc-web")],ni);var Ge=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Le=class extends O{constructor(){var e;super(),this.wallet=(e=U.state.data)==null?void 0:e.wallet,this.unsubscribe=[],this.platform=void 0,this.platforms=[],this.isSiwxEnabled=!!ee.state.siwx,this.remoteFeatures=ee.state.remoteFeatures,this.determinePlatforms(),this.initializeConnection(),this.unsubscribe.push(ee.subscribeKey("remoteFeatures",i=>this.remoteFeatures=i))}disconnectedCallback(){this.unsubscribe.forEach(e=>e())}render(){return c`
1301
1301
  ${this.headerTemplate()}
1302
1302
  <div>${this.platformTemplate()}</div>
1303
1303
  ${this.reownBrandingTemplate()}
1304
- `}reownBrandingTemplate(){var e;return(e=this.remoteFeatures)!=null&&e.reownBranding?c`<wui-ux-by-reown></wui-ux-by-reown>`:null}async initializeConnection(e=!1){if(!(this.platform==="browser"||Y.state.manualWCControl&&!e))try{const{wcPairingExpiry:i,status:n}=S.state;(e||Y.state.enableEmbedded||E.isPairingExpired(i)||n==="connecting")&&(await S.connectWalletConnect(),this.isSiwxEnabled||vi.close())}catch(i){J.sendEvent({type:"track",event:"CONNECT_ERROR",properties:{message:(i==null?void 0:i.message)??"Unknown"}}),S.setWcError(!0),Qe.showError(i.message??"Connection error"),S.resetWcConnection(),O.goBack()}}determinePlatforms(){if(!this.wallet){this.platforms.push("qrcode"),this.platform="qrcode";return}if(this.platform)return;const{mobile_link:e,desktop_link:i,webapp_link:n,injected:o,rdns:t}=this.wallet,a=o==null?void 0:o.map(({injected_id:$})=>$).filter(Boolean),s=[...t?[t]:a??[]],l=Y.state.isUniversalProvider?!1:s.length,h=e,d=n,_=S.checkInstalled(s),x=l&&_,m=i&&!E.isMobile();x&&!jt.state.noAdapters&&this.platforms.push("browser"),h&&this.platforms.push(E.isMobile()?"mobile":"qrcode"),d&&this.platforms.push("web"),m&&this.platforms.push("desktop"),!x&&l&&!jt.state.noAdapters&&this.platforms.push("unsupported"),this.platform=this.platforms[0]}platformTemplate(){switch(this.platform){case"browser":return c`<w3m-connecting-wc-browser></w3m-connecting-wc-browser>`;case"web":return c`<w3m-connecting-wc-web></w3m-connecting-wc-web>`;case"desktop":return c`
1304
+ `}reownBrandingTemplate(){var e;return(e=this.remoteFeatures)!=null&&e.reownBranding?c`<wui-ux-by-reown></wui-ux-by-reown>`:null}async initializeConnection(e=!1){if(!(this.platform==="browser"||ee.state.manualWCControl&&!e))try{const{wcPairingExpiry:i,status:n}=j.state;(e||ee.state.enableEmbedded||k.isPairingExpired(i)||n==="connecting")&&(await j.connectWalletConnect(),this.isSiwxEnabled||on.close())}catch(i){te.sendEvent({type:"track",event:"CONNECT_ERROR",properties:{message:(i==null?void 0:i.message)??"Unknown"}}),j.setWcError(!0),Xe.showError(i.message??"Connection error"),j.resetWcConnection(),U.goBack()}}determinePlatforms(){if(!this.wallet){this.platforms.push("qrcode"),this.platform="qrcode";return}if(this.platform)return;const{mobile_link:e,desktop_link:i,webapp_link:n,injected:o,rdns:t}=this.wallet,a=o==null?void 0:o.map(({injected_id:W})=>W).filter(Boolean),s=[...t?[t]:a??[]],l=ee.state.isUniversalProvider?!1:s.length,d=e,h=n,p=j.checkInstalled(s),x=l&&p,g=i&&!k.isMobile();x&&!Zt.state.noAdapters&&this.platforms.push("browser"),d&&this.platforms.push(k.isMobile()?"mobile":"qrcode"),h&&this.platforms.push("web"),g&&this.platforms.push("desktop"),!x&&l&&!Zt.state.noAdapters&&this.platforms.push("unsupported"),this.platform=this.platforms[0]}platformTemplate(){switch(this.platform){case"browser":return c`<w3m-connecting-wc-browser></w3m-connecting-wc-browser>`;case"web":return c`<w3m-connecting-wc-web></w3m-connecting-wc-web>`;case"desktop":return c`
1305
1305
  <w3m-connecting-wc-desktop .onRetry=${()=>this.initializeConnection(!0)}>
1306
1306
  </w3m-connecting-wc-desktop>
1307
1307
  `;case"mobile":return c`
@@ -1313,7 +1313,7 @@ Minimum version required to store current data is: `+t+`.
1313
1313
  .onSelectPlatfrom=${this.onSelectPlatform.bind(this)}
1314
1314
  >
1315
1315
  </w3m-connecting-header>
1316
- `:null}async onSelectPlatform(e){var n;const i=(n=this.shadowRoot)==null?void 0:n.querySelector("div");i&&(await i.animate([{opacity:1},{opacity:0}],{duration:200,fill:"forwards",easing:"ease"}).finished,this.platform=e,i.animate([{opacity:0},{opacity:1}],{duration:200,fill:"forwards",easing:"ease"}))}};Ke([v()],Se.prototype,"platform",void 0);Ke([v()],Se.prototype,"platforms",void 0);Ke([v()],Se.prototype,"isSiwxEnabled",void 0);Ke([v()],Se.prototype,"remoteFeatures",void 0);Se=Ke([C("w3m-connecting-wc-view")],Se);var Mi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let qt=class extends I{constructor(){super(...arguments),this.isMobile=E.isMobile()}render(){if(this.isMobile){const{featured:e,recommended:i}=T.state,{customWallets:n}=Y.state,o=ft.getRecentWallets(),t=e.length||i.length||(n==null?void 0:n.length)||o.length;return c`<wui-flex
1316
+ `:null}async onSelectPlatform(e){var n;const i=(n=this.shadowRoot)==null?void 0:n.querySelector("div");i&&(await i.animate([{opacity:1},{opacity:0}],{duration:200,fill:"forwards",easing:"ease"}).finished,this.platform=e,i.animate([{opacity:0},{opacity:1}],{duration:200,fill:"forwards",easing:"ease"}))}};Ge([_()],Le.prototype,"platform",void 0);Ge([_()],Le.prototype,"platforms",void 0);Ge([_()],Le.prototype,"isSiwxEnabled",void 0);Ge([_()],Le.prototype,"remoteFeatures",void 0);Le=Ge([B("w3m-connecting-wc-view")],Le);var pn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let oi=class extends O{constructor(){super(...arguments),this.isMobile=k.isMobile()}render(){if(this.isMobile){const{featured:e,recommended:i}=z.state,{customWallets:n}=ee.state,o=ft.getRecentWallets(),t=e.length||i.length||(n==null?void 0:n.length)||o.length;return c`<wui-flex
1317
1317
  flexDirection="column"
1318
1318
  gap="xs"
1319
1319
  .margin=${["3xs","s","s","s"]}
@@ -1324,11 +1324,11 @@ Minimum version required to store current data is: `+t+`.
1324
1324
  <w3m-connecting-wc-view></w3m-connecting-wc-view>
1325
1325
  <wui-flex flexDirection="column" .padding=${["0","m","0","m"]}>
1326
1326
  <w3m-all-wallets-widget></w3m-all-wallets-widget> </wui-flex
1327
- ></wui-flex>`}};Mi([v()],qt.prototype,"isMobile",void 0);qt=Mi([C("w3m-connecting-wc-basic-view")],qt);/**
1327
+ ></wui-flex>`}};pn([_()],oi.prototype,"isMobile",void 0);oi=pn([B("w3m-connecting-wc-basic-view")],oi);/**
1328
1328
  * @license
1329
1329
  * Copyright 2020 Google LLC
1330
1330
  * SPDX-License-Identifier: BSD-3-Clause
1331
- */const oi=()=>new wo;class wo{}const At=new WeakMap,ri=Gi(class extends Yi{render(r){return li}update(r,[e]){var n;const i=e!==this.G;return i&&this.rt(void 0),(i||this.lt!==this.ct)&&(this.G=e,this.ht=(n=r.options)==null?void 0:n.host,this.rt(this.ct=r.element)),li}rt(r){if(this.G!==void 0)if(this.isConnected||(r=void 0),typeof this.G=="function"){const e=this.ht??globalThis;let i=At.get(e);i===void 0&&(i=new WeakMap,At.set(e,i)),i.get(this.G)!==void 0&&this.G.call(this.ht,void 0),i.set(this.G,r),r!==void 0&&this.G.call(this.ht,r)}else this.G.value=r}get lt(){var r,e;return typeof this.G=="function"?(r=At.get(this.ht??globalThis))==null?void 0:r.get(this.G):(e=this.G)==null?void 0:e.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}}),bo=P`
1331
+ */const fi=()=>new Eo;class Eo{}const Xt=new WeakMap,pi=Rn(class extends _n{render(r){return yi}update(r,[e]){var n;const i=e!==this.G;return i&&this.rt(void 0),(i||this.lt!==this.ct)&&(this.G=e,this.ht=(n=r.options)==null?void 0:n.host,this.rt(this.ct=r.element)),yi}rt(r){if(this.G!==void 0)if(this.isConnected||(r=void 0),typeof this.G=="function"){const e=this.ht??globalThis;let i=Xt.get(e);i===void 0&&(i=new WeakMap,Xt.set(e,i)),i.get(this.G)!==void 0&&this.G.call(this.ht,void 0),i.set(this.G,r),r!==void 0&&this.G.call(this.ht,r)}else this.G.value=r}get lt(){var r,e;return typeof this.G=="function"?(r=Xt.get(this.ht??globalThis))==null?void 0:r.get(this.G):(e=this.G)==null?void 0:e.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}}),Wo=N`
1332
1332
  :host {
1333
1333
  display: flex;
1334
1334
  align-items: center;
@@ -1391,17 +1391,17 @@ Minimum version required to store current data is: `+t+`.
1391
1391
  input:checked + span:before {
1392
1392
  transform: translateX(calc(100% - 7px));
1393
1393
  }
1394
- `;var Ui=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ct=class extends I{constructor(){super(...arguments),this.inputElementRef=oi(),this.checked=void 0}render(){return c`
1394
+ `;var gn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let lt=class extends O{constructor(){super(...arguments),this.inputElementRef=fi(),this.checked=void 0}render(){return c`
1395
1395
  <label>
1396
1396
  <input
1397
- ${ri(this.inputElementRef)}
1397
+ ${pi(this.inputElementRef)}
1398
1398
  type="checkbox"
1399
- ?checked=${y(this.checked)}
1399
+ ?checked=${E(this.checked)}
1400
1400
  @change=${this.dispatchChangeEvent.bind(this)}
1401
1401
  />
1402
1402
  <span></span>
1403
1403
  </label>
1404
- `}dispatchChangeEvent(){var e;this.dispatchEvent(new CustomEvent("switchChange",{detail:(e=this.inputElementRef.value)==null?void 0:e.checked,bubbles:!0,composed:!0}))}};ct.styles=[A,M,Ki,bo];Ui([u({type:Boolean})],ct.prototype,"checked",void 0);ct=Ui([C("wui-switch")],ct);const mo=P`
1404
+ `}dispatchChangeEvent(){var e;this.dispatchEvent(new CustomEvent("switchChange",{detail:(e=this.inputElementRef.value)==null?void 0:e.checked,bubbles:!0,composed:!0}))}};lt.styles=[q,G,$n,Wo];gn([u({type:Boolean})],lt.prototype,"checked",void 0);lt=gn([B("wui-switch")],lt);const So=N`
1405
1405
  :host {
1406
1406
  height: 100%;
1407
1407
  }
@@ -1423,12 +1423,12 @@ Minimum version required to store current data is: `+t+`.
1423
1423
  wui-switch {
1424
1424
  pointer-events: none;
1425
1425
  }
1426
- `;var Fi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ut=class extends I{constructor(){super(...arguments),this.checked=void 0}render(){return c`
1426
+ `;var wn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ct=class extends O{constructor(){super(...arguments),this.checked=void 0}render(){return c`
1427
1427
  <button>
1428
1428
  <wui-icon size="xl" name="walletConnectBrown"></wui-icon>
1429
- <wui-switch ?checked=${y(this.checked)}></wui-switch>
1429
+ <wui-switch ?checked=${E(this.checked)}></wui-switch>
1430
1430
  </button>
1431
- `}};ut.styles=[A,M,mo];Fi([u({type:Boolean})],ut.prototype,"checked",void 0);ut=Fi([C("wui-certified-switch")],ut);const vo=P`
1431
+ `}};ct.styles=[q,G,So];wn([u({type:Boolean})],ct.prototype,"checked",void 0);ct=wn([B("wui-certified-switch")],ct);const To=N`
1432
1432
  button {
1433
1433
  background-color: var(--wui-color-fg-300);
1434
1434
  border-radius: var(--wui-border-radius-4xs);
@@ -1458,11 +1458,11 @@ Minimum version required to store current data is: `+t+`.
1458
1458
  background-color: var(--wui-color-fg-225);
1459
1459
  }
1460
1460
  }
1461
- `;var Vi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let dt=class extends I{constructor(){super(...arguments),this.icon="copy"}render(){return c`
1461
+ `;var bn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ut=class extends O{constructor(){super(...arguments),this.icon="copy"}render(){return c`
1462
1462
  <button>
1463
1463
  <wui-icon color="inherit" size="xxs" name=${this.icon}></wui-icon>
1464
1464
  </button>
1465
- `}};dt.styles=[A,M,vo];Vi([u()],dt.prototype,"icon",void 0);dt=Vi([C("wui-input-element")],dt);const yo=P`
1465
+ `}};ut.styles=[q,G,To];bn([u()],ut.prototype,"icon",void 0);ut=bn([B("wui-input-element")],ut);const Po=N`
1466
1466
  :host {
1467
1467
  position: relative;
1468
1468
  width: 100%;
@@ -1645,33 +1645,33 @@ Minimum version required to store current data is: `+t+`.
1645
1645
  ::slotted(wui-icon) {
1646
1646
  right: 0px;
1647
1647
  }
1648
- `;var oe=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let H=class extends I{constructor(){super(...arguments),this.inputElementRef=oi(),this.size="md",this.disabled=!1,this.placeholder="",this.type="text",this.value=""}render(){const e=`wui-padding-right-${this.inputRightPadding}`,n={[`wui-size-${this.size}`]:!0,[e]:!!this.inputRightPadding};return c`${this.templateIcon()}
1648
+ `;var le=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let X=class extends O{constructor(){super(...arguments),this.inputElementRef=fi(),this.size="md",this.disabled=!1,this.placeholder="",this.type="text",this.value=""}render(){const e=`wui-padding-right-${this.inputRightPadding}`,n={[`wui-size-${this.size}`]:!0,[e]:!!this.inputRightPadding};return c`${this.templateIcon()}
1649
1649
  <input
1650
1650
  data-testid="wui-input-text"
1651
- ${ri(this.inputElementRef)}
1652
- class=${Ji(n)}
1651
+ ${pi(this.inputElementRef)}
1652
+ class=${In(n)}
1653
1653
  type=${this.type}
1654
- enterkeyhint=${y(this.enterKeyHint)}
1654
+ enterkeyhint=${E(this.enterKeyHint)}
1655
1655
  ?disabled=${this.disabled}
1656
1656
  placeholder=${this.placeholder}
1657
1657
  @input=${this.dispatchInputChangeEvent.bind(this)}
1658
1658
  .value=${this.value||""}
1659
- tabindex=${y(this.tabIdx)}
1659
+ tabindex=${E(this.tabIdx)}
1660
1660
  />
1661
1661
  <slot></slot>`}templateIcon(){return this.icon?c`<wui-icon
1662
1662
  data-input=${this.size}
1663
1663
  size=${this.size}
1664
1664
  color="inherit"
1665
1665
  name=${this.icon}
1666
- ></wui-icon>`:null}dispatchInputChangeEvent(){var e;this.dispatchEvent(new CustomEvent("inputChange",{detail:(e=this.inputElementRef.value)==null?void 0:e.value,bubbles:!0,composed:!0}))}};H.styles=[A,M,yo];oe([u()],H.prototype,"size",void 0);oe([u()],H.prototype,"icon",void 0);oe([u({type:Boolean})],H.prototype,"disabled",void 0);oe([u()],H.prototype,"placeholder",void 0);oe([u()],H.prototype,"type",void 0);oe([u()],H.prototype,"keyHint",void 0);oe([u()],H.prototype,"value",void 0);oe([u()],H.prototype,"inputRightPadding",void 0);oe([u()],H.prototype,"tabIdx",void 0);H=oe([C("wui-input-text")],H);const xo=P`
1666
+ ></wui-icon>`:null}dispatchInputChangeEvent(){var e;this.dispatchEvent(new CustomEvent("inputChange",{detail:(e=this.inputElementRef.value)==null?void 0:e.value,bubbles:!0,composed:!0}))}};X.styles=[q,G,Po];le([u()],X.prototype,"size",void 0);le([u()],X.prototype,"icon",void 0);le([u({type:Boolean})],X.prototype,"disabled",void 0);le([u()],X.prototype,"placeholder",void 0);le([u()],X.prototype,"type",void 0);le([u()],X.prototype,"keyHint",void 0);le([u()],X.prototype,"value",void 0);le([u()],X.prototype,"inputRightPadding",void 0);le([u()],X.prototype,"tabIdx",void 0);X=le([B("wui-input-text")],X);const Bo=N`
1667
1667
  :host {
1668
1668
  position: relative;
1669
1669
  display: inline-block;
1670
1670
  width: 100%;
1671
1671
  }
1672
- `;var Co=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Ht=class extends I{constructor(){super(...arguments),this.inputComponentRef=oi()}render(){return c`
1672
+ `;var Lo=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ri=class extends O{constructor(){super(...arguments),this.inputComponentRef=fi()}render(){return c`
1673
1673
  <wui-input-text
1674
- ${ri(this.inputComponentRef)}
1674
+ ${pi(this.inputComponentRef)}
1675
1675
  placeholder="Search wallet"
1676
1676
  icon="search"
1677
1677
  type="search"
@@ -1680,11 +1680,11 @@ Minimum version required to store current data is: `+t+`.
1680
1680
  >
1681
1681
  <wui-input-element @click=${this.clearValue} icon="close"></wui-input-element>
1682
1682
  </wui-input-text>
1683
- `}clearValue(){const e=this.inputComponentRef.value,i=e==null?void 0:e.inputElementRef.value;i&&(i.value="",i.focus(),i.dispatchEvent(new Event("input")))}};Ht.styles=[A,xo];Ht=Co([C("wui-search-bar")],Ht);const $o=Ae`<svg viewBox="0 0 48 54" fill="none">
1683
+ `}clearValue(){const e=this.inputComponentRef.value,i=e==null?void 0:e.inputElementRef.value;i&&(i.value="",i.focus(),i.dispatchEvent(new Event("input")))}};ri.styles=[q,Bo];ri=Lo([B("wui-search-bar")],ri);const Oo=Ne`<svg viewBox="0 0 48 54" fill="none">
1684
1684
  <path
1685
1685
  d="M43.4605 10.7248L28.0485 1.61089C25.5438 0.129705 22.4562 0.129705 19.9515 1.61088L4.53951 10.7248C2.03626 12.2051 0.5 14.9365 0.5 17.886V36.1139C0.5 39.0635 2.03626 41.7949 4.53951 43.2752L19.9515 52.3891C22.4562 53.8703 25.5438 53.8703 28.0485 52.3891L43.4605 43.2752C45.9637 41.7949 47.5 39.0635 47.5 36.114V17.8861C47.5 14.9365 45.9637 12.2051 43.4605 10.7248Z"
1686
1686
  />
1687
- </svg>`,Ro=P`
1687
+ </svg>`,Ao=N`
1688
1688
  :host {
1689
1689
  display: flex;
1690
1690
  flex-direction: column;
@@ -1720,7 +1720,7 @@ Minimum version required to store current data is: `+t+`.
1720
1720
  width: 100%;
1721
1721
  }
1722
1722
  }
1723
- `;var qi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ht=class extends I{constructor(){super(...arguments),this.type="wallet"}render(){return c`
1723
+ `;var mn=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let dt=class extends O{constructor(){super(...arguments),this.type="wallet"}render(){return c`
1724
1724
  ${this.shimmerTemplate()}
1725
1725
  <wui-shimmer width="56px" height="20px" borderRadius="xs"></wui-shimmer>
1726
1726
  `}shimmerTemplate(){return this.type==="network"?c` <wui-shimmer
@@ -1729,13 +1729,13 @@ Minimum version required to store current data is: `+t+`.
1729
1729
  height="54px"
1730
1730
  borderRadius="xs"
1731
1731
  ></wui-shimmer>
1732
- ${$o}`:c`<wui-shimmer width="56px" height="56px" borderRadius="xs"></wui-shimmer>`}};ht.styles=[A,M,Ro];qi([u()],ht.prototype,"type",void 0);ht=qi([C("wui-card-select-loader")],ht);const _o=P`
1732
+ ${Oo}`:c`<wui-shimmer width="56px" height="56px" borderRadius="xs"></wui-shimmer>`}};dt.styles=[q,G,Ao];mn([u()],dt.prototype,"type",void 0);dt=mn([B("wui-card-select-loader")],dt);const ko=N`
1733
1733
  :host {
1734
1734
  display: grid;
1735
1735
  width: inherit;
1736
1736
  height: inherit;
1737
1737
  }
1738
- `;var K=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let N=class extends I{render(){return this.style.cssText=`
1738
+ `;var Z=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let H=class extends O{render(){return this.style.cssText=`
1739
1739
  grid-template-rows: ${this.gridTemplateRows};
1740
1740
  grid-template-columns: ${this.gridTemplateColumns};
1741
1741
  justify-items: ${this.justifyItems};
@@ -1745,15 +1745,15 @@ Minimum version required to store current data is: `+t+`.
1745
1745
  column-gap: ${this.columnGap&&`var(--wui-spacing-${this.columnGap})`};
1746
1746
  row-gap: ${this.rowGap&&`var(--wui-spacing-${this.rowGap})`};
1747
1747
  gap: ${this.gap&&`var(--wui-spacing-${this.gap})`};
1748
- padding-top: ${this.padding&&se.getSpacingStyles(this.padding,0)};
1749
- padding-right: ${this.padding&&se.getSpacingStyles(this.padding,1)};
1750
- padding-bottom: ${this.padding&&se.getSpacingStyles(this.padding,2)};
1751
- padding-left: ${this.padding&&se.getSpacingStyles(this.padding,3)};
1752
- margin-top: ${this.margin&&se.getSpacingStyles(this.margin,0)};
1753
- margin-right: ${this.margin&&se.getSpacingStyles(this.margin,1)};
1754
- margin-bottom: ${this.margin&&se.getSpacingStyles(this.margin,2)};
1755
- margin-left: ${this.margin&&se.getSpacingStyles(this.margin,3)};
1756
- `,c`<slot></slot>`}};N.styles=[A,_o];K([u()],N.prototype,"gridTemplateRows",void 0);K([u()],N.prototype,"gridTemplateColumns",void 0);K([u()],N.prototype,"justifyItems",void 0);K([u()],N.prototype,"alignItems",void 0);K([u()],N.prototype,"justifyContent",void 0);K([u()],N.prototype,"alignContent",void 0);K([u()],N.prototype,"columnGap",void 0);K([u()],N.prototype,"rowGap",void 0);K([u()],N.prototype,"gap",void 0);K([u()],N.prototype,"padding",void 0);K([u()],N.prototype,"margin",void 0);N=K([C("wui-grid")],N);const Io=P`
1748
+ padding-top: ${this.padding&&he.getSpacingStyles(this.padding,0)};
1749
+ padding-right: ${this.padding&&he.getSpacingStyles(this.padding,1)};
1750
+ padding-bottom: ${this.padding&&he.getSpacingStyles(this.padding,2)};
1751
+ padding-left: ${this.padding&&he.getSpacingStyles(this.padding,3)};
1752
+ margin-top: ${this.margin&&he.getSpacingStyles(this.margin,0)};
1753
+ margin-right: ${this.margin&&he.getSpacingStyles(this.margin,1)};
1754
+ margin-bottom: ${this.margin&&he.getSpacingStyles(this.margin,2)};
1755
+ margin-left: ${this.margin&&he.getSpacingStyles(this.margin,3)};
1756
+ `,c`<slot></slot>`}};H.styles=[q,ko];Z([u()],H.prototype,"gridTemplateRows",void 0);Z([u()],H.prototype,"gridTemplateColumns",void 0);Z([u()],H.prototype,"justifyItems",void 0);Z([u()],H.prototype,"alignItems",void 0);Z([u()],H.prototype,"justifyContent",void 0);Z([u()],H.prototype,"alignContent",void 0);Z([u()],H.prototype,"columnGap",void 0);Z([u()],H.prototype,"rowGap",void 0);Z([u()],H.prototype,"gap",void 0);Z([u()],H.prototype,"padding",void 0);Z([u()],H.prototype,"margin",void 0);H=Z([B("wui-grid")],H);const jo=N`
1757
1757
  button {
1758
1758
  display: flex;
1759
1759
  flex-direction: column;
@@ -1814,14 +1814,14 @@ Minimum version required to store current data is: `+t+`.
1814
1814
  width: 100%;
1815
1815
  }
1816
1816
  }
1817
- `;var Ge=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ye=class extends I{constructor(){super(),this.observer=new IntersectionObserver(()=>{}),this.visible=!1,this.imageSrc=void 0,this.imageLoading=!1,this.wallet=void 0,this.observer=new IntersectionObserver(e=>{e.forEach(i=>{i.isIntersecting?(this.visible=!0,this.fetchImageSrc()):this.visible=!1})},{threshold:.01})}firstUpdated(){this.observer.observe(this)}disconnectedCallback(){this.observer.disconnect()}render(){var i,n;const e=((i=this.wallet)==null?void 0:i.badge_type)==="certified";return c`
1817
+ `;var Ye=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Re=class extends O{constructor(){super(),this.observer=new IntersectionObserver(()=>{}),this.visible=!1,this.imageSrc=void 0,this.imageLoading=!1,this.wallet=void 0,this.observer=new IntersectionObserver(e=>{e.forEach(i=>{i.isIntersecting?(this.visible=!0,this.fetchImageSrc()):this.visible=!1})},{threshold:.01})}firstUpdated(){this.observer.observe(this)}disconnectedCallback(){this.observer.disconnect()}render(){var i,n;const e=((i=this.wallet)==null?void 0:i.badge_type)==="certified";return c`
1818
1818
  <button>
1819
1819
  ${this.imageTemplate()}
1820
1820
  <wui-flex flexDirection="row" alignItems="center" justifyContent="center" gap="3xs">
1821
1821
  <wui-text
1822
1822
  variant="tiny-500"
1823
1823
  color="inherit"
1824
- class=${y(e?"certified":void 0)}
1824
+ class=${E(e?"certified":void 0)}
1825
1825
  >${(n=this.wallet)==null?void 0:n.name}</wui-text
1826
1826
  >
1827
1827
  ${e?c`<wui-icon size="sm" name="walletConnectBrown"></wui-icon>`:null}
@@ -1830,13 +1830,13 @@ Minimum version required to store current data is: `+t+`.
1830
1830
  `}imageTemplate(){var e,i;return!this.visible&&!this.imageSrc||this.imageLoading?this.shimmerTemplate():c`
1831
1831
  <wui-wallet-image
1832
1832
  size="md"
1833
- imageSrc=${y(this.imageSrc)}
1833
+ imageSrc=${E(this.imageSrc)}
1834
1834
  name=${(e=this.wallet)==null?void 0:e.name}
1835
1835
  .installed=${(i=this.wallet)==null?void 0:i.installed}
1836
1836
  badgeSize="sm"
1837
1837
  >
1838
1838
  </wui-wallet-image>
1839
- `}shimmerTemplate(){return c`<wui-shimmer width="56px" height="56px" borderRadius="xs"></wui-shimmer>`}async fetchImageSrc(){this.wallet&&(this.imageSrc=D.getWalletImage(this.wallet),!this.imageSrc&&(this.imageLoading=!0,this.imageSrc=await D.fetchWalletImage(this.wallet.image_id),this.imageLoading=!1))}};ye.styles=Io;Ge([v()],ye.prototype,"visible",void 0);Ge([v()],ye.prototype,"imageSrc",void 0);Ge([v()],ye.prototype,"imageLoading",void 0);Ge([u()],ye.prototype,"wallet",void 0);ye=Ge([C("w3m-all-wallets-list-item")],ye);const Eo=P`
1839
+ `}shimmerTemplate(){return c`<wui-shimmer width="56px" height="56px" borderRadius="xs"></wui-shimmer>`}async fetchImageSrc(){this.wallet&&(this.imageSrc=K.getWalletImage(this.wallet),!this.imageSrc&&(this.imageLoading=!0,this.imageSrc=await K.fetchWalletImage(this.wallet.image_id),this.imageLoading=!1))}};Re.styles=jo;Ye([_()],Re.prototype,"visible",void 0);Ye([_()],Re.prototype,"imageSrc",void 0);Ye([_()],Re.prototype,"imageLoading",void 0);Ye([u()],Re.prototype,"wallet",void 0);Re=Ye([B("w3m-all-wallets-list-item")],Re);const Do=N`
1840
1840
  wui-grid {
1841
1841
  max-height: clamp(360px, 400px, 80vh);
1842
1842
  overflow: scroll;
@@ -1865,7 +1865,7 @@ Minimum version required to store current data is: `+t+`.
1865
1865
  justify-content: center;
1866
1866
  grid-column: 1 / span 4;
1867
1867
  }
1868
- `;var Be=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const bi="local-paginator";let pe=class extends I{constructor(){super(),this.unsubscribe=[],this.paginationObserver=void 0,this.loading=!T.state.wallets.length,this.wallets=T.state.wallets,this.recommended=T.state.recommended,this.featured=T.state.featured,this.filteredWallets=T.state.filteredWallets,this.unsubscribe.push(T.subscribeKey("wallets",e=>this.wallets=e),T.subscribeKey("recommended",e=>this.recommended=e),T.subscribeKey("featured",e=>this.featured=e),T.subscribeKey("filteredWallets",e=>this.filteredWallets=e))}firstUpdated(){this.initialFetch(),this.createPaginationObserver()}disconnectedCallback(){var e;this.unsubscribe.forEach(i=>i()),(e=this.paginationObserver)==null||e.disconnect()}render(){return c`
1868
+ `;var je=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};const tn="local-paginator";let me=class extends O{constructor(){super(),this.unsubscribe=[],this.paginationObserver=void 0,this.loading=!z.state.wallets.length,this.wallets=z.state.wallets,this.recommended=z.state.recommended,this.featured=z.state.featured,this.filteredWallets=z.state.filteredWallets,this.unsubscribe.push(z.subscribeKey("wallets",e=>this.wallets=e),z.subscribeKey("recommended",e=>this.recommended=e),z.subscribeKey("featured",e=>this.featured=e),z.subscribeKey("filteredWallets",e=>this.filteredWallets=e))}firstUpdated(){this.initialFetch(),this.createPaginationObserver()}disconnectedCallback(){var e;this.unsubscribe.forEach(i=>i()),(e=this.paginationObserver)==null||e.disconnect()}render(){return c`
1869
1869
  <wui-grid
1870
1870
  data-scroll=${!this.loading}
1871
1871
  .padding=${["0","s","s","s"]}
@@ -1876,14 +1876,14 @@ Minimum version required to store current data is: `+t+`.
1876
1876
  ${this.loading?this.shimmerTemplate(16):this.walletsTemplate()}
1877
1877
  ${this.paginationLoaderTemplate()}
1878
1878
  </wui-grid>
1879
- `}async initialFetch(){var i;this.loading=!0;const e=(i=this.shadowRoot)==null?void 0:i.querySelector("wui-grid");e&&(await T.fetchWalletsByPage({page:1}),await e.animate([{opacity:1},{opacity:0}],{duration:200,fill:"forwards",easing:"ease"}).finished,this.loading=!1,e.animate([{opacity:0},{opacity:1}],{duration:200,fill:"forwards",easing:"ease"}))}shimmerTemplate(e,i){return[...Array(e)].map(()=>c`
1880
- <wui-card-select-loader type="wallet" id=${y(i)}></wui-card-select-loader>
1881
- `)}walletsTemplate(){var n;const e=((n=this.filteredWallets)==null?void 0:n.length)>0?E.uniqueBy([...this.featured,...this.recommended,...this.filteredWallets],"id"):E.uniqueBy([...this.featured,...this.recommended,...this.wallets],"id");return gt.markWalletsAsInstalled(e).map(o=>c`
1879
+ `}async initialFetch(){var i;this.loading=!0;const e=(i=this.shadowRoot)==null?void 0:i.querySelector("wui-grid");e&&(await z.fetchWalletsByPage({page:1}),await e.animate([{opacity:1},{opacity:0}],{duration:200,fill:"forwards",easing:"ease"}).finished,this.loading=!1,e.animate([{opacity:0},{opacity:1}],{duration:200,fill:"forwards",easing:"ease"}))}shimmerTemplate(e,i){return[...Array(e)].map(()=>c`
1880
+ <wui-card-select-loader type="wallet" id=${E(i)}></wui-card-select-loader>
1881
+ `)}walletsTemplate(){var n;const e=((n=this.filteredWallets)==null?void 0:n.length)>0?k.uniqueBy([...this.featured,...this.recommended,...this.filteredWallets],"id"):k.uniqueBy([...this.featured,...this.recommended,...this.wallets],"id");return pt.markWalletsAsInstalled(e).map(o=>c`
1882
1882
  <w3m-all-wallets-list-item
1883
1883
  @click=${()=>this.onConnectWallet(o)}
1884
1884
  .wallet=${o}
1885
1885
  ></w3m-all-wallets-list-item>
1886
- `)}paginationLoaderTemplate(){const{wallets:e,recommended:i,featured:n,count:o}=T.state,t=window.innerWidth<352?3:4,a=e.length+i.length;let l=Math.ceil(a/t)*t-a+t;return l-=e.length?n.length%t:0,o===0&&n.length>0?null:o===0||[...n,...e,...i].length<o?this.shimmerTemplate(l,bi):null}createPaginationObserver(){var i;const e=(i=this.shadowRoot)==null?void 0:i.querySelector(`#${bi}`);e&&(this.paginationObserver=new IntersectionObserver(([n])=>{if(n!=null&&n.isIntersecting&&!this.loading){const{page:o,count:t,wallets:a}=T.state;a.length<t&&T.fetchWalletsByPage({page:o+1})}}),this.paginationObserver.observe(e))}onConnectWallet(e){L.selectWalletConnector(e)}};pe.styles=Eo;Be([v()],pe.prototype,"loading",void 0);Be([v()],pe.prototype,"wallets",void 0);Be([v()],pe.prototype,"recommended",void 0);Be([v()],pe.prototype,"featured",void 0);Be([v()],pe.prototype,"filteredWallets",void 0);pe=Be([C("w3m-all-wallets-list")],pe);const Wo=P`
1886
+ `)}paginationLoaderTemplate(){const{wallets:e,recommended:i,featured:n,count:o}=z.state,t=window.innerWidth<352?3:4,a=e.length+i.length;let l=Math.ceil(a/t)*t-a+t;return l-=e.length?n.length%t:0,o===0&&n.length>0?null:o===0||[...n,...e,...i].length<o?this.shimmerTemplate(l,tn):null}createPaginationObserver(){var i;const e=(i=this.shadowRoot)==null?void 0:i.querySelector(`#${tn}`);e&&(this.paginationObserver=new IntersectionObserver(([n])=>{if(n!=null&&n.isIntersecting&&!this.loading){const{page:o,count:t,wallets:a}=z.state;a.length<t&&z.fetchWalletsByPage({page:o+1})}}),this.paginationObserver.observe(e))}onConnectWallet(e){M.selectWalletConnector(e)}};me.styles=Do;je([_()],me.prototype,"loading",void 0);je([_()],me.prototype,"wallets",void 0);je([_()],me.prototype,"recommended",void 0);je([_()],me.prototype,"featured",void 0);je([_()],me.prototype,"filteredWallets",void 0);me=je([B("w3m-all-wallets-list")],me);const zo=N`
1887
1887
  wui-grid,
1888
1888
  wui-loading-spinner,
1889
1889
  wui-flex {
@@ -1915,7 +1915,7 @@ Minimum version required to store current data is: `+t+`.
1915
1915
  grid-template-columns: repeat(2, 1fr);
1916
1916
  }
1917
1917
  }
1918
- `;var It=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Te=class extends I{constructor(){super(...arguments),this.prevQuery="",this.prevBadge=void 0,this.loading=!0,this.query=""}render(){return this.onSearch(),this.loading?c`<wui-loading-spinner color="accent-100"></wui-loading-spinner>`:this.walletsTemplate()}async onSearch(){(this.query.trim()!==this.prevQuery.trim()||this.badge!==this.prevBadge)&&(this.prevQuery=this.query,this.prevBadge=this.badge,this.loading=!0,await T.searchWallet({search:this.query,badge:this.badge}),this.loading=!1)}walletsTemplate(){const{search:e}=T.state,i=gt.markWalletsAsInstalled(e);return e.length?c`
1918
+ `;var xt=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let Oe=class extends O{constructor(){super(...arguments),this.prevQuery="",this.prevBadge=void 0,this.loading=!0,this.query=""}render(){return this.onSearch(),this.loading?c`<wui-loading-spinner color="accent-100"></wui-loading-spinner>`:this.walletsTemplate()}async onSearch(){(this.query.trim()!==this.prevQuery.trim()||this.badge!==this.prevBadge)&&(this.prevQuery=this.query,this.prevBadge=this.badge,this.loading=!0,await z.searchWallet({search:this.query,badge:this.badge}),this.loading=!1)}walletsTemplate(){const{search:e}=z.state,i=pt.markWalletsAsInstalled(e);return e.length?c`
1919
1919
  <wui-grid
1920
1920
  data-testid="wallet-list"
1921
1921
  .padding=${["0","s","s","s"]}
@@ -1950,7 +1950,7 @@ Minimum version required to store current data is: `+t+`.
1950
1950
  No Wallet found
1951
1951
  </wui-text>
1952
1952
  </wui-flex>
1953
- `}onConnectWallet(e){L.selectWalletConnector(e)}};Te.styles=Wo;It([v()],Te.prototype,"loading",void 0);It([u()],Te.prototype,"query",void 0);It([u()],Te.prototype,"badge",void 0);Te=It([C("w3m-all-wallets-search")],Te);var ai=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let pt=class extends I{constructor(){super(...arguments),this.search="",this.onDebouncedSearch=E.debounce(e=>{this.search=e})}render(){const e=this.search.length>=2;return c`
1953
+ `}onConnectWallet(e){M.selectWalletConnector(e)}};Oe.styles=zo;xt([_()],Oe.prototype,"loading",void 0);xt([u()],Oe.prototype,"query",void 0);xt([u()],Oe.prototype,"badge",void 0);Oe=xt([B("w3m-all-wallets-search")],Oe);var gi=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let ht=class extends O{constructor(){super(...arguments),this.search="",this.onDebouncedSearch=k.debounce(e=>{this.search=e})}render(){const e=this.search.length>=2;return c`
1954
1954
  <wui-flex .padding=${["0","s","s","s"]} gap="xs">
1955
1955
  <wui-search-bar @inputChange=${this.onInputChange.bind(this)}></wui-search-bar>
1956
1956
  <wui-certified-switch
@@ -1962,9 +1962,9 @@ Minimum version required to store current data is: `+t+`.
1962
1962
  </wui-flex>
1963
1963
  ${e||this.badge?c`<w3m-all-wallets-search
1964
1964
  query=${this.search}
1965
- badge=${y(this.badge)}
1966
- ></w3m-all-wallets-search>`:c`<w3m-all-wallets-list badge=${y(this.badge)}></w3m-all-wallets-list>`}
1967
- `}onInputChange(e){this.onDebouncedSearch(e.detail)}onClick(){if(this.badge==="certified"){this.badge=void 0;return}this.badge="certified",Qe.showSvg("Only WalletConnect certified",{icon:"walletConnectBrown",iconColor:"accent-100"})}qrButtonTemplate(){return E.isMobile()?c`
1965
+ badge=${E(this.badge)}
1966
+ ></w3m-all-wallets-search>`:c`<w3m-all-wallets-list badge=${E(this.badge)}></w3m-all-wallets-list>`}
1967
+ `}onInputChange(e){this.onDebouncedSearch(e.detail)}onClick(){if(this.badge==="certified"){this.badge=void 0;return}this.badge="certified",Xe.showSvg("Only WalletConnect certified",{icon:"walletConnectBrown",iconColor:"accent-100"})}qrButtonTemplate(){return k.isMobile()?c`
1968
1968
  <wui-icon-box
1969
1969
  size="lg"
1970
1970
  iconSize="xl"
@@ -1976,7 +1976,7 @@ Minimum version required to store current data is: `+t+`.
1976
1976
  borderColor="wui-accent-glass-010"
1977
1977
  @click=${this.onWalletConnectQr.bind(this)}
1978
1978
  ></wui-icon-box>
1979
- `:null}onWalletConnectQr(){O.push("ConnectingWalletConnect")}};ai([v()],pt.prototype,"search",void 0);ai([v()],pt.prototype,"badge",void 0);pt=ai([C("w3m-all-wallets-view")],pt);const So=P`
1979
+ `:null}onWalletConnectQr(){U.push("ConnectingWalletConnect")}};gi([_()],ht.prototype,"search",void 0);gi([_()],ht.prototype,"badge",void 0);ht=gi([B("w3m-all-wallets-view")],ht);const No=N`
1980
1980
  button {
1981
1981
  column-gap: var(--wui-spacing-s);
1982
1982
  padding: 11px 18px 11px var(--wui-spacing-s);
@@ -2060,12 +2060,12 @@ Minimum version required to store current data is: `+t+`.
2060
2060
  top: 50%;
2061
2061
  transform: translateY(-50%);
2062
2062
  }
2063
- `;var X=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let F=class extends I{constructor(){super(...arguments),this.tabIdx=void 0,this.variant="icon",this.disabled=!1,this.imageSrc=void 0,this.alt=void 0,this.chevron=!1,this.loading=!1}render(){return c`
2063
+ `;var ne=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let J=class extends O{constructor(){super(...arguments),this.tabIdx=void 0,this.variant="icon",this.disabled=!1,this.imageSrc=void 0,this.alt=void 0,this.chevron=!1,this.loading=!1}render(){return c`
2064
2064
  <button
2065
2065
  ?disabled=${this.loading?!0:!!this.disabled}
2066
2066
  data-loading=${this.loading}
2067
- data-iconvariant=${y(this.iconVariant)}
2068
- tabindex=${y(this.tabIdx)}
2067
+ data-iconvariant=${E(this.iconVariant)}
2068
+ tabindex=${E(this.tabIdx)}
2069
2069
  >
2070
2070
  ${this.loadingTemplate()} ${this.visualTemplate()}
2071
2071
  <wui-flex gap="3xs">
@@ -2086,7 +2086,7 @@ Minimum version required to store current data is: `+t+`.
2086
2086
  `}return null}loadingTemplate(){return this.loading?c`<wui-loading-spinner
2087
2087
  data-testid="wui-list-item-loading-spinner"
2088
2088
  color="fg-300"
2089
- ></wui-loading-spinner>`:c``}chevronTemplate(){return this.chevron?c`<wui-icon size="inherit" color="fg-200" name="chevronRight"></wui-icon>`:null}};F.styles=[A,M,So];X([u()],F.prototype,"icon",void 0);X([u()],F.prototype,"iconSize",void 0);X([u()],F.prototype,"tabIdx",void 0);X([u()],F.prototype,"variant",void 0);X([u()],F.prototype,"iconVariant",void 0);X([u({type:Boolean})],F.prototype,"disabled",void 0);X([u()],F.prototype,"imageSrc",void 0);X([u()],F.prototype,"alt",void 0);X([u({type:Boolean})],F.prototype,"chevron",void 0);X([u({type:Boolean})],F.prototype,"loading",void 0);F=X([C("wui-list-item")],F);var To=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let mi=class extends I{constructor(){var e;super(...arguments),this.wallet=(e=O.state.data)==null?void 0:e.wallet}render(){if(!this.wallet)throw new Error("w3m-downloads-view");return c`
2089
+ ></wui-loading-spinner>`:c``}chevronTemplate(){return this.chevron?c`<wui-icon size="inherit" color="fg-200" name="chevronRight"></wui-icon>`:null}};J.styles=[q,G,No];ne([u()],J.prototype,"icon",void 0);ne([u()],J.prototype,"iconSize",void 0);ne([u()],J.prototype,"tabIdx",void 0);ne([u()],J.prototype,"variant",void 0);ne([u()],J.prototype,"iconVariant",void 0);ne([u({type:Boolean})],J.prototype,"disabled",void 0);ne([u()],J.prototype,"imageSrc",void 0);ne([u()],J.prototype,"alt",void 0);ne([u({type:Boolean})],J.prototype,"chevron",void 0);ne([u({type:Boolean})],J.prototype,"loading",void 0);J=ne([B("wui-list-item")],J);var Mo=function(r,e,i,n){var o=arguments.length,t=o<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,i):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")t=Reflect.decorate(r,e,i,n);else for(var s=r.length-1;s>=0;s--)(a=r[s])&&(t=(o<3?a(t):o>3?a(e,i,t):a(e,i))||t);return o>3&&t&&Object.defineProperty(e,i,t),t};let nn=class extends O{constructor(){var e;super(...arguments),this.wallet=(e=U.state.data)==null?void 0:e.wallet}render(){if(!this.wallet)throw new Error("w3m-downloads-view");return c`
2090
2090
  <wui-flex gap="xs" flexDirection="column" .padding=${["s","s","l","s"]}>
2091
2091
  ${this.chromeTemplate()} ${this.iosTemplate()} ${this.androidTemplate()}
2092
2092
  ${this.homepageTemplate()}
@@ -2125,4 +2125,4 @@ Minimum version required to store current data is: `+t+`.
2125
2125
  >
2126
2126
  <wui-text variant="paragraph-500" color="fg-100">Website</wui-text>
2127
2127
  </wui-list-item>
2128
- `:null}onChromeStore(){var e;(e=this.wallet)!=null&&e.chrome_store&&E.openHref(this.wallet.chrome_store,"_blank")}onAppStore(){var e;(e=this.wallet)!=null&&e.app_store&&E.openHref(this.wallet.app_store,"_blank")}onPlayStore(){var e;(e=this.wallet)!=null&&e.play_store&&E.openHref(this.wallet.play_store,"_blank")}onHomePage(){var e;(e=this.wallet)!=null&&e.homepage&&E.openHref(this.wallet.homepage,"_blank")}};mi=To([C("w3m-downloads-view")],mi);export{pt as W3mAllWalletsView,qt as W3mConnectingWcBasicView,mi as W3mDownloadsView};
2128
+ `:null}onChromeStore(){var e;(e=this.wallet)!=null&&e.chrome_store&&k.openHref(this.wallet.chrome_store,"_blank")}onAppStore(){var e;(e=this.wallet)!=null&&e.app_store&&k.openHref(this.wallet.app_store,"_blank")}onPlayStore(){var e;(e=this.wallet)!=null&&e.play_store&&k.openHref(this.wallet.play_store,"_blank")}onHomePage(){var e;(e=this.wallet)!=null&&e.homepage&&k.openHref(this.wallet.homepage,"_blank")}};nn=Mo([B("w3m-downloads-view")],nn);export{ht as W3mAllWalletsView,oi as W3mConnectingWcBasicView,nn as W3mDownloadsView};