@dcl/shop 0.1.0-29869835587.commit-e6e6578 → 0.1.0-29920979542.commit-4d76953
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.
- package/assets/{AnimatedBackground-BvysF8a0.js → AnimatedBackground-CKOyKuq9.js} +1 -1
- package/assets/Assets-ByJM1y5V.js +758 -0
- package/assets/Assets.styles-DD1YIA0w.js +503 -0
- package/assets/Cart-gPQahIus.js +3 -0
- package/assets/{CircularProgress-Bf7cTa84.js → CircularProgress-CtItbytk.js} +5 -5
- package/assets/{Collection-BFUSn0Z_.js → Collection-CLdWIwei.js} +1 -1
- package/assets/{CollectionCarousel-BaK4BZqg.js → CollectionCarousel-B_IpHIiN.js} +1 -1
- package/assets/{ConstantsUtil-CJUlyS7R.js → ConstantsUtil-CPwpahR3.js} +1 -1
- package/assets/{ContentClient-B6BvDsXj.js → ContentClient-BjQkITL0.js} +1 -1
- package/assets/{Creator-CTfg9WAL.js → Creator-VHIhb2gU.js} +1 -1
- package/assets/{CssVarsProvider-DQXUaIP8.js → CssVarsProvider-jpijQ72F.js} +1 -1
- package/assets/{DeploymentBuilder-Cp9K3LCu.js → DeploymentBuilder-D-b1kMax.js} +1 -1
- package/assets/{ErrorNotice-C7soUjRV.js → ErrorNotice-DDr3KjIH.js} +1 -1
- package/assets/{ExchangeController-H99cRhIr.js → ExchangeController-Co5yzjlz.js} +1 -1
- package/assets/GetCredits-BpKdDGUc.js +1 -0
- package/assets/{HelpersUtil-CN9OoRaT.js → HelpersUtil-BcUQ676Q.js} +1 -1
- package/assets/ImportListings-B47G6K7L.js +5 -0
- package/assets/ItemDetail-BOp9RNpW.js +78 -0
- package/assets/{LoadMore-QYabEF53.js → LoadMore-kFcJ8c6R.js} +1 -1
- package/assets/MarketCheckout-CS9k9P56.js +3 -0
- package/assets/MyAssets-ag2xjktG.js +258 -0
- package/assets/{MyFavorites-CCbFgdqL.js → MyFavorites-DjUSaIK2.js} +1 -1
- package/assets/MyPurchases-CzDlMrSh.js +200 -0
- package/assets/{NetworkUtil-Xp0fNa8X.js → NetworkUtil-CM7JZPbs.js} +1 -1
- package/assets/{NotFound-ViHzr3Nr.js → NotFound-Bvrv72pX.js} +1 -1
- package/assets/PrimaryListModal-Dcjz3ZJl.js +1 -0
- package/assets/{StoreSettings-BnHjda9z.js → StoreSettings-Cin3qrlR.js} +5 -5
- package/assets/{Success-CbfD54bz.js → Success-nfqeCH24.js} +2 -2
- package/assets/{SwapController-Tfj7j5wZ.js → SwapController-CU_5jEa7.js} +1 -1
- package/assets/Tooltip-zQgqv_WS.js +48 -0
- package/assets/{TradeService-kxdTGO_i.js → TradeService-_0nAkSNj.js} +1 -1
- package/assets/{W3MFrameProviderSingleton-BWjqHbac.js → W3MFrameProviderSingleton-MS8QbMhJ.js} +3 -3
- package/assets/{WebCryptoP256-8HU24K3x.js → WebCryptoP256-CPTxXHRL.js} +1 -1
- package/assets/{basic-DX-B5_bS.js → basic-Tf3II1zc.js} +1 -1
- package/assets/biconomy-DZCRr_z3.js +1 -0
- package/assets/{browser-9oFjBwrz.js → browser-7Z6Tx7yC.js} +1 -1
- package/assets/{browser-ponyfill-DMgE6PM5.js → browser-ponyfill-C_hn4Jen.js} +1 -1
- package/assets/browser-ponyfill-iWQHRc9C.js +1 -0
- package/assets/buy-B9BIW0Jt.js +1 -0
- package/assets/buy-gasless-DbZJNUIF.js +1 -0
- package/assets/{cart-checkout-C3WNM4cy.js → cart-checkout-B7LsaJk_.js} +1 -1
- package/assets/{categories-DQ55lr2p.js → categories-BltWZ-Er.js} +33 -33
- package/assets/{ccip-CYEnvd4I.js → ccip-Cc36BWjI.js} +1 -1
- package/assets/ccip-Do2tH0oQ.js +1 -0
- package/assets/{chains-CpxWadaj.js → chains-DOpzCPsr.js} +1 -1
- package/assets/collection-D7CncqdI.js +1 -0
- package/assets/{common-l22vMua4.js → common-BO9A6Obt.js} +1 -1
- package/assets/controller-DCaEQPE3.js +2 -0
- package/assets/{core-BtRDOtev.js → core-_W1O6dAM.js} +4 -4
- package/assets/{custom-DiiPEfeO.js → custom-BjaMQzvQ.js} +1 -1
- package/assets/{data-capture-BFGedRFL.js → data-capture-Dpsgkm1n.js} +1 -1
- package/assets/decimals-8h3d0d0Q.js +1 -0
- package/assets/decimals-z4vOxece.js +1 -0
- package/assets/detectExtension-Cvy4AYwr.js +1 -0
- package/assets/{email-D8YhsjSC.js → email-BIl3hlZ2.js} +1 -1
- package/assets/{embedded-wallet-CIVu6rdk.js → embedded-wallet-CHCE_nfA.js} +1 -1
- package/assets/emotion-styled.browser.esm-DP-xjC5M.js +1 -0
- package/assets/engine-CbJiHKp8.js +1 -0
- package/assets/{errors-BLIsDEoc.js → errors-BrsnEff4.js} +1 -1
- package/assets/estimate-l1-fee-DEmTi_Xz.js +1 -0
- package/assets/eth_estimateGas-BhQqpdnq.js +1 -0
- package/assets/eth_getStorageAt-CqeWdstl.js +1 -0
- package/assets/eth_getTransactionCount-Ca9PbmYY.js +1 -0
- package/assets/eth_sendRawTransaction-DPdnXbFR.js +1 -0
- package/assets/{ethereum-CkPyqOMA.js → ethereum-C3MAoMFC.js} +1 -1
- package/assets/{ethers-BeFqf2KO.js → ethers-CeDRuWE-.js} +1 -1
- package/assets/execute-2c6JVbQ7.js +2 -0
- package/assets/extractIPFS-HvQvYdM-.js +1 -0
- package/assets/{features-CFz8G3yF.js → features-CxUBJMFm.js} +1 -1
- package/assets/fetchTokenMetadata-DS7xbFh8.js +2 -0
- package/assets/{fortmatic-DhmlcDbL.js → fortmatic-udOxQk4J.js} +1 -1
- package/assets/get-bytecode-mfFuNYuc.js +1 -0
- package/assets/get-ecosystem-wallet-info-CpGKVIMs.js +1 -0
- package/assets/getBalance-DVC-Vuqr.js +2 -0
- package/assets/getInstalledModules-BNHlcIGs.js +1 -0
- package/assets/getNFT-CSbrXFvE.js +2 -0
- package/assets/getNFT-qJLfFykV.js +1 -0
- package/assets/{getOverlayAlpha-B_CoLTSj.js → getOverlayAlpha-DOBThdqC.js} +1 -1
- package/assets/{hashTypedData-DHR5yJit.js → hashTypedData-B4_iMbvS.js} +1 -1
- package/assets/{hashTypedData-BYNsvxyc.js → hashTypedData-dhsewv5B.js} +1 -1
- package/assets/import-C5j6Wx_d.js +1 -0
- package/assets/in-app-1Ryel-eO.js +1 -0
- package/assets/in-app-wallet-calls-CffLwIeA.js +1 -0
- package/assets/{index-CaHcCfyv.js → index-4eD2NdIO.js} +1 -1
- package/assets/index-6RadCnK_.js +2 -0
- package/assets/{index-CwWLPHI8.js → index-8mbANljx.js} +1 -1
- package/assets/index-BA2L6eSl.css +1 -0
- package/assets/{index-BDfpUFpd.js → index-BOwlzThi.js} +1 -1
- package/assets/{index-Cr7q_wI-.js → index-BdfhcS1O.js} +1 -1
- package/assets/{index-DJsdR_Dh.js → index-BmVq_L-1.js} +1 -1
- package/assets/{index-DkfyzgR8.js → index-BoYovC-T.js} +1 -1
- package/assets/{index-QMzB_9kT.js → index-BpbWCyB4.js} +1 -1
- package/assets/index-BsWlzlq1.js +4 -0
- package/assets/index-BsYYLNpm.js +1 -0
- package/assets/{index-CcJuo_B4.js → index-BukPqvyW.js} +1 -1
- package/assets/{index-PGZV0u8x.js → index-Bv7ES646.js} +1 -1
- package/assets/{index-DfnBxBKK.js → index-C-5O3A8t.js} +2 -2
- package/assets/{index-CN5ZLDnc.js → index-C-P3yFpA.js} +1 -1
- package/assets/index-C-zT6j6Q.js +2 -0
- package/assets/{index-FUu8bz4c.js → index-C1RUJcK5.js} +4 -4
- package/assets/{index-BtmcJRGy.js → index-C8ZENK8t.js} +1 -1
- package/assets/{index-BmxotHif.js → index-CABKIgjm.js} +1 -1
- package/assets/{index-pbhVNuOA.js → index-CAp_8XyK.js} +1 -1
- package/assets/{index--JSSHFMQ.js → index-CFkKMhmf.js} +1 -1
- package/assets/{index-BCGZozX2.js → index-CGKFKFa5.js} +1 -1
- package/assets/{index-Cuf2In7m.js → index-CGtI8pSN.js} +1 -1
- package/assets/{index-CTwiT5J0.js → index-CHTy8tIL.js} +1 -1
- package/assets/{index-g3sxw2b2.js → index-COJ-kKXu.js} +2 -2
- package/assets/{index-DGOaB47n.js → index-CQbgtHPx.js} +1 -1
- package/assets/{index-Do7lLz-O.js → index-C_P8UXnh.js} +1 -1
- package/assets/{index-goSkKmOv.js → index-C_wB7Cn-.js} +1 -1
- package/assets/{index-Bk6ayCIs.js → index-CjTTlJEo.js} +1 -1
- package/assets/{index-CtzfdSwK.js → index-Co247DcD.js} +1 -1
- package/assets/{index-B3vzzuVP.js → index-CpetmNFi.js} +1 -1
- package/assets/{index-Dp3Py-Ws.js → index-Cq0eRfqs.js} +1 -1
- package/assets/{index-BMFRmVon.js → index-CtUSW-Bf.js} +1 -1
- package/assets/{index-CXYokVDz.js → index-CvPKxvVT.js} +1 -1
- package/assets/{index-tKIgdudq.js → index-CvUlVzEh.js} +1 -1
- package/assets/index-Cw_zTgKJ.js +289 -0
- package/assets/{index-dYP5cvK2.js → index-Cx_FuvLh.js} +1 -1
- package/assets/{index-fOZ3JG1l.js → index-D7-fYmTC.js} +1 -1
- package/assets/{index-Y6b_vUQr.js → index-DDH_k4kE.js} +1 -1
- package/assets/{index-Cuq6iGY1.js → index-DDcyCRGs.js} +1 -1
- package/assets/{index-B4p2eLga.js → index-DEDR_sJL.js} +1 -1
- package/assets/{index-BfnFZQqu.js → index-DJVoIGkn.js} +1 -1
- package/assets/{index-07n_zhYq.js → index-DJZlClFe.js} +1 -1
- package/assets/{index-Cmi7sq59.js → index-DNI-bcwo.js} +1 -1
- package/assets/{index-BSjx8-a9.js → index-DPhmZ0Is.js} +1 -1
- package/assets/{index-CdfmzGmf.js → index-DZ7nTG5K.js} +1 -1
- package/assets/index-DeN7zJP6.js +2 -0
- package/assets/{index-2yTqM9xZ.js → index-DhSzX-CI.js} +1 -1
- package/assets/{index-CWuMb79R.js → index-DhoYZdLQ.js} +3 -3
- package/assets/{index-IqrjnIQ9.js → index-Dj-dQr5B.js} +1 -1
- package/assets/{index-BQwZ_U1w.js → index-Dnt0S0mL.js} +1 -1
- package/assets/{index-Da6whmyR.js → index-DobQjFvC.js} +1 -1
- package/assets/{index-C7SiFPEi.js → index-Drt6Trho.js} +1 -1
- package/assets/{index-CI-AD5iw.js → index-DtQgf-Kz.js} +1 -1
- package/assets/{index-BufR0bxC.js → index-LAd_iywb.js} +1 -1
- package/assets/{index-BuMOiAUw.js → index-LE62Wpkl.js} +1 -1
- package/assets/{index-mfpj9mGL.js → index-QNpfh38n.js} +1 -1
- package/assets/index-SIMFr-pa.js +3 -0
- package/assets/{index-C7VPGrdO.js → index-ULH0loBs.js} +1 -1
- package/assets/{index-Cv6TsksD.js → index-VGkdjss0.js} +1 -1
- package/assets/{index-BDRB8FDm.js → index-dlW_0FAj.js} +1 -1
- package/assets/{index-htvE856q.js → index-fBrY7bRL.js} +1 -1
- package/assets/{index-B4OkjZ5Z.js → index-nWE7w6GR.js} +3 -3
- package/assets/{index-gvpjFbR1.js → index-yxsQFb8G.js} +1 -1
- package/assets/{index-C_jKIil3.js → index-zY0h-QLU.js} +1 -1
- package/assets/{index.es-BsTkmkjS.js → index.es-BqINDpai.js} +1 -1
- package/assets/{index.es-Dvmu0NoU.js → index.es-DT0e-8F6.js} +4 -4
- package/assets/index.es-aQzlORue.js +1 -0
- package/assets/linkAccount-Coo42zCf.js +1 -0
- package/assets/loader-logo-BzY9EKdC.js +1 -0
- package/assets/{localBatchGatewayRequest-Cej95COc.js → localBatchGatewayRequest-CW07fVpY.js} +1 -1
- package/assets/{mana-rate-Disk-ReT.js → mana-rate-zpYtmb1D.js} +1 -1
- package/assets/{native-BMBZUPnx.js → native-0dhyeu0o.js} +1 -1
- package/assets/{networks-Dapm2cWP.js → networks-h5NQDWsI.js} +1 -1
- package/assets/{onramp-DLQLHSLI.js → onramp-BX2NU_qB.js} +1 -1
- package/assets/openzeppelin-PtKZTHIi.js +1 -0
- package/assets/ownerOf-DZ5adWxQ.js +1 -0
- package/assets/parseNft-PrcFp1dy.js +2 -0
- package/assets/{parseSignature-BUx9b-zW.js → parseSignature-773UBBmK.js} +14 -14
- package/assets/{parseSignature-O3FZfUUc.js → parseSignature-CCoh-bOo.js} +1 -1
- package/assets/passkeys-BpPvCZon.js +1 -0
- package/assets/{pay-with-exchange-DaiVhZAg.js → pay-with-exchange-gDj4lADp.js} +1 -1
- package/assets/prepare-contract-call-C3igYCn_.js +26 -0
- package/assets/{qr-overlay-CGmkZvV0.js → qr-overlay-DtSlNNS5.js} +3 -3
- package/assets/{react-C51i12iP.js → react-BMZSDQJw.js} +1 -1
- package/assets/{receive-DVL3YCyE.js → receive-DSZFrYHX.js} +1 -1
- package/assets/resolveImplementation-CbU1L1Fc.js +1 -0
- package/assets/{rpc-q1fg-PaK.js → rpc-BDqeZL2i.js} +2 -2
- package/assets/{secp256k1-Dj-unqH_.js → secp256k1-BZe2znzk.js} +1 -1
- package/assets/secp256k1-CknJ3w21.js +1 -0
- package/assets/{secp256k1-DT5nTJQH.js → secp256k1-pNAGLswQ.js} +1 -1
- package/assets/{send-CjhoocaG.js → send-DRd_OEaR.js} +1 -1
- package/assets/send-batch-transaction-D7eoe7U7.js +1 -0
- package/assets/send-eip712-transaction-fOYbA_CA.js +2 -0
- package/assets/send-gasless-transaction-Cxhl4UgI.js +2 -0
- package/assets/send-transaction-BoSey3h6.js +2 -0
- package/assets/{sendRawTransaction-CxX-WJOv.js → sendRawTransaction-2HzfqXtJ.js} +3 -3
- package/assets/{sentry-DKBoGDXH.js → sentry-8SzFotJj.js} +1 -1
- package/assets/{serializeTransaction-KtBgxNjB.js → serializeTransaction-DehzIoon.js} +1 -1
- package/assets/session-proposal-CXtYJ600.js +1 -0
- package/assets/session-request-Bzoc3aWY.js +2 -0
- package/assets/sha256-CDuVPJMW.js +1 -0
- package/assets/signing-BuFUwBsg.js +5 -0
- package/assets/{socials-BqxUUXtR.js → socials-DzFO5cs6.js} +1 -1
- package/assets/{swaps-EDZta6zk.js → swaps-DDj52bDn.js} +1 -1
- package/assets/thirdweb-CLT7AbaR.js +27 -0
- package/assets/to-serializable-transaction-3rHBxT_2.js +2 -0
- package/assets/totalSupply-qMyfSB-2.js +1 -0
- package/assets/transaction-DiMmwD2W.js +1 -0
- package/assets/transactionReceipt-D2-apwad.js +1 -0
- package/assets/{transactions-CGvL3Aj1.js → transactions-BzNf4QDf.js} +1 -1
- package/assets/types-DC0Zmj1B.js +1 -0
- package/assets/useCreditPacks-CCExEWAo.js +1 -0
- package/assets/useInfiniteGrid-CpG_Ao97.js +1 -0
- package/assets/{useStore-CQIJvFZA.js → useStore-IaDRl00u.js} +2 -2
- package/assets/useTheme-Y_Ojpcr-.js +1 -0
- package/assets/useTheme-tg-omw8T.js +1 -0
- package/assets/{utils-CBfcEx8F.js → utils-DLyVQGg1.js} +1 -1
- package/assets/{verifyHash-2hJaw2xF.js → verifyHash-4UFZIpQG.js} +1 -1
- package/assets/{w3m-modal-DZpfNka8.js → w3m-modal-D0oIAAHh.js} +1 -1
- package/assets/{w3m-modal-CXTIrAhw.js → w3m-modal-DuWRb-89.js} +1 -1
- package/assets/wait-for-tx-receipt-4BEbGWQp.js +1 -0
- package/assets/wallet-kind-Cg4yayUr.js +1 -0
- package/assets/wallets-K1dHuOGH.js +13 -0
- package/assets/web-connector-6Dl638uy.js +9 -0
- package/assets/{writeContract-CJkUo9D7.js → writeContract-DO4OjsR8.js} +1 -1
- package/assets/{zora-sepolia-CKT05Lph.js → zora-sepolia-sSAsjV_j.js} +1 -1
- package/assets/{zoraTestnet-CRD_79WO.js → zoraTestnet-DTqS-Os0.js} +1 -1
- package/index.html +11 -11
- package/package.json +2 -2
- package/assets/Assets-DoUIRoSX.js +0 -503
- package/assets/Cart-Cyj_u0xP.js +0 -3
- package/assets/GetCredits-BqhYAHL0.js +0 -1
- package/assets/ImportListings-CCQDdZMF.js +0 -5
- package/assets/ItemDetail-C6EEFa3M.js +0 -78
- package/assets/MarketCheckout-B1QbAQBC.js +0 -50
- package/assets/MyAssets-FkZXy017.css +0 -1
- package/assets/MyAssets-gjvqMgx3.js +0 -7
- package/assets/MyPurchases-D04-_M8f.js +0 -3
- package/assets/PrimaryListModal-D6DU8-ZC.js +0 -1
- package/assets/biconomy-DIiiyQwz.js +0 -1
- package/assets/browser-ponyfill-Djb5Py6a.js +0 -1
- package/assets/buy-C5_gzZWJ.js +0 -1
- package/assets/buy-gasless-Cxx1jwuH.js +0 -1
- package/assets/ccip-BafcYzQ9.js +0 -1
- package/assets/collection-DHOETntw.js +0 -1
- package/assets/controller-B80HcZCL.js +0 -2
- package/assets/decimals-Cdn10TAV.js +0 -1
- package/assets/decimals-DCazhsdS.js +0 -1
- package/assets/detectExtension-BSAkQ0I6.js +0 -1
- package/assets/emotion-styled.browser.esm-ClqtCiJQ.js +0 -1
- package/assets/engine-DsQHyohE.js +0 -1
- package/assets/estimate-l1-fee-Cna0j8C0.js +0 -1
- package/assets/eth_estimateGas-A7dV8Dq8.js +0 -1
- package/assets/eth_getStorageAt-DVqXAuzZ.js +0 -1
- package/assets/eth_getTransactionCount-DLrwUt6V.js +0 -1
- package/assets/extractIPFS-Dq1wghef.js +0 -1
- package/assets/fetchTokenMetadata-BTRazXId.js +0 -2
- package/assets/get-ecosystem-wallet-info-B8H2bbhI.js +0 -1
- package/assets/getBalance-BewKvJ6T.js +0 -2
- package/assets/getInstalledModules-ByFUGStC.js +0 -1
- package/assets/getNFT-1nUsfQAJ.js +0 -1
- package/assets/getNFT-BuDjU8-b.js +0 -2
- package/assets/import-CWsWpkUA.js +0 -1
- package/assets/in-app-wallet-calls-Fj_OJpWi.js +0 -1
- package/assets/index-B04ndUbB.js +0 -2
- package/assets/index-BBuZMaWr.js +0 -231
- package/assets/index-CzDOjIXr.js +0 -2
- package/assets/index-DH3Yzbz3.js +0 -1
- package/assets/index-Dhu9IXc1.js +0 -3
- package/assets/index-PISx9bvm.css +0 -1
- package/assets/index-nRbKhfJe.js +0 -2
- package/assets/index.es-CiHN99GO.js +0 -1
- package/assets/loader-logo-CK-TcJ-S.js +0 -1
- package/assets/openzeppelin-B2ua0Itn.js +0 -1
- package/assets/ownerOf-DOppg2jR.js +0 -1
- package/assets/parseNft-D_8M9mfO.js +0 -2
- package/assets/passkeys-CW4jmTtA.js +0 -1
- package/assets/resolveImplementation-06H3horI.js +0 -1
- package/assets/secp256k1-D6rN1PGV.js +0 -1
- package/assets/send-batch-transaction-Bbiva6rb.js +0 -1
- package/assets/send-eip712-transaction-NxK7USDp.js +0 -2
- package/assets/send-gasless-transaction-x5mofsoE.js +0 -2
- package/assets/session-proposal-KoaDAo-a.js +0 -1
- package/assets/session-request-CSef7ndM.js +0 -2
- package/assets/sha256-DkPvB4om.js +0 -1
- package/assets/signing-B9F_g0GG.js +0 -30
- package/assets/thirdweb-D99mQjH-.js +0 -27
- package/assets/totalSupply-BhpAtMjH.js +0 -1
- package/assets/trade-encoding-CWytSFjw.js +0 -1
- package/assets/transactionReceipt-OilL7-NS.js +0 -1
- package/assets/useInfiniteGrid-CpiD11c4.js +0 -1
- package/assets/useTheme-6tr3eE7K.js +0 -1
- package/assets/useTheme-Dpdkvivv.js +0 -1
- package/assets/wait-for-tx-receipt-Dt-8wYDQ.js +0 -1
- package/assets/wallet-kind-B9P1TeIH.js +0 -1
- package/assets/wallets-v6YyPYY8.js +0 -15
- package/assets/web-connector-DBKfHuJF.js +0 -9
|
@@ -0,0 +1,758 @@
|
|
|
1
|
+
import{u as Ke,r as p,j as e,a as Qe}from"./react-BMZSDQJw.js";import{c as F,o as Ze,k as Je,a2 as Xe,s,y as t,g as Ee,h as Ye,j as Te,al as Ie,t as o,I as T,l as B,n as pe,q as D,r as et,v as tt,u as Ne,z as nt,A as K,az as st,aA as ot}from"./index-Cw_zTgKJ.js";import{r as it,a as rt,m as Ae}from"./mana-rate-zpYtmb1D.js";import{u as _e,M as at}from"./MarketCheckout-CS9k9P56.js";import{g as lt,h as ct,i as dt,j as ft,k as pt,C as ut,l as xt,o as ht,m as mt,n as gt,M as bt}from"./Assets.styles-DD1YIA0w.js";import{d as ue,R as yt,F as wt,S as xe,b as jt}from"./categories-BltWZ-Er.js";import{L as vt}from"./LoadMore-kFcJ8c6R.js";import{u as $t}from"./useInfiniteGrid-CpG_Ao97.js";import{E as Ct}from"./ErrorNotice-DDr3KjIH.js";import{d as kt}from"./dcl-schemas-BICTSpB5.js";import{u as St,G as Rt,w as zt,S as Et}from"./buy-gasless-DbZJNUIF.js";import{s as Tt}from"./buy-B9BIW0Jt.js";import{j as It,s as Nt}from"./wallet-kind-Cg4yayUr.js";import{f as At}from"./errors-BrsnEff4.js";import{J as _t,C as Pt,B as ne}from"./ethers-CeDRuWE-.js";import{l as Mt}from"./loader-logo-BzY9EKdC.js";import{n as Lt}from"./emotion-CSxEP8yM.js";import"./sentry-8SzFotJj.js";import"./intl-CBcMB1D2.js";import"./index-HN6Rk25C.js";import"./Tooltip-zQgqv_WS.js";function Q(n){const i=n.source??"item",f=n.tradeId||`${n.contractAddress}-${n.tokenId??n.itemId??""}`;return`${i}:${f}`}const W="100000000000000000000",Pe=2,V=15,Bt=/^[a-zA-Z0-9]+$/;function he(n){const i=n.trim();return i.length===0?{ok:!1,reason:"empty"}:Bt.test(i)?i.length<Pe?{ok:!1,reason:"too-short"}:i.length>V?{ok:!1,reason:"too-long"}:{ok:!0}:{ok:!1,reason:"invalid-chars"}}function Ft(n){return n.replace(/[^a-zA-Z0-9]/g,"").slice(0,V)}const Wt=["function available(string _subdomain) view returns (bool)"],me={mainnet:{rpc:"https://rpc.decentraland.org/mainnet",address:"0x2a187453064356c898cae034eaed119e1663acb8"},sepolia:{rpc:"https://rpc.decentraland.org/sepolia",address:"0x7518456ae93eb98f3e64571b689c626616bb7f30"}};function Ht(){return F.chainId===kt.ChainId.MATIC_MAINNET?me.mainnet:me.sepolia}async function Ut(n,i={}){var d;const{rpc:f,address:u}=Ht(),l=new _t(f),c=new Pt(u,Wt,l);console.info(`[names] availability check → DCLRegistrar(${u}).available("${n}") on ${f}`);const x=await c.available(n);if((d=i.signal)!=null&&d.aborted)throw new DOMException("Aborted","AbortError");return console.info(`[names] "${n}" available=${x}`),x?"available":"taken"}const Ot="https://app.across.to/api";class Me extends Error{constructor(){super("Name registration is temporarily unavailable due to high network costs"),this.name="NameRouteCostTooHighError"}}function qt(n){return rt(W,n)}async function Gt(n,i,f={}){var d;const u=f.chainId??F.chainId,l=f.provider??"across",c=`${F.creditsServerUrl}/credits-name-route?name=${encodeURIComponent(i)}&chainId=${u}&provider=${l}`,x=await Xe(c,{method:"GET",identity:n,metadata:{}});if(!x.ok){let a;try{a=(d=await x.json())==null?void 0:d.code}catch{}throw a==="ROUTE_COST_TOO_HIGH"?new Me:new Error(`fetchNameCreditRoute ${x.status}`)}return x.json()}function Dt(n,i){const f=ne.from(n.availableAmount),l=ne.from(W).sub(f);return{credits:[{value:n.amount,expiresAt:Number(n.expiresAt),salt:It(n.id)}],creditsSignatures:[n.signature],externalCall:{target:i.externalCall.target,selector:i.externalCall.selector,data:i.externalCall.data,expiresAt:i.externalCall.expiresAt,salt:i.externalCall.salt},customExternalCallSignature:i.customExternalCallSignature,maxUncreditedValue:l.isNegative()?"0":l.toString(),maxCreditedValue:W}}async function Vt(n,i={}){const f=Ot,u=i.intervalMs??1e4,l=i.maxAttempts??60;let c={status:"pending",destinationTxHash:null,actionsSucceeded:!1};for(let x=0;x<l;x++){try{const d=await fetch(`${f}/deposit/status?originChainId=137&depositTxHash=${n}`);if(d.ok){const a=await d.json(),m=(a.status??"pending").toLowerCase(),w=a.fillTx??a.fillTxnRef??null,y=a.actionsSucceeded!==!1;if(m==="filled")return{status:"filled",destinationTxHash:w,actionsSucceeded:y};if(m==="refunded"||m==="expired")return{status:m,destinationTxHash:null,actionsSucceeded:!1};c={status:"pending",destinationTxHash:w,actionsSucceeded:y}}}catch{}x<l-1&&await new Promise(d=>setTimeout(d,u))}return c}async function Kt(n){const{name:i,identity:f,signer:u}=n,l=n.chainId??F.chainId,c=n.provider??"across",x=(n.beneficiary??await u.getAddress()).toLowerCase();let d=null,a=!1;console.info("[names] register start",{name:i,buyer:x,chainId:l,provider:c});try{const m=await it(l),w=qt(m);console.info("[names] step 1/6 sized reservation",{usdCents:w,manaRate:m});const y=await Gt(f,i,{chainId:l,provider:c});console.info("[names] step 2/6 route fetched",{target:y.externalCall.target,selector:y.externalCall.selector,provider:y.provider,quoteId:y.quoteId});const j=await Ze(f,w);if(d=j.credit.id,console.info("[names] step 3/6 credit authorized",{creditId:j.credit.id,maxCreditedValue:j.maxCreditedValue}),ne.from(j.maxCreditedValue).lt(W))throw new Error("Credit under-sized for the name price");const C=Dt(j.credit,y);let h;try{h=await St({chainId:l,buyer:x,signer:u,args:C})}catch(b){if(!(b instanceof Rt))throw b;h=await Tt(l,C,u)}if(console.info("[names] step 4/6 useCredits submitted (Polygon origin tx)",{originTxHash:h}),await zt(h),a=!0,console.info("[names] step 5/6 origin tx confirmed",{originTxHash:h}),c==="across"){const b=await Vt(h,n.acrossPoll);if(console.info("[names] step 6/6 across status",b),b.status==="pending")return{status:"pending",originTxHash:h};if(b.status!=="filled"||!b.actionsSucceeded)throw new Error("The name could not be registered on Ethereum; your funds were recovered.");return{status:"registered",originTxHash:h,destinationTxHash:b.destinationTxHash}}return{status:"pending",originTxHash:h}}catch(m){if(console.error("[names] register failed — raw error:",m,{name:i,buyer:x,originConfirmed:a}),m instanceof Et)return{status:"pending",originTxHash:m.txHash};throw d&&!a&&await Je(f,[d]).catch(()=>{}),m instanceof Me?m:new Error(At(m,"Couldn't register the name. Please try again.",{sale:!0}))}}const Qt=s.div`
|
|
2
|
+
position: fixed;
|
|
3
|
+
inset: 0;
|
|
4
|
+
z-index: 10000;
|
|
5
|
+
display: flex;
|
|
6
|
+
align-items: center;
|
|
7
|
+
justify-content: center;
|
|
8
|
+
padding: 16px;
|
|
9
|
+
background: rgba(22, 21, 24, 0.55);
|
|
10
|
+
`,Zt=s.div`
|
|
11
|
+
width: 560px;
|
|
12
|
+
max-width: 100%;
|
|
13
|
+
max-height: 92vh;
|
|
14
|
+
overflow-y: auto;
|
|
15
|
+
background: ${t.colors.white};
|
|
16
|
+
border-radius: 16px;
|
|
17
|
+
padding: 20px 24px 24px;
|
|
18
|
+
box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
|
|
19
|
+
|
|
20
|
+
${t.media.down("mobile")} {
|
|
21
|
+
padding: 16px;
|
|
22
|
+
}
|
|
23
|
+
`,ge=s.div`
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: flex-start;
|
|
26
|
+
justify-content: space-between;
|
|
27
|
+
gap: 12px;
|
|
28
|
+
`,be=s.h2`
|
|
29
|
+
margin: 0;
|
|
30
|
+
font-family: ${t.font.sans};
|
|
31
|
+
font-weight: 700;
|
|
32
|
+
font-size: 22px;
|
|
33
|
+
line-height: 1.2;
|
|
34
|
+
color: ${t.colors.text};
|
|
35
|
+
`,ye=s.button`
|
|
36
|
+
flex: none;
|
|
37
|
+
display: grid;
|
|
38
|
+
place-items: center;
|
|
39
|
+
width: 28px;
|
|
40
|
+
height: 28px;
|
|
41
|
+
border: 0;
|
|
42
|
+
background: none;
|
|
43
|
+
cursor: pointer;
|
|
44
|
+
color: ${t.colors.text};
|
|
45
|
+
|
|
46
|
+
.ico {
|
|
47
|
+
width: 18px;
|
|
48
|
+
height: 18px;
|
|
49
|
+
}
|
|
50
|
+
&:disabled {
|
|
51
|
+
opacity: 0.4;
|
|
52
|
+
cursor: default;
|
|
53
|
+
}
|
|
54
|
+
&:focus-visible {
|
|
55
|
+
outline: 2px solid ${t.colors.accent};
|
|
56
|
+
outline-offset: 2px;
|
|
57
|
+
}
|
|
58
|
+
`,we=s.div`
|
|
59
|
+
display: flex;
|
|
60
|
+
align-items: center;
|
|
61
|
+
gap: 6px;
|
|
62
|
+
margin-top: 4px;
|
|
63
|
+
font-family: ${t.font.sans};
|
|
64
|
+
font-size: 14px;
|
|
65
|
+
color: ${t.colors.text2};
|
|
66
|
+
|
|
67
|
+
.ico {
|
|
68
|
+
width: 16px;
|
|
69
|
+
height: 16px;
|
|
70
|
+
color: ${t.colors.brandViolet};
|
|
71
|
+
}
|
|
72
|
+
`,je=s.hr`
|
|
73
|
+
border: 0;
|
|
74
|
+
border-top: 1px solid ${t.colors.line};
|
|
75
|
+
margin: 16px 0;
|
|
76
|
+
`,ve=s.div`
|
|
77
|
+
display: flex;
|
|
78
|
+
align-items: center;
|
|
79
|
+
gap: 16px;
|
|
80
|
+
`,$e=s.div`
|
|
81
|
+
flex: none;
|
|
82
|
+
display: grid;
|
|
83
|
+
place-items: center;
|
|
84
|
+
width: 56px;
|
|
85
|
+
height: 56px;
|
|
86
|
+
border-radius: 10px;
|
|
87
|
+
background: ${t.gradients.amethyst};
|
|
88
|
+
color: ${t.colors.white};
|
|
89
|
+
|
|
90
|
+
.ico {
|
|
91
|
+
width: 30px;
|
|
92
|
+
height: 30px;
|
|
93
|
+
}
|
|
94
|
+
`,Ce=s.div`
|
|
95
|
+
flex: 1;
|
|
96
|
+
min-width: 0;
|
|
97
|
+
`,ke=s.div`
|
|
98
|
+
font-family: ${t.font.sans};
|
|
99
|
+
font-weight: 700;
|
|
100
|
+
font-size: 20px;
|
|
101
|
+
line-height: 1.3;
|
|
102
|
+
color: ${t.colors.text};
|
|
103
|
+
overflow: hidden;
|
|
104
|
+
text-overflow: ellipsis;
|
|
105
|
+
white-space: nowrap;
|
|
106
|
+
|
|
107
|
+
span {
|
|
108
|
+
font-weight: 400;
|
|
109
|
+
color: ${t.colors.muted2};
|
|
110
|
+
}
|
|
111
|
+
`,Se=s.div`
|
|
112
|
+
font-family: ${t.font.sans};
|
|
113
|
+
font-size: 14px;
|
|
114
|
+
color: ${t.colors.muted2};
|
|
115
|
+
`,Re=s.div`
|
|
116
|
+
flex: none;
|
|
117
|
+
display: flex;
|
|
118
|
+
align-items: center;
|
|
119
|
+
gap: 6px;
|
|
120
|
+
font-family: ${t.font.sans};
|
|
121
|
+
font-weight: 600;
|
|
122
|
+
font-size: 24px;
|
|
123
|
+
color: ${t.colors.text};
|
|
124
|
+
|
|
125
|
+
.ico {
|
|
126
|
+
width: 22px;
|
|
127
|
+
height: 22px;
|
|
128
|
+
color: ${t.colors.brandViolet};
|
|
129
|
+
}
|
|
130
|
+
`,Jt=s.div`
|
|
131
|
+
margin-top: 16px;
|
|
132
|
+
padding: 16px;
|
|
133
|
+
border-radius: 12px;
|
|
134
|
+
background: #f2e7fc;
|
|
135
|
+
`,Xt=s.div`
|
|
136
|
+
font-family: ${t.font.sans};
|
|
137
|
+
font-weight: 700;
|
|
138
|
+
font-size: 16px;
|
|
139
|
+
color: ${t.colors.text};
|
|
140
|
+
`,Yt=s.p`
|
|
141
|
+
margin: 8px 0 16px;
|
|
142
|
+
font-family: ${t.font.sans};
|
|
143
|
+
font-size: 14px;
|
|
144
|
+
line-height: 1.5;
|
|
145
|
+
color: ${t.colors.text2};
|
|
146
|
+
|
|
147
|
+
b {
|
|
148
|
+
font-weight: 700;
|
|
149
|
+
color: ${t.colors.brandViolet};
|
|
150
|
+
}
|
|
151
|
+
`,en=s.label`
|
|
152
|
+
display: flex;
|
|
153
|
+
align-items: center;
|
|
154
|
+
gap: 8px;
|
|
155
|
+
padding: 12px 14px;
|
|
156
|
+
background: ${t.colors.white};
|
|
157
|
+
border: 1px solid ${t.colors.text};
|
|
158
|
+
border-radius: 10px;
|
|
159
|
+
cursor: text;
|
|
160
|
+
|
|
161
|
+
&:focus-within {
|
|
162
|
+
border-color: ${t.colors.magenta};
|
|
163
|
+
}
|
|
164
|
+
`,tn=s.span`
|
|
165
|
+
flex: none;
|
|
166
|
+
font-family: ${t.font.sans};
|
|
167
|
+
font-size: 18px;
|
|
168
|
+
color: ${t.colors.muted2};
|
|
169
|
+
`,nn=s.input`
|
|
170
|
+
flex: 0 1 auto;
|
|
171
|
+
min-width: 0;
|
|
172
|
+
border: 0;
|
|
173
|
+
outline: none;
|
|
174
|
+
background: transparent;
|
|
175
|
+
font-family: ${t.font.sans};
|
|
176
|
+
font-size: 16px;
|
|
177
|
+
font-weight: 600;
|
|
178
|
+
color: ${t.colors.text};
|
|
179
|
+
|
|
180
|
+
&::placeholder {
|
|
181
|
+
color: #a09ba8;
|
|
182
|
+
font-weight: 400;
|
|
183
|
+
}
|
|
184
|
+
`,sn=s.span`
|
|
185
|
+
flex: none;
|
|
186
|
+
font-family: ${t.font.sans};
|
|
187
|
+
font-size: 16px;
|
|
188
|
+
color: ${t.colors.muted2};
|
|
189
|
+
`,ze=s.button`
|
|
190
|
+
margin-top: 16px;
|
|
191
|
+
width: 100%;
|
|
192
|
+
height: 52px;
|
|
193
|
+
border: 0;
|
|
194
|
+
border-radius: 12px;
|
|
195
|
+
cursor: pointer;
|
|
196
|
+
background: ${t.gradients.amethyst};
|
|
197
|
+
color: ${t.colors.softWhite};
|
|
198
|
+
font-family: ${t.font.sans};
|
|
199
|
+
font-weight: 600;
|
|
200
|
+
font-size: 15px;
|
|
201
|
+
letter-spacing: 0.46px;
|
|
202
|
+
text-transform: uppercase;
|
|
203
|
+
|
|
204
|
+
&:hover:not(:disabled) {
|
|
205
|
+
filter: brightness(1.06);
|
|
206
|
+
}
|
|
207
|
+
&:focus-visible {
|
|
208
|
+
outline: 2px solid ${t.colors.accent};
|
|
209
|
+
outline-offset: 2px;
|
|
210
|
+
}
|
|
211
|
+
&:disabled {
|
|
212
|
+
cursor: not-allowed;
|
|
213
|
+
background: #ddc7ec;
|
|
214
|
+
color: #f4ecfa;
|
|
215
|
+
}
|
|
216
|
+
`,on=s.div`
|
|
217
|
+
display: flex;
|
|
218
|
+
flex-direction: column;
|
|
219
|
+
align-items: flex-start;
|
|
220
|
+
gap: 20px;
|
|
221
|
+
padding: 32px 0 8px;
|
|
222
|
+
`,rn=s.img`
|
|
223
|
+
align-self: center;
|
|
224
|
+
width: 56px;
|
|
225
|
+
height: 56px;
|
|
226
|
+
`,an=s.div`
|
|
227
|
+
font-family: ${t.font.sans};
|
|
228
|
+
font-weight: 700;
|
|
229
|
+
font-size: 18px;
|
|
230
|
+
color: ${t.colors.text};
|
|
231
|
+
`,ln=s.div`
|
|
232
|
+
display: flex;
|
|
233
|
+
align-items: center;
|
|
234
|
+
gap: 12px;
|
|
235
|
+
width: 100%;
|
|
236
|
+
`,cn=s.div`
|
|
237
|
+
flex: 1;
|
|
238
|
+
height: 8px;
|
|
239
|
+
border-radius: 999px;
|
|
240
|
+
background: ${t.colors.chip};
|
|
241
|
+
overflow: hidden;
|
|
242
|
+
|
|
243
|
+
span {
|
|
244
|
+
display: block;
|
|
245
|
+
height: 100%;
|
|
246
|
+
width: 40%;
|
|
247
|
+
border-radius: 999px;
|
|
248
|
+
background: ${t.gradients.amethyst};
|
|
249
|
+
animation: nameProgress 1.1s ease-in-out infinite;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
@keyframes nameProgress {
|
|
253
|
+
0% {
|
|
254
|
+
transform: translateX(-100%);
|
|
255
|
+
}
|
|
256
|
+
100% {
|
|
257
|
+
transform: translateX(320%);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
`,dn=s.span`
|
|
261
|
+
flex: none;
|
|
262
|
+
font-family: ${t.font.sans};
|
|
263
|
+
font-size: 14px;
|
|
264
|
+
color: ${t.colors.muted};
|
|
265
|
+
`,fn=s.div`
|
|
266
|
+
display: flex;
|
|
267
|
+
flex-direction: column;
|
|
268
|
+
align-items: center;
|
|
269
|
+
gap: 16px;
|
|
270
|
+
padding: 24px;
|
|
271
|
+
border-radius: 12px;
|
|
272
|
+
background: #e2f5ea;
|
|
273
|
+
text-align: center;
|
|
274
|
+
`,pn=s.div`
|
|
275
|
+
display: grid;
|
|
276
|
+
place-items: center;
|
|
277
|
+
width: 56px;
|
|
278
|
+
height: 56px;
|
|
279
|
+
border-radius: 50%;
|
|
280
|
+
background: ${t.colors.ok};
|
|
281
|
+
color: ${t.colors.white};
|
|
282
|
+
|
|
283
|
+
.ico {
|
|
284
|
+
width: 30px;
|
|
285
|
+
height: 30px;
|
|
286
|
+
}
|
|
287
|
+
`,un=s.p`
|
|
288
|
+
margin: 0;
|
|
289
|
+
font-family: ${t.font.sans};
|
|
290
|
+
font-size: 16px;
|
|
291
|
+
line-height: 1.4;
|
|
292
|
+
color: ${t.colors.text};
|
|
293
|
+
|
|
294
|
+
b {
|
|
295
|
+
font-weight: 700;
|
|
296
|
+
}
|
|
297
|
+
`,xn=s.div`
|
|
298
|
+
display: flex;
|
|
299
|
+
gap: 16px;
|
|
300
|
+
margin-top: 20px;
|
|
301
|
+
|
|
302
|
+
${t.media.down("mobile")} {
|
|
303
|
+
flex-direction: column;
|
|
304
|
+
}
|
|
305
|
+
`,hn=s.button`
|
|
306
|
+
flex: 1;
|
|
307
|
+
height: 48px;
|
|
308
|
+
border: 1px solid ${t.colors.accent};
|
|
309
|
+
border-radius: 8px;
|
|
310
|
+
background: ${t.colors.white};
|
|
311
|
+
color: ${t.colors.accent};
|
|
312
|
+
cursor: pointer;
|
|
313
|
+
font-family: ${t.font.sans};
|
|
314
|
+
font-weight: 600;
|
|
315
|
+
font-size: 13px;
|
|
316
|
+
letter-spacing: 0.46px;
|
|
317
|
+
text-transform: uppercase;
|
|
318
|
+
|
|
319
|
+
&:hover {
|
|
320
|
+
background: rgba(105, 31, 169, 0.06);
|
|
321
|
+
}
|
|
322
|
+
&:focus-visible {
|
|
323
|
+
outline: 2px solid ${t.colors.accent};
|
|
324
|
+
outline-offset: 2px;
|
|
325
|
+
}
|
|
326
|
+
`,mn=s.a`
|
|
327
|
+
flex: 1;
|
|
328
|
+
display: inline-flex;
|
|
329
|
+
align-items: center;
|
|
330
|
+
justify-content: center;
|
|
331
|
+
height: 48px;
|
|
332
|
+
border-radius: 8px;
|
|
333
|
+
background: ${t.colors.dclRed};
|
|
334
|
+
color: ${t.colors.softWhite};
|
|
335
|
+
cursor: pointer;
|
|
336
|
+
text-decoration: none;
|
|
337
|
+
font-family: ${t.font.sans};
|
|
338
|
+
font-weight: 600;
|
|
339
|
+
font-size: 13px;
|
|
340
|
+
letter-spacing: 0.46px;
|
|
341
|
+
text-transform: uppercase;
|
|
342
|
+
|
|
343
|
+
&:hover {
|
|
344
|
+
filter: brightness(1.05);
|
|
345
|
+
}
|
|
346
|
+
&:focus-visible {
|
|
347
|
+
outline: 2px solid ${t.colors.accent};
|
|
348
|
+
outline-offset: 2px;
|
|
349
|
+
}
|
|
350
|
+
`,gn=s.div`
|
|
351
|
+
display: flex;
|
|
352
|
+
align-items: flex-start;
|
|
353
|
+
gap: 12px;
|
|
354
|
+
padding: 16px;
|
|
355
|
+
margin-top: 8px;
|
|
356
|
+
border-radius: 12px;
|
|
357
|
+
background: rgba(255, 45, 85, 0.1);
|
|
358
|
+
font-family: ${t.font.sans};
|
|
359
|
+
font-size: 14px;
|
|
360
|
+
line-height: 1.5;
|
|
361
|
+
color: ${t.colors.text};
|
|
362
|
+
|
|
363
|
+
.ico {
|
|
364
|
+
width: 22px;
|
|
365
|
+
height: 22px;
|
|
366
|
+
flex: none;
|
|
367
|
+
color: ${t.colors.dclRed};
|
|
368
|
+
}
|
|
369
|
+
`;function bn({name:n,priceCredits:i,onClose:f}){const{session:u}=Ee(),{data:l,isError:c}=Ye(u),x=Te(),d=Ke(),[a,m]=p.useState("confirm"),[w,y]=p.useState(""),[j,C]=p.useState(null),h=p.useRef(!1),b=w.trim().toLowerCase()===n.toLowerCase(),v=a==="completing",S=i!=null?Ie(i):"—";p.useEffect(()=>{const g=N=>{N.key==="Escape"&&!v&&f()};document.addEventListener("keydown",g);const H=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.removeEventListener("keydown",g),document.body.style.overflow=H}},[v,f]);async function k(){if(!(!u||!b||h.current)){h.current=!0,m("completing"),C(null);try{await Kt({name:n,identity:u.identity,signer:u.signer}),D("Shop Completed Purchase",{purchase_type:"name",is_primary:!0,payment_type:"credits",value_credits:i??null}),x.invalidateQueries({queryKey:["usd-balance"]}),m("success")}catch(g){D(tt(g)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"submit",error_code:et(g),purchase_type:"name"}),C((g==null?void 0:g.message)||o("names.errorGeneric")),m("error")}finally{h.current=!1}}}const I=a!=="success",R=Nt(u==null?void 0:u.providerType);return e.jsx(Qt,{onClick:v?void 0:f,role:"presentation",children:e.jsxs(Zt,{role:"dialog","aria-modal":"true","aria-label":o("names.buyTitle"),onClick:g=>g.stopPropagation(),children:[I&&e.jsxs(e.Fragment,{children:[e.jsxs(ge,{children:[e.jsx(be,{children:a==="error"?o("names.errorTitle"):o("names.buyTitle")}),e.jsx(ye,{onClick:f,disabled:v,"aria-label":o("buyModal.close"),children:e.jsx(T,{name:"close"})})]}),e.jsxs(we,{children:[o("names.myCreditsBalance")," ",e.jsx(B,{})," ",pe(l,c)]}),e.jsx(je,{})]}),(a==="confirm"||a==="error")&&e.jsxs(e.Fragment,{children:[e.jsxs(ve,{children:[e.jsx($e,{"aria-hidden":!0,children:"@"}),e.jsxs(Ce,{children:[e.jsxs(ke,{children:[n,e.jsx("span",{children:".dcl.eth"})]}),e.jsx(Se,{children:o("names.subtitle")})]}),e.jsxs(Re,{children:[e.jsx(B,{}),S]})]}),a==="error"?e.jsxs(e.Fragment,{children:[e.jsxs(gn,{children:[e.jsx(T,{name:"info","aria-hidden":!0}),e.jsx("span",{children:j})]}),e.jsx(ze,{onClick:()=>m("confirm"),children:o("names.tryAgain")})]}):e.jsxs(e.Fragment,{children:[e.jsxs(Jt,{children:[e.jsx(Xt,{children:o("names.confirmTitle")}),e.jsx(Yt,{dangerouslySetInnerHTML:{__html:o("names.confirmBody",{name:`<b>@${yn(n)}</b>`})}}),e.jsxs(en,{children:[e.jsx(tn,{"aria-hidden":!0,children:"@"}),e.jsx(nn,{value:w,onChange:g=>y(g.target.value.replace(/[^a-zA-Z0-9]/g,"")),placeholder:"yourname","aria-label":o("names.reenterAria"),autoComplete:"off",spellCheck:!1,style:{width:`${Math.max(w.length,8)}ch`}}),e.jsx(sn,{children:".dcl.eth"})]})]}),e.jsx(ze,{onClick:()=>void k(),disabled:!b||!u,children:o("names.buyCta")})]})]}),a==="completing"&&e.jsxs(on,{children:[e.jsx(rn,{src:Mt,alt:"",width:56,height:56}),e.jsx(an,{children:R?o("names.confirming"):o("names.completing")}),e.jsxs(ln,{children:[e.jsx(cn,{"aria-hidden":!0,children:e.jsx("span",{})}),e.jsx(dn,{children:"1/1"})]})]}),a==="success"&&e.jsxs(e.Fragment,{children:[e.jsxs(ge,{children:[e.jsx(be,{children:o("names.successHeaderTitle")}),e.jsx(ye,{onClick:f,"aria-label":o("buyModal.close"),children:e.jsx(T,{name:"close"})})]}),e.jsxs(we,{children:[o("names.myCreditsBalance")," ",e.jsx(B,{})," ",pe(l,c)]}),e.jsx(je,{}),e.jsxs(fn,{children:[e.jsx(pn,{"aria-hidden":!0,children:e.jsx(T,{name:"check"})}),e.jsxs(un,{children:[e.jsx("b",{children:o("names.successBannerBold")})," ",o("names.successBannerRest")]})]}),e.jsxs(ve,{style:{marginTop:20},children:[e.jsx($e,{"aria-hidden":!0,children:"@"}),e.jsxs(Ce,{children:[e.jsxs(ke,{children:[n,e.jsx("span",{children:".dcl.eth"})]}),e.jsx(Se,{children:o("names.subtitle")})]}),e.jsxs(Re,{children:[e.jsx(B,{}),S]})]}),e.jsxs(xn,{children:[e.jsx(hn,{onClick:()=>{f(),d("/my-assets")},children:o("names.myItems")}),e.jsx(mn,{href:F.profileUrl,target:"_blank",rel:"noopener noreferrer",children:o("names.assignToAvatar")})]})]})]})})}function yn(n){return n.replace(/[&<>"']/g,i=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[i])}const wn=s.div`
|
|
370
|
+
width: 100%;
|
|
371
|
+
min-width: 0;
|
|
372
|
+
`,jn=s.nav`
|
|
373
|
+
display: flex;
|
|
374
|
+
align-items: center;
|
|
375
|
+
gap: 6px;
|
|
376
|
+
margin: 4px 0 16px;
|
|
377
|
+
font-family: ${t.font.sans};
|
|
378
|
+
font-size: 12px;
|
|
379
|
+
line-height: 1;
|
|
380
|
+
color: ${t.colors.muted};
|
|
381
|
+
`,vn=s.button`
|
|
382
|
+
border: 0;
|
|
383
|
+
background: none;
|
|
384
|
+
padding: 0;
|
|
385
|
+
cursor: pointer;
|
|
386
|
+
font: inherit;
|
|
387
|
+
color: ${t.colors.muted};
|
|
388
|
+
|
|
389
|
+
&:hover {
|
|
390
|
+
text-decoration: underline;
|
|
391
|
+
}
|
|
392
|
+
&:focus-visible {
|
|
393
|
+
outline: 2px solid ${t.colors.accent};
|
|
394
|
+
outline-offset: 2px;
|
|
395
|
+
}
|
|
396
|
+
`,$n=s.span`
|
|
397
|
+
font-weight: 700;
|
|
398
|
+
color: ${t.colors.muted};
|
|
399
|
+
`,Cn=s.div`
|
|
400
|
+
display: flex;
|
|
401
|
+
flex-direction: column;
|
|
402
|
+
gap: 48px;
|
|
403
|
+
padding-bottom: 48px;
|
|
404
|
+
background: #ecdbfd;
|
|
405
|
+
border-radius: ${t.radius.banner};
|
|
406
|
+
overflow: hidden;
|
|
407
|
+
|
|
408
|
+
${t.media.down("mobile")} {
|
|
409
|
+
gap: 32px;
|
|
410
|
+
padding-bottom: 32px;
|
|
411
|
+
}
|
|
412
|
+
`,kn=s.div`
|
|
413
|
+
position: relative;
|
|
414
|
+
border-radius: ${t.radius.banner};
|
|
415
|
+
overflow: hidden;
|
|
416
|
+
padding: 88px 48px;
|
|
417
|
+
display: flex;
|
|
418
|
+
flex-direction: column;
|
|
419
|
+
align-items: center;
|
|
420
|
+
gap: 48px;
|
|
421
|
+
text-align: center;
|
|
422
|
+
background: radial-gradient(120% 95% at 50% 118%, #d13bd6 0%, #a026b0 28%, #6a1b9c 58%, #4a1173 100%);
|
|
423
|
+
|
|
424
|
+
${t.media.down("mobile")} {
|
|
425
|
+
padding: 40px 20px;
|
|
426
|
+
gap: 28px;
|
|
427
|
+
}
|
|
428
|
+
`,Sn=s.div`
|
|
429
|
+
display: flex;
|
|
430
|
+
flex-direction: column;
|
|
431
|
+
align-items: center;
|
|
432
|
+
gap: 12px;
|
|
433
|
+
`,Rn=s.h1`
|
|
434
|
+
margin: 0;
|
|
435
|
+
font-family: ${t.font.sans};
|
|
436
|
+
font-weight: 600;
|
|
437
|
+
font-size: 40px;
|
|
438
|
+
line-height: 1.167;
|
|
439
|
+
color: ${t.colors.white};
|
|
440
|
+
|
|
441
|
+
${t.media.down("mobile")} {
|
|
442
|
+
font-size: 26px;
|
|
443
|
+
}
|
|
444
|
+
`,zn=s.p`
|
|
445
|
+
margin: 0;
|
|
446
|
+
max-width: 760px;
|
|
447
|
+
font-family: ${t.font.sans};
|
|
448
|
+
font-weight: 500;
|
|
449
|
+
font-size: 24px;
|
|
450
|
+
line-height: 1.334;
|
|
451
|
+
color: #ecebed;
|
|
452
|
+
|
|
453
|
+
${t.media.down("mobile")} {
|
|
454
|
+
font-size: 16px;
|
|
455
|
+
}
|
|
456
|
+
`,En=s.div`
|
|
457
|
+
width: min(785px, 100%);
|
|
458
|
+
display: flex;
|
|
459
|
+
flex-direction: column;
|
|
460
|
+
gap: 12px;
|
|
461
|
+
`,Tn=s.div`
|
|
462
|
+
position: relative;
|
|
463
|
+
`,In=s("div",Lt("invalid"))`
|
|
464
|
+
display: flex;
|
|
465
|
+
align-items: center;
|
|
466
|
+
gap: 8px;
|
|
467
|
+
padding: 8px 8px 8px 16px;
|
|
468
|
+
background: ${t.colors.softWhite};
|
|
469
|
+
border: 1.5px solid ${({invalid:n})=>n?"#ff2d55":t.colors.line};
|
|
470
|
+
border-radius: 20px;
|
|
471
|
+
|
|
472
|
+
&:focus-within {
|
|
473
|
+
border-color: ${({invalid:n})=>n?"#ff2d55":t.colors.magenta};
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
${t.media.down("mobile")} {
|
|
477
|
+
border-radius: 16px;
|
|
478
|
+
}
|
|
479
|
+
`,Nn=s.span`
|
|
480
|
+
position: absolute;
|
|
481
|
+
left: -9999px;
|
|
482
|
+
top: 0;
|
|
483
|
+
visibility: hidden;
|
|
484
|
+
pointer-events: none;
|
|
485
|
+
white-space: pre;
|
|
486
|
+
font-family: ${t.font.sans};
|
|
487
|
+
font-size: 20px;
|
|
488
|
+
font-weight: 600;
|
|
489
|
+
line-height: 1.6;
|
|
490
|
+
|
|
491
|
+
${t.media.down("mobile")} {
|
|
492
|
+
font-size: 16px;
|
|
493
|
+
}
|
|
494
|
+
`,An=s.div`
|
|
495
|
+
position: absolute;
|
|
496
|
+
top: calc(100% + 8px);
|
|
497
|
+
left: 0;
|
|
498
|
+
right: 0;
|
|
499
|
+
z-index: 2;
|
|
500
|
+
display: flex;
|
|
501
|
+
align-items: center;
|
|
502
|
+
gap: 8px;
|
|
503
|
+
padding: 8px 12px;
|
|
504
|
+
border-radius: 8px;
|
|
505
|
+
background: #ffcdd4;
|
|
506
|
+
color: #ec303a;
|
|
507
|
+
font-family: ${t.font.sans};
|
|
508
|
+
font-size: 14px;
|
|
509
|
+
font-weight: 500;
|
|
510
|
+
line-height: 1.2;
|
|
511
|
+
text-align: left;
|
|
512
|
+
|
|
513
|
+
${t.media.down("mobile")} {
|
|
514
|
+
position: static;
|
|
515
|
+
margin-top: 8px;
|
|
516
|
+
align-items: flex-start;
|
|
517
|
+
flex-wrap: wrap;
|
|
518
|
+
}
|
|
519
|
+
`,_n=s.a`
|
|
520
|
+
display: inline-flex;
|
|
521
|
+
align-items: center;
|
|
522
|
+
gap: 2px;
|
|
523
|
+
margin-left: auto;
|
|
524
|
+
color: #ec303a;
|
|
525
|
+
font-weight: 600;
|
|
526
|
+
text-decoration: underline;
|
|
527
|
+
text-transform: uppercase;
|
|
528
|
+
white-space: nowrap;
|
|
529
|
+
|
|
530
|
+
${t.media.down("mobile")} {
|
|
531
|
+
margin-left: 0;
|
|
532
|
+
}
|
|
533
|
+
`,Pn=s.label`
|
|
534
|
+
flex: 1;
|
|
535
|
+
min-width: 0;
|
|
536
|
+
display: flex;
|
|
537
|
+
align-items: center;
|
|
538
|
+
gap: 0;
|
|
539
|
+
cursor: text;
|
|
540
|
+
overflow: hidden;
|
|
541
|
+
`,Mn=s.span`
|
|
542
|
+
flex: none;
|
|
543
|
+
margin-right: 8px;
|
|
544
|
+
font-family: ${t.font.sans};
|
|
545
|
+
font-size: 26px;
|
|
546
|
+
font-weight: 500;
|
|
547
|
+
line-height: 1;
|
|
548
|
+
color: #a09ba8;
|
|
549
|
+
|
|
550
|
+
${t.media.down("mobile")} {
|
|
551
|
+
font-size: 20px;
|
|
552
|
+
}
|
|
553
|
+
`,Ln=s.input`
|
|
554
|
+
flex: 0 1 auto;
|
|
555
|
+
min-width: 0;
|
|
556
|
+
max-width: 100%;
|
|
557
|
+
border: 0;
|
|
558
|
+
outline: none;
|
|
559
|
+
background: transparent;
|
|
560
|
+
font-family: ${t.font.sans};
|
|
561
|
+
font-size: 20px;
|
|
562
|
+
font-weight: 600;
|
|
563
|
+
line-height: 1.6;
|
|
564
|
+
color: ${t.colors.text};
|
|
565
|
+
padding: 0;
|
|
566
|
+
|
|
567
|
+
&::placeholder {
|
|
568
|
+
color: #5e5b67;
|
|
569
|
+
font-weight: 400;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
${t.media.down("mobile")} {
|
|
573
|
+
font-size: 16px;
|
|
574
|
+
}
|
|
575
|
+
`,Bn=s.span`
|
|
576
|
+
flex: none;
|
|
577
|
+
margin-left: 2px;
|
|
578
|
+
font-family: ${t.font.sans};
|
|
579
|
+
font-size: 20px;
|
|
580
|
+
font-weight: 400;
|
|
581
|
+
line-height: 1.6;
|
|
582
|
+
color: #5e5b67;
|
|
583
|
+
|
|
584
|
+
${t.media.down("mobile")} {
|
|
585
|
+
font-size: 16px;
|
|
586
|
+
}
|
|
587
|
+
`,Fn=s.span`
|
|
588
|
+
flex: none;
|
|
589
|
+
font-family: ${t.font.sans};
|
|
590
|
+
font-size: 13px;
|
|
591
|
+
color: #a09ba8;
|
|
592
|
+
white-space: nowrap;
|
|
593
|
+
`,Le=s.button`
|
|
594
|
+
flex: none;
|
|
595
|
+
display: inline-flex;
|
|
596
|
+
align-items: center;
|
|
597
|
+
justify-content: center;
|
|
598
|
+
gap: 8px;
|
|
599
|
+
height: 52px;
|
|
600
|
+
padding: 0 24px;
|
|
601
|
+
border: 0;
|
|
602
|
+
border-radius: 12px;
|
|
603
|
+
cursor: pointer;
|
|
604
|
+
background: ${t.gradients.cerise};
|
|
605
|
+
color: ${t.colors.softWhite};
|
|
606
|
+
font-family: ${t.font.sans};
|
|
607
|
+
font-weight: 600;
|
|
608
|
+
font-size: 15px;
|
|
609
|
+
letter-spacing: 0.46px;
|
|
610
|
+
line-height: 24px;
|
|
611
|
+
text-transform: uppercase;
|
|
612
|
+
|
|
613
|
+
&:hover:not(:disabled) {
|
|
614
|
+
filter: brightness(1.05);
|
|
615
|
+
}
|
|
616
|
+
&:focus-visible {
|
|
617
|
+
outline: 2px solid ${t.colors.white};
|
|
618
|
+
outline-offset: 2px;
|
|
619
|
+
}
|
|
620
|
+
&:disabled {
|
|
621
|
+
cursor: not-allowed;
|
|
622
|
+
background: #e7c8e9;
|
|
623
|
+
color: #fbe9fb;
|
|
624
|
+
}
|
|
625
|
+
|
|
626
|
+
${t.media.down("mobile")} {
|
|
627
|
+
display: none;
|
|
628
|
+
}
|
|
629
|
+
`,Wn=s(Le)`
|
|
630
|
+
display: none;
|
|
631
|
+
|
|
632
|
+
${t.media.down("mobile")} {
|
|
633
|
+
display: inline-flex;
|
|
634
|
+
width: 100%;
|
|
635
|
+
height: 48px;
|
|
636
|
+
border-radius: 12px;
|
|
637
|
+
}
|
|
638
|
+
`,Hn=s.span`
|
|
639
|
+
display: inline-flex;
|
|
640
|
+
align-items: center;
|
|
641
|
+
gap: 4px;
|
|
642
|
+
font-weight: 600;
|
|
643
|
+
|
|
644
|
+
.ico {
|
|
645
|
+
width: 16px;
|
|
646
|
+
height: 16px;
|
|
647
|
+
}
|
|
648
|
+
`,Z=s.div`
|
|
649
|
+
display: flex;
|
|
650
|
+
align-items: center;
|
|
651
|
+
gap: 8px;
|
|
652
|
+
padding: 8px 14px;
|
|
653
|
+
border-radius: 8px;
|
|
654
|
+
font-family: ${t.font.sans};
|
|
655
|
+
font-size: 13px;
|
|
656
|
+
font-weight: 500;
|
|
657
|
+
text-align: left;
|
|
658
|
+
|
|
659
|
+
background: ${({tone:n})=>n==="error"?"rgba(255, 45, 85, 0.12)":n==="ok"?"rgba(30, 166, 114, 0.14)":"rgba(255,255,255,0.14)"};
|
|
660
|
+
color: ${({tone:n})=>n==="error"?"#ff2d55":n==="ok"?"#0f7a4f":"#ecebed"};
|
|
661
|
+
|
|
662
|
+
.ico {
|
|
663
|
+
width: 16px;
|
|
664
|
+
height: 16px;
|
|
665
|
+
flex: none;
|
|
666
|
+
}
|
|
667
|
+
`,Un=s.section`
|
|
668
|
+
display: flex;
|
|
669
|
+
flex-direction: column;
|
|
670
|
+
gap: 48px;
|
|
671
|
+
padding: 0 48px;
|
|
672
|
+
|
|
673
|
+
${t.media.down("mobile")} {
|
|
674
|
+
gap: 24px;
|
|
675
|
+
padding: 0 20px;
|
|
676
|
+
}
|
|
677
|
+
`,On=s.h2`
|
|
678
|
+
margin: 0;
|
|
679
|
+
text-align: center;
|
|
680
|
+
font-family: ${t.font.sans};
|
|
681
|
+
font-weight: 600;
|
|
682
|
+
font-size: 32px;
|
|
683
|
+
line-height: 1.167;
|
|
684
|
+
color: ${t.colors.text2};
|
|
685
|
+
|
|
686
|
+
${t.media.down("mobile")} {
|
|
687
|
+
font-size: 22px;
|
|
688
|
+
}
|
|
689
|
+
`,qn=s.div`
|
|
690
|
+
display: flex;
|
|
691
|
+
gap: 48px;
|
|
692
|
+
align-items: stretch;
|
|
693
|
+
|
|
694
|
+
${t.media.down("mobile")} {
|
|
695
|
+
flex-direction: column;
|
|
696
|
+
gap: 24px;
|
|
697
|
+
}
|
|
698
|
+
`,J=s.article`
|
|
699
|
+
flex: 1 0 0;
|
|
700
|
+
min-width: 0;
|
|
701
|
+
display: flex;
|
|
702
|
+
flex-direction: column;
|
|
703
|
+
height: 340px;
|
|
704
|
+
background: ${t.colors.white};
|
|
705
|
+
border: 0.25px solid ${t.colors.muted2};
|
|
706
|
+
border-radius: ${t.radius.card};
|
|
707
|
+
overflow: hidden;
|
|
708
|
+
`,X=s.div`
|
|
709
|
+
flex: 1 0 0;
|
|
710
|
+
min-height: 0;
|
|
711
|
+
background: linear-gradient(135deg, #7a1fa2 0%, #c640cd 55%, #ff2d55 100%);
|
|
712
|
+
`,Y=s.div`
|
|
713
|
+
flex: none;
|
|
714
|
+
height: 96px;
|
|
715
|
+
display: flex;
|
|
716
|
+
flex-direction: column;
|
|
717
|
+
justify-content: space-between;
|
|
718
|
+
padding: 8px;
|
|
719
|
+
`,ee=s.p`
|
|
720
|
+
margin: 0;
|
|
721
|
+
font-family: ${t.font.sans};
|
|
722
|
+
font-weight: 600;
|
|
723
|
+
font-size: 14px;
|
|
724
|
+
line-height: 1.57;
|
|
725
|
+
color: ${t.colors.text};
|
|
726
|
+
`,Gn=s.a`
|
|
727
|
+
display: inline-flex;
|
|
728
|
+
align-items: center;
|
|
729
|
+
gap: 4px;
|
|
730
|
+
font-family: ${t.font.sans};
|
|
731
|
+
font-weight: 500;
|
|
732
|
+
font-size: 14px;
|
|
733
|
+
line-height: 30px;
|
|
734
|
+
color: ${t.colors.accent};
|
|
735
|
+
text-decoration: underline;
|
|
736
|
+
|
|
737
|
+
.ico {
|
|
738
|
+
width: 13px;
|
|
739
|
+
height: 13px;
|
|
740
|
+
}
|
|
741
|
+
`,Dn=s.span`
|
|
742
|
+
font-family: ${t.font.sans};
|
|
743
|
+
font-weight: 500;
|
|
744
|
+
font-size: 14px;
|
|
745
|
+
line-height: 30px;
|
|
746
|
+
color: ${t.colors.accent};
|
|
747
|
+
text-decoration: underline;
|
|
748
|
+
`,Vn=s.span`
|
|
749
|
+
position: absolute;
|
|
750
|
+
width: 1px;
|
|
751
|
+
height: 1px;
|
|
752
|
+
padding: 0;
|
|
753
|
+
margin: -1px;
|
|
754
|
+
overflow: hidden;
|
|
755
|
+
clip: rect(0, 0, 0, 0);
|
|
756
|
+
white-space: nowrap;
|
|
757
|
+
border: 0;
|
|
758
|
+
`,Kn="https://docs.decentraland.org/creator/worlds/about/";function Qn(n){const i=typeof window<"u"?window.location.hostname:"";return`${i.endsWith("decentraland.org")?"https://decentraland.org":i.endsWith("decentraland.today")?"https://decentraland.today":"https://decentraland.zone"}/marketplace/names/browse?search=${encodeURIComponent(n)}`}function Zn({onBack:n}){Ne({title:o("seo.names.title"),description:o("seo.names.description")});const{session:i,signIn:f}=Ee(),{data:u}=_e(),l=u?Ae(W,u):null,[c,x]=p.useState(""),[d,a]=p.useState("idle"),[m,w]=p.useState(!1),y=p.useRef(null),[j,C]=p.useState(void 0);p.useLayoutEffect(()=>{y.current&&C(y.current.offsetWidth)},[c]),p.useEffect(()=>{if(!he(c).ok){a(c.length===0?"idle":"invalid");return}a("checking");const I=new AbortController,R=setTimeout(()=>{(async()=>{try{const g=await Ut(c,{signal:I.signal});a(g)}catch(g){if((g==null?void 0:g.name)==="AbortError")return;a("error")}})()},400);return()=>{clearTimeout(R),I.abort()}},[c]);const h=he(c),b=h.ok&&(d==="available"||d==="error");function v(){if(b){if(!i){f();return}w(!0)}}const S=e.jsxs(e.Fragment,{children:[o("names.claim"),l!=null?e.jsxs(Hn,{children:[e.jsx(B,{}),Ie(l)]}):null]});return e.jsxs(wn,{"data-testid":"names-page",children:[e.jsxs(jn,{"aria-label":o("names.breadcrumbAria"),children:[e.jsx(vn,{onClick:n,children:o("names.breadcrumbCollectibles")}),e.jsx("span",{"aria-hidden":!0,children:">"}),e.jsx($n,{children:o("names.breadcrumbCurrent")})]}),e.jsxs(Cn,{children:[e.jsxs(kn,{children:[e.jsxs(Sn,{children:[e.jsx(Rn,{children:o("names.heroTitle")}),e.jsx(zn,{children:o("names.heroSubtitle")})]}),e.jsxs(En,{children:[e.jsxs(Tn,{children:[e.jsxs(In,{invalid:d==="taken",children:[e.jsxs(Pn,{children:[e.jsx(Mn,{"aria-hidden":!0,children:"@"}),e.jsx(Ln,{value:c,onChange:k=>x(Ft(k.target.value)),placeholder:o("names.inputPlaceholder"),"aria-label":o("names.inputAria"),autoComplete:"off",spellCheck:!1,maxLength:V,style:{width:j!=null?`${j}px`:void 0}}),e.jsx(Nn,{ref:y,"aria-hidden":!0,children:c||o("names.inputPlaceholder")}),e.jsx(Bn,{children:o("names.suffix")})]}),c.length>0?e.jsxs(Fn,{"aria-hidden":!0,children:[c.length,"/",V]}):null,e.jsx(Le,{onClick:v,disabled:!b,"data-testid":"names-claim",children:S})]}),d==="taken"?e.jsxs(An,{role:"status","data-testid":"names-taken",children:[e.jsx(T,{name:"info",size:16,"aria-hidden":!0}),e.jsx("span",{children:o("names.taken")}),e.jsxs(_n,{href:Qn(c),target:"_blank",rel:"noopener noreferrer",children:[o("names.takenMakeOffer"),e.jsx(T,{name:"external-link",size:13,"aria-hidden":!0})]})]}):null]}),e.jsx(Wn,{onClick:v,disabled:!b,children:S}),d==="checking"?e.jsx(Z,{tone:"muted",role:"status","data-testid":"names-checking",children:o("names.checking")}):d==="error"?e.jsx(Z,{tone:"muted",role:"status",children:o("names.checkError")}):d==="invalid"&&!h.ok&&h.reason==="too-short"?e.jsx(Z,{tone:"muted",role:"status",children:o("names.tooShort",{min:Pe})}):null,e.jsx(Vn,{role:"status","aria-live":"polite",children:d==="available"?o("names.available",{name:c}):""})]})]}),e.jsxs(Un,{children:[e.jsx(On,{children:o("names.whyTitle")}),e.jsxs(qn,{children:[e.jsxs(J,{children:[e.jsx(X,{"aria-hidden":!0}),e.jsx(Y,{children:e.jsx(ee,{children:o("names.why1")})})]}),e.jsxs(J,{children:[e.jsx(X,{"aria-hidden":!0}),e.jsxs(Y,{children:[e.jsx(ee,{children:o("names.why2")}),e.jsxs(Gn,{href:Kn,target:"_blank",rel:"noopener noreferrer",children:[o("names.why2Link"),e.jsx(T,{name:"external-link","aria-hidden":!0})]})]})]}),e.jsxs(J,{children:[e.jsx(X,{"aria-hidden":!0}),e.jsxs(Y,{children:[e.jsx(ee,{children:o("names.why3")}),e.jsx(Dn,{children:o("names.why3Link")})]})]})]})]})]}),m?e.jsx(bn,{name:c,priceCredits:l,onClose:()=>w(!1)}):null]})}const te=48;function Jn(n){return{tradeId:n.tradeId??n.id,listingType:"primary",contractAddress:n.contractAddress,itemId:n.itemId??"",name:n.name,thumbnail:n.thumbnail,rarity:n.rarity,category:n.category,wearableCategory:n.wearableCategory??null,creator:n.creator,manaWei:n.manaWei??"0",available:1,network:n.network,chainId:n.chainId,createdAt:0}}function ys(){const[n]=Qe(),i=(n.get("q")??"").trim().toLowerCase(),f=Te(),u=(n.get("q")??"").trim();Ne({title:u?o("seo.collectibles.searchTitle",{query:u}):o("seo.collectibles.title"),description:o("seo.collectibles.description")});const[l,c]=p.useState("wearable"),[x,d]=p.useState(null),[a,m]=p.useState([]),[w,y]=p.useState(""),[j,C]=p.useState(""),[h,b]=p.useState("on_sale"),[v,S]=p.useState(!1),[k,I]=p.useState("newest"),[R,g]=p.useState(!1),[H,N]=p.useState(null);p.useEffect(()=>{if(!R)return;const r=L=>{L.key==="Escape"&&g(!1)};document.addEventListener("keydown",r);const $=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.removeEventListener("keydown",r),document.body.style.overflow=$}},[R]);const U=h==="on_sale",A=w&&!Number.isNaN(Number(w))?Number(w):void 0,_=j&&!Number.isNaN(Number(j))?Number(j):void 0,se=x?jt[x]:void 0,oe=(ue.find(r=>r.key===k)??ue[0]).server,ie={category:l,rarities:a.length?a:void 0,wearableCategories:se,minPriceCredits:A,maxPriceCredits:_,search:i||void 0,sortBy:oe,isSmart:v||void 0,onSale:!0},re={category:l,rarities:a.length?a:void 0,wearableCategories:se,search:i||void 0,sortBy:oe,isWearableSmart:v||void 0,isOnSale:h==="not_for_sale"?!1:void 0},{items:P,total:ae,isLoading:z,isPlaceholderData:E,error:Be,hasNextPage:Fe,isFetchingNextPage:le,fetchNextPage:We}=$t(U?["unified-listings",ie]:["catalog-items",re],r=>U?st({...ie,first:te,skip:r}):ot({...re,first:te,skip:r}),{enabled:l!=="names"}),O=ae,He=z||E,Ue=z?15:Math.min(Math.max(P.length,1),te),{data:q,isError:Oe}=_e(),qe=r=>q&&r.manaWei?Ae(r.manaWei,q):null,ce=p.useRef(null);p.useEffect(()=>{z||E||!i||ce.current===i||(ce.current=i,D("Shop Searched",{query:i,result_count:O}))},[i,z,E,O]);const G=p.useRef("__init__");p.useEffect(()=>{if(z||E)return;const r=JSON.stringify({category:l,subCategory:x,rarities:a,min:A,max:_,sort:k,status:h,smart:v});if(G.current==="__init__"||G.current===r){G.current=r;return}G.current=r,D("Shop Applied Filter",{filters:{category:l,sub_category:x,rarities:a,min_price_credits:A??null,max_price_credits:_??null,status:h,smart:v,sort:k},result_count:O})},[l,x,a,A,_,k,h,v,z,E,O]);function de(r){c(r),d(null)}function fe(r){m($=>$.includes(r)?$.filter(L=>L!==r):[...$,r])}function Ge(){c("wearable"),d(null),m([]),y(""),C(""),b("on_sale"),S(!1)}function De(r){const $=P.find(L=>L.id===r.id);$&&$.source==="legacy"&&$.manaWei&&N(Jn($))}function Ve(){f.invalidateQueries({queryKey:["unified-listings"]})}const M=[];(A!=null||_!=null)&&M.push({key:"price",label:o("filter.price"),onRemove:()=>{y(""),C("")}});for(const r of yt)a.includes(r)&&M.push({key:`rarity-${r}`,label:nt(r),onRemove:()=>fe(r)});return v&&M.push({key:"smart",label:o("filter.smart"),onRemove:()=>S(!1)}),h!=="on_sale"&&M.push({key:"status",label:h==="all"?o("filter.statusAll"):o("filter.notForSale"),onRemove:()=>b("on_sale")}),e.jsxs(lt,{"data-testid":"browse",children:[l!=="names"&&e.jsxs(e.Fragment,{children:[R?e.jsx(ct,{onClick:()=>g(!1),"aria-hidden":!0}):null,e.jsxs(dt,{className:R?"is-open":"","data-testid":"browse-sidebar",children:[e.jsxs(ft,{children:[e.jsx(pt,{children:o("assets.filters")}),e.jsx(ut,{onClick:()=>g(!1),"aria-label":o("assets.closeFilters"),children:"✕"})]}),e.jsx(xt,{children:e.jsx(ht,{category:l,subCategory:x,onCategory:de,onSub:d,priceMin:w,priceMax:j,onPriceMin:y,onPriceMax:C,rarities:a,onToggleRarity:fe,status:h,onStatus:b,smart:v,onSmart:S})}),e.jsx(mt,{children:e.jsx(gt,{type:"button",onClick:()=>g(!1),children:o("assets.showItems")})})]})]}),e.jsx(bt,{children:l==="names"?e.jsx(Zn,{onBack:()=>de("wearable")}):e.jsxs(e.Fragment,{children:[e.jsx(wt,{sort:k,onSort:I,total:ae,loading:z||E,query:i,onOpenFilters:()=>g(!0),chips:M,onClearChips:Ge}),Oe&&U&&P.some(r=>r.source==="legacy")?e.jsx("p",{className:"market-banner market-banner--warn",children:o("assets.marketUnavailable")}):null,Be?e.jsx(Ct,{message:o("assets.loadError"),testId:"browse-error"}):null,e.jsx("div",{className:"grid","data-testid":"grid",children:He?e.jsx(xe,{count:Ue}):e.jsxs(e.Fragment,{children:[P.map(r=>{if(!U)return e.jsx(K,{item:r,mode:"view"},Q(r));const $=r;return $.source==="legacy"?e.jsx(K,{item:$,mode:"market",marketPriceCredits:qe($),onBuyNow:De},Q(r)):e.jsx(K,{item:r},Q(r))}),le?e.jsx(xe,{count:6}):null]})}),e.jsx(vt,{hasNextPage:Fe,isFetching:le,onLoadMore:()=>void We()}),!z&&!E&&P.length===0?e.jsx("p",{className:"muted",children:o("assets.noItems")}):null]})}),H&&q?e.jsx(at,{listing:H,rate:q,onClose:()=>N(null),onSold:()=>{N(null),Ve()}}):null]})}export{ys as Assets};
|