@dcl/shop 0.1.0-29994098968.commit-46a6a0c → 0.1.0-29994103056.commit-191afbc
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-BtxoZ_fw.js → AnimatedBackground-CwVmQoMy.js} +3 -3
- package/assets/{Assets-ClMZMx1a.js → Assets-DqZw3BZv.js} +1 -1
- package/assets/{Assets.styles-JVRlU2lC.js → Assets.styles-BmY0qPN-.js} +1 -1
- package/assets/{Authorizations-wPj_fvn3.js → Authorizations-BxmoVEl_.js} +1 -1
- package/assets/{Cart-BShdrrZS.js → Cart-DA1J5Be_.js} +1 -1
- package/assets/{CircularProgress-CLSvO83K.js → CircularProgress-BmaY3soK.js} +1 -1
- package/assets/{Collection-BYyH6eXu.js → Collection-BlMV8rIO.js} +1 -1
- package/assets/{CollectionCarousel-Dyw-XZFx.js → CollectionCarousel-B2cDWt_o.js} +1 -1
- package/assets/{Creator-DqVjR99e.js → Creator-CVsany2p.js} +1 -1
- package/assets/{CssVarsProvider-Dze6xxok.js → CssVarsProvider-D03-j1T8.js} +2 -2
- package/assets/{ExchangeController-CEtbskqk.js → ExchangeController-BKklF67w.js} +1 -1
- package/assets/{GetCredits-CATIgZsR.js → GetCredits-l0W_kkUA.js} +1 -1
- package/assets/{HelpersUtil-BxqSV8ZH.js → HelpersUtil-1AJlaO39.js} +1 -1
- package/assets/{ImportListings-CbvJ0vxX.js → ImportListings-CaC4hXkS.js} +1 -1
- package/assets/ItemDetail-DHaOvIrD.js +78 -0
- package/assets/{LoadMore-BFtkV8IC.js → LoadMore-DCZi1YY-.js} +1 -1
- package/assets/{MarketCheckout-Dlac-3dT.js → MarketCheckout-BrvEzX8j.js} +1 -1
- package/assets/{MyAssets-Cl5a0ipv.js → MyAssets-Gc_o5t9O.js} +1 -1
- package/assets/{MyFavorites-B1ctQKxs.js → MyFavorites-CTtHG-tK.js} +1 -1
- package/assets/{MyPurchases-xeoqVcYT.js → MyPurchases-DLOdIHUA.js} +1 -1
- package/assets/{NotFound-BuZmXlNo.js → NotFound-0kATSaSv.js} +1 -1
- package/assets/{PrimaryListModal-ByimAoht.js → PrimaryListModal-QH5JEih2.js} +1 -1
- package/assets/{StoreSettings-cBFiQNG0.js → StoreSettings-D97bWmhq.js} +5 -5
- package/assets/{Success-KErTN6A-.js → Success-DRMy6BRe.js} +1 -1
- package/assets/{SwapController-BqhWyeug.js → SwapController-C8nP5wvc.js} +1 -1
- package/assets/{Tooltip-CWYX2BtV.js → Tooltip-BaUllE5E.js} +1 -1
- package/assets/{TradeService-vOc7cmM-.js → TradeService-ZNznSjPX.js} +1 -1
- package/assets/{W3MFrameProviderSingleton-bzfGoYP9.js → W3MFrameProviderSingleton-B-iMukUt.js} +3 -3
- package/assets/{WebCryptoP256-0n5GC_Ut.js → WebCryptoP256-BN2oUA6b.js} +1 -1
- package/assets/{authorizations-4HFkBc9K.js → authorizations-QONJAQC4.js} +1 -1
- package/assets/{basic-BTIll8Fi.js → basic-BAZBRGQf.js} +1 -1
- package/assets/{biconomy-BW4ch8hb.js → biconomy-Bnx-4bDS.js} +1 -1
- package/assets/{buy-Djb-kNlV.js → buy-CE5I6jg2.js} +1 -1
- package/assets/{buy-gasless-Bpg3rjq9.js → buy-gasless-DPcBjPtZ.js} +1 -1
- package/assets/{cart-checkout-C350oS3_.js → cart-checkout-CUI-WqEI.js} +1 -1
- package/assets/{categories-DY58IjaQ.js → categories-BGNx7jfw.js} +1 -1
- package/assets/{ccip-CeLfuW_O.js → ccip-CPI8_6cL.js} +1 -1
- package/assets/{ccip-B_QBYF5J.js → ccip-s5BQ-vNw.js} +1 -1
- package/assets/{collection-CC5CSnLx.js → collection-Bm8Org8q.js} +1 -1
- package/assets/{controller-DSyyj9lD.js → controller-CL9wipr5.js} +2 -2
- package/assets/{core-BV9Uqx3a.js → core-gCo9rRyh.js} +4 -4
- package/assets/{custom-CftAA_1-.js → custom-BIAxnPyV.js} +1 -1
- package/assets/{data-capture-BDFC_AAZ.js → data-capture-D_IuhqRX.js} +1 -1
- package/assets/{email-NQmHVcSX.js → email-BCklj9Js.js} +1 -1
- package/assets/{embedded-wallet-BaACcSds.js → embedded-wallet-B6X4cZQC.js} +1 -1
- package/assets/{emotion-styled.browser.esm-CBmI5nIt.js → emotion-styled.browser.esm-D40Lt8fm.js} +1 -1
- package/assets/{engine-CJaBRUsg.js → engine-skvS20px.js} +1 -1
- package/assets/{errors-Cs9fnU9I.js → errors-DmdGTuzI.js} +1 -1
- package/assets/{estimate-l1-fee-Cy1M04Vs.js → estimate-l1-fee-J0AI4VGA.js} +1 -1
- package/assets/{execute-BuQfuqwm.js → execute-B_XUV-t5.js} +2 -2
- package/assets/{features-DUkOU29X.js → features-D1q967sn.js} +1 -1
- package/assets/{fetchTokenMetadata-DgDl3_sf.js → fetchTokenMetadata-Bgs6k1N5.js} +2 -2
- package/assets/{get-ecosystem-wallet-info-CVTh7CfJ.js → get-ecosystem-wallet-info-BRMexyn8.js} +1 -1
- package/assets/{getBalance-BIyXRLDy.js → getBalance-D2FG5QKV.js} +1 -1
- package/assets/{getNFT-cGRZcqJv.js → getNFT-BHzS5Cs2.js} +1 -1
- package/assets/{getNFT-rv6yBkGa.js → getNFT-DrLPmHpk.js} +1 -1
- package/assets/{getOverlayAlpha-BFopV-KN.js → getOverlayAlpha-B90Fo_-m.js} +1 -1
- package/assets/{hashTypedData-BfzJ0TS-.js → hashTypedData-Cetq1UOK.js} +1 -1
- package/assets/{hashTypedData-BdsAWz2G.js → hashTypedData-DwlPS8MG.js} +1 -1
- package/assets/{import-DzTakhaX.js → import-DLMm_P8-.js} +1 -1
- package/assets/{in-app-B8isPC0y.js → in-app-CL2vGnrW.js} +1 -1
- package/assets/{in-app-wallet-calls-ClTovWdh.js → in-app-wallet-calls-CQYLsbwB.js} +1 -1
- package/assets/{index-DDdtoGEi.js → index-B-3QmCY1.js} +1 -1
- package/assets/{index-DgI6b_1k.js → index-B-wT7-Au.js} +1 -1
- package/assets/{index-i-9qXVIl.js → index-B65D0iv0.js} +1 -1
- package/assets/{index-DLTp8-1W.js → index-B6gcmiqs.js} +1 -1
- package/assets/{index-BOhj5LdJ.js → index-BBg2vZhG.js} +1 -1
- package/assets/{index-CSgDOfxq.js → index-BEYHZcex.js} +1 -1
- package/assets/{index-C4L5vZQw.js → index-BZk7RUfM.js} +1 -1
- package/assets/{index-CDgxS1kA.js → index-BedvNbsM.js} +1 -1
- package/assets/{index-BOngn0q7.js → index-BkQHYnhC.js} +1 -1
- package/assets/{index-BeFcjOKO.js → index-BptsdzIZ.js} +1 -1
- package/assets/{index-CJlRo57i.js → index-BrG8RI5z.js} +1 -1
- package/assets/{index-CFIjjpBo.js → index-BywohlL7.js} +1 -1
- package/assets/{index-CQ0Ros7W.js → index-C0wsNojR.js} +1 -1
- package/assets/{index-CCFR9hc6.js → index-C2N-AU8j.js} +3 -3
- package/assets/{index-Ckg159RR.js → index-C2te_xAY.js} +2 -2
- package/assets/{index-CPgX0p-K.js → index-C5t2d1JX.js} +1 -1
- package/assets/{index-Mkx_BzFP.js → index-C6-1JAkG.js} +1 -1
- package/assets/{index-BP4skMl2.js → index-C97CPhyL.js} +1 -1
- package/assets/{index-BEIRvEFT.js → index-CHspULa1.js} +1 -1
- package/assets/{index-D-fHYuz6.js → index-CMZ-l1j1.js} +1 -1
- package/assets/{index-Cd5420Rq.js → index-CVPd9k0D.js} +1 -1
- package/assets/{index-DK9SMaUV.js → index-CW9ug21x.js} +3 -3
- package/assets/{index-1DxtfhSJ.js → index-CWfnhYLp.js} +1 -1
- package/assets/{index-BFk849bZ.js → index-ChbyDwUh.js} +1 -1
- package/assets/{index-DDIhscgO.js → index-Che81lrU.js} +1 -1
- package/assets/{index-CfltZkIg.js → index-Chep4cKH.js} +3 -3
- package/assets/{index-HZG2j8cz.js → index-Ctbl3gOg.js} +1 -1
- package/assets/{index-3d7PO8q_.js → index-CwlKjFOG.js} +1 -1
- package/assets/{index-DEMmrYiw.js → index-Cx9CeoZH.js} +1 -1
- package/assets/{index-BGdPOxCz.js → index-CyrfWYlv.js} +1 -1
- package/assets/{index-De5ttsh0.js → index-D-i0A7WQ.js} +2 -2
- package/assets/{index-X_kzACYR.js → index-D2F7-1mk.js} +1 -1
- package/assets/{index-D5HjNYdn.js → index-D3iIxnX6.js} +1 -1
- package/assets/{index-6hSJkqDq.js → index-D5zi_XmR.js} +1 -1
- package/assets/{index-DFmvL2Cv.js → index-D6Thjy9g.js} +1 -1
- package/assets/{index-CW8mL8-A.js → index-DAhYJ23_.js} +1 -1
- package/assets/{index-B3cwJw_u.js → index-DLJwIINa.js} +1 -1
- package/assets/{index-BZ_-xKre.js → index-DOyivP0c.js} +2 -2
- package/assets/{index-4bTa1qff.js → index-DTJ6mS_J.js} +1 -1
- package/assets/{index-BwS7sI1B.js → index-DYAXJBpy.js} +1 -1
- package/assets/{index-P7Sau0I5.js → index-DaOu_NHP.js} +20 -20
- package/assets/{index-B5Kj0FW_.js → index-DcsKpVUb.js} +1 -1
- package/assets/{index-D_5sPEkx.js → index-DexIqMzn.js} +3 -3
- package/assets/{index-Bvrid8NA.js → index-DnxELmkR.js} +1 -1
- package/assets/{index-C50En1tW.js → index-DyhpH4px.js} +1 -1
- package/assets/{index-Bkpu5jNe.js → index-Dzy3N4vA.js} +1 -1
- package/assets/{index-kcM3wjmL.js → index-Zev_LSPI.js} +2 -2
- package/assets/{index-D1kzW8fy.js → index-d3ZKkcaA.js} +1 -1
- package/assets/{index-DqtVIf4M.js → index-nTA1Tk1a.js} +1 -1
- package/assets/{index-B1DqMYiX.js → index-o_m2wFAn.js} +1 -1
- package/assets/{index-zbbepWkd.js → index-uK7qM9c7.js} +1 -1
- package/assets/{index-BQ4rZ0Kg.js → index-yr9vyS0z.js} +1 -1
- package/assets/{index.es-BAM5UZfH.js → index.es-CZtQ8FVb.js} +4 -4
- package/assets/{index.es-CtE5jBFg.js → index.es-DlHsAJbI.js} +1 -1
- package/assets/{index.es-BuXQjTmU.js → index.es-DnNvUOrT.js} +1 -1
- package/assets/{localBatchGatewayRequest-BmJtIlOK.js → localBatchGatewayRequest-DiUucTH0.js} +1 -1
- package/assets/{mana-rate-DXdP8JQC.js → mana-rate-BX_VjspN.js} +1 -1
- package/assets/{networks-CUafijuQ.js → networks-D5rFr4Uy.js} +1 -1
- package/assets/{onramp--Iu6rhXk.js → onramp-RD8o9zW8.js} +1 -1
- package/assets/{openzeppelin-GNxIJhIO.js → openzeppelin-GzHB2W1P.js} +1 -1
- package/assets/{parseNft-BxE7m6kg.js → parseNft-CbgJiXpe.js} +2 -2
- package/assets/{parseSignature-BWe0ZDDZ.js → parseSignature-DGB4v4W-.js} +1 -1
- package/assets/{parseSignature-DykTAPWJ.js → parseSignature-DZazOabU.js} +3 -3
- package/assets/{passkeys-DHqYP34I.js → passkeys-BDOXnD26.js} +1 -1
- package/assets/{pay-with-exchange-D66UeJj2.js → pay-with-exchange-ChCNzNHg.js} +1 -1
- package/assets/{qr-overlay-C7ZyUZLi.js → qr-overlay-BIPzfQds.js} +1 -1
- package/assets/{receive-Tu6Iesz3.js → receive-CsWO80gl.js} +1 -1
- package/assets/{resolveImplementation-CWJsUrAo.js → resolveImplementation-CInkT_I9.js} +1 -1
- package/assets/{rpc-BZZfKitN.js → rpc-DOR15RcJ.js} +1 -1
- package/assets/{secp256k1-C76o0bDB.js → secp256k1-C8pkcGJ3.js} +1 -1
- package/assets/{secp256k1-DEWXJb0G.js → secp256k1-DUaLgTGJ.js} +1 -1
- package/assets/{secp256k1-CQNFBqGb.js → secp256k1-N7sx_maT.js} +1 -1
- package/assets/{send-OHcFalUD.js → send-BEnX8iHn.js} +1 -1
- package/assets/{send-batch-transaction-BjHqNEHy.js → send-batch-transaction-Cl-WR4dD.js} +1 -1
- package/assets/{send-eip712-transaction-Bdiu-MHL.js → send-eip712-transaction-BnpCutKi.js} +2 -2
- package/assets/{send-gasless-transaction-C0KhDzDb.js → send-gasless-transaction-CGxm_r0E.js} +2 -2
- package/assets/{send-transaction-D66Dvp6I.js → send-transaction-BcThrsCr.js} +2 -2
- package/assets/{sendRawTransaction-Cx8JQgbZ.js → sendRawTransaction-BJLeMhAd.js} +3 -3
- package/assets/{serializeTransaction-PO2i8zfn.js → serializeTransaction-BMgHZkKp.js} +1 -1
- package/assets/{session-proposal-U6d-r0h1.js → session-proposal-Ds2RY-CA.js} +1 -1
- package/assets/{session-request-BWDFEy4d.js → session-request-CLTybC5q.js} +2 -2
- package/assets/{signing-647xzxe_.js → signing-Dr9d33yf.js} +3 -3
- package/assets/{socials-CSe9kiyp.js → socials-CaYP6kJa.js} +1 -1
- package/assets/{swaps-0ZQ3ykaN.js → swaps-BHrutsbS.js} +1 -1
- package/assets/{thirdweb-8PhoY169.js → thirdweb-DIAnaqbp.js} +3 -3
- package/assets/{to-serializable-transaction-BosnrISG.js → to-serializable-transaction-DqNZm-Zy.js} +2 -2
- package/assets/{trade-encoding-DLx_mjRt.js → trade-encoding-DqhxC9n7.js} +1 -1
- package/assets/{transactionReceipt-XOTwrGYa.js → transactionReceipt-iA2axmC8.js} +1 -1
- package/assets/{transactions-D7zvnmjK.js → transactions-DAq9dNVo.js} +1 -1
- package/assets/{useCreditPacks-D-Oae9wZ.js → useCreditPacks-CV1PhThV.js} +1 -1
- package/assets/{useInfiniteGrid-DpzTC5bY.js → useInfiniteGrid-Dh1-HUF4.js} +1 -1
- package/assets/{useStore-DDADUZbP.js → useStore-DBh7zwbY.js} +1 -1
- package/assets/useTheme--bd6Ub02.js +1 -0
- package/assets/{useTheme-Da_Gtdq6.js → useTheme-ddXkiCRZ.js} +1 -1
- package/assets/{verifyHash-DWxhTdFY.js → verifyHash-C62BfpA_.js} +1 -1
- package/assets/{w3m-modal-Duh5YevD.js → w3m-modal-BT8yrl74.js} +1 -1
- package/assets/{w3m-modal-Bm1VCEs7.js → w3m-modal-Bxbo8T_Z.js} +1 -1
- package/assets/{wait-for-tx-receipt-BH0Nmt__.js → wait-for-tx-receipt-D_og-NhE.js} +1 -1
- package/assets/{wallets-C9WwqLIm.js → wallets-B72ZtlfA.js} +5 -5
- package/assets/{web-connector-Djci4K78.js → web-connector-DBmok4eN.js} +3 -3
- package/assets/{writeContract-hVW1D3JA.js → writeContract-CLiFKioV.js} +1 -1
- package/assets/{zoraTestnet-BdlBNZA4.js → zoraTestnet-Bfnpd26p.js} +1 -1
- package/index.html +11 -11
- package/package.json +2 -2
- package/assets/ItemDetail-CcoMXI-P.js +0 -78
- package/assets/useTheme-CJjDEqR6.js +0 -1
package/index.html
CHANGED
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
<link rel="canonical" href="https://shop.decentraland.org/" />
|
|
17
17
|
|
|
18
18
|
<!-- Favicon: the Decentraland mark (same as the marketplace). -->
|
|
19
|
-
<link rel="icon" type="image/x-icon" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
20
|
-
<link rel="apple-touch-icon" sizes="180x180" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
19
|
+
<link rel="icon" type="image/x-icon" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/favicon.ico" sizes="16x16 32x32 48x48" />
|
|
20
|
+
<link rel="apple-touch-icon" sizes="180x180" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/apple-touch-icon.png" />
|
|
21
21
|
<meta name="apple-mobile-web-app-title" content="DCL Shop" />
|
|
22
|
-
<link rel="manifest" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
22
|
+
<link rel="manifest" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/site.webmanifest" />
|
|
23
23
|
|
|
24
24
|
<!-- Open Graph -->
|
|
25
25
|
<meta property="og:type" content="website" />
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
<meta name="twitter:image:alt" content="Decentraland Shop — wearables and emotes for your avatar" />
|
|
49
49
|
|
|
50
50
|
<!-- Sitemap -->
|
|
51
|
-
<link rel="sitemap" type="application/xml" title="Sitemap" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
51
|
+
<link rel="sitemap" type="application/xml" title="Sitemap" href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/sitemap.xml" />
|
|
52
52
|
|
|
53
53
|
<!-- Warm the 3D preview / fonts -->
|
|
54
54
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
@@ -60,13 +60,13 @@
|
|
|
60
60
|
<link rel="preconnect" href="https://wearable-preview.decentraland.org" />
|
|
61
61
|
<link rel="preconnect" href="https://peer.decentraland.zone" crossorigin />
|
|
62
62
|
<link rel="preconnect" href="https://peer.decentraland.org" crossorigin />
|
|
63
|
-
<script type="module" crossorigin src="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
64
|
-
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
65
|
-
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
66
|
-
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
67
|
-
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
68
|
-
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
69
|
-
<link rel="stylesheet" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-
|
|
63
|
+
<script type="module" crossorigin src="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/index-DaOu_NHP.js"></script>
|
|
64
|
+
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/react-BrLDncxD.js">
|
|
65
|
+
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/dcl-schemas-BICTSpB5.js">
|
|
66
|
+
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/sentry-DYZXk5O5.js">
|
|
67
|
+
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/ethers-BIvjmL85.js">
|
|
68
|
+
<link rel="modulepreload" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/intl-CBcMB1D2.js">
|
|
69
|
+
<link rel="stylesheet" crossorigin href="https://cdn.decentraland.org/@dcl/shop/0.1.0-29994103056.commit-191afbc/assets/index-Bw9Y53F1.css">
|
|
70
70
|
</head>
|
|
71
71
|
<body>
|
|
72
72
|
<div id="root"></div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcl/shop",
|
|
3
|
-
"version": "0.1.0-
|
|
3
|
+
"version": "0.1.0-29994103056.commit-191afbc",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"author": "Decentraland",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"type": "git",
|
|
9
9
|
"url": "git+https://github.com/decentraland/shop.git"
|
|
10
10
|
},
|
|
11
|
-
"commit": "
|
|
11
|
+
"commit": "191afbc5d2e37d740e0200156317e1862ac7d321"
|
|
12
12
|
}
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-CCFR9hc6.js","assets/react-BrLDncxD.js","assets/dcl-schemas-BICTSpB5.js","assets/index-P7Sau0I5.js","assets/sentry-DYZXk5O5.js","assets/ethers-BIvjmL85.js","assets/intl-CBcMB1D2.js","assets/index-Bw9Y53F1.css","assets/emotion-styled.browser.esm-CBmI5nIt.js","assets/useTheme-Da_Gtdq6.js","assets/CircularProgress-CLSvO83K.js","assets/index-De5ttsh0.js","assets/useTheme-CJjDEqR6.js","assets/CssVarsProvider-Dze6xxok.js","assets/getOverlayAlpha-BFopV-KN.js","assets/index-BOngn0q7.js","assets/colors-LINLm1ux.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{a as oe,r as d,j as e,d as pa,u as ya,L as fa}from"./react-BrLDncxD.js";import{d as X,n as xa,o as ve,t,ai as ba,i as ga,b as ja,w as va,q as ne,x as D,y as ge,z as fe,aj as Na,E as Z,g as E,j as de,B as z,C as xe,p as wa,J as Je,_ as be,al as ka,ay as Ia,az as Ca,aA as Sa,aB as Aa,c as Ne,aC as Ma,M as Ye,m as B,aD as Pa,I as T,F as K,s as W,aE as Ea,aF as Fa,aG as La,G as Ta,af as ze,a as Ke,aH as Da,aI as Ra,aJ as qa,aK as Ba,aL as $a,ag as Oa,u as za,aM as Ka,aN as Wa,aO as Va,h as Ua,aP as We,aQ as Qa,f as Ga,ap as Ha,aR as Ja,aS as Ya,aq as Xa,aT as Za,aU as et}from"./index-P7Sau0I5.js";import{d as G}from"./dcl-schemas-BICTSpB5.js";import{b as Ve,c as at}from"./buy-Djb-kNlV.js";import{P as tt,f as st}from"./PrimaryListModal-ByimAoht.js";import{b as it,w as rt,S as nt,G as lt}from"./buy-gasless-Bpg3rjq9.js";import{a as dt}from"./authorizations-4HFkBc9K.js";import{u as ot,M as ct,c as mt}from"./useCreditPacks-D-Oae9wZ.js";import{W as ut,C as ht,a as _t}from"./CollectionCarousel-Dyw-XZFx.js";import{R as Ue}from"./resume-buy-Bf0zIH7y.js";import{a as pt,f as je,i as yt}from"./errors-Cs9fnU9I.js";import{E as ce}from"./ErrorNotice-BDH9xoG4.js";import{l as ft}from"./loader-logo-BzY9EKdC.js";import{C as xt}from"./CircularProgress-CLSvO83K.js";import{a as bt,b as gt}from"./trade-encoding-DLx_mjRt.js";import{u as jt,M as vt}from"./MarketCheckout-Dlac-3dT.js";import{s as Nt}from"./address-DrURAr9O.js";import{T as Xe}from"./Tooltip-CWYX2BtV.js";import"./sentry-DYZXk5O5.js";import"./ethers-BIvjmL85.js";import"./intl-CBcMB1D2.js";import"./sendMetaTransaction-iOoE_Tw3.js";import"./mana-rate-DXdP8JQC.js";import"./emotion-CSxEP8yM.js";function wt({item:s,onClose:n,resume:i=!1}){var ae,te;const{session:o}=X(),{data:m}=xa(o),h=ve(),w=oe(),x=ot().packs.slice(0,ct),[c,l]=d.useState("loading"),[a,j]=d.useState(null),[y,N]=d.useState(""),[F,b]=d.useState(s.priceCredits),[f,g]=d.useState(null),I=d.useRef(null),M=(f==null?void 0:f.credits)??F,ee=(m==null?void 0:m.credits)??0;d.useEffect(()=>{let u=!1;if(!o){l("error"),j(t("buyModal.signInToCheckout"));return}const C=_=>{const S=_-((m==null?void 0:m.credits)??0),v=x.find(R=>R.credits>=S)??x[x.length-1];N(v.id),D("Shop Buy Credits Prompted",{from:"item_checkout",credits_needed:_,credits_balance:(m==null?void 0:m.credits)??0,shortfall:Math.max(0,S)}),l("nofunds")};return(async()=>{var _,S;try{const v=await ba(s);if(!v)throw new Error("not for sale");if(ga(v,o.address))throw new Error("You can't buy your own listing.");const R=ja((S=(_=v.received)==null?void 0:_[0])==null?void 0:S.amount);if(!Number.isFinite(R)||R<=0)throw new Error("price unavailable");const V=Math.ceil(R/10);if(u)return;if(b(V),m!=null&&m.credits<V){C(V);return}try{const{credit:A,maxCreditedValue:J,usdCents:O}=await va(o.identity,R,v.id);if(u){ne(o.identity,[A.id]).catch(()=>{});return}I.current=A.id;const se=Math.ceil(O/10);b(se);const U={trade:v,credit:A,maxCreditedValue:J,usdCents:O,credits:se};g(U),i?H(U):l("ready")}catch(A){if(u)return;if(pt(A)){C(V);return}throw A}}catch(v){if(u)return;D(fe(v)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"authorize",error_code:ge(v)}),l("error"),j(je(v,t("buyModal.error.generic"),{sale:!0}))}})(),()=>{u=!0,I.current&&o&&(ne(o.identity,[I.current]).catch(()=>{}),I.current=null)}},[]);async function H(u=f){if(!o||!u)return;l("processing"),j(null);let C=!1;try{const _={trade:u.trade,buyer:o.address,signer:o.signer,credits:[u.credit],maxCreditedValue:u.maxCreditedValue};let S;if(dt())try{S=await it(_),await rt(S),C=!0}catch(v){if(v instanceof nt)C=!0;else if(v instanceof lt)S=await Ve(_);else throw v}else S=await Ve(_);I.current=null,D("Shop Completed Purchase",{...Na([s]),payment_type:"credits",no_crypto_step:C,transaction_hash:S??null}),h.invalidateQueries({queryKey:["usd-balance"]}),l("complete")}catch(_){fe(_)||Z(_,{flow:"buy",step:"submit",gasless:C}),ne(o.identity,[u.credit.id]).catch(()=>{}),I.current=null,D(fe(_)?"Shop Purchase Cancelled":"Shop Purchase Failed",{step:"submit",error_code:ge(_)}),h.invalidateQueries({queryKey:["usd-balance"]}),j(je(_,t("buyModal.error.generic"),{sale:!0})),l("error")}}async function me(){if(!(!y||!o)){try{sessionStorage.setItem(Ue,JSON.stringify(s))}catch{}f&&ne(o.identity,[f.credit.id]).catch(()=>{}),I.current=null,l("loading");try{const u=await mt(y,{address:o.address,identity:o.identity});if(u.url){window.location.href=u.url;return}w("/credits")}catch(u){Z(u,{flow:"buy_credits_and_item"});try{sessionStorage.removeItem(Ue)}catch{}j(t("buyModal.error.creditsCheckout")),l("error")}}}const $=c==="processing",L=c==="complete"?t("buyModal.titleComplete"):c==="nofunds"?t("buyModal.titleNoFunds"):t("buyModal.titleBuy");return e.jsxs("div",{className:"buy-modal",role:"dialog","aria-modal":"true","aria-label":t("buyModal.dialogAria",{name:s.name}),children:[e.jsx("div",{className:"buy-modal__scrim",onClick:$?void 0:n,"aria-hidden":!0}),e.jsxs("div",{className:`buy-modal__card${c==="processing"||c==="loading"?" buy-modal__card--tall":""}`,children:[e.jsxs("div",{className:"buy-modal__head",children:[e.jsxs("div",{className:"buy-modal__head-row",children:[e.jsx("h2",{className:"buy-modal__title",children:L}),!$&&e.jsx("button",{className:"buy-modal__x",onClick:n,"aria-label":t("buyModal.close"),children:e.jsx("svg",{viewBox:"0 0 18 18",width:"18",height:"18","aria-hidden":!0,children:e.jsx("path",{d:"M4 4l10 10M14 4L4 14",stroke:"#161518",strokeWidth:"1.8",strokeLinecap:"round"})})})]}),e.jsxs("div",{className:"buy-modal__balance",children:[e.jsx("span",{className:"buy-modal__balance-label",children:c==="nofunds"?t("buyModal.dclBalance"):t("buyModal.myCreditsBalance")}),e.jsx(E,{className:"buy-modal__balance-ico"}),e.jsx("span",{className:"buy-modal__balance-value",children:de(ee)})]})]}),c==="loading"&&e.jsx("div",{className:"buy-modal__body buy-modal__processing",children:e.jsx(xt,{size:44})}),c==="error"&&e.jsxs("div",{className:"buy-modal__body",children:[e.jsx(ce,{message:a}),e.jsx("div",{className:"buy-modal__ctas",children:e.jsx("button",{className:"buy-modal__btn buy-modal__btn--gradient",onClick:n,children:t("buyModal.close")})})]}),c==="nofunds"&&e.jsxs("div",{className:"buy-modal__body",children:[e.jsxs("div",{className:"buy-modal__warning",children:[e.jsx(ut,{className:"buy-modal__warning-ico"}),e.jsxs("p",{className:"buy-modal__warning-text",children:[e.jsx("b",{children:t("buyModal.insufficientFunds")})," ",t("buyModal.warningNeedToBuy")," ",e.jsx("b",{children:t("buyModal.warningCreditsAmount",{count:Math.max(0,M-ee)})})," ",t("buyModal.warningToPurchase",{count:1})]})]}),e.jsx(Qe,{item:s,priceCredits:M}),e.jsx("div",{className:"buy-modal__packs",children:x.map(u=>{const C=u.credits,_=u.id===y;return e.jsxs("button",{className:`buy-modal__pack${_?" buy-modal__pack--on":""}`,onClick:()=>N(u.id),children:[e.jsx(E,{className:"buy-modal__pack-ico"}),e.jsx("span",{className:"buy-modal__pack-amount",children:de(C)}),e.jsxs("span",{className:"buy-modal__pack-usd",children:["($",u.usd.toFixed(2),")"]})]},u.id)})}),e.jsxs("div",{className:"buy-modal__total",children:[e.jsxs("div",{className:"buy-modal__total-credits",children:[e.jsx(E,{className:"buy-modal__total-ico"}),e.jsx("span",{children:de(((ae=x.find(u=>u.id===y))==null?void 0:ae.credits)??0)})]}),e.jsxs("span",{className:"buy-modal__total-usd",children:["$",(((te=x.find(u=>u.id===y))==null?void 0:te.usd)??0).toFixed(2)]})]}),e.jsxs("div",{className:"buy-modal__ctas",children:[e.jsx("button",{className:"buy-modal__btn buy-modal__btn--outline",onClick:n,children:t("buyModal.cancel")}),e.jsx("button",{className:"buy-modal__btn buy-modal__btn--gradient",onClick:()=>void me(),children:t("buyModal.buy")})]})]}),c==="ready"&&e.jsxs("div",{className:"buy-modal__body",children:[e.jsx(Qe,{item:s,priceCredits:M}),e.jsx("div",{className:"buy-modal__ctas",children:e.jsx("button",{className:"buy-modal__btn buy-modal__btn--gradient buy-modal__btn--full",onClick:()=>void H(),children:t("buyModal.buy")})})]}),c==="processing"&&e.jsxs("div",{className:"buy-modal__body buy-modal__processing",children:[e.jsx("img",{className:"buy-modal__logo",src:ft,alt:"",width:61,height:61}),e.jsx("div",{className:"buy-modal__processing-text",children:i?t("buyModal.completingPurchase"):t("buyModal.completingTransaction")}),e.jsx("div",{className:"buy-modal__progress","aria-hidden":!0,children:e.jsx("span",{className:"buy-modal__progress-fill"})})]}),c==="complete"&&e.jsxs("div",{className:"buy-modal__body",children:[e.jsxs("div",{className:"buy-modal__success",children:[e.jsxs("svg",{viewBox:"0 0 64 64",width:"64",height:"64","aria-hidden":!0,children:[e.jsx("circle",{cx:"32",cy:"32",r:"32",fill:"#34ce74"}),e.jsx("path",{d:"M20 33l8 8 16-18",fill:"none",stroke:"#fff",strokeWidth:"5",strokeLinecap:"round",strokeLinejoin:"round"})]}),e.jsxs("p",{className:"buy-modal__success-text",children:[e.jsx("b",{children:t("getCredits.successTitle")})," ",t("buyModal.successBody")]})]}),e.jsxs("div",{className:"buy-modal__ctas",children:[e.jsx("button",{className:"buy-modal__btn buy-modal__btn--outline",onClick:()=>w("/assets?tab=mine"),children:t("buyModal.myAssets")}),e.jsxs("button",{className:"buy-modal__btn buy-modal__btn--ruby",onClick:n,children:[t("buyModal.tryInWorld"),e.jsx("svg",{viewBox:"0 0 24 24",width:"20",height:"20","aria-hidden":!0,children:e.jsx("path",{d:"M5 12h12M13 7l5 5-5 5",fill:"none",stroke:"#fcfcfc",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})]})]})]})]})]})}function Qe({item:s,priceCredits:n}){return e.jsxs("div",{className:"buy-modal__asset",children:[e.jsx("div",{className:"buy-modal__asset-thumb",children:s.thumbnail?e.jsx("img",{src:s.thumbnail,alt:""}):null}),e.jsxs("div",{className:"buy-modal__asset-info",children:[e.jsxs("div",{children:[e.jsx("div",{className:"buy-modal__asset-name",title:s.name,children:s.name||t("buyModal.itemFallback")}),s.creator?e.jsx(ht,{address:s.creator,className:"buy-modal__asset-creator"}):null]}),e.jsxs("div",{className:"buy-modal__asset-price",children:[e.jsx(E,{className:"buy-modal__asset-price-ico"}),e.jsx("span",{children:de(n)})]})]})]})}const kt=1e3*60*60*24*182;function It({asset:s,session:n,onClose:i}){const o=ve(),m=oe(),[h,w]=d.useState("10"),[x,c]=d.useState(null),[l,a]=d.useState(null),[j,y]=d.useState(!1),[N,F]=d.useState(null);async function b(){a(null);const g=Number(h);if(!Number.isInteger(g)||g<=0){a(t("sellModal.errorWholeNumber"));return}y(!0);try{c(t("sellModal.statusPreparing")),await bt({signer:n.signer,contractAddress:s.contractAddress,chainId:s.chainId}),c(t("sellModal.statusListing"));const I=await gt({signer:n.signer,nft:{contractAddress:s.contractAddress,tokenId:s.tokenId,network:s.network,chainId:s.chainId},usdPrice:g/10,expiresAtMs:Date.now()+kt});c(t("sellModal.statusPublishing")),await wa(I,n.identity),c(null),F(g),D("Shop Listed Item",{item_id:s.itemId??s.tokenId??null,contract_address:s.contractAddress,price_credits:g,price_usd:g/10,listing_type:"secondary",is_primary:!1}),Je.success(t("sellModal.toastOnSale",{name:s.name})),o.invalidateQueries({queryKey:["my-assets",n.address]})}catch(I){Z(I,{flow:"list_secondary"}),D("Shop Listing Failed",{listing_type:"secondary",error_code:ge(I)}),a(je(I,t("sellModal.errorGeneric"))),c(null)}finally{y(!1)}}function f(){i(),m(`/item/${s.contractAddress}/${s.tokenId}`)}return N!==null?e.jsx("div",{className:"modal-backdrop",onClick:i,role:"presentation",children:e.jsxs("div",{className:"modal modal--success",onClick:g=>g.stopPropagation(),role:"dialog","aria-modal":"true",children:[e.jsx("div",{className:"modal-success__check","aria-hidden":!0,children:"✓"}),e.jsx("h2",{className:"modal__title",children:t("sellModal.successTitle")}),s.image?e.jsx("img",{className:"modal__img",src:s.image,alt:s.name}):null,e.jsx("p",{className:"modal-success__name",children:s.name}),e.jsxs("p",{className:"muted small",children:[t("sellModal.listedFor")," ",e.jsxs("strong",{children:[e.jsx(E,{className:"ccy-mark"})," ",N]})]}),e.jsxs("div",{className:"modal__actions",children:[e.jsx(z,{variant:"ghost",onClick:i,children:t("getCredits.done")}),e.jsx(z,{variant:"purple",onClick:f,children:t("sellModal.viewInShop")})]})]})}):e.jsx("div",{className:"modal-backdrop",onClick:i,role:"presentation",children:e.jsxs("div",{className:"modal","data-testid":"modal",onClick:g=>g.stopPropagation(),role:"dialog","aria-modal":"true",children:[e.jsx("h2",{className:"modal__title",children:t("sellModal.listTitle",{name:s.name})}),s.image?e.jsx("img",{className:"modal__img",src:s.image,alt:s.name}):null,e.jsxs("label",{className:"field",children:[e.jsx("span",{children:t("sellModal.priceLabel",{currency:xe.name})}),e.jsx("input",{type:"number",min:"1",step:"1",value:h,onChange:g=>w(g.target.value),disabled:j})]}),e.jsx("p",{className:"muted small",children:t("sellModal.pricedInWhole",{currency:xe.name,currencySingular:xe.nameSingular})}),x?e.jsx("p",{className:"muted",children:x}):null,e.jsx(ce,{message:l}),e.jsxs("div",{className:"modal__actions",children:[e.jsx(z,{variant:"ghost",onClick:i,disabled:j,children:t("sellModal.cancel")}),e.jsx(z,{onClick:()=>void b(),disabled:j,children:j?t("sellModal.listing"):t("sellModal.putOnSale")})]})]})})}const Ct=d.lazy(async()=>{const[{EmoteControls:s},{Experimental_CssVarsProvider:n},{light:i}]=await Promise.all([be(()=>import("./index-CCFR9hc6.js").then(o=>o.i),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10])),be(()=>import("./index-De5ttsh0.js"),__vite__mapDeps([11,3,1,2,4,5,6,7,12,9,13,14])),be(()=>import("./index-BOngn0q7.js"),__vite__mapDeps([15,3,1,2,4,5,6,7,16,14,13,9]))]);return{default:o=>e.jsx(n,{theme:i,children:e.jsx(s,{...o})})}});function St(s){return e.jsx(d.Suspense,{fallback:null,children:e.jsx(Ct,{...s})})}function At({item:s}){const n=X(f=>{var g;return(g=f.session)==null?void 0:g.address}),{data:i,isLoading:o}=ka(n),m=n&&i?n:"default",h=s.category==="emote",[w,x]=d.useState("item"),c=!h&&w==="item",l=c||!o,[a,j]=d.useState(!0);d.useEffect(()=>{j(!0)},[s.id,c]);const y=!!n&&!!i,N=y&&Ia(s,Ca(i)),F=Sa(s)[0],b=y&&!N&&!h;return e.jsxs(e.Fragment,{children:[l?e.jsx(Aa,{id:"shop-item-preview",contractAddress:s.contractAddress,tokenId:s.tokenId??void 0,itemId:s.tokenId?void 0:s.itemId??void 0,profile:c?void 0:N?m:"default",bodyShape:c||N?void 0:F,type:h?void 0:c?G.PreviewType.WEARABLE:G.PreviewType.AVATAR,emote:h||c?void 0:G.PreviewEmote.FASHION,disableBackground:!0,wheelZoom:h?1.5:void 0,wheelStart:h?100:void 0,dev:Ne.chainId===80002,onLoad:()=>j(!1)}):null,!l||a?e.jsx("div",{className:"item-preview__loading","aria-busy":"true","aria-label":t("itemPreview.loading"),children:e.jsx("span",{className:"item-preview__spinner","aria-hidden":!0})}):null,b&&!c?e.jsx("p",{className:"item-preview__note",children:t("itemPreview.shownOnBody",{shape:Ma(F)})}):null,h?e.jsx("div",{className:"item-preview__emote-controls","data-testid":"emote-controls",children:e.jsx(St,{wearablePreviewId:"shop-item-preview",hideFrameInput:!0})}):e.jsxs("div",{className:"item-preview__toggle",role:"group","aria-label":t("itemPreview.previewMode"),children:[e.jsxs("button",{type:"button",className:w==="avatar"?"is-active":"","aria-pressed":w==="avatar","aria-label":t("itemPreview.onAvatar"),onClick:()=>x("avatar"),children:[e.jsxs("svg",{className:"item-preview__toggle-ico",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":!0,children:[e.jsx("circle",{cx:"12",cy:"7.5",r:"4"}),e.jsx("path",{d:"M4 20c0-4.2 3.6-6.5 8-6.5s8 2.3 8 6.5v.5H4z"})]}),e.jsx("span",{className:"item-preview__toggle-label",children:t("itemPreview.onAvatar")})]}),e.jsxs("button",{type:"button",className:w==="item"?"is-active":"","aria-pressed":w==="item","aria-label":t("itemPreview.item"),onClick:()=>x("item"),children:[e.jsx("svg",{className:"item-preview__toggle-ico",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":!0,children:e.jsx("path",{d:"M8.5 3 3 6l1.8 3.8 2.2-1V21h10V8.8l2.2 1L22 6l-5.5-3a2.6 2.6 0 0 1-4.5 1.4A2.6 2.6 0 0 1 8.5 3z"})}),e.jsx("span",{className:"item-preview__toggle-label",children:t("itemPreview.item")})]})]})]})}function Ze(){return Ne.shopServerUrl||(typeof window<"u"?window.location.origin:"")}async function Mt(s,n,i){const o=new URLSearchParams({contractAddress:s,itemId:n}),m=`${Ze()}/notify-requests?${o.toString()}`,h=await Ye(m,{method:"GET",identity:i,metadata:{}});if(!h.ok)throw new Error(`getNotifyRequest ${h.status}`);return h.json()}async function Pt(s,n){const i=`${Ze()}/notify-requests`,o=await Ye(i,{method:"POST",identity:n,metadata:{},headers:{"Content-Type":"application/json"},body:JSON.stringify(s)});if(!o.ok)throw new Error(`createNotifyRequest ${o.status}: ${await o.text()}`);await o.json().catch(()=>{})}function Ge(s){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(s.trim())}function Et({item:s}){const n=X(b=>b.session),i=X(b=>b.signIn),[o,m]=d.useState(""),[h,w]=d.useState(!1),[x,c]=d.useState(!1),[l,a]=d.useState(null),j=!!n&&!!s.contractAddress&&!!s.itemId,{data:y}=B({queryKey:["notify-request",s.contractAddress,s.itemId,n==null?void 0:n.address],enabled:j,queryFn:()=>Mt(s.contractAddress,s.itemId,n.identity)});d.useEffect(()=>{y!=null&&y.email&&m(b=>b||y.email)},[y==null?void 0:y.email]),d.useEffect(()=>{if(!n)return;let b=!1;return Pa().then(f=>{!b&&f&&m(g=>g||f)}),()=>{b=!0}},[n]);const N=x||!!(y!=null&&y.subscribed);async function F(b){if(b.preventDefault(),!(!n||!s.itemId||!Ge(o)||h)){w(!0),a(null);try{await Pt({contractAddress:s.contractAddress,itemId:s.itemId,chainId:s.chainId,email:o.trim()},n.identity),c(!0)}catch(f){Z(f,{flow:"notify-me",contractAddress:s.contractAddress,itemId:s.itemId}),a(t("notifyMe.error"))}finally{w(!1)}}}return n?N?e.jsxs("div",{className:"notify notify__done","data-testid":"notify-subscribed",children:[e.jsx("span",{className:"notify__done-check","aria-hidden":!0,children:e.jsx(T,{name:"check",size:12})}),e.jsx("span",{className:"notify__done-text",children:t("notifyMe.subscribedBody")})]}):e.jsxs("form",{className:"notify",onSubmit:F,"data-testid":"notify",children:[e.jsx("label",{className:"notify__label",htmlFor:"notify-email",children:t("notifyMe.label")}),e.jsxs("div",{className:"notify__row",children:[e.jsx("input",{id:"notify-email",className:"notify__input",type:"email",inputMode:"email",autoComplete:"email",placeholder:t("notifyMe.placeholder"),value:o,onChange:b=>m(b.target.value),"data-testid":"notify-email"}),e.jsx("button",{type:"submit",className:"notify__btn",disabled:!Ge(o)||h,"data-testid":"notify-submit",children:h?t("notifyMe.working"):t("notifyMe.cta")})]}),e.jsx(ce,{message:l})]}):e.jsx("div",{className:"notify","data-testid":"notify",children:e.jsx("button",{type:"button",className:"notify__signin",onClick:i,"data-testid":"notify-signin",children:t("notifyMe.signInCta")})})}const Ft=W.button`
|
|
3
|
-
display: flex;
|
|
4
|
-
align-items: center;
|
|
5
|
-
justify-content: center;
|
|
6
|
-
gap: 8px;
|
|
7
|
-
width: 100%;
|
|
8
|
-
height: 40px;
|
|
9
|
-
padding: 0 12px;
|
|
10
|
-
border: 2px solid #c640cd;
|
|
11
|
-
border-radius: 8px;
|
|
12
|
-
background: transparent;
|
|
13
|
-
color: ${K.colors.accent};
|
|
14
|
-
font-family: ${K.font.sans};
|
|
15
|
-
font-weight: 600;
|
|
16
|
-
font-size: 15px;
|
|
17
|
-
line-height: 24px;
|
|
18
|
-
letter-spacing: 0.46px;
|
|
19
|
-
text-transform: uppercase;
|
|
20
|
-
cursor: not-allowed;
|
|
21
|
-
opacity: 0.55;
|
|
22
|
-
transition: opacity 0.15s ease;
|
|
23
|
-
|
|
24
|
-
&:hover,
|
|
25
|
-
&:focus-visible {
|
|
26
|
-
opacity: 0.75;
|
|
27
|
-
}
|
|
28
|
-
&:focus-visible {
|
|
29
|
-
outline: 2px solid ${K.colors.accent};
|
|
30
|
-
outline-offset: 2px;
|
|
31
|
-
}
|
|
32
|
-
`;function Lt({item:s}){return e.jsx(Xe,{block:!0,content:t("makeOffer.comingSoon"),onShow:()=>D("Shop Make Offer Tooltip Shown",{contractAddress:s.contractAddress,itemId:s.itemId}),children:e.jsxs(Ft,{type:"button","aria-disabled":!0,onClick:n=>n.preventDefault(),"data-testid":"make-offer",children:[e.jsx(T,{name:"offer",size:20,"aria-hidden":!0}),e.jsx("span",{children:t("makeOffer.cta")})]})})}const Tt=W(Ea)`
|
|
33
|
-
display: flex;
|
|
34
|
-
flex-direction: column;
|
|
35
|
-
overflow: hidden;
|
|
36
|
-
gap: 1px;
|
|
37
|
-
background: ${K.colors.lineStrong};
|
|
38
|
-
`;function Dt({contractAddress:s,name:n,items:i,className:o}){const m=oe();if(!s||!n)return null;const h=(i??[]).map(c=>c.thumbnail).filter(c=>!!c).slice(0,4),w=h.slice(0,2),x=h.slice(2,4);return e.jsxs(Fa,{as:"button","data-link":!0,className:o,"data-testid":"creator",onClick:c=>{c.stopPropagation(),m(`/collection/${s}`)},children:[h.length>0?e.jsxs(Tt,{as:"span","data-avatar":!0,"data-testid":"creator-ava","aria-hidden":!0,children:[e.jsx("span",{className:`collection-collage__row${x.length===0?" collection-collage__row--full":""}`,children:w.map((c,l)=>e.jsx("img",{src:c,alt:""},l))}),x.length>0?e.jsx("span",{className:"collection-collage__row",children:x.map((c,l)=>e.jsx("img",{src:c,alt:""},l))}):null]}):null,e.jsx(La,{"data-testid":"creator-name",children:Ta(n)})]})}const Rt=W(z)`
|
|
39
|
-
margin-top: 6px;
|
|
40
|
-
`,le=W(z)`
|
|
41
|
-
&& {
|
|
42
|
-
width: 100%;
|
|
43
|
-
height: 48px;
|
|
44
|
-
font-size: 15px;
|
|
45
|
-
font-weight: 600;
|
|
46
|
-
letter-spacing: 0.46px;
|
|
47
|
-
display: flex;
|
|
48
|
-
align-items: center;
|
|
49
|
-
justify-content: center;
|
|
50
|
-
gap: 8px;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
${K.media.down("lg")} {
|
|
54
|
-
.item-detail__ctas--dual && {
|
|
55
|
-
flex: 1 1 auto;
|
|
56
|
-
width: auto;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
`,qt=W("div")`
|
|
60
|
-
display: flex;
|
|
61
|
-
flex-direction: column;
|
|
62
|
-
gap: 10px;
|
|
63
|
-
width: 100%;
|
|
64
|
-
`,Bt=W(z)`
|
|
65
|
-
&& {
|
|
66
|
-
width: 100%;
|
|
67
|
-
height: 44px;
|
|
68
|
-
}
|
|
69
|
-
`,$t=W("p")`
|
|
70
|
-
margin: 4px 0 0;
|
|
71
|
-
font-size: 13px;
|
|
72
|
-
color: ${K.colors.muted};
|
|
73
|
-
|
|
74
|
-
a {
|
|
75
|
-
color: ${K.colors.accent};
|
|
76
|
-
font-weight: 600;
|
|
77
|
-
}
|
|
78
|
-
`;function Ot(s){return Object.values(G.Rarity).includes(s)}function zt(s){return s==="male"?t("itemDetail.genderMale"):s==="female"?t("itemDetail.genderFemale"):s==="unisex"?t("itemDetail.genderUnisex"):null}function He(s){return s.wearableCategory?s.wearableCategory.replace(/_/g," "):s.category==="emote"?t("itemDetail.categoryEmote"):t("itemDetail.categoryWearable")}function ps(){var $e;const{contractAddress:s,tokenId:n}=pa(),{state:i}=ya(),o=oe(),m=!!(i!=null&&i.market),h=(i==null?void 0:i.marketPriceCredits)??null,w=ze(r=>r.add),x=ze(r=>r.items),c=Ke(r=>r.toggle),{session:l}=X(),[a,j]=d.useState(()=>i!=null&&i.item?{...i.item,tradeId:i.tradeId??i.item.tradeId}:{id:`${s}-${n}`,name:"",creator:"",contractAddress:s??"",itemId:null,category:"wearable",rarity:"common",network:"MATIC",chainId:Ne.chainId,thumbnail:"",priceCredits:0,gender:null,isSmart:!1,tokenId:n??void 0,tradeId:i==null?void 0:i.tradeId}),[y,N]=d.useState(!1),[F,b]=d.useState(!!(i!=null&&i.resumeBuy));d.useEffect(()=>{i!=null&&i.resumeBuy&&N(!0)},[i==null?void 0:i.resumeBuy]);const{data:f=[],isFetched:g}=B({queryKey:["collection-items",a.contractAddress],enabled:!!a.contractAddress,queryFn:()=>Ha(a.contractAddress,{first:20}).then(r=>r.items)}),I=a.available==null&&!a.tokenId,{data:M,isLoading:ee}=B({queryKey:["shop-item",a.contractAddress,n],enabled:!m&&!!a.contractAddress&&!!n&&(!(i!=null&&i.item)||I),queryFn:()=>Ja(a.contractAddress,n)});d.useEffect(()=>{M&&j(r=>r.tradeId?r.available!=null&&r.wearableCategory?r:{...r,available:r.available??M.available,wearableCategory:r.wearableCategory??M.wearableCategory}:{...M})},[M]);const[H,me]=d.useState(!1),{data:$=""}=B({queryKey:["item-desc",a.contractAddress,a.itemId],enabled:!!a.contractAddress&&!!a.itemId,staleTime:5*6e4,queryFn:()=>Ya(a.contractAddress,a.itemId)}),{data:L}=B({queryKey:["collection-meta",a.contractAddress],enabled:!!a.contractAddress,staleTime:5*6e4,queryFn:()=>Xa(a.contractAddress)});d.useEffect(()=>{if(a.name||M||f.length===0)return;const r=n&&f.find(k=>k.tokenId===n||k.itemId===n)||f.find(k=>k.contractAddress===a.contractAddress);r&&j(k=>({...r,tradeId:k.tradeId??r.tradeId}))},[f,M]);const ae=d.useMemo(()=>{const r=new Set,k=[];for(const P of f){if(P.id===a.id||a.itemId&&P.itemId===a.itemId||a.tokenId&&P.tokenId===a.tokenId)continue;const Oe=`${P.contractAddress}-${P.itemId??P.tokenId??P.id}`;r.has(Oe)||(r.add(Oe),k.push(P))}return k},[f,a.id,a.itemId,a.tokenId]),{data:te,isLoading:u}=B({queryKey:["detail-trade",a.id,a.tradeId,a.contractAddress,a.itemId],enabled:!!a.contractAddress,queryFn:async()=>{if(a.tradeId)return a.tradeId;if(a.itemId){const r=await Za(a.contractAddress,a.itemId);return(r==null?void 0:r.id)??null}return null}}),C=a.tradeId??te??void 0,_=!!C,{data:S}=jt(m),v=d.useMemo(()=>{if(!m||!(i!=null&&i.item))return null;const r=i.item;return r.manaWei?{tradeId:r.tradeId??r.id,listingType:"primary",contractAddress:r.contractAddress,itemId:r.itemId??"",name:r.name,thumbnail:r.thumbnail,rarity:r.rarity,category:r.category,wearableCategory:r.wearableCategory??null,creator:r.creator,manaWei:r.manaWei,available:1,network:r.network,chainId:r.chainId,createdAt:0}:null},[m,i==null?void 0:i.item]),R=m&&h!=null&&!!S&&!!v,V=Da({priceCredits:a.priceCredits,compareAtCredits:a.compareAtCredits,saleEndsAt:a.saleEndsAt}),A=d.useMemo(()=>({...a,tradeId:C,id:C??a.id}),[a,C]),J=x.some(r=>r.id===A.id),O=!A.tokenId,se=(($e=x.find(r=>r.id===A.id))==null?void 0:$e.quantity)??0,U=O&&typeof a.available=="number"&&se>=a.available,q=Ke(r=>!!r.items[a.id]),we=d.useRef(null);d.useEffect(()=>{!a.name||u||we.current===a.id||(we.current=a.id,D("Shop Viewed Item",{...Ra(a),for_sale:_}),qa(a))},[a.id,a.name,u,_]);const ie=`${s}/${n}`,ke=d.useRef(ie);d.useEffect(()=>{ke.current!==ie&&(ke.current=ie,i!=null&&i.item&&j({...i.item,tradeId:i.tradeId??i.item.tradeId}),typeof window<"u"&&window.scrollTo({top:0,behavior:"smooth"}))},[ie]);function ea(){!_||he||u||!O&&J||U||w(A,"item_detail")}const ue=Ot(a.rarity)?a.rarity:G.Rarity.COMMON,Ie=zt(a.gender),Ce=Ba(a),Se=$a(a.gender),aa=_&&V,ta=t("itemDetail.moreFromCollection"),he=Oa(a,l==null?void 0:l.address),re=ve(),[sa,Ae]=d.useState(!1),[ia,Me]=d.useState(!1),[Y,Pe]=d.useState(!1),[ra,Ee]=d.useState(null),{data:p,isLoading:na}=B({queryKey:["owned-token",a.contractAddress,a.tokenId,l==null?void 0:l.address],enabled:!m&&!!(l!=null&&l.address)&&!!a.contractAddress&&!!a.tokenId,queryFn:()=>l?et(l.address,a.contractAddress,a.tokenId):null});d.useEffect(()=>{p&&j(r=>r.name?r.issuedId?r:{...r,issuedId:p.issuedId}:{id:p.id,name:p.name,creator:"",contractAddress:p.contractAddress,itemId:p.itemId,category:p.category,rarity:p.rarity??"common",network:p.network,chainId:p.chainId,thumbnail:p.image,priceCredits:p.listingPrice??0,gender:null,isSmart:!1,tokenId:p.tokenId,issuedId:p.issuedId,tradeId:p.tradeId})},[p]);const{data:_e}=B({queryKey:["publishable-item",a.contractAddress,a.itemId,l==null?void 0:l.address],enabled:he&&!!l&&!!a.itemId,queryFn:async()=>l?(await st(l.address,l.identity)).find(k=>k.contractAddress.toLowerCase()===a.contractAddress.toLowerCase()&&k.blockchainItemId===a.itemId)??null:null}),Q=!!p,pe=!m&&(he||Q),la=Q?!!(p!=null&&p.isOnSale):_,ye=Q?p==null?void 0:p.tradeId:C,Fe=Q?!!p:!!_e;async function Le(){await Promise.all([re.invalidateQueries({queryKey:["owned-token",a.contractAddress,a.tokenId]}),re.invalidateQueries({queryKey:["detail-trade"]}),re.invalidateQueries({queryKey:["shop-item"]}),re.invalidateQueries({queryKey:["collection-sale-state"]})])}async function Te(r={}){if(!l||!ye)return!1;Ee(null),Pe(!0);try{const k=await Ga(ye);return await at({trade:k,signer:l.signer}),r.silent||Je.success(t("myAssets.removedFromSale",{name:a.name})),await Le(),!0}catch(k){const P=yt(k);return P||Z(k,{flow:"remove-listing",tradeId:ye}),Ee(P?t("getCredits.errorCanceled"):t("myAssets.removeListingError")),!1}finally{Pe(!1)}}function De(){Q?Ae(!0):Me(!0)}async function da(){await Te({silent:!0})&&De()}function Re(){Ae(!1),Me(!1),Le()}const qe=_?u?t("itemDetail.checking"):U?t("itemDetail.maxInCart"):!O&&J?t("assetCard.inCart"):t("assetCard.addToCart"):t("itemDetail.notForSale"),oa=typeof a.available=="number"&&a.available>0&&!a.tokenId&&!m,ca=!m&&!a.tokenId&&a.available===0,ma=!pe&&_&&!m,ua=m||!pe,ha=ee||!!a.contractAddress&&!g||!a.name&&na,Be=!a.name&&!ha,_a=/^https?:\/\//i.test(a.thumbnail);return za(Be?{title:t("seo.item.notFoundTitle"),noindex:!0}:a.name?{title:a.name,description:$||t("seo.item.fallbackDescription",{name:a.name,rarity:a.rarity,category:He(a),creator:Nt(a.creator)}),image:_a?a.thumbnail:void 0,type:"product"}:{}),Be?e.jsxs("div",{className:"item-detail item-detail--notfound",children:[e.jsx(T,{name:"cart",className:"item-detail__notfound-ico"}),e.jsx("h1",{className:"item-detail__notfound-title",children:t("itemDetail.notAvailableTitle")}),e.jsx("p",{className:"muted",children:t("itemDetail.notAvailableBody")}),e.jsx(Rt,{variant:"purple",onClick:()=>o("/assets"),children:t("notFound.cta")})]}):e.jsxs("div",{className:"item-detail",children:[e.jsxs("nav",{className:"item-detail__crumbs","aria-label":t("itemDetail.breadcrumbAria"),children:[e.jsx("button",{className:"item-detail__crumb-link",onClick:()=>o("/assets"),children:t("nav.collectibles")}),e.jsx("span",{className:"item-detail__crumb-sep",children:"/"}),e.jsx("span",{className:"item-detail__crumb-current",children:a.name||t("itemDetail.itemFallback")})]}),e.jsxs("div",{className:"item-detail__main",children:[e.jsxs("div",{className:"item-detail__preview","data-testid":"item-preview",children:[a.name?e.jsx(At,{item:a}):e.jsx("div",{className:"item-preview__loading","aria-busy":"true","aria-label":t("itemPreview.loading"),children:e.jsx("span",{className:"skeleton item-preview__skeleton","aria-hidden":!0})}),e.jsx("button",{className:`item-detail__fav item-detail__fav--preview${q?" is-on":""}`,onClick:()=>c(a),"aria-pressed":q,"aria-label":q?t("assetCard.removeFromFavorites"):t("assetCard.addToFavorites"),children:e.jsx(T,{name:q?"heart-solid":"heart",size:18})})]}),e.jsx("div",{className:"item-detail__info",children:a.name?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"item-detail__info-head",children:[e.jsx("h1",{className:"item-detail__title",children:a.name}),e.jsx("button",{className:`item-detail__fav${q?" is-on":""}`,onClick:()=>c(a),"aria-pressed":q,"aria-label":q?t("assetCard.removeFromFavorites"):t("assetCard.addToFavorites"),children:e.jsx(T,{name:q?"heart-solid":"heart",size:18})})]}),e.jsxs("div",{className:"item-detail__chips",children:[e.jsx("span",{className:"chip chip--rarity",style:{background:Va(ue),color:Wa(ue)},title:Ka(a.rarity),children:a.rarity}),e.jsxs("span",{className:"chip item-detail__chip",children:[Ce?e.jsx(T,{name:Ce,size:18,color:"var(--text-2)"}):null,He(a)]}),Ie?e.jsxs("span",{className:"chip item-detail__chip",children:[Se?e.jsx(T,{name:Se,size:18,color:"var(--text-2)"}):null,Ie]}):null,a.issuedId?e.jsxs("span",{className:"chip item-detail__chip","data-testid":"detail-issued",children:["#",a.issuedId]}):null]}),$?e.jsxs("div",{className:"item-detail__section item-detail__description",children:[e.jsx("div",{className:"item-detail__label",children:t("itemDetail.description")}),e.jsx("p",{className:`item-detail__desc-text${H?" is-expanded":""}`,children:$}),$.length>140?e.jsx("button",{className:"link item-detail__desc-toggle",onClick:()=>me(r=>!r),children:H?t("itemDetail.showLess"):t("itemDetail.readMore")}):null]}):null,a.creator||L!=null&&L.name?e.jsxs("div",{className:"item-detail__meta",children:[a.creator?e.jsxs("div",{className:"item-detail__meta-col",children:[e.jsx("div",{className:"item-detail__label",children:t("itemDetail.creator")}),e.jsx(Ua,{address:a.creator,className:"item-detail__creator",linkToProfile:!0,hidePrefix:!0})]}):null,L!=null&&L.name?e.jsxs("div",{className:"item-detail__meta-col item-detail__meta-col--collection",children:[e.jsx("div",{className:"item-detail__label",children:t("itemDetail.collection")}),e.jsx(Dt,{contractAddress:a.contractAddress,name:L.name,items:f,className:"item-detail__creator"})]}):null]}):null,e.jsx("hr",{className:"item-detail__divider"}),e.jsx("div",{className:"item-detail__price-block",children:e.jsxs("div",{className:"item-detail__price-row",children:[e.jsxs("div",{className:"item-detail__price-col",children:[m||_?e.jsx("div",{className:"item-detail__price-label",children:t("itemDetail.price")}):null,m?e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"item-detail__price item-detail__price--market",children:h==null?e.jsx("span",{className:"item-detail__price-value",children:"—"}):e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"item-detail__approx","aria-hidden":!0,children:"≈"}),e.jsx(E,{className:"item-detail__diamond"}),e.jsx("span",{className:"item-detail__price-value",children:h})]})}),e.jsx("div",{className:"item-detail__market-note muted",children:t("assetCard.marketPrice")})]}):_?aa?e.jsxs("div",{className:"item-detail__price item-detail__price--sale",children:[e.jsxs("span",{className:"item-detail__price",children:[e.jsx(E,{className:"item-detail__diamond"}),e.jsx("span",{className:"item-detail__price-value",children:a.priceCredits})]}),e.jsxs("span",{className:"item-detail__price-was",children:[e.jsx(E,{className:"item-detail__diamond item-detail__diamond--was"}),a.compareAtCredits]}),We(a.compareAtCredits,a.priceCredits)>0?e.jsx("span",{className:"item-detail__sale-badge",children:t("assetCard.saleWithDiscount",{pct:We(a.compareAtCredits,a.priceCredits)})}):null,e.jsx(Qa,{endsAt:a.saleEndsAt,className:"item-detail__countdown"})]}):e.jsxs("div",{className:"item-detail__price",children:[e.jsx(E,{className:"item-detail__diamond"}),e.jsx("span",{className:"item-detail__price-value",children:a.priceCredits})]}):e.jsxs("div",{className:"item-detail__price item-detail__price--none",children:[e.jsx("span",{children:t("itemDetail.notForSale")}),e.jsx(Xe,{content:t("itemDetail.notForSaleHint"),children:e.jsx("span",{className:"item-detail__price-info",tabIndex:0,role:"img","aria-label":t("itemDetail.notForSaleHint"),children:e.jsx(T,{name:"info",size:14})})})]})]}),oa?e.jsxs("div",{className:"item-detail__stock-col",children:[e.jsx("div",{className:"item-detail__price-label",children:t("itemDetail.stock")}),e.jsxs("div",{className:"item-detail__stock-value",children:[(a.available??0).toLocaleString(),"/",G.Rarity.getMaxSupply(ue).toLocaleString()]})]}):ca?e.jsx("div",{className:"item-detail__stock-col",children:e.jsx("div",{className:"item-detail__stock-value item-detail__stock-value--out","data-testid":"out-of-stock",children:t("itemDetail.outOfStock")})}):null]})}),e.jsx("div",{className:`item-detail__ctas${ua?" item-detail__ctas--buttons":""}${ma?" item-detail__ctas--dual":""}`,children:m?e.jsxs(le,{variant:"purple",onClick:()=>N(!0),disabled:!R,children:[e.jsx("span",{className:"item-detail__cta-label",children:t("assetCard.buyNow")}),h!=null?e.jsxs("span",{className:"item-detail__cta-price","aria-hidden":!0,children:[e.jsx(E,{className:"item-detail__cta-diamond"}),h]}):null]}):pe?e.jsxs(qt,{"data-testid":"manage-actions",children:[e.jsx(ce,{message:ra}),la?e.jsxs(e.Fragment,{children:[e.jsx(le,{variant:"purple",onClick:()=>void da(),disabled:Y||!Fe,children:e.jsx("span",{className:"item-detail__cta-label",children:Y?t("itemDetail.manageWorking"):t("itemDetail.manageUpdatePrice")})}),e.jsx(Bt,{variant:"ghost",onClick:()=>void Te(),disabled:Y,children:Y?t("myAssets.removing"):t("itemDetail.manageRemove")})]}):e.jsx(le,{variant:"purple",onClick:()=>{Q&&D("Shop Started Listing",{listing_type:"secondary",item_id:a.itemId??a.tokenId??null}),De()},disabled:Y||!Fe,children:e.jsx("span",{className:"item-detail__cta-label",children:t("itemDetail.manageList")})}),e.jsxs($t,{children:[t("itemDetail.ownItemPrefix")," ",e.jsx(fa,{to:"/my-assets",children:t("nav.myAssets")}),t("itemDetail.ownItemSuffix")]})]}):_?e.jsxs(e.Fragment,{children:[e.jsxs(le,{variant:"purple",onClick:()=>N(!0),disabled:u,children:[e.jsx("span",{className:"item-detail__cta-label",children:t("assetCard.buyNow")}),e.jsxs("span",{className:"item-detail__cta-price","aria-hidden":!0,children:[e.jsx(E,{className:"item-detail__cta-diamond"}),a.priceCredits]})]}),e.jsxs("button",{className:"item-detail__addcart",onClick:ea,disabled:u||(O?U:J),"aria-label":qe,children:[e.jsx(T,{name:"cart-solid"}),e.jsx("span",{className:"item-detail__addcart-label",children:qe})]})]}):e.jsxs(e.Fragment,{children:[e.jsx(Et,{item:a}),e.jsx(Lt,{item:a})]})})]}):e.jsx(Kt,{})})]}),e.jsx(_t,{title:ta,items:ae,onViewAll:a.contractAddress?()=>o(`/collection/${a.contractAddress}`):void 0}),y&&m&&v&&S?e.jsx(vt,{listing:v,rate:S,onClose:()=>N(!1),onSold:()=>N(!1)}):y&&!m?e.jsx(wt,{item:A,resume:F,onClose:()=>{N(!1),b(!1)}}):null,sa&&p&&l?e.jsx(It,{asset:p,session:l,onClose:Re}):null,ia&&_e&&l?e.jsx(tt,{item:_e,session:l,onClose:Re}):null]})}function Kt(){return e.jsxs("div",{className:"item-detail__info-skel","aria-hidden":!0,children:[e.jsx("span",{className:"skeleton id-skel__title"}),e.jsxs("div",{className:"id-skel__chips",children:[e.jsx("span",{className:"skeleton id-skel__chip"}),e.jsx("span",{className:"skeleton id-skel__chip"})]}),e.jsx("span",{className:"skeleton id-skel__line"}),e.jsx("span",{className:"skeleton id-skel__line id-skel__line--short"}),e.jsx("hr",{className:"item-detail__divider"}),e.jsx("span",{className:"skeleton id-skel__price"}),e.jsx("span",{className:"skeleton id-skel__btn"})]})}export{ps as ItemDetail,ps as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./react-BrLDncxD.js";import{T as m,l as t}from"./index-P7Sau0I5.js";import{u as o}from"./useTheme-Da_Gtdq6.js";function a(){const e=o(t);return e[m]||e}export{a as u};
|