@dcl/shop 0.3.0 → 0.4.0
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/{Activity-CysvRMDH.js → Activity-CSDWiFkq.js} +1 -1
- package/_assets/{AnimatedBackground-1KvWirPP.js → AnimatedBackground-vKrEOHA5.js} +1 -1
- package/_assets/{Assets-CmA7g8ft.js → Assets-Cogahyqe.js} +3 -3
- package/_assets/{Assets.styles-BwMj4485.js → Assets.styles-B2EWL6JB.js} +1 -1
- package/_assets/{Authorizations-CfvVeEJl.js → Authorizations-BrKYlkZG.js} +1 -1
- package/_assets/{Cart-CYHKPPD-.js → Cart-W8w3sCuV.js} +5 -5
- package/_assets/{CircularProgress-oGg4qqHc.js → CircularProgress--GC-6I6k.js} +1 -1
- package/_assets/{Collection-Dmap3sR_.js → Collection-D16pjJSe.js} +1 -1
- package/_assets/{CollectionCarousel-DiADjTg-.js → CollectionCarousel-BeuBL17J.js} +77 -77
- package/_assets/{Creator-DB4BIeTa.js → Creator-BLsHzXRL.js} +1 -1
- package/_assets/{ErrorNotice-CBx78pQu.js → ErrorNotice-Cvc0nTjw.js} +1 -1
- package/_assets/{ExchangeController-DOvKzvyb.js → ExchangeController-DoFEzXko.js} +1 -1
- package/_assets/{GetCredits-Ch_OO41P.js → GetCredits-bxJh6m8F.js} +94 -130
- package/_assets/{HelpersUtil-CFCkU-g3.js → HelpersUtil-BFgierZ-.js} +1 -1
- package/_assets/{ImportListings-BGmtSIDb.js → ImportListings-BwORJ3CC.js} +13 -13
- package/_assets/{ItemDetail-ramYOGDR.js → ItemDetail-PoeIzOPp.js} +194 -194
- package/_assets/{ItemPreview.styles-D8aGYVBK.js → ItemPreview.styles-DtAUND9N.js} +1 -1
- package/_assets/{LoadMore-BSE8BKwI.js → LoadMore-DsWSQHxD.js} +1 -1
- package/_assets/ManaPricingBanner.styles-CF0iOeeS.js +74 -0
- package/_assets/{MenuList-qnDzTtfz.js → MenuList-DNOqfxHx.js} +1 -1
- package/_assets/{MyAssets-CgneL-KA.js → MyAssets-2XwaE-SE.js} +4 -4
- package/_assets/{MyFavorites-DrPT--am.js → MyFavorites-DIi3ztNe.js} +1 -1
- package/_assets/{NotFound-4IJj-QH6.js → NotFound-jHtQUp44.js} +1 -1
- package/_assets/{NotificationsBell-BOg2j5-7.js → NotificationsBell-By0uu4SI.js} +1 -1
- package/_assets/{OutfitDetail-DAfw3jDe.js → OutfitDetail-BQr6vhnT.js} +1 -1
- package/_assets/{OutfitPreview-DMQpfBpS.js → OutfitPreview-D6Z7-XEK.js} +1 -1
- package/_assets/{OutfitStudio-qASOqFO4.js → OutfitStudio-BFWU775v.js} +1 -1
- package/_assets/{StoreSettings-CjbyuHVf.js → StoreSettings-BJTpsKoX.js} +1 -1
- package/_assets/{Success-Ba2GyRY_.js → Success-CIQKaiOo.js} +1 -1
- package/_assets/{SwapController-B823Ep4J.js → SwapController-XcLKHFDT.js} +1 -1
- package/_assets/{Tooltip-2XcUkoOj.js → Tooltip-fS4VCxQs.js} +1 -1
- package/_assets/{TradeService-lYuRlk4v.js → TradeService-BgfeT0JQ.js} +1 -1
- package/_assets/{W3MFrameProviderSingleton-B8ZAc5Tp.js → W3MFrameProviderSingleton-BJE-tnmd.js} +3 -3
- package/_assets/{WebCryptoP256-CrjjL3U7.js → WebCryptoP256-P_MkVOZf.js} +1 -1
- package/_assets/authorizations-Bm65kFBw.js +1 -0
- package/_assets/{basic-3OIT7lDP.js → basic-BzdDurZu.js} +1 -1
- package/_assets/{biconomy-CLvfOfCg.js → biconomy-BHLIxKXm.js} +1 -1
- package/_assets/{browseLayout.styles-DCwE16ZG.js → browseLayout.styles-D_JQHeMK.js} +4 -4
- package/_assets/{builder-CoZ9B86k.js → builder-CPpn-LV6.js} +1 -1
- package/_assets/buy-CfVy6xwA.js +1 -0
- package/_assets/{buy-gasless-uIQiLsX8.js → buy-gasless-DmFIjDH7.js} +1 -1
- package/_assets/categories-D2JgaepG.js +448 -0
- package/_assets/{ccip-C8TW-3ey.js → ccip-BGuL2CTW.js} +1 -1
- package/_assets/{ccip-C4f9EXfY.js → ccip-japHsC-d.js} +1 -1
- package/_assets/{clsx-BsYHeX03.js → clsx-DY37pDvc.js} +1 -1
- package/_assets/{controller-ASkKeRkX.js → controller-CEuTNpMI.js} +2 -2
- package/_assets/{core-X_wu6_Dy.js → core-DFTtNj6Y.js} +4 -4
- package/_assets/{createSvgIcon-D4cpIqvx.js → createSvgIcon-BFo-10ds.js} +3 -3
- package/_assets/{custom-BVAi4D5H.js → custom-DyS8vC8K.js} +1 -1
- package/_assets/{data-capture-C23iRBhs.js → data-capture-CpqP5gpO.js} +1 -1
- package/_assets/{email-CB03fcCQ.js → email-DOkwtMrW.js} +1 -1
- package/_assets/{embedded-wallet-CnMDk9db.js → embedded-wallet-BI0I-FyI.js} +1 -1
- package/_assets/{emotion-styled.browser.esm-CNluusdx.js → emotion-styled.browser.esm-nmKSs9QV.js} +1 -1
- package/_assets/{engine-DaJGLPH7.js → engine-BsCDGGhp.js} +1 -1
- package/_assets/{errors-CJ4NHTPm.js → errors-CVWX9epA.js} +1 -1
- package/_assets/{estimate-l1-fee-DC2eYWPQ.js → estimate-l1-fee-BwVQYvPZ.js} +1 -1
- package/_assets/{execute-vh_I47EG.js → execute-DCjeHtk2.js} +2 -2
- package/_assets/{features-i2gsSk7q.js → features-DmQF08Nd.js} +1 -1
- package/_assets/{fetchTokenMetadata-DpicXKCe.js → fetchTokenMetadata-DtvlyEpN.js} +2 -2
- package/_assets/{field.styles-DPC95Ntd.js → field.styles-ZqzDOrCY.js} +1 -1
- package/_assets/{get-ecosystem-wallet-info-B8_se1pi.js → get-ecosystem-wallet-info-glXHSBBX.js} +1 -1
- package/_assets/{getBalance-Cee2d5fc.js → getBalance-D4uOuyXp.js} +1 -1
- package/_assets/{getNFT-CUD-atXT.js → getNFT-D9u1poHS.js} +1 -1
- package/_assets/{getNFT-BjnrEAq8.js → getNFT-VYQvQv4K.js} +1 -1
- package/_assets/{getThemeProps-B71MHgCC.js → getThemeProps-BOJ8W9dy.js} +1 -1
- package/_assets/{grid.styles-q_RkLJKv.js → grid.styles-C92STzz7.js} +1 -1
- package/_assets/{hashTypedData-Bclxfb96.js → hashTypedData-CU4XEihs.js} +1 -1
- package/_assets/{hashTypedData-CiuZE5MB.js → hashTypedData-Cmk_4l7W.js} +1 -1
- package/_assets/hero-credits-outfits-DeMMQYZj.webp +0 -0
- package/_assets/{in-app-DoTVgkA7.js → in-app-n2C_GYjN.js} +1 -1
- package/_assets/{in-app-wallet-calls-aTpQmtYp.js → in-app-wallet-calls-BH4EHvoE.js} +1 -1
- package/_assets/{index-DJ0Ox_g6.js → index-1DlQc04C.js} +1 -1
- package/_assets/{index-oYINO7Gh.js → index-1E3TZOEp.js} +3 -3
- package/_assets/{index-ZtNObKUx.js → index-3G1ZZRHy.js} +1 -1
- package/_assets/{index-C_quGuYS.js → index-5ZQ75r5A.js} +2 -2
- package/_assets/{index-BOqO3K08.js → index-5oJAYQpS.js} +1 -1
- package/_assets/{index-DnUnGNK1.js → index-8ahFN9pV.js} +1 -1
- package/_assets/{index-BLIOngWK.js → index-9ZSFZyk5.js} +1 -1
- package/_assets/{index-CkdrAVd7.js → index-B-0owZIE.js} +1 -1
- package/_assets/{index-KhxRGpab.js → index-B-2A_xJK.js} +1 -1
- package/_assets/index-B0wrSWVL.js +3467 -0
- package/_assets/{index-DxbeSgwP.js → index-B33pX4sx.js} +1 -1
- package/_assets/{index-CnAxZm7a.js → index-B6HLteu2.js} +1 -1
- package/_assets/{index-C-ZPerkC.js → index-B95j5ECm.js} +1 -1
- package/_assets/{index-D2Hh-irJ.js → index-BAGHoKjd.js} +1 -1
- package/_assets/{index-BdZJNMhf.js → index-BAKuuHpY.js} +1 -1
- package/_assets/{index-Br-QxSL4.js → index-BBLwTza9.js} +1 -1
- package/_assets/{index-CLm5_lcW.js → index-BFbvmloZ.js} +1 -1
- package/_assets/{index-DREmVGyP.js → index-BKB9eVo_.js} +1 -1
- package/_assets/{index-CShk5nTD.js → index-Bdk6ierZ.js} +1 -1
- package/_assets/{index-pDIZRYxP.js → index-BmtMJnoP.js} +2 -2
- package/_assets/{index-DzoYWAIJ.js → index-Bnnl1_Pn.js} +1 -1
- package/_assets/{index-CHLJVbwu.js → index-BpfebiBi.js} +1 -1
- package/_assets/{index-Dqt4TaYh.js → index-BvzZi8lQ.js} +1 -1
- package/_assets/{index-BnVjsoyV.js → index-C1Zza7kR.js} +3 -3
- package/_assets/{index-LbRdNAf3.js → index-C75VmoUV.js} +1 -1
- package/_assets/{index-CiqC5vqm.js → index-CCQWBULG.js} +1 -1
- package/_assets/{index-DAKpmmlR.js → index-CDzrsoju.js} +1 -1
- package/_assets/{index-DpAZRpHS.js → index-CFJ4759x.js} +1 -1
- package/_assets/{index-DmmqNlbI.js → index-CMiDANew.js} +1 -1
- package/_assets/{index-6U0_groo.js → index-CNek90qs.js} +1 -1
- package/_assets/{index-BIMSqj0E.js → index-CS26D5br.js} +1 -1
- package/_assets/index-D-NhBWWr.css +1 -0
- package/_assets/{index-Da9c_8XH.js → index-DCJFwzag.js} +1 -1
- package/_assets/{index-B8WxnCSZ.js → index-DCkPd79h.js} +1 -1
- package/_assets/{index-AvMVq3p5.js → index-DO-41U6s.js} +1 -1
- package/_assets/{index-Zni41xRh.js → index-DU7iVDBh.js} +3 -3
- package/_assets/{index-X-5FVXow.js → index-DUOePrjP.js} +1 -1
- package/_assets/{index-BmR9lQvd.js → index-DWyeO73d.js} +1 -1
- package/_assets/{index-CqqbmEIM.js → index-Das01MWO.js} +2 -2
- package/_assets/{index-CKgjOb17.js → index-DcW0aOo_.js} +1 -1
- package/_assets/{index-D2cHV9P4.js → index-Dg3cba8i.js} +1 -1
- package/_assets/{index-umhEn8if.js → index-DgIUvj1u.js} +1 -1
- package/_assets/{index-B-yk4_og.js → index-Drzr7GIe.js} +1 -1
- package/_assets/{index-DhW6Eiq4.js → index-DuYquyJk.js} +1 -1
- package/_assets/{index-grey-Hql.js → index-Dyb9tM0L.js} +1 -1
- package/_assets/{index-CQd88f4P.js → index-S5ytn1G_.js} +1 -1
- package/_assets/{index-pkIYUyEs.js → index-X1g5-mc1.js} +2 -2
- package/_assets/{index-Bm4qVnUT.js → index-YlEZ0MB-.js} +1 -1
- package/_assets/{index-Dk_Ivei2.js → index-gO1p5U4e.js} +1 -1
- package/_assets/{index-BMHjpFTY.js → index-iVhRHvGC.js} +1 -1
- package/_assets/{index-5tjsFjOD.js → index-lc1BgLRJ.js} +1 -1
- package/_assets/{index-tvenjK5z.js → index-x_f1XpFN.js} +1 -1
- package/_assets/{index.es-C5-qOo53.js → index.es-CYrm9JiK.js} +4 -4
- package/_assets/{index.es-C4q67lvL.js → index.es-D-Hj-yaE.js} +1 -1
- package/_assets/{index.es-gI39JHkd.js → index.es-DlCKcYQh.js} +1 -1
- package/_assets/{localBatchGatewayRequest-CYWicxBl.js → localBatchGatewayRequest-D-M3uJjn.js} +1 -1
- package/_assets/{mana-convert-C239nuRR.js → mana-convert-XtWFaGCt.js} +1 -1
- package/_assets/{mana-rate-CWXyJ6Qt.js → mana-rate-CLS7fjKR.js} +1 -1
- package/_assets/{networks-CdC9lKkb.js → networks-DLkt_HOu.js} +1 -1
- package/_assets/{onramp-B6zv6owZ.js → onramp-B9C9zg8X.js} +1 -1
- package/_assets/{openzeppelin-fBZEbwFp.js → openzeppelin-Czmq9Q8z.js} +1 -1
- package/_assets/{parseNft-Dn6QDQHN.js → parseNft-Df0bG2_u.js} +2 -2
- package/_assets/{parseSignature-DecBV3iH.js → parseSignature-Cu3sQgfL.js} +1 -1
- package/_assets/{parseSignature-DAHrPk4v.js → parseSignature-nbJG9PDg.js} +3 -3
- package/_assets/{passkeys-KiBei2LX.js → passkeys-UkbavCkH.js} +1 -1
- package/_assets/{pay-with-exchange-D9SNWmjx.js → pay-with-exchange-BZkWaWxT.js} +1 -1
- package/_assets/{qr-overlay-2zAa6fld.js → qr-overlay-BE8jnAiO.js} +1 -1
- package/_assets/{receive-ChxNL97S.js → receive-B2e1QRi3.js} +1 -1
- package/_assets/{resolveImplementation-BNaLKkof.js → resolveImplementation-BBe0akeh.js} +1 -1
- package/_assets/{rpc-DBHsoP5N.js → rpc-iEVF2nz4.js} +1 -1
- package/_assets/{secp256k1-C8JTXBnF.js → secp256k1-Ba2kPpNf.js} +1 -1
- package/_assets/{secp256k1-C2pLUi5w.js → secp256k1-ClQ_G_RL.js} +1 -1
- package/_assets/{secp256k1-xOB6yMRi.js → secp256k1-e7mCjC3J.js} +1 -1
- package/_assets/{send-BLmLJ3eA.js → send-BOmHA5ER.js} +1 -1
- package/_assets/{send-batch-transaction-120lF45D.js → send-batch-transaction-C1STwRsa.js} +1 -1
- package/_assets/{send-eip712-transaction-B2w1ZAOY.js → send-eip712-transaction-Dy9FgG1n.js} +2 -2
- package/_assets/{send-gasless-transaction-oH9WEYVY.js → send-gasless-transaction-C66wRlKz.js} +2 -2
- package/_assets/{send-transaction-CLaO8DmY.js → send-transaction-CLuOLZ7t.js} +2 -2
- package/_assets/{sendMetaTransaction-OKd_ifNL.js → sendMetaTransaction-DvDr2bCi.js} +1 -1
- package/_assets/{sendRawTransaction-BP5hNXP6.js → sendRawTransaction-DqkFhazS.js} +3 -3
- package/_assets/{serializeTransaction--Dr7RtAU.js → serializeTransaction-BEOUomEz.js} +1 -1
- package/_assets/{session-proposal-CiYz-jZC.js → session-proposal-UXG0f185.js} +1 -1
- package/_assets/{session-request-Clv9A0oy.js → session-request-DIqK3WRK.js} +2 -2
- package/_assets/{signing-CJ5kWk7o.js → signing-DReJZKDs.js} +3 -3
- package/_assets/{socials-CeLfiCF9.js → socials-CdGrw0ok.js} +1 -1
- package/_assets/{swaps-DkDPQf9R.js → swaps-CycOd3sO.js} +1 -1
- package/_assets/{thirdweb-BcTKOQfU.js → thirdweb-D5w8-dkS.js} +3 -3
- package/_assets/{to-serializable-transaction-CVgEJJoF.js → to-serializable-transaction-C1TwC6Ti.js} +2 -2
- package/_assets/{trade-encoding-COAHYjJi.js → trade-encoding-Mw7kNWLf.js} +1 -1
- package/_assets/{transactionReceipt-dayojTpn.js → transactionReceipt-DyOMk-YN.js} +1 -1
- package/_assets/{transactions-BqxmWzZz.js → transactions-VmU1Fomk.js} +1 -1
- package/_assets/{useCreditPacks-CHpQ4LEN.js → useCreditPacks-D1yz9_D9.js} +1 -1
- package/_assets/{useInfiniteGrid-sc2vmuxU.js → useInfiniteGrid-C-7TbIWI.js} +1 -1
- package/_assets/useManaRate-6JYRR5Sm.js +1 -0
- package/_assets/{useSecondarySales-C8BuUV_s.js → useSecondarySales-BhfHOcZl.js} +1 -1
- package/_assets/{useStore-D3ONm_sP.js → useStore-DCWOq5iS.js} +1 -1
- package/_assets/{useTheme-D8ClSCiJ.js → useTheme-DoVQgCCM.js} +1 -1
- package/_assets/{verifyHash-tNHFcENz.js → verifyHash-B-nszbU3.js} +1 -1
- package/_assets/{w3m-modal-D0qE5VS7.js → w3m-modal-C9EOWDq3.js} +1 -1
- package/_assets/{w3m-modal-BYIDrkH-.js → w3m-modal-y9ZrKukQ.js} +1 -1
- package/_assets/{wait-for-tx-receipt-C3lxZWQH.js → wait-for-tx-receipt-DL1snjgl.js} +1 -1
- package/_assets/{wallets-BlFrUv2a.js → wallets-CExmmU6y.js} +5 -5
- package/_assets/{web-connector-DzEBomI8.js → web-connector-vE0RE6CB.js} +3 -3
- package/_assets/{writeContract-CaaID3Lc.js → writeContract-B0sDSczf.js} +1 -1
- package/_assets/{zoraTestnet-Da9dTQUp.js → zoraTestnet-B_NFi9S-.js} +1 -1
- package/index.html +11 -11
- package/package.json +2 -2
- package/_assets/ManaPricingBanner.styles-bQxgJp4R.js +0 -74
- package/_assets/authorizations-BeJcD0Ty.js +0 -1
- package/_assets/buy-5BIPC7Eq.js +0 -1
- package/_assets/categories-CmiNaFHh.js +0 -427
- package/_assets/hero-fashion-week-B9LOzkde.png +0 -0
- package/_assets/index-9_8O7Lhc.js +0 -3488
- package/_assets/index-BMzstP-8.css +0 -1
- package/_assets/promo-best-rated-emotes-C6kNvB-a.png +0 -0
- package/_assets/promo-week-selected-outfits-BBmkZYZx.png +0 -0
- package/_assets/useManaRate-Ceh_R3VR.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as k,ao as j,
|
|
1
|
+
import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as k,ao as j,bt as C,f as Y,k as G,I as Q,l as X,a as W,C as B,b as Z,Y as J,bR as F,ad as q}from"./index-B0wrSWVL.js";import{s as ee,i as U,A as H,g as K,r as te,m as ne,c as ae,M as ie,e as oe}from"./authorizations-Bm65kFBw.js";import{i as se}from"./errors-CVWX9epA.js";import{E as re}from"./ErrorNotice-Cvc0nTjw.js";import{a as ce}from"./buy-CfVy6xwA.js";import{g as de,a as le}from"./trade-encoding-Mw7kNWLf.js";import{s as pe,M as he,E as ue}from"./sendMetaTransaction-DvDr2bCi.js";import{I as xe,C as ge}from"./ethers-CtNGBird.js";const R="shop:resume_after_signin",fe=900*1e3;function dt(a){try{sessionStorage.setItem(R,JSON.stringify({...a,at:Date.now()}))}catch{}}function lt(a){let n;try{n=sessionStorage.getItem(R)}catch{return null}if(!n)return null;try{sessionStorage.removeItem(R)}catch{}let i;try{i=JSON.parse(n)}catch{return null}return!i||i.type!==a||typeof i.at!="number"||Date.now()-i.at>fe?null:i.type==="cart-checkout"?{type:"cart-checkout"}:{type:"item-buy",path:i.path}}function me(a,n){return(a+n-1n)/n}function be(a,n,i){return a<=0||n<=0?0n:a>=n?i:me(i*BigInt(a),BigInt(n))}function pt(a){var b,y,w;const n=Number.isFinite(a.priceCents)?Math.max(0,Math.trunc(a.priceCents)):0,i=Number.isFinite(a.balanceCents)?Math.max(0,Math.trunc(a.balanceCents)):0,s=a.priceManaWei>0n?a.priceManaWei:0n,l=a.manaBalanceWei>0n?a.manaBalanceWei:0n;if(n<=0)return{options:[],preferred:null,manaShortfall:null};const c=[];if(i>=n&&c.push({method:"credits",creditsCents:n,manaWei:0n}),s>0n&&i>0&&i<n){const d=n-i,f=be(d,n,s);l>=f&&c.push({method:"combined",creditsCents:i,manaWei:f})}s>0n&&l>=s&&c.push({method:"mana",creditsCents:0,manaWei:s});const p=((b=c.find(d=>d.method==="credits"))==null?void 0:b.method)??((y=c.find(d=>d.method==="combined"))==null?void 0:y.method)??((w=c.find(d=>d.method==="mana"))==null?void 0:w.method)??null,m=!c.some(d=>d.method==="mana"||d.method==="combined")&&s>0n&&l>0n?{manaWei:l,manaCents:ye(l,n,s),priceCents:n}:null;return{options:c,preferred:p,manaShortfall:m}}function ye(a,n,i){return Number(a*BigInt(n)/i)}function ht(a,n){let i=Number.isFinite(n)?Math.max(0,Math.trunc(n)):0;return a.map(s=>{const l=Number.isFinite(s)?Math.max(0,Math.trunc(s)):0,c=Math.min(l,i);return i-=c,c})}function M(a){return Number.isFinite(a)?Math.max(0,a)/10:0}function ut(a,n){return a.options.find(i=>i.method===n)??null}function xt(a,n){if(!Number.isFinite(a)||a<=0||n<=0n)return null;const i=a/10;return Number(n)/1e18/i}const T="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Group%201'%3e%3cpath%20id='Vector'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12%202L22%2012L12%2022L2%2012L12%202ZM12%204.8L19.2%2012L12%2019.2L4.8%2012L12%204.8ZM12%2015.6C12.9548%2015.6001%2013.8705%2015.2209%2014.5457%2014.5459C15.2209%2013.8708%2015.6003%2012.9552%2015.6004%2012.0004C15.6005%2011.0456%2015.2213%2010.1299%2014.5463%209.45471C13.8712%208.7795%2012.9556%208.40011%2012.0008%208.4C11.0461%208.4%2010.1304%208.77928%209.45525%209.45442C8.78012%2010.1295%208.40083%2011.0452%208.40083%2012C8.40083%2012.9548%208.78012%2013.8705%209.45525%2014.5456C10.1304%2015.2207%2011.0461%2015.6%2012.0008%2015.6H12Z'%20fill='white'/%3e%3cg%20id='Rectangle%201'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",we=e.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
gap: 12px;
|
|
@@ -35,7 +35,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
35
35
|
opacity: 0.6;
|
|
36
36
|
cursor: default;
|
|
37
37
|
}
|
|
38
|
-
`,
|
|
38
|
+
`,ve=e.button`
|
|
39
39
|
${_}
|
|
40
40
|
background: ${o.gradients.amethyst};
|
|
41
41
|
|
|
@@ -49,7 +49,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
49
49
|
&:hover:not(:disabled) {
|
|
50
50
|
background: ${o.colors.gray0};
|
|
51
51
|
}
|
|
52
|
-
`,
|
|
52
|
+
`,z=e.span`
|
|
53
53
|
display: inline-flex;
|
|
54
54
|
align-items: center;
|
|
55
55
|
gap: 6px;
|
|
@@ -66,7 +66,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
66
66
|
height: 24px;
|
|
67
67
|
background: ${o.colors.softWhite};
|
|
68
68
|
}
|
|
69
|
-
`,
|
|
69
|
+
`,E=e.span`
|
|
70
70
|
position: relative;
|
|
71
71
|
display: block;
|
|
72
72
|
width: 30px;
|
|
@@ -84,16 +84,16 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
84
84
|
height: 24px;
|
|
85
85
|
display: block;
|
|
86
86
|
}
|
|
87
|
-
`,
|
|
87
|
+
`,ke=e.span`
|
|
88
88
|
font-size: 13px;
|
|
89
89
|
font-weight: 600;
|
|
90
90
|
letter-spacing: 0.02em;
|
|
91
91
|
opacity: 0.85;
|
|
92
|
-
|
|
92
|
+
`,$e=e.span`
|
|
93
93
|
font-size: 18px;
|
|
94
94
|
font-weight: 600;
|
|
95
95
|
opacity: 0.7;
|
|
96
|
-
`,
|
|
96
|
+
`,je=e.p`
|
|
97
97
|
margin: 0;
|
|
98
98
|
font-family: ${o.font.sans};
|
|
99
99
|
font-weight: 400;
|
|
@@ -101,7 +101,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
101
101
|
line-height: 1;
|
|
102
102
|
color: ${o.colors.muted};
|
|
103
103
|
text-align: center;
|
|
104
|
-
|
|
104
|
+
`,Ce=e.p`
|
|
105
105
|
margin: -4px 0 0;
|
|
106
106
|
font-family: ${o.font.sans};
|
|
107
107
|
font-weight: 400;
|
|
@@ -109,9 +109,9 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
109
109
|
line-height: 1.4;
|
|
110
110
|
color: ${o.colors.muted};
|
|
111
111
|
text-align: center;
|
|
112
|
-
`;function
|
|
112
|
+
`;function gt({options:a,totalCents:n,onPay:i,busy:s=!1,rateNote:l,creditsLabel:c,shortfall:p}){return t.jsxs(we,{children:[a.map(h=>h.method==="credits"?t.jsxs(ve,{type:"button","data-testid":"pay-with-credits",onClick:()=>i("credits"),disabled:s,children:[t.jsx("span",{children:c??g("buyModal.buy")}),t.jsxs(z,{children:[t.jsx(k,{}),t.jsx("span",{children:j(M(h.creditsCents))})]})]},"credits"):h.method==="mana"?t.jsxs(N,{type:"button","data-testid":"pay-with-mana",onClick:()=>i("mana"),disabled:s,children:[t.jsx("span",{children:g("buyModal.buyWithMana")}),t.jsxs(z,{children:[t.jsx(E,{children:t.jsx("img",{src:T,alt:"","aria-hidden":!0})}),t.jsx("span",{children:C(h.manaWei)})]})]},"mana"):t.jsxs(N,{type:"button","data-testid":"pay-with-combined",onClick:()=>i("combined"),disabled:s,children:[t.jsx("span",{children:g("buyModal.buyWith")}),t.jsxs(z,{children:[t.jsx(k,{}),t.jsx("span",{children:j(M(h.creditsCents))}),t.jsx($e,{children:"+"}),t.jsx(E,{children:t.jsx("img",{src:T,alt:"","aria-hidden":!0})}),t.jsx("span",{children:C(h.manaWei)}),t.jsx(ke,{children:"MANA"})]})]},"combined")),p?t.jsxs(t.Fragment,{children:[t.jsxs(N,{type:"button","data-testid":"pay-with-mana-disabled",disabled:!0,children:[t.jsx("span",{children:g("buyModal.buyWithMana")}),t.jsxs(z,{children:[t.jsx(E,{children:t.jsx("img",{src:T,alt:"","aria-hidden":!0})}),t.jsx("span",{children:C(p.manaWei)})]})]},"mana-short"),t.jsx(Ce,{"data-testid":"mana-shortfall-note",children:g("buyModal.manaWorth",{mana:C(p.manaWei),credits:j(M(p.manaCents)),price:j(M(p.priceCents)),currency:Y.name})})]}):null,l?t.jsx(je,{"data-testid":"mana-rate-note",children:l}):null,t.jsx("span",{hidden:!0,"data-testid":"pay-total-cents",children:n})]})}function ft(a,n){const i=(s,...l)=>void a.invalidateQueries({queryKey:n?[s,...l]:[s]});a.invalidateQueries({queryKey:["usd-balance"]}),a.invalidateQueries({queryKey:["detail-trade"]}),a.invalidateQueries({queryKey:["shop-item"]}),i("owned-token",n==null?void 0:n.contractAddress,n==null?void 0:n.tokenId),i("public-token",n==null?void 0:n.contractAddress,n==null?void 0:n.tokenId),i("item-resales",n==null?void 0:n.contractAddress,n==null?void 0:n.itemId),a.invalidateQueries({queryKey:["shop-items"]}),a.invalidateQueries({queryKey:["catalog-items"]}),a.invalidateQueries({queryKey:["overview-listings"]}),a.invalidateQueries({queryKey:["upsell-listings"]}),a.invalidateQueries({queryKey:["my-assets"]}),a.invalidateQueries({queryKey:["purchases"]}),a.invalidateQueries({queryKey:["owned-item-count"]})}const Me=G`
|
|
113
113
|
to { transform: rotate(360deg); }
|
|
114
|
-
`,
|
|
114
|
+
`,ze=e.div`
|
|
115
115
|
position: fixed;
|
|
116
116
|
inset: 0;
|
|
117
117
|
z-index: 10000;
|
|
@@ -120,7 +120,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
120
120
|
justify-content: center;
|
|
121
121
|
padding: 16px;
|
|
122
122
|
background: rgba(22, 21, 24, 0.55);
|
|
123
|
-
`,
|
|
123
|
+
`,Ae=e.div`
|
|
124
124
|
width: 480px;
|
|
125
125
|
max-width: 100%;
|
|
126
126
|
max-height: 92vh;
|
|
@@ -132,21 +132,21 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
132
132
|
display: flex;
|
|
133
133
|
flex-direction: column;
|
|
134
134
|
gap: 20px;
|
|
135
|
-
`,
|
|
135
|
+
`,We=e.div`
|
|
136
136
|
display: flex;
|
|
137
137
|
align-items: center;
|
|
138
138
|
justify-content: space-between;
|
|
139
139
|
gap: 8px;
|
|
140
140
|
padding-bottom: 16px;
|
|
141
141
|
border-bottom: 1px solid ${o.colors.gray4};
|
|
142
|
-
`,
|
|
142
|
+
`,Ie=e.h2`
|
|
143
143
|
margin: 0;
|
|
144
144
|
font-family: ${o.font.sans};
|
|
145
145
|
font-weight: 600;
|
|
146
146
|
font-size: 20px;
|
|
147
147
|
line-height: 1.6;
|
|
148
148
|
color: ${o.colors.text};
|
|
149
|
-
`,
|
|
149
|
+
`,Se=e.button`
|
|
150
150
|
flex: none;
|
|
151
151
|
display: grid;
|
|
152
152
|
place-items: center;
|
|
@@ -169,7 +169,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
169
169
|
outline: 2px solid ${o.colors.accent};
|
|
170
170
|
outline-offset: 2px;
|
|
171
171
|
}
|
|
172
|
-
`,
|
|
172
|
+
`,Te=e.div`
|
|
173
173
|
display: grid;
|
|
174
174
|
grid-template-columns: 44px 1fr;
|
|
175
175
|
align-items: center;
|
|
@@ -178,7 +178,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
178
178
|
background: ${o.colors.white};
|
|
179
179
|
border: 1px solid ${o.colors.line};
|
|
180
180
|
border-radius: 16px;
|
|
181
|
-
`,
|
|
181
|
+
`,Ne=e.div`
|
|
182
182
|
width: 44px;
|
|
183
183
|
height: 44px;
|
|
184
184
|
border-radius: 10px;
|
|
@@ -198,31 +198,31 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
198
198
|
width: 26px;
|
|
199
199
|
height: 26px;
|
|
200
200
|
}
|
|
201
|
-
`,
|
|
201
|
+
`,Ee=e.div`
|
|
202
202
|
min-width: 0;
|
|
203
203
|
display: flex;
|
|
204
204
|
flex-direction: column;
|
|
205
205
|
gap: 4px;
|
|
206
|
-
`,
|
|
206
|
+
`,Be=e.span`
|
|
207
207
|
font-weight: 700;
|
|
208
208
|
color: ${o.colors.text};
|
|
209
|
-
`,
|
|
209
|
+
`,Re=e.span`
|
|
210
210
|
font-size: 13px;
|
|
211
211
|
line-height: 1.45;
|
|
212
212
|
color: ${o.colors.muted};
|
|
213
|
-
`,
|
|
213
|
+
`,Le=e.p`
|
|
214
214
|
margin: 0;
|
|
215
215
|
font-size: 12px;
|
|
216
216
|
line-height: 1.5;
|
|
217
217
|
color: ${o.colors.muted2};
|
|
218
|
-
`,
|
|
218
|
+
`,Pe=e.div`
|
|
219
219
|
display: flex;
|
|
220
220
|
gap: 12px;
|
|
221
221
|
|
|
222
222
|
${o.media.maxWidth("mobile")} {
|
|
223
223
|
flex-direction: column-reverse;
|
|
224
224
|
}
|
|
225
|
-
`,
|
|
225
|
+
`,Fe=e.button`
|
|
226
226
|
flex: 1 1 0;
|
|
227
227
|
height: 48px;
|
|
228
228
|
border: 2px solid ${o.colors.accent};
|
|
@@ -248,7 +248,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
248
248
|
outline: 2px solid ${o.colors.accent};
|
|
249
249
|
outline-offset: 2px;
|
|
250
250
|
}
|
|
251
|
-
`,
|
|
251
|
+
`,Ke=e.button`
|
|
252
252
|
flex: 1 1 0;
|
|
253
253
|
display: inline-flex;
|
|
254
254
|
align-items: center;
|
|
@@ -278,29 +278,29 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
278
278
|
outline: 2px solid ${o.colors.accent};
|
|
279
279
|
outline-offset: 2px;
|
|
280
280
|
}
|
|
281
|
-
`,
|
|
281
|
+
`,De=e.span`
|
|
282
282
|
width: 16px;
|
|
283
283
|
height: 16px;
|
|
284
284
|
border-radius: 50%;
|
|
285
285
|
border: 2px solid rgba(255, 255, 255, 0.5);
|
|
286
286
|
border-top-color: ${o.colors.white};
|
|
287
|
-
animation: ${
|
|
287
|
+
animation: ${Me} 0.7s linear infinite;
|
|
288
288
|
|
|
289
289
|
@media (prefers-reduced-motion: reduce) {
|
|
290
290
|
animation: none;
|
|
291
291
|
}
|
|
292
|
-
`;function
|
|
292
|
+
`;function mt({auth:a,signer:n,title:i,reason:s,name:l,image:c,icon:p,onAuthorized:h,onCancel:m,onClose:b}){const[y,w]=v.useState(!1),[d,f]=v.useState(null);async function $(){w(!0),f(null);try{await ee({auth:a,signer:n,active:!0}),h()}catch(u){se(u)?f(g("authorizeStep.errorRejected")):(X(u,{flow:"authorize_step",kind:a.kind}),f(g("authorizeStep.errorGeneric"))),w(!1)}}return t.jsx(ze,{onClick:y?void 0:b,role:"presentation",children:t.jsxs(Ae,{onClick:u=>u.stopPropagation(),role:"dialog","aria-modal":"true","aria-label":i,children:[t.jsxs(We,{children:[t.jsx(Ie,{children:i}),t.jsx(Se,{onClick:b,disabled:y,"aria-label":g("authorizeStep.close"),children:t.jsx(Q,{name:"close",className:"ico"})})]}),t.jsxs(Te,{"data-testid":"authorize-step-row",children:[t.jsx(Ne,{children:c?t.jsx("img",{src:c,alt:""}):p}),t.jsxs(Ee,{children:[t.jsx(Be,{title:l,children:l}),t.jsx(Re,{children:s})]})]}),t.jsx(Le,{children:g("authorizeStep.note")}),t.jsx(re,{message:d}),t.jsxs(Pe,{children:[t.jsx(Fe,{type:"button",onClick:m,disabled:y,children:g("authorizeStep.cancel")}),t.jsx(Ke,{type:"button","data-testid":"authorize-step-action",onClick:()=>void $(),disabled:y,children:y?t.jsxs(t.Fragment,{children:[t.jsx(De,{"aria-hidden":!0}),g("authorizeStep.authorizing")]}):g("authorizeStep.authorize")})]})]})})}async function bt(a){const[n]=await Qe({...a,trades:[a.trade]});return n}async function Qe(a){const{trades:n,buyer:i,signer:s,onSigned:l}=a;if(n.length===0)throw new Error("No items to buy");const c=new Map;for(const h of n){const m=`${h.chainId}:${h.contract.toLowerCase()}`,b=c.get(m);b?b.push(h):c.set(m,[h])}const p=[];for(const h of c.values())p.push(await Ue({trades:h,buyer:i,signer:s,onSigned:l}));return p}async function Ue(a){const{trades:n,buyer:i,signer:s,onSigned:l}=a,c=n[0],p=W(Z(c.contract),c.chainId),h=W(B.MANAToken,c.chainId);await U({auth:{kind:H.Allowance,contractAddress:h.address,spenderAddress:p.address,chainId:c.chainId},signer:s});const m=n.map(d=>de(d,i));if(K.enabled)try{const d=new xe(p.abi).encodeFunctionData("accept",[m]),f=te(),$=ne(s.provider,f),u=await pe($,f,d,p,{serverURL:K.relayerUrl});return l==null||l(),await ae(u,"the MANA purchase"),u}catch(d){if(d instanceof he&&d.code===ue.USER_DENIED||d instanceof ie)throw d;console.warn("[buyWithMana] gasless meta-tx failed, falling back to a direct tx:",d)}await oe(s.provider,c.chainId);const y=await new ge(p.address,p.abi,s).accept(m,le(c.chainId));return l==null||l(),(await y.wait()).transactionHash}async function yt(a){const{trade:n,buyer:i,signer:s,credits:l,manaGapWei:c,onBroadcast:p,onReverted:h}=a;if(l.length===0)throw new Error("No credits to spend — use buyWithMana for a MANA-only purchase");if(c<=0n)throw new Error("No MANA gap to cover — use buyWithCredits for a credits-only purchase");const m=W(B.MANAToken,n.chainId),b=W(B.CreditsManager,n.chainId);await U({auth:{kind:H.Allowance,contractAddress:m.address,spenderAddress:b.address,chainId:n.chainId},signer:s});const w=(l.reduce((d,f)=>d+BigInt(f.availableAmount),0n)+c).toString();return ce({trade:n,buyer:i,signer:s,credits:l,maxCreditedValue:w,onBroadcast:p,onReverted:h})}function wt(a){return t.jsx("svg",{viewBox:"0 0 18 18",width:"18",height:"18","aria-hidden":!0,...a,children:t.jsx("path",{d:"M4 4l10 10M14 4L4 14",stroke:"#161518",strokeWidth:"1.8",strokeLinecap:"round"})})}function vt(a){return t.jsxs("svg",{viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":!0,...a,children:[t.jsx("path",{d:"M12 3L2 20h20L12 3z",fill:"none",stroke:"#691fa9",strokeWidth:"1.8",strokeLinejoin:"round"}),t.jsx("path",{d:"M12 9v5",stroke:"#691fa9",strokeWidth:"1.8",strokeLinecap:"round"}),t.jsx("circle",{cx:"12",cy:"17",r:"1.1",fill:"#691fa9"})]})}const{colors:r,gradients:O,radius:V,z:He}=o,kt=e.div`
|
|
293
293
|
position: fixed;
|
|
294
294
|
inset: 0;
|
|
295
|
-
z-index: ${
|
|
295
|
+
z-index: ${He.overlay};
|
|
296
296
|
display: flex;
|
|
297
297
|
overflow-y: auto;
|
|
298
298
|
padding: 20px;
|
|
299
|
-
|
|
299
|
+
`,$t=e.div`
|
|
300
300
|
position: fixed;
|
|
301
301
|
inset: 0;
|
|
302
302
|
background: rgba(22, 21, 24, 0.45);
|
|
303
|
-
`,
|
|
303
|
+
`,jt=e.div`
|
|
304
304
|
position: relative;
|
|
305
305
|
z-index: 1;
|
|
306
306
|
margin: auto;
|
|
@@ -330,46 +330,46 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
330
330
|
min-height: 379px;
|
|
331
331
|
justify-content: space-between;
|
|
332
332
|
}
|
|
333
|
-
|
|
333
|
+
`,Ct=e.div`
|
|
334
334
|
display: flex;
|
|
335
335
|
flex-direction: column;
|
|
336
336
|
gap: 4px;
|
|
337
337
|
padding-bottom: 16px;
|
|
338
338
|
border-bottom: 1px solid ${r.gray4};
|
|
339
|
-
`,
|
|
339
|
+
`,Mt=e.div`
|
|
340
340
|
display: flex;
|
|
341
341
|
align-items: flex-start;
|
|
342
342
|
justify-content: space-between;
|
|
343
343
|
gap: 8px;
|
|
344
|
-
`,
|
|
344
|
+
`,zt=e.h2`
|
|
345
345
|
margin: 0;
|
|
346
346
|
font-size: 20px;
|
|
347
347
|
font-weight: 600;
|
|
348
348
|
line-height: 1.6;
|
|
349
349
|
color: ${r.text};
|
|
350
|
-
`,
|
|
350
|
+
`,At=e.button`
|
|
351
351
|
flex-shrink: 0;
|
|
352
352
|
border: 0;
|
|
353
353
|
background: transparent;
|
|
354
354
|
cursor: pointer;
|
|
355
355
|
padding: 2px;
|
|
356
356
|
line-height: 0;
|
|
357
|
-
`,
|
|
357
|
+
`,Wt=e.div`
|
|
358
358
|
display: flex;
|
|
359
359
|
align-items: center;
|
|
360
360
|
gap: 4px;
|
|
361
|
-
`,
|
|
361
|
+
`,It=e.span`
|
|
362
362
|
font-size: 14px;
|
|
363
363
|
font-weight: 600;
|
|
364
364
|
color: ${r.muted1};
|
|
365
|
-
`,
|
|
365
|
+
`,St=e(k)`
|
|
366
366
|
width: 14px;
|
|
367
367
|
height: 14px;
|
|
368
368
|
background: ${r.text};
|
|
369
|
-
`,
|
|
369
|
+
`,Tt=e.span`
|
|
370
370
|
font-size: 14px;
|
|
371
371
|
color: ${r.text};
|
|
372
|
-
`,
|
|
372
|
+
`,Nt=e.div`
|
|
373
373
|
display: flex;
|
|
374
374
|
flex-direction: column;
|
|
375
375
|
gap: 24px;
|
|
@@ -387,11 +387,11 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
387
387
|
gap: 32px;
|
|
388
388
|
padding: 24px 0;
|
|
389
389
|
}
|
|
390
|
-
`,
|
|
390
|
+
`,Et=e.div`
|
|
391
391
|
display: flex;
|
|
392
392
|
gap: 12px;
|
|
393
393
|
align-items: center;
|
|
394
|
-
`,
|
|
394
|
+
`,Bt=e.div`
|
|
395
395
|
flex-shrink: 0;
|
|
396
396
|
width: 180px;
|
|
397
397
|
height: 180px;
|
|
@@ -408,25 +408,25 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
408
408
|
object-fit: contain;
|
|
409
409
|
filter: drop-shadow(0.7px 2.9px 3.7px rgba(0, 0, 0, 0.1));
|
|
410
410
|
}
|
|
411
|
-
`,
|
|
411
|
+
`,Rt=e.div`
|
|
412
412
|
flex: 1;
|
|
413
413
|
min-width: 0;
|
|
414
414
|
display: flex;
|
|
415
415
|
flex-direction: column;
|
|
416
416
|
gap: 32px;
|
|
417
417
|
padding: 8px;
|
|
418
|
-
`,
|
|
418
|
+
`,Lt=e.div`
|
|
419
419
|
font-size: 20px;
|
|
420
420
|
font-weight: 600;
|
|
421
421
|
line-height: 1.57;
|
|
422
422
|
color: ${r.text};
|
|
423
423
|
overflow: hidden;
|
|
424
424
|
text-overflow: ellipsis;
|
|
425
|
-
`,
|
|
425
|
+
`,Pt=e(J)`
|
|
426
426
|
font-size: 10px;
|
|
427
427
|
line-height: 1.43;
|
|
428
428
|
color: ${r.muted};
|
|
429
|
-
`,
|
|
429
|
+
`,Ft=e.div`
|
|
430
430
|
display: flex;
|
|
431
431
|
align-items: center;
|
|
432
432
|
gap: 4px;
|
|
@@ -436,11 +436,11 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
436
436
|
font-weight: 600;
|
|
437
437
|
color: ${r.text2};
|
|
438
438
|
}
|
|
439
|
-
`,
|
|
439
|
+
`,Kt=e(k)`
|
|
440
440
|
width: 24px;
|
|
441
441
|
height: 24px;
|
|
442
442
|
background: ${r.text2};
|
|
443
|
-
`,
|
|
443
|
+
`,Dt=e.div`
|
|
444
444
|
display: flex;
|
|
445
445
|
align-items: center;
|
|
446
446
|
gap: 8px;
|
|
@@ -448,7 +448,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
448
448
|
background: rgba(255, 162, 90, 0.3);
|
|
449
449
|
border-radius: ${V.btn};
|
|
450
450
|
padding: 12px 8px;
|
|
451
|
-
`,
|
|
451
|
+
`,Qt=e.p`
|
|
452
452
|
margin: 0;
|
|
453
453
|
font-size: 14px;
|
|
454
454
|
line-height: 1.334;
|
|
@@ -458,10 +458,10 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
458
458
|
& b {
|
|
459
459
|
font-weight: 700;
|
|
460
460
|
}
|
|
461
|
-
`,
|
|
461
|
+
`,Ut=e.div`
|
|
462
462
|
display: flex;
|
|
463
463
|
gap: 12px;
|
|
464
|
-
`,
|
|
464
|
+
`,Ht=e.button`
|
|
465
465
|
flex: 1;
|
|
466
466
|
height: 109px;
|
|
467
467
|
border: 1px solid ${r.muted2};
|
|
@@ -477,39 +477,39 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
477
477
|
&[data-on] {
|
|
478
478
|
border: 4px solid ${r.magenta};
|
|
479
479
|
}
|
|
480
|
-
`,
|
|
480
|
+
`,_t=e(k)`
|
|
481
481
|
width: 24px;
|
|
482
482
|
height: 24px;
|
|
483
483
|
background: ${r.text};
|
|
484
|
-
`,
|
|
484
|
+
`,Ot=e.span`
|
|
485
485
|
font-size: 24px;
|
|
486
486
|
font-weight: 500;
|
|
487
487
|
color: ${r.text};
|
|
488
|
-
`,
|
|
488
|
+
`,Vt=e.span`
|
|
489
489
|
font-size: 14px;
|
|
490
490
|
color: ${r.text};
|
|
491
|
-
`,
|
|
491
|
+
`,Yt=e.div`
|
|
492
492
|
display: flex;
|
|
493
493
|
align-items: center;
|
|
494
494
|
justify-content: space-between;
|
|
495
495
|
border-top: 1px solid ${r.gray4};
|
|
496
496
|
padding-top: 12px;
|
|
497
|
-
`,
|
|
497
|
+
`,Gt=e.div`
|
|
498
498
|
display: flex;
|
|
499
499
|
align-items: center;
|
|
500
500
|
gap: 8px;
|
|
501
501
|
font-size: 24px;
|
|
502
502
|
font-weight: 700;
|
|
503
503
|
color: ${r.text};
|
|
504
|
-
`,
|
|
504
|
+
`,Xt=e(k)`
|
|
505
505
|
width: 30px;
|
|
506
506
|
height: 30px;
|
|
507
507
|
background: ${r.text};
|
|
508
|
-
`,
|
|
508
|
+
`,Zt=e.span`
|
|
509
509
|
font-size: 14px;
|
|
510
510
|
font-weight: 600;
|
|
511
511
|
color: ${r.muted1};
|
|
512
|
-
`,
|
|
512
|
+
`,Jt=e.div`
|
|
513
513
|
position: sticky;
|
|
514
514
|
bottom: 0;
|
|
515
515
|
display: flex;
|
|
@@ -517,7 +517,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
517
517
|
margin-top: -8px;
|
|
518
518
|
padding-top: 8px;
|
|
519
519
|
background: ${r.white};
|
|
520
|
-
`,
|
|
520
|
+
`,qt=e.button`
|
|
521
521
|
flex: 1;
|
|
522
522
|
/* Let the CTAs shrink so their min-content can't widen the modal past the viewport on mobile. */
|
|
523
523
|
min-width: 0;
|
|
@@ -563,10 +563,10 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
563
563
|
opacity: 0.6;
|
|
564
564
|
cursor: default;
|
|
565
565
|
}
|
|
566
|
-
`,
|
|
566
|
+
`,en=e.img`
|
|
567
567
|
width: 61px;
|
|
568
568
|
height: 61px;
|
|
569
|
-
`,
|
|
569
|
+
`,tn=e.div`
|
|
570
570
|
display: flex;
|
|
571
571
|
flex-direction: column;
|
|
572
572
|
align-items: center;
|
|
@@ -574,11 +574,11 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
574
574
|
background: rgba(255, 201, 213, 0.5);
|
|
575
575
|
border-radius: 16px;
|
|
576
576
|
padding: 24px 16px;
|
|
577
|
-
`,
|
|
577
|
+
`,nn=e.img`
|
|
578
578
|
width: 64px;
|
|
579
579
|
height: 80px;
|
|
580
580
|
object-fit: contain;
|
|
581
|
-
`,
|
|
581
|
+
`,an=e.p`
|
|
582
582
|
margin: 0;
|
|
583
583
|
text-align: center;
|
|
584
584
|
font-size: 20px;
|
|
@@ -589,19 +589,19 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
589
589
|
& b {
|
|
590
590
|
font-weight: 700;
|
|
591
591
|
}
|
|
592
|
-
`,
|
|
592
|
+
`,on=e.div`
|
|
593
593
|
font-size: 20px;
|
|
594
594
|
font-weight: 700;
|
|
595
595
|
color: ${r.text2};
|
|
596
596
|
text-align: center;
|
|
597
|
-
`,
|
|
597
|
+
`,sn=e.div`
|
|
598
598
|
width: 100%;
|
|
599
599
|
max-width: 456px;
|
|
600
600
|
height: 12px;
|
|
601
601
|
background: ${r.media};
|
|
602
602
|
border-radius: 100px;
|
|
603
603
|
overflow: hidden;
|
|
604
|
-
`,
|
|
604
|
+
`,rn=e.span`
|
|
605
605
|
display: block;
|
|
606
606
|
height: 100%;
|
|
607
607
|
width: 40%;
|
|
@@ -623,7 +623,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
623
623
|
min-width: 12px;
|
|
624
624
|
transition: width 0.35s ease;
|
|
625
625
|
}
|
|
626
|
-
`,
|
|
626
|
+
`,cn=e.div`
|
|
627
627
|
display: flex;
|
|
628
628
|
flex-direction: column;
|
|
629
629
|
align-items: center;
|
|
@@ -645,7 +645,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
645
645
|
padding: 16px;
|
|
646
646
|
}
|
|
647
647
|
}
|
|
648
|
-
`,
|
|
648
|
+
`,dn=e.p`
|
|
649
649
|
margin: 0;
|
|
650
650
|
font-size: 20px;
|
|
651
651
|
line-height: 1.334;
|
|
@@ -665,18 +665,18 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
665
665
|
text-align: center;
|
|
666
666
|
}
|
|
667
667
|
}
|
|
668
|
-
`,{colors:I,media:A}=o,
|
|
668
|
+
`,{colors:I,media:A}=o,_e=e.section`
|
|
669
669
|
margin-top: 40px;
|
|
670
|
-
`,
|
|
670
|
+
`,Oe=e.div`
|
|
671
671
|
display: flex;
|
|
672
672
|
align-items: center;
|
|
673
673
|
justify-content: space-between;
|
|
674
674
|
margin-bottom: 20px;
|
|
675
|
-
`,
|
|
675
|
+
`,Ve=e.h2`
|
|
676
676
|
font-size: 22px;
|
|
677
677
|
font-weight: 700;
|
|
678
678
|
color: ${I.text};
|
|
679
|
-
`,
|
|
679
|
+
`,Ye=e.button`
|
|
680
680
|
display: inline-flex;
|
|
681
681
|
align-items: center;
|
|
682
682
|
gap: 4px;
|
|
@@ -694,9 +694,9 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
694
694
|
&:hover {
|
|
695
695
|
text-decoration: underline;
|
|
696
696
|
}
|
|
697
|
-
`,
|
|
697
|
+
`,Ge=e(Q)`
|
|
698
698
|
transform: rotate(-90deg);
|
|
699
|
-
`,
|
|
699
|
+
`,Xe=e.div`
|
|
700
700
|
position: relative;
|
|
701
701
|
`,D=e.button`
|
|
702
702
|
position: absolute;
|
|
@@ -745,7 +745,7 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
745
745
|
${A.maxWidth("lg")} {
|
|
746
746
|
display: none;
|
|
747
747
|
}
|
|
748
|
-
`,
|
|
748
|
+
`,Ze=e.div`
|
|
749
749
|
display: grid;
|
|
750
750
|
grid-auto-flow: column;
|
|
751
751
|
grid-auto-columns: calc((100% - 64px) / 5);
|
|
@@ -773,13 +773,13 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
773
773
|
${A.maxWidth("sm")} {
|
|
774
774
|
grid-auto-columns: calc((100% - 16px) / 2);
|
|
775
775
|
}
|
|
776
|
-
`,
|
|
776
|
+
`,Je=e.div`
|
|
777
777
|
display: flex;
|
|
778
778
|
align-items: center;
|
|
779
779
|
justify-content: center;
|
|
780
780
|
gap: 8px;
|
|
781
781
|
margin-top: 18px;
|
|
782
|
-
`,
|
|
782
|
+
`,qe=e.button`
|
|
783
783
|
width: 10px;
|
|
784
784
|
height: 10px;
|
|
785
785
|
border-radius: 50%;
|
|
@@ -801,4 +801,4 @@ import{j as t,r as v}from"./react-DehiWSvs.js";import{s as e,t as o,e as g,p as
|
|
|
801
801
|
opacity: 1;
|
|
802
802
|
transform: scale(1.1);
|
|
803
803
|
}
|
|
804
|
-
`;function
|
|
804
|
+
`;function ln({title:a,items:n,onViewAll:i}){const s=v.useRef(null),[l,c]=v.useState(1),[p,h]=v.useState(0),[m,b]=v.useState(!0),[y,w]=v.useState(!1),d=v.useCallback(()=>{const u=s.current;if(!u)return;const{scrollLeft:x,scrollWidth:L,clientWidth:S}=u,P=Math.max(1,Math.ceil(L/S));c(P),h(Math.min(P-1,Math.round(x/S))),b(x<=1),w(x+S>=L-1)},[]);if(v.useEffect(()=>{d();const u=s.current;if(u)return u.addEventListener("scroll",d,{passive:!0}),window.addEventListener("resize",d),()=>{u.removeEventListener("scroll",d),window.removeEventListener("resize",d)}},[d,n.length]),n.length===0)return null;function f(u){const x=s.current;x&&x.scrollBy({left:u*x.clientWidth,behavior:"smooth"})}function $(u){const x=s.current;x&&x.scrollTo({left:u*x.clientWidth,behavior:"smooth"})}return t.jsxs(_e,{children:[t.jsxs(Oe,{children:[t.jsx(Ve,{children:a}),i?t.jsxs(Ye,{onClick:i,children:[g("collectionCarousel.viewAll"),t.jsx(Ge,{name:"chevron-down",size:16})]}):null]}),t.jsxs(Xe,{children:[t.jsx(D,{"data-side":"left",onClick:()=>f(-1),"aria-label":g("collectionCarousel.scrollLeft"),disabled:m,children:t.jsx("img",{src:F,alt:"","aria-hidden":!0})}),t.jsx(Ze,{ref:s,children:n.map(u=>t.jsx(q,{item:u},u.id))}),t.jsx(D,{"data-side":"right",onClick:()=>f(1),"aria-label":g("collectionCarousel.scrollRight"),disabled:y,children:t.jsx("img",{src:F,alt:"","aria-hidden":!0})})]}),l>1?t.jsx(Je,{"aria-label":g("collectionCarousel.pages"),children:Array.from({length:l}).map((u,x)=>t.jsx(qe,{"data-active":x===p||void 0,"aria-label":g("collectionCarousel.goToPage",{page:x+1}),"aria-current":x===p?"true":void 0,onClick:()=>$(x)},x))}):null]})}export{M as $,Et as A,Wt as B,jt as C,Ot as D,Vt as E,Yt as F,Gt as G,Ct as H,Xt as I,Zt as J,pt as K,en as L,kt as M,lt as N,ln as O,gt as P,mt as Q,T as R,$t as S,zt as T,dt as U,ft as V,Dt as W,At as X,Qe as Y,ht as Z,be as _,Mt as a,cn as a0,dn as a1,bt as a2,ut as a3,yt as a4,wt as b,It as c,St as d,Tt as e,Nt as f,tn as g,nn as h,an as i,Jt as j,qt as k,on as l,xt as m,sn as n,rn as o,vt as p,Qt as q,Bt as r,Rt as s,Lt as t,Pt as u,Ft as v,Kt as w,Ut as x,Ht as y,_t as z};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{d as Y,j as e,L as be,u as fe,e as we,r as y}from"./react-DehiWSvs.js";import{t as Z,A as je,E as I,D as _,s as r,
|
|
1
|
+
import{d as Y,j as e,L as be,u as fe,e as we,r as y}from"./react-DehiWSvs.js";import{t as Z,A as je,E as I,D as _,s as r,bd as ve,an as Ce,be as ye,e as t,bf as $e,bg as W,B as ke,a9 as q,R as J,n as Ne,v as Q,I as T,c as Pe,m as Se,ac as S,f as Le,ad as Ae,bc as Ee,bh as Fe}from"./index-B0wrSWVL.js";import{d as Me,g as ze,a as Be,P as Re,C as Ie,b as _e,c as We,A as Te,B as He,S as Ue,M as De,e as Ge,f as Ke}from"./browseLayout.styles-D_JQHeMK.js";import{u as Oe,L as Ve}from"./useStore-DCWOq5iS.js";import{S as H,C as Ye,F as Ze,c as qe,P as Je,d as Qe,H as Xe,e as et}from"./categories-D2JgaepG.js";import{L as U}from"./LoadMore-DsWSQHxD.js";import{u as D}from"./useInfiniteGrid-C-7TbIWI.js";import{E as G}from"./ErrorNotice-Cvc0nTjw.js";import{G as K}from"./grid.styles-C92STzz7.js";import"./sentry-973sfbO9.js";import"./dcl-schemas-Dr9BTjb7.js";import"./ethers-CtNGBird.js";import"./intl-CBcMB1D2.js";const{colors:u,radius:X,media:tt}=Z,it=r.article`
|
|
2
2
|
height: 300px;
|
|
3
3
|
background: ${u.bg};
|
|
4
4
|
border-radius: ${X.card};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as r}from"./react-DehiWSvs.js";import{I as i}from"./index-
|
|
1
|
+
import{j as r}from"./react-DehiWSvs.js";import{I as i}from"./index-B0wrSWVL.js";function a({message:e,className:o,testId:t}){return e?r.jsxs("p",{className:o?`error-notice ${o}`:"error-notice","data-testid":t,role:"alert",children:[r.jsx(i,{name:"alert",className:"error-notice__ico",size:18}),r.jsx("span",{className:"error-notice__msg",children:e})]}):null}export{a as E};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{C as l,E as w,b as E,S as A,d as k,O as U,N as P,g as f,B as x,e as N,i as I,p as L}from"./W3MFrameProviderSingleton-
|
|
1
|
+
import{C as l,E as w,b as E,S as A,d as k,O as U,N as P,g as f,B as x,e as N,i as I,p as L}from"./W3MFrameProviderSingleton-BJE-tnmd.js";import{g as T,a as W,f as b,b as _,c as v}from"./index-DU7iVDBh.js";const D=0,C={paymentAsset:null,amount:null,tokenAmount:0,priceLoading:!1,error:null,exchanges:[],isLoading:!1,currentPayment:void 0,isPaymentInProgress:!1,paymentId:"",assets:[]},e=L(C),m={state:e,subscribe(t){return I(e,()=>t(e))},subscribeKey(t,n){return N(e,t,n)},resetState(){Object.assign(e,{...C})},async getAssetsForNetwork(t){const n=v(t),s=await m.getAssetsImageAndPrice(n),r=n.map(a=>{var c,o,p,y;const u=a.asset==="native"?f():`${a.network}:${a.asset}`,i=s.find(S=>{var g,d,h;return((h=(d=(g=S.fungibles)==null?void 0:g[0])==null?void 0:d.address)==null?void 0:h.toLowerCase())===u.toLowerCase()});return{...a,price:((o=(c=i==null?void 0:i.fungibles)==null?void 0:c[0])==null?void 0:o.price)||1,metadata:{...a.metadata,iconUrl:(y=(p=i==null?void 0:i.fungibles)==null?void 0:p[0])==null?void 0:y.iconUrl}}});return e.assets=r,r},async getAssetsImageAndPrice(t){const n=t.map(r=>r.asset==="native"?f():`${r.network}:${r.asset}`);return await Promise.all(n.map(r=>x.fetchTokenPrice({addresses:[r]})))},getTokenAmount(){var s;if(!((s=e==null?void 0:e.paymentAsset)!=null&&s.price))throw new Error("Cannot get token price");const t=P.bigNumber(e.amount??0).round(8),n=P.bigNumber(e.paymentAsset.price).round(8);return t.div(n).round(8).toNumber()},setAmount(t){var n;e.amount=t,(n=e.paymentAsset)!=null&&n.price&&(e.tokenAmount=m.getTokenAmount())},setPaymentAsset(t){e.paymentAsset=t},isPayWithExchangeEnabled(){var t;return(t=U.state.remoteFeatures)==null?void 0:t.payWithExchange},isPayWithExchangeSupported(){return m.isPayWithExchangeEnabled()&&l.state.activeCaipNetwork&&k.PAY_WITH_EXCHANGE_SUPPORTED_CHAIN_NAMESPACES.includes(l.state.activeCaipNetwork.chainNamespace)},async fetchExchanges(){var t;try{const n=m.isPayWithExchangeSupported();if(!e.paymentAsset||!n){e.exchanges=[],e.isLoading=!1;return}e.isLoading=!0;const s=await _({page:D,asset:b(e.paymentAsset.network,e.paymentAsset.asset),amount:((t=e.amount)==null?void 0:t.toString())??"0"});e.exchanges=s.exchanges.slice(0,2)}catch{throw A.showError("Unable to get exchanges"),new Error("Unable to get exchanges")}finally{e.isLoading=!1}},async getPayUrl(t,n){try{const s=Number(n.amount),r=await W({exchangeId:t,asset:b(n.network,n.asset),amount:s.toString(),recipient:`${n.network}:${n.recipient}`});return w.sendEvent({type:"track",event:"PAY_EXCHANGE_SELECTED",properties:{exchange:{id:t},configuration:{network:n.network,asset:n.asset,recipient:n.recipient,amount:s},currentPayment:{type:"exchange",exchangeId:t},source:"fund-from-exchange",headless:!1}}),r}catch(s){throw s instanceof Error&&s.message.includes("is not supported")?new Error("Asset not supported"):new Error(s.message)}},async handlePayWithExchange(t){var n;try{const s=(n=l.getAccountData())==null?void 0:n.address;if(!s)throw new Error("No account connected");if(!e.paymentAsset)throw new Error("No payment asset selected");const r=E.returnOpenHref("","popupWindow","scrollbar=yes,width=480,height=720");if(!r)throw new Error("Could not create popup window");e.isPaymentInProgress=!0,e.paymentId=crypto.randomUUID(),e.currentPayment={type:"exchange",exchangeId:t};const{network:a,asset:u}=e.paymentAsset,i={network:a,asset:u,amount:e.tokenAmount,recipient:s},c=await m.getPayUrl(t,i);if(!c){try{r.close()}catch(o){console.error("Unable to close popup window",o)}throw new Error("Unable to initiate payment")}e.currentPayment.sessionId=c.sessionId,e.currentPayment.status="IN_PROGRESS",e.currentPayment.exchangeId=t,r.location.href=c.url}catch{e.error="Unable to initiate payment",A.showError(e.error)}},async waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r=20}){const a=await m.getBuyStatus(t,n,s);if(a.status==="SUCCESS"||a.status==="FAILED")return a;if(r===0)throw new Error("Unable to get deposit status");return await new Promise(u=>{setTimeout(u,5e3)}),m.waitUntilComplete({exchangeId:t,sessionId:n,paymentId:s,retries:r-1})},async getBuyStatus(t,n,s){var r,a,u,i,c;try{if(!e.currentPayment)throw new Error("No current payment");const o=await T({sessionId:n,exchangeId:t});if(e.currentPayment.status=o.status,o.status==="SUCCESS"||o.status==="FAILED"){const p=(r=l.getAccountData())==null?void 0:r.address;e.currentPayment.result=o.txHash,e.isPaymentInProgress=!1,w.sendEvent({type:"track",event:o.status==="SUCCESS"?"PAY_SUCCESS":"PAY_ERROR",properties:{message:o.status==="FAILED"?E.parseError(e.error):void 0,source:"fund-from-exchange",paymentId:s,configuration:{network:((a=e.paymentAsset)==null?void 0:a.network)||"",asset:((u=e.paymentAsset)==null?void 0:u.asset)||"",recipient:p||"",amount:e.amount??0},currentPayment:{type:"exchange",exchangeId:(i=e.currentPayment)==null?void 0:i.exchangeId,sessionId:(c=e.currentPayment)==null?void 0:c.sessionId,result:o.txHash}}})}return o}catch{return{status:"UNKNOWN",txHash:""}}},reset(){e.currentPayment=void 0,e.isPaymentInProgress=!1,e.paymentId="",e.paymentAsset=null,e.amount=0,e.tokenAmount=0,e.priceLoading=!1,e.error=null,e.exchanges=[],e.isLoading=!1}};export{m as E};
|