@dcl/shop 0.1.0-30612955316.commit-0d9b744 → 0.1.0-30633401379.commit-5cd1c31

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 (178) hide show
  1. package/assets/Activity-BHKoZZp5.js +291 -0
  2. package/assets/{AnimatedBackground-DTgtqP8R.js → AnimatedBackground-BlD5oHcR.js} +2 -2
  3. package/assets/{Assets-B9KXwYG0.js → Assets-DUKvbfgo.js} +7 -7
  4. package/assets/{Assets.styles-Dm_MgfhY.js → Assets.styles-BLCNmjO6.js} +1 -1
  5. package/assets/{Authorizations--gatNHIW.js → Authorizations-6n5FWz0U.js} +1 -1
  6. package/assets/Cart-D7ktjzZK.js +695 -0
  7. package/assets/{CircularProgress-BRaMu2HF.js → CircularProgress-CMZVAt1l.js} +1 -1
  8. package/assets/{Collection-BIR5xrVe.js → Collection-CQps3SAa.js} +1 -1
  9. package/assets/{CollectionCarousel-oh8d08gi.js → CollectionCarousel-CrTrsXB-.js} +1 -1
  10. package/assets/{Creator-jKJMNfvf.js → Creator-DeBO0_hP.js} +2 -2
  11. package/assets/{ErrorNotice-C2qBxBzo.js → ErrorNotice-DwhdhAu6.js} +1 -1
  12. package/assets/{ExchangeController-BJ20Rri0.js → ExchangeController-DFaPYxag.js} +1 -1
  13. package/assets/{GetCredits-DWkdHCSk.js → GetCredits-CH0SxGoe.js} +8 -8
  14. package/assets/{HelpersUtil-Bc_-rYa4.js → HelpersUtil-CGxvruiS.js} +1 -1
  15. package/assets/{ImportListings-C61E-WD4.js → ImportListings-D3Q-MYHt.js} +8 -8
  16. package/assets/{ItemDetail-BFNeFxLh.js → ItemDetail-grsXVByw.js} +3 -3
  17. package/assets/{LoadMore-BI2cyij4.js → LoadMore-CVBNO6CV.js} +1 -1
  18. package/assets/{MenuList-CsoSKANx.js → MenuList-D5vC383J.js} +1 -1
  19. package/assets/{MyAssets-B8jlwAvA.js → MyAssets-B4-suVif.js} +1 -1
  20. package/assets/{MyFavorites-B6kCgq1h.js → MyFavorites-rQde9LEq.js} +1 -1
  21. package/assets/{NotFound-CWtlpg63.js → NotFound-CICAlcY2.js} +1 -1
  22. package/assets/{NotificationsBell-wPKuEs_b.js → NotificationsBell-BcUtKYE_.js} +1 -1
  23. package/assets/{StoreSettings-BW2EY9gn.js → StoreSettings-D-p-KMUm.js} +1 -1
  24. package/assets/Success-CKUShs2s.js +276 -0
  25. package/assets/{SwapController-DHr7xvAI.js → SwapController-BqpEkXCy.js} +1 -1
  26. package/assets/{Tooltip-DFmfpHxa.js → Tooltip-v8d4_GhH.js} +1 -1
  27. package/assets/{TradeService-BxS-ssTi.js → TradeService-CMvEMasH.js} +1 -1
  28. package/assets/{W3MFrameProviderSingleton-D3RatyJZ.js → W3MFrameProviderSingleton-MrB8u6EW.js} +3 -3
  29. package/assets/{WebCryptoP256-DLlMYv1t.js → WebCryptoP256-CP0xBKi2.js} +1 -1
  30. package/assets/{authorizations-BrAVsIY_.js → authorizations-uQp0Tner.js} +1 -1
  31. package/assets/{basic-B1iPuZqz.js → basic-B_OSMlWi.js} +1 -1
  32. package/assets/{biconomy-CReC5_o1.js → biconomy-DrNdbDOV.js} +1 -1
  33. package/assets/{browseLayout.styles-Ck-h2OX5.js → browseLayout.styles-B5gAAnD7.js} +5 -5
  34. package/assets/{builder-BW_vsdgs.js → builder-BH8bW8w3.js} +1 -1
  35. package/assets/buy-DI2htlf2.js +1 -0
  36. package/assets/{buy-gasless-DoEdxK3L.js → buy-gasless-D3ucK012.js} +1 -1
  37. package/assets/{categories-P1zgLmzy.js → categories-CUWn-vWY.js} +1 -1
  38. package/assets/{ccip-BHjcKqJV.js → ccip-D4QJIvrM.js} +1 -1
  39. package/assets/{ccip-CZBbVQi3.js → ccip-zHeTh1U3.js} +1 -1
  40. package/assets/{clsx-DhFqZi_3.js → clsx-C78Se7VZ.js} +2 -2
  41. package/assets/{controller-DGy85CgR.js → controller-BICwQmay.js} +2 -2
  42. package/assets/{core-Db5S1VHS.js → core-BpePoapT.js} +4 -4
  43. package/assets/{createSvgIcon-DLpGC0um.js → createSvgIcon-D6bh0MrS.js} +3 -3
  44. package/assets/{custom-ClweN61f.js → custom-DIlU15wg.js} +1 -1
  45. package/assets/{data-capture-z84EsTtU.js → data-capture-DF5W_J8T.js} +1 -1
  46. package/assets/{email-CcLkWyvu.js → email-CLMX01kZ.js} +1 -1
  47. package/assets/{embedded-wallet-COy2jXd-.js → embedded-wallet-CbYQTubx.js} +1 -1
  48. package/assets/{emotion-styled.browser.esm-Bl0xNQms.js → emotion-styled.browser.esm-uimCutsp.js} +1 -1
  49. package/assets/{engine-D5VFTt2U.js → engine-Bobn5NnI.js} +1 -1
  50. package/assets/{errors-D660SWgT.js → errors-BHapDldI.js} +1 -1
  51. package/assets/{estimate-l1-fee-D0AZXU9d.js → estimate-l1-fee-Zo4D8zNV.js} +1 -1
  52. package/assets/{execute-B7xe5F3I.js → execute-B3koRsQT.js} +2 -2
  53. package/assets/{features-CDbo6Rgb.js → features-29eUittk.js} +1 -1
  54. package/assets/{fetchTokenMetadata-CTdt9CEd.js → fetchTokenMetadata-BVVFFsly.js} +2 -2
  55. package/assets/{get-ecosystem-wallet-info-DSZkSx4X.js → get-ecosystem-wallet-info-Fbs6oNmw.js} +1 -1
  56. package/assets/{getBalance-BDX5XOeM.js → getBalance-BynOYuPH.js} +1 -1
  57. package/assets/{getNFT-CVs2H6Tl.js → getNFT-C7BU-05F.js} +1 -1
  58. package/assets/{getNFT-DINbSeyy.js → getNFT-CHPhy1te.js} +1 -1
  59. package/assets/{getThemeProps-CGtqDWEq.js → getThemeProps-BCb3jyqf.js} +1 -1
  60. package/assets/{grid.styles-D4B-EHGj.js → grid.styles-CFlLjGWA.js} +1 -1
  61. package/assets/{hashTypedData-Dz79Rf5q.js → hashTypedData-BmEKHoZL.js} +1 -1
  62. package/assets/{hashTypedData-B7lV4LZj.js → hashTypedData-CixGH523.js} +1 -1
  63. package/assets/{import-DSm0v4af.js → import-xE4hDmDm.js} +1 -1
  64. package/assets/{in-app-C5pWpM6r.js → in-app-BcKmOV8m.js} +1 -1
  65. package/assets/{in-app-wallet-calls-DXx7lWeR.js → in-app-wallet-calls-BI1PaW_x.js} +1 -1
  66. package/assets/{index-ODLNljC7.js → index-9WfG_CLW.js} +1 -1
  67. package/assets/{index-CJgXTNhS.js → index-ASq7s2Iv.js} +2 -2
  68. package/assets/{index-BobbFiKW.js → index-B0eTctvC.js} +1 -1
  69. package/assets/{index-D7R57an8.js → index-B439DG-9.js} +2 -2
  70. package/assets/{index-BZocXWA4.js → index-BAORCNZn.js} +1 -1
  71. package/assets/{index-G1xB9dvf.js → index-BFzvJeyM.js} +1 -1
  72. package/assets/{index-Cl-v7TvL.js → index-BHVh9ZD-.js} +1 -1
  73. package/assets/{index-yJi2QIJf.js → index-BMIuNfCB.js} +252 -252
  74. package/assets/{index-CZTqkynu.js → index-BTOrBWcS.js} +1 -1
  75. package/assets/{index-b_a6Xe2g.js → index-BUo3wAlN.js} +3 -3
  76. package/assets/{index-1koyBXBc.js → index-Bb9TuCMN.js} +1 -1
  77. package/assets/{index-B81PeozV.js → index-BdDw5syJ.js} +1 -1
  78. package/assets/{index-xZ3i_Adn.js → index-Bdx6vg6T.js} +1 -1
  79. package/assets/{index-tdQJ2A6x.js → index-Bler0kM4.js} +1 -1
  80. package/assets/{index-3ZTohoUZ.js → index-C7EZCMfv.js} +1 -1
  81. package/assets/{index-BBkUTtNV.js → index-CG3EVA6i.js} +2 -2
  82. package/assets/{index-P_XHlb3T.js → index-CP0MJS3n.js} +1 -1
  83. package/assets/{index-frQRdZ2q.js → index-CSzz0-yL.js} +1 -1
  84. package/assets/{index-BFSsZJPW.js → index-CY9EBgzo.js} +1 -1
  85. package/assets/{index-DiOmLLPI.js → index-CgOcSf2Q.js} +1 -1
  86. package/assets/{index-CdsKR_zs.js → index-CkfB4xYf.js} +1 -1
  87. package/assets/{index-CZ1tNVf6.js → index-CpKxcKSt.js} +1 -1
  88. package/assets/{index-B8zb5Fyq.js → index-CsCFxm9l.js} +1 -1
  89. package/assets/{index-DZg10nMY.js → index-CugdcJ5p.js} +1 -1
  90. package/assets/{index-gKwUmrp3.js → index-CvuWb2er.js} +1 -1
  91. package/assets/{index-BgoikptS.js → index-D-jdrajA.js} +1 -1
  92. package/assets/{index-DfTLbDYm.js → index-D6z3Iok7.js} +1 -1
  93. package/assets/{index-DQ2sE8uD.js → index-DA1IdQid.js} +1 -1
  94. package/assets/{index-DMjEzVVJ.js → index-DCUYsq3Z.js} +1 -1
  95. package/assets/{index-1c_qW8yi.js → index-DI-G5L8D.js} +1 -1
  96. package/assets/{index-C0LSKXhw.js → index-DJGQazF5.js} +1 -1
  97. package/assets/{index-C0odNd_G.js → index-DNLfbOQJ.js} +1 -1
  98. package/assets/{index-CuPPMOVj.js → index-DfVobYmm.js} +1 -1
  99. package/assets/{index-C-C5pEJc.js → index-DmnyvmGd.js} +1 -1
  100. package/assets/{index-CpqhaC2H.js → index-DpjOr79p.js} +1 -1
  101. package/assets/{index-DjbRx8bI.js → index-DzCJVhsv.js} +1 -1
  102. package/assets/{index-CXntdDwE.js → index-Eco3bQ72.js} +2 -2
  103. package/assets/{index-CwVjvkdk.js → index-FvB9JTSh.js} +1 -1
  104. package/assets/{index-DU8_EWWx.js → index-H02HAhZo.js} +1 -1
  105. package/assets/{index-CzByZQWv.js → index-LL0BV6rh.js} +1 -1
  106. package/assets/{index-CLBmEx6A.js → index-MsJgZMgr.js} +3 -3
  107. package/assets/{index-Dr4K4hFL.js → index-R3pS6x6y.js} +3 -3
  108. package/assets/{index-CX5Ekh69.js → index-dXYc2QRl.js} +1 -1
  109. package/assets/{index-CkBDyoGg.js → index-hwCoxi9L.js} +1 -1
  110. package/assets/{index-BJ-25Q5l.js → index-ldblNYIT.js} +1 -1
  111. package/assets/{index-CbITlqFn.js → index-n-ShiY2h.js} +1 -1
  112. package/assets/{index-DIR4uPmO.js → index-oFYHMIzO.js} +1 -1
  113. package/assets/{index-Cw6mXTIQ.js → index-rFh28dtY.js} +1 -1
  114. package/assets/{index-CKEG3W2m.js → index-wfubccp5.js} +1 -1
  115. package/assets/{index-Dw4Gh8Hk.js → index-wnx7vlu-.js} +2 -2
  116. package/assets/{index-NPIY1Vbs.js → index-xk15qzPN.js} +1 -1
  117. package/assets/{index.es-CdLNKigl.js → index.es-BEVmNmLD.js} +4 -4
  118. package/assets/{index.es-CZz1nBev.js → index.es-BPA6fTzR.js} +1 -1
  119. package/assets/{index.es-CeoIh9-h.js → index.es-BW6RduBG.js} +1 -1
  120. package/assets/{localBatchGatewayRequest-Dbz593U8.js → localBatchGatewayRequest-C2eNLm--.js} +1 -1
  121. package/assets/{mana-convert-DTic_WF4.js → mana-convert-C341n1xm.js} +1 -1
  122. package/assets/{mana-rate-DTd_zYK_.js → mana-rate-BAPBwbaG.js} +1 -1
  123. package/assets/{networks-D-WgnPJO.js → networks-gEGHz8eL.js} +1 -1
  124. package/assets/{onramp-CxZE_awn.js → onramp-DHcILVIp.js} +1 -1
  125. package/assets/{openzeppelin-BicG6fZ-.js → openzeppelin-BvSgRich.js} +1 -1
  126. package/assets/{parseNft-crNNmDcM.js → parseNft-DrAu-xVe.js} +2 -2
  127. package/assets/{parseSignature-xro4_AeM.js → parseSignature--WNVOXAe.js} +3 -3
  128. package/assets/{parseSignature-TUf4MZpE.js → parseSignature-BlmIeeL7.js} +1 -1
  129. package/assets/{passkeys-DlsWo5hj.js → passkeys-BD41PpMD.js} +1 -1
  130. package/assets/{pay-with-exchange-uJFVzJz2.js → pay-with-exchange-DCmtfnr1.js} +1 -1
  131. package/assets/{qr-overlay-D1DRCZeg.js → qr-overlay-DYViFXBB.js} +1 -1
  132. package/assets/{receive-jEtfcBkz.js → receive-LPMbYHZa.js} +1 -1
  133. package/assets/{resolveImplementation-Dfr_x2D4.js → resolveImplementation-CdVPuboc.js} +1 -1
  134. package/assets/{rpc-HxGwRhjl.js → rpc-D2C2velX.js} +1 -1
  135. package/assets/{secp256k1-BeCdbOwL.js → secp256k1-DLPIWcy9.js} +1 -1
  136. package/assets/{secp256k1-Bmo0zLoN.js → secp256k1-DtCfsIY0.js} +1 -1
  137. package/assets/{secp256k1-CPsxfMTn.js → secp256k1-KqMjq-B-.js} +1 -1
  138. package/assets/{send-SCYWhWgO.js → send-BYANl3m1.js} +1 -1
  139. package/assets/{send-batch-transaction-ClJpcx_r.js → send-batch-transaction-BHqPVqqQ.js} +1 -1
  140. package/assets/{send-eip712-transaction-DCKQGfPC.js → send-eip712-transaction-D3zsFnZJ.js} +2 -2
  141. package/assets/{send-gasless-transaction-C6PqTuT4.js → send-gasless-transaction-Db4a0n6K.js} +2 -2
  142. package/assets/{send-transaction-DCRA_QBx.js → send-transaction-0fPTuVE4.js} +2 -2
  143. package/assets/{sendMetaTransaction-BOtIj1YL.js → sendMetaTransaction-DAsHliEn.js} +1 -1
  144. package/assets/{sendRawTransaction-BkrUK6tH.js → sendRawTransaction-B5IMe5Y5.js} +3 -3
  145. package/assets/{serializeTransaction-bVNzq6Wv.js → serializeTransaction-BT9LeH0D.js} +1 -1
  146. package/assets/{session-proposal-BwFRVt7g.js → session-proposal-plO_EjqI.js} +1 -1
  147. package/assets/{session-request-4TbdsxSC.js → session-request-DTauixOT.js} +2 -2
  148. package/assets/{signing-BxAbixw6.js → signing-BKT41maQ.js} +3 -3
  149. package/assets/{socials-B5zVEegD.js → socials-BPcwRKMp.js} +1 -1
  150. package/assets/{swaps-DQ1LcBTU.js → swaps-DddX0hWZ.js} +1 -1
  151. package/assets/{thirdweb-r2nvH1Ph.js → thirdweb-DI1D_9ce.js} +3 -3
  152. package/assets/{to-serializable-transaction-DMc2E6fk.js → to-serializable-transaction-BZX746C8.js} +2 -2
  153. package/assets/trade-encoding-CK5EArKF.js +1 -0
  154. package/assets/{transactionReceipt-DFdTIN3F.js → transactionReceipt-2D5Q3zvv.js} +1 -1
  155. package/assets/{transactions-DnRd57Kk.js → transactions-DtbDwrsO.js} +1 -1
  156. package/assets/useCreditPacks-Dw0jIjQE.js +1 -0
  157. package/assets/{useInfiniteGrid-CDkGdzFf.js → useInfiniteGrid-Xjfvrq_T.js} +1 -1
  158. package/assets/useManaRate-BEVwu7Q9.js +1 -0
  159. package/assets/{useSecondarySales-BLnZD7gi.js → useSecondarySales-bajhgse5.js} +1 -1
  160. package/assets/{useStore-Dt337zVA.js → useStore-CIqjcPjh.js} +1 -1
  161. package/assets/{useTheme-DlRIY8zD.js → useTheme-DVSXpYGO.js} +1 -1
  162. package/assets/{verifyHash-D8nhWUT9.js → verifyHash-DmL5gbPk.js} +1 -1
  163. package/assets/{w3m-modal-Z-IBP9yL.js → w3m-modal-B2N-eyv6.js} +1 -1
  164. package/assets/{w3m-modal-D1mPkWGM.js → w3m-modal-CfZXCvPG.js} +1 -1
  165. package/assets/{wait-for-tx-receipt-8bgpdxSo.js → wait-for-tx-receipt-BEDrW5cD.js} +1 -1
  166. package/assets/{wallets-BTh4qQ9L.js → wallets-DQk0dtw_.js} +5 -5
  167. package/assets/{web-connector-DXtL7d_s.js → web-connector-2N1NjIJ4.js} +3 -3
  168. package/assets/{writeContract-B7vnLdJy.js → writeContract-BZemjhP4.js} +1 -1
  169. package/assets/{zoraTestnet-kFdaoH4G.js → zoraTestnet-BK5x9nJO.js} +1 -1
  170. package/index.html +11 -11
  171. package/package.json +2 -2
  172. package/assets/Activity-BF3WNwMh.js +0 -291
  173. package/assets/Cart-Cs0FD0IN.js +0 -695
  174. package/assets/Success-CTKJzQjE.js +0 -276
  175. package/assets/buy-DLi3_94e.js +0 -1
  176. package/assets/trade-encoding-BFXwI1r3.js +0 -1
  177. package/assets/useCreditPacks-DnQLmQo7.js +0 -1
  178. package/assets/useManaRate-DwO6H8fK.js +0 -1
@@ -1,4 +1,4 @@
1
- import{M as N,N as U,O as o,P as n,H as D,x as M}from"./index-yJi2QIJf.js";import{r as w,j as g}from"./react-vyZjIDcS.js";import{g as z,a as E,c as I,b as F,s as v}from"./clsx-DhFqZi_3.js";function K(r){return z("MuiCircularProgress",r)}E("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const W=["className","color","disableShrink","size","style","thickness","value","variant"];let l=r=>r,P,b,S,$;const t=44,B=M(P||(P=l`
1
+ import{M as N,N as U,O as o,P as n,H as D,x as M}from"./index-BMIuNfCB.js";import{r as w,j as g}from"./react-vyZjIDcS.js";import{g as z,a as E,c as I,b as F,s as v}from"./clsx-C78Se7VZ.js";function K(r){return z("MuiCircularProgress",r)}E("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const W=["className","color","disableShrink","size","style","thickness","value","variant"];let l=r=>r,P,b,S,$;const t=44,B=M(P||(P=l`
2
2
  0% {
3
3
  transform: rotate(0deg);
4
4
  }
@@ -1,4 +1,4 @@
1
- import{j as e,r as m,e as Y,b as Z}from"./react-vyZjIDcS.js";import{t as v,s as c,af as J,ag as z,I as X,e as a,c as ee,l as te,u as ae,m as re,h as oe,S as E,A as ie,ah as se,ai as ne}from"./index-yJi2QIJf.js";import{E as ce}from"./ErrorNotice-C2qBxBzo.js";import{d as le,g as de,a as pe,P as xe,C as ue,b as me,c as ge,B as he,S as be,M as fe,A as je}from"./browseLayout.styles-Ck-h2OX5.js";import{u as ve}from"./useStore-Dt337zVA.js";import{c as F,a as ye,F as Ce,d as we,P as Se,e as ke,H as Ae,S as Ne}from"./categories-P1zgLmzy.js";import{L as $e}from"./LoadMore-BI2cyij4.js";import{u as Pe}from"./useInfiniteGrid-CDkGdzFf.js";import{G as Me}from"./grid.styles-D4B-EHGj.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";const Re=c.section`
1
+ import{j as e,r as m,e as Y,b as Z}from"./react-vyZjIDcS.js";import{t as v,s as c,af as J,ag as z,I as X,e as a,c as ee,l as te,u as ae,m as re,h as oe,S as E,A as ie,ah as se,ai as ne}from"./index-BMIuNfCB.js";import{E as ce}from"./ErrorNotice-DwhdhAu6.js";import{d as le,g as de,a as pe,P as xe,C as ue,b as me,c as ge,B as he,S as be,M as fe,A as je}from"./browseLayout.styles-B5gAAnD7.js";import{u as ve}from"./useStore-CIqjcPjh.js";import{c as F,a as ye,F as Ce,d as we,P as Se,e as ke,H as Ae,S as Ne}from"./categories-CUWn-vWY.js";import{L as $e}from"./LoadMore-CVBNO6CV.js";import{u as Pe}from"./useInfiniteGrid-Xjfvrq_T.js";import{G as Me}from"./grid.styles-CFlLjGWA.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";const Re=c.section`
2
2
  position: relative;
3
3
  border-radius: ${v.radius.card};
4
4
  overflow: hidden;
@@ -1,4 +1,4 @@
1
- import{j as t,r as v}from"./react-vyZjIDcS.js";import{s as e,t as o,e as g,z as k,J as j,bc as C,h as G,x as Y,I as Q,l as X,a as W,C as B,b as J,bd as Z,be as F,A as q}from"./index-yJi2QIJf.js";import{s as ee,h as U,A as H,g as K,r as te,m as ne,e as ae}from"./authorizations-BrAVsIY_.js";import{i as ie}from"./errors-D660SWgT.js";import{E as oe}from"./ErrorNotice-C2qBxBzo.js";import{a as se}from"./buy-DLi3_94e.js";import{g as re,d as ce}from"./trade-encoding-BFXwI1r3.js";import{s as de,M as le,E as pe}from"./sendMetaTransaction-BOtIj1YL.js";import{I as he,C as ue}from"./ethers-CXBJm_wN.js";const L="shop:resume_after_signin",xe=900*1e3;function rt(a){try{sessionStorage.setItem(L,JSON.stringify({...a,at:Date.now()}))}catch{}}function ct(a){let n;try{n=sessionStorage.getItem(L)}catch{return null}if(!n)return null;try{sessionStorage.removeItem(L)}catch{}let i;try{i=JSON.parse(n)}catch{return null}return!i||i.type!==a||typeof i.at!="number"||Date.now()-i.at>xe?null:i.type==="cart-checkout"?{type:"cart-checkout"}:{type:"item-buy",path:i.path}}function ge(a,n){return(a+n-1n)/n}function fe(a,n,i){return a<=0||n<=0?0n:a>=n?i:ge(i*BigInt(a),BigInt(n))}function dt(a){var m,f,w;const n=Number.isFinite(a.priceCents)?Math.max(0,Math.trunc(a.priceCents)):0,i=Number.isFinite(a.balanceCents)?Math.max(0,Math.trunc(a.balanceCents)):0,s=a.priceManaWei>0n?a.priceManaWei:0n,d=a.manaBalanceWei>0n?a.manaBalanceWei:0n;if(n<=0)return{options:[],preferred:null,manaShortfall:null};const c=[];if(i>=n&&c.push({method:"credits",creditsCents:n,manaWei:0n}),s>0n&&i>0&&i<n){const l=n-i,b=fe(l,n,s);d>=b&&c.push({method:"combined",creditsCents:i,manaWei:b})}s>0n&&d>=s&&c.push({method:"mana",creditsCents:0,manaWei:s});const p=((m=c.find(l=>l.method==="credits"))==null?void 0:m.method)??((f=c.find(l=>l.method==="combined"))==null?void 0:f.method)??((w=c.find(l=>l.method==="mana"))==null?void 0:w.method)??null,y=!c.some(l=>l.method==="mana"||l.method==="combined")&&s>0n&&d>0n?{manaWei:d,manaCents:me(d,n,s),priceCents:n}:null;return{options:c,preferred:p,manaShortfall:y}}function me(a,n,i){return Number(a*BigInt(n)/i)}function lt(a,n){let i=Number.isFinite(n)?Math.max(0,Math.trunc(n)):0;return a.map(s=>{const d=Number.isFinite(s)?Math.max(0,Math.trunc(s)):0,c=Math.min(d,i);return i-=c,c})}function z(a){return Number.isFinite(a)?Math.max(0,a)/10:0}function pt(a,n){return a.options.find(i=>i.method===n)??null}function ht(a,n){if(!Number.isFinite(a)||a<=0||n<=0n)return null;const i=a/10;return Number(n)/1e18/i}const T="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Group%201'%3e%3cpath%20id='Vector'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12%202L22%2012L12%2022L2%2012L12%202ZM12%204.8L19.2%2012L12%2019.2L4.8%2012L12%204.8ZM12%2015.6C12.9548%2015.6001%2013.8705%2015.2209%2014.5457%2014.5459C15.2209%2013.8708%2015.6003%2012.9552%2015.6004%2012.0004C15.6005%2011.0456%2015.2213%2010.1299%2014.5463%209.45471C13.8712%208.7795%2012.9556%208.40011%2012.0008%208.4C11.0461%208.4%2010.1304%208.77928%209.45525%209.45442C8.78012%2010.1295%208.40083%2011.0452%208.40083%2012C8.40083%2012.9548%208.78012%2013.8705%209.45525%2014.5456C10.1304%2015.2207%2011.0461%2015.6%2012.0008%2015.6H12Z'%20fill='white'/%3e%3cg%20id='Rectangle%201'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",be=e.div`
1
+ import{j as t,r as v}from"./react-vyZjIDcS.js";import{s as e,t as o,e as g,z as k,J as j,bd as C,h as G,x as Y,I as Q,l as X,a as W,C as B,b as J,be as Z,bf as F,A as q}from"./index-BMIuNfCB.js";import{s as ee,h as U,A as H,g as K,r as te,m as ne,e as ae}from"./authorizations-uQp0Tner.js";import{i as ie}from"./errors-BHapDldI.js";import{E as oe}from"./ErrorNotice-DwhdhAu6.js";import{a as se}from"./buy-DI2htlf2.js";import{g as re,d as ce}from"./trade-encoding-CK5EArKF.js";import{s as de,M as le,E as pe}from"./sendMetaTransaction-DAsHliEn.js";import{I as he,C as ue}from"./ethers-CXBJm_wN.js";const L="shop:resume_after_signin",xe=900*1e3;function rt(a){try{sessionStorage.setItem(L,JSON.stringify({...a,at:Date.now()}))}catch{}}function ct(a){let n;try{n=sessionStorage.getItem(L)}catch{return null}if(!n)return null;try{sessionStorage.removeItem(L)}catch{}let i;try{i=JSON.parse(n)}catch{return null}return!i||i.type!==a||typeof i.at!="number"||Date.now()-i.at>xe?null:i.type==="cart-checkout"?{type:"cart-checkout"}:{type:"item-buy",path:i.path}}function ge(a,n){return(a+n-1n)/n}function fe(a,n,i){return a<=0||n<=0?0n:a>=n?i:ge(i*BigInt(a),BigInt(n))}function dt(a){var m,f,w;const n=Number.isFinite(a.priceCents)?Math.max(0,Math.trunc(a.priceCents)):0,i=Number.isFinite(a.balanceCents)?Math.max(0,Math.trunc(a.balanceCents)):0,s=a.priceManaWei>0n?a.priceManaWei:0n,d=a.manaBalanceWei>0n?a.manaBalanceWei:0n;if(n<=0)return{options:[],preferred:null,manaShortfall:null};const c=[];if(i>=n&&c.push({method:"credits",creditsCents:n,manaWei:0n}),s>0n&&i>0&&i<n){const l=n-i,b=fe(l,n,s);d>=b&&c.push({method:"combined",creditsCents:i,manaWei:b})}s>0n&&d>=s&&c.push({method:"mana",creditsCents:0,manaWei:s});const p=((m=c.find(l=>l.method==="credits"))==null?void 0:m.method)??((f=c.find(l=>l.method==="combined"))==null?void 0:f.method)??((w=c.find(l=>l.method==="mana"))==null?void 0:w.method)??null,y=!c.some(l=>l.method==="mana"||l.method==="combined")&&s>0n&&d>0n?{manaWei:d,manaCents:me(d,n,s),priceCents:n}:null;return{options:c,preferred:p,manaShortfall:y}}function me(a,n,i){return Number(a*BigInt(n)/i)}function lt(a,n){let i=Number.isFinite(n)?Math.max(0,Math.trunc(n)):0;return a.map(s=>{const d=Number.isFinite(s)?Math.max(0,Math.trunc(s)):0,c=Math.min(d,i);return i-=c,c})}function z(a){return Number.isFinite(a)?Math.max(0,a)/10:0}function pt(a,n){return a.options.find(i=>i.method===n)??null}function ht(a,n){if(!Number.isFinite(a)||a<=0||n<=0n)return null;const i=a/10;return Number(n)/1e18/i}const T="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Group%201'%3e%3cpath%20id='Vector'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12%202L22%2012L12%2022L2%2012L12%202ZM12%204.8L19.2%2012L12%2019.2L4.8%2012L12%204.8ZM12%2015.6C12.9548%2015.6001%2013.8705%2015.2209%2014.5457%2014.5459C15.2209%2013.8708%2015.6003%2012.9552%2015.6004%2012.0004C15.6005%2011.0456%2015.2213%2010.1299%2014.5463%209.45471C13.8712%208.7795%2012.9556%208.40011%2012.0008%208.4C11.0461%208.4%2010.1304%208.77928%209.45525%209.45442C8.78012%2010.1295%208.40083%2011.0452%208.40083%2012C8.40083%2012.9548%208.78012%2013.8705%209.45525%2014.5456C10.1304%2015.2207%2011.0461%2015.6%2012.0008%2015.6H12Z'%20fill='white'/%3e%3cg%20id='Rectangle%201'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",be=e.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  gap: 12px;
@@ -1,4 +1,4 @@
1
- import{b as Y,j as e,L as ue,e as fe,u as be,r as y}from"./react-vyZjIDcS.js";import{t as Z,aA as we,aB as R,aC as _,s as a,aD as je,G as ve,aE as Ce,e as t,aF as W,B as ye,H as q,af as J,n as $e,ag as Q,I as T,c as ke,m as Ne,S,h as Pe,A as Se,az as Le,aG as Ae}from"./index-yJi2QIJf.js";import{d as Me,g as ze,a as Fe,P as Be,C as Ee,b as Ie,c as Re,A as _e,B as We,S as Te,M as Ge,e as He,f as Ue}from"./browseLayout.styles-Ck-h2OX5.js";import{u as De,L as Ke}from"./useStore-Dt337zVA.js";import{c as G,a as Oe,F as Ve,d as Ye,P as Ze,e as qe,H as Je,S as Qe}from"./categories-P1zgLmzy.js";import{L as H}from"./LoadMore-BI2cyij4.js";import{u as U}from"./useInfiniteGrid-CDkGdzFf.js";import{E as D}from"./ErrorNotice-C2qBxBzo.js";import{G as K}from"./grid.styles-D4B-EHGj.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";const{colors:m,radius:X,media:Xe}=Z,et=a.article`
1
+ import{b as Y,j as e,L as ue,e as fe,u as be,r as y}from"./react-vyZjIDcS.js";import{t as Z,aB as we,aC as R,aD as _,s as a,aE as je,G as ve,aF as Ce,e as t,aG as W,B as ye,H as q,af as J,n as $e,ag as Q,I as T,c as ke,m as Ne,S,h as Pe,A as Se,aA as Le,aH as Ae}from"./index-BMIuNfCB.js";import{d as Me,g as Fe,a as ze,P as Be,C as Ee,b as Ie,c as Re,A as _e,B as We,S as Te,M as He,e as Ge,f as Ue}from"./browseLayout.styles-B5gAAnD7.js";import{u as De,L as Ke}from"./useStore-CIqjcPjh.js";import{c as H,a as Oe,F as Ve,d as Ye,P as Ze,e as qe,H as Je,S as Qe}from"./categories-CUWn-vWY.js";import{L as G}from"./LoadMore-CVBNO6CV.js";import{u as U}from"./useInfiniteGrid-Xjfvrq_T.js";import{E as D}from"./ErrorNotice-DwhdhAu6.js";import{G as K}from"./grid.styles-CFlLjGWA.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";const{colors:m,radius:X,media:Xe}=Z,et=a.article`
2
2
  height: 300px;
3
3
  background: ${m.bg};
4
4
  border-radius: ${X.card};
@@ -303,4 +303,4 @@ import{b as Y,j as e,L as ue,e as fe,u as be,r as y}from"./react-vyZjIDcS.js";im
303
303
  &:hover {
304
304
  background: rgba(255, 255, 255, 0.14);
305
305
  }
306
- `,Nt={website:"website",twitter:"twitter",discord:"discord",facebook:"facebook"};function Pt({address:r}){var h,$;const{data:i}=J(r),{data:n}=De(r),l=$e(c=>{var k;return(k=c.session)==null?void 0:k.address}),x=!!l&&l.toLowerCase()===r.toLowerCase(),u=(i==null?void 0:i.name)||Q(r),f=($=(h=i==null?void 0:i.avatar)==null?void 0:h.snapshots)==null?void 0:$.face256,C=(n==null?void 0:n.cover)||Me,d=n==null?void 0:n.description,w=`${ke.profileUrl}/${r}`,g=Ke.filter(c=>n==null?void 0:n.links[c]),b=ze(Fe({name:i==null?void 0:i.name,hasClaimedName:i==null?void 0:i.hasClaimedName,ethAddress:(i==null?void 0:i.ethAddress)??r}));return e.jsxs(gt,{"aria-label":`${u} storefront`,children:[e.jsxs(mt,{children:[e.jsx(ut,{src:C,alt:"",loading:"eager"}),e.jsx(ft,{"aria-hidden":!0})]}),(g.length>0||x)&&e.jsxs(bt,{children:[g.map(c=>e.jsx(wt,{"data-testid":"creator-hero-link",href:(n==null?void 0:n.links[c])??"",target:"_blank",rel:"noopener noreferrer",title:t(`creator.link.${c}`),"aria-label":t(`creator.link.${c}`),children:e.jsx(T,{name:Nt[c]})},c)),x&&e.jsx(jt,{to:"/store-settings",title:t("creator.editStore"),"aria-label":t("creator.editStore"),children:e.jsx(T,{name:"pen"})})]}),e.jsxs(vt,{children:[f?e.jsx(O,{src:f,alt:"",loading:"eager",style:{backgroundColor:b}}):e.jsx(O,{as:"span","aria-hidden":!0,style:{backgroundColor:b}}),e.jsxs("div",{children:[e.jsx(Ct,{children:u}),d?e.jsx(yt,{children:d}):null]}),e.jsxs($t,{children:[e.jsx(kt,{"data-testid":"creator-hero-view",href:w,target:"_blank",rel:"noopener noreferrer",children:t("creator.viewProfile")}),e.jsx(pt,{address:r,className:"creator-hero__follow"})]})]})]})}const V=48;function Gt(){const{address:r}=fe(),i=Y(),[n]=be(),l=n.has("collections"),{data:x}=J(r),u=(x==null?void 0:x.name)||(r?Q(r):t("creator.fallbackName"));Ne({title:u,description:t("seo.creator.description",{name:u})});const[f,C]=y.useState("wearable"),[d,w]=y.useState(null),[g,b]=y.useState([]),[h,$]=y.useState(""),[c,k]=y.useState(""),[A,oe]=y.useState("newest"),M=h&&!Number.isNaN(Number(h))?Number(h):void 0,z=c&&!Number.isNaN(Number(c))?Number(c):void 0,ae=d?Qe[d]:void 0,re=(G.find(o=>o.key===A)??G[0]).server,F={creator:r,category:f,rarities:g.length?g:void 0,wearableCategories:ae,minPriceCredits:M,maxPriceCredits:z,sortBy:re},{items:N,total:ne,isLoading:P,error:B,hasNextPage:se,isFetchingNextPage:E,fetchNextPage:ce}=U(["creator-listings",F],o=>Le({...F,first:V,skip:o}),{enabled:!!r&&!l}),p=U(["creator-collections",r],o=>Ae(r,{first:V,skip:o}).then(s=>({items:s.collections,total:s.total})),{enabled:!!r&&l});function le(o){C(o),w(null),l&&I()}function I(){const o=new URLSearchParams(n);o.delete("collections");const s=o.toString();i({search:s?`?${s}`:""},{replace:!0})}function de(){if(l){I();return}const o=new URLSearchParams(n);o.delete("collections");const s=o.toString();i({search:s?`?${s}&collections`:"?collections"},{replace:!0})}function he(o){b(s=>s.includes(o)?s.filter(me=>me!==o):[...s,o])}function xe(){C("wearable"),w(null),b([]),$(""),k("")}const L=!!(M||z),pe=L?`${h||"0"}–${c||"∞"}`:t("filter.price"),ge=f!=="wearable"||!!d||g.length>0||L;return e.jsxs(Be,{children:[e.jsxs(Ee,{"aria-label":t("creator.breadcrumbAria"),children:[e.jsx(Ie,{onClick:()=>i("/assets"),children:t("creator.breadcrumb")}),e.jsx("span",{children:"/"}),e.jsx(Re,{children:u})]}),r?e.jsx(Pt,{address:r}):null,!l&&!P&&N.length>0?e.jsx(_e,{items:N,source:"creator"}):null,e.jsxs(We,{children:[e.jsx(Te,{children:e.jsx(Oe,{category:f,subCategory:d,onCategory:le,onSub:w,title:t("creator.category"),flat:!0,collections:l,onCollections:de})}),e.jsx(Ge,{children:l?e.jsxs(e.Fragment,{children:[e.jsx(He,{children:e.jsx(Ue,{children:p.isLoading?"…":t("creator.collectionsCount",{count:p.total})})}),p.error?e.jsx(D,{message:t("creator.error")}):null,e.jsx(K,{"data-variant":"collections",children:p.isLoading?e.jsx(S,{count:9}):e.jsxs(e.Fragment,{children:[p.items.map(o=>e.jsx(xt,{collection:o,itemCount:o.itemCount},o.contractAddress)),p.isFetchingNextPage?e.jsx(S,{count:6}):null]})}),e.jsx(H,{hasNextPage:p.hasNextPage,isFetching:p.isFetchingNextPage,onLoadMore:()=>void p.fetchNextPage()}),!p.isLoading&&!p.error&&p.items.length===0?e.jsx("p",{className:"muted",children:t("creator.collectionsEmpty")}):null]}):e.jsxs(e.Fragment,{children:[e.jsx(Ve,{rarities:g,onToggleRarity:he,sort:A,onSort:oe,total:ne,loading:P,anyActive:ge,onClear:xe,renderTrailing:o=>e.jsx(Ye,{panelKey:"price",label:pe,active:L,panel:o,children:e.jsxs(Ze,{"data-variant":"price",children:[e.jsxs(qe,{children:[e.jsx("input",{type:"number",min:"0","aria-label":t("creator.priceMin"),placeholder:t("creator.priceMinPlaceholder"),value:h,onChange:s=>$(s.target.value)}),e.jsx("span",{children:"–"}),e.jsx("input",{type:"number",min:"0","aria-label":t("creator.priceMax"),placeholder:t("creator.priceMaxPlaceholder"),value:c,onChange:s=>k(s.target.value)})]}),e.jsx(Je,{children:t("creator.priceHint",{currency:Pe.name})})]})})}),B?e.jsx(D,{message:t("creator.error")}):null,e.jsx(K,{children:P?e.jsx(S,{count:15}):e.jsxs(e.Fragment,{children:[N.map(o=>e.jsx(Se,{item:o},o.id)),E?e.jsx(S,{count:6}):null]})}),e.jsx(H,{hasNextPage:se,isFetching:E,onLoadMore:()=>void ce()}),!P&&!B&&N.length===0?e.jsx("p",{className:"muted",children:t("creator.empty")}):null]})})]})]})}export{Gt as Creator,Gt as default};
306
+ `,Nt={website:"website",twitter:"twitter",discord:"discord",facebook:"facebook"};function Pt({address:r}){var h,$;const{data:i}=J(r),{data:n}=De(r),l=$e(c=>{var k;return(k=c.session)==null?void 0:k.address}),x=!!l&&l.toLowerCase()===r.toLowerCase(),u=(i==null?void 0:i.name)||Q(r),f=($=(h=i==null?void 0:i.avatar)==null?void 0:h.snapshots)==null?void 0:$.face256,C=(n==null?void 0:n.cover)||Me,d=n==null?void 0:n.description,w=`${ke.profileUrl}/${r}`,g=Ke.filter(c=>n==null?void 0:n.links[c]),b=Fe(ze({name:i==null?void 0:i.name,hasClaimedName:i==null?void 0:i.hasClaimedName,ethAddress:(i==null?void 0:i.ethAddress)??r}));return e.jsxs(gt,{"aria-label":`${u} storefront`,children:[e.jsxs(mt,{children:[e.jsx(ut,{src:C,alt:"",loading:"eager"}),e.jsx(ft,{"aria-hidden":!0})]}),(g.length>0||x)&&e.jsxs(bt,{children:[g.map(c=>e.jsx(wt,{"data-testid":"creator-hero-link",href:(n==null?void 0:n.links[c])??"",target:"_blank",rel:"noopener noreferrer",title:t(`creator.link.${c}`),"aria-label":t(`creator.link.${c}`),children:e.jsx(T,{name:Nt[c]})},c)),x&&e.jsx(jt,{to:"/store-settings",title:t("creator.editStore"),"aria-label":t("creator.editStore"),children:e.jsx(T,{name:"pen"})})]}),e.jsxs(vt,{children:[f?e.jsx(O,{src:f,alt:"",loading:"eager",style:{backgroundColor:b}}):e.jsx(O,{as:"span","aria-hidden":!0,style:{backgroundColor:b}}),e.jsxs("div",{children:[e.jsx(Ct,{children:u}),d?e.jsx(yt,{children:d}):null]}),e.jsxs($t,{children:[e.jsx(kt,{"data-testid":"creator-hero-view",href:w,target:"_blank",rel:"noopener noreferrer",children:t("creator.viewProfile")}),e.jsx(pt,{address:r,className:"creator-hero__follow"})]})]})]})}const V=48;function Ht(){const{address:r}=fe(),i=Y(),[n]=be(),l=n.has("collections"),{data:x}=J(r),u=(x==null?void 0:x.name)||(r?Q(r):t("creator.fallbackName"));Ne({title:u,description:t("seo.creator.description",{name:u})});const[f,C]=y.useState("wearable"),[d,w]=y.useState(null),[g,b]=y.useState([]),[h,$]=y.useState(""),[c,k]=y.useState(""),[A,oe]=y.useState("newest"),M=h&&!Number.isNaN(Number(h))?Number(h):void 0,F=c&&!Number.isNaN(Number(c))?Number(c):void 0,ae=d?Qe[d]:void 0,re=(H.find(o=>o.key===A)??H[0]).server,z={creator:r,category:f,rarities:g.length?g:void 0,wearableCategories:ae,minPriceCredits:M,maxPriceCredits:F,sortBy:re},{items:N,total:ne,isLoading:P,error:B,hasNextPage:se,isFetchingNextPage:E,fetchNextPage:ce}=U(["creator-listings",z],o=>Le({...z,first:V,skip:o}),{enabled:!!r&&!l}),p=U(["creator-collections",r],o=>Ae(r,{first:V,skip:o}).then(s=>({items:s.collections,total:s.total})),{enabled:!!r&&l});function le(o){C(o),w(null),l&&I()}function I(){const o=new URLSearchParams(n);o.delete("collections");const s=o.toString();i({search:s?`?${s}`:""},{replace:!0})}function de(){if(l){I();return}const o=new URLSearchParams(n);o.delete("collections");const s=o.toString();i({search:s?`?${s}&collections`:"?collections"},{replace:!0})}function he(o){b(s=>s.includes(o)?s.filter(me=>me!==o):[...s,o])}function xe(){C("wearable"),w(null),b([]),$(""),k("")}const L=!!(M||F),pe=L?`${h||"0"}–${c||"∞"}`:t("filter.price"),ge=f!=="wearable"||!!d||g.length>0||L;return e.jsxs(Be,{children:[e.jsxs(Ee,{"aria-label":t("creator.breadcrumbAria"),children:[e.jsx(Ie,{onClick:()=>i("/assets"),children:t("creator.breadcrumb")}),e.jsx("span",{children:"/"}),e.jsx(Re,{children:u})]}),r?e.jsx(Pt,{address:r}):null,!l&&!P&&N.length>0?e.jsx(_e,{items:N,source:"creator"}):null,e.jsxs(We,{children:[e.jsx(Te,{children:e.jsx(Oe,{category:f,subCategory:d,onCategory:le,onSub:w,title:t("creator.category"),flat:!0,collections:l,onCollections:de})}),e.jsx(He,{children:l?e.jsxs(e.Fragment,{children:[e.jsx(Ge,{children:e.jsx(Ue,{children:p.isLoading?"…":t("creator.collectionsCount",{count:p.total})})}),p.error?e.jsx(D,{message:t("creator.error")}):null,e.jsx(K,{"data-variant":"collections",children:p.isLoading?e.jsx(S,{count:9}):e.jsxs(e.Fragment,{children:[p.items.map(o=>e.jsx(xt,{collection:o,itemCount:o.itemCount},o.contractAddress)),p.isFetchingNextPage?e.jsx(S,{count:6}):null]})}),e.jsx(G,{hasNextPage:p.hasNextPage,isFetching:p.isFetchingNextPage,onLoadMore:()=>void p.fetchNextPage()}),!p.isLoading&&!p.error&&p.items.length===0?e.jsx("p",{className:"muted",children:t("creator.collectionsEmpty")}):null]}):e.jsxs(e.Fragment,{children:[e.jsx(Ve,{rarities:g,onToggleRarity:he,sort:A,onSort:oe,total:ne,loading:P,anyActive:ge,onClear:xe,renderTrailing:o=>e.jsx(Ye,{panelKey:"price",label:pe,active:L,panel:o,children:e.jsxs(Ze,{"data-variant":"price",children:[e.jsxs(qe,{children:[e.jsx("input",{type:"number",min:"0","aria-label":t("creator.priceMin"),placeholder:t("creator.priceMinPlaceholder"),value:h,onChange:s=>$(s.target.value)}),e.jsx("span",{children:"–"}),e.jsx("input",{type:"number",min:"0","aria-label":t("creator.priceMax"),placeholder:t("creator.priceMaxPlaceholder"),value:c,onChange:s=>k(s.target.value)})]}),e.jsx(Je,{children:t("creator.priceHint",{currency:Pe.name})})]})})}),B?e.jsx(D,{message:t("creator.error")}):null,e.jsx(K,{children:P?e.jsx(S,{count:15}):e.jsxs(e.Fragment,{children:[N.map(o=>e.jsx(Se,{item:o},o.id)),E?e.jsx(S,{count:6}):null]})}),e.jsx(G,{hasNextPage:se,isFetching:E,onLoadMore:()=>void ce()}),!P&&!B&&N.length===0?e.jsx("p",{className:"muted",children:t("creator.empty")}):null]})})]})]})}export{Ht as Creator,Ht as default};
@@ -1 +1 @@
1
- import{j as r}from"./react-vyZjIDcS.js";import{I as i}from"./index-yJi2QIJf.js";function a({message:e,className:o,testId:t}){return e?r.jsxs("p",{className:o?`error-notice ${o}`:"error-notice","data-testid":t,role:"alert",children:[r.jsx(i,{name:"alert",className:"error-notice__ico",size:18}),r.jsx("span",{className:"error-notice__msg",children:e})]}):null}export{a as E};
1
+ import{j as r}from"./react-vyZjIDcS.js";import{I as i}from"./index-BMIuNfCB.js";function a({message:e,className:o,testId:t}){return e?r.jsxs("p",{className:o?`error-notice ${o}`:"error-notice","data-testid":t,role:"alert",children:[r.jsx(i,{name:"alert",className:"error-notice__ico",size:18}),r.jsx("span",{className:"error-notice__msg",children:e})]}):null}export{a as E};
@@ -1 +1 @@
1
- import{C as l,E as w,b as E,S as A,d as k,O as U,N as P,g as f,B as x,e as N,i as I,p as L}from"./W3MFrameProviderSingleton-D3RatyJZ.js";import{g as T,a as W,f as b,b as _,c as v}from"./index-b_a6Xe2g.js";const D=0,C={paymentAsset:null,amount:null,tokenAmount:0,priceLoading:!1,error:null,exchanges:[],isLoading:!1,currentPayment:void 0,isPaymentInProgress:!1,paymentId:"",assets:[]},e=L(C),m={state:e,subscribe(t){return I(e,()=>t(e))},subscribeKey(t,n){return N(e,t,n)},resetState(){Object.assign(e,{...C})},async getAssetsForNetwork(t){const n=v(t),s=await m.getAssetsImageAndPrice(n),r=n.map(a=>{var c,o,p,y;const u=a.asset==="native"?f():`${a.network}:${a.asset}`,i=s.find(S=>{var g,d,h;return((h=(d=(g=S.fungibles)==null?void 0:g[0])==null?void 0:d.address)==null?void 0:h.toLowerCase())===u.toLowerCase()});return{...a,price:((o=(c=i==null?void 0:i.fungibles)==null?void 0:c[0])==null?void 0:o.price)||1,metadata:{...a.metadata,iconUrl:(y=(p=i==null?void 0:i.fungibles)==null?void 0:p[0])==null?void 0:y.iconUrl}}});return e.assets=r,r},async getAssetsImageAndPrice(t){const n=t.map(r=>r.asset==="native"?f():`${r.network}:${r.asset}`);return await Promise.all(n.map(r=>x.fetchTokenPrice({addresses:[r]})))},getTokenAmount(){var s;if(!((s=e==null?void 0:e.paymentAsset)!=null&&s.price))throw new Error("Cannot get token price");const t=P.bigNumber(e.amount??0).round(8),n=P.bigNumber(e.paymentAsset.price).round(8);return t.div(n).round(8).toNumber()},setAmount(t){var n;e.amount=t,(n=e.paymentAsset)!=null&&n.price&&(e.tokenAmount=m.getTokenAmount())},setPaymentAsset(t){e.paymentAsset=t},isPayWithExchangeEnabled(){var t;return(t=U.state.remoteFeatures)==null?void 0:t.payWithExchange},isPayWithExchangeSupported(){return m.isPayWithExchangeEnabled()&&l.state.activeCaipNetwork&&k.PAY_WITH_EXCHANGE_SUPPORTED_CHAIN_NAMESPACES.includes(l.state.activeCaipNetwork.chainNamespace)},async fetchExchanges(){var t;try{const n=m.isPayWithExchangeSupported();if(!e.paymentAsset||!n){e.exchanges=[],e.isLoading=!1;return}e.isLoading=!0;const s=await _({page:D,asset:b(e.paymentAsset.network,e.paymentAsset.asset),amount:((t=e.amount)==null?void 0:t.toString())??"0"});e.exchanges=s.exchanges.slice(0,2)}catch{throw A.showError("Unable to get exchanges"),new Error("Unable to get exchanges")}finally{e.isLoading=!1}},async getPayUrl(t,n){try{const s=Number(n.amount),r=await W({exchangeId:t,asset:b(n.network,n.asset),amount:s.toString(),recipient:`${n.network}:${n.recipient}`});return w.sendEvent({type:"track",event:"PAY_EXCHANGE_SELECTED",properties:{exchange:{id:t},configuration:{network:n.network,asset:n.asset,recipient:n.recipient,amount:s},currentPayment:{type:"exchange",exchangeId:t},source:"fund-from-exchange",headless:!1}}),r}catch(s){throw s instanceof Error&&s.message.includes("is not supported")?new Error("Asset not supported"):new Error(s.message)}},async handlePayWithExchange(t){var n;try{const s=(n=l.getAccountData())==null?void 0:n.address;if(!s)throw new Error("No account connected");if(!e.paymentAsset)throw new Error("No payment asset selected");const r=E.returnOpenHref("","popupWindow","scrollbar=yes,width=480,height=720");if(!r)throw new Error("Could not create popup window");e.isPaymentInProgress=!0,e.paymentId=crypto.randomUUID(),e.currentPayment={type:"exchange",exchangeId:t};const{network:a,asset:u}=e.paymentAsset,i={network:a,asset:u,amount:e.tokenAmount,recipient:s},c=await m.getPayUrl(t,i);if(!c){try{r.close()}catch(o){console.error("Unable to close popup window",o)}throw new Error("Unable to initiate payment")}e.currentPayment.sessionId=c.sessionId,e.currentPayment.status="IN_PROGRESS",e.currentPayment.exchangeId=t,r.location.href=c.url}catch{e.error="Unable to initiate payment",A.showError(e.error)}},async waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r=20}){const a=await m.getBuyStatus(t,n,s);if(a.status==="SUCCESS"||a.status==="FAILED")return a;if(r===0)throw new Error("Unable to get deposit status");return await new Promise(u=>{setTimeout(u,5e3)}),m.waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r-1})},async getBuyStatus(t,n,s){var r,a,u,i,c;try{if(!e.currentPayment)throw new Error("No current payment");const o=await T({sessionId:n,exchangeId:t});if(e.currentPayment.status=o.status,o.status==="SUCCESS"||o.status==="FAILED"){const p=(r=l.getAccountData())==null?void 0:r.address;e.currentPayment.result=o.txHash,e.isPaymentInProgress=!1,w.sendEvent({type:"track",event:o.status==="SUCCESS"?"PAY_SUCCESS":"PAY_ERROR",properties:{message:o.status==="FAILED"?E.parseError(e.error):void 0,source:"fund-from-exchange",paymentId:s,configuration:{network:((a=e.paymentAsset)==null?void 0:a.network)||"",asset:((u=e.paymentAsset)==null?void 0:u.asset)||"",recipient:p||"",amount:e.amount??0},currentPayment:{type:"exchange",exchangeId:(i=e.currentPayment)==null?void 0:i.exchangeId,sessionId:(c=e.currentPayment)==null?void 0:c.sessionId,result:o.txHash}}})}return o}catch{return{status:"UNKNOWN",txHash:""}}},reset(){e.currentPayment=void 0,e.isPaymentInProgress=!1,e.paymentId="",e.paymentAsset=null,e.amount=0,e.tokenAmount=0,e.priceLoading=!1,e.error=null,e.exchanges=[],e.isLoading=!1}};export{m as E};
1
+ import{C as l,E as w,b as E,S as A,d as k,O as U,N as P,g as f,B as x,e as N,i as I,p as L}from"./W3MFrameProviderSingleton-MrB8u6EW.js";import{g as T,a as W,f as b,b as _,c as v}from"./index-BUo3wAlN.js";const D=0,C={paymentAsset:null,amount:null,tokenAmount:0,priceLoading:!1,error:null,exchanges:[],isLoading:!1,currentPayment:void 0,isPaymentInProgress:!1,paymentId:"",assets:[]},e=L(C),m={state:e,subscribe(t){return I(e,()=>t(e))},subscribeKey(t,n){return N(e,t,n)},resetState(){Object.assign(e,{...C})},async getAssetsForNetwork(t){const n=v(t),s=await m.getAssetsImageAndPrice(n),r=n.map(a=>{var c,o,p,y;const u=a.asset==="native"?f():`${a.network}:${a.asset}`,i=s.find(S=>{var g,d,h;return((h=(d=(g=S.fungibles)==null?void 0:g[0])==null?void 0:d.address)==null?void 0:h.toLowerCase())===u.toLowerCase()});return{...a,price:((o=(c=i==null?void 0:i.fungibles)==null?void 0:c[0])==null?void 0:o.price)||1,metadata:{...a.metadata,iconUrl:(y=(p=i==null?void 0:i.fungibles)==null?void 0:p[0])==null?void 0:y.iconUrl}}});return e.assets=r,r},async getAssetsImageAndPrice(t){const n=t.map(r=>r.asset==="native"?f():`${r.network}:${r.asset}`);return await Promise.all(n.map(r=>x.fetchTokenPrice({addresses:[r]})))},getTokenAmount(){var s;if(!((s=e==null?void 0:e.paymentAsset)!=null&&s.price))throw new Error("Cannot get token price");const t=P.bigNumber(e.amount??0).round(8),n=P.bigNumber(e.paymentAsset.price).round(8);return t.div(n).round(8).toNumber()},setAmount(t){var n;e.amount=t,(n=e.paymentAsset)!=null&&n.price&&(e.tokenAmount=m.getTokenAmount())},setPaymentAsset(t){e.paymentAsset=t},isPayWithExchangeEnabled(){var t;return(t=U.state.remoteFeatures)==null?void 0:t.payWithExchange},isPayWithExchangeSupported(){return m.isPayWithExchangeEnabled()&&l.state.activeCaipNetwork&&k.PAY_WITH_EXCHANGE_SUPPORTED_CHAIN_NAMESPACES.includes(l.state.activeCaipNetwork.chainNamespace)},async fetchExchanges(){var t;try{const n=m.isPayWithExchangeSupported();if(!e.paymentAsset||!n){e.exchanges=[],e.isLoading=!1;return}e.isLoading=!0;const s=await _({page:D,asset:b(e.paymentAsset.network,e.paymentAsset.asset),amount:((t=e.amount)==null?void 0:t.toString())??"0"});e.exchanges=s.exchanges.slice(0,2)}catch{throw A.showError("Unable to get exchanges"),new Error("Unable to get exchanges")}finally{e.isLoading=!1}},async getPayUrl(t,n){try{const s=Number(n.amount),r=await W({exchangeId:t,asset:b(n.network,n.asset),amount:s.toString(),recipient:`${n.network}:${n.recipient}`});return w.sendEvent({type:"track",event:"PAY_EXCHANGE_SELECTED",properties:{exchange:{id:t},configuration:{network:n.network,asset:n.asset,recipient:n.recipient,amount:s},currentPayment:{type:"exchange",exchangeId:t},source:"fund-from-exchange",headless:!1}}),r}catch(s){throw s instanceof Error&&s.message.includes("is not supported")?new Error("Asset not supported"):new Error(s.message)}},async handlePayWithExchange(t){var n;try{const s=(n=l.getAccountData())==null?void 0:n.address;if(!s)throw new Error("No account connected");if(!e.paymentAsset)throw new Error("No payment asset selected");const r=E.returnOpenHref("","popupWindow","scrollbar=yes,width=480,height=720");if(!r)throw new Error("Could not create popup window");e.isPaymentInProgress=!0,e.paymentId=crypto.randomUUID(),e.currentPayment={type:"exchange",exchangeId:t};const{network:a,asset:u}=e.paymentAsset,i={network:a,asset:u,amount:e.tokenAmount,recipient:s},c=await m.getPayUrl(t,i);if(!c){try{r.close()}catch(o){console.error("Unable to close popup window",o)}throw new Error("Unable to initiate payment")}e.currentPayment.sessionId=c.sessionId,e.currentPayment.status="IN_PROGRESS",e.currentPayment.exchangeId=t,r.location.href=c.url}catch{e.error="Unable to initiate payment",A.showError(e.error)}},async waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r=20}){const a=await m.getBuyStatus(t,n,s);if(a.status==="SUCCESS"||a.status==="FAILED")return a;if(r===0)throw new Error("Unable to get deposit status");return await new Promise(u=>{setTimeout(u,5e3)}),m.waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r-1})},async getBuyStatus(t,n,s){var r,a,u,i,c;try{if(!e.currentPayment)throw new Error("No current payment");const o=await T({sessionId:n,exchangeId:t});if(e.currentPayment.status=o.status,o.status==="SUCCESS"||o.status==="FAILED"){const p=(r=l.getAccountData())==null?void 0:r.address;e.currentPayment.result=o.txHash,e.isPaymentInProgress=!1,w.sendEvent({type:"track",event:o.status==="SUCCESS"?"PAY_SUCCESS":"PAY_ERROR",properties:{message:o.status==="FAILED"?E.parseError(e.error):void 0,source:"fund-from-exchange",paymentId:s,configuration:{network:((a=e.paymentAsset)==null?void 0:a.network)||"",asset:((u=e.paymentAsset)==null?void 0:u.asset)||"",recipient:p||"",amount:e.amount??0},currentPayment:{type:"exchange",exchangeId:(i=e.currentPayment)==null?void 0:i.exchangeId,sessionId:(c=e.currentPayment)==null?void 0:c.sessionId,result:o.txHash}}})}return o}catch{return{status:"UNKNOWN",txHash:""}}},reset(){e.currentPayment=void 0,e.isPaymentInProgress=!1,e.paymentId="",e.paymentAsset=null,e.amount=0,e.tokenAmount=0,e.priceLoading=!1,e.error=null,e.exchanges=[],e.isLoading=!1}};export{m as E};
@@ -1,4 +1,4 @@
1
- import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t as e,x as T,m as he,e as r,h as p,n as ge,E as fe,ar as f,ap as me,l as N,ay as H,I as re,aj as K,z as E,aQ as D}from"./index-yJi2QIJf.js";import{R as O}from"./resume-buy-Bf0zIH7y.js";import{u as be,p as we,R as ye,c as ke,i as Ce,a as je}from"./useCreditPacks-DnQLmQo7.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";import"./mana-convert-DTic_WF4.js";const P="https://cdn.decentraland.org/@dcl/shop/0.1.0-30612955316.commit-0d9b744/assets/pack-coins-BDh1ZDbh.webp",ne="https://cdn.decentraland.org/@dcl/shop/0.1.0-30612955316.commit-0d9b744/assets/pack-stacks-D-V2jSHW.webp",se="https://cdn.decentraland.org/@dcl/shop/0.1.0-30612955316.commit-0d9b744/assets/pack-chest-BX_j84xW.webp",$e="https://cdn.decentraland.org/@dcl/shop/0.1.0-30612955316.commit-0d9b744/assets/credit-coin-CmcTCd5i.webp",ve="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",Se="https://cdn.decentraland.org/@dcl/shop/0.1.0-30612955316.commit-0d9b744/assets/packs-backdrop-BcXiUPeP.webp",Y="linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0)",Pe=i.div`
1
+ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t as e,x as T,m as he,e as r,h as p,n as ge,E as fe,ar as f,ap as me,l as N,az as H,I as re,aj as K,z as E,aR as D}from"./index-BMIuNfCB.js";import{R as O}from"./resume-buy-Bf0zIH7y.js";import{u as be,p as we,R as ye,c as ke,i as Ce,a as je}from"./useCreditPacks-Dw0jIjQE.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";import"./mana-convert-C341n1xm.js";const P="https://cdn.decentraland.org/@dcl/shop/0.1.0-30633401379.commit-5cd1c31/assets/pack-coins-BDh1ZDbh.webp",ne="https://cdn.decentraland.org/@dcl/shop/0.1.0-30633401379.commit-5cd1c31/assets/pack-stacks-D-V2jSHW.webp",se="https://cdn.decentraland.org/@dcl/shop/0.1.0-30633401379.commit-5cd1c31/assets/pack-chest-BX_j84xW.webp",$e="https://cdn.decentraland.org/@dcl/shop/0.1.0-30633401379.commit-5cd1c31/assets/credit-coin-CmcTCd5i.webp",ve="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",Se="https://cdn.decentraland.org/@dcl/shop/0.1.0-30633401379.commit-5cd1c31/assets/packs-backdrop-BcXiUPeP.webp",Y="linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0)",Pe=i.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  gap: 24px;
@@ -136,7 +136,7 @@ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t a
136
136
  gap: 12px;
137
137
  row-gap: 24px;
138
138
  }
139
- `,Q=i.button`
139
+ `,X=i.button`
140
140
  position: relative;
141
141
  display: flex;
142
142
  flex-direction: column;
@@ -256,7 +256,7 @@ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t a
256
256
  height: 18px;
257
257
  }
258
258
  }
259
- `,X=i.span`
259
+ `,q=i.span`
260
260
  display: flex;
261
261
  flex-direction: column;
262
262
  align-items: center;
@@ -266,7 +266,7 @@ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t a
266
266
  ${e.media.maxWidth("mobile")} {
267
267
  padding-top: 16px;
268
268
  }
269
- `,q=i.span`
269
+ `,Q=i.span`
270
270
  display: flex;
271
271
  flex-direction: column;
272
272
  align-items: center;
@@ -392,15 +392,15 @@ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t a
392
392
  max-width: 100%;
393
393
  aspect-ratio: 1;
394
394
  border-radius: 16px;
395
- `,Qe=i(F)`
395
+ `,Xe=i(F)`
396
396
  width: 100%;
397
397
  height: 48px;
398
398
  border-radius: ${e.radius.card};
399
- `,Xe=i.p`
399
+ `,qe=i.p`
400
400
  margin: 0;
401
401
  font-family: ${e.font.sans};
402
402
  color: ${e.colors.muted};
403
- `,qe=i.div`
403
+ `,Qe=i.div`
404
404
  position: absolute;
405
405
  inset: 0;
406
406
  z-index: 1;
@@ -668,4 +668,4 @@ import{b as xe,u as ue,r as l,j as t}from"./react-vyZjIDcS.js";import{s as i,t a
668
668
  margin: 0;
669
669
  font-family: ${e.font.sans};
670
670
  color: ${e.colors.err};
671
- `,j=Ce()?"mock":"stripe",te=[P,P,ne,se],kt={pack_5:P,pack_10:P,pack_25:ne,pack_50:se};function ae(a,s){return kt[a.id]??te[s%te.length]}function Ct(a,s){return a.artUrl??ae(a,s)}const jt="https://docs.decentraland.org";function ie(a){const s=a;if((s==null?void 0:s.name)==="AbortError")return r("getCredits.errorCanceled");const m=((s==null?void 0:s.message)??"").toLowerCase();return m.includes("sign in")?r("getCredits.errorSignIn",{currency:p.name}):m.includes("timed out")?r("getCredits.errorTimeout",{currency:p.name}):r("getCredits.errorGeneric")}function Tt(){var M;he({title:r("nav.getCredits",{currency:p.name}),noindex:!0});const a=xe(),{session:s,signIn:m}=ge(),o=fe(),[b,x]=ue(),{packs:$,isLoading:y}=be(),[h,u]=l.useState("select"),[c,L]=l.useState(null),[v,W]=l.useState(null),de=(v!=null?(M=$.find(n=>n.credits===v))==null?void 0:M.artUrl:void 0)??$e,[ce,k]=l.useState(null),[le,R]=l.useState(!1),_=l.useRef(null);l.useEffect(()=>()=>{var n;return(n=_.current)==null?void 0:n.abort()},[]);const I=l.useCallback(()=>{x(n=>{const d=new URLSearchParams(n);return d.delete("order"),d.delete("canceled"),d},{replace:!0})},[x]),z=l.useCallback(async n=>{u("processing");const d=new AbortController;_.current=d;try{const g=await we(n,{signal:d.signal,address:s==null?void 0:s.address,identity:s==null?void 0:s.identity});if(g.status==="credited"){const w=g.creditsGranted??(c==null?void 0:c.credits)??0;W(w>0?w:null),u("success"),f("Shop Completed Buy Credits",{order_id:n,pack_usd:(c==null?void 0:c.usd)??null,credits:w>0?w:null,provider:j}),o.invalidateQueries({queryKey:["usd-balance"]});try{if(sessionStorage.getItem(ye)){const S={resumeCheckout:!0,...w>0?{creditsAdded:w}:{}};a("/cart",{state:S});return}}catch{}try{const S=sessionStorage.getItem(O);if(S){sessionStorage.removeItem(O);const G=JSON.parse(S),U=me(G);if(U){a(U,{state:{item:G,resumeBuy:!0}});return}}}catch{}}else g.status==="pending"?(f("Shop Buy Credits Pending",{step:"grant",pack_usd:(c==null?void 0:c.usd)??null}),o.invalidateQueries({queryKey:["usd-balance"]}),u("pending")):(f("Shop Buy Credits Failed",{step:"grant",error_code:"grant_failed",pack_usd:(c==null?void 0:c.usd)??null}),k(g.error??r("getCredits.errorGrant",{currency:p.name})),u("error"))}catch(g){N(g,{flow:"get_credits",step:"grant",order_id:n}),f("Shop Buy Credits Failed",{step:"grant",error_code:H(g),pack_usd:(c==null?void 0:c.usd)??null}),k(ie(g)),u("error")}},[c,s,o,a]),pe=l.useCallback(async n=>{if(!s){m();return}k(null),R(!1),L(n),u(j==="mock"?"processing":"redirecting"),f("Shop Started Buy Credits",{pack_usd:n.usd,credits:n.credits,provider:j});try{const d=await ke(n.id,{address:s.address,identity:s.identity});if(d.mock)z(d.orderId);else if(d.url)f("Shop Redirected To Stripe",{order_id:d.orderId,pack_usd:n.usd,credits:n.credits}),window.location.href=d.url;else throw new Error("Checkout did not return a redirect url")}catch(d){N(d,{flow:"get_credits",step:"checkout",provider:j}),f("Shop Buy Credits Failed",{step:"checkout",error_code:H(d),pack_usd:n.usd}),k(ie(d)),u("error")}},[s,m,z]),A=l.useRef(!1);l.useEffect(()=>{if(A.current)return;const n=b.get("order");if(b.get("canceled")!=null){A.current=!0,f("Shop Buy Credits Cancelled",{order_id:n,provider:j}),I(),R(!0),u("select");return}n&&(u("processing"),s&&(A.current=!0,I(),z(n)))},[b,s]);function B(){var n;(n=_.current)==null||n.abort(),u("select"),L(null),W(null),k(null),R(!1)}return t.jsxs(Pe,{children:[(h==="select"||h==="redirecting")&&t.jsxs(Re,{"data-testid":"credits-hero",children:[t.jsx(_e,{"aria-hidden":!0}),t.jsxs(ze,{$hidden:h==="redirecting",children:[t.jsxs(Ae,{children:[t.jsx(Be,{children:r("getCredits.title",{currency:p.name})}),t.jsxs(Ee,{children:[t.jsx(Te,{children:r("getCredits.subtitle",{currency:p.nameSingular})}),t.jsxs(Fe,{href:jt,target:"_blank",rel:"noreferrer",children:[r("getCredits.learnMore"),t.jsx(re,{name:"link-out"})]})]})]}),le&&t.jsx(Le,{role:"status",children:r("getCredits.canceledNote")}),t.jsx($t,{packs:$,loading:y,onSelect:n=>void pe(n)})]}),h==="redirecting"&&t.jsxs(qe,{role:"status","aria-live":"polite",children:[t.jsx(tt,{src:K,alt:"",width:72,height:72}),t.jsx(Ze,{children:r("getCredits.redirecting")})]})]}),h==="processing"&&t.jsxs(et,{role:"status","aria-live":"polite",children:[t.jsx(oe,{src:K,alt:"",width:61,height:61}),t.jsxs(it,{children:[t.jsxs(rt,{children:[t.jsx("strong",{children:r("getCredits.processing")}),"…"]}),t.jsxs(nt,{"aria-hidden":!0,children:[t.jsx(ot,{children:t.jsx(at,{})}),t.jsx(dt,{children:"1/1"})]})]})]}),h==="success"&&t.jsxs(ct,{role:"status","aria-live":"polite",children:[t.jsxs(lt,{children:[t.jsx(pt,{src:ve,alt:"",width:60,height:60}),t.jsxs(xt,{children:[t.jsx("strong",{children:r("getCredits.successTitle")})," ",r("getCredits.successBody",{currency:p.name})]})]}),v!=null&&t.jsx(ut,{children:t.jsxs(ht,{children:[t.jsx(gt,{src:de,alt:"",width:93,height:93}),t.jsxs(ft,{children:[t.jsx(E,{}),t.jsxs("span",{children:[t.jsx(mt,{children:r("getCredits.creditsAmount",{credits:v,currency:p.name})})," ",t.jsx(bt,{children:r("getCredits.creditsAdded")})]})]})]})}),t.jsxs(wt,{children:[t.jsx(C,{"data-variant":"outline",onClick:B,children:r("getCredits.buyMore",{currency:p.name})}),t.jsx(C,{onClick:()=>a("/assets"),children:r("getCredits.startShopping")})]})]}),h==="pending"&&t.jsxs(Z,{role:"status","aria-live":"polite",children:[t.jsx(J,{children:r("getCredits.pendingTitle",{currency:p.name})}),t.jsx(Xe,{children:r("getCredits.pendingBody")}),t.jsxs(ee,{children:[t.jsx(C,{onClick:()=>a("/assets"),children:r("getCredits.startShopping")}),t.jsx(C,{"data-variant":"outline",onClick:B,children:r("getCredits.done")})]})]}),h==="error"&&t.jsxs(Z,{role:"alert",children:[t.jsx(J,{"data-tone":"error",children:r("getCredits.errorTitle")}),t.jsx(yt,{children:ce}),t.jsx(ee,{children:t.jsx(C,{onClick:B,children:r("getCredits.tryAgain")})})]})]})}function $t({packs:a,loading:s,onSelect:m}){return s?t.jsx(V,{"aria-busy":"true","aria-label":r("getCredits.packsLoading",{currency:p.name}),children:[0,1,2,3].map(o=>t.jsxs(Q,{as:"div","data-skeleton":"true","data-testid":"pack-skeleton","aria-hidden":!0,children:[t.jsxs(X,{children:[t.jsx(q,{children:t.jsx(Ye,{})}),t.jsx(Ve,{})]}),t.jsx(Qe,{})]},o))}):t.jsx(V,{children:a.map((o,b)=>{const x=je(o,a);return t.jsxs(Q,{type:"button","data-testid":"pack","data-best":o.bestValue?"true":void 0,onClick:()=>m(o),"aria-label":x?r("getCredits.packAriaBonus",{amount:D(o.credits),usd:o.usd,bonus:x.bonus,baseline:x.baseline}):r("getCredits.packAria",{amount:D(o.credits),usd:o.usd}),children:[o.bestValue&&t.jsxs(We,{children:[t.jsx(re,{name:"star-rounded"}),r("getCredits.packBadge")]}),t.jsxs(X,{children:[t.jsxs(q,{children:[t.jsxs(Ie,{children:[t.jsx(E,{}),t.jsx(Me,{children:o.credits})]}),t.jsx(Ge,{children:r("getCredits.packUnit",{currency:p.name})}),t.jsxs(Ue,{"data-empty":x?void 0:"true","aria-hidden":!0,children:[t.jsx(E,{}),t.jsx(Ne,{children:x?x.baseline:0}),x&&t.jsx(He,{children:r("getCredits.packBonus",{bonus:x.bonus})})]})]}),t.jsx(Ke,{children:t.jsx("img",{src:Ct(o,b),alt:"",loading:"lazy",width:507,height:507,onError:$=>{const y=$.currentTarget;y.dataset.artFallback||(y.dataset.artFallback="done",y.src=ae(o,b))}})})]}),t.jsxs(De,{children:["$",o.usd.toFixed(2)]})]},o.id)})})}export{Tt as GetCredits,Tt as default};
671
+ `,j=Ce()?"mock":"stripe",te=[P,P,ne,se],kt={pack_5:P,pack_10:P,pack_25:ne,pack_50:se};function ae(a,s){return kt[a.id]??te[s%te.length]}function Ct(a,s){return a.artUrl??ae(a,s)}const jt="https://docs.decentraland.org";function ie(a){const s=a;if((s==null?void 0:s.name)==="AbortError")return r("getCredits.errorCanceled");const m=((s==null?void 0:s.message)??"").toLowerCase();return m.includes("sign in")?r("getCredits.errorSignIn",{currency:p.name}):m.includes("timed out")?r("getCredits.errorTimeout",{currency:p.name}):r("getCredits.errorGeneric")}function Tt(){var M;he({title:r("nav.getCredits",{currency:p.name}),noindex:!0});const a=xe(),{session:s,signIn:m}=ge(),o=fe(),[b,x]=ue(),{packs:$,isLoading:y}=be(),[h,u]=l.useState("select"),[c,L]=l.useState(null),[v,W]=l.useState(null),de=(v!=null?(M=$.find(n=>n.credits===v))==null?void 0:M.artUrl:void 0)??$e,[ce,k]=l.useState(null),[le,R]=l.useState(!1),_=l.useRef(null);l.useEffect(()=>()=>{var n;return(n=_.current)==null?void 0:n.abort()},[]);const I=l.useCallback(()=>{x(n=>{const d=new URLSearchParams(n);return d.delete("order"),d.delete("canceled"),d},{replace:!0})},[x]),z=l.useCallback(async n=>{u("processing");const d=new AbortController;_.current=d;try{const g=await we(n,{signal:d.signal,address:s==null?void 0:s.address,identity:s==null?void 0:s.identity});if(g.status==="credited"){const w=g.creditsGranted??(c==null?void 0:c.credits)??0;W(w>0?w:null),u("success"),f("Shop Completed Buy Credits",{order_id:n,pack_usd:(c==null?void 0:c.usd)??null,credits:w>0?w:null,provider:j}),o.invalidateQueries({queryKey:["usd-balance"]});try{if(sessionStorage.getItem(ye)){const S={resumeCheckout:!0,...w>0?{creditsAdded:w}:{}};a("/cart",{state:S});return}}catch{}try{const S=sessionStorage.getItem(O);if(S){sessionStorage.removeItem(O);const G=JSON.parse(S),U=me(G);if(U){a(U,{state:{item:G,resumeBuy:!0}});return}}}catch{}}else g.status==="pending"?(f("Shop Buy Credits Pending",{step:"grant",pack_usd:(c==null?void 0:c.usd)??null}),o.invalidateQueries({queryKey:["usd-balance"]}),u("pending")):(f("Shop Buy Credits Failed",{step:"grant",error_code:"grant_failed",pack_usd:(c==null?void 0:c.usd)??null}),k(g.error??r("getCredits.errorGrant",{currency:p.name})),u("error"))}catch(g){N(g,{flow:"get_credits",step:"grant",order_id:n}),f("Shop Buy Credits Failed",{step:"grant",error_code:H(g),pack_usd:(c==null?void 0:c.usd)??null}),k(ie(g)),u("error")}},[c,s,o,a]),pe=l.useCallback(async n=>{if(!s){m();return}k(null),R(!1),L(n),u(j==="mock"?"processing":"redirecting"),f("Shop Started Buy Credits",{pack_usd:n.usd,credits:n.credits,provider:j});try{const d=await ke(n.id,{address:s.address,identity:s.identity});if(d.mock)z(d.orderId);else if(d.url)f("Shop Redirected To Stripe",{order_id:d.orderId,pack_usd:n.usd,credits:n.credits}),window.location.href=d.url;else throw new Error("Checkout did not return a redirect url")}catch(d){N(d,{flow:"get_credits",step:"checkout",provider:j}),f("Shop Buy Credits Failed",{step:"checkout",error_code:H(d),pack_usd:n.usd}),k(ie(d)),u("error")}},[s,m,z]),A=l.useRef(!1);l.useEffect(()=>{if(A.current)return;const n=b.get("order");if(b.get("canceled")!=null){A.current=!0,f("Shop Buy Credits Cancelled",{order_id:n,provider:j}),I(),R(!0),u("select");return}n&&(u("processing"),s&&(A.current=!0,I(),z(n)))},[b,s]);function B(){var n;(n=_.current)==null||n.abort(),u("select"),L(null),W(null),k(null),R(!1)}return t.jsxs(Pe,{children:[(h==="select"||h==="redirecting")&&t.jsxs(Re,{"data-testid":"credits-hero",children:[t.jsx(_e,{"aria-hidden":!0}),t.jsxs(ze,{$hidden:h==="redirecting",children:[t.jsxs(Ae,{children:[t.jsx(Be,{children:r("getCredits.title",{currency:p.name})}),t.jsxs(Ee,{children:[t.jsx(Te,{children:r("getCredits.subtitle",{currency:p.nameSingular})}),t.jsxs(Fe,{href:jt,target:"_blank",rel:"noreferrer",children:[r("getCredits.learnMore"),t.jsx(re,{name:"link-out"})]})]})]}),le&&t.jsx(Le,{role:"status",children:r("getCredits.canceledNote")}),t.jsx($t,{packs:$,loading:y,onSelect:n=>void pe(n)})]}),h==="redirecting"&&t.jsxs(Qe,{role:"status","aria-live":"polite",children:[t.jsx(tt,{src:K,alt:"",width:72,height:72}),t.jsx(Ze,{children:r("getCredits.redirecting")})]})]}),h==="processing"&&t.jsxs(et,{role:"status","aria-live":"polite",children:[t.jsx(oe,{src:K,alt:"",width:61,height:61}),t.jsxs(it,{children:[t.jsxs(rt,{children:[t.jsx("strong",{children:r("getCredits.processing")}),"…"]}),t.jsxs(nt,{"aria-hidden":!0,children:[t.jsx(ot,{children:t.jsx(at,{})}),t.jsx(dt,{children:"1/1"})]})]})]}),h==="success"&&t.jsxs(ct,{role:"status","aria-live":"polite",children:[t.jsxs(lt,{children:[t.jsx(pt,{src:ve,alt:"",width:60,height:60}),t.jsxs(xt,{children:[t.jsx("strong",{children:r("getCredits.successTitle")})," ",r("getCredits.successBody",{currency:p.name})]})]}),v!=null&&t.jsx(ut,{children:t.jsxs(ht,{children:[t.jsx(gt,{src:de,alt:"",width:93,height:93}),t.jsxs(ft,{children:[t.jsx(E,{}),t.jsxs("span",{children:[t.jsx(mt,{children:r("getCredits.creditsAmount",{credits:v,currency:p.name})})," ",t.jsx(bt,{children:r("getCredits.creditsAdded")})]})]})]})}),t.jsxs(wt,{children:[t.jsx(C,{"data-variant":"outline",onClick:B,children:r("getCredits.buyMore",{currency:p.name})}),t.jsx(C,{onClick:()=>a("/assets"),children:r("getCredits.startShopping")})]})]}),h==="pending"&&t.jsxs(Z,{role:"status","aria-live":"polite",children:[t.jsx(J,{children:r("getCredits.pendingTitle",{currency:p.name})}),t.jsx(qe,{children:r("getCredits.pendingBody")}),t.jsxs(ee,{children:[t.jsx(C,{onClick:()=>a("/assets"),children:r("getCredits.startShopping")}),t.jsx(C,{"data-variant":"outline",onClick:B,children:r("getCredits.done")})]})]}),h==="error"&&t.jsxs(Z,{role:"alert",children:[t.jsx(J,{"data-tone":"error",children:r("getCredits.errorTitle")}),t.jsx(yt,{children:ce}),t.jsx(ee,{children:t.jsx(C,{onClick:B,children:r("getCredits.tryAgain")})})]})]})}function $t({packs:a,loading:s,onSelect:m}){return s?t.jsx(V,{"aria-busy":"true","aria-label":r("getCredits.packsLoading",{currency:p.name}),children:[0,1,2,3].map(o=>t.jsxs(X,{as:"div","data-skeleton":"true","data-testid":"pack-skeleton","aria-hidden":!0,children:[t.jsxs(q,{children:[t.jsx(Q,{children:t.jsx(Ye,{})}),t.jsx(Ve,{})]}),t.jsx(Xe,{})]},o))}):t.jsx(V,{children:a.map((o,b)=>{const x=je(o,a);return t.jsxs(X,{type:"button","data-testid":"pack","data-best":o.bestValue?"true":void 0,onClick:()=>m(o),"aria-label":x?r("getCredits.packAriaBonus",{amount:D(o.credits),usd:o.usd,bonus:x.bonus,baseline:x.baseline}):r("getCredits.packAria",{amount:D(o.credits),usd:o.usd}),children:[o.bestValue&&t.jsxs(We,{children:[t.jsx(re,{name:"star-rounded"}),r("getCredits.packBadge")]}),t.jsxs(q,{children:[t.jsxs(Q,{children:[t.jsxs(Ie,{children:[t.jsx(E,{}),t.jsx(Me,{children:o.credits})]}),t.jsx(Ge,{children:r("getCredits.packUnit",{currency:p.name})}),t.jsxs(Ue,{"data-empty":x?void 0:"true","aria-hidden":!0,children:[t.jsx(E,{}),t.jsx(Ne,{children:x?x.baseline:0}),x&&t.jsx(He,{children:r("getCredits.packBonus",{bonus:x.bonus})})]})]}),t.jsx(Ke,{children:t.jsx("img",{src:Ct(o,b),alt:"",loading:"lazy",width:507,height:507,onError:$=>{const y=$.currentTarget;y.dataset.artFallback||(y.dataset.artFallback="done",y.src=ae(o,b))}})})]}),t.jsxs(De,{children:["$",o.usd.toFixed(2)]})]},o.id)})})}export{Tt as GetCredits,Tt 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-CkBDyoGg.js";import{d as g,r as v}from"./index-b_a6Xe2g.js";import{C as c}from"./ConstantsUtil-Dfwpy1eP.js";import{R as $,O as u}from"./W3MFrameProviderSingleton-D3RatyJZ.js";import{au as y}from"./NetworkUtil-HlUKXKcF.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-hwCoxi9L.js";import{d as g,r as v}from"./index-BUo3wAlN.js";import{C as c}from"./ConstantsUtil-Dfwpy1eP.js";import{R as $,O as u}from"./W3MFrameProviderSingleton-MrB8u6EW.js";import{au as y}from"./NetworkUtil-HlUKXKcF.js";const b=g`
2
2
  :host {
3
3
  display: flex;
4
4
  justify-content: center;
@@ -1,4 +1,4 @@
1
- import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s as t,x as ie,y as se,e as i,h as R,B as I,z,ar as ne,aP as K,l as W,m as re,n as oe,E as ae,u as de,F as ce}from"./index-yJi2QIJf.js";import{i as le,R as pe,f as ge}from"./import-DSm0v4af.js";import{u as xe}from"./useSecondarySales-BLnZD7gi.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";import"./buy-DLi3_94e.js";import"./authorizations-BrAVsIY_.js";import"./sendMetaTransaction-BOtIj1YL.js";import"./trade-encoding-BFXwI1r3.js";import"./mana-rate-DTd_zYK_.js";import"./mana-convert-DTic_WF4.js";function U({size:o=12,...w}){return e.jsx("svg",{viewBox:"0 0 20 20",width:o,height:o,fill:"none","aria-hidden":!0,focusable:"false",...w,children:e.jsx("path",{d:"M5 10.5l3 3 7-7.5",stroke:"#fff",strokeWidth:"2.4",strokeLinecap:"round",strokeLinejoin:"round"})})}const{colors:M,radius:me,z:ue}=S,he=ie`
1
+ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s as t,x as ie,y as se,e as i,h as Q,B as I,z,ar as ne,aQ as K,l as W,m as re,n as oe,E as ae,u as de,F as ce}from"./index-BMIuNfCB.js";import{i as le,R as pe,f as ge}from"./import-xE4hDmDm.js";import{u as xe}from"./useSecondarySales-bajhgse5.js";import"./sentry-B35L1FdR.js";import"./dcl-schemas-BICTSpB5.js";import"./ethers-CXBJm_wN.js";import"./intl-CBcMB1D2.js";import"./buy-DI2htlf2.js";import"./authorizations-uQp0Tner.js";import"./sendMetaTransaction-DAsHliEn.js";import"./trade-encoding-CK5EArKF.js";import"./mana-rate-BAPBwbaG.js";import"./mana-convert-C341n1xm.js";function U({size:o=12,...w}){return e.jsx("svg",{viewBox:"0 0 20 20",width:o,height:o,fill:"none","aria-hidden":!0,focusable:"false",...w,children:e.jsx("path",{d:"M5 10.5l3 3 7-7.5",stroke:"#fff",strokeWidth:"2.4",strokeLinecap:"round",strokeLinejoin:"round"})})}const{colors:M,radius:me,z:ue}=S,he=ie`
2
2
  0% {
3
3
  transform: scale(0);
4
4
  opacity: 0;
@@ -179,7 +179,7 @@ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s a
179
179
  font-size: 12px;
180
180
  `,Ne=t.p`
181
181
  margin: 12px 0 0;
182
- `;function Be({queue:o,session:w,onClose:j,onDone:m}){const v=ee(),p=se(w.providerType),[g,b]=h.useState(()=>o.map(()=>"pending")),[A,P]=h.useState("running"),k=h.useRef(!1);h.useEffect(()=>{if(k.current)return;k.current=!0;let n=!1;return(async()=>{for(let a=0;a<o.length;a++){if(n)return;b(x=>x.map((u,f)=>f===a?"active":u));try{await le(o[a].item,o[a].priceCredits,w),ne("Shop Migrated Listing",{item_id:o[a].item.itemId??o[a].item.oldTradeId??null,contract_address:o[a].item.contractAddress,new_price_credits:o[a].priceCredits,new_price_usd:K(o[a].priceCredits)}),n||b(x=>x.map((u,f)=>f===a?"done":u))}catch(x){if(x instanceof pe)W(x,{flow:"import_listing",step:"relist",itemId:o[a].item.itemId??o[a].item.oldTradeId}),n||b(u=>u.map((f,C)=>C===a?"unlisted":f));else{const u=x,f=u.code===4001||/reject|denied|cancel/i.test(u.message??"");f||W(x,{flow:"import_listing",itemId:o[a].item.itemId??o[a].item.oldTradeId}),n||b(C=>C.map((B,Q)=>Q===a?f?"skipped":"failed":B))}}}n||P("finished")})(),()=>{n=!0}},[]);const $=g.filter(n=>n==="done").length,E=g.findIndex(n=>n==="active"),N=Math.round(g.filter(n=>n!=="pending"&&n!=="active").length/o.length*100);function L(){m(),j()}if(A==="finished"){const n=g.filter(a=>a==="skipped"||a==="failed").length,l=g.filter(a=>a==="unlisted").length;return e.jsx(H,{role:"presentation",children:e.jsxs(Z,{"data-success":!0,role:"dialog","aria-modal":"true",children:[e.jsx(be,{"aria-hidden":!0,children:e.jsx(U,{size:30})}),e.jsx(O,{children:$>0?i("migrate.successTitle"):i("migrate.nothingTitle")}),e.jsxs("p",{className:"muted",style:{margin:0},children:[$>0?i("migrate.listedSummary",{count:$,currency:R.name}):i("migrate.noneListed"),n>0?" "+i("migrate.skippedSummary",{count:n}):"",l>0?" "+i("migrate.unlistedSummary",{count:l}):""]}),e.jsxs(fe,{"data-actions":!0,children:[e.jsx(I,{variant:"ghost",onClick:L,children:i("getCredits.done")}),l>0?e.jsx(I,{variant:"purple",onClick:()=>{m(),j(),v("/my-assets")},children:i("migrate.goToMyAssets")}):$>0?e.jsx(I,{variant:"purple",onClick:()=>{m(),j(),v("/assets")},children:i("migrate.viewInShop")}):null]})]})})}return e.jsx(H,{role:"presentation",children:e.jsxs(je,{"data-testid":"modal",role:"dialog","aria-modal":"true","aria-live":"polite",children:[e.jsx(O,{children:i("migrate.listingTitle")}),e.jsxs("p",{className:"muted small",style:{margin:"0 0 4px"},children:[p?i("migrate.subConfirm"):i("migrate.subManaged")," ",E>=0?i("migrate.progressCount",{current:E+1,total:o.length}):""]}),e.jsx(ve,{children:e.jsx(ke,{style:{width:`${N}%`}})}),e.jsx($e,{children:o.map((n,l)=>e.jsxs(Se,{"data-status":g[l],children:[e.jsx(Ie,{children:n.item.thumbnail?e.jsx("img",{src:n.item.thumbnail,alt:""}):null}),e.jsx(Le,{title:n.item.name,children:n.item.name||i("migrate.itemFallback")}),e.jsxs(Ce,{children:[e.jsx(z,{className:"ccy-mark"})," ",n.priceCredits.toLocaleString()]}),e.jsx(Te,{children:g[l]==="active"?e.jsxs(e.Fragment,{children:[e.jsx(Me,{className:"spinner","aria-hidden":!0})," ",p?i("migrate.statusConfirm"):i("migrate.statusAdding")]}):g[l]==="done"?e.jsx(Ee,{children:e.jsx(U,{})}):g[l]==="skipped"?e.jsx(_,{children:i("migrate.statusSkipped")}):g[l]==="failed"?e.jsx(_,{children:i("migrate.statusFailed")}):g[l]==="unlisted"?e.jsx(_,{title:i("migrate.unlistedTooltip"),children:i("migrate.statusUnlisted")}):e.jsx(ze,{children:i("migrate.statusWaiting")})})]},n.item.oldTradeId))}),e.jsx(Ne,{className:"muted small",children:p?i("migrate.hintConfirm"):i("migrate.hintManaged")})]})})}const{colors:r,gradients:Re,radius:Ae}=S,D="@media (max-width: 620px)",G=t.div`
182
+ `;function Be({queue:o,session:w,onClose:j,onDone:m}){const v=ee(),p=se(w.providerType),[g,b]=h.useState(()=>o.map(()=>"pending")),[R,A]=h.useState("running"),k=h.useRef(!1);h.useEffect(()=>{if(k.current)return;k.current=!0;let n=!1;return(async()=>{for(let a=0;a<o.length;a++){if(n)return;b(x=>x.map((u,f)=>f===a?"active":u));try{await le(o[a].item,o[a].priceCredits,w),ne("Shop Migrated Listing",{item_id:o[a].item.itemId??o[a].item.oldTradeId??null,contract_address:o[a].item.contractAddress,new_price_credits:o[a].priceCredits,new_price_usd:K(o[a].priceCredits)}),n||b(x=>x.map((u,f)=>f===a?"done":u))}catch(x){if(x instanceof pe)W(x,{flow:"import_listing",step:"relist",itemId:o[a].item.itemId??o[a].item.oldTradeId}),n||b(u=>u.map((f,C)=>C===a?"unlisted":f));else{const u=x,f=u.code===4001||/reject|denied|cancel/i.test(u.message??"");f||W(x,{flow:"import_listing",itemId:o[a].item.itemId??o[a].item.oldTradeId}),n||b(C=>C.map((B,F)=>F===a?f?"skipped":"failed":B))}}}n||A("finished")})(),()=>{n=!0}},[]);const $=g.filter(n=>n==="done").length,E=g.findIndex(n=>n==="active"),N=Math.round(g.filter(n=>n!=="pending"&&n!=="active").length/o.length*100);function L(){m(),j()}if(R==="finished"){const n=g.filter(a=>a==="skipped"||a==="failed").length,l=g.filter(a=>a==="unlisted").length;return e.jsx(H,{role:"presentation",children:e.jsxs(Z,{"data-success":!0,role:"dialog","aria-modal":"true",children:[e.jsx(be,{"aria-hidden":!0,children:e.jsx(U,{size:30})}),e.jsx(O,{children:$>0?i("migrate.successTitle"):i("migrate.nothingTitle")}),e.jsxs("p",{className:"muted",style:{margin:0},children:[$>0?i("migrate.listedSummary",{count:$,currency:Q.name}):i("migrate.noneListed"),n>0?" "+i("migrate.skippedSummary",{count:n}):"",l>0?" "+i("migrate.unlistedSummary",{count:l}):""]}),e.jsxs(fe,{"data-actions":!0,children:[e.jsx(I,{variant:"ghost",onClick:L,children:i("getCredits.done")}),l>0?e.jsx(I,{variant:"purple",onClick:()=>{m(),j(),v("/my-assets")},children:i("migrate.goToMyAssets")}):$>0?e.jsx(I,{variant:"purple",onClick:()=>{m(),j(),v("/assets")},children:i("migrate.viewInShop")}):null]})]})})}return e.jsx(H,{role:"presentation",children:e.jsxs(je,{"data-testid":"modal",role:"dialog","aria-modal":"true","aria-live":"polite",children:[e.jsx(O,{children:i("migrate.listingTitle")}),e.jsxs("p",{className:"muted small",style:{margin:"0 0 4px"},children:[p?i("migrate.subConfirm"):i("migrate.subManaged")," ",E>=0?i("migrate.progressCount",{current:E+1,total:o.length}):""]}),e.jsx(ve,{children:e.jsx(ke,{style:{width:`${N}%`}})}),e.jsx($e,{children:o.map((n,l)=>e.jsxs(Se,{"data-status":g[l],children:[e.jsx(Ie,{children:n.item.thumbnail?e.jsx("img",{src:n.item.thumbnail,alt:""}):null}),e.jsx(Le,{title:n.item.name,children:n.item.name||i("migrate.itemFallback")}),e.jsxs(Ce,{children:[e.jsx(z,{className:"ccy-mark"})," ",n.priceCredits.toLocaleString()]}),e.jsx(Te,{children:g[l]==="active"?e.jsxs(e.Fragment,{children:[e.jsx(Me,{className:"spinner","aria-hidden":!0})," ",p?i("migrate.statusConfirm"):i("migrate.statusAdding")]}):g[l]==="done"?e.jsx(Ee,{children:e.jsx(U,{})}):g[l]==="skipped"?e.jsx(_,{children:i("migrate.statusSkipped")}):g[l]==="failed"?e.jsx(_,{children:i("migrate.statusFailed")}):g[l]==="unlisted"?e.jsx(_,{title:i("migrate.unlistedTooltip"),children:i("migrate.statusUnlisted")}):e.jsx(ze,{children:i("migrate.statusWaiting")})})]},n.item.oldTradeId))}),e.jsx(Ne,{className:"muted small",children:p?i("migrate.hintConfirm"):i("migrate.hintManaged")})]})})}const{colors:r,gradients:Qe,radius:Re}=S,D="@media (max-width: 620px)",G=t.div`
183
183
  max-width: 520px;
184
184
  margin: 0 auto;
185
185
  text-align: center;
@@ -196,13 +196,13 @@ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s a
196
196
  margin: 4px 0 0;
197
197
  `,V=t(I)`
198
198
  margin-top: 10px;
199
- `,Pe=t.div`
199
+ `,Ae=t.div`
200
200
  max-width: 860px;
201
201
  margin: 0 auto;
202
202
  padding-bottom: 120px;
203
- `,Qe=t.header`
203
+ `,Fe=t.header`
204
204
  margin-bottom: 18px;
205
- `,Fe=t.span`
205
+ `,Pe=t.span`
206
206
  display: inline-block;
207
207
  font-size: 12px;
208
208
  font-weight: 700;
@@ -220,7 +220,7 @@ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s a
220
220
  line-height: 1.08;
221
221
  margin: 0 0 10px;
222
222
  `,Ke=t.span`
223
- background: ${Re.amethyst};
223
+ background: ${Qe.amethyst};
224
224
  -webkit-background-clip: text;
225
225
  background-clip: text;
226
226
  color: transparent;
@@ -317,7 +317,7 @@ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s a
317
317
  `,Xe=t.div`
318
318
  width: 56px;
319
319
  height: 56px;
320
- border-radius: ${Ae.card};
320
+ border-radius: ${Re.card};
321
321
  overflow: hidden;
322
322
  flex: none;
323
323
  display: grid;
@@ -444,4 +444,4 @@ import{j as e,b as ee,r as h,L as te}from"./react-vyZjIDcS.js";import{t as S,s a
444
444
  flex: 1 1 auto;
445
445
  `,xt=t(I)`
446
446
  padding: 13px 24px;
447
- `,mt=[{key:"creations",title:"importListings.creations.title",sub:"importListings.creations.sub"},{key:"owned",title:"importListings.owned.title",sub:"importListings.owned.sub",secondary:!0}];function Tt(){re({title:i("seo.import.title"),noindex:!0});const{session:o,signIn:w,restore:j}=oe(),m=ae(),v=o==null?void 0:o.address;h.useEffect(()=>{j()},[j]);const{data:p,isLoading:g}=de({queryKey:["importable",v],queryFn:()=>ge(v),enabled:!!v}),b=xe(),A=h.useMemo(()=>mt.filter(d=>!d.secondary||b),[b]),[P,k]=h.useState({}),[$,E]=h.useState(new Set),[N,L]=h.useState(null),n=h.useMemo(()=>[...(p==null?void 0:p.creations)??[],...b?(p==null?void 0:p.owned)??[]:[]],[p,b]);h.useEffect(()=>{n.length&&k(d=>{const c={...d};for(const s of n)c[s.oldTradeId]==null&&(c[s.oldTradeId]=s.suggestedCredits);return c})},[n]);const l=d=>!$.has(d),a=d=>P[d.oldTradeId]??d.suggestedCredits,x=n.filter(d=>l(d.oldTradeId)),u=x.reduce((d,c)=>d+a(c),0);function f(d,c){const s=c.replace(/[^\d]/g,"");k(T=>({...T,[d]:s===""?0:parseInt(s,10)}))}function C(d){E(c=>{const s=new Set(c);return s.has(d)?s.delete(d):s.add(d),s})}function B(d){return d.map(c=>({item:c,priceCredits:Math.max(1,a(c))}))}function Q(){m.invalidateQueries({queryKey:["importable"]}),m.invalidateQueries({queryKey:["shop-items"]}),m.invalidateQueries({queryKey:["catalog-items"]}),m.invalidateQueries({queryKey:["overview-listings"]}),m.invalidateQueries({queryKey:["upsell-listings"]}),m.invalidateQueries({queryKey:["my-assets"]}),m.invalidateQueries({queryKey:["collection-sale-state"]}),ce.success(i("importListings.toastUpdated"))}return o?!g&&n.length===0?e.jsxs(G,{children:[e.jsx(Y,{"aria-hidden":!0,children:"✨"}),e.jsx(J,{children:i("importListings.emptyTitle")}),e.jsx("p",{className:"muted",children:i("importListings.emptyBody")}),e.jsx(V,{as:te,to:"/my-assets",variant:"purple",children:i("importListings.goToMyAssets")})]}):e.jsxs(Pe,{children:[e.jsxs(Qe,{children:[e.jsx(Fe,{children:i("importListings.eyebrow")}),e.jsxs(_e,{children:[i("importListings.titleLead")," ",e.jsx(Ke,{children:i("importListings.titleAccent")})]}),e.jsx(De,{children:i("importListings.lede",{currency:R.name})})]}),e.jsxs(We,{children:[e.jsx(z,{className:"ccy-mark",color:S.colors.text})," ",i("importListings.rate",{currency:R.nameSingular})]}),g?e.jsx(X,{children:Array.from({length:4}).map((d,c)=>e.jsx(Je,{},c))}):A.map(d=>{const c=(p==null?void 0:p[d.key])??[];return c.length===0?null:e.jsxs(Ue,{children:[e.jsxs(He,{children:[e.jsx(Oe,{children:i(d.title)}),e.jsx(Ge,{children:i(d.sub)})]}),e.jsx(X,{children:c.map(s=>{const T=a(s),q=T!==s.suggestedCredits;return e.jsxs(Ye,{"data-off":l(s.oldTradeId)?void 0:!0,children:[e.jsx(Ve,{type:"checkbox",checked:l(s.oldTradeId),onChange:()=>C(s.oldTradeId),"aria-label":i("importListings.includeItem",{name:s.name})}),e.jsx(Xe,{children:s.thumbnail?e.jsx("img",{src:s.thumbnail,alt:""}):null}),e.jsxs(Ze,{children:[e.jsx(qe,{title:s.name,children:s.name||i("importListings.itemFallback")}),e.jsx(et,{children:s.rarity})]}),e.jsxs(tt,{children:[e.jsxs(it,{children:[e.jsx(z,{size:15,color:S.colors.text}),e.jsx(st,{"data-testid":"imp-price-input",inputMode:"numeric",value:T.toLocaleString(),onChange:F=>f(s.oldTradeId,F.target.value),"aria-label":i("importListings.priceAria",{currency:R.name,name:s.name})})]}),e.jsxs(nt,{children:[e.jsxs("span",{children:["$",K(T).toFixed(2)]}),q?e.jsxs(rt,{onClick:()=>k(F=>({...F,[s.oldTradeId]:s.suggestedCredits})),children:[i("importListings.resetTo")," ",e.jsx(z,{className:"ccy-mark"}),s.suggestedCredits.toLocaleString()]}):null]})]}),e.jsx(ot,{children:e.jsx(at,{size:"sm",disabled:!l(s.oldTradeId),onClick:()=>L(B([s])),children:i("importListings.list")})})]},s.oldTradeId)})})]},d.key)}),e.jsx(dt,{children:e.jsxs(ct,{children:[e.jsxs("div",{children:[e.jsxs(lt,{children:[e.jsx(z,{className:"ccy-mark",color:S.colors.text})," ",u.toLocaleString()]}),e.jsx(pt,{children:i("importListings.selectedSummary",{count:x.length,usd:K(u).toFixed(2)})})]}),e.jsx(gt,{}),e.jsx(xt,{variant:"purple",disabled:x.length===0,onClick:()=>L(B(x)),children:i("importListings.listAll",{count:x.length})})]})}),N&&o?e.jsx(Be,{queue:N,session:o,onClose:()=>L(null),onDone:Q}):null]}):e.jsxs(G,{children:[e.jsx(Y,{"aria-hidden":!0,children:"📦"}),e.jsx(J,{children:i("importListings.signInTitle")}),e.jsx("p",{className:"muted",children:i("importListings.signInBody")}),e.jsx(V,{variant:"purple",onClick:()=>w(),children:i("storeSettings.signIn")})]})}export{Tt as ImportListings};
447
+ `,mt=[{key:"creations",title:"importListings.creations.title",sub:"importListings.creations.sub"},{key:"owned",title:"importListings.owned.title",sub:"importListings.owned.sub",secondary:!0}];function Tt(){re({title:i("seo.import.title"),noindex:!0});const{session:o,signIn:w,restore:j}=oe(),m=ae(),v=o==null?void 0:o.address;h.useEffect(()=>{j()},[j]);const{data:p,isLoading:g}=de({queryKey:["importable",v],queryFn:()=>ge(v),enabled:!!v}),b=xe(),R=h.useMemo(()=>mt.filter(d=>!d.secondary||b),[b]),[A,k]=h.useState({}),[$,E]=h.useState(new Set),[N,L]=h.useState(null),n=h.useMemo(()=>[...(p==null?void 0:p.creations)??[],...b?(p==null?void 0:p.owned)??[]:[]],[p,b]);h.useEffect(()=>{n.length&&k(d=>{const c={...d};for(const s of n)c[s.oldTradeId]==null&&(c[s.oldTradeId]=s.suggestedCredits);return c})},[n]);const l=d=>!$.has(d),a=d=>A[d.oldTradeId]??d.suggestedCredits,x=n.filter(d=>l(d.oldTradeId)),u=x.reduce((d,c)=>d+a(c),0);function f(d,c){const s=c.replace(/[^\d]/g,"");k(T=>({...T,[d]:s===""?0:parseInt(s,10)}))}function C(d){E(c=>{const s=new Set(c);return s.has(d)?s.delete(d):s.add(d),s})}function B(d){return d.map(c=>({item:c,priceCredits:Math.max(1,a(c))}))}function F(){m.invalidateQueries({queryKey:["importable"]}),m.invalidateQueries({queryKey:["shop-items"]}),m.invalidateQueries({queryKey:["catalog-items"]}),m.invalidateQueries({queryKey:["overview-listings"]}),m.invalidateQueries({queryKey:["upsell-listings"]}),m.invalidateQueries({queryKey:["my-assets"]}),m.invalidateQueries({queryKey:["collection-sale-state"]}),ce.success(i("importListings.toastUpdated"))}return o?!g&&n.length===0?e.jsxs(G,{children:[e.jsx(Y,{"aria-hidden":!0,children:"✨"}),e.jsx(J,{children:i("importListings.emptyTitle")}),e.jsx("p",{className:"muted",children:i("importListings.emptyBody")}),e.jsx(V,{as:te,to:"/my-assets",variant:"purple",children:i("importListings.goToMyAssets")})]}):e.jsxs(Ae,{children:[e.jsxs(Fe,{children:[e.jsx(Pe,{children:i("importListings.eyebrow")}),e.jsxs(_e,{children:[i("importListings.titleLead")," ",e.jsx(Ke,{children:i("importListings.titleAccent")})]}),e.jsx(De,{children:i("importListings.lede",{currency:Q.name})})]}),e.jsxs(We,{children:[e.jsx(z,{className:"ccy-mark",color:S.colors.text})," ",i("importListings.rate",{currency:Q.nameSingular})]}),g?e.jsx(X,{children:Array.from({length:4}).map((d,c)=>e.jsx(Je,{},c))}):R.map(d=>{const c=(p==null?void 0:p[d.key])??[];return c.length===0?null:e.jsxs(Ue,{children:[e.jsxs(He,{children:[e.jsx(Oe,{children:i(d.title)}),e.jsx(Ge,{children:i(d.sub)})]}),e.jsx(X,{children:c.map(s=>{const T=a(s),q=T!==s.suggestedCredits;return e.jsxs(Ye,{"data-off":l(s.oldTradeId)?void 0:!0,children:[e.jsx(Ve,{type:"checkbox",checked:l(s.oldTradeId),onChange:()=>C(s.oldTradeId),"aria-label":i("importListings.includeItem",{name:s.name})}),e.jsx(Xe,{children:s.thumbnail?e.jsx("img",{src:s.thumbnail,alt:""}):null}),e.jsxs(Ze,{children:[e.jsx(qe,{title:s.name,children:s.name||i("importListings.itemFallback")}),e.jsx(et,{children:s.rarity})]}),e.jsxs(tt,{children:[e.jsxs(it,{children:[e.jsx(z,{size:15,color:S.colors.text}),e.jsx(st,{"data-testid":"imp-price-input",inputMode:"numeric",value:T.toLocaleString(),onChange:P=>f(s.oldTradeId,P.target.value),"aria-label":i("importListings.priceAria",{currency:Q.name,name:s.name})})]}),e.jsxs(nt,{children:[e.jsxs("span",{children:["$",K(T).toFixed(2)]}),q?e.jsxs(rt,{onClick:()=>k(P=>({...P,[s.oldTradeId]:s.suggestedCredits})),children:[i("importListings.resetTo")," ",e.jsx(z,{className:"ccy-mark"}),s.suggestedCredits.toLocaleString()]}):null]})]}),e.jsx(ot,{children:e.jsx(at,{size:"sm",disabled:!l(s.oldTradeId),onClick:()=>L(B([s])),children:i("importListings.list")})})]},s.oldTradeId)})})]},d.key)}),e.jsx(dt,{children:e.jsxs(ct,{children:[e.jsxs("div",{children:[e.jsxs(lt,{children:[e.jsx(z,{className:"ccy-mark",color:S.colors.text})," ",u.toLocaleString()]}),e.jsx(pt,{children:i("importListings.selectedSummary",{count:x.length,usd:K(u).toFixed(2)})})]}),e.jsx(gt,{}),e.jsx(xt,{variant:"purple",disabled:x.length===0,onClick:()=>L(B(x)),children:i("importListings.listAll",{count:x.length})})]})}),N&&o?e.jsx(Be,{queue:N,session:o,onClose:()=>L(null),onDone:F}):null]}):e.jsxs(G,{children:[e.jsx(Y,{"aria-hidden":!0,children:"📦"}),e.jsx(J,{children:i("importListings.signInTitle")}),e.jsx("p",{className:"muted",children:i("importListings.signInBody")}),e.jsx(V,{variant:"purple",onClick:()=>w(),children:i("storeSettings.signIn")})]})}export{Tt as ImportListings};
@@ -1,5 +1,5 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-DU8_EWWx.js","assets/react-vyZjIDcS.js","assets/dcl-schemas-BICTSpB5.js","assets/index-yJi2QIJf.js","assets/sentry-B35L1FdR.js","assets/ethers-CXBJm_wN.js","assets/intl-CBcMB1D2.js","assets/index-BMzstP-8.css","assets/createSvgIcon-DLpGC0um.js","assets/clsx-DhFqZi_3.js","assets/emotion-styled.browser.esm-Bl0xNQms.js","assets/CircularProgress-BRaMu2HF.js","assets/index-CJgXTNhS.js","assets/useTheme-DlRIY8zD.js","assets/getThemeProps-CGtqDWEq.js"])))=>i.map(i=>d[i]);
2
- var Hc=Object.defineProperty;var zc=(n,a,t)=>a in n?Hc(n,a,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[a]=t;var W=(n,a,t)=>zc(n,typeof a!="symbol"?a+"":a,t);import{r as v,d as qc,j as s,b as Wt,l as us,R as M,h as Qc,e as Kc,a as Vc,L as Uc}from"./react-vyZjIDcS.js";import{s as m,t as d,e as x,I as J,bd as Xc,z as _e,J as Ke,h as vt,D as ao,bc as Rr,n as Ot,al as ps,am as Gc,E as Bt,at as Jc,$ as fs,a0 as rr,au as oa,av as $e,ar as le,ay as Xe,ax as at,bx as Zc,aw as Lr,l as Ge,aj as el,c as At,a as ia,b as tl,C as hs,y as nl,u as we,L as rl,af as br,o as vr,ag as ma,aP as Gt,p as ms,F as _n,ai as gs,by as al,B as Pn,H as In,bz as xs,aQ as oo,aR as ol,f as ys,_ as Fr,x as il,ak as Dn,bA as sl,bB as cl,bC as ll,bD as dl,bE as ul,bF as pl,bG as bs,bH as fl,bI as hl,d as vs,bJ as ml,bK as gl,bL as xl,bM as yl,G as bl,bN as vl,Q as wl,bO as kl,bP as Dl,bQ as Cl,bR as Sl,bS as Ml,bT as _l,aH as Pl,m as Il,bU as jl,bV as El,bW as Tl,bX as io,ah as $l,bY as Nl,bZ as Ol,b_ as Al,b$ as Rl,c0 as Ll,c1 as Fl}from"./index-yJi2QIJf.js";import{d as Re,a as so}from"./dcl-schemas-BICTSpB5.js";import{$ as Yr,m as Yl,K as Wl,V as Bl,Q as ws,R as Hl,M as zl,S as ql,C as Ql,H as Kl,a as Vl,T as Ul,X as Xl,b as Gl,B as Jl,c as Zl,d as ed,e as td,f as Qt,j as Yn,k as Kt,W as nd,p as rd,q as ad,P as od,x as id,y as sd,z as cd,D as ld,E as dd,F as ud,G as pd,I as fd,J as hd,L as md,l as gd,n as xd,o as yd,a0 as bd,a1 as vd,A as wd,r as kd,s as Dd,t as Cd,u as Sd,v as Md,w as _d,a2 as Pd,a3 as Id,a4 as jd,N as Ed,O as Td,U as $d}from"./CollectionCarousel-oh8d08gi.js";import{a as ar,t as Nd,c as Od}from"./buy-DLi3_94e.js";import{f as Ad}from"./builder-BW_vsdgs.js";import{u as Rd,M as Ld,l as Fd,c as Yd}from"./useCreditPacks-DnQLmQo7.js";import{r as Wd}from"./mana-rate-DTd_zYK_.js";import{i as ks,f as Ds,n as Bd,j as Hd,c as co,g as Cs,e as zd,r as qd,m as Qd}from"./authorizations-BrAVsIY_.js";import{a as Ss,w as Ms,S as _s,G as Ps}from"./buy-gasless-DoEdxK3L.js";import{R as lo}from"./resume-buy-Bf0zIH7y.js";import{a as Kd,f as yt,i as en}from"./errors-D660SWgT.js";import{E as ut}from"./ErrorNotice-C2qBxBzo.js";import{C as Vd}from"./CircularProgress-BRaMu2HF.js";import{a as Ud,b as Xd,h as Gd,e as Jd,c as Zd,d as eu}from"./trade-encoding-BFXwI1r3.js";import{M as tu,E as nu,s as ru}from"./sendMetaTransaction-BOtIj1YL.js";import{C as au,I as ou}from"./ethers-CXBJm_wN.js";import{a as Wr}from"./mana-convert-DTic_WF4.js";import{u as Is}from"./useManaRate-DwO6H8fK.js";import{u as iu}from"./useSecondarySales-BLnZD7gi.js";import{T as js}from"./Tooltip-DFmfpHxa.js";import"./sentry-B35L1FdR.js";import"./intl-CBcMB1D2.js";import"./clsx-DhFqZi_3.js";const tn=Math.min,Et=Math.max,or=Math.round,Wn=Math.floor,it=n=>({x:n,y:n}),su={left:"right",right:"left",bottom:"top",top:"bottom"};function cu(n,a,t){return Et(n,tn(a,t))}function wr(n,a){return typeof n=="function"?n(a):n}function nn(n){return n.split("-")[0]}function jn(n){return n.split("-")[1]}function lu(n){return n==="x"?"y":"x"}function ga(n){return n==="y"?"height":"width"}function It(n){const a=n[0];return a==="t"||a==="b"?"y":"x"}function xa(n){return lu(It(n))}function du(n,a,t){t===void 0&&(t=!1);const e=jn(n),r=xa(n),o=ga(r);let i=r==="x"?e===(t?"end":"start")?"right":"left":e==="start"?"bottom":"top";return a.reference[o]>a.floating[o]&&(i=ir(i)),[i,ir(i)]}function uu(n){const a=ir(n);return[sa(n),a,sa(a)]}function sa(n){return n.includes("start")?n.replace("start","end"):n.replace("end","start")}const uo=["left","right"],po=["right","left"],pu=["top","bottom"],fu=["bottom","top"];function hu(n,a,t){switch(n){case"top":case"bottom":return t?a?po:uo:a?uo:po;case"left":case"right":return a?pu:fu;default:return[]}}function mu(n,a,t,e){const r=jn(n);let o=hu(nn(n),t==="start",e);return r&&(o=o.map(i=>i+"-"+r),a&&(o=o.concat(o.map(sa)))),o}function ir(n){const a=nn(n);return su[a]+n.slice(a.length)}function gu(n){var a,t,e,r;return{top:(a=n.top)!=null?a:0,right:(t=n.right)!=null?t:0,bottom:(e=n.bottom)!=null?e:0,left:(r=n.left)!=null?r:0}}function Es(n){return typeof n!="number"?gu(n):{top:n,right:n,bottom:n,left:n}}function sr(n){const{x:a,y:t,width:e,height:r}=n;return{width:e,height:r,top:t,left:a,right:a+e,bottom:t+r,x:a,y:t}}function fo(n,a,t){let{reference:e,floating:r}=n;const o=It(a),i=xa(a),c=ga(i),l=nn(a),p=o==="y",u=e.x+e.width/2-r.width/2,h=e.y+e.height/2-r.height/2,y=e[c]/2-r[c]/2;let g;switch(l){case"top":g={x:u,y:e.y-r.height};break;case"bottom":g={x:u,y:e.y+e.height};break;case"right":g={x:e.x+e.width,y:h};break;case"left":g={x:e.x-r.width,y:h};break;default:g={x:e.x,y:e.y}}const b=jn(a);return b&&(g[i]+=y*(b==="end"?1:-1)*(t&&p?-1:1)),g}async function xu(n,a){var t;a===void 0&&(a={});const{x:e,y:r,platform:o,rects:i,elements:c,strategy:l}=n,{boundary:p="clippingAncestors",rootBoundary:u="viewport",elementContext:h="floating",altBoundary:y=!1,padding:g=0}=wr(a,n),b=Es(g),f=c[y?h==="floating"?"reference":"floating":h],D=sr(await o.getClippingRect({element:(t=await(o.isElement==null?void 0:o.isElement(f)))==null||t?f:f.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(c.floating)),boundary:p,rootBoundary:u,strategy:l})),S=h==="floating"?{x:e,y:r,width:i.floating.width,height:i.floating.height}:i.reference,j=await(o.getOffsetParent==null?void 0:o.getOffsetParent(c.floating)),T=await(o.isElement==null?void 0:o.isElement(j))&&await(o.getScale==null?void 0:o.getScale(j))||{x:1,y:1},O=sr(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:S,offsetParent:j,strategy:l}):S);return{top:(D.top-O.top+b.top)/T.y,bottom:(O.bottom-D.bottom+b.bottom)/T.y,left:(D.left-O.left+b.left)/T.x,right:(O.right-D.right+b.right)/T.x}}const yu=50,bu=async(n,a,t)=>{const{placement:e="bottom",strategy:r="absolute",middleware:o=[],platform:i}=t,c=i.detectOverflow?i:{...i,detectOverflow:xu},l=await(i.isRTL==null?void 0:i.isRTL(a));let p=await i.getElementRects({reference:n,floating:a,strategy:r}),{x:u,y:h}=fo(p,e,l),y=e,g=0;const b={};for(let w=0;w<o.length;w++){const f=o[w];if(!f)continue;const{name:D,fn:S}=f,{x:j,y:T,data:O,reset:$}=await S({x:u,y:h,initialPlacement:e,placement:y,strategy:r,middlewareData:b,rects:p,platform:c,elements:{reference:n,floating:a}});u=j??u,h=T??h,b[D]={...b[D],...O},$&&g<yu&&(g++,typeof $=="object"&&($.placement&&(y=$.placement),$.rects&&(p=$.rects===!0?await i.getElementRects({reference:n,floating:a,strategy:r}):$.rects),{x:u,y:h}=fo(p,y,l)),w=-1)}return{x:u,y:h,placement:y,strategy:r,middlewareData:b}},vu=n=>({name:"arrow",options:n,async fn(a){const{x:t,y:e,placement:r,rects:o,platform:i,elements:c,middlewareData:l}=a,{element:p,padding:u=0}=wr(n,a)||{};if(p==null)return{};const h=Es(u),y={x:t,y:e},g=xa(r),b=ga(g),w=await i.getDimensions(p),f=g==="y",D=f?"top":"left",S=f?"bottom":"right",j=f?"clientHeight":"clientWidth",T=o.reference[b]+o.reference[g]-y[g]-o.floating[b],O=y[g]-o.reference[g],$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(p));let C=$?$[j]:0;(!C||!await(i.isElement==null?void 0:i.isElement($)))&&(C=c.floating[j]||o.floating[b]);const k=T/2-O/2,_=C/2-w[b]/2-1,E=tn(h[D],_),N=tn(h[S],_),A=C-w[b]-N,B=C/2-w[b]/2+k,U=cu(E,B,A),Q=!l.arrow&&jn(r)!=null&&B!==U&&o.reference[b]/2-(B<E?E:N)-w[b]/2<0,L=Q?B<E?B-E:B-A:0;return{[g]:y[g]+L,data:{[g]:U,centerOffset:B-U-L,...Q&&{alignmentOffset:L}},reset:Q}}}),wu=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(a){var t,e;const{placement:r,middlewareData:o,rects:i,initialPlacement:c,platform:l,elements:p}=a,{mainAxis:u=!0,crossAxis:h=!0,fallbackPlacements:y,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:w=!0,...f}=wr(n,a);if((t=o.arrow)!=null&&t.alignmentOffset)return{};const D=nn(r),S=It(c),j=nn(c)===c,T=await(l.isRTL==null?void 0:l.isRTL(p.floating)),O=y||(j||!w?[ir(c)]:uu(c)),$=b!=="none";!y&&$&&O.push(...mu(c,w,b,T));const C=[c,...O],k=await l.detectOverflow(a,f),_=[];let E=((e=o.flip)==null?void 0:e.overflows)||[];if(u&&_.push(k[D]),h){const U=du(r,i,T);_.push(k[U[0]],k[U[1]])}if(E=[...E,{placement:r,overflows:_}],!_.every(U=>U<=0)){var N,A;const U=(((N=o.flip)==null?void 0:N.index)||0)+1,Q=C[U];if(Q&&(!(h==="alignment"?S!==It(Q):!1)||E.every(P=>It(P.placement)===S?P.overflows[0]>0:!0)))return{data:{index:U,overflows:E},reset:{placement:Q}};let L=(A=E.filter(q=>q.overflows[0]<=0).sort((q,P)=>q.overflows[1]-P.overflows[1])[0])==null?void 0:A.placement;if(!L)switch(g){case"bestFit":{var B;const q=(B=E.filter(P=>{if($){const K=It(P.placement);return K===S||K==="y"}return!0}).map(P=>[P.placement,P.overflows.filter(K=>K>0).reduce((K,ie)=>K+ie,0)]).sort((P,K)=>P[1]-K[1])[0])==null?void 0:B[0];q&&(L=q);break}case"initialPlacement":L=c;break}if(r!==L)return{reset:{placement:L}}}return{}}}},ku=new Set(["left","top"]);async function Du(n,a){const{placement:t,platform:e,elements:r}=n,o=await(e.isRTL==null?void 0:e.isRTL(r.floating)),i=nn(t),c=jn(t),l=It(t)==="y",p=ku.has(i)?-1:1,u=o&&l?-1:1,h=wr(a,n);let{mainAxis:y,crossAxis:g,alignmentAxis:b}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return c&&typeof b=="number"&&(g=c==="end"?b*-1:b),l?{x:g*u,y:y*p}:{x:y*p,y:g*u}}const Cu=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(a){var t,e;const{x:r,y:o,placement:i,middlewareData:c}=a,l=await Du(a,n);return i===((t=c.offset)==null?void 0:t.placement)&&(e=c.arrow)!=null&&e.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:i}}}}};function kr(){return typeof window<"u"}function sn(n){return Ts(n)?(n.nodeName||"").toLowerCase():"#document"}function Pe(n){var a;return(n==null||(a=n.ownerDocument)==null?void 0:a.defaultView)||window}function ht(n){var a;return(a=(Ts(n)?n.ownerDocument:n.document)||window.document)==null?void 0:a.documentElement}function Ts(n){return kr()?n instanceof Node||n instanceof Pe(n).Node:!1}function Me(n){return kr()?n instanceof Element||n instanceof Pe(n).Element:!1}function Dt(n){return kr()?n instanceof HTMLElement||n instanceof Pe(n).HTMLElement:!1}function ho(n){return!kr()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Pe(n).ShadowRoot}function Dr(n){const{overflow:a,overflowX:t,overflowY:e,display:r}=Fe(n);return/auto|scroll|overlay|hidden|clip/.test(a+e+t)&&r!=="inline"&&r!=="contents"}function Su(n){return/^(table|td|th)$/.test(sn(n))}function Cr(n){try{if(n.matches(":popover-open"))return!0}catch{}try{return n.matches(":modal")}catch{return!1}}const Mu=/transform|translate|scale|rotate|perspective|filter/,_u=/paint|layout|strict|content/,_t=n=>!!n&&n!=="none";let Br;function ya(n){const a=Me(n)?Fe(n):n;return _t(a.transform)||_t(a.translate)||_t(a.scale)||_t(a.rotate)||_t(a.perspective)||!ba()&&(_t(a.backdropFilter)||_t(a.filter))||Mu.test(a.willChange||"")||_u.test(a.contain||"")}function Pu(n){let a=Rt(n);for(;Dt(a)&&!Cn(a);){if(ya(a))return a;if(Cr(a))return null;a=Rt(a)}return null}function ba(){return Br==null&&(Br=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Br}function Cn(n){return/^(html|body|#document)$/.test(sn(n))}function Fe(n){return Pe(n).getComputedStyle(n)}function Sr(n){return Me(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function Rt(n){if(sn(n)==="html")return n;const a=n.assignedSlot||n.parentNode||ho(n)&&n.host||ht(n);return ho(a)?a.host:a}function $s(n){const a=Rt(n);return Cn(a)?(n.ownerDocument||n).body:Dt(a)&&Dr(a)?a:$s(a)}function Sn(n,a,t){var e;a===void 0&&(a=[]),t===void 0&&(t=!0);const r=$s(n),o=r===((e=n.ownerDocument)==null?void 0:e.body),i=Pe(r);if(o){const c=ca(i);return a.concat(i,i.visualViewport||[],Dr(r)?r:[],c&&t?Sn(c):[])}else return a.concat(r,Sn(r,[],t))}function ca(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Ns(n){const a=Fe(n);let t=parseFloat(a.width)||0,e=parseFloat(a.height)||0;const r=Dt(n),o=r?n.offsetWidth:t,i=r?n.offsetHeight:e,c=or(t)!==o||or(e)!==i;return c&&(t=o,e=i),{width:t,height:e,$:c}}function va(n){return Me(n)?n:n.contextElement}function Jt(n){const a=va(n);if(!Dt(a))return it(1);const t=a.getBoundingClientRect(),{width:e,height:r,$:o}=Ns(a);let i=(o?or(t.width):t.width)/e,c=(o?or(t.height):t.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const Iu=it(0);function Os(n){const a=Pe(n);return!ba()||!a.visualViewport?Iu:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function ju(n,a,t){return a===void 0&&(a=!1),!!t&&a&&t===Pe(n)}function Lt(n,a,t,e){a===void 0&&(a=!1),t===void 0&&(t=!1);const r=n.getBoundingClientRect(),o=va(n);let i=it(1);a&&(e?Me(e)&&(i=Jt(e)):i=Jt(n));const c=ju(o,t,e)?Os(o):it(0);let l=(r.left+c.x)/i.x,p=(r.top+c.y)/i.y,u=r.width/i.x,h=r.height/i.y;if(o&&e){const y=Pe(o),g=Me(e)?Pe(e):e;let b=y,w=ca(b);for(;w&&g!==b;){const f=Jt(w),D=w.getBoundingClientRect(),S=Fe(w),j=D.left+(w.clientLeft+parseFloat(S.paddingLeft))*f.x,T=D.top+(w.clientTop+parseFloat(S.paddingTop))*f.y;l*=f.x,p*=f.y,u*=f.x,h*=f.y,l+=j,p+=T,b=Pe(w),w=ca(b)}}return sr({width:u,height:h,x:l,y:p})}function Mr(n,a){const t=Sr(n).scrollLeft;return a?a.left+t:Lt(ht(n)).left+t}function As(n,a){const t=n.getBoundingClientRect(),e=t.left+a.scrollLeft-Mr(n,t),r=t.top+a.scrollTop;return{x:e,y:r}}function Eu(n){let{elements:a,rect:t,offsetParent:e,strategy:r}=n;const o=r==="fixed",i=ht(e),c=a?Cr(a.floating):!1;if(e===i||c&&o)return t;let l={scrollLeft:0,scrollTop:0},p=it(1);const u=it(0),h=Dt(e);if((h||!o)&&((sn(e)!=="body"||Dr(i))&&(l=Sr(e)),h)){const g=Lt(e);p=Jt(e),u.x=g.x+e.clientLeft,u.y=g.y+e.clientTop}const y=i&&!h&&!o?As(i,l):it(0);return{width:t.width*p.x,height:t.height*p.y,x:t.x*p.x-l.scrollLeft*p.x+u.x+y.x,y:t.y*p.y-l.scrollTop*p.y+u.y+y.y}}function Tu(n){return n.getClientRects?Array.from(n.getClientRects()):[]}function $u(n){const a=Sr(n),t=n.ownerDocument.body,e=Et(n.scrollWidth,n.clientWidth,t.scrollWidth,t.clientWidth),r=Et(n.scrollHeight,n.clientHeight,t.scrollHeight,t.clientHeight);let o=-a.scrollLeft+Mr(n);const i=-a.scrollTop;return Fe(t).direction==="rtl"&&(o+=Et(n.clientWidth,t.clientWidth)-e),{width:e,height:r,x:o,y:i}}const Nu=25;function Ou(n,a,t){t===void 0&&(t="viewport");const e=t==="layoutViewport",r=Pe(n),o=ht(n),i=r.visualViewport;let c=o.clientWidth,l=o.clientHeight,p=0,u=0;if(i){const y=!ba()||a==="fixed";e?y||(p=-i.offsetLeft,u=-i.offsetTop):(c=i.width,l=i.height,y&&(p=i.offsetLeft,u=i.offsetTop))}if(Mr(o)<=0){const y=o.ownerDocument,g=y.body,b=getComputedStyle(g),w=y.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,f=Math.abs(o.clientWidth-g.clientWidth-w),D=getComputedStyle(o).scrollbarGutter==="stable both-edges"?f/2:f;D<=Nu&&(c-=D)}return{width:c,height:l,x:p,y:u}}function Au(n,a){const t=Lt(n,!0,a==="fixed"),e=t.top+n.clientTop,r=t.left+n.clientLeft,o=Jt(n),i=n.clientWidth*o.x,c=n.clientHeight*o.y,l=r*o.x,p=e*o.y;return{width:i,height:c,x:l,y:p}}function mo(n,a,t){let e;if(a==="viewport"||a==="layoutViewport")e=Ou(n,t,a);else if(a==="document")e=$u(ht(n));else if(Me(a))e=Au(a,t);else{const r=Os(n);e={x:a.x-r.x,y:a.y-r.y,width:a.width,height:a.height}}return sr(e)}function Ru(n,a){const t=a.get(n);if(t)return t;let e=Sn(n,[],!1).filter(c=>Me(c)&&sn(c)!=="body"),r=null;const o=Fe(n).position==="fixed";let i=o?Rt(n):n;for(;Me(i)&&!Cn(i);){const c=Fe(i),l=ya(i),p=r?r.position:o?"fixed":"";!l&&(p==="fixed"||p==="absolute"&&c.position==="static")?e=e.filter(h=>h!==i):r=c,i=Rt(i)}return a.set(n,e),e}function Lu(n){let{element:a,boundary:t,rootBoundary:e,strategy:r}=n;const i=[...t==="clippingAncestors"?Cr(a)?[]:Ru(a,this._c):[].concat(t),e],c=mo(a,i[0],r);let l=c.top,p=c.right,u=c.bottom,h=c.left;for(let y=1;y<i.length;y++){const g=mo(a,i[y],r);l=Et(g.top,l),p=tn(g.right,p),u=tn(g.bottom,u),h=Et(g.left,h)}return{width:p-h,height:u-l,x:h,y:l}}function Fu(n){const{width:a,height:t}=Ns(n);return{width:a,height:t}}function Yu(n,a,t){const e=Dt(a),r=ht(a),o=t==="fixed",i=Lt(n,!0,o,a);let c={scrollLeft:0,scrollTop:0};const l=it(0);if((e||!o)&&((sn(a)!=="body"||Dr(r))&&(c=Sr(a)),e)){const y=Lt(a,!0,o,a);l.x=y.x+a.clientLeft,l.y=y.y+a.clientTop}!e&&r&&(l.x=Mr(r));const p=r&&!e&&!o?As(r,c):it(0),u=i.left+c.scrollLeft-l.x-p.x,h=i.top+c.scrollTop-l.y-p.y;return{x:u,y:h,width:i.width,height:i.height}}function Hr(n){return Fe(n).position==="static"}function go(n,a){if(!Dt(n)||Fe(n).position==="fixed")return null;if(a)return a(n);let t=n.offsetParent;return ht(n)===t&&(t=t.ownerDocument.body),t}function Rs(n,a){const t=Pe(n);if(Cr(n))return t;if(!Dt(n)){let r=Rt(n);for(;r&&!Cn(r);){if(Me(r)&&!Hr(r))return r;r=Rt(r)}return t}let e=go(n,a);for(;e&&Su(e)&&Hr(e);)e=go(e,a);return e&&Cn(e)&&Hr(e)&&!ya(e)?t:e||Pu(n)||t}const Wu=async function(n){const a=this.getOffsetParent||Rs,t=this.getDimensions,e=await t(n.floating);return{reference:Yu(n.reference,await a(n.floating),n.strategy),floating:{x:0,y:0,width:e.width,height:e.height}}};function Bu(n){return Fe(n).direction==="rtl"}const Hu={convertOffsetParentRelativeRectToViewportRelativeRect:Eu,getDocumentElement:ht,getClippingRect:Lu,getOffsetParent:Rs,getElementRects:Wu,getClientRects:Tu,getDimensions:Fu,getScale:Jt,isElement:Me,isRTL:Bu};function Ls(n,a){return n.x===a.x&&n.y===a.y&&n.width===a.width&&n.height===a.height}function zu(n,a,t){let e=null,r;const o=ht(n);function i(){var u;clearTimeout(r),(u=e)==null||u.disconnect(),e=null}function c(u,h){u===void 0&&(u=!1),h===void 0&&(h=1),i();const y=n.getBoundingClientRect(),{left:g,top:b,width:w,height:f}=y;if(u||a(),!w||!f)return;const D=Wn(b),S=Wn(o.clientWidth-(g+w)),j=Wn(o.clientHeight-(b+f)),T=Wn(g),$={rootMargin:-D+"px "+-S+"px "+-j+"px "+-T+"px",threshold:Et(0,tn(1,h))||1};let C=!0;function k(_){const E=_[0].intersectionRatio;if(!Ls(y,n.getBoundingClientRect()))return c();if(E!==h){if(!C)return c();E?c(!1,E):r=setTimeout(()=>{c(!1,1e-7)},1e3)}C=!1}try{e=new IntersectionObserver(k,{...$,root:o.ownerDocument})}catch{e=new IntersectionObserver(k,$)}e.observe(n)}const l=Pe(n),p=()=>c(t);return l.addEventListener("resize",p),c(!0),()=>{l.removeEventListener("resize",p),i()}}function qu(n,a,t,e){e===void 0&&(e={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:l=!1}=e,p=va(n),u=r||o?[...p?Sn(p):[],...a?Sn(a):[]]:[];u.forEach(D=>{r&&D.addEventListener("scroll",t),o&&D.addEventListener("resize",t)});const h=p&&c?zu(p,t,o):null;let y=-1,g=null;i&&(g=new ResizeObserver(D=>{let[S]=D;S&&S.target===p&&g&&a&&(g.unobserve(a),cancelAnimationFrame(y),y=requestAnimationFrame(()=>{var j;(j=g)==null||j.observe(a)})),t()}),p&&!l&&g.observe(p),a&&g.observe(a));let b,w=l?Lt(n):null;l&&f();function f(){const D=Lt(n);w&&!Ls(w,D)&&t(),w=D,b=requestAnimationFrame(f)}return t(),()=>{var D;u.forEach(S=>{r&&S.removeEventListener("scroll",t),o&&S.removeEventListener("resize",t)}),h==null||h(),(D=g)==null||D.disconnect(),g=null,l&&cancelAnimationFrame(b)}}const Qu=Cu,Ku=wu,xo=vu,Vu=(n,a,t)=>{const e=new Map,r=t??{},o={...Hu,...r.platform,_c:e};return bu(n,a,{...r,platform:o})};var Uu=typeof document<"u",Xu=function(){},Gn=Uu?v.useLayoutEffect:Xu;function cr(n,a){if(n===a)return!0;if(typeof n!=typeof a)return!1;if(typeof n=="function"&&n.toString()===a.toString())return!0;let t,e,r;if(n&&a&&typeof n=="object"){if(Array.isArray(n)){if(t=n.length,t!==a.length)return!1;for(e=t;e--!==0;)if(!cr(n[e],a[e]))return!1;return!0}if(r=Object.keys(n),t=r.length,t!==Object.keys(a).length)return!1;for(e=t;e--!==0;)if(!{}.hasOwnProperty.call(a,r[e]))return!1;for(e=t;e--!==0;){const o=r[e];if(!(o==="_owner"&&n.$$typeof)&&!cr(n[o],a[o]))return!1}return!0}return n!==n&&a!==a}function Fs(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function yo(n,a){const t=Fs(n);return Math.round(a*t)/t}function zr(n){const a=v.useRef(n);return Gn(()=>{a.current=n}),a}function Gu(n){n===void 0&&(n={});const{placement:a="bottom",strategy:t="absolute",middleware:e=[],platform:r,elements:{reference:o,floating:i}={},transform:c=!0,whileElementsMounted:l,open:p}=n,[u,h]=v.useState({x:0,y:0,strategy:t,placement:a,middlewareData:{},isPositioned:!1}),[y,g]=v.useState(e);cr(y,e)||g(e);const[b,w]=v.useState(null),[f,D]=v.useState(null),S=v.useCallback(P=>{P!==$.current&&($.current=P,w(P))},[]),j=v.useCallback(P=>{P!==C.current&&(C.current=P,D(P))},[]),T=o||b,O=i||f,$=v.useRef(null),C=v.useRef(null),k=v.useRef(u),_=l!=null,E=zr(l),N=zr(r),A=zr(p),B=v.useCallback(()=>{if(!$.current||!C.current)return;const P={placement:a,strategy:t,middleware:y};N.current&&(P.platform=N.current),Vu($.current,C.current,P).then(K=>{const ie={...K,isPositioned:A.current!==!1};U.current&&!cr(k.current,ie)&&(k.current=ie,qc.flushSync(()=>{h(ie)}))})},[y,a,t,N,A]);Gn(()=>{p===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,h(P=>({...P,isPositioned:!1})))},[p]);const U=v.useRef(!1);Gn(()=>(U.current=!0,()=>{U.current=!1}),[]),Gn(()=>{if(T&&($.current=T),O&&(C.current=O),T&&O){if(E.current)return E.current(T,O,B);B()}},[T,O,B,E,_]);const Q=v.useMemo(()=>({reference:$,floating:C,setReference:S,setFloating:j}),[S,j]),L=v.useMemo(()=>({reference:T,floating:O}),[T,O]),q=v.useMemo(()=>{const P={position:t,left:0,top:0};if(!L.floating)return P;const K=yo(L.floating,u.x),ie=yo(L.floating,u.y);return c?{...P,transform:"translate("+K+"px, "+ie+"px)",...Fs(L.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:K,top:ie}},[t,c,L.floating,u.x,u.y]);return v.useMemo(()=>({...u,update:B,refs:Q,elements:L,floatingStyles:q}),[u,B,Q,L,q])}const Ju=n=>{function a(t){return{}.hasOwnProperty.call(t,"current")}return{name:"arrow",options:n,fn(t){const{element:e,padding:r}=typeof n=="function"?n(t):n;return e&&a(e)?e.current!=null?xo({element:e.current,padding:r}).fn(t):{}:e?xo({element:e,padding:r}).fn(t):{}}}},Zu=(n,a)=>{const t=Qu(n);return{name:t.name,fn:t.fn,options:[n,a]}},ep=(n,a)=>{const t=Ku(n);return{name:t.name,fn:t.fn,options:[n,a]}},tp=(n,a)=>{const t=Ju(n);return{name:t.name,fn:t.fn,options:[n,a]}},Ys=216n,np=(1n<<Ys)-1n;function rp(n){const a=typeof n=="bigint"?n:BigInt(n.trim());if(a<0n)throw new Error(`Invalid tokenId: ${String(n)}`);return{itemId:(a>>Ys).toString(),issuedId:(a&np).toString()}}function ap(n){if(!n)return null;try{return rp(n).itemId}catch{return null}}function bo(n,a){return a.kind==="listed"?{...n,isOnSale:!0,listingPrice:a.priceCredits,tradeId:a.tradeId??n.tradeId}:{...n,isOnSale:!1,listingPrice:void 0,tradeId:void 0}}function qr(n,a,t){const{address:e,contractAddress:r,tokenId:o}=a;if(!r||!o)return;const i=`${r}-${o}`;n.cancelQueries({queryKey:["owned-token",r,o]}),n.cancelQueries({queryKey:["secondary-sale-state"]}),e&&n.cancelQueries({queryKey:["my-assets",e]});const c=t.kind==="gone";n.setQueriesData({queryKey:["owned-token",r,o]},p=>p&&(c?null:bo(p,t)));const l=e?["my-assets",e]:["my-assets"];n.setQueriesData({queryKey:l},p=>p!=null&&p.pages?{...p,pages:p.pages.map(u=>{if(c){const h=u.items.filter(y=>!(y.contractAddress===r&&y.tokenId===o));return{...u,items:h,total:Math.max(0,u.total-(u.items.length-h.length))}}return{...u,items:u.items.map(h=>h.contractAddress===r&&h.tokenId===o?bo(h,t):h)}})}:p),n.setQueriesData({queryKey:["secondary-sale-state"]},p=>{var h;if(!p)return p;const u={...p};return t.kind==="removed"||t.kind==="gone"?delete u[i]:u[i]={priceCredits:t.priceCredits,tradeId:t.tradeId??((h=u[i])==null?void 0:h.tradeId)??""},u})}function op(n){return!(n.isMarket||n.forSale&&n.priceKnown||n.manage||n.soldOutWithResale||!n.stillResolving&&!n.resolvingTrade&&(n.isTokenRoute?!n.ownedAssetLoading:!n.deepLinkLoading))}const ip="data:image/webp;base64,UklGRqgOAABXRUJQVlA4IJwOAACwOwCdASqEAIsAPj0YikMiIaEWuib4IAPEtQBl0QC/bukK7J6X8cPZP5F69/Nvhj8oPlD3odY/QB8RXPv/C+3n59+izzA/0l/3/9064PmD/bH9Zvey/33r8/2PqC/zH/fdaX6EX7O+nP+3Xwlfub+33tOf/+7N8wTMuJT/znss7V9qD/DcDplr/deudN0/Rcajjp49/Q//7vLR70+4X+tP/R9az//+3r9z/Yk/ZVVfCa+jj+kU2kxc+zPDZIZQYWF19BTevkFTZdPnQBT3YukdDX/AtCNcmvBrFJ96eYkUWaCCtnOpfB+/IETSsPYuwsabIrqSWHYoPBskXi/DUubCFDAf/6+0pCLU1kmMIueWH8HebltZsATbIO+vXwG1gHAXjGECElz7j/+GXHZJM9ORAFgOa/b/pGdMUEE9PfuMHx1G3GpnRw8WEP5FknNoUNOyb6iY5VX/W5w6pnS5r1srs4CXTuHzUJLdvXVpyiQNuBwCyLYlukPjvLuqqHRrv5/jHTa1L+iumi2wLA8NzahM3euE6fvC7shIbIWajyLkVYhWOOdMRjOWdhSN1wi7JvE4t+bFXSVHOX+4DnQxVhhUKacLKMYPHhQKLZSdyYzM66dZ22undenNBcAjNHjBW+9t0W2glcAA/v44VaU8mJJP1Vz1l456kKu23B2wH7M9h1OtAwoGAGj8t///XA7H+OEVSxGjYfFAlM1Upvv/NmvKOBdxK8JXyQ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+QPuy2Kw8J6cXH2BA7K2LAF85VIVNVoRlDLXxjwsBb4heeCxAzkU+gm7I1b5uvL3i2xq/xj+lhL8t6XTKJliRrlPGHQuVR3ZceU87KLxOQcICfVOCe7B88mxyvsB2FmiotOM3UOnG+VcZ3jL1W+JFDzYyR9Y3KsZNaeJAazd5ajmnZLTYIY7gJ4N4t99U2hY/CMgI0yMNLaq3cJB0CNBsd1hRKl7lZ1wMh16/EZx5jig5JWvlZNPTMuJFHvpW42fyFjIfKslwVHB/SJKWDRr3w9uFCRm/Z3ABn2ydMFGvXjMZEaTsZlqF17J76wjrLkgmgcbtrtL9N8T3dXsKhM4LPscSPo2kc9MfW3dmjuo98vCdxBR/RvMAgm0VzEuXulny1QdmDMzoBUfPseIFkTNYFg89+m4OKn/8Xc28jcPteGx8v0vwYyKNlOAZvi/yt7OImF7kADj+rzqjSoqwVTnCCjOKrF1Gt1i+6oeDggdd5wEh1ghvxdHELxvJeJE8x82cfHEVXhE9Nheu7Q1WycLXUTZA8oZHsdBaBFpk6vyYdYFT8YTShaCjPle1+2DJHzXzhRUQ6ZY/HcDs/vS2V8+jO+pjV23u5WL6yRWULzVi+0qUXIiJzd9qj65YnWPMxIubcSpm+5n8vMpysoMuGzoNwBmNszF+S+b8acZRgm2Gi0UT5OGuYwq4wZ5kmd8OqnDzhze2RxwMRtRm+17eKYWzLWtgVuOca/HWuBI58UC9FNZtBLv1l2htg7Iyehb/cr9uKvXkPXh0LFeyfEc49dOsGvppssGqOAAAAA=",cp=m.div`
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-H02HAhZo.js","assets/react-vyZjIDcS.js","assets/dcl-schemas-BICTSpB5.js","assets/index-BMIuNfCB.js","assets/sentry-B35L1FdR.js","assets/ethers-CXBJm_wN.js","assets/intl-CBcMB1D2.js","assets/index-BMzstP-8.css","assets/createSvgIcon-D6bh0MrS.js","assets/clsx-C78Se7VZ.js","assets/emotion-styled.browser.esm-uimCutsp.js","assets/CircularProgress-CMZVAt1l.js","assets/index-ASq7s2Iv.js","assets/useTheme-DVSXpYGO.js","assets/getThemeProps-BCb3jyqf.js"])))=>i.map(i=>d[i]);
2
+ var Hc=Object.defineProperty;var zc=(n,a,t)=>a in n?Hc(n,a,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[a]=t;var W=(n,a,t)=>zc(n,typeof a!="symbol"?a+"":a,t);import{r as v,d as qc,j as s,b as Wt,l as us,R as M,h as Qc,e as Kc,a as Vc,L as Uc}from"./react-vyZjIDcS.js";import{s as m,t as d,e as x,I as J,be as Xc,z as _e,J as Ke,h as vt,D as ao,bd as Rr,n as Ot,al as ps,am as Gc,E as Bt,at as Jc,$ as fs,a0 as rr,av as oa,aw as $e,ar as le,az as Xe,ay as at,by as Zc,ax as Lr,l as Ge,aj as el,c as At,a as ia,b as tl,C as hs,y as nl,u as we,L as rl,af as br,o as vr,ag as ma,aQ as Gt,p as ms,F as _n,ai as gs,bz as al,B as Pn,H as In,bA as xs,aR as oo,aS as ol,f as ys,_ as Fr,x as il,ak as Dn,bB as sl,bC as cl,bD as ll,bE as dl,bF as ul,bG as pl,bH as bs,bI as fl,bJ as hl,d as vs,bK as ml,bL as gl,bM as xl,bN as yl,G as bl,bO as vl,Q as wl,bP as kl,bQ as Dl,bR as Cl,bS as Sl,bT as Ml,bU as _l,aI as Pl,m as Il,bV as jl,bW as El,bX as Tl,bY as io,ah as $l,bZ as Nl,b_ as Ol,b$ as Al,c0 as Rl,c1 as Ll,c2 as Fl}from"./index-BMIuNfCB.js";import{d as Re,a as so}from"./dcl-schemas-BICTSpB5.js";import{$ as Yr,m as Yl,K as Wl,V as Bl,Q as ws,R as Hl,M as zl,S as ql,C as Ql,H as Kl,a as Vl,T as Ul,X as Xl,b as Gl,B as Jl,c as Zl,d as ed,e as td,f as Qt,j as Yn,k as Kt,W as nd,p as rd,q as ad,P as od,x as id,y as sd,z as cd,D as ld,E as dd,F as ud,G as pd,I as fd,J as hd,L as md,l as gd,n as xd,o as yd,a0 as bd,a1 as vd,A as wd,r as kd,s as Dd,t as Cd,u as Sd,v as Md,w as _d,a2 as Pd,a3 as Id,a4 as jd,N as Ed,O as Td,U as $d}from"./CollectionCarousel-CrTrsXB-.js";import{a as ar,t as Nd,c as Od}from"./buy-DI2htlf2.js";import{f as Ad}from"./builder-BH8bW8w3.js";import{u as Rd,M as Ld,l as Fd,c as Yd}from"./useCreditPacks-Dw0jIjQE.js";import{r as Wd}from"./mana-rate-BAPBwbaG.js";import{i as ks,f as Ds,n as Bd,j as Hd,c as co,g as Cs,e as zd,r as qd,m as Qd}from"./authorizations-uQp0Tner.js";import{a as Ss,w as Ms,S as _s,G as Ps}from"./buy-gasless-D3ucK012.js";import{R as lo}from"./resume-buy-Bf0zIH7y.js";import{a as Kd,f as yt,i as en}from"./errors-BHapDldI.js";import{E as ut}from"./ErrorNotice-DwhdhAu6.js";import{C as Vd}from"./CircularProgress-CMZVAt1l.js";import{a as Ud,b as Xd,j as Gd,e as Jd,c as Zd,d as eu}from"./trade-encoding-CK5EArKF.js";import{M as tu,E as nu,s as ru}from"./sendMetaTransaction-DAsHliEn.js";import{C as au,I as ou}from"./ethers-CXBJm_wN.js";import{a as Wr}from"./mana-convert-C341n1xm.js";import{u as Is}from"./useManaRate-BEVwu7Q9.js";import{u as iu}from"./useSecondarySales-bajhgse5.js";import{T as js}from"./Tooltip-v8d4_GhH.js";import"./sentry-B35L1FdR.js";import"./intl-CBcMB1D2.js";import"./clsx-C78Se7VZ.js";const tn=Math.min,Et=Math.max,or=Math.round,Wn=Math.floor,it=n=>({x:n,y:n}),su={left:"right",right:"left",bottom:"top",top:"bottom"};function cu(n,a,t){return Et(n,tn(a,t))}function wr(n,a){return typeof n=="function"?n(a):n}function nn(n){return n.split("-")[0]}function jn(n){return n.split("-")[1]}function lu(n){return n==="x"?"y":"x"}function ga(n){return n==="y"?"height":"width"}function It(n){const a=n[0];return a==="t"||a==="b"?"y":"x"}function xa(n){return lu(It(n))}function du(n,a,t){t===void 0&&(t=!1);const e=jn(n),r=xa(n),o=ga(r);let i=r==="x"?e===(t?"end":"start")?"right":"left":e==="start"?"bottom":"top";return a.reference[o]>a.floating[o]&&(i=ir(i)),[i,ir(i)]}function uu(n){const a=ir(n);return[sa(n),a,sa(a)]}function sa(n){return n.includes("start")?n.replace("start","end"):n.replace("end","start")}const uo=["left","right"],po=["right","left"],pu=["top","bottom"],fu=["bottom","top"];function hu(n,a,t){switch(n){case"top":case"bottom":return t?a?po:uo:a?uo:po;case"left":case"right":return a?pu:fu;default:return[]}}function mu(n,a,t,e){const r=jn(n);let o=hu(nn(n),t==="start",e);return r&&(o=o.map(i=>i+"-"+r),a&&(o=o.concat(o.map(sa)))),o}function ir(n){const a=nn(n);return su[a]+n.slice(a.length)}function gu(n){var a,t,e,r;return{top:(a=n.top)!=null?a:0,right:(t=n.right)!=null?t:0,bottom:(e=n.bottom)!=null?e:0,left:(r=n.left)!=null?r:0}}function Es(n){return typeof n!="number"?gu(n):{top:n,right:n,bottom:n,left:n}}function sr(n){const{x:a,y:t,width:e,height:r}=n;return{width:e,height:r,top:t,left:a,right:a+e,bottom:t+r,x:a,y:t}}function fo(n,a,t){let{reference:e,floating:r}=n;const o=It(a),i=xa(a),c=ga(i),l=nn(a),p=o==="y",u=e.x+e.width/2-r.width/2,h=e.y+e.height/2-r.height/2,y=e[c]/2-r[c]/2;let g;switch(l){case"top":g={x:u,y:e.y-r.height};break;case"bottom":g={x:u,y:e.y+e.height};break;case"right":g={x:e.x+e.width,y:h};break;case"left":g={x:e.x-r.width,y:h};break;default:g={x:e.x,y:e.y}}const b=jn(a);return b&&(g[i]+=y*(b==="end"?1:-1)*(t&&p?-1:1)),g}async function xu(n,a){var t;a===void 0&&(a={});const{x:e,y:r,platform:o,rects:i,elements:c,strategy:l}=n,{boundary:p="clippingAncestors",rootBoundary:u="viewport",elementContext:h="floating",altBoundary:y=!1,padding:g=0}=wr(a,n),b=Es(g),f=c[y?h==="floating"?"reference":"floating":h],D=sr(await o.getClippingRect({element:(t=await(o.isElement==null?void 0:o.isElement(f)))==null||t?f:f.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(c.floating)),boundary:p,rootBoundary:u,strategy:l})),S=h==="floating"?{x:e,y:r,width:i.floating.width,height:i.floating.height}:i.reference,j=await(o.getOffsetParent==null?void 0:o.getOffsetParent(c.floating)),T=await(o.isElement==null?void 0:o.isElement(j))&&await(o.getScale==null?void 0:o.getScale(j))||{x:1,y:1},O=sr(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:S,offsetParent:j,strategy:l}):S);return{top:(D.top-O.top+b.top)/T.y,bottom:(O.bottom-D.bottom+b.bottom)/T.y,left:(D.left-O.left+b.left)/T.x,right:(O.right-D.right+b.right)/T.x}}const yu=50,bu=async(n,a,t)=>{const{placement:e="bottom",strategy:r="absolute",middleware:o=[],platform:i}=t,c=i.detectOverflow?i:{...i,detectOverflow:xu},l=await(i.isRTL==null?void 0:i.isRTL(a));let p=await i.getElementRects({reference:n,floating:a,strategy:r}),{x:u,y:h}=fo(p,e,l),y=e,g=0;const b={};for(let w=0;w<o.length;w++){const f=o[w];if(!f)continue;const{name:D,fn:S}=f,{x:j,y:T,data:O,reset:$}=await S({x:u,y:h,initialPlacement:e,placement:y,strategy:r,middlewareData:b,rects:p,platform:c,elements:{reference:n,floating:a}});u=j??u,h=T??h,b[D]={...b[D],...O},$&&g<yu&&(g++,typeof $=="object"&&($.placement&&(y=$.placement),$.rects&&(p=$.rects===!0?await i.getElementRects({reference:n,floating:a,strategy:r}):$.rects),{x:u,y:h}=fo(p,y,l)),w=-1)}return{x:u,y:h,placement:y,strategy:r,middlewareData:b}},vu=n=>({name:"arrow",options:n,async fn(a){const{x:t,y:e,placement:r,rects:o,platform:i,elements:c,middlewareData:l}=a,{element:p,padding:u=0}=wr(n,a)||{};if(p==null)return{};const h=Es(u),y={x:t,y:e},g=xa(r),b=ga(g),w=await i.getDimensions(p),f=g==="y",D=f?"top":"left",S=f?"bottom":"right",j=f?"clientHeight":"clientWidth",T=o.reference[b]+o.reference[g]-y[g]-o.floating[b],O=y[g]-o.reference[g],$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(p));let C=$?$[j]:0;(!C||!await(i.isElement==null?void 0:i.isElement($)))&&(C=c.floating[j]||o.floating[b]);const k=T/2-O/2,_=C/2-w[b]/2-1,E=tn(h[D],_),N=tn(h[S],_),A=C-w[b]-N,B=C/2-w[b]/2+k,U=cu(E,B,A),Q=!l.arrow&&jn(r)!=null&&B!==U&&o.reference[b]/2-(B<E?E:N)-w[b]/2<0,L=Q?B<E?B-E:B-A:0;return{[g]:y[g]+L,data:{[g]:U,centerOffset:B-U-L,...Q&&{alignmentOffset:L}},reset:Q}}}),wu=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(a){var t,e;const{placement:r,middlewareData:o,rects:i,initialPlacement:c,platform:l,elements:p}=a,{mainAxis:u=!0,crossAxis:h=!0,fallbackPlacements:y,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:w=!0,...f}=wr(n,a);if((t=o.arrow)!=null&&t.alignmentOffset)return{};const D=nn(r),S=It(c),j=nn(c)===c,T=await(l.isRTL==null?void 0:l.isRTL(p.floating)),O=y||(j||!w?[ir(c)]:uu(c)),$=b!=="none";!y&&$&&O.push(...mu(c,w,b,T));const C=[c,...O],k=await l.detectOverflow(a,f),_=[];let E=((e=o.flip)==null?void 0:e.overflows)||[];if(u&&_.push(k[D]),h){const U=du(r,i,T);_.push(k[U[0]],k[U[1]])}if(E=[...E,{placement:r,overflows:_}],!_.every(U=>U<=0)){var N,A;const U=(((N=o.flip)==null?void 0:N.index)||0)+1,Q=C[U];if(Q&&(!(h==="alignment"?S!==It(Q):!1)||E.every(P=>It(P.placement)===S?P.overflows[0]>0:!0)))return{data:{index:U,overflows:E},reset:{placement:Q}};let L=(A=E.filter(q=>q.overflows[0]<=0).sort((q,P)=>q.overflows[1]-P.overflows[1])[0])==null?void 0:A.placement;if(!L)switch(g){case"bestFit":{var B;const q=(B=E.filter(P=>{if($){const K=It(P.placement);return K===S||K==="y"}return!0}).map(P=>[P.placement,P.overflows.filter(K=>K>0).reduce((K,ie)=>K+ie,0)]).sort((P,K)=>P[1]-K[1])[0])==null?void 0:B[0];q&&(L=q);break}case"initialPlacement":L=c;break}if(r!==L)return{reset:{placement:L}}}return{}}}},ku=new Set(["left","top"]);async function Du(n,a){const{placement:t,platform:e,elements:r}=n,o=await(e.isRTL==null?void 0:e.isRTL(r.floating)),i=nn(t),c=jn(t),l=It(t)==="y",p=ku.has(i)?-1:1,u=o&&l?-1:1,h=wr(a,n);let{mainAxis:y,crossAxis:g,alignmentAxis:b}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return c&&typeof b=="number"&&(g=c==="end"?b*-1:b),l?{x:g*u,y:y*p}:{x:y*p,y:g*u}}const Cu=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(a){var t,e;const{x:r,y:o,placement:i,middlewareData:c}=a,l=await Du(a,n);return i===((t=c.offset)==null?void 0:t.placement)&&(e=c.arrow)!=null&&e.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:i}}}}};function kr(){return typeof window<"u"}function sn(n){return Ts(n)?(n.nodeName||"").toLowerCase():"#document"}function Pe(n){var a;return(n==null||(a=n.ownerDocument)==null?void 0:a.defaultView)||window}function ht(n){var a;return(a=(Ts(n)?n.ownerDocument:n.document)||window.document)==null?void 0:a.documentElement}function Ts(n){return kr()?n instanceof Node||n instanceof Pe(n).Node:!1}function Me(n){return kr()?n instanceof Element||n instanceof Pe(n).Element:!1}function Dt(n){return kr()?n instanceof HTMLElement||n instanceof Pe(n).HTMLElement:!1}function ho(n){return!kr()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Pe(n).ShadowRoot}function Dr(n){const{overflow:a,overflowX:t,overflowY:e,display:r}=Fe(n);return/auto|scroll|overlay|hidden|clip/.test(a+e+t)&&r!=="inline"&&r!=="contents"}function Su(n){return/^(table|td|th)$/.test(sn(n))}function Cr(n){try{if(n.matches(":popover-open"))return!0}catch{}try{return n.matches(":modal")}catch{return!1}}const Mu=/transform|translate|scale|rotate|perspective|filter/,_u=/paint|layout|strict|content/,_t=n=>!!n&&n!=="none";let Br;function ya(n){const a=Me(n)?Fe(n):n;return _t(a.transform)||_t(a.translate)||_t(a.scale)||_t(a.rotate)||_t(a.perspective)||!ba()&&(_t(a.backdropFilter)||_t(a.filter))||Mu.test(a.willChange||"")||_u.test(a.contain||"")}function Pu(n){let a=Rt(n);for(;Dt(a)&&!Cn(a);){if(ya(a))return a;if(Cr(a))return null;a=Rt(a)}return null}function ba(){return Br==null&&(Br=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Br}function Cn(n){return/^(html|body|#document)$/.test(sn(n))}function Fe(n){return Pe(n).getComputedStyle(n)}function Sr(n){return Me(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function Rt(n){if(sn(n)==="html")return n;const a=n.assignedSlot||n.parentNode||ho(n)&&n.host||ht(n);return ho(a)?a.host:a}function $s(n){const a=Rt(n);return Cn(a)?(n.ownerDocument||n).body:Dt(a)&&Dr(a)?a:$s(a)}function Sn(n,a,t){var e;a===void 0&&(a=[]),t===void 0&&(t=!0);const r=$s(n),o=r===((e=n.ownerDocument)==null?void 0:e.body),i=Pe(r);if(o){const c=ca(i);return a.concat(i,i.visualViewport||[],Dr(r)?r:[],c&&t?Sn(c):[])}else return a.concat(r,Sn(r,[],t))}function ca(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Ns(n){const a=Fe(n);let t=parseFloat(a.width)||0,e=parseFloat(a.height)||0;const r=Dt(n),o=r?n.offsetWidth:t,i=r?n.offsetHeight:e,c=or(t)!==o||or(e)!==i;return c&&(t=o,e=i),{width:t,height:e,$:c}}function va(n){return Me(n)?n:n.contextElement}function Jt(n){const a=va(n);if(!Dt(a))return it(1);const t=a.getBoundingClientRect(),{width:e,height:r,$:o}=Ns(a);let i=(o?or(t.width):t.width)/e,c=(o?or(t.height):t.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const Iu=it(0);function Os(n){const a=Pe(n);return!ba()||!a.visualViewport?Iu:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function ju(n,a,t){return a===void 0&&(a=!1),!!t&&a&&t===Pe(n)}function Lt(n,a,t,e){a===void 0&&(a=!1),t===void 0&&(t=!1);const r=n.getBoundingClientRect(),o=va(n);let i=it(1);a&&(e?Me(e)&&(i=Jt(e)):i=Jt(n));const c=ju(o,t,e)?Os(o):it(0);let l=(r.left+c.x)/i.x,p=(r.top+c.y)/i.y,u=r.width/i.x,h=r.height/i.y;if(o&&e){const y=Pe(o),g=Me(e)?Pe(e):e;let b=y,w=ca(b);for(;w&&g!==b;){const f=Jt(w),D=w.getBoundingClientRect(),S=Fe(w),j=D.left+(w.clientLeft+parseFloat(S.paddingLeft))*f.x,T=D.top+(w.clientTop+parseFloat(S.paddingTop))*f.y;l*=f.x,p*=f.y,u*=f.x,h*=f.y,l+=j,p+=T,b=Pe(w),w=ca(b)}}return sr({width:u,height:h,x:l,y:p})}function Mr(n,a){const t=Sr(n).scrollLeft;return a?a.left+t:Lt(ht(n)).left+t}function As(n,a){const t=n.getBoundingClientRect(),e=t.left+a.scrollLeft-Mr(n,t),r=t.top+a.scrollTop;return{x:e,y:r}}function Eu(n){let{elements:a,rect:t,offsetParent:e,strategy:r}=n;const o=r==="fixed",i=ht(e),c=a?Cr(a.floating):!1;if(e===i||c&&o)return t;let l={scrollLeft:0,scrollTop:0},p=it(1);const u=it(0),h=Dt(e);if((h||!o)&&((sn(e)!=="body"||Dr(i))&&(l=Sr(e)),h)){const g=Lt(e);p=Jt(e),u.x=g.x+e.clientLeft,u.y=g.y+e.clientTop}const y=i&&!h&&!o?As(i,l):it(0);return{width:t.width*p.x,height:t.height*p.y,x:t.x*p.x-l.scrollLeft*p.x+u.x+y.x,y:t.y*p.y-l.scrollTop*p.y+u.y+y.y}}function Tu(n){return n.getClientRects?Array.from(n.getClientRects()):[]}function $u(n){const a=Sr(n),t=n.ownerDocument.body,e=Et(n.scrollWidth,n.clientWidth,t.scrollWidth,t.clientWidth),r=Et(n.scrollHeight,n.clientHeight,t.scrollHeight,t.clientHeight);let o=-a.scrollLeft+Mr(n);const i=-a.scrollTop;return Fe(t).direction==="rtl"&&(o+=Et(n.clientWidth,t.clientWidth)-e),{width:e,height:r,x:o,y:i}}const Nu=25;function Ou(n,a,t){t===void 0&&(t="viewport");const e=t==="layoutViewport",r=Pe(n),o=ht(n),i=r.visualViewport;let c=o.clientWidth,l=o.clientHeight,p=0,u=0;if(i){const y=!ba()||a==="fixed";e?y||(p=-i.offsetLeft,u=-i.offsetTop):(c=i.width,l=i.height,y&&(p=i.offsetLeft,u=i.offsetTop))}if(Mr(o)<=0){const y=o.ownerDocument,g=y.body,b=getComputedStyle(g),w=y.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,f=Math.abs(o.clientWidth-g.clientWidth-w),D=getComputedStyle(o).scrollbarGutter==="stable both-edges"?f/2:f;D<=Nu&&(c-=D)}return{width:c,height:l,x:p,y:u}}function Au(n,a){const t=Lt(n,!0,a==="fixed"),e=t.top+n.clientTop,r=t.left+n.clientLeft,o=Jt(n),i=n.clientWidth*o.x,c=n.clientHeight*o.y,l=r*o.x,p=e*o.y;return{width:i,height:c,x:l,y:p}}function mo(n,a,t){let e;if(a==="viewport"||a==="layoutViewport")e=Ou(n,t,a);else if(a==="document")e=$u(ht(n));else if(Me(a))e=Au(a,t);else{const r=Os(n);e={x:a.x-r.x,y:a.y-r.y,width:a.width,height:a.height}}return sr(e)}function Ru(n,a){const t=a.get(n);if(t)return t;let e=Sn(n,[],!1).filter(c=>Me(c)&&sn(c)!=="body"),r=null;const o=Fe(n).position==="fixed";let i=o?Rt(n):n;for(;Me(i)&&!Cn(i);){const c=Fe(i),l=ya(i),p=r?r.position:o?"fixed":"";!l&&(p==="fixed"||p==="absolute"&&c.position==="static")?e=e.filter(h=>h!==i):r=c,i=Rt(i)}return a.set(n,e),e}function Lu(n){let{element:a,boundary:t,rootBoundary:e,strategy:r}=n;const i=[...t==="clippingAncestors"?Cr(a)?[]:Ru(a,this._c):[].concat(t),e],c=mo(a,i[0],r);let l=c.top,p=c.right,u=c.bottom,h=c.left;for(let y=1;y<i.length;y++){const g=mo(a,i[y],r);l=Et(g.top,l),p=tn(g.right,p),u=tn(g.bottom,u),h=Et(g.left,h)}return{width:p-h,height:u-l,x:h,y:l}}function Fu(n){const{width:a,height:t}=Ns(n);return{width:a,height:t}}function Yu(n,a,t){const e=Dt(a),r=ht(a),o=t==="fixed",i=Lt(n,!0,o,a);let c={scrollLeft:0,scrollTop:0};const l=it(0);if((e||!o)&&((sn(a)!=="body"||Dr(r))&&(c=Sr(a)),e)){const y=Lt(a,!0,o,a);l.x=y.x+a.clientLeft,l.y=y.y+a.clientTop}!e&&r&&(l.x=Mr(r));const p=r&&!e&&!o?As(r,c):it(0),u=i.left+c.scrollLeft-l.x-p.x,h=i.top+c.scrollTop-l.y-p.y;return{x:u,y:h,width:i.width,height:i.height}}function Hr(n){return Fe(n).position==="static"}function go(n,a){if(!Dt(n)||Fe(n).position==="fixed")return null;if(a)return a(n);let t=n.offsetParent;return ht(n)===t&&(t=t.ownerDocument.body),t}function Rs(n,a){const t=Pe(n);if(Cr(n))return t;if(!Dt(n)){let r=Rt(n);for(;r&&!Cn(r);){if(Me(r)&&!Hr(r))return r;r=Rt(r)}return t}let e=go(n,a);for(;e&&Su(e)&&Hr(e);)e=go(e,a);return e&&Cn(e)&&Hr(e)&&!ya(e)?t:e||Pu(n)||t}const Wu=async function(n){const a=this.getOffsetParent||Rs,t=this.getDimensions,e=await t(n.floating);return{reference:Yu(n.reference,await a(n.floating),n.strategy),floating:{x:0,y:0,width:e.width,height:e.height}}};function Bu(n){return Fe(n).direction==="rtl"}const Hu={convertOffsetParentRelativeRectToViewportRelativeRect:Eu,getDocumentElement:ht,getClippingRect:Lu,getOffsetParent:Rs,getElementRects:Wu,getClientRects:Tu,getDimensions:Fu,getScale:Jt,isElement:Me,isRTL:Bu};function Ls(n,a){return n.x===a.x&&n.y===a.y&&n.width===a.width&&n.height===a.height}function zu(n,a,t){let e=null,r;const o=ht(n);function i(){var u;clearTimeout(r),(u=e)==null||u.disconnect(),e=null}function c(u,h){u===void 0&&(u=!1),h===void 0&&(h=1),i();const y=n.getBoundingClientRect(),{left:g,top:b,width:w,height:f}=y;if(u||a(),!w||!f)return;const D=Wn(b),S=Wn(o.clientWidth-(g+w)),j=Wn(o.clientHeight-(b+f)),T=Wn(g),$={rootMargin:-D+"px "+-S+"px "+-j+"px "+-T+"px",threshold:Et(0,tn(1,h))||1};let C=!0;function k(_){const E=_[0].intersectionRatio;if(!Ls(y,n.getBoundingClientRect()))return c();if(E!==h){if(!C)return c();E?c(!1,E):r=setTimeout(()=>{c(!1,1e-7)},1e3)}C=!1}try{e=new IntersectionObserver(k,{...$,root:o.ownerDocument})}catch{e=new IntersectionObserver(k,$)}e.observe(n)}const l=Pe(n),p=()=>c(t);return l.addEventListener("resize",p),c(!0),()=>{l.removeEventListener("resize",p),i()}}function qu(n,a,t,e){e===void 0&&(e={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:l=!1}=e,p=va(n),u=r||o?[...p?Sn(p):[],...a?Sn(a):[]]:[];u.forEach(D=>{r&&D.addEventListener("scroll",t),o&&D.addEventListener("resize",t)});const h=p&&c?zu(p,t,o):null;let y=-1,g=null;i&&(g=new ResizeObserver(D=>{let[S]=D;S&&S.target===p&&g&&a&&(g.unobserve(a),cancelAnimationFrame(y),y=requestAnimationFrame(()=>{var j;(j=g)==null||j.observe(a)})),t()}),p&&!l&&g.observe(p),a&&g.observe(a));let b,w=l?Lt(n):null;l&&f();function f(){const D=Lt(n);w&&!Ls(w,D)&&t(),w=D,b=requestAnimationFrame(f)}return t(),()=>{var D;u.forEach(S=>{r&&S.removeEventListener("scroll",t),o&&S.removeEventListener("resize",t)}),h==null||h(),(D=g)==null||D.disconnect(),g=null,l&&cancelAnimationFrame(b)}}const Qu=Cu,Ku=wu,xo=vu,Vu=(n,a,t)=>{const e=new Map,r=t??{},o={...Hu,...r.platform,_c:e};return bu(n,a,{...r,platform:o})};var Uu=typeof document<"u",Xu=function(){},Gn=Uu?v.useLayoutEffect:Xu;function cr(n,a){if(n===a)return!0;if(typeof n!=typeof a)return!1;if(typeof n=="function"&&n.toString()===a.toString())return!0;let t,e,r;if(n&&a&&typeof n=="object"){if(Array.isArray(n)){if(t=n.length,t!==a.length)return!1;for(e=t;e--!==0;)if(!cr(n[e],a[e]))return!1;return!0}if(r=Object.keys(n),t=r.length,t!==Object.keys(a).length)return!1;for(e=t;e--!==0;)if(!{}.hasOwnProperty.call(a,r[e]))return!1;for(e=t;e--!==0;){const o=r[e];if(!(o==="_owner"&&n.$$typeof)&&!cr(n[o],a[o]))return!1}return!0}return n!==n&&a!==a}function Fs(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function yo(n,a){const t=Fs(n);return Math.round(a*t)/t}function zr(n){const a=v.useRef(n);return Gn(()=>{a.current=n}),a}function Gu(n){n===void 0&&(n={});const{placement:a="bottom",strategy:t="absolute",middleware:e=[],platform:r,elements:{reference:o,floating:i}={},transform:c=!0,whileElementsMounted:l,open:p}=n,[u,h]=v.useState({x:0,y:0,strategy:t,placement:a,middlewareData:{},isPositioned:!1}),[y,g]=v.useState(e);cr(y,e)||g(e);const[b,w]=v.useState(null),[f,D]=v.useState(null),S=v.useCallback(P=>{P!==$.current&&($.current=P,w(P))},[]),j=v.useCallback(P=>{P!==C.current&&(C.current=P,D(P))},[]),T=o||b,O=i||f,$=v.useRef(null),C=v.useRef(null),k=v.useRef(u),_=l!=null,E=zr(l),N=zr(r),A=zr(p),B=v.useCallback(()=>{if(!$.current||!C.current)return;const P={placement:a,strategy:t,middleware:y};N.current&&(P.platform=N.current),Vu($.current,C.current,P).then(K=>{const ie={...K,isPositioned:A.current!==!1};U.current&&!cr(k.current,ie)&&(k.current=ie,qc.flushSync(()=>{h(ie)}))})},[y,a,t,N,A]);Gn(()=>{p===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,h(P=>({...P,isPositioned:!1})))},[p]);const U=v.useRef(!1);Gn(()=>(U.current=!0,()=>{U.current=!1}),[]),Gn(()=>{if(T&&($.current=T),O&&(C.current=O),T&&O){if(E.current)return E.current(T,O,B);B()}},[T,O,B,E,_]);const Q=v.useMemo(()=>({reference:$,floating:C,setReference:S,setFloating:j}),[S,j]),L=v.useMemo(()=>({reference:T,floating:O}),[T,O]),q=v.useMemo(()=>{const P={position:t,left:0,top:0};if(!L.floating)return P;const K=yo(L.floating,u.x),ie=yo(L.floating,u.y);return c?{...P,transform:"translate("+K+"px, "+ie+"px)",...Fs(L.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:K,top:ie}},[t,c,L.floating,u.x,u.y]);return v.useMemo(()=>({...u,update:B,refs:Q,elements:L,floatingStyles:q}),[u,B,Q,L,q])}const Ju=n=>{function a(t){return{}.hasOwnProperty.call(t,"current")}return{name:"arrow",options:n,fn(t){const{element:e,padding:r}=typeof n=="function"?n(t):n;return e&&a(e)?e.current!=null?xo({element:e.current,padding:r}).fn(t):{}:e?xo({element:e,padding:r}).fn(t):{}}}},Zu=(n,a)=>{const t=Qu(n);return{name:t.name,fn:t.fn,options:[n,a]}},ep=(n,a)=>{const t=Ku(n);return{name:t.name,fn:t.fn,options:[n,a]}},tp=(n,a)=>{const t=Ju(n);return{name:t.name,fn:t.fn,options:[n,a]}},Ys=216n,np=(1n<<Ys)-1n;function rp(n){const a=typeof n=="bigint"?n:BigInt(n.trim());if(a<0n)throw new Error(`Invalid tokenId: ${String(n)}`);return{itemId:(a>>Ys).toString(),issuedId:(a&np).toString()}}function ap(n){if(!n)return null;try{return rp(n).itemId}catch{return null}}function bo(n,a){return a.kind==="listed"?{...n,isOnSale:!0,listingPrice:a.priceCredits,tradeId:a.tradeId??n.tradeId}:{...n,isOnSale:!1,listingPrice:void 0,tradeId:void 0}}function qr(n,a,t){const{address:e,contractAddress:r,tokenId:o}=a;if(!r||!o)return;const i=`${r}-${o}`;n.cancelQueries({queryKey:["owned-token",r,o]}),n.cancelQueries({queryKey:["secondary-sale-state"]}),e&&n.cancelQueries({queryKey:["my-assets",e]});const c=t.kind==="gone";n.setQueriesData({queryKey:["owned-token",r,o]},p=>p&&(c?null:bo(p,t)));const l=e?["my-assets",e]:["my-assets"];n.setQueriesData({queryKey:l},p=>p!=null&&p.pages?{...p,pages:p.pages.map(u=>{if(c){const h=u.items.filter(y=>!(y.contractAddress===r&&y.tokenId===o));return{...u,items:h,total:Math.max(0,u.total-(u.items.length-h.length))}}return{...u,items:u.items.map(h=>h.contractAddress===r&&h.tokenId===o?bo(h,t):h)}})}:p),n.setQueriesData({queryKey:["secondary-sale-state"]},p=>{var h;if(!p)return p;const u={...p};return t.kind==="removed"||t.kind==="gone"?delete u[i]:u[i]={priceCredits:t.priceCredits,tradeId:t.tradeId??((h=u[i])==null?void 0:h.tradeId)??""},u})}function op(n){return!(n.isMarket||n.forSale&&n.priceKnown||n.manage||n.soldOutWithResale||!n.stillResolving&&!n.resolvingTrade&&(n.isTokenRoute?!n.ownedAssetLoading:!n.deepLinkLoading))}const ip="data:image/webp;base64,UklGRqgOAABXRUJQVlA4IJwOAACwOwCdASqEAIsAPj0YikMiIaEWuib4IAPEtQBl0QC/bukK7J6X8cPZP5F69/Nvhj8oPlD3odY/QB8RXPv/C+3n59+izzA/0l/3/9064P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F7kADj+rzqjSoqwVTnCCjOKrF1Gt1i+6oeDggdd5wEh1ghvxdHELxvJeJE8x82cfHEVXhE9Nheu7Q1WycLXUTZA8oZHsdBaBFpk6vyYdYFT8YTShaCjPle1+2DJHzXzhRUQ6ZY/HcDs/vS2V8+jO+pjV23u5WL6yRWULzVi+0qUXIiJzd9qj65YnWPMxIubcSpm+5n8vMpysoMuGzoNwBmNszF+S+b8acZRgm2Gi0UT5OGuYwq4wZ5kmd8OqnDzhze2RxwMRtRm+17eKYWzLWtgVuOca/HWuBI58UC9FNZtBLv1l2htg7Iyehb/cr9uKvXkPXh0LFeyfEc49dOsGvppssGqOAAAAA=",cp=m.div`
3
3
  display: flex;
4
4
  flex-direction: column;
5
5
  gap: 24px;
@@ -1705,7 +1705,7 @@ var Hc=Object.defineProperty;var zc=(n,a,t)=>a in n?Hc(n,a,{enumerable:!0,config
1705
1705
  margin-top: 18px;
1706
1706
  `,Ni=m(Pn)`
1707
1707
  flex: 1;
1708
- `;function Oi(n){if(en(n))return x("errors.rejected");const a=(n.message??"").toLowerCase();return a.includes("insufficient")?x("marketCheckout.error.insufficient",{currency:vt.name}):a.includes("not found")||a.includes("no active listing")||a.includes("404")?x("marketCheckout.error.soldOrRemoved"):a.includes("your own listing")?x("errors.cantBuyOwn"):x("marketCheckout.error.generic")}function ay(n){return{id:n.tradeId,tradeId:n.tradeId,name:n.name,creator:n.creator,contractAddress:n.contractAddress,itemId:n.itemId,category:n.category,wearableCategory:n.wearableCategory??void 0,rarity:n.rarity,network:n.network,chainId:n.chainId,thumbnail:n.thumbnail,priceCredits:0,gender:null,isSmart:!1}}function yc({listing:n,rate:a,onClose:t,onSold:e}){const{session:r}=Ot(),{data:o,isError:i}=ps(r),c=Bt(),l=Wt(),[p,u]=v.useState("confirm"),[h,y]=v.useState(x("marketCheckout.lockingPrice")),[g,b]=v.useState(null),[w,f]=v.useState(null),D=v.useRef(null),S=rr(Wr(n.manaWei,a));v.useEffect(()=>{let C=!1;if(!r){u("error"),b(x("buyModal.signInToCheckout"));return}return(async()=>{try{const _=await ys(n.tradeId);if(!_)throw new Error("not found");if(fs(_,r.address))throw new Error("You can't buy your own listing.");const E=Wr(n.manaWei,a);if(!Number.isFinite(E)||E<=0)throw new Error("price unavailable");const{credit:N,maxCreditedValue:A,usdCents:B}=await oa(r.identity,E,n.tradeId);if(C){$e(r.identity,[N.id]).catch(()=>{});return}D.current=N.id,f({trade:_,credit:N,maxCreditedValue:A,usdCents:B,credits:rr(B)}),y("")}catch(_){if(C)return;console.error("[market] authorize failed",_),le(at(_)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"authorize",error_code:Xe(_),value_usd:Math.round(Wr(n.manaWei,a))/100}),u("error"),b(Oi(_))}})(),()=>{C=!0,D.current&&r&&($e(r.identity,[D.current]).catch(()=>{}),D.current=null)}},[]);const j=!!w&&o!=null&&o.credits<w.credits;async function T(){if(!r||!w)return;if(j){le("Shop Buy Credits Prompted",{from:"item_checkout",credits_needed:w.credits,credits_balance:(o==null?void 0:o.credits)??0,shortfall:Math.max(0,w.credits-((o==null?void 0:o.credits)??0))}),$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,l("/credits");return}u("working"),b(null);let C=!1;try{y(x("marketCheckout.confirming"));const k={trade:w.trade,buyer:r.address,signer:r.signer,credits:[w.credit],maxCreditedValue:w.maxCreditedValue};let _;if(ks())try{_=await Ss(k),await Ms(_),C=!0}catch(N){if(N instanceof _s)C=!0;else if(N instanceof Ps)_=await ar(k);else throw N}else _=await ar(k);D.current=null,le("Shop Completed Purchase",{items:[{item_id:n.itemId??null,contract_address:n.contractAddress,token_id:null,price_usd:w.usdCents/100}],value_credits:w.credits,value_usd:w.usdCents/100,purchase_type:"item",is_primary:!0,payment_type:"credits",no_crypto_step:C,transaction_hash:_??null}),c.invalidateQueries({queryKey:["usd-balance"]}),c.invalidateQueries({queryKey:["detail-trade"]}),c.invalidateQueries({queryKey:["shop-item"]}),c.invalidateQueries({queryKey:["item-resales",n.contractAddress,n.itemId]}),c.invalidateQueries({queryKey:["shop-items"]}),c.invalidateQueries({queryKey:["catalog-items"]}),c.invalidateQueries({queryKey:["my-assets"]}),c.invalidateQueries({queryKey:["purchases"]});const E={items:[ay(n)],txHash:_};l("/success",{state:E})}catch(k){console.error("[market] buy now failed",k),$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,le(at(k)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"submit",error_code:Xe(k),value_usd:w.usdCents/100}),c.invalidateQueries({queryKey:["usd-balance"]}),b(Oi(k)),u("error");const _=(k.message??"").toLowerCase();(_.includes("not found")||_.includes("no active listing")||_.includes("404"))&&e()}}function O(){r&&w&&$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,t()}const $=p==="working";return s.jsxs(Kx,{role:"dialog","aria-modal":"true","aria-label":x("buyModal.dialogAria",{name:n.name}),children:[s.jsx(Vx,{onClick:$?void 0:O,"aria-hidden":!0}),s.jsxs(Ux,{children:[s.jsxs(Xx,{children:[s.jsx(Gx,{children:n.thumbnail?s.jsx("img",{src:n.thumbnail,alt:""}):null}),s.jsxs("div",{children:[s.jsx(Jx,{title:n.name,children:n.name||x("buyModal.itemFallback")}),s.jsx(xs,{"data-variant":"rarity",children:n.rarity})]})]}),s.jsx(Zx,{children:w?s.jsxs(s.Fragment,{children:[s.jsx(Ii,{children:x("marketCheckout.finalPrice")}),s.jsxs(ji,{children:[s.jsx(Ei,{}),oo(w.credits)]}),s.jsxs(Ti,{className:"muted",children:[x("marketCheckout.lockedForPurchase")," · $",(w.usdCents/100).toFixed(2)]})]}):s.jsxs(s.Fragment,{children:[s.jsx(Ii,{children:x("marketCheckout.todaysPrice")}),s.jsxs(ji,{"data-approx":!0,children:[s.jsx(ey,{"aria-hidden":!0,children:"≈"}),s.jsx(Ei,{}),oo(S)]}),s.jsx(Ti,{className:"muted",children:h||x("marketCheckout.lockingPrice")})]})}),r?s.jsxs(ty,{className:"muted",children:[x("marketCheckout.yourBalance")," ",s.jsx(_e,{className:"ccy-mark"})," ",ol(o,i)]}):null,j?s.jsx($i,{className:"muted",children:x("marketCheckout.needMore",{currency:vt.name})}):null,h&&p==="working"?s.jsx($i,{className:"muted",children:h}):null,s.jsx(ny,{message:g}),s.jsxs(ry,{children:[s.jsx(Ni,{variant:"ghost",onClick:O,disabled:$,children:x("buyModal.cancel")}),s.jsx(Ni,{variant:"purple",onClick:()=>void T(),disabled:$||!w,children:$?x("marketCheckout.buying"):j?x("nav.getCredits",{currency:vt.name}):x("marketCheckout.confirmPurchase")})]})]})]})}const oy=v.lazy(async()=>{const[{EmoteControls:n},{Experimental_CssVarsProvider:a},{light:t}]=await Promise.all([Fr(()=>import("./index-DU8_EWWx.js").then(e=>e.i),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11])),Fr(()=>import("./index-CJgXTNhS.js"),__vite__mapDeps([12,3,1,4,2,5,6,7,13,14,9])),Fr(()=>import("./index-yJi2QIJf.js").then(e=>e.c5),__vite__mapDeps([3,1,4,2,5,6,7]))]);return{default:e=>s.jsx(a,{theme:t,children:s.jsx(n,{...e})})}});function iy(n){return s.jsx(v.Suspense,{fallback:null,children:s.jsx(oy,{...n})})}function sy(){const n=v.useRef(null),[a,t]=v.useState(!0),[e,r]=v.useState(()=>typeof document>"u"||document.visibilityState!=="hidden");return v.useEffect(()=>{const o=n.current;if(!o||typeof IntersectionObserver>"u")return;const i=new IntersectionObserver(c=>t(c.some(l=>l.isIntersecting)),{rootMargin:"200px"});return i.observe(o),()=>i.disconnect()},[]),v.useEffect(()=>{if(typeof document>"u")return;const o=()=>r(document.visibilityState!=="hidden");return document.addEventListener("visibilitychange",o),()=>document.removeEventListener("visibilitychange",o)},[]),{ref:n,active:a&&e}}function cy(n){if(n)try{so.sendMessage(n,so.PreviewMessageType.CONTROLLER_REQUEST,{id:`dispose-${Date.now()}`,namespace:"scene",method:"cleanup",params:[]})}catch{}}const{colors:ce,media:Ia}=d,ly=il`
1708
+ `;function Oi(n){if(en(n))return x("errors.rejected");const a=(n.message??"").toLowerCase();return a.includes("insufficient")?x("marketCheckout.error.insufficient",{currency:vt.name}):a.includes("not found")||a.includes("no active listing")||a.includes("404")?x("marketCheckout.error.soldOrRemoved"):a.includes("your own listing")?x("errors.cantBuyOwn"):x("marketCheckout.error.generic")}function ay(n){return{id:n.tradeId,tradeId:n.tradeId,name:n.name,creator:n.creator,contractAddress:n.contractAddress,itemId:n.itemId,category:n.category,wearableCategory:n.wearableCategory??void 0,rarity:n.rarity,network:n.network,chainId:n.chainId,thumbnail:n.thumbnail,priceCredits:0,gender:null,isSmart:!1}}function yc({listing:n,rate:a,onClose:t,onSold:e}){const{session:r}=Ot(),{data:o,isError:i}=ps(r),c=Bt(),l=Wt(),[p,u]=v.useState("confirm"),[h,y]=v.useState(x("marketCheckout.lockingPrice")),[g,b]=v.useState(null),[w,f]=v.useState(null),D=v.useRef(null),S=rr(Wr(n.manaWei,a));v.useEffect(()=>{let C=!1;if(!r){u("error"),b(x("buyModal.signInToCheckout"));return}return(async()=>{try{const _=await ys(n.tradeId);if(!_)throw new Error("not found");if(fs(_,r.address))throw new Error("You can't buy your own listing.");const E=Wr(n.manaWei,a);if(!Number.isFinite(E)||E<=0)throw new Error("price unavailable");const{credit:N,maxCreditedValue:A,usdCents:B}=await oa(r.identity,E,n.tradeId);if(C){$e(r.identity,[N.id]).catch(()=>{});return}D.current=N.id,f({trade:_,credit:N,maxCreditedValue:A,usdCents:B,credits:rr(B)}),y("")}catch(_){if(C)return;console.error("[market] authorize failed",_),le(at(_)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"authorize",error_code:Xe(_),value_usd:Math.round(Wr(n.manaWei,a))/100}),u("error"),b(Oi(_))}})(),()=>{C=!0,D.current&&r&&($e(r.identity,[D.current]).catch(()=>{}),D.current=null)}},[]);const j=!!w&&o!=null&&o.credits<w.credits;async function T(){if(!r||!w)return;if(j){le("Shop Buy Credits Prompted",{from:"item_checkout",credits_needed:w.credits,credits_balance:(o==null?void 0:o.credits)??0,shortfall:Math.max(0,w.credits-((o==null?void 0:o.credits)??0))}),$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,l("/credits");return}u("working"),b(null);let C=!1;try{y(x("marketCheckout.confirming"));const k={trade:w.trade,buyer:r.address,signer:r.signer,credits:[w.credit],maxCreditedValue:w.maxCreditedValue};let _;if(ks())try{_=await Ss(k),await Ms(_),C=!0}catch(N){if(N instanceof _s)C=!0;else if(N instanceof Ps)_=await ar(k);else throw N}else _=await ar(k);D.current=null,le("Shop Completed Purchase",{items:[{item_id:n.itemId??null,contract_address:n.contractAddress,token_id:null,price_usd:w.usdCents/100}],value_credits:w.credits,value_usd:w.usdCents/100,purchase_type:"item",is_primary:!0,payment_type:"credits",no_crypto_step:C,transaction_hash:_??null}),c.invalidateQueries({queryKey:["usd-balance"]}),c.invalidateQueries({queryKey:["detail-trade"]}),c.invalidateQueries({queryKey:["shop-item"]}),c.invalidateQueries({queryKey:["item-resales",n.contractAddress,n.itemId]}),c.invalidateQueries({queryKey:["shop-items"]}),c.invalidateQueries({queryKey:["catalog-items"]}),c.invalidateQueries({queryKey:["my-assets"]}),c.invalidateQueries({queryKey:["purchases"]});const E={items:[ay(n)],txHash:_};l("/success",{state:E})}catch(k){console.error("[market] buy now failed",k),$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,le(at(k)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"submit",error_code:Xe(k),value_usd:w.usdCents/100}),c.invalidateQueries({queryKey:["usd-balance"]}),b(Oi(k)),u("error");const _=(k.message??"").toLowerCase();(_.includes("not found")||_.includes("no active listing")||_.includes("404"))&&e()}}function O(){r&&w&&$e(r.identity,[w.credit.id]).catch(()=>{}),D.current=null,t()}const $=p==="working";return s.jsxs(Kx,{role:"dialog","aria-modal":"true","aria-label":x("buyModal.dialogAria",{name:n.name}),children:[s.jsx(Vx,{onClick:$?void 0:O,"aria-hidden":!0}),s.jsxs(Ux,{children:[s.jsxs(Xx,{children:[s.jsx(Gx,{children:n.thumbnail?s.jsx("img",{src:n.thumbnail,alt:""}):null}),s.jsxs("div",{children:[s.jsx(Jx,{title:n.name,children:n.name||x("buyModal.itemFallback")}),s.jsx(xs,{"data-variant":"rarity",children:n.rarity})]})]}),s.jsx(Zx,{children:w?s.jsxs(s.Fragment,{children:[s.jsx(Ii,{children:x("marketCheckout.finalPrice")}),s.jsxs(ji,{children:[s.jsx(Ei,{}),oo(w.credits)]}),s.jsxs(Ti,{className:"muted",children:[x("marketCheckout.lockedForPurchase")," · $",(w.usdCents/100).toFixed(2)]})]}):s.jsxs(s.Fragment,{children:[s.jsx(Ii,{children:x("marketCheckout.todaysPrice")}),s.jsxs(ji,{"data-approx":!0,children:[s.jsx(ey,{"aria-hidden":!0,children:"≈"}),s.jsx(Ei,{}),oo(S)]}),s.jsx(Ti,{className:"muted",children:h||x("marketCheckout.lockingPrice")})]})}),r?s.jsxs(ty,{className:"muted",children:[x("marketCheckout.yourBalance")," ",s.jsx(_e,{className:"ccy-mark"})," ",ol(o,i)]}):null,j?s.jsx($i,{className:"muted",children:x("marketCheckout.needMore",{currency:vt.name})}):null,h&&p==="working"?s.jsx($i,{className:"muted",children:h}):null,s.jsx(ny,{message:g}),s.jsxs(ry,{children:[s.jsx(Ni,{variant:"ghost",onClick:O,disabled:$,children:x("buyModal.cancel")}),s.jsx(Ni,{variant:"purple",onClick:()=>void T(),disabled:$||!w,children:$?x("marketCheckout.buying"):j?x("nav.getCredits",{currency:vt.name}):x("marketCheckout.confirmPurchase")})]})]})]})}const oy=v.lazy(async()=>{const[{EmoteControls:n},{Experimental_CssVarsProvider:a},{light:t}]=await Promise.all([Fr(()=>import("./index-H02HAhZo.js").then(e=>e.i),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11])),Fr(()=>import("./index-ASq7s2Iv.js"),__vite__mapDeps([12,3,1,4,2,5,6,7,13,14,9])),Fr(()=>import("./index-BMIuNfCB.js").then(e=>e.c6),__vite__mapDeps([3,1,4,2,5,6,7]))]);return{default:e=>s.jsx(a,{theme:t,children:s.jsx(n,{...e})})}});function iy(n){return s.jsx(v.Suspense,{fallback:null,children:s.jsx(oy,{...n})})}function sy(){const n=v.useRef(null),[a,t]=v.useState(!0),[e,r]=v.useState(()=>typeof document>"u"||document.visibilityState!=="hidden");return v.useEffect(()=>{const o=n.current;if(!o||typeof IntersectionObserver>"u")return;const i=new IntersectionObserver(c=>t(c.some(l=>l.isIntersecting)),{rootMargin:"200px"});return i.observe(o),()=>i.disconnect()},[]),v.useEffect(()=>{if(typeof document>"u")return;const o=()=>r(document.visibilityState!=="hidden");return document.addEventListener("visibilitychange",o),()=>document.removeEventListener("visibilitychange",o)},[]),{ref:n,active:a&&e}}function cy(n){if(n)try{so.sendMessage(n,so.PreviewMessageType.CONTROLLER_REQUEST,{id:`dispose-${Date.now()}`,namespace:"scene",method:"cleanup",params:[]})}catch{}}const{colors:ce,media:Ia}=d,ly=il`
1709
1709
  to {
1710
1710
  transform: rotate(360deg);
1711
1711
  }
@@ -1,4 +1,4 @@
1
- import{r as l,j as c}from"./react-vyZjIDcS.js";import{s as u,B as f,e as d}from"./index-yJi2QIJf.js";const p=u.div`
1
+ import{r as l,j as c}from"./react-vyZjIDcS.js";import{s as u,B as f,e as d}from"./index-BMIuNfCB.js";const p=u.div`
2
2
  display: flex;
3
3
  justify-content: center;
4
4
  padding: 28px 0 8px;
@@ -1,4 +1,4 @@
1
- import{N as Y,M as Ke,O as M,bt as vt,b6 as mt,br as we}from"./index-yJi2QIJf.js";import{h as De,R as Me,r as O,j as X,d as nn,i as rn,g as on}from"./react-vyZjIDcS.js";import{g as jt,a as Nt,c as Lt,b as Ye,s as Ze,d as an,f as sn}from"./clsx-DhFqZi_3.js";import{_ as ln,T as Wt,u as ue,s as ht,o as je,a as un}from"./createSvgIcon-DLpGC0um.js";import{u as cn}from"./useTheme-DlRIY8zD.js";function fn(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}var Fe={exports:{}},S={};/**
1
+ import{N as Y,M as Ke,O as M,bu as vt,b7 as mt,bs as we}from"./index-BMIuNfCB.js";import{h as De,R as Me,r as O,j as X,d as nn,i as rn,g as on}from"./react-vyZjIDcS.js";import{g as jt,a as Nt,c as Lt,b as Ye,s as Ze,d as an,f as sn}from"./clsx-C78Se7VZ.js";import{_ as ln,T as Wt,u as ue,s as ht,o as je,a as un}from"./createSvgIcon-D6bh0MrS.js";import{u as cn}from"./useTheme-DVSXpYGO.js";function fn(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}var Fe={exports:{}},S={};/**
2
2
  * @license React
3
3
  * react-is.production.min.js
4
4
  *