@dcl/shop 0.1.0-29254953636.commit-ab5b9c7 → 0.1.0-29254964718.commit-bc79b69
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-CayB6Bll.js → AnimatedBackground-CYPw0X0a.js} +1 -1
- package/assets/{Assets-DoO7bTJC.js → Assets-DxS2faEZ.js} +1 -1
- package/assets/{Button-BwUOrZ4W.js → Button-jfeZp7ca.js} +1 -1
- package/assets/{Cart-DnjBH9F9.js → Cart-D-1Cw1Sr.js} +1 -1
- package/assets/{CircularProgress-DIN0Am04.js → CircularProgress-CPvlc7QL.js} +1 -1
- package/assets/{Collection-FRdInFcr.js → Collection-CYi23kK5.js} +1 -1
- package/assets/{Creator-C5hBRQCk.js → Creator-qLB6WcFI.js} +1 -1
- package/assets/{ExchangeController-F4wgcdv_.js → ExchangeController-V8OR0dzr.js} +1 -1
- package/assets/GetCredits-DPE-aWPu.js +2 -0
- package/assets/{HelpersUtil-9xBYIGVQ.js → HelpersUtil-CtIs2MhB.js} +1 -1
- package/assets/{ImportListings-BmfzpRLv.js → ImportListings-40JsDT9M.js} +1 -1
- package/assets/{ItemDetail-eaGx2XMJ.css → ItemDetail-Casltmsg.css} +1 -1
- package/assets/ItemDetail-I6d0cFBS.js +2 -0
- package/assets/{Market-CPufLt_W.js → Market-WU7aF7sI.js} +1 -1
- package/assets/{MenuItem-CvWwCUyV.js → MenuItem-w3Bac3-j.js} +1 -1
- package/assets/MyAssets-3d8acYU5.js +1 -0
- package/assets/{MyAssets-BjiqkBzd.css → MyAssets-BqJHbQOZ.css} +1 -1
- package/assets/{MyFavorites-Coe5yz6C.js → MyFavorites-B_cD0Nva.js} +1 -1
- package/assets/{MyPurchases-BcWKW6Lx.js → MyPurchases-BKjDwmLs.js} +1 -1
- package/assets/{NotFound-CCVKi2J5.js → NotFound-lbzVYbwO.js} +1 -1
- package/assets/{RealCheckout-CiIiI79v.js → RealCheckout-B0bgjX2-.js} +1 -1
- package/assets/{ShopFooterInner--HXclFzP.js → ShopFooterInner-DZ0k_kvA.js} +2 -2
- package/assets/{Success-Cbjfwo15.js → Success-Dg5SGZJd.js} +1 -1
- package/assets/{SvgIcon-ww3tfKfG.js → SvgIcon-5egtOrJ1.js} +1 -1
- package/assets/{SwapController-Ch2EGE7O.js → SwapController-DGVAOKON.js} +1 -1
- package/assets/{TradeService-_fD_YpjJ.js → TradeService-CFsfszzf.js} +1 -1
- package/assets/{W3MFrameProviderSingleton-D-QSNOHL.js → W3MFrameProviderSingleton-D-sA9voE.js} +3 -3
- package/assets/{WebCryptoP256-Dy_bAN9p.js → WebCryptoP256-Cur58MZH.js} +1 -1
- package/assets/{basic-DRSsVCIz.js → basic-w3M6gfMQ.js} +1 -1
- package/assets/{biconomy-CNbqwxQj.js → biconomy-CYidIfsD.js} +1 -1
- package/assets/{buy-C4TwQkjN.js → buy-DPkdz8_j.js} +1 -1
- package/assets/{buy-gasless-VUH82n0U.js → buy-gasless-C1f9BGN1.js} +1 -1
- package/assets/{ccip-C32UepGQ.js → ccip-BVFRaXzI.js} +1 -1
- package/assets/{ccip-BxtpQQtz.js → ccip-tqDMgLYY.js} +1 -1
- package/assets/{collection-By47wF3B.js → collection-VGK84by0.js} +1 -1
- package/assets/{controller-D-Y8yPKm.js → controller-DX7HSWkP.js} +2 -2
- package/assets/{core-DvUkEMGK.js → core-BM6gIeM_.js} +4 -4
- package/assets/{custom-Do_AW4bs.js → custom-CsWC_84R.js} +1 -1
- package/assets/{data-capture-BkASvRut.js → data-capture-SKbYUAS8.js} +1 -1
- package/assets/{decimals-DU8Kh2PZ.js → decimals-CZLlhwKd.js} +1 -1
- package/assets/decimals-Dx-ayJ8g.js +1 -0
- package/assets/{detectExtension-CXylF5-h.js → detectExtension-BZ2-93E_.js} +1 -1
- package/assets/{email-Dr3FeGBc.js → email-DDSeTNsL.js} +1 -1
- package/assets/{embedded-wallet-mbcn_Q5S.js → embedded-wallet-Brrr_aoM.js} +1 -1
- package/assets/{engine-C_bSZ9f_.js → engine-BFbHnKUR.js} +1 -1
- package/assets/{estimate-l1-fee-BoeGmRPD.js → estimate-l1-fee-C-ypH83W.js} +1 -1
- package/assets/{eth_estimateGas-OWF_H8S2.js → eth_estimateGas-DoUbiXjX.js} +1 -1
- package/assets/{eth_getStorageAt-CT_lFiZW.js → eth_getStorageAt-XRojRAyD.js} +1 -1
- package/assets/{eth_getTransactionCount-DmtEFt6P.js → eth_getTransactionCount-CKTG58Gl.js} +1 -1
- package/assets/{extractIPFS-DEzL2wD0.js → extractIPFS-CUFJqgxI.js} +1 -1
- package/assets/{features-Cg5smZur.js → features-TNRzfRjw.js} +1 -1
- package/assets/{fetchTokenMetadata-DzXu_Y7Y.js → fetchTokenMetadata-CFrMm1kS.js} +2 -2
- package/assets/{generateUtilityClasses-9wixv4Bk.js → generateUtilityClasses-fINIb8L-.js} +1 -1
- package/assets/{get-ecosystem-wallet-info-BhYru4vY.js → get-ecosystem-wallet-info-nffk7j4l.js} +1 -1
- package/assets/{getBalance-hUinJTNJ.js → getBalance-BSwMlOG5.js} +1 -1
- package/assets/{getInstalledModules-D7F8clOV.js → getInstalledModules-DqnNZrIl.js} +1 -1
- package/assets/{getNFT-CVL6aC4b.js → getNFT-CsNxud4l.js} +1 -1
- package/assets/{getNFT-DC9NhuIY.js → getNFT-D5RLr30P.js} +2 -2
- package/assets/{hashTypedData-BMdo4Tma.js → hashTypedData-BUM2UbU8.js} +1 -1
- package/assets/{hashTypedData-M4IJXJgC.js → hashTypedData-DOlGWBor.js} +1 -1
- package/assets/{import-BVOn6UO-.js → import-Bvvecx-a.js} +1 -1
- package/assets/{in-app-wallet-calls-DT0g6FWQ.js → in-app-wallet-calls-BwsYr0X-.js} +1 -1
- package/assets/{index-Dj45ajVb.js → index-1W4ke6tk.js} +1 -1
- package/assets/{index-DSQarJUH.js → index-5E4Qxuys.js} +1 -1
- package/assets/{index-DSEdIyIG.js → index-5FJu7_pQ.js} +1 -1
- package/assets/{index-DTVqE1Je.js → index-93I3rDvn.js} +1 -1
- package/assets/{index-du9LyOqL.js → index-B9e3yQ39.js} +3 -3
- package/assets/{index-iWe9zRwD.js → index-BAVs-li0.js} +1 -1
- package/assets/{index-CMsz8dKN.js → index-BGEefTl2.js} +2 -2
- package/assets/{index-D1sw5222.js → index-BHQVkrbu.js} +1 -1
- package/assets/{index-DQoXJlnn.js → index-BLs4FXiR.js} +1 -1
- package/assets/{index-yun0W_bV.js → index-BN16ZkhT.js} +1 -1
- package/assets/{index-BMk8Iss0.js → index-BPZXZd4b.js} +3 -3
- package/assets/{index-Bt0IcvNq.js → index-BWkZgiPu.js} +1 -1
- package/assets/{index-BOWoMAbj.js → index-BlUhpggc.js} +1 -1
- package/assets/{index-DUT3TOQS.js → index-BsGtBIbY.js} +1 -1
- package/assets/{index-dW1Z2OKD.js → index-ByRL-K0O.js} +1 -1
- package/assets/{index-BGGGYHRg.js → index-BzNrbFS5.js} +1 -1
- package/assets/{index-DxEhcSLK.js → index-C-zOuzFt.js} +1 -1
- package/assets/{index-DywxO5bC.js → index-C5yBkdsj.js} +1 -1
- package/assets/{index-BNe86Sl_.js → index-C8v4sBkt.js} +1 -1
- package/assets/{index--AasD72r.js → index-CBp1JvML.js} +1 -1
- package/assets/{index-BLootnQG.js → index-CIsmu4yZ.js} +1 -1
- package/assets/{index-BJCo8Mlr.js → index-CKP5tgqu.js} +1 -1
- package/assets/{index-CzP-6gXF.js → index-CK_w5rE-.js} +1 -1
- package/assets/{index-CPELH-tG.js → index-CRJchE0b.js} +2 -2
- package/assets/{index-DwvB8BuO.js → index-CVEtsrwz.js} +1 -1
- package/assets/{index-DnfEcQpd.js → index-CaT4Yoza.js} +1 -1
- package/assets/{index-C0tEZ1JP.js → index-Cccog_Wr.js} +1 -1
- package/assets/{index-dYvCsAcL.js → index-CdglnCaM.js} +1 -1
- package/assets/{index-tARlv0yB.js → index-CrAp-Hqd.js} +1 -1
- package/assets/{index-DeDj6J0t.js → index-D2VoAnKZ.js} +1 -1
- package/assets/{index-GtHY0k2m.js → index-DBgz21lR.js} +1 -1
- package/assets/{index-DUcQjvv6.js → index-DGI8RsK5.js} +1 -1
- package/assets/{index-DY82ggfi.js → index-DGb0-PGf.js} +1 -1
- package/assets/{index-BWjhZ1U7.js → index-DOxmIwh4.js} +1 -1
- package/assets/{index-DjE6_m2T.js → index-DQUQfZyN.js} +1 -1
- package/assets/{index-BbXKaqsR.js → index-DT_ZoznA.js} +1 -1
- package/assets/{index-4WN2p1Cr.js → index-DYWK8g8J.js} +1 -1
- package/assets/{index-CkFoP6da.js → index-Dhamn116.js} +1 -1
- package/assets/{index-CePtF-Zu.js → index-DkRoZ1kn.js} +1 -1
- package/assets/{index-BC50Rq_6.js → index-DkYuWNYd.js} +1 -1
- package/assets/{index-BEk0MAzr.js → index-Dn_nS3H8.js} +1 -1
- package/assets/{index-DM0t-7Mu.js → index-DoV0ZXV-.js} +1 -1
- package/assets/{index-49u-BEBa.js → index-Dya1qtKt.js} +1 -1
- package/assets/{index-CBZEInz8.js → index-Dyy2Vrl8.js} +1 -1
- package/assets/{index-Yt_s0ZD3.js → index-NmDgDGPG.js} +1 -1
- package/assets/{index-BEjeMKhX.js → index-OpBhEJ0O.js} +5 -5
- package/assets/{index-BalpXHTm.js → index-SmBWdodi.js} +1 -1
- package/assets/{index-DHbaTadG.js → index-UZsYrJpx.js} +1 -1
- package/assets/{index-5kGVT5eW.js → index-pBIbi3sY.js} +1 -1
- package/assets/{index-Dwiqd_SM.js → index-rziIJjT3.js} +1 -1
- package/assets/{index-BEnLYO4x.js → index-w4da2I_c.js} +2 -2
- package/assets/{index-BmOrf8V5.js → index-xfTQqZlI.js} +1 -1
- package/assets/{index-Dr9tn2p2.js → index-y18oYnpV.js} +1 -1
- package/assets/{index.es-B0Qk3lhw.js → index.es-B2m0dGuK.js} +1 -1
- package/assets/{index.es-SovYeymQ.js → index.es-Bz88joRt.js} +1 -1
- package/assets/{index.es-BuGsSiEx.js → index.es-WVKi35_9.js} +4 -4
- package/assets/{localBatchGatewayRequest-CUliN2qA.js → localBatchGatewayRequest-Dx1Ngoiv.js} +1 -1
- package/assets/{mana-rate-Dw8Alkj5.js → mana-rate-BwWfDtJA.js} +1 -1
- package/assets/network-Ecp55o0j.js +1 -0
- package/assets/{networks-Bn8lbzYo.js → networks-DV6L3hZH.js} +1 -1
- package/assets/{onramp-sy_ZAs95.js → onramp-BgQ1VTr3.js} +1 -1
- package/assets/{openzeppelin-BX7rGxYO.js → openzeppelin-d5g8gt6k.js} +1 -1
- package/assets/{ownerOf-Da6WO9NM.js → ownerOf-mSbNpFEc.js} +1 -1
- package/assets/{parseNft-dq8Wegw6.js → parseNft-BqTY16Sh.js} +2 -2
- package/assets/{parseSignature-CE18PMJh.js → parseSignature-DDoIdVmZ.js} +3 -3
- package/assets/{parseSignature-BEohFJTg.js → parseSignature-DED62W1Z.js} +1 -1
- package/assets/{pay-with-exchange-B5DMoyal.js → pay-with-exchange-DtygapAt.js} +1 -1
- package/assets/{qr-overlay-B4XNgJUl.js → qr-overlay-BsnSx594.js} +1 -1
- package/assets/{receive-DrHUxeg0.js → receive-Bk_Y4nir.js} +1 -1
- package/assets/{resolveImplementation-Dw7iYzWV.js → resolveImplementation-2cqTuYY3.js} +1 -1
- package/assets/{rpc-CSPbHYTq.js → rpc-C-_3TTfR.js} +1 -1
- package/assets/{secp256k1-W29B4T96.js → secp256k1-B6m_r9vE.js} +1 -1
- package/assets/{secp256k1-cia-fuoD.js → secp256k1-DJm7cf-B.js} +1 -1
- package/assets/{secp256k1-DyetGq9U.js → secp256k1-DTGkWTQZ.js} +1 -1
- package/assets/{send-Cy2O1Aa6.js → send-CtZgL8WM.js} +1 -1
- package/assets/{send-batch-transaction-CERvXCWf.js → send-batch-transaction-D0n9dziL.js} +1 -1
- package/assets/{send-eip712-transaction-DbTxDB0F.js → send-eip712-transaction-BZIS831Y.js} +2 -2
- package/assets/{send-gasless-transaction-CIee-JIo.js → send-gasless-transaction-DApNUzAF.js} +2 -2
- package/assets/{sendRawTransaction-CrvsebWe.js → sendRawTransaction-BoQdixC3.js} +3 -3
- package/assets/{serializeTransaction-BsgaKI-B.js → serializeTransaction-DN1RjM-F.js} +1 -1
- package/assets/{session-proposal-CdAe8BME.js → session-proposal-BjuHQlqy.js} +1 -1
- package/assets/{session-request-CTuZIYK3.js → session-request-BYnkRq1D.js} +2 -2
- package/assets/{sha256-BzIX1Kst.js → sha256-S4mPKaQu.js} +1 -1
- package/assets/{signing-CXMLFouj.js → signing-DCH_IdFq.js} +4 -4
- package/assets/{socials-n_JonGPB.js → socials-BoDTcCP1.js} +1 -1
- package/assets/{swaps-DKrnD1zn.js → swaps-CZEay7rk.js} +1 -1
- package/assets/{thirdweb-66hiNImB.js → thirdweb-C7C9bpXy.js} +3 -3
- package/assets/{totalSupply-CQyA5v7z.js → totalSupply-CZT7CnUl.js} +1 -1
- package/assets/{transactionReceipt-CHjL2-o_.js → transactionReceipt-h0CSeAi-.js} +1 -1
- package/assets/{transactions-vVnbaT6V.js → transactions-CbcysK7b.js} +1 -1
- package/assets/{useInfiniteGrid-DL9NgvWc.js → useInfiniteGrid-DcPmkTvS.js} +1 -1
- package/assets/{verifyHash-DHUZPbpz.js → verifyHash-D30bdle-.js} +1 -1
- package/assets/{w3m-modal-03R5f9ZC.js → w3m-modal-DKot6AnX.js} +1 -1
- package/assets/{w3m-modal-BGVoou3v.js → w3m-modal-YGSU7pfJ.js} +1 -1
- package/assets/{wait-for-tx-receipt-CecB1Ixd.js → wait-for-tx-receipt-Dx_eJJVk.js} +1 -1
- package/assets/{wallet-kind-Bb9rH2CA.js → wallet-kind-8FEv-QVA.js} +1 -1
- package/assets/{wallets-Bmpc31N6.js → wallets-C58TNTZv.js} +6 -6
- package/assets/{web-connector-BtTXkrID.js → web-connector-BLGVIwAD.js} +3 -3
- package/assets/{writeContract-BkyA4hiX.js → writeContract-DvcMEQyV.js} +1 -1
- package/assets/{zoraTestnet-BcaU4lTb.js → zoraTestnet-B_y-7tzp.js} +1 -1
- package/index.html +8 -8
- package/package.json +2 -2
- package/assets/GetCredits-DAu4Ajxk.js +0 -2
- package/assets/ItemDetail-DrDwkrrL.js +0 -2
- package/assets/MyAssets-DXUtpmwr.js +0 -1
- package/assets/decimals-CFzc87kE.js +0 -1
- package/assets/network-CLGopcgn.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as b,i as g,b as m}from"./lit-element-B3y9oplH.js";import{n as v,r as h}from"./class-map-CxwNmq0D.js";import{d as y}from"./index-
|
|
1
|
+
import{a as b,i as g,b as m}from"./lit-element-B3y9oplH.js";import{n as v,r as h}from"./class-map-CxwNmq0D.js";import{d as y}from"./index-BPZXZd4b.js";import{c as w}from"./index-Dya1qtKt.js";import{j as x,e as $,i as R,p as T,R as C,M as P}from"./W3MFrameProviderSingleton-D-sA9voE.js";const s=T({message:"",open:!1,triggerRect:{width:0,height:0,top:0,left:0},variant:"shade"}),_={state:s,subscribe(t){return R(s,()=>t(s))},subscribeKey(t,e){return $(s,t,e)},showTooltip({message:t,triggerRect:e,variant:o}){s.open=!0,s.message=t,s.triggerRect=e,s.variant=o},hide(){s.open=!1,s.message="",s.triggerRect={width:0,height:0,top:0,left:0}}},a=x(_),j=b`
|
|
2
2
|
:host {
|
|
3
3
|
width: 100%;
|
|
4
4
|
display: block;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as _,b as l,a as ve}from"./lit-element-B3y9oplH.js";import{n as b,o as f,r as h,a as Ie}from"./class-map-CxwNmq0D.js";import{d as U,r as Ne,e as Se,v as ke}from"./index-
|
|
1
|
+
import{i as _,b as l,a as ve}from"./lit-element-B3y9oplH.js";import{n as b,o as f,r as h,a as Ie}from"./class-map-CxwNmq0D.js";import{d as U,r as Ne,e as Se,v as ke}from"./index-BPZXZd4b.js";import{c as C,U as _e}from"./index-Dya1qtKt.js";import"./index-xfTQqZlI.js";import"./index-93I3rDvn.js";import"./index-DGb0-PGf.js";import"./index-Dyy2Vrl8.js";import"./index-BLs4FXiR.js";import"./index-C5yBkdsj.js";import"./index-rziIJjT3.js";import{$ as Ce,k as v,a0 as $e,a1 as y,b as O,a2 as Re,a3 as N,O as ce,N as A,a4 as me,C as m,q as T,E as M,S as R,n as Oe,M as G,e as Ue,i as Le,p as qe,o as P,R as z}from"./W3MFrameProviderSingleton-D-sA9voE.js";import{au as I}from"./NetworkUtil-DDES604E.js";import"./index-CVEtsrwz.js";import{M as ge}from"./MathUtil-BGCe3rZ3.js";const De=U`
|
|
2
2
|
:host {
|
|
3
3
|
position: relative;
|
|
4
4
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as d,b as h}from"./lit-element-B3y9oplH.js";import{n as r}from"./class-map-CxwNmq0D.js";import{e as m,n as f}from"./ref-BsAZ42-h.js";import{d as c,r as v,e as y,v as b}from"./index-
|
|
1
|
+
import{i as d,b as h}from"./lit-element-B3y9oplH.js";import{n as r}from"./class-map-CxwNmq0D.js";import{e as m,n as f}from"./ref-BsAZ42-h.js";import{d as c,r as v,e as y,v as b}from"./index-BPZXZd4b.js";import{c as g,U as w}from"./index-Dya1qtKt.js";const x=c`
|
|
2
2
|
:host {
|
|
3
3
|
position: relative;
|
|
4
4
|
display: inline-block;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as b,b as l,a as O}from"./lit-element-B3y9oplH.js";import{n as h,r as d}from"./class-map-CxwNmq0D.js";import{d as C,r as E,e as P}from"./index-
|
|
1
|
+
import{i as b,b as l,a as O}from"./lit-element-B3y9oplH.js";import{n as h,r as d}from"./class-map-CxwNmq0D.js";import{d as C,r as E,e as P}from"./index-BPZXZd4b.js";import{c as v,U as x}from"./index-Dya1qtKt.js";import"./index-BN16ZkhT.js";import"./index-BLs4FXiR.js";import{u as g,R as S,o as $,b as R,S as T}from"./W3MFrameProviderSingleton-D-sA9voE.js";const L=C`
|
|
2
2
|
:host {
|
|
3
3
|
position: relative;
|
|
4
4
|
display: inline-block;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as u,b as h}from"./lit-element-B3y9oplH.js";import{n as d,o as f}from"./class-map-CxwNmq0D.js";import{c as p}from"./index-
|
|
1
|
+
import{i as u,b as h}from"./lit-element-B3y9oplH.js";import{n as d,o as f}from"./class-map-CxwNmq0D.js";import{c as p}from"./index-Dya1qtKt.js";import{d as g,r as m,e as b}from"./index-BPZXZd4b.js";const y=g`
|
|
2
2
|
:host {
|
|
3
3
|
display: inline-flex;
|
|
4
4
|
justify-content: center;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as m,b as n}from"./lit-element-B3y9oplH.js";import{n as r}from"./class-map-CxwNmq0D.js";import{c as u}from"./index-
|
|
1
|
+
import{i as m,b as n}from"./lit-element-B3y9oplH.js";import{n as r}from"./class-map-CxwNmq0D.js";import{c as u}from"./index-Dya1qtKt.js";import"./index-DGb0-PGf.js";import"./index-CVEtsrwz.js";import{d as g,r as p,e as x}from"./index-BPZXZd4b.js";const b=g`
|
|
2
2
|
button {
|
|
3
3
|
display: block;
|
|
4
4
|
display: flex;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{w as f,i as w,b as l}from"./lit-element-B3y9oplH.js";import{n as o,o as y}from"./class-map-CxwNmq0D.js";import{c as v,U as $}from"./index-
|
|
1
|
+
import{w as f,i as w,b as l}from"./lit-element-B3y9oplH.js";import{n as o,o as y}from"./class-map-CxwNmq0D.js";import{c as v,U as $}from"./index-Dya1qtKt.js";import"./index-DGb0-PGf.js";import{d as b,r as x,e as z}from"./index-BPZXZd4b.js";import"./index-BzNrbFS5.js";const S=f`<svg width="86" height="96" fill="none">
|
|
2
2
|
<path
|
|
3
3
|
d="M78.3244 18.926L50.1808 2.45078C45.7376 -0.150261 40.2624 -0.150262 35.8192 2.45078L7.6756 18.926C3.23322 21.5266 0.5 26.3301 0.5 31.5248V64.4752C0.5 69.6699 3.23322 74.4734 7.6756 77.074L35.8192 93.5492C40.2624 96.1503 45.7376 96.1503 50.1808 93.5492L78.3244 77.074C82.7668 74.4734 85.5 69.6699 85.5 64.4752V31.5248C85.5 26.3301 82.7668 21.5266 78.3244 18.926Z"
|
|
4
4
|
/>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as x,k as N,r as i,j as f}from"./react-Vu6nbGi5.js";import{al as he,am as ve}from"./index-BEjeMKhX.js";import{J as L}from"./generateUtilityClasses-9wixv4Bk.js";import{r as q,j as ye,k as Ee}from"./Button-BwUOrZ4W.js";import{n as M}from"./SvgIcon-ww3tfKfG.js";import{C as we}from"./CircularProgress-DIN0Am04.js";var y=he(),A={},oe;function Pe(){if(oe)return A;oe=1,Object.defineProperty(A,"__esModule",{value:!0});function e(){let r,n;const t=new Promise((a,u)=>{r=c=>{a(c),t.isPending=!1},n=c=>{u(c),t.isPending=!1}}).catch(a=>Promise.reject(a));return t.resolve=r,t.reject=n,"finally"in t||(t.finally=a=>{t.then(a),t.catch(a)}),t.isPending=!0,t}return A.future=e,A.default=e,A}var be=Pe();const Se=x(be);function ae(e){return{all:e=e||new Map,on:function(r,n){var t=e.get(r);t?t.push(n):e.set(r,[n])},off:function(r,n){var t=e.get(r);t&&(n?t.splice(t.indexOf(n)>>>0,1):e.set(r,[]))},emit:function(r,n){var t=e.get(r);t&&t.slice().map(function(a){a(n)}),(t=e.get("*"))&&t.slice().map(function(a){a(r,n)})}}}const S=new Map,Y=new Map,Z=new Map,k=new Map;function se(e){const r=document.getElementById(e);return!r||!r.contentWindow?!1:Z.get(r.contentWindow)??!1}function H(e){if(e.data&&e.data.type)try{switch(e.data.type){case y.PreviewMessageType.CONTROLLER_RESPONSE:{const r=e.data.payload,{id:n}=r,t=S.get(n);t&&(S.delete(n),r.ok?t.resolve(r.result):r.ok===!1&&t.reject(new Error(r.error)));break}case y.PreviewMessageType.EMOTE_EVENT:{const r=e.data.payload,{type:n,payload:t}=r,a=e.source?Y.get(e.source):null;a&&n&&a.emit(n,t);break}case y.PreviewMessageType.LOAD:{e.source&&(Z.set(e.source,!0),(k.get(e.source)||[]).filter(t=>{var a;return((a=t.data)==null?void 0:a.type)!==y.PreviewMessageType.LOAD}).forEach(H),k.delete(e.source));break}default:}}catch(r){console.error("Error processing WearablePreview message:",r)}}const Me=e=>{var n;if(((n=e.data)==null?void 0:n.type)===y.PreviewMessageType.LOAD){H(e);return}if(!(e.source?Z.get(e.source):!1)&&e.source){const t=k.get(e.source)||[];t.push(e),k.set(e.source,t);return}H(e)};typeof window<"u"&&window.addEventListener("message",Me,!1);let ie=0;function Ae(e){return function(n,t,a){const u=document.getElementById(e);if(!u||!u.contentWindow){const d=new Error("iframe not found or not accessible");return Promise.reject(d)}const c=e+"-"+ie,l=Se();S.set(c,l);const p=y.PreviewMessageType.CONTROLLER_REQUEST,v={id:c,namespace:n,method:t,params:a},m=setTimeout(()=>{S.delete(c),l.reject(new Error(`Request timeout for ${t}`))},1e4),s=l.resolve,j=l.reject;l.resolve=d=>{clearTimeout(m),s(d)},l.reject=d=>{clearTimeout(m),j(d)};try{y.sendMessage(u.contentWindow,p,v)}catch(d){const w=d instanceof Error?d.message:String(d);l.reject(new Error(`Failed to send message: ${w}`)),S.delete(c),clearTimeout(m)}return ie++,l}}function Re(e){const r=document.getElementById(e);if(!r)throw new Error(`Could not find an iframe with id="${e}"`);S.clear();const n=r.contentWindow?Y.get(r.contentWindow)??ae():ae();r.contentWindow&&Y.set(r.contentWindow,n);const t=Ae(e);return{scene:{getScreenshot(a,u){return t("scene","getScreenshot",[a,u])},getMetrics(){return t("scene","getMetrics",[])},changeZoom:function(a){return t("scene","changeZoom",[a])},panCamera:function(a){return t("scene","panCamera",[a])},changeCameraPosition:function(a){return t("scene","changeCameraPosition",[a])},cleanup(){return t("scene","cleanup",[])},setUsername:function(a){return t("scene","setUsername",[a])}},emote:{getLength(){return t("emote","getLength",[])},isPlaying(){return t("emote","isPlaying",[])},goTo(a){return t("emote","goTo",[a])},play(){return t("emote","play",[])},pause(){return t("emote","pause",[])},stop(){return t("emote","stop",[])},enableSound(){return t("emote","enableSound",[])},disableSound(){return t("emote","disableSound",[])},hasSound(){return t("emote","hasSound",[])},isSocialEmote(){return t("emote","isSocialEmote",[])},getSocialEmoteAnimations(){return t("emote","getSocialEmoteAnimations",[])},getPlayingSocialEmoteAnimation(){return t("emote","getPlayingSocialEmoteAnimation",[])},emote:null,events:n},physics:{setSpringBonesParams(a,u){return t("physics","setSpringBonesParams",[a,u])}}}}var g=ve(),R={},ue;function Te(){if(ue)return R;ue=1;var e=L();Object.defineProperty(R,"__esModule",{value:!0}),R.default=void 0;var r=e(q()),n=N();return R.default=(0,r.default)((0,n.jsx)("path",{d:"M6 19h4V5H6zm8-14v14h4V5z"}),"Pause"),R}var Ce=Te();const Ie=x(Ce);var T={},ce;function xe(){if(ce)return T;ce=1;var e=L();Object.defineProperty(T,"__esModule",{value:!0}),T.default=void 0;var r=e(q()),n=N();return T.default=(0,r.default)((0,n.jsx)("path",{d:"M8 5v14l11-7z"}),"PlayArrow"),T}var je=xe();const _e=x(je);var C={},le;function Oe(){if(le)return C;le=1;var e=L();Object.defineProperty(C,"__esModule",{value:!0}),C.default=void 0;var r=e(q()),n=N();return C.default=(0,r.default)((0,n.jsx)("path",{d:"M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63m2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71M4.27 3 3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9zM12 4 9.91 6.09 12 8.18z"}),"VolumeOff"),C}var ke=Oe();const Ne=x(ke);var I={},de;function Le(){if(de)return I;de=1;var e=L();Object.defineProperty(I,"__esModule",{value:!0}),I.default=void 0;var r=e(q()),n=N();return I.default=(0,r.default)((0,n.jsx)("path",{d:"M3 9v6h4l5 5V4L7 9zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02M14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77"}),"VolumeUp"),I}var qe=Le();const We=x(qe),Ve=(e,r)=>{const n=i.useRef(null),[t,a]=i.useState(!1);return i.useEffect(()=>{const u=r??Re(e);if(n.current=u,se(e)){a(!0);return}const c=document.getElementById(e);if(!c){console.error(`Could not find iframe with id="${e}"`);return}if(!c.contentWindow){console.error(`Iframe contentWindow is not accessible for id="${e}"`);return}const p=v=>{var m;((m=v.data)==null?void 0:m.type)===y.PreviewMessageType.LOAD&&se(e)&&a(!0)};return window.addEventListener("message",p),()=>{window.removeEventListener("message",p),a(!1),n.current=null}},[e,r]),{controllerRef:n,isReady:t}},Ue={small:16,medium:20,large:24},me=({children:e,startIcon:r,endIcon:n,loading:t=!1,loadingIcon:a,loadingPosition:u="center",disabled:c=!1,size:l="medium",...p})=>{const v=f.jsx(we,{color:"inherit",size:Ue[l]}),m=a||v,s=t&&u==="center"?m:e;return f.jsx(ye,{disabled:c||t,startIcon:t&&u==="start"?m:r,endIcon:t&&u==="end"?m:n,size:l,...p,children:s})},De=M(Ee)(({theme:e})=>({display:"flex",position:"absolute",width:"100%",bottom:0,margin:`${e.spacing(2)} 0`,padding:`0 ${e.spacing(3)}`,gap:e.spacing(2)})),Fe=M(me)(({theme:e})=>({width:56,height:44,padding:0,minWidth:"unset",background:"rgba(0, 0, 0, 0.64) !important","& svg":{marginLeft:e.spacing(.5)}})),Be=M(me)(({theme:e,muted:r})=>({marginLeft:e.spacing(2.5),minWidth:25,background:"none",padding:0,opacity:r?.5:1})),ze=M("input")(({theme:e})=>({flex:1,width:"100%",background:"none",WebkitAppearance:"none","&:focus":{outline:"none"},"&::-webkit-slider-thumb":{WebkitAppearance:"none",width:24,height:24,borderRadius:10,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer",paddingBottom:e.spacing(.625),marginTop:e.spacing(-.5)},"&::-moz-range-thumb":{width:24,height:24,borderRadius:20,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer",border:"none"},"&::-ms-thumb":{width:24,height:24,borderRadius:20,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer"},"&::-webkit-slider-runnable-track":{width:300,height:15,background:"rgba(115, 110, 125, 0.32)",border:"none",borderRadius:10},"&::-moz-range-track":{width:"100%",height:15,borderRadius:10,cursor:"pointer",background:"rgba(115, 110, 125, 0.32)"}})),$e=M("div")({display:"flex",alignItems:"center"}),Ye=M("input")({width:56,height:44,borderRadius:5,background:"transparent",border:"1px solid rgba(115, 110, 125, 0.4)",color:"white",textAlign:"center","&:focus-visible":{outline:"1px solid"}}),He=({wearablePreviewId:e,className:r,hideFrameInput:n,hideProgressInput:t,hidePlayButton:a,hideSoundButton:u,wearablePreviewController:c,renderPlayButton:l,renderSoundButton:p,renderProgressBar:v,renderFrameInput:m})=>{const{controllerRef:s,isReady:j}=Ve(e,c),[d,w]=i.useState(0),[P,W]=i.useState(!1),[h,fe]=i.useState(void 0),[b,ge]=i.useState(!0),[_,G]=i.useState(void 0),[J,Q]=i.useState(!1),[K,X]=i.useState(!1),V=i.useCallback(()=>{w(0)},[]),U=i.useCallback(()=>{W(!1),w(o=>o>=Math.floor((h??0)*100)?0:o)},[h]),D=i.useCallback(()=>{W(!1)},[]),F=i.useCallback(async()=>{if(!K){let o=h;!h&&s.current&&(o=await s.current.emote.getLength()),W(!0),fe(o)}},[h,K,s]),B=i.useCallback(({length:o})=>{w(Math.ceil((o??0)*100))},[]);i.useEffect(()=>{const o=s.current;if(o)return o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PLAY,F),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PLAYING,B),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_END,U),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PAUSE,D),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_LOOP,V),()=>{o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PLAY,F),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PLAYING,B),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_END,U),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PAUSE,D),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_LOOP,V)}},[s,F,B,U,D,V]),i.useEffect(()=>{_===void 0&&j&&s.current&&s.current.emote.hasSound().then(o=>G(o)).catch(o=>{console.error("Error checking sound:",o),G(!1)})},[_,j,s]);const z=i.useCallback(async()=>{if(s.current)try{await s.current.emote.play()}catch(o){console.error("Error playing emote:",o)}},[s]),$=i.useCallback(async()=>{if(s.current)try{await s.current.emote.pause()}catch(o){console.error("Error pausing emote:",o)}},[s]),ee=i.useCallback(async()=>{P?await $():await z()},[P,z,$]),te=i.useCallback(()=>{var o,E;b?(o=s.current)==null||o.emote.disableSound():(E=s.current)==null||E.emote.enableSound(),ge(!b)},[b,s]),O=i.useCallback(async o=>{if(isNaN(o)||!s.current)return;let E=o;const ne=h??0;ne*100<o&&(E=ne*100),w(E),X(!0);try{P&&(await s.current.emote.pause(),Q(!0)),await s.current.emote.goTo(E/100)}catch(pe){console.error("Error changing frame:",pe)}},[h,P,s]),re=i.useCallback(async()=>{if(X(!1),J&&s.current){try{await s.current.emote.play()}catch(o){console.error("Error resuming play:",o)}Q(!1)}},[J,s]);return f.jsxs(De,{className:r,children:[a?null:l?l({isPlaying:P,onPlay:z,onPause:$,onToggle:ee}):f.jsx(Fe,{onClick:ee,children:P?f.jsx(Ie,{}):f.jsx(_e,{})}),t?null:v?v({frame:d,length:h??0,onChange:O,onMouseUp:re}):f.jsx(ze,{type:"range",value:d,max:Math.ceil((h??0)*100),min:0,step:1,onChange:o=>O(Number(o.target.value)),onMouseUp:re}),n?null:f.jsx($e,{children:m?m({frame:Math.round(d/100),onChange:o=>O(o*100)}):f.jsx(Ye,{type:"number",value:Math.round(d/100),onChange:o=>O(Number(o.target.value)*100)})}),u||!_?null:p?p({isSoundEnabled:b,hasSound:_,onToggle:te}):f.jsx(Be,{muted:!b,onClick:te,children:b?f.jsx(We,{}):f.jsx(Ne,{})})]})},et=Object.freeze(Object.defineProperty({__proto__:null,EmoteControls:He},Symbol.toStringTag,{value:"Module"}));export{me as B,He as E,Re as c,et as i,y as p,Ve as u};
|
|
1
|
+
import{g as x,k as N,r as i,j as f}from"./react-Vu6nbGi5.js";import{al as he,am as ve}from"./index-OpBhEJ0O.js";import{J as L}from"./generateUtilityClasses-fINIb8L-.js";import{r as q,j as ye,k as Ee}from"./Button-jfeZp7ca.js";import{n as M}from"./SvgIcon-5egtOrJ1.js";import{C as we}from"./CircularProgress-CPvlc7QL.js";var y=he(),A={},oe;function Pe(){if(oe)return A;oe=1,Object.defineProperty(A,"__esModule",{value:!0});function e(){let r,n;const t=new Promise((a,u)=>{r=c=>{a(c),t.isPending=!1},n=c=>{u(c),t.isPending=!1}}).catch(a=>Promise.reject(a));return t.resolve=r,t.reject=n,"finally"in t||(t.finally=a=>{t.then(a),t.catch(a)}),t.isPending=!0,t}return A.future=e,A.default=e,A}var be=Pe();const Se=x(be);function ae(e){return{all:e=e||new Map,on:function(r,n){var t=e.get(r);t?t.push(n):e.set(r,[n])},off:function(r,n){var t=e.get(r);t&&(n?t.splice(t.indexOf(n)>>>0,1):e.set(r,[]))},emit:function(r,n){var t=e.get(r);t&&t.slice().map(function(a){a(n)}),(t=e.get("*"))&&t.slice().map(function(a){a(r,n)})}}}const S=new Map,Y=new Map,Z=new Map,k=new Map;function se(e){const r=document.getElementById(e);return!r||!r.contentWindow?!1:Z.get(r.contentWindow)??!1}function H(e){if(e.data&&e.data.type)try{switch(e.data.type){case y.PreviewMessageType.CONTROLLER_RESPONSE:{const r=e.data.payload,{id:n}=r,t=S.get(n);t&&(S.delete(n),r.ok?t.resolve(r.result):r.ok===!1&&t.reject(new Error(r.error)));break}case y.PreviewMessageType.EMOTE_EVENT:{const r=e.data.payload,{type:n,payload:t}=r,a=e.source?Y.get(e.source):null;a&&n&&a.emit(n,t);break}case y.PreviewMessageType.LOAD:{e.source&&(Z.set(e.source,!0),(k.get(e.source)||[]).filter(t=>{var a;return((a=t.data)==null?void 0:a.type)!==y.PreviewMessageType.LOAD}).forEach(H),k.delete(e.source));break}default:}}catch(r){console.error("Error processing WearablePreview message:",r)}}const Me=e=>{var n;if(((n=e.data)==null?void 0:n.type)===y.PreviewMessageType.LOAD){H(e);return}if(!(e.source?Z.get(e.source):!1)&&e.source){const t=k.get(e.source)||[];t.push(e),k.set(e.source,t);return}H(e)};typeof window<"u"&&window.addEventListener("message",Me,!1);let ie=0;function Ae(e){return function(n,t,a){const u=document.getElementById(e);if(!u||!u.contentWindow){const d=new Error("iframe not found or not accessible");return Promise.reject(d)}const c=e+"-"+ie,l=Se();S.set(c,l);const p=y.PreviewMessageType.CONTROLLER_REQUEST,v={id:c,namespace:n,method:t,params:a},m=setTimeout(()=>{S.delete(c),l.reject(new Error(`Request timeout for ${t}`))},1e4),s=l.resolve,j=l.reject;l.resolve=d=>{clearTimeout(m),s(d)},l.reject=d=>{clearTimeout(m),j(d)};try{y.sendMessage(u.contentWindow,p,v)}catch(d){const w=d instanceof Error?d.message:String(d);l.reject(new Error(`Failed to send message: ${w}`)),S.delete(c),clearTimeout(m)}return ie++,l}}function Re(e){const r=document.getElementById(e);if(!r)throw new Error(`Could not find an iframe with id="${e}"`);S.clear();const n=r.contentWindow?Y.get(r.contentWindow)??ae():ae();r.contentWindow&&Y.set(r.contentWindow,n);const t=Ae(e);return{scene:{getScreenshot(a,u){return t("scene","getScreenshot",[a,u])},getMetrics(){return t("scene","getMetrics",[])},changeZoom:function(a){return t("scene","changeZoom",[a])},panCamera:function(a){return t("scene","panCamera",[a])},changeCameraPosition:function(a){return t("scene","changeCameraPosition",[a])},cleanup(){return t("scene","cleanup",[])},setUsername:function(a){return t("scene","setUsername",[a])}},emote:{getLength(){return t("emote","getLength",[])},isPlaying(){return t("emote","isPlaying",[])},goTo(a){return t("emote","goTo",[a])},play(){return t("emote","play",[])},pause(){return t("emote","pause",[])},stop(){return t("emote","stop",[])},enableSound(){return t("emote","enableSound",[])},disableSound(){return t("emote","disableSound",[])},hasSound(){return t("emote","hasSound",[])},isSocialEmote(){return t("emote","isSocialEmote",[])},getSocialEmoteAnimations(){return t("emote","getSocialEmoteAnimations",[])},getPlayingSocialEmoteAnimation(){return t("emote","getPlayingSocialEmoteAnimation",[])},emote:null,events:n},physics:{setSpringBonesParams(a,u){return t("physics","setSpringBonesParams",[a,u])}}}}var g=ve(),R={},ue;function Te(){if(ue)return R;ue=1;var e=L();Object.defineProperty(R,"__esModule",{value:!0}),R.default=void 0;var r=e(q()),n=N();return R.default=(0,r.default)((0,n.jsx)("path",{d:"M6 19h4V5H6zm8-14v14h4V5z"}),"Pause"),R}var Ce=Te();const Ie=x(Ce);var T={},ce;function xe(){if(ce)return T;ce=1;var e=L();Object.defineProperty(T,"__esModule",{value:!0}),T.default=void 0;var r=e(q()),n=N();return T.default=(0,r.default)((0,n.jsx)("path",{d:"M8 5v14l11-7z"}),"PlayArrow"),T}var je=xe();const _e=x(je);var C={},le;function Oe(){if(le)return C;le=1;var e=L();Object.defineProperty(C,"__esModule",{value:!0}),C.default=void 0;var r=e(q()),n=N();return C.default=(0,r.default)((0,n.jsx)("path",{d:"M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63m2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71M4.27 3 3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9zM12 4 9.91 6.09 12 8.18z"}),"VolumeOff"),C}var ke=Oe();const Ne=x(ke);var I={},de;function Le(){if(de)return I;de=1;var e=L();Object.defineProperty(I,"__esModule",{value:!0}),I.default=void 0;var r=e(q()),n=N();return I.default=(0,r.default)((0,n.jsx)("path",{d:"M3 9v6h4l5 5V4L7 9zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02M14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77"}),"VolumeUp"),I}var qe=Le();const We=x(qe),Ve=(e,r)=>{const n=i.useRef(null),[t,a]=i.useState(!1);return i.useEffect(()=>{const u=r??Re(e);if(n.current=u,se(e)){a(!0);return}const c=document.getElementById(e);if(!c){console.error(`Could not find iframe with id="${e}"`);return}if(!c.contentWindow){console.error(`Iframe contentWindow is not accessible for id="${e}"`);return}const p=v=>{var m;((m=v.data)==null?void 0:m.type)===y.PreviewMessageType.LOAD&&se(e)&&a(!0)};return window.addEventListener("message",p),()=>{window.removeEventListener("message",p),a(!1),n.current=null}},[e,r]),{controllerRef:n,isReady:t}},Ue={small:16,medium:20,large:24},me=({children:e,startIcon:r,endIcon:n,loading:t=!1,loadingIcon:a,loadingPosition:u="center",disabled:c=!1,size:l="medium",...p})=>{const v=f.jsx(we,{color:"inherit",size:Ue[l]}),m=a||v,s=t&&u==="center"?m:e;return f.jsx(ye,{disabled:c||t,startIcon:t&&u==="start"?m:r,endIcon:t&&u==="end"?m:n,size:l,...p,children:s})},De=M(Ee)(({theme:e})=>({display:"flex",position:"absolute",width:"100%",bottom:0,margin:`${e.spacing(2)} 0`,padding:`0 ${e.spacing(3)}`,gap:e.spacing(2)})),Fe=M(me)(({theme:e})=>({width:56,height:44,padding:0,minWidth:"unset",background:"rgba(0, 0, 0, 0.64) !important","& svg":{marginLeft:e.spacing(.5)}})),Be=M(me)(({theme:e,muted:r})=>({marginLeft:e.spacing(2.5),minWidth:25,background:"none",padding:0,opacity:r?.5:1})),ze=M("input")(({theme:e})=>({flex:1,width:"100%",background:"none",WebkitAppearance:"none","&:focus":{outline:"none"},"&::-webkit-slider-thumb":{WebkitAppearance:"none",width:24,height:24,borderRadius:10,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer",paddingBottom:e.spacing(.625),marginTop:e.spacing(-.5)},"&::-moz-range-thumb":{width:24,height:24,borderRadius:20,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer",border:"none"},"&::-ms-thumb":{width:24,height:24,borderRadius:20,backgroundColor:"#736e7d",overflow:"visible",cursor:"pointer"},"&::-webkit-slider-runnable-track":{width:300,height:15,background:"rgba(115, 110, 125, 0.32)",border:"none",borderRadius:10},"&::-moz-range-track":{width:"100%",height:15,borderRadius:10,cursor:"pointer",background:"rgba(115, 110, 125, 0.32)"}})),$e=M("div")({display:"flex",alignItems:"center"}),Ye=M("input")({width:56,height:44,borderRadius:5,background:"transparent",border:"1px solid rgba(115, 110, 125, 0.4)",color:"white",textAlign:"center","&:focus-visible":{outline:"1px solid"}}),He=({wearablePreviewId:e,className:r,hideFrameInput:n,hideProgressInput:t,hidePlayButton:a,hideSoundButton:u,wearablePreviewController:c,renderPlayButton:l,renderSoundButton:p,renderProgressBar:v,renderFrameInput:m})=>{const{controllerRef:s,isReady:j}=Ve(e,c),[d,w]=i.useState(0),[P,W]=i.useState(!1),[h,fe]=i.useState(void 0),[b,ge]=i.useState(!0),[_,G]=i.useState(void 0),[J,Q]=i.useState(!1),[K,X]=i.useState(!1),V=i.useCallback(()=>{w(0)},[]),U=i.useCallback(()=>{W(!1),w(o=>o>=Math.floor((h??0)*100)?0:o)},[h]),D=i.useCallback(()=>{W(!1)},[]),F=i.useCallback(async()=>{if(!K){let o=h;!h&&s.current&&(o=await s.current.emote.getLength()),W(!0),fe(o)}},[h,K,s]),B=i.useCallback(({length:o})=>{w(Math.ceil((o??0)*100))},[]);i.useEffect(()=>{const o=s.current;if(o)return o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PLAY,F),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PLAYING,B),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_END,U),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_PAUSE,D),o.emote.events.on(g.PreviewEmoteEventType.ANIMATION_LOOP,V),()=>{o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PLAY,F),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PLAYING,B),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_END,U),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_PAUSE,D),o.emote.events.off(g.PreviewEmoteEventType.ANIMATION_LOOP,V)}},[s,F,B,U,D,V]),i.useEffect(()=>{_===void 0&&j&&s.current&&s.current.emote.hasSound().then(o=>G(o)).catch(o=>{console.error("Error checking sound:",o),G(!1)})},[_,j,s]);const z=i.useCallback(async()=>{if(s.current)try{await s.current.emote.play()}catch(o){console.error("Error playing emote:",o)}},[s]),$=i.useCallback(async()=>{if(s.current)try{await s.current.emote.pause()}catch(o){console.error("Error pausing emote:",o)}},[s]),ee=i.useCallback(async()=>{P?await $():await z()},[P,z,$]),te=i.useCallback(()=>{var o,E;b?(o=s.current)==null||o.emote.disableSound():(E=s.current)==null||E.emote.enableSound(),ge(!b)},[b,s]),O=i.useCallback(async o=>{if(isNaN(o)||!s.current)return;let E=o;const ne=h??0;ne*100<o&&(E=ne*100),w(E),X(!0);try{P&&(await s.current.emote.pause(),Q(!0)),await s.current.emote.goTo(E/100)}catch(pe){console.error("Error changing frame:",pe)}},[h,P,s]),re=i.useCallback(async()=>{if(X(!1),J&&s.current){try{await s.current.emote.play()}catch(o){console.error("Error resuming play:",o)}Q(!1)}},[J,s]);return f.jsxs(De,{className:r,children:[a?null:l?l({isPlaying:P,onPlay:z,onPause:$,onToggle:ee}):f.jsx(Fe,{onClick:ee,children:P?f.jsx(Ie,{}):f.jsx(_e,{})}),t?null:v?v({frame:d,length:h??0,onChange:O,onMouseUp:re}):f.jsx(ze,{type:"range",value:d,max:Math.ceil((h??0)*100),min:0,step:1,onChange:o=>O(Number(o.target.value)),onMouseUp:re}),n?null:f.jsx($e,{children:m?m({frame:Math.round(d/100),onChange:o=>O(o*100)}):f.jsx(Ye,{type:"number",value:Math.round(d/100),onChange:o=>O(Number(o.target.value)*100)})}),u||!_?null:p?p({isSoundEnabled:b,hasSound:_,onToggle:te}):f.jsx(Be,{muted:!b,onClick:te,children:b?f.jsx(We,{}):f.jsx(Ne,{})})]})},et=Object.freeze(Object.defineProperty({__proto__:null,EmoteControls:He},Symbol.toStringTag,{value:"Module"}));export{me as B,He as E,Re as c,et as i,y as p,Ve as u};
|