@dcl/shop 0.1.0-30270468476.commit-071c9d3 → 0.1.0-30276533246.commit-f8e4e8f

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 (208) hide show
  1. package/assets/Activity-hXLcKq2h.js +287 -0
  2. package/assets/{AnimatedBackground-BBExv7oB.js → AnimatedBackground-dbV7gtfn.js} +1 -1
  3. package/assets/Assets-CMMyLxYK.js +787 -0
  4. package/assets/{Assets.styles-B1CaeypS.js → Assets.styles-0t7WQHO0.js} +94 -21
  5. package/assets/Authorizations-UmG-Df3r.js +182 -0
  6. package/assets/{Button-C0mFw7Q0.js → Button-DZEnGtFb.js} +3 -3
  7. package/assets/Cart-C_kThny7.css +1 -0
  8. package/assets/Cart-Cv-0Hvub.js +1 -0
  9. package/assets/{CircularProgress-CAwo3QqI.js → CircularProgress-BJ3mR2Td.js} +3 -3
  10. package/assets/{Collection-DMfTR7b6.js → Collection-B2vZD-tj.js} +2 -2
  11. package/assets/CollectionCarousel--kzVfaO5.js +292 -0
  12. package/assets/{Creator-BOr7PKtc.js → Creator-q1uyTJMB.js} +1 -1
  13. package/assets/{ExchangeController-D7O0HVIS.js → ExchangeController-aW_MlhrS.js} +1 -1
  14. package/assets/GetCredits-C_zVvwJv.js +611 -0
  15. package/assets/{HelpersUtil-BhSIsEQG.js → HelpersUtil-ClO_3Jc1.js} +1 -1
  16. package/assets/{ImportListings-CgSizNHs.js → ImportListings-Bkbdthc9.js} +2 -2
  17. package/assets/ImportListings-CgB7Xjb_.css +1 -0
  18. package/assets/{ItemDetail-DSWLL-Uv.css → ItemDetail-CkmPrObF.css} +1 -1
  19. package/assets/ItemDetail-mOl_Kn1H.js +2406 -0
  20. package/assets/{LoadMore-DseV0MlP.js → LoadMore-EHn5w6iP.js} +1 -1
  21. package/assets/{MarketCheckout-DB0ndatN.js → MarketCheckout-dZs9K_G4.js} +1 -1
  22. package/assets/{MenuList-D2U4AWro.js → MenuList-CMbA1PQj.js} +2 -2
  23. package/assets/{MyAssets-CPerVCvd.js → MyAssets-BJI5V-2P.js} +4 -4
  24. package/assets/MyFavorites-BguSqCh7.js +1 -0
  25. package/assets/{NotFound-BZbWWGpU.js → NotFound-i-z6JKyV.js} +1 -1
  26. package/assets/NotificationsBell-C_yrd9Xo.js +34 -0
  27. package/assets/{StoreSettings-tUVa8Io9.js → StoreSettings-DZkFM1rM.js} +5 -5
  28. package/assets/{Success-CQZAhwk3.js → Success-Dnd1gDEe.js} +2 -2
  29. package/assets/{SwapController-IzNMQ24o.js → SwapController-3J3CaWML.js} +1 -1
  30. package/assets/{Tooltip-ChLdaLYy.js → Tooltip-D02GGolw.js} +1 -1
  31. package/assets/TradeService-CD7-qmvB.js +1 -0
  32. package/assets/{W3MFrameProviderSingleton-BztPgidQ.js → W3MFrameProviderSingleton-C03Pb4B-.js} +3 -3
  33. package/assets/{WebCryptoP256-6gTeaG7K.js → WebCryptoP256-BNVfqOHe.js} +1 -1
  34. package/assets/authorizations-Cp6LZG2p.js +1 -0
  35. package/assets/{basic-CcHHcm5S.js → basic-BiNYECPU.js} +1 -1
  36. package/assets/{biconomy-BYyRZm8p.js → biconomy-sueKb6TZ.js} +1 -1
  37. package/assets/{builder-BoAWy25K.js → builder-DlCHGdvc.js} +1 -1
  38. package/assets/buy-B2kHW0nr.js +1 -0
  39. package/assets/buy-gasless-C1AGMpyR.js +1 -0
  40. package/assets/{cart-checkout-Bm6eeQha.js → cart-checkout-gXQTm1Je.js} +1 -1
  41. package/assets/{categories-BYiSMngY.js → categories-C3OIiumf.js} +6 -6
  42. package/assets/categories-YFBLpDYC.css +1 -0
  43. package/assets/{ccip-D-SUSHY2.js → ccip-DN5nMPw-.js} +1 -1
  44. package/assets/{ccip-dayWThwi.js → ccip-DPUSAyAP.js} +1 -1
  45. package/assets/{collection-Bth8_k5I.js → collection-DreRuzb5.js} +1 -1
  46. package/assets/{controller-B9W16qW5.js → controller-3Y3P-qSA.js} +2 -2
  47. package/assets/{core-B-5sR4Al.js → core-DNLw0r_l.js} +4 -4
  48. package/assets/{custom-DT3TVg96.js → custom-B2MFF440.js} +1 -1
  49. package/assets/{data-capture-yB25uWoP.js → data-capture-BwNOBkUG.js} +1 -1
  50. package/assets/{email-B1UyBbY4.js → email-DsF1SFzq.js} +1 -1
  51. package/assets/{embedded-wallet-BtccJaHj.js → embedded-wallet-CqXzyQH3.js} +1 -1
  52. package/assets/{emotion-styled.browser.esm-RqaRvwIJ.js → emotion-styled.browser.esm-KRbVdXBp.js} +1 -1
  53. package/assets/{engine-D4vflTHi.js → engine-Bt0lIrAq.js} +1 -1
  54. package/assets/{errors-Dqf6lF1i.js → errors-DRre14b2.js} +1 -1
  55. package/assets/{estimate-l1-fee-DwvW303J.js → estimate-l1-fee-D2kU8y3A.js} +1 -1
  56. package/assets/{execute-BaUM8WN1.js → execute-CxJ661iN.js} +2 -2
  57. package/assets/{features-Cejx8412.js → features-C_M-5faE.js} +1 -1
  58. package/assets/{fetchTokenMetadata-hqfW0OZq.js → fetchTokenMetadata-_p-iZKio.js} +2 -2
  59. package/assets/{get-ecosystem-wallet-info-CceN8ViP.js → get-ecosystem-wallet-info-86ruW1Fa.js} +1 -1
  60. package/assets/{getBalance-BOq60Htf.js → getBalance-unWh_KQT.js} +1 -1
  61. package/assets/{getNFT-WQ6wLGOs.js → getNFT-BGqdTpXh.js} +1 -1
  62. package/assets/{getNFT-BT1uhLCc.js → getNFT-CIgk3nT1.js} +1 -1
  63. package/assets/{getThemeProps-CxqsFRQQ.js → getThemeProps-BSd7rKgs.js} +1 -1
  64. package/assets/governance-DnazlIjy.webp +0 -0
  65. package/assets/{hashTypedData-ldGY6czM.js → hashTypedData-BTWIstyF.js} +1 -1
  66. package/assets/{hashTypedData-DIRqpKJD.js → hashTypedData-QLpD25u5.js} +1 -1
  67. package/assets/identity-B4DXDuJP.webp +0 -0
  68. package/assets/{import-BfcW9VC0.js → import-C8mG5kpp.js} +1 -1
  69. package/assets/{in-app-RHMiKi43.js → in-app-BhtePNrr.js} +1 -1
  70. package/assets/{in-app-wallet-calls-CHCsaG0p.js → in-app-wallet-calls-CshV6paA.js} +1 -1
  71. package/assets/{index-CaidRfGp.js → index-B5y-D5X8.js} +1 -1
  72. package/assets/{index-DvkrX5ye.js → index-BHZuyKoD.js} +1 -1
  73. package/assets/{index-B1mN6E1A.js → index-BQmilESQ.js} +1 -1
  74. package/assets/index-BR3whuSX.js +4 -0
  75. package/assets/{index-BJmcBnq5.js → index-BW895N7Q.js} +1 -1
  76. package/assets/{index-CIff5ZGB.js → index-BjEtYT4r.js} +1 -1
  77. package/assets/{index-DO2Pr01D.js → index-Bm3DarTl.js} +1 -1
  78. package/assets/{index-DwtkT27Z.js → index-BnmhOYyH.js} +1 -1
  79. package/assets/{index-MVkp8e7J.js → index-By453YwH.js} +3 -3
  80. package/assets/{index-Dm5e5M85.js → index-ByXnBudX.js} +1 -1
  81. package/assets/{index-CJGCs0w1.js → index-C2uZoNuk.js} +1 -1
  82. package/assets/{index-DyYQbYH-.js → index-C8v7zDBJ.js} +1 -1
  83. package/assets/{index-ITKVn9c6.js → index-CLcox4E7.js} +1 -1
  84. package/assets/{index-B2vHUvUF.js → index-COdiwi90.js} +1 -1
  85. package/assets/{index-DdvwPc4-.js → index-COv1RTFu.js} +2 -2
  86. package/assets/{index-FGgU3KKK.js → index-CQCEoI0f.js} +1 -1
  87. package/assets/{index-BjZzDuYa.js → index-CZHmX5J8.js} +1 -1
  88. package/assets/{index-CDISO1MK.js → index-CZat8yuA.js} +1 -1
  89. package/assets/{index-BMGLnaLh.js → index-C_Gr4cGQ.js} +1 -1
  90. package/assets/{index-C0CWtzpF.js → index-CbMR0Bj_.js} +1 -1
  91. package/assets/{index-DYEbFvRt.js → index-Cd5MdlQV.js} +1 -1
  92. package/assets/{index-D7-WGuPj.js → index-CjbITVZo.js} +1 -1
  93. package/assets/{index-BhbG_RoV.js → index-CkOuE7FD.js} +1 -1
  94. package/assets/{index-DTXSnpsP.js → index-Cn4XSZr0.js} +1 -1
  95. package/assets/{index-_mUwznhX.js → index-CoUgtRBd.js} +2 -2
  96. package/assets/{index-BWZ36vyh.js → index-Cy1iqq4E.js} +1 -1
  97. package/assets/{index-Dy1DXK_P.js → index-CyD5tTbO.js} +1 -1
  98. package/assets/{index-CBBoSPJo.js → index-CzQo6jjU.js} +1 -1
  99. package/assets/{index-Cm2XuGaZ.js → index-D14A8-Ez.js} +1 -1
  100. package/assets/{index-DZak9MEk.js → index-D2w8m12L.js} +3 -3
  101. package/assets/{index-yQapraNh.js → index-DFiDXKfN.js} +1 -1
  102. package/assets/{index-CiuTWGL8.js → index-DIpKr5PH.js} +1 -1
  103. package/assets/{index-DTkbLRUZ.js → index-DNq_ZzO9.js} +1 -1
  104. package/assets/{index-CEin_PWO.js → index-DOpvn00g.js} +1 -1
  105. package/assets/{index-DXOEYfzl.js → index-DTdfAXzC.js} +3 -3
  106. package/assets/{index-BMqoO8d3.js → index-DTu4F44-.js} +1 -1
  107. package/assets/{index-Co1s6m53.js → index-DW7iqXK6.js} +1 -1
  108. package/assets/{index-ErHUvXaQ.js → index-DXk86Ivm.js} +1 -1
  109. package/assets/{index-UF7uwKmo.js → index-DYq_oVmx.js} +1 -1
  110. package/assets/{index-CA3xi9-C.js → index-DekG2ccV.js} +1 -1
  111. package/assets/{index-SKjibbg2.js → index-DkF53JBL.js} +1 -1
  112. package/assets/{index-CmzbojcQ.js → index-DsxE94hA.js} +1 -1
  113. package/assets/index-DwufS2l2.css +1 -0
  114. package/assets/{index-0vETaKW6.js → index-Dz09ibiS.js} +2 -2
  115. package/assets/{index-DP6tma9C.js → index-OZxfsC7n.js} +1 -1
  116. package/assets/{index-BVZMk7zF.js → index-XVXsmUHu.js} +1 -1
  117. package/assets/index-ZWDXIF6O.js +312 -0
  118. package/assets/{index-_75wkcmX.js → index-ezQi9fE0.js} +1 -1
  119. package/assets/{index-D887F5ux.js → index-jMf-NKbX.js} +1 -1
  120. package/assets/{index-IYJz3MPB.js → index-m5nQVxYP.js} +1 -1
  121. package/assets/index-phHbAFw8.js +2 -0
  122. package/assets/{index-SfExPdbm.js → index-w8qdvQSI.js} +1 -1
  123. package/assets/{index.es-DQGcjZw1.js → index.es-B_VDxdYa.js} +1 -1
  124. package/assets/{index.es-CepefRlj.js → index.es-CH1EpUFZ.js} +4 -4
  125. package/assets/{index.es-l2IY2ojC.js → index.es-CUbFS9-7.js} +1 -1
  126. package/assets/invite-BfwIhP2C.webp +0 -0
  127. package/assets/{localBatchGatewayRequest-C7J9kEpF.js → localBatchGatewayRequest-gUKVbACI.js} +1 -1
  128. package/assets/mana-rate-BkFbk0kZ.js +1 -0
  129. package/assets/{networks-D0XKaUxt.js → networks-Bd6TgNp5.js} +1 -1
  130. package/assets/{onramp-jfcruKoz.js → onramp-CsEoJ4ye.js} +1 -1
  131. package/assets/{openzeppelin-CcCPYRLb.js → openzeppelin-CvVwdooA.js} +1 -1
  132. package/assets/pack-chest-BX_j84xW.webp +0 -0
  133. package/assets/pack-coins-BDh1ZDbh.webp +0 -0
  134. package/assets/pack-stacks-D-V2jSHW.webp +0 -0
  135. package/assets/packs-backdrop-BcXiUPeP.webp +0 -0
  136. package/assets/{parseNft-Bh8hbeUO.js → parseNft-BuGslaHc.js} +2 -2
  137. package/assets/{parseSignature-CG87M4TZ.js → parseSignature-CJjL6IIG.js} +1 -1
  138. package/assets/{parseSignature-lC7f5E0E.js → parseSignature-cMUHSEHb.js} +3 -3
  139. package/assets/{passkeys-Bj-lvFCY.js → passkeys-CU5Dd8fW.js} +1 -1
  140. package/assets/{pay-with-exchange-BeP2M3Qv.js → pay-with-exchange-D5anhnsP.js} +1 -1
  141. package/assets/{qr-overlay-BpfmJGAi.js → qr-overlay-D7N8zFXO.js} +1 -1
  142. package/assets/{receive-COD7fdso.js → receive-D1bfspT3.js} +1 -1
  143. package/assets/{resolveImplementation-roeco7Ws.js → resolveImplementation-yZJLHNcT.js} +1 -1
  144. package/assets/{rpc-CsWpew24.js → rpc-DR3Pyl3d.js} +1 -1
  145. package/assets/{secp256k1-cCdOUO1G.js → secp256k1-CphVajjd.js} +1 -1
  146. package/assets/{secp256k1-DDF768fe.js → secp256k1-DDxmRKuj.js} +1 -1
  147. package/assets/{secp256k1-CgFtQxlZ.js → secp256k1-zVdNPaTf.js} +1 -1
  148. package/assets/{send-BAFhKY00.js → send-CQZNNlKI.js} +1 -1
  149. package/assets/{send-batch-transaction-BLJJXFHU.js → send-batch-transaction-DbJ2GI0Z.js} +1 -1
  150. package/assets/{send-eip712-transaction-Bz71BkCW.js → send-eip712-transaction-g0RXPeLW.js} +2 -2
  151. package/assets/{send-gasless-transaction-D71RFEDG.js → send-gasless-transaction-hk-PL2RZ.js} +2 -2
  152. package/assets/{send-transaction-SAnk0Q__.js → send-transaction-Qs7YNICs.js} +2 -2
  153. package/assets/sendMetaTransaction-Bky8YK8T.js +1 -0
  154. package/assets/{sendRawTransaction-BsLS3Akr.js → sendRawTransaction-FrBDfTMh.js} +3 -3
  155. package/assets/{serializeTransaction-BCs_Pp_j.js → serializeTransaction-BY81pWis.js} +1 -1
  156. package/assets/{session-proposal-CiZSuAhW.js → session-proposal-DJycTDzh.js} +1 -1
  157. package/assets/{session-request-9Ve-p2ZN.js → session-request-CvXHUfW2.js} +2 -2
  158. package/assets/{signing-BonuLK2W.js → signing-C-pXPlUm.js} +3 -3
  159. package/assets/{socials-Bxj_1Z0E.js → socials-ZM1DPB14.js} +1 -1
  160. package/assets/{swaps-CuOjno-D.js → swaps-DWHYQxSV.js} +1 -1
  161. package/assets/{thirdweb-DZ7PpVq9.js → thirdweb-CdJoXk5x.js} +3 -3
  162. package/assets/{to-serializable-transaction-CMEZmVXF.js → to-serializable-transaction-D53T_ITW.js} +2 -2
  163. package/assets/trade-encoding-C0CKvlMZ.js +1 -0
  164. package/assets/{transactionReceipt-DeaouCg8.js → transactionReceipt-DcSpquTW.js} +1 -1
  165. package/assets/{transactions-D2Vd5hsC.js → transactions-BH9skO3z.js} +1 -1
  166. package/assets/{useCreditPacks-CvGo72Yh.js → useCreditPacks-DA-NvTNC.js} +1 -1
  167. package/assets/{useInfiniteGrid-BP6y2F0x.js → useInfiniteGrid-Byw1k8Mi.js} +1 -1
  168. package/assets/useManaRate-CslU6wit.js +1 -0
  169. package/assets/{useStore-D0aVskRf.js → useStore-ZMBovGpH.js} +1 -1
  170. package/assets/useTheme-DqyRDQjm.js +1 -0
  171. package/assets/{verifyHash-BP78LGMF.js → verifyHash-DVsBhfqm.js} +1 -1
  172. package/assets/{w3m-modal-Bhuvkbk7.js → w3m-modal-BJOvzFgf.js} +1 -1
  173. package/assets/{w3m-modal-DlPGU9Hi.js → w3m-modal-r_B_A1Y3.js} +1 -1
  174. package/assets/{wait-for-tx-receipt-c8TXyqT7.js → wait-for-tx-receipt-BWOrjd7S.js} +1 -1
  175. package/assets/{wallets-uvClMVWd.js → wallets-CQrQiCdZ.js} +5 -5
  176. package/assets/{web-connector-Bkzu3qgs.js → web-connector-b-JbgcxK.js} +3 -3
  177. package/assets/world-B-9aPlxu.webp +0 -0
  178. package/assets/{writeContract-B7ucurrF.js → writeContract-CRMw42Kd.js} +1 -1
  179. package/assets/{zoraTestnet-Dw1u3z7B.js → zoraTestnet-ziGwenPM.js} +1 -1
  180. package/index.html +11 -11
  181. package/package.json +2 -2
  182. package/assets/Activity-Cz1ikBbA.js +0 -284
  183. package/assets/Assets-CDD55lk7.js +0 -758
  184. package/assets/Authorizations-ZBky7Fps.js +0 -175
  185. package/assets/Cart-BaVkpmjN.css +0 -1
  186. package/assets/Cart-BoKysdAy.js +0 -3
  187. package/assets/CollectionCarousel-ClxfOuf0.js +0 -1
  188. package/assets/GetCredits-81R0mokS.js +0 -1
  189. package/assets/ImportListings-Dx8BzO4r.css +0 -1
  190. package/assets/ItemDetail-HSda4F4J.js +0 -1762
  191. package/assets/MyFavorites-C9DmnRPJ.js +0 -3
  192. package/assets/NotificationsBell-CcSL0fus.js +0 -34
  193. package/assets/TradeService-C9FGvByw.js +0 -1
  194. package/assets/authorizations-LVujlH7N.js +0 -1
  195. package/assets/buy-C5fAE4Tk.js +0 -1
  196. package/assets/buy-gasless-DkWqG4cD.js +0 -1
  197. package/assets/categories-_8oO8Yih.css +0 -1
  198. package/assets/index-BC0JGAsO.js +0 -2
  199. package/assets/index-C5gvQ6I4.js +0 -4
  200. package/assets/index-D3DtvRSj.css +0 -1
  201. package/assets/index-DKn89nIW.js +0 -312
  202. package/assets/index-HN6Rk25C.js +0 -1
  203. package/assets/mana-rate-ClCow8js.js +0 -1
  204. package/assets/pack-chips--HnOpf5U.webp +0 -0
  205. package/assets/sendMetaTransaction-CiO3jI6F.js +0 -1
  206. package/assets/trade-encoding-BNfrO5uz.js +0 -1
  207. package/assets/useManaRate-BgA2oiUd.js +0 -1
  208. package/assets/useTheme-BbjtAD5a.js +0 -1
@@ -0,0 +1,611 @@
1
+ import{u as ae,b as de,r as c,j as t}from"./react-BW1xvPTF.js";import{s as i,K as e,R,x as ce,t as r,u as le,b as pe,j as g,an as xe,e as l,J as G,k as H,I as J,C as Z,f as ue}from"./index-ZWDXIF6O.js";import{R as M}from"./resume-buy-Bf0zIH7y.js";import{R as ge}from"./cart-checkout-gXQTm1Je.js";import{l as he}from"./loader-logo-BzY9EKdC.js";import{u as fe,p as me,c as be,i as we}from"./useCreditPacks-DA-NvTNC.js";import{C as ye}from"./CircularProgress-BJ3mR2Td.js";import"./sentry-BV_ZSgtd.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CtVvB8eG.js";import"./intl-CBcMB1D2.js";const j="https://cdn.decentraland.org/@dcl/shop/0.1.0-30276533246.commit-f8e4e8f/assets/pack-coins-BDh1ZDbh.webp",ee="https://cdn.decentraland.org/@dcl/shop/0.1.0-30276533246.commit-f8e4e8f/assets/pack-stacks-D-V2jSHW.webp",te="https://cdn.decentraland.org/@dcl/shop/0.1.0-30276533246.commit-f8e4e8f/assets/pack-chest-BX_j84xW.webp",ke="https://cdn.decentraland.org/@dcl/shop/0.1.0-30276533246.commit-f8e4e8f/assets/credit-coin-CmcTCd5i.webp",Ce="data:image/svg+xml,%3csvg%20width='60'%20height='60'%20viewBox='0%200%2060%2060'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='60'%20height='60'%20rx='30'%20fill='%2334CE77'/%3e%3cpath%20d='M21.6583%2046.1067L11.4656%2036.0591C10.1688%2034.829%2010.1905%2032.7207%2011.4769%2031.4622L13.6868%2029.3591C14.9732%2028.1006%2017.1615%2028.1058%2018.4582%2029.3359L23.8747%2034.6197L41.9704%2015.6527C43.2568%2014.3942%2045.4291%2014.2093%2046.7258%2015.4394L48.8765%2017.3628C50.1732%2018.5929%2050.3491%2020.6844%2049.0626%2021.9429L26.6112%2045.8766C25.1433%2047.342%2022.955%2047.3368%2021.6583%2046.1067Z'%20fill='%23FCFCFC'/%3e%3c/svg%3e",je="https://cdn.decentraland.org/@dcl/shop/0.1.0-30276533246.commit-f8e4e8f/assets/packs-backdrop-BcXiUPeP.webp",N="linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0)",$e=i.div`
2
+ display: flex;
3
+ flex-direction: column;
4
+ gap: 24px;
5
+ `,ve=i.section`
6
+ position: relative;
7
+ isolation: isolate;
8
+ display: flex;
9
+ flex-direction: column;
10
+ align-items: center;
11
+ border-radius: ${e.radius.banner};
12
+ overflow: hidden;
13
+ padding: 82px clamp(16px, 7.06%, 122px) 129px;
14
+
15
+ ${e.media.down("lg")} {
16
+ padding: 48px 24px 56px;
17
+ }
18
+ ${e.media.down("mobile")} {
19
+ padding: 32px 16px 40px;
20
+ }
21
+ `,Se=i.div`
22
+ position: absolute;
23
+ inset: 0;
24
+ z-index: -1;
25
+ opacity: 0.9;
26
+ pointer-events: none;
27
+ background-image: url(${je});
28
+ background-size: cover;
29
+ background-position: 50% 96%;
30
+ background-repeat: no-repeat;
31
+ `,Pe=i.div`
32
+ width: 100%;
33
+ max-width: 1478px;
34
+ display: flex;
35
+ flex-direction: column;
36
+ align-items: center;
37
+ gap: 52px;
38
+
39
+ ${e.media.down("lg")} {
40
+ gap: 32px;
41
+ }
42
+ `,_e=i.header`
43
+ display: flex;
44
+ flex-direction: column;
45
+ align-items: center;
46
+ gap: 12px;
47
+ width: 100%;
48
+ text-align: center;
49
+ `,Re=i.h1`
50
+ margin: 0;
51
+ font-family: ${e.font.sans};
52
+ font-size: 40px;
53
+ font-weight: 700;
54
+ line-height: 1.167;
55
+ color: ${e.colors.white};
56
+ text-transform: capitalize;
57
+
58
+ ${e.media.down("mobile")} {
59
+ font-size: 28px;
60
+ }
61
+ `,ze=i.div`
62
+ display: flex;
63
+ flex-wrap: wrap;
64
+ align-items: center;
65
+ justify-content: center;
66
+ gap: 8px;
67
+ `,Ae=i.p`
68
+ margin: 0;
69
+ font-family: ${e.font.sans};
70
+ font-size: 24px;
71
+ font-weight: 500;
72
+ line-height: 1.334;
73
+ color: ${e.colors.media};
74
+
75
+ ${e.media.down("mobile")} {
76
+ font-size: 16px;
77
+ }
78
+ `,Be=i.a`
79
+ display: inline-flex;
80
+ align-items: center;
81
+ gap: 2px;
82
+ font-family: ${e.font.sans};
83
+ font-size: 20px;
84
+ font-weight: 500;
85
+ line-height: 30px;
86
+ color: ${e.colors.white};
87
+ text-decoration: underline;
88
+ text-underline-offset: 2px;
89
+
90
+ .ico {
91
+ width: 26px;
92
+ height: 26px;
93
+ }
94
+ &:hover {
95
+ opacity: 0.85;
96
+ }
97
+ &:focus-visible {
98
+ outline: 2px solid ${e.colors.white};
99
+ outline-offset: 3px;
100
+ border-radius: ${e.radius.chip};
101
+ }
102
+
103
+ ${e.media.down("mobile")} {
104
+ font-size: 15px;
105
+ line-height: 22px;
106
+
107
+ .ico {
108
+ width: 18px;
109
+ height: 18px;
110
+ }
111
+ }
112
+ `,Ee=i.p`
113
+ margin: 0;
114
+ padding: 10px 16px;
115
+ border-radius: ${e.radius.btn};
116
+ background: rgba(21, 21, 21, 0.4);
117
+ font-family: ${e.font.sans};
118
+ font-size: 14px;
119
+ line-height: 1.6;
120
+ color: ${e.colors.media};
121
+ text-align: center;
122
+ `,U=i.div`
123
+ display: grid;
124
+ grid-template-columns: repeat(4, minmax(0, 1fr));
125
+ gap: 24px;
126
+ width: 100%;
127
+
128
+ /* Two per row from tablet all the way down to the narrowest phone (Figma node 1654-374664): one
129
+ full-width pack per row wastes the height and pushes the fourth option far below the fold. */
130
+ @media (max-width: 980px) {
131
+ grid-template-columns: repeat(2, minmax(0, 1fr));
132
+ row-gap: 40px;
133
+ }
134
+ @media (max-width: 520px) {
135
+ gap: 12px;
136
+ row-gap: 24px;
137
+ }
138
+ `,K=i.button`
139
+ position: relative;
140
+ display: flex;
141
+ flex-direction: column;
142
+ align-items: center;
143
+ gap: 48px;
144
+ min-width: 0;
145
+ padding: 24px 16px 16px;
146
+ border: 0;
147
+ border-radius: ${e.radius.banner};
148
+ background: rgba(21, 21, 21, 0.4);
149
+ backdrop-filter: blur(3px);
150
+ -webkit-backdrop-filter: blur(3px);
151
+ color: ${e.colors.white};
152
+ cursor: pointer;
153
+ text-align: center;
154
+ transition:
155
+ background 0.15s ease,
156
+ box-shadow 0.15s ease;
157
+
158
+ &::before,
159
+ &::after {
160
+ content: '';
161
+ position: absolute;
162
+ border-radius: inherit;
163
+ pointer-events: none;
164
+ -webkit-mask: ${N};
165
+ -webkit-mask-composite: xor;
166
+ mask: ${N};
167
+ mask-composite: exclude;
168
+ transition: opacity 0.15s ease;
169
+ }
170
+ /* Hairline outline (Figma: 1px Flare stroke). */
171
+ &::before {
172
+ inset: 0;
173
+ padding: 1px;
174
+ background: ${e.gradients.flare};
175
+ }
176
+ /* Hover ring: a 6px warm outline floating in the 4px gutter outside the card. */
177
+ &::after {
178
+ inset: -10px;
179
+ padding: 6px;
180
+ border-radius: 30px;
181
+ background: ${e.gradients.ember};
182
+ opacity: 0;
183
+ }
184
+
185
+ &:hover,
186
+ &:focus-visible,
187
+ &:active {
188
+ background: ${e.colors.accent};
189
+ box-shadow: 0 0 8px ${e.colors.brandViolet};
190
+ }
191
+ &:hover::before,
192
+ &:focus-visible::before,
193
+ &:active::before {
194
+ opacity: 0;
195
+ }
196
+ &:hover::after,
197
+ &:focus-visible::after,
198
+ &:active::after {
199
+ opacity: 1;
200
+ }
201
+ &:focus-visible {
202
+ outline: none;
203
+ }
204
+
205
+ /* Loading placeholder shell — same card, none of the interaction. */
206
+ &[data-skeleton='true'] {
207
+ cursor: default;
208
+ }
209
+ &[data-skeleton='true']:hover {
210
+ background: rgba(21, 21, 21, 0.4);
211
+ box-shadow: none;
212
+ }
213
+ &[data-skeleton='true']:hover::before {
214
+ opacity: 1;
215
+ }
216
+ &[data-skeleton='true']:hover::after {
217
+ opacity: 0;
218
+ }
219
+
220
+ ${e.media.down("mobile")} {
221
+ gap: 24px;
222
+ }
223
+ `,Te=i.span`
224
+ position: absolute;
225
+ top: -18px;
226
+ left: 50%;
227
+ transform: translateX(-50%);
228
+ z-index: 2;
229
+ display: inline-flex;
230
+ align-items: center;
231
+ gap: 4px;
232
+ padding: 6px 12px 6px 8px;
233
+ border-radius: ${e.radius.pill};
234
+ background: ${e.gradients.flare};
235
+ font-family: ${e.font.sans};
236
+ font-size: 20px;
237
+ font-weight: 500;
238
+ line-height: 24px;
239
+ color: ${e.colors.white};
240
+ white-space: nowrap;
241
+
242
+ .ico {
243
+ width: 24px;
244
+ height: 24px;
245
+ }
246
+
247
+ ${e.media.down("mobile")} {
248
+ top: -14px;
249
+ padding: 4px 10px 4px 6px;
250
+ font-size: 14px;
251
+ line-height: 20px;
252
+
253
+ .ico {
254
+ width: 18px;
255
+ height: 18px;
256
+ }
257
+ }
258
+ `,D=i.span`
259
+ display: flex;
260
+ flex-direction: column;
261
+ align-items: center;
262
+ gap: 12px;
263
+ padding-top: 32px;
264
+
265
+ ${e.media.down("mobile")} {
266
+ padding-top: 16px;
267
+ }
268
+ `,O=i.span`
269
+ display: flex;
270
+ flex-direction: column;
271
+ align-items: center;
272
+ gap: 12px;
273
+ width: 100%;
274
+ `,Le=i.span`
275
+ display: flex;
276
+ align-items: center;
277
+ gap: 8px;
278
+
279
+ .ico {
280
+ width: 28.21px;
281
+ height: 29.79px;
282
+ color: ${e.colors.softWhite};
283
+ }
284
+ `,Ie=i.span`
285
+ font-family: ${e.font.sans};
286
+ font-size: 40px;
287
+ font-weight: 800;
288
+ line-height: 30px;
289
+ color: ${e.colors.white};
290
+ `,Fe=i.span`
291
+ font-family: ${e.font.sans};
292
+ font-size: 20px;
293
+ font-weight: 500;
294
+ line-height: 15px;
295
+ color: ${e.colors.media};
296
+ text-transform: uppercase;
297
+ `,Ge=i.span`
298
+ display: block;
299
+ width: 253.5px;
300
+ max-width: 100%;
301
+ aspect-ratio: 1;
302
+
303
+ img {
304
+ display: block;
305
+ width: 100%;
306
+ height: 100%;
307
+ object-fit: contain;
308
+ }
309
+
310
+ /* One column: a full-size render per card would make the page absurdly tall. */
311
+ @media (max-width: 520px) {
312
+ width: 200px;
313
+ }
314
+ `,He=i.span`
315
+ display: flex;
316
+ align-items: center;
317
+ justify-content: center;
318
+ width: 100%;
319
+ height: 48px;
320
+ padding: 0 12px;
321
+ border-radius: ${e.radius.card};
322
+ background: ${e.colors.white};
323
+ font-family: ${e.font.sans};
324
+ font-size: 16px;
325
+ font-weight: 800;
326
+ line-height: 24px;
327
+ letter-spacing: 0.46px;
328
+ color: ${e.colors.text2};
329
+ text-transform: uppercase;
330
+ `,Me=R`
331
+ to {
332
+ background-position: -200% 0;
333
+ }
334
+ `,z=i.span`
335
+ display: block;
336
+ background: linear-gradient(
337
+ 100deg,
338
+ rgba(255, 255, 255, 0.08) 30%,
339
+ rgba(255, 255, 255, 0.2) 50%,
340
+ rgba(255, 255, 255, 0.08) 70%
341
+ );
342
+ background-size: 200% 100%;
343
+ animation: ${Me} 1.4s infinite linear;
344
+
345
+ @media (prefers-reduced-motion: reduce) {
346
+ animation: none;
347
+ }
348
+ `,Ne=i(z)`
349
+ width: 60%;
350
+ height: 30px;
351
+ border-radius: ${e.radius.chip};
352
+ `,Ue=i(z)`
353
+ width: 253.5px;
354
+ max-width: 100%;
355
+ aspect-ratio: 1;
356
+ border-radius: 16px;
357
+ `,Ke=i(z)`
358
+ width: 100%;
359
+ height: 48px;
360
+ border-radius: ${e.radius.card};
361
+ `,V=i.p`
362
+ margin: 0;
363
+ font-family: ${e.font.sans};
364
+ color: ${e.colors.muted};
365
+ `,De=i.div`
366
+ display: flex;
367
+ flex-direction: column;
368
+ align-items: center;
369
+ gap: 10px;
370
+ padding: 48px 24px;
371
+ text-align: center;
372
+ `,Oe=R`
373
+ 0%, 100% {
374
+ transform: scale(1);
375
+ opacity: 1;
376
+ }
377
+ 50% {
378
+ transform: scale(0.88);
379
+ opacity: 0.7;
380
+ }
381
+ `,Ve=i.div`
382
+ display: flex;
383
+ flex-direction: column;
384
+ align-items: center;
385
+ justify-content: center;
386
+ gap: 32px;
387
+ padding: 64px 24px;
388
+ min-height: 42vh;
389
+ `,We=i.img`
390
+ width: 61px;
391
+ height: 61px;
392
+ animation: ${Oe} 1.2s ease-in-out infinite;
393
+
394
+ @media (prefers-reduced-motion: reduce) {
395
+ animation: none;
396
+ }
397
+ `,Ye=i.div`
398
+ display: flex;
399
+ flex-direction: column;
400
+ align-items: center;
401
+ gap: 8px;
402
+ `,Xe=i.p`
403
+ margin: 0;
404
+ font-family: ${e.font.sans};
405
+ font-size: 20px;
406
+ line-height: 1.6;
407
+ color: ${e.colors.text2};
408
+
409
+ strong {
410
+ font-weight: 700;
411
+ }
412
+ `,qe=i.div`
413
+ display: flex;
414
+ align-items: center;
415
+ gap: 8px;
416
+ `,Qe=R`
417
+ 0% {
418
+ left: -40%;
419
+ }
420
+ 100% {
421
+ left: 100%;
422
+ }
423
+ `,Je=i.span`
424
+ position: relative;
425
+ width: 456px;
426
+ max-width: 60vw;
427
+ height: 12px;
428
+ border-radius: ${e.radius.pill};
429
+ background: ${e.colors.chip};
430
+ overflow: hidden;
431
+ `,Ze=i.span`
432
+ position: absolute;
433
+ top: 0;
434
+ left: -40%;
435
+ width: 40%;
436
+ height: 100%;
437
+ border-radius: ${e.radius.pill};
438
+ background: ${e.gradients.amethyst};
439
+ animation: ${Qe} 1.4s ease-in-out infinite;
440
+
441
+ @media (prefers-reduced-motion: reduce) {
442
+ left: 0;
443
+ width: 30%;
444
+ animation: none;
445
+ }
446
+ `,et=i.span`
447
+ font-family: ${e.font.sans};
448
+ font-size: 16px;
449
+ line-height: 22px;
450
+ color: ${e.colors.text2};
451
+ `,tt=i.div`
452
+ display: flex;
453
+ flex-direction: column;
454
+ gap: 12px;
455
+ max-width: 895px;
456
+ margin: 0 auto;
457
+ `,it=i.div`
458
+ display: flex;
459
+ align-items: center;
460
+ gap: 16px;
461
+ padding: 24px 16px;
462
+ border-radius: 16px;
463
+ background: #e0f7e7;
464
+ border: 1px solid #34ce77;
465
+
466
+ @media (max-width: 560px) {
467
+ flex-direction: column;
468
+ text-align: center;
469
+ }
470
+ `,rt=i.img`
471
+ flex: none;
472
+ width: 60px;
473
+ height: 60px;
474
+ `,nt=i.p`
475
+ flex: 1;
476
+ margin: 0;
477
+ font-family: ${e.font.sans};
478
+ font-size: 20px;
479
+ line-height: 1.334;
480
+ color: ${e.colors.text2};
481
+ text-align: center;
482
+
483
+ strong {
484
+ font-weight: 700;
485
+ }
486
+ `,st=i.div`
487
+ padding: 24px;
488
+ border-radius: 16px;
489
+ background: ${e.colors.white};
490
+ border: 1px solid ${e.colors.gray4};
491
+ `,ot=i.div`
492
+ position: relative;
493
+ display: flex;
494
+ align-items: center;
495
+ justify-content: center;
496
+ min-height: 109px;
497
+ padding: 8px 24px 8px 150px;
498
+ border-radius: ${e.radius.btn};
499
+ background: #f4e9ff;
500
+
501
+ @media (max-width: 560px) {
502
+ flex-direction: column;
503
+ gap: 10px;
504
+ padding: 120px 16px 16px;
505
+ }
506
+ `,at=i.img`
507
+ position: absolute;
508
+ left: 35px;
509
+ top: 50%;
510
+ transform: translateY(-50%);
511
+ width: 93px;
512
+ height: 93px;
513
+ filter: drop-shadow(5px 7px 14px rgba(0, 0, 0, 0.17));
514
+
515
+ @media (max-width: 560px) {
516
+ left: 50%;
517
+ top: 16px;
518
+ transform: translateX(-50%);
519
+ }
520
+ `,dt=i.p`
521
+ display: inline-flex;
522
+ align-items: center;
523
+ gap: 8px;
524
+ margin: 0;
525
+ font-family: ${e.font.sans};
526
+ color: ${e.colors.text};
527
+
528
+ .ico {
529
+ width: 30px;
530
+ height: 30px;
531
+ color: ${e.colors.text};
532
+ }
533
+ `,ct=i.strong`
534
+ font-size: 24px;
535
+ font-weight: 700;
536
+ text-transform: capitalize;
537
+ `,lt=i.span`
538
+ font-size: 14px;
539
+ font-weight: 400;
540
+ `,pt=i.div`
541
+ display: flex;
542
+ gap: 12px;
543
+
544
+ @media (max-width: 560px) {
545
+ flex-direction: column;
546
+ }
547
+ `,y=i.button`
548
+ flex: 1;
549
+ display: inline-flex;
550
+ align-items: center;
551
+ justify-content: center;
552
+ height: 48px;
553
+ padding: 0 12px;
554
+ border: 0;
555
+ border-radius: ${e.radius.btn};
556
+ background: ${e.colors.accent};
557
+ font-family: ${e.font.sans};
558
+ font-size: 15px;
559
+ font-weight: 600;
560
+ letter-spacing: 0.046em;
561
+ color: ${e.colors.softWhite};
562
+ text-transform: uppercase;
563
+ cursor: pointer;
564
+ transition:
565
+ background 0.15s ease,
566
+ filter 0.15s ease;
567
+
568
+ &:hover {
569
+ filter: brightness(1.08);
570
+ }
571
+ &[data-variant='outline'] {
572
+ background: ${e.colors.white};
573
+ border: 2px solid ${e.colors.accent};
574
+ color: ${e.colors.accent};
575
+ }
576
+ &[data-variant='outline']:hover {
577
+ background: rgba(105, 31, 169, 0.06);
578
+ filter: none;
579
+ }
580
+ &:focus-visible {
581
+ outline: 2px solid ${e.colors.accent};
582
+ outline-offset: 2px;
583
+ }
584
+ `,W=i.div`
585
+ display: flex;
586
+ flex-direction: column;
587
+ align-items: center;
588
+ gap: 10px;
589
+ max-width: 560px;
590
+ margin: 0 auto;
591
+ padding: 48px 24px;
592
+ text-align: center;
593
+ `,Y=i.p`
594
+ margin: 0;
595
+ font-family: ${e.font.sans};
596
+ font-size: 20px;
597
+ font-weight: 700;
598
+ color: ${e.colors.text};
599
+
600
+ &[data-tone='error'] {
601
+ color: ${e.colors.err};
602
+ }
603
+ `,X=i.div`
604
+ display: flex;
605
+ gap: 12px;
606
+ margin-top: 16px;
607
+ `,xt=i.p`
608
+ margin: 0;
609
+ font-family: ${e.font.sans};
610
+ color: ${e.colors.err};
611
+ `,k=we()?"mock":"stripe",q=[j,j,ee,te],ut={pack_5:j,pack_10:j,pack_25:ee,pack_50:te};function gt(p,s){return ut[p.id]??q[s%q.length]}const ht="https://docs.decentraland.org";function Q(p){const s=p;if((s==null?void 0:s.name)==="AbortError")return r("getCredits.errorCanceled");const h=((s==null?void 0:s.message)??"").toLowerCase();return h.includes("sign in")?r("getCredits.errorSignIn",{currency:l.name}):h.includes("timed out")?r("getCredits.errorTimeout",{currency:l.name}):r("getCredits.errorGeneric")}function _t(){ce({title:r("nav.getCredits",{currency:l.name}),noindex:!0});const p=ae(),{session:s,signIn:h}=le(),d=pe(),[b,A]=de(),{packs:ie,isLoading:re}=fe(),[f,x]=c.useState("select"),[a,B]=c.useState(null),[E,T]=c.useState(null),[ne,w]=c.useState(null),[se,$]=c.useState(!1),v=c.useRef(null);c.useEffect(()=>()=>{var n;return(n=v.current)==null?void 0:n.abort()},[]);const L=c.useCallback(()=>{A(n=>{const o=new URLSearchParams(n);return o.delete("order"),o.delete("canceled"),o},{replace:!0})},[A]),S=c.useCallback(async n=>{x("processing");const o=new AbortController;v.current=o;try{const u=await me(n,{signal:o.signal,address:s==null?void 0:s.address,identity:s==null?void 0:s.identity});if(u.status==="credited"){const m=u.creditsGranted??(a==null?void 0:a.credits)??0;T(m>0?m:null),x("success"),g("Shop Completed Buy Credits",{order_id:n,pack_usd:(a==null?void 0:a.usd)??null,credits:m>0?m:null,provider:k}),d.invalidateQueries({queryKey:["usd-balance"]});try{if(sessionStorage.getItem(ge)){const C={resumeCheckout:!0,...m>0?{creditsAdded:m}:{}};p("/cart",{state:C});return}}catch{}try{const C=sessionStorage.getItem(M);if(C){sessionStorage.removeItem(M);const I=JSON.parse(C),F=xe(I);if(F){p(F,{state:{item:I,resumeBuy:!0}});return}}}catch{}}else u.status==="pending"?(g("Shop Buy Credits Pending",{step:"grant",pack_usd:(a==null?void 0:a.usd)??null}),d.invalidateQueries({queryKey:["usd-balance"]}),x("pending")):(g("Shop Buy Credits Failed",{step:"grant",error_code:"grant_failed",pack_usd:(a==null?void 0:a.usd)??null}),w(u.error??r("getCredits.errorGrant",{currency:l.name})),x("error"))}catch(u){G(u,{flow:"get_credits",step:"grant",order_id:n}),g("Shop Buy Credits Failed",{step:"grant",error_code:H(u),pack_usd:(a==null?void 0:a.usd)??null}),w(Q(u)),x("error")}},[a,s,d,p]),oe=c.useCallback(async n=>{if(!s){h();return}w(null),$(!1),B(n),x(k==="mock"?"processing":"redirecting"),g("Shop Started Buy Credits",{pack_usd:n.usd,credits:n.credits,provider:k});try{const o=await be(n.id,{address:s.address,identity:s.identity});if(o.mock)S(o.orderId);else if(o.url)g("Shop Redirected To Stripe",{order_id:o.orderId,pack_usd:n.usd,credits:n.credits}),window.location.href=o.url;else throw new Error("Checkout did not return a redirect url")}catch(o){G(o,{flow:"get_credits",step:"checkout",provider:k}),g("Shop Buy Credits Failed",{step:"checkout",error_code:H(o),pack_usd:n.usd}),w(Q(o)),x("error")}},[s,h,S]),P=c.useRef(!1);c.useEffect(()=>{if(P.current)return;const n=b.get("order");if(b.get("canceled")!=null){P.current=!0,g("Shop Buy Credits Cancelled",{order_id:n,provider:k}),L(),$(!0),x("select");return}n&&(x("processing"),s&&(P.current=!0,L(),S(n)))},[b,s]);function _(){var n;(n=v.current)==null||n.abort(),x("select"),B(null),T(null),w(null),$(!1)}return t.jsxs($e,{children:[f==="select"&&t.jsxs(ve,{"data-testid":"credits-hero",children:[t.jsx(Se,{"aria-hidden":!0}),t.jsxs(Pe,{children:[t.jsxs(_e,{children:[t.jsx(Re,{children:r("getCredits.title",{currency:l.name})}),t.jsxs(ze,{children:[t.jsx(Ae,{children:r("getCredits.subtitle",{currency:l.nameSingular})}),t.jsxs(Be,{href:ht,target:"_blank",rel:"noreferrer",children:[r("getCredits.learnMore"),t.jsx(J,{name:"link-out"})]})]})]}),se&&t.jsx(Ee,{role:"status",children:r("getCredits.canceledNote")}),t.jsx(ft,{packs:ie,loading:re,onSelect:n=>void oe(n)})]})]}),f==="redirecting"&&t.jsxs(De,{role:"status","aria-live":"polite",children:[t.jsx(ye,{size:32}),t.jsx(V,{children:r("getCredits.redirecting")})]}),f==="processing"&&t.jsxs(Ve,{role:"status","aria-live":"polite",children:[t.jsx(We,{src:he,alt:"",width:61,height:61}),t.jsxs(Ye,{children:[t.jsxs(Xe,{children:[t.jsx("strong",{children:r("getCredits.processing")}),"…"]}),t.jsxs(qe,{"aria-hidden":!0,children:[t.jsx(Je,{children:t.jsx(Ze,{})}),t.jsx(et,{children:"1/1"})]})]})]}),f==="success"&&t.jsxs(tt,{role:"status","aria-live":"polite",children:[t.jsxs(it,{children:[t.jsx(rt,{src:Ce,alt:"",width:60,height:60}),t.jsxs(nt,{children:[t.jsx("strong",{children:r("getCredits.successTitle")})," ",r("getCredits.successBody",{currency:l.name})]})]}),E!=null&&t.jsx(st,{children:t.jsxs(ot,{children:[t.jsx(at,{src:ke,alt:"",width:93,height:93}),t.jsxs(dt,{children:[t.jsx(Z,{}),t.jsxs("span",{children:[t.jsx(ct,{children:r("getCredits.creditsAmount",{credits:E,currency:l.name})})," ",t.jsx(lt,{children:r("getCredits.creditsAdded")})]})]})]})}),t.jsxs(pt,{children:[t.jsx(y,{"data-variant":"outline",onClick:_,children:r("getCredits.buyMore",{currency:l.name})}),t.jsx(y,{onClick:()=>p("/assets"),children:r("getCredits.startShopping")})]})]}),f==="pending"&&t.jsxs(W,{role:"status","aria-live":"polite",children:[t.jsx(Y,{children:r("getCredits.pendingTitle",{currency:l.name})}),t.jsx(V,{children:r("getCredits.pendingBody")}),t.jsxs(X,{children:[t.jsx(y,{onClick:()=>p("/assets"),children:r("getCredits.startShopping")}),t.jsx(y,{"data-variant":"outline",onClick:_,children:r("getCredits.done")})]})]}),f==="error"&&t.jsxs(W,{role:"alert",children:[t.jsx(Y,{"data-tone":"error",children:r("getCredits.errorTitle")}),t.jsx(xt,{children:ne}),t.jsx(X,{children:t.jsx(y,{onClick:_,children:r("getCredits.tryAgain")})})]})]})}function ft({packs:p,loading:s,onSelect:h}){return s?t.jsx(U,{"aria-busy":"true","aria-label":r("getCredits.packsLoading",{currency:l.name}),children:[0,1,2,3].map(d=>t.jsxs(K,{as:"div","data-skeleton":"true","data-testid":"pack-skeleton","aria-hidden":!0,children:[t.jsxs(D,{children:[t.jsx(O,{children:t.jsx(Ne,{})}),t.jsx(Ue,{})]}),t.jsx(Ke,{})]},d))}):t.jsx(U,{children:p.map((d,b)=>t.jsxs(K,{type:"button","data-testid":"pack","data-best":d.bestValue?"true":void 0,onClick:()=>h(d),"aria-label":r("getCredits.packAria",{amount:ue(d.credits),usd:d.usd}),children:[d.bestValue&&t.jsxs(Te,{children:[t.jsx(J,{name:"star-rounded"}),r("getCredits.packBadge")]}),t.jsxs(D,{children:[t.jsxs(O,{children:[t.jsxs(Le,{children:[t.jsx(Z,{}),t.jsx(Ie,{children:d.credits})]}),t.jsx(Fe,{children:r("getCredits.packUnit",{currency:l.name})})]}),t.jsx(Ge,{children:t.jsx("img",{src:gt(d,b),alt:"",loading:"lazy",width:507,height:507})})]}),t.jsxs(He,{children:["$",d.usd.toFixed(2)]})]},d.id))})}export{_t as GetCredits,_t as default};
@@ -1,4 +1,4 @@
1
- import{i as f,b as h}from"./lit-element-B3y9oplH.js";import{n as m}from"./class-map-CxwNmq0D.js";import{c as p}from"./index-_75wkcmX.js";import{d as g,r as v}from"./index-DZak9MEk.js";import{C as c}from"./ConstantsUtil-DTrOBzCe.js";import{R as $,O as u}from"./W3MFrameProviderSingleton-BztPgidQ.js";import{au as y}from"./NetworkUtil-C1aEwuOK.js";const b=g`
1
+ import{i as f,b as h}from"./lit-element-B3y9oplH.js";import{n as m}from"./class-map-CxwNmq0D.js";import{c as p}from"./index-ezQi9fE0.js";import{d as g,r as v}from"./index-D2w8m12L.js";import{C as c}from"./ConstantsUtil-DTrOBzCe.js";import{R as $,O as u}from"./W3MFrameProviderSingleton-C03Pb4B-.js";import{au as y}from"./NetworkUtil-C1aEwuOK.js";const b=g`
2
2
  :host {
3
3
  display: flex;
4
4
  justify-content: center;
@@ -1,5 +1,5 @@
1
- import{u as R,r as h,j as e,L as B}from"./react-BW1xvPTF.js";import{w as P,t as s,e as S,B as k,C as L,j as $,H as Q,m as U,u as W,b as O,o as z,s as F,P as H}from"./index-DKn89nIW.js";import{i as Y,R as D,f as G}from"./import-BfcW9VC0.js";import"./sentry-BV_ZSgtd.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CtVvB8eG.js";import"./intl-CBcMB1D2.js";import"./buy-C5fAE4Tk.js";import"./authorizations-LVujlH7N.js";import"./index-HN6Rk25C.js";import"./sendMetaTransaction-CiO3jI6F.js";import"./trade-encoding-BNfrO5uz.js";import"./mana-rate-ClCow8js.js";function J({queue:n,session:w,onClose:j,onDone:o}){const N=R(),d=P(w.providerType),[m,f]=h.useState(()=>n.map(()=>"pending")),[I,M]=h.useState("running"),T=h.useRef(!1);h.useEffect(()=>{if(T.current)return;T.current=!0;let t=!1;return(async()=>{for(let r=0;r<n.length;r++){if(t)return;f(u=>u.map((g,p)=>p===r?"active":g));try{await Y(n[r].item,n[r].priceCredits,w),$("Shop Migrated Listing",{item_id:n[r].item.itemId??n[r].item.oldTradeId??null,contract_address:n[r].item.contractAddress,new_price_credits:n[r].priceCredits,new_price_usd:n[r].priceCredits/10}),t||f(u=>u.map((g,p)=>p===r?"done":g))}catch(u){if(u instanceof D)Q(u,{flow:"import_listing",step:"relist",itemId:n[r].item.itemId??n[r].item.oldTradeId}),t||f(g=>g.map((p,b)=>b===r?"unlisted":p));else{const g=u,p=g.code===4001||/reject|denied|cancel/i.test(g.message??"");p||Q(u,{flow:"import_listing",itemId:n[r].item.itemId??n[r].item.oldTradeId}),t||f(b=>b.map((a,l)=>l===r?p?"skipped":"failed":a))}}}t||M("finished")})(),()=>{t=!0}},[]);const _=m.filter(t=>t==="done").length,v=m.findIndex(t=>t==="active"),x=Math.round(m.filter(t=>t!=="pending"&&t!=="active").length/n.length*100);function y(){o(),j()}if(I==="finished"){const t=m.filter(r=>r==="skipped"||r==="failed").length,c=m.filter(r=>r==="unlisted").length;return e.jsx("div",{className:"modal-backdrop",role:"presentation",children:e.jsxs("div",{className:"modal modal--success",role:"dialog","aria-modal":"true",children:[e.jsx("div",{className:"modal-success__check","aria-hidden":!0,children:"✓"}),e.jsx("h2",{className:"modal__title",children:_>0?s("migrate.successTitle"):s("migrate.nothingTitle")}),e.jsxs("p",{className:"muted",style:{margin:0},children:[_>0?s("migrate.listedSummary",{count:_,currency:S.name}):s("migrate.noneListed"),t>0?" "+s("migrate.skippedSummary",{count:t}):"",c>0?" "+s("migrate.unlistedSummary",{count:c}):""]}),e.jsxs("div",{className:"modal__actions",children:[e.jsx(k,{variant:"ghost",onClick:y,children:s("getCredits.done")}),c>0?e.jsx(k,{variant:"purple",onClick:()=>{o(),j(),N("/my-assets")},children:s("migrate.goToMyAssets")}):_>0?e.jsx(k,{variant:"purple",onClick:()=>{o(),j(),N("/assets")},children:s("migrate.viewInShop")}):null]})]})})}return e.jsx("div",{className:"modal-backdrop",role:"presentation",children:e.jsxs("div",{className:"modal migrate","data-testid":"modal",role:"dialog","aria-modal":"true","aria-live":"polite",children:[e.jsx("h2",{className:"modal__title",children:s("migrate.listingTitle")}),e.jsxs("p",{className:"muted small",style:{margin:"0 0 4px"},children:[d?s("migrate.subConfirm"):s("migrate.subManaged")," ",v>=0?s("migrate.progressCount",{current:v+1,total:n.length}):""]}),e.jsx("div",{className:"migrate__progress",children:e.jsx("div",{className:"migrate__bar",style:{width:`${x}%`}})}),e.jsx("ul",{className:"migrate__list",children:n.map((t,c)=>e.jsxs("li",{className:`migrate__row migrate__row--${m[c]}`,children:[e.jsx("span",{className:"migrate__thumb",children:t.item.thumbnail?e.jsx("img",{src:t.item.thumbnail,alt:""}):null}),e.jsx("span",{className:"migrate__name",title:t.item.name,children:t.item.name||s("migrate.itemFallback")}),e.jsxs("span",{className:"migrate__price",children:[e.jsx(L,{className:"ccy-mark"})," ",t.priceCredits.toLocaleString()]}),e.jsx("span",{className:"migrate__status",children:m[c]==="active"?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"spinner migrate__spin","aria-hidden":!0})," ",d?s("migrate.statusConfirm"):s("migrate.statusAdding")]}):m[c]==="done"?e.jsx("span",{className:"migrate__tick",children:"✓"}):m[c]==="skipped"?e.jsx("span",{className:"migrate__skip",children:s("migrate.statusSkipped")}):m[c]==="failed"?e.jsx("span",{className:"migrate__skip",children:s("migrate.statusFailed")}):m[c]==="unlisted"?e.jsx("span",{className:"migrate__skip",title:s("migrate.unlistedTooltip"),children:s("migrate.statusUnlisted")}):e.jsx("span",{className:"migrate__wait",children:s("migrate.statusWaiting")})})]},t.item.oldTradeId))}),e.jsx("p",{className:"muted small migrate__hint",children:d?s("migrate.hintConfirm"):s("migrate.hintManaged")})]})})}const A=F(k)`
1
+ import{u as R,r as h,j as e,L as B}from"./react-BW1xvPTF.js";import{y as U,t as s,e as S,B as k,C as L,j as $,J as Q,x as P,u as W,b as O,n as z,s as F,U as J}from"./index-ZWDXIF6O.js";import{i as Y,R as D,f as G}from"./import-C8mG5kpp.js";import"./sentry-BV_ZSgtd.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CtVvB8eG.js";import"./intl-CBcMB1D2.js";import"./buy-B2kHW0nr.js";import"./authorizations-Cp6LZG2p.js";import"./sendMetaTransaction-Bky8YK8T.js";import"./trade-encoding-C0CKvlMZ.js";import"./mana-rate-BkFbk0kZ.js";function H({queue:n,session:T,onClose:j,onDone:o}){const N=R(),d=U(T.providerType),[m,f]=h.useState(()=>n.map(()=>"pending")),[I,M]=h.useState("running"),w=h.useRef(!1);h.useEffect(()=>{if(w.current)return;w.current=!0;let t=!1;return(async()=>{for(let r=0;r<n.length;r++){if(t)return;f(u=>u.map((g,p)=>p===r?"active":g));try{await Y(n[r].item,n[r].priceCredits,T),$("Shop Migrated Listing",{item_id:n[r].item.itemId??n[r].item.oldTradeId??null,contract_address:n[r].item.contractAddress,new_price_credits:n[r].priceCredits,new_price_usd:n[r].priceCredits/10}),t||f(u=>u.map((g,p)=>p===r?"done":g))}catch(u){if(u instanceof D)Q(u,{flow:"import_listing",step:"relist",itemId:n[r].item.itemId??n[r].item.oldTradeId}),t||f(g=>g.map((p,b)=>b===r?"unlisted":p));else{const g=u,p=g.code===4001||/reject|denied|cancel/i.test(g.message??"");p||Q(u,{flow:"import_listing",itemId:n[r].item.itemId??n[r].item.oldTradeId}),t||f(b=>b.map((a,l)=>l===r?p?"skipped":"failed":a))}}}t||M("finished")})(),()=>{t=!0}},[]);const _=m.filter(t=>t==="done").length,v=m.findIndex(t=>t==="active"),x=Math.round(m.filter(t=>t!=="pending"&&t!=="active").length/n.length*100);function y(){o(),j()}if(I==="finished"){const t=m.filter(r=>r==="skipped"||r==="failed").length,c=m.filter(r=>r==="unlisted").length;return e.jsx("div",{className:"modal-backdrop",role:"presentation",children:e.jsxs("div",{className:"modal modal--success",role:"dialog","aria-modal":"true",children:[e.jsx("div",{className:"modal-success__check","aria-hidden":!0,children:"✓"}),e.jsx("h2",{className:"modal__title",children:_>0?s("migrate.successTitle"):s("migrate.nothingTitle")}),e.jsxs("p",{className:"muted",style:{margin:0},children:[_>0?s("migrate.listedSummary",{count:_,currency:S.name}):s("migrate.noneListed"),t>0?" "+s("migrate.skippedSummary",{count:t}):"",c>0?" "+s("migrate.unlistedSummary",{count:c}):""]}),e.jsxs("div",{className:"modal__actions",children:[e.jsx(k,{variant:"ghost",onClick:y,children:s("getCredits.done")}),c>0?e.jsx(k,{variant:"purple",onClick:()=>{o(),j(),N("/my-assets")},children:s("migrate.goToMyAssets")}):_>0?e.jsx(k,{variant:"purple",onClick:()=>{o(),j(),N("/assets")},children:s("migrate.viewInShop")}):null]})]})})}return e.jsx("div",{className:"modal-backdrop",role:"presentation",children:e.jsxs("div",{className:"modal migrate","data-testid":"modal",role:"dialog","aria-modal":"true","aria-live":"polite",children:[e.jsx("h2",{className:"modal__title",children:s("migrate.listingTitle")}),e.jsxs("p",{className:"muted small",style:{margin:"0 0 4px"},children:[d?s("migrate.subConfirm"):s("migrate.subManaged")," ",v>=0?s("migrate.progressCount",{current:v+1,total:n.length}):""]}),e.jsx("div",{className:"migrate__progress",children:e.jsx("div",{className:"migrate__bar",style:{width:`${x}%`}})}),e.jsx("ul",{className:"migrate__list",children:n.map((t,c)=>e.jsxs("li",{className:`migrate__row migrate__row--${m[c]}`,children:[e.jsx("span",{className:"migrate__thumb",children:t.item.thumbnail?e.jsx("img",{src:t.item.thumbnail,alt:""}):null}),e.jsx("span",{className:"migrate__name",title:t.item.name,children:t.item.name||s("migrate.itemFallback")}),e.jsxs("span",{className:"migrate__price",children:[e.jsx(L,{className:"ccy-mark"})," ",t.priceCredits.toLocaleString()]}),e.jsx("span",{className:"migrate__status",children:m[c]==="active"?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"spinner migrate__spin","aria-hidden":!0})," ",d?s("migrate.statusConfirm"):s("migrate.statusAdding")]}):m[c]==="done"?e.jsx("span",{className:"migrate__tick",children:"✓"}):m[c]==="skipped"?e.jsx("span",{className:"migrate__skip",children:s("migrate.statusSkipped")}):m[c]==="failed"?e.jsx("span",{className:"migrate__skip",children:s("migrate.statusFailed")}):m[c]==="unlisted"?e.jsx("span",{className:"migrate__skip",title:s("migrate.unlistedTooltip"),children:s("migrate.statusUnlisted")}):e.jsx("span",{className:"migrate__wait",children:s("migrate.statusWaiting")})})]},t.item.oldTradeId))}),e.jsx("p",{className:"muted small migrate__hint",children:d?s("migrate.hintConfirm"):s("migrate.hintManaged")})]})})}const A=F(k)`
2
2
  margin-top: 10px;
3
3
  `,V=F(k)`
4
4
  padding: 13px 24px;
5
- `,X=[{key:"creations",title:"importListings.creations.title",sub:"importListings.creations.sub"},{key:"owned",title:"importListings.owned.title",sub:"importListings.owned.sub"}];function oe(){U({title:s("seo.import.title"),noindex:!0});const{session:n,signIn:w,restore:j}=W(),o=O(),N=n==null?void 0:n.address;h.useEffect(()=>{j()},[j]);const{data:d,isLoading:m}=z({queryKey:["importable",N],queryFn:()=>G(N),enabled:!!N}),[f,I]=h.useState({}),[M,T]=h.useState(new Set),[_,v]=h.useState(null),x=h.useMemo(()=>[...(d==null?void 0:d.creations)??[],...(d==null?void 0:d.owned)??[]],[d]);h.useEffect(()=>{x.length&&I(a=>{const l={...a};for(const i of x)l[i.oldTradeId]==null&&(l[i.oldTradeId]=i.suggestedCredits);return l})},[x]);const y=a=>!M.has(a),t=a=>f[a.oldTradeId]??a.suggestedCredits,c=x.filter(a=>y(a.oldTradeId)),r=c.reduce((a,l)=>a+t(l),0);function u(a,l){const i=l.replace(/[^\d]/g,"");I(C=>({...C,[a]:i===""?0:parseInt(i,10)}))}function g(a){T(l=>{const i=new Set(l);return i.has(a)?i.delete(a):i.add(a),i})}function p(a){return a.map(l=>({item:l,priceCredits:Math.max(1,t(l))}))}function b(){o.invalidateQueries({queryKey:["importable"]}),o.invalidateQueries({queryKey:["shop-items"]}),o.invalidateQueries({queryKey:["catalog-items"]}),o.invalidateQueries({queryKey:["overview-listings"]}),o.invalidateQueries({queryKey:["upsell-listings"]}),o.invalidateQueries({queryKey:["my-assets"]}),o.invalidateQueries({queryKey:["collection-sale-state"]}),H.success(s("importListings.toastUpdated"))}return n?!m&&x.length===0?e.jsxs("div",{className:"imp-empty",children:[e.jsx("span",{className:"imp-empty__ico","aria-hidden":!0,children:"✨"}),e.jsx("h1",{className:"imp-empty__title",children:s("importListings.emptyTitle")}),e.jsx("p",{className:"muted",children:s("importListings.emptyBody")}),e.jsx(A,{as:B,to:"/my-assets",variant:"purple",children:s("importListings.goToMyAssets")})]}):e.jsxs("div",{className:"imp",children:[e.jsxs("header",{className:"imp__head",children:[e.jsx("span",{className:"imp__eyebrow",children:s("importListings.eyebrow")}),e.jsxs("h1",{className:"imp__title",children:[s("importListings.titleLead")," ",e.jsx("span",{className:"imp__grad",children:s("importListings.titleAccent")})]}),e.jsx("p",{className:"imp__lede",children:s("importListings.lede",{currency:S.name})})]}),e.jsxs("div",{className:"imp__ratebar",children:[e.jsx(L,{className:"ccy-mark imp__diamond"})," ",s("importListings.rate",{currency:S.nameSingular})]}),m?e.jsx("div",{className:"imp__list",children:Array.from({length:4}).map((a,l)=>e.jsx("div",{className:"imp-row imp-row--skeleton"},l))}):X.map(a=>{const l=(d==null?void 0:d[a.key])??[];return l.length===0?null:e.jsxs("section",{className:"imp__section",children:[e.jsxs("div",{className:"imp__section-head",children:[e.jsx("h2",{className:"imp__section-title",children:s(a.title)}),e.jsx("span",{className:"imp__section-sub",children:s(a.sub)})]}),e.jsx("div",{className:"imp__list",children:l.map(i=>{const C=t(i),K=C!==i.suggestedCredits;return e.jsxs("article",{className:`imp-row${y(i.oldTradeId)?"":" is-off"}`,children:[e.jsx("input",{type:"checkbox",className:"imp-check",checked:y(i.oldTradeId),onChange:()=>g(i.oldTradeId),"aria-label":s("importListings.includeItem",{name:i.name})}),e.jsx("div",{className:"imp-thumb",children:i.thumbnail?e.jsx("img",{src:i.thumbnail,alt:""}):null}),e.jsxs("div",{className:"imp-meta",children:[e.jsx("div",{className:"imp-name",title:i.name,children:i.name||s("importListings.itemFallback")}),e.jsx("span",{className:"imp-chip",children:i.rarity})]}),e.jsxs("div",{className:"imp-price",children:[e.jsxs("div",{className:"imp-price__field",children:[e.jsx(L,{className:"ccy-mark imp-price__diamond"}),e.jsx("input",{className:"imp-price__input","data-testid":"imp-price-input",inputMode:"numeric",value:C.toLocaleString(),onChange:E=>u(i.oldTradeId,E.target.value),"aria-label":s("importListings.priceAria",{currency:S.name,name:i.name})})]}),e.jsxs("div",{className:"imp-price__sub",children:[e.jsxs("span",{children:["$",(C*.1).toFixed(2)]}),K?e.jsxs("button",{className:"imp-price__reset",onClick:()=>I(E=>({...E,[i.oldTradeId]:i.suggestedCredits})),children:[s("importListings.resetTo")," ",e.jsx(L,{className:"ccy-mark"}),i.suggestedCredits.toLocaleString()]}):null]})]}),e.jsx("div",{className:"imp-action",children:e.jsx(k,{size:"sm",className:"imp-row__list",disabled:!y(i.oldTradeId),onClick:()=>v(p([i])),children:s("importListings.list")})})]},i.oldTradeId)})})]},a.key)}),e.jsx("div",{className:"imp-dock",children:e.jsxs("div",{className:"imp-dock__inner",children:[e.jsxs("div",{className:"imp-dock__summary",children:[e.jsxs("div",{className:"imp-dock__total",children:[e.jsx(L,{className:"ccy-mark imp__diamond"})," ",r.toLocaleString()]}),e.jsx("div",{className:"imp-dock__sub",children:s("importListings.selectedSummary",{count:c.length,usd:(r*.1).toFixed(2)})})]}),e.jsx("span",{className:"imp-dock__spacer"}),e.jsx(V,{variant:"purple",disabled:c.length===0,onClick:()=>v(p(c)),children:s("importListings.listAll",{count:c.length})})]})}),_&&n?e.jsx(J,{queue:_,session:n,onClose:()=>v(null),onDone:b}):null]}):e.jsxs("div",{className:"imp-empty",children:[e.jsx("span",{className:"imp-empty__ico","aria-hidden":!0,children:"📦"}),e.jsx("h1",{className:"imp-empty__title",children:s("importListings.signInTitle")}),e.jsx("p",{className:"muted",children:s("importListings.signInBody")}),e.jsx(A,{variant:"purple",onClick:()=>w(),children:s("storeSettings.signIn")})]})}export{oe as ImportListings};
5
+ `,X=[{key:"creations",title:"importListings.creations.title",sub:"importListings.creations.sub"},{key:"owned",title:"importListings.owned.title",sub:"importListings.owned.sub"}];function me(){P({title:s("seo.import.title"),noindex:!0});const{session:n,signIn:T,restore:j}=W(),o=O(),N=n==null?void 0:n.address;h.useEffect(()=>{j()},[j]);const{data:d,isLoading:m}=z({queryKey:["importable",N],queryFn:()=>G(N),enabled:!!N}),[f,I]=h.useState({}),[M,w]=h.useState(new Set),[_,v]=h.useState(null),x=h.useMemo(()=>[...(d==null?void 0:d.creations)??[],...(d==null?void 0:d.owned)??[]],[d]);h.useEffect(()=>{x.length&&I(a=>{const l={...a};for(const i of x)l[i.oldTradeId]==null&&(l[i.oldTradeId]=i.suggestedCredits);return l})},[x]);const y=a=>!M.has(a),t=a=>f[a.oldTradeId]??a.suggestedCredits,c=x.filter(a=>y(a.oldTradeId)),r=c.reduce((a,l)=>a+t(l),0);function u(a,l){const i=l.replace(/[^\d]/g,"");I(C=>({...C,[a]:i===""?0:parseInt(i,10)}))}function g(a){w(l=>{const i=new Set(l);return i.has(a)?i.delete(a):i.add(a),i})}function p(a){return a.map(l=>({item:l,priceCredits:Math.max(1,t(l))}))}function b(){o.invalidateQueries({queryKey:["importable"]}),o.invalidateQueries({queryKey:["shop-items"]}),o.invalidateQueries({queryKey:["catalog-items"]}),o.invalidateQueries({queryKey:["overview-listings"]}),o.invalidateQueries({queryKey:["upsell-listings"]}),o.invalidateQueries({queryKey:["my-assets"]}),o.invalidateQueries({queryKey:["collection-sale-state"]}),J.success(s("importListings.toastUpdated"))}return n?!m&&x.length===0?e.jsxs("div",{className:"imp-empty",children:[e.jsx("span",{className:"imp-empty__ico","aria-hidden":!0,children:"✨"}),e.jsx("h1",{className:"imp-empty__title",children:s("importListings.emptyTitle")}),e.jsx("p",{className:"muted",children:s("importListings.emptyBody")}),e.jsx(A,{as:B,to:"/my-assets",variant:"purple",children:s("importListings.goToMyAssets")})]}):e.jsxs("div",{className:"imp",children:[e.jsxs("header",{className:"imp__head",children:[e.jsx("span",{className:"imp__eyebrow",children:s("importListings.eyebrow")}),e.jsxs("h1",{className:"imp__title",children:[s("importListings.titleLead")," ",e.jsx("span",{className:"imp__grad",children:s("importListings.titleAccent")})]}),e.jsx("p",{className:"imp__lede",children:s("importListings.lede",{currency:S.name})})]}),e.jsxs("div",{className:"imp__ratebar",children:[e.jsx(L,{className:"ccy-mark imp__diamond"})," ",s("importListings.rate",{currency:S.nameSingular})]}),m?e.jsx("div",{className:"imp__list",children:Array.from({length:4}).map((a,l)=>e.jsx("div",{className:"imp-row imp-row--skeleton"},l))}):X.map(a=>{const l=(d==null?void 0:d[a.key])??[];return l.length===0?null:e.jsxs("section",{className:"imp__section",children:[e.jsxs("div",{className:"imp__section-head",children:[e.jsx("h2",{className:"imp__section-title",children:s(a.title)}),e.jsx("span",{className:"imp__section-sub",children:s(a.sub)})]}),e.jsx("div",{className:"imp__list",children:l.map(i=>{const C=t(i),K=C!==i.suggestedCredits;return e.jsxs("article",{className:`imp-row${y(i.oldTradeId)?"":" is-off"}`,children:[e.jsx("input",{type:"checkbox",className:"imp-check",checked:y(i.oldTradeId),onChange:()=>g(i.oldTradeId),"aria-label":s("importListings.includeItem",{name:i.name})}),e.jsx("div",{className:"imp-thumb",children:i.thumbnail?e.jsx("img",{src:i.thumbnail,alt:""}):null}),e.jsxs("div",{className:"imp-meta",children:[e.jsx("div",{className:"imp-name",title:i.name,children:i.name||s("importListings.itemFallback")}),e.jsx("span",{className:"imp-chip",children:i.rarity})]}),e.jsxs("div",{className:"imp-price",children:[e.jsxs("div",{className:"imp-price__field",children:[e.jsx(L,{className:"ccy-mark imp-price__diamond"}),e.jsx("input",{className:"imp-price__input","data-testid":"imp-price-input",inputMode:"numeric",value:C.toLocaleString(),onChange:E=>u(i.oldTradeId,E.target.value),"aria-label":s("importListings.priceAria",{currency:S.name,name:i.name})})]}),e.jsxs("div",{className:"imp-price__sub",children:[e.jsxs("span",{children:["$",(C*.1).toFixed(2)]}),K?e.jsxs("button",{className:"imp-price__reset",onClick:()=>I(E=>({...E,[i.oldTradeId]:i.suggestedCredits})),children:[s("importListings.resetTo")," ",e.jsx(L,{className:"ccy-mark"}),i.suggestedCredits.toLocaleString()]}):null]})]}),e.jsx("div",{className:"imp-action",children:e.jsx(k,{size:"sm",className:"imp-row__list",disabled:!y(i.oldTradeId),onClick:()=>v(p([i])),children:s("importListings.list")})})]},i.oldTradeId)})})]},a.key)}),e.jsx("div",{className:"imp-dock",children:e.jsxs("div",{className:"imp-dock__inner",children:[e.jsxs("div",{className:"imp-dock__summary",children:[e.jsxs("div",{className:"imp-dock__total",children:[e.jsx(L,{className:"ccy-mark imp__diamond"})," ",r.toLocaleString()]}),e.jsx("div",{className:"imp-dock__sub",children:s("importListings.selectedSummary",{count:c.length,usd:(r*.1).toFixed(2)})})]}),e.jsx("span",{className:"imp-dock__spacer"}),e.jsx(V,{variant:"purple",disabled:c.length===0,onClick:()=>v(p(c)),children:s("importListings.listAll",{count:c.length})})]})}),_&&n?e.jsx(H,{queue:_,session:n,onClose:()=>v(null),onDone:b}):null]}):e.jsxs("div",{className:"imp-empty",children:[e.jsx("span",{className:"imp-empty__ico","aria-hidden":!0,children:"📦"}),e.jsx("h1",{className:"imp-empty__title",children:s("importListings.signInTitle")}),e.jsx("p",{className:"muted",children:s("importListings.signInBody")}),e.jsx(A,{variant:"purple",onClick:()=>T(),children:s("storeSettings.signIn")})]})}export{me as ImportListings};